/* ================================================================
   Portfolio Design System — styles.css
   Ported from design_handoff/ React prototype
   ================================================================ */

/* ── Tokens ─────────────────────────────────────────────────────── */
:root {
  --bg: oklch(96% 0.012 75);
  --bg-2: oklch(93% 0.014 75);
  --bg-3: oklch(89% 0.018 75);
  --ink: oklch(18% 0.012 50);
  --ink-2: oklch(35% 0.012 50);
  --muted: oklch(52% 0.012 50);
  --line: oklch(82% 0.018 75);
  --accent: oklch(58% 0.14 45);
  --accent-soft: oklch(58% 0.14 45 / 0.12);
  --shadow: 0 1px 0 oklch(80% 0.018 75), 0 12px 32px oklch(40% 0.04 60 / 0.06);

  --f-serif: 'Instrument Serif', ui-serif, Georgia, serif;
  --f-sans: 'Geist', ui-sans-serif, system-ui, -apple-system, 'Helvetica Neue', sans-serif;
  --f-mono: 'Geist Mono', ui-monospace, 'JetBrains Mono', monospace;

  --gutter: clamp(20px, 4vw, 56px);
  --maxw: 1280px;

  --section-y: 110px;
  --stack-y: 20px;

  color-scheme: light;
}

/* ── Theme: terminal (dark) ─────────────────────────────────────── */
[data-theme="terminal"] {
  --bg: oklch(15% 0.024 252);
  --bg-2: oklch(19% 0.026 252);
  --bg-3: oklch(23% 0.028 252);
  --ink: oklch(94% 0.008 250);
  --ink-2: oklch(78% 0.012 250);
  --muted: oklch(60% 0.018 250);
  --line: oklch(30% 0.03 252);
  --accent: oklch(78% 0.15 220);
  --accent-soft: oklch(78% 0.15 220 / 0.14);
  --shadow: 0 0 0 1px oklch(30% 0.03 252), 0 24px 60px oklch(8% 0.04 252 / 0.6);
  color-scheme: dark;
}

/* ── Accent variants ────────────────────────────────────────────── */
[data-accent="rust"]    { --accent: oklch(58% 0.14 45);  --accent-soft: oklch(58% 0.14 45 / 0.12); }
[data-accent="forest"]  { --accent: oklch(56% 0.12 150); --accent-soft: oklch(56% 0.12 150 / 0.12); }
[data-accent="cobalt"]  { --accent: oklch(56% 0.16 255); --accent-soft: oklch(56% 0.16 255 / 0.12); }
[data-accent="plum"]    { --accent: oklch(52% 0.14 330); --accent-soft: oklch(52% 0.14 330 / 0.12); }
[data-theme="terminal"][data-accent="rust"]   { --accent: oklch(72% 0.14 50);  --accent-soft: oklch(72% 0.14 50 / 0.14); }
[data-theme="terminal"][data-accent="forest"] { --accent: oklch(78% 0.16 150); --accent-soft: oklch(78% 0.16 150 / 0.14); }
[data-theme="terminal"][data-accent="cobalt"] { --accent: oklch(78% 0.15 220); --accent-soft: oklch(78% 0.15 220 / 0.14); }
[data-theme="terminal"][data-accent="plum"]   { --accent: oklch(74% 0.15 320); --accent-soft: oklch(74% 0.15 320 / 0.14); }

/* ── Density variants ───────────────────────────────────────────── */
[data-density="cozy"]    { --section-y: 64px;  --stack-y: 14px; }
[data-density="comfy"]   { --section-y: 110px; --stack-y: 20px; }
[data-density="spacious"]{ --section-y: 160px; --stack-y: 28px; }

/* ── Reset & base ───────────────────────────────────────────────── */
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--f-sans);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  transition: background 240ms ease, color 240ms ease;
}

::selection { background: var(--accent-soft); color: var(--ink); }

body::before {
  content: "";
  position: fixed; inset: 0;
  background-image: radial-gradient(oklch(50% 0.03 60 / 0.025) 1px, transparent 1px);
  background-size: 3px 3px;
  pointer-events: none;
  z-index: 0;
  opacity: 1;
}
[data-theme="terminal"] body::before { opacity: 0; }

a { color: inherit; text-underline-offset: 3px; text-decoration-thickness: 1px; }
hr.rule { border: 0; height: 1px; background: var(--line); margin: 0; }

/* ── Layout ─────────────────────────────────────────────────────── */
.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 var(--gutter); position: relative; z-index: 1; }
section { padding: var(--section-y, 110px) 0; position: relative; }

/* ── Typography helpers ─────────────────────────────────────────── */
.mono { font-family: var(--f-mono); font-feature-settings: "ss01" on, "ss02" on; }
.serif { font-family: var(--f-serif); font-weight: 400; }
[data-theme="terminal"] .serif { font-family: var(--f-mono); font-weight: 400; letter-spacing: -0.01em; }
[data-theme="terminal"] body { letter-spacing: 0.005em; }

.eyebrow {
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  display: inline-flex; align-items: center; gap: 10px;
}
.eyebrow::before {
  content: ""; width: 18px; height: 1px; background: var(--accent);
}

/* ── Components ─────────────────────────────────────────────────── */
.pill {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-family: var(--f-mono);
  font-size: 12px;
  color: var(--ink-2);
  background: var(--bg);
}
.pill .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }

.card {
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: 14px;
  transition: transform 240ms ease, border-color 240ms ease, background 240ms ease;
}
[data-theme="terminal"] .card { border-radius: 8px; }

.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 12px 18px;
  border-radius: 999px;
  border: 1px solid var(--ink);
  background: var(--ink);
  color: var(--bg);
  font-family: var(--f-sans);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  text-decoration: none;
  transition: transform 160ms ease, background 160ms ease, color 160ms ease;
}
.btn:hover { transform: translateY(-1px); }
.btn.ghost { background: transparent; color: var(--ink); border-color: var(--line); }
[data-theme="terminal"] .btn { border-radius: 6px; font-family: var(--f-mono); font-size: 13px; }
[data-theme="terminal"] .btn.ghost { border-color: var(--accent); color: var(--accent); }

/* ── Utility ────────────────────────────────────────────────────── */
.row { display: flex; }
.col { display: flex; flex-direction: column; }
.gap-8 { gap: 8px; } .gap-12 { gap: 12px; } .gap-16 { gap: 16px; } .gap-24 { gap: 24px; } .gap-32 { gap: 32px; }

/* ================================================================
   NAV
   ================================================================ */
.nav {
  position: sticky; top: 0; z-index: 80;
  backdrop-filter: blur(14px) saturate(140%);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  background: color-mix(in oklch, var(--bg) 82%, transparent);
  border-bottom: 1px solid var(--line);
}
.nav-inner {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 0;
}
.nav-brand {
  display: flex; align-items: center; gap: 12px;
  font-family: var(--f-mono);
  font-size: 13px;
  color: var(--ink);
  text-decoration: none;
}
.nav-brand .glyph {
  width: 28px; height: 28px; border-radius: 8px;
  background: var(--ink); color: var(--bg);
  display: grid; place-items: center;
  font-family: var(--f-serif); font-size: 18px; font-weight: 600;
  letter-spacing: -0.02em;
}
[data-theme="terminal"] .nav-brand .glyph {
  background: var(--accent); color: var(--bg);
  font-family: var(--f-mono); font-size: 13px; border-radius: 4px;
}
.nav-brand .status {
  display: inline-flex; align-items: center; gap: 7px;
  color: var(--muted); font-size: 11px; letter-spacing: .08em; text-transform: uppercase;
}
.nav-brand .status::before {
  content: ""; width: 6px; height: 6px; border-radius: 50%;
  background: oklch(70% 0.16 145);
  box-shadow: 0 0 0 3px oklch(70% 0.16 145 / 0.18);
  animation: pulse 2.4s ease-in-out infinite;
}
@keyframes pulse { 50% { opacity: .5; } }

.nav-links { display: flex; align-items: center; gap: 4px; }
.nav-links a {
  text-decoration: none; color: var(--ink-2);
  padding: 8px 14px; border-radius: 999px;
  font-family: var(--f-mono); font-size: 12px;
}
.nav-links a:hover { background: var(--bg-2); color: var(--ink); }
[data-theme="terminal"] .nav-links a { border-radius: 4px; }

.nav-toggle {
  appearance: none; border: 1px solid var(--line); background: var(--bg-2);
  color: var(--ink-2); border-radius: 999px;
  padding: 7px 12px;
  font-family: var(--f-mono); font-size: 11px;
  cursor: pointer;
}
.nav-toggle:hover { color: var(--ink); border-color: var(--ink-2); }
[data-theme="terminal"] .nav-toggle { border-radius: 4px; }

/* ================================================================
   HERO
   ================================================================ */
.hero { padding-top: clamp(60px, 10vh, 120px); padding-bottom: clamp(50px, 8vh, 100px); }
.hero-grid {
  display: grid;
  grid-template-columns: 1.35fr 1fr;
  gap: clamp(28px, 5vw, 80px);
  align-items: end;
}
.hero-left .eyebrow { margin-bottom: 28px; }
.hero-name {
  font-family: var(--f-serif);
  font-size: clamp(56px, 11vw, 168px);
  line-height: 0.92;
  letter-spacing: -0.025em;
  margin: 0 0 28px;
  color: var(--ink);
  text-wrap: balance;
}
.hero-name .it { font-style: italic; color: var(--accent); }
.hero-name .amp {
  font-style: italic; font-weight: 400; color: var(--muted);
}
[data-theme="terminal"] .hero-name {
  font-size: clamp(40px, 8vw, 120px);
  font-family: var(--f-mono); font-weight: 500;
  letter-spacing: -0.04em;
}
[data-theme="terminal"] .hero-name .it { font-style: normal; }
[data-theme="terminal"] .hero-name::before {
  content: "$ "; color: var(--muted); font-style: normal;
}

.hero-sub {
  font-size: clamp(18px, 1.6vw, 22px);
  line-height: 1.45;
  color: var(--ink-2);
  max-width: 56ch;
  margin: 0 0 36px;
}
.hero-sub b { color: var(--ink); font-weight: 500; }

.hero-meta { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 36px; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; }

.hero-right {
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 18px;
  align-self: stretch;
}
.hero-card {
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 22px;
  position: relative;
  overflow: hidden;
}
[data-theme="terminal"] .hero-card { border-radius: 8px; }
.hero-card .corner {
  position: absolute; top: 10px; right: 12px;
  font-family: var(--f-mono); font-size: 10px;
  color: var(--muted); letter-spacing: .12em; text-transform: uppercase;
}

.stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 4px; }
.stat { padding: 14px 4px; }
.stat .n {
  font-family: var(--f-serif);
  font-size: 56px; line-height: 1;
  color: var(--ink); letter-spacing: -0.02em;
}
.stat .n .unit { font-size: 20px; color: var(--muted); margin-left: 2px; }
.stat .lbl {
  font-family: var(--f-mono); font-size: 11px; color: var(--muted);
  text-transform: uppercase; letter-spacing: .1em; margin-top: 8px;
}
[data-theme="terminal"] .stat .n { font-family: var(--f-mono); font-weight: 500; }

.now-card { display: grid; grid-template-rows: auto 1fr auto; gap: 14px; }
.now-card h4 {
  margin: 0; font-family: var(--f-mono); font-size: 11px;
  color: var(--muted); letter-spacing: .14em; text-transform: uppercase;
  display: flex; align-items: center; gap: 8px;
}
.now-card h4 .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
.now-card p { margin: 0; color: var(--ink-2); line-height: 1.5; font-size: 14.5px; }
.now-card .ticker {
  font-family: var(--f-mono); font-size: 11.5px;
  color: var(--ink); border-top: 1px dashed var(--line);
  padding-top: 12px;
  display: flex; justify-content: space-between;
}
.now-card .ticker .v { color: var(--accent); }

.ai-strip {
  margin-top: 56px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--bg-2);
  padding: 18px 22px;
  display: flex; gap: 18px; align-items: center;
  font-family: var(--f-mono); font-size: 13px;
}
[data-theme="terminal"] .ai-strip { border-radius: 6px; }
.ai-strip .bullet {
  width: 10px; height: 10px; border-radius: 50%;
  background: var(--accent); flex: 0 0 auto;
  box-shadow: 0 0 0 4px var(--accent-soft);
}
.ai-strip .ai-label { color: var(--muted); }
.ai-strip .typer { color: var(--ink); }
.ai-strip .caret {
  display: inline-block; width: 8px; height: 14px;
  background: var(--ink); vertical-align: -2px; margin-left: 2px;
  animation: blink 1.05s steps(2,end) infinite;
}
@keyframes blink { 50% { opacity: 0; } }

/* ================================================================
   TIMELINE
   ================================================================ */
.tl { background: var(--bg); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.tl-head {
  display: flex; justify-content: space-between; align-items: flex-end;
  gap: 24px; margin-bottom: 56px; flex-wrap: wrap;
}
.tl-head h2 {
  font-family: var(--f-serif); font-weight: 400;
  font-size: clamp(36px, 5vw, 64px); line-height: 1.02;
  letter-spacing: -0.02em;
  margin: 14px 0 0; max-width: 18ch;
  color: var(--ink);
}
.tl-head h2 em { color: var(--accent); font-style: italic; }
[data-theme="terminal"] .tl-head h2 { font-family: var(--f-mono); font-weight: 500; }
[data-theme="terminal"] .tl-head h2 em { font-style: normal; }
.tl-head .legend {
  display: flex; gap: 18px; align-items: center;
  font-family: var(--f-mono); font-size: 11px; color: var(--muted);
}
.tl-head .legend span { display: inline-flex; align-items: center; gap: 6px; }
.tl-head .legend .sw { width: 12px; height: 8px; border-radius: 2px; }

.tl-chart {
  position: relative;
  display: grid;
  grid-template-columns: 80px 1fr;
  gap: 18px;
  align-items: stretch;
}
.tl-years {
  position: absolute; left: 98px; right: 0; top: 0;
  height: calc(100% - 60px);
  display: flex; pointer-events: none;
  z-index: 0;
}
.tl-yr {
  flex: 1 0 0; position: relative;
  border-left: 1px dashed var(--line);
}
.tl-yr:last-child { border-right: 1px dashed var(--line); }
.tl-yr .yr-lbl {
  position: absolute; bottom: -28px; left: -14px;
  font-family: var(--f-mono); font-size: 10.5px;
  color: var(--muted); letter-spacing: .04em;
}
.tl-yr[data-now="true"] { background: var(--accent-soft); }

.tl-rows {
  position: relative; z-index: 1;
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: 80px 1fr;
  gap: 14px 18px;
  align-items: center;
  padding-bottom: 60px;
}
.tl-role-label {
  font-family: var(--f-mono); font-size: 11px;
  color: var(--muted); text-align: right;
  letter-spacing: .04em;
}
.tl-track { position: relative; height: 44px; }
.tl-bar {
  position: absolute; top: 4px; bottom: 4px;
  border-radius: 8px;
  background: var(--ink);
  color: var(--bg);
  padding: 0 14px;
  display: flex; align-items: center;
  font-family: var(--f-mono); font-size: 12px;
  letter-spacing: .01em;
  cursor: default;
  transition: transform 200ms ease, background 200ms ease;
  white-space: nowrap; overflow: hidden;
}
.tl-bar:hover { transform: translateY(-1px); }
.tl-bar.alt { background: var(--bg-3); color: var(--ink); border: 1px solid var(--line); }
[data-theme="terminal"] .tl-bar { border-radius: 4px; }

.tl-overlay {
  position: relative; height: 44px;
  margin-top: 8px;
  background: repeating-linear-gradient(45deg, transparent 0 6px, var(--accent-soft) 6px 7px);
  border-radius: 8px;
  border: 1px dashed var(--accent);
  display: flex; align-items: center; justify-content: flex-end;
  padding: 0 14px;
  font-family: var(--f-mono); font-size: 12px;
  color: var(--accent);
}
[data-theme="terminal"] .tl-overlay { border-radius: 4px; }
.tl-overlay::before {
  content: ""; position: absolute; left: 0; top: 50%;
  width: 14px; height: 1px; background: var(--accent);
  transform: translateY(-0.5px);
}

.tl-callouts {
  margin-top: 40px;
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px;
}
.tl-callouts .card { padding: 22px; }
.tl-callouts .card .yr {
  font-family: var(--f-mono); font-size: 11px; color: var(--muted);
  letter-spacing: .12em; text-transform: uppercase; margin-bottom: 8px;
}
.tl-callouts .card h4 {
  margin: 0 0 8px; font-family: var(--f-serif); font-weight: 400;
  font-size: 24px; line-height: 1.15; color: var(--ink);
  letter-spacing: -.01em;
}
[data-theme="terminal"] .tl-callouts .card h4 { font-family: var(--f-mono); font-weight: 500; font-size: 18px; }
.tl-callouts .card p { margin: 0; font-size: 14px; color: var(--ink-2); line-height: 1.5; }

/* ================================================================
   SKILLS
   ================================================================ */
.sk { background: var(--bg); }
.sk-head { margin-bottom: 56px; }
.sk-head h2 {
  font-family: var(--f-serif); font-weight: 400;
  font-size: clamp(36px, 5vw, 64px); line-height: 1.02;
  letter-spacing: -0.02em; margin: 14px 0 16px;
  color: var(--ink); max-width: 22ch;
}
.sk-head h2 em { color: var(--accent); font-style: italic; }
[data-theme="terminal"] .sk-head h2 { font-family: var(--f-mono); font-weight: 500; }
[data-theme="terminal"] .sk-head h2 em { font-style: normal; }
.sk-head p { font-size: 16px; color: var(--ink-2); max-width: 60ch; margin: 0; }

.sk-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 18px;
}
.sk-card {
  border: 1px solid var(--line);
  background: var(--bg-2);
  border-radius: 16px;
  padding: 22px;
  position: relative;
}
[data-theme="terminal"] .sk-card { border-radius: 6px; }
.sk-card .h {
  display: flex; align-items: baseline; justify-content: space-between;
  margin-bottom: 18px;
}
.sk-card .h .title {
  font-family: var(--f-mono); font-size: 11px;
  color: var(--muted); letter-spacing: .14em; text-transform: uppercase;
}
.sk-card .h .badge {
  font-family: var(--f-mono); font-size: 11px;
  color: var(--accent); letter-spacing: .04em;
}

.sk-row {
  display: flex; align-items: center; gap: 14px;
  padding: 12px 0;
  border-top: 1px dashed var(--line);
}
.sk-row:first-of-type { border-top: 0; }
.sk-row .name {
  flex: 0 0 38%;
  font-family: var(--f-sans); font-size: 14.5px; color: var(--ink);
  font-weight: 500;
}
[data-theme="terminal"] .sk-row .name { font-family: var(--f-mono); font-size: 13px; }
.sk-row .bar {
  position: relative; height: 6px;
  background: var(--bg-3); border-radius: 999px; flex: 1 1 auto;
  overflow: hidden;
}
.sk-row .bar .fill {
  position: absolute; top: 0; bottom: 0; left: 0;
  background: var(--ink); border-radius: 999px;
  transform-origin: left center;
  animation: skfill 1.2s cubic-bezier(.22,.7,.2,1) both;
}
.sk-row .bar .fill.accent { background: var(--accent); }
@keyframes skfill { from { transform: scaleX(0); } }
.sk-row .yrs {
  flex: 0 0 56px; text-align: right;
  font-family: var(--f-mono); font-size: 11.5px; color: var(--muted);
}

.sk-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.sk-chip {
  border: 1px solid var(--line);
  background: var(--bg);
  border-radius: 999px;
  padding: 7px 12px;
  font-family: var(--f-mono); font-size: 12px;
  color: var(--ink-2);
}
[data-theme="terminal"] .sk-chip { border-radius: 4px; }

.sk-philosophy {
  grid-column: span 12;
  margin-top: 24px;
  border-top: 1px dashed var(--line);
  padding-top: 36px;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 24px;
}
.sk-philosophy .p {
  font-family: var(--f-serif); font-size: clamp(20px, 2vw, 26px);
  line-height: 1.32; color: var(--ink);
  letter-spacing: -0.005em;
}
.sk-philosophy .p::before {
  content: ""; display: block; width: 28px; height: 2px;
  background: var(--accent); margin-bottom: 14px;
}
[data-theme="terminal"] .sk-philosophy .p { font-family: var(--f-mono); font-size: 15px; font-weight: 400; }
.sk-philosophy .p span { color: var(--muted); }

/* ================================================================
   EXPERIMENTS (AI LAB)
   ================================================================ */
.ex { background: var(--bg-2); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.ex-head {
  display: flex; justify-content: space-between; align-items: flex-end;
  gap: 24px; margin-bottom: 56px; flex-wrap: wrap;
}
.ex-head h2 {
  font-family: var(--f-serif); font-weight: 400;
  font-size: clamp(36px, 5vw, 64px); line-height: 1.02;
  letter-spacing: -0.02em; margin: 14px 0 0; max-width: 22ch;
  color: var(--ink);
}
.ex-head h2 em { color: var(--accent); font-style: italic; }
[data-theme="terminal"] .ex-head h2 { font-family: var(--f-mono); font-weight: 500; }
[data-theme="terminal"] .ex-head h2 em { font-style: normal; }

.ex-grid {
  display: grid; grid-template-columns: repeat(12, 1fr);
  gap: 18px;
}
.ex-card {
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 18px;
  overflow: hidden;
  display: flex; flex-direction: column;
  transition: transform 220ms ease, border-color 220ms ease;
}
.ex-card:hover { transform: translateY(-3px); border-color: var(--ink-2); }
[data-theme="terminal"] .ex-card { border-radius: 8px; }
.ex-card .head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line);
  font-family: var(--f-mono); font-size: 11px;
  color: var(--muted); letter-spacing: .08em; text-transform: uppercase;
}
.ex-card .head .status {
  display: inline-flex; align-items: center; gap: 6px; color: var(--accent);
}
.ex-card .head .status .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
.ex-card .body { padding: 20px 22px 0; }
.ex-card h3 {
  font-family: var(--f-serif); font-weight: 400;
  font-size: clamp(22px, 2vw, 28px); line-height: 1.15;
  letter-spacing: -.01em; margin: 0 0 10px;
  color: var(--ink);
}
[data-theme="terminal"] .ex-card h3 { font-family: var(--f-mono); font-weight: 500; font-size: 20px; }
.ex-card p { margin: 0 0 16px; color: var(--ink-2); font-size: 14.5px; line-height: 1.55; }
.ex-card .demo {
  margin: 0 22px 22px;
  border-radius: 12px;
  background: var(--bg-2);
  border: 1px solid var(--line);
  padding: 14px 16px;
  font-family: var(--f-mono); font-size: 12px;
  color: var(--ink-2);
  flex: 1;
}
[data-theme="terminal"] .ex-card .demo { border-radius: 4px; background: oklch(10% 0.024 252); }
.ex-card .demo .ln { display: block; padding: 2px 0; white-space: pre-wrap; word-break: break-word; }
.ex-card .demo .pr { color: var(--accent); }
.ex-card .demo .mu { color: var(--muted); }
.ex-card .demo .ok { color: oklch(70% 0.15 145); }
.ex-card .foot {
  padding: 12px 18px;
  border-top: 1px dashed var(--line);
  display: flex; justify-content: space-between; align-items: center;
  font-family: var(--f-mono); font-size: 11px;
  color: var(--muted); letter-spacing: .04em;
}
.ex-card .foot a {
  color: var(--ink); text-decoration: none;
  display: inline-flex; align-items: center; gap: 6px;
}
.ex-card .foot a:hover { color: var(--accent); }

/* ================================================================
   WRITING
   ================================================================ */
.wr { background: var(--bg); }
.wr-head {
  margin-bottom: 56px; display: flex; justify-content: space-between;
  align-items: flex-end; flex-wrap: wrap; gap: 20px;
}
.wr-head h2 {
  font-family: var(--f-serif); font-weight: 400;
  font-size: clamp(36px, 5vw, 64px); line-height: 1.02;
  letter-spacing: -0.02em; margin: 14px 0 0; max-width: 22ch;
  color: var(--ink);
}
.wr-head h2 em { color: var(--accent); font-style: italic; }
[data-theme="terminal"] .wr-head h2 { font-family: var(--f-mono); font-weight: 500; }
[data-theme="terminal"] .wr-head h2 em { font-style: normal; }

.wr-feed {
  display: grid; grid-template-columns: 1fr;
  border-top: 1px solid var(--line);
}
.wr-row {
  display: grid;
  grid-template-columns: 110px 1fr 220px;
  gap: 32px;
  padding: 28px 0;
  border-bottom: 1px solid var(--line);
  align-items: baseline;
  transition: background 200ms ease, padding 220ms ease;
  text-decoration: none;
}
.wr-row:hover { background: var(--bg-2); padding-left: 12px; padding-right: 12px; }
.wr-row .date {
  font-family: var(--f-mono); font-size: 11px; color: var(--muted);
  letter-spacing: .08em; text-transform: uppercase;
}
.wr-row .title {
  font-family: var(--f-serif); font-weight: 400;
  font-size: clamp(22px, 2.6vw, 32px); line-height: 1.18;
  letter-spacing: -.01em; color: var(--ink);
  text-decoration: none;
}
[data-theme="terminal"] .wr-row .title { font-family: var(--f-mono); font-weight: 500; font-size: 18px; }
.wr-row .title em { color: var(--accent); font-style: italic; }
.wr-row .title:hover em { text-decoration: underline; }
.wr-row .dek {
  font-family: var(--f-sans); font-size: 14px; color: var(--ink-2);
  margin-top: 8px; max-width: 56ch; line-height: 1.55;
}
.wr-row .meta {
  text-align: right;
  font-family: var(--f-mono); font-size: 11px;
  color: var(--muted); letter-spacing: .04em;
  display: flex; flex-direction: column; gap: 6px; align-items: flex-end;
}
.wr-row .meta .tag { color: var(--accent); }

.wr-foot {
  margin-top: 36px;
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 16px;
  font-family: var(--f-mono); font-size: 12px; color: var(--muted);
}

/* ================================================================
   CONTACT
   ================================================================ */
.ct { background: var(--bg-2); border-top: 1px solid var(--line); }
.ct-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: clamp(28px, 5vw, 80px);
  align-items: start;
}
.ct h2 {
  font-family: var(--f-serif); font-weight: 400;
  font-size: clamp(48px, 7vw, 110px); line-height: 0.96;
  letter-spacing: -0.025em; margin: 14px 0 28px;
  color: var(--ink); max-width: 14ch;
  text-wrap: balance;
}
.ct h2 em { color: var(--accent); font-style: italic; }
[data-theme="terminal"] .ct h2 { font-family: var(--f-mono); font-weight: 500; }
[data-theme="terminal"] .ct h2 em { font-style: normal; }
.ct .lead {
  font-size: 18px; color: var(--ink-2); max-width: 50ch; margin: 0 0 36px;
  line-height: 1.55;
}
.ct .email {
  display: inline-flex; align-items: center; gap: 14px;
  padding: 18px 22px;
  border: 1px solid var(--ink);
  border-radius: 999px;
  background: var(--ink);
  color: var(--bg);
  font-family: var(--f-mono); font-size: 14px;
  text-decoration: none;
  transition: transform 200ms ease;
}
.ct .email:hover { transform: translateY(-1px); }
[data-theme="terminal"] .ct .email { border-radius: 6px; }

.ct-card {
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 28px;
}
[data-theme="terminal"] .ct-card { border-radius: 8px; }
.ct-card h4 {
  margin: 0 0 18px; font-family: var(--f-mono); font-size: 11px;
  color: var(--muted); letter-spacing: .14em; text-transform: uppercase;
}

.ct-list { display: grid; gap: 0; }
.ct-list .li {
  display: grid; grid-template-columns: 110px 1fr;
  gap: 18px; padding: 14px 0;
  border-top: 1px dashed var(--line);
  align-items: center;
}
.ct-list .li:first-child { border-top: 0; }
.ct-list .k { font-family: var(--f-mono); font-size: 11px; color: var(--muted); letter-spacing: .04em; text-transform: uppercase; }
.ct-list .v { font-family: var(--f-mono); font-size: 13.5px; color: var(--ink); }
.ct-list a.v { text-decoration: none; }
.ct-list a.v:hover { color: var(--accent); }

.ct-availability {
  margin-top: 22px;
  padding: 18px;
  border: 1px dashed var(--accent);
  border-radius: 12px;
  background: var(--accent-soft);
}
[data-theme="terminal"] .ct-availability { border-radius: 4px; }
.ct-availability .t {
  font-family: var(--f-mono); font-size: 11px;
  color: var(--accent); letter-spacing: .14em; text-transform: uppercase;
  margin-bottom: 8px;
}
.ct-availability p { margin: 0; font-size: 14.5px; color: var(--ink); line-height: 1.5; }

/* ── Contact form ────────────────────────────────────────────────── */
.ct-form {
  margin-top: 28px;
  display: grid;
  gap: 14px;
  max-width: 540px;
}
.ct-form-head {
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 4px;
}
.ct-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 640px) { .ct-row { grid-template-columns: 1fr; } }

.ct-field { display: grid; gap: 6px; }
.ct-label {
  font-family: var(--f-mono);
  font-size: 10.5px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted);
}
.ct-input, .ct-textarea {
  font-family: var(--f-sans);
  font-size: 15px;
  color: var(--ink);
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 11px 14px;
  width: 100%;
  outline: none;
  transition: border-color .15s, box-shadow .15s, background .15s;
  -webkit-appearance: none;
  appearance: none;
}
.ct-textarea {
  min-height: 140px;
  resize: vertical;
  line-height: 1.5;
}
.ct-input::placeholder, .ct-textarea::placeholder { color: oklch(60% 0 0 / 0.5); }
.ct-input:hover, .ct-textarea:hover { border-color: oklch(70% 0.018 75); }
.ct-input:focus, .ct-textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
  background: var(--bg);
}
[data-theme="terminal"] .ct-input,
[data-theme="terminal"] .ct-textarea { border-radius: 4px; background: var(--bg-2); }

.ct-actions {
  display: flex; align-items: center; gap: 14px;
  margin-top: 4px;
}
.ct-submit {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--f-sans);
  font-size: 14.5px;
  font-weight: 500;
  letter-spacing: -0.005em;
  color: var(--bg);
  background: var(--ink);
  border: 1px solid var(--ink);
  border-radius: 999px;
  padding: 13px 22px;
  cursor: pointer;
  transition: transform .15s, opacity .15s;
}
.ct-submit:hover:not(:disabled) { transform: translateY(-1px); }
.ct-submit:disabled { opacity: 0.55; cursor: progress; }
[data-theme="terminal"] .ct-submit { border-radius: 6px; }

.ct-meta {
  font-family: var(--f-mono);
  font-size: 11px;
  color: var(--muted);
  letter-spacing: .04em;
}
.ct-error {
  font-family: var(--f-sans);
  font-size: 13px;
  color: var(--accent);
  margin-top: 2px;
}

.ct-success {
  margin-top: 28px;
  display: grid;
  gap: 10px;
  padding: 22px 24px;
  max-width: 540px;
  border: 1px solid var(--accent);
  border-radius: 14px;
  background: var(--accent-soft);
  color: var(--ink);
}
[data-theme="terminal"] .ct-success { border-radius: 6px; }
.ct-success .h {
  display: flex; align-items: center; gap: 10px;
  font-family: var(--f-serif);
  font-size: 22px;
  letter-spacing: -0.01em;
  line-height: 1.05;
}
.ct-success .h .dot {
  width: 22px; height: 22px; border-radius: 999px;
  background: var(--accent); color: var(--bg);
  display: inline-flex; align-items: center; justify-content: center;
  font-family: var(--f-sans); font-weight: 700; font-size: 12px;
  flex-shrink: 0;
}
.ct-success p {
  margin: 0;
  font-size: 14.5px; color: var(--ink-2); line-height: 1.55;
  font-family: var(--f-sans);
}

/* Honeypot — visually hidden from real users, still in the DOM for bots. */
.ct-hp {
  position: absolute !important;
  width: 1px; height: 1px;
  margin: -1px; padding: 0;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* ── Footer ─────────────────────────────────────────────────────── */
.footer {
  margin-top: clamp(60px, 10vh, 120px);
  padding-top: 32px;
  border-top: 1px solid var(--line);
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 16px;
  font-family: var(--f-mono); font-size: 11px;
  color: var(--muted); letter-spacing: .04em;
}
.footer .built { display: inline-flex; gap: 8px; align-items: center; }
.footer .built .accent { color: var(--accent); }
.footer a { color: var(--ink-2); text-decoration: none; }
.footer a:hover { color: var(--ink); }
.footer-links { display: inline-flex; gap: 18px; }

/* ================================================================
   CMDK (Command Palette)
   ================================================================ */
.cmdk-backdrop {
  position: fixed; inset: 0; background: oklch(0% 0 0 / 0.45); backdrop-filter: blur(6px);
  display: flex; align-items: flex-start; justify-content: center; padding-top: 12vh;
  z-index: 200;
}
.cmdk {
  width: min(640px, 92vw);
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: 0 30px 80px oklch(10% 0.02 252 / 0.4);
  overflow: hidden;
  font-family: var(--f-sans);
}
.cmdk-input {
  display: flex; align-items: center; gap: 10px;
  padding: 16px 18px;
  border-bottom: 1px solid var(--line);
  font-family: var(--f-mono);
}
.cmdk-input svg { width: 16px; height: 16px; color: var(--muted); }
.cmdk-input input {
  flex: 1; border: 0; outline: 0; background: transparent;
  font-family: var(--f-mono); font-size: 14px; color: var(--ink);
}
.cmdk-input kbd {
  padding: 2px 6px; border-radius: 4px;
  border: 1px solid var(--line); background: var(--bg-2);
  font-size: 10px; color: var(--muted);
}
.cmdk-list {
  max-height: 60vh; overflow: auto;
  padding: 8px;
}
.cmdk-group {
  font-family: var(--f-mono); font-size: 10px;
  color: var(--muted); letter-spacing: .12em; text-transform: uppercase;
  padding: 12px 10px 6px;
}
.cmdk-item {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 12px; border-radius: 8px;
  font-family: var(--f-sans); font-size: 14px;
  color: var(--ink); cursor: pointer;
  text-decoration: none;
}
.cmdk-item:hover, .cmdk-item.active { background: var(--bg-2); }
.cmdk-item .ico {
  width: 28px; height: 28px; border-radius: 6px;
  display: grid; place-items: center;
  background: var(--bg-3); color: var(--ink);
  font-family: var(--f-mono); font-size: 12px;
}
.cmdk-item .item-meta { margin-left: auto; color: var(--muted); font-family: var(--f-mono); font-size: 11px; }
[data-theme="terminal"] .cmdk-item { border-radius: 4px; font-family: var(--f-mono); font-size: 13px; }
[data-theme="terminal"] .cmdk-item .ico { border-radius: 3px; }

/* ================================================================
   BLOG POST PAGE
   ================================================================ */
.blog-post { max-width: 760px; margin: 0 auto; }
.blog-post .post-back {
  margin-bottom: 32px;
}
.blog-post .post-back a {
  color: var(--muted); font-family: var(--f-mono); font-size: 13px;
  text-decoration: none;
}
.blog-post .post-back a:hover { color: var(--accent); }
.blog-post .post-header { margin-bottom: 40px; }
.blog-post .post-title {
  font-family: var(--f-serif); font-weight: 400;
  font-size: clamp(32px, 5vw, 52px); line-height: 1.08;
  letter-spacing: -0.02em; margin: 0 0 16px;
  color: var(--ink);
}
[data-theme="terminal"] .blog-post .post-title { font-family: var(--f-mono); font-weight: 500; }
.blog-post .post-date {
  font-family: var(--f-mono); font-size: 12px; color: var(--muted);
  letter-spacing: .08em; text-transform: uppercase;
}
.blog-post .post-tags {
  display: flex; flex-wrap: wrap; gap: 6px; margin-top: 16px;
}

.blog-post .post-body { line-height: 1.7; color: var(--ink-2); }
.blog-post .post-body h1,
.blog-post .post-body h2,
.blog-post .post-body h3 {
  font-family: var(--f-serif); font-weight: 400;
  color: var(--ink); margin: 2em 0 0.75em; line-height: 1.2;
}
[data-theme="terminal"] .blog-post .post-body h1,
[data-theme="terminal"] .blog-post .post-body h2,
[data-theme="terminal"] .blog-post .post-body h3 { font-family: var(--f-mono); font-weight: 500; }
.blog-post .post-body h1 { font-size: 1.8em; }
.blog-post .post-body h2 { font-size: 1.4em; }
.blog-post .post-body h3 { font-size: 1.15em; }
.blog-post .post-body p { margin: 0 0 1.25em; }
.blog-post .post-body strong { color: var(--ink); font-weight: 600; }
.blog-post .post-body a { color: var(--accent); }
.blog-post .post-body a:hover { text-decoration: underline; }
.blog-post .post-body code {
  font-family: var(--f-mono); font-size: 0.875em;
  background: var(--bg-2); border: 1px solid var(--line);
  padding: 2px 6px; border-radius: 4px;
}
.blog-post .post-body pre {
  background: var(--bg-2); border: 1px solid var(--line);
  border-radius: 10px; padding: 18px 20px;
  overflow-x: auto; margin: 0 0 1.5em;
  font-family: var(--f-mono); font-size: 13px;
  line-height: 1.6;
}
.blog-post .post-body pre code {
  background: none; border: 0; padding: 0; border-radius: 0;
}
.blog-post .post-body ul, .blog-post .post-body ol {
  padding-left: 1.5em; margin: 0 0 1.25em;
}
.blog-post .post-body li { margin-bottom: 0.4em; }
.blog-post .post-body hr {
  border: 0; height: 1px; background: var(--line); margin: 2em 0;
}
.blog-post .post-body blockquote {
  border-left: 3px solid var(--accent);
  padding-left: 1em; margin: 1.5em 0;
  color: var(--ink-2); font-style: italic;
}

/* ================================================================
   RESPONSIVE
   ================================================================ */
@media (max-width: 980px) {
  .sk-grid > .sk-card { grid-column: span 12 !important; }
  .sk-philosophy { grid-template-columns: 1fr; }
  .ex-card { grid-column: span 12 !important; }
  .ct-grid { grid-template-columns: 1fr; }
}

@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-right { grid-template-columns: 1fr 1fr; grid-template-rows: auto; gap: 12px; }
  .hero-card { padding: 18px; }
}

@media (max-width: 760px) {
  .nav-links { display: none; }
  .tl-callouts { grid-template-columns: 1fr; }
  .tl-bar { font-size: 10.5px; padding: 0 8px; }
  .tl-role-label { font-size: 10px; }
  .wr-row { grid-template-columns: 1fr; gap: 8px; }
  .wr-row .meta { text-align: left; align-items: flex-start; flex-direction: row; gap: 14px; }
}

@media (max-width: 720px) {
  section { padding: 72px 0; }
}

@media (max-width: 600px) {
  .hero-right { grid-template-columns: 1fr; }
}

/* ================================================================
   THEMES — Extended Palette
   ================================================================ */

/* ── Theme: glass (glassmorphism) ──────────────────────────────── */
[data-theme="glass"] {
  --bg: oklch(13% 0.06 278);
  --bg-2: oklch(18% 0.07 282);
  --bg-3: oklch(23% 0.08 286);
  --ink: oklch(96% 0.005 280);
  --ink-2: oklch(82% 0.01 280);
  --muted: oklch(65% 0.018 275);
  --line: oklch(75% 0.06 295 / 0.22);
  --accent: oklch(82% 0.22 340);
  --accent-soft: oklch(82% 0.22 340 / 0.15);
  --shadow: 0 0 0 1px oklch(80% 0.08 295 / 0.14),
            0 16px 48px oklch(6% 0.04 280 / 0.55),
            0 0 40px oklch(70% 0.18 340 / 0.06);
  color-scheme: dark;
}

[data-theme="glass"] body {
  background:
    radial-gradient(ellipse 80% 60% at 20% 40%, oklch(40% 0.2 295 / 0.14) 0%, transparent 70%),
    radial-gradient(ellipse 70% 50% at 80% 20%, oklch(45% 0.2 345 / 0.12) 0%, transparent 60%),
    radial-gradient(ellipse 60% 50% at 60% 85%, oklch(38% 0.18 255 / 0.12) 0%, transparent 55%),
    oklch(13% 0.06 278);
  background-attachment: fixed;
}

[data-theme="glass"] body::before { opacity: 0; }

[data-theme="glass"] .card {
  background: oklch(22% 0.06 282 / 0.35);
  backdrop-filter: blur(20px) saturate(160%);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
  border-color: oklch(80% 0.1 295 / 0.18);
  border-radius: 16px;
}

[data-theme="glass"] .hero-card {
  background: oklch(22% 0.06 282 / 0.3);
  backdrop-filter: blur(16px) saturate(150%);
  -webkit-backdrop-filter: blur(16px) saturate(150%);
  border-color: oklch(80% 0.1 295 / 0.16);
  border-radius: 16px;
}

[data-theme="glass"] .nav {
  background: oklch(14% 0.055 278 / 0.65);
  backdrop-filter: blur(24px) saturate(180%);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
  border-bottom-color: oklch(75% 0.08 295 / 0.14);
}

[data-theme="glass"] .theme-panel {
  background: oklch(18% 0.07 282 / 0.75);
  backdrop-filter: blur(28px);
  -webkit-backdrop-filter: blur(28px);
  border-color: oklch(75% 0.06 295 / 0.18);
}

/* ── Theme: neon (cyberpunk) ───────────────────────────────────── */
[data-theme="neon"] {
  --bg: oklch(8% 0.015 275);
  --bg-2: oklch(12% 0.022 272);
  --bg-3: oklch(16% 0.028 272);
  --ink: oklch(88% 0.06 148);
  --ink-2: oklch(72% 0.05 148);
  --muted: oklch(52% 0.03 272);
  --line: oklch(42% 0.18 332 / 0.4);
  --accent: oklch(75% 0.28 332);
  --accent-soft: oklch(75% 0.28 332 / 0.12);
  --shadow: 0 0 0 1px oklch(45% 0.18 332 / 0.35),
            0 0 24px oklch(65% 0.25 332 / 0.12);
  color-scheme: dark;
}

[data-theme="neon"] body {
  background:
    linear-gradient(135deg, oklch(12% 0.04 332 / 0.18) 0%, transparent 35%),
    linear-gradient(225deg, oklch(12% 0.04 148 / 0.14) 0%, transparent 35%),
    oklch(8% 0.015 275);
  background-attachment: fixed;
}

[data-theme="neon"] body::before { opacity: 0; }
[data-theme="neon"] .card { border-radius: 4px; border-color: oklch(42% 0.18 332 / 0.38); }
[data-theme="neon"] .hero-card { border-radius: 4px; border-color: oklch(42% 0.18 332 / 0.38); }
[data-theme="neon"] .nav { border-bottom-color: oklch(42% 0.18 332 / 0.4); }
[data-theme="neon"] .nav-brand .glyph {
  background: var(--accent); color: oklch(8% 0.015 275);
  font-family: var(--f-mono); font-size: 13px; border-radius: 2px;
}
[data-theme="neon"] .serif { font-family: var(--f-mono); font-weight: 400; }
[data-theme="neon"] .hero-name {
  font-family: var(--f-mono);
  font-size: clamp(36px, 7vw, 110px);
  letter-spacing: -0.04em;
}
[data-theme="neon"] .hero-name::before { content: "> "; color: var(--accent); }
[data-theme="neon"] .hero-name .it { font-style: normal; color: var(--accent); }
[data-theme="neon"] .btn { border-radius: 2px; font-family: var(--f-mono); }
[data-theme="neon"] .pill { border-radius: 2px; }

/* ── Theme: minimal (monochrome) ───────────────────────────────── */
[data-theme="minimal"] {
  --bg: oklch(99% 0 0);
  --bg-2: oklch(96% 0 0);
  --bg-3: oklch(92% 0 0);
  --ink: oklch(8% 0 0);
  --ink-2: oklch(24% 0 0);
  --muted: oklch(52% 0 0);
  --line: oklch(82% 0 0);
  --accent: oklch(14% 0 0);
  --accent-soft: oklch(14% 0 0 / 0.07);
  --shadow: 0 1px 0 oklch(86% 0 0), 0 6px 20px oklch(50% 0 0 / 0.05);
  color-scheme: light;
}

[data-theme="minimal"] body::before { opacity: 0; }
[data-theme="minimal"] .card { border-radius: 0; border-color: oklch(84% 0 0); }
[data-theme="minimal"] .hero-card { border-radius: 0; border-color: oklch(84% 0 0); }
[data-theme="minimal"] .nav {
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  background: oklch(99% 0 0);
  border-bottom-color: oklch(82% 0 0);
}
[data-theme="minimal"] .btn { border-radius: 0; }
[data-theme="minimal"] .pill { border-radius: 0; }
[data-theme="minimal"] .nav-links a { border-radius: 0; }

/* ── Theme: aurora (night sky) ─────────────────────────────────── */
[data-theme="aurora"] {
  --bg: oklch(11% 0.025 200);
  --bg-2: oklch(15% 0.034 208);
  --bg-3: oklch(19% 0.04 216);
  --ink: oklch(94% 0.008 190);
  --ink-2: oklch(78% 0.012 190);
  --muted: oklch(60% 0.018 200);
  --line: oklch(35% 0.046 208 / 0.6);
  --accent: oklch(80% 0.22 158);
  --accent-soft: oklch(80% 0.22 158 / 0.15);
  --shadow: 0 0 0 1px oklch(38% 0.046 208 / 0.5),
            0 24px 48px oklch(6% 0.025 210 / 0.65);
  color-scheme: dark;
}

[data-theme="aurora"] body {
  background:
    radial-gradient(ellipse 70% 45% at 25% 25%, oklch(35% 0.2 158 / 0.14) 0%, transparent 60%),
    radial-gradient(ellipse 60% 40% at 75% 75%, oklch(35% 0.18 262 / 0.1) 0%, transparent 55%),
    radial-gradient(ellipse 50% 35% at 55% 10%, oklch(28% 0.14 200 / 0.12) 0%, transparent 50%),
    oklch(11% 0.025 200);
  background-attachment: fixed;
}

[data-theme="aurora"] body::before { opacity: 0; }
[data-theme="aurora"] .card { border-radius: 10px; }
[data-theme="aurora"] .hero-card { border-radius: 10px; }
[data-theme="aurora"] .nav { border-bottom-color: oklch(35% 0.046 208 / 0.5); }

/* ================================================================
   THEME CHOOSER PANEL
   ================================================================ */

.theme-chooser {
  position: relative;
  display: inline-flex;
  align-items: center;
}

.theme-overlay {
  position: fixed;
  inset: 0;
  z-index: 99;
  background: transparent;
  cursor: default;
}

.theme-panel {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  z-index: 100;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 10px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  min-width: 256px;
  box-shadow: var(--shadow);
  animation: theme-panel-in 180ms cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes theme-panel-in {
  from { opacity: 0; transform: translateY(-8px) scale(0.96); }
  to   { opacity: 1; transform: none; }
}

[data-theme="terminal"] .theme-panel,
[data-theme="neon"] .theme-panel { border-radius: 6px; }
[data-theme="minimal"] .theme-panel { border-radius: 0; }

.theme-option {
  appearance: none;
  border: 1px solid transparent;
  background: transparent;
  border-radius: 10px;
  padding: 10px 10px 9px;
  cursor: pointer;
  text-align: left;
  width: 100%;
  transition: border-color 140ms ease, background 140ms ease;
  color: var(--ink);
}

.theme-option:hover {
  background: var(--bg-3);
  border-color: var(--line);
}

.theme-option.active {
  border-color: var(--accent);
  background: var(--accent-soft);
}

[data-theme="terminal"] .theme-option,
[data-theme="neon"] .theme-option,
[data-theme="glass"] .theme-option { border-radius: 4px; }
[data-theme="minimal"] .theme-option { border-radius: 0; }

.theme-option-swatches {
  display: flex;
  gap: 3px;
  margin-bottom: 7px;
}

.theme-option-swatch {
  flex: 1;
  height: 12px;
  border-radius: 2px;
}

[data-theme="minimal"] .theme-option-swatch { border-radius: 0; }

.theme-option-label {
  display: block;
  font-family: var(--f-mono);
  font-size: 11px;
  font-weight: 500;
  color: var(--ink);
  letter-spacing: 0.02em;
}

.theme-option-desc {
  display: block;
  font-family: var(--f-mono);
  font-size: 10px;
  color: var(--muted);
  margin-top: 2px;
  letter-spacing: 0.01em;
}
