/* ══════════════════════════════════════════════
   GLOBAL SECTION REVEAL (scroll-triggered)
   Excludes cinematic headline
   ══════════════════════════════════════════════ */
.anim-section {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.9s cubic-bezier(0.16, 1, 0.3, 1),
        transform 0.9s cubic-bezier(0.16, 1, 0.3, 1);
}

.anim-section.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* ══════════════════════════════════════════════
   SECTION HEADING UNDERLINE ANIMATION
   ══════════════════════════════════════════════ */
.heading-reveal-container {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    margin-bottom: 2em;
    position: relative;
    max-width: fit-content;
    text-align: left;
}

.heading-reveal-container h2,
.heading-reveal-container p,
.heading-reveal-container span {
    opacity: 0;
    transition: opacity 0.6s ease;
    margin: 0;
    width: 100%;
}

.heading-underline {
    height: 2.5px;
    background: var(--accent);
    width: 80px;
    transform: scaleX(0);
    transform-origin: left;
    /* Changed back to left for a consistent left-aligned draw */
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1) 0.15s;
    border-radius: 99px;
    margin-top: 5px;
    margin-bottom: 5px;
}


.heading-reveal-container.heading-visible h2,
.heading-reveal-container.heading-visible p,
.heading-reveal-container.heading-visible span {
    opacity: 1;
}

.heading-reveal-container.heading-visible .heading-underline {
    transform: scaleX(1);
}



/* ══════════════════════════════════════════════
   HERO STAGGER SYSTEM (Global rule except Role)
   Stagger handled in JS via transition-delay
   ══════════════════════════════════════════════ */
.hero-stagger {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.9s cubic-bezier(0.16, 1, 0.3, 1),
        transform 0.9s cubic-bezier(0.16, 1, 0.3, 1);
}

.hero-stagger.hero-visible {
    opacity: 1;
    transform: translateY(0);
}

/* ══════════════════════════════════════════════
   ROLE HEADLINE — APPLE-LEVEL CINEMATIC
   ══════════════════════════════════════════════ */
.hero-role {
    display: block;
    width: 100%;
    opacity: 0;
    filter: blur(20px);
    transform: scale(1.08);
    transition: opacity 1.2s cubic-bezier(0.25, 0.46, 0.45, 0.94),
        filter 1.2s cubic-bezier(0.25, 0.46, 0.45, 0.94),
        transform 1.2s cubic-bezier(0.25, 0.46, 0.45, 0.94);

    background: linear-gradient(90deg,
            rgb(91, 108, 255) 0%,
            rgb(138, 92, 255) 50%,
            rgb(217, 70, 239) 100%);
    background-size: 200% 100%;
    background-position: 100% 0%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent !important;
    background-clip: text;
}

.hero-role.reveal {
    opacity: 1;
    filter: blur(0);
    transform: scale(1);
}

.role-assoc {
    display: inline-block;
    margin-right: 0.25em;
    font-weight: 800;
}

.role-main {
    display: inline-block;
}

.hero-role.sweep {
    animation: gradientSweep 2s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes gradientSweep {
    0% {
        background-position: 200% 0%;
    }

    100% {
        background-position: -100% 0%;
    }
}

.hero-role.pulse {
    animation: headlinePulse 1.2s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes headlinePulse {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.012);
    }

    100% {
        transform: scale(1);
    }
}

/* ══════════════════════════════════════════════
   PROJECT CARDS (slow minimal)
   ══════════════════════════════════════════════ */
.project-card.anim-card {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.9s cubic-bezier(0.16, 1, 0.3, 1),
        transform 0.9s cubic-bezier(0.16, 1, 0.3, 1);
}

.project-card.anim-card.card-visible {
    opacity: 1;
    transform: translateY(0) !important;
}

/* HIGH SPECIFICITY HOVER OVERRIDE */
.project-card.anim-card.card-visible:hover {
    transform: translateY(-25px) !important;
    box-shadow: 0 80px 160px rgba(0, 0, 0, 0.15);
    z-index: 20;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.4s ease;
}

/* ══════════════════════════════════════════════
   ABOUT ELEMENTS (slow minimal)
   ══════════════════════════════════════════════ */
.about-visual,
.about-body,
.about-stats {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.9s cubic-bezier(0.16, 1, 0.3, 1),
        transform 0.9s cubic-bezier(0.16, 1, 0.3, 1);
}

.about-visual.about-visible,
.about-body.about-visible,
.about-stats.about-visible {
    opacity: 1;
    transform: translateY(0);
}

/* ══════════════════════════════════════════════
   EXPERIENCE / TIMELINE (slow minimal)
   ══════════════════════════════════════════════ */
.exp-item {
    opacity: 0;
    transform: translateX(-30px);
    transition: opacity 0.9s cubic-bezier(0.16, 1, 0.3, 1),
        transform 0.9s cubic-bezier(0.16, 1, 0.3, 1);
}

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

/* Timeline line removed as requested */


/* ══════════════════════════════════════════════
   CERTIFICATION CARDS (scroll-triggered)
   ══════════════════════════════════════════════ */
.cert-card {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.9s cubic-bezier(0.16, 1, 0.3, 1),
        transform 0.9s cubic-bezier(0.16, 1, 0.3, 1);
}

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

/* ══════════════════════════════════════════════
   CONTACT COLUMNS (slow minimal)
   ══════════════════════════════════════════════ */
.contact-info-col,
.contact-form-col {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.9s cubic-bezier(0.16, 1, 0.3, 1),
        transform 0.9s cubic-bezier(0.16, 1, 0.3, 1);
}

.contact-info-col.contact-visible,
.contact-form-col.contact-visible {
    opacity: 1;
    transform: translateY(0);
}

/* REDUCED MOTION PREFERENCE */
@media (prefers-reduced-motion: reduce) {

    .anim-section,
    .hero-stagger,
    .hero-role,
    .aws-card-item,
    .project-card,
    .about-visual,
    .about-body,
    .about-stats,
    .exp-item,
    .cert-card,
    .contact-info-col,
    .contact-form-col {
        opacity: 1 !important;
        transform: none !important;
        filter: none !important;
        transition: none !important;
        animation: none !important;
    }
}

/* ══════════════════════════════════════════════
   PROJECT CARD FINAL HOVER OVERRIDE
   ══════════════════════════════════════════════ */
.project-card:hover,
.project-card.card-visible:hover {
    transform: translateY(-12px) !important;
    box-shadow: 0 50px 100px rgba(0, 0, 0, 0.1) !important;
    z-index: 50 !important;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.4s ease !important;
}

/* ══════════════════════════════════════════════
   EXPERIENCE ITEM FINAL HOVER OVERRIDE
   ══════════════════════════════════════════════ */
.exp-item:hover,
.exp-item.exp-visible:hover {
    transform: translateY(-10px) !important;
    box-shadow: 0 40px 80px rgba(0, 0, 0, 0.08) !important;
    z-index: 50 !important;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.4s ease !important;
}