/* ═══════════════════════════════════════════════════════════════
   Ajay Thakur Portfolio — Inspired by rubenmarcus.dev
   Matrix Green on Pure Black · Noise Grain · Terminal Aesthetics
   ═══════════════════════════════════════════════════════════════ */
@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@400;500;600;700&family=JetBrains+Mono:wght@400;500;700&display=swap');

:root {
    --bg-0: #000000;
    --bg-1: rgba(74, 222, 128, 0.035);
    --bg-2: rgba(74, 222, 128, 0.055);
    --line: rgba(74, 222, 128, 0.1);
    --line-strong: rgba(74, 222, 128, 0.18);
    --line-bright: rgba(74, 222, 128, 0.32);
    --text: #f5f1ea;
    --cream: #f5f1ea;
    --muted: rgba(245, 241, 234, 0.82);
    --muted-soft: rgba(245, 241, 234, 0.55);
    --accent: #00ff41;
    --accent-soft: #4ade80;
    --accent-deep: #15803d;
    --font-display: 'Space Grotesk', system-ui, sans-serif;
    --font-mono: 'JetBrains Mono', monospace;
    --radius-card: 16px;
    --radius-pill: 9999px;
    --ease: cubic-bezier(0.22, 1, 0.36, 1);
    --dur: 0.22s;
}

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; border-color: var(--line); }

body {
    background: var(--bg-0);
    color: var(--text);
    font-family: var(--font-display);
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
    position: relative;
}

/* Film Grain Noise Overlay */
body::before {
    content: '';
    position: fixed; inset: 0;
    pointer-events: none; z-index: 1;
    opacity: 0.04;
    mix-blend-mode: overlay;
    background-image: url("data:image/svg+xml;utf8,<svg viewBox='0 0 320 320' xmlns='http://www.w3.org/2000/svg'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='1.6' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 1 0'/></filter><rect width='100%25' height='100%25' filter='url(%23n)' opacity='0.9'/></svg>");
    background-size: 320px 320px;
}

/* Animated Dot Grid Background */
body::after {
    content: '';
    position: fixed; inset: 0;
    pointer-events: none; z-index: 1;
    mix-blend-mode: screen;
    background-image: radial-gradient(circle, rgba(74, 222, 128, 0.12) 1px, transparent 1px);
    background-size: 26px 26px;
    animation: dotCascade 32s linear infinite;
}
@keyframes dotCascade { 0% { background-position: 0 0; } to { background-position: 0 26px; } }

/* WebGL Background Canvas */
#gl-canvas {
    position: fixed;
    top: 0; left: 0;
    width: 100vw; height: 100vh;
    z-index: 0;
    pointer-events: none;
}

::selection { background: rgba(0, 255, 65, 0.35); color: #fff; }

h1, h2, h3 { font-family: var(--font-display); font-weight: 500; letter-spacing: -0.02em; color: var(--text); line-height: 1.1; }
p { color: var(--muted); line-height: 1.7; max-width: 68ch; }
a { color: inherit; text-decoration: none; }

.hidden { display: none !important; }

/* ── Loader ── */
.fixed-loader {
    position: fixed; inset: 0; background: var(--bg-0);
    display: flex; justify-content: center; align-items: center;
    z-index: 9999; transition: opacity 0.5s ease;
}
.spinner {
    width: 20px; height: 20px;
    border: 2px solid rgba(74, 222, 128, 0.15);
    border-top-color: var(--accent);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ── Marquee Availability Banner ── */
.marquee-banner {
    position: fixed; top: 0; left: 0; right: 0; height: 32px;
    display: flex; align-items: center;
    z-index: 1001; overflow: hidden;
    background: #010603;
    border-bottom: 1px solid rgba(0, 255, 65, 0.35);
}
.marquee-track {
    display: flex; width: max-content;
    animation: marqueeScroll 30s linear infinite;
}
.marquee-group {
    display: flex; align-items: center; gap: 0;
    flex-shrink: 0;
}
.marquee-item {
    display: inline-flex; align-items: center; gap: 0.45em;
    font-family: var(--font-mono); font-size: 0.68rem;
    letter-spacing: 0.12em; text-transform: uppercase;
    color: var(--muted-soft); white-space: nowrap;
    padding: 0 1.5rem;
}
.marquee-dot {
    width: 6px; height: 6px; border-radius: 50%;
    background: var(--accent); box-shadow: 0 0 7px rgba(0, 255, 65, 0.8);
}
.marquee-sep { color: var(--accent-deep); padding: 0 0.25rem; }
@keyframes marqueeScroll { 0% { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ── Header ── */
.site-header {
    position: fixed; top: 32px; left: 0; right: 0;
    z-index: 1000; padding: 1rem 0;
    background: transparent;
    border-bottom: 1px solid transparent;
    transition: background var(--dur) var(--ease), border-color var(--dur) var(--ease), backdrop-filter var(--dur) var(--ease);
}
.site-header.scrolled {
    background: rgba(6, 8, 15, 0.72);
    backdrop-filter: blur(16px);
    border-bottom-color: var(--line);
}
.header-inner {
    max-width: 1200px; margin: 0 auto;
    padding: 0 clamp(1rem, 2.5vw, 2rem);
    display: grid; grid-template-columns: auto 1fr auto;
    align-items: center; gap: 2rem;
}
.logo-link {
    font-family: var(--font-display); font-size: 1.5rem;
    font-weight: 600; letter-spacing: -0.01em;
    color: var(--text); text-decoration: none;
}
.desktop-nav { display: inline-flex; align-items: center; gap: clamp(1rem, 1.5vw, 2rem); justify-content: center; }
.desktop-nav a {
    position: relative; font-family: var(--font-display);
    font-size: 0.95rem; font-weight: 500;
    color: var(--muted); text-decoration: none;
    transition: color var(--dur) var(--ease);
}
.desktop-nav a::before {
    content: '>_'; display: inline-block;
    width: 0; margin-right: 0; overflow: hidden; white-space: pre;
    font-family: var(--font-mono); font-size: 0.72em;
    color: var(--accent-soft); opacity: 0;
    transition: width 0.26s steps(2, end), margin-right 0.26s steps(2, end), opacity 0.14s var(--ease);
}
.desktop-nav a:hover::before { width: 1.7ch; margin-right: 0.45ch; opacity: 1; }
.desktop-nav a::after {
    content: ''; position: absolute; left: 0; right: 0; bottom: -7px;
    height: 1.5px; background: var(--accent-soft);
    box-shadow: 0 0 8px rgba(0, 255, 65, 0.5);
    transform: scaleX(0); transform-origin: left;
    transition: transform 0.32s var(--ease);
}
.desktop-nav a:hover::after { transform: scaleX(1); }
.desktop-nav a:hover, .desktop-nav a.active { color: var(--text); }
.desktop-nav a.active::after { transform: scaleX(1); opacity: 1; }

/* ── Overline Labels ── */
.overline {
    font-family: var(--font-mono); font-size: 0.7rem;
    letter-spacing: 0.16em; text-transform: uppercase;
    color: var(--muted-soft); display: inline-block;
    margin-bottom: 0.5rem;
}

/* ── Buttons ── */
.btn-primary {
    display: inline-flex; align-items: center; justify-content: center;
    gap: 0.55rem; min-height: 44px;
    padding: 0.7rem 1.3rem;
    border: 1px solid var(--cream); border-radius: var(--radius-pill);
    font-size: 0.86rem; font-weight: 500;
    color: #0c0d10; background: var(--cream);
    cursor: pointer; text-decoration: none;
    transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease), background var(--dur) var(--ease);
}
.btn-primary:hover {
    background: #fff; transform: translateY(-1px);
    box-shadow: 0 0 0 1px var(--accent-soft), 0 0 24px rgba(0, 255, 65, 0.3);
}
.btn-secondary {
    display: inline-flex; align-items: center; justify-content: center;
    gap: 0.55rem; min-height: 44px;
    padding: 0.7rem 1.3rem;
    border: 1px solid var(--line-strong); border-radius: var(--radius-pill);
    font-size: 0.86rem; font-weight: 500;
    color: var(--text); background: transparent;
    cursor: pointer; text-decoration: none;
    transition: background var(--dur) var(--ease), border-color var(--dur) var(--ease);
}
.btn-secondary:hover { background: rgba(245, 241, 234, 0.05); border-color: var(--line-bright); }

/* ── Hero ── */
.hero-section {
    position: relative; min-height: 100vh;
    display: flex; flex-direction: column;
    padding: 8rem clamp(2rem, 7vw, 8rem) 11%;
    overflow: hidden;
}
.hero-lede {
    margin-top: auto;
    position: relative; z-index: 3;
    display: flex; flex-direction: column;
    align-items: flex-start; gap: 1.55rem;
    max-width: min(44rem, 55vw);
}
.hero-intro {
    font-family: var(--font-display); font-size: clamp(1.4rem, 2.1vw, 2rem);
    font-weight: 400; color: var(--muted); line-height: 1.3;
}
.hero-intro-name { color: var(--accent-soft); }
.hero-title {
    font-size: clamp(2.6rem, 4.9vw, 4.4rem);
    line-height: 0.98; letter-spacing: -0.03em; font-weight: 500;
    word-wrap: break-word;
    hyphens: auto;
}
.hero-verb {
    color: var(--accent-soft);
    text-shadow: 0 0 24px rgba(0, 255, 65, 0.4), 0 0 48px rgba(0, 255, 65, 0.2);
}
.hero-sub {
    max-width: 34rem; font-family: var(--font-display);
    font-size: clamp(0.98rem, 1.25vw, 1.15rem); font-weight: 400;
    color: var(--muted);
}
.hero-ctas { display: flex; flex-wrap: wrap; gap: 0.8rem; margin-top: 0.4rem; }
.hero-vignette {
    position: absolute; inset: 0; pointer-events: none;
    background: radial-gradient(ellipse 50% 45% at 20% 82%, rgba(4,6,11,0.62) 0%, rgba(4,6,11,0.26) 55%, transparent 82%),
                linear-gradient(180deg, rgba(4,6,11,0.5) 0%, transparent 14%);
}
.hero-fade-bottom {
    position: absolute; left: 0; right: 0; bottom: 0; height: 320px;
    pointer-events: none; z-index: 1;
    background: linear-gradient(180deg, transparent 0%, rgba(0,0,0,0.25) 30%, rgba(0,0,0,0.7) 65%, #000 100%);
}

/* ── Sections ── */
.section { position: relative; z-index: 2; width: 100%; border-bottom: 1px solid var(--line); background: #000; }
.section-inner {
    width: 100%; max-width: 1200px;
    margin: 0 auto; padding: 3.5rem clamp(1.5rem, 5vw, 3.5rem) 4.5rem;
}
.section-head { display: flex; flex-direction: column; gap: 1rem; margin-bottom: 2.25rem; }
.section-title {
    font-size: clamp(2rem, 3.8vw, 3rem); font-weight: 500;
    line-height: 1; letter-spacing: -0.01em;
}

/* ── Cards ── */
.card {
    position: relative;
    display: flex; flex-direction: column; gap: 0.65rem;
    padding: 1.4rem; border: 1px solid var(--line);
    border-radius: var(--radius-card); background: #000;
    overflow: hidden; isolation: isolate;
    transition: border-color var(--dur) var(--ease), transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}
.card::after {
    content: ''; position: absolute; inset: 0;
    pointer-events: none; border-radius: inherit;
    background: linear-gradient(115deg, transparent 32%, rgba(0,255,65,0.05) 46%, rgba(0,255,65,0.14) 50%, rgba(0,255,65,0.05) 54%, transparent 68%);
    background-size: 260% 100%; background-position: 125% 0;
    opacity: 0;
    transition: background-position 0.72s var(--ease), opacity var(--dur) var(--ease);
}
.card:hover {
    border-color: var(--line-bright); transform: translateY(-3px);
    box-shadow: 0 16px 40px rgba(0,0,0,0.48), 0 0 0 1px rgba(0,255,65,0.1);
}
.card:hover::after { opacity: 1; background-position: -25% 0; }

/* ── Stats Grid ── */
.stats-grid {
    display: grid; grid-template-columns: 1fr;
    gap: 1px; background: var(--line);
    border: 1px solid var(--line); border-radius: var(--radius-card);
    overflow: hidden;
}
@media (min-width: 640px) { .stats-grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1080px) { .stats-grid { grid-template-columns: repeat(4, 1fr); } }
.stats-cell {
    display: flex; flex-direction: column; gap: 0.4rem;
    padding: 1.5rem 1.4rem; background: #000;
    transition: background var(--dur) var(--ease);
}
.stats-cell:hover { background: rgba(0, 255, 65, 0.03); }
.stats-value {
    font-family: var(--font-display); font-size: clamp(1.9rem, 3vw, 2.6rem);
    font-weight: 600; line-height: 1; letter-spacing: -0.02em;
    color: var(--text); font-variant-numeric: tabular-nums;
    text-shadow: 0 0 18px rgba(0, 255, 65, 0.18);
}
.stats-label { color: var(--muted); font-size: 0.88rem; }

/* ── Work Experience Cards ── */
.hire-grid { display: grid; grid-template-columns: 1fr; gap: 1.25rem; }
@media (min-width: 720px) { .hire-grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1080px) { .hire-grid { grid-template-columns: repeat(3, 1fr); } }

.work-card {
    --mx: 50%; --my: 50%;
    position: relative; display: flex; flex-direction: column; gap: 0.65rem;
    padding: 1.4rem 1.4rem 1.5rem;
    border: 1px solid var(--line); border-radius: var(--radius-card);
    background: #000; overflow: hidden; isolation: isolate;
    transition: border-color var(--dur) var(--ease), transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}
.work-card::before {
    content: ''; position: absolute; inset: 0; z-index: -1;
    background: radial-gradient(220px circle at var(--mx) var(--my), rgba(0,255,65,0.09), transparent 70%);
    opacity: 0; transition: opacity var(--dur) var(--ease);
}
.work-card:hover::before { opacity: 1; }
.work-card::after {
    content: ''; position: absolute; left: 0; right: 0; top: -2px; height: 2px;
    background: linear-gradient(90deg, transparent, rgba(0,255,65,0.75), transparent);
    opacity: 0; pointer-events: none;
}
.work-card:hover::after { opacity: 1; animation: hireSweep 0.9s var(--ease) 1; }
@keyframes hireSweep { 0% { transform: translateY(0); } to { transform: translateY(320px); } }
.work-card:hover {
    border-color: var(--line-bright); transform: translateY(-4px);
    box-shadow: 0 20px 52px rgba(0,0,0,0.55), 0 0 0 1px rgba(0,255,65,0.12);
}
.work-card-header { display: flex; justify-content: space-between; align-items: flex-start; }
.work-logo {
    width: 48px; height: 48px; border-radius: 8px;
    object-fit: contain; background: #fff; padding: 4px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
}
.work-dates {
    text-align: right; display: flex; flex-direction: column; gap: 0.25rem;
    font-family: var(--font-mono); font-size: 0.68rem;
    color: var(--muted-soft); text-transform: uppercase; font-weight: 500;
}
.work-duration { color: var(--accent-soft); font-weight: 700; font-size: 0.78rem; }
.work-title-row { display: flex; align-items: center; gap: 0.5rem; }
.work-title { font-size: 1.35rem; font-weight: 500; font-family: var(--font-display); line-height: 1.1; }
.work-badge { font-size: 0.62rem; font-family: var(--font-mono); padding: 0.15rem 0.4rem; border-radius: 4px; font-weight: 700; }
.work-badge.current { background: rgba(0, 255, 65, 0.12); color: var(--accent); border: 1px solid rgba(0, 255, 65, 0.3); }
.work-company { font-size: 0.85rem; color: var(--muted-soft); }
.work-desc { font-size: 0.95rem; color: var(--muted); line-height: 1.55; flex: 1; }
.work-skills { display: flex; flex-wrap: wrap; gap: 0.3rem 0.45rem; padding: 0; margin: 0.2rem 0 0; list-style: none; }
.work-skills span {
    padding: 0.18rem 0.5rem;
    border: 1px solid var(--line); border-radius: var(--radius-pill);
    font-family: var(--font-mono); font-size: 0.66rem;
    color: var(--muted-soft);
    transition: color var(--dur) var(--ease), border-color var(--dur) var(--ease);
}
.work-card:hover .work-skills span:hover { color: var(--accent-soft); border-color: rgba(0,255,65,0.3); background: rgba(0,255,65,0.06); }

/* ── Domain Cards ── */
.domains-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 1.25rem; }
.card-name { font-family: var(--font-display); font-size: 1.35rem; line-height: 1.1; }
.card-desc { color: var(--muted); font-size: 0.95rem; }
.card-chips { display: flex; flex-wrap: wrap; gap: 0.3rem 0.45rem; list-style: none; padding: 0; margin: 0.2rem 0 0; }
.card-chips span {
    padding: 0.18rem 0.5rem; border: 1px solid var(--line);
    border-radius: var(--radius-pill); font-family: var(--font-mono);
    font-size: 0.66rem; color: var(--muted-soft);
}

/* ── Article Cards ── */
.articles-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 1.25rem; }
.article-card { cursor: pointer; }
.article-meta {
    display: flex; gap: 1rem;
    font-family: var(--font-mono); font-size: 0.68rem;
    color: var(--muted-soft); text-transform: uppercase; letter-spacing: 0.08em;
}
.article-card h3 { font-size: 1.15rem; font-weight: 500; transition: color var(--dur) var(--ease); }
.article-card p { font-size: 0.9rem; }
.article-card:hover h3 { color: var(--accent-soft); }
.read-more-btn {
    font-family: var(--font-mono); font-size: 0.72rem; letter-spacing: 0.06em;
    text-transform: uppercase; color: var(--accent-soft); opacity: 0.75;
    transition: opacity var(--dur) var(--ease);
}
.card:hover .read-more-btn { opacity: 1; text-shadow: 0 0 12px rgba(0, 255, 65, 0.45); }

/* ── Timeline ── */
.timeline { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 1.5rem; }
.timeline .timeline-row { display: grid; grid-template-columns: 1fr; gap: 1rem; }
@media(min-width: 720px) { .timeline .timeline-row { grid-template-columns: 200px 1fr; gap: 2rem; } }
.timeline-meta { display: flex; flex-direction: column; gap: 0.25rem; }
.timeline-year { font-family: var(--font-display); font-size: 2rem; line-height: 1; color: var(--accent-soft); }
.timeline-period { font-family: var(--font-mono); font-size: 0.72rem; color: var(--muted); }
.timeline-location { font-family: var(--font-mono); font-size: 0.7rem; color: var(--muted-soft); }
.timeline-body { display: flex; flex-direction: column; gap: 0.7rem; }
.timeline-head { display: flex; flex-wrap: wrap; gap: 0.4rem 0.85rem; align-items: baseline; }
.timeline-role { font-family: var(--font-display); font-size: 1.4rem; line-height: 1.15; color: var(--text); }
.timeline-org { font-family: var(--font-mono); font-size: 0.74rem; color: var(--accent-soft); text-transform: uppercase; letter-spacing: 0.08em; }
.timeline-bullets { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 0.45rem; }
.timeline-bullets li { color: var(--muted); font-size: 0.95rem; line-height: 1.55; padding-left: 1.2rem; position: relative; }
.timeline-bullets li:before { content: "→"; position: absolute; left: 0; color: var(--accent-soft); }
.timeline-stack { display: flex; flex-wrap: wrap; gap: 0.3rem 0.4rem; margin-top: 0.3rem; }
.timeline-tag { padding: 0.15rem 0.5rem; border: 1px solid var(--line); border-radius: var(--radius-pill); font-family: var(--font-mono); font-size: 0.66rem; color: var(--muted-soft); }

/* ── Education List ── */
.edu-list { list-style: none; padding: 0; margin: 0; }
.edu-row { display: grid; grid-template-columns: 1fr; gap: 0.4rem; padding: 1rem 0; border-top: 1px solid var(--line); border-bottom: 1px solid transparent; }
.edu-row:not(:last-child) { border-bottom: 1px solid var(--line); }
@media(min-width: 720px) { .edu-row { grid-template-columns: 200px 1fr auto; gap: 1.2rem; align-items: baseline; } }
.edu-school { font-family: var(--font-display); font-size: 1.4rem; line-height: 1; color: var(--text); }
.edu-school a { color: inherit; text-decoration: none; border-bottom: 1px solid var(--line-strong); transition: border-color var(--dur) var(--ease); }
.edu-school a:hover { border-color: var(--accent-soft); }
.edu-program { color: var(--muted); font-size: 0.95rem; }
.edu-period { font-family: var(--font-mono); font-size: 0.74rem; color: var(--muted-soft); }

/* ── About Grid (from Ruben Marcus) ── */
.about-grid { display: grid; gap: 2.5rem; grid-template-columns: 1fr; margin-top: 1rem; }
@media(min-width: 880px) { .about-grid { grid-template-columns: 1.4fr 1fr; gap: 4rem; } }
.about-body { display: flex; flex-direction: column; gap: 1.2rem; }
.about-body p { color: var(--muted); font-size: 1.05rem; line-height: 1.7; margin-bottom: 0; }
.about-card { border: 1px solid var(--line); border-radius: var(--radius-card); padding: 1rem; background: #06080f99; backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); display: flex; flex-direction: column; gap: 1rem; }
.about-card__photo { position: relative; border-radius: 12px; overflow: hidden; }
.about-card__portrait { aspect-ratio: 1 / 1; width: 100%; border-radius: 12px; object-fit: cover; display: block; }
.about-card__meta dl { display: grid; gap: 0.6rem; margin: 0.55rem 0 0; }
.about-card__meta dl > div { display: grid; grid-template-columns: 88px 1fr; gap: 0.6rem; }
.about-card__meta dt { font-family: var(--font-mono); font-size: 0.7rem; color: var(--muted-soft); text-transform: uppercase; letter-spacing: 0.08em; }
.about-card__meta dd { color: var(--text); margin: 0; font-size: 0.9rem; }

/* ── Recruiter Section ── */
.recruiter-section { text-align: center; padding: 4rem clamp(1.5rem, 5vw, 3.5rem); }
.recruiter-box { max-width: 700px; margin: 0 auto; }
.recruiter-info h3 { font-size: 1.5rem; margin-bottom: 0.5rem; }
.recruiter-info p { color: var(--muted); margin-bottom: 2rem; }

/* ── Modal ── */
.modal-overlay {
    position: fixed; inset: 0;
    background: rgba(0, 0, 0, 0.6); backdrop-filter: blur(8px);
    z-index: 1100; display: flex; align-items: center; justify-content: center; padding: 1rem;
}
.modal-content {
    background: #0c0d10; border: 1px solid var(--line);
    width: 100%; max-width: 600px; border-radius: var(--radius-card);
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.6); overflow: hidden;
}
.modal-header {
    padding: 1.25rem 1.5rem; border-bottom: 1px solid var(--line);
    display: flex; justify-content: space-between; align-items: center;
}
.close-btn { background: none; border: none; color: var(--muted); font-size: 2rem; cursor: pointer; line-height: 0.5; transition: color var(--dur); }
.close-btn:hover { color: var(--accent-soft); }
.modal-body { padding: 2rem; }
.keyword-density { display: flex; flex-wrap: wrap; gap: 0.4rem; margin: 1rem 0; }
.keyword-density span {
    font-family: var(--font-mono); font-size: 0.66rem;
    padding: 0.3rem 0.6rem; border-radius: var(--radius-pill);
    background: rgba(0, 255, 65, 0.06); border: 1px solid var(--line);
    color: var(--accent-soft);
}

/* ── Reader Modal ── */
.reader-modal-content {
    width: 100%; max-width: 900px; height: 90vh; padding: 0;
    background: #0c0d10; border: 1px solid var(--line);
    border-radius: var(--radius-card); display: flex; flex-direction: column;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.6); overflow: hidden;
}
.reader-header {
    padding: 1rem 2rem; border-bottom: 1px solid var(--line);
    display: flex; justify-content: space-between; align-items: center;
    background: rgba(2, 6, 23, 0.95);
}
.reader-actions { display: flex; align-items: center; }
.reader-body { padding: 3rem 2rem; overflow-y: auto; flex: 1; }
.reader-title { font-size: 2.5rem; font-weight: 600; margin-bottom: 1rem; line-height: 1.15; }
.reader-meta { font-family: var(--font-mono); font-size: 0.85rem; color: var(--muted-soft); margin-bottom: 3rem; padding-bottom: 2rem; border-bottom: 1px solid var(--line); }
.reader-content { font-size: 1.1rem; line-height: 1.8; color: var(--muted); max-width: 700px; margin: 0 auto; }
.reader-content p { margin-bottom: 1.5rem; }
.reader-content h1, .reader-content h2, .reader-content h3 { margin: 2.5rem 0 1rem; color: var(--text); }
.reader-content img { max-width: 100%; height: auto; border-radius: 8px; margin: 2rem 0; }
.reader-content a { color: var(--accent-soft); text-decoration: underline; }
.reader-content blockquote { border-left: 3px solid var(--accent); padding-left: 1.5rem; font-style: italic; color: var(--muted-soft); margin: 2rem 0; }

/* ── Footer ── */
.site-footer {
    border-top: 1px solid var(--line);
    padding: 3rem clamp(1.5rem, 5vw, 3.5rem) 1.75rem;
    position: relative; z-index: 2; background: var(--bg-0);
}
.footer-inner {
    max-width: 1200px; margin: 0 auto;
    display: grid; gap: 2rem; grid-template-columns: 1.2fr repeat(2, 1fr);
}
@media (max-width: 768px) { .footer-inner { grid-template-columns: 1fr; } }
.footer-col { display: flex; flex-direction: column; gap: 0.85rem; }
.footer-brand-name { font-family: var(--font-display); font-size: 1.5rem; font-weight: 500; }
.footer-brand-role { color: var(--muted); font-size: 0.95rem; }
.footer-links { list-style: none; padding: 0; display: grid; gap: 0.15rem; }
.footer-links a {
    display: inline-block; padding: 0.28rem 0;
    color: var(--muted); font-family: var(--font-mono); font-size: 0.8rem;
    transition: color var(--dur) var(--ease);
}
.footer-links a:hover { color: var(--accent-soft); }
.footer-bottom {
    max-width: 1200px; margin: 2rem auto 0;
    padding-top: 1.5rem; border-top: 1px solid var(--line);
    font-family: var(--font-mono); font-size: 0.7rem; color: var(--muted-soft);
    text-align: center;
}

/* ── Certs ── */
.cert-grid { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.cert-pill {
    display: inline-flex; align-items: center; gap: 0.45rem;
    padding: 0.38rem 0.62rem;
    border: 1px solid rgba(74, 222, 128, 0.2); border-radius: var(--radius-pill);
    background: rgba(74, 222, 128, 0.05);
    color: var(--accent-soft); font-family: var(--font-mono);
    font-size: 0.7rem; white-space: nowrap;
    text-decoration: none;
    transition: background var(--dur) var(--ease), border-color var(--dur) var(--ease);
}
.cert-pill:hover { background: rgba(74, 222, 128, 0.12); border-color: rgba(0, 255, 65, 0.4); }

/* ── Scroll Animations ── */
.scroll-animate { opacity: 0; transform: translateY(16px); transition: opacity 0.64s var(--ease), transform 0.64s var(--ease); }
.scroll-animate.is-visible { opacity: 1; transform: none; }
.delay-1 { transition-delay: 0.1s; }
.delay-2 { transition-delay: 0.2s; }
.delay-3 { transition-delay: 0.3s; }

/* ── Loading/Error states ── */
.loading-blogs { text-align: center; color: var(--muted-soft); padding: 4rem 0; grid-column: 1 / -1; }
.error-blogs { text-align: center; color: #ef4444; padding: 4rem 0; grid-column: 1 / -1; }

/* ── Mobile Sidebar Menu ── */
.mobile-menu-btn {
    display: none;
    background: none; border: none;
    color: var(--text); padding: 0.5rem;
    cursor: pointer;
    transition: color var(--dur) var(--ease);
}
.mobile-menu-btn:hover { color: var(--accent-soft); }
.mobile-menu-btn svg { width: 28px; height: 28px; }

.mobile-sidebar {
    position: fixed; top: 0; left: 0; bottom: 0;
    width: 280px; max-width: 80vw;
    background: #06080f;
    border-right: 1px solid var(--line);
    z-index: 10000;
    display: flex; flex-direction: column;
    transform: translateX(-100%);
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.mobile-sidebar.open { transform: translateX(0); }

.sidebar-close {
    padding: 1.5rem; display: flex; justify-content: flex-end;
}
.close-sidebar-btn {
    background: none; border: none;
    color: var(--muted); font-size: 2.5rem; line-height: 0.5;
    cursor: pointer; transition: color var(--dur);
}
.close-sidebar-btn:hover { color: var(--accent-soft); }

.sidebar-nav {
    display: flex; flex-direction: column;
    padding: 0 2rem 2rem; gap: 0.5rem;
}
.sidebar-nav a {
    font-family: var(--font-display);
    font-size: 1.5rem; font-weight: 500;
    color: var(--muted);
    padding: 1rem 0;
    border-bottom: 1px solid var(--line);
    text-decoration: none;
    transition: color var(--dur) var(--ease);
}
.sidebar-nav a:hover, .sidebar-nav a.active {
    color: var(--text);
}
.sidebar-nav a.active::before {
    content: '>_ ';
    color: var(--accent-soft);
    font-family: var(--font-mono);
    font-size: 0.8em;
}

.sidebar-overlay {
    position: fixed; inset: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    z-index: 9999;
    opacity: 0; pointer-events: none;
    transition: opacity 0.4s ease;
}
.sidebar-overlay.open {
    opacity: 1; pointer-events: auto;
}

@media (max-width: 900px) {
    .header-inner { display: flex; justify-content: space-between; align-items: center; }
    .hero-lede { max-width: none; }
    .hero-section { padding: 8rem 1rem 8%; }
    .desktop-nav { display: none; }
    .header-socials { display: none; }
    .mobile-menu-btn { display: flex; align-items: center; justify-content: center; margin-left: auto; }
}

/* ── Custom Cursor ── */
.cursor-dot {
    position: fixed; width: 8px; height: 8px;
    background: var(--accent); border-radius: 50%;
    pointer-events: none; z-index: 9998;
    transform: translate(-50%, -50%);
    transition: width 0.15s var(--ease), height 0.15s var(--ease), background 0.15s var(--ease);
    box-shadow: 0 0 10px rgba(0, 255, 65, 0.6), 0 0 30px rgba(0, 255, 65, 0.2);
}
.cursor-ring {
    position: fixed; width: 36px; height: 36px;
    border: 1.5px solid rgba(0, 255, 65, 0.35); border-radius: 50%;
    pointer-events: none; z-index: 9997;
    transform: translate(-50%, -50%);
    transition: width 0.3s var(--ease), height 0.3s var(--ease), border-color 0.3s var(--ease);
}
body.cursor-hover .cursor-dot {
    width: 14px; height: 14px;
    background: var(--accent-soft);
    box-shadow: 0 0 20px rgba(0, 255, 65, 0.8), 0 0 50px rgba(0, 255, 65, 0.3);
}
body.cursor-hover .cursor-ring {
    width: 50px; height: 50px;
    border-color: rgba(0, 255, 65, 0.5);
}
@media (pointer: coarse) {
    .cursor-dot, .cursor-ring { display: none; }
}

/* ── Header Social Icons ── */
.header-socials {
    display: inline-flex; align-items: center; gap: 0.4rem;
}
.header-social {
    display: inline-grid; place-items: center;
    width: 36px; height: 36px; border-radius: 999px;
    color: var(--muted); text-decoration: none;
    transition: color var(--dur) var(--ease);
}
.header-social:hover { color: var(--text); }
.header-social svg { width: 18px; height: 18px; }

/* ── Language Toggle ── */
.lang-toggle {
    display: inline-flex;
    align-items: center;
    position: relative;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 999px;
    padding: 2px;
    cursor: pointer;
    gap: 0;
    margin-right: 0.3rem;
    backdrop-filter: blur(8px);
    transition: border-color var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}
.lang-toggle:hover {
    border-color: rgba(255, 255, 255, 0.15);
    box-shadow: 0 0 12px rgba(0, 255, 65, 0.08);
}
.lang-option {
    position: relative;
    z-index: 2;
    padding: 4px 10px;
    font-family: var(--font-mono);
    font-size: 0.65rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--muted);
    border: none;
    background: none;
    cursor: pointer;
    border-radius: 999px;
    transition: color var(--dur) var(--ease);
    line-height: 1;
    white-space: nowrap;
}
.lang-option.active {
    color: var(--bg);
}
.lang-option:not(.active):hover {
    color: var(--text);
}
.lang-slider {
    position: absolute;
    top: 2px;
    left: 2px;
    height: calc(100% - 4px);
    width: calc(50% - 2px);
    background: var(--accent);
    border-radius: 999px;
    transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1);
    z-index: 1;
    box-shadow: 0 0 8px rgba(0, 255, 65, 0.3);
}
.lang-toggle[data-lang="de"] .lang-slider {
    transform: translateX(100%);
}

/* ── Projects Grid ── */
.projects-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 1.25rem; }
.project-card { text-decoration: none; color: var(--text); }
.project-thumb {
    width: 100%; aspect-ratio: 16/9; border-radius: 8px;
    background: var(--bg-1); overflow: hidden; margin-bottom: 1rem;
    display: flex; align-items: center; justify-content: center;
    font-family: var(--font-mono); font-size: 3rem; color: var(--accent-deep);
    border: 1px solid var(--line);
}
.project-name { font-size: 1.2rem; font-weight: 500; margin-bottom: 0.25rem; }
.project-desc { font-size: 0.9rem; color: var(--muted); }
.project-cta {
    display: inline-block; margin-top: 0.75rem;
    font-family: var(--font-mono); font-size: 0.72rem;
    letter-spacing: 0.06em; text-transform: uppercase;
    color: var(--accent-soft); opacity: 0.75;
    transition: opacity var(--dur) var(--ease);
}
.card:hover .project-cta { opacity: 1; text-shadow: 0 0 12px rgba(0, 255, 65, 0.45); }

/* ── Contact Form ── */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: start; }
@media (max-width: 768px) { .contact-grid { grid-template-columns: 1fr; } }
.contact-form { display: flex; flex-direction: column; gap: 1rem; }
.form-group { display: flex; flex-direction: column; gap: 0.3rem; }
.form-label { font-family: var(--font-mono); font-size: 0.7rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted-soft); }
.form-input, .form-textarea {
    padding: 0.75rem 1rem;
    font-family: var(--font-mono); font-size: 0.85rem;
    color: var(--text); background: #06080c;
    border: 1px solid var(--line); border-radius: 8px;
    outline: none;
    transition: border-color var(--dur) var(--ease);
}
.form-input:focus, .form-textarea:focus { border-color: rgba(0, 255, 65, 0.45); }
.form-textarea { resize: vertical; min-height: 140px; }
.contact-info { display: flex; flex-direction: column; gap: 1.5rem; }
.contact-info-item h4 { font-size: 0.95rem; font-weight: 500; margin-bottom: 0.25rem; }
.contact-info-item p { font-size: 0.88rem; }
.contact-info-item a { color: var(--accent-soft); border-bottom: 1px solid var(--line-strong); transition: border-color var(--dur) var(--ease); }
.contact-info-item a:hover { border-bottom-color: var(--accent-soft); }

/* ── Theme Definitions ── */
body.theme-white {
    --accent: #ffffff;
    --accent-soft: #e2e8f0;
    --accent-deep: #94a3b8;
    --bg-1: rgba(255, 255, 255, 0.035);
    --bg-2: rgba(255, 255, 255, 0.055);
    --line: rgba(255, 255, 255, 0.1);
    --line-strong: rgba(255, 255, 255, 0.18);
    --line-bright: rgba(255, 255, 255, 0.32);
}

body.theme-cyan {
    --accent: #00e5ff;
    --accent-soft: #22d3ee;
    --accent-deep: #0891b2;
    --bg-1: rgba(34, 211, 238, 0.035);
    --bg-2: rgba(34, 211, 238, 0.055);
    --line: rgba(34, 211, 238, 0.1);
    --line-strong: rgba(34, 211, 238, 0.18);
    --line-bright: rgba(34, 211, 238, 0.32);
}

body.theme-yellow {
    --accent: #fbbf24;
    --accent-soft: #fcd34d;
    --accent-deep: #d97706;
    --bg-1: rgba(252, 211, 77, 0.035);
    --bg-2: rgba(252, 211, 77, 0.055);
    --line: rgba(252, 211, 77, 0.1);
    --line-strong: rgba(252, 211, 77, 0.18);
    --line-bright: rgba(252, 211, 77, 0.32);
}

body.theme-red {
    --accent: #f43f5e;
    --accent-soft: #fb7185;
    --accent-deep: #be123c;
    --bg-1: rgba(251, 113, 133, 0.035);
    --bg-2: rgba(251, 113, 133, 0.055);
    --line: rgba(251, 113, 133, 0.1);
    --line-strong: rgba(251, 113, 133, 0.18);
    --line-bright: rgba(251, 113, 133, 0.32);
}

/* Theme Toggle Button */
.theme-toggle-btn {
    background: none; border: none;
    color: var(--muted); padding: 0.5rem;
    cursor: pointer; display: flex; align-items: center; justify-content: center;
    transition: color var(--dur) var(--ease);
}
.theme-toggle-btn:hover { color: var(--accent-soft); }
.theme-toggle-btn svg { width: 24px; height: 24px; }

@media (min-width: 901px) {
    .theme-toggle-btn { margin-left: auto; }
}

/* System Config Modal */
.theme-modal-overlay {
    position: fixed; inset: 0;
    background: rgba(0, 0, 0, 0.4); backdrop-filter: blur(8px);
    z-index: 10500; display: flex; align-items: center; justify-content: flex-end;
    opacity: 0; pointer-events: none; transition: opacity 0.3s ease;
    padding: 1rem;
}
.theme-modal-overlay.open { opacity: 1; pointer-events: auto; }

.theme-modal {
    background: rgba(6, 8, 15, 0.95);
    border: 1px solid var(--line); border-radius: 12px;
    width: 320px; box-shadow: 0 25px 50px rgba(0, 0, 0, 0.8);
    transform: translateX(40px); transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    display: flex; flex-direction: column; overflow: hidden;
}
.theme-modal-overlay.open .theme-modal { transform: translateX(0); }

.theme-modal-header {
    padding: 1.25rem; border-bottom: 1px solid var(--line);
    display: flex; justify-content: space-between; align-items: flex-start;
}
.theme-modal-header h3 { font-family: var(--font-mono); font-size: 1.2rem; color: var(--text); margin-bottom: 0.2rem; }
.theme-modal-subtitle { font-family: var(--font-mono); font-size: 0.65rem; color: var(--muted-soft); letter-spacing: 0.1em; }
.theme-modal-close {
    background: transparent; border: 1px solid var(--line-strong);
    color: var(--muted); padding: 0.25rem 0.6rem; border-radius: 4px;
    font-family: var(--font-mono); font-size: 0.7rem; cursor: pointer;
    transition: all var(--dur);
}
.theme-modal-close:hover { border-color: var(--accent-soft); color: var(--accent-soft); }

.theme-modal-section { padding: 1.5rem 1.25rem; }
.theme-modal-section-title {
    display: flex; justify-content: space-between; font-family: var(--font-mono);
    font-size: 0.7rem; color: var(--muted-soft); margin-bottom: 1rem;
}

.theme-picker-box {
    display: flex; align-items: center; justify-content: space-between;
    padding: 1rem; border: 1px solid var(--line); border-radius: 8px;
    background: rgba(0,0,0,0.4);
}
.theme-dot {
    width: 20px; height: 20px; border-radius: 50%;
    border: none; cursor: pointer; position: relative;
    transition: transform var(--dur);
}
.theme-dot:hover { transform: scale(1.15); }
.theme-dot.active::before {
    content: ''; position: absolute; inset: -6px;
    border: 1.5px solid var(--accent-soft); border-radius: 50%;
}
.theme-dot[data-theme="theme-white"] { background: #ffffff; }
.theme-dot[data-theme="theme-cyan"] { background: #00e5ff; }
.theme-dot[data-theme="theme-green"] { background: #00ff41; }
.theme-dot[data-theme="theme-yellow"] { background: #fbbf24; }
.theme-dot[data-theme="theme-red"] { background: #f43f5e; }

.theme-modal-footer {
    padding: 1rem; border-top: 1px solid var(--line);
    text-align: center; font-family: var(--font-mono); font-size: 0.65rem;
    color: var(--muted-soft); display: flex; align-items: center; justify-content: center; gap: 0.5rem;
}
.theme-status-dot {
    width: 6px; height: 6px; background: var(--accent-soft); border-radius: 50%;
    box-shadow: 0 0 6px var(--accent-soft);
}
