/* ============================================
   JASWANT PORTFOLIO
   ============================================ */

/* CSS Variables */
:root {
    /* Colors */
    --bg-primary: #0a0a0f;
    --bg-secondary: #12121a;
    --bg-card: rgba(255, 255, 255, 0.055);
    --bg-card-hover: rgba(255, 255, 255, 0.10);
    --bg-glass: rgba(255, 255, 255, 0.07);
    
    --text-primary: #ffffff;
    --text-secondary: rgba(255, 255, 255, 0.7);
    --text-muted: rgba(255, 255, 255, 0.5);
    
    --accent-primary: #8b5cf6;
    --accent-secondary: #06b6d4;
    --accent-tertiary: #10b981;
    --accent-gradient: linear-gradient(135deg, #a855f7 0%, #6366f1 25%, #3b82f6 55%, #06b6d4 80%, #10b981 100%);
    --accent-glow: rgba(139, 92, 246, 0.4);
    
    --border-color: rgba(255, 255, 255, 0.1);
    --border-glow: rgba(139, 92, 246, 0.3);
    
    /* Spacing */
    --section-padding: 100px 0;
    --container-max: 1200px;
    
    /* Transitions — Fluent fluid easing */
    --transition-fast: 0.22s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    --transition-normal: 0.42s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    --transition-slow: 0.65s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    --transition-bounce: 0.55s cubic-bezier(0.34, 1.56, 0.64, 1);
    
    /* Border Radius */
    --radius-sm: 10px;
    --radius-md: 16px;
    --radius-lg: 24px;
    --radius-xl: 36px;
}

/* ============================================
   LIGHT MODE THEME
   ============================================ */
html[data-theme="light"] {
    --bg-primary: #f0f4ff;
    --bg-secondary: #e4eaff;
    --bg-card: rgba(255, 255, 255, 0.72);
    --bg-card-hover: rgba(255, 255, 255, 0.95);
    --bg-glass: rgba(255, 255, 255, 0.6);
    --text-primary: #0f0f1a;
    --text-secondary: rgba(15, 15, 26, 0.75);
    --text-muted: rgba(15, 15, 26, 0.5);
    --border-color: rgba(0, 0, 0, 0.09);
    --border-glow: rgba(139, 92, 246, 0.25);
    --accent-glow: rgba(139, 92, 246, 0.15);
}

html[data-theme="light"] body { background: linear-gradient(160deg, #f5f7ff 0%, #eef1ff 40%, #f2eeff 100%); color: var(--text-primary); }
html[data-theme="light"] .animated-bg { background: linear-gradient(160deg, #f5f7ff 0%, #eef1ff 40%, #f2eeff 100%); }
html[data-theme="light"] .gradient-orb { opacity: 0.16; }
html[data-theme="light"] .animated-bg::before { opacity: 0.82; }
html[data-theme="light"] .animated-bg::after { opacity: 0.72; }
html[data-theme="light"] .noise-overlay { opacity: 0.01; }
html[data-theme="light"] .vignette { background: radial-gradient(ellipse at center, transparent 50%, rgba(170, 180, 215, 0.2) 100%); }
html[data-theme="light"] .hex-grid { opacity: 0.2; filter: invert(0.9) hue-rotate(20deg); }
html[data-theme="light"] .data-stream { background: linear-gradient(to bottom, transparent, rgba(139, 92, 246, 0.18), transparent); }
html[data-theme="light"] .code-frag { color: rgba(139, 92, 246, 0.3); }
html[data-theme="light"] .particle { background: rgba(139, 92, 246, 0.22); }
html[data-theme="light"] .neural-node { opacity: 0.22; }
html[data-theme="light"] .navbar.scrolled { background: rgba(240, 242, 248, 0.94); border-bottom-color: rgba(139, 92, 246, 0.15); }
html[data-theme="light"] .theme-toggle {
    background: rgba(139, 92, 246, 0.08);
    border-color: rgba(139, 92, 246, 0.18);
    color: var(--accent-primary);
}
html[data-theme="light"] .nav-links a { color: var(--text-secondary); }
html[data-theme="light"] .nav-links a:hover { color: var(--accent-primary) !important; background: rgba(139, 92, 246, 0.08) !important; }
html[data-theme="light"] .nav-links a:focus { outline: none; background: rgba(139, 92, 246, 0.08); }
html[data-theme="light"] .btn-secondary { border-color: rgba(139, 92, 246, 0.4); color: var(--text-primary); }
html[data-theme="light"] .btn-secondary:hover { background: rgba(139, 92, 246, 0.1); color: var(--text-primary); }
html[data-theme="light"] .section-label { background: rgba(139, 92, 246, 0.1); border-color: rgba(139, 92, 246, 0.2); color: var(--accent-primary); }
html[data-theme="light"] .cert-card,
html[data-theme="light"] .skill-card,
html[data-theme="light"] .project-card,
html[data-theme="light"] .timeline-content,
html[data-theme="light"] .achievement-card {
    background: rgba(255, 255, 255, 0.78);
    backdrop-filter: blur(20px) saturate(200%);
    -webkit-backdrop-filter: blur(20px) saturate(200%);
    border-color: rgba(255, 255, 255, 0.90);
    box-shadow: 0 8px 32px rgba(100, 116, 200, 0.10), 0 2px 8px rgba(0, 0, 0, 0.06), inset 0 1px 0 rgba(255, 255, 255, 1);
}
html[data-theme="light"] .cert-card:hover,
html[data-theme="light"] .skill-card:hover,
html[data-theme="light"] .project-card:hover,
html[data-theme="light"] .achievement-card:hover {
    background: rgba(255, 255, 255, 0.96);
    border-color: rgba(139, 92, 246, 0.20);
    box-shadow: 0 20px 56px rgba(100, 116, 200, 0.16), 0 6px 16px rgba(0, 0, 0, 0.08), inset 0 1px 0 rgba(255, 255, 255, 1);
}
html[data-theme="light"] .contact-card {
    background: rgba(255, 255, 255, 0.65);
    backdrop-filter: blur(16px) saturate(180%);
    -webkit-backdrop-filter: blur(16px) saturate(180%);
    border-color: rgba(255, 255, 255, 0.75);
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06), inset 0 1px 0 rgba(255, 255, 255, 0.9);
    color: var(--text-primary);
}
html[data-theme="light"] .contact-card:hover {
    background: rgba(255, 255, 255, 0.92);
    border-color: rgba(139, 92, 246, 0.25);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.1), inset 0 1px 0 rgba(255, 255, 255, 1);
}
html[data-theme="light"] .contact-card-content h4 { color: #0f0f1a; }
html[data-theme="light"] .contact-card-content p { color: rgba(15, 15, 26, 0.55); }
html[data-theme="light"] .contact-arrow { color: rgba(15, 15, 26, 0.4); }
html[data-theme="light"] .social-link-card {
    background: rgba(255, 255, 255, 0.65);
    backdrop-filter: blur(16px) saturate(180%);
    -webkit-backdrop-filter: blur(16px) saturate(180%);
    border-color: rgba(255, 255, 255, 0.75);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.05), inset 0 1px 0 rgba(255, 255, 255, 0.9);
    color: var(--text-primary);
}
html[data-theme="light"] .social-link-card:hover { 
    background: var(--accent-gradient); 
    border-color: transparent;
    box-shadow: 0 12px 30px var(--accent-glow);
}
html[data-theme="light"] .skill-tag { background: rgba(139, 92, 246, 0.1); color: var(--accent-primary); border-color: rgba(139, 92, 246, 0.2); }
html[data-theme="light"] .stat-item {
    background: rgba(255, 255, 255, 0.65);
    backdrop-filter: blur(16px) saturate(180%);
    -webkit-backdrop-filter: blur(16px) saturate(180%);
    border-color: rgba(255, 255, 255, 0.75);
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06), inset 0 1px 0 rgba(255, 255, 255, 0.9);
}
html[data-theme="light"] .floating-badge {
    background: rgba(255, 255, 255, 0.75);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-color: rgba(255, 255, 255, 0.8);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
    color: var(--accent-primary);
}
html[data-theme="light"] .footer { background: rgba(228, 232, 245, 0.95); border-top-color: rgba(139, 92, 246, 0.15); }
html[data-theme="light"] .footer p, html[data-theme="light"] .footer-brand { color: var(--text-secondary); }
html[data-theme="light"] .project-category { color: var(--accent-primary); }
html[data-theme="light"] .project-tech span { color: var(--text-secondary); }
html[data-theme="light"] .timeline-year { color: var(--accent-secondary); }
html[data-theme="light"] .grade { color: var(--accent-secondary); }
html[data-theme="light"] ::-webkit-scrollbar-track { background: var(--bg-secondary); }

/* ============================================
   THEME TOGGLE BUTTON
   ============================================ */
.theme-toggle {
    background: var(--bg-glass);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    width: 38px;
    height: 38px;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    cursor: pointer;
    transition: var(--transition-normal);
    flex-shrink: 0;
    backdrop-filter: blur(10px);
}

.theme-toggle:hover {
    background: var(--accent-gradient);
    border-color: transparent;
    color: white;
    transform: rotate(20deg) scale(1.05);
}

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

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
    font-size: 16px;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: 'Segoe UI Variable', 'Segoe UI', -apple-system, BlinkMacSystemFont, system-ui, 'Helvetica Neue', Arial, sans-serif;
    font-weight: 400;
    font-style: normal;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-secondary);
}

::-webkit-scrollbar-thumb {
    background: var(--accent-primary);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--accent-secondary);
}

/* Selection */
::selection {
    background: var(--accent-primary);
    color: white;
}

/* Links */
a {
    color: var(--accent-secondary);
    text-decoration: none;
    transition: var(--transition-fast);
}

a:hover {
    color: var(--accent-primary);
}

/* Container */
.container {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 24px;
}

/* ============================================
   ANIMATED BACKGROUND
   ============================================ */
.animated-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
    background: var(--bg-primary);
}

/* ═══ COPILOT-STYLE MASSIVE FLUID BLOBS ═══
   Right-side blob: violet → coral → salmon  (matches Copilot screenshot right wash)
   Left-side blob:  periwinkle → lavender     (matches Copilot screenshot left wash) */
.animated-bg::before {
    content: '';
    position: absolute;
    width: 920px;
    height: 920px;
    background: radial-gradient(ellipse at 40% 38%,
        rgba(139, 92, 246, 0.52) 0%,
        rgba(109, 40, 217, 0.28) 45%,
        transparent 100%
    );
    border-radius: 62% 38% 54% 46% / 48% 56% 44% 52%;
    top: -290px;
    right: -290px;
    animation: blobMorph1 22s ease-in-out infinite;
    filter: blur(58px);
    pointer-events: none;
}

.animated-bg::after {
    content: '';
    position: absolute;
    width: 800px;
    height: 800px;
    background: radial-gradient(ellipse at 40% 42%,
        rgba(139, 92, 246, 0.40) 0%,
        rgba(109, 40, 217, 0.20) 48%,
        transparent 100%
    );
    border-radius: 38% 62% 46% 54% / 55% 45% 60% 40%;
    bottom: -260px;
    left: -230px;
    animation: blobMorph2 26s ease-in-out infinite;
    filter: blur(52px);
    pointer-events: none;
}

@keyframes blobMorph1 {
    0%, 100% {
        border-radius: 62% 38% 54% 46% / 48% 56% 44% 52%;
        transform: translate(0, 0) scale(1);
    }
    33% {
        border-radius: 48% 52% 62% 38% / 58% 42% 54% 46%;
        transform: translate(-26px, 38px) scale(1.04);
    }
    66% {
        border-radius: 72% 28% 46% 54% / 40% 60% 46% 54%;
        transform: translate(16px, -30px) scale(0.97);
    }
}

@keyframes blobMorph2 {
    0%, 100% {
        border-radius: 38% 62% 46% 54% / 55% 45% 60% 40%;
        transform: translate(0, 0) scale(1);
    }
    38% {
        border-radius: 56% 44% 38% 62% / 44% 56% 48% 52%;
        transform: translate(36px, -42px) scale(1.05);
    }
    70% {
        border-radius: 44% 56% 60% 40% / 62% 38% 52% 48%;
        transform: translate(-20px, 26px) scale(0.96);
    }
}

html[data-theme="light"] .animated-bg::before { opacity: 0.80; }
html[data-theme="light"] .animated-bg::after { opacity: 0.68; }

.gradient-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(72px);
    opacity: 0.5;
    transition: transform 0.8s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    will-change: transform, border-radius;
    animation: orbBreathe 14s ease-in-out infinite;
}

@keyframes orbBreathe {
    0%, 100% {
        opacity: 0.26;
        filter: blur(80px);
        border-radius: 50%;
    }
    25% {
        opacity: 0.36;
        filter: blur(72px);
        border-radius: 58% 42% 62% 38% / 46% 54% 46% 54%;
    }
    50% {
        opacity: 0.30;
        filter: blur(88px);
        border-radius: 42% 58% 38% 62% / 55% 45% 60% 40%;
    }
    75% {
        opacity: 0.38;
        filter: blur(76px);
        border-radius: 62% 38% 52% 48% / 40% 60% 42% 58%;
    }
}

/* Single-color orbs — all purple */
.orb-1 {
    width: 620px;
    height: 620px;
    background: radial-gradient(circle at 38% 36%, rgba(139, 92, 246, 0.68) 0%, rgba(109, 40, 217, 0.28) 45%, transparent 72%);
    top: -200px;
    right: -130px;
    animation-delay: 0s;
}

.orb-2 {
    width: 520px;
    height: 520px;
    background: radial-gradient(circle at 40% 40%, rgba(139, 92, 246, 0.50) 0%, rgba(109, 40, 217, 0.22) 45%, transparent 72%);
    bottom: -160px;
    left: -110px;
    animation-delay: 4s;
}

.orb-3 {
    width: 440px;
    height: 440px;
    background: radial-gradient(circle at 42% 38%, rgba(139, 92, 246, 0.42) 0%, rgba(109, 40, 217, 0.18) 45%, transparent 72%);
    top: 45%;
    left: 46%;
    animation-delay: 8s;
}

@keyframes float {
    0%, 100% { transform: translate(0, 0) scale(1); }
    25% { transform: translate(28px, -28px) scale(1.04); }
    50% { transform: translate(-18px, 18px) scale(0.96); }
    75% { transform: translate(-26px, -18px) scale(1.02); }
}



/* ============================================
   AI/ML NEURAL NETWORK ANIMATION
   ============================================ */

/* Neural Network Container */
.neural-network {
    position: absolute;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

/* Neural Nodes - Mouse Reactive */
.neural-node {
    position: absolute;
    border-radius: 50%;
    background: radial-gradient(circle, var(--accent-primary) 0%, transparent 70%);
    transition: transform 0.4s ease-out, opacity 0.3s, box-shadow 0.3s;
    will-change: transform;
    opacity: 0.4;
}

.neural-node::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 25%;
    height: 25%;
    background: rgba(255, 255, 255, 0.45);
    border-radius: 50%;
    box-shadow: 0 0 8px rgba(139, 92, 246, 0.5);
    transition: box-shadow 0.3s;
}

.neural-node.active {
    opacity: 0.9;
}

.neural-node.active::before {
    box-shadow: 0 0 30px rgba(139, 92, 246, 1), 0 0 60px rgba(139, 92, 246, 0.5);
}

/* Node Sizes and Positions — all single accent-primary color */
.neural-node:nth-child(1) { width: 80px; height: 80px; top: 15%; left: 10%; }
.neural-node:nth-child(2) { width: 60px; height: 60px; top: 25%; left: 85%; }
.neural-node:nth-child(3) { width: 100px; height: 100px; top: 60%; left: 5%; }
.neural-node:nth-child(4) { width: 50px; height: 50px; top: 70%; left: 90%; }
.neural-node:nth-child(5) { width: 70px; height: 70px; top: 85%; left: 45%; }
.neural-node:nth-child(6) { width: 55px; height: 55px; top: 40%; left: 75%; }

/* Floating Code Elements */
.code-elements {
    position: absolute;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.code-symbol {
    position: absolute;
    font-family: 'JetBrains Mono', monospace;
    font-size: 1.8rem;
    color: rgba(139, 92, 246, 0.12);
    animation: code-float 25s linear infinite;
    user-select: none;
}

.code-symbol.accent-2 { color: rgba(6, 182, 212, 0.12); }
.code-symbol.accent-3 { color: rgba(16, 185, 129, 0.12); }

@keyframes code-float {
    0% { transform: translateY(100vh) rotate(0deg); opacity: 0; }
    5% { opacity: 1; }
    95% { opacity: 1; }
    100% { transform: translateY(-100vh) rotate(360deg); opacity: 0; }
}

/* Code Symbol Positions (Simplified - 6 elements) */
.code-symbol:nth-child(1) { left: 8%; animation-delay: 0s; font-size: 2rem; }
.code-symbol:nth-child(2) { left: 25%; animation-delay: 4s; font-size: 1.6rem; }
.code-symbol:nth-child(3) { left: 42%; animation-delay: 8s; font-size: 1.4rem; }
.code-symbol:nth-child(4) { left: 60%; animation-delay: 12s; font-size: 1.8rem; }
.code-symbol:nth-child(5) { left: 78%; animation-delay: 16s; font-size: 2.2rem; }
.code-symbol:nth-child(6) { left: 92%; animation-delay: 20s; font-size: 1.5rem; }

/* ============================================
   CUSTOM CURSOR
   ============================================ */
*, *::before, *::after {
    cursor: none !important;
}

.cursor-glow {
    position: fixed;
    top: 0;
    left: 0;
    width: 28px;
    height: 28px;
    pointer-events: none;
    z-index: 99999;
    opacity: 0;
    will-change: transform;
    /* SVG arrow cursor — dark mode: white fill, straight edges, rounded corners only */
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='28' height='28' viewBox='0 0 28 28'%3E%3Cpath d='M4 2 L4 21.5 Q4 24 6.5 22.5 L9 19.5 Q10.5 18.5 13 18.5 L21.5 18.5 Q24 18.5 22.5 17 Z' fill='%23222222' stroke='%23222222' stroke-width='3.5' stroke-linejoin='round' stroke-linecap='round'/%3E%3Cpath d='M4 2 L4 21.5 Q4 24 6.5 22.5 L9 19.5 Q10.5 18.5 13 18.5 L21.5 18.5 Q24 18.5 22.5 17 Z' fill='%23f0f0f0'/%3E%3C/svg%3E");
    background-size: contain;
    background-repeat: no-repeat;
    filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.55));
    transition: opacity 0.15s ease, transform 0s;
}

.cursor-glow.active {
    opacity: 1;
}

.cursor-glow.clicking {
    filter: drop-shadow(0 3px 12px rgba(139, 92, 246, 0.55)) drop-shadow(0 2px 5px rgba(0, 0, 0, 0.45));
}

html[data-theme="light"] .cursor-glow {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='28' height='28' viewBox='0 0 28 28'%3E%3Cpath d='M4 2 L4 21.5 Q4 24 6.5 22.5 L9 19.5 Q10.5 18.5 13 18.5 L21.5 18.5 Q24 18.5 22.5 17 Z' fill='white' stroke='white' stroke-width='3.5' stroke-linejoin='round' stroke-linecap='round'/%3E%3Cpath d='M4 2 L4 21.5 Q4 24 6.5 22.5 L9 19.5 Q10.5 18.5 13 18.5 L21.5 18.5 Q24 18.5 22.5 17 Z' fill='%230f0f0f'/%3E%3C/svg%3E");
    filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.30));
}

/* ============================================
   RIPPLE EFFECT ON CLICK
   ============================================ */
.ripple-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.ripple {
    position: absolute;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(139, 92, 246, 0.3) 0%, transparent 70%);
    transform: translate(-50%, -50%) scale(0);
    animation: ripple-expand 1s ease-out forwards;
    pointer-events: none;
}

@keyframes ripple-expand {
    0% { transform: translate(-50%, -50%) scale(0); opacity: 1; }
    100% { transform: translate(-50%, -50%) scale(4); opacity: 0; }
}

/* ============================================
   NOISE GRAIN OVERLAY
   ============================================ */
.noise-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0.03;
    pointer-events: none;
    z-index: 10;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
}

/* ============================================
   VIGNETTE EFFECT
   ============================================ */
.vignette {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 11;
    background: radial-gradient(ellipse at center, transparent 40%, rgba(0, 0, 0, 0.4) 100%);
}

/* ============================================
   HEXAGON GRID PATTERN
   ============================================ */
.hex-grid {
    position: absolute;
    width: 100%;
    height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='28' height='49' viewBox='0 0 28 49'%3E%3Cg fill-rule='evenodd'%3E%3Cg fill='%230891b2' fill-opacity='0.03'%3E%3Cpath d='M13.99 9.25l13 7.5v15l-13 7.5L1 31.75v-15l12.99-7.5zM3 17.9v12.7l10.99 6.34 11-6.35V17.9l-11-6.34L3 17.9zM0 15l12.98-7.5V0h-2v6.35L0 12.69v2.3zm0 18.5L12.98 41v8h-2v-6.85L0 35.81v-2.3zM15 0v7.5L27.99 15H28v-2.31h-.01L17 6.35V0h-2zm0 49v-8l12.99-7.5H28v2.31h-.01L17 42.15V49h-2z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    opacity: 0.5;
    animation: hexPulse 4s ease-in-out infinite;
}

@keyframes hexPulse {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 0.5; }
}

/* ============================================
   DATA STREAMS
   ============================================ */
.data-streams {
    position: absolute;
    width: 100%;
    height: 100%;
    overflow: hidden;
    pointer-events: none;
}

.data-stream {
    position: absolute;
    width: 1px;
    height: 100px;
    background: linear-gradient(180deg, transparent, rgba(139, 92, 246, 0.4), transparent);
    animation: dataFlow 6s linear infinite;
    opacity: 0;
}

.data-stream:nth-child(1) { animation-delay: 0s; }
.data-stream:nth-child(2) { animation-delay: 1.2s; }
.data-stream:nth-child(3) { animation-delay: 2.4s; }
.data-stream:nth-child(4) { animation-delay: 3.6s; }
.data-stream:nth-child(5) { animation-delay: 4.8s; }

@keyframes dataFlow {
    0% { top: -100px; opacity: 0; }
    10% { opacity: 0.6; }
    90% { opacity: 0.6; }
    100% { top: 100%; opacity: 0; }
}

/* ============================================
   CODE FRAGMENTS
   ============================================ */
.code-fragments {
    position: absolute;
    width: 100%;
    height: 100%;
    pointer-events: none;
    overflow: hidden;
}

.code-frag {
    position: absolute;
    font-family: 'Fira Code', 'Consolas', monospace;
    font-size: 14px;
    color: rgba(6, 182, 212, 0.15);
    animation: floatCode 20s linear infinite;
}

.code-frag:nth-child(1) { left: 5%; animation-delay: 0s; }
.code-frag:nth-child(2) { left: 20%; animation-delay: 4s; }
.code-frag:nth-child(3) { left: 40%; animation-delay: 8s; }
.code-frag:nth-child(4) { left: 60%; animation-delay: 12s; }
.code-frag:nth-child(5) { left: 85%; animation-delay: 16s; }

@keyframes floatCode {
    0% { top: 100%; opacity: 0; transform: translateX(0) rotate(0deg); }
    10% { opacity: 0.3; }
    90% { opacity: 0.3; }
    100% { top: -50px; opacity: 0; transform: translateX(30px) rotate(15deg); }
}

/* ============================================
   INTERACTIVE PARTICLES (ANIMATED)
   ============================================ */
.interactive-particles {
    position: absolute;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.interactive-particles .particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: rgba(139, 92, 246, 0.6);
    border-radius: 50%;
    box-shadow: 0 0 10px rgba(139, 92, 246, 0.4);
    transition: box-shadow 0.3s;
    will-change: transform;
    animation: particleDrift 25s ease-in-out infinite;
}

.interactive-particles .particle:nth-child(2n) {
    animation: particleDrift2 30s ease-in-out infinite;
}

.interactive-particles .particle:nth-child(3n) {
    animation: particleDrift3 20s ease-in-out infinite;
}

.interactive-particles .particle:nth-child(5n) {
    width: 6px;
    height: 6px;
}

.interactive-particles .particle:nth-child(7n) {
    width: 3px;
    height: 3px;
    animation-duration: 35s;
}

@keyframes particleDrift {
    0%, 100% { transform: translate(0, 0); }
    25% { transform: translate(30px, -20px); }
    50% { transform: translate(-20px, 30px); }
    75% { transform: translate(25px, 15px); }
}

@keyframes particleDrift2 {
    0%, 100% { transform: translate(0, 0); }
    33% { transform: translate(-40px, 25px); }
    66% { transform: translate(35px, -30px); }
}

@keyframes particleDrift3 {
    0%, 100% { transform: translate(0, 0); }
    20% { transform: translate(20px, 40px); }
    40% { transform: translate(-30px, 20px); }
    60% { transform: translate(-20px, -35px); }
    80% { transform: translate(35px, -15px); }
}

.interactive-particles .particle.near-cursor {
    box-shadow: 0 0 20px rgba(139, 92, 246, 0.8), 0 0 40px rgba(139, 92, 246, 0.4);
    animation-play-state: paused;
}

/* ============================================
   CONNECTION LINES SVG
   ============================================ */
.connection-lines {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 2;
}

.connection-lines line {
    stroke: url(#lineGradient);
    stroke-width: 1;
    fill: none;
}

.connection-lines .static-line {
    stroke: rgba(0, 133, 222, 0.15);
    stroke-width: 0.5;
}

.connection-lines .dynamic-line {
    stroke: url(#lineGradient);
    stroke-width: 1.5;
    transition: opacity 0.15s ease;
}

.connection-lines .cursor-line {
    stroke: rgba(112, 92, 255, 0.6);
    stroke-width: 2;
}

.connection-lines .network-line {
    stroke: rgba(0, 133, 222, 0.5);
}

.connection-lines line.pulse {
    animation: linePulse 0.5s ease-out;
}

@keyframes linePulse {
    0% { stroke-width: 2; opacity: 0.8; }
    50% { stroke-width: 4; opacity: 1; }
    100% { stroke-width: 2; opacity: 0.3; }
}

/* ============================================
   ANIMATIONS
   ============================================ */
.fade-in-up {
    opacity: 0;
    transform: translateY(36px);
    animation: fadeInUp 0.9s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.fade-in-left {
    opacity: 0;
    transform: translateX(-36px);
    animation: fadeInLeft 0.9s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.fade-in-right {
    opacity: 0;
    transform: translateX(36px);
    animation: fadeInRight 0.9s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

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

@keyframes fadeInLeft {
    to { opacity: 1; transform: translateX(0); }
}

@keyframes fadeInRight {
    to { opacity: 1; transform: translateX(0); }
}

/* ============================================
   NAVIGATION
   ============================================ */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 20px 0;
    background: transparent;
    transition: var(--transition-normal);
}

.navbar.scrolled {
    background: rgba(10, 10, 15, 0.9);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-color);
    padding: 15px 0;
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1.5rem;
    font-weight: 700;
}

.nav-brand .brand-icon {
    width: 40px;
    height: 40px;
    background: var(--accent-gradient);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.2rem;
}

.nav-brand .brand-text {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-links {
    display: flex;
    gap: 10px;
    list-style: none;
}

.nav-links a {
    color: var(--text-secondary);
    font-weight: 500;
    font-size: 0.9rem;
    padding: 10px 16px;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    gap: 6px;
    transition: var(--transition-normal);
}

.nav-links a i { font-size: 1rem; }

.nav-links a:hover {
    color: var(--text-primary);
    background: var(--bg-glass);
}

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    padding: 10px;
    z-index: 1001;
}

.nav-toggle span {
    width: 25px;
    height: 2px;
    background: var(--text-primary);
    transition: var(--transition-normal);
}

/* ============================================
   HERO SECTION
   ============================================ */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 120px 24px 80px;
    position: relative;
}

.hero-content {
    max-width: 900px;
    z-index: 1;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 10px 24px;
    background: var(--bg-glass);
    border: 1px solid var(--border-color);
    border-radius: 50px;
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 30px;
    backdrop-filter: blur(10px);
    animation: pulse-border 2s ease-in-out infinite;
}

@keyframes pulse-border {
    0%, 100% { border-color: var(--border-color); }
    50% { border-color: var(--accent-primary); }
}

.pulse-dot {
    width: 10px;
    height: 10px;
    background: #10b981;
    border-radius: 50%;
    animation: pulse 2s ease-in-out infinite;
    box-shadow: 0 0 10px #10b981;
}

@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); box-shadow: 0 0 10px #10b981; }
    50% { opacity: 0.5; transform: scale(1.2); box-shadow: 0 0 20px #10b981; }
}

.hero-title {
    font-size: clamp(2.5rem, 8vw, 4.5rem);
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 24px;
    letter-spacing: -0.02em;
}

.hero-title .line-1,
.hero-title .line-3 {
    display: block;
    font-size: 0.5em;
    color: var(--text-secondary);
    font-weight: 400;
}

.hero-title .gradient-text {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradient-shift 3s ease infinite;
    background-size: 200% 200%;
}

@keyframes gradient-shift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

.hero-roles {
    font-size: clamp(1.5rem, 3vw, 2rem);
    color: var(--accent-primary);
    margin-bottom: 20px;
    font-weight: 500;
    min-height: 2.5rem;
}

.role-text {
    color: var(--accent-secondary);
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.typing-cursor {
    color: var(--accent-primary);
    animation: blink 0.8s infinite;
    font-weight: 300;
}

@keyframes blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0; }
}

.hero-subtitle {
    font-size: clamp(1.1rem, 2.5vw, 1.3rem);
    color: var(--text-secondary);
    margin-bottom: 40px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.7;
}

.hero-cta {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 40px;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 16px 32px;
    border-radius: var(--radius-md);
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: var(--transition-normal);
    border: none;
    text-decoration: none;
}

.btn i { font-size: 1.2rem; }

.btn-primary {
    background: var(--accent-gradient);
    color: white;
    box-shadow: 0 4px 20px var(--accent-glow);
    position: relative;
    overflow: hidden;
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: 0.5s;
}

.btn-primary:hover::before { left: 100%; }

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 30px var(--accent-glow);
    color: white;
}

.btn-secondary {
    background: var(--bg-glass);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
    backdrop-filter: blur(10px);
}

.btn-secondary:hover {
    background: var(--bg-card-hover);
    border-color: var(--accent-primary);
    color: var(--text-primary);
    transform: translateY(-3px);
}

/* Hero Social */
.hero-social {
    display: flex;
    justify-content: center;
    gap: 16px;
}

.social-icon {
    width: 50px;
    height: 50px;
    background: var(--bg-glass);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    color: var(--text-secondary);
    transition: var(--transition-bounce);
}

.social-icon:hover {
    background: var(--accent-primary);
    border-color: var(--accent-primary);
    color: white;
    transform: translateY(-5px) scale(1.1);
    box-shadow: 0 10px 30px var(--accent-glow);
}

/* Scroll Indicator */
.scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    color: var(--text-muted);
    font-size: 0.8rem;
    animation: bounce 2s ease-in-out infinite;
}

.scroll-indicator i {
    font-size: 1.5rem;
    animation: scroll-bounce 1.5s ease-in-out infinite;
}

@keyframes scroll-bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(10px); }
}

@keyframes bounce {
    0%, 100% { transform: translateX(-50%) translateY(0); }
    50% { transform: translateX(-50%) translateY(10px); }
}

/* ============================================
   SECTIONS COMMON
   ============================================ */
.section {
    padding: var(--section-padding);
    position: relative;
    scroll-margin-top: 80px;
}

.section-header {
    text-align: center;
    margin-bottom: 60px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.section-label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--accent-primary);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 16px;
    padding: 8px 16px;
    background: rgba(139, 92, 246, 0.1);
    border-radius: 50px;
}

.section-label i { font-size: 1rem; }

.section-title {
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 700;
    margin-bottom: 16px;
    position: relative;
    display: inline-block;
    text-align: center;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 120px;
    height: 3px;
    background: var(--accent-gradient);
    background-size: 200% 100%;
    border-radius: 4px;
    animation: glowLine 3s ease-in-out infinite, gradientSlide 4s linear infinite;
}

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

@keyframes glowLine {
    0%, 100% { box-shadow: 0 0 5px var(--accent-primary), 0 0 10px var(--accent-primary); opacity: 0.8; }
    50% { box-shadow: 0 0 15px var(--accent-primary), 0 0 25px var(--accent-secondary); opacity: 1; }
}

.section-subtitle {
    color: var(--text-secondary);
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto;
}

/* ============================================
   ABOUT SECTION
   ============================================ */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.about-image { position: relative; }

.about-image-wrapper {
    position: relative;
    border-radius: var(--radius-lg);
    overflow: hidden;
    aspect-ratio: 1;
    background: var(--bg-glass);
    border: 2px solid var(--border-color);
    transition: var(--transition-normal);
}

.about-image-wrapper:hover { border-color: var(--accent-primary); }

.profile-photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition-slow);
}

.about-image-wrapper:hover .profile-photo { transform: scale(1.05); }

.image-glow {
    position: absolute;
    inset: 0;
    background: var(--accent-gradient);
    opacity: 0;
    transition: var(--transition-normal);
    pointer-events: none;
}

.about-image-wrapper:hover .image-glow { opacity: 0.1; }

/* Floating Badges */
.floating-badges {
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.floating-badge {
    position: absolute;
    width: 50px;
    height: 50px;
    background: var(--accent-gradient);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.3rem;
    box-shadow: 0 10px 30px var(--accent-glow);
    animation: float-badge 4s ease-in-out infinite;
}

/* Distinct colors per floating badge */
.badge-1 { top: 10%; right: -10%; animation-delay: 0s;  background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%); box-shadow: 0 10px 30px rgba(59,130,246,0.4); }
.badge-2 { bottom: 20%; left: -10%; animation-delay: 1s; background: linear-gradient(135deg, #10b981 0%, #059669 100%); box-shadow: 0 10px 30px rgba(16,185,129,0.4); }
.badge-3 { bottom: 10%; right: 10%; animation-delay: 2s; background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%); box-shadow: 0 10px 30px rgba(245,158,11,0.4); }

@keyframes float-badge {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-10px) rotate(5deg); }
}

.about-content h3 {
    font-size: 2rem;
    margin-bottom: 20px;
}

.about-content p {
    color: var(--text-secondary);
    margin-bottom: 20px;
    line-height: 1.8;
}

.about-content em {
    color: var(--accent-secondary);
    font-style: italic;
}

.about-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-top: 30px;
}

.stat-item {
    text-align: center;
    padding: 24px;
    background: var(--bg-glass);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    transition: var(--transition-normal);
}

.stat-item:hover {
    border-color: var(--accent-primary);
    transform: translateY(-5px);
}

.stat-icon {
    font-size: 1.5rem;
    color: var(--accent-primary);
    margin-bottom: 10px;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    display: inline-block;
}

.stat-number.animate {
    animation: countPulse 0.5s ease-out;
}

@keyframes countPulse {
    0% { transform: scale(0.5); opacity: 0; }
    50% { transform: scale(1.2); }
    100% { transform: scale(1); opacity: 1; }
}

.stat-label {
    font-size: 0.875rem;
    color: var(--text-muted);
    margin-top: 5px;
}

/* ============================================
   SKILLS SECTION
   ============================================ */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
}

.skill-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 30px;
    transition: var(--transition-normal);
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.12), 0 1px 4px rgba(0, 0, 0, 0.08);
}

.skill-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--accent-gradient);
    transform: scaleX(0);
    transition: var(--transition-normal);
}

.skill-card:hover {
    background: var(--bg-card-hover);
    border-color: var(--border-glow);
    transform: translateY(-8px);
    box-shadow: 0 24px 48px rgba(139, 92, 246, 0.18), 0 8px 16px rgba(0, 0, 0, 0.12);
}

.skill-card:hover::before { transform: scaleX(1); }

.skill-icon-wrapper {
    width: 60px;
    height: 60px;
    background: var(--accent-gradient);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    color: white;
    margin-bottom: 20px;
    transition: var(--transition-normal);
}

/* Per-card skill icon colors */
.skill-card:nth-child(1) .skill-icon-wrapper { background: linear-gradient(135deg, #8b5cf6 0%, #6d28d9 100%); }
.skill-card:nth-child(2) .skill-icon-wrapper { background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%); }
.skill-card:nth-child(3) .skill-icon-wrapper { background: linear-gradient(135deg, #06b6d4 0%, #0284c7 100%); }
.skill-card:nth-child(4) .skill-icon-wrapper { background: linear-gradient(135deg, #10b981 0%, #059669 100%); }
.skill-card:nth-child(5) .skill-icon-wrapper { background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%); }
.skill-card:nth-child(6) .skill-icon-wrapper { background: linear-gradient(135deg, #ec4899 0%, #be185d 100%); }

.skill-card:hover .skill-icon-wrapper {
    transform: scale(1.1) rotate(5deg);
}

.skill-card h4 {
    font-size: 1.25rem;
    margin-bottom: 12px;
}

.skill-card p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    margin-bottom: 20px;
}

.skill-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.skill-tag {
    padding: 6px 14px;
    background: var(--bg-glass);
    border-radius: 20px;
    font-size: 0.8rem;
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
    transition: var(--transition-fast);
}

.skill-card:hover .skill-tag {
    border-color: var(--accent-primary);
    color: var(--accent-secondary);
}

/* ============================================
   PROJECTS SECTION
   ============================================ */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px;
}

.project-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: var(--transition-normal);
    display: flex;
    flex-direction: column;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.15), 0 1px 4px rgba(0, 0, 0, 0.08);
}

.project-card:hover {
    border-color: var(--border-glow);
    transform: translateY(-10px);
    box-shadow: 0 32px 64px rgba(0, 0, 0, 0.28), 0 8px 20px rgba(139, 92, 246, 0.12);
}

.project-image {
    height: 200px;
    background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-primary) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 4rem;
    color: var(--accent-primary);
    position: relative;
    overflow: hidden;
}

/* Per-project distinct image background tints */
.project-card:nth-child(1) .project-image { background: linear-gradient(135deg, rgba(139,92,246,0.18) 0%, rgba(109,40,217,0.10) 100%); }
.project-card:nth-child(2) .project-image { background: linear-gradient(135deg, rgba(59,130,246,0.18) 0%, rgba(29,78,216,0.10) 100%); color: #3b82f6; }
.project-card:nth-child(3) .project-image { background: linear-gradient(135deg, rgba(16,185,129,0.18) 0%, rgba(5,150,105,0.10) 100%); color: #10b981; }
.project-card:nth-child(4) .project-image { background: linear-gradient(135deg, rgba(245,158,11,0.18) 0%, rgba(217,119,6,0.10) 100%); color: #f59e0b; }

.project-image svg {
    width: 80px;
    height: 80px;
    color: var(--accent-primary);
    transition: var(--transition-normal);
}

.project-image.neuropath-icon svg {
    color: #8b5cf6;
}

.project-card:hover .project-image svg {
    transform: scale(1.2);
}

.project-image::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--accent-gradient);
    opacity: 0;
    transition: var(--transition-normal);
}

.project-card:hover .project-image::before { opacity: 0.1; }

.project-card:hover .project-image i {
    transform: scale(1.2);
    transition: var(--transition-normal);
}

.project-overlay {
    position: absolute;
    bottom: 14px;
    left: 16px;
}

.project-status {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    letter-spacing: 0.5px;
}

.project-status.live {
    background: rgba(16, 185, 129, 0.2);
    color: #10b981;
    border: 1px solid rgba(16, 185, 129, 0.3);
}

.project-status.upcoming {
    background: rgba(245, 158, 11, 0.2);
    color: #f59e0b;
    border: 1px solid rgba(245, 158, 11, 0.3);
}

.project-status.research {
    background: rgba(6, 182, 212, 0.2);
    color: #06b6d4;
    border: 1px solid rgba(6, 182, 212, 0.3);
}

.project-content {
    padding: 30px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.project-category {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.8rem;
    color: var(--accent-primary);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 10px;
}

.project-content h4 {
    font-size: 1.4rem;
    margin-bottom: 12px;
}

.project-content p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.7;
    margin-bottom: 20px;
    flex: 1;
}

.project-content p em {
    color: var(--text-muted);
    font-size: 0.85rem;
}

.project-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
}

.project-tech span {
    display: inline-flex;
    align-items: center;
    padding: 5px 12px;
    background: var(--bg-glass);
    border-radius: 15px;
    font-size: 0.75rem;
    color: var(--accent-secondary);
    font-family: 'JetBrains Mono', monospace;
}

.project-tech span i { color: var(--accent-primary); }

.project-links {
    display: flex;
    gap: 12px;
}

.project-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    background: var(--bg-glass);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    font-size: 0.875rem;
    color: var(--text-secondary);
    transition: var(--transition-normal);
}

.project-link.primary {
    background: var(--accent-gradient);
    border: none;
    color: white;
}

.project-link.primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px var(--accent-glow);
    color: white;
}

.project-link.disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.project-link:not(.disabled):hover {
    background: var(--accent-primary);
    border-color: var(--accent-primary);
    color: white;
}

/* ============================================
   EDUCATION TIMELINE
   ============================================ */
.timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    width: 2px;
    height: 100%;
    background: linear-gradient(
        to bottom,
        var(--accent-primary),
        var(--accent-secondary),
        var(--accent-tertiary),
        var(--accent-primary)
    );
    background-size: 100% 200%;
    animation: timeline-flow 4s linear infinite;
}

@keyframes timeline-flow {
    0%   { background-position: 0% 0%; }
    100% { background-position: 0% 200%; }
}

.timeline-item {
    display: flex;
    justify-content: flex-end;
    padding-right: 50%;
    position: relative;
    margin-bottom: 50px;
}

.timeline-item:nth-child(even) {
    justify-content: flex-start;
    padding-right: 0;
    padding-left: 50%;
}

.timeline-content {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 30px;
    max-width: 400px;
    position: relative;
    margin-right: 30px;
    transition: var(--transition-normal);
}

.timeline-content:hover {
    border-color: var(--accent-primary);
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(139, 92, 246, 0.15);
}

.timeline-item:nth-child(even) .timeline-content {
    margin-right: 0;
    margin-left: 30px;
}

.timeline-dot {
    position: absolute;
    right: calc(50% - 25px);
    top: 25px;
    width: 50px;
    height: 50px;
    background: var(--accent-gradient);
    border-radius: 50%;
    border: 4px solid var(--bg-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.2rem;
    z-index: 1;
    box-shadow: 0 5px 20px var(--accent-glow);
}

/* Distinct color per timeline entry */
.timeline-item:nth-child(1) .timeline-dot { background: linear-gradient(135deg, #8b5cf6 0%, #6d28d9 100%); box-shadow: 0 5px 20px rgba(139,92,246,0.4); }
.timeline-item:nth-child(2) .timeline-dot { background: linear-gradient(135deg, #06b6d4 0%, #0284c7 100%); box-shadow: 0 5px 20px rgba(6,182,212,0.4); }
.timeline-item:nth-child(3) .timeline-dot { background: linear-gradient(135deg, #10b981 0%, #059669 100%); box-shadow: 0 5px 20px rgba(16,185,129,0.4); }

.timeline-item:nth-child(even) .timeline-dot {
    right: auto;
    left: calc(50% - 25px);
}

.timeline-year {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.875rem;
    color: var(--accent-primary);
    font-weight: 600;
    margin-bottom: 10px;
}

.timeline-content h4 {
    font-size: 1.2rem;
    margin-bottom: 10px;
}

.timeline-content p {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-secondary);
    font-size: 0.95rem;
    margin-bottom: 10px;
}

.timeline-content .grade {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-top: 10px;
    padding: 8px 16px;
    background: var(--bg-glass);
    border-radius: 20px;
    font-size: 0.85rem;
    color: var(--accent-secondary);
}

.timeline-content .grade i { color: #fbbf24; }

/* ============================================
   CERTIFICATIONS
   ============================================ */
.certs-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 24px;
}

.cert-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 30px;
    display: flex;
    gap: 20px;
    align-items: center;
    transition: var(--transition-normal);
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.10), 0 1px 4px rgba(0, 0, 0, 0.06);
}

/* Shine sweep on hover */
.cert-card::after {
    content: '';
    position: absolute;
    top: 0; left: -100%;
    width: 60%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.06), transparent);
    transition: left 0.55s ease;
    pointer-events: none;
}

.cert-card:hover::after { left: 140%; }

.cert-card:hover {
    background: var(--bg-card-hover);
    border-color: var(--border-glow);
    transform: translateY(-5px);
    box-shadow: 0 20px 44px rgba(0, 0, 0, 0.18), 0 6px 12px rgba(139, 92, 246, 0.10);
}

.cert-icon {
    width: 70px;
    height: 70px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    flex-shrink: 0;
    color: white;
}

.cert-icon.oracle { background: linear-gradient(135deg, #f80000 0%, #c20000 100%); }
.cert-icon.microsoft { background: linear-gradient(135deg, #00a4ef 0%, #0078d4 100%); }
.cert-icon.csharp { background: linear-gradient(135deg, #68217a 0%, #9b4f96 100%); }
.cert-icon.codechef { background: linear-gradient(135deg, #5b4638 0%, #8b6914 100%); }

/* Microsoft Learn Profile Card */
.learn-profile-card {
    display: flex;
    align-items: center;
    gap: 24px;
    background: var(--bg-card);
    border: 1.5px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 28px 36px;
    margin-top: 24px;
    transition: var(--transition-normal);
    position: relative;
    overflow: hidden;
}

/* Gradient border ring on hover — mask technique, no background fill */
.learn-profile-card::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    padding: 1.5px;
    background: linear-gradient(135deg, #f25022, #ffb900, #7fba00, #00a4ef);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.35s ease;
    pointer-events: none;
}

/* Shine sweep on hover */
.learn-profile-card::after {
    content: '';
    position: absolute;
    top: 0; left: -100%;
    width: 60%; height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.07), transparent);
    transition: left 0.6s ease;
    pointer-events: none;
}

.learn-profile-card:hover::before { opacity: 1; }

.learn-profile-card:hover::after { left: 140%; }

.learn-profile-card:hover {
    border-color: transparent;
    transform: translateY(-4px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

.learn-profile-icon {
    width: 72px;
    height: 72px;
    border-radius: var(--radius-md);
    background: linear-gradient(135deg, #0078d4 0%, #5c2d91 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: white;
    flex-shrink: 0;
    position: relative;
    overflow: hidden;
    transition: box-shadow 0.35s ease;
}

/* 4-color Microsoft fill — fades in/out smoothly via opacity */
.learn-profile-icon::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background:
        linear-gradient(#f25022, #f25022) 0 0 / 50% 50% no-repeat,
        linear-gradient(#7fba00, #7fba00) 100% 0 / 50% 50% no-repeat,
        linear-gradient(#00a4ef, #00a4ef) 0 100% / 50% 50% no-repeat,
        linear-gradient(#ffb900, #ffb900) 100% 100% / 50% 50% no-repeat;
    opacity: 0;
    transition: opacity 0.35s ease;
    z-index: 0;
}

.learn-profile-card:hover .learn-profile-icon::after {
    opacity: 1;
}

.learn-profile-icon i {
    position: relative;
    z-index: 1;
    transition: transform 0.35s ease, text-shadow 0.35s ease;
}

.learn-profile-card:hover .learn-profile-icon {
    box-shadow: 0 4px 20px rgba(0, 120, 212, 0.4);
}

.learn-profile-card:hover .learn-profile-icon i {
    transform: scale(1.1);
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
}

.learn-profile-content { flex: 1; }

.learn-profile-label {
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--accent-secondary);
    margin-bottom: 4px;
    display: block;
}

.learn-profile-content h4 {
    font-size: 1.2rem;
    margin-bottom: 6px;
    color: var(--text-primary);
}

.learn-profile-content p {
    color: var(--text-muted);
    font-size: 0.92rem;
    margin: 0;
}

.learn-profile-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
    flex-shrink: 0;
}

.learn-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 18px;
    border-radius: var(--radius-sm);
    font-size: 0.88rem;
    font-weight: 600;
    text-decoration: none;
    transition: var(--transition-fast);
    white-space: nowrap;
}

.learn-btn.primary {
    background: var(--accent-gradient);
    color: white;
    box-shadow: 0 4px 15px var(--accent-glow);
}

.learn-btn.primary:hover {
    transform: translateY(-2px) translateX(2px);
    box-shadow: 0 8px 24px var(--accent-glow);
    color: white;
}

.learn-btn.secondary {
    background: var(--bg-glass);
    color: var(--accent-primary);
    border: 1px solid var(--border-color);
}

.learn-btn.secondary:hover {
    background: var(--bg-card-hover);
    border-color: var(--accent-primary);
    transform: translateY(-2px) translateX(2px);
}

@media (max-width: 600px) {
    .learn-profile-card { flex-direction: column; text-align: center; padding: 24px 20px; }
    .learn-profile-actions { flex-direction: row; justify-content: center; flex-wrap: wrap; }
}

.cert-info { flex: 1; }

.cert-info h4 {
    font-size: 1.05rem;
    margin-bottom: 8px;
    line-height: 1.4;
}

.cert-info p {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.cert-orgs {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 8px;
}

.cert-org {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(255, 255, 255, 0.08);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    color: var(--text-secondary);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: var(--transition-fast);
}

.cert-org i {
    font-size: 0.9rem;
}

.cert-org:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: var(--border-glow);
}

.cert-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    font-size: 1.5rem;
    color: var(--accent-tertiary);
    opacity: 0;
    transition: var(--transition-normal);
}

.cert-card:hover .cert-badge { opacity: 1; }

/* ============================================
   ACHIEVEMENTS
   ============================================ */
.achievements-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.achievement-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 16px;
    transition: var(--transition-normal);
}

.achievement-card:hover {
    background: var(--bg-card-hover);
    border-color: var(--border-glow);
    transform: translateX(10px);
}

.achievement-icon {
    width: 55px;
    height: 55px;
    background: var(--accent-gradient);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: white;
    flex-shrink: 0;
    transition: var(--transition-normal);
}

/* Per-card distinct icon colors */
.achievement-card:nth-child(1) .achievement-icon { background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%); }
.achievement-card:nth-child(2) .achievement-icon { background: linear-gradient(135deg, #8b5cf6 0%, #6d28d9 100%); }
.achievement-card:nth-child(3) .achievement-icon { background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%); }
.achievement-card:nth-child(4) .achievement-icon { background: linear-gradient(135deg, #10b981 0%, #059669 100%); }
.achievement-card:nth-child(5) .achievement-icon { background: linear-gradient(135deg, #06b6d4 0%, #0284c7 100%); }

.achievement-card:hover .achievement-icon { transform: scale(1.1) rotate(-4deg); }

.achievement-info h5 {
    font-size: 1.05rem;
    margin-bottom: 6px;
}

.achievement-info p {
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* ============================================
   CONTACT SECTION
   ============================================ */
.contact-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    max-width: 900px;
    margin: 0 auto 50px;
}

.contact-card {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 24px 30px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    transition: var(--transition-normal);
    text-decoration: none;
}

.contact-card:hover {
    background: var(--bg-card-hover);
    border-color: var(--accent-primary);
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(139, 92, 246, 0.15);
}

.contact-card-icon {
    width: 55px;
    height: 55px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: white;
    flex-shrink: 0;
}

.contact-card-icon.email { background: linear-gradient(135deg, #ea4335 0%, #c5221f 100%); }
.contact-card-icon.phone { background: linear-gradient(135deg, #10b981 0%, #059669 100%); }
.contact-card-icon.linkedin { background: linear-gradient(135deg, #0077b5 0%, #005885 100%); }
.contact-card-icon.github { background: linear-gradient(135deg, #333 0%, #24292e 100%); }

.contact-card-content { 
    flex: 1; 
    min-width: 0; /* Allow text to shrink */
    overflow: hidden;
}

.contact-card-content h4 {
    font-size: 1.1rem;
    margin-bottom: 4px;
    color: var(--text-primary);
}

.contact-card-content p {
    font-size: 0.85rem;
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.contact-arrow {
    font-size: 1.2rem;
    color: var(--text-muted);
    transition: var(--transition-normal);
}

.contact-card:hover .contact-arrow {
    color: var(--accent-primary);
    transform: translateX(5px);
}

/* Location */
.contact-location {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    padding: 30px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    max-width: 500px;
    margin: 0 auto 50px;
}

.location-icon {
    width: 55px;
    height: 55px;
    background: var(--accent-gradient);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: white;
}

.location-text h4 {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 4px;
}

.location-text p {
    font-size: 1.1rem;
    color: var(--text-primary);
}

/* Social Links */
.social-links-section { text-align: center; }

.social-links-section h4 {
    font-size: 1rem;
    color: var(--text-muted);
    margin-bottom: 20px;
}

.social-links-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 16px;
}

.social-link-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 20px 30px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    transition: var(--transition-bounce);
    min-width: 120px;
}

.social-link-card i {
    font-size: 1.8rem;
    color: var(--accent-primary);
    transition: var(--transition-normal);
}

/* Platform brand colors */
.social-link-card[title="GitHub"] i         { color: #e6edf3; } /* dark mode */
html[data-theme="light"] .social-link-card[title="GitHub"] i { color: #24292e; }
.social-link-card[title="LinkedIn"] i       { color: #0a66c2; }
.social-link-card[title="Instagram"] i      { color: #e1306c; }
.social-link-card[title="Facebook"] i       { color: #1877f2; }
.social-link-card[title="Medium"] i         { color: #aaaaaa; }
.social-link-card[title="ORCID"] i          { color: #a6ce39; }
.social-link-card[title="Microsoft Tech Community"] i { color: #00a4ef; }
.social-link-card[title="Microsoft Learn"] i            { color: #00a4ef; }

.social-link-card span {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.social-link-card:hover {
    background: var(--accent-gradient);
    border-color: transparent;
    transform: translateY(-8px) scale(1.05);
    box-shadow: 0 15px 30px var(--accent-glow);
}

.social-link-card:hover i,
.social-link-card:hover span { color: white !important; }

/* ============================================
   FOOTER
   ============================================ */
.footer {
    padding: 50px 0;
    border-top: none;
    position: relative;
    text-align: center;
    background: var(--bg-secondary);
}

.footer::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 2px;
    background: linear-gradient(90deg,
        var(--accent-primary),
        var(--accent-secondary),
        var(--accent-tertiary),
        var(--accent-primary)
    );
    background-size: 200% 100%;
    animation: footer-shimmer 4s linear infinite;
}

@keyframes footer-shimmer {
    0%   { background-position: 0% 0%; }
    100% { background-position: 200% 0%; }
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--text-primary);
}

.footer-brand .brand-icon {
    width: 40px;
    height: 40px;
    background: var(--accent-gradient);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.2rem;
}

.footer p {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.footer-heart {
    color: #ef4444;
    animation: heartbeat 1.5s ease-in-out infinite;
}

@keyframes heartbeat {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.2); }
}

.footer-links a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: var(--bg-glass);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    transition: var(--transition-normal);
}

.footer-links a:hover {
    background: var(--accent-primary);
    border-color: var(--accent-primary);
    color: white;
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 1024px) {
    .about-grid { grid-template-columns: 1fr; gap: 40px; }
    .about-image { order: -1; max-width: 400px; margin: 0 auto; }
    
    .timeline::before { left: 25px; }
    .timeline-item,
    .timeline-item:nth-child(even) {
        padding-left: 80px;
        padding-right: 0;
        justify-content: flex-start;
    }
    .timeline-content,
    .timeline-item:nth-child(even) .timeline-content {
        margin-left: 0;
        margin-right: 0;
        max-width: 100%;
    }
    .timeline-dot,
    .timeline-item:nth-child(even) .timeline-dot { left: 0; right: auto; }
}

@media (max-width: 768px) {
    :root { --section-padding: 70px 0; }
    
    .nav-links {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        z-index: 9999;
        background: rgba(10, 10, 15, 0.98);
        backdrop-filter: blur(20px);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 20px;
        opacity: 0;
        visibility: hidden;
        transition: var(--transition-normal);
    }
    
    html[data-theme="light"] .nav-links {
        background: rgba(240, 242, 248, 0.98);
    }
    
    html[data-theme="light"] .nav-links a {
        color: #0f0f1a;
    }
    
    html[data-theme="light"] .nav-links a:hover {
        color: var(--accent-primary);
        background: rgba(139, 92, 246, 0.1);
    }
    
    .nav-links.active { opacity: 1; visibility: visible; }
    .nav-links a { font-size: 1.3rem; padding: 15px 30px; }
    .nav-toggle { display: flex; position: relative; z-index: 10000; }
    .theme-toggle { position: relative; z-index: 10000; }

    /* Remove backdrop-filter from navbar when nav is open so fixed children fill viewport */
    .navbar:has(.nav-links.active) {
        backdrop-filter: none !important;
        -webkit-backdrop-filter: none !important;
        background: transparent !important;
        border-bottom: none !important;
    }
    
    .nav-toggle.active span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
    .nav-toggle.active span:nth-child(2) { opacity: 0; }
    .nav-toggle.active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }
    
    .hero { padding-top: 100px; }
    .hero-cta { flex-direction: column; align-items: center; }
    .btn { width: 100%; max-width: 280px; justify-content: center; }
    .about-stats { grid-template-columns: 1fr; }
    .projects-grid { grid-template-columns: 1fr; }
    .skills-grid { grid-template-columns: 1fr; }
    .certs-grid { grid-template-columns: 1fr; }
    .contact-cards { grid-template-columns: 1fr; }
    .social-links-grid { gap: 12px; }
    .social-link-card { padding: 15px 20px; min-width: 100px; }
    .scroll-indicator { display: none; }
    .floating-badges { display: none; }
    
    /* Mobile optimizations for background effects */
    * { cursor: auto !important; }
    .cursor-glow { display: none; }
    .connection-lines { display: none; }
    .hex-grid { opacity: 0.2; }
    .data-streams { display: none; }
    .code-fragments { display: none; }
    .interactive-particles .particle:nth-child(n+10) { display: none; }
    .neural-node:nth-child(n+3) { display: none; }

    /* Kill heavy GPU animations on mobile */
    .animated-bg::before,
    .animated-bg::after {
        animation: none !important;
        filter: blur(40px) !important;
    }

    .animated-bg::before {
        width: 500px;
        height: 500px;
    }

    .animated-bg::after {
        width: 420px;
        height: 420px;
    }

    .gradient-orb {
        animation: none !important;
        will-change: auto !important;
        filter: blur(50px) !important;
    }

    .orb-1 {
        width: 340px;
        height: 340px;
    }

    .orb-2 {
        width: 280px;
        height: 280px;
    }

    .orb-3 {
        width: 240px;
        height: 240px;
    }

    .neural-node {
        will-change: auto !important;
    }

    .neural-node::before {
        box-shadow: none !important;
    }

    .interactive-particles .particle {
        box-shadow: none !important;
        will-change: auto !important;
        animation-duration: 40s !important;
    }

    .nav-links {
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
    }
}

@media (max-width: 480px) {
    .container { padding: 0 16px; }
    .hero-title { font-size: 2.5rem; }
    .hero-subtitle { font-size: 1rem; }
    .section-title { font-size: 1.75rem; }
    .hero-social { gap: 12px; }
    .social-icon { width: 45px; height: 45px; }
    .project-image { height: 160px; font-size: 3rem; }
    .cert-card { flex-direction: column; text-align: center; }
    .cert-icon { margin: 0 auto; }
    .about-stats { grid-template-columns: repeat(3, 1fr); gap: 10px; }
    .stat-item { padding: 15px 10px; }
    .stat-number { font-size: 1.8rem; }
    .stat-label { font-size: 0.7rem; }
}

/* ============================================
   UTILITIES
   ============================================ */
.text-gradient {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ============================================
   BLAZOR
   ============================================ */
#blazor-error-ui {
    background: #1a1a2e;
    color: var(--text-primary);
    border-top: 1px solid var(--accent-primary);
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 0.6rem 1.25rem;
    z-index: 1000;
}

#blazor-error-ui .dismiss {
    cursor: pointer;
    position: absolute;
    right: 0.75rem;
    top: 0.5rem;
}

.loading-progress {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 8rem;
    height: 8rem;
}

.loading-progress circle {
    fill: none;
    stroke: var(--bg-secondary);
    stroke-width: 0.6rem;
    transform-origin: 50% 50%;
    transform: rotate(-90deg);
}

.loading-progress circle:last-child {
    stroke: var(--accent-primary);
    stroke-dasharray: calc(3.141 * var(--blazor-load-percentage, 0%) * 0.8), 500%;
    transition: stroke-dasharray 0.05s ease-in-out;
}

.loading-progress-text {
    position: fixed;
    text-align: center;
    font-weight: bold;
    top: calc(50% + 60px);
    left: 50%;
    transform: translateX(-50%);
    color: var(--text-primary);
}

.loading-progress-text::after {
    content: var(--blazor-load-percentage-text, "Loading");
}

/* ============================================
   REDIRECT OVERLAY
   ============================================ */
.redirect-overlay {
    position: fixed;
    inset: 0;
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-primary, #0a0812);
    animation: redirectFadeIn 0.35s ease;
}

@keyframes redirectFadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

.redirect-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.6rem;
    text-align: center;
    padding: 2rem;
}

.redirect-spinner {
    position: relative;
    width: 88px;
    height: 88px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.spinner-ring {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    border: 2.5px solid transparent;
    border-top-color: rgba(139, 92, 246, 0.9);
    animation: spinRing 1.1s linear infinite;
}

.spinner-ring-2 {
    inset: 12px;
    border-top-color: rgba(139, 92, 246, 0.45);
    animation-duration: 0.75s;
    animation-direction: reverse;
}

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

.spinner-icon {
    font-size: 1.6rem;
    color: var(--accent-primary, rgba(139, 92, 246, 1));
    animation: spinnerIconPulse 1.1s ease-in-out infinite;
}

@keyframes spinnerIconPulse {
    0%, 100% { opacity: 1;   transform: scale(1); }
    50%       { opacity: 0.6; transform: scale(0.88); }
}

.redirect-title {
    font-size: 1.45rem;
    font-weight: 600;
    color: var(--text-primary, #fff);
    margin: 0;
    letter-spacing: -0.02em;
}

.redirect-url {
    font-size: 0.82rem;
    color: var(--text-muted, rgba(255,255,255,0.45));
    font-family: 'JetBrains Mono', monospace;
    margin: 0;
    letter-spacing: 0.03em;
}

.redirect-progress {
    width: 220px;
    height: 3px;
    background: rgba(139, 92, 246, 0.12);
    border-radius: 99px;
    overflow: hidden;
}

.redirect-bar {
    height: 100%;
    width: 0;
    background: linear-gradient(90deg, rgba(139,92,246,0.7), rgba(139,92,246,1), rgba(167,139,250,1));
    border-radius: 99px;
    animation: redirectProgress 2.1s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes redirectProgress {
    from { width: 0%; }
    to   { width: 100%; }
}

/* Blog nav link highlight */
.nav-blog-link {
    color: rgba(139, 92, 246, 0.9) !important;
    font-weight: 500;
}

.nav-blog-link:hover {
    color: rgba(167, 139, 250, 1) !important;
}

/* Blog CTA button */
.btn-blog {
    background: transparent;
    border: 1.5px solid rgba(139, 92, 246, 0.6);
    color: rgba(139, 92, 246, 0.95);
    cursor: pointer;
}

.btn-blog:hover {
    background: rgba(139, 92, 246, 0.12);
    border-color: rgba(139, 92, 246, 0.9);
    color: rgba(167, 139, 250, 1);
    transform: translateY(-2px);
}
