/* ============================================================
   PORTFOLIO REDESIGN — ATMOSPHERIC IMMERSIVE SINGLE-PAGE
   Nature-inspired · Moonlit Wilderness · Depth Layering
   Scroll-driven atmosphere · Parallax · Organic Glass
   ============================================================ */

/* --- Google Fonts loaded via <link> in HTML for non-blocking load --- */

/* --- CSS Reset --- */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

/* ============================================================
   DESIGN TOKENS — Moonlit Wilderness Palette
   ============================================================ */
:root {
    
    /* Deep Earth Base -> Monochromatic Base */
    --bg-deep: #0a0a0a;
    --bg-primary: #141414;
    --bg-secondary: #1f1f1f;
    --bg-tertiary: #2a2a2a;
    --bg-card: rgba(15, 15, 15, 0.45);
    --bg-card-hover: rgba(20, 20, 20, 0.55);

    /* Organic Glass -> Monochromatic Glass */
    --glass-bg: rgba(15, 15, 15, 0.35);
    --glass-bg-strong: rgba(20, 20, 20, 0.6);
    --glass-border: rgba(255, 255, 255, 0.12);
    --glass-border-hover: rgba(255, 255, 255, 0.18);
    --glass-shine: rgba(255, 255, 255, 0.02);

    /* Atmospheric Accent Lights -> Grayscale Accents */
    --moonlight: #ffffff;   
    --moonlight-dim: rgba(255, 255, 255, 0.08);
    --dawn-amber: #cccccc;
    --dawn-amber-dim: rgba(200, 200, 200, 0.08);
    --forest-sage: #999999;
    --forest-sage-dim: rgba(150, 150, 150, 0.08);
    --autumn-copper: #666666;
    --autumn-copper-dim: rgba(100, 100, 100, 0.08);
    --twilight-lavender: #e0e0e0;
    --twilight-lavender-dim: rgba(220, 220, 220, 0.08);
    --ember-glow: #bbbbbb;

    /* Active accent — changes per section via JS */
    --accent: var(--moonlight);
    --accent-dim: var(--moonlight-dim);
    --accent-secondary: var(--dawn-amber);

    /* Gradients -> Grayscale */
    --gradient-primary: linear-gradient(135deg, #ffffff, #888888);
    --gradient-warm: linear-gradient(135deg, #dddddd, #555555);
    --gradient-nature: linear-gradient(135deg, #aaaaaa, #ffffff);

    /* Text — Grayscale tones */
    --text-primary: #ffffff;
    --text-secondary: #bbbbbb;
    --text-muted: #777777;
    --text-accent: var(--moonlight);

    /* Borders */
    --border-subtle: rgba(255, 255, 255, 0.06);
    --border-glow: rgba(255, 255, 255, 0.12);

    /* Shadows */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.5);
    --shadow-md: 0 4px 24px rgba(0, 0, 0, 0.6);
    --shadow-lg: 0 8px 40px rgba(0, 0, 0, 0.7);
    --shadow-glow: 0 0 40px rgba(255, 255, 255, 0.06), 0 0 80px rgba(255, 255, 255, 0.03);
    --shadow-warm: 0 0 40px rgba(200, 200, 200, 0.06), 0 0 80px rgba(200, 200, 200, 0.03);

    /* Spacing */
    --section-padding: 130px 0;
    --container-max: 1200px;
    --container-padding: 0 40px;

    /* Shape */
    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 20px;
    --radius-xl: 28px;
    --radius-full: 9999px;

    /* Transitions */
    --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-base: 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 0.6s cubic-bezier(0.22, 1, 0.36, 1);
    --transition-spring: 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@media (prefers-color-scheme: light) {
    :root {
        /* Deep Earth Base -> Monochromatic Base */
        --bg-deep: #f5f5f5;
        --bg-primary: #ebebeb;
        --bg-secondary: #e0e0e0;
        --bg-tertiary: #d5d5d5;
        --bg-card: rgba(240, 240, 240, 0.65);
        --bg-card-hover: rgba(230, 230, 230, 0.75);

        /* Organic Glass -> Monochromatic Glass */
        --glass-bg: rgba(250, 250, 250, 0.55);
        --glass-bg-strong: rgba(250, 250, 250, 0.8);
        --glass-border: rgba(0, 0, 0, 0.12);
        --glass-border-hover: rgba(0, 0, 0, 0.18);
        --glass-shine: rgba(0, 0, 0, 0.02);

        /* Atmospheric Accent Lights -> Grayscale Accents */
        --moonlight: #000000;   
        --moonlight-dim: rgba(0, 0, 0, 0.08);
        --dawn-amber: #333333;
        --dawn-amber-dim: rgba(0, 0, 0, 0.08);
        --forest-sage: #666666;
        --forest-sage-dim: rgba(0, 0, 0, 0.08);
        --autumn-copper: #999999;
        --autumn-copper-dim: rgba(0, 0, 0, 0.08);
        --twilight-lavender: #222222;
        --twilight-lavender-dim: rgba(0, 0, 0, 0.08);
        --ember-glow: #444444;

        /* Active accent — changes per section via JS */
        --accent: var(--moonlight);
        --accent-dim: var(--moonlight-dim);
        --accent-secondary: var(--dawn-amber);

        /* Gradients -> Grayscale */
        --gradient-primary: linear-gradient(135deg, #000000, #777777);
        --gradient-warm: linear-gradient(135deg, #222222, #aaaaaa);
        --gradient-nature: linear-gradient(135deg, #555555, #000000);

        /* Text — Grayscale tones */
        --text-primary: #000000;
        --text-secondary: #444444;
        --text-muted: #666666;
        --text-accent: var(--moonlight);

        /* Borders */
        --border-subtle: rgba(0, 0, 0, 0.06);
        --border-glow: rgba(0, 0, 0, 0.12);

        /* Shadows */
        --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.05);
        --shadow-md: 0 4px 24px rgba(0, 0, 0, 0.08);
        --shadow-lg: 0 8px 40px rgba(0, 0, 0, 0.12);
        --shadow-glow: 0 0 40px rgba(0, 0, 0, 0.04), 0 0 80px rgba(0, 0, 0, 0.02);
        --shadow-warm: 0 0 40px rgba(0, 0, 0, 0.04), 0 0 80px rgba(0, 0, 0, 0.02);
    }
}

/* ============================================================
   TYPOGRAPHY
   ============================================================ */
body {
    font-family: 'Outfit', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--bg-deep);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    line-height: 1.12;
    letter-spacing: -0.035em;
}

h1 { font-size: clamp(2.8rem, 6vw, 5rem); }
h2 { font-size: clamp(2rem, 4vw, 3.2rem); }
h3 { font-size: clamp(1.2rem, 2.5vw, 1.5rem); }
h4 { font-size: 1.1rem; }
p { font-size: 1rem; color: var(--text-secondary); }

.mono { font-family: 'JetBrains Mono', monospace; }

/* ============================================================
   LAYOUT
   ============================================================ */
.container {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: var(--container-padding);
}

.portfolio-section {
    padding: var(--section-padding);
    position: relative;
    z-index: 1;
    content-visibility: auto;
    contain-intrinsic-size: auto 800px;
}

/* ============================================================
   ATMOSPHERIC DEPTH LAYERS
   Each section has ambient orbs that create atmosphere
   ============================================================ */
.atmo-layer {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    pointer-events: none;
    overflow: hidden;
    z-index: 0;
}

.atmo-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0;
    transition: opacity 1.2s ease;
    will-change: transform;
}

.atmo-visible .atmo-orb {
    opacity: 1;
}

/* Section-specific atmospheres */
/* Hero — Moonlit clearing */
.atmo-hero .atmo-orb:nth-child(1) {
    width: 500px; height: 500px;
    top: -10%; left: -5%;
    background: radial-gradient(circle, rgba(200, 212, 226, 0.06) 0%, transparent 70%);
    animation: driftSlow1 25s ease-in-out infinite;
}
.atmo-hero .atmo-orb:nth-child(2) {
    width: 400px; height: 400px;
    bottom: -5%; right: -8%;
    background: radial-gradient(circle, rgba(155, 142, 196, 0.05) 0%, transparent 70%);
    animation: driftSlow2 22s ease-in-out infinite;
}
.atmo-hero .atmo-orb:nth-child(3) {
    width: 300px; height: 300px;
    top: 40%; left: 60%;
    background: radial-gradient(circle, rgba(200, 212, 226, 0.03) 0%, transparent 70%);
    animation: driftSlow3 18s ease-in-out infinite;
}

/* About — Dawn breaking */
.atmo-dawn .atmo-orb:nth-child(1) {
    width: 600px; height: 400px;
    top: 20%; right: -15%;
    background: radial-gradient(ellipse, rgba(232, 168, 124, 0.06) 0%, transparent 70%);
    animation: driftSlow2 20s ease-in-out infinite;
}
.atmo-dawn .atmo-orb:nth-child(2) {
    width: 400px; height: 400px;
    bottom: 10%; left: -10%;
    background: radial-gradient(circle, rgba(196, 139, 92, 0.04) 0%, transparent 70%);
    animation: driftSlow1 24s ease-in-out infinite;
}

/* Experience — Golden hour */
.atmo-golden .atmo-orb:nth-child(1) {
    width: 500px; height: 500px;
    top: -15%; left: 30%;
    background: radial-gradient(circle, rgba(232, 168, 124, 0.07) 0%, transparent 70%);
    animation: driftSlow3 22s ease-in-out infinite;
}
.atmo-golden .atmo-orb:nth-child(2) {
    width: 350px; height: 350px;
    bottom: -10%; right: 10%;
    background: radial-gradient(circle, rgba(212, 118, 94, 0.04) 0%, transparent 70%);
    animation: driftSlow1 18s ease-in-out infinite;
}

/* Skills — Forest canopy */
.atmo-forest .atmo-orb:nth-child(1) {
    width: 500px; height: 500px;
    top: 10%; left: -10%;
    background: radial-gradient(circle, rgba(126, 176, 155, 0.06) 0%, transparent 70%);
    animation: driftSlow2 20s ease-in-out infinite;
}
.atmo-forest .atmo-orb:nth-child(2) {
    width: 400px; height: 400px;
    bottom: -5%; right: -5%;
    background: radial-gradient(circle, rgba(126, 176, 155, 0.04) 0%, transparent 70%);
    animation: driftSlow3 24s ease-in-out infinite;
}

/* Projects — Autumn warmth */
.atmo-autumn .atmo-orb:nth-child(1) {
    width: 550px; height: 550px;
    top: -10%; right: -10%;
    background: radial-gradient(circle, rgba(196, 139, 92, 0.06) 0%, transparent 70%);
    animation: driftSlow1 22s ease-in-out infinite;
}
.atmo-autumn .atmo-orb:nth-child(2) {
    width: 400px; height: 400px;
    bottom: 15%; left: -15%;
    background: radial-gradient(circle, rgba(232, 168, 124, 0.04) 0%, transparent 70%);
    animation: driftSlow2 18s ease-in-out infinite;
}

/* Education — Clear sky */
.atmo-sky .atmo-orb:nth-child(1) {
    width: 500px; height: 500px;
    top: -10%; left: 20%;
    background: radial-gradient(circle, rgba(200, 212, 226, 0.05) 0%, transparent 70%);
    animation: driftSlow3 20s ease-in-out infinite;
}

/* Achievements — Sunset */
.atmo-sunset .atmo-orb:nth-child(1) {
    width: 600px; height: 400px;
    top: -5%; right: -10%;
    background: radial-gradient(ellipse, rgba(212, 118, 94, 0.06) 0%, transparent 70%);
    animation: driftSlow1 22s ease-in-out infinite;
}
.atmo-sunset .atmo-orb:nth-child(2) {
    width: 400px; height: 400px;
    bottom: 10%; left: 10%;
    background: radial-gradient(circle, rgba(232, 168, 124, 0.04) 0%, transparent 70%);
    animation: driftSlow2 19s ease-in-out infinite;
}

/* Research — Twilight */
.atmo-twilight .atmo-orb:nth-child(1) {
    width: 500px; height: 500px;
    top: 10%; left: -10%;
    background: radial-gradient(circle, rgba(155, 142, 196, 0.06) 0%, transparent 70%);
    animation: driftSlow2 20s ease-in-out infinite;
}

/* Contact — Starlight */
.atmo-starlight .atmo-orb:nth-child(1) {
    width: 500px; height: 500px;
    top: -15%; right: -5%;
    background: radial-gradient(circle, rgba(200, 212, 226, 0.05) 0%, transparent 70%);
    animation: driftSlow3 22s ease-in-out infinite;
}
.atmo-starlight .atmo-orb:nth-child(2) {
    width: 350px; height: 350px;
    bottom: 10%; left: -5%;
    background: radial-gradient(circle, rgba(155, 142, 196, 0.03) 0%, transparent 70%);
    animation: driftSlow1 18s ease-in-out infinite;
}

@keyframes driftSlow1 {
    0%, 100% { transform: translate(0, 0) scale(1); }
    33% { transform: translate(40px, -25px) scale(1.08); }
    66% { transform: translate(-25px, 35px) scale(0.94); }
}
@keyframes driftSlow2 {
    0%, 100% { transform: translate(0, 0) scale(1); }
    33% { transform: translate(-35px, 30px) scale(1.05); }
    66% { transform: translate(30px, -35px) scale(0.92); }
}
@keyframes driftSlow3 {
    0%, 100% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(20px, 20px) scale(1.1); }
}

/* ============================================================
   LOADING OVERLAY
   ============================================================ */
.loading-overlay {
    position: fixed;
    top: 0; left: 0;
    width: 100vw; height: 100vh;
    background: var(--bg-deep);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    transition: opacity 0.6s ease, visibility 0.6s ease;
}
.loading-overlay.fade-out {
    opacity: 0;
    visibility: hidden;
}
.loading-spinner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 24px;
}
.spinner-ring {
    width: 48px; height: 48px;
    border: 2px solid rgba(200, 212, 226, 0.08);
    border-top: 2px solid var(--moonlight);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}
.loading-text {
    color: var(--text-muted);
    font-size: 12px;
    letter-spacing: 4px;
    text-transform: uppercase;
    font-weight: 400;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ============================================================
   PARTICLE CANVAS
   ============================================================ */
#particle-canvas {
    position: fixed;
    top: 0; left: 0;
    width: 100vw; height: 100vh;
    z-index: 0;
    pointer-events: none;
}

/* ============================================================
   ORGANIC GLASS UTILITIES
   ============================================================ */
.glass-card {
    background: var(--glass-bg);
    backdrop-filter: blur(24px) saturate(1.2);
    -webkit-backdrop-filter: blur(24px) saturate(1.2);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    position: relative;
    overflow: hidden;
    transition: all var(--transition-base);
}

.glass-card::after {
    content: '';
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: linear-gradient(165deg, rgba(255,248,240,0.015) 0%, transparent 50%);
    border-radius: inherit;
    pointer-events: none;
}

.glass-card:hover {
    border-color: var(--glass-border-hover);
    background: var(--bg-card-hover);
    box-shadow: var(--shadow-glow);
}

/* Shimmer line on top of glass cards */
.glass-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent 0%, rgba(200, 212, 226, 0.12) 50%, transparent 100%);
    opacity: 0;
    transition: opacity var(--transition-base);
}
.glass-card:hover::before {
    opacity: 1;
}

/* ============================================================
   NAVIGATION
   ============================================================ */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    transition: transform var(--transition-base), background var(--transition-base), box-shadow var(--transition-base);
}

.navbar.scrolled {
    background: var(--glass-bg-strong);
    backdrop-filter: blur(24px) saturate(1.3);
    -webkit-backdrop-filter: blur(24px) saturate(1.3);
    border-bottom: 1px solid var(--glass-border);
    box-shadow: var(--shadow-md);
}

.navbar.nav-hidden { transform: translateY(-100%); }
.navbar.nav-visible { transform: translateY(0); }

.nav-container {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 68px;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: var(--text-primary);
}
.nav-logo h3 {
    font-size: 1.3rem;
    font-weight: 800;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.02em;
}
.nav-logo .logo-dot {
    width: 7px; height: 7px;
    background: var(--moonlight);
    border-radius: 50%;
    animation: pulse-dot 3s ease-in-out infinite;
    box-shadow: 0 0 8px rgba(200, 212, 226, 0.3);
}
@keyframes pulse-dot {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.3; transform: scale(0.6); }
}

.nav-menu {
    display: flex;
    gap: 2px;
    align-items: center;
}
.nav-link {
    text-decoration: none;
    color: var(--text-muted);
    font-size: 0.82rem;
    font-weight: 500;
    padding: 8px 14px;
    border-radius: var(--radius-full);
    transition: all var(--transition-fast);
    position: relative;
    letter-spacing: 0.02em;
}
.nav-link:hover {
    color: var(--text-secondary);
    background: var(--moonlight-dim);
}
.nav-link.active {
    color: var(--text-primary);
    background: var(--moonlight-dim);
}
.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: 2px; left: 50%;
    transform: translateX(-50%);
    width: 14px; height: 1.5px;
    background: var(--moonlight);
    border-radius: 1px;
    opacity: 0.6;
}

.nav-resume-btn {
    background: var(--moonlight-dim) !important;
    border: 1px solid var(--glass-border) !important;
    color: var(--text-primary) !important;
    font-weight: 600 !important;
    padding: 7px 18px !important;
}
.nav-resume-btn:hover {
    background: var(--glass-border) !important;
    border-color: var(--glass-border-hover) !important;
    transform: translateY(-1px);
}

/* Hamburger */
.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 5px;
    padding: 5px;
    z-index: 1001;
}
.bar {
    width: 22px; height: 1.5px;
    background: var(--text-secondary);
    border-radius: 2px;
    transition: var(--transition-fast);
}
.hamburger.active .bar:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.hamburger.active .bar:nth-child(2) { opacity: 0; }
.hamburger.active .bar:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

/* ============================================================
   HERO SECTION — Moonlit Clearing
   ============================================================ */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    padding: 120px 40px 80px;
    z-index: 1;
}

.hero-container {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 860px;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 20px;
    background: var(--moonlight-dim);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-full);
    font-size: 0.78rem;
    color: var(--text-secondary);
    margin-bottom: 30px;
    font-weight: 500;
    backdrop-filter: blur(10px);
    letter-spacing: 0.5px;
}
.hero-badge .status-dot {
    width: 6px; height: 6px;
    background: var(--forest-sage);
    border-radius: 50%;
    animation: pulse-dot 3s ease-in-out infinite;
    box-shadow: 0 0 6px rgba(126, 176, 155, 0.4);
}

.hero-title {
    font-size: clamp(2.8rem, 7vw, 5.5rem);
    font-weight: 900;
    line-height: 1.05;
    margin-bottom: 14px;
    color: var(--text-primary);
}
.hero-name {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-typed-wrapper {
    min-height: 48px;
    margin-bottom: 22px;
}
.hero-typed {
    font-size: clamp(1.05rem, 2.5vw, 1.4rem);
    font-weight: 400;
    color: var(--text-secondary);
    font-family: 'JetBrains Mono', monospace;
}
.typed-cursor {
    display: inline-block;
    width: 2px;
    height: 1.2em;
    background: var(--moonlight);
    margin-left: 3px;
    animation: blink 1s infinite;
    vertical-align: text-bottom;
    opacity: 0.5;
}
@keyframes blink {
    0%, 50% { opacity: 0.5; }
    51%, 100% { opacity: 0; }
}

.hero-description {
    font-size: 1.08rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto 40px;
    line-height: 1.8;
    font-weight: 300;
}

.hero-buttons {
    display: flex;
    gap: 14px;
    justify-content: center;
    margin-bottom: 60px;
    flex-wrap: wrap;
}

/* Stat orbs */
.hero-stats {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
}
.hero-stat {
    text-align: center;
    padding: 18px 24px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    backdrop-filter: blur(16px);
    transition: all var(--transition-base);
    min-width: 110px;
}
.hero-stat:hover {
    border-color: var(--glass-border-hover);
    transform: translateY(-5px);
    box-shadow: var(--shadow-glow);
}
.hero-stat-value {
    font-size: 2rem;
    font-weight: 800;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1.2;
}
.hero-stat-label {
    font-size: 0.68rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-top: 5px;
    font-weight: 500;
}

.hero-social {
    display: flex;
    gap: 12px;
    justify-content: center;
    margin-top: 40px;
}
.hero-social a {
    width: 44px; height: 44px;
    border-radius: 50%;
    border: 1px solid var(--glass-border);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    text-decoration: none;
    transition: all var(--transition-base);
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    font-size: 0.9rem;
}
.hero-social a:hover {
    border-color: var(--glass-border-hover);
    color: var(--text-primary);
    transform: translateY(-4px);
    box-shadow: var(--shadow-glow);
}

/* Scroll indicator */
.scroll-indicator {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    color: var(--text-muted);
    font-size: 0.65rem;
    letter-spacing: 3px;
    text-transform: uppercase;
    animation: scrollBounce 2.5s ease-in-out infinite;
    font-weight: 400;
}
.scroll-indicator .scroll-line {
    width: 1px;
    height: 28px;
    background: linear-gradient(to bottom, var(--moonlight), transparent);
    opacity: 0.3;
}
@keyframes scrollBounce {
    0%, 100% { transform: translateX(-50%) translateY(0); opacity: 0.5; }
    50% { transform: translateX(-50%) translateY(8px); opacity: 0.2; }
}

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 13px 30px;
    border: none;
    border-radius: var(--radius-full);
    font-family: 'Outfit', sans-serif;
    font-size: 0.88rem;
    font-weight: 500;
    text-decoration: none;
    cursor: pointer;
    transition: all var(--transition-base);
    position: relative;
    overflow: hidden;
    letter-spacing: 0.02em;
}
.btn-primary {
    background: var(--text-primary);
    color: var(--bg-deep);
    box-shadow: 0 4px 20px rgba(232, 224, 216, 0.12);
}
.btn-primary:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 8px 35px rgba(232, 224, 216, 0.18);
}
.btn-secondary {
    background: var(--glass-bg);
    color: var(--text-secondary);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(10px);
}
.btn-secondary:hover {
    border-color: var(--glass-border-hover);
    color: var(--text-primary);
    background: var(--moonlight-dim);
    transform: translateY(-2px);
}

/* ============================================================
   SECTION HEADERS
   ============================================================ */
.section-header {
    text-align: center;
    margin-bottom: 72px;
}
.section-label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 18px;
    background: var(--moonlight-dim);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-full);
    font-size: 0.72rem;
    font-weight: 500;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 2.5px;
    margin-bottom: 20px;
}
.section-label i {
    font-size: 0.7rem;
    opacity: 0.6;
}
.section-title {
    color: var(--text-primary);
    margin-bottom: 14px;
}
.section-subtitle {
    font-size: 1.02rem;
    color: var(--text-muted);
    max-width: 500px;
    margin: 0 auto;
    line-height: 1.7;
    font-weight: 300;
}

/* ============================================================
   ABOUT SECTION
   ============================================================ */
.about-grid {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 56px;
    align-items: center;
}
.about-photo-wrapper {
    position: relative;
}
.about-photo {
    width: 100%;
    aspect-ratio: 3/4;
    object-fit: cover;
    border-radius: var(--radius-lg);
    border: 1px solid var(--glass-border);
    position: relative;
    z-index: 1;
    filter: saturate(0.85) contrast(1.05);
    transition: filter var(--transition-slow);
}
.about-photo-wrapper:hover .about-photo {
    filter: saturate(1) contrast(1);
}
.about-photo-wrapper::after {
    content: '';
    position: absolute;
    inset: -3px;
    border-radius: calc(var(--radius-lg) + 3px);
    background: var(--gradient-primary);
    z-index: 0;
    opacity: 0.12;
    filter: blur(12px);
    transition: opacity var(--transition-base);
}
.about-photo-wrapper:hover::after { opacity: 0.25; }

.about-bio { margin-bottom: 32px; }
.about-bio p {
    font-size: 1.02rem;
    line-height: 1.9;
    color: var(--text-secondary);
    font-weight: 300;
}
.about-info-tags {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 24px;
}
.info-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-full);
    font-size: 0.78rem;
    font-weight: 500;
    color: var(--text-muted);
    backdrop-filter: blur(10px);
    transition: all var(--transition-fast);
}
.info-tag i { color: var(--dawn-amber); font-size: 0.75rem; }
.info-tag:hover {
    border-color: var(--glass-border-hover);
    color: var(--text-secondary);
    transform: translateY(-2px);
}

/* ============================================================
   EXPERIENCE — Horizontal Timeline
   ============================================================ */
.experience-timeline {
    position: relative;
    display: flex;
    gap: 20px;
    overflow-x: auto;
    overflow-y: visible;
    padding: 20px 0 40px;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}
.experience-timeline::-webkit-scrollbar { display: none; }

.experience-timeline::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0; width: 100%;
    height: 1px;
    background: linear-gradient(90deg, var(--moonlight), var(--dawn-amber), var(--twilight-lavender), transparent);
    opacity: 0.12;
    transform: translateY(-50%);
    z-index: 0;
    pointer-events: none;
}

.exp-card {
    flex: 0 0 330px;
    scroll-snap-align: center;
    position: relative;
    z-index: 1;
}
.exp-card-inner {
    background: var(--glass-bg);
    backdrop-filter: blur(24px) saturate(1.2);
    -webkit-backdrop-filter: blur(24px) saturate(1.2);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    padding: 28px;
    transition: all var(--transition-base);
    position: relative;
    overflow: hidden;
    height: 100%;
}
.exp-card-inner::after {
    content: '';
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: linear-gradient(165deg, rgba(255,248,240,0.012) 0%, transparent 50%);
    border-radius: inherit;
    pointer-events: none;
}
.exp-card-inner:hover {
    border-color: var(--glass-border-hover);
    transform: translateY(-6px);
    box-shadow: var(--shadow-warm);
}

.exp-dot {
    position: absolute;
    top: -10px; left: 28px;
    width: 12px; height: 12px;
    background: var(--dawn-amber);
    border-radius: 50%;
    border: 3px solid var(--bg-deep);
    box-shadow: 0 0 10px rgba(232, 168, 124, 0.3);
    z-index: 2;
}
.exp-dot.current { animation: pulse-dot 3s ease-in-out infinite; }

.exp-header {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 12px;
}
.exp-logo {
    width: 44px; height: 44px;
    border-radius: var(--radius-sm);
    object-fit: contain;
    background: rgba(255,255,255,0.04);
    padding: 4px;
    flex-shrink: 0;
}
.exp-info h3 { font-size: 1rem; color: var(--text-primary); font-weight: 600; }
.exp-info h4 { font-size: 0.82rem; color: var(--dawn-amber); font-weight: 500; }
.exp-period {
    display: inline-flex;
    padding: 4px 12px;
    background: rgba(232, 168, 124, 0.04);
    border: 1px solid rgba(232, 168, 124, 0.08);
    border-radius: var(--radius-full);
    font-size: 0.7rem;
    color: var(--dawn-amber);
    font-weight: 500;
    margin-bottom: 12px;
    letter-spacing: 0.5px;
    opacity: 0.8;
}
.exp-description {
    color: var(--text-secondary);
    font-size: 0.85rem;
    line-height: 1.75;
    font-weight: 300;
}

.carousel-controls {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 24px;
}
.carousel-btn {
    width: 42px; height: 42px;
    border-radius: 50%;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    color: var(--text-muted);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-fast);
    backdrop-filter: blur(10px);
    font-size: 0.85rem;
}
.carousel-btn:hover {
    border-color: var(--glass-border-hover);
    color: var(--text-secondary);
    background: rgba(200, 212, 226, 0.03);
}

/* ============================================================
   SKILLS
   ============================================================ */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
    gap: 18px;
}
.skill-category-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    padding: 26px;
    backdrop-filter: blur(20px) saturate(1.2);
    -webkit-backdrop-filter: blur(20px) saturate(1.2);
    transition: all var(--transition-base);
    position: relative;
    overflow: hidden;
}
.skill-category-card::after {
    content: '';
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: linear-gradient(165deg, rgba(255,248,240,0.01) 0%, transparent 50%);
    border-radius: inherit;
    pointer-events: none;
}
.skill-category-card:hover {
    border-color: var(--glass-border-hover);
    transform: translateY(-3px);
    box-shadow: var(--shadow-glow);
}
.skill-category-card h3 {
    font-size: 0.95rem;
    margin-bottom: 14px;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
}
.skill-category-card h3 i {
    color: var(--forest-sage);
    font-size: 0.88rem;
}

.skills-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
}
.skill-tag {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 6px 13px;
    background: rgba(126, 176, 155, 0.03);
    border: 1px solid rgba(126, 176, 155, 0.06);
    border-radius: var(--radius-full);
    font-size: 0.76rem;
    font-weight: 500;
    color: var(--text-secondary);
    transition: all var(--transition-fast);
}
.skill-tag i {
    font-size: 0.9rem;
    color: var(--forest-sage);
    opacity: 0.7;
}
.skill-tag:hover {
    background: rgba(126, 176, 155, 0.08);
    border-color: rgba(126, 176, 155, 0.18);
    color: var(--text-primary);
    transform: translateY(-2px);
}

.non-technical-tag {
    background: rgba(155, 142, 196, 0.03);
    border-color: rgba(155, 142, 196, 0.06);
}
.non-technical-tag i { color: var(--twilight-lavender); opacity: 0.7; }
.non-technical-tag:hover {
    background: rgba(155, 142, 196, 0.08);
    border-color: rgba(155, 142, 196, 0.18);
}

/* ============================================================
   PROJECTS — Grid with 3D Tilt
   ============================================================ */
.projects-controls {
    display: flex;
    flex-direction: column;
    gap: 18px;
    margin-bottom: 40px;
}
.search-wrapper {
    position: relative;
    max-width: 460px;
    margin: 0 auto;
    width: 100%;
}
.search-wrapper i {
    position: absolute;
    left: 18px; top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 0.85rem;
}
.search-input {
    width: 100%;
    padding: 13px 18px 13px 46px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-full);
    color: var(--text-primary);
    font-family: 'Outfit', sans-serif;
    font-size: 0.88rem;
    transition: all var(--transition-fast);
    outline: none;
    backdrop-filter: blur(10px);
    font-weight: 300;
}
.search-input:focus {
    border-color: rgba(200, 212, 226, 0.15);
    box-shadow: 0 0 0 3px rgba(200, 212, 226, 0.04);
}
.search-input::placeholder { color: var(--text-muted); }

.filter-tags {
    display: flex;
    gap: 8px;
    justify-content: center;
    flex-wrap: wrap;
}
.filter-tag {
    padding: 7px 18px;
    background: transparent;
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-full);
    color: var(--text-muted);
    font-size: 0.78rem;
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition-fast);
    font-family: 'Outfit', sans-serif;
}
.filter-tag:hover,
.filter-tag.active {
    background: rgba(196, 139, 92, 0.05);
    border-color: rgba(196, 139, 92, 0.15);
    color: var(--autumn-copper);
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(355px, 1fr));
    gap: 20px;
}
.project-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: all var(--transition-base);
    display: flex;
    flex-direction: column;
    opacity: 0;
    transform: translateY(25px);
    backdrop-filter: blur(20px) saturate(1.2);
    -webkit-backdrop-filter: blur(20px) saturate(1.2);
    transform-style: preserve-3d;
    perspective: 1000px;
}
.project-card.visible {
    opacity: 1;
    transform: translateY(0);
}
.project-card:hover {
    border-color: var(--glass-border-hover);
    box-shadow: var(--shadow-warm);
}
.project-card.tilting { transition: none !important; }

.project-media {
    position: relative;
    overflow: hidden;
    background: rgba(0,0,0,0.2);
}
.project-media img,
.project-media video {
    width: 100%;
    height: 210px;
    object-fit: cover;
    transition: transform 0.6s ease;
    filter: saturate(0.8) brightness(0.95);
}
.project-card:hover .project-media img,
.project-card:hover .project-media video {
    transform: scale(1.05);
    filter: saturate(1) brightness(1);
}
.project-type-badge {
    position: absolute;
    top: 12px; left: 12px;
    padding: 4px 12px;
    background: rgba(12, 10, 9, 0.75);
    border: 1px solid rgba(200, 212, 226, 0.1);
    border-radius: var(--radius-full);
    font-size: 0.66rem;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 1px;
    backdrop-filter: blur(8px);
}
.project-status-badge {
    position: absolute;
    top: 12px; right: 12px;
    padding: 4px 12px;
    border-radius: var(--radius-full);
    font-size: 0.66rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    backdrop-filter: blur(8px);
}
.project-status-badge.completed {
    background: rgba(126, 176, 155, 0.1);
    border: 1px solid rgba(126, 176, 155, 0.15);
    color: var(--forest-sage);
}
.project-status-badge.in-progress {
    background: rgba(232, 168, 124, 0.1);
    border: 1px solid rgba(232, 168, 124, 0.15);
    color: var(--dawn-amber);
}
.project-content {
    padding: 22px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}
.project-title {
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
}
.project-description {
    color: var(--text-secondary);
    font-size: 0.85rem;
    line-height: 1.7;
    margin-bottom: 14px;
    flex-grow: 1;
    font-weight: 300;
}
.project-tech-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-bottom: 14px;
}
.tech-tag {
    padding: 3px 10px;
    background: rgba(196, 139, 92, 0.05);
    border: 1px solid rgba(196, 139, 92, 0.1);
    border-radius: var(--radius-full);
    font-size: 0.66rem;
    color: var(--autumn-copper);
    font-weight: 500;
    opacity: 0.8;
}
.project-footer {
    display: flex;
    gap: 8px;
    margin-top: auto;
}
.project-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 14px;
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-full);
    font-size: 0.78rem;
    font-weight: 500;
    color: var(--text-muted);
    text-decoration: none;
    transition: all var(--transition-fast);
}
.project-link:hover {
    border-color: var(--glass-border-hover);
    color: var(--text-secondary);
}
.project-link.disabled { opacity: 0.25; pointer-events: none; }

.no-results {
    text-align: center;
    padding: 80px 20px;
    color: var(--text-muted);
    grid-column: 1 / -1;
}
.no-results i { font-size: 2.5rem; margin-bottom: 16px; display: block; opacity: 0.4; }

/* ============================================================
   EDUCATION — Vertical Timeline
   ============================================================ */
.education-timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
    padding-left: 40px;
}
.education-timeline::before {
    content: '';
    position: absolute;
    left: 0; top: 0; bottom: 0;
    width: 1px;
    background: linear-gradient(to bottom, var(--moonlight), var(--dawn-amber), transparent);
    opacity: 0.15;
}
.edu-item {
    position: relative;
    margin-bottom: 36px;
    padding-left: 32px;
}
.edu-dot {
    position: absolute;
    left: -47px; top: 6px;
    width: 12px; height: 12px;
    background: var(--moonlight);
    border-radius: 50%;
    border: 3px solid var(--bg-deep);
    box-shadow: 0 0 10px rgba(200, 212, 226, 0.2);
}
.edu-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    padding: 24px;
    backdrop-filter: blur(20px) saturate(1.2);
    -webkit-backdrop-filter: blur(20px) saturate(1.2);
    transition: all var(--transition-base);
}
.edu-card:hover {
    border-color: var(--glass-border-hover);
    box-shadow: var(--shadow-glow);
}
.edu-header {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 12px;
}
.edu-logo {
    width: 50px; height: 50px;
    border-radius: var(--radius-sm);
    object-fit: contain;
    background: rgba(255,255,255,0.04);
    padding: 5px;
    flex-shrink: 0;
}
.edu-info h3 { font-size: 1.05rem; color: var(--text-primary); }
.edu-info h4 { font-size: 0.82rem; color: var(--moonlight); font-weight: 500; opacity: 0.7; }
.edu-period {
    display: inline-flex;
    padding: 4px 12px;
    background: rgba(200, 212, 226, 0.03);
    border: 1px solid rgba(200, 212, 226, 0.06);
    border-radius: var(--radius-full);
    font-size: 0.7rem;
    color: var(--text-muted);
    font-weight: 500;
    margin-right: 8px;
}
.edu-status {
    display: inline-flex;
    padding: 4px 12px;
    border-radius: var(--radius-full);
    font-size: 0.66rem;
    font-weight: 600;
}
.edu-status.graduated {
    background: rgba(126, 176, 155, 0.06);
    border: 1px solid rgba(126, 176, 155, 0.1);
    color: var(--forest-sage);
}
.edu-status.completed {
    background: rgba(200, 212, 226, 0.05);
    border: 1px solid rgba(200, 212, 226, 0.08);
    color: var(--text-muted);
}

/* ============================================================
   ACHIEVEMENTS — Bento Grid
   ============================================================ */
.achievements-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(330px, 1fr));
    gap: 18px;
}
.achievement-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: all var(--transition-base);
    backdrop-filter: blur(20px) saturate(1.2);
    -webkit-backdrop-filter: blur(20px) saturate(1.2);
}
.achievement-card:hover {
    border-color: var(--glass-border-hover);
    transform: translateY(-4px);
    box-shadow: var(--shadow-warm);
}
.achievement-image {
    width: 100%;
    height: 190px;
    object-fit: cover;
    border-bottom: 1px solid var(--glass-border);
    filter: saturate(0.8) brightness(0.9);
    transition: filter var(--transition-slow);
}
.achievement-card:hover .achievement-image {
    filter: saturate(1) brightness(1);
}
.achievement-content { padding: 22px; }
.achievement-content h3 {
    font-size: 1rem;
    color: var(--text-primary);
    margin-bottom: 6px;
}
.achievement-org {
    font-size: 0.8rem;
    color: var(--dawn-amber);
    margin-bottom: 8px;
    font-weight: 500;
    opacity: 0.8;
}
.achievement-date {
    font-size: 0.7rem;
    color: var(--text-muted);
    margin-bottom: 12px;
}
.achievement-description {
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.7;
    font-weight: 300;
}
.achievement-type-badge {
    display: inline-flex;
    padding: 4px 12px;
    border-radius: var(--radius-full);
    font-size: 0.66rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 12px;
}
.achievement-type-badge.certification {
    background: rgba(200, 212, 226, 0.04);
    border: 1px solid rgba(200, 212, 226, 0.08);
    color: var(--text-muted);
}
.achievement-type-badge.achievement {
    background: rgba(232, 168, 124, 0.04);
    border: 1px solid rgba(232, 168, 124, 0.08);
    color: var(--dawn-amber);
    opacity: 0.8;
}

.subcourse-list {
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px solid var(--glass-border);
}
.subcourse-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 5px 0;
    font-size: 0.8rem;
    color: var(--text-secondary);
    font-weight: 300;
}
.subcourse-item i { color: var(--forest-sage); font-size: 0.68rem; }

/* ============================================================
   RESEARCH
   ============================================================ */
.research-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(355px, 1fr));
    gap: 20px;
}
.research-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: all var(--transition-base);
    backdrop-filter: blur(20px) saturate(1.2);
    -webkit-backdrop-filter: blur(20px) saturate(1.2);
}
.research-card:hover {
    border-color: var(--glass-border-hover);
    transform: translateY(-4px);
    box-shadow: var(--shadow-glow);
}
.research-image {
    width: 100%;
    height: 190px;
    object-fit: cover;
    filter: saturate(0.8);
}
.research-card:hover .research-image { filter: saturate(1); }
.research-content { padding: 22px; }
.research-content h3 { font-size: 1rem; color: var(--text-primary); margin-bottom: 8px; }
.research-content p { font-size: 0.85rem; color: var(--text-secondary); line-height: 1.7; margin-bottom: 14px; font-weight: 300; }
.research-tags { display: flex; flex-wrap: wrap; gap: 5px; margin-bottom: 14px; }
.research-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 14px;
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-full);
    font-size: 0.78rem;
    color: var(--text-muted);
    text-decoration: none;
    transition: all var(--transition-fast);
}
.research-link:hover { border-color: var(--glass-border-hover); color: var(--text-secondary); }
.research-link.disabled { opacity: 0.25; pointer-events: none; }

/* ============================================================
   CONTACT
   ============================================================ */
.contact-grid {
    display: flex;
    justify-content: center;
    max-width: 650px;
    margin: 0 auto;
}
.contact-card-inner {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-xl);
    padding: 48px;
    backdrop-filter: blur(24px) saturate(1.3);
    -webkit-backdrop-filter: blur(24px) saturate(1.3);
    width: 100%;
    position: relative;
    overflow: hidden;
}
.contact-card-inner::after {
    content: '';
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: linear-gradient(165deg, rgba(255,248,240,0.012) 0%, transparent 50%);
    border-radius: inherit;
    pointer-events: none;
}
.contact-info { display: flex; flex-direction: column; gap: 22px; }
.contact-item { display: flex; align-items: center; gap: 16px; }
.contact-icon {
    width: 48px; height: 48px;
    border-radius: 50%;
    background: rgba(200, 212, 226, 0.03);
    border: 1px solid rgba(200, 212, 226, 0.06);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--moonlight);
    font-size: 1rem;
    flex-shrink: 0;
    transition: all var(--transition-base);
    opacity: 0.6;
}
.contact-item:hover .contact-icon {
    opacity: 1;
    background: rgba(200, 212, 226, 0.06);
    box-shadow: var(--shadow-glow);
    transform: scale(1.05);
}
.contact-item h4 { font-size: 0.88rem; color: var(--text-primary); margin-bottom: 3px; }
.contact-item p { font-size: 0.82rem; color: var(--text-secondary); font-weight: 300; }
.contact-social { display: flex; gap: 10px; margin-top: 8px; }
.contact-social a {
    width: 44px; height: 44px;
    border-radius: 50%;
    border: 1px solid var(--glass-border);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    text-decoration: none;
    transition: all var(--transition-base);
    background: var(--glass-bg);
    font-size: 0.88rem;
}
.contact-social a:hover {
    border-color: var(--glass-border-hover);
    color: var(--text-primary);
    transform: translateY(-3px);
    box-shadow: var(--shadow-glow);
}

/* ============================================================
   FOOTER
   ============================================================ */
.footer {
    background: rgba(12, 10, 9, 0.6);
    border-top: 1px solid var(--glass-border);
    padding: 50px 0 24px;
}
.footer-content {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr;
    gap: 48px;
    margin-bottom: 28px;
}
.footer-brand h3 {
    font-size: 1.15rem;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 8px;
}
.footer-brand p { font-size: 0.82rem; color: var(--text-muted); margin-bottom: 14px; font-style: italic; font-weight: 300; }
.footer-social { display: flex; gap: 8px; }
.footer-social a {
    width: 32px; height: 32px;
    border-radius: 50%;
    border: 1px solid var(--glass-border);
    display: flex; align-items: center; justify-content: center;
    color: var(--text-muted); text-decoration: none;
    transition: all var(--transition-fast); font-size: 0.8rem;
}
.footer-social a:hover { border-color: var(--glass-border-hover); color: var(--text-secondary); }
.footer-links h4 {
    font-size: 0.75rem; color: var(--text-muted); margin-bottom: 12px;
    text-transform: uppercase; letter-spacing: 2px; font-weight: 500;
}
.footer-links ul { list-style: none; display: flex; flex-direction: column; gap: 8px; }
.footer-links a { color: var(--text-muted); text-decoration: none; font-size: 0.82rem; transition: color var(--transition-fast); font-weight: 300; }
.footer-links a:hover { color: var(--text-secondary); }
.footer-bottom { text-align: center; padding-top: 18px; border-top: 1px solid var(--glass-border); color: var(--text-muted); font-size: 0.75rem; font-weight: 300; }

/* ============================================================
   BACK TO TOP
   ============================================================ */
.back-to-top {
    position: fixed;
    bottom: 28px; right: 28px;
    width: 42px; height: 42px;
    border-radius: 50%;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    color: var(--text-muted);
    cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    z-index: 900;
    opacity: 0; visibility: hidden;
    transform: translateY(20px);
    transition: all var(--transition-base);
    backdrop-filter: blur(16px);
    font-size: 0.85rem;
}
.back-to-top.show { opacity: 1; visibility: visible; transform: translateY(0); }
.back-to-top:hover {
    background: rgba(200, 212, 226, 0.04);
    border-color: var(--glass-border-hover);
    transform: translateY(-3px);
    color: var(--text-secondary);
}

/* ============================================================
   SCROLL-TRIGGERED ANIMATIONS
   ============================================================ */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s cubic-bezier(0.22, 1, 0.36, 1),
                transform 0.8s cubic-bezier(0.22, 1, 0.36, 1);
}
.reveal.visible { opacity: 1; transform: translateY(0); }

.reveal-left {
    opacity: 0;
    transform: translateX(-50px);
    transition: opacity 0.8s cubic-bezier(0.22, 1, 0.36, 1),
                transform 0.8s cubic-bezier(0.22, 1, 0.36, 1);
}
.reveal-left.visible { opacity: 1; transform: translateX(0); }

.reveal-right {
    opacity: 0;
    transform: translateX(50px);
    transition: opacity 0.8s cubic-bezier(0.22, 1, 0.36, 1),
                transform 0.8s cubic-bezier(0.22, 1, 0.36, 1);
}
.reveal-right.visible { opacity: 1; transform: translateX(0); }

.reveal-scale {
    opacity: 0;
    transform: scale(0.88);
    transition: opacity 0.8s cubic-bezier(0.22, 1, 0.36, 1),
                transform 0.8s cubic-bezier(0.22, 1, 0.36, 1);
}
.reveal-scale.visible { opacity: 1; transform: scale(1); }

/* Stagger children */
.stagger-children > * {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}
.stagger-children.visible > *:nth-child(1) { transition-delay: 0.05s; opacity: 1; transform: translateY(0); }
.stagger-children.visible > *:nth-child(2) { transition-delay: 0.1s; opacity: 1; transform: translateY(0); }
.stagger-children.visible > *:nth-child(3) { transition-delay: 0.15s; opacity: 1; transform: translateY(0); }
.stagger-children.visible > *:nth-child(4) { transition-delay: 0.2s; opacity: 1; transform: translateY(0); }
.stagger-children.visible > *:nth-child(5) { transition-delay: 0.25s; opacity: 1; transform: translateY(0); }
.stagger-children.visible > *:nth-child(6) { transition-delay: 0.3s; opacity: 1; transform: translateY(0); }
.stagger-children.visible > *:nth-child(7) { transition-delay: 0.35s; opacity: 1; transform: translateY(0); }
.stagger-children.visible > *:nth-child(8) { transition-delay: 0.4s; opacity: 1; transform: translateY(0); }

.fade-in {
    opacity: 0;
    transform: translateY(25px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}
.fade-in.visible { opacity: 1; transform: translateY(0); }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1024px) {
    .about-grid { grid-template-columns: 1fr; }
    .about-photo-wrapper { max-width: 260px; margin: 0 auto; }
    .footer-content { grid-template-columns: 1fr 1fr; gap: 28px; }
    .exp-card { flex: 0 0 290px; }
}

@media (max-width: 768px) {
    :root {
        --section-padding: 80px 0;
        --container-padding: 0 20px;
    }
    .nav-container { padding: 0 20px; }
    .hamburger { display: flex; }
    .nav-menu {
        position: fixed;
        left: -100%;
        top: 68px;
        flex-direction: column;
        background: rgba(12, 10, 9, 0.97);
        backdrop-filter: blur(24px);
        -webkit-backdrop-filter: blur(24px);
        width: 100%;
        padding: 16px 20px;
        gap: 2px;
        transition: left var(--transition-base);
        border-bottom: 1px solid var(--glass-border);
    }
    .nav-menu.active { left: 0; }
    .nav-link { padding: 14px 20px; font-size: 0.95rem; border-radius: var(--radius-sm); }
    .hero { padding: 100px 20px 60px; }
    .hero-stats { gap: 10px; }
    .hero-stat { padding: 14px 16px; min-width: 85px; }
    .hero-stat-value { font-size: 1.6rem; }
    .hero-buttons { flex-direction: column; align-items: center; }
    .projects-grid { grid-template-columns: 1fr; }
    .achievements-grid { grid-template-columns: 1fr; }
    .research-grid { grid-template-columns: 1fr; }
    .skills-grid { grid-template-columns: 1fr; }
    .footer-content { grid-template-columns: 1fr; gap: 24px; }
    .exp-card { flex: 0 0 270px; }
    .contact-card-inner { padding: 28px 22px; }
    .scroll-indicator { display: none; }
    .atmo-orb { filter: blur(60px); } /* lighter blur on mobile for perf */
}

@media (max-width: 480px) {
    h1 { font-size: 2.2rem; }
    h2 { font-size: 1.7rem; }
    .hero-stat-value { font-size: 1.3rem; }
    .hero-stats { gap: 8px; }
    .hero-stat-label { font-size: 0.6rem; }
    .hero-stat { min-width: 75px; padding: 10px 12px; }
}

/* ============================================================
   SCROLLBAR
   ============================================================ */
::-webkit-scrollbar { width: 5px; }
::-webkit-scrollbar-track { background: var(--bg-deep); }
::-webkit-scrollbar-thumb {
    background: rgba(200, 212, 226, 0.08);
    border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover { background: rgba(200, 212, 226, 0.15); }

/* ============================================================
   PDF GENERATOR LOADING OVERLAY
   ============================================================ */
#pdf-loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(12, 10, 9, 0.8);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity var(--transition-base);
}

#pdf-loading-overlay.active {
    opacity: 1;
    pointer-events: all;
}

.pdf-loader-content {
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    padding: 30px 45px;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 18px;
    max-width: 320px;
    width: 90%;
    text-align: center;
    transform: translateY(20px);
    transition: transform var(--transition-base);
}

#pdf-loading-overlay.active .pdf-loader-content {
    transform: translateY(0);
}

.pdf-spinner {
    width: 42px;
    height: 42px;
    border: 3.5px solid rgba(200, 212, 226, 0.1);
    border-top: 3.5px solid var(--moonlight);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.pdf-loader-content p {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-primary);
    letter-spacing: 0.02em;
    margin: 0;
}

/* spin keyframes defined above */


/* ============================================================
   REDUCED MOTION
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
    }
}
