/* ========================================================
   Yuuko Suzuki — piano
   Layout system ported from the GavaStocks watchlist:
   aurora background, frosted glass cards, mono micro-labels.
   Palette kept from the original 2006 site (gold / amber / dark brown).
   ======================================================== */

:root {
  --r-card: 24px;
  --r-pill: 999px;
  --r-soft: 14px;
  --ease-glide: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --dur-fast: 200ms;
  --dur-mid: 400ms;
  --dur-slow: 700ms;
}

:root[data-theme="dark"] {
  /* Original site: bg #1b170c, text #fff, accent #ed921d, links #e0caac */
  --bg-0: #17130a;
  --bg-1: #0e0b05;
  --bg-deep: #070502;

  --glass: rgba(255, 231, 135, 0.045);
  --glass-strong: rgba(255, 231, 135, 0.085);
  --glass-hover: rgba(255, 231, 135, 0.075);
  --glass-border: rgba(247, 212, 165, 0.14);
  --glass-border-strong: rgba(247, 212, 165, 0.3);
  --glass-inner-hi: rgba(255, 247, 206, 0.24);
  --glass-inner-lo: rgba(255, 231, 135, 0.02);

  --ink: rgba(255, 247, 206, 0.96);
  --ink-soft: rgba(247, 212, 165, 0.74);
  --ink-muted: rgba(224, 202, 172, 0.48);
  --ink-faint: rgba(224, 202, 172, 0.26);

  --accent: #ed921d;
  --accent-glow: rgba(237, 146, 29, 0.5);
  --link: #e0caac;
  --link-hover: #ffe788;

  /* Warm-only aurora so the gold identity survives the blur */
  --aurora-1: #ed921d;
  --aurora-2: #ffe787;
  --aurora-3: #a35a12;
  --aurora-4: #fff7ce;

  /* Text-safe category colours (aurora tones are for orbs, not type) */
  --cat-a: #ffe787;
  --cat-b: #ed921d;
  --cat-c: #fff7ce;
  --cat-d: rgba(247, 212, 165, 0.74);

  /* Title shimmer stops */
  --shimmer-1: #ed921d;
  --shimmer-2: #ffe787;

  --shadow-card:
    0 1px 0 rgba(255, 247, 206, 0.06) inset,
    0 -1px 0 rgba(0, 0, 0, 0.32) inset,
    0 30px 60px -30px rgba(0, 0, 0, 0.85),
    0 10px 30px -10px rgba(0, 0, 0, 0.6);

  --scrollbar: rgba(247, 212, 165, 0.16);
}

:root[data-theme="light"] {
  /* Original site body was #ffe787 — this is that gold, calmed for reading */
  --bg-0: #f6e6b4;
  --bg-1: #efd98f;
  --bg-deep: #fdf4dc;

  --glass: rgba(255, 252, 240, 0.6);
  --glass-strong: rgba(255, 252, 240, 0.84);
  --glass-hover: rgba(255, 252, 240, 0.74);
  --glass-border: rgba(83, 65, 33, 0.2);
  --glass-border-strong: rgba(83, 65, 33, 0.38);
  --glass-inner-hi: rgba(255, 252, 240, 0.95);
  --glass-inner-lo: rgba(83, 65, 33, 0.03);

  --ink: #1b170c;
  --ink-soft: #4a3e24;
  --ink-muted: #857a5e;
  --ink-faint: #b3a684;

  --accent: #b06400;
  --accent-glow: rgba(176, 100, 0, 0.4);
  --link: #8a5a12;
  --link-hover: #ed921d;

  --aurora-1: #ffc46b;
  --aurora-2: #ffe787;
  --aurora-3: #e0a84f;
  --aurora-4: #fff7ce;

  /* Darkened so labels stay legible on the cream glass */
  --cat-a: #8a6d1f;
  --cat-b: #b06400;
  --cat-c: #6b5a2a;
  --cat-d: #4a3e24;

  --shimmer-1: #b06400;
  --shimmer-2: #8a6d1f;

  --shadow-card:
    0 1px 0 rgba(255, 252, 240, 0.95) inset,
    0 -1px 0 rgba(83, 65, 33, 0.05) inset,
    0 30px 60px -30px rgba(60, 45, 20, 0.38),
    0 10px 30px -10px rgba(60, 45, 20, 0.2);

  --scrollbar: rgba(83, 65, 33, 0.22);
}

/* ========================================================
   RESET / BASE
   ======================================================== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { font-size: 16px; -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  min-height: 100vh;
  background: var(--bg-deep);
  color: var(--ink);
  font-family: 'Geist', -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  font-weight: 400;
  line-height: 1.5;
  overflow-x: hidden;
  position: relative;
  -webkit-font-smoothing: antialiased;
  transition: background 600ms var(--ease-glide), color 600ms var(--ease-glide);
}

::selection { background: var(--accent); color: var(--bg-deep); }

::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--scrollbar); border-radius: 4px; }

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

a { color: var(--link); text-decoration: none; transition: color var(--dur-fast) var(--ease-glide); }
a:hover { color: var(--link-hover); }

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

/* ========================================================
   AURORA BACKGROUND
   ======================================================== */
.aurora {
  position: fixed;
  inset: 0;
  z-index: -2;
  overflow: hidden;
  background: linear-gradient(180deg, var(--bg-0) 0%, var(--bg-1) 60%, var(--bg-deep) 100%);
}

.aurora-orb {
  position: absolute;
  width: 60vw;
  height: 60vw;
  border-radius: 50%;
  filter: blur(120px);
  opacity: 0.5;
  mix-blend-mode: screen;
  will-change: transform;
}

:root[data-theme="light"] .aurora-orb {
  mix-blend-mode: multiply;
  opacity: 0.32;
  filter: blur(140px);
}

.aurora-orb.orb-1 {
  top: -20%; left: -10%;
  background: radial-gradient(circle, var(--aurora-1) 0%, transparent 60%);
  animation: drift-1 28s var(--ease-glide) infinite alternate;
}
.aurora-orb.orb-2 {
  top: 10%; right: -20%;
  background: radial-gradient(circle, var(--aurora-2) 0%, transparent 60%);
  animation: drift-2 36s var(--ease-glide) infinite alternate;
}
.aurora-orb.orb-3 {
  bottom: -15%; left: 20%;
  background: radial-gradient(circle, var(--aurora-3) 0%, transparent 60%);
  animation: drift-3 42s var(--ease-glide) infinite alternate;
}
.aurora-orb.orb-4 {
  bottom: 10%; right: 5%;
  width: 40vw; height: 40vw;
  background: radial-gradient(circle, var(--aurora-4) 0%, transparent 60%);
  animation: drift-4 48s var(--ease-glide) infinite alternate;
}

@keyframes drift-1 { to { transform: translate(20vw, 15vh) rotate(40deg); } }
@keyframes drift-2 { to { transform: translate(-25vw, 20vh) rotate(-35deg); } }
@keyframes drift-3 { to { transform: translate(15vw, -10vh) rotate(50deg); } }
@keyframes drift-4 { to { transform: translate(-15vw, -15vh) rotate(-45deg); } }

.aurora-noise {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: 0.4;
  background-image: url("data:image/svg+xml;utf8,<svg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/><feColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0.12 0'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
}

:root[data-theme="light"] .aurora-noise { opacity: 0.5; mix-blend-mode: multiply; }

/* ========================================================
   LAYOUT
   ======================================================== */
.container {
  max-width: min(94vw, 1600px);
  margin: 0 auto;
  padding:
    clamp(1.5rem, 4vw, 3.5rem)
    max(clamp(1rem, 3vw, 3rem), env(safe-area-inset-right))
    calc(5rem + env(safe-area-inset-bottom))
    max(clamp(1rem, 3vw, 3rem), env(safe-area-inset-left));
  position: relative;
  z-index: 1;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--accent);
  color: var(--bg-deep);
  padding: 0.6rem 1rem;
  border-radius: var(--r-pill);
  font-family: 'Geist Mono', monospace;
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  z-index: 100;
}
.skip-link:focus { left: 1rem; top: 1rem; color: var(--bg-deep); }

/* ========================================================
   NAV — segmented pill switcher
   ======================================================== */
.app-switcher {
  display: inline-flex;
  background: var(--glass);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid var(--glass-border);
  border-radius: var(--r-pill);
  padding: 0.35rem;
  margin-bottom: clamp(1.5rem, 3vw, 2.25rem);
  box-shadow: 0 1px 0 var(--glass-inner-hi) inset, 0 6px 18px -6px rgba(0, 0, 0, 0.4);
  max-width: 100%;
  overflow-x: auto;
  scrollbar-width: none;
}
.app-switcher::-webkit-scrollbar { display: none; }

.app-switcher a {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.5rem 1.05rem;
  border-radius: var(--r-pill);
  font-family: 'Geist Mono', monospace;
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--ink-muted);
  transition: color var(--dur-fast) var(--ease-glide), background var(--dur-fast) var(--ease-glide);
  white-space: nowrap;
}
.app-switcher a:hover { color: var(--ink); }
.app-switcher a.active {
  background: rgba(255, 247, 206, 0.92);
  color: var(--bg-deep);
  box-shadow: 0 2px 8px -2px rgba(0, 0, 0, 0.35);
}
:root[data-theme="light"] .app-switcher a.active {
  background: var(--ink);
  color: var(--bg-deep);
}
.app-switcher .dot {
  width: 5px; height: 5px;
  border-radius: 50%;
  background: currentColor;
  opacity: 0.7;
}

/* ========================================================
   MASTHEAD
   ======================================================== */
.masthead {
  padding-bottom: 1rem;
  margin-bottom: clamp(1.75rem, 3.5vw, 2.75rem);
  border-bottom: 1px solid var(--glass-border);
  position: relative;
}
.masthead::after {
  content: '';
  position: absolute;
  inset: auto 0 -1px 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--glass-border-strong) 50%, transparent);
  filter: blur(0.5px);
}

.mh-eyebrow {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.55rem;
  font-family: 'Geist Mono', ui-monospace, monospace;
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-muted);
  margin-bottom: 0.7rem;
}
.mh-eyebrow .pulse {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 8px var(--accent-glow), 0 0 16px var(--accent-glow);
  animation: pulse 2.4s ease-in-out infinite;
}
.mh-eyebrow .sep { opacity: 0.4; }
.mh-eyebrow-right { margin-left: auto; display: flex; align-items: center; gap: 0.55rem; }

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

.mh-main-row {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  flex-wrap: wrap;
}

.title {
  font-family: 'Montserrat', 'Inter', system-ui, sans-serif;
  font-weight: 700;
  font-size: clamp(1.7rem, 3.6vw, 2.8rem);
  line-height: 1;
  letter-spacing: -0.045em;
  color: var(--ink);
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.1em;
  margin: 0;
}
.title a { color: inherit; }

.title .w1 {
  background: linear-gradient(
    100deg,
    var(--ink) 0%,
    var(--ink) 20%,
    var(--shimmer-1) 40%,
    var(--shimmer-2) 60%,
    var(--ink) 80%,
    var(--ink) 100%
  );
  background-size: 200% 100%;
  background-position: 100% 50%;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  animation: shimmer 8s var(--ease-glide) infinite;
}

.title .t-bold { font-weight: 800; letter-spacing: -0.05em; }
.title .t-thin { font-weight: 200; letter-spacing: -0.02em; }

@keyframes shimmer {
  0%, 100% { background-position: 100% 50%; }
  50% { background-position: 0% 50%; }
}

.title .w2 {
  font-family: 'Geist Mono', monospace;
  font-size: 0.18em;
  color: var(--ink-muted);
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  margin-left: 0.5em;
  transform: translateY(-1.2em);
  opacity: 0.85;
}

.mh-tools {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-left: auto;
  flex-wrap: wrap;
}

.tool-btn {
  appearance: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: var(--glass);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid var(--glass-border);
  border-radius: var(--r-pill);
  color: var(--ink-soft);
  font-family: 'Geist Mono', monospace;
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 0.5rem 0.95rem;
  transition: all var(--dur-fast) var(--ease-glide);
}
.tool-btn:hover {
  color: var(--ink);
  border-color: var(--glass-border-strong);
  background: var(--glass-hover);
}
.tool-btn.icon { padding: 0.5rem 0.7rem; font-size: 0.8rem; letter-spacing: 0; }

/* ========================================================
   SECTION HEADS
   ======================================================== */
.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.8rem;
  margin-bottom: 0.9rem;
  flex-wrap: wrap;
}
.section-head h2,
.section-head h3 {
  font-family: 'Montserrat', 'Inter', system-ui, sans-serif;
  font-weight: 600;
  font-size: clamp(1.1rem, 1.6vw, 1.35rem);
  letter-spacing: -0.02em;
  color: var(--ink);
}
.section-head .label,
.label {
  font-family: 'Geist Mono', monospace;
  font-size: 0.62rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-muted);
}

.section { margin-bottom: clamp(2rem, 4vw, 3.25rem); }

/* ========================================================
   GLASS CARD — the core surface
   ======================================================== */
.card {
  --cx: 50%;
  --cy: 50%;
  position: relative;
  background: var(--glass);
  backdrop-filter: blur(28px) saturate(180%);
  -webkit-backdrop-filter: blur(28px) saturate(180%);
  border: 1px solid var(--glass-border);
  border-radius: 18px;
  padding: 1.15rem 1.25rem;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transform: scale(1) translateY(0);
  transition:
    transform 220ms var(--ease-glide),
    background var(--dur-mid) var(--ease-glide),
    box-shadow var(--dur-mid) var(--ease-glide),
    border-color var(--dur-mid) var(--ease-glide);
  box-shadow: var(--shadow-card);
  isolation: isolate;
}

/* Chromatic refraction edge */
.card::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(135deg,
    var(--glass-inner-hi) 0%,
    var(--glass-border) 25%,
    transparent 50%,
    var(--glass-border) 75%,
    var(--glass-inner-hi) 100%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
          mask-composite: exclude;
  pointer-events: none;
  z-index: 2;
  opacity: 0.85;
}

/* Cursor spotlight + top specular sheen */
.card::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background:
    radial-gradient(circle 240px at var(--cx) var(--cy), rgba(255, 231, 135, 0.13), transparent 70%),
    linear-gradient(180deg, rgba(255, 247, 206, 0.07) 0%, rgba(255, 247, 206, 0) 30%, rgba(255, 247, 206, 0) 100%);
  pointer-events: none;
  opacity: 0;
  transition: opacity var(--dur-mid) var(--ease-glide);
  z-index: 1;
}

.card > * { position: relative; z-index: 3; }

.card.interactive { cursor: pointer; }
.card.interactive:hover,
.card.lift:hover {
  background: var(--glass-hover);
  border-color: var(--glass-border-strong);
  transform: scale(1.012) translateY(-3px);
  box-shadow:
    0 1px 0 var(--glass-inner-hi) inset,
    0 -1px 0 rgba(0, 0, 0, 0.3) inset,
    0 40px 80px -30px rgba(0, 0, 0, 0.9),
    0 20px 40px -10px rgba(0, 0, 0, 0.6),
    0 0 60px -10px var(--accent-glow);
}
.card.interactive:hover::after,
.card.lift:hover::after { opacity: 1; }

/* Featured / highlighted card — the "flagged" treatment */
.card.featured {
  border-color: rgba(237, 146, 29, 0.35);
  animation: featured-breathe 4s ease-in-out infinite;
}
:root[data-theme="light"] .card.featured { border-color: rgba(176, 100, 0, 0.45); }

@keyframes featured-breathe {
  0%, 100% {
    box-shadow:
      0 1px 0 var(--glass-inner-hi) inset,
      0 0 0 1px rgba(237, 146, 29, 0.12) inset,
      0 0 32px -4px rgba(237, 146, 29, 0.22),
      0 30px 60px -30px rgba(0, 0, 0, 0.7),
      0 10px 30px -10px rgba(0, 0, 0, 0.45);
  }
  50% {
    box-shadow:
      0 1px 0 var(--glass-inner-hi) inset,
      0 0 0 1px rgba(237, 146, 29, 0.18) inset,
      0 0 44px -4px rgba(237, 146, 29, 0.32),
      0 30px 60px -30px rgba(0, 0, 0, 0.7),
      0 10px 30px -10px rgba(0, 0, 0, 0.45);
  }
}

/* Category micro-badge — 12px leading rule + mono caps */
.cat {
  font-family: 'Geist Mono', monospace;
  font-size: 0.55rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink-muted);
  margin-bottom: 0.5rem;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}
.cat::before { content: ''; width: 12px; height: 1px; background: var(--ink-faint); }

.cat[data-cat="RECITAL"]      { color: var(--cat-a); }
.cat[data-cat="TOUR"]         { color: var(--cat-b); }
.cat[data-cat="TRANSLATION"]  { color: var(--cat-c); }
.cat[data-cat="HONOUR"]       { color: var(--cat-b); }
.cat[data-cat="THESIS"]       { color: var(--cat-a); }
.cat[data-cat="ARTICLE"]      { color: var(--cat-d); }
.cat[data-cat="MASTERCLASS"]  { color: var(--cat-a); }
.cat[data-cat="COMPETITION"]  { color: var(--cat-b); }

.cat[data-cat]::before { background: currentColor; opacity: 0.5; }

/* Card internals */
.card-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.6rem;
  margin-bottom: 0.35rem;
}

.card h3,
.card .card-title {
  font-family: 'Montserrat', 'Inter', system-ui, sans-serif;
  font-weight: 600;
  font-size: 1rem;
  line-height: 1.25;
  letter-spacing: -0.015em;
  color: var(--ink);
}

.card .meta,
.card .date {
  font-family: 'Geist Mono', monospace;
  font-size: 0.63rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-muted);
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.card .place {
  font-family: 'Geist', system-ui, sans-serif;
  font-style: italic;
  font-size: 0.9rem;
  color: var(--ink-soft);
  line-height: 1.45;
  margin-top: 0.15rem;
}

.card p { color: var(--ink-soft); font-size: 0.92rem; line-height: 1.6; }
.card p + p { margin-top: 0.7rem; }

.card .card-figure {
  margin: 0.85rem -1.25rem -1.15rem;
  border-top: 1px solid var(--glass-border);
  overflow: hidden;
  flex-shrink: 0;      /* never let the flex column squash the photo */
}
.card .card-figure img {
  width: 100%;
  transition: transform var(--dur-slow) var(--ease-glide);
}
.card:hover .card-figure img { transform: scale(1.04); }

/* ========================================================
   GRIDS
   ======================================================== */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 0.9rem;
  align-items: start;
}
.grid.wide { grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); }
.grid.narrow { grid-template-columns: repeat(auto-fill, minmax(248px, 1fr)); }

/* Two-column page shell: content + sticky rail */
.page-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 340px);
  gap: clamp(1rem, 2vw, 1.75rem);
  align-items: start;
}
.page-main { min-width: 0; }
.page-rail { position: sticky; top: 1rem; display: flex; flex-direction: column; gap: 0.9rem; }

/* ========================================================
   PROSE — long-form body copy inside a glass panel
   ======================================================== */
.prose {
  font-size: 1rem;
  line-height: 1.72;
  color: var(--ink-soft);
  max-width: 68ch;
}
.prose p + p { margin-top: 1.05rem; }
.prose em { font-style: italic; color: var(--ink); }
.prose strong { color: var(--ink); font-weight: 600; }
.prose .lead {
  font-family: 'Geist', system-ui, sans-serif;
  font-style: italic;
  font-size: clamp(1.05rem, 1.5vw, 1.2rem);
  color: var(--ink);
  line-height: 1.55;
}

/* ========================================================
   HERO (index)
   ======================================================== */
.hero {
  position: relative;
  border-radius: var(--r-card);
  overflow: hidden;
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow-card);
  margin-bottom: clamp(1.5rem, 3vw, 2.25rem);
  isolation: isolate;
}
.hero img.hero-img {
  width: 100%;
  display: block;
  filter: saturate(1.05);
}
.hero .hero-veil {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(7, 5, 2, 0) 35%, rgba(7, 5, 2, 0.55) 75%, rgba(7, 5, 2, 0.88) 100%);
  pointer-events: none;
}
:root[data-theme="light"] .hero .hero-veil {
  background: linear-gradient(180deg, rgba(253, 244, 220, 0) 40%, rgba(253, 244, 220, 0.5) 80%, rgba(253, 244, 220, 0.85) 100%);
}
.hero .hero-caption {
  position: absolute;
  left: clamp(1rem, 3vw, 2.25rem);
  bottom: clamp(0.9rem, 2.5vw, 1.75rem);
  right: clamp(1rem, 3vw, 2.25rem);
  font-family: 'Geist Mono', monospace;
  font-size: 0.62rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(255, 247, 206, 0.8);
  text-shadow: 0 1px 12px rgba(0, 0, 0, 0.7);
}
:root[data-theme="light"] .hero .hero-caption { color: var(--ink-soft); text-shadow: none; }

.enter-cta {
  display: inline-flex;
  align-items: center;
  align-self: flex-start;   /* don't stretch inside the flex-column card */
  gap: 0.6rem;
  margin-top: 1.1rem;
  padding: 0.7rem 1.4rem;
  border-radius: var(--r-pill);
  background: var(--accent);
  color: #17130a;
  font-family: 'Geist Mono', monospace;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  box-shadow: 0 0 28px -6px var(--accent-glow);
  transition: transform var(--dur-fast) var(--ease-spring), box-shadow var(--dur-fast) var(--ease-glide);
}
.enter-cta:hover {
  color: #17130a;
  transform: translateY(-2px);
  box-shadow: 0 0 40px -4px var(--accent-glow);
}
.enter-cta .arrow { transition: transform var(--dur-fast) var(--ease-glide); }
.enter-cta:hover .arrow { transform: translateX(3px); }

/* ========================================================
   PORTRAIT
   ======================================================== */
.portrait {
  border-radius: var(--r-soft);
  overflow: hidden;
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow-card);
}
.portrait img { width: 100%; }
.portrait figcaption {
  font-family: 'Geist Mono', monospace;
  font-size: 0.58rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-muted);
  padding: 0.6rem 0.75rem;
  background: var(--glass);
  border-top: 1px solid var(--glass-border);
}

/* ========================================================
   TIMELINE (events year groups)
   ======================================================== */
.year-block { margin-bottom: clamp(1.75rem, 3vw, 2.5rem); }

.year-head {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  margin-bottom: 0.9rem;
}
.year-head .year {
  font-family: 'Montserrat', system-ui, sans-serif;
  font-weight: 800;
  font-size: clamp(1.5rem, 3vw, 2.1rem);
  letter-spacing: -0.04em;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
  line-height: 1;
}
.year-head .rule {
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, var(--glass-border-strong), transparent);
}
.year-head .count {
  font-family: 'Geist Mono', monospace;
  font-size: 0.6rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-muted);
  white-space: nowrap;
}

/* ========================================================
   AUDIO PLAYER CARD
   ======================================================== */
.audio-card .track {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.7rem 0;
  border-top: 1px solid var(--glass-border);
}
.audio-card .track:first-of-type { border-top: none; padding-top: 0.3rem; }

.play-btn {
  appearance: none;
  cursor: pointer;
  flex-shrink: 0;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid var(--glass-border-strong);
  background: var(--glass-strong);
  color: var(--accent);
  font-size: 0.8rem;
  line-height: 1;
  display: grid;
  place-items: center;
  transition: all var(--dur-fast) var(--ease-glide);
}
.play-btn:hover {
  border-color: var(--accent);
  box-shadow: 0 0 20px -4px var(--accent-glow);
  transform: scale(1.06);
}
.play-btn[aria-pressed="true"] {
  background: var(--accent);
  color: #17130a;
  border-color: var(--accent);
}

.track-meta { min-width: 0; flex: 1; }
.track-meta .track-name {
  font-family: 'Geist', system-ui, sans-serif;
  font-style: italic;
  font-size: 0.95rem;
  color: var(--ink);
  line-height: 1.3;
}
.track-meta .track-sub {
  font-family: 'Geist Mono', monospace;
  font-size: 0.58rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-muted);
  margin-top: 0.2rem;
}

/* ========================================================
   STAT / FACT ROW
   ======================================================== */
.stats {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
  margin-top: 0.85rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--glass-border);
}
.stat .k {
  font-family: 'Geist Mono', monospace;
  font-size: 0.55rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-muted);
  display: block;
  margin-bottom: 0.25rem;
}
.stat .v {
  font-family: 'Geist Mono', monospace;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}

/* ========================================================
   LIGHTBOX
   ======================================================== */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: none;
  place-items: center;
  padding: clamp(1rem, 4vw, 3rem);
  background: rgba(7, 5, 2, 0.9);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}
.lightbox.open { display: grid; animation: lb-in var(--dur-mid) var(--ease-glide); }
@keyframes lb-in { from { opacity: 0; } to { opacity: 1; } }

.lightbox img {
  max-width: 100%;
  max-height: 85vh;
  width: auto;
  border-radius: var(--r-soft);
  box-shadow: 0 40px 100px -20px rgba(0, 0, 0, 0.9);
}
.lightbox .lb-cap {
  margin-top: 0.9rem;
  text-align: center;
  font-family: 'Geist Mono', monospace;
  font-size: 0.62rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(255, 247, 206, 0.7);
}
.lightbox .lb-close {
  position: absolute;
  top: clamp(1rem, 3vw, 2rem);
  right: clamp(1rem, 3vw, 2rem);
  appearance: none;
  cursor: pointer;
  width: 40px; height: 40px;
  border-radius: 50%;
  border: 1px solid rgba(247, 212, 165, 0.3);
  background: rgba(255, 231, 135, 0.08);
  color: rgba(255, 247, 206, 0.9);
  font-size: 1.1rem;
  line-height: 1;
}
.lightbox .lb-close:hover { background: rgba(255, 231, 135, 0.16); }

/* ========================================================
   FOOTER
   ======================================================== */
footer.site-footer {
  margin-top: 5rem;
  padding-top: 2rem;
  border-top: 1px solid var(--glass-border);
  font-family: 'Geist Mono', monospace;
  font-size: 0.68rem;
  color: var(--ink-muted);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  line-height: 2;
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem 1.4rem;
  align-items: baseline;
  justify-content: space-between;
}
footer.site-footer nav { display: flex; flex-wrap: wrap; gap: 0.6rem 1.1rem; }
footer.site-footer .copy { opacity: 0.8; letter-spacing: 0.06em; }

/* ========================================================
   RESPONSIVE
   ======================================================== */
@media (max-width: 960px) {
  .page-layout { grid-template-columns: minmax(0, 1fr); }
  .page-rail { position: static; flex-direction: row; flex-wrap: wrap; }
  .page-rail > * { flex: 1 1 260px; }
}

@media (max-width: 640px) {
  .grid, .grid.wide, .grid.narrow { grid-template-columns: minmax(0, 1fr); }
  .card.interactive:hover, .card.lift:hover { transform: none; }
  .card:hover .card-figure img { transform: none; }
  .mh-tools { margin-left: 0; width: 100%; }
  .mh-eyebrow-right { margin-left: 0; width: 100%; }
  .aurora-orb { filter: blur(70px); }
  .app-switcher a { padding: 0.5rem 0.8rem; font-size: 0.65rem; }
  .card .card-figure { margin-left: -1.25rem; margin-right: -1.25rem; }
  footer.site-footer { flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
