:root {
  color-scheme: dark;
  --ground: #10110f;
  --ink: #eeeae1;
  --muted: #a4a69c;
  --line: #eeeecc26;
  --accent: #89c5af;
  --mono: ui-monospace, SFMono-Regular, Consolas, monospace;
  --sans: Arial, Helvetica, sans-serif;
  --header: 76px;
  --rail: 64px;
}
* {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
  scroll-padding-top: 100px;
}
body {
  margin: 0;
  background: var(--ground);
  color: var(--ink);
  font: 16px/1.65 var(--sans);
  -webkit-font-smoothing: antialiased;
}
a {
  color: inherit;
  text-underline-offset: 5px;
}
button,
input {
  font: inherit;
}
button,
a,
input,
summary {
  -webkit-tap-highlight-color: transparent;
}
a:focus-visible,
button:focus-visible,
summary:focus-visible,
input:focus-visible,
canvas:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 5px;
}
button {
  cursor: pointer;
}
button:disabled {
  cursor: default;
}
::selection {
  background: var(--accent);
  color: var(--ground);
}
[hidden] {
  display: none !important;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
.skip {
  position: fixed;
  left: 16px;
  top: -100px;
  z-index: 20;
  padding: 12px;
  background: var(--ink);
  color: var(--ground);
}
.skip:focus {
  top: 12px;
}
.topbar {
  height: var(--header);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 3vw;
  position: fixed;
  inset: 0 0 auto;
  z-index: 10;
  background: var(--ground);
  border-bottom: 1px solid var(--line);
  gap: 24px;
}
.wordmark {
  display: flex;
  align-items: center;
  gap: 12px;
  font: 12px var(--mono);
  letter-spacing: 0.15em;
  text-decoration: none;
}
.brand-grid {
  width: 18px;
  height: 18px;
  background: radial-gradient(circle, var(--accent) 1.5px, transparent 2px) 0
    0/6px 6px;
}
.edition {
  font: 10px var(--mono);
  letter-spacing: 0.16em;
  color: var(--muted);
}
.topbar nav {
  display: flex;
  gap: 28px;
  font-size: 12px;
}
.topbar nav a {
  text-decoration: none;
}
.topbar nav a:hover {
  color: var(--accent);
}
.guide-layout {
  display: grid;
  grid-template-columns: 56% 44%;
  max-width: 1680px;
  margin: auto;
  padding-top: var(--header);
}
.stage {
  position: sticky;
  top: var(--header);
  height: calc(100svh - var(--header) - var(--rail));
  min-height: 460px;
  display: flex;
  flex-direction: column;
  padding: 36px 3vw 18px;
  overflow: hidden;
  align-self: start;
}
.stage-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.eyebrow {
  font: 10px/1.6 var(--mono);
  letter-spacing: 0.16em;
  font-weight: 400;
}
.stage-top .eyebrow {
  color: var(--muted);
}
.status-dot {
  height: 5px;
  width: 5px;
  border-radius: 50%;
  background: var(--accent);
}
.model-wrap {
  position: relative;
  flex: 1;
  min-height: 0;
}
.model-wrap canvas {
  width: 100%;
  height: 100%;
  display: block;
  cursor: grab;
  touch-action: pan-y;
}
.model-wrap canvas:active {
  cursor: grabbing;
}
.model-fallback {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.model-label {
  position: absolute;
  left: 0;
  bottom: 20px;
  font: 12px/1.6 var(--mono);
  color: var(--ink);
  pointer-events: none;
}
.model-label span {
  font-size: 9px;
  letter-spacing: 0.12em;
  color: var(--muted);
}
.model-ui {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}
.view-controls {
  display: flex;
  gap: 4px;
}
.view-controls button {
  border: 1px solid transparent;
  background: transparent;
  color: var(--muted);
  font: 11px var(--mono);
  min-height: 38px;
  padding: 8px 12px;
  transition:
    color 0.15s,
    border-color 0.15s;
}
.view-controls button:hover,
.view-controls button[aria-pressed="true"] {
  color: var(--ink);
  border-color: var(--line);
}
.drag-hint {
  color: var(--muted);
  font: 9px var(--mono);
  letter-spacing: 0.13em;
}
.model-note {
  font-size: 11px;
  line-height: 1.6;
  color: var(--muted);
  max-width: 430px;
  margin: 14px 0 0;
}
.story {
  padding: 0 clamp(28px, 5vw, 88px) 0 clamp(24px, 3vw, 48px);
  position: relative;
}
.guide-section {
  min-height: calc(100svh - var(--header));
  padding: 100px 0 120px;
  scroll-margin-top: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  border-bottom: 1px solid var(--line);
}
.intro {
  padding-top: 64px;
  min-height: calc(100svh - var(--header) - var(--rail));
}
.accent {
  color: var(--accent);
}
h1,
h2 {
  letter-spacing: -0.055em;
  font-weight: 400;
  line-height: 1.04;
  margin: 20px 0 24px;
}
h1 {
  font-size: clamp(44px, 5vw, 76px);
}
h2 {
  font-size: clamp(36px, 4vw, 58px);
}
h1 em {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
  color: var(--accent);
}
p {
  margin: 0 0 20px;
  max-width: 50ch;
  color: #c3c5bc;
}
strong {
  color: var(--ink);
  font-weight: 500;
}
.intro-copy {
  font-size: 17px;
  line-height: 1.65;
}
.start-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  width: 100%;
  border-bottom: 1px solid var(--accent);
  padding: 16px 0;
  color: var(--ink);
  text-decoration: none;
  font-size: 14px;
  margin: 12px 0 24px;
}
.start-link span {
  font-size: 20px;
  color: var(--accent);
}
.start-link:hover {
  color: var(--accent);
}
.spec-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  width: 100%;
  gap: 16px;
  margin: 16px 0 24px;
}
.spec-strip dt {
  font: 9px var(--mono);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 8px;
}
.spec-strip dd {
  font: 14px var(--mono);
  margin: 0;
  white-space: nowrap;
}
.quiet {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.7;
}
.intro-note {
  font-size: 11px;
}
.next-link {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  width: 100%;
  text-decoration: none;
  color: var(--muted);
  font-size: 12px;
  border-top: 1px solid var(--line);
  padding-top: 20px;
  margin-top: 40px;
}
.next-link:hover {
  color: var(--ink);
}
.source-link {
  font-size: 12px;
  color: var(--accent);
  line-height: 1.7;
}
.source-links {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.parts-list {
  width: 100%;
  margin: 12px 0 24px;
}
.parts-list details {
  border-top: 1px solid var(--line);
}
.parts-list details:last-child {
  border-bottom: 1px solid var(--line);
}
summary {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px 0;
  cursor: pointer;
  list-style: none;
  line-height: 1.4;
  font-size: 15px;
}
summary::-webkit-details-marker {
  display: none;
}
.quantity {
  font: 10px var(--mono);
  color: var(--accent);
  align-self: flex-start;
  padding-top: 4px;
}
summary small {
  display: block;
  font-size: 11px;
  color: var(--muted);
  margin-top: 6px;
}
.expand {
  margin-left: auto;
  color: var(--muted);
}
details[open] .expand {
  transform: rotate(45deg);
}
.detail-body {
  font-size: 13px;
  line-height: 1.7;
  color: var(--muted);
  padding: 0 16px 20px 30px;
}
.detail-body a {
  display: block;
  color: var(--accent);
  font-size: 11px;
  margin-top: 12px;
}
.checkpoint {
  border-left: 1px solid var(--accent);
  padding-left: 16px;
  font-size: 13px;
  margin: 16px 0 24px;
}
.checkpoint > span {
  display: block;
  font: 9px var(--mono);
  letter-spacing: 0.12em;
  color: var(--accent);
  margin: 0 0 8px;
}
.connection-line {
  display: flex;
  align-items: center;
  gap: 20px;
  width: 100%;
  font: 11px var(--mono);
  letter-spacing: 0.05em;
  padding: 24px 0;
  margin: 8px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.connection-line span:nth-child(2) {
  color: var(--accent);
}
.fact-rows {
  width: 100%;
  font-size: 13px;
  margin: 12px 0 24px;
}
.fact-rows > div {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  border-top: 1px solid var(--line);
  padding: 14px 0;
}
.fact-rows dt {
  color: var(--ink);
}
.fact-rows dd {
  text-align: right;
  color: var(--muted);
  margin: 0;
}
.power-spec {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 32px;
  padding: 20px 0;
  margin: 8px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.power-spec strong {
  font-size: 68px;
  line-height: 1;
  letter-spacing: -0.06em;
  color: var(--accent);
}
.power-spec strong span {
  font: 13px var(--mono);
  letter-spacing: 0;
  margin-left: 8px;
}
.power-spec p {
  font-size: 12px;
  line-height: 1.8;
  margin: 0;
}
pre {
  width: 100%;
  overflow: auto;
  border: 1px solid var(--line);
  padding: 20px;
  font: 12px/1.8 var(--mono);
  color: var(--accent);
  margin: 8px 0 24px;
  tab-size: 2;
}
.checklist {
  border: 0;
  padding: 0;
  margin: 16px 0 20px;
  width: 100%;
  min-width: 0;
}
.checklist legend {
  font: 10px var(--mono);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
  margin-bottom: 12px;
}
.checklist label {
  display: flex;
  gap: 14px;
  border-top: 1px solid var(--line);
  padding: 16px 0;
  font-size: 13px;
  cursor: pointer;
}
.checklist input {
  accent-color: var(--accent);
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  margin: 3px 0 0;
}
.checklist label:has(:checked) {
  color: var(--accent);
}
.ending {
  min-height: auto;
  padding-bottom: 140px;
  border-bottom: 0;
}
footer {
  border-top: 1px solid var(--line);
  padding-top: 32px;
  margin-top: 48px;
  font-size: 11px;
  color: var(--muted);
}
footer p {
  color: var(--muted);
  margin-bottom: 12px;
}
footer a {
  font-size: 11px;
}
.chapter-rail {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 10;
  height: var(--rail);
  display: flex;
  justify-content: center;
  gap: clamp(16px, 3.5vw, 56px);
  padding: 0 24px;
  background: var(--ground);
  border-top: 1px solid var(--line);
  overflow-x: auto;
  scrollbar-width: none;
}
.chapter-rail a {
  font: 11px var(--mono);
  text-decoration: none;
  white-space: nowrap;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 10px;
  border-top: 2px solid transparent;
}
.chapter-rail a span {
  font-size: 9px;
  color: var(--muted);
}
.chapter-rail a:hover,
.chapter-rail a[aria-current="step"] {
  color: var(--ink);
}
.chapter-rail a[aria-current="step"] {
  border-color: var(--accent);
}
.chapter-rail a[aria-current="step"] span {
  color: var(--accent);
}
@media (min-width: 1680px) {
  .stage {
    padding-left: 48px;
    padding-right: 48px;
  }
}
@media (max-width: 1100px) {
  .guide-layout {
    grid-template-columns: 52% 48%;
  }
  .story {
    padding-right: 32px;
    padding-left: 24px;
  }
  .stage {
    padding: 28px 24px 18px;
  }
  .edition {
    display: none;
  }
  .drag-hint {
    display: none;
  }
  h1 {
    font-size: 54px;
  }
  .guide-section {
    padding-top: 76px;
    padding-bottom: 96px;
  }
  .intro {
    padding-top: 36px;
    padding-bottom: 36px;
  }
}
@media (max-width: 760px) {
  :root {
    --header: 60px;
    --rail: 54px;
  }
  html {
    scroll-padding-top: calc(var(--header) + 32svh + 20px);
  }
  .topbar {
    padding: 0 20px;
  }
  .wordmark {
    font-size: 10px;
    gap: 8px;
  }
  .topbar nav {
    gap: 20px;
    font-size: 11px;
  }
  .guide-layout {
    display: block;
  }
  .stage {
    height: 32svh;
    min-height: 220px;
    max-height: 360px;
    padding: 10px 20px 8px;
    z-index: 4;
    background: var(--ground);
    border-bottom: 1px solid var(--line);
  }
  .stage-top {
    position: absolute;
    top: 14px;
    left: 20px;
    right: 20px;
    pointer-events: none;
  }
  .stage-top .eyebrow {
    font-size: 8px;
    max-width: 100px;
  }
  .model-wrap {
    margin: 0 60px;
  }
  .model-label {
    font-size: 9px;
    left: -60px;
    bottom: 4px;
  }
  .model-label span {
    display: none;
  }
  .model-ui {
    position: absolute;
    bottom: 8px;
    right: 16px;
  }
  .view-controls {
    gap: 0;
  }
  .view-controls button {
    font-size: 9px;
    padding: 8px;
    min-height: 36px;
  }
  .model-note {
    font-size: 9px;
    line-height: 1.4;
    max-width: 56%;
    margin: 8px 0 0;
  }
  .story {
    padding: 0 24px;
  }
  .guide-section {
    min-height: auto;
    padding: 64px 0 72px;
    scroll-margin-top: 0;
  }
  .intro {
    padding: 36px 0 56px;
  }
  .intro .eyebrow {
    font-size: 9px;
  }
  h1 {
    font-size: clamp(40px, 8.5vw, 58px);
    margin-top: 14px;
  }
  h1 br:nth-of-type(2) {
    display: none;
  }
  h2 {
    font-size: 40px;
  }
  .intro-copy {
    font-size: 15px;
  }
  .chapter-rail {
    justify-content: flex-start;
    gap: 24px;
    padding: 0 20px;
  }
  .chapter-rail a {
    font-size: 10px;
    gap: 6px;
  }
  .ending {
    padding-bottom: 100px;
  }
  .spec-strip {
    margin: 8px 0 24px;
  }
  .model-fallback {
    min-height: 0;
  }
}
@media (max-width: 360px) {
  .topbar {
    padding: 0 16px;
    gap: 16px;
  }
  .topbar nav {
    gap: 14px;
  }
  .wordmark {
    letter-spacing: 0.08em;
  }
  .story {
    padding: 0 20px;
  }
  .stage {
    padding-left: 16px;
    padding-right: 16px;
  }
  .model-wrap {
    margin: 0 36px;
  }
  .model-label {
    left: -36px;
  }
  .model-note {
    max-width: 48%;
    font-size: 8px;
  }
  .view-controls button {
    padding: 6px;
    font-size: 8px;
  }
  .spec-strip dd {
    font-size: 12px;
  }
  .fact-rows {
    font-size: 12px;
  }
  .power-spec {
    gap: 20px;
  }
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    transition: none !important;
    animation: none !important;
  }
}
@media print {
  body {
    background: white;
    color: black;
  }
  .topbar,
  .stage,
  .chapter-rail,
  .next-link,
  .skip {
    display: none;
  }
  .guide-layout {
    display: block;
    padding: 0;
  }
  .story {
    padding: 0;
  }
  .guide-section {
    min-height: 0;
    padding: 24px 0;
    break-inside: avoid;
  }
  p,
  strong,
  h1,
  h2,
  dt,
  dd,
  .quiet {
    color: black !important;
  }
  a {
    color: black;
  }
  .checklist input {
    appearance: auto;
  }
  footer {
    margin-top: 24px;
  }
  h1 {
    font-size: 36px;
  }
  h2 {
    font-size: 28px;
  }
}
