/* ═══════════════════════════════════════════════════════════════════
   HERO · EDITORIAL — pearl/cream by day, ink letterpress by night.
   Ported from _LOCKED_HERO_FINAL.html · Frame B.
   Theme is governed at the BODY level (body.theme-light / body.theme-dark)
   so the whole page flips, not just the hero.
   ═══════════════════════════════════════════════════════════════════ */

/* --- Typography & token map (Markoni Site already loads Inter Tight,
       Fraunces, JetBrains Mono. We add Instrument Serif + brand gold.) --- */
@import url('https://fonts.googleapis.com/css2?family=Instrument+Serif:ital@0;1&display=swap');

:root {
  --hero-serif: 'Instrument Serif', 'Fraunces', Georgia, serif;
  --hero-sans:  'Inter Tight', system-ui, sans-serif;
  --hero-mono:  'JetBrains Mono', ui-monospace, monospace;

  --gold-light:  #FFD166;
  --gold-molten: #FFB300;
  --gold-ember:  #FF8A00;
  --gold-deep:   #C46900;

  --gold-400: #FFD166;
  --gold-500: #FFB300;
  --gold-600: #FF8A00;
  --gold-700: #C46900;

  --gold-gradient: linear-gradient(135deg, #FFD166 0%, #FFB300 50%, #FF8A00 100%);
}

/* Page-level theme flip. Body class controls whether hero is cream or ink. */
body.theme-light { background: #f4efe6; color: #1a1a18; }
body.theme-dark  { background: #0e0d0b; color: rgba(244, 239, 230, 0.95); }

/* The hero IS the frame — full viewport, position relative for absolute children */
.hero-editorial {
  position: relative;
  width: 100%;
  height: 100dvh;
  min-height: 680px;
  max-height: 1080px;
  overflow: hidden;
  font-family: var(--hero-sans);
}
body.theme-light .hero-editorial { background: #f4efe6; color: #1a1a18; }
body.theme-dark  .hero-editorial { background: #0e0d0b; color: rgba(244, 239, 230, 0.95); }

/* Ambient radial wash */
.hero-editorial::before {
  content: ''; position: absolute; inset: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 80% 50% at 50% 0%, rgba(255, 179, 0, 0.08), transparent 70%),
    radial-gradient(ellipse 60% 40% at 50% 100%, rgba(217, 115, 0, 0.06), transparent 70%);
}
body.theme-dark .hero-editorial::before {
  background:
    radial-gradient(ellipse 80% 50% at 50% 0%, rgba(255, 179, 0, 0.10), transparent 70%),
    radial-gradient(ellipse 60% 40% at 50% 100%, rgba(255, 138, 0, 0.07), transparent 70%);
}

/* ─── Stage layout ───────────────────────────────────────────────── */
.hero-stage {
  position: relative; z-index: 2;
  display: flex; flex-direction: column;
  justify-content: center; align-items: center;
  width: 100%; height: 100%;
  padding: 96px 64px 108px;  /* top: nav clearance, bottom: rail (88px) + breathing */
  text-align: center;
}

.hero-eyebrow {
  font-family: var(--hero-mono); font-size: 10px; letter-spacing: 0.2em;
  color: rgba(26,26,24,0.5); text-transform: uppercase;
  display: inline-flex; align-items: center; gap: 10px;
  padding: 8px 18px; border: 1px solid rgba(26,26,24,0.15); border-radius: 999px;
  background: rgba(255,255,255,0.5); backdrop-filter: blur(10px);
  align-self: center; margin-bottom: 0;
}
.hero-eyebrow::before {
  content: ''; width: 6px; height: 6px; border-radius: 50%; background: var(--gold-600);
}
body.theme-dark .hero-eyebrow {
  color: rgba(244, 239, 230, 0.55);
  border-color: rgba(244, 239, 230, 0.14);
  background: rgba(244, 239, 230, 0.04);
}
body.theme-dark .hero-eyebrow::before {
  background: var(--gold-light);
  box-shadow: 0 0 8px rgba(255, 209, 102, 0.5);
}

.hero-headline {
  font-family: var(--hero-serif);
  font-size: clamp(44px, 4.8vw, 80px);
  line-height: 1.10; letter-spacing: -0.025em;
  font-weight: 400; color: #1a1a18;
  margin: 18px 0 0; max-width: 18ch;
  padding-bottom: 0.30em;
  overflow: visible;
}
.hero-headline .em { font-style: italic; color: #1a1a18; }
.hero-headline .accent {
  font-style: italic;
  background: var(--gold-gradient);
  -webkit-background-clip: text;
          background-clip: text;
  -webkit-text-fill-color: transparent;
          color: transparent;
  display: inline-block;
  padding: 0.10em 0.10em 0.40em 0.18em;
  margin: -0.10em 0 -0.30em 0.08em;
  line-height: inherit;
  overflow: visible;
  vertical-align: baseline;
}
body.theme-dark .hero-headline,
body.theme-dark .hero-headline .em { color: rgba(244, 239, 230, 0.97); }
body.theme-dark .hero-headline .accent {
  background: linear-gradient(135deg, #FFE08A 0%, #FFC940 50%, #FFA533 100%);
  -webkit-background-clip: text;
          background-clip: text;
  -webkit-text-fill-color: transparent;
          color: transparent;
}

.hero-sub {
  font-family: var(--hero-sans); font-weight: 300;
  font-size: 16px; line-height: 1.55;
  color: rgba(26,26,24,0.65);
  max-width: 520px; margin-top: 4px;
}
.hero-sub strong { color: #1a1a18; font-weight: 500; }
body.theme-dark .hero-sub { color: rgba(244, 239, 230, 0.6); }
body.theme-dark .hero-sub strong { color: rgba(244, 239, 230, 0.95); }

/* ─── Switchboard (cream variant ported from b-switchboard) ─────── */
.hero-switchboard {
  position: relative;
  margin: 24px 0 0;
  width: 100%;
  display: flex; flex-direction: column; align-items: center; justify-content: flex-start;
  text-align: center;
  gap: 8px;
}
.hsb-pre {
  font-family: var(--hero-mono); font-size: 10px; letter-spacing: 0.22em; text-transform: uppercase;
  color: rgba(26,26,24,0.55);
  display: inline-flex; align-items: center; gap: 12px;
  margin-bottom: 4px;
}
.hsb-pre .sep { width: 28px; height: 1px; background: rgba(26,26,24,0.18); display: inline-block; }
.hsb-pulse {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--gold-600); box-shadow: 0 0 10px var(--gold-600);
  animation: heroPulse 2s ease-in-out infinite;
}
@keyframes heroPulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.4; } }
body.theme-dark .hsb-pre { color: rgba(244, 239, 230, 0.6); }
body.theme-dark .hsb-pre .sep { background: rgba(244, 239, 230, 0.18); }
body.theme-dark .hsb-pulse {
  background: var(--gold-light);
  box-shadow: 0 0 10px var(--gold-light);
}

.hsb-sentence-wrap {
  font-family: var(--hero-serif);
  font-weight: 400;
  font-size: clamp(24px, 2.6vw, 38px);
  line-height: 1.20;
  letter-spacing: -0.018em;
  color: #1a1a18;
  max-width: 36ch;
  margin: 0 auto;
  text-align: center;
  min-height: 2.4em;
  max-height: 2.4em;
  display: block;
  perspective: 600px;
  padding: 0.10em 0 0.06em;
}
.hsb-sentence {
  display: inline;
  white-space: pre-line;
}
.hsb-quote {
  display: inline;              /* stays in line-box, no overflow risk */
  color: #FF9F1A;
  font-style: italic;
  font-size: 0.55em;            /* refined, well below ascender height */
  margin: 0 0.04em;
  opacity: 0.65;
  vertical-align: 0.55em;       /* sit near top of cap-height, no overflow */
}
.hsb-sentence { display: inline; white-space: pre-line; }
.hsb-sentence .word { display: inline-block; white-space: nowrap; }
.hsb-sentence .reveal {
  display: inline-block; opacity: 0;
  transform: translateY(0.18em); filter: blur(3px);
  transition: opacity 360ms ease, transform 360ms cubic-bezier(0.2,0.8,0.3,1), filter 360ms ease;
  will-change: opacity, transform, filter;
}
.hsb-sentence .reveal.reveal-in {
  opacity: 1; transform: translateY(0); filter: blur(0);
}
.hsb-sentence .ch {
  display: inline-block; will-change: transform, opacity;
  transform-origin: 50% 0%;
}
.hsb-sentence .ch.flip {
  animation: heroFlapFlip 280ms cubic-bezier(0.6, 0, 0.4, 1);
}
@keyframes heroFlapFlip {
  0%   { transform: rotateX(0deg); opacity: 1; }
  49%  { transform: rotateX(-90deg); opacity: 0; filter: blur(0.4px); }
  50%  { transform: rotateX(90deg);  opacity: 0; filter: blur(0.4px); }
  100% { transform: rotateX(0deg);   opacity: 1; }
}
body.theme-dark .hsb-sentence-wrap { color: rgba(244, 239, 230, 0.97); }
body.theme-dark .hsb-quote { color: #FFA827; opacity: 0.97; }

.hsb-meta {
  font-family: var(--hero-mono); font-size: 10px; letter-spacing: 0.18em;
  color: rgba(26,26,24,0.55); text-transform: uppercase;
  display: inline-flex; align-items: center; gap: 16px;
  min-height: 1.4em;
  white-space: nowrap;
  transition: opacity 240ms ease;
}
.hsb-meta .who { color: rgba(26,26,24,0.85); font-weight: 500; }
.hsb-meta .dot { width: 3px; height: 3px; border-radius: 50%; background: rgba(26,26,24,0.3); display: inline-block; }
.hsb-meta .where { color: rgba(26,26,24,0.55); }
.hsb-meta .when { color: var(--gold-700); }
.hsb-meta.fading { opacity: 0; }
body.theme-dark .hsb-meta { color: rgba(244, 239, 230, 0.55); }
body.theme-dark .hsb-meta .who { color: rgba(244, 239, 230, 0.92); }
body.theme-dark .hsb-meta .dot { background: rgba(244, 239, 230, 0.35); }
body.theme-dark .hsb-meta .where { color: rgba(244, 239, 230, 0.6); }
body.theme-dark .hsb-meta .when { color: var(--gold-light); }

.hsb-channel {
  font-family: var(--hero-mono); font-size: 9px; letter-spacing: 0.22em; text-transform: uppercase;
  color: rgba(26,26,24,0.4);
  display: inline-flex; align-items: center; gap: 12px;
  margin-top: -4px;
}
.hsb-channel .ch-tag {
  padding: 3px 10px; border: 1px solid rgba(26,26,24,0.15); border-radius: 999px;
  color: rgba(26,26,24,0.7);
  background: rgba(255,255,255,0.4);
}
body.theme-dark .hsb-channel { color: rgba(244, 239, 230, 0.45); }
body.theme-dark .hsb-channel .ch-tag {
  border-color: rgba(244, 239, 230, 0.18);
  color: rgba(244, 239, 230, 0.8);
}

.hsb-cities {
  margin-top: 14px;
  display: flex; gap: 26px; justify-content: center;
  font-family: var(--hero-mono); font-size: 10px; letter-spacing: 0.14em; text-transform: uppercase;
  color: rgba(26,26,24,0.4);
}
.hsb-cities .city {
  display: inline-flex; flex-direction: column; align-items: center; gap: 5px;
  transition: color 320ms ease;
  position: relative;
  padding-top: 11px;
  cursor: pointer;
}
.hsb-cities .city .lang-code { font-size: 9px; letter-spacing: 0.2em; color: rgba(26,26,24,0.4); }
.hsb-cities .city::before {
  content: ''; position: absolute; top: 0; left: 50%; transform: translateX(-50%);
  width: 5px; height: 5px; border-radius: 50%;
  background: rgba(26,26,24,0.18);
  transition: all 320ms ease;
}
.hsb-cities .city.active { color: var(--gold-700); }
.hsb-cities .city:hover { color: rgba(26,26,24,0.75); }
.hsb-cities .city:hover::before { background: rgba(26,26,24,0.55); }
.hsb-cities .city.active .lang-code { color: var(--gold-700); }
.hsb-cities .city.active::before {
  background: var(--gold-600);
  box-shadow: 0 0 10px rgba(255, 138, 0, 0.6);
}
body.theme-dark .hsb-cities { color: rgba(244, 239, 230, 0.45); }
body.theme-dark .hsb-cities .city.active { color: var(--gold-light); }
body.theme-dark .hsb-cities .city .lang-code { color: rgba(244, 239, 230, 0.4); }
body.theme-dark .hsb-cities .city.active .lang-code { color: var(--gold-light); }
body.theme-dark .hsb-cities .city:hover { color: rgba(244, 239, 230, 0.85); }
body.theme-dark .hsb-cities .city:hover::before { background: rgba(244, 239, 230, 0.55); }
body.theme-dark .hsb-cities .city.active::before {
  background: var(--gold-light);
  box-shadow: 0 0 10px rgba(255, 209, 102, 0.55);
}

/* ─── CTAs ───────────────────────────────────────────────────────── */
.hero-ctas { display: flex; gap: 20px; align-items: center; justify-content: center; margin-top: 24px; }
.hero-cta-primary,
body.theme-light .hero-cta-primary {
  display: inline-flex; align-items: center; gap: 10px;
  background: #1a1a18; color: #f4efe6;
  padding: 16px 28px; border-radius: 999px;
  font-family: var(--hero-sans); font-weight: 600; font-size: 13px;
  text-decoration: none; border: 1px solid #1a1a18;
  position: relative;
  box-shadow: 0 6px 20px rgba(26,26,24,0.18);
  transition: all 240ms ease, box-shadow 240ms ease;
}
.hero-cta-primary::before {
  content: ''; position: absolute; inset: -3px; border-radius: 999px;
  border: 1px solid rgba(255, 138, 0, 0.55);
  opacity: 0; pointer-events: none;
  transition: opacity 240ms ease;
}
.hero-cta-primary:hover {
  background: var(--gold-500); color: #1a1a18; border-color: var(--gold-500);
  box-shadow: 0 10px 28px rgba(255, 138, 0, 0.35);
}
.hero-cta-primary:hover::before { opacity: 1; }
.hero-cta-ghost {
  color: rgba(26,26,24,0.7); font-size: 12px;
  font-family: var(--hero-sans); font-weight: 500;
  text-decoration: none; padding: 16px 20px;
  border-radius: 999px;
  border: 1px solid rgba(26,26,24,0.18);
  background: rgba(255,255,255,0.4);
  transition: all 200ms ease;
  display: inline-flex; align-items: center; gap: 9px;
}
.hero-cta-ghost .hero-cta-play {
  opacity: 0.75; transition: opacity 200ms ease, transform 200ms ease;
}
.hero-cta-ghost:hover .hero-cta-play { opacity: 1; transform: translateX(1px); }
.hero-cta-ghost:hover {
  color: #1a1a18; border-color: rgba(26,26,24,0.4); background: rgba(255,255,255,0.7);
}
body.theme-dark .hero-cta-primary {
  background: var(--gold-gradient); color: #1a1a18;
  border-color: var(--gold-molten);
}
body.theme-dark .hero-cta-primary::before { border-color: rgba(255, 179, 0, 0.5); }
body.theme-dark .hero-cta-primary:hover {
  background: transparent; color: var(--gold-molten);
  border-color: var(--gold-molten);
  box-shadow: 0 10px 28px rgba(255, 179, 0, 0.22);
}
body.theme-dark .hero-cta-ghost {
  color: rgba(244, 239, 230, 0.75);
  border-color: rgba(244, 239, 230, 0.22);
  background: rgba(244, 239, 230, 0.03);
}
body.theme-dark .hero-cta-ghost:hover {
  color: rgba(244, 239, 230, 0.97);
  border-color: rgba(244, 239, 230, 0.45);
  background: rgba(244, 239, 230, 0.08);
}

/* ─── Bottom rail / live ticker ─────────────────────────────────── */
.hero-rail {
  position: absolute; bottom: 0; left: 0; right: 0; z-index: 4;
  height: 88px; border-top: 1px solid rgba(26,26,24,0.12);
  background: rgba(255,255,255,0.4); backdrop-filter: blur(20px);
  display: grid; grid-template-columns: 200px 1fr 200px;
  align-items: center;
}
.hero-rail-head {
  padding: 0 24px;
  font-family: var(--hero-mono); font-size: 9px; letter-spacing: 0.14em; text-transform: uppercase;
  color: rgba(26,26,24,0.55);
  border-right: 1px solid rgba(26,26,24,0.1);
}
.hero-rail-head .live {
  display: inline-flex; align-items: center; gap: 8px; color: var(--gold-700);
  font-weight: 500;
}
.hero-rail-head .live::before {
  content: ''; width: 6px; height: 6px; border-radius: 50%; background: var(--gold-600);
  animation: heroPulse 2s ease-in-out infinite;
}
.hero-rail-tally {
  padding: 0 24px; text-align: right;
  border-left: 1px solid rgba(26,26,24,0.1);
  font-family: var(--hero-mono); font-size: 9px; letter-spacing: 0.14em; text-transform: uppercase;
  color: rgba(26,26,24,0.55);
}
.hero-rail-tally strong {
  display: block; font-family: var(--hero-serif); font-size: 21px;
  color: #1a1a18; font-weight: 400; letter-spacing: 0; text-transform: none; margin-top: 4px;
}
.hero-rail-stream { overflow: hidden; height: 100%; position: relative; }
.hero-stream-track {
  position: absolute; top: 0; left: 0; height: 100%;
  display: flex; align-items: center;
  gap: 56px; padding: 0 32px;
  animation: heroStreamLeft 90s linear infinite;
}
@keyframes heroStreamLeft { from { transform: translateX(0); } to { transform: translateX(-50%); } }
.hero-event {
  display: flex; align-items: center; gap: 14px;
  flex-shrink: 0; white-space: nowrap;
}
.hero-event .time { font-family: var(--hero-mono); font-size: 10px; color: rgba(26,26,24,0.5); letter-spacing: 0.04em; }
.hero-event .channel {
  font-family: var(--hero-mono); font-size: 9px; letter-spacing: 0.16em; text-transform: uppercase;
  padding: 3px 8px; border-radius: 3px;
  background: rgba(26,26,24,0.06); color: rgba(26,26,24,0.7);
}
.hero-event .desc { font-size: 12px; color: #1a1a18; font-weight: 400; }
.hero-event .amt { font-family: var(--hero-mono); font-size: 11px; color: var(--gold-700); font-weight: 500; }
.hero-event-dot { width: 4px; height: 4px; border-radius: 50%; background: rgba(26,26,24,0.25); flex-shrink: 0; }

body.theme-dark .hero-rail {
  border-top-color: rgba(244, 239, 230, 0.1);
  background: rgba(0, 0, 0, 0.25);
}
body.theme-dark .hero-rail-head {
  color: rgba(244, 239, 230, 0.55);
  border-right-color: rgba(244, 239, 230, 0.1);
}
body.theme-dark .hero-rail-head .live { color: var(--gold-light); }
body.theme-dark .hero-rail-head .live::before {
  background: var(--gold-light); box-shadow: 0 0 8px rgba(255, 209, 102, 0.5);
}
body.theme-dark .hero-rail-tally {
  border-left-color: rgba(244, 239, 230, 0.1);
  color: rgba(244, 239, 230, 0.55);
}
body.theme-dark .hero-rail-tally strong { color: rgba(244, 239, 230, 0.97); }
body.theme-dark .hero-event .time { color: rgba(244, 239, 230, 0.5); }
body.theme-dark .hero-event .channel { background: rgba(244, 239, 230, 0.06); color: rgba(244, 239, 230, 0.75); }
body.theme-dark .hero-event .desc { color: rgba(244, 239, 230, 0.95); }
body.theme-dark .hero-event .amt { color: var(--gold-light); }
body.theme-dark .hero-event-dot { background: rgba(244, 239, 230, 0.25); }

/* ─── VFX layers (cursor, constellation, eavesdrop) ──────────────── */
.vfx-cursor-light,
.vfx-constellation,
.vfx-eavesdrop {
  position: absolute; inset: 0;
  pointer-events: none;
  z-index: 1;
  overflow: hidden;
  opacity: 0;
  transition: opacity 600ms ease;
}
.hero-editorial[data-vfx="cursor"]        .vfx-cursor-light,
.hero-editorial[data-vfx="all"]           .vfx-cursor-light  { opacity: 1; }
.hero-editorial[data-vfx="constellation"] .vfx-constellation,
.hero-editorial[data-vfx="all"]           .vfx-constellation { opacity: 1; pointer-events: auto; }
.hero-editorial[data-vfx="eavesdrop"]     .vfx-eavesdrop,
.hero-editorial[data-vfx="all"]           .vfx-eavesdrop     { opacity: 1; }

/* #1 Cursor light */
.vfx-cursor-light::before {
  content: '';
  position: absolute; top: 0; left: 0;
  width: 720px; height: 720px;
  transform: translate3d(var(--mx, -1000px), var(--my, -1000px), 0) translate(-50%, -50%);
  background: radial-gradient(circle at center,
    rgba(255, 179, 0, 0.16) 0%,
    rgba(255, 138, 0, 0.10) 18%,
    rgba(255, 138, 0, 0.04) 38%,
    transparent 62%);
  filter: blur(8px);
  transition: transform 220ms cubic-bezier(0.2, 0.8, 0.3, 1);
  will-change: transform;
}
.vfx-cursor-light::after {
  content: '';
  position: absolute; top: 0; left: 0;
  width: 220px; height: 220px;
  transform: translate3d(var(--mx, -1000px), var(--my, -1000px), 0) translate(-50%, -50%);
  background: radial-gradient(circle at center,
    rgba(255, 230, 170, 0.22) 0%,
    rgba(255, 200, 100, 0.10) 25%,
    transparent 60%);
  filter: blur(2px);
  transition: transform 380ms cubic-bezier(0.2, 0.8, 0.3, 1);
  will-change: transform;
}

/* #4 Constellation */
.vfx-constellation .ping {
  position: absolute;
  width: 4px; height: 4px;
  border-radius: 50%;
  background: var(--gold-600);
  box-shadow: 0 0 0 0 rgba(255, 138, 0, 0.5);
  cursor: pointer;
  pointer-events: auto;
  opacity: 0;
  animation: heroPingBlink var(--dur, 6s) ease-in-out infinite;
  animation-delay: var(--delay, 0s);
}
@keyframes heroPingBlink {
  0%, 100% { opacity: 0; transform: scale(0.6); box-shadow: 0 0 0 0 rgba(255, 138, 0, 0.5); }
  25%      { opacity: 0.9; transform: scale(1); box-shadow: 0 0 0 6px rgba(255, 138, 0, 0); }
  50%      { opacity: 0.6; transform: scale(0.95); }
  75%      { opacity: 0.9; transform: scale(1); }
}
.vfx-constellation .ping:hover {
  opacity: 1 !important;
  transform: scale(1.4) !important;
  box-shadow: 0 0 18px rgba(255, 179, 0, 0.7);
}
.vfx-constellation .ping-tip {
  position: absolute;
  background: rgba(26,26,24,0.94);
  color: rgba(244,239,230,0.95);
  border: 1px solid rgba(255,179,0,0.25);
  padding: 8px 12px;
  border-radius: 6px;
  font-family: var(--hero-mono); font-size: 10px; letter-spacing: 0.08em;
  text-transform: uppercase; white-space: nowrap;
  pointer-events: none;
  transform: translate(-50%, calc(-100% - 14px));
  opacity: 0;
  transition: opacity 180ms ease;
  z-index: 5;
}
.vfx-constellation .ping-tip.show { opacity: 1; }
.vfx-constellation .ping-tip::after {
  content: ''; position: absolute;
  bottom: -4px; left: 50%; transform: translateX(-50%) rotate(45deg);
  width: 8px; height: 8px; background: rgba(26,26,24,0.94);
  border-right: 1px solid rgba(255,179,0,0.25);
  border-bottom: 1px solid rgba(255,179,0,0.25);
}

/* #3+8 Eavesdrop ghosts */
.vfx-eavesdrop .ghost {
  position: absolute;
  font-family: var(--hero-mono); font-size: 9px; letter-spacing: 0.12em;
  color: rgba(26,26,24,0.45);
  text-transform: uppercase; white-space: nowrap;
  opacity: 0;
  animation: heroGhostDrift var(--dur, 7s) ease-in-out forwards;
}
.vfx-eavesdrop .ghost.gratitude {
  font-family: var(--hero-serif); font-style: italic;
  font-size: clamp(13px, 1.15vw, 17px);
  color: rgba(26,26,24,0.32);
  text-transform: none; letter-spacing: 0;
}
.vfx-eavesdrop .ghost .check { color: var(--gold-600); margin-left: 8px; }
@keyframes heroGhostDrift {
  0%   { opacity: 0; transform: translateY(8px); }
  20%  { opacity: 1; transform: translateY(0); }
  80%  { opacity: 1; transform: translateY(-6px); }
  100% { opacity: 0; transform: translateY(-14px); }
}
body.theme-dark .vfx-eavesdrop .ghost { color: rgba(244, 239, 230, 0.45); }
body.theme-dark .vfx-eavesdrop .ghost.gratitude { color: rgba(244, 239, 230, 0.42); }

/* ─── Fireflies ─────────────────────────────────────────────────── */
.fireflies {
  position: absolute; inset: 0;
  pointer-events: none;
  z-index: 3;
  overflow: hidden;
}
.fireflies .fly {
  position: absolute;
  width: 5px; height: 5px;
  border-radius: 50%;
  background: radial-gradient(circle, #f5b13a 0%, #e8901e 45%, rgba(232,144,30,0) 75%);
  box-shadow: 0 0 12px 2px rgba(245, 177, 58, 0.55), 0 0 24px 4px rgba(232, 144, 30, 0.25);
  pointer-events: auto;
  cursor: pointer;
  opacity: 0;
  transform: translate(-50%, -50%);
  animation: heroFlyPulse var(--dur, 7s) ease-in-out infinite;
  animation-delay: var(--delay, 0s);
  transition: transform 240ms cubic-bezier(0.2, 0.8, 0.3, 1), box-shadow 240ms ease;
}
@keyframes heroFlyPulse {
  0%, 100% { opacity: 0; transform: translate(-50%, -50%) scale(0.4); }
  20%      { opacity: 0.9; transform: translate(calc(-50% + var(--dx1, 0px)), calc(-50% + var(--dy1, 0px))) scale(1); }
  50%      { opacity: 0.55; transform: translate(calc(-50% + var(--dx2, 0px)), calc(-50% + var(--dy2, 0px))) scale(0.85); }
  80%      { opacity: 0.85; transform: translate(calc(-50% + var(--dx3, 0px)), calc(-50% + var(--dy3, 0px))) scale(1); }
}
.fireflies .fly:hover {
  opacity: 1 !important;
  box-shadow: 0 0 24px 4px rgba(245, 177, 58, 0.9), 0 0 48px 8px rgba(232, 144, 30, 0.5);
  animation-play-state: paused;
}

/* Firefly hover card — editorial paper clipping */
.firefly-card {
  position: absolute;
  pointer-events: none;
  z-index: 50;
  background: linear-gradient(180deg, #fbf6ec 0%, #f4ecdb 100%);
  color: #1a1a18;
  border-radius: 2px;
  padding: 18px 22px 16px;
  min-width: 260px; max-width: 320px;
  opacity: 0;
  transform: translate(-50%, -100%) translateY(-22px);
  transition: opacity 260ms ease, transform 260ms cubic-bezier(0.2, 0.8, 0.3, 1);
  box-shadow:
    0 1px 0 rgba(196, 105, 0, 0.06) inset,
    0 0 0 1px rgba(26, 26, 24, 0.06),
    0 2px 6px rgba(0, 0, 0, 0.04),
    0 18px 40px -14px rgba(26, 26, 24, 0.18);
}
.firefly-card::before {
  content: ''; position: absolute; left: 0; right: 0; top: 0; height: 2px;
  background: var(--gold-gradient);
  opacity: 0.95;
}
.firefly-card::after {
  content: ''; position: absolute; left: 50%; bottom: -22px;
  width: 1px; height: 22px;
  background: linear-gradient(180deg, rgba(196, 105, 0, 0.55) 0%, rgba(196, 105, 0, 0) 100%);
  transform: translateX(-50%);
}
.firefly-card.show {
  opacity: 1;
  transform: translate(-50%, -100%) translateY(-30px);
}
.firefly-card .fc-head {
  display: flex; align-items: center; gap: 8px;
  font-family: var(--hero-mono); font-size: 9px;
  letter-spacing: 0.2em; text-transform: uppercase;
  color: rgba(26, 26, 24, 0.45);
  margin-bottom: 10px;
}
.firefly-card .fc-head .pulse {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--gold-molten);
  box-shadow: 0 0 0 0 rgba(255, 179, 0, 0.55);
  animation: heroFcPulse 2s ease-out infinite;
}
@keyframes heroFcPulse {
  0%   { box-shadow: 0 0 0 0   rgba(255, 179, 0, 0.55); }
  70%  { box-shadow: 0 0 0 8px rgba(255, 179, 0, 0); }
  100% { box-shadow: 0 0 0 0   rgba(255, 179, 0, 0); }
}
.firefly-card .fc-head .fc-spacer { flex: 1; }
.firefly-card .fc-head .fc-channel {
  color: var(--gold-deep);
  font-weight: 500;
  letter-spacing: 0.18em;
}
.firefly-card .fc-quote {
  position: relative;
  font-family: var(--hero-serif); font-style: italic;
  font-size: 14px; line-height: 1.42;
  color: #1a1a18;
  text-wrap: pretty;
}
.firefly-card .fc-quote::before {
  content: '';
  display: inline-block;
  width: 18px; height: 1px;
  background: var(--gold-deep);
  vertical-align: middle;
  margin-right: 12px;
  margin-bottom: 4px;
  opacity: 0.6;
}
.firefly-card .fc-quote[dir="rtl"] {
  text-align: right;
}
.firefly-card .fc-quote[dir="rtl"]::before {
  margin-right: 0;
  margin-left: 12px;
}
.firefly-card .fc-trans {
  font-family: var(--hero-serif); font-style: italic;
  font-size: 11px; line-height: 1.45;
  color: rgba(26, 26, 24, 0.5);
  margin-top: 6px;
  text-wrap: pretty;
}
.firefly-card .fc-trans:empty { display: none; }
.firefly-card .fc-meta {
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid rgba(26, 26, 24, 0.08);
  display: flex; align-items: center; gap: 8px;
  font-family: var(--hero-mono); font-size: 9px;
  letter-spacing: 0.1em; text-transform: uppercase;
  color: rgba(26, 26, 24, 0.5);
  white-space: nowrap; overflow: hidden;
}
.firefly-card .fc-meta .sep {
  display: inline-block;
  width: 1px; height: 9px;
  background: rgba(26, 26, 24, 0.18);
}
.firefly-card .fc-meta .who { color: rgba(26, 26, 24, 0.75); }

body.theme-dark .firefly-card {
  background: linear-gradient(180deg, #1a1a18 0%, #14130f 100%);
  color: rgba(244, 239, 230, 0.95);
  box-shadow:
    0 1px 0 rgba(255, 209, 102, 0.05) inset,
    0 0 0 1px rgba(255, 209, 102, 0.08),
    0 2px 6px rgba(0, 0, 0, 0.4),
    0 18px 40px -14px rgba(0, 0, 0, 0.6);
}
body.theme-dark .firefly-card .fc-head { color: rgba(244, 239, 230, 0.45); }
body.theme-dark .firefly-card .fc-head .fc-channel { color: var(--gold-light); }
body.theme-dark .firefly-card .fc-quote { color: rgba(244, 239, 230, 0.97); }
body.theme-dark .firefly-card .fc-quote::before {
  background: var(--gold-light); opacity: 0.85;
}
body.theme-dark .firefly-card .fc-trans { color: rgba(244, 239, 230, 0.55); }
body.theme-dark .firefly-card .fc-meta {
  border-top-color: rgba(244, 239, 230, 0.1);
  color: rgba(244, 239, 230, 0.5);
}
body.theme-dark .firefly-card .fc-meta .sep { background: rgba(244, 239, 230, 0.18); }
body.theme-dark .firefly-card .fc-meta .who { color: rgba(244, 239, 230, 0.85); }

/* ─── Nav-chrome (replaces the old dark sticky bar) ─────────────── */
.nav-chrome {
  position: fixed; top: 20px; left: 50%; transform: translateX(-50%);
  z-index: 100;
  display: grid; grid-template-columns: 1fr auto 1fr;
  align-items: center; gap: 24px;
  width: calc(100% - 40px); max-width: 1380px;
  padding: 10px 14px 10px 20px;
  background: rgba(255,255,255,0.55);
  backdrop-filter: blur(20px) saturate(140%);
  -webkit-backdrop-filter: blur(20px) saturate(140%);
  border: 1px solid rgba(26,26,24,0.08);
  border-radius: 999px;
  transition: background 240ms ease, border-color 240ms ease;
}
.nav-chrome .brand { display: flex; align-items: center; justify-self: start; }
.nav-chrome .brand img { height: 22px; width: auto; display: block; }
.nav-chrome .nav-right { display: flex; align-items: center; gap: 14px; justify-self: end; }
.nav-chrome .menu {
  display: flex; gap: 28px; justify-content: center;
  font-family: var(--hero-sans); font-size: 13px; font-weight: 400;
}
.nav-chrome .menu a {
  color: rgba(26,26,24,0.7); text-decoration: none;
  transition: color 180ms ease;
}
.nav-chrome .menu a:hover { color: #1a1a18; }
.nav-chrome .nav-cta {
  padding: 9px 18px; border-radius: 999px;
  background: #1a1a18; color: #f4efe6;
  white-space: nowrap;
  font-family: var(--hero-sans); font-size: 13px; font-weight: 500;
  text-decoration: none;
  transition: opacity 180ms ease;
}
.nav-chrome .nav-cta:hover { opacity: 0.85; }

/* Day/Night toggle */
.nav-chrome .nav-theme {
  width: 28px; height: 28px;
  display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid rgba(26, 26, 24, 0.16);
  border-radius: 50%;
  background: transparent;
  color: rgba(26, 26, 24, 0.6);
  cursor: pointer; padding: 0;
  transition: color 200ms ease, border-color 200ms ease, background 200ms ease;
}
.nav-chrome .nav-theme:hover {
  color: #1a1a18;
  border-color: rgba(26, 26, 24, 0.4);
  background: rgba(255, 255, 255, 0.5);
}
.nav-chrome .nav-theme svg { width: 13px; height: 13px; display: block; }
.nav-chrome .nav-theme .ico-sun  { display: none; }
.nav-chrome .nav-theme .ico-moon { display: block; }
body.theme-dark .nav-chrome .nav-theme .ico-sun  { display: block; }
body.theme-dark .nav-chrome .nav-theme .ico-moon { display: none; }

/* Dark-mode nav surface */
body.theme-dark .nav-chrome {
  background: rgba(20, 18, 14, 0.65);
  border-color: rgba(244, 239, 230, 0.1);
}
body.theme-dark .nav-chrome .brand img {
  content: url('/assets/brand/Markoni-Wordmark-White.png');
}
body.theme-dark .nav-chrome .menu a { color: rgba(244, 239, 230, 0.7); }
body.theme-dark .nav-chrome .menu a:hover { color: rgba(244, 239, 230, 1); }
body.theme-dark .nav-chrome .nav-cta {
  background: var(--gold-gradient); color: #1a1a18;
}
body.theme-dark .nav-chrome .nav-theme {
  border-color: rgba(244, 239, 230, 0.22);
  color: rgba(244, 239, 230, 0.7);
}
body.theme-dark .nav-chrome .nav-theme:hover {
  color: var(--gold-light);
  border-color: var(--gold-light);
  background: rgba(255, 209, 102, 0.08);
}

/* ─── Below-hero theme handling for the rest of the Markoni page ─
   The existing site CSS assumes a dark page. We let body.theme-light
   invert the major dark-on-cream surfaces. Sections beyond the hero
   already use CSS vars from main.css/refine.css, so this is a soft
   override — only the darkest panels need flipping. */
body.theme-light { color-scheme: light; }
body.theme-light section,
body.theme-light footer { color: #1a1a18; }
