/* Modern Enhancements */
:root {
    --glass-bg: rgba(255, 255, 255, 0.7);
    --glass-border: rgba(255, 255, 255, 0.5);
    --glass-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.07);
}

html {
    scroll-behavior: smooth;
}

/* Reading Progress Bar */
#progress-bar {
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 4px;
    background: linear-gradient(90deg, var(--cta-color), var(--highlight-gold));
    z-index: 9999;
    transition: width 0.1s ease;
}

/* Animated Background Gradient */
.resume-bg-wrapper {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: -1;
    overflow: hidden;
    background: var(--bg-primary);
}

.gradient-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.15;
    animation: floatOrb 20s infinite ease-in-out;
}

.orb-1 {
    width: 50vw;
    height: 50vw;
    background: var(--cta-color);
    top: -10%;
    left: -10%;
    animation-delay: 0s;
}

.orb-2 {
    width: 40vw;
    height: 40vw;
    background: var(--accent-primary);
    bottom: -10%;
    right: -10%;
    animation-delay: -5s;
}

.orb-3 {
    width: 30vw;
    height: 30vw;
    background: var(--highlight-gold);
    top: 40%;
    left: 40%;
    animation-duration: 25s;
}

@keyframes floatOrb {

    0%,
    100% {
        transform: translate(0, 0) scale(1);
    }

    33% {
        transform: translate(30px, -50px) scale(1.1);
    }

    66% {
        transform: translate(-20px, 20px) scale(0.9);
    }
}

/* Resume Page Specific Styles */
.resume-header {
    text-align: center;
    margin-bottom: 4rem;
    position: relative;
    padding: 3rem 0;
}

.resume-header h1 {
    font-size: 3.5rem;
    background: linear-gradient(135deg, var(--accent-primary), var(--cta-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.5rem;
    opacity: 0;
    animation: fadeDown 0.8s ease forwards 0.2s;
}

.resume-header .tagline {
    font-size: 1.4rem;
    color: var(--text-secondary);
    font-weight: 500;
    opacity: 0;
    animation: fadeDown 0.8s ease forwards 0.4s;
}

.resume-contact-bar {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    flex-wrap: wrap;
    margin-top: 2rem;
    opacity: 0;
    animation: fadeUp 0.8s ease forwards 0.6s;
}

.resume-contact-item {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    color: var(--text-secondary);
    font-size: 0.95rem;
    padding: 0.8rem 1.5rem;
    background: var(--bg-secondary);
    border-radius: 50px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: 1px solid transparent;
    text-decoration: none;
}

.resume-contact-item:hover {
    color: var(--accent-primary);
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
    border-color: var(--cta-color);
}

.resume-contact-item i {
    color: var(--cta-color);
    font-size: 1.1rem;
}

/* Glassmorphism Section Headers */
h2.section-title {
    font-size: 2rem;
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid rgba(0, 0, 0, 0.05);
    position: relative;
}

h2.section-title::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100px;
    height: 2px;
    background: var(--cta-color);
    transition: width 0.3s ease;
}

.section-wrapper:hover h2.section-title::after {
    width: 150px;
}

/* Summary Section */
.resume-summary {
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    padding: 2.5rem;
    border-radius: 20px;
    border: 1px solid var(--glass-border);
    margin-bottom: 4rem;
    box-shadow: var(--glass-shadow);
    position: relative;
    overflow: hidden;
    transition: transform 0.3s ease;
}

.resume-summary:hover {
    transform: scale(1.01);
}

.resume-summary::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 5px;
    background: linear-gradient(180deg, var(--cta-color), var(--highlight-gold));
}

/* Skills Interactive */
.skills-section {
    margin-bottom: 4rem;
}

.skills-grid-modern {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.skill-group {
    background: var(--bg-secondary);
    padding: 2rem;
    border-radius: 16px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.03);
    border: 1px solid var(--shadow-color);
    transition: all 0.3s ease;
}

.skill-group:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.08);
}

.skill-group h3 {
    color: var(--accent-primary);
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.8rem;
    font-size: 1.1rem;
}

.skill-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
}

.skill-tag {
    background: rgba(36, 107, 207, 0.05);
    padding: 0.5rem 1rem;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-secondary);
    border: 1px solid transparent;
    transition: all 0.2s ease;
    cursor: default;
    user-select: none;
}

.skill-tag:hover {
    background: var(--cta-color);
    color: white;
    transform: scale(1.05) rotate(1deg);
}

/* Experience Timeline */
.experience-section {
    margin-bottom: 4rem;
}

.timeline-wrapper {
    position: relative;
    padding-left: 2rem;
}

.timeline-line {
    position: absolute;
    left: 0;
    top: 10px;
    bottom: 0;
    width: 3px;
    background: #e2e8f0;
    border-radius: 3px;
}

.timeline-progress {
    position: absolute;
    left: 0;
    top: 10px;
    width: 3px;
    background: var(--accent-primary);
    height: 0%;
    transition: height 1.5s ease-out;
    max-height: 100%;
}

.experience-item {
    position: relative;
    padding: 2rem;
    background: var(--bg-secondary);
    border-radius: 16px;
    margin-bottom: 2rem;
    border: 1px solid var(--shadow-color);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    margin-left: 1.5rem;
    /* Hidden initially for animation */
    opacity: 0;
    transform: translateX(30px);
}

.experience-item.visible {
    opacity: 1;
    transform: translateX(0);
}

.experience-item:hover {
    transform: translateX(5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.08);
    border-color: var(--cta-color);
    z-index: 10;
}

.timeline-dot {
    position: absolute;
    left: -2.35rem;
    top: 2rem;
    width: 16px;
    height: 16px;
    background: var(--bg-secondary);
    border-radius: 50%;
    border: 3px solid #cbd5e1;
    z-index: 2;
    transition: all 0.3s ease;
}

.experience-item:hover .timeline-dot {
    border-color: var(--accent-primary);
    background: var(--accent-primary);
    box-shadow: 0 0 0 5px rgba(36, 107, 207, 0.2);
}

.experience-header {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.experience-role-group h3 {
    font-size: 1.4rem;
    color: var(--accent-primary);
    margin: 0;
}

.experience-company {
    font-size: 1.1rem;
    color: var(--text-primary);
    font-weight: 700;
}

.experience-date {
    background: linear-gradient(135deg, var(--cta-color), var(--accent-primary));
    color: white;
    padding: 0.4rem 1.2rem;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
    box-shadow: 0 4px 10px rgba(36, 107, 207, 0.3);
}

.experience-bullets li {
    position: relative;
    padding-left: 1.8rem;
    margin-bottom: 0.8rem;
    color: var(--text-secondary);
    line-height: 1.7;
}

.experience-bullets li::before {
    content: '\f00c';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    position: absolute;
    left: 0;
    color: var(--highlight-gold);
    font-size: 0.9rem;
    top: 4px;
}

/* Education & Certs Cards */
.edu-cert-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
    margin-bottom: 4rem;
}

.info-card {
    background: var(--bg-secondary);
    padding: 2rem;
    border-radius: 16px;
    border: 1px solid var(--shadow-color);
    display: flex;
    align-items: flex-start;
    gap: 1.5rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    opacity: 0;
    transform: translateY(20px);
}

.info-card.visible {
    opacity: 1;
    transform: translateY(0);
}

.info-card::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 100px;
    height: 100px;
    background: linear-gradient(135deg, transparent 50%, rgba(36, 107, 207, 0.05) 50%);
    border-radius: 0 16px 0 200px;
    transition: all 0.5s ease;
}

.info-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

.info-card:hover::after {
    width: 150px;
    height: 150px;
    background: linear-gradient(135deg, transparent 50%, rgba(36, 107, 207, 0.1) 50%);
}

.card-icon {
    width: 60px;
    height: 60px;
    background: var(--bg-primary);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    color: var(--accent-primary);
    flex-shrink: 0;
    transition: all 0.3s ease;
}

.info-card:hover .card-icon {
    background: var(--accent-primary);
    color: white;
    transform: rotateY(180deg);
}

/* FAB (Floating Action Button) */
.fab-container {
    position: fixed;
    bottom: 30px;
    right: 30px;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    z-index: 100;
    pointer-events: none;
    /* Initially hidden interaction */
}

.fab-btn {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--cta-color);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    box-shadow: 0 5px 20px rgba(0, 185, 252, 0.4);
    border: none;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    opacity: 0;
    transform: scale(0);
    pointer-events: auto;
}

.fab-btn.visible {
    opacity: 1;
    transform: scale(1);
}

.fab-btn:hover {
    transform: scale(1.1);
    background: var(--accent-primary);
}

/* Tooltip */
.fab-tooltip {
    position: absolute;
    right: 75px;
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    font-size: 0.85rem;
    opacity: 0;
    transition: 0.3s;
    pointer-events: none;
    white-space: nowrap;
}

.fab-btn:hover+.fab-tooltip {
    opacity: 1;
    transform: translateX(-10px);
}

/* Animation Keyframes */
@keyframes fadeDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 768px) {
    .resume-header h1 {
        font-size: 2.2rem;
    }

    .timeline-dots {
        display: none;
    }

    .timeline-line {
        left: 1rem;
    }

    .experience-item {
        margin-left: 0;
    }

    .experience-header {
        flex-direction: column;
        gap: 0.5rem;
    }

    .fab-container {
        bottom: 20px;
        right: 20px;
    }
}

@media print {

    .resume-bg-wrapper,
    #progress-bar,
    .fab-container,
    nav,
    footer {
        display: none !important;
    }

    .resume-summary,
    .skill-group,
    .experience-item,
    .info-card {
        box-shadow: none !important;
        break-inside: avoid;
    }
}