/* Institutional typography, light subpages, emblem, sticky Academy menu.
   Inspired by the calm of long-standing academic sites, never copied:
   no outside names, crests, or colors used as a seal. */

@font-face {
  font-family: "Source Serif 4";
  src: url("../fonts/SourceSerif4Variable-Roman.woff2") format("woff2");
  font-weight: 200 900;
  font-style: normal;
  font-display: swap;
}

:root {
  --display: "Source Serif 4", "Palatino Linotype", Palatino, "Times New Roman", serif;
  --serif: var(--display);
}

h1, h2, h3,
.jp-idea h2,
.jp h3,
.film-frame strong,
.cover-title,
.sub-hero h1,
.portal h3,
.join-strip h2 {
  font-family: var(--serif);
  font-weight: 400;
  letter-spacing: -0.02em;
}

/* Slightly quieter landing motion */
.hero-art .orb { will-change: transform; }

/* Emblem + refined brand */
.brand-emblem {
  width: 40px;
  height: 40px;
  display: block;
  flex-shrink: 0;
}
.brand-word {
  font-family: var(--serif);
  font-weight: 400;
  letter-spacing: -0.01em;
  font-size: 0.98rem;
  line-height: 1.15;
}
.hero-emblem {
  width: 112px;
  height: 112px;
  display: block;
  margin: 0 0 22px;
}
.lede-short {
  max-width: 22em;
  font-size: 1.12rem;
  color: var(--muted);
}

/* How to join */
.join-strip {
  position: relative;
  z-index: 2;
  padding: 96px 0 80px;
  border-top: 1px solid var(--hair);
}
.join-strip h2 {
  font-size: clamp(2rem, 4.4vw, 3.4rem);
  margin: 0 0 36px;
  line-height: 1.08;
  color: var(--fg-strong);
}
.join-steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid var(--hair);
  border-bottom: 1px solid var(--hair);
}
.join-steps li { border-right: 1px solid var(--hair); }
.join-steps li:last-child { border-right: 0; }
.join-steps a {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 28px 22px 32px;
  color: inherit;
  text-decoration: none;
  min-height: 180px;
}
.join-steps a:hover { background: rgba(47, 180, 255, 0.06); color: inherit; }
.join-num {
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  color: var(--accent);
}
.join-steps strong {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.45rem;
  color: var(--fg-strong);
}
.join-steps span:last-child { color: var(--muted); font-size: 0.95rem; }
.join-more { margin: 22px 0 0; }
.join-steps-on-page { margin-top: 12px; }

/* Library band on the landing */
.library-band {
  position: relative;
  z-index: 2;
  padding: 88px 0 48px;
  border-top: 1px solid var(--hair);
}
.library-link { text-align: center; margin: 8px 0 0; }

/* Graphical portals */
.portals {
  position: relative;
  z-index: 2;
  padding: 48px 0 120px;
}
.portal-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid var(--hair);
  border-left: 1px solid var(--hair);
}
.portal {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 32px 28px 36px;
  min-height: 220px;
  color: inherit;
  text-decoration: none;
  border-right: 1px solid var(--hair);
  border-bottom: 1px solid var(--hair);
  background: transparent;
}
.portal:hover { background: rgba(47, 180, 255, 0.06); color: inherit; }
.portal-kicker {
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
}
.portal h3 {
  margin: 0;
  font-size: 1.7rem;
  line-height: 1.1;
  color: var(--fg-strong);
}
.portal p { margin: 0; color: var(--muted); }
.portal-keycap {
  align-self: flex-start;
  font-family: var(--mono);
  font-weight: 500;
  letter-spacing: 0.08em;
  border: 1.5px solid var(--accent);
  border-radius: 6px;
  padding: 0.25rem 0.55rem;
  background: var(--accent);
  color: var(--ink);
  box-shadow: 0 2px 0 rgba(47, 180, 255, 0.35), inset 0 -2px 0 rgba(0, 0, 0, 0.18);
}
.portal-dim { background: rgba(255, 255, 255, 0.015); }

/* Sticky Academy submenu + Back to Home (subpages) */
.academy-rail {
  position: sticky;
  top: calc(var(--draft-h) + var(--nav-h));
  z-index: 40;
  background: rgba(244, 241, 234, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--hair);
}
.academy-rail-inner {
  display: flex;
  align-items: center;
  gap: 18px;
  min-height: 48px;
}
.academy-menu ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.15rem 1.15rem;
}
.academy-menu a,
.academy-anchors a,
.academy-drawer a {
  color: var(--fg);
  text-decoration: none;
  font-size: 0.88rem;
  letter-spacing: 0.01em;
}
.academy-menu a:hover,
.academy-anchors a:hover,
.academy-drawer a:hover { color: var(--accent); }
.academy-menu a[aria-current="page"],
.academy-drawer a[aria-current="page"] {
  color: var(--fg-strong);
  box-shadow: inset 0 -2px 0 var(--accent);
  font-weight: 600;
}
.academy-anchors {
  display: flex;
  align-items: baseline;
  gap: 14px 18px;
  padding: 0 0 10px;
  flex-wrap: wrap;
}
.academy-anchors ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.2rem 0.9rem;
}
.academy-anchors-label {
  margin: 0;
  font-family: var(--mono);
  font-size: 0.64rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--faint);
}
.academy-menu-toggle {
  display: none;
  margin-left: auto;
  min-height: 40px;
  padding: 0 0.8rem;
  border: 1px solid var(--hair-strong);
  border-radius: var(--radius-btn);
  background: transparent;
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
  color: inherit;
}
.academy-drawer {
  display: none;
  border-top: 1px solid var(--hair);
  padding: 12px 0 18px;
}
.academy-drawer[hidden] { display: none !important; }
.academy-drawer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.academy-drawer .back-home { display: inline-flex; margin-bottom: 12px; }

.back-home {
  color: var(--fg-strong);
  text-decoration: none;
  font-size: 0.9rem;
  letter-spacing: 0.01em;
  white-space: nowrap;
}
.back-home-bar {
  font-weight: 600;
  padding-right: 16px;
  border-right: 1px solid var(--hair);
}
.back-home-bar::before { content: "← "; }
.back-home-row { margin: 0; }
.back-home-row.back-home-top { padding: 28px 0 0; }
.back-home-row.back-home-bottom { padding: 8px 0 56px; }
.back-home-row .back-home.btn { display: inline-flex; }

.sub-hero {
  padding: 48px 0 24px;
}
.sub-hero h1 {
  font-size: clamp(2.6rem, 6vw, 4.6rem);
  line-height: 1.04;
  margin: 0 0 16px;
  color: var(--fg-strong);
}
.sub-hero .lede {
  max-width: 38rem;
  font-size: 1.15rem;
  color: var(--muted);
  margin: 0;
}

/* Ivory content pages */
body.page-sub {
  --bg: #f4f1ea;
  --ink: #161513;
  --fg: #1c1b18;
  --fg-strong: #111110;
  --muted: rgba(22, 21, 19, 0.68);
  --faint: rgba(22, 21, 19, 0.46);
  --hair: rgba(22, 21, 19, 0.12);
  --hair-strong: rgba(22, 21, 19, 0.2);
  --accent: #0a6fa3;
  --accent-soft: rgba(10, 111, 163, 0.1);
  --accent-line: rgba(10, 111, 163, 0.38);
  --link: #0a6fa3;
  background: var(--bg);
  color: var(--fg);
}
body.page-sub a { color: var(--link); }
body.page-sub a:hover { color: #085781; }
body.page-sub .btn-primary,
body.page-sub .nav-cta,
body.page-sub .assignment.live .as-tag,
body.page-sub .portal-keycap {
  background: #161513;
  color: #f4f1ea;
  border-color: #161513;
  box-shadow: none;
}
body.page-sub .btn-primary:hover,
body.page-sub .nav-cta:hover { color: #fff; }
body.page-sub .btn-glass {
  background: transparent;
  color: var(--fg-strong);
  border-color: var(--hair-strong);
}
body.page-sub .site-header,
body.page-sub .nav-bar {
  background: rgba(244, 241, 234, 0.92);
}
body.page-sub .draft-banner {
  background: #161513;
  color: #f4f1ea;
}
body.page-sub .nav-socials a,
body.page-sub .nav-links a { color: var(--fg); }
body.page-home .page-watermark img {
  opacity: 0.07;
  filter: none;
  mix-blend-mode: normal;
}
body.page-sub .page-watermark img {
  opacity: 0.035;
  mix-blend-mode: multiply;
  filter: grayscale(1) contrast(0.85) brightness(1.15);
}
@media (max-width: 960px) {
  body.page-sub .page-watermark img { opacity: 0.032; }
}
@media (max-width: 760px) {
  body.page-sub .page-watermark img { opacity: 0.03; }
}
body.page-sub .guides { opacity: 0.45; }
body.page-sub .page-traces { opacity: 0.35; }
body.page-sub .circuit-field { opacity: 0.12; }
body.page-sub .site-footer {
  background: transparent;
  border-top: 1px solid var(--hair);
  color: var(--fg);
}
body.page-sub .as-tag {
  background: #f4f1ea;
  color: var(--fg-strong);
  box-shadow: 0 2px 0 rgba(22, 21, 19, 0.12), inset 0 -2px 0 rgba(0, 0, 0, 0.06);
}
body.page-sub .certificate {
  /* Keep the existing dark certificate preview (open decision). */
  box-shadow: 0 18px 48px rgba(22, 21, 19, 0.12);
}
body.page-sub .cover-face {
  background:
    radial-gradient(circle at 50% 24%, rgba(10, 111, 163, 0.12), transparent 58%),
    #161513;
  color: #e6edf3;
}
body.page-sub .cover-title { color: #fff; }
body.page-sub .cover-series { color: #7dceff; }
body.page-sub .cover-track { color: rgba(230, 237, 243, 0.72); }
body.page-sub .cover-author { color: rgba(230, 237, 243, 0.9); }
#notes { scroll-margin-top: 8rem; }
.book-landing { scroll-margin-top: 7rem; }
body.page-sub .hash { color: var(--link); }

.roadmap-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 16px;
}
.roadmap-grid .cover-card {
  position: relative;
  inset: auto;
  transform: none !important;
  backface-visibility: visible;
}
.roadmap-grid .cover-face { min-height: 220px; }

.about-lede {
  font-family: var(--serif);
  font-size: 1.35rem;
  line-height: 1.45;
  max-width: 40rem;
  padding-bottom: 8px;
}
.about-lede p { margin: 0 0 1rem; }

html { scroll-padding-top: calc(var(--draft-h) + var(--nav-h) + 64px); }
body.page-sub { scroll-padding-top: calc(var(--draft-h) + var(--nav-h) + 108px); }

@media (max-width: 960px) {
  .portal-grid,
  .join-steps { grid-template-columns: 1fr 1fr; }
  .join-steps li:nth-child(2) { border-right: 0; }
}
@media (max-width: 760px) {
  .academy-menu { display: none; }
  .academy-anchors { display: none; }
  .academy-menu-toggle { display: inline-flex; align-items: center; }
  .academy-rail.is-open .academy-drawer { display: block; }
  .academy-rail.is-open .academy-drawer[hidden] { display: block !important; }
  .portal-grid,
  .join-steps { grid-template-columns: 1fr; }
  .join-steps li { border-right: 0; border-bottom: 1px solid var(--hair); }
  .hero-emblem { width: 88px; height: 88px; }
  .back-home-bar { border-right: 0; padding-right: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .academy-rail { backdrop-filter: none; }
}

.brand img.brand-emblem { height: 40px; width: 40px; }
body.page-home .brand-word { color: var(--fg-strong); }

@keyframes hero-orb-scroll {
  from { --hero-s: 1; --hero-r: 0deg; }
  to { --hero-s: 1.08; --hero-r: 8deg; }
}
@keyframes hero-spread {
  from { --spread: 1; }
  to { --spread: 1.22; }
}

/* Keep the nav CTA readable on ivory pages (do not inherit body text color). */
body.page-sub .nav-links a.nav-cta,
body.page-sub a.nav-cta {
  background: #161513;
  color: #f4f1ea !important;
}
body.page-sub .nav-links a.nav-cta .chev { color: #f4f1ea; }

.hero-emblem {
  width: 176px;
  height: 176px;
  margin: 0 0 28px;
}
.brand img.brand-emblem { height: 48px; width: 48px; }
@media (max-width: 760px) {
  .hero-emblem { width: 120px; height: 120px; }
}

/* —— Landing portal marks (Athletics, Staff) —— */
.portal-mark {
  display: inline-flex;
  align-self: flex-start;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  margin: 2px 0 2px;
}
.portal-mark svg { display: block; }
.portal-athletics .portal-mark { color: var(--accent); }
body.page-home .portal-athletics .portal-mark { color: #2fb4ff; }

/* —— Token Breakers Athletics —— */
body.page-athletics { --ath-orange: #c45a12; --ath-ember: #e8792b; }
body.page-athletics .ath-eyebrow { color: var(--ath-orange); }
.ath-wip {
  display: inline-block;
  margin-left: 0.5em;
  padding: 0.08rem 0.4rem;
  border: 1px solid var(--ath-orange, #c45a12);
  border-radius: var(--radius-btn);
  font-family: var(--mono);
  font-size: 0.62rem;
  letter-spacing: 0.12em;
  color: var(--ath-orange, #c45a12);
  vertical-align: 0.25em;
}
.ath-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 200px;
  gap: 40px 48px;
  align-items: center;
}
.ath-crest {
  width: 200px;
  height: auto;
  justify-self: end;
  filter: drop-shadow(0 10px 24px rgba(22, 21, 19, 0.12));
}
.ath-colors {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem 1rem;
  margin: 22px 0 0;
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--faint);
}
.sw {
  display: inline-block;
  width: 0.7rem;
  height: 0.7rem;
  margin-right: 0.4rem;
  border-radius: 50%;
  vertical-align: -0.1rem;
  box-shadow: inset 0 0 0 1px rgba(22, 21, 19, 0.2);
}
.sw-ink { background: #0e1116; }
.sw-cyan { background: #0a6fa3; }
.sw-orange { background: #c45a12; }
.ath-note { max-width: 44rem; margin-top: 8px; }
.ath-seasons {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 16px;
}
.ath-season {
  border: 1px solid var(--hair);
  padding: 24px 24px 28px;
  min-height: 180px;
  background: rgba(255, 255, 255, 0.35);
}
.ath-season.is-next { box-shadow: inset 4px 0 0 var(--ath-orange, #c45a12); }
.ath-tag {
  display: block;
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ath-orange, #c45a12);
  margin-bottom: 10px;
}
.ath-season h3 { margin: 0 0 8px; font-size: 1.7rem; }
.ath-season p { margin: 0 0 16px; color: var(--muted); }
.ath-pill {
  background: transparent;
  color: var(--ath-orange, #c45a12);
  border: 1px solid rgba(196, 90, 18, 0.45);
}
.ath-drills {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid var(--hair);
  border-left: 1px solid var(--hair);
}
.ath-drills li {
  padding: 24px 22px 28px;
  border-right: 1px solid var(--hair);
  border-bottom: 1px solid var(--hair);
  min-height: 180px;
}
.ath-num {
  display: block;
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  color: var(--ath-orange, #c45a12);
  margin-bottom: 10px;
}
.ath-drills h3 { margin: 0 0 8px; font-size: 1.35rem; }
.ath-drills p { margin: 0; color: var(--muted); }
.ath-board {
  background: #0e1116;
  color: #e6edf3;
  border: 1px solid rgba(47, 180, 255, 0.28);
  border-radius: 8px;
  padding: 22px 24px 18px;
  box-shadow: 0 18px 48px rgba(22, 21, 19, 0.16), inset 0 0 0 1px rgba(232, 121, 43, 0.12);
}
.ath-board-top {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #2fb4ff;
  border-bottom: 1px solid rgba(47, 180, 255, 0.2);
  padding-bottom: 12px;
  margin-bottom: 18px;
}
.ath-board-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  text-align: center;
}
.ath-k {
  display: block;
  font-family: var(--mono);
  font-size: 0.62rem;
  letter-spacing: 0.14em;
  color: rgba(230, 237, 243, 0.5);
  margin-bottom: 8px;
}
.ath-v {
  display: block;
  font-family: var(--display);
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  letter-spacing: 0.04em;
  color: #e6edf3;
}
.ath-v-orange { color: #e8792b; }
.ath-board-note {
  margin: 18px 0 0;
  font-size: 0.85rem;
  color: rgba(230, 237, 243, 0.62);
}
.ath-app .ath-meter {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 8px;
  max-width: 36rem;
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--faint);
}
.ath-meter i {
  flex: 1;
  height: 8px;
  border-radius: 99px;
  background: linear-gradient(90deg, #0a6fa3 0%, #0a6fa3 8%, rgba(196, 90, 18, 0.25) 8%, rgba(196, 90, 18, 0.25) 100%);
  box-shadow: inset 0 0 0 1px var(--hair);
}
.ath-join h2 { margin-bottom: 10px; }
.ath-join .fine { margin-top: 18px; max-width: 40rem; color: var(--muted); }

@media (max-width: 960px) {
  .ath-hero-grid { grid-template-columns: 1fr; gap: 24px; }
  .ath-crest { width: 160px; justify-self: start; }
  .ath-seasons, .ath-drills, .ath-board-grid { grid-template-columns: 1fr 1fr; }
  .ath-drills li:nth-child(3) { grid-column: 1 / -1; }
}
@media (max-width: 640px) {
  .ath-crest { width: 132px; }
  .ath-seasons, .ath-drills, .ath-board-grid { grid-template-columns: 1fr; }
  .ath-drills li:nth-child(3) { grid-column: auto; }
  .ath-season { min-height: 0; }
}

/* —— Meet the staff —— */
.staff-lead {
  display: grid;
  grid-template-columns: minmax(280px, 0.92fr) minmax(0, 1.08fr);
  gap: 28px 40px;
  align-items: center;
  padding-bottom: 12px;
}
.staff-photo {
  margin: 0;
  background: rgba(255, 255, 255, 0.4);
  border: 1px solid var(--hair);
  padding: 12px;
}
.staff-photo img {
  display: block;
  width: 100%;
  height: auto;
}

/* —— Kash founder stage (frameless JARVIS portrait) —— */
.kash-stage {
  --kash-px: 0;
  --kash-py: 0;
  --kash-motion: 1;
  position: relative;
  margin: 0;
  border: 0;
  background: transparent;
  padding: 12px 8px 8px;
  overflow: visible;
  isolation: isolate;
  min-height: 0;
  width: min(100%, 460px);
  justify-self: start;
  container-type: inline-size;
  transform-style: preserve-3d;
}
/* Dark field so the frameless portrait can float on cyan HUD + steam, without a card around him. */
body.page-staff #founder {
  background:
    radial-gradient(ellipse at 18% 42%, rgba(47, 180, 255, 0.16), transparent 58%),
    linear-gradient(180deg, #080b10 0%, #10161c 55%, #080b10 100%);
  color: #e6edf3;
  padding-block: 36px 40px;
}
body.page-staff #founder h2 { color: #fff; }
body.page-staff #founder .staff-bio { color: rgba(230, 237, 243, 0.9); }
body.page-staff #founder .eyebrow { color: #2fb4ff; }
body.page-staff #founder a { color: #7ad3ff; }
body.page-staff #founder a:hover { color: #fff; }

.kash-fx,
.kash-cutout,
.kash-callouts,
.kash-readout {
  pointer-events: none;
}
.kash-fx {
  position: absolute;
  inset: 0;
  z-index: 1;
  transform: translate3d(calc(var(--kash-px) * 6px), calc(var(--kash-py) * 4px), 0);
}
.kash-steam {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  z-index: 1;
}
.kash-hex {
  position: absolute;
  inset: 4% 6% 10%;
  width: auto;
  height: auto;
  z-index: 2;
  opacity: 0.28;
  mix-blend-mode: screen;
  mask-image: radial-gradient(ellipse at 50% 42%, #000 40%, transparent 78%);
  -webkit-mask-image: radial-gradient(ellipse at 50% 42%, #000 40%, transparent 78%);
}
.kash-rings {
  position: absolute;
  left: 8%;
  right: 8%;
  top: 6%;
  width: auto;
  height: auto;
  aspect-ratio: 1;
  margin: 0 auto;
  z-index: 3;
  overflow: visible;
  filter: drop-shadow(0 0 6px rgba(47, 180, 255, 0.55));
}
.kash-ring {
  stroke: rgba(122, 211, 255, 0.72);
  stroke-linecap: round;
  transform-origin: 100px 108px;
  animation: kash-spin 22s linear infinite;
}
.kash-ring-a {
  stroke-width: 0.7;
  stroke-dasharray: 28 14 8 20;
  animation-duration: 18s;
  animation-direction: reverse;
  opacity: 0.85;
}
.kash-ring-b {
  stroke-width: 1.05;
  stroke-dasharray: 52 18 12 26;
  animation-duration: 28s;
  opacity: 0.95;
}
.kash-ring-c {
  stroke-width: 0.6;
  stroke-dasharray: 16 10 6 22 40 14;
  animation-duration: 16s;
  animation-direction: reverse;
  opacity: 0.7;
}
.kash-ring-d {
  stroke-width: 0.85;
  stroke-dasharray: 70 24 10 30;
  animation-duration: 36s;
  opacity: 0.8;
}
@keyframes kash-spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}
.kash-scan {
  position: absolute;
  inset: 0;
  z-index: 4;
  background: repeating-linear-gradient(
    to bottom,
    rgba(122, 211, 255, 0.05) 0 1px,
    transparent 1px 6px
  );
  mix-blend-mode: screen;
  opacity: 0.45;
  mask-image: radial-gradient(ellipse at 50% 46%, #000 48%, transparent 80%);
  -webkit-mask-image: radial-gradient(ellipse at 50% 46%, #000 48%, transparent 80%);
}
.kash-scan::after {
  content: "";
  position: absolute;
  left: 10%;
  right: 10%;
  height: 22%;
  background: linear-gradient(to bottom, transparent, rgba(122, 211, 255, 0.28), transparent);
  animation: kash-scan-sweep 5.2s linear infinite;
}
@keyframes kash-scan-sweep {
  0% { transform: translateY(-140%); }
  100% { transform: translateY(480%); }
}
.kash-cutout {
  position: relative;
  z-index: 3;
  display: block;
  margin: 28px auto 36px;
  max-width: 340px;
  width: 78%;
  aspect-ratio: 1;
  border-radius: 50%;
  overflow: hidden;
  background:
    radial-gradient(circle at 38% 32%, #3a3220 0%, #16130e 64%, #0c0b09 100%);
  box-shadow:
    0 0 0 3px #e8c547,
    0 0 0 7px #7a5b12,
    0 0 0 10px #c9a227,
    0 16px 28px rgba(0, 0, 0, 0.55),
    0 0 22px rgba(201, 162, 39, 0.35);
  transform: translate3d(calc(var(--kash-px) * -10px), calc(var(--kash-py) * -7px), 36px);
  will-change: transform;
}
.kash-cutout picture {
  display: block;
  width: 100%;
  height: 100%;
}
.kash-cutout img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center 46%;
}
.kash-callouts {
  position: absolute;
  inset: 0;
  z-index: 5;
  font-family: var(--mono);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #d8f3ff;
  text-shadow: 0 1px 2px rgba(4, 10, 16, 0.95), 0 0 10px rgba(47, 180, 255, 0.55);
  transform: translate3d(calc(var(--kash-px) * 12px), calc(var(--kash-py) * 8px), 48px);
}
.kash-callout {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 8px;
  max-width: 46%;
}
.kash-callout p {
  margin: 0;
  font-size: clamp(0.52rem, 1.5cqw, 0.7rem);
  line-height: 1.25;
  white-space: nowrap;
  animation: kash-flicker 5.8s step-end infinite;
}
.kash-callout-line {
  display: block;
  height: 1px;
  background: linear-gradient(90deg, rgba(122, 211, 255, 0.15), #7ad3ff);
  box-shadow: 0 0 6px rgba(47, 180, 255, 0.8);
  flex: 0 0 auto;
  transform-origin: left center;
  animation: kash-draw 1.6s ease-out both;
}
.kash-c1 {
  top: 3.5%;
  left: 3%;
  flex-direction: row;
}
.kash-c1 .kash-callout-line { width: 36px; }
.kash-c2 {
  top: 3.5%;
  right: 3%;
  left: auto;
  flex-direction: row-reverse;
}
.kash-c2 .kash-callout-line {
  width: 32px;
  transform-origin: right center;
  background: linear-gradient(270deg, rgba(122, 211, 255, 0.15), #7ad3ff);
}
.kash-c3 {
  top: auto;
  bottom: 8.5%;
  left: 3%;
}
.kash-c3 .kash-callout-line { width: 28px; animation-delay: 0.25s; }
.kash-c3 p { animation-delay: 0.35s; }
.kash-c4 {
  top: auto;
  bottom: 8.5%;
  right: 3%;
  left: auto;
  flex-direction: row-reverse;
}
.kash-c4 .kash-callout-line {
  width: 30px;
  transform-origin: right center;
  background: linear-gradient(270deg, rgba(122, 211, 255, 0.15), #7ad3ff);
  animation-delay: 0.4s;
}
.kash-c4 p { animation-delay: 0.5s; }
@keyframes kash-draw {
  from { transform: scaleX(0); opacity: 0; }
  to { transform: scaleX(1); opacity: 1; }
}
@keyframes kash-flicker {
  0%, 18%, 22%, 61%, 64%, 100% { opacity: 0.94; }
  20% { opacity: 0.18; }
  62.5% { opacity: 0.28; }
}
.kash-c2 p { animation-delay: 0.8s; }
.kash-readout {
  position: absolute;
  left: 6%;
  right: 6%;
  bottom: 4%;
  z-index: 5;
  margin: 0;
  display: flex;
  justify-content: space-between;
  gap: 8px;
  font-family: var(--mono);
  font-size: clamp(0.48rem, 1.4cqw, 0.62rem);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #7ad3ff;
  text-shadow: 0 0 8px rgba(47, 180, 255, 0.45);
}
.kash-readout span {
  animation: kash-flicker 7.2s step-end infinite;
}
.kash-readout span:nth-child(2) { animation-delay: 1.1s; }
.kash-readout span:nth-child(3) { animation-delay: 2.2s; }

.staff-bio {
  font-family: var(--serif);
  font-size: 1.12rem;
  line-height: 1.5;
  max-width: 40rem;
  margin: 0 0 16px;
}
.staff-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-top: 1px solid var(--hair);
  border-left: 1px solid var(--hair);
}
.staff-cards .staff-card {
  padding: 28px 24px 32px;
  border-right: 1px solid var(--hair);
  border-bottom: 1px solid var(--hair);
  min-height: 200px;
}
.staff-card-dim { background: rgba(255, 255, 255, 0.28); }
.staff-icon {
  font-family: var(--mono);
  font-size: 1.4rem;
  color: var(--accent);
  margin-bottom: 12px;
}
.staff-cards h3 { margin: 0 0 8px; }
.staff-cards p { margin: 0; color: var(--muted); }
.staff-mascot {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  gap: 28px 36px;
  align-items: center;
  border: 1px solid var(--hair);
  padding: 24px;
  margin-top: 8px;
  background: #161513;
  color: #e6edf3;
}
.staff-mascot img {
  width: 180px;
  height: auto;
  display: block;
  justify-self: center;
}
.staff-mascot h2 { color: #fff; margin: 0 0 8px; }
.staff-mascot p { margin: 0; color: rgba(230, 237, 243, 0.78); }
.staff-mascot .eyebrow { color: #2fb4ff; }

@media (max-width: 960px) {
  .staff-lead { grid-template-columns: minmax(240px, 0.9fr) minmax(0, 1fr); gap: 24px; }
  .staff-mascot { grid-template-columns: 140px 1fr; }
  .staff-mascot img { width: 140px; }
  .kash-cutout { max-width: 300px; }
  .kash-callout p { white-space: normal; }
}
@media (max-width: 760px) {
  .staff-lead, .staff-cards, .staff-mascot { grid-template-columns: 1fr; }
  .staff-photo { max-width: 280px; }
  .staff-mascot img { width: 160px; }
  .kash-stage { max-width: 420px; margin-inline: auto; }
  .kash-cutout { max-width: 280px; }
}

/* —— Rex photo card (Staff) —— */
.staff-mascot.staff-mascot-rex {
  --rex-px: 0;
  --rex-py: 0;
  grid-template-columns: minmax(280px, 1.28fr) minmax(0, 1fr);
  align-items: start;
  gap: 24px 32px;
  padding: 18px;
  color: #e6edf3;
  border-color: rgba(47, 180, 255, 0.45);
  background:
    linear-gradient(180deg, rgba(12, 18, 26, 0.94), rgba(16, 20, 24, 0.96)),
    repeating-linear-gradient(0deg, rgba(47, 180, 255, 0.055) 0 1px, transparent 1px 22px),
    repeating-linear-gradient(90deg, rgba(47, 180, 255, 0.055) 0 1px, transparent 1px 22px),
    #12151a;
  box-shadow:
    0 0 0 1px rgba(47, 180, 255, 0.22),
    0 18px 48px rgba(4, 10, 18, 0.45),
    0 0 42px rgba(47, 180, 255, 0.12);
  perspective: 1400px;
  transform-style: preserve-3d;
}
.rex-stage {
  position: relative;
  transform-style: preserve-3d;
  transform:
    rotateX(calc(var(--rex-py) * -6deg))
    rotateY(calc(var(--rex-px) * 8deg));
  will-change: transform;
}
.rex-portrait {
  margin: 0;
  position: relative;
  overflow: hidden;
  background: #0d0c0b;
  border: 1px solid rgba(47, 180, 255, 0.4);
  container-type: inline-size;
  container-name: rex-sky;
  transform-style: preserve-3d;
  box-shadow:
    inset 0 0 0 1px rgba(122, 211, 255, 0.12),
    0 0 28px rgba(47, 180, 255, 0.18);
}
.rex-sky {
  position: relative;
  z-index: 1;
}
.rex-cutout {
  position: absolute;
  inset: 0;
  z-index: 4;
  pointer-events: none;
}
.staff-mascot.staff-mascot-rex .rex-sky img,
.staff-mascot.staff-mascot-rex .rex-cutout img {
  width: 100%;
  height: auto;
  display: block;
  justify-self: stretch;
  object-fit: contain;
  transform: translate3d(calc(var(--rex-px) * -6px), calc(var(--rex-py) * -4px), 0) scale(1.04);
  transform-origin: 50% 60%;
  will-change: transform;
}
.rex-rings {
  position: absolute;
  left: 26%;
  top: 14%;
  width: 48%;
  aspect-ratio: 1;
  z-index: 3;
  pointer-events: none;
  transform: translate3d(calc(var(--rex-px) * 4px), calc(var(--rex-py) * 3px), 24px);
  filter: drop-shadow(0 0 6px rgba(47, 180, 255, 0.55));
}
.rex-rings-svg { display: block; width: 100%; height: auto; overflow: visible; }
.rex-ring {
  stroke: rgba(122, 211, 255, 0.78);
  stroke-linecap: round;
  transform-origin: 100px 108px;
  animation: kash-spin 20s linear infinite;
}
.rex-ring-a {
  stroke-width: 0.9;
  stroke-dasharray: 24 12 8 18;
  animation-duration: 16s;
  animation-direction: reverse;
}
.rex-ring-b {
  stroke-width: 1.15;
  stroke-dasharray: 44 16 10 22;
  animation-duration: 26s;
}
.rex-ring-c {
  stroke-width: 0.7;
  stroke-dasharray: 18 10 6 20 36 12;
  animation-duration: 14s;
  animation-direction: reverse;
  opacity: 0.75;
}
.rex-callouts {
  position: absolute;
  inset: 0;
  z-index: 6;
  font-family: var(--mono);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #d7f3ff;
  text-shadow: 0 1px 2px rgba(8, 20, 32, 0.95), 0 0 8px rgba(47, 180, 255, 0.5);
  pointer-events: none;
}
.rex-callout {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 7px;
  max-width: 42%;
}
.rex-callout p {
  margin: 0;
  font-size: clamp(0.5rem, 2.15cqw, 0.68rem);
  line-height: 1.25;
  white-space: nowrap;
  color: #9be2ff;
  animation: kash-flicker 6.4s step-end infinite;
}
.rex-callout-line {
  display: block;
  height: 1px;
  width: 28px;
  flex: 0 0 auto;
  background: linear-gradient(90deg, rgba(122, 211, 255, 0.15), #7ad3ff);
  box-shadow: 0 0 6px rgba(47, 180, 255, 0.8);
  transform-origin: left center;
  animation: kash-draw 1.5s ease-out both;
}
.rex-c1 { top: 10%; left: 3%; }
.rex-c1 p { animation-delay: 0.2s; }
.rex-c2 {
  top: 10%;
  right: 3%;
  left: auto;
  flex-direction: row-reverse;
}
.rex-c2 .rex-callout-line {
  transform-origin: right center;
  background: linear-gradient(270deg, rgba(122, 211, 255, 0.15), #7ad3ff);
  animation-delay: 0.2s;
}
.rex-c2 p { animation-delay: 0.4s; }
.rex-c3 {
  top: 22%;
  left: 3%;
}
.rex-c3 .rex-callout-line { animation-delay: 0.35s; width: 22px; }
.rex-c3 p { animation-delay: 0.55s; }

.rex-body .staff-bio {
  color: rgba(230, 237, 243, 0.86);
  max-width: 36rem;
  margin: 0;
}

/* Floating quote in the open sky */
.rex-quote {
  position: absolute;
  top: 1.2%;
  left: 2%;
  right: 2%;
  margin: 0;
  z-index: 2;
  text-align: center;
  pointer-events: none;
  transform: translate3d(calc(var(--rex-px) * 16px), calc(var(--rex-py) * 9px), 18px);
}
.rex-quote-lines {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.02em;
}
.rex-quote-line {
  display: flex;
  justify-content: center;
  flex-wrap: nowrap;
  font-family: "Bangers", "Inter Tight", sans-serif;
  font-weight: 400;
  font-style: normal;
  line-height: 0.86;
  letter-spacing: 0.08em;
  color: #fff;
  text-transform: uppercase;
  text-shadow:
    0 0 2px rgba(8, 20, 32, 0.95),
    0 2px 0 rgba(8, 20, 32, 0.45),
    0 0 16px rgba(47, 180, 255, 0.75),
    0 0 32px rgba(47, 180, 255, 0.4);
}
.rex-quote-line-1 {
  font-size: clamp(2.6rem, 22cqw, 7.1rem);
}
.rex-quote-line-2 {
  font-size: clamp(1.7rem, 15.8cqw, 5.1rem);
  letter-spacing: 0.12em;
  margin-top: 0.55em;
}
.rex-letter {
  display: inline-block;
  animation: rex-bob 3.6s ease-in-out infinite;
  animation-delay: calc(var(--i) * 0.11s);
  will-change: transform;
}
.rex-letter-gap { margin-left: 0.32em; }
.rex-letter-punct { margin-left: 0.02em; }
.rex-quote-attr {
  position: absolute;
  top: 10px;
  right: 16px;
  z-index: 6;
  margin: 0;
  font-family: var(--mono);
  font-size: clamp(0.58rem, 2.4cqw, 0.76rem);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #7ad3ff;
  text-shadow: 0 1px 2px rgba(8, 20, 32, 0.85), 0 0 10px rgba(47, 180, 255, 0.45);
  pointer-events: none;
}
@keyframes rex-bob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-0.12em); }
}

/* HUD overlay */
.rex-hud {
  position: absolute;
  inset: 0;
  z-index: 5;
  pointer-events: none;
  transform: translate3d(calc(var(--rex-px) * 5px), calc(var(--rex-py) * 4px), 28px);
}
.rex-hud-frame {
  position: absolute;
  inset: 8px;
}
.rex-frame-corner {
  position: absolute;
  width: 22px;
  height: 22px;
  border: 0 solid #7ad3ff;
  filter: drop-shadow(0 0 6px rgba(47, 180, 255, 0.7));
}
.rex-frame-corner-tl { top: 0; left: 0; border-top-width: 2px; border-left-width: 2px; }
.rex-frame-corner-tr { top: 0; right: 0; border-top-width: 2px; border-right-width: 2px; }
.rex-frame-corner-bl { bottom: 0; left: 0; border-bottom-width: 2px; border-left-width: 2px; }
.rex-frame-corner-br { bottom: 0; right: 0; border-bottom-width: 2px; border-right-width: 2px; }

.rex-scan {
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    to bottom,
    rgba(122, 211, 255, 0.07) 0 1px,
    transparent 1px 5px
  );
  mix-blend-mode: screen;
  opacity: 0.55;
}
.rex-scan::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  height: 26%;
  background: linear-gradient(to bottom, transparent, rgba(122, 211, 255, 0.22), transparent);
  animation: rex-scan-sweep 5.8s linear infinite;
}
@keyframes rex-scan-sweep {
  0% { transform: translateY(-120%); }
  100% { transform: translateY(430%); }
}

/* Tracking box around Rex (open-sky standing shot) */
.rex-reticle {
  position: absolute;
  left: 37.6%;
  top: 24.5%;
  width: 24.8%;
  height: 69%;
  z-index: 2;
}
.rex-bracket {
  position: absolute;
  width: 14px;
  height: 14px;
  border: 0 solid #7ad3ff;
  filter: drop-shadow(0 0 5px rgba(47, 180, 255, 0.85));
}
.rex-bracket-tl { top: 0; left: 0; border-top-width: 2px; border-left-width: 2px; }
.rex-bracket-tr { top: 0; right: 0; border-top-width: 2px; border-right-width: 2px; }
.rex-bracket-bl { bottom: 0; left: 0; border-bottom-width: 2px; border-left-width: 2px; }
.rex-bracket-br { bottom: 0; right: 0; border-bottom-width: 2px; border-right-width: 2px; }
.rex-reticle::before {
  content: "";
  position: absolute;
  inset: 0;
  border: 1px solid rgba(122, 211, 255, 0.28);
}
.rex-reticle-tag {
  position: absolute;
  bottom: -1.2em;
  left: 0;
  font-family: var(--mono);
  font-size: clamp(0.48rem, 2cqw, 0.62rem);
  letter-spacing: 0.16em;
  color: #7ad3ff;
  text-shadow: 0 1px 2px rgba(8, 20, 32, 0.85);
}

.rex-hud-readouts {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 32px 12px 10px 12px;
  background: linear-gradient(to top, rgba(6, 14, 22, 0.88) 0%, rgba(6, 14, 22, 0.5) 48%, transparent 100%);
  z-index: 4;
}
.rex-hud-line {
  margin: 0;
  font-family: var(--mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #d7f3ff;
  text-shadow: 0 1px 2px rgba(8, 20, 32, 0.95), 0 0 8px rgba(47, 180, 255, 0.35);
}
.rex-hud-line-top {
  display: flex;
  flex-wrap: wrap;
  gap: 0.15em 0.85em;
  font-size: clamp(0.55rem, 2.45cqw, 0.72rem);
  color: #9be2ff;
}
.rex-hud-line-sub {
  margin-top: 3px;
  font-size: clamp(0.52rem, 2.2cqw, 0.66rem);
  letter-spacing: 0.14em;
  color: #e8f7ff;
}

/* Gallery as floating AR panels */
.rex-gallery {
  list-style: none;
  margin: 22px 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  perspective: 900px;
  transform-style: preserve-3d;
}
.rex-gallery li {
  transform-style: preserve-3d;
  transform:
    rotateX(calc(var(--rex-py) * -3deg))
    rotateY(calc(var(--rex-px) * 5deg + (var(--panel, 0) * 5deg)))
    translate3d(calc(var(--rex-px) * 8px), calc(var(--rex-py) * 5px), 28px);
  will-change: transform;
  animation: rex-panel-float 5.2s ease-in-out infinite;
  animation-delay: calc((var(--panel, 0) + 1) * 0.35s);
}
@keyframes rex-panel-float {
  0%, 100% { translate: 0 0; }
  50% { translate: 0 -5px; }
}
.rex-shot {
  margin: 0;
  position: relative;
  overflow: hidden;
  aspect-ratio: 1 / 1;
  background: #0d0c0b;
  border: 1px solid rgba(122, 211, 255, 0.5);
  box-shadow:
    0 0 0 1px rgba(47, 180, 255, 0.18),
    0 0 18px rgba(47, 180, 255, 0.28),
    0 10px 22px rgba(4, 10, 18, 0.45);
}
.rex-panel-frame {
  position: absolute;
  inset: 5px;
  pointer-events: none;
  box-shadow:
    inset 2px 0 0 0 #7ad3ff,
    inset 0 2px 0 0 #7ad3ff,
    inset -2px 0 0 0 #7ad3ff,
    inset 0 -2px 0 0 #7ad3ff;
  /* Use mask so only corners show: draw full border then cut the midsections */
  --cut: 12px;
  clip-path: polygon(
    0 0, var(--cut) 0, var(--cut) 2px, calc(100% - var(--cut)) 2px, calc(100% - var(--cut)) 0, 100% 0,
    100% var(--cut), calc(100% - 2px) var(--cut), calc(100% - 2px) calc(100% - var(--cut)), 100% calc(100% - var(--cut)),
    100% 100%, calc(100% - var(--cut)) 100%, calc(100% - var(--cut)) calc(100% - 2px), var(--cut) calc(100% - 2px), var(--cut) 100%, 0 100%,
    0 calc(100% - var(--cut)), 2px calc(100% - var(--cut)), 2px var(--cut), 0 var(--cut)
  );
  opacity: 0.9;
  filter: drop-shadow(0 0 4px rgba(47, 180, 255, 0.65));
}
.rex-panel-tag {
  position: absolute;
  left: 6px;
  bottom: 6px;
  font-family: var(--mono);
  font-size: 0.62rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #7ad3ff;
  background: rgba(8, 16, 24, 0.78);
  border: 1px solid rgba(47, 180, 255, 0.4);
  padding: 2px 6px;
  pointer-events: none;
  z-index: 2;
}
.staff-mascot.staff-mascot-rex .rex-shot img,
.staff-mascot.staff-mascot-rex .rex-shot video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  justify-self: stretch;
}
.rex-shot-blanket img { object-position: 50% 28%; }
.rex-shot-sandstone img { object-position: 50% 18%; }
.rex-clip img,
.rex-clip video { object-position: 62% 50%; }
.rex-clip {
  cursor: pointer;
  outline: none;
}
.rex-clip:focus-visible {
  outline: 2px solid #2fb4ff;
  outline-offset: 2px;
}
.rex-clip-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  pointer-events: none;
}
html:not(.review) .rex-clip.is-playing .rex-clip-video { opacity: 1; }
.rex-clip-cue {
  position: absolute;
  top: 6px;
  right: 6px;
  left: auto;
  bottom: auto;
  font-family: var(--mono);
  font-size: 0.62rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #7ad3ff;
  background: rgba(8, 16, 24, 0.78);
  border: 1px solid rgba(47, 180, 255, 0.4);
  padding: 2px 6px;
  pointer-events: none;
  z-index: 2;
}
html:not(.review) .rex-clip.is-playing .rex-clip-cue { display: none; }

/* Motion: live page is dynamic. ?review=1 freezes a static frame.
   prefers-reduced-motion keeps gentle motion (slow rings, slow steam, soft letter float). */
@media (prefers-reduced-motion: reduce) {
  .staff-mascot.staff-mascot-rex .rex-clip-video,
  .rex-clip-cue { display: none; }
  .rex-clip { cursor: default; }
  .rex-letter { animation-duration: 9.5s !important; }
  .rex-gallery li { animation-duration: 12s !important; }
  .rex-scan::after,
  .kash-scan::after { animation-duration: 16s !important; }
  .kash-ring-a, .rex-ring-a { animation-duration: 48s !important; }
  .kash-ring-b, .rex-ring-b { animation-duration: 64s !important; }
  .kash-ring-c, .rex-ring-c { animation-duration: 42s !important; }
  .kash-ring-d { animation-duration: 72s !important; }
  .kash-callout p,
  .kash-readout span,
  .rex-callout p { animation: none !important; opacity: 0.94; }
  .kash-callout-line,
  .rex-callout-line { animation: none !important; transform: scaleX(1); opacity: 1; }
  .rex-stage,
  .staff-mascot.staff-mascot-rex .rex-sky img,
  .staff-mascot.staff-mascot-rex .rex-cutout img,
  .rex-quote,
  .rex-hud,
  .rex-rings,
  .rex-gallery li,
  .kash-fx,
  .kash-cutout,
  .kash-callouts {
    /* keep CSS animation; drop pointer-tilt parallax */
    --rex-px: 0 !important;
    --rex-py: 0 !important;
    --kash-px: 0 !important;
    --kash-py: 0 !important;
  }
}
html.reduce-motion .rex-letter { animation-duration: 9.5s !important; }
html.reduce-motion .rex-gallery li { animation-duration: 12s !important; }
html.reduce-motion .rex-scan::after,
html.reduce-motion .kash-scan::after { animation-duration: 16s !important; }
html.reduce-motion .kash-ring-a, html.reduce-motion .rex-ring-a { animation-duration: 48s !important; }
html.reduce-motion .kash-ring-b, html.reduce-motion .rex-ring-b { animation-duration: 64s !important; }
html.reduce-motion .kash-ring-c, html.reduce-motion .rex-ring-c { animation-duration: 42s !important; }
html.reduce-motion .kash-ring-d { animation-duration: 72s !important; }
html.reduce-motion .kash-callout p,
html.reduce-motion .kash-readout span,
html.reduce-motion .rex-callout p { animation: none !important; opacity: 0.94; }
html.reduce-motion .kash-callout-line,
html.reduce-motion .rex-callout-line { animation: none !important; transform: scaleX(1); opacity: 1; }

/* ?review=1: fully static, including a frozen steam frame (drawn in JS). */
html.review .staff-mascot.staff-mascot-rex .rex-clip-video,
html.review .rex-clip-cue { display: none; }
html.review .rex-clip { cursor: default; }
html.review .rex-letter,
html.review .rex-gallery li,
html.review .rex-scan::after,
html.review .kash-scan::after,
html.review .kash-ring,
html.review .rex-ring,
html.review .kash-callout p,
html.review .kash-readout span,
html.review .rex-callout p,
html.review .kash-callout-line,
html.review .rex-callout-line {
  animation: none !important;
}
html.review .kash-callout-line,
html.review .rex-callout-line {
  transform: scaleX(1);
  opacity: 1;
}
html.review .kash-callout p,
html.review .kash-readout span,
html.review .rex-callout p { opacity: 0.94; }
html.review .rex-stage,
html.review .staff-mascot.staff-mascot-rex .rex-sky img,
html.review .staff-mascot.staff-mascot-rex .rex-cutout img,
html.review .rex-quote,
html.review .rex-hud,
html.review .rex-rings,
html.review .rex-gallery li,
html.review .kash-fx,
html.review .kash-cutout,
html.review .kash-callouts {
  transform: none !important;
  will-change: auto;
}

@media (max-width: 960px) {
  .staff-mascot.staff-mascot-rex { grid-template-columns: 1fr; }
  .staff-mascot.staff-mascot-rex .rex-portrait img,
  .staff-mascot.staff-mascot-rex .rex-shot img { width: 100%; }
  .rex-quote-line-1 { font-size: clamp(2.2rem, 20cqw, 5.4rem); }
  .rex-quote-line-2 { font-size: clamp(1.4rem, 13.8cqw, 3.6rem); }
}
@media (max-width: 760px) {
  .staff-mascot.staff-mascot-rex { grid-template-columns: 1fr; }
  .staff-mascot.staff-mascot-rex .rex-portrait img,
  .staff-mascot.staff-mascot-rex .rex-shot img { width: 100%; }
  .kash-c1, .kash-c3 { max-width: 48%; }
  .kash-c2, .kash-c4 { max-width: 48%; }
}
@media (max-width: 430px) {
  .rex-quote { top: 1%; left: 1.5%; right: 1.5%; }
  .rex-quote-line-1 { font-size: clamp(1.85rem, 19.5cqw, 2.7rem); }
  .rex-quote-line-2 { font-size: clamp(1.15rem, 13.2cqw, 1.85rem); margin-top: 0.35em; }
  .rex-quote-attr { top: 8px; right: 10px; }
  .rex-hud-readouts { padding: 22px 10px 8px; }
  .rex-reticle { width: 28%; left: 36%; }
  .rex-callout p { font-size: 0.48rem; letter-spacing: 0.06em; }
  .rex-c1, .rex-c3 { left: 2%; max-width: 52%; }
  .rex-c2 { right: 2%; max-width: 48%; }
  .rex-c3 { top: 20%; }
  .kash-callout p { font-size: 0.5rem; letter-spacing: 0.06em; white-space: normal; }
  .kash-c1, .kash-c3 { left: 2%; max-width: 50%; }
  .kash-c2, .kash-c4 { right: 2%; max-width: 50%; }
  .kash-readout { gap: 4px; font-size: 0.46rem; }
  .kash-stage { padding: 8px 4px 6px; }
}


/* —— Individual Library book landing pages —— */
.book-landing {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  gap: 28px 36px;
  align-items: start;
}
.book-landing-cover {
  position: relative;
  inset: auto;
  transform: none !important;
  width: 180px;
  max-width: 100%;
}
.book-landing-cover .cover-face {
  min-height: 268px;
  overflow: hidden;
}
.book-landing-cover .cover-stamp {
  position: static;
  transform: none;
  margin-top: 0.7rem;
  align-self: flex-start;
}
.book-landing-copy h1 {
  font-family: var(--display);
  font-weight: 300;
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  letter-spacing: -0.03em;
  line-height: 1.08;
  margin: 0 0 0.4rem;
  color: var(--fg-strong);
}
.book-landing-by {
  margin: 0 0 1rem;
  color: var(--muted);
  font-size: 0.95rem;
}
.book-landing-sale {
  margin: 0.85rem 0 0;
  color: var(--muted);
  font-size: 0.92rem;
}
.coming-wip { color: #c9a227; }
body.page-book .coming-wip { color: #8a7010; }

.wip-notes {
  border: 1px solid var(--hair);
  border-radius: var(--radius-media);
  padding: 22px 24px 20px;
  background: rgba(8, 10, 14, 0.04);
  box-shadow: 0 0 0 1px rgba(47, 180, 255, 0.04);
}
body.page-sub .wip-notes {
  background: rgba(22, 21, 19, 0.04);
}
.wip-notes .section-head { margin-bottom: 12px; }
.wip-dl {
  margin: 0;
  display: grid;
  gap: 14px;
}
.wip-dl > div {
  display: grid;
  grid-template-columns: 9.5rem minmax(0, 1fr);
  gap: 8px 16px;
  padding-top: 12px;
  border-top: 1px solid var(--hair);
}
.wip-dl > div:first-child { border-top: 0; padding-top: 0; }
.wip-dl dt {
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0.15rem 0 0;
}
.wip-dl dd {
  margin: 0;
  color: var(--fg-strong);
  font-size: 1rem;
  line-height: 1.45;
}
.book-pager {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-top: 28px;
  flex-wrap: wrap;
}
.book-pager a {
  max-width: 48%;
  overflow-wrap: anywhere;
}
.book-pager span { flex: 1; }

@media (max-width: 760px) {
  .book-landing {
    grid-template-columns: 1fr;
    justify-items: center;
    text-align: left;
  }
  .book-landing-cover { width: min(220px, 70vw); }
  .book-landing-copy { width: 100%; }
  .wip-notes { padding: 16px 14px 14px; }
  .wip-dl > div { grid-template-columns: 1fr; gap: 4px; }
  .book-pager a { max-width: 100%; }
}
