/* ==========================================
   CSS DESIGN SYSTEM — Joshua Kochiyil Portfolio
   Premium AI/ML Theme · Cyan + Purple Glow
   ========================================== */

/* ---------- CSS Custom Properties ---------- */
:root {
    /* Core backgrounds */
    --bg-primary: #06060e;
    --bg-secondary: #0a0a18;
    --bg-surface: #0d0d1a;
    --bg-elevated: #13132a;
    --bg-card: rgba(13, 13, 26, 0.7);
    --bg-card-hover: rgba(19, 19, 42, 0.85);

    /* Accent colors */
    --cyan: #00e5ff;
    --cyan-dim: #00b8d4;
    --purple: #8b5cf6;
    --purple-dim: #7c3aed;
    --accent-gradient: linear-gradient(135deg, #00e5ff, #8b5cf6);
    --accent-gradient-reverse: linear-gradient(135deg, #8b5cf6, #00e5ff);
    --accent-gradient-subtle: linear-gradient(135deg, rgba(0, 229, 255, 0.15), rgba(139, 92, 246, 0.15));

    /* Text */
    --text-primary: #eaeaf0;
    --text-secondary: #8a8aad;
    --text-muted: #4a4a6a;
    --text-bright: #ffffff;

    /* Borders & Glass */
    --border-subtle: rgba(0, 229, 255, 0.06);
    --border-default: rgba(0, 229, 255, 0.1);
    --border-glow: rgba(0, 229, 255, 0.25);
    --glass-bg: rgba(13, 13, 30, 0.55);
    --glass-border: rgba(0, 229, 255, 0.08);
    --glass-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);

    /* Glows */
    --glow-cyan: 0 0 30px rgba(0, 229, 255, 0.15);
    --glow-cyan-strong: 0 0 50px rgba(0, 229, 255, 0.25);
    --glow-purple: 0 0 30px rgba(139, 92, 246, 0.15);
    --glow-mixed: 0 0 40px rgba(0, 229, 255, 0.12), 0 0 80px rgba(139, 92, 246, 0.08);

    /* Spacing */
    --section-pad: 110px;
    --container-width: 1200px;

    /* Typography */
    --font-heading: 'Space Grotesk', 'Inter', sans-serif;
    --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-mono: 'JetBrains Mono', 'Fira Code', monospace;

    /* Transitions */
    --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
    --ease-smooth: cubic-bezier(0.4, 0, 0.2, 1);
    --t-fast: 0.2s var(--ease-smooth);
    --t-base: 0.35s var(--ease-smooth);
    --t-slow: 0.6s var(--ease-out);

    /* Radius */
    --r-sm: 8px;
    --r-md: 12px;
    --r-lg: 16px;
    --r-xl: 24px;
}

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

html {
    scroll-behavior: smooth;
    font-size: 16px;
    scrollbar-width: thin;
    scrollbar-color: var(--cyan-dim) var(--bg-primary);
}

body {
    font-family: var(--font-body);
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.7;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg-primary); }
::-webkit-scrollbar-thumb {
    background: linear-gradient(to bottom, var(--cyan-dim), var(--purple-dim));
    border-radius: 3px;
}

::selection {
    background: rgba(0, 229, 255, 0.2);
    color: var(--text-bright);
}

img { max-width: 100%; display: block; }

a {
    text-decoration: none;
    color: inherit;
    transition: color var(--t-fast);
}

ul { list-style: none; }

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

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

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

/* ---------- Glass Card ---------- */
.glass-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--r-lg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: var(--glass-shadow);
    transition: transform var(--t-base), border-color var(--t-base), box-shadow var(--t-base), background var(--t-base);
    position: relative;
}

.glass-card:hover {
    transform: translateY(-4px);
    border-color: var(--border-glow);
    box-shadow: var(--glow-mixed), var(--glass-shadow);
    background: var(--bg-card-hover);
}

/* ==========================================
   NAVIGATION
   ========================================== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 18px 0;
    transition: all var(--t-base);
    background: transparent;
    border-bottom: 1px solid transparent;
}

.navbar.scrolled {
    background: rgba(6, 6, 14, 0.88);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border-bottom-color: var(--border-subtle);
    padding: 12px 0;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

.nav-container {
    width: 100%;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.nav-logo {
    font-family: var(--font-mono);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    letter-spacing: -0.5px;
    position: relative;
}

.logo-bracket {
    color: var(--cyan);
    text-shadow: 0 0 20px rgba(0, 229, 255, 0.4);
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 4px;
}

.nav-link {
    padding: 8px 16px;
    font-size: 0.88rem;
    font-weight: 500;
    color: var(--text-secondary);
    border-radius: var(--r-sm);
    transition: all var(--t-fast);
    position: relative;
    letter-spacing: 0.01em;
}

.nav-link:hover {
    color: var(--text-primary);
    background: rgba(0, 229, 255, 0.04);
}

.nav-link.active {
    color: var(--cyan);
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: 0px;
    left: 50%;
    transform: translateX(-50%);
    width: 20px;
    height: 2px;
    background: var(--accent-gradient);
    border-radius: 1px;
    box-shadow: 0 0 8px rgba(0, 229, 255, 0.4);
}

/* Hamburger */
.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    z-index: 1001;
}

.bar {
    width: 24px;
    height: 2px;
    background: var(--text-primary);
    border-radius: 2px;
    transition: all var(--t-base);
}

.hamburger.active .bar:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}
.hamburger.active .bar:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}
.hamburger.active .bar:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* Mobile Overlay */
.mobile-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    z-index: 998;
    opacity: 0;
    pointer-events: none;
    transition: opacity var(--t-base);
    backdrop-filter: blur(4px);
}

.mobile-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

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

.hero::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: clamp(140px, 22vh, 260px);
    background: linear-gradient(
        to bottom,
        rgba(10, 10, 24, 0) 0%,
        rgba(10, 10, 24, 0.35) 35%,
        rgba(10, 10, 24, 0.75) 65%,
        var(--bg-secondary) 100%
    );
    z-index: 1;
    pointer-events: none;
}

/* Neural network canvas */
.hero-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
}

/* Background effects */
.hero-bg-effects {
    position: absolute;
    inset: 0;
    overflow: hidden;
    z-index: 0;
    pointer-events: none;
}

.hero-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(120px);
    opacity: 0.2;
    animation: orbFloat 25s ease-in-out infinite;
}

.hero-orb-1 {
    width: 600px;
    height: 600px;
    background: var(--cyan);
    top: -15%;
    right: -10%;
    animation-delay: 0s;
}

.hero-orb-2 {
    width: 500px;
    height: 500px;
    background: var(--purple);
    bottom: -15%;
    left: -10%;
    animation-delay: -8s;
}

.hero-orb-3 {
    width: 350px;
    height: 350px;
    background: linear-gradient(135deg, var(--cyan), var(--purple));
    top: 40%;
    left: 40%;
    transform: translate(-50%, -50%);
    animation-delay: -16s;
    opacity: 0.1;
}

@keyframes orbFloat {
    0%, 100% { transform: translate(0, 0) scale(1); }
    25% { transform: translate(40px, -50px) scale(1.06); }
    50% { transform: translate(-30px, 40px) scale(0.94); }
    75% { transform: translate(20px, -20px) scale(1.02); }
}

.hero-grid {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(0, 229, 255, 0.025) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 229, 255, 0.025) 1px, transparent 1px);
    background-size: 64px 64px;
    mask-image: radial-gradient(ellipse at center, black 20%, transparent 70%);
    -webkit-mask-image: radial-gradient(ellipse at center, black 20%, transparent 70%);
}

/* Glowing data orb */
.hero-data-orb {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 400px;
    height: 400px;
    border-radius: 50%;
    background: radial-gradient(circle at 40% 40%,
        rgba(0, 229, 255, 0.06) 0%,
        rgba(139, 92, 246, 0.04) 40%,
        transparent 70%);
    animation: orbPulse 6s ease-in-out infinite;
    z-index: 0;
    pointer-events: none;
}

.hero-data-orb::after {
    content: '';
    position: absolute;
    inset: 20%;
    border-radius: 50%;
    border: 1px solid rgba(0, 229, 255, 0.06);
    animation: orbRing 8s linear infinite;
}

@keyframes orbPulse {
    0%, 100% { transform: translate(-50%, -50%) scale(1); opacity: 0.6; }
    50% { transform: translate(-50%, -50%) scale(1.08); opacity: 1; }
}

@keyframes orbRing {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Hero content */
.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 880px;
}

/* Boot sequence */
.hero-boot {
    margin-bottom: 32px;
    min-height: 80px;
}

.boot-line {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--cyan);
    opacity: 0;
    transform: translateY(8px);
    transition: opacity 0.5s ease, transform 0.5s ease;
    text-shadow: 0 0 10px rgba(0, 229, 255, 0.3);
}

.boot-line.visible {
    opacity: 1;
    transform: translateY(0);
}

.boot-line.dim {
    color: var(--text-muted);
    text-shadow: none;
}

.boot-cursor {
    display: inline-block;
    width: 8px;
    height: 16px;
    background: var(--cyan);
    margin-left: 4px;
    animation: bootBlink 0.7s step-end infinite;
    vertical-align: middle;
    box-shadow: 0 0 6px rgba(0, 229, 255, 0.5);
}

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

/* Hero title */
.hero-title {
    font-family: var(--font-heading);
    font-size: clamp(2.2rem, 5.5vw, 3.8rem);
    font-weight: 700;
    line-height: 1.15;
    margin-bottom: 24px;
    letter-spacing: -1.5px;
    opacity: 0;
    transform: translateY(30px);
    animation: heroFadeIn 0.9s var(--ease-out) 2.8s both;
}

.hero-subtitle {
    font-size: clamp(1rem, 2.2vw, 1.2rem);
    color: var(--text-secondary);
    max-width: 640px;
    margin: 0 auto 32px;
    line-height: 1.8;
    opacity: 0;
    transform: translateY(20px);
    animation: heroFadeIn 0.9s var(--ease-out) 3s both;
}

/* Typed role */
.hero-roles {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 1.05rem;
    margin-bottom: 40px;
    min-height: 32px;
    opacity: 0;
    transform: translateY(20px);
    animation: heroFadeIn 0.9s var(--ease-out) 3.2s both;
}

.role-prefix {
    color: var(--text-secondary);
}

.typed-text {
    color: var(--cyan);
    font-weight: 600;
    font-family: var(--font-mono);
    text-shadow: 0 0 12px rgba(0, 229, 255, 0.3);
}

.cursor-blink {
    color: var(--cyan);
    font-weight: 300;
    animation: blink 1s step-end infinite;
}

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

/* Hero CTA */
.hero-cta {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    flex-wrap: wrap;
    opacity: 0;
    transform: translateY(20px);
    animation: heroFadeIn 0.9s var(--ease-out) 3.4s both;
}

@keyframes heroFadeIn {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 28px;
    font-size: 0.92rem;
    font-weight: 600;
    border-radius: var(--r-md);
    cursor: pointer;
    border: none;
    transition: all var(--t-base);
    font-family: var(--font-body);
    letter-spacing: 0.01em;
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: var(--accent-gradient);
    color: var(--bg-primary);
    box-shadow: 0 4px 20px rgba(0, 229, 255, 0.2), 0 0 40px rgba(0, 229, 255, 0.08);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(0, 229, 255, 0.3), 0 0 60px rgba(0, 229, 255, 0.12);
}

.btn-secondary {
    background: transparent;
    color: var(--text-primary);
    border: 1px solid var(--border-glow);
}

.btn-secondary:hover {
    background: rgba(0, 229, 255, 0.06);
    border-color: var(--cyan);
    transform: translateY(-2px);
    box-shadow: var(--glow-cyan);
}

.btn-outline {
    background: transparent;
    border: 1px solid var(--glass-border);
    color: var(--text-secondary);
}

.btn-outline:hover {
    border-color: var(--cyan);
    color: var(--text-primary);
    background: rgba(0, 229, 255, 0.05);
    box-shadow: var(--glow-cyan);
}

.btn-sm {
    padding: 10px 20px;
    font-size: 0.84rem;
}

/* ==========================================
   SECTIONS — SHARED STYLES
   ========================================== */
.section {
    padding: var(--section-pad) 0;
    position: relative;
    background: var(--bg-secondary);
}

#about::before {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    height: clamp(90px, 16vh, 170px);
    background: linear-gradient(
        to bottom,
        rgba(10, 10, 24, 0.85) 0%,
        rgba(10, 10, 24, 0.35) 55%,
        rgba(10, 10, 24, 0) 100%
    );
    pointer-events: none;
}

.section-alt {
    background: var(--bg-secondary);
}

.section-header {
    text-align: center;
    margin-bottom: 72px;
}

.section-tag {
    display: inline-block;
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--cyan);
    text-transform: uppercase;
    letter-spacing: 3px;
    margin-bottom: 14px;
    font-family: var(--font-mono);
    text-shadow: 0 0 12px rgba(0, 229, 255, 0.2);
}

.section-title {
    font-family: var(--font-heading);
    font-size: clamp(1.9rem, 4vw, 2.6rem);
    font-weight: 700;
    letter-spacing: -0.5px;
    margin-bottom: 18px;
}

.section-line {
    width: 60px;
    height: 3px;
    background: var(--accent-gradient);
    border-radius: 3px;
    margin: 0 auto;
    box-shadow: 0 0 12px rgba(0, 229, 255, 0.3);
}

/* ==========================================
   ABOUT SECTION — Avatar Scanner
   ========================================== */
.about-scanner-layout {
    display: grid;
    grid-template-columns: 380px 1fr;
    gap: 48px;
    align-items: start;
}

/* ---- Avatar Scanner (Left) ---- */
.avatar-scanner {
    position: sticky;
    top: 120px;
}

.scanner-frame {
    position: relative;
    width: 100%;
    aspect-ratio: 1;
    border-radius: var(--r-lg);
    overflow: hidden;
    background: rgba(6, 6, 14, 0.8);
    border: 1px solid var(--border-default);
    box-shadow: var(--glass-shadow);
}

/* Corner bracket overlays */
.scanner-corner {
    position: absolute;
    width: 28px;
    height: 28px;
    z-index: 5;
    pointer-events: none;
}

.scanner-corner::before,
.scanner-corner::after {
    content: '';
    position: absolute;
    background: var(--cyan);
    border-radius: 1px;
    transition: background 0.4s;
}

.scanner-corner-tl { top: 10px; left: 10px; }
.scanner-corner-tl::before { width: 28px; height: 2px; top: 0; left: 0; }
.scanner-corner-tl::after  { width: 2px; height: 28px; top: 0; left: 0; }

.scanner-corner-tr { top: 10px; right: 10px; }
.scanner-corner-tr::before { width: 28px; height: 2px; top: 0; right: 0; }
.scanner-corner-tr::after  { width: 2px; height: 28px; top: 0; right: 0; }

.scanner-corner-bl { bottom: 10px; left: 10px; }
.scanner-corner-bl::before { width: 28px; height: 2px; bottom: 0; left: 0; }
.scanner-corner-bl::after  { width: 2px; height: 28px; bottom: 0; left: 0; }

.scanner-corner-br { bottom: 10px; right: 10px; }
.scanner-corner-br::before { width: 28px; height: 2px; bottom: 0; right: 0; }
.scanner-corner-br::after  { width: 2px; height: 28px; bottom: 0; right: 0; }

/* Scanner beam */
.scanner-beam {
    position: absolute;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--cyan);
    box-shadow:
        0 0 20px rgba(0, 229, 255, 0.6),
        0 0 60px rgba(0, 229, 255, 0.3),
        0 -30px 80px rgba(0, 229, 255, 0.08);
    z-index: 4;
    opacity: 0;
    top: 0;
}

.scanner-beam.active {
    opacity: 1;
    animation: beamSweep 2.4s ease-in-out forwards;
}

@keyframes beamSweep {
    0%   { top: 0%; }
    100% { top: 100%; }
}

/* HUD labels */
.scanner-hud {
    position: absolute;
    inset: 0;
    z-index: 5;
    pointer-events: none;
}

.hud-label {
    position: absolute;
    font-family: var(--font-mono);
    font-size: 0.65rem;
    font-weight: 600;
    color: var(--cyan);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    opacity: 0.6;
    text-shadow: 0 0 6px rgba(0, 229, 255, 0.4);
}

.hud-top-left     { top: 16px; left: 46px; }
.hud-top-right    { top: 16px; right: 46px; }
.hud-bottom-left  { bottom: 16px; left: 46px; }
.hud-bottom-right { bottom: 16px; right: 46px; }

/* Crosshair */
.scanner-crosshair {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 48px;
    height: 48px;
    transform: translate(-50%, -50%);
    z-index: 5;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.5s;
}

.scanner-crosshair.active {
    opacity: 0.5;
}

.scanner-crosshair::before,
.scanner-crosshair::after {
    content: '';
    position: absolute;
    background: var(--cyan);
}

.scanner-crosshair::before {
    width: 1px;
    height: 100%;
    left: 50%;
    top: 0;
}

.scanner-crosshair::after {
    height: 1px;
    width: 100%;
    top: 50%;
    left: 0;
}

/* Avatar image */
.scanner-avatar {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center top;
    filter: saturate(0.3) brightness(0.7);
    transition: filter 1.6s ease;
}

.scanner-avatar.scanned {
    filter: saturate(1) brightness(1);
}

/* Progress bar below scanner */
.scanner-status-bar {
    margin-top: 12px;
    height: 3px;
    background: rgba(0, 229, 255, 0.08);
    border-radius: 3px;
    overflow: hidden;
}

.scanner-status-fill {
    height: 100%;
    width: 0%;
    background: var(--accent-gradient);
    border-radius: 3px;
    box-shadow: 0 0 8px rgba(0, 229, 255, 0.3);
    transition: width 2.4s ease-in-out;
}

.scanner-status-fill.active {
    width: 100%;
}

/* Status text */
.scanner-status-text {
    margin-top: 8px;
    font-family: var(--font-mono);
    font-size: 0.72rem;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 8px;
}

.scanner-status-text i {
    color: var(--cyan);
    font-size: 0.7rem;
}

/* ---- Scan Results (Right) ---- */
.scan-results {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

/* Terminal window */
.scan-terminal {
    border-radius: var(--r-lg);
    border: 1px solid var(--border-default);
    background: rgba(6, 6, 14, 0.85);
    overflow: hidden;
    box-shadow: var(--glass-shadow);
}

.scan-terminal-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 20px;
    border-bottom: 1px solid var(--border-subtle);
    background: rgba(13, 13, 30, 0.6);
}

.terminal-dots {
    display: flex;
    gap: 7px;
}

.dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.dot-red    { background: #ff5f57; }
.dot-yellow { background: #febc2e; }
.dot-green  { background: #28c840; }

.terminal-title {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--text-muted);
    flex: 1;
}

.scan-badge {
    font-family: var(--font-mono);
    font-size: 0.65rem;
    font-weight: 700;
    padding: 3px 10px;
    border-radius: 4px;
    background: rgba(255, 165, 0, 0.12);
    color: #ffa500;
    border: 1px solid rgba(255, 165, 0, 0.25);
    letter-spacing: 1px;
    text-transform: uppercase;
    transition: all 0.5s;
}

.scan-badge.complete {
    background: rgba(0, 229, 255, 0.1);
    color: var(--cyan);
    border-color: rgba(0, 229, 255, 0.3);
}

/* Terminal body */
.scan-terminal-body {
    padding: 20px;
    min-height: 200px;
}

.scan-output-line {
    opacity: 0;
    transform: translateY(8px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.scan-output-line.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Command lines */
.scan-cmd {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-bottom: 16px;
}

.scan-cmd .prompt {
    color: var(--cyan);
    margin-right: 4px;
    text-shadow: 0 0 8px rgba(0, 229, 255, 0.4);
}

/* Result key-value lines */
.scan-result {
    display: flex;
    align-items: baseline;
    gap: 12px;
    margin-bottom: 10px;
    padding: 6px 0;
    border-bottom: 1px solid rgba(0, 229, 255, 0.04);
}

.scan-label {
    font-family: var(--font-mono);
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--cyan);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    min-width: 80px;
    opacity: 0.8;
    flex-shrink: 0;
}

.scan-value {
    font-size: 0.95rem;
    color: var(--text-primary);
    font-weight: 500;
}

/* Bio paragraphs */
.scan-bio {
    margin-bottom: 12px;
}

.scan-bio p {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.8;
}

/* Complete line */
.scan-complete-line {
    color: var(--cyan) !important;
    margin-top: 8px;
}

.scan-check {
    color: #28c840;
    font-weight: 700;
    text-shadow: 0 0 8px rgba(40, 200, 64, 0.5);
}

/* ---- Interests below terminal ---- */
.scan-interests {
    opacity: 0;
    transform: translateY(16px);
    transition: opacity 0.6s ease 0.3s, transform 0.6s ease 0.3s;
}

.scan-interests.visible {
    opacity: 1;
    transform: translateY(0);
}

.scan-interests-title {
    font-family: var(--font-heading);
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.scan-interests-title i {
    color: var(--cyan);
    font-size: 0.85rem;
}

.interest-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.tag {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 18px;
    background: rgba(0, 229, 255, 0.04);
    border: 1px solid rgba(0, 229, 255, 0.1);
    border-radius: 50px;
    font-size: 0.85rem;
    color: var(--text-secondary);
    transition: all var(--t-fast);
}

.tag:hover {
    background: rgba(0, 229, 255, 0.08);
    border-color: var(--cyan);
    color: var(--text-primary);
    box-shadow: var(--glow-cyan);
}

.tag i {
    color: var(--cyan);
    font-size: 0.8rem;
}

/* ---- Stats row ---- */
.scan-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
}

.scan-stat-item {
    padding: 20px 12px;
    text-align: center;
}

.stat-icon {
    font-size: 1.4rem;
    color: var(--cyan);
    margin-bottom: 12px;
}

.stat-value {
    font-family: var(--font-heading);
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.stat-label {
    font-size: 0.72rem;
    color: var(--text-muted);
}

/* ==========================================
   PROJECTS
   ========================================== */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 28px;
}

.project-card {
    padding: 36px;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
}

.project-card:hover {
    transform: none;
}

/* Animated top border */
.project-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--accent-gradient);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.5s var(--ease-out);
}

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

/* Hover glow background */
.project-card::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at center,
        rgba(0, 229, 255, 0.03) 0%,
        transparent 50%);
    opacity: 0;
    transition: opacity var(--t-slow);
    pointer-events: none;
}

.project-card:hover::after {
    opacity: 1;
}

.project-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    position: relative;
    z-index: 1;
}

.project-icon {
    width: 54px;
    height: 54px;
    border-radius: var(--r-md);
    background: rgba(0, 229, 255, 0.08);
    border: 1px solid rgba(0, 229, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    color: var(--cyan);
    transition: all var(--t-base);
}

.project-card:hover .project-icon {
    background: var(--accent-gradient);
    color: var(--bg-primary);
    border-color: transparent;
    box-shadow: var(--glow-cyan);
}

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

.project-link {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    transition: all var(--t-fast);
    font-size: 1.1rem;
}

.project-link:hover {
    color: var(--cyan);
    background: rgba(0, 229, 255, 0.08);
}

.project-title {
    font-family: var(--font-heading);
    font-size: 1.35rem;
    font-weight: 700;
    margin-bottom: 4px;
    position: relative;
    z-index: 1;
}

.project-subtitle {
    font-size: 0.82rem;
    color: var(--cyan);
    font-weight: 500;
    margin-bottom: 8px;
    font-family: var(--font-mono);
    position: relative;
    z-index: 1;
}

.project-impact {
    font-size: 0.92rem;
    color: var(--purple);
    font-weight: 500;
    margin-bottom: 12px;
    font-style: italic;
    position: relative;
    z-index: 1;
}

.project-description {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.75;
    margin-bottom: 20px;
    flex: 1;
    position: relative;
    z-index: 1;
}

.project-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 24px;
    position: relative;
    z-index: 1;
}

.tech-tag {
    padding: 4px 14px;
    background: rgba(0, 229, 255, 0.05);
    border: 1px solid rgba(0, 229, 255, 0.1);
    border-radius: 6px;
    font-size: 0.78rem;
    color: var(--cyan);
    font-family: var(--font-mono);
    font-weight: 500;
    transition: all var(--t-fast);
}

.tech-tag:hover {
    background: rgba(0, 229, 255, 0.1);
    border-color: var(--cyan);
}

.project-cta {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    position: relative;
    z-index: 1;
}

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

.timeline::before {
    content: '';
    position: absolute;
    left: 28px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: linear-gradient(to bottom,
        var(--cyan),
        var(--purple),
        rgba(139, 92, 246, 0.1));
    border-radius: 2px;
    box-shadow: 0 0 12px rgba(0, 229, 255, 0.15);
}

.timeline-item {
    display: flex;
    gap: 32px;
    margin-bottom: 44px;
    position: relative;
}

.timeline-item:last-child {
    margin-bottom: 0;
}

.timeline-marker {
    flex-shrink: 0;
    width: 58px;
    display: flex;
    justify-content: center;
    position: relative;
    z-index: 2;
}

.timeline-dot {
    width: 58px;
    height: 58px;
    border-radius: 50%;
    background: var(--bg-surface);
    border: 2px solid var(--cyan);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    color: var(--cyan);
    box-shadow: 0 0 24px rgba(0, 229, 255, 0.15), inset 0 0 12px rgba(0, 229, 255, 0.05);
    transition: all var(--t-base);
}

.timeline-item:hover .timeline-dot {
    background: var(--accent-gradient);
    color: var(--bg-primary);
    border-color: transparent;
    box-shadow: var(--glow-cyan-strong);
}

.timeline-content {
    flex: 1;
    padding: 28px;
}

.timeline-content:hover {
    transform: translateY(-4px) translateX(4px);
}

.timeline-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 16px;
    flex-wrap: wrap;
    gap: 12px;
}

.timeline-date {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.8rem;
    color: var(--cyan);
    font-family: var(--font-mono);
    font-weight: 500;
    margin-bottom: 8px;
    text-shadow: 0 0 8px rgba(0, 229, 255, 0.2);
}

.timeline-title {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 6px;
}

.timeline-org {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.timeline-status {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 14px;
    border-radius: 50px;
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1.5px;
}

.timeline-status.active {
    background: rgba(0, 229, 255, 0.08);
    color: var(--cyan);
    border: 1px solid rgba(0, 229, 255, 0.2);
    box-shadow: 0 0 12px rgba(0, 229, 255, 0.1);
}

.timeline-status.active .status-dot {
    width: 6px;
    height: 6px;
    background: var(--cyan);
    border-radius: 50%;
    animation: pulse 2s ease-in-out infinite;
    box-shadow: 0 0 6px rgba(0, 229, 255, 0.5);
}

@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(0.7); }
}

.timeline-details {
    margin-bottom: 20px;
}

.timeline-details li {
    position: relative;
    padding-left: 20px;
    margin-bottom: 8px;
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.65;
}

.timeline-details li::before {
    content: '▹';
    position: absolute;
    left: 0;
    color: var(--cyan);
    font-size: 0.9rem;
}

.timeline-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

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

.skill-card {
    padding: 32px;
    text-align: center;
}

.skill-icon {
    width: 56px;
    height: 56px;
    margin: 0 auto 18px;
    border-radius: var(--r-md);
    background: rgba(0, 229, 255, 0.06);
    border: 1px solid rgba(0, 229, 255, 0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    color: var(--cyan);
    transition: all var(--t-base);
}

.skill-card:hover .skill-icon {
    background: var(--accent-gradient);
    color: var(--bg-primary);
    border-color: transparent;
    transform: scale(1.1) rotate(5deg);
    box-shadow: var(--glow-cyan);
}

.skill-category {
    font-family: var(--font-heading);
    font-size: 1.05rem;
    font-weight: 700;
    margin-bottom: 16px;
}

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

.skill-tags span {
    padding: 6px 14px;
    background: rgba(0, 229, 255, 0.03);
    border: 1px solid rgba(0, 229, 255, 0.08);
    border-radius: 6px;
    font-size: 0.82rem;
    color: var(--text-secondary);
    transition: all var(--t-fast);
}

.skill-tags span:hover {
    background: rgba(0, 229, 255, 0.08);
    border-color: var(--cyan);
    color: var(--text-primary);
    box-shadow: 0 0 12px rgba(0, 229, 255, 0.1);
}

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

.achievement-card {
    padding: 40px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

/* Radial glow on hover */
.achievement-card::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle,
        rgba(0, 229, 255, 0.03) 0%,
        rgba(139, 92, 246, 0.02) 30%,
        transparent 60%);
    opacity: 0;
    transition: opacity var(--t-slow);
    pointer-events: none;
}

.achievement-card:hover::after {
    opacity: 1;
}

.achievement-icon {
    font-size: 2.8rem;
    margin-bottom: 20px;
    position: relative;
    z-index: 1;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    filter: drop-shadow(0 0 8px rgba(0, 229, 255, 0.3));
}

.achievement-year {
    display: inline-block;
    padding: 4px 18px;
    background: rgba(0, 229, 255, 0.06);
    border: 1px solid rgba(0, 229, 255, 0.15);
    border-radius: 50px;
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--cyan);
    margin-bottom: 18px;
    font-family: var(--font-mono);
    position: relative;
    z-index: 1;
}

.achievement-title {
    font-family: var(--font-heading);
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 14px;
    position: relative;
    z-index: 1;
}

.achievement-description {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.75;
    position: relative;
    z-index: 1;
}

/* ==========================================
   CONTACT
   ========================================== */
.contact-intro {
    text-align: center;
    font-size: 1.1rem;
    color: var(--text-secondary);
    max-width: 580px;
    margin: 0 auto 52px;
    line-height: 1.8;
}

.contact-headline {
    text-align: center;
    margin-bottom: 16px;
}

.contact-headline h3 {
    font-family: var(--font-heading);
    font-size: clamp(1.6rem, 3.5vw, 2.2rem);
    font-weight: 700;
    letter-spacing: -0.5px;
}

.contact-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    max-width: 800px;
    margin: 0 auto;
}

.contact-card {
    padding: 40px 24px;
    text-align: center;
    cursor: pointer;
    display: block;
}

.contact-card:hover {
    transform: translateY(-6px);
}

.contact-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 18px;
    border-radius: 50%;
    background: rgba(0, 229, 255, 0.06);
    border: 1px solid rgba(0, 229, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    color: var(--cyan);
    transition: all var(--t-base);
}

.contact-card:hover .contact-icon {
    background: var(--accent-gradient);
    color: var(--bg-primary);
    border-color: transparent;
    transform: scale(1.1);
    box-shadow: var(--glow-cyan-strong);
}

.contact-card h3 {
    font-family: var(--font-heading);
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 8px;
}

.contact-card p {
    font-size: 0.85rem;
    color: var(--text-muted);
    word-break: break-word;
}

/* ==========================================
   FOOTER
   ========================================== */
.footer {
    padding: 44px 0;
    border-top: 1px solid var(--border-subtle);
    background: var(--bg-primary);
}

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

.footer-logo {
    font-family: var(--font-mono);
    font-size: 1.3rem;
    font-weight: 700;
}

.footer-text {
    font-size: 0.88rem;
    color: var(--text-secondary);
}

.footer-socials {
    display: flex;
    gap: 16px;
}

.footer-socials a {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    border: 1px solid var(--border-subtle);
    transition: all var(--t-fast);
}

.footer-socials a:hover {
    color: var(--cyan);
    border-color: var(--cyan);
    background: rgba(0, 229, 255, 0.06);
    transform: translateY(-2px);
    box-shadow: var(--glow-cyan);
}

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

/* ==========================================
   ANIMATIONS — Reveal on Scroll
   ========================================== */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s var(--ease-out), transform 0.8s var(--ease-out);
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

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

@keyframes fadeInDown {
    from { opacity: 0; transform: translateY(-20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ==========================================
   RESPONSIVE — Tablet
   ========================================== */
@media (max-width: 1024px) {
    :root {
        --section-pad: 80px;
    }

    .about-scanner-layout {
        grid-template-columns: 1fr;
    }

    .avatar-scanner {
        max-width: 380px;
        margin: 0 auto;
        position: relative;
        top: auto;
    }

    .scan-stats {
        grid-template-columns: repeat(4, 1fr);
    }

    .skills-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .projects-grid {
        grid-template-columns: 1fr;
    }
}

/* ==========================================
   RESPONSIVE — Mobile
   ========================================== */
@media (max-width: 768px) {
    :root {
        --section-pad: 64px;
    }

    .hamburger {
        display: flex;
    }

    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 280px;
        height: 100vh;
        background: rgba(10, 10, 24, 0.97);
        backdrop-filter: blur(24px);
        -webkit-backdrop-filter: blur(24px);
        flex-direction: column;
        align-items: flex-start;
        padding: 80px 32px 32px;
        gap: 4px;
        transition: right var(--t-base);
        z-index: 999;
        border-left: 1px solid var(--border-subtle);
    }

    .nav-links.open {
        right: 0;
    }

    .nav-link {
        width: 100%;
        padding: 12px 16px;
        font-size: 1rem;
    }

    .hero {
        padding: 100px 20px 60px;
    }

    .hero-title {
        font-size: clamp(1.6rem, 7vw, 2.4rem);
    }

    .hero-data-orb {
        width: 250px;
        height: 250px;
    }

    .about-scanner-layout {
        gap: 32px;
    }

    .avatar-scanner {
        max-width: 300px;
    }

    .scan-stats {
        grid-template-columns: repeat(2, 1fr);
    }

    .scan-terminal-body {
        padding: 14px;
    }

    .scan-result {
        flex-direction: column;
        gap: 4px;
    }

    .skills-grid {
        grid-template-columns: 1fr;
    }

    .contact-grid {
        grid-template-columns: 1fr;
        max-width: 400px;
    }

    .achievements-grid {
        grid-template-columns: 1fr;
    }

    .projects-grid {
        grid-template-columns: 1fr;
    }

    /* Timeline mobile */
    .timeline::before {
        left: 16px;
    }

    .timeline-item {
        gap: 20px;
    }

    .timeline-marker {
        width: 34px;
    }

    .timeline-dot {
        width: 34px;
        height: 34px;
        font-size: 0.75rem;
    }

    .timeline-content {
        padding: 20px;
    }

    .timeline-header {
        flex-direction: column;
    }
}

@media (max-width: 480px) {
    .hero-roles {
        flex-direction: column;
        gap: 4px;
    }

    .hero-cta {
        flex-direction: column;
        width: 100%;
    }

    .btn {
        width: 100%;
        justify-content: center;
    }

    .project-cta {
        flex-direction: column;
    }

    .project-cta .btn {
        width: 100%;
        justify-content: center;
    }

    .hero-boot {
        min-height: 60px;
    }

    .boot-line {
        font-size: 0.75rem;
    }
}
