/* =====================================================================
   THE POCKET MIRROR · styles
   Dark, black-and-white with gold accents. Magistral for headlines,
   Neue Haas Display for text.

   THE SYSTEM (use these tokens, never one-off values)
   · Type: 7 sizes, all multiples of 4 → 56 · 48 · 32 · 24 · 20 · 16 · 12.
     Only 56 / 48 / 32 shrink on small phones (→ 48 / 40 / 28).
     Magistral is for things you glance at, Neue Haas for things you read.
   · Letter-spacing: display −.01em, labels .2em, buttons .14em. Everything else 0.
     (The wordmark keeps its own wide spacing: it is the logo.)
   · Colour: 13 colours, each with a job (see :root).
   · Gold means: do this, this is yours, or progress. Solid or 35%, nothing else.
     The metal gradient is a material, only on things you could hold:
     plates, cards, play buttons. Never on text, borders, badges or the main button.
   · One glow per screen, behind the thing in focus.
   · Corners: 8 (inputs, thumbnails), 16 (cards, sheets), round (buttons, circles).
   · One shadow, under floating layers (sheets, toast, mini player).
   · Exceptions: the card artwork and the lock-screen mock are pictures and
     scale with themselves; caption words not yet said stay dark on purpose;
     the tab bar labels are 11px; the landing headline (36px) and the podcast
     episode number (112px) are off the scale.
   ===================================================================== */

@font-face { font-family: "Magistral"; src: url("../assets/fonts/magistral-bold.woff2") format("woff2"); font-weight: 700; font-style: normal; font-display: swap; }
@font-face { font-family: "Magistral"; src: url("../assets/fonts/magistral-bold-italic.woff2") format("woff2"); font-weight: 700; font-style: italic; font-display: swap; }
@font-face { font-family: "Neue Haas Display"; src: url("../assets/fonts/nhd-light.woff2") format("woff2"); font-weight: 300; font-style: normal; font-display: swap; }
@font-face { font-family: "Neue Haas Display"; src: url("../assets/fonts/nhd-light-italic.woff2") format("woff2"); font-weight: 300; font-style: italic; font-display: swap; }
@font-face { font-family: "Neue Haas Display"; src: url("../assets/fonts/nhd-medium.woff2") format("woff2"); font-weight: 500; font-style: normal; font-display: swap; }
@font-face { font-family: "Neue Haas Display"; src: url("../assets/fonts/nhd-bold.woff2") format("woff2"); font-weight: 700; font-style: normal; font-display: swap; }

:root {
  /* colour · dark (the whole app) */
  --bg: #0a0a0a;          /* page */
  --surface: #161616;     /* cards, sheets, inputs */
  --line: rgba(255, 255, 255, .10); /* every divider and border */
  --ink: #f2f2ef;         /* titles, body · 17.7:1 */
  --ink-2: #a8a8a4;       /* meta, labels, secondary · 8.3:1 */
  --ink-3: #8a8a86;       /* quietest allowed: locked, coming soon, fine print · 5.7:1 */
  --gold: #e0b84c;        /* action and progress · 10.5:1 */
  --gold-35: rgba(224, 184, 76, .35); /* rings and borders */
  --on-gold: #0a0a0a;     /* text on gold */
  --error: #e06c4c;       /* errors only · 6.1:1 */
  /* colour · light (Mirror 21 page and the white Mirror 21 doors) */
  --paper: #ffffff;
  --paper-ink: #0a0a0a;
  --paper-ink-2: #5c5c58; /* 6.7:1 */
  --gold-deep: #896a00;   /* gold text on white · 5.1:1 */
  --paper-line: rgba(10, 10, 10, .10);
  /* the metal: objects only (plates, cards, play buttons) */
  --gold-metal: linear-gradient(110deg, #d8ad3e, #ffef9a 53%, #d8ad3e);

  /* type */
  --display: "Magistral", "Arial Narrow", Arial, sans-serif;
  --text: "Neue Haas Display", "Helvetica Neue", Arial, sans-serif;
  --fs-xl: 56px;      /* Display XL: 12 MIRRORS, SEE IT */
  --fs-tab: 48px;     /* Tab title */
  --fs-display: 32px; /* Display: landing headline, sheet headlines, $99 */
  --fs-title: 24px;   /* Title: player and sheet titles */
  --fs-20: 20px;      /* List title (Magistral), Voice (captions), Quote */
  --fs-body: 16px;    /* Body: any sentence */
  --fs-small: 12px;   /* Meta, Label, Button */
  --ls-display: -.01em;
  --ls-label: .2em;
  --ls-button: .14em;

  /* shape */
  --r-sm: 8px;
  --r-md: 16px;
  --r-full: 999px;
  --shadow: 0 -12px 40px rgba(0, 0, 0, .6);

  --frame: 480px;
  --pad: 24px;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --tabbar: 80px;     /* the floating tab bar (64) + its gap from the bottom edge (16) */
}
@media (max-width: 380px) {
  :root { --fs-xl: 48px; --fs-tab: 40px; --fs-display: 28px; }
}

* { box-sizing: border-box; }
html { background: var(--bg); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100dvh;
  background: var(--bg);
  color: var(--ink);
  font: 500 var(--fs-body)/1.5 var(--text);
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  overscroll-behavior-y: none;
}
img { display: block; max-width: 100%; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
a { color: inherit; text-decoration: none; }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; border-radius: var(--r-sm); }
[hidden] { display: none !important; }
h1, h2, .t, .feeling, .quote, .line { text-wrap: balance; }
/* text for screen readers only (iPhone could show a 1px sliver of it without the margin / clip-path) */
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; border: 0; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }

/* ---------- app frame (phone-width column, centred on desktop) ---------- */
#app { position: relative; max-width: var(--frame); min-height: 100dvh; margin: 0 auto; overflow-x: hidden; }
@media (min-width: 600px) {
  #app { box-shadow: 0 0 0 1px var(--line); }
}
.screen {
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 100dvh;
  padding: calc(var(--safe-top) + 20px) var(--pad) calc(var(--safe-bottom) + 28px);
  animation: enter .35s ease both;
}
@keyframes enter { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

/* ---------- shared bits ---------- */
.label { font: 700 var(--fs-small)/1 var(--text); letter-spacing: var(--ls-label); text-transform: uppercase; }
.wordmark { margin: 0; font: italic 700 var(--fs-small)/1.5 var(--display); letter-spacing: .3em; white-space: nowrap; }
.eyebrow { margin: 0; font: 700 var(--fs-small)/1 var(--text); letter-spacing: var(--ls-label); color: var(--ink-2); text-transform: uppercase; }
.gold-text { color: var(--gold); }
.topbar { display: flex; align-items: center; justify-content: space-between; min-height: 44px; }
.icon-btn { display: grid; place-items: center; width: 44px; height: 44px; margin-left: -10px; border-radius: 50%; color: var(--ink); }
.icon-btn svg { width: 24px; height: 24px; }

.btn-gold {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  width: 100%; height: 60px; border-radius: var(--r-full);
  background: var(--gold); color: var(--on-gold);
  font: 700 var(--fs-small)/1 var(--text); letter-spacing: var(--ls-button);
  transition: transform .12s ease;
}
.btn-gold:active { transform: scale(.98); }
/* the same button in white: the kit's black "ink" button, flipped for the dark app */
.btn-gold.white { background: var(--ink); color: var(--bg); }
/* the kit's outline button, dark: same size, thin light border, white label */
.btn-outline {
  display: flex; align-items: center; justify-content: center; width: 100%; height: 60px;
  border: 1px solid rgba(255, 255, 255, .24); border-radius: var(--r-full); color: var(--ink);
  font: 700 var(--fs-small)/1 var(--text); letter-spacing: var(--ls-button);
  transition: transform .12s ease, border-color .2s ease;
}
.btn-outline:active { transform: scale(.98); border-color: rgba(255, 255, 255, .5); }
.btn-outline svg { width: 18px; height: 18px; margin-left: 10px; }   /* e.g. the down chevron on SEE ALL 12 MIRRORS */
/* the logo image (assets/images/pocket-mirror-logo.png, trimmed from "Pocket Mirror - dark.png").
   Its background is pure black; "screen" makes that black vanish into the page so no box shows. */
.logo { display: block; height: auto; mix-blend-mode: screen; }
.topbar .logo { width: 136px; }
.btn-gold.done { background: none; border: 1px solid var(--gold-35); color: var(--gold); }
.btn-gold svg { width: 18px; height: 18px; }
.link { font: 500 var(--fs-small)/1 var(--text); color: var(--ink-2); text-decoration: underline; text-underline-offset: 4px; padding: 12px 8px; }

/* mirrored path / title word */
.reflect { position: relative; height: 96px; overflow: hidden; margin: 8px 0 0; }
.reflect p { margin: 0; font: italic 700 var(--fs-xl)/1 var(--display); letter-spacing: var(--ls-display); white-space: nowrap; color: var(--ink); }
.reflect p + p {
  margin-top: -6px; transform: scaleY(-1); color: rgba(255, 255, 255, .15) !important;
  -webkit-mask-image: linear-gradient(0deg, #000, transparent 70%); mask-image: linear-gradient(0deg, #000, transparent 70%);
}
.reflect.change p:first-child { color: var(--gold); }

/* =====================================================================
   1 · LANDING
   ===================================================================== */
/* the wordmark top left, the line and Kevin (its voice) in the middle, the button at the bottom */
.landing { text-align: center; }
.landing .logo { width: 168px; }
.landing-mid { display: flex; flex-direction: column; align-items: center; gap: 28px; margin: auto 0; }
/* off the scale on purpose (it's the cover): YOURSELF. as big as the column allows (≈ 5.6em wide, 6 leaves a margin),
   up to 64px; "ONE MINUTE WITH" sits above it at half that size. All white, no gold on the landing. */
.landing h1 { margin: 0; font: italic 700 64px/.92 var(--display); font-size: min(64px, calc((100vw - 2 * var(--pad)) / 6)); letter-spacing: -.04em; white-space: nowrap; }
.landing h1 .lead { display: block; margin-bottom: .2em; font-size: .5em; letter-spacing: -.02em; }
.landing h1 .word { display: block; }
.landing .host img { width: 44px; height: 44px; box-shadow: 0 0 0 1.5px var(--ink-3); }
.landing-foot { display: flex; flex-direction: column; align-items: stretch; gap: 14px; }
.landing .fine { margin: 0; font-style: italic; font-weight: 300; color: var(--ink-2); }
.tap-hint {
  display: flex; align-items: center; justify-content: center; gap: 10px; margin: clamp(16px, 3dvh, 26px) 0 0;
  font: 700 var(--fs-small)/1 var(--text); letter-spacing: var(--ls-label); color: var(--ink-2);
  opacity: 0; transform: translateY(6px); transition: opacity .45s ease, transform .45s ease;
}
.tap-hint.show { opacity: 1; transform: none; }
.tap-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--gold); animation: ping 1.4s ease-out infinite; }
@keyframes ping { 0% { box-shadow: 0 0 0 0 rgba(224, 184, 76, .6); } 100% { box-shadow: 0 0 0 10px rgba(224, 184, 76, 0); } }

/* =====================================================================
   1b · MEET KEVIN · the intro video (first time only)
   ===================================================================== */
/* full screen, black behind, the video in its own colour */
.intro {
  position: fixed; top: 0; bottom: 0; left: 50%; z-index: 5; width: min(100%, var(--frame)); transform: translateX(-50%);
  overflow: hidden; background: #000; transition: opacity .45s ease;
}
.intro.leaving { opacity: 0; }
.intro-stage { position: absolute; inset: 0; cursor: pointer; }
.intro-video { display: block; width: 100%; height: 100%; object-fit: cover; background: #000; }
/* a thin progress line along the top */
.intro-bar { position: absolute; left: 16px; right: 16px; top: calc(var(--safe-top) + 12px); height: 2px; border-radius: 1px; background: rgba(255, 255, 255, .2); box-shadow: 0 0 6px rgba(0, 0, 0, .25); pointer-events: none; }
.intro-bar span { display: block; width: 0; height: 100%; border-radius: inherit; background: rgba(255, 255, 255, .85); transition: width .25s linear; }
/* SKIP: small and barely there */
.intro-skip { position: absolute; z-index: 2; top: calc(var(--safe-top) + 20px); right: 8px; padding: 12px 10px; font: 700 10px/1 var(--text); letter-spacing: .2em; color: rgba(255, 255, 255, .5); text-shadow: 0 1px 6px rgba(0, 0, 0, .45); }
/* the black fades: the top one behind MEET KEVIN (only when it shows), the bottom one always, strong, up over his hands */
.intro-shade { position: absolute; inset: 0; pointer-events: none; }
.intro-shade::before, .intro-shade::after { content: ""; position: absolute; left: 0; right: 0; }
.intro-shade::before { top: 0; height: 30%; background: linear-gradient(180deg, rgba(0, 0, 0, .78), rgba(0, 0, 0, .35) 55%, transparent); transition: opacity .4s ease; }
.intro-shade::after { bottom: 0; height: 50%; background: linear-gradient(0deg, #000 0, #000 22%, rgba(0, 0, 0, .9) 45%, rgba(0, 0, 0, .6) 70%, transparent); }
.intro:not(.paused):not(.ended) .intro-shade::before { opacity: .35; }
/* top left: the time, then MEET KEVIN (like a step title); away while Kevin talks */
.intro-head { position: absolute; z-index: 2; left: var(--pad); right: 72px; top: calc(var(--safe-top) + 36px); pointer-events: none; transition: opacity .35s ease, transform .35s ease; }
.intro-meta { margin: 0; min-height: 12px; font: 700 var(--fs-small)/1 var(--text); letter-spacing: var(--ls-label); color: var(--ink-2); font-variant-numeric: tabular-nums; }
.intro-title { margin: 10px 0 0; font: italic 700 var(--fs-display)/1 var(--display); letter-spacing: -.03em; }
.intro:not(.paused):not(.ended) .intro-head { opacity: 0; transform: translateY(-6px); }
/* in the middle of the screen: the see-through glass play button (like Kevin's video on the Mirror 21 page) */
.intro-play {
  position: absolute; z-index: 2; left: 50%; top: 50%; transform: translate(-50%, -50%);
  display: flex; padding: 0; color: var(--ink); transition: opacity .3s ease;
}
.intro-play .ring {
  display: grid; place-items: center; width: 72px; height: 72px; border-radius: 50%;
  background: rgba(10, 10, 10, .3); border: 1.5px solid rgba(255, 255, 255, .75);
  -webkit-backdrop-filter: blur(8px) saturate(120%); backdrop-filter: blur(8px) saturate(120%); box-shadow: 0 4px 18px rgba(0, 0, 0, .25);
  transition: transform .12s ease;
}
.intro-play:active .ring { transform: scale(.95); }
.intro-play svg { width: 26px; height: 26px; margin-left: 4px; }
.intro:not(.paused) .intro-play { opacity: 0; pointer-events: none; }
/* at the end: WATCH AGAIN, then the white LET'S BEGIN button */
.intro-end {
  position: absolute; z-index: 2; left: var(--pad); right: var(--pad); bottom: calc(var(--safe-bottom) + 28px);
  display: flex; flex-direction: column; align-items: center; gap: 14px; transition: opacity .35s ease, transform .35s ease;
}
.intro:not(.ended) .intro-end { opacity: 0; transform: translateY(12px); pointer-events: none; }
.intro-again { display: inline-flex; align-items: center; gap: 10px; padding: 10px; font: 700 var(--fs-body)/1 var(--text); letter-spacing: .1em; color: var(--ink); }
.intro-again svg { width: 18px; height: 18px; }
.intro .intro-begin { height: 60px; }
@media (prefers-reduced-motion: reduce) { .intro, .intro-head, .intro-play, .intro-end, .intro-shade::before, .intro-bar span { transition: none; } }

/* =====================================================================
   2 · PATH · WHICH ONE IS YOU?
   ===================================================================== */
/* the page's question as the title (kit: tight Magistral), on one line at 32px (28 on small phones);
   data-fit (fitTitles in app.js) shrinks it a little more only if it would still be wider than the screen. Then the Mirrors as cards. No gold. */
.page-title { margin: 28px 0 0; font: italic 700 var(--fs-display)/1 var(--display); letter-spacing: -.03em; white-space: nowrap; }
.page-title > span { display: inline-block; }
.path .mirror-list { margin-top: 24px; }

/* one Mirror = one card (kit "choice tile", dark): ringed number, title, length, round white play button.
   Also used on Home · 12 Mirrors. */
.mirror-list { display: flex; flex-direction: column; gap: 10px; margin: 0; padding: 0; list-style: none; }
.mirror-row {
  display: flex; align-items: center; gap: 14px; width: 100%; padding: 16px; text-align: left;
  border: 1px solid var(--line); border-radius: 20px; background: var(--surface);
  transition: transform .12s ease, background-color .2s ease;
}
.mirror-row:active { transform: scale(.99); background: #1c1c1c; }
.mirror-row .num {
  display: grid; place-items: center; flex-shrink: 0; align-self: flex-start; width: 32px; height: 32px; border-radius: 50%;
  border: 1.5px solid var(--ink); font: italic 700 var(--fs-small)/1 var(--display); letter-spacing: 0;
}
.mirror-row .body { flex: 1; min-width: 0; padding-top: 4px; }
.mirror-row .t { display: block; font: italic 700 var(--fs-20)/1.15 var(--display); letter-spacing: -.02em; }
.mirror-row .meta { display: flex; align-items: center; gap: 6px; margin-top: 8px; font: 500 var(--fs-small)/1 var(--text); color: var(--ink-2); }
.mirror-row .meta svg { width: 14px; height: 14px; }
.play-ring {
  display: grid; place-items: center; flex-shrink: 0; width: 44px; height: 44px; border-radius: 50%;
  background: var(--ink); color: var(--bg);
}
.play-ring svg { width: 16px; height: 16px; margin-left: 2px; }
.play-ring.heard svg { margin-left: 0; }
.mirror-row.soon { cursor: default; }
.mirror-row.soon .num { border-color: var(--ink-3); color: var(--ink-3); }
.mirror-row.soon .play-ring { background: none; box-shadow: inset 0 0 0 1.5px var(--line); color: var(--ink-3); }
.more-note { margin: 14px 0 0; font: 500 var(--fs-small)/1.4 var(--text); color: var(--ink-2); }
.path .btn-outline { margin-top: 20px; }

/* =====================================================================
   3 · PLAYER (Mirror and podcast)
   ===================================================================== */
.player { align-items: center; text-align: center; }
.player .topbar { align-self: stretch; }
.player .eyebrow { flex: 1; text-align: center; margin-right: 34px; }
/* the title is the topic: bold italic Magistral (kit tracking). The captions below are Kevin's voice: light, upright, bigger. */
.player h1 { margin: clamp(12px, 3dvh, 28px) 0 0; font: italic 700 var(--fs-title)/1.15 var(--display); letter-spacing: -.02em; max-width: 330px; }
/* the play button: solid white with the screen's one glow (Mirror and podcast players) */
.big-play {
  position: absolute; left: 50%; top: 50%; width: 35%; height: 35%; transform: translate(-50%, -50%);
  display: grid; place-items: center; border-radius: 50%;
  background: var(--ink); color: var(--bg); box-shadow: 0 0 44px rgba(255, 255, 255, .14);
  transition: transform .12s ease;
}
.big-play:active { transform: translate(-50%, -50%) scale(.95); }
.big-play svg { width: 34%; height: 34%; }
.big-play .i-play { margin-left: 6%; }
.sound-hint { display: flex; align-items: center; justify-content: center; gap: 8px; margin: 0; font: 500 var(--fs-small)/1 var(--text); color: var(--ink-3); }
.sound-hint svg { width: 14px; height: 14px; }

/* ---------- Mirror player (Spotify-like): artwork, title, bar, controls, Subtitles + Best with sound ---------- */
.mirror-player { align-items: stretch; text-align: left; }
.mirror-player .eyebrow, .subs .eyebrow { color: var(--ink); font-size: var(--fs-body); letter-spacing: .08em; }
/* the artwork: Daily Xcellence logo + "it starts with you" on a dark rounded card. Square, never taller than 42% of the screen. */
.art {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 5%;
  width: min(100%, 42dvh); aspect-ratio: 1; margin: clamp(10px, 2dvh, 20px) auto 0;
  border: 1px solid var(--line); border-radius: 20px; background: linear-gradient(160deg, #1d1d1d, #111);
  container-type: inline-size;
}
.art img { width: 74%; height: auto; mix-blend-mode: screen; }   /* the logo's black background vanishes into the card */
.art p { margin: 0; font: italic 700 clamp(11px, 3.6vw, 15px)/1 var(--display); font-size: 4.3cqw; letter-spacing: .3em; text-indent: .3em; white-space: nowrap; }
/* title on two lines, left, Magistral; no line under it (MIRROR 01 is in the top bar) */
.mirror-player h1 { max-width: none; margin: clamp(16px, 3dvh, 28px) 0 0; text-align: center; }   /* centred (Mirror and episode players) */
/* the bar: grey track, the free part lighter (before the email), white fill and dot; drag or tap it */
.scrub { margin-top: clamp(14px, 2.6dvh, 24px); padding: 12px 0; touch-action: none; cursor: pointer; border-radius: var(--r-sm); }
.scrub-track { position: relative; height: 4px; border-radius: 2px; background: rgba(255, 255, 255, .14); }
.scrub-free, .scrub-fill { position: absolute; top: 0; bottom: 0; left: 0; border-radius: 2px; }
.scrub-free { background: rgba(255, 255, 255, .3); }
.scrub-fill { width: 0; background: var(--ink); transition: width .25s linear; }
.scrub-knob { position: absolute; top: 50%; left: 0; width: 14px; height: 14px; margin: -7px 0 0 -7px; border-radius: 50%; background: var(--ink); transition: left .25s linear, transform .15s ease; }
.scrub.dragging .scrub-fill, .scrub.dragging .scrub-knob { transition: none; }
.scrub.dragging .scrub-knob { transform: scale(1.3); }
.scrub-times { display: flex; justify-content: space-between; font: 500 var(--fs-small)/1 var(--text); color: var(--ink-2); font-variant-numeric: tabular-nums; }
.mirror-player .transport, .subs .transport { margin-top: clamp(10px, 2dvh, 20px); }
.mirror-player .transport .skip svg, .subs .transport .skip svg { width: 34px; height: 34px; }
/* bottom row: the outlined Subtitles button left, Best with sound right; sits at the bottom on tall phones */
.player-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: auto; padding-top: clamp(18px, 3dvh, 32px); }
.cc-btn {
  display: inline-flex; align-items: center; gap: 10px; height: 46px; padding: 0 20px 0 16px;
  border: 1.5px solid rgba(255, 255, 255, .55); border-radius: var(--r-full); font: 500 var(--fs-body)/1 var(--text);
  transition: transform .12s ease;
}
.cc-btn:active { transform: scale(.97); }
.cc-btn svg { width: 24px; height: 24px; }
.player-foot .sound-hint { font-size: var(--fs-body); color: var(--ink-2); }
.player-foot .sound-hint svg { width: 18px; height: 18px; }

/* ---------- Subtitles: full-screen layer over the Mirror player (slides up; under the email gate) ---------- */
.subs {
  position: fixed; top: 0; bottom: 0; left: 50%; z-index: 15; width: min(100%, var(--frame));
  display: flex; flex-direction: column; padding: calc(var(--safe-top) + 20px) var(--pad) calc(var(--safe-bottom) + 28px);
  background: var(--bg); transform: translate(-50%, 100%); visibility: hidden;
  transition: transform .38s cubic-bezier(.2, .8, .2, 1), visibility 0s linear .38s;
}
.subs.open { transform: translate(-50%, 0); visibility: visible; transition: transform .38s cubic-bezier(.2, .8, .2, 1), visibility 0s; }
.subs.instant { transition: none; }
.subs .eyebrow { flex: 1; text-align: center; }
.subs .subs-x { margin: 0 -10px 0 0; }
.subs-card { margin-top: 14px; padding: 18px 20px; text-align: center; border: 1px solid var(--line); border-radius: 16px; background: var(--surface); font: italic 700 var(--fs-20)/1.1 var(--display); letter-spacing: -.01em; }
/* the line just said (grey, smaller) above the line being said: each word turns white as Kevin says it */
.subs-lines { flex: 1; min-height: 0; display: flex; flex-direction: column; justify-content: center; gap: 18px; padding: 24px 0; overflow: hidden; text-align: center; }
.subs-prev { margin: 0; font: italic 700 var(--fs-title)/1.15 var(--display); letter-spacing: -.02em; color: var(--ink-3); text-wrap: balance; }
.subs-prev:empty { display: none; }
.subs-now { margin: 0; font: italic 700 var(--fs-display)/1.12 var(--display); letter-spacing: -.02em; text-wrap: balance; }
.subs-now .w { color: #4f4f4c; transition: color .12s ease; }
.subs-now .w.said, .subs-now .w.now { color: var(--ink); }
.subs-now.in { animation: subs-in .35s ease both; }
@keyframes subs-in { from { opacity: 0; transform: translateY(10px); } }
.subs-controls { display: flex; flex-direction: column; border-top: 1px solid var(--line); padding-top: 6px; }
/* filled CC = subtitles on; tap to turn them off */
.cc-on { align-self: center; margin-top: 16px; height: 32px; padding: 0 12px; border-radius: var(--r-sm); background: var(--ink); color: var(--bg); font: 700 var(--fs-small)/1 var(--text); letter-spacing: .06em; }
@media (prefers-reduced-motion: reduce) { .subs, .subs.open { transition: none; } .subs-now.in { animation: none; } }
/* the player fades out as it hands over to the card unlocked screen */
.player.leaving { animation: leave .3s ease forwards; }
@keyframes leave { to { opacity: 0; transform: scale(.98); } }

/* episode player: the Mirror player's layout (.mirror-player), the episode's cassette as the artwork */
.art.tape-art img { width: 90%; mix-blend-mode: normal; filter: drop-shadow(0 14px 24px rgba(0, 0, 0, .6)); }
.player-foot.solo { justify-content: center; }
.episode-player .m21-end { align-self: center; margin-top: 18px; }
.next-lock { display: flex; align-items: center; justify-content: center; gap: 8px; margin: 18px 0 0; font: 500 var(--fs-small)/1 var(--text); color: var(--ink-3); }
.next-lock svg { width: 14px; height: 14px; }
.transport { display: flex; align-items: center; justify-content: center; gap: 28px; margin-top: clamp(18px, 3dvh, 32px); }
.transport .skip { display: grid; place-items: center; width: 52px; height: 52px; border-radius: 50%; color: var(--ink); }
.transport .skip svg { width: 28px; height: 28px; }
.transport .big-play { position: static; transform: none; width: 76px; height: 76px; }
.transport .big-play:active { transform: scale(.95); }
.transport .big-play svg { width: 28px; height: 28px; }

/* ---------- unlock sheet ---------- */
.dim { position: fixed; inset: 0; z-index: 20; background: rgba(0, 0, 0, .6); opacity: 0; pointer-events: none; transition: opacity .35s ease; }
.dim.open { opacity: 1; pointer-events: auto; }
.sheet {
  position: fixed; left: 50%; bottom: 0; z-index: 21; width: min(100%, var(--frame));
  padding: 22px var(--pad) calc(var(--safe-bottom) + 22px);
  border-top: 1px solid var(--line); border-radius: var(--r-md) var(--r-md) 0 0;
  background: var(--surface); box-shadow: var(--shadow);
  transform: translate(-50%, 110%); transition: transform .55s cubic-bezier(.2, .9, .25, 1.03);
  text-align: left;
}
.sheet.open { transform: translate(-50%, 0); }
.host { display: flex; align-items: center; gap: 12px; }
.host img { width: 46px; height: 46px; border-radius: 50%; object-fit: cover; box-shadow: 0 0 0 1.5px var(--ink-3); }
.host b { display: block; font: 700 var(--fs-small)/1 var(--text); letter-spacing: var(--ls-label); }
.host small { display: block; margin-top: 6px; font: 500 var(--fs-small)/1 var(--text); color: var(--ink-2); }
.sheet h2 { margin: 18px 0 14px; font: italic 700 var(--fs-display)/1 var(--display); letter-spacing: -.03em; }
/* what the email gives: the kit's bullet list, small white dots */
.unlock-list { display: flex; flex-direction: column; gap: 10px; margin: 0 0 20px; padding: 0; list-style: none; font: 500 var(--fs-body)/1.35 var(--text); }
.unlock-list li { position: relative; padding-left: 18px; }
.unlock-list li::before { content: ""; position: absolute; left: 2px; top: .55em; width: 6px; height: 6px; border-radius: 50%; background: var(--ink); }
/* the email field (kit input, dark): full width, white border while typing; the white KEEP LISTENING button sits under it */
.email-row {
  display: flex; align-items: center; height: 56px; padding: 0 18px;
  border: 1px solid var(--line); border-radius: var(--r-md); background: var(--bg);
  transition: border-color .2s ease;
}
.email-row:focus-within { border-color: var(--ink); }
.email-row.error { border-color: var(--error); }
.email-row input {
  flex: 1; min-width: 0; height: 100%; padding: 0; border: 0; outline: none; background: none;
  color: var(--ink); font: 500 var(--fs-body)/1 var(--text);
}
.email-row input::placeholder { color: var(--ink-3); }
.form-error { min-height: 18px; margin: 6px 0 4px 4px; font: 500 var(--fs-small)/1.4 var(--text); color: var(--error); }
.form-error:empty { min-height: 10px; }
[data-gate-form] .btn-gold { height: 56px; }
.fine { margin: 6px 0 0; text-align: center; font: 500 var(--fs-small)/1.4 var(--text); color: var(--ink-3); }
.sheet .link { display: block; margin: 8px auto 0; text-align: center; }

/* ---------- toast ---------- */
.toast {
  position: fixed; left: 50%; top: calc(var(--safe-top) + 14px); z-index: 40;
  display: flex; align-items: center; gap: 10px; padding: 11px 16px 11px 12px; border-radius: var(--r-full);
  background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow);
  font: 700 var(--fs-small)/1 var(--text); letter-spacing: var(--ls-label); white-space: nowrap;
  opacity: 0; transform: translate(-50%, -16px); pointer-events: none; transition: opacity .35s ease, transform .35s ease;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast .tick { display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: var(--ink); color: var(--bg); }
.toast .tick svg { width: 14px; height: 14px; }

/* =====================================================================
   4 · NUDGE CARDS (keep screen + Nudges tab)
   ===================================================================== */
/* ---------- 4a · card unlocked (straight after a Mirror or episode) ---------- */
.reward { align-items: center; text-align: center; overflow: hidden; }
/* "✓ MIRROR 01 DONE": a small chip, an achievement rather than a label */
.done-chip {
  display: inline-flex; align-items: center; gap: 8px; height: 32px; margin: 16px 0 0; padding: 0 14px 0 10px;
  border: 1px solid var(--line); border-radius: var(--r-full); background: var(--surface);
  font: 700 var(--fs-small)/1 var(--text); letter-spacing: var(--ls-button); animation: rise .6s ease both;
}
.done-chip svg { width: 14px; height: 14px; }
.reward h1 { margin: 14px 0 0; font: italic 700 var(--fs-display)/1.05 var(--display); letter-spacing: var(--ls-display); animation: rise .6s ease .1s both; }
@keyframes rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
/* the card sits centred in the room between the title and the button */
.reward-stage { flex: 1 1 auto; min-height: 0; display: flex; align-items: center; justify-content: center; margin: clamp(16px, 3dvh, 28px) 0; perspective: 1200px; }
/* the card arrives face down, turns over, then floats: a slow rise and fall with a little tilt */
.reward-card {
  position: relative; width: min(272px, 68vw, 42dvh); aspect-ratio: 745 / 1040; border-radius: var(--r-md);
  box-shadow: 0 0 60px var(--gold-35);
  animation: cardIn .5s ease both, cardFloat 6s ease-in-out 1.6s infinite;
}
.reward-card.white, .reward-card.black { box-shadow: 0 0 60px rgba(255, 255, 255, .16); }   /* gold glow only behind gold cards */
.rc-inner { position: absolute; inset: 0; transform-style: preserve-3d; animation: cardTurn 1s cubic-bezier(.3, .7, .2, 1) .35s both; }
.rc-face { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; border-radius: var(--r-md); backface-visibility: hidden; -webkit-backface-visibility: hidden; }
.rc-back { transform: rotateY(180deg); }
/* a soft band of light slides across the card, like light on foil */
.rc-sheen {
  position: absolute; inset: 0; border-radius: var(--r-md); pointer-events: none; mix-blend-mode: soft-light;
  background: linear-gradient(105deg, transparent 35%, rgba(255, 255, 255, .75) 50%, transparent 65%) no-repeat;
  background-size: 250% 100%; background-position: 150% 0;
  animation: sheen 4.5s ease-in-out 1.5s infinite;
}
@keyframes cardIn { from { opacity: 0; transform: translateY(24px) scale(.94); } to { opacity: 1; transform: none; } }
@keyframes cardTurn { from { transform: rotateY(180deg); } to { transform: rotateY(0deg); } }
@keyframes cardFloat {
  0%, 100% { transform: translateY(0) rotateX(0deg) rotateY(0deg); }
  25% { transform: translateY(-6px) rotateX(3deg) rotateY(-5deg); }
  50% { transform: translateY(-10px) rotateX(0deg) rotateY(0deg); }
  75% { transform: translateY(-6px) rotateX(-3deg) rotateY(5deg); }
}
@keyframes sheen { 0% { background-position: 150% 0; } 45%, 100% { background-position: -50% 0; } }
/* collected: white text, white segments for the cards you have, grey for the rest (no gold) */
.segs { display: flex; gap: 3px; width: 100%; max-width: 300px; margin-top: 12px; }
.segs span { flex: 1; height: 3px; border-radius: var(--r-full); background: rgba(255, 255, 255, .14); }
.segs span.on { background: var(--ink); }
.segs span.new { animation: segIn .6s ease 1.3s both; }
@keyframes segIn { from { background: rgba(255, 255, 255, .14); transform: scaleY(1); } 60% { transform: scaleY(2.4); } to { background: var(--ink); transform: scaleY(1); } }

/* COLLECT and EXPLORE are fixed pages (lockPage in app.js): no scrolling, no bounce; only the cards / cassettes move */
html.locked, html.locked body { height: 100%; overflow: hidden; overscroll-behavior: none; }
html.locked body { position: fixed; inset: 0; width: 100%; }

/* ---------- 4b · COLLECT: all 21 cards in one arc you flick through ---------- */
/* one screen, no scrolling: the bar (13 OF 21), stages, question, the arc (takes the room left), the info line */
.home.collect { height: 100dvh; min-height: 0; overflow: hidden; }
/* AWARENESS · ACCEPTANCE · ACTION: light up by themselves as you flick; tap one to jump to it */
.arc-stages { display: flex; justify-content: center; gap: 4px; margin-top: 28px; }
.arc-stages button {
  height: 32px; padding: 0 12px; border-radius: var(--r-full); color: var(--ink-3);
  font: 700 clamp(10px, 2.8vw, 11px)/1 var(--text); letter-spacing: .12em; white-space: nowrap;
  transition: background-color .25s ease, color .25s ease;
}
.arc-stages button[aria-current="true"] { color: var(--ink); background: rgba(255, 255, 255, .1); }
/* the stage's question (CAN I SEE IT?), one line */
.arc-ask { margin: 14px 0 0; text-align: center; font: italic 700 min(var(--fs-title), 5vw)/1.1 var(--display); letter-spacing: -.02em; white-space: nowrap; }
.arc-ask.swap { animation: rise .35s ease both; }
/* the stage the cards stand on: full width, 3D */
.arc {
  position: relative; flex: 1 1 auto; min-height: 220px; margin: 6px calc(-1 * var(--pad)) 0;
  perspective: 1500px; perspective-origin: 50% 46%; overflow: hidden; touch-action: none; cursor: grab;   /* a finger on the cards only turns them */
  -webkit-user-select: none; user-select: none; -webkit-tap-highlight-color: transparent;
}
.arc.dragging { cursor: grabbing; }
.arc, .tapes { contain: layout paint; }   /* what happens inside never makes the rest of the page redraw */
.arc:focus-visible { outline-offset: -4px; }
.arc { --card-h: min(84%, 340px, 88vw); --floor: calc(47% + var(--card-h) / 2 + 22px); }   /* the light sits just under the cards */
/* moved frame by frame from app.js (swipeDeck): no CSS transition here, it would fight the glide and make cards lag and pile up */
.arc-card {
  position: absolute; top: 47%; left: 50%; height: var(--card-h); aspect-ratio: 745 / 1040;
  border-radius: 14px; background: #111; cursor: pointer; backface-visibility: hidden; -webkit-backface-visibility: hidden;
  box-shadow: 0 22px 36px rgba(0, 0, 0, .7), 0 0 0 1px rgba(255, 255, 255, .06);
}
/* the face (or, for a card you don't have yet, the card back: the same back the Card unlocked screen turns over) */
.arc-inner { position: absolute; inset: 0; transform-style: preserve-3d; }
.arc-face {
  position: absolute; inset: 0; display: block; width: 100%; height: 100%; object-fit: cover; border-radius: 14px; pointer-events: none;
  -webkit-backface-visibility: hidden; backface-visibility: hidden;
}
.arc-back { transform: rotateY(180deg); }
/* just unlocked: it turns over from its back, once, as the tab opens */
.arc-card.flip-in { perspective: 1200px; }
.arc-card.flip-in .arc-inner { animation: cardTurn 1s cubic-bezier(.3, .7, .2, 1) .45s both; }
/* the light the cards stand on: silver, gold only under gold cards (crossfades as you flick) */
.arc-floor, .arc-glow { position: absolute; pointer-events: none; transition: opacity .5s ease; }
.arc-floor {
  left: 10%; right: 10%; top: var(--floor); height: 2px; border-radius: 50%; filter: blur(1.5px);
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .3) 18%, rgba(255, 255, 255, .85) 50%, rgba(255, 255, 255, .3) 82%, transparent);
}
.arc-glow { left: 14%; right: 14%; top: calc(var(--floor) - 60px); height: 120px; border-radius: 50%; filter: blur(26px); background: radial-gradient(closest-side, rgba(255, 255, 255, .12), transparent 72%); }
.arc::before, .arc::after { content: ""; position: absolute; pointer-events: none; opacity: 0; transition: opacity .5s ease; }
.arc::before {
  left: 10%; right: 10%; top: var(--floor); height: 3px; border-radius: 50%; filter: blur(1.5px);
  background: linear-gradient(90deg, transparent, rgba(170, 129, 7, .45) 18%, rgba(255, 239, 154, .9) 50%, rgba(170, 129, 7, .45) 82%, transparent);
}
.arc::after { left: 14%; right: 14%; top: calc(var(--floor) - 60px); height: 120px; border-radius: 50%; filter: blur(26px); background: radial-gradient(closest-side, rgba(224, 184, 76, .22), transparent 72%); }
.arc[data-tone="gold"]::before, .arc[data-tone="gold"]::after { opacity: 1; }
.arc[data-tone="gold"] .arc-floor, .arc[data-tone="gold"] .arc-glow { opacity: 0; }
/* under the arc: what the middle card is. Yours: "✓ MIRROR 01 · TAP TO SAVE". Locked: "▶ LISTEN TO EPISODE 09 TO UNLOCK" */
.arc-info {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; align-self: center; height: 40px; margin-top: 6px; padding: 0 18px;
  border-radius: var(--r-full); border: 1px solid var(--line); color: var(--ink-2);
  font: 700 var(--fs-small)/1 var(--text); letter-spacing: var(--ls-button); white-space: nowrap;
}
.arc-info svg { width: 14px; height: 14px; flex: none; }
.arc-info.locked { color: var(--ink); border-color: rgba(255, 255, 255, .3); }
.arc-info:active { transform: scale(.97); }
/* 13 OF 21 COLLECTED, at the top: the 21 segments in their three decks; the middle card's segment stands taller */
.arc-progress { margin-top: 22px; }
.arc-progress .segs span { transition: transform .25s ease, background-color .25s ease; }
.arc-progress .segs span.gap { margin-left: 7px; }
.arc-progress .segs span.here { transform: scaleY(2.6); background: rgba(255, 255, 255, .45); }
.arc-progress .segs span.on.here { background: var(--ink); }
@media (prefers-reduced-motion: reduce) { .arc-card { transition: none; } .arc-ask.swap, .arc-card.flip-in .arc-inner { animation: none; } }

/* ---------- 4c · a collected card, big (tap to flip) ---------- */
.viewer {
  position: fixed; left: 50%; top: 50%; z-index: 21; width: min(100% - 48px, 320px);
  display: flex; flex-direction: column; align-items: center; gap: 16px;
  transform: translate(-50%, -46%) scale(.96); opacity: 0; pointer-events: none; transition: transform .35s ease, opacity .25s ease;
}
.viewer.open { transform: translate(-50%, -50%); opacity: 1; pointer-events: auto; }
.viewer .card { width: min(260px, 66vw, 46dvh); }
.viewer .tap-hint { margin: 0; }
.viewer .link { margin-top: -8px; }

.card {
  aspect-ratio: 745 / 1040; perspective: 1200px; container-type: inline-size;
}
.card-inner { display: block; text-align: center; color: inherit; position: relative; width: 100%; height: 100%; transform-style: preserve-3d; transition: transform .7s cubic-bezier(.3, .7, .2, 1); }
.card.flipped .card-inner { transform: rotateY(180deg); }
.face { position: absolute; inset: 0; border-radius: var(--r-md); overflow: hidden; backface-visibility: hidden; -webkit-backface-visibility: hidden; }
.face.front { display: block; width: 100%; height: 100%; padding: 0; border: 0; background: none; cursor: pointer; }
.face.front img { width: 100%; height: 100%; object-fit: cover; }
.card:not(.flipped) .face.back { pointer-events: none; }
.card.flipped .face.front { pointer-events: none; }
.card .face { box-shadow: 0 0 34px var(--gold-35); }

/* back of card · card artwork: it keeps its own colours and scales with the card */
.face.back { transform: rotateY(180deg); padding: 6%; text-align: center; }
.face.back .frame { display: flex; flex-direction: column; height: 100%; padding: 7% 7% 5%; border-radius: 10px; border: 2.5px solid currentColor; }
.back-top { display: flex; flex-direction: column; flex: 1; min-height: 0; padding: 0; border: 0; background: none; color: inherit; text-align: center; cursor: pointer; }
.face.back .head { display: grid; place-items: center; flex-shrink: 0; height: 40px; border-radius: 8px; font: italic 700 clamp(15px, 5vw, 19px)/1 var(--display); }
.face.back .lbl { margin: 8% 0 2%; font: 700 8.5px/1 var(--text); letter-spacing: .22em; }
.card-actions { display: flex; flex-direction: column; align-items: center; gap: 2px; flex-shrink: 0; padding-top: 6px; }
.card-actions .yes { width: 100%; height: 34px; border-radius: 17px; font: 700 10.5px/1 var(--text); letter-spacing: .18em; cursor: pointer; }
.card-actions .no { padding: 7px 10px 2px; font: 500 11px/1 var(--text); text-decoration: underline; text-underline-offset: 3px; opacity: .75; cursor: pointer; }
.back.gold .card-actions .yes { background: #151515; color: #f2cf6c; }
.back.black .card-actions .yes { background: var(--gold-metal); color: var(--on-gold); }
.back.white .card-actions .yes { background: #111111; color: #ffffff; }
.face.back .line { padding: 5% 2%; font: italic 700 clamp(11px, 3.4vw, 13px)/1.18 var(--display); border-top: 1px solid var(--rule); }
.face.back .lbl + .line { border-top: 0; }
.face.back .lbl, .face.back .line, .face.back .why { display: block; }
.face.back .why { margin-top: auto; font: italic 700 clamp(10px, 3.2vw, 12px)/1.25 var(--display); }
.back.gold { background: linear-gradient(160deg, #f9ec8f 0%, #d9b648 35%, #f6df7a 55%, #b98f2b 85%, #e6c45c 100%); color: #15110a; --rule: rgba(0, 0, 0, .22); }
.back.gold .head { background: #151515; }
.back.gold .head span { background: var(--gold-metal); -webkit-background-clip: text; background-clip: text; color: transparent; }
.back.black { background: #050505; color: #ffffff; border: 1px solid #3a3a3a; --rule: rgba(255, 255, 255, .18); }
.back.black .head { background: #ffffff; color: #111111; }
.back.white { background: #ffffff; color: #111111; --rule: rgba(0, 0, 0, .14); }
.back.white .head { background: #111111; color: #ffffff; }


/* =====================================================================
   5 · HOME (after email) · tabs
   ===================================================================== */
/* room at the bottom for the floating tab bar */
.home { padding-bottom: calc(var(--tabbar) + var(--safe-bottom) + 24px); }
.home .logo12 { width: 100%; max-width: 360px; margin: 26px 0 0; }
.home .mirror-list { margin-top: 16px; }

/* LISTEN / COLLECT / EXPLORE: tight Magistral, one line (data-fit shrinks it only if needed), no reflection */
.tab-title { margin: 26px 0 0; font: italic 700 var(--fs-tab)/1 var(--display); letter-spacing: -.04em; white-space: nowrap; }
.tab-title > span { display: inline-block; }
/* "12 OF 12 HEARD" and a white segmented bar (same as Card unlocked) */
.tab-progress { margin-top: 12px; font: 700 var(--fs-small)/1 var(--text); letter-spacing: var(--ls-label); }
.tab-progress .segs { max-width: none; margin-top: 10px; }
.tab-progress + .tab-sub { margin-top: 14px; }
.home .tab-sub { margin: 10px 0 0; font: 500 var(--fs-body)/1.5 var(--text); color: var(--ink-2); }
.home .btn-gold { margin-top: 16px; }

/* EXPLORE: a row of cassettes you swipe, then the middle one's title, length and button. One screen, no scrolling. */
.home.explore { height: 100dvh; min-height: 0; overflow: hidden; }
.tapes {
  position: relative; flex: 1 1 auto; min-height: 200px; margin: 8px calc(-1 * var(--pad)) 0; overflow: hidden;
  touch-action: none; cursor: grab; -webkit-user-select: none; user-select: none; -webkit-tap-highlight-color: transparent;   /* a finger on the cassettes only swipes them */
  container-type: size;
}
.tapes.dragging { cursor: grabbing; }
.tapes:focus-visible { outline-offset: -4px; }
/* one cassette + its number under it: as wide as the room allows (it shrinks on short phones) */
.tape {
  position: absolute; top: 50%; left: 50%; width: 58vw; width: min(64cqw, (100cqh - 70px) * 1.45, 300px);
  cursor: pointer;   /* moved frame by frame from app.js: no CSS transition (it would fight the glide) */
}
.tape-pic { position: relative; isolation: isolate; }
/* no live shadow filter: it is recalculated every frame while the cassettes scale, which made swiping lag */
.tape img { display: block; width: 100%; height: auto; pointer-events: none; }
/* the one you can play, in the middle: a soft white light pulses around it (tap it to play) */
.tape-pic::before {
  content: ""; position: absolute; z-index: -1; inset: 4% 3%; border-radius: 6% / 9%; opacity: 0; pointer-events: none;
  box-shadow: 0 0 30px 12px rgba(255, 255, 255, .6), 0 0 90px 30px rgba(255, 255, 255, .28); transition: opacity .4s ease;
}
.tape[aria-selected="true"]:not(.locked) .tape-pic::before { animation: tapeGlow 2s ease-in-out infinite; }
@keyframes tapeGlow { 0%, 100% { opacity: .15; transform: scale(.98); } 50% { opacity: 1; transform: scale(1.03); } }
/* not open yet: the frosted cassette (a ready-made picture: ep-NN-locked.webp) with a white lock on it, and LOCKED under its number */
.tape-lock { position: absolute; inset: 0; display: grid; place-items: center; color: var(--ink); }
.tape-lock svg { width: 26%; height: auto; stroke-width: 1.6; }
.tape-locked { margin: 6px 0 0; text-align: center; font: 700 var(--fs-small)/1 var(--text); letter-spacing: var(--ls-label); color: var(--ink-3); }
/* 02 • under the middle cassette; 01 ✓ (heard) and 03 / LOCKED under the others */
.tape-n {
  display: flex; align-items: center; justify-content: center; gap: 10px; margin: 14px 0 0;
  font: italic 700 40px/1 var(--display); letter-spacing: -.02em; color: var(--ink-3); font-variant-numeric: tabular-nums;
}
.tape[aria-selected="true"] .tape-n { color: var(--ink); }
.tape-n svg { width: 30px; height: 30px; }
.tape-n .ic-done { display: grid; place-items: center; width: 34px; height: 34px; border: 2.5px solid currentColor; border-radius: 50%; }
.tape-n .ic-done svg { width: 18px; height: 18px; }
.tape-n .ic-dot { width: 12px; height: 12px; border-radius: 50%; background: currentColor; }
/* the middle episode */
.tape-info { display: flex; flex-direction: column; align-items: center; padding-top: 6px; text-align: center; }
.tape-title { margin: 0; font: italic 700 min(var(--fs-display), 8vw)/1.08 var(--display); letter-spacing: -.03em; text-wrap: balance; min-height: 2.16em; display: flex; align-items: center; }
.tape-meta { margin: 8px 0 0; min-height: 16px; font: 500 var(--fs-body)/1 var(--text); color: var(--ink-2); }
/* one grey line instead of a button: "Finish 02 to unlock 03", "Tap to listen again", "Finish Episode 02 to open"… */
.tape-hint { margin: clamp(12px, 2.4dvh, 20px) 0 4px; min-height: 1.3em; font: italic 300 var(--fs-20)/1.3 var(--text); color: var(--ink-2); }
@media (prefers-reduced-motion: reduce) { .tape[aria-selected="true"]:not(.locked) .tape-pic::before { animation: none; opacity: .7; } }

/* tab bar: the kit's floating glass pill, dark. Active tab white on a soft highlight; the others grey. */
.tabbar {
  position: fixed; left: 50%; bottom: max(16px, calc(var(--safe-bottom) + 8px)); z-index: 10;
  width: min(100% - 32px, var(--frame) - 32px); height: 64px; transform: translateX(-50%);
  display: flex; gap: 4px; padding: 6px; border-radius: 32px;
  border: 1px solid rgba(255, 255, 255, .08); background: rgba(28, 28, 28, .74);
  -webkit-backdrop-filter: blur(22px) saturate(160%); backdrop-filter: blur(22px) saturate(160%);
  box-shadow: 0 10px 30px rgba(0, 0, 0, .5), inset 0 1px 0 rgba(255, 255, 255, .06);
}
/* kept quiet: the tab labels are the one place under 12px (11px, by choice) */
.tabbar a {
  flex: 1; min-width: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 5px;
  border-radius: 26px; color: var(--ink-3); font: italic 700 11px/1 var(--display); letter-spacing: .06em;
  transition: background-color .2s ease, color .2s ease;
}
.tabbar a svg { width: 20px; height: 20px; }
.tabbar a[aria-current="page"] { color: var(--ink); background: rgba(255, 255, 255, .1); }

/* the MIRROR 21 logotype, everywhere Mirror 21 is named: MIRROR in bold italic Magistral (the text colour), 21 in gold.
   It takes the size of the text around it. The brand mark is the one place gold stays. */
.m21-mark { font: italic 700 1em/1 var(--display); letter-spacing: -.01em; white-space: nowrap; text-transform: none; }
.m21-mark b { font-weight: inherit; color: var(--gold); }

/* ---------- Mirror 21 card (a white door in the dark app) ---------- */
.m21-card {
  position: relative; display: block; margin-top: 18px; padding: 20px 20px 18px; border-radius: 20px;
  background: var(--paper); border: 1px solid var(--paper); color: var(--paper-ink);
  text-align: left;
}
.m21-eyebrow { display: block; font: 700 var(--fs-small)/1.3 var(--text); letter-spacing: var(--ls-label); color: var(--paper-ink-2); }
.m21-name { display: flex; align-items: center; margin-top: 12px; font: 700 var(--fs-display)/1 var(--display); letter-spacing: -.02em; }
.m21-line { display: block; margin-top: 10px; font: 500 var(--fs-body)/1.4 var(--text); color: var(--paper-ink-2); }
/* one black button: SEE HOW IT WORKS · $99 */
.m21-cta {
  display: flex; align-items: center; justify-content: center; height: 52px; margin-top: 16px; border-radius: var(--r-full);
  background: var(--paper-ink); color: var(--paper); font: 700 var(--fs-small)/1 var(--text); letter-spacing: var(--ls-button);
}
.m21-card:active .m21-cta { transform: scale(.98); }
.m21-cta .m21-mark { margin-left: .3em; font-size: 15px; letter-spacing: 0; }   /* SEE MIRROR 21: the logotype inside */
.m21-card.compact { padding: 16px 16px 14px; }
.m21-card.compact .m21-name { font-size: var(--fs-title); }
.m21-card.compact .m21-cta { height: 44px; margin-top: 12px; }
.m21-end { position: relative; width: 100%; max-width: 360px; margin-top: 22px; }
.m21-end .m21-card { margin-top: 0; }
.m21-end-x { position: absolute; top: 8px; right: 8px; z-index: 1; display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; color: var(--paper-ink-2); }
.m21-end-x svg { width: 16px; height: 16px; }

/* ---------- Mirror 21 screen ---------- */
.m21 .m21-kicker { margin-top: 18px; color: var(--gold); }
.m21-tag { margin: 0; font: italic 300 var(--fs-20)/1.4 var(--text); color: var(--ink-2); }
.m21-points { margin: 0; padding: 0; list-style: none; }
.m21-points li { display: flex; gap: 14px; padding: 14px 0; border-top: 1px solid var(--line); font: 500 var(--fs-body)/1.5 var(--text); }
.m21-points li:first-child { border-top: 0; }
.m21-points li span { flex-shrink: 0; width: 24px; font: 700 var(--fs-small)/1.9 var(--text); color: var(--gold); }
.m21-host { display: flex; align-items: center; gap: 12px; margin-top: 14px; font: 500 var(--fs-small)/1.4 var(--text); color: var(--ink-2); }
.m21-host img { width: 44px; height: 44px; border-radius: 50%; object-fit: cover; box-shadow: 0 0 0 1.5px var(--gold); }
.m21-host b { color: var(--ink); font-weight: 700; letter-spacing: var(--ls-label); }
.m21-buy { margin-top: auto; padding-top: 26px; text-align: center; }
.m21-buy .fine { margin-top: 10px; }
.m21-buy .link { display: inline-block; margin-top: 4px; }


/* ---------- placeholder Mirrors ---------- */
.mirror-row.soon { opacity: .5; }
.mirror-row.soon .t { color: var(--ink-2); }

/* ---------- "That's me" lock-screen sheet ---------- */
.sheet.ns h2 { margin: 8px 0 8px; font: italic 700 var(--fs-title)/1.1 var(--display); letter-spacing: 0; }
.ns-row { display: flex; align-items: center; gap: 18px; }
.ns-copy { flex: 1; min-width: 0; }
.eyebrow.gold { color: var(--gold); }
.ns-sub { margin: 0; font: 500 var(--fs-body)/1.5 var(--text); color: var(--ink-2); }
/* the lock-screen mock is a picture of a phone: it keeps its own sizes */
.phone-mock {
  position: relative; flex-shrink: 0; width: 118px; aspect-ratio: 1179 / 2556; border-radius: 20px; overflow: hidden;
  background: #0a0a0a; box-shadow: 0 0 0 3px #2c2c2c, 0 0 0 4px #000, 0 18px 40px rgba(0, 0, 0, .7);
}
.phone-mock img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.phone-mock .pm-date { position: absolute; left: 0; right: 0; top: 11%; text-align: center; font: 500 7px/1 var(--text); color: rgba(255, 255, 255, .85); }
.phone-mock .pm-time { position: absolute; left: 0; right: 0; top: 14%; text-align: center; font: 300 34px/1 var(--text); color: #fff; letter-spacing: -.02em; }
.sheet.ns .btn-gold { margin-top: 20px; }
.ns-after { margin: 10px 0 0; text-align: center; font: 500 var(--fs-small)/1.4 var(--text); color: var(--ink-2); }
.ns-m21 { display: flex; align-items: center; justify-content: center; gap: 6px; flex-wrap: wrap; margin-top: 12px; padding: 12px; border-radius: var(--r-md); background: var(--paper); color: var(--paper-ink); font: 500 var(--fs-small)/1.4 var(--text); text-align: center; }
.ns-m21 b { display: inline-flex; align-items: center; gap: 6px; font: 700 var(--fs-body)/1 var(--text); color: var(--paper-ink); }
.ns-m21 svg { width: 14px; height: 14px; }
.sheet.ns .link { display: block; margin: 6px auto 0; }

/* ---------- Mirror 21 pop-up at a collection milestone (a white door) ---------- */
.sheet.m21-pop { background: var(--paper); color: var(--paper-ink); border-top: 0; text-align: center; }
/* same as the Mirror 21 card: MIRROR + 21 in a black circle, tight title, one black button. No gold. */
.m21-pop-brand { display: flex; align-items: center; justify-content: center; margin: 0; font: 700 var(--fs-body)/1 var(--display); letter-spacing: -.01em; }
.m21-pop-brand .m21-mark { font-size: var(--fs-20); }
/* "SEE MIRROR 21": the logotype inside the button, a touch bigger than the label */
.btn-gold .m21-mark { margin: 0 .3em 0 .15em; font-size: 15px; letter-spacing: 0; }
.m21x .btn-gold, .sheet.m21-pop .btn-gold { gap: 0; }   /* text + logotype + text: spaced by the logotype's margins, not the button's gap */
.sheet.m21-pop h2 { margin: 14px 0 0; font: italic 700 var(--fs-display)/1.05 var(--display); letter-spacing: -.03em; }
.m21-pop-line { margin: 12px auto 0; max-width: 300px; font: 500 var(--fs-body)/1.5 var(--text); color: var(--paper-ink-2); }
.sheet.m21-pop .btn-gold { margin-top: 24px; }
/* the black button on white (the Mirror 21 doors) */
.btn-gold.ink { background: var(--paper-ink); color: var(--paper); }
.sheet.m21-pop .link { display: block; margin: 8px auto 0; color: var(--paper-ink-2); }

/* ---------- Home top bar with MIRROR 21 (a white door) ---------- */
/* the POCKET MIRROR logo (image) left, the MIRROR 21 logotype in a white pill right */
.home-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 44px; }
.home-top .logo { width: 150px; }
.m21-btn {
  display: inline-flex; align-items: center; height: 40px; padding: 0 18px; border-radius: var(--r-full);
  background: var(--paper); color: var(--paper-ink); box-shadow: 0 0 24px rgba(255, 255, 255, .12);
  font: 700 var(--fs-body)/1 var(--display); letter-spacing: -.01em; white-space: nowrap;
  transition: transform .12s ease;
}
.m21-btn:active { transform: scale(.96); }
.m21-btn .g, .m21-card .g, .ns-m21 .g { color: var(--gold-deep); }

/* =====================================================================
   v5 · landing line, nudge choice, captions
   ===================================================================== */


/* nudge cards: back = the question only, bigger lines */
.face.back { display: block; width: 100%; height: 100%; border: 0; cursor: pointer; font: inherit; }
.face.back .frame { display: flex; flex-direction: column; justify-content: flex-start; }
.face.back .head { height: 44px; font-size: clamp(16px, 5.2vw, 20px); }
.face.back .lbl { margin: 10% 0 4%; font-size: 9px; }
.face.back .line { padding: 6.5% 2%; font: italic 700 clamp(13px, 4vw, 15.5px)/1.2 var(--display); }


/* =====================================================================
   MIRROR 21 · white page
   ===================================================================== */
html.is-light, html.is-light body { background: var(--paper); }
/* one white screen (the kit as it is: it's a white kit), never scrolls: everything keeps its size except the phones
   picture, which takes what is left. Gold: the 21 of the logotype and the rule under the phones (as in the design). */
.m21x { position: relative; height: 100dvh; overflow: hidden; padding: calc(var(--safe-top) + 12px) 0 calc(var(--safe-bottom) + 14px); background: var(--paper); color: var(--paper-ink); text-align: center; }
.m21x-top { position: relative; z-index: 1; display: flex; flex-shrink: 0; align-items: center; justify-content: space-between; height: 44px; padding: 0 20px; }
.m21x-brand { margin: 0; font: 700 var(--fs-title)/1 var(--display); letter-spacing: var(--ls-display); }
/* the kit's soft grey round close */
.m21x-close { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; background: rgba(0, 0, 0, .06); color: var(--paper-ink); }
.m21x-close svg { width: 16px; height: 16px; }
/* the headline (SEE IT. OWN IT. CHANGE IT.): huge, black, tight, one phrase per line. As wide as the screen allows for
   the longest line (≈ 6.4em), and shorter when there are more lines (--lines, set from app.js) so the phones keep room. */
.m21x-head {
  flex-shrink: 0; margin: 16px 0 0; padding: 0 16px;
  font: italic 700 64px/.9 var(--display); font-size: min(80px, calc((min(100vw, var(--frame)) - 40px) / 6.6), calc(20dvh / var(--lines, 2))); letter-spacing: -.045em;
}
.m21x-head span { display: block; white-space: nowrap; }
/* the title on top (IN 21 STEPS): Magistral bold italic, a bit bigger than SEE IT. OWN IT. CHANGE IT. under it, without shouting */
.m21x-kicker {
  flex-shrink: 0; margin: 16px 0 0; padding: 0 16px; white-space: nowrap;
  font: italic 700 40px/.95 var(--display); font-size: min(46px, calc((min(100vw, var(--frame)) - 40px) / 8.8), 6dvh); letter-spacing: -.04em;
}
.m21x-kicker + .m21x-head { margin-top: 8px; }
/* one line (SEE IT. OWN IT. CHANGE IT.): starts big and fitTitles (data-fit) shrinks it to exactly the width */
.m21x-head.one { margin: 18px 16px 0; padding: 0; font-size: 44px; line-height: 1; white-space: nowrap; }
.m21x-head.one span { display: inline-block; }
.m21x-sub { flex-shrink: 0; margin: 12px 0 0; padding: 0 20px; font: 300 var(--fs-20)/1.3 var(--text); color: var(--paper-ink-2); text-wrap: balance; }
/* the three phones: they take the room that is left */
.m21x-visual { position: relative; flex: 1 1 auto; min-height: 120px; margin: 12px 6px 0; }
.m21x-visual img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; filter: drop-shadow(0 18px 22px rgba(0, 0, 0, .16)); }
.m21x-body { position: relative; z-index: 1; display: flex; flex-shrink: 0; flex-direction: column; align-items: center; padding: 0 20px; }
/* the gold rule under the phones (as in the design) */
.m21x-rule { align-self: stretch; height: 2px; margin: 14px 16px 0; border: 0; background: var(--gold); }
.m21x-points { display: grid; gap: 10px; margin: 18px 0 0; padding: 0; list-style: none; text-align: left; }
.m21x-points li { display: flex; align-items: center; gap: 12px; font: 500 var(--fs-body)/1.3 var(--text); }
.m21x-points svg { flex-shrink: 0; width: 18px; height: 18px; color: var(--paper-ink); }
/* START MIRROR 21: the black button, the logotype inside (no price: it is on the LET'S FOLLOW THROUGH button) */
.m21x .btn-gold { margin-top: 20px; }
/* short phones: a little tighter, so it still fits on one screen */
@media (max-height: 720px) {
  .m21x-head { margin-top: 10px; }
  .m21x-sub { margin-top: 8px; font-size: var(--fs-body); }
  .m21x-rule { margin-top: 10px; }
  .m21x-points { gap: 6px; margin-top: 12px; }
  .m21x .btn-gold { height: 52px; margin-top: 14px; }
}

/* Kevin's video on the Mirror 21 page: full screen over it, in the MEET KEVIN style (.intro). The picture is nearly
   square, so it sits sharp across the width in the middle and fades into the black above and below. */
.film { z-index: 15; display: none; }
.film.open { display: block; }
.film-frame { position: absolute; left: 0; right: 0; top: 50%; transform: translateY(-50%); aspect-ratio: 480 / 512; cursor: pointer; }
.film-frame .intro-video {
  object-fit: cover;
  -webkit-mask-image: linear-gradient(180deg, transparent 0, #000 14%, #000 78%, transparent 100%); mask-image: linear-gradient(180deg, transparent 0, #000 14%, #000 78%, transparent 100%);
}
.film .intro-play { top: 50%; }   /* in the middle (the video frame sits in the middle of the screen) */
.film .intro-title .m21-mark { font-size: 1em; }
/* LET'S FOLLOW THROUGH: a pop-up in the middle of the screen, over the paused video (the kit's centred pop-up) */
.sheet.m21-pop.center {
  top: 50%; bottom: auto; width: min(100% - 32px, 400px); padding: 26px 22px 18px; border-radius: 24px;
  transform: translate(-50%, -50%) scale(.94); opacity: 0; pointer-events: none;
  transition: transform .35s cubic-bezier(.2, .9, .25, 1.05), opacity .25s ease;
}
.sheet.m21-pop.center.open { transform: translate(-50%, -50%); opacity: 1; pointer-events: auto; }

/* =====================================================================
   Add to home screen
   ===================================================================== */
.a2hs { margin-top: 18px; padding: 14px 14px 12px; border-radius: var(--r-md); border: 1px solid var(--line); background: var(--surface); transition: opacity .3s ease, transform .3s ease; }
.a2hs.gone { opacity: 0; transform: translateY(-6px); }
.a2hs-row { display: flex; align-items: center; gap: 12px; }
.a2hs-row img { width: 44px; height: 44px; border-radius: var(--r-sm); }
.a2hs-row .body { flex: 1; min-width: 0; }
.a2hs-row b { display: block; font: 700 var(--fs-small)/1 var(--text); letter-spacing: var(--ls-label); color: var(--ink-2); }
.a2hs-row .body > span { display: block; margin-top: 6px; font: 500 var(--fs-body)/1.4 var(--text); color: var(--ink); }
.a2hs-x { display: grid; place-items: center; flex-shrink: 0; width: 36px; height: 36px; margin: -6px -6px 0 0; border-radius: 50%; color: var(--ink-2); align-self: flex-start; }
.a2hs-x svg { width: 18px; height: 18px; }
.a2hs-go { display: block; width: 100%; height: 44px; margin-top: 12px; border-radius: var(--r-full); border: 1px solid rgba(255, 255, 255, .24); font: 700 var(--fs-small)/1 var(--text); letter-spacing: var(--ls-button); color: var(--ink); }
.sheet.a2 h2 { margin: 8px 0 18px; font: italic 700 var(--fs-title)/1.1 var(--display); letter-spacing: 0; }
.a2-steps { margin: 0 0 22px; padding: 0; list-style: none; }
.a2-steps li { display: flex; align-items: center; gap: 14px; padding: 14px 0; border-top: 1px solid var(--line); font: 500 var(--fs-body)/1.4 var(--text); }
.a2-steps li:first-child { border-top: 0; }
.a2-steps .n { display: grid; place-items: center; flex-shrink: 0; width: 28px; height: 28px; border-radius: 50%; background: var(--gold); color: var(--on-gold); font: 700 var(--fs-small)/1 var(--text); }
.a2-steps .t { flex: 1; }
.a2-steps .sub { display: block; margin-top: 4px; font-size: var(--fs-small); color: var(--ink-2); }
/* iOS-blue icon tile: it shows what the Share button looks like on the phone */
.a2-steps .ico { display: grid; place-items: center; flex-shrink: 0; width: 40px; height: 40px; border-radius: var(--r-sm); background: var(--bg); color: #4ea3ff; }
.a2-steps .ico svg { width: 22px; height: 22px; }

/* ---------- demo mode ---------- */
.demo-reset { display: block; margin: 18px auto 0; }

/* ---------- play / pause icon swap ---------- */
[data-toggle] .i-pause { display: none; }
[data-toggle].is-playing .i-pause { display: block; }
[data-toggle].is-playing .i-play { display: none; }

/* ---------- motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* =====================================================================
   v6 · nudge cards: IS THIS YOU? + 3 lines
   ===================================================================== */
/* back of the card: the question and the three lines, sized to the card so it never overflows */
.face.back { padding: 6cqw; }
.face.back .frame { padding: 6cqw 5.5cqw 4cqw; border-radius: 3.5cqw; }
.face.back .head { flex-shrink: 0; height: 15.5cqw; border-radius: 3cqw; font-size: 7.4cqw; }
.face.back .lbl { display: none; }
.face.back .lines { flex: 1; display: flex; flex-direction: column; justify-content: center; min-height: 0; }
.face.back .line { display: block; padding: 4.2cqw 1cqw; font-size: 6.7cqw; line-height: 1.16; border-top: 1px solid var(--rule); }
.face.back .lines .line:first-child { border-top: 0; }
