:root {
  color-scheme: dark;
  --bg: #080a0d;
  --surface: #10141a;
  --surface-raised: #151a21;
  --surface-soft: #1a2028;
  --ink: #f2f4ef;
  --muted: #a4acb6;
  --faint: #6d7782;
  --line: rgba(255, 255, 255, .1);
  --line-strong: rgba(255, 255, 255, .17);
  --accent: #c8f169;
  --accent-ink: #172008;
  --accent-soft: rgba(200, 241, 105, .1);
  --coral: #ff9a78;
  --sky: #91d7ff;
  --sans: Inter, "SF Pro Display", "PingFang SC", "Microsoft YaHei", "Noto Sans CJK SC", system-ui, sans-serif;
  --mono: "SFMono-Regular", "Cascadia Code", Consolas, "Liberation Mono", monospace;
  --radius: 24px;
  --ease: cubic-bezier(.22, 1, .36, 1);
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { background: var(--bg); scroll-behavior: smooth; }
body {
  min-height: 100vh;
  min-height: 100svh;
  margin: 0;
  display: grid;
  grid-template-rows: auto 2px minmax(0, 1fr) auto;
  overflow-x: hidden;
  font-family: var(--sans);
  font-synthesis: none;
  color: var(--ink);
  background:
    radial-gradient(circle at 12% -10%, rgba(145, 215, 255, .06), transparent 30%),
    radial-gradient(circle at 92% 110%, rgba(200, 241, 105, .045), transparent 32%),
    var(--bg);
  -webkit-font-smoothing: antialiased;
}
body::before {
  content: "";
  position: fixed;
  z-index: 0;
  inset: 0;
  pointer-events: none;
  opacity: .18;
  background-image:
    linear-gradient(rgba(255, 255, 255, .022) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, .022) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: linear-gradient(to bottom, black, transparent 82%);
}
button, input { font: inherit; }
button { cursor: pointer; -webkit-tap-highlight-color: transparent; }
button:disabled { cursor: default; }
a { color: inherit; }
button, a { touch-action: manipulation; }
button:focus-visible, a:focus-visible, input:focus-visible, canvas:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}
::selection { color: var(--accent-ink); background: var(--accent); }
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { border-radius: 10px; background: #333c46; }

.ambient {
  position: fixed;
  z-index: 0;
  width: 360px;
  aspect-ratio: 1;
  border-radius: 50%;
  filter: blur(120px);
  opacity: .06;
  pointer-events: none;
}
.ambient-one { top: 12%; left: -240px; background: var(--sky); }
.ambient-two { right: -220px; bottom: 0; background: var(--accent); }

.deck-header, .deck-footer {
  position: relative;
  z-index: 5;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  padding-inline: clamp(18px, 3vw, 48px);
}
.deck-header {
  min-height: 72px;
  border-bottom: 1px solid rgba(255, 255, 255, .045);
  background: rgba(8, 10, 13, .76);
  backdrop-filter: blur(18px);
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--ink);
  text-decoration: none;
}
.brand-mark {
  display: block;
  flex: 0 0 auto;
  width: 34px;
  height: 34px;
  border-radius: 11px;
  box-shadow: 0 5px 18px rgba(0, 0, 0, .24), inset 0 1px 0 rgba(255, 255, 255, .04);
  transition: transform .25s var(--ease), box-shadow .25s ease;
}
.brand:hover .brand-mark {
  transform: translateY(-1px);
  box-shadow: 0 7px 22px rgba(0, 0, 0, .3), 0 0 0 1px rgba(200, 241, 105, .08);
}
.brand-mark svg { display: block; width: 100%; height: 100%; }
.brand-copy { display: grid; gap: 5px; }
.brand-copy strong { font-size: 13px; line-height: 1; letter-spacing: .23em; font-weight: 640; }
.brand-copy small { color: #818c96; font-family: var(--mono); font-size: 8.5px; line-height: 1; letter-spacing: .25em; font-weight: 500; }
.header-context {
  display: flex;
  align-items: center;
  gap: 9px;
  color: var(--faint);
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: .13em;
}
.header-context span {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 12px rgba(200, 241, 105, .75);
}
.tools, .controls, .footer-actions { display: flex; align-items: center; }
.tools { gap: 6px; }
.tools button, .controls button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 38px;
  border: 1px solid transparent;
  border-radius: 10px;
  padding: 8px 11px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 620;
  white-space: nowrap;
  background: transparent;
  transition: color .2s ease, border-color .2s ease, background .2s ease, transform .2s ease;
}
.tools button svg, .controls button svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.tools button:hover { color: var(--ink); border-color: var(--line); background: rgba(255, 255, 255, .045); }
.tools button:active, .controls button:active:not(:disabled) { transform: scale(.96); }
.progress { position: relative; z-index: 6; overflow: hidden; background: rgba(255, 255, 255, .04); }
.progress span {
  display: block;
  width: 0;
  height: 100%;
  background: linear-gradient(90deg, #78963d, var(--accent), #e5ffad);
  box-shadow: 0 0 16px rgba(200, 241, 105, .45);
  transition: width .55s var(--ease);
}

.deck {
  position: relative;
  z-index: 1;
  display: flex;
  width: min(100%, 1580px);
  min-width: 0;
  margin-inline: auto;
  padding: clamp(16px, 2.2vw, 32px) clamp(14px, 3vw, 46px) clamp(12px, 1.6vw, 24px);
}
.deck:focus { outline: none; }
.slide {
  --pointer-x: 80%;
  --pointer-y: 0%;
  position: relative;
  isolation: isolate;
  align-self: stretch;
  display: flex;
  flex-direction: column;
  justify-content: center;
  width: 100%;
  min-width: 0;
  min-height: min(720px, calc(100svh - 188px));
  overflow: hidden;
  padding: clamp(30px, 4vw, 64px);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, .035), transparent 38%),
    linear-gradient(150deg, #12171d 0%, #0e1217 58%, #0c1015 100%);
  box-shadow: 0 30px 80px rgba(0, 0, 0, .26), inset 0 1px 0 rgba(255, 255, 255, .035);
}
.slide::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(540px circle at var(--pointer-x) var(--pointer-y), rgba(145, 215, 255, .055), transparent 66%);
}
.slide::after {
  content: attr(data-number);
  position: absolute;
  z-index: -1;
  right: clamp(18px, 3vw, 48px);
  bottom: -.06em;
  color: rgba(255, 255, 255, .022);
  font-family: var(--mono);
  font-size: clamp(130px, 19vw, 280px);
  font-weight: 800;
  line-height: .8;
  letter-spacing: -.1em;
  pointer-events: none;
}
.slide > * { position: relative; z-index: 1; }
.slide.is-forward { animation: enter-forward .52s var(--ease) both; }
.slide.is-backward { animation: enter-backward .52s var(--ease) both; }
@keyframes enter-forward {
  from { opacity: 0; transform: translate3d(24px, 0, 0) scale(.992); }
  to { opacity: 1; transform: translate3d(0, 0, 0) scale(1); }
}
@keyframes enter-backward {
  from { opacity: 0; transform: translate3d(-24px, 0, 0) scale(.992); }
  to { opacity: 1; transform: translate3d(0, 0, 0) scale(1); }
}
.chapter {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 17px;
  color: var(--accent);
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .16em;
  font-weight: 680;
  text-transform: uppercase;
}
.chapter::before { content: ""; width: 23px; height: 1px; background: currentColor; }
.chapter span {
  padding-left: 12px;
  border-left: 1px solid var(--line-strong);
  color: var(--faint);
  letter-spacing: .08em;
}
.slide h2 {
  max-width: 1040px;
  margin: 0;
  color: var(--ink);
  font-size: clamp(34px, 4.15vw, 62px);
  font-weight: 710;
  line-height: 1.12;
  letter-spacing: -.047em;
  text-wrap: balance;
}
.lead {
  max-width: 850px;
  margin: 16px 0 0;
  color: var(--muted);
  font-size: clamp(15px, 1.55vw, 21px);
  font-weight: 400;
  line-height: 1.62;
  letter-spacing: .005em;
}
.slide-split {
  display: grid;
  grid-template-columns: minmax(0, .82fr) minmax(0, 1.28fr);
  gap: clamp(24px, 3.4vw, 54px);
  align-items: start;
  margin-top: clamp(24px, 3.8vh, 40px);
}
.slide-body { margin-top: clamp(24px, 4vh, 42px); }
.slide-body .fact-list { max-width: 1160px; }
.slide-body.has-detail {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(20px, 3vw, 42px);
  align-items: start;
}
.fact-list { margin: 0; counter-reset: facts; }
.fact {
  display: grid;
  grid-template-columns: 36px minmax(145px, .62fr) minmax(0, 1.38fr);
  gap: 16px;
  align-items: start;
  padding: 17px 12px 17px 0;
  border-top: 1px solid var(--line);
  transition: background .2s ease, padding-left .25s var(--ease);
}
.fact:last-child { border-bottom: 1px solid var(--line); }
.fact:hover { padding-left: 10px; background: linear-gradient(90deg, rgba(200, 241, 105, .045), transparent 76%); }
.fact-index {
  padding-top: 4px;
  color: var(--faint);
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: .05em;
}
.fact dt, .fact dd { margin: 0; overflow-wrap: anywhere; font-size: clamp(14px, 1.36vw, 18px); line-height: 1.55; }
.fact dt { color: #e8ece6; font-weight: 650; }
.fact dd { color: var(--muted); }
.slide-read .fact, .has-detail .fact { grid-template-columns: 30px minmax(0, 1fr); gap: 3px 12px; padding-block: 13px; }
.slide-read .fact dt, .has-detail .fact dt { grid-column: 2; font-size: clamp(14px, 1.26vw, 17px); }
.slide-read .fact dd, .has-detail .fact dd { grid-column: 2; font-size: clamp(12px, 1.09vw, 15px); }
.slide-read .fact-index, .has-detail .fact-index { grid-row: 1 / span 2; }
.slide-visual, .slide-read { min-width: 0; }
.slide-read .code, .slide-read .table-scroll { margin-top: 16px; }

.slide-pipeline .fact-list, .slide-prototype .fact-list {
  max-width: none;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 13px;
}
.slide-pipeline .fact, .slide-prototype .fact {
  display: flex;
  flex-direction: column;
  gap: 9px;
  min-height: 150px;
  padding: 19px;
  border: 1px solid var(--line);
  border-radius: 15px;
  background: rgba(255, 255, 255, .026);
}
.slide-pipeline .fact:last-child, .slide-prototype .fact:last-child { border-bottom: 1px solid var(--line); }
.slide-pipeline .fact:hover, .slide-prototype .fact:hover {
  padding-left: 19px;
  border-color: rgba(200, 241, 105, .3);
  background: var(--accent-soft);
  transform: translateY(-2px);
}
.slide-pipeline .fact dt, .slide-prototype .fact dt { margin-top: 3px; }
.slide-pipeline .fact dd, .slide-prototype .fact dd { font-size: clamp(12px, 1.15vw, 15px); }
.slide-pipeline .fact-index, .slide-prototype .fact-index { color: var(--accent); }
.slide-prototype {
  background:
    radial-gradient(circle at 90% 10%, rgba(200, 241, 105, .1), transparent 34%),
    linear-gradient(145deg, #151c18, #0e1312 62%, #0b100f);
}
.slide-recap { background: radial-gradient(circle at 100% 100%, rgba(255, 154, 120, .08), transparent 34%), linear-gradient(145deg, #15171b, #0e1217); }

.sources {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 18px;
  list-style: none;
  padding: 0;
  margin: 25px 0 0;
  color: var(--faint);
  font-family: var(--mono);
  font-size: 10px;
  line-height: 1.5;
}
.sources::before { content: "SOURCES"; color: #8c96a1; letter-spacing: .13em; }
.sources a { text-decoration: none; border-bottom: 1px solid transparent; overflow-wrap: anywhere; transition: color .2s, border-color .2s; }
.sources a::after { content: " ↗"; color: var(--faint); }
.sources a:hover { color: var(--accent); border-color: rgba(200, 241, 105, .4); }

.cover {
  min-height: min(720px, calc(100svh - 188px));
  color: var(--ink);
  background: #090d11;
  border-color: rgba(255, 255, 255, .14);
}
.cover::before {
  z-index: 1;
  background:
    linear-gradient(90deg, rgba(8, 12, 16, .99) 0%, rgba(8, 12, 16, .96) 32%, rgba(8, 12, 16, .68) 56%, rgba(8, 12, 16, .08) 92%),
    linear-gradient(0deg, rgba(8, 12, 16, .64), transparent 45%);
}
.cover::after { content: "01"; color: rgba(255, 255, 255, .025); }
.cover-art {
  position: absolute;
  z-index: 0;
  inset: -3%;
  background: url("media/ref-5.jpg") right center / auto 100% no-repeat;
  filter: saturate(.78) contrast(1.12) brightness(.82);
  transform: translate3d(var(--parallax-x, 0), var(--parallax-y, 0), 0) scale(1.04);
  transition: transform .8s var(--ease);
}
.cover-art::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, transparent 50%, rgba(200, 241, 105, .06));
  mix-blend-mode: screen;
}
.cover-copy { max-width: 750px; width: 67%; padding-block: 8px; }
.cover-label {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 25px;
  color: var(--accent);
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 650;
  letter-spacing: .18em;
}
.cover-label span { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 14px rgba(200, 241, 105, .65); }
.cover h1 {
  display: grid;
  margin: 0;
  font-size: clamp(55px, 7.2vw, 108px);
  font-weight: 790;
  letter-spacing: -.072em;
  line-height: .84;
}
.cover-title-outline { color: rgba(242, 244, 239, .12); -webkit-text-stroke: 1px rgba(242, 244, 239, .68); }
.cover-title-cn { margin: 20px 0 0; color: #e3e8e0; font-size: clamp(20px, 2.2vw, 31px); font-weight: 570; letter-spacing: .12em; }
.cover-lead { max-width: 580px; margin: 19px 0 0; color: #b8c0c8; font-size: clamp(15px, 1.55vw, 21px); line-height: 1.6; }
.cover-tags { display: flex; flex-wrap: wrap; gap: 7px; list-style: none; padding: 0; margin: 21px 0 0; }
.cover-tags li {
  padding: 6px 9px;
  border: 1px solid rgba(255, 255, 255, .13);
  border-radius: 6px;
  color: #9ca6b0;
  background: rgba(10, 14, 18, .48);
  backdrop-filter: blur(10px);
  font-family: var(--mono);
  font-size: 9px;
  letter-spacing: .09em;
}
.cover-author {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 20px 0 0;
  color: #74806f;
  font-family: var(--mono);
  font-size: 9px;
  font-weight: 500;
  letter-spacing: .16em;
}
.cover-author::before { content: ""; width: 20px; height: 1px; background: rgba(200, 241, 105, .42); }
.cover-author strong { color: #d7e2cd; font-size: 10px; font-weight: 620; letter-spacing: .2em; }
.start {
  display: inline-flex;
  align-items: center;
  gap: 19px;
  min-height: 52px;
  margin-top: 26px;
  padding: 6px 7px 6px 19px;
  border: 1px solid rgba(227, 255, 161, .72);
  border-radius: 13px;
  color: var(--accent-ink);
  background: linear-gradient(135deg, #dcff8f 0%, #c8f169 48%, #b8df58 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .52), inset 0 -1px 0 rgba(68, 89, 21, .12), 0 10px 30px rgba(200, 241, 105, .12);
  font-size: 13px;
  font-weight: 650;
  letter-spacing: .015em;
  transition: transform .25s var(--ease), box-shadow .25s ease, filter .25s ease;
}
.start-label { padding-top: 1px; }
.start-icon {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 1px solid rgba(255, 255, 255, .16);
  border-radius: 11px;
  background:
    radial-gradient(circle at 30% 18%, rgba(255, 255, 255, .14), transparent 32%),
    linear-gradient(145deg, #34451b 0%, #1c290d 46%, #111b07 100%);
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, .18), inset 0 -2px 3px rgba(0, 0, 0, .38), 0 3px 6px rgba(31, 42, 9, .28);
  transition: transform .3s var(--ease), border-color .25s ease, box-shadow .25s ease;
}
.start-icon svg {
  width: 32px;
  height: 32px;
  overflow: visible;
  filter: drop-shadow(0 2px 1px rgba(0, 0, 0, .32));
  transform-origin: 50% 50%;
  transition: transform .3s var(--ease), filter .3s ease;
}
.start:hover {
  transform: translateY(-1px);
  filter: brightness(1.035);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .58), 0 14px 36px rgba(200, 241, 105, .19);
}
.start:hover .start-icon {
  border-color: rgba(255, 255, 255, .25);
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, .22), inset 0 -2px 3px rgba(0, 0, 0, .4), 0 4px 8px rgba(31, 42, 9, .34);
}
.start:hover .start-icon svg { transform: translate3d(1.5px, -1px, 0) scale(1.03); filter: drop-shadow(0 3px 1.5px rgba(0, 0, 0, .38)); }
.start:active { transform: translateY(0) scale(.985); }
.art-caption {
  position: absolute;
  right: 20px;
  bottom: 18px;
  margin: 0;
  padding: 7px 9px;
  border: 1px solid rgba(255, 255, 255, .1);
  border-radius: 6px;
  color: #b4bdc5;
  background: rgba(7, 10, 13, .68);
  backdrop-filter: blur(10px);
  font-family: var(--mono);
  font-size: 9px;
  letter-spacing: .05em;
}

figure { margin: 0; }
figcaption { margin-top: 11px; color: var(--faint); font-size: clamp(10px, 1vw, 13px); line-height: 1.55; }
.asset-grid { display: grid; gap: 9px; }
.references .asset-grid { grid-template-columns: repeat(6, minmax(0, 1fr)); }
.references .asset-grid > div { grid-column: span 2; }
.references .asset-grid > div:nth-child(4) { grid-column: 2 / span 2; }
.textures .asset-grid { grid-template-columns: repeat(6, minmax(0, 1fr)); }
.asset-grid > div {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface-soft);
}
.asset-grid img { display: block; width: 100%; object-fit: cover; aspect-ratio: 16 / 9; transition: transform .55s var(--ease), filter .3s ease; }
.asset-grid > div:hover img { transform: scale(1.045); filter: brightness(1.08); }
.textures .asset-grid img { aspect-ratio: 1; }
.asset-grid span {
  position: absolute;
  right: 6px;
  bottom: 6px;
  padding: 4px 6px;
  border: 1px solid rgba(255, 255, 255, .1);
  border-radius: 4px;
  color: #e3e8e3;
  background: rgba(7, 10, 13, .72);
  backdrop-filter: blur(8px);
  font-size: clamp(9px, .85vw, 11px);
}
.single-visual { padding: 12px; border: 1px solid var(--line); border-radius: 16px; background: rgba(255, 255, 255, .022); }
.single-visual img { display: block; width: 100%; max-height: 420px; border-radius: 9px; object-fit: contain; }
.single-visual figcaption { padding-inline: 3px; }

.table-scroll { overflow: auto; border: 1px solid var(--line); border-radius: 13px; }
table { width: 100%; border-collapse: collapse; font-size: clamp(12px, 1.15vw, 15px); line-height: 1.5; }
th, td { text-align: left; vertical-align: top; padding: 12px 13px; border-bottom: 1px solid var(--line); }
thead th { color: #dfe5dd; font-weight: 650; background: rgba(255, 255, 255, .05); }
tbody th { color: #dfe5dd; font-weight: 620; }
tbody td { color: var(--muted); }
tbody tr:last-child > * { border-bottom: 0; }
.code {
  position: relative;
  margin: 0;
  padding: 22px;
  overflow: auto;
  border: 1px solid rgba(145, 215, 255, .12);
  border-radius: 14px;
  background: #090e13;
  color: #cfe0d5;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .025);
  font-size: clamp(11px, 1.1vw, 14px);
  line-height: 1.75;
  white-space: pre-wrap;
}
.code code { font-family: var(--mono); }

.model-lab { display: grid; gap: 10px; }
.model-toolbar, .map-toolbar, .chapter-jumps, .cue-points { display: flex; flex-wrap: wrap; gap: 6px; }
.model-button, .map-toolbar button, .chapter-jumps button, .cue-points button {
  min-height: 31px;
  padding: 6px 10px;
  border: 1px solid var(--line);
  border-radius: 7px;
  color: var(--muted);
  background: rgba(255, 255, 255, .035);
  font-size: clamp(10px, .98vw, 12px);
  font-weight: 620;
  transition: color .2s, border-color .2s, background .2s, transform .2s;
}
.model-button:hover:not(:disabled), .map-toolbar button:hover, .chapter-jumps button:hover, .cue-points button:hover {
  color: var(--ink);
  border-color: var(--line-strong);
  background: rgba(255, 255, 255, .075);
}
.model-button[aria-pressed="true"], .map-toolbar button[aria-pressed="true"], .chapter-jumps button[aria-pressed="true"] {
  border-color: rgba(200, 241, 105, .5);
  color: var(--accent);
  background: var(--accent-soft);
}
.model-button:disabled { opacity: .5; }
.model-stage {
  position: relative;
  min-height: 240px;
  height: clamp(240px, 34vh, 380px);
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: radial-gradient(circle at 50% 38%, #1a2528, #0a0f13 72%);
}
.model-stage-message {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 14px;
  color: var(--muted);
  text-align: center;
  pointer-events: none;
}
.model-view { display: block; width: 100%; height: 100%; touch-action: none; cursor: grab; }
.model-view:active { cursor: grabbing; }
.model-meta, .model-status, .model-label, .status-copy { margin: 0; color: var(--faint); font-size: clamp(10px, .98vw, 12px); line-height: 1.5; overflow-wrap: anywhere; }
.model-meta { color: #dce3dc; font-family: var(--mono); font-weight: 600; }

.material-lab { min-width: 0; }
.map-frame {
  height: clamp(200px, 35vh, 360px);
  margin-top: 10px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #090d11;
}
.map-frame img { display: block; width: 100%; height: 100%; object-fit: contain; }
.story-lab { padding: clamp(13px, 1.55vw, 21px); border: 1px solid var(--line); border-radius: 16px; background: rgba(255, 255, 255, .022); }
.timeline-line {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 8px;
  margin-top: 15px;
  color: #cbd2cc;
  font-size: 11px;
  font-weight: 650;
}
.timeline-line output { color: var(--accent); font-family: var(--mono); }
.timeline-line input { grid-column: 1 / -1; width: 100%; height: 3px; margin: 6px 0 3px; accent-color: var(--accent); cursor: ew-resize; }
.cue-points { margin-top: 10px; }
.story-stats {
  display: grid;
  grid-template-columns: 1.2fr 1fr .83fr .8fr;
  gap: 8px;
  margin: 14px 0;
  padding: 12px 0;
  border-block: 1px solid var(--line);
}
.story-stats dt { color: var(--faint); font-size: 10px; }
.story-stats dd { margin: 4px 0 0; color: #e3e9e2; font-family: var(--mono); font-size: clamp(11px, 1.02vw, 14px); font-weight: 650; }
.flight-figure figcaption { margin: 0 0 5px; color: #cbd2cc; font-size: 11px; font-weight: 620; }
#flight-chart { display: block; width: 100%; height: auto; }
.flight-status { min-height: 18px; margin: 6px 0 0; color: var(--faint); font-family: var(--mono); font-size: 10px; }

.deck-footer { min-height: 72px; }
#slide-position { display: flex; align-items: baseline; gap: 7px; min-width: 160px; margin: 0; font-family: var(--mono); }
.position-current { color: var(--ink); font-size: 18px; font-weight: 650; }
.position-total { color: var(--faint); font-size: 11px; }
.position-chapter { margin-left: 7px; color: var(--faint); font-family: var(--sans); font-size: 10px; letter-spacing: .1em; }
.footer-signature { color: #535d67; font-family: var(--mono); font-size: 9px; letter-spacing: .13em; }
.footer-signature span { margin-inline: 8px; color: #71803f; }
.footer-actions { gap: 0; }
.controls { flex-shrink: 0; gap: 7px; }
.controls button { min-width: 40px; border-color: var(--line); color: #b1bac3; background: rgba(255, 255, 255, .025); }
.controls button:hover:not(:disabled) { color: var(--ink); border-color: var(--line-strong); background: rgba(255, 255, 255, .07); }
.controls button#next-button { padding-inline: 15px; border-color: var(--accent); color: var(--accent-ink); background: var(--accent); }
.controls button#next-button:hover:not(:disabled) { color: var(--accent-ink); background: #dcff91; }
.controls button:disabled { opacity: .26; }

.slide-rail {
  position: fixed;
  z-index: 8;
  top: 50%;
  right: 13px;
  display: grid;
  gap: 2px;
  transform: translateY(-50%);
}
.slide-rail button {
  position: relative;
  display: grid;
  place-items: center;
  width: 27px;
  height: 24px;
  padding: 0;
  border: 0;
  color: transparent;
  background: transparent;
  font-family: var(--mono);
  font-size: 8px;
}
.slide-rail button::before { content: ""; width: 2px; height: 8px; border-radius: 4px; background: #3d454e; transition: height .25s var(--ease), background .25s; }
.slide-rail button:hover::before { height: 15px; background: #89939d; }
.slide-rail button[aria-current="page"] { color: var(--accent); }
.slide-rail button[aria-current="page"]::before { position: absolute; right: 1px; height: 18px; background: var(--accent); box-shadow: 0 0 10px rgba(200, 241, 105, .4); }
.slide-rail button span { position: absolute; left: 4px; }
.slide-rail button::after {
  content: attr(data-title);
  position: absolute;
  right: 34px;
  width: max-content;
  max-width: 260px;
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 7px;
  color: #dce2dc;
  background: rgba(15, 19, 24, .96);
  box-shadow: 0 8px 24px rgba(0, 0, 0, .3);
  font-family: var(--sans);
  font-size: 11px;
  opacity: 0;
  transform: translateX(5px);
  pointer-events: none;
  transition: opacity .2s, transform .2s;
}
.slide-rail button:hover::after, .slide-rail button:focus-visible::after { opacity: 1; transform: translateX(0); }

.deck-dialog {
  width: min(840px, calc(100% - 28px));
  max-height: min(840px, 94vh);
  max-height: min(840px, 94svh);
  padding: 30px clamp(20px, 4vw, 36px);
  overflow: auto;
  overscroll-behavior: contain;
  border: 1px solid var(--line-strong);
  border-radius: 20px;
  color: var(--ink);
  background: rgba(16, 20, 26, .97);
  box-shadow: 0 35px 100px rgba(0, 0, 0, .55);
  backdrop-filter: blur(24px);
}
.deck-dialog[open] { animation: dialog-in .28s var(--ease); }
.deck-dialog::backdrop { background: rgba(2, 4, 6, .75); backdrop-filter: blur(7px); }
@keyframes dialog-in { from { opacity: 0; transform: translateY(12px) scale(.98); } to { opacity: 1; transform: none; } }
.dialog-top {
  position: sticky;
  z-index: 2;
  top: -30px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  padding: 10px 0 16px;
  background: linear-gradient(#10141a 84%, transparent);
}
.dialog-eyebrow { margin: 0 0 6px; color: var(--accent); font-family: var(--mono); font-size: 9px; letter-spacing: .16em; }
.dialog-top h2 { margin: 0; font-size: 26px; letter-spacing: -.03em; }
.dialog-top button {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  padding: 0 0 3px;
  border: 1px solid var(--line);
  border-radius: 9px;
  color: var(--muted);
  background: rgba(255, 255, 255, .03);
  font-size: 24px;
  line-height: 1;
}
.dialog-top button:hover { color: var(--ink); background: rgba(255, 255, 255, .08); }
.outline { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px 14px; list-style: none; margin: 0; padding: 0; }
.outline button {
  display: grid;
  grid-template-columns: 29px minmax(0, 1fr);
  width: 100%;
  gap: 3px 10px;
  min-height: 58px;
  align-content: center;
  padding: 10px 12px;
  border: 1px solid transparent;
  border-radius: 10px;
  color: #c6cdd4;
  background: transparent;
  text-align: left;
  font-size: 12px;
  line-height: 1.45;
  transition: background .2s, border-color .2s;
}
.outline button span { grid-row: 1 / span 2; color: var(--faint); font-family: var(--mono); font-size: 10px; padding-top: 2px; }
.outline button small { color: var(--faint); font-size: 9px; letter-spacing: .08em; }
.outline button:hover, .outline button[aria-current="page"] { border-color: var(--line); background: rgba(255, 255, 255, .045); }
.outline button[aria-current="page"] span { color: var(--accent); }
.no-script { position: relative; z-index: 3; padding: 2rem; color: var(--ink); }

@media (max-width: 1280px) {
  .slide-rail { display: none; }
}
@media (max-width: 1040px) {
  .header-context { display: none; }
  .slide-split { grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr); gap: 24px; }
  .slide-pipeline .fact-list, .slide-prototype .fact-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .footer-signature { display: none; }
}
@media (max-width: 760px) {
  .deck-header { min-height: 60px; gap: 8px; padding-inline: 14px; }
  .brand { gap: 9px; }
  .brand-mark { width: 29px; height: 29px; border-radius: 9px; }
  .brand-copy { gap: 4px; }
  .brand-copy strong { font-size: 11px; letter-spacing: .19em; }
  .brand-copy small { font-size: 7.5px; letter-spacing: .2em; }
  .tools { gap: 1px; }
  .tools button { min-width: 35px; min-height: 35px; padding: 7px; }
  .tools .button-label { display: none; }
  .deck { padding: 11px 10px 0; }
  .slide { min-height: calc(100svh - 150px); padding: 28px 21px; border-radius: 18px; }
  .slide::after { font-size: 130px; }
  .chapter { margin-bottom: 13px; font-size: 9px; }
  .slide h2 { font-size: clamp(29px, 7.4vw, 42px); }
  .lead { margin-top: 12px; font-size: 15px; }
  .slide-split, .slide-body.has-detail { grid-template-columns: 1fr; }
  .slide-split { gap: 22px; margin-top: 23px; }
  .slide-body { margin-top: 23px; }
  .fact, .slide-read .fact, .has-detail .fact { grid-template-columns: 26px minmax(0, 1fr); gap: 3px 8px; padding-block: 12px; }
  .fact dt, .fact dd, .slide-read .fact dt, .slide-read .fact dd, .has-detail .fact dt, .has-detail .fact dd { grid-column: 2; font-size: 14px; }
  .fact-index, .slide-read .fact-index, .has-detail .fact-index { grid-row: 1 / span 2; }
  .slide-pipeline .fact-list, .slide-prototype .fact-list { grid-template-columns: 1fr; }
  .slide-pipeline .fact, .slide-prototype .fact { min-height: 0; }
  .references .asset-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .references .asset-grid > div, .references .asset-grid > div:nth-child(4) { grid-column: auto; }
  .textures .asset-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .cover { min-height: max(650px, calc(100svh - 150px)); justify-content: end; padding-bottom: 55px; }
  .cover::before { background: linear-gradient(0deg, #080c10 5%, rgba(8, 12, 16, .96) 40%, rgba(8, 12, 16, .25) 83%, rgba(8, 12, 16, .1)); }
  .cover-art { inset: -2%; background: url("media/ref-5.jpg") 62% top / auto 63% no-repeat; }
  .cover-copy { width: 100%; max-width: 580px; }
  .cover-label { margin-bottom: 17px; font-size: 9px; }
  .cover h1 { font-size: clamp(47px, 14.2vw, 76px); }
  .cover-title-cn { margin-top: 16px; font-size: 20px; }
  .cover-lead { margin-top: 13px; font-size: 14px; }
  .cover-tags { margin-top: 15px; }
  .cover-author { margin-top: 13px; }
  .start { margin-top: 19px; }
  .art-caption { display: none; }
  .deck-footer { min-height: 66px; padding-inline: 14px; }
  #slide-position { min-width: 0; }
  .position-chapter { display: none; }
  .next-label { display: none; }
  .controls button#next-button { padding-inline: 10px; }
  .model-stage { height: clamp(245px, 44vh, 330px); }
  .story-stats { grid-template-columns: repeat(2, 1fr); }
  .outline { grid-template-columns: 1fr; }
}
@media (min-width: 761px) and (max-height: 820px) {
  .deck-header { min-height: 58px; }
  .deck-footer { min-height: 58px; }
  .deck { padding-block: 13px 10px; }
  .slide, .cover { min-height: calc(100svh - 152px); padding-block: clamp(23px, 3.2vh, 34px); }
  .slide h2 { font-size: clamp(31px, 3.7vw, 51px); }
  .lead { margin-top: 10px; }
  .chapter { margin-bottom: 11px; }
  .slide-split, .slide-body { margin-top: 20px; }
  .fact { padding-block: 11px; }
  .slide-read .fact, .has-detail .fact { padding-block: 9px; }
  .slide-pipeline .fact, .slide-prototype .fact { min-height: 126px; padding: 15px; }
  .sources { margin-top: 17px; }
  .cover h1 { font-size: clamp(53px, 6.5vw, 90px); }
  .cover-label { margin-bottom: 18px; }
  .cover-title-cn { margin-top: 15px; }
  .cover-lead { margin-top: 13px; }
  .cover-tags { margin-top: 14px; }
  .cover-author { margin-top: 12px; }
  .start { margin-top: 17px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .cover-art { transform: scale(1.04); }
}

@page { size: landscape; margin: 8mm; }
@media print {
  :root { color-scheme: dark; }
  body { display: block; background: var(--bg); print-color-adjust: exact; -webkit-print-color-adjust: exact; }
  body::before, .ambient, .deck-header, .deck-footer, .progress, .deck-dialog, .slide-rail, .start { display: none !important; }
  .deck { display: block; width: 100%; padding: 0; }
  .deck .slide, .deck .slide[hidden] {
    display: flex !important;
    min-height: 175mm;
    padding: 28px;
    break-after: page;
    break-inside: avoid;
    box-shadow: none;
    animation: none;
  }
  .deck .slide:last-child { break-after: auto; }
  .slide h2 { font-size: 34px; }
  .lead, .fact dt, .fact dd { font-size: 14px; }
  .slide-split { grid-template-columns: 1fr 1.2fr; }
  .model-stage, .map-frame { height: 180px; min-height: 0; }
}
