/* =========================================================================
   ONENEO — Studio Portfolio · base + shared design system
   Dark-mode-first. Magenta is the brand voice; the 8-stop spectrum is the
   connective tissue (8 hues = 8 products = one studio). Three variants
   (neon / cosmic / minimal) layer a theme file on top of this base and swap
   the Three.js hero — everything else is shared.
   ========================================================================= */

:root {
  /* surfaces — true black, dark-mode-first */
  --bg: #000000;
  --surface: #0B0B0F;
  --surface-2: #14141B;
  --text: #F4F2F8;
  --text-muted: #8B8896;
  --line: #1E1E27;
  --line-soft: #131319;

  /* brand voice — magenta */
  --accent: #D490FF;
  --accent-ink: #1A0A24;
  --accent-dim: color-mix(in srgb, var(--accent) 60%, var(--text-muted));

  /* the 8-stop spectrum (matches PROJECTS hues, green → marigold) */
  --hue-1: #34D399; /* seojack — green        */
  --hue-2: #2EE6A6; /* me — teal              */
  --hue-3: #22D3EE; /* neojack — cyan         */
  --hue-4: #6AA6FF; /* ai — electric blue     */
  --hue-5: #8B5CF6; /* vibe — violet          */
  --hue-6: #D490FF; /* her — magenta          */
  --hue-7: #C6F04E; /* thc — lime             */
  --hue-8: #F4A93A; /* caco — marigold        */
  --spectrum: linear-gradient(90deg,
    var(--hue-1), var(--hue-3), var(--hue-4),
    var(--hue-5), var(--hue-6), var(--hue-7), var(--hue-8));

  /* per-card colour is set inline: style="--hue:#34D399" (from content.js) */
  --hue: var(--accent);

  /* type — Geist / Geist Mono */
  --font-display: "Geist", "Geist Fallback", system-ui, sans-serif;
  --font-body: "Geist", system-ui, sans-serif;
  --font-mono: "Geist Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;

  --maxw: 1220px;
  --pad: clamp(1.15rem, 5vw, 4rem);
  --bar-top: 46px;
  --bar-bottom: 34px;
  --r: 16px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-mech: cubic-bezier(0.16, 1, 0.3, 1);
}

/* Metric-matched fallback for the display (LCP) face so the hero title does
   not reflow when Geist swaps in. Tuned to Arial's box. */
@font-face {
  font-family: "Geist Fallback";
  src: local("Arial");
  size-adjust: 100%;
  ascent-override: 95%;
  descent-override: 24%;
  line-gap-override: 0%;
}

/* ---------- reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html {
  -webkit-text-size-adjust: 100%;
  overflow-x: clip;
  scroll-behavior: auto; /* Lenis owns smooth scroll; native fallback if absent */
}
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: clamp(1rem, 0.97rem + 0.22vw, 1.14rem);
  line-height: 1.62;
  font-weight: 400;
  overflow-x: clip;
  min-height: 100vh;
  padding-top: var(--bar-top);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg, canvas { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: none; cursor: pointer; }
input { font: inherit; }
ul { list-style: none; padding: 0; }
::selection { background: var(--accent); color: var(--accent-ink); }

.mono { font-family: var(--font-mono); letter-spacing: 0.04em; font-variant-numeric: tabular-nums; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 3px; }

@supports (scrollbar-color: red blue) {
  html { scrollbar-color: var(--line) var(--bg); scrollbar-width: thin; }
}
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--line); border-radius: 10px; }

.skip-link {
  position: fixed; top: 6px; left: 6px; z-index: 200;
  transform: translateY(-180%);
  background: var(--accent); color: var(--accent-ink);
  padding: 0.5rem 0.9rem; border-radius: 8px; font-weight: 600;
  transition: transform 0.2s var(--ease);
}
.skip-link:focus { transform: translateY(0); }

/* ---------- shared dots / chips ---------- */
.dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--text-muted); vertical-align: middle; }
.dot--live { background: var(--accent); box-shadow: 0 0 8px var(--accent); }
.dot--pulse { animation: dotpulse 2.4s ease-in-out infinite; }
.dot--spectrum { animation: dotspectrum 9s linear infinite; }
@keyframes dotpulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.4; } }
@keyframes dotspectrum {
  0%   { background: var(--hue-1); box-shadow: 0 0 8px var(--hue-1); }
  16%  { background: var(--hue-3); box-shadow: 0 0 8px var(--hue-3); }
  33%  { background: var(--hue-4); box-shadow: 0 0 8px var(--hue-4); }
  50%  { background: var(--hue-5); box-shadow: 0 0 8px var(--hue-5); }
  66%  { background: var(--hue-6); box-shadow: 0 0 8px var(--hue-6); }
  83%  { background: var(--hue-7); box-shadow: 0 0 8px var(--hue-7); }
  100% { background: var(--hue-1); box-shadow: 0 0 8px var(--hue-1); }
}

.chip {
  display: inline-flex; align-items: center; gap: 0.35em;
  font-family: var(--font-mono); font-size: 0.64rem; font-weight: 500;
  letter-spacing: 0.12em; padding: 0.22em 0.55em; border-radius: 5px;
  border: 1px solid var(--line); color: var(--text-muted); white-space: nowrap;
}
.chip--live { color: var(--hue, var(--accent)); border-color: color-mix(in srgb, var(--hue, var(--accent)) 42%, transparent); background: color-mix(in srgb, var(--hue, var(--accent)) 10%, transparent); }
.chip--beta { color: var(--hue, var(--accent)); border-color: color-mix(in srgb, var(--hue, var(--accent)) 34%, transparent); background: color-mix(in srgb, var(--hue, var(--accent)) 7%, transparent); }
.chip--personal { color: var(--text-muted); border-style: dashed; }

kbd {
  font-family: var(--font-mono); font-size: 0.78em; line-height: 1;
  background: var(--surface-2); border: 1px solid var(--line);
  border-radius: 5px; padding: 0.25em 0.45em; color: var(--text);
}

/* =========================================================================
   STATUS BARS + VARIANT SWITCHER
   ========================================================================= */
.statusbar {
  position: fixed; left: 0; right: 0; z-index: 90;
  display: flex; align-items: center; gap: clamp(0.5rem, 1.8vw, 1.3rem);
  height: var(--bar-top); padding: 0 clamp(0.8rem, 3vw, 1.5rem);
  font-size: 0.7rem; color: var(--text-muted);
  background: color-mix(in srgb, var(--bg) 80%, transparent);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line-soft);
}
.statusbar--top { top: 0; }
.statusbar--bottom {
  bottom: 0; top: auto; height: var(--bar-bottom); z-index: 80;
  border-bottom: none; border-top: 1px solid var(--line-soft);
  font-size: 0.66rem; justify-content: flex-start;
}
.statusbar__seg { display: inline-flex; align-items: center; gap: 0.4em; white-space: nowrap; }
.statusbar__brand { color: var(--text); font-weight: 700; letter-spacing: 0.1em; }
.statusbar__v { color: var(--accent); font-size: 0.6rem; margin-left: 0.2em; }
.statusbar__nav { margin-left: auto; display: flex; gap: clamp(0.7rem, 2vw, 1.3rem); }
.statusbar__nav a { color: var(--text-muted); transition: color 0.2s; }
.statusbar__nav a:hover { color: var(--accent); }

/* variant switcher — flip NEON · COSMIC · MINIMAL */
.switcher { display: inline-flex; align-items: center; gap: 0.15rem; padding: 0.12rem; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); }
.switcher__btn { padding: 0.28em 0.62em; border-radius: 999px; font-family: var(--font-mono); font-size: 0.6rem; letter-spacing: 0.1em; color: var(--text-muted); transition: color 0.2s, background 0.2s; }
.switcher__btn:hover { color: var(--text); }
.switcher__btn.is-active { color: var(--accent-ink); background: var(--accent); font-weight: 600; }
.statusbar__k {
  display: inline-flex; align-items: center; gap: 0.25em;
  padding: 0.3em 0.5em; border: 1px solid var(--line); border-radius: 7px;
  background: var(--surface); transition: border-color 0.2s, background 0.2s;
}
.statusbar__k:hover { border-color: var(--accent); }
.statusbar__online { margin-left: auto; color: var(--accent); }
.statusbar__scroll { color: var(--text); }

/* =========================================================================
   BOOT OVERLAY (one-time, sessionStorage-gated)
   ========================================================================= */
.boot { position: fixed; inset: 0; z-index: 300; background: var(--bg); display: grid; place-items: center; }
.boot[hidden] { display: none; }
.boot__inner { width: min(560px, 86vw); position: relative; }
.boot__log { font-size: clamp(0.78rem, 2.6vw, 0.95rem); line-height: 1.9; color: var(--accent); white-space: pre-wrap; min-height: 6em; }
.boot__skip { position: absolute; right: 0; bottom: -2.4em; font-family: var(--font-mono); font-size: 0.72rem; color: var(--text-muted); border: 1px solid var(--line); border-radius: 6px; padding: 0.3em 0.6em; }
.boot__skip:hover { color: var(--accent); border-color: var(--accent); }

/* =========================================================================
   BUTTONS
   ========================================================================= */
.btn {
  display: inline-flex; align-items: center; gap: 0.5em;
  padding: 0.7em 1.2em; border-radius: 999px; font-weight: 600;
  font-size: 0.92rem; border: 1px solid transparent; white-space: nowrap;
  transition: transform 0.2s var(--ease), background 0.2s, border-color 0.2s, color 0.2s, box-shadow 0.2s;
}
.btn--primary { background: var(--accent); color: var(--accent-ink); box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 50%, transparent); }
.btn--primary:hover { box-shadow: 0 8px 30px -8px color-mix(in srgb, var(--accent) 70%, transparent); transform: translateY(-2px); }
.btn--ghost { border-color: var(--line); color: var(--text); background: color-mix(in srgb, var(--surface) 70%, transparent); }
.btn--ghost:hover { border-color: var(--accent); color: var(--accent); }
.btn--lg { padding: 0.85em 1.5em; font-size: 1rem; }
.btn kbd { background: color-mix(in srgb, var(--bg) 40%, transparent); border-color: color-mix(in srgb, var(--accent-ink) 30%, transparent); }

/* =========================================================================
   SECTIONS
   ========================================================================= */
.section { max-width: var(--maxw); margin: 0 auto; padding: clamp(4rem, 11vh, 8rem) var(--pad); }
.section__index { font-size: 0.7rem; letter-spacing: 0.22em; color: var(--accent-dim); margin-bottom: 0.9rem; }
.section__head { margin-bottom: clamp(2rem, 5vh, 3.4rem); max-width: 64ch; }
.section__title { font-family: var(--font-display); font-weight: 700; font-size: clamp(1.9rem, 4.6vw, 3.2rem); line-height: 1.04; letter-spacing: -0.02em; text-wrap: balance; }
.section__lead { margin-top: 1rem; color: var(--text-muted); font-size: clamp(1rem, 0.97rem + 0.3vw, 1.16rem); }

/* =========================================================================
   HERO (shared shell — the GL canvas + fallback live behind SSR copy)
   ========================================================================= */
.hero { position: relative; min-height: calc(100svh - var(--bar-top)); display: flex; align-items: center; padding: clamp(2rem, 6vh, 5rem) var(--pad) clamp(5rem, 10vh, 7rem); overflow: clip; }
.hero__field { position: absolute; inset: 0; z-index: 0; overflow: clip; }
.hero__gl { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero__gl canvas { position: absolute; inset: 0; width: 100% !important; height: 100% !important; }
/* static fallback shown when GL is unavailable / reduced-motion (JS reveals it) */
.hero__fallback { position: absolute; inset: 0; display: none; place-items: center; }
.hero__fallback::before { content: ""; position: absolute; inset: 0; background: radial-gradient(60% 60% at 70% 40%, color-mix(in srgb, var(--accent) 22%, transparent), transparent 70%), conic-gradient(from 200deg at 72% 42%, var(--hue-1), var(--hue-3), var(--hue-4), var(--hue-5), var(--hue-6), var(--hue-7), var(--hue-8), var(--hue-1)); filter: blur(60px); opacity: 0.5; }
.hero__fallback img { position: relative; width: clamp(120px, 22vw, 220px); opacity: 0.85; filter: drop-shadow(0 0 30px color-mix(in srgb, var(--accent) 60%, transparent)); }
:root.no-gl .hero__fallback { display: grid; }

.hero__field::after {
  content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(90deg, var(--bg) 0%, color-mix(in srgb, var(--bg) 55%, transparent) 42%, transparent 78%),
    linear-gradient(180deg, transparent 44%, var(--bg) 100%);
}
.hero__inner { position: relative; z-index: 2; max-width: var(--maxw); width: 100%; margin: 0 auto; }
.hero__id { display: flex; align-items: center; gap: 0.9rem; flex-wrap: wrap; margin-bottom: clamp(1.2rem, 4vh, 1.8rem); }
.hero__mark { width: 48px; height: 48px; flex: none; filter: drop-shadow(0 0 16px color-mix(in srgb, var(--accent) 45%, transparent)); animation: markspin 38s linear infinite; }
@keyframes markspin { to { transform: rotate(360deg); } }
.hero__eyebrow { display: inline-flex; align-items: center; gap: 0.55em; flex-wrap: wrap; font-family: var(--font-mono); font-size: clamp(0.62rem, 2.2vw, 0.74rem); letter-spacing: 0.08em; color: var(--text-muted); padding: 0.45em 0.85em; border: 1px solid var(--line); border-radius: 999px; background: color-mix(in srgb, var(--surface) 55%, transparent); }
.hero__online { color: var(--accent); }

.hero__wordmark { font-family: var(--font-display); font-weight: 700; font-size: clamp(3rem, 13vw, 9rem); line-height: 0.9; letter-spacing: -0.04em; }
.hero__wordmark .spectrum-text {
  background-image: var(--spectrum); background-size: 200% 100%;
  -webkit-background-clip: text; background-clip: text; color: transparent; -webkit-text-fill-color: transparent;
  animation: spectrumFlow 14s ease-in-out infinite alternate;
}
@keyframes spectrumFlow { from { background-position: 0% 50%; } to { background-position: 100% 50%; } }
.hero__title { font-family: var(--font-display); font-weight: 700; font-size: clamp(1.7rem, 4.6vw, 3.1rem); line-height: 1.02; letter-spacing: -0.02em; margin-top: clamp(0.8rem, 2.5vh, 1.4rem); text-wrap: balance; }
.hero__sub { margin-top: clamp(1.1rem, 3.5vh, 1.7rem); max-width: 54ch; color: var(--text-muted); font-size: clamp(1rem, 0.97rem + 0.4vw, 1.2rem); }
.hero__cta { margin-top: clamp(1.6rem, 5vh, 2.4rem); display: flex; flex-wrap: wrap; gap: 0.8rem; }

.kchip { position: absolute; right: clamp(1rem, 4vw, 2.4rem); bottom: clamp(4.6rem, 9vh, 6rem); z-index: 3; display: inline-flex; align-items: center; gap: 0.5em; font-family: var(--font-mono); font-size: 0.72rem; color: var(--text-muted); padding: 0.55em 0.9em; border: 1px solid var(--line); border-radius: 999px; background: color-mix(in srgb, var(--surface) 80%, transparent); backdrop-filter: blur(8px); transition: border-color 0.2s, color 0.2s, transform 0.2s var(--ease); }
.kchip:hover { border-color: var(--accent); color: var(--text); transform: translateY(-2px); }
.kchip__pulse { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 10px var(--accent); animation: dotpulse 2s ease-in-out infinite; }

/* =========================================================================
   MANIFESTO + CAPABILITIES
   ========================================================================= */
.manifesto { font-family: var(--font-display); font-weight: 700; font-size: clamp(1.9rem, 5.2vw, 3.6rem); line-height: 1.08; letter-spacing: -0.02em; }
.manifesto .reveal-line { display: block; }
.manifesto em { font-style: normal; background-image: var(--spectrum); background-size: 200% 100%; -webkit-background-clip: text; background-clip: text; color: transparent; -webkit-text-fill-color: transparent; animation: spectrumFlow 12s ease-in-out infinite alternate; }
.manifesto__cursor { display: inline-block; width: 0.5ch; height: 1em; transform: translateY(0.12em); background: var(--accent); margin-left: 0.04em; animation: caret 1s steps(1) infinite; }
.manifesto__cursor.is-done { animation: none; opacity: 0; }
@keyframes caret { 50% { opacity: 0; } }
.tw-char { display: inline; }

.caps { margin-top: clamp(2.4rem, 6vh, 3.6rem); display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); gap: 1px; background: var(--line-soft); border: 1px solid var(--line-soft); border-radius: var(--r); overflow: hidden; }
.caps li { background: var(--surface); padding: 1.3rem 1.4rem; display: flex; flex-direction: column; gap: 0.5rem; transition: background 0.25s; }
.caps li:hover { background: var(--surface-2); }
.caps__k { font-size: 0.68rem; letter-spacing: 0.16em; color: var(--accent); }
.caps__v { color: var(--text-muted); font-size: 0.96rem; line-height: 1.5; }

/* =========================================================================
   THE SPECTRUM — work cards (the heart)
   ========================================================================= */
.work__bar { display: flex; align-items: center; gap: 0.5rem; flex-wrap: wrap; margin-bottom: 1.6rem; }
.filters { display: flex; gap: 0.4rem; flex-wrap: wrap; }
.filter { font-family: var(--font-mono); font-size: 0.68rem; letter-spacing: 0.08em; padding: 0.45em 0.85em; border: 1px solid var(--line); border-radius: 999px; color: var(--text-muted); transition: color 0.2s, border-color 0.2s, background 0.2s; }
.filter:hover { color: var(--text); border-color: var(--accent-dim); }
.filter.is-active { color: var(--accent-ink); background: var(--accent); border-color: var(--accent); font-weight: 600; }

.work-grid { display: grid; grid-template-columns: repeat(12, 1fr); gap: clamp(1rem, 2.2vw, 1.6rem); }

.work-card {
  position: relative; grid-column: span 6; display: flex; flex-direction: column;
  border: 1px solid var(--line); border-radius: var(--r); overflow: hidden;
  background: var(--surface); isolation: isolate;
  transition: transform 0.4s var(--ease), border-color 0.3s, box-shadow 0.4s;
}
/* editorial tiling — each 12-wide row sums cleanly (7+5, 5+7, 6+6, 7+5) */
.work-card[data-span="5"] { grid-column: span 5; }
.work-card[data-span="6"] { grid-column: span 6; }
.work-card[data-span="7"] { grid-column: span 7; }
.work-card[hidden] { display: none; }
.work-card::before { /* hue hairline + glow at the top edge */
  content: ""; position: absolute; inset: 0 0 auto 0; height: 3px; z-index: 3;
  background: var(--hue); box-shadow: 0 0 18px var(--hue);
  opacity: 0.9; transition: opacity 0.3s;
}
.work-card:hover { transform: translateY(-6px); border-color: color-mix(in srgb, var(--hue) 55%, var(--line)); box-shadow: 0 24px 60px -28px color-mix(in srgb, var(--hue) 60%, transparent), 0 0 0 1px color-mix(in srgb, var(--hue) 30%, transparent); }

.work-card__media { position: relative; display: block; aspect-ratio: 16 / 10; overflow: hidden; background: color-mix(in srgb, var(--hue) 9%, var(--surface-2)); }
.work-card__media img { width: 100%; height: 100%; object-fit: cover; object-position: top center; transition: transform 0.6s var(--ease), filter 0.4s; }
.work-card:hover .work-card__media img { transform: scale(1.045); }
.work-card__ph-letter { display: none; }
.work-card__media--ph { display: grid; place-items: center; background: linear-gradient(135deg, color-mix(in srgb, var(--hue) 22%, var(--surface-2)), var(--surface)); }
.work-card__media--ph .work-card__ph-letter { display: grid; place-items: center; position: absolute; inset: 0; z-index: 0; font-family: var(--font-display); font-weight: 700; font-size: clamp(3rem, 9vw, 6rem); color: color-mix(in srgb, var(--hue) 65%, transparent); }
.work-card__scan { position: absolute; left: 0; right: 0; top: 0; height: 42%; z-index: 2; pointer-events: none; opacity: 0; background: linear-gradient(180deg, color-mix(in srgb, var(--hue) 40%, transparent), transparent); }
.work-card__shade { position: absolute; inset: 0; z-index: 1; background: linear-gradient(180deg, transparent 55%, color-mix(in srgb, var(--bg) 86%, transparent)); }

.work-card__body { position: relative; z-index: 2; padding: 1.2rem 1.3rem 1.35rem; display: flex; flex-direction: column; gap: 0.55rem; flex: 1; }
.work-card__top { display: flex; align-items: center; gap: 0.6rem; font-family: var(--font-mono); }
.work-card__host { font-size: 0.7rem; letter-spacing: 0.06em; color: var(--text-muted); }
.work-card__top .chip { margin-left: auto; }
.work-card__name { font-family: var(--font-display); font-weight: 700; font-size: clamp(1.15rem, 2.4vw, 1.5rem); letter-spacing: -0.015em; line-height: 1.1; }
.work-card__tag { color: color-mix(in srgb, var(--hue) 75%, var(--text)); font-weight: 500; font-size: 0.95rem; }
.work-card__desc { color: var(--text-muted); font-size: 0.92rem; line-height: 1.55; }
.work-card__stack { display: flex; flex-wrap: wrap; gap: 0.35rem; margin-top: 0.15rem; }
.work-card__stack li { font-family: var(--font-mono); font-size: 0.62rem; letter-spacing: 0.05em; color: var(--text-muted); border: 1px solid var(--line); border-radius: 5px; padding: 0.18em 0.5em; }
.work-card__foot { margin-top: auto; padding-top: 0.7rem; display: flex; align-items: center; justify-content: space-between; gap: 0.6rem; }
.work-card__cat { font-family: var(--font-mono); font-size: 0.62rem; letter-spacing: 0.12em; color: var(--text-muted); }
.work-card__visit { display: inline-flex; align-items: center; gap: 0.4em; font-family: var(--font-mono); font-size: 0.72rem; letter-spacing: 0.06em; color: var(--hue); border: 1px solid color-mix(in srgb, var(--hue) 40%, transparent); border-radius: 999px; padding: 0.4em 0.85em; transition: background 0.2s, color 0.2s, transform 0.2s var(--ease); }
.work-card__visit:hover { background: var(--hue); color: var(--accent-ink); transform: translateX(2px); }
.work-card__cover { position: absolute; inset: 0; z-index: 4; } /* whole-card link */
.work-card__cover:focus-visible { outline-offset: -3px; }
.work-card__visit { position: relative; z-index: 5; } /* keep the pill clickable above the cover */

.work-card__banner { position: absolute; top: 0.9rem; left: 0.9rem; z-index: 5; font-family: var(--font-mono); font-size: 0.6rem; letter-spacing: 0.14em; color: var(--accent-ink); background: var(--hue); padding: 0.3em 0.6em; border-radius: 5px; font-weight: 600; box-shadow: 0 0 16px color-mix(in srgb, var(--hue) 60%, transparent); }

/* =========================================================================
   THE THREAD — full-width spectrum strip
   ========================================================================= */
.thread { max-width: 100%; padding: clamp(3rem, 8vh, 5rem) 0; overflow: hidden; }
.thread__head { max-width: var(--maxw); margin: 0 auto 1.8rem; padding: 0 var(--pad); }
.thread__strip { position: relative; display: grid; grid-template-columns: repeat(8, 1fr); height: clamp(80px, 14vh, 130px); }
.thread__cell { position: relative; display: flex; align-items: flex-end; padding: 0.6rem 0.7rem; overflow: hidden; }
.thread__cell::before { content: ""; position: absolute; inset: 0; background: var(--hue); opacity: 0.16; transition: opacity 0.3s; }
.thread__cell:hover::before { opacity: 0.34; }
.thread__cell::after { content: ""; position: absolute; left: 0; top: 0; height: 3px; width: 100%; background: var(--hue); box-shadow: 0 0 14px var(--hue); }
.thread__label { position: relative; font-family: var(--font-mono); font-size: 0.6rem; letter-spacing: 0.06em; color: var(--text); line-height: 1.3; }
.thread__label b { display: block; font-size: 0.74rem; color: var(--hue); }
.thread__progress { position: absolute; inset: 0 0 auto 0; height: 4px; background: var(--spectrum); transform-origin: left; transform: scaleX(0); z-index: 4; }

/* =========================================================================
   STATS
   ========================================================================= */
.stats__grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr)); gap: 1px; background: var(--line-soft); border: 1px solid var(--line-soft); border-radius: var(--r); overflow: hidden; }
.stat { background: var(--surface); padding: clamp(1.6rem, 4vw, 2.6rem) 1.4rem; }
.stat__num { font-family: var(--font-display); font-weight: 700; font-size: clamp(2.4rem, 6vw, 4rem); line-height: 1; letter-spacing: -0.02em; color: var(--hue, var(--accent)); }
.stat__suffix { font-size: 0.5em; margin-left: 0.05em; }
.stat__label { margin-top: 0.6rem; color: var(--text-muted); font-size: 0.9rem; }

/* =========================================================================
   CONTACT + FOOTER
   ========================================================================= */
.contact { text-align: left; }
.contact__title { font-family: var(--font-display); font-weight: 700; font-size: clamp(2.2rem, 6vw, 4rem); letter-spacing: -0.02em; line-height: 1.02; }
.contact__lead { margin-top: 1.1rem; max-width: 54ch; color: var(--text-muted); font-size: clamp(1.02rem, 1rem + 0.4vw, 1.22rem); }
.contact__handshake { margin-top: 1.4rem; color: var(--accent); font-size: 0.82rem; }
.contact__cta { margin-top: 1.8rem; display: flex; flex-wrap: wrap; gap: 0.8rem; }

.footer { max-width: var(--maxw); margin: 0 auto; padding: clamp(2.6rem, 6vh, 4rem) var(--pad) calc(var(--bar-bottom) + 2.4rem); border-top: 1px solid var(--line-soft); color: var(--text-muted); font-size: 0.8rem; }
.footer__ascii { color: var(--accent-dim); font-size: clamp(0.5rem, 1.6vw, 0.74rem); line-height: 1.25; overflow-x: auto; margin-bottom: 1.8rem; }
.footer__row { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); gap: 1.6rem; }
.footer__lbl { color: var(--text); letter-spacing: 0.14em; font-size: 0.66rem; margin-bottom: 0.6rem; }
.footer__col a { display: block; color: var(--text-muted); padding: 0.12rem 0; transition: color 0.2s; }
.footer__col a:hover { color: var(--accent); }
.footer__eof { margin-top: 2rem; font-size: 0.7rem; color: var(--accent-dim); }

/* =========================================================================
   COMMAND PALETTE (⌘K)
   ========================================================================= */
.palette { position: fixed; inset: 0; z-index: 250; display: grid; align-items: start; justify-items: center; padding-top: 12vh; }
.palette[hidden] { display: none; }
.palette__scrim { position: absolute; inset: 0; background: color-mix(in srgb, var(--bg) 70%, transparent); backdrop-filter: blur(6px); }
.palette__panel { position: relative; width: min(620px, 92vw); background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); box-shadow: 0 40px 120px -30px #000; overflow: hidden; }
.palette__inputrow { display: flex; align-items: center; gap: 0.6rem; padding: 0.9rem 1.1rem; border-bottom: 1px solid var(--line-soft); }
.palette__prompt { color: var(--accent); }
.palette__input { flex: 1; background: none; border: none; outline: none; color: var(--text); font-size: 1rem; }
.palette__input::placeholder { color: var(--text-muted); }
.palette__esc { font-size: 0.66rem; }
.palette__list { max-height: 46vh; overflow-y: auto; }
.palette__opt { display: flex; align-items: center; gap: 0.8rem; padding: 0.7rem 1.1rem; cursor: pointer; border-left: 2px solid transparent; }
.palette__opt[aria-selected="true"] { background: var(--surface-2); border-left-color: var(--hue, var(--accent)); }
.palette__opt-idx { width: 9px; height: 9px; border-radius: 50%; background: var(--hue, var(--accent)); box-shadow: 0 0 8px var(--hue, var(--accent)); flex: none; }
.palette__opt-name { font-weight: 600; }
.palette__opt-host { font-family: var(--font-mono); font-size: 0.66rem; color: var(--text-muted); }
.palette__opt-cat { margin-left: auto; font-family: var(--font-mono); font-size: 0.62rem; letter-spacing: 0.08em; color: var(--text-muted); }
.palette__status { padding: 0 1.1rem; }
.palette__response, .palette__empty { padding: 0.8rem 0; color: var(--text-muted); font-family: var(--font-mono); font-size: 0.8rem; white-space: pre-wrap; line-height: 1.6; }
.palette__response { color: var(--accent); }
.palette__foot { display: flex; gap: 1rem; flex-wrap: wrap; padding: 0.7rem 1.1rem; border-top: 1px solid var(--line-soft); font-size: 0.66rem; color: var(--text-muted); }
.palette__hint { margin-left: auto; }
.palette code { color: var(--accent); }

/* =========================================================================
   CUSTOM CURSOR + MAGNETIC + REVEAL
   ========================================================================= */
.cursor { position: fixed; top: 0; left: 0; z-index: 400; width: 26px; height: 26px; border: 1px solid var(--accent); border-radius: 50%; transform: translate(-50%, -50%); pointer-events: none; opacity: 0; transition: opacity 0.3s, width 0.2s var(--ease), height 0.2s var(--ease), background 0.2s; mix-blend-mode: difference; }
.cursor.is-on { opacity: 0.7; }
.cursor.is-active { width: 42px; height: 42px; background: color-mix(in srgb, var(--accent) 18%, transparent); }
@media (hover: none), (pointer: coarse) { .cursor { display: none; } }

.reveal { will-change: transform, opacity; }

/* =========================================================================
   RESPONSIVE
   ========================================================================= */
@media (max-width: 1080px) {
  .work-card, .work-card[data-span] { grid-column: span 6; }
}
@media (max-width: 880px) {
  .statusbar__hide-sm { display: none; }
}
@media (max-width: 680px) {
  .work-card, .work-card[data-span] { grid-column: span 12; }
  .thread__label { writing-mode: vertical-rl; transform: rotate(180deg); }
  .thread__label b { writing-mode: horizontal-tb; }
}
@media (max-width: 560px) {
  .hero__cta { flex-direction: column; align-items: stretch; }
  .hero__cta .btn { justify-content: center; }
  .kchip { display: none; }
  .switcher__btn { padding: 0.28em 0.45em; }
  .thread__label { font-size: 0.52rem; }
}

/* =========================================================================
   REDUCED MOTION — first-class static path
   ========================================================================= */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; scroll-behavior: auto !important; }
  .hero__mark { animation: none; }
  .reveal { opacity: 1 !important; transform: none !important; }
  .manifesto__cursor { display: none; }
}
