/* ─────────────────────────────────────────────────────────
   V8 — "THE CORE" · Live Infrastructure Portfolio
   Aesthetic: dark holographic HUD over a live 3D scene
   Fonts: Inter (display + body) / Fraunces (editorial) / JetBrains Mono (mono)
   ───────────────────────────────────────────────────────── */

:root {
  /* palette — monochrome with ONE warm accent. The solar system is colorful enough on its own. */
  --bg-void: #0a0a0c;
  --bg-ink:  #0f0f12;
  --bg-panel:       rgba(14, 14, 17, 0.72);
  --bg-panel-solid: #101013;
  --bg-panel-hi:    rgba(22, 22, 26, 0.86);
  --bg-panel-ai:    rgba(12, 12, 16, 0.86);
  --edge:    rgba(255, 255, 255, 0.08);
  --edge-hi: rgba(255, 255, 255, 0.18);
  --edge-glow: rgba(255, 255, 255, 0.14);

  --text:      #eeeeee;
  --text-dim:  #a0a0a6;
  --text-mute: #686870;

  /* single warm accent — used sparingly. everything "cyan" is now a refined off-white. */
  --amber:      #d9a367;    /* THE accent — restrained gold */
  --amber-soft: rgba(217, 163, 103, 0.14);
  --cyan:       #e4e5e9;    /* neutralized to cool off-white; not actually cyan anymore */
  --cyan-soft:  rgba(228, 229, 233, 0.08);
  --magenta:      #c96677;  /* error state only */
  --magenta-soft: rgba(201, 102, 119, 0.12);
  --lime:         #c9cdd4;  /* collapsed into neutral */
  --online:       #58d68d;  /* classic status-green — only for live/online dots */

  --accent:   var(--amber);
  --accent-2: var(--cyan);

  --shadow-glow-cy: 0 0 32px rgba(255, 255, 255, 0.06);
  --shadow-glow-mg: 0 0 32px rgba(217, 163, 103, 0.10);
  --shadow-panel:   0 20px 50px rgba(0, 0, 0, 0.42), inset 0 1px 0 rgba(255, 255, 255, 0.03);

  --radius:    12px;
  --radius-sm: 8px;
  --radius-lg: 20px;

  --font-display:   "Inter", system-ui, -apple-system, sans-serif;
  --font-body:      "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-editorial: "Fraunces", Georgia, serif;
  --font-mono:      "JetBrains Mono", ui-monospace, SFMono-Regular, monospace;

  --ease-out:    cubic-bezier(0.22, 1, 0.36, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);

  --station-h: 120vh;
}

/* ── reset ── */
*,
*::before,
*::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  background: var(--bg-void);
  color: var(--text);
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overscroll-behavior-y: none;
}

body {
  font-family: var(--font-body);
  font-weight: 400;
  line-height: 1.55;
  color: var(--text);
  background: var(--bg-void);
  min-height: 100vh;
  overflow-x: hidden;
}

/* Hide the decorative custom cursor on touch devices */
@media (hover: none), (pointer: coarse) {
  #cursor { display: none !important; }
}

a { color: inherit; text-decoration: none; cursor: pointer; }
button { font: inherit; background: none; border: none; color: inherit; cursor: pointer; }
input, textarea, select { font: inherit; color: inherit; }
img { display: block; max-width: 100%; }

::selection {
  background: rgba(217, 163, 103, 0.28);
  color: #fff;
}

/* Skip link — visible only on keyboard focus */
.skip-link {
  position: fixed;
  top: 8px;
  left: 8px;
  z-index: 10000;
  padding: 10px 16px;
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 500;
  color: #18181b;
  background: var(--text);
  border: 1px solid var(--text);
  border-radius: 8px;
  text-decoration: none;
  transform: translateY(-150%);
  transition: transform 180ms var(--ease-out);
}
.skip-link:focus,
.skip-link:focus-visible {
  transform: translateY(0);
  outline: 2px solid var(--amber);
  outline-offset: 2px;
}

/* Give every interactive element a readable focus ring */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible,
[tabindex]:focus-visible {
  outline: 2px solid var(--amber);
  outline-offset: 2px;
  border-radius: 4px;
}

/* scrollbar */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.12);
  border-radius: 10px;
  border: 2px solid var(--bg-void);
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.22);
}

/* ── BOOT OVERLAY ── */
.boot {
  position: fixed;
  inset: 0;
  background: #0a0a0c;
  z-index: 1000;
  display: grid;
  place-items: center;
  color: var(--text);
  font-family: var(--font-body);
  transition: opacity 700ms var(--ease-out), visibility 700ms;
}
.boot.is-done {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: scale(1.05);
  transition: opacity 700ms var(--ease-out), visibility 700ms, transform 700ms var(--ease-out);
}
.boot-inner {
  width: min(620px, 92vw);
  padding: 28px 32px 26px;
  position: relative;
  text-align: left;
  border: 1px solid var(--edge);
  border-radius: var(--radius);
  background: rgba(16, 16, 22, 0.6);
  backdrop-filter: blur(12px);
  overflow: hidden;
}
.boot-canvas {
  display: block;
  width: 100%;
  height: 180px;
  margin-bottom: 18px;
  border-radius: 8px;
  background: radial-gradient(70% 80% at 50% 50%, rgba(255, 180, 80, 0.06), transparent 70%);
}
.boot-inner::before {
  display: none;
}
.boot-brand {
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: 0.22em;
  font-size: 14px;
  color: var(--text);
  margin-bottom: 6px;
  text-transform: uppercase;
  animation: bootBrandIn 700ms var(--ease-out);
}
@keyframes bootBrandIn {
  0%   { opacity: 0; letter-spacing: 0.5em; }
  100% { opacity: 1; letter-spacing: 0.22em; }
}
.boot-brand-dot {
  color: var(--amber);
  margin: 0 1px;
}
.boot-sub {
  font-family: var(--font-body);
  font-size: 13px;
  color: var(--text-dim);
  letter-spacing: -0.005em;
  margin-bottom: 4px;
  animation: bootLineIn 520ms var(--ease-out) 160ms both;
}
.boot-sub em {
  font-family: var(--font-editorial);
  font-style: italic;
  color: var(--text);
}
.boot-log {
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: var(--text-dim);
  min-height: 150px;
  max-height: 150px;
  overflow: hidden;
  white-space: pre-wrap;
  line-height: 1.85;
  margin-top: 18px;
}
.boot-log > div {
  opacity: 0;
  transform: translateY(4px);
  animation: bootLineIn 360ms var(--ease-out) forwards;
}
@keyframes bootLineIn {
  to { opacity: 1; transform: translateY(0); }
}
.boot-log .ok { color: var(--text); }
.boot-log .warn { color: var(--amber); }
.boot-log .hi { color: var(--amber); }
.boot-log .dim { color: var(--text-mute); }
.boot-bar {
  margin-top: 24px;
  height: 1px;
  background: var(--edge);
  position: relative;
  overflow: hidden;
}
.boot-bar-fill {
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 0%;
  background: var(--text);
  transition: width 120ms linear;
}
.boot-bar-fill::after {
  content: "";
  position: absolute;
  right: -12px; top: -1px;
  width: 12px; height: 3px;
  background: var(--amber);
  box-shadow: 0 0 8px rgba(217, 163, 103, 0.6);
  border-radius: 2px;
}
.boot-hint {
  margin-top: 14px;
  font-family: var(--font-body);
  font-size: 12.5px;
  color: var(--text-mute);
  letter-spacing: -0.005em;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.boot-hint em {
  font-family: var(--font-editorial);
  font-style: italic;
  color: var(--text-dim);
}

/* ── CURSOR — decorative ring follows the real cursor (which is still visible) ── */
.cursor {
  position: fixed;
  top: 0; left: 0;
  width: 0; height: 0;
  pointer-events: none;
  z-index: 999;
}
.cursor-dot { display: none; }
.cursor-ring {
  position: absolute;
  width: 26px; height: 26px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  transition: width 200ms var(--ease-out), height 200ms var(--ease-out), border-color 200ms, opacity 200ms;
  opacity: 0.7;
}
.cursor.is-hover .cursor-ring {
  width: 48px; height: 48px;
  border-color: rgba(255, 255, 255, 0.55);
  opacity: 1;
}
.cursor.is-click .cursor-ring {
  width: 20px; height: 20px;
  border-color: var(--amber);
}
.cursor-label {
  position: absolute;
  transform: translate(16px, 16px);
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text);
  background: rgba(0,0,0,0.8);
  padding: 4px 8px;
  border: 1px solid var(--edge-hi);
  border-radius: 4px;
  opacity: 0;
  white-space: nowrap;
  transition: opacity 180ms;
}
.cursor.is-labeled .cursor-label { opacity: 1; }

/* ── WEBGL CANVAS ── */
.bg-canvas {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  z-index: 0;
  pointer-events: none;
  display: block;
  opacity: 0.92;
}

/* ── VIGNETTE — improves content legibility on top of 3D ── */
.vignette {
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    radial-gradient(120% 100% at 50% 50%, transparent 0%, transparent 38%, rgba(4,4,10,0.55) 80%, rgba(4,4,10,0.85) 100%),
    linear-gradient(180deg, rgba(4,4,10,0.55) 0%, transparent 16%, transparent 80%, rgba(4,4,10,0.7) 100%);
  mix-blend-mode: multiply;
}

/* very subtle grain — texture, not noise */
.grain {
  position: fixed;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  opacity: 0.035;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='1.4' numOctaves='3' stitchTiles='stitch'/></filter><rect width='100%25' height='100%25' filter='url(%23n)' opacity='0.9'/></svg>");
}

/* ── HUD (fixed UI chrome on top of canvas) ── */
.hud {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 10;
}
.hud > * { pointer-events: auto; }

/* top bar */
.hud-top {
  position: absolute;
  top: 18px; left: 22px; right: 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 10px 16px;
  background: var(--bg-panel);
  border: 1px solid var(--edge);
  border-radius: 999px;
  backdrop-filter: blur(18px) saturate(120%);
  -webkit-backdrop-filter: blur(18px) saturate(120%);
}
.hud-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 14px;
  letter-spacing: -0.01em;
  padding-right: 14px;
  border-right: 1px solid var(--edge);
  color: var(--text);
}
.hud-brand-dot {
  width: 7px; height: 7px;
  background: var(--amber);
  border-radius: 50%;
  animation: pulseDot 2.2s ease-in-out infinite;
}
.hud-brand-text i {
  color: var(--text-mute);
  font-style: normal;
  font-weight: 400;
}
@keyframes pulseDot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%      { opacity: 0.55; transform: scale(0.82); }
}

.hud-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  flex: 1;
  justify-content: center;
}
.hud-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 11px;
  font-size: 13.5px;
  font-weight: 400;
  color: var(--text-dim);
  border-radius: 999px;
  transition: color 160ms, background 160ms;
  position: relative;
  letter-spacing: -0.005em;
}
.hud-link:hover,
.hud-link.is-active {
  color: var(--text);
}
.hud-link.is-active { color: var(--text); background: rgba(255,255,255,0.05); }
.hud-link-idx {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-mute);
  opacity: 0.5;
}
.hud-link.is-active .hud-link-idx { color: var(--amber); opacity: 1; }

.hud-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}
.hud-switcher {
  appearance: none;
  -webkit-appearance: none;
  padding: 7px 26px 7px 12px;
  font-family: var(--font-mono);
  font-size: 12px;
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--edge);
  border-radius: 999px;
  color: var(--text);
  background-image:
    linear-gradient(45deg, transparent 50%, var(--text-dim) 50%),
    linear-gradient(-45deg, transparent 50%, var(--text-dim) 50%);
  background-position:
    calc(100% - 12px) 50%,
    calc(100% - 8px) 50%;
  background-size: 4px 4px;
  background-repeat: no-repeat;
  transition: border-color 180ms, background 180ms;
}
.hud-switcher:hover { border-color: var(--edge-hi); }
.hud-switcher:focus { outline: none; border-color: var(--cyan); }
.hud-switcher option { background: var(--bg-panel-solid); color: var(--text); }

.hud-resume {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 12px;
  font-family: var(--font-body);
  font-size: 12.5px;
  font-weight: 500;
  background: var(--text);
  border: 1px solid var(--text);
  border-radius: 999px;
  color: #18181b;
  transition: background 180ms, transform 180ms;
  letter-spacing: -0.005em;
}
.hud-resume:hover {
  background: #ffffff;
  border-color: #ffffff;
  transform: translateY(-1px);
}
.hud-resume-dot {
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--amber);
}

/* right rail */
.hud-rail {
  position: absolute;
  right: 22px;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 14px 8px;
}
.rail-track {
  position: absolute;
  top: 14px; bottom: 14px;
  width: 1px;
  background: linear-gradient(180deg, transparent, var(--edge) 20%, var(--edge) 80%, transparent);
  left: 50%; transform: translateX(-50%);
}
.rail-ticks {
  display: flex;
  flex-direction: column;
  gap: 18px;
  position: relative;
}
.rail-tick {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: transparent;
  border: 1px solid var(--edge-hi);
  transition: background 220ms, border-color 220ms, transform 220ms;
  cursor: none;
}
.rail-tick.is-active {
  background: var(--cyan);
  border-color: var(--cyan);
  transform: scale(1.3);
  box-shadow: 0 0 10px var(--cyan);
}
.rail-caption {
  position: absolute;
  right: 30px;
  top: 50%;
  transform: translateY(-50%);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.15em;
  color: var(--text-mute);
  text-transform: uppercase;
  writing-mode: vertical-rl;
  transform-origin: center;
  transform: rotate(180deg) translateX(-10px);
  white-space: nowrap;
}

/* bottom bar */
.hud-bottom {
  position: absolute;
  left: 24px; right: 24px; bottom: 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-dim);
  background: rgba(10, 12, 24, 0.55);
  border: 1px solid var(--edge);
  border-radius: 999px;
  padding: 8px 18px;
  backdrop-filter: blur(18px) saturate(140%);
  -webkit-backdrop-filter: blur(18px) saturate(140%);
}
.hud-bottom-left,
.hud-bottom-right {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}
.hud-stat {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}
.hud-stat b {
  color: var(--text);
  font-weight: 500;
}
.hud-stat i { color: var(--cyan); font-style: normal; margin: 0 1px; }
.hud-stat-dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--text-mute);
}
.hud-stat-dot--live {
  background: var(--online);
  box-shadow: 0 0 8px rgba(88, 214, 141, 0.55);
  animation: pulseDot 1.8s ease-in-out infinite;
}
.hud-stat-sep {
  width: 1px; height: 12px;
  background: var(--edge);
}

/* audio toggle */
.hud-audio {
  position: absolute;
  left: 24px;
  top: 50%;
  transform: translateY(-50%);
  width: 40px; height: 40px;
  display: grid; place-items: center;
  background: rgba(10, 12, 24, 0.55);
  border: 1px solid var(--edge);
  border-radius: 50%;
  backdrop-filter: blur(12px);
  transition: background 180ms, border-color 180ms;
}
.hud-audio:hover { border-color: var(--edge-hi); }
.hud-audio .wave {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  height: 16px;
}
.hud-audio .wave span {
  width: 2px;
  height: 6px;
  background: var(--text-dim);
  border-radius: 2px;
  transition: background 180ms, height 180ms;
}
.hud-audio[aria-pressed="true"] .wave span {
  background: var(--cyan);
  animation: waveBounce 1s ease-in-out infinite;
}
.hud-audio[aria-pressed="true"] .wave span:nth-child(2) { animation-delay: 0.15s; }
.hud-audio[aria-pressed="true"] .wave span:nth-child(3) { animation-delay: 0.3s; }
.hud-audio[aria-pressed="true"] .wave span:nth-child(4) { animation-delay: 0.45s; }
@keyframes waveBounce {
  0%, 100% { height: 4px; }
  50%      { height: 14px; }
}

/* ── DRIVER / STATIONS ── */
.driver {
  position: relative;
  z-index: 5;
}

.station {
  position: relative;
  min-height: var(--station-h);
  padding: 120px 24px 120px;
  display: flex;
  align-items: center;
}
.station-inner {
  width: min(1240px, 100%);
  margin: 0 auto;
  position: relative;
  z-index: 2;
}
.station-head {
  display: flex;
  align-items: baseline;
  gap: 20px;
  margin-bottom: 52px;
}
.station-idx {
  font-family: var(--font-mono);
  font-size: 12.5px;
  color: var(--text-mute);
  letter-spacing: 0.04em;
  padding-top: 0.25em;
}
.station-title {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: clamp(32px, 4.5vw, 56px);
  letter-spacing: -0.025em;
  line-height: 1.05;
  color: var(--text);
}
.station-title em {
  font-family: var(--font-editorial);
  font-style: italic;
  font-weight: 400;
  color: var(--amber);
  letter-spacing: -0.005em;
}

/* ── HERO ── */
.station--hero {
  min-height: 100vh;
  max-height: 100vh;
  padding-top: 130px;
  padding-bottom: 80px;
}
.hero-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: 60px;
  align-items: center;
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 11px;
  font-family: var(--font-body);
  font-size: 12.5px;
  font-weight: 500;
  letter-spacing: 0.01em;
  color: var(--text-dim);
  background: transparent;
  border: 1px solid var(--edge);
  border-radius: 999px;
  margin-bottom: 28px;
}
.tag-dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--amber);
  box-shadow: 0 0 10px rgba(217, 163, 103, 0.45);
  animation: pulseDot 1.8s ease-in-out infinite;
}
.tag--live { color: var(--text); }

/* Hero name — editorial: sans-semibold + italic serif accent. Mixed case, quiet 3D tilt only. */
.hero-title {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: clamp(56px, 10vw, 148px);
  line-height: 0.94;
  letter-spacing: -0.035em;
  margin-bottom: 18px;
  color: var(--text);
  position: relative;
  perspective: 1200px;
  user-select: none;
  --rx: 0deg;
  --ry: 0deg;
}
.hero-title-word {
  display: inline-block;
  transform: rotateX(var(--rx)) rotateY(var(--ry));
  transition: transform 400ms cubic-bezier(.22,1,.36,1);
}
.hero-title-word--a {
  color: var(--text);
  margin-right: 0.15em;
}
.hero-title-word--b {
  font-family: var(--font-editorial);
  font-style: italic;
  font-weight: 400;
  color: var(--amber);
  letter-spacing: -0.01em;
}
.tw-char {
  display: inline-block;
  opacity: 0;
  transform: translateY(0.4em);
  animation: charIn 700ms cubic-bezier(.22,1,.36,1) forwards;
  animation-delay: calc(var(--d, 0) * 42ms + 200ms);
  will-change: transform, opacity;
}
.tw-char.tw-space { width: 0.28em; }
@keyframes charIn {
  from { opacity: 0; transform: translateY(0.45em); }
  to   { opacity: 1; transform: translateY(0); }
}
.hero-kicker {
  font-family: var(--font-body);
  font-size: clamp(16px, 1.15vw, 19px);
  color: var(--text-dim);
  letter-spacing: -0.005em;
  margin-bottom: 22px;
  font-weight: 400;
}
.hero-kicker em {
  font-family: var(--font-editorial);
  font-style: italic;
  font-weight: 400;
  color: var(--text);
  font-size: 1.08em;
  margin-right: 6px;
}

.hero-lead {
  font-size: clamp(16px, 1.15vw, 18px);
  color: var(--text-dim);
  max-width: 560px;
  line-height: 1.7;
  margin-bottom: 32px;
}
.hero-lead b {
  color: var(--text);
  font-weight: 500;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 20px;
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: -0.005em;
  border-radius: 10px;
  border: 1px solid transparent;
  transition: background 180ms var(--ease-out), border-color 180ms, color 180ms, transform 180ms;
  white-space: nowrap;
}
.btn--primary {
  background: var(--text);
  color: #18181b;
  border-color: var(--text);
}
.btn--primary:hover {
  background: #ffffff;
  border-color: #ffffff;
  transform: translateY(-1px);
}
.btn--ghost {
  background: transparent;
  color: var(--text);
  border-color: var(--edge-hi);
}
.btn--ghost:hover {
  background: rgba(255,255,255,0.04);
  border-color: rgba(255,255,255,0.3);
}
.btn--wide { width: 100%; justify-content: center; padding: 13px 20px; }

.hero-chips {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  list-style: none;
}
.hero-chips li {
  font-family: var(--font-body);
  font-size: 12.5px;
  color: var(--text-mute);
  padding: 3px 0;
  border: 0;
  background: transparent;
  position: relative;
}
.hero-chips li:not(:last-child)::after {
  content: "·";
  margin-left: 8px;
  color: var(--text-mute);
  opacity: 0.5;
}

.hero-right {
  position: relative;
  height: 100%;
  min-height: 420px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.core-ident {
  min-width: 280px;
  padding: 18px 20px;
  background: var(--bg-panel);
  border: 1px solid var(--edge);
  border-radius: var(--radius);
  backdrop-filter: blur(14px) saturate(120%);
  box-shadow: var(--shadow-panel);
  position: relative;
}
.core-ident-head {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-body);
  font-size: 12.5px;
  color: var(--text-dim);
  letter-spacing: -0.005em;
  margin-bottom: 14px;
  font-weight: 500;
}
.core-ident-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--amber);
  animation: pulseDot 2s ease-in-out infinite;
}
.core-ident-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px 24px;
}
.core-ident-stats div { display: flex; flex-direction: column; gap: 3px; }
.core-ident-stats dt {
  font-family: var(--font-body);
  font-size: 12px;
  color: var(--text-mute);
  letter-spacing: -0.005em;
  font-weight: 400;
}
.core-ident-stats dd {
  font-family: var(--font-body);
  font-size: 22px;
  font-weight: 600;
  color: var(--text);
  letter-spacing: -0.02em;
}
.core-ident-stats b {
  color: var(--cyan);
  font-weight: 700;
}

/* ── AI TERMINAL — quiet editorial treatment ── */
.panel--ai {
  padding: 0;
  background: var(--bg-panel-ai);
  border: 1px solid var(--edge);
  box-shadow: var(--shadow-panel);
  display: flex;
  flex-direction: column;
  min-height: 340px;
  max-height: 460px;
}
.panel--ai::before { display: none; }
.ai-term-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 18px;
  border-bottom: 1px solid var(--edge);
  background: transparent;
  gap: 12px;
}
.ai-term-head-left,
.ai-term-head-right {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.ai-term-avatar {
  position: relative;
  width: 28px; height: 28px;
  border-radius: 50%;
  background: #1a1a1e;
  border: 1px solid var(--edge-hi);
  flex-shrink: 0;
  overflow: hidden;
}
.ai-term-avatar::before {
  display: none;
}
.ai-term-avatar-core {
  position: absolute;
  inset: 35%;
  background: var(--amber);
  border-radius: 50%;
  animation: aiPulse 2.6s ease-in-out infinite;
}
@keyframes aiPulse {
  0%, 100% { transform: scale(1);   opacity: 0.7; }
  50%      { transform: scale(1.3); opacity: 1; }
}
.ai-term-title {
  display: flex;
  flex-direction: column;
  gap: 2px;
  line-height: 1.15;
}
.ai-term-name {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 14px;
  letter-spacing: -0.01em;
  color: var(--text);
}
.ai-term-name i { color: var(--text-mute); font-style: normal; font-weight: 400; }
.ai-term-sub {
  font-family: var(--font-body);
  font-size: 12px;
  color: var(--text-mute);
  letter-spacing: -0.005em;
}
.ai-term-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 10px;
  font-family: var(--font-body);
  font-size: 11.5px;
  color: var(--text-dim);
  background: transparent;
  border: 1px solid var(--edge);
  border-radius: 999px;
  letter-spacing: -0.005em;
}
.ai-term-pill-dot {
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--online);
  box-shadow: 0 0 6px rgba(88, 214, 141, 0.55);
  animation: pulseDot 1.6s ease-in-out infinite;
}
.ai-term-clear {
  font-family: var(--font-body);
  font-size: 12px;
  color: var(--text-mute);
  padding: 3px 8px;
  border-radius: 4px;
  transition: color 160ms;
}
.ai-term-clear:hover {
  color: var(--text);
}

.ai-term-log {
  flex: 1;
  overflow-y: auto;
  padding: 16px 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-size: 14px;
  line-height: 1.6;
  color: var(--text);
  scrollbar-width: thin;
  scrollbar-color: var(--edge-hi) transparent;
}
.ai-term-log::-webkit-scrollbar { width: 6px; }
.ai-term-log::-webkit-scrollbar-track { background: transparent; }
.ai-term-log::-webkit-scrollbar-thumb { background: var(--edge-hi); border-radius: 3px; }

.ai-msg {
  display: flex;
  gap: 10px;
  padding: 0;
  border-radius: 0;
  animation: msgIn 320ms var(--ease-out);
}
@keyframes msgIn {
  from { opacity: 0; transform: translateY(4px); }
  to   { opacity: 1; transform: translateY(0); }
}
.ai-msg b { color: var(--text); font-weight: 500; }
.ai-msg--sys   { color: var(--text-dim); }
.ai-msg--user  { color: var(--text); }
.ai-msg--ai    { color: var(--text); white-space: pre-wrap; }
.ai-msg--err   { color: var(--magenta); }
.ai-msg-tag {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-mute);
  letter-spacing: -0.005em;
  flex-shrink: 0;
  padding-top: 2px;
  min-width: 40px;
}
.ai-msg--user .ai-msg-tag { color: var(--amber); }
.ai-msg--ai .ai-msg-tag   { color: var(--text-dim); }

/* AI response markdown styles */
.ai-msg-body        { flex: 1; min-width: 0; }
.ai-msg-body p      { margin: 0 0 8px; line-height: 1.6; }
.ai-msg-body p:last-child { margin-bottom: 0; }
.ai-msg-body ul,
.ai-msg-body ol     { margin: 6px 0 10px; padding-left: 22px; }
.ai-msg-body ul:last-child,
.ai-msg-body ol:last-child { margin-bottom: 0; }
.ai-msg-body li     { margin: 4px 0; line-height: 1.55; }
.ai-msg-body li::marker { color: var(--text-mute); }
.ai-msg-body strong { color: var(--text); font-weight: 600; }
.ai-msg-body em     { color: var(--text); font-style: italic; font-family: var(--font-editorial); font-size: 1.04em; }
.ai-msg-body code   {
  font-family: var(--font-mono);
  font-size: 0.88em;
  padding: 1px 6px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--edge);
  border-radius: 4px;
  color: var(--amber);
}
.ai-msg-body a { color: var(--amber); text-decoration: underline; text-underline-offset: 2px; }
.ai-msg-body a:hover { color: var(--text); }

.ai-reveal { animation: aiReveal 360ms var(--ease-out); }
@keyframes aiReveal {
  from { opacity: 0; transform: translateY(3px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* thinking dots */
.ai-thinking {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--text-dim);
  font-family: var(--font-mono);
  font-size: 12.5px;
}
.ai-thinking-dots {
  display: inline-flex;
  gap: 3px;
}
.ai-thinking-dots span {
  width: 4px; height: 4px;
  border-radius: 50%;
  background: var(--text-dim);
  animation: thinkDot 1.2s ease-in-out infinite;
}
.ai-thinking-dots span:nth-child(2) { animation-delay: 0.18s; }
.ai-thinking-dots span:nth-child(3) { animation-delay: 0.36s; }
@keyframes thinkDot {
  0%, 100% { opacity: 0.25; transform: translateY(0); }
  50%      { opacity: 1;    transform: translateY(-3px); }
}

.ai-cursor {
  display: inline-block;
  width: 7px;
  height: 14px;
  background: var(--text);
  vertical-align: middle;
  margin-left: 2px;
  animation: blinkCaret 0.9s steps(2, start) infinite;
}
@keyframes blinkCaret {
  0%, 100% { opacity: 1; }
  50%      { opacity: 0; }
}

.ai-term-chips {
  display: flex;
  gap: 6px;
  padding: 10px 16px;
  border-top: 1px solid var(--edge);
  border-bottom: 1px solid var(--edge);
  overflow-x: auto;
  scrollbar-width: none;
}
.ai-term-chips::-webkit-scrollbar { display: none; }
.ai-chip {
  flex-shrink: 0;
  padding: 5px 11px;
  font-family: var(--font-body);
  font-size: 12px;
  color: var(--text-dim);
  background: transparent;
  border: 1px solid var(--edge);
  border-radius: 999px;
  transition: color 160ms, border-color 160ms, background 160ms;
  white-space: nowrap;
  letter-spacing: -0.005em;
}
.ai-chip:hover {
  color: var(--text);
  border-color: var(--edge-hi);
  background: rgba(255, 255, 255, 0.03);
}

.ai-term-input {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 18px;
  border-top: 1px solid var(--edge);
  background: rgba(0, 0, 0, 0.2);
}
.ai-term-prompt {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--text-mute);
  flex-shrink: 0;
}
.ai-term-input-field {
  flex: 1;
  background: transparent;
  border: 0;
  outline: none;
  color: var(--text);
  font-family: var(--font-body);
  font-size: 14px;
  padding: 6px 0;
  letter-spacing: -0.005em;
}
.ai-term-input-field::placeholder {
  color: var(--text-mute);
}
.ai-term-send {
  width: 30px; height: 30px;
  display: grid; place-items: center;
  color: var(--text-dim);
  background: transparent;
  border: 1px solid var(--edge-hi);
  border-radius: 8px;
  transition: color 160ms, background 160ms;
}
.ai-term-send:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.04);
}
.ai-term-send:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.scroll-cue {
  position: absolute;
  left: 50%;
  bottom: 32px;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  font-family: var(--font-body);
  font-size: 11.5px;
  color: var(--text-mute);
  letter-spacing: -0.005em;
}
.scroll-cue-text { text-transform: none; }
.scroll-cue-line {
  width: 1px;
  height: 30px;
  background: linear-gradient(180deg, var(--text-dim), transparent);
  animation: scrollCue 2.2s var(--ease-out) infinite;
  transform-origin: top center;
}
@keyframes scrollCue {
  0%   { transform: scaleY(0); }
  40%  { transform: scaleY(1); }
  100% { transform: scaleY(0) translateY(30px); }
}

/* ── PANEL — quiet, flat, one thin hairline border ── */
.panel {
  position: relative;
  padding: 26px 28px;
  background: var(--bg-panel);
  border: 1px solid var(--edge);
  border-radius: var(--radius);
  backdrop-filter: blur(14px) saturate(120%);
  -webkit-backdrop-filter: blur(14px) saturate(120%);
  box-shadow: var(--shadow-panel);
  overflow: hidden;
  transition: border-color 240ms, background 240ms;
}
.panel::before {
  display: none; /* no tint overlays */
}
.panel:hover {
  border-color: var(--edge-hi);
  background: var(--bg-panel-hi);
}

.panel--lg { padding: 34px 34px; }
.panel-head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding-bottom: 16px;
  margin-bottom: 20px;
  border-bottom: 1px solid var(--edge);
}
.panel-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--amber);
}
.panel-label {
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: var(--text-mute);
  letter-spacing: 0.02em;
  text-transform: none;
}
.panel-body { display: flex; flex-direction: column; gap: 14px; }

/* ── ABOUT ── */
.about-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-auto-rows: auto;
  gap: 18px;
}
.about-bio {
  grid-column: span 2;
  grid-row: span 2;
}
.about-photo {
  grid-column: span 2;
  grid-row: span 2;
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 18px;
}
.about-lead {
  font-family: var(--font-body);
  font-size: 17px;
  color: var(--text);
  line-height: 1.65;
  font-weight: 400;
  letter-spacing: -0.005em;
}
.about-lead b, .about-bio b { color: var(--text); font-weight: 600; }
.about-bio p {
  color: var(--text-dim);
  line-height: 1.72;
  font-size: 15.5px;
}
.about-bio i { color: var(--text); font-style: italic; font-family: var(--font-body); }

.about-facts {
  list-style: none;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px 16px;
  margin-top: 4px;
  padding-top: 14px;
  border-top: 1px dashed var(--edge);
}
.about-facts li {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.fact-k {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-mute);
  letter-spacing: 0.15em;
  text-transform: uppercase;
}
.fact-v { color: var(--text); font-weight: 500; font-size: 14px; }

.photo-frame {
  position: relative;
  aspect-ratio: 4 / 5;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid var(--edge-hi);
}
.photo-img {
  width: 100%; height: 100%;
  object-fit: cover;
  filter: saturate(0.95) contrast(1.04);
  transition: transform 6s var(--ease-out);
}
.about-photo:hover .photo-img { transform: scale(1.05); }
.photo-scan {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 40%, rgba(0,245,255,0.22) 50%, transparent 60%);
  mix-blend-mode: screen;
  animation: photoScan 5s linear infinite;
  pointer-events: none;
}
@keyframes photoScan {
  from { transform: translateY(-60%); }
  to   { transform: translateY(60%); }
}
.photo-corners span {
  position: absolute;
  width: 14px; height: 14px;
  border: 1.5px solid var(--cyan);
}
.photo-corners span:nth-child(1) { top: 10px; left: 10px; border-right: 0; border-bottom: 0; }
.photo-corners span:nth-child(2) { top: 10px; right: 10px; border-left: 0; border-bottom: 0; }
.photo-corners span:nth-child(3) { bottom: 10px; left: 10px; border-right: 0; border-top: 0; }
.photo-corners span:nth-child(4) { bottom: 10px; right: 10px; border-left: 0; border-top: 0; }
.photo-meta {
  display: flex;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 11px;
}
.photo-meta-k { color: var(--text-mute); letter-spacing: 0.12em; text-transform: uppercase; }
.photo-meta-v { color: var(--cyan); }

.about-stat {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 22px 24px;
  min-height: 170px;
}
.about-stat--a::before,
.about-stat--b::before,
.about-stat--c::before,
.about-stat--d::before { display: none; }

.stat-num {
  font-family: var(--font-body);
  font-size: clamp(42px, 4.5vw, 60px);
  font-weight: 600;
  letter-spacing: -0.035em;
  line-height: 1;
  color: var(--text);
}
.stat-num b { color: var(--text); font-weight: 600; }
.stat-unit {
  font-size: 0.5em;
  color: var(--text-mute);
  font-weight: 500;
  margin-left: 2px;
  letter-spacing: -0.01em;
}
.stat-desc {
  color: var(--text-dim);
  font-size: 14.5px;
  line-height: 1.6;
  letter-spacing: -0.005em;
}

/* ── STACK ── */
.stack-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
.stack-col {
  padding: 20px 22px;
  background: var(--bg-panel);
  border: 1px solid var(--edge);
  border-radius: var(--radius);
  backdrop-filter: blur(14px) saturate(140%);
  transition: border-color 200ms, transform 220ms var(--ease-out);
}
.stack-col:hover {
  border-color: var(--edge-hi);
  transform: translateY(-2px);
}
.stack-col--wide { grid-column: span 4; }
.stack-col-head {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-mute);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  margin-bottom: 14px;
}
.stack-col-idx {
  width: 20px; height: 20px;
  display: grid; place-items: center;
  font-size: 10px;
  color: var(--cyan);
  background: rgba(0,245,255,0.08);
  border: 1px solid rgba(0,245,255,0.3);
  border-radius: 4px;
}
.stack-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.chip {
  display: inline-flex;
  align-items: center;
  padding: 5px 11px;
  font-size: 13px;
  font-weight: 400;
  color: var(--text-dim);
  background: transparent;
  border: 1px solid var(--edge);
  border-radius: 999px;
  transition: color 160ms, border-color 160ms, background 160ms;
}
.chip:hover {
  color: var(--text);
  border-color: var(--edge-hi);
  background: rgba(255,255,255,0.03);
}
.chip--hot {
  color: var(--text);
  border-color: var(--edge-hi);
  background: rgba(255,255,255,0.04);
}
.chip--accent {
  color: var(--amber);
  border-color: rgba(217, 163, 103, 0.35);
  background: transparent;
}

/* ── WORK ── */
.work-timeline {
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.exp-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}
.exp-co {
  font-family: var(--font-body);
  font-size: 26px;
  font-weight: 600;
  letter-spacing: -0.025em;
  line-height: 1.2;
  margin-bottom: 6px;
  color: var(--text);
}
.exp-product {
  font-family: var(--font-editorial);
  font-style: italic;
  font-weight: 400;
  color: var(--text-dim);
  letter-spacing: -0.01em;
}
.exp-role {
  font-size: 14px;
  color: var(--text-dim);
  font-weight: 500;
}
.exp-meta {
  display: flex;
  flex-direction: column;
  gap: 2px;
  align-items: flex-end;
  font-family: var(--font-mono);
  font-size: 12px;
}
.exp-date { color: var(--text); }
.exp-loc { color: var(--text-mute); }
.exp-body {
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.exp-grp-title {
  font-family: var(--font-body);
  font-size: 12px;
  color: var(--text-mute);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: 10px;
  font-weight: 500;
}
.exp-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 9px;
}
.exp-list li {
  position: relative;
  padding-left: 20px;
  color: var(--text-dim);
  font-size: 14.5px;
  line-height: 1.7;
  letter-spacing: -0.005em;
}
.exp-list li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 0.65em;
  width: 10px;
  height: 1px;
  background: var(--text-mute);
}
.exp-list li b { color: var(--text); font-weight: 500; }
.exp-list li em {
  font-style: italic;
  font-weight: 400;
  font-family: var(--font-editorial);
  color: var(--amber);
  padding: 0 1px;
  font-size: 1.05em;
}
.exp-list a { color: var(--text); text-decoration: underline; text-underline-offset: 3px; text-decoration-color: var(--edge-hi); }
.exp-list a:hover { text-decoration-color: var(--amber); }
.exp-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px dashed var(--edge);
}
.tag {
  display: inline-block;
  padding: 3px 9px;
  font-family: var(--font-body);
  font-size: 12px;
  color: var(--text-mute);
  background: transparent;
  border: 1px solid var(--edge);
  border-radius: 4px;
  letter-spacing: -0.005em;
}
.tag--accent {
  color: var(--amber);
  background: transparent;
  border-color: rgba(217, 163, 103, 0.35);
}

/* ── BUILDS ── */
.builds-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
.build {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-height: 240px;
  position: relative;
}
.build--featured {
  grid-column: span 2;
  background: var(--bg-panel-hi);
  border-color: var(--edge-hi);
}
.build-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}
.build-kind {
  font-family: var(--font-body);
  font-size: 12px;
  color: var(--text-mute);
  letter-spacing: 0.02em;
  text-transform: none;
  font-weight: 400;
}
.build-link {
  width: 30px; height: 30px;
  display: grid; place-items: center;
  background: transparent;
  border: 1px solid var(--edge);
  border-radius: 8px;
  color: var(--text-dim);
  transition: color 160ms, border-color 160ms;
}
.build-link:hover {
  color: var(--text);
  border-color: var(--edge-hi);
}
.build-badge {
  font-family: var(--font-body);
  font-size: 11.5px;
  color: var(--amber);
  padding: 2px 8px;
  border: 1px solid rgba(217, 163, 103, 0.35);
  border-radius: 4px;
  background: transparent;
  letter-spacing: -0.005em;
}
.build-name {
  font-family: var(--font-body);
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--text);
}
.build-desc {
  color: var(--text-dim);
  font-size: 14.5px;
  line-height: 1.65;
  flex: 1;
  letter-spacing: -0.005em;
}
.build-desc b { color: var(--text); font-weight: 500; }
.build-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  padding-top: 12px;
  border-top: 1px dashed var(--edge);
}

/* ── EDUCATION ── */
.edu-grid {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 18px;
  align-items: start;
}
.edu-entries {
  display: flex;
  flex-direction: column;
  gap: 22px;
}
.edu-entry {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 20px;
  padding: 16px 0;
  border-bottom: 1px dashed var(--edge);
}
.edu-entry:last-child { border-bottom: 0; padding-bottom: 0; }
.edu-year {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--cyan);
  letter-spacing: 0.08em;
}
.edu-body { display: flex; flex-direction: column; gap: 6px; }
.edu-degree {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
  color: var(--text);
}
.edu-school {
  color: var(--text-dim);
  font-size: 14px;
}
.edu-tags { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 4px; }

.certs-list {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px 8px;
}
.certs-list li a {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 10px 12px;
  border-radius: 8px;
  border: 1px solid var(--edge);
  background: rgba(255,255,255,0.015);
  transition: background 180ms, border-color 180ms, transform 180ms;
  height: 100%;
}
.certs-list li a:hover {
  transform: translateY(-1px);
}
.certs-list li a:hover {
  background: rgba(0,245,255,0.06);
  border-color: rgba(0,245,255,0.18);
}
.cert-name {
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
  line-height: 1.35;
}
.cert-issuer {
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: var(--text-mute);
  letter-spacing: 0.04em;
}
.certs-foot {
  margin-top: 14px;
  padding: 10px 14px;
  font-family: var(--font-body);
  font-size: 13px;
  color: var(--text-dim);
  background: transparent;
  border: 1px dashed var(--edge);
  border-radius: 8px;
  text-align: center;
  letter-spacing: -0.005em;
}

/* ── RECOMMENDATIONS — editorial pull quotes ── */
.recs-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}
.rec-card {
  position: relative;
  padding: 36px 30px 28px;
  background: var(--bg-panel);
  border: 1px solid var(--edge);
  border-radius: var(--radius);
  backdrop-filter: blur(14px) saturate(120%);
  transition: border-color 240ms, background 240ms, transform 240ms var(--ease-out);
}
.rec-card::before {
  content: "\201C";                        /* “ — typographic left quote */
  position: absolute;
  top: 4px; left: 18px;
  font-family: var(--font-editorial);
  font-style: italic;
  font-size: 72px;
  line-height: 1;
  color: var(--amber);
  opacity: 0.5;
  pointer-events: none;
}
.rec-card:hover {
  border-color: var(--edge-hi);
  background: var(--bg-panel-hi);
  transform: translateY(-2px);
}
.rec-quote {
  font-family: var(--font-editorial);
  font-style: italic;
  font-size: clamp(17px, 1.2vw, 19px);
  line-height: 1.55;
  color: var(--text);
  letter-spacing: -0.005em;
  margin: 0 0 22px;
}
.rec-footer {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding-top: 16px;
  border-top: 1px solid var(--edge);
}
.rec-name {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 14.5px;
  color: var(--text);
  letter-spacing: -0.01em;
}
.rec-role {
  font-family: var(--font-body);
  font-size: 12.5px;
  color: var(--text-mute);
  letter-spacing: -0.005em;
}

/* ── CONTACT ── */
.contact-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 32px;
  align-items: start;
}
.contact-info {
  padding: 16px;
}
.contact-lead {
  font-size: 18px;
  color: var(--text-dim);
  line-height: 1.55;
  margin-bottom: 28px;
  max-width: 480px;
}
.contact-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.contact-list li a {
  display: grid;
  grid-template-columns: 100px 1fr;
  gap: 16px;
  align-items: center;
  padding: 14px 18px;
  background: var(--bg-panel);
  border: 1px solid var(--edge);
  border-radius: var(--radius-sm);
  backdrop-filter: blur(14px);
  transition: border-color 180ms, transform 180ms var(--ease-out);
}
.contact-list li a:hover {
  border-color: var(--edge-hi);
  background: var(--bg-panel-hi);
}
.contact-k {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-mute);
  letter-spacing: 0.18em;
  text-transform: uppercase;
}
.contact-v {
  font-size: 14.5px;
  font-weight: 500;
  color: var(--text);
}

.contact-form { padding: 0; }
.contact-form .panel-body { padding: 20px 24px 24px; }
.field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.field-label {
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: var(--text-mute);
  letter-spacing: 0.2em;
  text-transform: uppercase;
}
.field input,
.field textarea {
  width: 100%;
  padding: 12px 14px;
  background: rgba(0,0,0,0.3);
  border: 1px solid var(--edge);
  border-radius: 8px;
  color: var(--text);
  font-size: 14px;
  transition: border-color 180ms, background 180ms;
  font-family: var(--font-body);
}
.field textarea { resize: vertical; min-height: 120px; font-family: var(--font-body); }
.field input:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--edge-hi);
  background: rgba(0,0,0,0.45);
  box-shadow: 0 0 0 3px rgba(255,255,255,0.06);
}
.field input::placeholder,
.field textarea::placeholder {
  color: var(--text-mute);
  font-family: var(--font-body);
}

.station-foot {
  margin-top: 64px;
  padding-top: 24px;
  border-top: 1px dashed var(--edge);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: var(--text-mute);
  letter-spacing: 0.08em;
}
.back-top {
  color: var(--cyan);
  transition: color 180ms;
}
.back-top:hover { color: var(--magenta); }

/* ── PLANET FOCUS PANEL ── */
.planet-panel {
  position: fixed;
  top: 120px;
  right: 22px;
  width: min(360px, 92vw);
  max-height: calc(100vh - 180px);
  background: var(--bg-panel-solid);
  border: 1px solid var(--edge);
  border-radius: var(--radius);
  box-shadow: var(--shadow-panel);
  backdrop-filter: blur(14px) saturate(120%);
  z-index: 60;
  transform: translateX(24px);
  opacity: 0;
  pointer-events: none;
  transition: transform 320ms var(--ease-out), opacity 320ms var(--ease-out);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.planet-panel[hidden] { display: none; }
.planet-panel.is-open {
  transform: translateX(0);
  opacity: 1;
  pointer-events: auto;
}
.pp-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  border-bottom: 1px solid var(--edge);
}
.pp-head-left { display: inline-flex; align-items: center; gap: 8px; }
.pp-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--amber);
  animation: pulseDot 1.8s ease-in-out infinite;
}
.pp-kicker {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-mute);
  letter-spacing: 0.04em;
}
.pp-close {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 9px;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-mute);
  background: transparent;
  border: 1px solid var(--edge);
  border-radius: 6px;
  transition: color 160ms, border-color 160ms, background 160ms;
}
.pp-close:hover { color: var(--text); border-color: var(--edge-hi); background: rgba(255,255,255,0.04); }
.pp-close span { font-size: 12px; }
.pp-body {
  padding: 20px 22px 22px;
  overflow-y: auto;
}
.pp-name {
  font-family: var(--font-body);
  font-size: 34px;
  font-weight: 600;
  letter-spacing: -0.03em;
  color: var(--text);
  margin-bottom: 6px;
}
.pp-sub {
  font-family: var(--font-editorial);
  font-style: italic;
  font-size: 17px;
  color: var(--text-dim);
  letter-spacing: -0.005em;
  margin-bottom: 18px;
}
.pp-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px 16px;
  padding: 14px 0;
  border-top: 1px solid var(--edge);
  border-bottom: 1px solid var(--edge);
}
.pp-stats div { display: flex; flex-direction: column; gap: 3px; }
.pp-stats dt {
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: var(--text-mute);
  letter-spacing: 0.02em;
}
.pp-stats dd {
  font-family: var(--font-body);
  font-size: 15.5px;
  font-weight: 500;
  color: var(--text);
  letter-spacing: -0.01em;
}
.pp-note {
  margin-top: 16px;
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-dim);
  letter-spacing: -0.005em;
}
.pp-note em {
  font-family: var(--font-editorial);
  font-style: italic;
  color: var(--text);
  font-size: 1.05em;
}

/* Hover cursor on canvas when a planet is under the pointer */
body.is-planet-hover { cursor: pointer; }

@media (max-width: 780px) {
  .planet-panel {
    top: auto;
    bottom: 70px;
    right: 12px;
    left: 12px;
    width: auto;
    max-height: 60vh;
  }
}

/* ── MODAL ── */
.modal {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: grid;
  place-items: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 240ms, visibility 240ms;
}
.modal[hidden] { display: none; }
.modal.is-open {
  opacity: 1;
  visibility: visible;
}
.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(2, 4, 12, 0.7);
  backdrop-filter: blur(8px);
}
.modal-panel {
  position: relative;
  width: min(960px, 94vw);
  height: min(86vh, 1000px);
  background: var(--bg-panel-solid);
  border: 1px solid var(--edge-hi);
  border-radius: var(--radius);
  box-shadow: 0 40px 120px rgba(0,0,0,0.6), 0 0 60px rgba(0,245,255,0.12);
  display: flex;
  flex-direction: column;
  transform: translateY(16px) scale(0.98);
  transition: transform 280ms var(--ease-spring);
  overflow: hidden;
}
.modal.is-open .modal-panel { transform: translateY(0) scale(1); }
.modal-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 18px;
  border-bottom: 1px solid var(--edge);
  background: rgba(0,0,0,0.3);
}
.modal-head-left,
.modal-head-right { display: inline-flex; align-items: center; gap: 12px; }
.modal-title {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text);
  letter-spacing: 0.08em;
}
.modal-download {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--cyan);
  padding: 5px 10px;
  border: 1px solid rgba(0,245,255,0.3);
  border-radius: 6px;
  transition: background 180ms, border-color 180ms;
}
.modal-download:hover { background: rgba(0,245,255,0.08); }
.modal-close {
  width: 28px; height: 28px;
  display: grid; place-items: center;
  font-size: 22px;
  color: var(--text-dim);
  border-radius: 6px;
  transition: color 180ms, background 180ms;
}
.modal-close:hover { color: var(--magenta); background: rgba(255,61,154,0.1); }
.modal-body { flex: 1; background: #1a1d2e; }
.modal-body iframe {
  width: 100%; height: 100%;
  border: 0;
  background: #fff;
}

/* submit button spinner */
.btn-spin { animation: btnSpin 0.9s linear infinite; transform-origin: center; }
@keyframes btnSpin { to { transform: rotate(360deg); } }

/* ── TOAST ── */
.toast {
  position: fixed;
  bottom: 80px;
  left: 50%;
  transform: translate(-50%, 20px);
  padding: 12px 20px;
  background: rgba(10,12,24,0.9);
  border: 1px solid var(--cyan);
  border-radius: 10px;
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 13px;
  backdrop-filter: blur(14px);
  box-shadow: 0 10px 40px rgba(0,245,255,0.2);
  opacity: 0;
  pointer-events: none;
  transition: opacity 240ms, transform 240ms var(--ease-out);
  z-index: 300;
}
.toast.is-show {
  opacity: 1;
  transform: translate(-50%, 0);
}
.toast.is-error { border-color: var(--magenta); box-shadow: 0 10px 40px rgba(255,61,154,0.3); }

/* ── REVEAL ANIMATIONS ── */
.station .panel,
.station .stack-col,
.station .station-head {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 700ms var(--ease-out), transform 700ms var(--ease-out);
}
.station.is-visible .panel,
.station.is-visible .stack-col,
.station.is-visible .station-head {
  opacity: 1;
  transform: translateY(0);
}
.station.is-visible .panel:nth-child(2),
.station.is-visible .stack-col:nth-child(2) { transition-delay: 80ms; }
.station.is-visible .panel:nth-child(3),
.station.is-visible .stack-col:nth-child(3) { transition-delay: 160ms; }
.station.is-visible .panel:nth-child(4),
.station.is-visible .stack-col:nth-child(4) { transition-delay: 240ms; }
.station.is-visible .panel:nth-child(5),
.station.is-visible .stack-col:nth-child(5) { transition-delay: 320ms; }
.station.is-visible .panel:nth-child(6) { transition-delay: 400ms; }
.station.is-visible .panel:nth-child(7) { transition-delay: 480ms; }

/* ── RESPONSIVE ── */
/* ── RESPONSIVE ── */
@media (max-width: 1180px) {
  .hero-layout { grid-template-columns: 1fr; gap: 36px; }
  .hero-right { min-height: 0; }
  .core-ident { position: static; min-width: 0; width: 100%; margin-top: 12px; }
  .recs-grid { grid-template-columns: 1fr 1fr; gap: 16px; }
  .about-grid { grid-template-columns: repeat(2, 1fr); }
  .about-bio { grid-column: span 2; grid-row: auto; }
  .about-photo { grid-column: span 2; grid-row: auto; flex-direction: row; align-items: center; }
  .about-photo .photo-frame { flex: 0 0 220px; aspect-ratio: 1 / 1.1; }
  .stack-grid { grid-template-columns: repeat(2, 1fr); }
  .stack-col--wide { grid-column: span 2; }
  .builds-grid { grid-template-columns: repeat(2, 1fr); }
  .build--featured { grid-column: span 2; }
  .edu-grid { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
}

/* ── tablet / small laptop ── */
@media (max-width: 900px) {
  .hud-nav { gap: 2px; }
  .hud-link { padding: 6px 9px; font-size: 12px; }
  .hud-link-idx { display: none; }
  .station { padding: 110px 22px 110px; }
  .station-head { margin-bottom: 34px; }
  .about-photo { flex-direction: column; align-items: stretch; }
  .about-photo .photo-frame { flex: 0 0 auto; aspect-ratio: 4/5; }
}

/* ── phone ── */
@media (max-width: 780px) {
  body { overflow-x: hidden; }
  .certs-list { grid-template-columns: 1fr; }
  .grain { opacity: 0.04; }

  .hud-top {
    top: 10px;
    border-radius: 16px;
    left: 10px; right: 10px;
    padding: 8px 10px 8px 14px;
    gap: 8px;
    flex-wrap: nowrap;
  }
  .hud-nav { display: none; }
  .hud-rail { display: none; }
  .hud-audio { display: none; }
  .hud-actions { gap: 6px; margin-left: auto; }
  .hud-switcher { padding: 6px 22px 6px 10px; font-size: 11px; }
  .hud-resume { padding: 6px 10px; font-size: 11px; }
  .hud-resume-dot { display: none; }

  .hud-bottom {
    left: 10px; right: 10px; bottom: 10px;
    padding: 6px 12px;
    font-size: 10px;
    border-radius: 14px;
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
  }
  .hud-bottom-left, .hud-bottom-right { gap: 6px; flex-wrap: wrap; }
  .hud-stat:not(:first-child):not(:nth-child(3)) { display: none; }
  .hud-bottom-right .hud-stat:last-child { display: inline-flex; }
  .hud-stat-sep { display: none; }

  .station { padding: 90px 16px 80px; min-height: auto; }
  .station--hero { padding-top: 100px; padding-bottom: 40px; min-height: 100vh; }
  .station-head { margin-bottom: 26px; gap: 10px; }
  .station-title { font-size: clamp(26px, 8vw, 40px); }
  .station-idx { font-size: 11px; }

  .hero-title { font-size: clamp(48px, 15vw, 84px); margin-bottom: 18px; }
  .hero-title-word { letter-spacing: -0.01em; }
  .hero-kicker { font-size: 10.5px; margin-bottom: 20px; }
  .hero-lead { font-size: 15px; margin-bottom: 22px; }
  .hero-lead br { display: none; }
  .hero-chips { gap: 5px; }
  .hero-chips li { font-size: 10.5px; padding: 3px 8px; }
  .scroll-cue { display: none; }

  /* AI terminal — tighter on phones */
  .panel--ai { min-height: 300px; max-height: 64vh; }
  .ai-term-head { padding: 10px 12px; gap: 8px; }
  .ai-term-avatar { width: 28px; height: 28px; }
  .ai-term-name { font-size: 13px; letter-spacing: 0.08em; }
  .ai-term-sub { font-size: 10px; }
  .ai-term-pill { padding: 2px 7px; font-size: 9.5px; }
  .ai-term-log { padding: 10px 12px; font-size: 13px; gap: 8px; }
  .ai-term-chips { padding: 8px 10px; }
  .ai-chip { font-size: 11px; padding: 4px 9px; }
  .ai-term-input { padding: 10px 12px; }
  .ai-term-input-field { font-size: 13px; }

  .panel { padding: 18px 18px; }
  .panel--lg { padding: 22px 20px; }
  .core-ident { padding: 14px 14px; }
  .core-ident-stats dd { font-size: 18px; }

  .about-grid { grid-template-columns: 1fr; gap: 14px; }
  .about-bio, .about-photo { grid-column: auto; grid-row: auto; }
  .about-facts { grid-template-columns: 1fr; }
  .about-stat { min-height: 130px; }
  .about-stat .stat-num { font-size: clamp(36px, 9vw, 48px); }

  .stack-grid { grid-template-columns: 1fr; gap: 12px; }
  .stack-col { padding: 16px 18px; }
  .stack-col--wide { grid-column: auto; }

  .builds-grid { grid-template-columns: 1fr; gap: 14px; }
  .build--featured { grid-column: auto; }
  .build { min-height: 0; }
  .build-name { font-size: 19px; }

  .exp-head { flex-direction: column; align-items: flex-start; gap: 6px; }
  .exp-co { font-size: 22px; }
  .exp-meta { align-items: flex-start; }
  .exp-list li { font-size: 14px; }

  .edu-entry { grid-template-columns: 1fr; gap: 4px; padding: 12px 0; }
  .edu-year { font-size: 11px; }
  .recs-grid { grid-template-columns: 1fr; gap: 16px; }

  .field-row { grid-template-columns: 1fr; }
  .contact-lead { font-size: 15px; }
  .contact-list li a { grid-template-columns: 80px 1fr; gap: 10px; padding: 12px 14px; }
  .contact-v { font-size: 13.5px; word-break: break-word; }

  .station-foot { flex-direction: column; align-items: flex-start; gap: 8px; }

  .modal-panel { width: 96vw; height: 90vh; }
  .modal-head { padding: 10px 12px; }
  .modal-title { font-size: 11px; }

  .boot-inner { padding: 18px 18px; }
  .boot-log { min-height: 140px; font-size: 11px; }

  .cursor, #cursor { display: none !important; }
}

@media (max-width: 480px) {
  .hud-top { padding: 6px 8px 6px 12px; }
  .hud-brand { padding-right: 8px; gap: 6px; font-size: 12px; letter-spacing: 0.18em; }
  .hud-brand-text { display: inline; font-size: 11px; }
  .hud-switcher { font-size: 10.5px; padding: 5px 20px 5px 8px; background-size: 3px 3px; }
  .hud-resume { padding: 5px 9px; font-size: 10.5px; }

  .station { padding: 78px 14px 64px; }
  .station--hero { padding-top: 90px; }
  .hero-title { font-size: clamp(40px, 14vw, 64px); }
  .hero-cta { flex-direction: column; align-items: stretch; width: 100%; }
  .btn { justify-content: center; width: 100%; }
  .core-ident-stats { grid-template-columns: 1fr 1fr; gap: 10px 14px; }
  .core-ident-head { font-size: 9.5px; gap: 6px; }

  .ai-term-chips { padding: 6px 10px; gap: 5px; }
  .ai-chip { font-size: 10.5px; padding: 3px 8px; }
  .ai-term-input-field { font-size: 12.5px; }

  .panel { padding: 16px 16px; }
  .exp-co { font-size: 19px; }
  .build-name { font-size: 18px; }
  .station-title { font-size: clamp(22px, 8vw, 32px); }
}

/* tiny phones / landscape short screens */
@media (max-height: 560px) and (orientation: landscape) {
  .station--hero { min-height: 640px; }
  .hud-bottom { padding: 4px 10px; }
}

/* Reduce motion */
@media (prefers-reduced-motion: reduce) {
  * { animation-duration: 0.001ms !important; transition-duration: 180ms !important; }
  .boot-bar-fill { transition: none; }
  body { cursor: auto; }
  #cursor { display: none; }
}
