@charset "UTF-8";
/* Askew / Systems — the lab. Ember on deep charcoal: the far side of the rabbit hole.
   Martian Grotesk and Martian Mono, SIL Open Font License 1.1 — see /assets/fonts/. */

@font-face {
  font-display: swap;
  font-family: "Martian Grotesk";
  font-stretch: 90% 130%;
  font-weight: 300 800;
  src: url("/assets/fonts/martian-grotesk-latin-32f81ef640.woff2") format("woff2");
}

@font-face {
  font-display: swap;
  font-family: "Martian Mono";
  font-stretch: 75% 112.5%;
  font-weight: 100 800;
  src: url("/assets/fonts/martian-mono-latin-f9c1655c2c.woff2") format("woff2");
}

/* The mono pinned to its narrowest cut, for the labels the exhibits draw on canvas. */
@font-face {
  font-display: swap;
  font-family: "Martian Label";
  font-stretch: 75%;
  font-weight: 400;
  src: url("/assets/fonts/martian-mono-latin-f9c1655c2c.woff2") format("woff2");
}

:root {
  color-scheme: dark;
  --bg: #08090c;
  --panel: #0e1218;
  --panel-2: #141a23;
  --well: #0a0d13;
  --line: #212833;
  --line-strong: #364252;
  --ink: #f3f0e9;
  --muted: #abb1bb;
  --faint: #7d8693;
  --steel: #97adc4;
  --ember: #ff7948;
  --ember-soft: #ffb690;
  --ember-deep: #33211a;
  --teal: #86d6c6;
  --danger: #ff9ca4;
  --orange: var(--ember);
  --sans: "Martian Grotesk", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --mono: "Martian Mono", ui-monospace, "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  --gutter: clamp(1.1rem, 4vw, 4.2rem);
  --shell: 1560px;
  --masthead: 4.75rem;
  --radius: 14px;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: calc(var(--masthead) + 1rem); }

body {
  -webkit-font-smoothing: antialiased;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1rem;
  line-height: 1.6;
  margin: 0;
  overflow-x: hidden;
  overflow-x: clip;
}

/* Fine grain keeps the large dark areas from banding. */
body::before {
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Cpath fill='%23fff' filter='url(%23n)' opacity='.25' d='M0 0h180v180H0z'/%3E%3C/svg%3E");
  content: "";
  inset: 0;
  opacity: 0.1;
  pointer-events: none;
  position: fixed;
  z-index: -1;
}

a { color: inherit; text-decoration: none; }
button, input, select { font: inherit; }
button { background: none; border: 0; color: inherit; cursor: pointer; padding: 0; }
button:disabled { cursor: default; opacity: 0.4; }
button, a, input { -webkit-tap-highlight-color: transparent; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, summary:focus-visible, canvas:focus-visible { outline: 2px solid var(--ember); outline-offset: 4px; }
::selection { background: var(--ember); color: var(--bg); }
[hidden] { display: none !important; }

h1, h2, h3, h4 { font-weight: 600; margin: 0; }

.mono, .eyebrow, .fine-print {
  font-family: var(--mono);
  font-stretch: 87.5%;
}
.mono, .eyebrow { font-size: 0.66rem; letter-spacing: 0.13em; line-height: 1.6; }
.eyebrow { color: var(--muted); font-weight: 400; margin: 0; }
.fine-print { color: var(--faint); font-size: 0.68rem; letter-spacing: 0.02em; line-height: 1.7; margin: 0; max-width: 34rem; }
.orange { color: var(--ember); }
.danger { color: var(--danger) !important; }
.sr-only { border: 0; clip: rect(0, 0, 0, 0); height: 1px; margin: -1px; overflow: hidden; padding: 0; position: absolute; white-space: nowrap; width: 1px; }
.skip-link { background: var(--ember); color: var(--bg); left: 1.25rem; padding: 1rem; position: fixed; top: -6rem; z-index: 60; }
.skip-link:focus { top: 0.75rem; }

.status-dot, .small-dot { background: var(--ember); border-radius: 50%; display: inline-block; vertical-align: middle; }
.status-dot { animation: pulse 2.6s ease-in-out infinite; box-shadow: 0 0 12px rgba(255, 121, 72, 0.55); height: 7px; margin-right: 0.6rem; width: 7px; }
.small-dot { height: 5px; margin-right: 0.5rem; width: 5px; }

/* ---------- Masthead and chapter rail ---------- */

.masthead {
  align-items: center;
  display: flex;
  gap: clamp(1rem, 2.4vw, 2.2rem);
  height: var(--masthead);
  inset: 0 0 auto;
  padding-inline: var(--gutter);
  position: fixed;
  transition: background 300ms ease, border-color 300ms ease, backdrop-filter 300ms ease;
  border-bottom: 1px solid transparent;
  z-index: 40;
}
.is-scrolled .masthead { backdrop-filter: blur(16px) saturate(1.3); background: rgba(8, 9, 12, 0.74); border-bottom-color: var(--line); }

.wordmark { align-items: center; display: flex; font-size: 0.86rem; font-stretch: 118%; font-weight: 700; letter-spacing: 0.1em; white-space: nowrap; }
.brand-icon { font-size: 2rem; font-stretch: 100%; font-weight: 600; letter-spacing: -0.12em; line-height: 1; margin-right: 1.1rem; }
.brand-icon > span { color: var(--ember); font-size: 1.2rem; }
.wordmark-divider { color: var(--faint); font-weight: 400; margin: 0 0.6rem; }
.wordmark-light { color: var(--muted); font-size: 0.74rem; font-weight: 400; }

.masthead nav { display: flex; gap: clamp(1rem, 2.2vw, 2rem); margin-left: auto; }
.masthead nav a { color: var(--muted); font-size: 0.82rem; position: relative; transition: color 160ms ease; }
.masthead nav a::after { background: var(--ember); bottom: -0.4rem; content: ""; height: 1px; left: 0; position: absolute; transform: scaleX(0); transform-origin: left; transition: transform 280ms var(--ease); width: 100%; }
.masthead nav a:hover { color: var(--ink); }
.masthead nav a:hover::after { transform: scaleX(1); }

.command-button { align-items: center; background: rgba(20, 26, 35, 0.8); border: 1px solid var(--line-strong); border-radius: 8px; color: var(--muted); display: inline-flex; font-size: 0.76rem; gap: 0.9rem; min-height: 2.75rem; padding: 0 0.8rem; transition: border-color 160ms ease, color 160ms ease; }
.command-button:hover { border-color: var(--ember); color: var(--ink); }
.command-button kbd { color: var(--faint); font: 0.62rem var(--mono); letter-spacing: 0.06em; }
.exit-link { align-items: center; display: flex; font: 0.68rem var(--mono); gap: 0.7rem; letter-spacing: 0.08em; min-height: 2.75rem; transition: color 160ms ease; }
.exit-link span { color: var(--ember); transition: transform 200ms var(--ease); }
.exit-link:hover { color: var(--ember-soft); }
.exit-link:hover span { transform: translate(2px, -2px); }

.chapter-rail { display: none; flex-direction: column; gap: 0.15rem; position: fixed; right: clamp(0.7rem, 1.1vw, 1.4rem); top: 50%; transform: translateY(-50%); z-index: 30; }
.chapter-rail a { align-items: center; color: var(--faint); display: flex; font-size: 0.56rem; gap: 0.55rem; justify-content: flex-end; letter-spacing: 0.1em; padding: 0.42rem 0; transition: color 200ms ease; }
.chapter-rail a b { background: rgba(8, 9, 12, 0.86); border: 1px solid var(--line); border-radius: 5px; font-weight: 400; opacity: 0; padding: 0.2rem 0.45rem; transform: translateX(6px); transition: opacity 200ms ease, transform 260ms var(--ease); order: -1; text-transform: uppercase; }
.chapter-rail a::after { background: currentColor; content: ""; height: 1px; transition: width 300ms var(--ease); width: 0.7rem; }
.chapter-rail a:hover { color: var(--ink); }
.chapter-rail a:hover b { opacity: 1; transform: none; }
.chapter-rail a.is-current { color: var(--ember); }
.chapter-rail a.is-current::after { width: 1.5rem; }
@media (min-width: 1240px) and (hover: hover) { .js .chapter-rail { display: flex; } }

/* ---------- Hero: the observatory fills the first screen ---------- */

.hero {
  display: flex;
  flex-direction: column;
  isolation: isolate;
  min-height: max(100vh, 46rem);
  min-height: max(100svh, 46rem);
  overflow: hidden;
  overflow: clip;
  padding: calc(var(--masthead) + 0.6rem) var(--gutter) calc(var(--dock-h, 13.5rem) + 1.1rem);
  position: relative;
}
.hero-coordinate { color: var(--faint); display: flex; font-size: 0.58rem; justify-content: space-between; letter-spacing: 0.18em; pointer-events: none; position: relative; z-index: 2; }
.hero-copy { margin-block: auto; padding-block: 0.75rem; pointer-events: none; position: relative; z-index: 2; }
.hero-copy a { pointer-events: auto; }
.hero-copy .eyebrow { color: var(--ink); margin-bottom: clamp(0.9rem, 2.4vh, 1.6rem); }
.hero-copy > p { max-width: 31rem; }

.hero h1 {
  font-size: clamp(3.4rem, 7.9vw, 8.4rem);
  font-stretch: 118%;
  font-weight: 640;
  letter-spacing: -0.055em;
  line-height: 0.93;
  margin: 0 0 clamp(1.1rem, 3vh, 2rem);
  text-shadow: 0 0 60px rgba(8, 9, 12, 0.9);
  white-space: nowrap;
}
/* Each line rises from behind its own baseline; only the vertical axis is clipped. */
.hero-line { display: block; overflow-x: visible; overflow-y: clip; padding-bottom: 0.1em; margin-bottom: -0.1em; width: fit-content; }
.hero-line > span { display: block; }
.hero-accent { color: var(--ember); }
.hero-description { font-size: clamp(1.1rem, 1.75vw, 1.6rem); font-weight: 450; letter-spacing: -0.02em; line-height: 1.4; margin: 0 0 0.9rem; }
.hero-description em { color: var(--muted); font-style: normal; }
.hero-subcopy { color: var(--muted); font-size: 0.92rem; line-height: 1.7; margin: 0 0 clamp(1.2rem, 3vh, 2rem); }

.primary-link { align-items: center; border-bottom: 1px solid var(--ember); display: inline-flex; font-size: 0.86rem; font-weight: 500; gap: 2.2rem; padding: 0.8rem 0; transition: color 160ms ease, gap 260ms var(--ease); }
.primary-link > span { color: var(--ember); font-size: 1.4rem; line-height: 1; transition: transform 240ms var(--ease); }
.primary-link:hover { color: var(--ember-soft); gap: 2.8rem; }
.primary-link:hover > span { transform: translate(4px, 3px); }

.solar-stage { inset: 0; position: absolute; z-index: 0; }
.solar-view { inset: 0; isolation: isolate; overflow: hidden; position: absolute; }
.solar-view canvas { cursor: grab; display: block; height: 100%; touch-action: pan-y; width: 100%; }
.solar-view canvas:active { cursor: grabbing; }
.solar-view canvas:focus-visible { outline-offset: -4px; }
/* A scrim keeps the headline legible and lets the sky sink into the page. */
.solar-view::after {
  background: linear-gradient(90deg, rgba(8, 9, 12, 0.86) 0%, rgba(8, 9, 12, 0.5) 30%, transparent 58%), linear-gradient(0deg, var(--bg) 2%, rgba(8, 9, 12, 0.55) 22%, transparent 42%), linear-gradient(180deg, rgba(8, 9, 12, 0.7), transparent 16%);
  content: "";
  inset: 0;
  pointer-events: none;
  position: absolute;
}
/* Until the simulation draws (or without scripting), a still diagram holds the space. */
.solar-stage:not(.scene-ready) .solar-view {
  background:
    radial-gradient(circle at 66% 48%, #ffc266 0 0.55rem, rgba(255, 121, 72, 0.3) 0.7rem, transparent 3.4rem),
    radial-gradient(ellipse 13% 7% at 66% 48%, transparent 96%, rgba(151, 173, 196, 0.28) 97.5%, transparent 99.5%),
    radial-gradient(ellipse 22% 12% at 66% 48%, transparent 97%, rgba(151, 173, 196, 0.22) 98.2%, transparent 99.6%),
    radial-gradient(ellipse 31% 17% at 66% 48%, transparent 97.6%, rgba(151, 173, 196, 0.16) 98.6%, transparent 99.7%),
    #080b11;
}
.scene-fallback { color: var(--steel); font: 0.68rem/1.9 var(--mono); inset: 70% 6% auto 52%; letter-spacing: 0.06em; position: absolute; text-align: center; z-index: -1; }
.scene-ready .scene-fallback { display: none; }
.scene-expand {
  align-items: center;
  backdrop-filter: blur(10px);
  background: rgba(16, 22, 30, 0.72);
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  color: var(--steel);
  display: inline-flex;
  font-size: 1.35rem;
  justify-content: center;
  min-height: 2.9rem;
  min-width: 2.9rem;
  position: absolute;
  transition: border-color 160ms ease, color 160ms ease, transform 200ms var(--ease);
  z-index: 3;
}
.scene-expand:hover { border-color: var(--ember); color: var(--ember-soft); transform: scale(1.06); }
.solar-view .scene-expand { right: var(--gutter); top: calc(var(--masthead) + 2.4rem); }

.solar-dock { bottom: 1.1rem; display: grid; gap: 0.7rem; left: var(--gutter); position: absolute; right: var(--gutter); z-index: 3; }
.hero-bottom { align-items: center; display: flex; gap: 1.6rem; min-height: 2.75rem; }
#renderer-label { color: var(--steel); }
.motion-control { align-items: center; color: var(--muted); display: inline-flex; gap: 0.5rem; min-height: 2.75rem; transition: color 160ms ease; }
.motion-control:hover { color: var(--ember-soft); }
.scroll-cue { color: var(--faint); margin-left: auto; transition: color 160ms ease; }
.scroll-cue > span { color: var(--ember); display: inline-block; font-size: 1rem; margin-left: 1rem; }
.scroll-cue:hover { color: var(--ink); }

.solar-console {
  backdrop-filter: blur(18px) saturate(1.25);
  background: rgba(12, 16, 22, 0.74);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.04);
  display: grid;
  grid-template-columns: minmax(15rem, 0.8fr) minmax(0, 2fr);
}
.planet-brief { align-content: center; border-right: 1px solid var(--line); display: grid; gap: 0.3rem 0.9rem; grid-template-columns: auto 1fr; padding: 0.9rem 1.25rem; }
.planet-brief strong { color: var(--ember-soft); font-size: 1.5rem; font-stretch: 112%; font-weight: 600; letter-spacing: -0.03em; line-height: 1.15; }
.planet-brief > span { align-self: center; color: var(--muted); font-size: 0.82rem; line-height: 1.45; }
.planet-brief .mono { color: var(--steel); font-size: 0.6rem; grid-column: 1 / -1; letter-spacing: 0.06em; }
.planet-brief #planet-orbit { color: var(--faint); }
.solar-controls-row, .solar-orbit-controls { align-items: center; display: flex; flex-wrap: wrap; gap: 0.35rem 1.4rem; padding: 0.55rem 1.25rem; }
.solar-orbit-controls { border-top: 1px solid var(--line); }
.solar-console label { align-items: center; color: var(--faint); display: flex; font: 0.6rem var(--mono); font-stretch: 87.5%; gap: 0.6rem; letter-spacing: 0.12em; }
.solar-console button { color: var(--ink); font: 0.68rem var(--mono); font-stretch: 87.5%; letter-spacing: 0.04em; min-height: 2.6rem; transition: color 160ms ease; }
.solar-console button:hover { color: var(--ember-soft); }
.solar-console button[aria-pressed] { padding-left: 1rem; position: relative; }
.solar-console button[aria-pressed]::before { background: var(--ember); border-radius: 50%; box-shadow: 0 0 8px rgba(255, 121, 72, 0.7); content: ""; height: 6px; left: 0; position: absolute; top: calc(50% - 3px); width: 6px; }
.solar-console button[aria-pressed="false"] { color: var(--faint); }
.solar-console button[aria-pressed="false"]::before { background: var(--line-strong); box-shadow: none; }
.solar-console select { max-width: 9rem; }
.solar-console output { color: var(--ember-soft); font-size: 0.62rem; letter-spacing: 0.04em; }
.speed-control input { width: 5.5rem; }
.orbit-tilt-control { margin-left: auto; }
.orbit-tilt-control input { width: 5.5rem; }
.orbit-tilt-control output { min-width: 7.2rem; }
.scene-note { border-top: 1px solid var(--line); color: var(--faint); font: 0.58rem/1.6 var(--mono); font-stretch: 87.5%; letter-spacing: 0.02em; margin: 0; padding: 0.55rem 1.25rem 0.65rem; }

/* ---------- Ticker ---------- */

.signal-strip { border-block: 1px solid var(--line); color: var(--muted); display: flex; overflow: hidden; padding: 1.15rem 0; white-space: nowrap; }
.signal-track { animation: ticker 46s linear infinite; display: flex; flex-shrink: 0; gap: clamp(2.5rem, 6vw, 6rem); min-width: 100%; padding-right: clamp(2.5rem, 6vw, 6rem); justify-content: space-around; }
.signal-track > span:first-child { color: var(--ink); }

/* ---------- Chapters ---------- */

.section-shell { margin-inline: auto; padding-block: clamp(4.5rem, 12vh, 9rem); width: min(100% - 2 * var(--gutter), var(--shell)); }
.section-heading { align-items: center; border-top: 1px solid var(--line); display: flex; gap: 1.5rem; justify-content: space-between; padding-top: 1.1rem; position: relative; }
.section-heading::before { background: var(--ember); content: ""; height: 2px; left: 0; position: absolute; top: -1px; width: 3rem; }
.section-heading .eyebrow { color: var(--ember); }
.section-aside { color: var(--faint); }
/* The headline takes the width it needs; the lede sits beside it when there is room, beneath it when not. */
.section-intro { align-items: end; display: flex; flex-wrap: wrap; gap: 1.4rem clamp(2rem, 5vw, 6rem); justify-content: space-between; margin: clamp(1.8rem, 5vh, 3.4rem) 0 clamp(2.2rem, 6vh, 4.5rem); }
h2 { font-size: clamp(2.5rem, 6.1vw, 6.5rem); font-stretch: 114%; font-weight: 620; letter-spacing: -0.05em; line-height: 0.98; }
h2 > span { color: var(--faint); }
.section-intro > h2 { flex: 0 1 auto; }
.section-intro > p { color: var(--muted); flex: 1 1 22rem; font-size: clamp(1rem, 1.2vw, 1.18rem); line-height: 1.65; margin: 0 0 0 auto; max-width: 27rem; padding-bottom: 0.5em; text-wrap: pretty; }

/* ---------- Shared instrument parts ---------- */

.point-instrument, .network-lab, .exhibit, .exhibit-nav {
  background: var(--panel);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.03);
  overflow: hidden;
}

select {
  appearance: none;
  background: var(--panel-2) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' fill='none' stroke='%23ffb690' stroke-width='1.4'%3E%3Cpath d='m1 1 4 4 4-4'/%3E%3C/svg%3E") no-repeat right 0.75rem center;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  color: var(--ink);
  cursor: pointer;
  font: 0.72rem var(--mono);
  font-stretch: 87.5%;
  letter-spacing: 0.02em;
  max-width: 100%;
  min-height: 2.6rem;
  padding: 0 2.1rem 0 0.8rem;
  transition: border-color 160ms ease;
}
select:hover { border-color: var(--ember); }

/* Ranges show how far along they are; alternate.js keeps --fill in step. */
input[type="range"] { appearance: none; background: transparent; cursor: pointer; height: 1.9rem; margin: 0; max-width: 100%; }
input[type="range"]::-webkit-slider-runnable-track { background: linear-gradient(90deg, var(--ember) var(--fill, 50%), var(--line-strong) var(--fill, 50%)); border-radius: 2px; height: 3px; }
input[type="range"]::-webkit-slider-thumb { appearance: none; background: var(--ink); border: 3px solid var(--ember); border-radius: 50%; box-shadow: 0 0 0 0 rgba(255, 121, 72, 0.3); height: 15px; margin-top: -6px; transition: box-shadow 200ms ease, transform 200ms var(--ease); width: 15px; }
input[type="range"]:hover::-webkit-slider-thumb, input[type="range"]:active::-webkit-slider-thumb { box-shadow: 0 0 0 6px rgba(255, 121, 72, 0.2); transform: scale(1.1); }
input[type="range"]::-moz-range-track { background: var(--line-strong); border-radius: 2px; height: 3px; }
input[type="range"]::-moz-range-progress { background: var(--ember); border-radius: 2px; height: 3px; }
input[type="range"]::-moz-range-thumb { background: var(--ink); border: 3px solid var(--ember); border-radius: 50%; height: 9px; width: 9px; }

.range-label { align-items: center; color: var(--steel); display: flex; flex-wrap: wrap; font: 0.68rem var(--mono); font-stretch: 87.5%; gap: 0.25rem 0.8rem; letter-spacing: 0.04em; margin: 1.4rem 0; }
.range-label output { color: var(--ember-soft); margin-left: auto; }
.range-label input { width: 100%; }
.control-label { color: var(--steel); display: flex; flex-direction: column; font: 0.62rem var(--mono); font-stretch: 87.5%; gap: 0.6rem; letter-spacing: 0.12em; margin-bottom: 1.3rem; }
.control-label select { letter-spacing: 0.02em; width: 100%; }
.control-actions { align-items: center; display: flex; flex-wrap: wrap; gap: 0.4rem 1.4rem; margin-top: 1.4rem; }

.primary-button {
  align-items: center;
  background: var(--ember);
  border-radius: 10px;
  color: #1a0f0a;
  display: flex;
  font-size: 0.84rem;
  font-weight: 600;
  justify-content: space-between;
  min-height: 3rem;
  padding: 0 1.1rem;
  transition: background 160ms ease, box-shadow 240ms ease, transform 200ms var(--ease);
  width: 100%;
}
.primary-button:hover:not(:disabled) { background: #ff9567; box-shadow: 0 10px 34px rgba(255, 121, 72, 0.3); transform: translateY(-1px); }
.primary-button:active:not(:disabled) { transform: translateY(0); }
.text-button { color: var(--ink); font-size: 0.8rem; min-height: 2.75rem; position: relative; transition: color 160ms ease; }
.text-button:hover:not(:disabled) { color: var(--ember-soft); }
.text-button[aria-pressed="false"] { color: var(--faint); }
.lab-status { color: var(--ember-soft); font-size: 0.64rem; letter-spacing: 0.1em; line-height: 1.6; margin: 1.4rem 0 0; min-height: 1.6rem; }
.demo-explanation { color: var(--muted); font-size: 0.88rem; line-height: 1.65; margin: 0; min-height: 5.6rem; text-wrap: pretty; }
.exhibit-note { border-top: 1px solid var(--line); color: var(--faint); font: 0.64rem/1.75 var(--mono); font-stretch: 87.5%; letter-spacing: 0.02em; margin: 0; padding: 1rem 1.6rem; }

.stage-pipeline { display: grid; gap: 0.5rem; grid-template-columns: repeat(2, 1fr); margin: 0 0 1.4rem; }
.stage-pipeline span { border-bottom: 1px solid var(--line-strong); color: var(--faint); font: 0.6rem/1.5 var(--mono); font-stretch: 87.5%; letter-spacing: 0.08em; padding: 0.5rem 0; transition: border-color 240ms ease, color 240ms ease; }
.stage-pipeline span.current { border-color: var(--ember); color: var(--ember-soft); }

/* ---------- 01 / Point cloud ---------- */

.point-lab { padding-bottom: clamp(2rem, 6vh, 4rem); }
.point-topline, .lab-topline { align-items: center; color: var(--steel); display: flex; font-size: 0.62rem; gap: 1.25rem; justify-content: space-between; letter-spacing: 0.12em; }
.point-topline { border-bottom: 1px solid var(--line); padding: 0.95rem 1.4rem; }
.point-topline strong { color: var(--ember-soft); font-weight: 400; text-transform: uppercase; }
.point-stage {
  background: radial-gradient(ellipse at 50% 55%, rgba(255, 121, 72, 0.09) 0%, transparent 62%), radial-gradient(rgba(70, 84, 104, 0.35) 0.65px, transparent 0.65px) 0 0 / 28px 28px, var(--well);
  height: clamp(26rem, 74vh, 47rem);
  overflow: hidden;
  position: relative;
}
.point-stage > canvas { cursor: grab; display: block; height: 100%; inset: 0; position: absolute; touch-action: pan-y; width: 100%; }
.point-stage > canvas[hidden] { display: none; }
.point-stage > canvas:active { cursor: grabbing; }
.point-stage > canvas:focus-visible { outline-offset: -4px; }
.point-empty { color: var(--muted); font: 0.8rem/2 var(--mono); left: 20%; position: absolute; right: 20%; text-align: center; top: 38%; }
.points-ready .point-empty { display: none; }
.point-stage:not(.points-ready) .scene-expand { display: none; }
.point-reticle { border-color: rgba(255, 182, 144, 0.4); height: 1.6rem; pointer-events: none; position: absolute; width: 1.6rem; }
.point-reticle-a { border-left: 1px solid; border-top: 1px solid; left: 1.5rem; top: 1.5rem; }
.point-reticle-b { border-bottom: 1px solid; border-right: 1px solid; bottom: 1.5rem; right: 1.5rem; }
.point-axis { bottom: 1.5rem; color: var(--faint); font-size: 0.64rem; left: 1.6rem; letter-spacing: 0.04em; line-height: 1.8; pointer-events: none; position: absolute; }
/* A dark chip keeps the count readable when the whiteboard passes behind it. */
.point-count { backdrop-filter: blur(6px); background: rgba(10, 13, 19, 0.62); border-radius: 10px; color: var(--ember-soft); font-size: clamp(1.6rem, 3vw, 2.6rem); font-stretch: 100%; left: 1rem; letter-spacing: -0.04em; line-height: 1; padding: 0.6rem; pointer-events: none; position: absolute; top: 3.6rem; }
.point-count > span { color: var(--faint); display: block; font-size: 0.58rem; letter-spacing: 0.14em; margin-top: 0.6rem; }
.point-stage .scene-expand { right: 1.25rem; top: 1.25rem; }

.point-forms { display: grid; grid-template-columns: repeat(4, 1fr); }
.point-forms button, .exhibit-nav button {
  align-items: center;
  background: transparent;
  border-right: 1px solid var(--line);
  color: var(--muted);
  display: flex;
  gap: 0.85rem;
  justify-content: center;
  min-height: 4.2rem;
  position: relative;
  transition: background 200ms ease, color 200ms ease;
}
.point-forms button { border-block: 1px solid var(--line); font: 0.74rem var(--mono); font-stretch: 87.5%; letter-spacing: 0.04em; }
.point-forms button:last-child, .exhibit-nav button:last-child { border-right: 0; }
.point-forms button > span { color: var(--faint); font-size: 1.35rem; line-height: 1; transition: color 200ms ease, transform 300ms var(--ease); }
.point-forms button::after, .exhibit-nav button::after { background: var(--ember); bottom: 0; content: ""; height: 2px; left: 0; position: absolute; transform: scaleX(0); transform-origin: left; transition: transform 360ms var(--ease); width: 100%; }
.point-forms button:hover, .exhibit-nav button:hover { background: rgba(255, 255, 255, 0.03); color: var(--ink); }
.point-forms button[aria-pressed="true"], .exhibit-nav button[aria-pressed="true"] { background: linear-gradient(180deg, rgba(255, 121, 72, 0.03), rgba(255, 121, 72, 0.13)); color: var(--ink); }
.point-forms button[aria-pressed="true"]::after, .exhibit-nav button[aria-pressed="true"]::after { transform: scaleX(1); }
.point-forms button[aria-pressed="true"] > span { color: var(--ember); transform: scale(1.15); }
.point-settings { align-items: center; display: flex; flex-wrap: wrap; gap: 0.4rem 1.8rem; padding: 0.9rem 1.4rem; }
.point-settings .range-label { flex: 1 1 11rem; margin: 0; max-width: 16rem; }
.point-settings .text-button { font: 0.68rem var(--mono); font-stretch: 87.5%; letter-spacing: 0.04em; white-space: nowrap; }
.point-bottom { align-items: center; border-top: 1px solid var(--line); display: flex; gap: 1.5rem; justify-content: space-between; padding: 0.95rem 1.4rem; }
.point-bottom p { color: var(--ink); font-size: 0.92rem; line-height: 1.5; margin: 0; }
.point-bottom > span { color: var(--faint); font-size: 0.58rem; text-align: right; }

/* ---------- 02 / Network fabric ---------- */

.network-lab { display: grid; grid-template-columns: minmax(0, 1fr) 22rem; }
.lab-visual { display: flex; flex-direction: column; min-width: 0; padding: 1.2rem 1.4rem 0; }
.fabric-stage { margin-top: 1.4rem; position: relative; }
.fabric-stage svg { display: block; height: auto; width: 100%; }
.fabric-stage canvas { height: 100%; left: 0; pointer-events: none; position: absolute; top: 0; width: 100%; }
#network-grid circle { fill: #3d4958; }
.network-edges path { fill: none; stroke: rgba(118, 142, 168, 0.26); stroke-width: 1.5; transition: stroke 300ms ease, stroke-width 300ms ease; }
.network-edges path.active { stroke: #d99866; stroke-width: 2; }
.network-edges path.failed { stroke: rgba(170, 100, 112, 0.42); stroke-dasharray: 3 5; }
.fabric-node { cursor: pointer; outline: none; }
.fabric-node rect { fill: #14202c; stroke: #4e6a84; stroke-width: 1; transition: fill 240ms ease, stroke 240ms ease, stroke-width 160ms ease; }
.fabric-node > path { fill: none; stroke: #a9c0d6; stroke-width: 1.2; transition: stroke 240ms ease; }
.fabric-node > circle { fill: var(--teal); }
.fabric-node > text { fill: #9db2c6; font: 10px var(--mono); letter-spacing: 0.5px; text-anchor: middle; }
.fabric-node.active rect { fill: #2e231b; stroke: #f0a771; }
.fabric-node.active > path { stroke: #ffc998; }
.fabric-node.offline rect { fill: #35232b; stroke: #ce7078; }
.fabric-node.offline > path { stroke: #965661; }
.fabric-node.offline > circle { fill: #ef767e; }
.fabric-node:focus-visible rect, .fabric-node:hover rect { stroke: #ffe3c2; stroke-width: 2.5; }
.network-readout { border-top: 1px solid var(--line); color: var(--ink); font-size: 0.62rem; letter-spacing: 0.06em; line-height: 1.7; margin-top: 1.4rem; min-height: 3.6rem; padding: 1rem 0; }
.fabric-metrics { border-top: 1px solid var(--line); display: grid; gap: 1.2rem; grid-template-columns: repeat(3, 1fr); padding: 1.2rem 0 1.4rem; }
.fabric-metrics span { color: var(--faint); display: block; font-size: 0.58rem; }
.fabric-metrics strong { color: var(--ink); display: block; font-size: clamp(1.5rem, 2.4vw, 2.2rem); font-stretch: 110%; font-weight: 560; letter-spacing: -0.04em; line-height: 1.1; margin-top: 0.4rem; }
.lab-copy { border-left: 1px solid var(--line); padding: 1.6rem 1.5rem; }
.index-number { color: var(--faint); font: 0.62rem var(--mono); font-stretch: 87.5%; letter-spacing: 0.13em; }
.lab-copy h3 { font-size: clamp(1.45rem, 1.9vw, 1.75rem); letter-spacing: -0.04em; line-height: 1.12; margin: 1.2rem 0 1rem; }
.lab-copy > p:not(.lab-status):not(.fine-print) { color: var(--muted); font-size: 0.88rem; line-height: 1.65; margin: 0; }
.lab-actions { align-items: flex-start; display: flex; flex-direction: column; gap: 0.3rem; margin-top: 1.4rem; }
.lab-copy .fine-print { margin-top: 1rem; }

/* ---------- 03 / The five exhibits ---------- */

.exhibit-nav { display: grid; grid-template-columns: repeat(5, 1fr); }
.exhibit-nav button { font-size: 0.92rem; font-weight: 500; letter-spacing: -0.01em; min-height: 4.6rem; padding: 0.5rem; }
.exhibit-nav button span { color: var(--faint); font: 0.6rem var(--mono); letter-spacing: 0.1em; transition: color 200ms ease; }
.exhibit-nav button[aria-pressed="true"] span { color: var(--ember); }
.exhibit-toolbar { align-items: center; color: var(--faint); display: flex; font-size: 0.6rem; gap: 1.25rem; justify-content: space-between; margin: 0.9rem 0; min-height: 2.75rem; }
.exhibit-toolbar button { color: var(--muted); font: 0.66rem var(--mono); font-stretch: 87.5%; letter-spacing: 0.06em; min-height: 2.75rem; transition: color 160ms ease; }
.exhibit-toolbar button:hover { color: var(--ember-soft); }

/* A newly chosen exhibit settles into place. */
.exhibit { animation: rise 520ms var(--ease) both; }
.exhibit-header { align-items: end; border-bottom: 1px solid var(--line); display: flex; gap: 2rem; justify-content: space-between; padding: 1.6rem 1.6rem 1.5rem; }
.exhibit-header .eyebrow { color: var(--ember-soft); font-size: 0.6rem; margin-bottom: 0.7rem; }
.exhibit-header h3 { font-size: clamp(1.7rem, 3.3vw, 3rem); font-stretch: 112%; letter-spacing: -0.045em; line-height: 1.05; }
.exhibit-header > span { color: var(--faint); font-size: 0.58rem; max-width: 15rem; text-align: right; }
.exhibit-grid { display: grid; grid-template-columns: minmax(0, 1fr) 22rem; }
.exhibit-visual { background: var(--well); min-height: 36rem; overflow: hidden; position: relative; }
.exhibit-visual > canvas { display: block; height: 100%; inset: 0; position: absolute; touch-action: pan-y; width: 100%; }
.exhibit-visual > canvas[tabindex], #ai-canvas { cursor: grab; }
.exhibit-visual > canvas:focus-visible { outline-offset: -4px; }
.robot-visual .canvas-corner { left: auto; right: 1.4rem; }
.canvas-corner { bottom: 1rem; color: var(--steel); display: flex; flex-wrap: wrap; font-size: 0.58rem; gap: 0.8rem; left: 1.4rem; pointer-events: none; position: absolute; }
.exhibit-controls { border-left: 1px solid var(--line); min-width: 0; padding: 1.6rem 1.5rem; }
.exhibit-controls h4 { font-size: 1.3rem; font-stretch: 106%; letter-spacing: -0.03em; line-height: 1.25; margin: 0 0 0.9rem; }
.exhibit-controls .fine-print { margin-top: 0.9rem; }

.candidate-bars { display: flex; flex-direction: column; gap: 0.45rem; margin: 1.3rem 0; }
.candidate-bars > div { background: var(--panel-2); border-radius: 6px; display: flex; font: 0.68rem var(--mono); font-stretch: 87.5%; justify-content: space-between; overflow: hidden; padding: 0.6rem 0.75rem; position: relative; }
.candidate-bars i { background: linear-gradient(90deg, rgba(255, 121, 72, 0.5), rgba(255, 121, 72, 0.28)); inset: 0 auto 0 0; position: absolute; transition: width 420ms var(--ease); }
.candidate-bars span, .candidate-bars b { font-weight: 400; position: relative; }
.candidate-bars b { color: var(--steel); }
.generation-output { background: var(--well); border-top: 1px solid var(--line); padding: 1.4rem 1.6rem; }
.generation-output > span { color: var(--steel); font-size: 0.58rem; }
.generation-output p { color: var(--ink); font-size: clamp(1.15rem, 2vw, 1.7rem); font-stretch: 106%; font-weight: 500; letter-spacing: -0.03em; line-height: 1.35; margin: 0.6rem 0 0; min-height: 2.2rem; }
.typing-caret { animation: caret 1s steps(2, jump-none) infinite; color: var(--ember); margin-left: 0.2em; }

.code-workbench { background: var(--well); min-width: 0; }
.editor-chrome { border-bottom: 1px solid var(--line); color: var(--steel); display: flex; font: 0.66rem var(--mono); font-stretch: 87.5%; gap: 0.6rem; justify-content: space-between; letter-spacing: 0.04em; padding: 1rem 1.4rem; }
.editor-chrome > span:first-child { align-items: center; display: flex; gap: 0.4rem; }
.editor-chrome i { background: #82615d; border-radius: 50%; display: inline-block; height: 8px; width: 8px; }
.editor-chrome i:nth-child(2) { background: #a79762; }
.editor-chrome i:nth-child(3) { background: #679f87; }
#code-source { font-size: 0.8rem; line-height: 2; margin: 0; min-height: 23rem; overflow: auto; padding: 1.4rem 1.2rem 1.4rem 0; tab-size: 2; }
.code-line { display: flex; }
.code-line > i { color: #4d6279; flex-shrink: 0; font: 0.6rem/2.65 var(--mono); font-style: normal; text-align: center; width: 3.4rem; }
.code-line code { color: #cfdbe8; font-family: var(--mono); font-stretch: 87.5%; }
.code-line .code-comment { color: #7c958e; }
.code-line .code-highlight { color: var(--ember-soft); }
.repl-output { background: #07090d; border-top: 1px solid var(--line); color: var(--teal); font: 0.72rem/2 var(--mono); font-stretch: 87.5%; min-height: 9.6rem; padding: 1.2rem 1.5rem; white-space: pre-wrap; }
.work-metrics { border-block: 1px solid var(--line); margin: 1.2rem 0; padding: 0.6rem 0; }
.work-metrics > div { align-items: center; display: flex; gap: 1rem; justify-content: space-between; margin: 0.7rem 0; }
.work-metrics span { color: var(--faint); font: 0.58rem var(--mono); font-stretch: 87.5%; letter-spacing: 0.1em; }
.work-metrics strong { color: var(--ember-soft); font: 1.45rem var(--mono); font-stretch: 87.5%; font-weight: 400; letter-spacing: -0.04em; }

.part-buttons, .reaction-select { display: flex; flex-wrap: wrap; gap: 0.45rem; margin: 1.1rem 0; }
.reaction-select { margin-top: 0; }
.part-buttons button, .reaction-select button { background: var(--panel-2); border: 1px solid var(--line-strong); border-radius: 8px; color: var(--muted); font: 0.68rem var(--mono); font-stretch: 87.5%; letter-spacing: 0.03em; min-height: 2.6rem; padding: 0 0.85rem; transition: background 200ms ease, border-color 200ms ease, color 200ms ease; }
.part-buttons button:hover, .reaction-select button:hover { border-color: var(--ember); color: var(--ink); }
.part-buttons button[aria-pressed="true"], .reaction-select button[aria-pressed="true"] { background: var(--ember-deep); border-color: var(--ember); color: var(--ember-soft); }
.motor-sliders { display: grid; gap: 1rem; grid-template-columns: 1fr 1fr; }
.motor-sliders .range-label { margin: 0.7rem 0; }
.robot-visual { min-height: 40rem; }
.robot-lower { border-top: 1px solid var(--line); display: grid; grid-template-columns: 1fr 22rem; min-height: 16rem; }
.robot-lower > div:first-child { background: var(--well); padding: 1.4rem 1.6rem; }
.firmware-label { color: var(--steel); font-size: 0.58rem; }
#robot-firmware { color: var(--teal); font: 0.72rem/1.9 var(--mono); font-stretch: 87.5%; margin: 1rem 0 0; overflow: auto; }
.rover-map { border-left: 1px solid var(--line); min-height: 16rem; position: relative; }
.rover-map canvas { height: 100%; inset: 0; position: absolute; width: 100%; }
.rover-map > span { bottom: 0.7rem; color: var(--steel); font-size: 0.58rem; left: 1rem; position: absolute; }

.reality-stage { height: clamp(22rem, 62vh, 38rem); overflow: hidden; position: relative; }
.reality-stage canvas { cursor: grab; display: block; height: 100%; touch-action: pan-y; width: 100%; }
.reality-hud { color: #d8eeec; display: flex; font-size: 0.6rem; justify-content: space-between; left: 1.5rem; pointer-events: none; position: absolute; right: 1.5rem; text-shadow: 0 1px 8px rgba(0, 0, 0, 0.7); top: 1.2rem; }
.reality-controls { align-items: center; border-block: 1px solid var(--line); display: flex; gap: 2rem; padding: 1rem 1.6rem; }
.reality-controls .range-label { flex: 1; margin: 0; }
.reality-controls .primary-button { max-width: 16rem; }
.reality-controls .text-button { white-space: nowrap; }
.perception-chain { align-items: center; display: flex; gap: 1.75rem; justify-content: space-between; padding: 2rem 1.6rem; }
.perception-chain > div { column-gap: 0.9rem; display: grid; flex: 1; grid-template-columns: 2.4rem 1fr; }
.perception-symbol { color: var(--teal); filter: drop-shadow(0 0 calc(var(--immersion, 0) * 10px) #6eddd5); font-size: 1.9rem; grid-row: 1 / 3; line-height: 1.1; }
.perception-chain strong { font-size: 1rem; font-weight: 560; letter-spacing: -0.02em; }
.perception-chain p { color: var(--muted); font-size: 0.8rem; line-height: 1.6; margin: 0.3rem 0 0; }
.perception-chain > span { color: var(--faint); }

.reaction-equation { color: var(--ember-soft); font-size: clamp(1.7rem, 2.6vw, 2.3rem); font-stretch: 106%; font-weight: 520; letter-spacing: -0.03em; line-height: 1.35; margin: 1.3rem 0; }
.reaction-equation > span { color: var(--steel); font-size: 0.62em; font-weight: 400; }
.atom-accounting { display: flex; gap: 1.6rem; margin: 1.3rem 0; }
.atom-accounting > span { color: var(--faint); font: 0.58rem var(--mono); font-stretch: 87.5%; letter-spacing: 0.1em; }
.atom-accounting b { color: var(--ink); display: block; font: 1.2rem var(--mono); font-stretch: 87.5%; font-weight: 400; margin-top: 0.5rem; }
.legend-proton { color: #eeb780; }
.legend-neutron { color: #98b9e6; }
.legend-electron { color: #a1e3df; }

.no-script-interests { color: var(--muted); font-size: 0.95rem; line-height: 1.8; }
.model-notes { border-bottom: 1px solid var(--line); color: var(--faint); font: 0.68rem/1.9 var(--mono); font-stretch: 87.5%; margin-top: 1.2rem; padding: 1.1rem 0; }
.model-notes summary { color: var(--muted); cursor: pointer; letter-spacing: 0.04em; padding: 0.4rem 0; transition: color 160ms ease; }
.model-notes summary:hover { color: var(--ember-soft); }
.model-notes p { max-width: 56rem; }
.model-notes a { color: var(--ember-soft); text-decoration: underline; text-underline-offset: 3px; }

/* ---------- 04 / The human, and the close ---------- */

.human { align-items: center; display: grid; gap: clamp(2.5rem, 7vw, 7rem); grid-template-columns: 1.5fr 1fr; }
.human-heading { border-top: 1px solid var(--line); padding-top: 1.1rem; position: relative; }
.human-heading::before { background: var(--ember); content: ""; height: 2px; left: 0; position: absolute; top: -1px; width: 3rem; }
.human .eyebrow { color: var(--ember); margin-bottom: clamp(1.8rem, 5vh, 3.4rem); }
.human h2 { font-size: clamp(2.3rem, 4.5vw, 4.9rem); }
.human h2 em { color: var(--ember); font-style: normal; }
.human-heading > p:not(.eyebrow) { color: var(--muted); font-size: clamp(1rem, 1.2vw, 1.18rem); line-height: 1.65; margin: 1.6rem 0 1.2rem; max-width: 31rem; text-wrap: pretty; }
/* A note pinned slightly off level: the family resemblance to the homepage. */
.human-note { background: linear-gradient(160deg, #1b1915, #14130f); border: 1px solid #3a352d; border-radius: 6px; box-shadow: 0 30px 80px rgba(0, 0, 0, 0.5); padding: 1.7rem 1.9rem; transform: rotate(2.4deg); transition: transform 600ms var(--ease); }
.human-note:hover { transform: rotate(0deg) scale(1.01); }
.human-note > .mono { color: #a49d90; font-size: 0.58rem; }
.asterisk { color: var(--ember); font-size: 3.8rem; line-height: 1; margin: 1.4rem 0 0.6rem; }
.human-note blockquote { font-size: clamp(1.5rem, 2.5vw, 2.2rem); font-stretch: 108%; font-weight: 560; letter-spacing: -0.04em; line-height: 1.18; margin: 0; }
.human-note > p { color: #a9a499; font-size: 0.8rem; line-height: 1.7; margin: 1rem 0 2.2rem; }
.human-note > .note-bottom { border-top: 1px solid #39362f; display: block; padding-top: 1rem; }

.closing { border-top: 1px solid var(--line); padding: clamp(3.5rem, 9vh, 6rem) 0 2.8rem; }
.closing > .eyebrow { color: var(--faint); }
.closing-title { font-size: clamp(2rem, 8.5vw, 9.4rem); font-stretch: 116%; font-weight: 640; letter-spacing: -0.06em; line-height: 0.92; margin: clamp(1.4rem, 4vh, 2.4rem) 0 clamp(2rem, 6vh, 3.4rem); position: relative; }
.closing-title > span:first-of-type { color: var(--ember); }
.closing-star { color: var(--ember); display: inline-block; font-size: 0.7em; font-stretch: 100%; margin-left: 0.12em; transition: transform 500ms var(--ease); }
.closing-title:hover .closing-star { transform: translate(0.08em, -0.08em); }
.closing-bottom { align-items: center; color: var(--muted); display: flex; font-size: 0.84rem; gap: 1.5rem; justify-content: space-between; }
.closing-bottom .text-button span { color: var(--ember); margin-left: 0.8rem; }

.footer { align-items: center; border-top: 1px solid var(--line); color: var(--faint); display: flex; font-size: 0.58rem; gap: 1.5rem; justify-content: space-between; padding: 1.5rem var(--gutter); }
.footer > a { align-items: center; display: inline-flex; min-height: 2.75rem; transition: color 160ms ease; }
.footer > a:first-child { color: var(--ink); }
.footer > a:first-child span { color: var(--faint); margin-left: 1.2rem; }
.footer a:hover, .footer a:hover span { color: var(--ember-soft); }

/* ---------- Dialogs ---------- */

dialog { background: #10141a; border: 1px solid var(--line-strong); border-radius: var(--radius); box-shadow: 0 30px 160px rgba(0, 0, 0, 0.75); color: var(--ink); max-height: 80vh; max-height: 80svh; padding: 0; width: min(44rem, calc(100% - 2rem)); }
dialog::backdrop { backdrop-filter: blur(14px); background: rgba(5, 6, 9, 0.8); }
dialog[open] { animation: dialog-in 320ms var(--ease); }
.observatory-close { color: var(--muted); font: 0.7rem var(--mono); font-stretch: 87.5%; letter-spacing: 0.06em; min-height: 2.75rem; position: absolute; right: 1.25rem; top: 0.5rem; transition: color 160ms ease; z-index: 4; }
.observatory-close:hover { color: var(--ember-soft); }

#observatory, #particle-observatory { background: var(--bg); max-height: 96vh; max-height: 96svh; max-width: 1800px; overflow: auto; width: 96vw; }
#observatory { height: 94vh; height: 94svh; }
#observatory .solar-stage { display: flex; flex-direction: column; gap: 0.9rem; height: 100%; inset: auto; padding: 3.5rem 1.25rem 1.25rem; position: relative; }
#observatory .solar-view { border: 1px solid var(--line); border-radius: 10px; flex: 1; inset: auto; min-height: 15rem; position: relative; }
#observatory .solar-view::after, #observatory #solar-expand, #observatory .scroll-cue { display: none; }
#observatory .solar-dock { bottom: auto; left: auto; position: relative; right: auto; }
#particle-observatory { padding: 3.5rem 1rem 1rem; }
#particle-observatory .point-stage { height: calc(94svh - 20rem); min-height: 16rem; }
#particle-observatory #point-expand { display: none; }

#console { overflow: hidden; }
.console-header { align-items: center; border-bottom: 1px solid var(--line); color: var(--steel); display: flex; font-size: 0.64rem; justify-content: space-between; padding: 0.9rem 1.25rem; }
.console-header button { background: var(--panel-2); border-radius: 6px; color: var(--muted); font: 0.62rem var(--mono); min-height: 2.2rem; padding: 0 0.7rem; }
.console-header button:hover { color: var(--ember-soft); }
.console-output { font: 0.78rem/1.8 var(--mono); font-stretch: 87.5%; height: 18rem; max-height: 45vh; overflow-wrap: anywhere; overflow-y: auto; padding: 0.6rem 1.4rem 1.2rem; white-space: pre-wrap; }
.console-output p { margin: 0.6rem 0; }
.console-output .command-entry { color: var(--ember-soft); margin-top: 1.1rem; }
#console-form { align-items: center; border-top: 1px solid var(--line); display: flex; gap: 0.9rem; padding: 1rem 1.25rem; }
#console-input { background: none; border: 0; color: var(--ink); flex: 1; font: 0.84rem var(--mono); font-stretch: 87.5%; min-width: 0; outline: none; }
#console-input:focus-visible { outline: 1px solid var(--ember); outline-offset: 7px; }
#console-form > button { color: var(--ember); font-size: 1.35rem; min-height: 2.75rem; min-width: 2.75rem; }
.console-hints { background: #0b0d11; color: var(--faint); display: flex; font-size: 0.56rem; justify-content: space-between; padding: 0.75rem 1.25rem; }

/* ---------- Motion ---------- */

@keyframes pulse { 50% { box-shadow: 0 0 20px rgba(255, 121, 72, 0.9); opacity: 0.75; } }
@keyframes caret { 50% { opacity: 0; } }
@keyframes ticker { to { transform: translateX(-100%); } }
@keyframes dialog-in { from { opacity: 0; transform: translateY(14px) scale(0.985); } }
@keyframes rise { from { opacity: 0; transform: translateY(22px); } }
@keyframes line-up { from { transform: translateY(108%); } }
@keyframes drift { 50% { transform: translateY(5px); } }
@keyframes sky-in { from { opacity: 0; } }

.reveals-on .reveal { opacity: 0; transform: translateY(30px); transition: opacity 900ms var(--ease), transform 900ms var(--ease); }
.reveals-on .reveal.is-in { opacity: 1; transform: none; }
/* The pinned note keeps its tilt once it has arrived. */
.reveals-on .human-note.reveal { transform: translateY(30px) rotate(5deg); }
.reveals-on .human-note.reveal.is-in { transform: rotate(2.4deg); }
.reveals-on .human-note.reveal.is-in:hover { transform: rotate(0deg) scale(1.01); }

@media (prefers-reduced-motion: no-preference) {
  /* `intro` is set before first paint and removed a few seconds later, so moving the
     observatory into and out of its dialog never replays the entrance. */
  .intro .solar-view { animation: sky-in 1400ms ease both; }
  .intro .hero-line > span { animation: line-up 1000ms var(--ease) both; }
  .intro .hero-accent > span { animation-delay: 110ms; }
  .intro .hero-copy .eyebrow, .intro .hero-description, .intro .hero-subcopy, .intro .hero-copy .primary-link, .intro .solar-dock { animation: rise 900ms var(--ease) both; }
  .intro .hero-copy .eyebrow { animation-delay: 60ms; }
  .intro .hero-description { animation-delay: 320ms; }
  .intro .hero-subcopy { animation-delay: 420ms; }
  .intro .hero-copy .primary-link { animation-delay: 520ms; }
  .intro .solar-dock { animation-delay: 700ms; }
  .scroll-cue > span { animation: drift 1.8s ease-in-out infinite; }

  /* Arriving from the homepage: the Matrix falls away and the lab comes forward.
     The opt-in itself (@view-transition) is inline in the page head, so it is
     always known before first paint. */
  ::view-transition-old(root) { animation: 340ms ease-in both leave-world; }
  ::view-transition-new(root) { animation: 620ms var(--ease) 120ms both enter-world; }
}
@keyframes leave-world { to { filter: blur(6px); opacity: 0; transform: scale(1.08); } }
@keyframes enter-world { from { opacity: 0; transform: scale(0.965); } }

.motion-paused *, .motion-paused *::before, .motion-paused *::after { animation-play-state: paused !important; }
.motion-paused { scroll-behavior: auto; }
.motion-paused .reveal { opacity: 1 !important; transform: none; transition: none; }
.motion-paused .human-note.reveal { transform: rotate(2.4deg); }
/* Anything that animates in from invisible must not be left paused on its first frame. */
.motion-paused .hero-line > span, .motion-paused .hero-copy *, .motion-paused .solar-dock, .motion-paused .solar-view, .motion-paused .exhibit, .motion-paused dialog[open] { animation: none !important; }

/* ---------- Narrower screens ---------- */

@media (max-width: 1180px) {
  .network-lab { grid-template-columns: minmax(0, 1fr) 19rem; }
  .exhibit-grid { grid-template-columns: minmax(0, 1fr) 19.5rem; }
  .robot-lower { grid-template-columns: 1fr 19.5rem; }
  .solar-console { grid-template-columns: minmax(13rem, 0.7fr) minmax(0, 2fr); }
  .orbit-tilt-control { margin-left: 0; }
  .masthead nav a { font-size: 0.76rem; }
  .command-button { font-size: 0; gap: 0; }
  .command-button kbd { font-size: 0.62rem; }
}

@media (max-width: 960px) {
  /* The observatory takes its own band beneath the headline. */
  .hero { min-height: 0; padding: calc(var(--masthead) + 0.6rem) 0 0; }
  .hero-coordinate, .hero-copy { margin-inline: var(--gutter); }
  .hero-copy { margin-block: clamp(1.6rem, 6vh, 3.5rem) 0; max-width: none; padding-block: 0; pointer-events: auto; }
  .hero h1 { font-size: clamp(2.6rem, 12.6vw, 7rem); }
  .solar-stage { inset: auto; margin-top: 0.5rem; position: relative; }
  .solar-view { height: min(62vh, 27rem); height: min(62svh, 27rem); inset: auto; position: relative; }
  .solar-view::after { background: linear-gradient(0deg, var(--bg) 0%, transparent 10%), linear-gradient(180deg, var(--bg) 0%, transparent 8%); }
  .solar-view .scene-expand { right: var(--gutter); top: 2.6rem; }
  .scene-fallback { inset: 74% 10% auto; }
  .solar-stage:not(.scene-ready) .solar-view { background-position: -16vw 0; }
  .solar-dock { bottom: auto; left: auto; margin: -0.5rem var(--gutter) 0; padding-bottom: 1.5rem; position: relative; right: auto; }
  .solar-console { grid-template-columns: 1fr; }
  .planet-brief { border-bottom: 1px solid var(--line); border-right: 0; }
  .network-lab, .exhibit-grid, .robot-lower { grid-template-columns: 1fr; }
  .lab-copy, .exhibit-controls, .rover-map { border-left: 0; border-top: 1px solid var(--line); }
  .lab-actions { align-items: center; flex-direction: row; flex-wrap: wrap; gap: 0.3rem 1.4rem; }
  .lab-actions .primary-button, .control-actions .primary-button { max-width: 22rem; }
  .stage-pipeline { grid-template-columns: repeat(4, 1fr); }
  .demo-explanation { min-height: 0; }
  .exhibit-visual { min-height: 30rem; }
  .robot-visual { min-height: 34rem; }
  .rover-map { height: 17rem; }
  .exhibit-nav button { flex-direction: column; gap: 0.35rem; }
  .human { grid-template-columns: 1fr; }
  .human-note { max-width: 28rem; }
  .footer > span { display: none; }
}

@media (max-width: 760px) {
  :root { --masthead: 4.1rem; }
  .masthead nav { display: none; }
  .command-button { margin-left: auto; }
  .wordmark { font-size: 0.74rem; }
  .brand-icon { font-size: 1.7rem; margin-right: 0.8rem; }
  .exit-link > span { display: none; }
  .hero-coordinate > span, .section-aside, .exhibit-header > span, .perception-chain > span, .reality-hud > span:last-child, .lab-topline > span:last-child { display: none; }
  .hero-bottom { flex-wrap: wrap; gap: 0 1.2rem; justify-content: space-between; }
  .scroll-cue { display: none; }
  .solar-controls-row, .solar-orbit-controls { gap: 0.3rem 1rem; justify-content: space-between; padding: 0.6rem 1rem; }
  .orbit-tilt-control { flex-basis: 100%; justify-content: space-between; }
  .orbit-tilt-control input { flex: 1; max-width: 9rem; }
  .orbit-tilt-control output { min-width: 0; text-align: right; }
  .signal-track { animation-duration: 32s; }
  .section-intro { grid-template-columns: 1fr; gap: 1.2rem; }
  .section-intro > p { max-width: none; }
  .point-stage { height: clamp(22rem, 60vh, 30rem); }
  .point-topline { padding: 0.85rem 1rem; }
  .point-topline > span:last-child { max-width: 9rem; text-align: right; }
  .point-forms { grid-template-columns: repeat(2, 1fr); }
  .point-forms button { min-height: 3.6rem; }
  .point-forms button:nth-child(2) { border-right: 0; }
  .point-forms button:nth-child(n + 3) { border-top: 0; }
  .point-count { left: 1.1rem; top: 3.4rem; }
  .point-reticle-a { left: 1rem; top: 1rem; }
  .point-reticle-b { bottom: 1rem; right: 1rem; }
  .point-axis { bottom: 1rem; left: 1.1rem; }
  .point-settings { justify-content: space-between; padding: 0.9rem 1rem; }
  .point-settings .range-label { flex-basis: 40%; max-width: none; }
  .point-bottom { align-items: flex-start; flex-direction: column; gap: 0.5rem; padding: 0.9rem 1rem; }
  .point-bottom > span { text-align: left; }
  .lab-visual { padding: 1rem 0.8rem 0; }
  /* The fabric keeps a readable scale and scrolls sideways instead of shrinking. */
  .fabric-stage { overflow-x: auto; padding-bottom: 0.75rem; }
  .fabric-stage svg { height: 288px; max-width: none; width: 700px; }
  .fabric-stage canvas { height: 288px; width: 700px; }
  .lab-copy { padding: 1.4rem 1.1rem; }
  .exhibit-nav { grid-template-columns: repeat(3, 1fr); }
  .exhibit-nav button { border-bottom: 1px solid var(--line); font-size: 0.78rem; min-height: 4rem; }
  .exhibit-nav button:nth-child(3) { border-right: 0; }
  .exhibit-nav button:nth-child(n + 4) { border-bottom: 0; }
  .exhibit-nav button:last-child { grid-column: span 2; }
  .exhibit-toolbar > span { max-width: 12rem; }
  .exhibit-header { align-items: start; padding: 1.25rem 1.1rem; }
  .exhibit-visual { min-height: 24rem; }
  .robot-visual { min-height: 27rem; }
  .exhibit-controls { padding: 1.4rem 1.1rem; }
  .exhibit-note, .generation-output { padding-inline: 1.1rem; }
  .canvas-corner { left: 1.1rem; right: 0.7rem; }
  .reality-stage { height: 22rem; }
  .reality-controls { flex-wrap: wrap; gap: 0.6rem 1.4rem; padding: 1.1rem; }
  .reality-controls .range-label { flex-basis: 100%; }
  .reality-controls .primary-button { flex: 1; max-width: none; width: auto; }
  .perception-chain { align-items: flex-start; gap: 0.9rem; padding: 1.5rem 1.1rem; }
  .perception-chain > div { display: flex; flex-direction: column; gap: 0.4rem; }
  .code-line > i { width: 2.2rem; }
  #code-source { font-size: 0.68rem; min-height: 18rem; }
  .repl-output { font-size: 0.66rem; padding: 1.1rem; }
  .robot-lower > div:first-child { padding: 1.25rem 1.1rem; }
  .closing-bottom { align-items: flex-start; flex-direction: column; gap: 0.6rem; }
  .footer { align-items: flex-start; flex-direction: column; gap: 0.2rem; }
  .console-hints > span:nth-child(2) { display: none; }
  #observatory, #particle-observatory { width: 98vw; }
  #observatory .solar-stage { padding: 3.2rem 0.5rem 0.75rem; }
  #particle-observatory { padding: 3.2rem 0.4rem 0.4rem; }
  #particle-observatory .point-stage { height: calc(96svh - 27rem); }
}

@media (max-width: 370px) {
  .wordmark-light, .wordmark-divider { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveals-on .reveal { opacity: 1; transform: none; }
  .reveals-on .human-note.reveal { transform: rotate(2.4deg); }
}

@media print {
  .reveal { opacity: 1 !important; transform: none !important; }
}
