/* Crackinmath — one look for the 14-Day Path and The History of Math.
   Night ground, bone-white type, one historical pigment at a time. See crackinmath/DESIGN.md. */
@import url("fonts.css");

:root {
  color-scheme: dark;
  --night0: #090C12; --night1: #10141F; --night2: #181E2C; --night3: #212838; --line: #2A3247;
  --bone: #F2EADA; --bone-dim: #B9B1A1; --bone-faint: #A09B90;
  --ochre: #E3A13B; --lapis: #7E95FF; --malachite: #45C28F; --cinnabar: #EA5A40; --indigo: #A08CF6; --verdigris: #41BDB5; --gilt: #E9C76B;
  --pigment: var(--ochre);
  --display: "Fraunces Soft", Georgia, "Times New Roman", serif;
  --text: "Instrument Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
  --wrap: min(1200px, calc(100% - 64px));
  --radius: 6px;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 100px; }
body {
  margin: 0; min-height: 100vh; background: var(--night1); color: var(--bone-dim);
  font: 400 1.0625rem/1.7 var(--text); font-optical-sizing: auto;
}
a { color: var(--bone); text-decoration-color: color-mix(in srgb, var(--pigment) 70%, transparent); text-underline-offset: .2em; }
a:hover { color: var(--pigment); }
:focus-visible { outline: 2px solid var(--ochre); outline-offset: 5px; border-radius: 3px; }
img, video, canvas, svg { max-width: 100%; display: block; }
img { height: auto; }
.wrap { width: var(--wrap); margin-inline: auto; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--bone); color: var(--night0); padding: 8px 14px; border-radius: 8px; z-index: 10; }
.skip:focus { left: 12px; }

/* type */
h1, h2, h3 { font-family: var(--display); color: var(--bone); font-weight: 460; letter-spacing: -0.025em; margin: 0; text-wrap: balance; }
h1 { font-size: clamp(2.5rem, 5.5vw, 4.8rem); line-height: 1.06; }
h2 { font-size: clamp(1.8rem, 3.2vw, 2.75rem); line-height: 1.18; }
h3 { font-size: clamp(1.25rem, 2vw, 1.6rem); line-height: 1.25; font-weight: 460; }
p { margin: 0 0 1em; max-width: 68ch; }
.lede { font-size: clamp(1.08rem, 1.65vw, 1.3rem); color: var(--bone-dim); max-width: 52ch; line-height: 1.65; }
.kicker { font: 600 .72rem/1.45 var(--text); letter-spacing: .15em; text-transform: uppercase; color: var(--pigment); margin: 0 0 1rem; }
.mono { font-family: var(--mono); }
.small { font-size: .92rem; }
.faint { color: var(--bone-faint); }
em, i { font-family: var(--display); font-style: italic; }

/* Shared navigation: a quiet frame for the work. */
.site-header { position: sticky; top: 0; z-index: 5; background: var(--night0); border-bottom: 1px solid var(--line); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px 32px; min-height: 80px; flex-wrap: wrap; }
.brand { display: inline-flex; align-items: center; gap: 10px; flex-shrink: 0; min-height: 44px; font: 500 1.45rem/1 var(--display); color: var(--bone); text-decoration: none; letter-spacing: -.025em; }
.brand .brand-wordmark { color: var(--bone); white-space: nowrap; }
.brand-wordmark b { font-weight: inherit; color: var(--ochre); }
.brand-mark, .brand-mark img { display: block; width: 44px; height: 44px; flex-shrink: 0; }
.nav { display: flex; align-items: center; gap: 6px 28px; flex-wrap: wrap; }
.nav a { display: inline-flex; align-items: center; min-height: 44px; padding: 10px 0; font: 500 .93rem/1.4 var(--text); color: var(--bone-dim); text-decoration: none; border-bottom: 1px solid transparent; transition: color .18s, border-color .18s; }
.nav a:hover, .nav a[aria-current="page"] { color: var(--bone); border-bottom-color: var(--ochre); }
.menu-toggle { display: none; align-items: center; justify-content: center; gap: 8px; min-width: 68px; min-height: 44px; padding: 8px 12px; border: 1px solid var(--line); border-radius: 4px; color: var(--bone); background: transparent; font: 500 .9rem/1 var(--text); cursor: pointer; }
.menu-toggle[aria-expanded="true"] { border-color: var(--ochre); }
.site-footer { border-top: 1px solid var(--line); margin-top: 80px; padding: 30px 0 42px; color: var(--bone-faint); font-size: .88rem; }
.site-footer .wrap { display: flex; justify-content: space-between; align-items: start; gap: 28px 56px; flex-wrap: wrap; }
.site-footer p { max-width: 62ch; margin: 0; }
.site-footer .mono { font: 400 .78rem/1.6 var(--text); }
.footer-links { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 24px; margin-top: -10px; }
.footer-links a { display: inline-flex; align-items: center; min-height: 44px; padding: 8px 0; text-decoration: none; }
.footer-links a:hover { text-decoration: underline; }
@media (max-width: 760px) {
  .site-header .wrap { min-height: 72px; gap: 0; }
  .brand { font-size: 1.35rem; }
  .brand-mark, .brand-mark img { width: 40px; height: 40px; }
  .nav { width: 100%; padding: 8px 0 16px; gap: 0 24px; }
  .nav a { flex: 1 0 40%; min-height: 48px; }
  .nav-ready .menu-toggle { display: inline-flex; }
  .nav-ready .nav { display: none; }
  .nav-ready.nav-open .nav { display: flex; border-top: 1px solid var(--line); margin-top: 8px; }
}

/* sections */
.hero { padding: clamp(48px, 7vw, 88px) 0 clamp(32px, 4vw, 52px); }
.hero h1 { max-width: 15ch; }
.hero .lede { margin-top: 26px; }
section { padding: clamp(40px, 6vw, 80px) 0; }
.rule { border: 0; border-top: 1px solid var(--line); margin: 0; }
.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); gap: 24px; }
.grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); gap: 20px; }

/* doors (home) */
.door { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) minmax(120px, 34%); gap: 28px; align-items: end; padding: 26px 0; border-top: 1px solid var(--line); text-decoration: none; color: var(--bone-dim); transition: border-color .2s; min-height: 320px; }
.door:hover { border-color: var(--door, var(--ochre)); color: var(--bone-dim); }
.door h2 { margin-bottom: 12px; }
.door img { border-radius: 4px; aspect-ratio: 9 / 16; object-fit: cover; width: 100%; }
.door .go { font: 500 .92rem/1.5 var(--text); color: var(--door, var(--ochre)); margin-top: 18px; display: inline-block; }

/* key chips */
.keys { display: flex; flex-wrap: wrap; gap: 8px 24px; padding: 0; margin: 0; list-style: none; }
.key { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; padding: 10px 0; border-bottom: 1px solid var(--line); color: var(--bone); font-size: .95rem; text-decoration: none; }
.key::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--k, var(--ochre)); }
a.key:hover { border-color: var(--k); color: var(--bone); }

/* the Path */
.learning-hero h1 { max-width: 19ch; }
.learning-hero .lede { max-width: 62ch; }
.learning-hero.series-title .subtitle { font-size: clamp(1.15rem, 1.8vw, 1.4rem); max-width: 54ch; margin-bottom: 0; }
.learning-time { font-size: .9rem; color: var(--bone-faint); margin: 20px 0 0; max-width: 78ch; }
.learning-guide { padding-top: 24px; }
.learning-columns { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(32px, 6vw, 80px); }
.learning-columns > div { border-top: 1px solid var(--line); padding-top: 28px; }
.learning-columns h2 { font-size: clamp(1.7rem, 2.7vw, 2.25rem); max-width: 24ch; }
.learning-outcomes { list-style: none; padding: 0; margin: 28px 0 0; }
.learning-outcomes li + li { margin-top: 24px; }
.learning-outcomes h3 { font-family: var(--text); font-size: 1.05rem; font-weight: 600; letter-spacing: 0; margin-bottom: 6px; }
.learning-outcomes p { margin: 0; }
.learning-steps { padding-left: 1.5em; margin: 28px 0 24px; }
.learning-steps li { padding-left: 8px; margin-bottom: 16px; }
.learning-steps li::marker { color: var(--ochre); font-weight: 600; }
.learning-steps strong { color: var(--bone); font-weight: 600; }
.learning-note { font-size: .95rem; }
.learning-crosslink { font-size: .95rem; padding-top: 20px; border-top: 1px solid var(--line); margin-bottom: 0; }
.learning-context { padding-block: 0; }
.series-context { border-block: 1px solid var(--line); }
.series-context summary { padding: 20px 0; cursor: pointer; color: var(--bone); }
.series-context summary::marker { color: var(--ochre); }
.series-context > div { padding: 12px 0 28px; }
@media (max-width: 760px) { .learning-columns { grid-template-columns: 1fr; } }
.weeks { display: grid; gap: 64px; }
.week-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 20px; }
.levels { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 20px; list-style: none; padding: 0; margin: 0; }
.level { position: relative; display: flex; flex-direction: column; height: 100%; gap: 10px; color: var(--bone-dim); text-decoration: none; }
.level img { aspect-ratio: 9 / 16; object-fit: cover; width: 100%; border-radius: 4px; border: 1px solid var(--line); transition: border-color .2s, transform .2s; }
a.level:hover img { border-color: var(--ochre); transform: translateY(-2px); }
.level .lv { font: 600 .76rem/1.4 var(--text); color: var(--ochre); }
.level .hook { font: 500 1rem/1.4 var(--text); color: var(--bone); }
.level .lesson-summary { font: 400 .9rem/1.55 var(--text); color: var(--bone-dim); }
.level.locked img { filter: grayscale(.6) brightness(.55); }
.level .state { margin-top: auto; padding-top: 4px; font: 500 .78rem/1.4 var(--text); color: var(--ochre); }
.level .done { position: absolute; top: 10px; right: 10px; width: 26px; height: 26px; border-radius: 50%; background: var(--malachite); color: var(--night0); display: none; place-items: center; font: 700 .8rem/1 var(--mono); }
.level.is-done .done { display: grid; }

/* day page */
.lesson { display: grid; grid-template-columns: minmax(260px, 400px) minmax(0, 1fr); gap: clamp(28px, 5vw, 64px); align-items: start; }
@media (max-width: 820px) { .lesson { grid-template-columns: 1fr; } }
.frame { position: sticky; top: 104px; border-radius: 6px; overflow: hidden; border: 1px solid var(--line); background: #000; }
@media (max-width: 820px) { .frame { position: static; max-width: 420px; margin-inline: auto; } }
.frame video { width: 100%; aspect-ratio: 9 / 16; background: #000; }
.panel { border: 0; border-top: 1px solid var(--line); border-radius: 0; padding: 28px 0; background: transparent; margin-bottom: 12px; }
.panel h2 { font-size: clamp(1.4rem, 2.4vw, 1.9rem); margin-bottom: 14px; }
.choices { display: flex; gap: 12px; flex-wrap: wrap; margin: 16px 0; }
.choice { font: 600 1.2rem/1 var(--mono); color: var(--bone); background: transparent; border: 1px solid var(--line); border-radius: 4px; padding: 16px 22px; min-width: 92px; min-height: 48px; cursor: pointer; transition: border-color .2s, background .2s; }
.choice:hover { border-color: var(--ochre); }
.choice .letter { display: block; font-size: .66rem; letter-spacing: .2em; color: var(--bone-faint); margin-bottom: 8px; }
.choice[aria-pressed="true"] { border-color: var(--ochre); background: rgba(227,161,59,.08); }
.choice.is-answer { border-color: var(--malachite); background: rgba(69,194,143,.1); }
.reveal[hidden] { display: none; }
.reveal { border-top: 1px dashed var(--line); margin-top: 18px; padding-top: 18px; }
.linkish { display: inline-flex; align-items: center; min-height: 44px; background: none; border: 0; padding: 8px 0; color: var(--bone-dim); font: inherit; text-decoration: underline; text-underline-offset: .2em; cursor: pointer; }
.rule-box { border: 0; border-left: 2px solid var(--rule, var(--indigo)); padding: 8px 0 8px 22px; background: transparent; } /* a Day's rule box takes the Day's own colour (Paul, 10 Nov 2026) */
.rule-box .kicker { color: var(--rule, var(--indigo)); }
.rule-box p { color: var(--bone); font: 500 clamp(1.15rem, 2vw, 1.4rem)/1.4 var(--display); }
.math { font-family: var(--mono); color: var(--bone); background: var(--night0); border: 1px solid var(--line); border-radius: 10px; padding: 2px 8px; white-space: nowrap; }
details { border-top: 1px solid var(--line); padding: 14px 0; }
summary { cursor: pointer; min-height: 44px; padding: 10px 0; font: 500 .95rem/1.5 var(--text); color: var(--bone); }
.transcript { list-style: none; padding: 0; margin: 14px 0 0; display: grid; gap: 10px; }
.transcript .t { font: 500 .78rem/1 var(--mono); color: var(--bone-faint); margin-right: 10px; }
.pager { display: flex; justify-content: space-between; gap: 16px; margin-top: 40px; flex-wrap: wrap; }
.pager a { display: inline-flex; align-items: center; min-height: 44px; font: 500 .94rem/1.5 var(--text); text-decoration: none; }

/* The History of Math */
.series-title h1 { max-width: 16ch; }
.series-title .subtitle { font: 400 clamp(1.25rem, 2.6vw, 2rem)/1.25 var(--display); font-style: italic; color: var(--ochre); margin-top: 14px; max-width: 30ch; }
.deep-time { margin: 34px 0 8px; }
.deep-time svg { width: 100%; height: auto; overflow: visible; }
.deep-time text { font-family: var(--mono); fill: var(--bone-faint); font-size: 11px; letter-spacing: .1em; }
.deep-time .ep { fill: var(--bone-faint); }
.deep-time .ep.lit { fill: var(--ochre); filter: drop-shadow(0 0 6px var(--ochre)); }
.legend { display: flex; flex-wrap: wrap; gap: 14px 28px; list-style: none; padding: 0; margin: 18px 0 0; font-size: .92rem; }
.legend li { display: flex; align-items: center; gap: 12px; }
.legend i { display: inline-block; width: 44px; height: 0; border-top: 2px solid var(--bone); }
.legend .reading i { border-top-style: dashed; border-color: var(--bone-dim); }
.legend .schematic i { border-top-style: dotted; border-color: var(--bone-dim); }
.legend .error i { border-top-style: dashed; border-color: var(--cinnabar); }
.act { margin-top: 56px; }
.act-head { display: flex; gap: 18px; align-items: baseline; flex-wrap: wrap; margin-bottom: 18px; }
.act-head .num { font: 600 .78rem/1 var(--mono); letter-spacing: .2em; color: var(--ochre); }
.episodes { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 48px; }
.episode { display: grid; grid-template-columns: 48px minmax(0, 1fr); gap: 16px; padding: 24px 0; border-top: 1px solid var(--line); text-decoration: none; color: var(--bone-dim); height: 100%; transition: border-color .2s; }
a.episode:hover { border-color: var(--ochre); color: var(--bone-dim); }
.episode .n { font: 500 1.9rem/1 var(--display); color: var(--bone-faint); }
a.episode .n { color: var(--ochre); }
.episode h3 { font-size: 1.26rem; margin-bottom: 8px; }
.episode .episode-copy { display: flex; flex-direction: column; align-items: flex-start; min-width: 0; }
.episode .era { font-size: .86rem; color: var(--bone-faint); margin: 0 0 8px; }
.episodes .episode .era { margin-bottom: 12px; }
.episode .duration { white-space: nowrap; }
.episode .episode-summary { font-size: 1rem; margin: 0 0 12px; }
.episode .truth { font-size: .84rem; color: var(--bone-faint); margin: 0 0 12px; }
.episode .watch { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; margin-top: auto; color: var(--ochre); font: 500 .9rem/1.5 var(--text); }
a.episode:hover .watch { text-decoration: underline; text-underline-offset: .25em; }
.status { display: inline-block; font: 500 .76rem/1.5 var(--text); color: var(--bone-faint); margin-top: 10px; }
.status.pilot { color: var(--ochre); }

/* episode player */
.theatre { display: grid; grid-template-columns: minmax(280px, 440px) minmax(0, 1fr); gap: clamp(28px, 5vw, 64px); align-items: start; }
@media (max-width: 860px) { .theatre { grid-template-columns: minmax(0, 1fr); } }
.stage { position: sticky; top: 104px; }
@media (max-width: 860px) { .stage { position: static; max-width: 440px; margin-inline: auto; width: 100%; } }
.stage canvas { width: 100%; aspect-ratio: 9 / 16; border-radius: 6px; border: 1px solid var(--line); background: #000; }
.controls { display: grid; grid-template-columns: auto 1fr auto; gap: 12px; align-items: center; margin-top: 14px; }
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; font: 600 .88rem/1.3 var(--text); color: var(--night0); background: var(--bone); border: 1px solid transparent; border-radius: 4px; padding: 11px 16px; cursor: pointer; }
.btn.ghost { background: transparent; color: var(--bone); border: 1px solid var(--line); }
.btn:hover { background: var(--ochre); color: var(--night0); }
input[type="range"] { width: 100%; min-height: 44px; margin: 0; accent-color: var(--ochre); }
.time { font: 500 .78rem/1 var(--mono); color: var(--bone-faint); min-width: 92px; text-align: right; }
.chapters { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; }
.chapters button[aria-current="true"] { border-color: var(--ochre); color: var(--ochre); }
/* play all: one player, every episode in order */
.playlist { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.pl-item { width: 100%; display: grid; grid-template-columns: 36px minmax(0, 1fr) auto; gap: 12px; align-items: baseline; text-align: left; min-height: 48px; padding: 16px 12px; border: 0; border-left: 2px solid transparent; border-bottom: 1px solid var(--line); border-radius: 0; background: transparent; color: var(--bone-dim); font: inherit; cursor: pointer; }
.pl-item:hover { border-color: var(--ochre); }
.pl-item[aria-current="true"] { border-color: var(--ochre); background: color-mix(in srgb, var(--ochre) 10%, var(--night2)); }
.pl-item .n { font: 500 1.4rem/1 var(--display); color: var(--ochre); }
.pl-item .t { font: 500 1.02rem/1.35 var(--display); color: var(--bone); }
.pl-item .t .status { margin: 0 0 0 10px; vertical-align: middle; }
.pl-item .d { font: 500 .74rem/1 var(--mono); color: var(--bone-faint); }
.now { margin-top: 14px; color: var(--bone); }
.btn:disabled, .btn:disabled:hover { opacity: .4; cursor: default; background: transparent; color: var(--bone); }
.dialogue { list-style: none; padding: 0; margin: 0; display: grid; gap: 14px; }
.dialogue li { display: grid; grid-template-columns: 84px minmax(0, 1fr); gap: 12px; padding: 10px 12px; border-radius: 12px; transition: background .2s; }
.dialogue li.is-now { background: rgba(242,234,218,.05); }
.dialogue .voice { font: 700 .68rem/1.9 var(--mono); letter-spacing: .18em; }
.dialogue .voice.SHE { color: var(--ochre); }
.dialogue .voice.HE { color: var(--lapis); }
.dialogue .voice.PICTURE { color: var(--bone-faint); }
.dialogue li.picture .line { color: var(--bone-dim); font-style: italic; }
.bridge { font: 500 clamp(1.1rem, 2vw, 1.35rem)/1.45 var(--display); color: var(--bone); margin: 34px 0 0; max-width: 46ch; }
.dialogue .line { font: 400 1.12rem/1.5 var(--display); color: var(--bone); }
.clip-head { font: 600 .74rem/1.4 var(--mono); letter-spacing: .18em; text-transform: uppercase; color: var(--bone-faint); margin: 26px 0 10px; }
.ledger-table { width: 100%; border-collapse: collapse; font: 500 .92rem/1.5 var(--mono); }
.ledger-table td { border-top: 1px solid var(--line); padding: 10px 8px; vertical-align: top; }
.ledger-table td:last-child { color: var(--bone); text-align: right; white-space: nowrap; }
.ledger-table.wrap td:last-child { white-space: normal; min-width: 14ch; }
@media (max-width: 560px) { .ledger-table td:last-child { white-space: normal; } } /* long sums wrap on phones instead of widening the page */
.sources li { margin-bottom: 8px; }

/* six keys */
.key-card { border-top: 2px solid var(--k); padding: 24px 0; background: transparent; }
.key-card h2 { font-size: clamp(1.4rem, 2.4vw, 1.9rem); margin: 6px 0 8px; }
.key-card .q { color: var(--bone-dim); margin-bottom: 16px; }
.key-card .kicker { color: var(--k); }
.pills { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding: 0; margin: 8px 0 0; }
.pills a, .pills span { display: inline-flex; align-items: center; min-height: 44px; font: 500 .85rem/1.4 var(--text); padding: 8px 4px; border-bottom: 1px solid var(--line); text-decoration: none; color: var(--bone-dim); }
.pills a { color: var(--bone); border-color: var(--k); }

.note { border-left: 2px solid var(--ochre); padding: 4px 0 4px 18px; color: var(--bone-dim); }
.note strong { color: var(--bone); }

/* Home: one precise mark on a calm ground. */
.lp-hero { padding: 0; background: var(--night0); border-bottom: 1px solid var(--line); }
.home-hero-grid { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); align-items: center; gap: clamp(24px, 5vw, 80px); min-height: min(680px, calc(100svh - 81px)); padding-block: 56px; }
.home-hero-copy { min-width: 0; }
.lp-hero h1 { font-size: clamp(3.4rem, 6.5vw, 5.9rem); line-height: 1.05; font-weight: 460; letter-spacing: -.045em; margin-bottom: 22px; }
.home-hero-line { color: var(--bone); font: 400 clamp(1.55rem, 2.5vw, 2.15rem)/1.25 var(--display); max-width: 23ch; letter-spacing: -.02em; margin-bottom: 20px; text-wrap: balance; }
.lp-hero .lede { font-size: 1.08rem; max-width: 42ch; margin: 0; }
.home-brand-mark { display: block; width: 100%; max-width: 470px; justify-self: end; }
.home-brand-mark img { display: block; width: 100%; height: auto; }
/* The image remains the fallback until the real 3D mark has rendered. */
.sphere-stage { display: block; position: relative; width: 100%; aspect-ratio: 1; }
.sphere-stage > picture, .sphere-stage > picture img { display: block; width: 100%; height: auto; }
.sphere-stage canvas { position: absolute; inset: 0; display: block; width: 100%; height: 100%; opacity: 0; transition: opacity .25s ease; }
[data-sphere-fallback] { transition: opacity .25s ease; }
[data-sphere-mark][data-ready="true"] [data-sphere-fallback] { opacity: 0; }
[data-sphere-mark][data-ready="true"] canvas { opacity: 1; }
[data-sphere-mark="interactive"] canvas { cursor: grab; touch-action: pan-y; }
[data-sphere-mark="interactive"] canvas:active { cursor: grabbing; }
[data-sphere-mark="interactive"] canvas:focus-visible { outline: 2px solid var(--ochre); outline-offset: 2px; border-radius: 50%; }
[data-sphere-mark="compact"] canvas { pointer-events: none; }
.sphere-controls { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 4px 14px; margin-top: 6px; }
.sphere-controls[hidden] { display: none; }
.sphere-hint { margin: 0; color: var(--bone-faint); font-size: .75rem; }
.sphere-actions { display: inline-flex; gap: 4px; }
.sphere-actions button { border: 0; border-bottom: 1px solid var(--line); border-radius: 0; background: transparent; color: var(--bone-dim); min-height: 44px; padding: 6px 9px; font: 500 .78rem/1.4 var(--text); cursor: pointer; }
.sphere-actions button:hover { color: var(--bone); border-color: var(--ochre); }
.sphere-actions button:focus-visible { outline: 2px solid var(--ochre); outline-offset: 3px; }
@media (prefers-reduced-motion: reduce) { .sphere-stage canvas, [data-sphere-fallback] { transition: none; } }

.home-availability { font-size: .82rem; color: var(--bone-faint); margin: 20px 0 0; }
.cta { display: flex; align-items: center; flex-wrap: wrap; gap: 12px 26px; margin-top: 28px; }
.cta a { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 48px; font: 600 .95rem/1.4 var(--text); text-decoration: none; border-radius: 4px; padding: 13px 19px; transition: color .18s, background .18s, border-color .18s; }
.cta .primary { background: var(--ochre); color: var(--night0); }
.cta .primary:hover { background: var(--bone); color: var(--night0); }
.cta .ghost { border-radius: 0; padding-inline: 0; color: var(--bone); border-bottom: 1px solid var(--line); }
.cta .ghost:hover { border-color: var(--ochre); color: var(--ochre); }
.home-film { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); background: var(--night0); }
.film-preview { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: clamp(28px, 6vw, 80px); align-items: center; }
.film-preview img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 4px; }
.film-preview h2 { margin-bottom: 20px; }
.film-preview a { display: inline-flex; align-items: center; min-height: 44px; }
.film-preview > a { display: block; }
.film-art { position: relative; }
.film-play { position: absolute; bottom: 16px; left: 16px; display: inline-flex; align-items: center; min-height: 44px; padding: 10px 14px; background: var(--night0); border: 1px solid var(--line); border-radius: 3px; color: var(--bone); font: 500 .88rem/1.4 var(--text); }
.film-art:hover .film-play { border-color: var(--ochre); color: var(--ochre); }
.text-link { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; color: var(--ochre); text-decoration: none; border-bottom: 1px solid var(--line); }
.text-link:hover { color: var(--bone); border-color: var(--ochre); }
.keys-intro { margin-top: 28px; padding-top: 24px; border-top: 1px solid var(--line); }
.keys-intro h3 { margin-bottom: 10px; }
.home-principle { padding-bottom: 32px; }
.home-coming { border-top: 1px solid var(--line); }
@media (prefers-reduced-motion: no-preference) {
  .home-hero-copy { animation: arrive .6s ease-out both; }
  .home-brand-mark { animation: arrive .8s .08s ease-out both; }
  .nav-ready.nav-open .nav { animation: arrive .18s ease-out both; }
  @keyframes arrive { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }
}
@media (max-width: 1050px) {
  .home-hero-grid { grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: 24px; padding-block: 44px; }
  .lp-hero h1 { font-size: clamp(3rem, 6.4vw, 4.5rem); }
  .levels { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px 18px; }
}
@media (max-width: 760px) {
  :root { --wrap: calc(100% - 40px); }
  html { scroll-padding-top: 88px; }
  .home-hero-grid { grid-template-columns: 1fr; min-height: 0; gap: 20px; padding-block: 24px 40px; }
  .home-brand-mark { order: -1; justify-self: center; max-width: min(62vw, 250px); }
  .lp-hero h1 { font-size: clamp(2.7rem, 11.5vw, 3.8rem); margin-bottom: 14px; }
  .home-hero-line { font-size: 1.6rem; line-height: 1.3; max-width: 25ch; margin-bottom: 16px; }
  .lp-hero .lede { font-size: 1rem; max-width: 42ch; }
  .lp-hero .kicker { margin-bottom: 12px; }
  .cta { margin-top: 22px; gap: 10px 22px; }
  .home-availability { margin-top: 16px; font-size: .78rem; }
  .film-preview, .episodes { grid-template-columns: 1fr; }
  .film-preview { gap: 28px; }
  .levels { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px 18px; }
}
.idea { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: clamp(28px, 6vw, 80px); align-items: start; }
@media (max-width: 860px) { .idea { grid-template-columns: minmax(0, 1fr); } }
.idea h2 { max-width: 16ch; }
.idea .body p { color: var(--bone-dim); }
.idea .body p:first-child { color: var(--bone); font-size: 1.12rem; }
.strands { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(28px, 4vw, 56px); margin-top: 32px; }
.strand { display: flex; flex-direction: column; gap: 28px; min-width: 0; border-block: 1px solid var(--line); padding-block: 32px; text-decoration: none; color: var(--bone-dim); }
a.strand:hover { color: var(--bone-dim); }
.strand .art { aspect-ratio: 16 / 10; overflow: hidden; border-radius: 4px; background: var(--night0); display: grid; place-items: center; }
.strand .art img { width: 100%; height: 100%; object-fit: contain; object-position: center; transition: transform .35s; }
a.strand:hover .art img { transform: scale(1.025); }
.strand .art svg { width: 64%; height: auto; }
.strand .copy { display: flex; flex: 1; flex-direction: column; align-items: start; gap: 12px; max-width: 46ch; }
.strand .kicker { color: var(--ochre); margin: 0; }
.strand h3 { font-size: clamp(1.65rem, 3.2vw, 2.6rem); }
.strand p { margin: 0; }
.strand .go { display: inline-block; margin-top: auto; padding: 10px 0 4px; font: 500 .98rem/1.5 var(--text); color: var(--ochre); border-bottom: 1px solid var(--line); }
a.strand:hover .go { border-color: var(--ochre); }
.strand .badge { font: 400 .85rem/1.5 var(--text); color: var(--bone-faint); }
.strand .badge.later { color: var(--bone-faint); }
@media (max-width: 760px) { .strands { grid-template-columns: 1fr; gap: 0; } .strand { gap: 24px; padding-block: 28px; } .strand + .strand { border-top: 0; } }
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); gap: 16px; margin-top: 26px; list-style: none; padding: 0; }
.fact { border-top: 1px solid var(--line); padding: 22px 0; }
.fact .stroke { display: block; width: 56px; border-top: 2px solid var(--bone); margin-bottom: 14px; }
.fact.reading .stroke { border-top-style: dashed; border-color: var(--bone-dim); }
.fact.error .stroke { border-top-style: dashed; border-color: var(--cinnabar); }
.fact .label { font: 600 .66rem/1 var(--mono); letter-spacing: .18em; text-transform: uppercase; color: var(--bone-faint); }
.fact .num { display: block; font: 560 clamp(1.6rem, 3vw, 2.2rem)/1.15 var(--display); color: var(--bone); margin: 10px 0 8px; }
.fact p { margin: 0; font-size: .95rem; }
.waitlist { position: relative; max-width: 760px; padding: 0; }
.waitlist h2 { max-width: 18ch; }
.waitlist form { margin-top: 26px; display: grid; gap: 18px; max-width: 640px; }
.waitlist .row { display: flex; gap: 10px; flex-wrap: wrap; }
.waitlist input[type="email"] { flex: 1 1 260px; min-width: 0; min-height: 48px; font: 400 1rem/1.4 var(--text); color: var(--bone); background: var(--night0); border: 1px solid var(--line); border-radius: 4px; padding: 14px 16px; }
.waitlist input[type="email"]:focus { outline: 2px solid var(--ochre); outline-offset: 2px; border-color: transparent; }
.waitlist button[type="submit"] { min-height: 48px; font: 600 .95rem/1.4 var(--text); color: var(--night0); background: var(--ochre); border: 0; border-radius: 4px; padding: 14px 22px; cursor: pointer; }
.waitlist button[type="submit"]:hover { background: var(--bone); }
.waitlist button[disabled] { opacity: .6; cursor: progress; }
.interests { display: flex; flex-wrap: wrap; gap: 8px; border: 0; padding: 0; margin: 0; }
.interests legend { font: 500 .85rem/1.5 var(--text); color: var(--bone-faint); margin-bottom: 10px; padding: 0; }
.interests label { position: relative; cursor: pointer; }
.interests input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.interests span { display: inline-flex; align-items: center; min-height: 44px; font-size: .9rem; color: var(--bone-dim); border: 1px solid var(--line); border-radius: 4px; padding: 10px 14px; transition: border-color .2s, color .2s; }
.interests input:checked + span { border-color: var(--ochre); color: var(--bone); background: rgba(227,161,59,.08); }
.interests input:focus-visible + span { outline: 2px solid var(--ochre); outline-offset: 2px; }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.form-status { min-height: 1.5em; margin: 0; font-size: .98rem; }
.form-status[data-kind="ok"] { color: var(--malachite); }
.form-status[data-kind="error"] { color: var(--cinnabar); }
.fine { font-size: .85rem; color: var(--bone-faint); margin: 0; max-width: 60ch; }

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; animation: none !important; } }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
