/* Ctrl Alt Create Academy
   Format inspired by a cinematic long-scroll dark page (1180px, light
   huge type, hairlines, paired buttons). Visual language is ours:
   #2FB4FF, keycaps, Bit Rex, host avatar, Bangers callouts.
   No remotes, no trackers, no copied third-party assets. */

@font-face {
  font-family: "Inter Tight";
  src: url("../fonts/InterTight%5Bwght%5D.ttf") format("truetype");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Inter";
  src: url("../fonts/InterVariable.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Space Grotesk";
  src: url("../fonts/SpaceGrotesk%5Bwght%5D.woff2") format("woff2");
  font-weight: 300 700;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Bangers";
  src: url("../fonts/Bangers-Regular.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg: #000000;
  --ink: #0a0d12;
  --fg: #e6edf3;
  --fg-strong: #ffffff;
  --muted: rgba(230, 237, 243, 0.62);
  --faint: rgba(230, 237, 243, 0.42);
  --accent: #2fb4ff;
  --accent-soft: rgba(47, 180, 255, 0.14);
  --accent-line: rgba(47, 180, 255, 0.38);
  --good: #3fb950;
  --draft: #f5c542;
  --hair: rgba(230, 237, 243, 0.12);
  --hair-strong: rgba(230, 237, 243, 0.2);
  --max: 1180px;
  --nav-h: 56px;
  --draft-h: 0px;
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
  --radius-btn: 2px;
  --radius-media: 4px;
  --display: "Inter Tight", "Inter", "Helvetica Neue", Arial, sans-serif;
  --body: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "Space Grotesk", "Inter", ui-monospace, monospace;
  --chat-clearance: 168px;
  /* Space reserved for the fixed Support button (updated in JS from its box). */
  --support-clearance: 80px;
}

*,
*::before,
*::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--draft-h) + var(--nav-h) + 16px);
  scroll-padding-bottom: var(--support-clearance);
  background: var(--bg);
  color: var(--fg);
}

body {
  margin: 0;
  font-family: var(--body);
  font-weight: 400;
  font-size: 16px;
  line-height: 1.6;
  background: var(--bg);
  color: var(--fg);
  min-height: 100vh;
  overflow-x: hidden;
}

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

a {
  color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

a:hover { color: #7dceff; }

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

.skip {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--accent);
  color: var(--ink);
  padding: 0.6rem 1rem;
  z-index: 1000;
  font-weight: 600;
}

.skip:focus { left: 1rem; top: calc(var(--draft-h) + 0.6rem); }

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Blueprint guides — behind content, with the watermark */
.guides {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background-image:
    linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 100% 100%;
  background-position: center top;
  background-repeat: no-repeat;
}

.guides::before,
.guides::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  width: 1px;
  background: rgba(255, 255, 255, 0.045);
  left: max(0px, calc(50% - var(--max) / 2));
}

.guides::after {
  left: auto;
  right: max(0px, calc(50% - var(--max) / 2));
}

/* Channel profile pic as a still, permanent watermark.
   Fixed, faint, non-interactive, no animation, behind copy.
   Kept clear of the bottom-right support button. */
.page-watermark {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.page-watermark img {
  position: absolute;
  left: 50%;
  top: 46%;
  transform: translate(-50%, -50%);
  width: min(38vw, 440px);
  height: auto;
  max-height: calc(100vh - var(--chat-clearance) - 48px);
  max-width: calc(100vw - 48px);
  opacity: 0.07;
  object-fit: contain;
}

.wrap {
  width: min(var(--max), calc(100% - 48px));
  margin-inline: auto;
  position: relative;
  z-index: 2;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
}

.draft-banner {
  display: none;
}

.draft-banner strong {
  font-weight: 700;
  letter-spacing: 0.12em;
}

.nav-bar {
  background: transparent;
  border-bottom: 1px solid transparent;
  transition: background 0.35s var(--ease), border-color 0.35s var(--ease);
}

.site-header.is-scrolled .nav-bar {
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(16px) saturate(1.1);
  -webkit-backdrop-filter: blur(16px) saturate(1.1);
  border-bottom-color: var(--hair);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: var(--nav-h);
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  color: inherit;
  text-decoration: none;
  min-width: 0;
}

.brand:hover { color: inherit; }

.brand img {
  height: 32px;
  width: auto;
}

.brand-word {
  font-family: var(--mono);
  font-weight: 500;
  font-size: 0.92rem;
  letter-spacing: 0.06em;
  color: var(--fg-strong);
  border-left: 1px solid var(--hair-strong);
  padding-left: 0.75rem;
  line-height: 1.1;
}

.brand-word span {
  display: block;
  font-size: 0.62rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--faint);
  margin-top: 0.14rem;
}

.nav-toggle {
  display: none;
  background: transparent;
  border: 1px solid var(--hair-strong);
  color: var(--fg);
  width: 40px;
  height: 40px;
  border-radius: var(--radius-btn);
  cursor: pointer;
  padding: 0;
}

.nav-toggle span,
.nav-toggle span::before,
.nav-toggle span::after {
  display: block;
  width: 16px;
  height: 1.5px;
  background: var(--fg-strong);
  margin: 0 auto;
  position: relative;
}

.nav-toggle span::before,
.nav-toggle span::after {
  content: "";
  position: absolute;
  left: 0;
}

.nav-toggle span::before { top: -5px; }
.nav-toggle span::after { top: 5px; }

.nav-links {
  display: flex;
  align-items: center;
  gap: 0.15rem 1.25rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-links a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.84rem;
  font-weight: 500;
  letter-spacing: 0.02em;
}

.nav-links a:hover { color: var(--fg-strong); }

.nav-links .nav-cta {
  color: var(--fg-strong);
  background: rgba(230, 237, 243, 0.14);
  padding: 0.5rem 0.85rem;
  border-radius: var(--radius-btn);
  font-weight: 500;
  font-size: 0.82rem;
}

.nav-links .nav-cta:hover {
  color: var(--fg-strong);
  background: rgba(230, 237, 243, 0.22);
}

/* Hero */
.hero {
  position: relative;
  z-index: 2;
  padding: 72px 0 0;
  min-height: min(52rem, calc(100svh - var(--nav-h) - var(--draft-h)));
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 48px;
  align-items: center;
  flex: 1;
}

.eyebrow {
  font-family: var(--body);
  font-weight: 500;
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 18px;
}

h1, h2, h3, h4 {
  font-family: var(--display);
  font-weight: 300;
  letter-spacing: -0.035em;
  line-height: 1.05;
  margin: 0;
  color: var(--fg-strong);
}

h1 {
  font-size: clamp(48px, 6.2vw, 70px);
  line-height: 1.02;
  letter-spacing: -0.035em;
  max-width: 11ch;
}

h1 .h-rest,
.split-rest {
  display: block;
  color: var(--muted);
}

h2 {
  font-size: clamp(36px, 4.6vw, 55px);
  line-height: 1.03;
  letter-spacing: -0.032em;
  margin-bottom: 18px;
}

h3 {
  font-size: clamp(22px, 2.2vw, 28px);
  letter-spacing: -0.027em;
  line-height: 1.2;
}

.lede {
  margin: 24px 0 0;
  font-family: var(--display);
  font-weight: 300;
  font-size: clamp(18px, 1.8vw, 25px);
  line-height: 1.24;
  letter-spacing: -0.02em;
  color: var(--muted);
  max-width: 36rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 36px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  border-radius: var(--radius-btn);
  padding: 11px 16px;
  font-family: var(--body);
  font-weight: 500;
  font-size: 14.4px;
  line-height: 1.03;
  letter-spacing: 0.01em;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background 0.25s var(--ease), color 0.25s var(--ease), border-color 0.25s var(--ease);
}

.btn .chev {
  display: inline-block;
  transition: transform 0.25s var(--ease);
  font-weight: 400;
}

.btn:hover .chev { transform: translateX(2px); }

.btn-primary {
  background: #ededee;
  color: var(--ink);
  border-color: #ededee;
}

.btn-primary:hover {
  background: #ffffff;
  color: var(--ink);
  border-color: #ffffff;
}

.btn-glass {
  background: rgba(237, 237, 238, 0.14);
  color: var(--fg-strong);
  border-color: transparent;
}

.btn-glass:hover {
  background: rgba(237, 237, 238, 0.22);
  color: var(--fg-strong);
}

.btn-sm { padding: 8px 14px; font-size: 13px; }

.hero-art {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 20px;
  /* Even side inset so orbit chips stay inside the column without a larger right margin. */
  padding-inline: 16px;
  min-width: 0;
}

.hero-orb {
  position: relative;
  display: grid;
  place-items: center;
  width: 100%;
  max-width: min(460px, 100%);
  aspect-ratio: 1;
  margin-inline: auto;
  min-width: 0;
  overflow: visible;
}

.hero-art .orb {
  position: relative;
  z-index: 1;
  pointer-events: none;
  /* Keep the glass smaller than the ring so chips sit clearly outside it. */
  width: min(62%, 300px);
  border-radius: 50%;
  mask-image: radial-gradient(circle at 50% 50%, #000 62%, transparent 78%);
  -webkit-mask-image: radial-gradient(circle at 50% 50%, #000 62%, transparent 78%);
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem 1.5rem;
  margin-top: 72px;
  padding: 36px 0 0;
  border-top: 1px solid var(--hair);
  color: var(--muted);
  font-size: 0.88rem;
}

.hero-meta span {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
}

.hero-meta span::before {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 6px rgba(47, 180, 255, 0.45);
}

/* Sections */
section.block {
  position: relative;
  z-index: 2;
  padding: 126px 0;
}

.section-head {
  max-width: 40rem;
  margin-bottom: 48px;
}

.section-head p {
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.6;
}

.kicker {
  font-family: "Bangers", "Inter", sans-serif;
  font-size: 1.35rem;
  letter-spacing: 0.04em;
  color: var(--accent);
  transform: rotate(-2.5deg);
  transform-origin: left center;
  display: inline-block;
  margin-bottom: 0.7rem;
}

.hash,
.step code {
  font-family: var(--mono);
  font-size: 0.86em;
  color: var(--accent);
  background: var(--accent-soft);
  padding: 0.08em 0.35em;
  border-radius: var(--radius-btn);
}

/* How it works — avatar presents the steps, Rex is not in this section */
.how-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 48px 64px;
  align-items: start;
}

.steps {
  display: grid;
  gap: 0;
  counter-reset: step;
  border-top: 1px solid var(--hair);
}

.step {
  display: grid;
  grid-template-columns: 4.5rem 1fr;
  gap: 18px;
  padding: 24px 0;
  border-bottom: 1px solid var(--hair);
  background: transparent;
}

.step::before {
  counter-increment: step;
  content: counter(step, decimal-leading-zero);
  font-family: var(--display);
  font-weight: 300;
  font-size: 36px;
  letter-spacing: -0.04em;
  line-height: 1;
  color: var(--accent);
  padding-top: 0.15rem;
}

.step h3 { margin-bottom: 0.4rem; font-size: 22px; }

.step p {
  margin: 0;
  color: var(--muted);
  font-size: 16px;
}

.note {
  margin-top: 36px;
  padding: 0 0 0 18px;
  border-left: 1px solid var(--accent);
  background: transparent;
  color: var(--fg);
  font-size: 0.95rem;
}

.note p { margin: 0; color: var(--fg); }
.note p + p { margin-top: 0.7rem; }

.fine {
  font-size: 0.88rem;
  color: var(--muted);
}

.explainer {
  position: sticky;
  top: calc(var(--draft-h) + var(--nav-h) + 24px);
  align-self: start;
}

.explainer figure { margin: 0; }

.explainer img {
  width: 100%;
  max-width: 420px;
  margin-inline: auto;
  mask-image: linear-gradient(to bottom, #000 72%, transparent 100%);
  -webkit-mask-image: linear-gradient(to bottom, #000 72%, transparent 100%);
}

.explainer figcaption {
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--faint);
  margin-top: 0.6rem;
  text-align: center;
}

/* Assignments — hairline rows, keycap tags */
.assignment-list {
  display: grid;
  gap: 0;
  border-top: 1px solid var(--hair);
}

.assignment {
  display: grid;
  grid-template-columns: 6.25rem 1fr;
  gap: 24px;
  padding: 28px 0;
  border-bottom: 1px solid var(--hair);
  background: transparent;
  align-items: start;
}

.assignment.live { color: var(--fg); }
.assignment.locked { color: var(--muted); }
.assignment.locked .as-body h3 { color: var(--muted); }
.assignment.live .as-body h3 { color: var(--fg-strong); }

.as-tag {
  font-family: var(--mono);
  font-weight: 500;
  font-size: 1.05rem;
  letter-spacing: 0.06em;
  color: var(--fg-strong);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 4.4rem;
  height: 2.6rem;
  padding: 0 0.55rem;
  border: 1.5px solid var(--hair-strong);
  border-radius: 6px;
  background: #12151a;
  box-shadow: 0 2px 0 rgba(255, 255, 255, 0.08), inset 0 -2px 0 rgba(0, 0, 0, 0.45);
}

.assignment.live .as-tag {
  border-color: var(--accent);
  color: var(--ink);
  background: var(--accent);
  box-shadow: 0 2px 0 rgba(47, 180, 255, 0.35), inset 0 -2px 0 rgba(0, 0, 0, 0.18);
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  border-radius: var(--radius-btn);
  padding: 0.12rem 0.45rem;
  font-family: var(--mono);
  font-size: 0.66rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 600;
}

.pill-live {
  background: var(--good);
  color: #041208;
}

.pill-soon {
  background: transparent;
  color: var(--faint);
  border: 1px solid var(--hair);
}

.as-body h3 { margin-bottom: 0.2rem; font-size: 24px; }

.as-meta {
  color: var(--muted);
  font-size: 0.88rem;
  margin: 0 0 0.7rem;
}

.as-meta .pill { margin-right: 0.45rem; vertical-align: 0.1em; }

.as-body p { margin: 0.35rem 0; }

.as-body dt {
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--faint);
  font-family: var(--mono);
  margin-top: 0.7rem;
  font-weight: 500;
}

.as-body dd { margin: 0.15rem 0 0; color: var(--fg); }

.assignment.locked .as-body dd { color: var(--muted); }

.as-actions { margin-top: 1rem; display: flex; flex-wrap: wrap; gap: 0.5rem; }

/* Levels — typographic scale rows */
.levels {
  display: grid;
  gap: 0;
  border-top: 1px solid var(--hair);
}

.level {
  display: grid;
  grid-template-columns: 10rem 14rem 1fr;
  gap: 18px 28px;
  padding: 36px 0;
  border-bottom: 1px solid var(--hair);
  align-items: start;
}

.level-idx {
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  padding-top: 0.55rem;
}

.level h3 {
  font-size: clamp(32px, 3.4vw, 45px);
  letter-spacing: -0.027em;
  line-height: 1.1;
}

.level p { margin: 0; color: var(--muted); font-size: 0.95rem; }

.level .gets {
  margin-top: 0.7rem;
  padding-top: 0;
  border-top: 0;
  color: var(--fg);
  font-size: 0.95rem;
}

/* Certificate */
.certificate-frame {
  display: grid;
  justify-items: center;
}

.certificate {
  width: min(100%, 820px);
  background: var(--ink);
  border: 1px solid var(--accent-line);
  border-radius: var(--radius-media);
  padding: 48px 40px 32px;
  text-align: center;
  position: relative;
}

.certificate .cert-logo {
  height: 40px;
  width: auto;
  margin: 0 auto 1.25rem;
}

.certificate .cert-kicker {
  font-family: var(--mono);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  font-size: 0.72rem;
  color: var(--accent);
  margin: 0 0 0.7rem;
}

.certificate h3 {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  margin-bottom: 1.25rem;
}

.cert-name {
  font-family: var(--display);
  font-weight: 300;
  font-size: clamp(1.8rem, 3.5vw, 2.6rem);
  letter-spacing: -0.03em;
  color: #fff;
  border-bottom: 1px solid var(--hair-strong);
  display: inline-block;
  padding: 0 1rem 0.25rem;
  margin: 0.25rem 0 1rem;
}

.cert-body {
  max-width: 38rem;
  margin: 0 auto;
  color: var(--fg);
  font-size: 1rem;
}

.disclaimer {
  margin-top: 1.6rem;
  padding-top: 1.1rem;
  border-top: 1px solid var(--hair);
  font-size: 0.78rem;
  line-height: 1.55;
  color: var(--muted);
  text-align: left;
  max-width: 40rem;
  margin-left: auto;
  margin-right: auto;
}

.disclaimer strong { color: var(--fg); font-weight: 600; }

.cert-preview-tag {
  position: absolute;
  top: 1rem;
  right: 1rem;
  font-family: var(--mono);
  font-size: 0.65rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--draft);
  border: 1px dashed rgba(245, 197, 66, 0.5);
  padding: 0.2rem 0.45rem;
  border-radius: var(--radius-btn);
}

/* Tracks — open tiles */
.tracks {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  border-top: 1px solid var(--hair);
}

.track {
  border: 0;
  border-bottom: 1px solid var(--hair);
  border-right: 1px solid var(--hair);
  border-radius: 0;
  padding: 28px 24px 32px;
  background: transparent;
  min-height: 100%;
}

.track:nth-child(3n) { border-right: 0; }

.track.now {
  background: linear-gradient(180deg, var(--accent-soft), transparent 70%);
}

.track-top {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 0.5rem;
  margin-bottom: 0.55rem;
}

.track-num {
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--faint);
}

.track h3 { font-size: 1.2rem; letter-spacing: -0.02em; }

.track p { margin: 0.4rem 0 0; color: var(--muted); font-size: 0.92rem; }

.track .advice {
  margin-top: 0.55rem;
  font-size: 0.8rem;
  color: #c9b27a;
}

/* Books */
.book-feature {
  display: grid;
  grid-template-columns: 1fr;
  gap: 36px;
  align-items: start;
  background: transparent;
  border-top: 1px solid var(--hair);
  border-bottom: 1px solid var(--hair);
  border-radius: 0;
  padding: 48px 0;
  overflow: visible;
}

.book-cover {
  aspect-ratio: 3 / 4;
  max-width: 260px;
  margin-left: auto;
  background:
    radial-gradient(circle at 50% 30%, rgba(47, 180, 255, 0.28), transparent 55%),
    var(--ink);
  border: 1px solid var(--accent-line);
  border-radius: var(--radius-media);
  padding: 1.5rem 1.2rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
}

.book-cover .cover-series {
  font-family: var(--mono);
  font-size: 0.62rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
}

.book-cover .cover-title {
  font-family: var(--display);
  font-weight: 300;
  font-size: 1.65rem;
  letter-spacing: -0.03em;
  line-height: 1.1;
}

.book-cover .cover-author {
  font-size: 0.85rem;
  color: var(--muted);
}

.book-cover img {
  width: 72px;
  position: absolute;
  right: 0.7rem;
  bottom: 3.2rem;
  opacity: 0.95;
}

.book-feature > div:first-child { max-width: 720px; }

.coming {
  display: inline-block;
  margin-top: 1rem;
  font-family: var(--mono);
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--draft);
}

/* FAQ */
.faq {
  display: grid;
  gap: 0;
  border-top: 1px solid var(--hair);
}

.faq details {
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--hair);
  border-radius: 0;
  padding: 0;
}

.faq summary {
  cursor: pointer;
  list-style: none;
  padding: 22px 0;
  font-weight: 500;
  font-size: 1.05rem;
  color: var(--fg-strong);
}

.faq summary::-webkit-details-marker { display: none; }

.faq summary::after {
  content: "+";
  float: right;
  color: var(--accent);
  font-weight: 300;
  font-size: 1.4rem;
  line-height: 1;
}

.faq details[open] summary::after { content: "–"; }

.faq .faq-body {
  padding: 0 0 22px;
  color: var(--muted);
}

.faq .faq-body p { margin: 0 0 0.7rem; }
.faq .faq-body p:last-child { margin-bottom: 0; }

/* Footer */
.site-footer {
  border-top: 1px solid var(--hair);
  padding: 72px 0 calc(48px + var(--support-clearance));
  position: relative;
  z-index: 2;
  background: transparent;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr;
  gap: 36px;
}

.footer-brand img { height: 36px; width: auto; margin-bottom: 0.8rem; }

.site-footer h2 {
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 500;
  color: var(--faint);
  margin-bottom: 0.7rem;
}

.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin: 0.3rem 0; }
.site-footer a { color: var(--fg); text-decoration: none; }
.site-footer a:hover { color: var(--accent); }

.footer-note {
  margin-top: 48px;
  padding-top: 24px;
  border-top: 1px solid var(--hair);
  color: var(--muted);
  font-size: 0.82rem;
}

/* Support chat — draft, on-page only */
.support {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 80;
  width: auto;
  font-family: var(--body);
}

.support-launch {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  background: #ededee;
  color: var(--ink);
  border: 1px solid #ededee;
  border-radius: var(--radius-btn);
  padding: 11px 16px;
  font: 500 14.4px/1.03 var(--body);
  letter-spacing: 0.01em;
  cursor: pointer;
}

.support-launch:hover { background: #fff; }

.support:has(#support-panel:not([hidden])) .support-launch {
  visibility: hidden;
  pointer-events: none;
}

.support-launch-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 6px rgba(47, 180, 255, 0.55);
}

.support-panel {
  /* Keep the chat on a dark palette even on ivory subpages. */
  --fg: #e6edf3;
  --fg-strong: #ffffff;
  --muted: rgba(230, 237, 243, 0.72);
  --faint: rgba(230, 237, 243, 0.5);
  --ink: #0a0d12;
  --hair: rgba(230, 237, 243, 0.12);
  --hair-strong: rgba(230, 237, 243, 0.2);
  --accent: #2fb4ff;
  --accent-soft: rgba(47, 180, 255, 0.16);
  --accent-line: rgba(47, 180, 255, 0.38);
  color: var(--fg);
  position: absolute;
  right: 0;
  bottom: calc(100% + 10px);
  width: min(380px, calc(100vw - 32px));
  height: min(560px, calc(100svh - var(--draft-h) - var(--nav-h) - 96px));
  background: #07090c;
  border: 1px solid var(--hair-strong);
  border-radius: var(--radius-media);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.support-panel[hidden] { display: none !important; }

.support-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 14px 14px 12px;
  border-bottom: 1px solid var(--hair);
}

.support-kicker {
  margin: 0 0 0.2rem;
  font-family: var(--mono);
  font-size: 0.62rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--draft);
}

.support-head h2 {
  font-size: 1.15rem;
  margin: 0;
  letter-spacing: -0.03em;
}

.support-close {
  background: transparent;
  border: 1px solid var(--hair);
  color: var(--fg);
  width: 32px;
  height: 32px;
  border-radius: var(--radius-btn);
  cursor: pointer;
  font-size: 1.1rem;
  line-height: 1;
}

.support-log {
  flex: 1;
  overflow: auto;
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 160px;
}

.support-msg {
  max-width: 92%;
  padding: 10px 12px;
  border-radius: var(--radius-media);
  font-size: 0.9rem;
  line-height: 1.45;
}

.support-msg p { margin: 0 0 0.45rem; }
.support-msg p:last-child { margin-bottom: 0; }

.support-msg.bot {
  align-self: flex-start;
  background: rgba(237, 237, 238, 0.08);
  color: var(--fg);
}

.support-msg.user {
  align-self: flex-end;
  background: var(--accent-soft);
  color: var(--fg-strong);
}

.support-qs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}

.support-qs button {
  background: transparent;
  color: var(--fg);
  border: 1px solid var(--hair-strong);
  border-radius: var(--radius-btn);
  padding: 6px 8px;
  font-size: 0.75rem;
  cursor: pointer;
  text-align: left;
}

.support-qs button:hover {
  border-color: var(--accent-line);
  color: var(--accent);
}

.support-ask,
.support-form {
  display: flex;
  gap: 6px;
  padding: 10px 12px 12px;
  border-top: 1px solid var(--hair);
}

.support-ask input,
.support-form input,
.support-form textarea {
  flex: 1;
  background: #000;
  color: var(--fg);
  border: 1px solid var(--hair-strong);
  border-radius: var(--radius-btn);
  padding: 10px 10px;
  font: 400 0.9rem/1.4 var(--body);
  width: 100%;
}

.support-ask[hidden],
.support-form[hidden] { display: none !important; }

.support-form {
  flex-direction: column;
  gap: 8px;
}

.support-form label {
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  color: var(--muted);
}

.support-consent {
  display: flex;
  align-items: flex-start;
  gap: 0.45rem;
  font-size: 0.8rem;
  color: var(--muted);
  line-height: 1.4;
}

.support-consent input { margin-top: 0.2rem; flex: none; }

.support-form .form-actions {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.support-note {
  margin: 0;
  font-size: 0.75rem;
  color: var(--faint);
  padding: 0 12px 10px;
}

/* Reveal */
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}

.reveal.is-in,
.no-js .reveal {
  opacity: 1;
  transform: none;
}

.nowrap { white-space: nowrap; }

/* Responsive */
@media (max-width: 960px) {
  .hero-grid,
  .how-grid,
  .book-feature,
  .footer-grid { grid-template-columns: 1fr; }
  .level { grid-template-columns: 8rem 1fr; }
  .level-idx { grid-column: 1; }
  .level h3 { grid-column: 2; }
  .level > div:last-child { grid-column: 1 / -1; }
  .tracks { grid-template-columns: 1fr 1fr; }
  .track:nth-child(3n) { border-right: 1px solid var(--hair); }
  .track:nth-child(2n) { border-right: 0; }
  .book-cover { margin: 1rem auto 0; }
  h1 { max-width: none; }
  .explainer { position: relative; top: 0; max-width: 280px; }
  .how-grid { display: flex; flex-direction: column; }
  .how-copy { order: 2; }
  .explainer { order: 1; margin: 0 auto 8px; }
  .page-watermark img { width: min(52vw, 300px); opacity: 0.065; top: 44%; left: 50%; }
}

@media (max-width: 760px) {
  .nav-toggle { display: inline-flex; align-items: center; justify-content: center; }

  .nav-links {
    display: none;
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    flex-direction: column;
    align-items: stretch;
    background: rgba(0, 0, 0, 0.96);
    border-bottom: 1px solid var(--hair);
    padding: 0.6rem 1.25rem 1rem;
    gap: 0.2rem;
  }

  .nav.is-open .nav-links { display: flex; }

  .nav-links a { padding: 0.65rem 0; }
  .nav-links .nav-cta { width: fit-content; margin-top: 0.3rem; }

  .assignment { grid-template-columns: 1fr; gap: 0.7rem; }
  .hero { padding-top: 48px; min-height: 0; }
  .hero-grid { gap: 32px; }
  .hero-meta { margin-top: 48px; padding-top: 24px; }
  section.block { padding: 72px 0; }
  .wrap { width: min(var(--max), calc(100% - 32px)); }
  .certificate { padding: 32px 18px 22px; }
  .brand-word { display: none; }
  .support { right: 12px; bottom: 12px; }
  .support-panel {
    position: fixed;
    right: 12px;
    bottom: 64px;
    width: calc(100vw - 24px);
    height: min(70svh, 560px);
  }
  .page-watermark img {
    width: min(64vw, 260px);
    opacity: 0.06;
    top: 42%;
    left: 50%;
  }
}

@media (max-width: 560px) {
  .tracks,
  .footer-grid { grid-template-columns: 1fr; }
  .track { border-right: 0 !important; }
  .level { grid-template-columns: 1fr; gap: 8px; }
  .level-idx, .level h3, .level > div:last-child { grid-column: 1; }
  .hero-actions { gap: 8px; }
  .btn { min-height: 44px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .btn:hover .chev { transform: none; }
  .site-header .nav-bar { transition: none; }
}

html.review .reveal,
html.review .reveal.is-in {
  opacity: 1;
  transform: none;
  transition: none;
}


/* —— Socials (YouTube, TikTok, Instagram, X) —— */
.footer-socials {
  list-style: none;
  margin: 0;
  padding: 0;
}

.section-head .footer-socials {
  margin-top: 1.15rem;
}

.section-head .footer-socials li {
  margin: 0.35rem 0;
}

.socials {
  list-style: none;
  margin: 28px 0 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
}

.socials a {
  color: var(--fg-strong);
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  display: inline-flex;
  align-items: baseline;
  gap: 0.4rem;
  border-bottom: 1px solid var(--hair-strong);
  padding-bottom: 2px;
}

.socials a:hover { color: var(--accent); border-bottom-color: var(--accent); }

@media (max-width: 1240px) and (min-width: 961px) {
  .socials-hero { gap: 10px 14px; }
  .socials-hero a { font-size: 0.86rem; }
}

.socials .handle,
.footer-socials .handle,
.link-tile .handle {
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  color: var(--muted);
  font-weight: 400;
}

.nav-socials {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding-left: 0.85rem;
  border-left: 1px solid var(--hair);
}

.nav-socials a {
  color: var(--muted);
  font-size: 0.78rem;
  letter-spacing: 0.04em;
}

.footer-socials a {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.55rem;
  align-items: baseline;
}

/* —— Hero orbit: chips and open-source tools —— */
.orbit-stage {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

.orbit-stage .circuit {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
}

.orbit-ring {
  position: absolute;
  left: 50%;
  top: 50%;
  width: var(--orbit-r, 240px);
  height: var(--orbit-r, 240px);
  margin: calc(var(--orbit-r, 240px) / -2) 0 0 calc(var(--orbit-r, 240px) / -2);
}

.ring-a { display: none; }
/* Cap the ring so radius + chip size stays inside the orb stage, even at max --spread. */
.ring-b {
  --orbit-r: min(calc(64% * var(--spread, 1)), calc(100% - 9.5rem));
  --n: 8;
  --spin: 72s;
}

.ring-c {
  --orbit-r: min(calc(96% * var(--spread, 1)), calc(100% - 2.75rem));
  --n: 10;
  --spin: 110s;
  pointer-events: none;
  z-index: 3;
}

.ring-c .slot {
  --a: calc(var(--i) * 360deg / var(--n) + 18deg);
  animation-direction: reverse;
}

.slot {
  position: absolute;
  inset: 0;
  --a: calc(var(--i) * 360deg / var(--n));
  transform: rotate(var(--a));
  animation: orbit-spin var(--spin) linear infinite;
}

.slot .chip {
  position: absolute;
  left: 50%;
  top: 0;
  transform: translate(-50%, -50%) rotate(calc(-1 * var(--a)));
  animation: orbit-counter var(--spin) linear infinite;
  font-family: var(--mono);
  font-size: 0.55rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--fg);
  background: #07090c;
  border: 1px solid rgba(47, 180, 255, 0.4);
  border-radius: 2px;
  /* Slightly generous padding; an extra invisible ::after target sits around it. */
  padding: 6px 10px 6px 16px;
  white-space: nowrap;
  box-shadow: inset 0 0 0 1px rgba(47, 180, 255, 0.08);
  text-decoration: none;
  cursor: pointer;
  pointer-events: auto;
  z-index: 2;
}

.slot a.chip:hover,
.slot a.chip:focus-visible {
  color: var(--fg-strong);
  border-color: rgba(47, 180, 255, 0.95);
  box-shadow:
    inset 0 0 0 1px rgba(47, 180, 255, 0.28),
    0 0 10px rgba(47, 180, 255, 0.55),
    0 0 22px rgba(47, 180, 255, 0.32);
}

.slot a.chip:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}

.slot .chip::before {
  content: "";
  position: absolute;
  left: 5px;
  top: 5px;
  bottom: 5px;
  width: 4px;
  background:
    repeating-linear-gradient(
      to bottom,
      rgba(47, 180, 255, 0.7) 0 1px,
      transparent 1px 3px
    );
  pointer-events: none;
}

/* Invisible larger hit area so catching a moving chip stays doable. */
.slot .chip::after {
  content: "";
  position: absolute;
  inset: -12px -14px;
  border-radius: 4px;
}

.chip-caught {
  position: absolute;
  left: 50%;
  bottom: calc(100% + 4px);
  transform: translateX(-50%);
  font-family: var(--mono);
  font-size: 0.58rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #d8f3ff;
  text-shadow: 0 0 8px rgba(47, 180, 255, 0.85);
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  z-index: 3;
}

.slot a.chip.is-caught {
  border-color: rgba(180, 230, 255, 1);
  box-shadow:
    inset 0 0 0 1px rgba(47, 180, 255, 0.4),
    0 0 14px rgba(47, 180, 255, 0.85),
    0 0 28px rgba(47, 180, 255, 0.45);
}

.slot a.chip.is-caught .chip-caught {
  animation: chip-caught-pop 0.42s ease-out;
}

@keyframes chip-caught-pop {
  0% { opacity: 0; transform: translateX(-50%) translateY(4px) scale(0.72); }
  35% { opacity: 1; transform: translateX(-50%) translateY(-2px) scale(1.06); }
  100% { opacity: 0; transform: translateX(-50%) translateY(-10px) scale(1); }
}

@keyframes orbit-spin {
  from { transform: rotate(var(--a)); }
  to { transform: rotate(calc(var(--a) + 360deg)); }
}

@keyframes orbit-counter {
  from { transform: translate(-50%, -50%) rotate(calc(-1 * var(--a))); }
  to { transform: translate(-50%, -50%) rotate(calc(-1 * var(--a) - 360deg)); }
}

/* —— Opposition / rogues —— */
.rogues {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 0;
  border-top: 1px solid var(--hair);
}

.rogue {
  padding: 28px 22px 32px;
  border-bottom: 1px solid var(--hair);
  border-right: 1px solid var(--hair);
  background: transparent;
}

.rogue-cartel,
.rogue-mob,
.rogue-pirates,
.rogue-trolls { grid-column: span 6; }

.rogue-sharks,
.rogue-monthly,
.rogue-cloud { grid-column: span 4; }

.rogue-mob,
.rogue-sharks,
.rogue-cloud,
.rogue-trolls { border-right: 0; }

.rogue-rank {
  margin: 0 0 0.55rem;
  font-family: var(--mono);
  font-size: 0.66rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--faint);
}

.rogue h3 {
  font-family: var(--mono);
  font-size: 1.15rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  line-height: 1.2;
  margin-bottom: 0.55rem;
}

.rogue p { margin: 0; color: var(--muted); font-size: 0.92rem; }

.rogue-cartel { box-shadow: inset 3px 0 0 #4A1020; }
.rogue-cartel h3 { color: #d7b45a; }
.rogue-mob { box-shadow: inset 3px 0 0 #4B2E5C; }
.rogue-mob h3 { color: #c4b0d4; }
.rogue-sharks { box-shadow: inset 3px 0 0 #3A4A5C; }
.rogue-sharks h3 { color: #b7c4d4; }
.rogue-monthly { box-shadow: inset 3px 0 0 #3D2F4F; }
.rogue-monthly h3 { color: #c5b3d8; }
.rogue-cloud { box-shadow: inset 3px 0 0 #1F4A4A; }
.rogue-cloud h3 { color: #9ec9c6; }
.rogue-pirates { box-shadow: inset 3px 0 0 #7A2E2E; }
.rogue-pirates h3 { color: #e0a3a3; }
.rogue-trolls { box-shadow: inset 3px 0 0 #2F3B2A; }
.rogue-trolls h3 { color: #b5c7a8; }

/* Never use hero cyan on villain names */

/* —— Links hub —— */
.link-hub {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  border-top: 1px solid var(--hair);
  border-bottom: 1px solid var(--hair);
}

.link-tile {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  padding: 32px 24px 36px;
  text-decoration: none;
  color: var(--fg);
  border-right: 1px solid var(--hair);
  min-height: 180px;
}

.link-tile:last-child { border-right: 0; }

.link-tile:hover {
  background: var(--accent-soft);
  color: var(--fg-strong);
}

.link-kicker {
  font-family: var(--mono);
  font-size: 0.66rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
}

.link-tile strong {
  font-family: var(--display);
  font-weight: 300;
  font-size: clamp(28px, 3vw, 40px);
  letter-spacing: -0.03em;
  color: var(--fg-strong);
}

.link-go {
  margin-top: auto;
  padding-top: 1rem;
  color: var(--muted);
  font-size: 0.88rem;
}

.link-tile:hover .link-go { color: var(--accent); }
.link-tile:hover .chev { transform: translateX(2px); }
.link-tile .chev { display: inline-block; transition: transform 0.25s var(--ease); }

.page-index {
  list-style: none;
  margin: 36px 0 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px 0;
  border-top: 1px solid var(--hair);
}

.page-index li {
  margin: 0;
}

.page-index a {
  display: inline-block;
  padding: 10px 18px 10px 0;
  margin-right: 18px;
  color: var(--fg);
  text-decoration: none;
  border-bottom: 1px solid var(--hair);
  font-size: 0.95rem;
}

.page-index a:hover { color: var(--accent); border-bottom-color: var(--accent); }

@media (max-width: 960px) {
  .rogues { grid-template-columns: 1fr 1fr; }
  .rogue,
  .rogue-cartel,
  .rogue-mob,
  .rogue-sharks,
  .rogue-monthly,
  .rogue-cloud,
  .rogue-pirates,
  .rogue-trolls { grid-column: span 1; }
  .rogue { border-right: 1px solid var(--hair); }
  .rogue-mob,
  .rogue-monthly,
  .rogue-pirates,
  .rogue-trolls { border-right: 0; }
  .link-hub { grid-template-columns: 1fr; }
  .link-tile { border-right: 0; border-bottom: 1px solid var(--hair); min-height: 0; }
  .hero-orb { max-width: min(440px, 84%); }
  .socials-hero .handle { display: none; }
}

@media (max-width: 1100px) and (min-width: 761px) {
  .nav-socials {
    gap: 0.5rem;
    padding-left: 0.6rem;
  }
  .nav-socials a { font-size: 0.74rem; letter-spacing: 0.03em; }
  .nav-links { gap: 0.15rem 0.9rem; }
}

@media (max-width: 760px) {
  .nav-socials {
    border-left: 0;
    padding-left: 0;
    flex-wrap: wrap;
    padding-top: 0.4rem;
  }
  .hero-art { min-height: 0; }
  .hero-orb { max-width: min(420px, 86%); }
}

@media (max-width: 560px) {
  .rogues { grid-template-columns: 1fr; }
  .rogue,
  .rogue-mob,
  .rogue-monthly,
  .rogue-pirates,
  .rogue-trolls { border-right: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .slot,
  .slot .chip,
  .slot .social-orb { animation: none; }
  .link-tile .chev { transition: none; }
  .slot a.chip.is-caught .chip-caught {
    animation: none;
    opacity: 1;
    transform: translateX(-50%) translateY(-4px);
  }
}

html.review .slot,
html.review .slot .chip,
html.review .slot .social-orb { animation: none; }


/* —— Scroll-driven graphics, visitor journey, books turntable (v3) —— */
@property --spread {
  syntax: "<number>";
  inherits: true;
  initial-value: 1;
}
@property --hero-s {
  syntax: "<number>";
  inherits: true;
  initial-value: 1;
}
@property --hero-r {
  syntax: "<angle>";
  inherits: true;
  initial-value: 0deg;
}
@property --page-p {
  syntax: "<number>";
  inherits: true;
  initial-value: 0;
}
@property --journey {
  syntax: "<number>";
  inherits: true;
  initial-value: 0;
}

.hero-art .orb {
  transform: scale(var(--hero-s, 1)) rotate(var(--hero-r, 0deg));
  transform-origin: 50% 50%;
  will-change: transform;
}

.circuit-field {
  position: fixed;
  inset: -18% 0;
  pointer-events: none;
  z-index: 0;
  opacity: 0.22;
  background-image:
    radial-gradient(circle at 20% 30%, rgba(47, 180, 255, 0.05), transparent 42%),
    repeating-linear-gradient(
      90deg,
      transparent 0 46px,
      rgba(47, 180, 255, 0.035) 46px 47px
    ),
    repeating-linear-gradient(
      0deg,
      transparent 0 58px,
      rgba(47, 180, 255, 0.03) 58px 59px
    );
  transform: translate3d(0, calc(var(--par-y, 0) * 1px), 0);
  will-change: transform;
}

.page-traces {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1;
}
.trace-run {
  fill: none;
  stroke: #2fb4ff;
  stroke-width: 0.28;
  stroke-linecap: square;
  stroke-linejoin: miter;
  opacity: 0.55;
  stroke-dasharray: 100;
  stroke-dashoffset: calc(100 - var(--page-p, 0) * 100);
}

@supports (animation-timeline: scroll()) {
  html:not(.no-scroll-timeline):not(.review):not(.reduce-motion) .hero-art .orb {
    animation: hero-orb-scroll linear both;
    animation-timeline: scroll();
    animation-range: 0 70vh;
  }
  html:not(.no-scroll-timeline):not(.review):not(.reduce-motion) .ring-b,
  html:not(.no-scroll-timeline):not(.review):not(.reduce-motion) .ring-c {
    animation: hero-spread linear both;
    animation-timeline: scroll();
    animation-range: 0 70vh;
  }
  html:not(.no-scroll-timeline):not(.review):not(.reduce-motion) .trace-run {
    stroke-dashoffset: 100;
    animation: trace-draw linear both;
    animation-timeline: scroll();
  }
}

@keyframes hero-orb-scroll {
  from { --hero-s: 1; --hero-r: 0deg; }
  to { --hero-s: 1.14; --hero-r: 16deg; }
}
@keyframes hero-spread {
  from { --spread: 1; }
  to { --spread: 1.38; }
}
@keyframes trace-draw {
  from { stroke-dashoffset: 100; }
  to { stroke-dashoffset: 0; }
}

/* Headline line reveal */
.section-head h2 .h-line {
  display: block;
  overflow: hidden;
}
.section-head h2 .h-line > span {
  display: inline-block;
  transform: translateY(108%);
  opacity: 0;
  transition: transform 0.85s var(--ease), opacity 0.7s var(--ease);
}
.section-head h2 .h-line:nth-child(2) > span { transition-delay: 0.12s; }
.section-head.is-in h2 .h-line > span,
.section-head.reveal.is-in h2 .h-line > span,
.no-js .section-head h2 .h-line > span {
  transform: none;
  opacity: 1;
}

/* Assignment keycaps press in on a tight beat */
.assignment.is-in .as-tag {
  animation: key-press 0.72s var(--ease) both;
  animation-delay: calc(var(--k, 0) * 90ms);
}
@keyframes key-press {
  0% { transform: translateY(16px); opacity: 0; }
  58% { transform: translateY(0); opacity: 1; }
  76% { transform: translateY(4px); }
  100% { transform: translateY(0); }
}

/* Visitor journey */
.journey {
  position: relative;
  z-index: 2;
  background: #000;
  border-top: 1px solid var(--hair);
  border-bottom: 1px solid var(--hair);
}
.journey-track { height: 380vh; position: relative; }
.journey-stage {
  position: sticky;
  top: calc(var(--draft-h) + var(--nav-h));
  height: calc(100svh - var(--draft-h) - var(--nav-h));
  overflow: hidden;
  display: grid;
  place-items: center;
}
.jp {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 18px;
  padding: 28px 24px 40px;
  opacity: 0;
  pointer-events: none;
  transform: translate3d(0, 18px, 0);
  will-change: opacity, transform;
}
.jp.is-live { pointer-events: auto; }
.jp h2,
.jp h3 {
  margin: 0;
  font-family: var(--display);
  font-weight: 300;
  letter-spacing: -0.035em;
  line-height: 1.02;
  color: var(--fg-strong);
  text-align: center;
}
.jp-idea h2 {
  font-size: clamp(3.4rem, 11vw, 8.4rem);
}
.jp h3 { font-size: clamp(1.6rem, 3.6vw, 2.8rem); max-width: 18ch; }
.jp-kicker,
.jp-copy,
.jp-caption p {
  margin: 0;
  color: var(--muted);
  text-align: center;
  max-width: 36rem;
}
.jp-kicker {
  font-family: var(--mono);
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
}
.jp-idea .eyebrow { margin-bottom: 0; }
.jp-caption { max-width: 28rem; }
.jp-gears,
.jp-board {
  max-width: 100%;
  width: 100%;
  box-sizing: border-box;
}
.journey,
.journey-track {
  max-width: 100%;
  overflow-x: clip;
}

.gear-svg {
  width: min(520px, 100%);
  max-width: 100%;
  height: auto;
  overflow: visible;
  filter: drop-shadow(0 0 18px rgba(47, 180, 255, 0.18));
}
.gear {
  fill: rgba(47, 180, 255, 0.12);
  stroke: rgba(47, 180, 255, 0.85);
  stroke-width: 1.6;
}
.gear-a { transform-origin: 200px 200px; transform: rotate(calc(var(--gear, 0) * 1deg)); }
.gear-b { transform-origin: 355px 200px; transform: rotate(calc(var(--gear, 0) * -1.33deg)); }
.gear-c { transform-origin: 300px 330px; transform: rotate(calc(var(--gear, 0) * 1.6deg)); }
.board-svg {
  width: min(640px, 100%);
  max-width: 100%;
  height: auto;
  overflow: visible;
}
.board-base {
  filter: drop-shadow(0 0 calc(var(--power, 0) * 22px) rgba(47, 180, 255, 0.7));
  transition: filter 0.2s linear;
}
.board-trace {
  fill: none;
  stroke-linecap: square;
  stroke-dasharray: 100;
  stroke-dashoffset: calc(100 - var(--trace, 0) * 100);
  opacity: 0.9;
}
.board-part {
  transform-box: fill-box;
  transform-origin: center;
  transform: translateY(calc((1 - var(--seat, 0)) * -36px)) scale(calc(0.86 + var(--seat, 0) * 0.14));
  opacity: var(--seat, 0);
}
.board-led {
  opacity: var(--power, 0);
  filter: drop-shadow(0 0 8px #2fb4ff);
}
.digit-static {
  display: none;
  max-width: 34rem;
  margin: 0 auto;
  text-align: center;
  font-family: var(--mono);
  font-size: 0.85rem;
  letter-spacing: 0.16em;
  line-height: 2;
  color: rgba(47, 180, 255, 0.55);
  text-transform: uppercase;
}
@media (prefers-reduced-motion: reduce) {
  .digit-static { display: block; }
}
html.review .digit-static { display: block; }

.digit-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
}
.jp-digits .jp-caption-front {
  position: relative;
  z-index: 1;
  text-shadow: 0 0 24px rgba(0, 0, 0, 0.85);
}
.film-frame {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  width: min(520px, 88vw);
  padding: 36px 28px 32px;
  border: 1px solid var(--accent-line);
  background:
    linear-gradient(180deg, rgba(47, 180, 255, 0.1), transparent 42%),
    #07090c;
  box-shadow: 0 0 0 1px rgba(47, 180, 255, 0.08), 0 0 48px rgba(47, 180, 255, 0.12);
  text-align: center;
}
.film-tag {
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
}
.film-frame strong {
  font-family: var(--display);
  font-weight: 300;
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  letter-spacing: -0.03em;
  line-height: 1.08;
  color: var(--fg-strong);
}
.film-sub { color: var(--muted); font-size: 0.95rem; max-width: 28ch; }
.jp-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  margin-top: 8px;
}

/* Books turntable */
.book-turntable {
  position: relative;
  outline: none;
}
.book-stage {
  perspective: 1600px;
  perspective-origin: 50% 46%;
  height: 520px;
  display: grid;
  place-items: center;
  overflow: visible;
  touch-action: pan-y;
  cursor: grab;
}
.book-turntable.is-dragging .book-stage { cursor: grabbing; }
.book-wheel {
  position: relative;
  width: 132px;
  height: 196px;
  transform-style: preserve-3d;
  transform: rotateY(var(--rot, 0deg));
  will-change: transform;
}
.cover-card {
  position: absolute;
  inset: 0;
  transform: rotateY(calc(var(--bi) * 360deg / var(--n))) translateZ(var(--radius, 450px));
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
}
.cover-face {
  position: relative;
  width: 100%;
  height: 100%;
  padding: 0.7rem 0.65rem 0.6rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
  background:
    radial-gradient(circle at 50% 24%, rgba(47, 180, 255, 0.22), transparent 58%),
    #0a0d12;
  border: 1px solid var(--accent-line);
  border-radius: var(--radius-media);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.45);
}
.cover-card-lead .cover-face {
  background:
    radial-gradient(circle at 50% 22%, rgba(47, 180, 255, 0.38), transparent 55%),
    #0a0d12;
  border-color: rgba(47, 180, 255, 0.7);
}
.cover-series {
  font-family: var(--mono);
  font-size: 0.48rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
}
.cover-title {
  font-family: var(--display);
  font-weight: 300;
  font-size: 0.86rem;
  letter-spacing: -0.03em;
  line-height: 1.12;
  color: var(--fg-strong);
  margin-top: 0.35rem;
}
.cover-card-lead .cover-title { font-size: 0.95rem; }
.cover-track {
  font-family: var(--mono);
  font-size: 0.52rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--faint);
  margin-top: auto;
}
.cover-author {
  font-size: 0.62rem;
  color: var(--muted);
  margin-top: 0.2rem;
}
.cover-face img {
  width: 42px;
  position: absolute;
  right: 0.4rem;
  bottom: 2.15rem;
  opacity: 0.92;
  pointer-events: none;
}
.cover-stamp {
  position: absolute;
  top: 54%;
  left: 50%;
  transform: translate(-50%, -50%) rotate(-18deg);
  border: 1.5px solid;
  border-radius: 2px;
  padding: 0.22rem 0.4rem;
  font-family: var(--mono);
  font-size: 0.52rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  white-space: nowrap;
  background: rgba(0, 0, 0, 0.55);
  pointer-events: none;
}
.stamp-soon { color: #7dceff; border-color: #2fb4ff; }
.stamp-wip { color: #f5c542; border-color: #f5c542; }
.book-controls {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 8px;
}
.book-btn {
  min-height: 40px;
  min-width: 40px;
  padding: 0 0.85rem;
  border: 1px solid var(--hair-strong);
  border-radius: var(--radius-btn);
  background: rgba(255, 255, 255, 0.04);
  color: var(--fg-strong);
  font-family: var(--mono);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
}
.book-btn:hover { border-color: var(--accent); color: var(--accent); }
.book-status {
  margin: 10px 0 0;
  text-align: center;
  font-family: var(--mono);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  color: var(--muted);
}

@media (max-width: 960px) {
  .book-stage { height: 440px; }
  .book-wheel { --radius: 360px; }
}

@media (max-width: 760px) {
  .journey-track { height: 300vh; }
  .gear-svg { width: min(420px, 100%); }
  .jp-idea h2 { font-size: clamp(2.6rem, 16vw, 4.4rem); }
}

/* Narrow screens: drop the 3D ring for a single-card peek carousel.
   prefers-reduced-motion keeps the stacked grid from the rule below. */
@media (max-width: 760px) and (prefers-reduced-motion: no-preference) {
  .book-stage {
    height: auto;
    perspective: none;
    perspective-origin: unset;
    display: flex;
    justify-content: flex-start;
    align-items: stretch;
    overflow-x: auto;
    overflow-y: hidden;
    overscroll-behavior-x: contain;
    scroll-snap-type: x mandatory;
    scroll-padding-inline: 20px;
    -webkit-overflow-scrolling: touch;
    touch-action: pan-x pan-y;
    cursor: grab;
    transform: none;
    padding: 4px 0 12px;
    scrollbar-width: none;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    position: relative;
  }
  .book-stage::-webkit-scrollbar { display: none; }
  .book-turntable.is-dragging .book-stage { cursor: grabbing; }
  .book-turntable {
    max-width: 100%;
    min-width: 0;
  }
  .book-wheel {
    --radius: 0px;
    flex: 0 0 auto;
    width: max-content;
    max-width: none;
    height: auto;
    display: flex;
    align-items: stretch;
    gap: 14px;
    transform: none !important;
    transform-style: flat;
    will-change: auto;
    padding-inline: 0;
    box-sizing: content-box;
    position: relative !important;
    left: auto !important;
    right: auto !important;
    inset: auto !important;
    margin: 0 !important;
    justify-self: start;
    align-self: stretch;
  }
  .cover-card {
    position: relative;
    inset: auto;
    flex: 0 0 min(268px, 76vw);
    width: min(268px, 76vw);
    max-width: min(268px, 76vw);
    height: auto;
    min-height: 320px;
    transform: none !important;
    backface-visibility: visible;
    -webkit-backface-visibility: visible;
    scroll-snap-align: center;
    scroll-snap-stop: always;
  }
  .cover-link {
    display: block;
    height: 100%;
  }
  .cover-face {
    min-height: 320px;
    height: 100%;
    overflow: visible;
    padding: 1rem 0.9rem 0.9rem;
  }
  .cover-series { font-size: 0.62rem; }
  .cover-title {
    font-size: 1.15rem;
    line-height: 1.2;
    overflow-wrap: anywhere;
    margin-top: 0.45rem;
  }
  .cover-card-lead .cover-title { font-size: 1.22rem; }
  .cover-track { font-size: 0.68rem; margin-top: 0.85rem; }
  .cover-author { font-size: 0.78rem; }
  .cover-face img {
    width: 56px;
    right: 0.55rem;
    bottom: 3.4rem;
  }
  .cover-stamp {
    position: static;
    transform: none;
    margin-top: 0.7rem;
    align-self: flex-start;
    font-size: 0.62rem;
    background: rgba(0, 0, 0, 0.55);
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-art .orb { transform: none; }
  .circuit-field { transform: none; }
  .trace-run { stroke-dashoffset: 0; }
  .section-head h2 .h-line > span { transform: none; opacity: 1; transition: none; }
  .assignment.is-in .as-tag { animation: none; }
  .journey-track { height: auto; }
  .journey-stage {
    position: relative;
    top: auto;
    height: auto;
    display: flex;
    flex-direction: column;
    gap: 48px;
    padding: 64px 16px;
    overflow: visible;
  }
  .jp {
    position: relative;
    inset: auto;
    opacity: 1 !important;
    transform: none !important;
    pointer-events: auto;
  }
  .digit-canvas { display: none; }
  .gear { transform: none; }
  .board-part { opacity: 1; transform: none; }
  .board-trace { stroke-dashoffset: 0; }
  .board-led { opacity: 1; }
  .book-stage {
    perspective: none;
    height: auto;
    cursor: default;
    transform: none;
  }
  .book-wheel {
    transform: none !important;
    width: 100%;
    height: auto;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(132px, 1fr));
    gap: 14px;
    position: static;
  }
  .cover-card {
    position: relative;
    inset: auto;
    transform: none !important;
    backface-visibility: visible;
  }
  .book-controls { display: none; }
}

html.review .hero-art .orb { transform: none; }
html.review .circuit-field { transform: none; }
html.review .trace-run { stroke-dashoffset: 0; }
html.review .section-head h2 .h-line > span { transform: none; opacity: 1; transition: none; }
html.review .assignment.is-in .as-tag,
html.review .assignment .as-tag { animation: none; }
html.review .journey-track { height: auto; }
html.review .journey-stage {
  position: relative;
  top: auto;
  height: auto;
  display: flex;
  flex-direction: column;
  gap: 36px;
  padding: 48px 16px 56px;
  overflow: visible;
}
html.review .jp {
  position: relative;
  inset: auto;
  opacity: 1 !important;
  transform: none !important;
  pointer-events: auto;
}
html.review .digit-canvas { display: none; }
html.review .gear-a { transform: rotate(18deg); }
html.review .gear-b { transform: rotate(-24deg); }
html.review .gear-c { transform: rotate(28deg); }
html.review .board-part { opacity: 1; transform: none; }
html.review .board-trace { stroke-dashoffset: 0; }
html.review .board-led { opacity: 1; }
html.review .book-wheel { --rot: -24deg; }


/* Chat identity: approved host avatar, never shown next to Bit Rex */
.support-identity {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  flex: 1;
}
.support-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
  object-position: center 18%;
  flex-shrink: 0;
  border: 1px solid var(--hair-strong);
  background: #12151a;
}
.support-role {
  margin: 0.18rem 0 0;
  font-size: 0.72rem;
  line-height: 1.3;
  color: var(--muted);
}
.support-head h2 { font-size: 1.05rem; }
.support-row {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  align-self: stretch;
  max-width: 100%;
}
.support-msg-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  object-fit: cover;
  object-position: center 18%;
  flex-shrink: 0;
  margin-top: 4px;
  border: 1px solid var(--hair);
  background: #12151a;
}
.support-row .support-msg { max-width: calc(100% - 40px); }
.support-launch-avatar {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  object-fit: cover;
  object-position: center 18%;
  display: block;
  flex-shrink: 0;
}
@media (max-width: 760px) {
  .support-avatar { width: 40px; height: 40px; }
  .support-role { font-size: 0.68rem; }
}

/* Keep page content clear of the fixed Support button. */
@media (max-width: 960px) {
  .support {
    right: 12px;
    bottom: 12px;
  }
  .support-launch {
    padding: 8px 12px;
    min-height: 44px;
  }
}

.announce-frame {
  max-height: calc(100svh - var(--draft-h) - var(--nav-h) - var(--support-clearance) - 12px);
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.announce-frame > [data-announce-panel] {
  min-height: 0;
  flex: 1 1 auto;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}

.announce-frame > [data-announce-panel][hidden] {
  display: none !important;
  flex: 0;
  overflow: hidden;
}


/* —— Hero announcement carousel —— */
.announce {
  position: relative;
  z-index: 3;
  width: 100%;
  flex: 0 0 auto;
}

.announce-frame {
  position: relative;
  border: 1px solid var(--hair);
  border-radius: var(--radius-media);
  background: rgba(8, 10, 14, 0.66);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 0 0 1px rgba(47, 180, 255, 0.06);
  padding: 16px 18px 12px;
  overflow: hidden;
}

.announce-progress {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: rgba(47, 180, 255, 0.12);
}

.announce-progress-bar {
  display: block;
  height: 100%;
  width: 100%;
  transform: scaleX(0);
  transform-origin: left center;
  background: var(--accent);
}

@keyframes announce-progress {
  from { transform: scaleX(0); }
  to { transform: scaleX(1); }
}

.announce-viewport {
  min-height: 6.35rem;
}

.announce-slide.is-active {
  animation: announce-fade 0.45s var(--ease);
}

@keyframes announce-fade {
  from { opacity: 0; }
  to { opacity: 1; }
}

.announce-eyebrow {
  font-family: var(--body);
  font-weight: 500;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 6px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.announce-wip {
  font-family: var(--mono);
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #f5c542;
  border: 1px solid #f5c542;
  border-radius: 2px;
  padding: 0.1rem 0.34rem 0.08rem;
  line-height: 1;
}

.announce-title {
  font-family: var(--serif, "Source Serif 4", Palatino, "Times New Roman", serif);
  font-weight: 400;
  font-size: clamp(1.2rem, 1.7vw, 1.5rem);
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin: 0 0 6px;
  color: var(--fg-strong);
}

.announce-line {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.35;
}

.announce-link {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  margin-top: 8px;
  font-size: 0.82rem;
  font-weight: 500;
  text-decoration: none;
  color: var(--accent);
}

.announce-link:hover { color: #7dceff; }

.announce-link .chev {
  display: inline-block;
  transition: transform 0.25s var(--ease);
}

.announce-link:hover .chev { transform: translateX(2px); }

.announce-controls {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid var(--hair);
}

.announce-btn {
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--hair-strong);
  border-radius: var(--radius-btn);
  background: rgba(255, 255, 255, 0.03);
  color: var(--fg-strong);
  cursor: pointer;
  padding: 0;
}

.announce-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.announce-play .icon-play { display: none; }
.announce:not(.is-playing) .announce-play .icon-play { display: block; }
.announce:not(.is-playing) .announce-play .icon-pause { display: none; }

.announce-dots {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-left: 8px;
}

.announce-dot {
  position: relative;
  width: 6px;
  height: 6px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(230, 237, 243, 0.28);
  cursor: pointer;
}

.announce-dot::after {
  content: "";
  position: absolute;
  inset: -8px;
}

.announce-dot.is-active {
  background: var(--accent);
  box-shadow: 0 0 6px rgba(47, 180, 255, 0.45);
}

.announce-status {
  margin: 0 0 0 auto;
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.no-js .announce-controls,
.no-js .announce-progress { display: none; }

@media (max-width: 960px) {
  .announce { max-width: 34rem; margin-inline: auto; }
  .announce-viewport { min-height: 0; }
}

@media (max-width: 560px) {
  .announce { max-width: none; }
  .announce-dots { display: none; }
  .announce-btn { width: 40px; height: 40px; }
  .announce-frame { padding: 12px 14px 8px; }
  .announce-title { font-size: 1.15rem; }
  .announce-controls { margin-top: 8px; padding-top: 8px; }
  .announce-line { font-size: 0.85rem; }
}

@media (max-height: 820px) and (min-width: 961px) {
  .hero { padding-top: 32px; }
  .hero-grid { align-items: start; }
  .hero-art { gap: 12px; padding-inline: 16px; }
  .hero-art .hero-orb { width: min(280px, 38%); max-width: 280px; }
  .hero-art .orb { width: min(52%, 188px); }
  .socials-hero .handle { display: none; }
  .announce-frame { padding: 10px 14px 8px; }
  .announce-viewport { min-height: 0; }
  .announce-controls { margin-top: 8px; padding-top: 8px; }
  .hero-meta { margin-top: 24px; padding-top: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  .announce-slide.is-active,
  .announce-progress-bar { animation: none; }
  .announce-link .chev { transition: none; }
  .announce-progress-bar { transform: scaleX(0); }
}

html.review .announce-slide.is-active,
html.review .announce-progress-bar { animation: none; }
html.review .announce-progress-bar { transform: scaleX(0); }


/* —— Enroll now: hero/nav/footer button + accessible modal —— */
.hero-follow {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 22px;
  margin-top: 28px;
}

.hero-follow .socials {
  margin-top: 0;
  flex: 1 1 auto;
}

.enroll-hero {
  flex: 0 0 auto;
  min-height: 44px;
  padding-inline: 18px;
  letter-spacing: 0.02em;
}

.nav-socials .nav-enroll {
  margin-left: 0.15rem;
  padding: 6px 11px;
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  text-transform: none;
  min-height: 0;
  line-height: 1.1;
}

.footer-enroll {
  margin-top: 0.85rem;
}

.contact-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

button.announce-link {
  font-family: inherit;
  background: none;
  border: 0;
  cursor: pointer;
  text-align: left;
}

.enroll-layer {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: grid;
  place-items: center;
  padding: 24px 16px;
}

.enroll-layer[hidden] { display: none !important; }

.enroll-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(4, 6, 10, 0.72);
}

.enroll-modal {
  position: relative;
  z-index: 1;
  width: min(32.5rem, 100%);
  max-height: min(90vh, 44rem);
  overflow: auto;
  background: #0c1016;
  color: #d7dde6;
  border: 1px solid rgba(47, 180, 255, 0.22);
  border-radius: 8px;
  padding: 28px 24px 24px;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.5);
}

.enroll-modal h2 {
  margin: 0 2rem 0.5rem 0;
  font-family: var(--display);
  font-weight: 300;
  font-size: clamp(1.6rem, 3vw, 2.1rem);
  letter-spacing: -0.03em;
  color: #f4f6f8;
}

.enroll-modal #enroll-intro {
  margin: 0 0 1.15rem;
  color: rgba(215, 221, 230, 0.78);
  font-size: 0.95rem;
}

.enroll-modal form {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.enroll-modal form[hidden],
.enroll-thanks[hidden],
.enroll-error[hidden] { display: none !important; }

.enroll-modal label {
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  color: rgba(215, 221, 230, 0.72);
}

.enroll-modal .optional {
  letter-spacing: 0.02em;
  text-transform: none;
  color: rgba(215, 221, 230, 0.46);
}

.enroll-modal input[type="text"],
.enroll-modal input[type="email"],
.enroll-modal select {
  background: #07090c;
  color: #f4f6f8;
  border: 1px solid rgba(237, 237, 238, 0.16);
  border-radius: var(--radius-btn);
  padding: 10px 12px;
  font: 400 0.95rem/1.4 var(--body);
  width: 100%;
  margin-bottom: 0.55rem;
}

.enroll-modal input:focus-visible,
.enroll-modal select:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.enroll-newsletter {
  margin: 0.2rem 0 0.55rem;
  font-size: 0.92rem;
  color: #f4f6f8;
  line-height: 1.45;
}

.enroll-consent {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  font-size: 0.84rem;
  color: rgba(215, 221, 230, 0.82);
  line-height: 1.45;
  margin-bottom: 0.35rem;
}

.enroll-consent input {
  margin-top: 0.2rem;
  flex: none;
}

.enroll-note {
  margin: 0 0 1rem;
  font-size: 0.78rem;
  color: rgba(215, 221, 230, 0.52);
  line-height: 1.45;
}

.enroll-modal .form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.enroll-error {
  margin: 0 0 0.7rem;
  font-size: 0.88rem;
  color: #ffb4b4;
}

.enroll-thanks {
  margin: 0.4rem 0 0;
  font-size: 1.05rem;
  color: #f4f6f8;
  line-height: 1.45;
}

.enroll-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 36px;
  height: 36px;
  border: 0;
  background: transparent;
  color: rgba(215, 221, 230, 0.8);
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  border-radius: 4px;
}

.enroll-close:hover { color: #fff; }

body.enroll-open { overflow: hidden; }

/* Keep the modal on the dark palette even on ivory subpages. */
body.page-sub .enroll-modal,
body.page-sub .enroll-modal a,
body.page-sub .enroll-modal p,
body.page-sub .enroll-modal label {
  color: #d7dde6;
}
body.page-sub .enroll-modal h2,
body.page-sub .enroll-newsletter,
body.page-sub .enroll-thanks { color: #f4f6f8; }
body.page-sub .enroll-modal .btn-primary {
  background: #ededee;
  color: #161513;
  border-color: #ededee;
}
body.page-sub .enroll-modal .btn-primary:hover {
  background: #fff;
  color: #161513;
}
body.page-sub .enroll-modal .btn-glass {
  background: rgba(237, 237, 238, 0.14);
  color: #f4f6f8;
  border-color: transparent;
}

@media (max-width: 1024px) {
  .hero-follow { gap: 12px 16px; }
  .nav-socials { gap: 0.45rem; }
}

@media (max-width: 820px) {
  .hero-follow { gap: 12px; }
  .enroll-hero { padding-inline: 16px; }
  .nav-socials .nav-enroll { padding: 6px 10px; }
  .enroll-modal { padding: 24px 18px 20px; }
}

@media (max-width: 560px) {
  .hero-follow { margin-top: 22px; }
  .enroll-hero { width: 100%; justify-content: center; }
  .nav-socials {
    width: 100%;
    flex-wrap: wrap;
  }
}

@media (prefers-reduced-motion: reduce) {
  .enroll-modal { scroll-behavior: auto; }
}

/* —— Hero terminal + stage (v10) —— */
.wrap.hero-grid {
  width: min(1280px, calc(100% - 48px));
}

/* Announcement sits above the orbit in one stack (v8 placement).
   The terminal is a tall column beside that stack, stretched to the same height. */
.hero-art {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: flex-start;
  gap: 24px;
  min-width: 0;
}

/* Rex + orbits sit directly to the left of the terminal, vertically centered. */
.hero-term-row {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 20px;
  min-width: 0;
  width: 100%;
}

.hero-stack {
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-width: 0;
  align-items: stretch;
  flex: 0 0 auto;
  width: 100%;
}

.hero-art > .announce,
.hero-stack > .announce,
.hero-art > .hero-video,
.hero-stack > .hero-video {
  max-width: none;
  width: 100%;
  flex: 0 0 auto;
}

.hero-art .term {
  position: relative;
  flex: 1 1 320px;
  align-self: stretch;
  min-width: 0;
  width: auto;
  height: auto;
  min-height: 280px;
  overflow: hidden;
}

.hero-art .hero-orb {
  flex: 0 1 auto;
  width: min(320px, 42%);
  max-width: 320px;
  margin-inline: 0;
  /* No Support-button inset: the orb now sits on the left of the terminal. */
}

@media (min-width: 961px) {
  .hero { padding-top: 48px; padding-bottom: 48px; }
  .hero-grid {
    grid-template-columns: minmax(250px, 0.78fr) minmax(640px, 1.34fr);
    gap: 28px;
    align-items: start;
  }
  /* Market Pulse is a grid sibling so the desktop left column stays copy + box,
     while mobile can stack the box below the orbit and clear the Support button. */
  .hero-copy { grid-column: 1; grid-row: 1; }
  .hero-art { grid-column: 2; grid-row: 1 / span 2; align-self: stretch; padding-inline: 16px; }
  .hero-grid > .market-pulse { grid-column: 1; grid-row: 2; align-self: start; }
  /* Support is now beside the video/announce stack, not the orb.
     Reserve a first-screen lane so the button does not cover the video. */
  .hero-stack {
    max-width: calc(100% - 7.75rem);
    margin-inline-end: 7.75rem;
    align-self: start;
    width: 100%;
  }
  .hero-actions { margin-top: 24px; }
  .hero-follow { margin-top: 16px; }
  .lede { margin-top: 18px; }
}

@media (max-width: 1180px) and (min-width: 961px) {
  .socials-hero .handle { display: none; }
}

.term {
  --term-mono: ui-monospace, "SFMono-Regular", "SF Mono", "Cascadia Mono", "Cascadia Code", "Segoe UI Mono", "Liberation Mono", Menlo, Monaco, Consolas, monospace;
  position: relative;
  z-index: 3;
  min-width: 0;
  width: 100%;
}

.term-window {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  height: 100%;
  min-height: 0;
  max-height: none;
}

.hero-art .term-window {
  position: absolute;
  inset: 0;
  height: auto;
  max-height: none;
  min-height: 0;
  border: 1px solid var(--hair);
  border-radius: var(--radius-media);
  background: rgba(6, 8, 12, 0.78);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 0 0 1px rgba(47, 180, 255, 0.06);
  overflow: hidden;
}

.term-chrome {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
  padding: 7px 8px 7px 10px;
  border-bottom: 1px solid var(--hair);
  background: rgba(255, 255, 255, 0.015);
}

.term-dots {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  flex: 0 0 auto;
}

.term-dots i {
  display: block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(230, 237, 243, 0.28);
}

.term-dots i:nth-child(1) { background: #c85a54; }
.term-dots i:nth-child(2) { background: #c9a24a; }
.term-dots i:nth-child(3) { background: #3fa35a; }

.term-title {
  margin: 0;
  min-width: 0;
  flex: 1 1 auto;
  font-family: var(--term-mono);
  font-size: 0.66rem;
  font-weight: 400;
  letter-spacing: 0;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.term-play {
  flex: 0 0 auto;
  width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--hair-strong);
  border-radius: var(--radius-btn);
  background: rgba(255, 255, 255, 0.03);
  color: var(--fg-strong);
  cursor: pointer;
  padding: 0;
}

.term-play:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.term.is-playing .term-play .icon-play { display: none; }
.term:not(.is-playing) .term-play .icon-play { display: block; }
.term:not(.is-playing) .term-play .icon-pause { display: none; }

.term-body {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
  padding: 8px 12px 10px;
  scrollbar-width: thin;
  scrollbar-color: rgba(47, 180, 255, 0.35) transparent;
}

.term-scroll {
  margin: 0;
  font-family: var(--term-mono);
  font-size: 0.68rem;
  line-height: 1.42;
  letter-spacing: 0;
  color: #c8d6e0;
}

.term-line {
  word-break: break-word;
  overflow-wrap: anywhere;
  min-height: 1.42em;
}

.term-prompt { color: var(--accent); font-weight: 600; }
.term-cmd { color: #e8f4ff; }
.term-out { color: rgba(200, 214, 224, 0.72); }
.term-ok { color: #5ee08a; }
.term-hash { color: rgba(47, 180, 255, 0.82); }
.term-bar {
  color: var(--accent);
  font-variant-numeric: tabular-nums;
  white-space: pre-wrap;
}
.term-scroll a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 0.15em;
}
.term-scroll a:hover { color: #7dceff; }

.term-tag {
  font-weight: 600;
  letter-spacing: 0.02em;
}
.term-tag-youtube { color: #ff7a7a; }
.term-tag-tiktok { color: #6cf0e6; }
.term-tag-instagram { color: #f0a0c8; }
.term-tag-x { color: #e6edf3; }
.term-handle { color: #d5e6f4; }
.term-quote { color: rgba(200, 214, 224, 0.84); }

.term-caret {
  display: inline-block;
  width: 0.55em;
  height: 1em;
  margin-left: 1px;
  background: var(--accent);
  vertical-align: text-bottom;
  box-shadow: 0 0 6px rgba(47, 180, 255, 0.55);
  animation: term-blink 1.05s step-end infinite;
}

.term-caret.is-still { animation: none; opacity: 0.85; }

@keyframes term-blink {
  50% { opacity: 0; }
}

.no-js .term-play { display: none; }

.enroll-hp {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.enroll-privacy {
  margin: 0 0 0.85rem;
  font-size: 0.8rem;
  color: rgba(215, 221, 230, 0.62);
  line-height: 1.45;
}

@media (max-width: 1024px) {
  .wrap.hero-grid { width: min(1180px, calc(100% - 40px)); }
  .term-scroll { font-size: 0.66rem; }
}

/* iPad (and other mid widths): keep the tall terminal beside announce + orbit. */
@media (max-width: 960px) {
  .wrap.hero-grid { width: min(var(--max), calc(100% - 32px)); }
  .hero-art {
    gap: 16px;
    padding-inline: 12px;
  }
  .hero-term-row { gap: 16px; }
  /* Shrink rings so slot transforms stay inside the orb stage (no sideways scroll). */
  .hero-art .hero-orb { width: min(280px, 40%); max-width: 280px; }
  .hero-art .ring-c { --orbit-r: min(calc(66% * var(--spread, 1)), calc(100% - 6rem)); }
  .hero-art .ring-b { --orbit-r: min(calc(44% * var(--spread, 1)), calc(100% - 10.5rem)); }
  .announce { max-width: none; }
  .term-window { max-height: none; }
  /* Keep the fixed Support button off the Latest Video card on the first screen. */
  .hero-stack > .hero-video {
    margin-inline-end: 7.75rem;
    max-width: calc(100% - 7.75rem);
    align-self: start;
    width: 100%;
  }
}

@media (max-width: 640px) {
  .hero-art {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 16px;
    padding-inline: 0;
    /* Clip only decorative slot-transform overflow so the restored
       full-column orbit cannot scroll the page sideways. */
    overflow-x: clip;
  }
  /* Keep video/announcements first; stack Rex above the terminal. */
  .hero-stack { order: 1; width: 100%; flex: 0 0 auto; }
  .hero-term-row {
    order: 2;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    width: 100%;
  }
  .hero-art .term {
    width: 100%;
    flex: 0 0 auto;
    position: relative;
    height: auto;
    min-height: 0;
    align-self: stretch;
  }
  .hero-art .hero-orb {
    /* Full-column orbit; stacking keeps it from being squashed beside the terminal. */
    width: min(420px, 100%);
    max-width: min(420px, 100%);
    align-self: center;
  }
  /* Smaller glass on mobile so orbit one has a clear lane between
     the bubble and the social ring. Desktop is unchanged. */
  .hero-art .orb {
    width: min(42%, 180px);
  }
  /* Paint chips above the glass photo so labels are not hidden under it. */
  .hero-art .orbit-stage { z-index: 2; }
  /* Orbit one: sit in a mid-radius lane that clears the glass and
     stays inside the social ring even as the rings rotate. */
  .hero-art .ring-b {
    --orbit-r: min(calc(60% * var(--spread, 1)), calc(100% - 6.5rem));
    z-index: 3;
  }
  /* Place the 8 tool chips on 8 of the 10 midpoints between socials,
     skipping two opposite gaps so labels are more evenly spaced. */
  /* Wide labels (yt-uploader, Chatterbox, Glaxnimate, llama.cpp) sit
     near the top or bottom so their width does not cut into the glass. */
  .hero-art .ring-b .slot:nth-child(1) { --a: 36deg; }   /* Kokoro */
  .hero-art .ring-b .slot:nth-child(2) { --a: 144deg; }  /* Glaxnimate */
  .hero-art .ring-b .slot:nth-child(3) { --a: 180deg; }  /* Chatterbox */
  .hero-art .ring-b .slot:nth-child(4) { --a: 72deg; }   /* Whisper */
  .hero-art .ring-b .slot:nth-child(5) { --a: 252deg; }  /* Rhubarb */
  .hero-art .ring-b .slot:nth-child(6) { --a: 324deg; }  /* ComfyUI */
  .hero-art .ring-b .slot:nth-child(7) { --a: 216deg; }  /* llama.cpp */
  .hero-art .ring-b .slot:nth-child(8) { --a: 0deg; }    /* yt-uploader */
  /* Slightly tighter labels so the widest chips (yt-uploader, Glaxnimate)
     fit the lane without covering the glass or a social icon. The
     existing ::after hit area stays at or above 44px. */
  .hero-art .ring-b .chip {
    font-size: 0.5rem;
    letter-spacing: 0.02em;
    padding: 5px 6px 5px 11px;
  }
  /* Social ring: undo the mid-width 66% cap so spacing matches the
     pre-Change-4 look. Chip size, items, and links stay the same. */
  .hero-art .ring-c {
    --orbit-r: min(calc(96% * var(--spread, 1)), calc(100% - 2.75rem));
  }
  .hero-stack > .announce { max-width: 34rem; align-self: center; width: 100%; }
  .hero-stack > .hero-video {
    max-width: min(34rem, calc(100% - 7.75rem));
    margin-inline-end: 7.75rem;
    align-self: start;
    width: 100%;
  }
  .hero-art .term-window,
  .term-window {
    position: relative;
    inset: auto;
    height: 220px;
    min-height: 220px;
    max-height: 220px;
    flex: 0 0 220px;
  }
  .term-scroll { font-size: 0.62rem; line-height: 1.35; }
  .term-play { width: 40px; height: 40px; }
  .term-title { font-size: 0.62rem; }
}

@media (max-height: 820px) and (min-width: 961px) {
  .hero-term-row { gap: 16px; }
  .hero-stack { gap: 12px; }
  .hero-art .hero-orb { width: min(280px, 38%); max-width: 280px; }
  .hero-art .orb { width: min(58%, 240px); }
}

@media (prefers-reduced-motion: reduce) {
  .term-caret { animation: none; }
  .term-play { display: none; }
}

html.review .term-caret { animation: none; }
html.review .term-play { display: none; }

/* —— Morning Digest (announcements tab + archive) —— */
.announce-tabs {
  display: flex;
  align-items: stretch;
  gap: 0;
  margin: 0 0 10px;
  padding: 0 0 0;
  border-bottom: 1px solid var(--hair);
}

.announce-tab {
  appearance: none;
  -webkit-appearance: none;
  margin: 0;
  padding: 0 12px 8px;
  border: 0;
  border-bottom: 1px solid transparent;
  margin-bottom: -1px;
  background: transparent;
  color: var(--muted);
  font-family: var(--body);
  font-weight: 500;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
  line-height: 1.2;
}

.announce-tab:hover { color: var(--fg-strong); }

.announce-tab[aria-selected="true"] {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

.announce-tab:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.announce.is-digest .announce-progress { display: none; }

.digest-panel {
  min-height: 6.35rem;
}

.digest-date {
  color: var(--muted);
  letter-spacing: 0.08em;
  font-weight: 500;
}

.digest-date::before {
  content: "·";
  margin: 0 0.45em 0 0.15em;
  color: rgba(47, 180, 255, 0.55);
}

.digest-lines {
  list-style: none;
  margin: 0;
  padding: 0;
  max-height: 7.6rem;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(47, 180, 255, 0.35) transparent;
}

.digest-lines li {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
  padding: 0.22rem 0;
  border-bottom: 1px solid rgba(47, 180, 255, 0.08);
  font-size: 0.78rem;
  line-height: 1.3;
}

.digest-lines li:last-child { border-bottom: 0; }

.digest-line-title,
.digest-item-title {
  color: var(--fg-strong);
  text-decoration: none;
  min-width: 0;
  flex: 1 1 auto;
  overflow-wrap: anywhere;
}

a.digest-line-title,
a.digest-item-title { color: #9ad6ff; }

a.digest-line-title:hover,
a.digest-item-title:hover { color: #c8e9ff; }

.digest-badges {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 4px;
  flex: 0 0 auto;
  justify-content: flex-end;
}

.digest-badge {
  font-family: var(--mono);
  font-size: 0.52rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  line-height: 1;
  padding: 0.14rem 0.32rem 0.1rem;
  border-radius: 2px;
  border: 1px solid;
  white-space: nowrap;
}

.digest-badge-os {
  color: #7dceff;
  border-color: rgba(47, 180, 255, 0.55);
  background: rgba(47, 180, 255, 0.08);
}

.digest-badge-ubuntu {
  color: #9ee37d;
  border-color: rgba(110, 200, 90, 0.55);
  background: rgba(80, 160, 60, 0.12);
}

.digest-badge-unverified {
  color: var(--muted);
  border-color: var(--hair-strong);
  background: rgba(255, 255, 255, 0.03);
}

.digest-badge-closed {
  color: #f5c542;
  border-color: rgba(245, 197, 66, 0.45);
  background: rgba(245, 197, 66, 0.08);
}

.digest-empty {
  margin: 0;
  color: var(--muted);
  font-size: 0.85rem;
  line-height: 1.35;
}

.digest-see-all { margin-top: 8px; }

.digest-noscript {
  margin: 8px 0 0;
  font-size: 0.8rem;
  color: var(--muted);
}

/* Archive page (dark, matches the landing). */
body.page-digest .digest-archive {
  display: flex;
  flex-direction: column;
  gap: 36px;
  padding-bottom: 48px;
}

.digest-day {
  border: 1px solid var(--hair);
  border-radius: var(--radius-media);
  background: rgba(8, 10, 14, 0.66);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 0 0 1px rgba(47, 180, 255, 0.06);
  padding: 22px 24px 20px;
}

.digest-day-head { margin-bottom: 14px; }

.digest-day-head h2 {
  font-family: var(--serif, "Source Serif 4", Palatino, "Times New Roman", serif);
  font-weight: 400;
  font-size: clamp(1.4rem, 2vw, 1.85rem);
  letter-spacing: -0.02em;
  margin: 0;
  color: var(--fg-strong);
}

.digest-items {
  list-style: none;
  margin: 0;
  padding: 0;
  counter-reset: digest-item;
}

.digest-item {
  padding: 12px 0;
  border-top: 1px solid var(--hair);
  counter-increment: digest-item;
}

.digest-item:first-child { border-top: 0; padding-top: 0; }

.digest-item-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.digest-item-title {
  font-size: 1.02rem;
  font-weight: 600;
  line-height: 1.3;
}

.digest-item-summary {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.45;
  max-width: 46rem;
}

.digest-ideas {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--hair);
}

.digest-ideas ul {
  margin: 8px 0 0;
  padding: 0 0 0 1.15rem;
  color: var(--fg-strong);
  font-size: 0.92rem;
  line-height: 1.45;
}

.digest-ideas li { margin: 0 0 0.4rem; }

@media (max-width: 560px) {
  .announce-tab { padding: 0 10px 8px; font-size: 10px; }
  .digest-panel { min-height: 0; }
  .digest-lines { max-height: 9.5rem; }
  .digest-day { padding: 16px 14px 14px; }
  .digest-item-head { gap: 6px; }
}

@media (prefers-reduced-motion: reduce) {
  .announce-tab { transition: none; }
}

html.review .digest-lines {
  /* Keep the first items in view for stills; no motion anyway. */
  scroll-behavior: auto;
}


/* Cover cards as links (3D shelf, library grid, and book pages) */
.cover-link {
  display: block;
  width: 100%;
  height: 100%;
  color: inherit;
  text-decoration: none;
  border-radius: inherit;
}
.cover-link:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}
.cover-link:hover .cover-face {
  border-color: var(--accent);
}
.roadmap-grid .cover-link { height: 100%; }

/* —— Products tab in the announcement box —— */
.announce.is-products .announce-progress { display: none; }

.products-panel { min-height: 6.35rem; }

.products-intro {
  margin: 0 0 8px;
  color: var(--muted);
  font-size: 0.8rem;
  line-height: 1.35;
}

.product-list {
  list-style: none;
  margin: 0;
  padding: 0;
  max-height: none;
  overflow: visible;
}

.product-item {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  padding: 0.45rem 0;
  border-bottom: 1px solid rgba(47, 180, 255, 0.08);
}

.product-item:last-child { border-bottom: 0; }

.product-name {
  margin: 0;
  color: var(--fg-strong);
  font-size: 0.82rem;
  font-weight: 600;
  line-height: 1.3;
  min-width: 0;
  width: 100%;
  overflow-wrap: anywhere;
}

.product-meta {
  margin: 0;
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 8px;
  width: 100%;
  text-align: left;
}

.product-price {
  color: var(--muted);
  font-size: 0.72rem;
  line-height: 1.3;
}

.product-buy {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  flex: 0 0 auto;
  padding: 0.18rem 0.5rem 0.16rem;
  border: 1px solid var(--accent);
  border-radius: var(--radius-btn);
  background: rgba(47, 180, 255, 0.12);
  color: #c8e9ff;
  font-family: var(--mono);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  line-height: 1.2;
  white-space: nowrap;
}
.product-buy:hover {
  background: rgba(47, 180, 255, 0.22);
  color: #fff;
  border-color: #7dceff;
}
.product-buy .chev { transition: transform 0.15s ease; }
.product-buy:hover .chev { transform: translateX(2px); }
.product-buy:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
@media (prefers-reduced-motion: reduce) {
  .product-buy .chev { transition: none; }
}

.product-soon {
  font-family: var(--mono);
  font-size: 0.52rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  line-height: 1;
  padding: 0.14rem 0.32rem 0.1rem;
  border-radius: 2px;
  border: 1px solid rgba(47, 180, 255, 0.55);
  color: #7dceff;
  background: rgba(47, 180, 255, 0.08);
  white-space: nowrap;
}

@media (max-width: 560px) {
  .announce-tabs {
    overflow-x: auto;
    flex-wrap: nowrap;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }
  .announce-tabs::-webkit-scrollbar { display: none; }
  .announce-tab {
    flex: 0 0 auto;
    white-space: nowrap;
    padding: 0 8px 8px;
    letter-spacing: 0.08em;
  }
  .products-panel { min-height: 0; }
  .product-list { max-height: none; }
}


.product-lead {
  margin: 0;
  color: var(--muted);
  font-size: 0.72rem;
  line-height: 1.35;
}

.product-tiers {
  list-style: none;
  margin: 2px 0 0;
  padding: 0;
  width: 100%;
  display: grid;
  gap: 4px;
}

.product-tiers li {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 2px 8px;
  font-size: 0.74rem;
  line-height: 1.3;
}

.product-tier-name {
  color: var(--fg-strong);
  font-weight: 600;
}

.product-tiers .product-price { font-size: 0.72rem; }

.product-tier-note {
  color: var(--muted);
  font-size: 0.7rem;
  flex: 1 1 12rem;
}

.product-item-service .product-meta { margin-top: 4px; }

html.review .product-list { scroll-behavior: auto; }

/* —— Follow us row in the announcement box —— */
.announce-follow {
  margin: 0 0 10px;
  padding: 0 0 10px;
  border-bottom: 1px solid var(--hair);
}

.announce-follow .announce-eyebrow {
  margin: 0 0 8px;
}

.announce-socials {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 10px;
}

.announce-socials a {
  color: var(--fg-strong);
  text-decoration: none;
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  display: inline-flex;
  align-items: baseline;
  gap: 0.35rem;
  border-bottom: 1px solid var(--hair-strong);
  padding-bottom: 2px;
  line-height: 1.2;
}

.announce-socials a:hover {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

.announce-socials a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.announce-socials .handle {
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.04em;
  color: var(--muted);
  font-weight: 400;
  /* The announcement column is too narrow for handles. */
  display: none;
}

@media (max-width: 560px) {
  .announce-follow { margin-bottom: 8px; padding-bottom: 8px; }
  .announce-socials { gap: 8px 12px; }
  .announce-socials a { font-size: 0.8rem; }
}


/* —— Video 01 embed, immediately above the announcement box —— */
.hero-video {
  position: relative;
  z-index: 3;
  width: 100%;
  flex: 0 0 auto;
  min-width: 0;
  scroll-margin-top: calc(var(--draft-h) + var(--nav-h) + 16px);
  scroll-margin-bottom: var(--support-clearance);
}

.hero-video-frame {
  position: relative;
  border: 1px solid var(--hair);
  border-radius: var(--radius-media);
  background: rgba(8, 10, 14, 0.66);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 0 0 1px rgba(47, 180, 255, 0.06);
  padding: 16px 18px 12px;
}

.hero-video-frame .announce-title {
  margin-bottom: 10px;
}

.hero-video-embed {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #05070a;
  border: 1px solid var(--hair);
  border-radius: var(--radius-media);
  overflow: hidden;
}

.hero-video-embed iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}

.hero-video-frame .announce-link {
  margin-top: 10px;
}

@media (max-width: 560px) {
  .hero-video-frame { padding: 14px 14px 10px; }
}

/* Keep review stills clear of the support launcher. */
html.review .support { display: none !important; }


/* —— Social orbit (outer ring) + Market Pulse (landing lower left) —— */
.orbit-stage:hover .slot,
.orbit-stage:focus-within .slot,
.orbit-stage:hover .slot .chip,
.orbit-stage:focus-within .slot .chip,
.orbit-stage:hover .slot .social-orb,
.orbit-stage:focus-within .slot .social-orb {
  animation-play-state: paused;
}

.slot .social-orb {
  position: absolute;
  left: 50%;
  top: 0;
  transform: translate(-50%, -50%) rotate(calc(-1 * var(--a)));
  animation: orbit-counter-social var(--spin) linear infinite reverse;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  min-width: 44px;
  min-height: 44px;
  color: var(--fg-strong);
  background: #07090c;
  border: 1px solid rgba(47, 180, 255, 0.45);
  border-radius: 50%;
  box-shadow:
    inset 0 0 0 1px rgba(47, 180, 255, 0.08),
    0 0 10px rgba(47, 180, 255, 0.18);
  text-decoration: none;
  pointer-events: auto;
  z-index: 3;
}

.slot .social-orb::after {
  content: "";
  position: absolute;
  inset: -4px;
  border-radius: 50%;
}

.slot .social-orb:hover,
.slot .social-orb:focus-visible {
  color: #d8f3ff;
  border-color: rgba(47, 180, 255, 0.95);
  box-shadow:
    inset 0 0 0 1px rgba(47, 180, 255, 0.28),
    0 0 12px rgba(47, 180, 255, 0.55),
    0 0 22px rgba(47, 180, 255, 0.32);
}

.slot .social-orb:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

@keyframes orbit-counter-social {
  from { transform: translate(-50%, -50%) rotate(calc(-1 * var(--a))); }
  to { transform: translate(-50%, -50%) rotate(calc(-1 * var(--a) - 360deg)); }
}

.market-pulse {
  margin-top: 28px;
  max-width: 26rem;
  width: 100%;
  position: relative;
  z-index: 4;
}

.market-pulse-frame {
  border: 1px solid var(--hair);
  border-radius: var(--radius-media);
  background: rgba(8, 10, 14, 0.66);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 0 0 1px rgba(47, 180, 255, 0.06);
  padding: 14px 16px 12px;
}

.market-pulse-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 6px 12px;
  margin-bottom: 4px;
}

.market-pulse-head .eyebrow {
  margin: 0;
}

.market-pulse-asof {
  margin: 0;
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.04em;
  color: var(--muted);
}

.market-pulse-tabs {
  display: flex;
  align-items: stretch;
  gap: 0;
  margin: 8px 0 10px;
  border-bottom: 1px solid var(--hair);
}

.market-pulse-tab {
  appearance: none;
  -webkit-appearance: none;
  margin: 0;
  padding: 8px 10px 8px;
  min-height: 44px;
  border: 0;
  border-bottom: 1px solid transparent;
  margin-bottom: -1px;
  background: transparent;
  color: var(--muted);
  font-family: var(--body);
  font-weight: 500;
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
  line-height: 1.2;
}

.market-pulse-tab:hover { color: var(--fg-strong); }

.market-pulse-tab[aria-selected="true"] {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

.market-pulse-tab:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.market-pulse-panel {
  min-height: 0;
  max-height: min(28rem, 58vh);
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding-right: 4px;
  scrollbar-width: thin;
  scrollbar-color: rgba(47, 180, 255, 0.45) transparent;
}
.market-pulse-panel::-webkit-scrollbar { width: 6px; }
.market-pulse-panel::-webkit-scrollbar-thumb {
  background: rgba(47, 180, 255, 0.45);
  border-radius: 3px;
}
.market-pulse-panel[hidden] { display: none !important; }

.market-pulse-empty,
.market-pulse-note {
  margin: 0;
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.4;
}

.market-pulse-note { margin-top: 8px; font-size: 0.75rem; }

.market-pulse-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 8px;
}

.market-pulse-item {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 1px 12px;
  align-items: baseline;
  padding-bottom: 6px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.market-pulse-item:last-child { border-bottom: 0; padding-bottom: 0; }

.market-pulse-name,
.market-pulse-name a {
  color: var(--fg-strong);
  font-size: 0.92rem;
  text-decoration: none;
}

.market-pulse-name a:hover { color: var(--accent); }
.market-pulse-name a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.market-pulse-meta {
  margin: 0;
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.03em;
  color: var(--muted);
  grid-column: 1 / -1;
}

.market-pulse-stat {
  font-family: var(--mono);
  font-size: 0.78rem;
  color: var(--accent);
  white-space: nowrap;
}
.market-pulse-stat.is-empty { color: var(--muted); }

.market-pulse-source {
  margin: 10px 0 0;
  font-size: 0.7rem;
  color: var(--muted);
  line-height: 1.35;
}

@media (max-width: 760px) {
  .market-pulse { max-width: none; margin-top: 22px; padding-bottom: var(--support-clearance); }
  .hero-orb { max-width: min(460px, 94%); }
  .slot .social-orb { width: 44px; height: 44px; }
}

@media (prefers-reduced-motion: reduce) {
  .orbit-stage:hover .slot,
  .orbit-stage:focus-within .slot,
  .orbit-stage:hover .slot .chip,
  .orbit-stage:focus-within .slot .chip,
  .orbit-stage:hover .slot .social-orb,
  .orbit-stage:focus-within .slot .social-orb {
    animation-play-state: paused;
  }
}
