/* Noon's page. The aurora and grain come from the Pixel Pane site; the colours
   are the noonlight theme (snehithnayak.github.io/themes): a warm near-black,
   cream text, an amber accent, and aqua, pink and green for the three agents.
   The app shares them: docs/BRAND.md in its repository. */

:root {
  --ink: #0b0a08;                 /* theme: panel, title bar */
  --edge: #0f0e0c;                /* theme: editor background */
  --edge-clear: rgba(15, 14, 12, 0);
  --paper: #ebdbb2;               /* theme: foreground */
  --bright: #fbf1c7;              /* theme: bright white; headings */
  --muted: #a89984;               /* theme: text.muted */
  --faint: #928374;               /* theme: terminal dim foreground (5.3:1 on --edge) */
  --line: #27231d;                /* theme: border.variant */
  --line-strong: rgba(235, 219, 178, 0.22);
  --glass: rgba(235, 219, 178, 0.04);
  --glass-edge: #332f29;          /* theme: border */
  --surface: rgba(18, 16, 13, 0.78);  /* theme: surface.background */
  --card: #181511;                /* theme: elevated surface */
  --hover: #211d18;               /* theme: element.hover */
  --active: #2c2418;              /* theme: element.active, secondary button */
  --amber: #d8a657;               /* theme: accent; "needs approval", modified files */
  --orange: #e78a4e;              /* theme: button hover */
  --green: #a9b665;               /* theme: created; "finished", new files */
  --aqua: #7daea3;                /* theme: info, links */
  --term: #0c0a09;                /* theme: terminal.background */
  --term-fg: #d4be98;             /* theme: terminal.foreground */
  --warn-bg: #352712;             /* theme: warning.background */
  --warn-edge: #75551f;           /* theme: warning.border */
  --ok-edge: #395334;             /* theme: created.border */
  --sans: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", system-ui, Helvetica, Arial, sans-serif;
  --display: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", system-ui, Helvetica, Arial, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;
  --maxw: 1040px;
  --gutter: max(clamp(16px, 5vw, 56px), env(safe-area-inset-left, 0px), env(safe-area-inset-right, 0px));
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --r: 8px;                       /* panels and cards: a canvas, not a brochure */
  --r-s: 4px;                     /* buttons, chips, tags */
  --mark: rgba(125, 174, 163, 0.55);  /* crop marks on the big frames */
}

/* JetBrains Mono, self-hosted (SIL OFL 1.1, fonts/OFL.txt): one variable
   file covers weights 400–600; the range is Google Fonts' latin subset. */
@font-face {
  font-family: "JetBrains Mono";
  font-style: normal;
  font-weight: 400 600;
  font-display: swap;
  src: url("fonts/jetbrains-mono-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

*, *::before, *::after { box-sizing: border-box; }
/* Public downloads are opt-in; this also works with JavaScript disabled. */
html:not([data-downloads-enabled="true"]) [data-download-only],
html[data-downloads-enabled="true"] [data-beta-only] { display: none !important; }
html { background: var(--edge); color-scheme: dark; }
body {
  margin: 0;
  background: var(--edge);
  color: var(--paper);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  letter-spacing: -0.01em;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
/* The aurora: screen blending over near-black keeps it vivid. Noon light is
   warm, so amber leads; aqua, pink and green sit at the edges. The layer is
   120% of the viewport, just enough for the drift, and the drift stops after
   four passes so panels' backdrop blur isn't redrawn forever. */
body::before {
  content: "";
  position: fixed;
  inset: -10%;
  z-index: 0;
  pointer-events: none;
  background-color: var(--ink);
  background-image:
    radial-gradient(40% 34.67% at -0.67% -6%,       rgba(216, 166, 87, 0.34), transparent 64%),
    radial-gradient(32% 26.67% at 76.67% -11.33%,   rgba(231, 138, 78, 0.24), transparent 64%),
    radial-gradient(26.67% 24% at 108.67% 15.33%,   rgba(125, 174, 163, 0.24), transparent 64%),
    radial-gradient(32% 29.33% at 98% 76.67%,       rgba(211, 134, 155, 0.2), transparent 68%),
    radial-gradient(42.67% 37.33% at 42% 111.33%,   rgba(216, 166, 87, 0.3), transparent 66%),
    radial-gradient(32% 29.33% at -6% 79.33%,       rgba(169, 182, 101, 0.2), transparent 68%),
    radial-gradient(29.33% 32% at -14% 36.67%,      rgba(125, 174, 163, 0.22), transparent 64%),
    radial-gradient(29.33% 26.67% at 111.33% 108.67%, rgba(231, 138, 78, 0.18), transparent 68%);
  background-blend-mode: screen;
  animation: drift 68s ease-in-out 0s 4 alternate both;
}
@keyframes drift {
  from { transform: translate3d(-1.5%, -1%, 0) scale(1.02); }
  to   { transform: translate3d(1.5%, 1.5%, 0) scale(1.08); }
}
/* A canvas dot grid and film grain over the aurora, under the content; the
   edges fade to --edge. The grid is what the agents' wireframes snap to. */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background-image:
    linear-gradient(to bottom, var(--edge), var(--edge-clear) 72px),
    linear-gradient(to top, var(--edge), var(--edge-clear) 104px),
    radial-gradient(rgba(235, 219, 178, 0.085) 1px, transparent 1.3px),
    url("grain.png?v=1");
  background-size: 100% 100%, 100% 100%, 24px 24px, 160px 160px;
  background-repeat: no-repeat, no-repeat, repeat, repeat;
}
::selection { background: rgba(216, 166, 87, 0.28); }
a { color: inherit; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--amber); outline-offset: 2px; }

.wrap {
  position: relative;
  z-index: 2;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* ── hero ───────────────────────────────────────────────── */
.eye {
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--aqua);
  margin: 0 0 18px;
}
.eye b { font-weight: 500; color: var(--faint); margin-right: 10px; }
.hero { padding-top: clamp(40px, 7vw, 84px); }
.hero h1 { margin: 0 0 28px; line-height: 0; }
.hero h1 .logo { display: block; width: auto; max-width: 100%; aspect-ratio: 1134 / 256; height: clamp(44px, 7vw, 72px); filter: drop-shadow(0 12px 30px rgba(216, 166, 87, 0.18)); }
.sub {
  font-family: var(--display);
  font-weight: 600;
  font-size: clamp(28px, 4.4vw, 50px);
  line-height: 1.06;
  letter-spacing: -0.03em;
  color: var(--bright);
  max-width: 20ch;
  margin: 0 0 34px;
}
/* The agent counter in the tagline (counter.js): numbers roll in like an
   odometer, smear as they speed up, and land on a ∞ that draws itself. */
.sub .count {
  position: relative;
  display: inline-block;
  white-space: nowrap;
  color: var(--amber);
  font-variant-numeric: tabular-nums;
  text-shadow: 0 0 calc(var(--blur, 0) * 0.4em) rgba(216, 166, 87, 0.55);
  transition: width 0.32s var(--ease);
}
.sub .count .d {
  display: inline-block;
  filter: blur(calc(var(--blur, 0) * 0.08em));
  transform: scaleY(calc(1 + var(--blur, 0) * 0.18));
  opacity: calc(1 - var(--blur, 0) * 0.2);
}
.sub .count .in { animation: count-in 0.3s var(--ease) both; }
.sub .count .out { position: absolute; left: 0; bottom: 0; animation: count-out 0.3s var(--ease) both; }
@keyframes count-in { from { transform: translateY(0.5em); opacity: 0; filter: blur(0.06em); } }
@keyframes count-out { to { transform: translateY(-0.5em); opacity: 0; filter: blur(0.06em); } }
.sub .count .inf {
  display: inline-block;
  width: 1.5em;
  height: 0.75em;
  margin: 0 0.04em;
  vertical-align: -0.02em;
  overflow: visible;
  fill: none;
  stroke-linecap: round;
  stroke-width: 8;
  filter: drop-shadow(0 0 0.14em rgba(216, 166, 87, 0.35));
}
.sub .count .inf .base { stroke: var(--amber); stroke-dasharray: 1; stroke-dashoffset: 0; }
.sub .count .inf .glint { stroke: var(--bright); stroke-dasharray: 0.07 0.93; opacity: 0; }
/* The landing: the blurred number keeps smearing, stretches and burns out
   into a flare, and the ∞ comes out of it, focusing as it draws itself. */
.sub .count .melt {
  position: absolute; left: 0; bottom: 0;
  animation: count-melt 0.55s cubic-bezier(0.4, 0, 0.2, 1) both;
}
@keyframes count-melt {
  from { filter: blur(0.08em); transform: scale(1, 1.18); opacity: 0.8; }
  40% { filter: blur(0.12em) brightness(1.6); opacity: 0.9; }
  to { filter: blur(0.3em) brightness(2); transform: scale(1.9, 0.5); opacity: 0; }
}
.sub .count::after {
  content: "";
  position: absolute;
  left: 50%; top: 52%;
  width: 3.2em; height: 1.6em;
  transform: translate(-50%, -50%);
  background: radial-gradient(closest-side, rgba(251, 241, 199, 0.55), rgba(216, 166, 87, 0.3) 45%, transparent);
  mix-blend-mode: screen;
  opacity: 0;
  pointer-events: none;
}
.sub .count.landed::after { animation: count-flare 1.1s cubic-bezier(0.2, 0, 0, 1) both; }
@keyframes count-flare {
  0% { opacity: 0; transform: translate(-50%, -50%) scale(0.4, 0.6); }
  22% { opacity: 1; }
  100% { opacity: 0; transform: translate(-50%, -50%) scale(1.5, 1.1); }
}
.sub .count.landed .inf { animation: inf-arrive 0.95s cubic-bezier(0.22, 1, 0.36, 1) 0.08s both; }
.sub .count.landed .inf .base { animation: inf-draw 1.2s cubic-bezier(0.65, 0, 0.35, 1) 0.08s both; }
.sub .count.landed .inf .glint { animation: inf-glint-in 0.6s ease 1.2s forwards, inf-glint 3.2s linear 1.2s infinite; }
@keyframes inf-arrive {
  from { opacity: 0; transform: scale(1.35, 0.85); filter: blur(0.16em) drop-shadow(0 0 0.5em rgba(216, 166, 87, 0.9)); }
  45% { opacity: 1; }
  to { opacity: 1; transform: none; filter: blur(0) drop-shadow(0 0 0.14em rgba(216, 166, 87, 0.35)); }
}
@keyframes inf-draw { from { stroke-dashoffset: 1; } }
@keyframes inf-glint-in { to { opacity: 0.85; } }
@keyframes inf-glint { from { stroke-dashoffset: 0; } to { stroke-dashoffset: -1; } }
.cta { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 28px; }
.cta > div { display: grid; gap: 4px; }
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-family: var(--mono);
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 14px 22px;
  border-radius: var(--r-s);
  border: 0;
  background: var(--amber);
  color: var(--edge);
  text-decoration: none;
  cursor: pointer;
  box-shadow: 0 0 0 0 rgba(216, 166, 87, 0);
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease), background 0.3s var(--ease);
}
@media (hover: hover) { .btn:hover { background: var(--orange); transform: translateY(-1px); box-shadow: 0 0 0 4px rgba(231, 138, 78, 0.18); } }
.btn svg { width: 15px; height: 15px; }
.btn.alt { background: transparent; color: var(--paper); border: 1px solid var(--line-strong); box-shadow: none; }
@media (hover: hover) { .btn.alt:hover { background: var(--hover); color: var(--bright); box-shadow: none; } }
.btn[hidden] { display: none; }
.btn:active { transform: scale(0.98); }
.fine { font-family: var(--mono); font-size: 12px; letter-spacing: 0.02em; color: var(--faint); margin: 0; }
.brew code { color: var(--muted); overflow-wrap: anywhere; user-select: all; }
.works { font-size: 14px; color: var(--muted); margin: 0; }
.works b { font-weight: 500; color: var(--paper); }

/* ── sections ───────────────────────────────────────────── */
section.block { margin-top: clamp(64px, 9vw, 104px); padding-top: 26px; border-top: 1px solid var(--line); }
.head { margin-bottom: 22px; display: grid; grid-template-columns: minmax(0, 1fr); gap: 0 32px; }
.head .eye { margin-bottom: 14px; }
.head h2 {
  font-family: var(--display);
  font-weight: 600;
  font-size: clamp(26px, 3.4vw, 36px);
  letter-spacing: -0.025em;
  line-height: 1.1;
  margin: 0 0 8px;
  color: var(--bright);
}
.head p { margin: 0; color: var(--muted); font-size: 16px; max-width: 52ch; }
.hint { font-family: var(--mono); font-size: 11.5px; color: var(--faint); letter-spacing: 0.02em; }
.below { margin: 12px 0 0; }

/* Keyframes run only while their demo is on screen (the ticker adds .live). */
.demo:not(.live) *, .demo:not(.live) { animation-play-state: paused !important; }

/* shared bits */
.pill {
  border: 0;
  border-radius: var(--r-s);
  padding: 5px 12px;
  font: 600 11.5px var(--mono);
  cursor: pointer;
  transition: transform 0.2s var(--ease), opacity 0.2s, background 0.2s;
}
@media (hover: hover) { .pill:hover:not(:disabled) { transform: translateY(-1px); } }
.pill:disabled { cursor: not-allowed; opacity: 0.35; }
.pill[hidden] { display: none; }
.state { font-family: var(--mono); font-size: 11px; white-space: nowrap; }
.state::before { content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%; margin-right: 5px; vertical-align: 1px; background: currentColor; }
.state.preparing { color: var(--faint); }
.state.working { color: var(--muted); }
.state.working::before { animation: blink 1.2s ease-in-out infinite; }
.state.ask { color: var(--amber); }
.state.finished { color: var(--green); }
.state.stopped { color: var(--faint); }
.state.stopped::before { background: transparent; border: 1px solid currentColor; }
@keyframes blink { 50% { opacity: 0.25; } }
.ask-box {
  font-size: 12.5px;
  color: var(--amber);
  background: var(--warn-bg);
  border: 1px solid var(--warn-edge);
  border-radius: var(--r-s);
  padding: 8px 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.ask-box[hidden] { display: none; }
.approve { background: var(--amber); color: var(--edge); }
@media (hover: hover) { .approve:hover:not(:disabled) { background: var(--orange); } }
.panel {
  border: 1px solid var(--glass-edge);
  border-radius: var(--r);
  background: rgba(18, 16, 13, 0.6);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
/* Crop marks at the corners of the big frames: the page's own selection handles. */
.window, .panel { position: relative; }
.window::before, .window::after, .panel::before, .panel::after {
  content: "";
  position: absolute;
  width: 7px;
  height: 7px;
  pointer-events: none;
  z-index: 1;
}
.window::before, .panel::before { left: -1px; top: -1px; border-left: 1px solid var(--mark); border-top: 1px solid var(--mark); }
.window::after, .panel::after { right: -1px; bottom: -1px; border-right: 1px solid var(--mark); border-bottom: 1px solid var(--mark); }

/* ── 1. the window and its map ──────────────────────────── */
.window {
  border: 1px solid var(--glass-edge);
  border-radius: var(--r);
  background: var(--surface);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 40px 80px -56px rgba(0, 0, 0, 0.95);
}
.window > * { border-radius: inherit; }
.win-body { border-radius: 0 0 var(--r) var(--r); overflow: hidden; }
.titlebar {
  height: 38px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 14px;
  border-bottom: 1px solid var(--line);
  font-family: var(--mono);
  font-size: 12px;
  color: var(--faint);
}
.titlebar i { width: 11px; height: 11px; border-radius: 50%; background: rgba(235, 219, 178, 0.16); }
.titlebar span { margin-left: 8px; color: var(--muted); }
.titlebar em { margin-left: auto; font-style: normal; text-transform: uppercase; letter-spacing: 0.14em; font-size: 10px; }
.win-body { display: grid; grid-template-columns: 272px minmax(0, 1fr); }
.side { border-right: 1px solid var(--line); padding: 12px; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.label { font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--faint); margin: 2px 6px 6px; }
.task {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr);
  gap: 1px 10px;
  align-items: center;
  width: 100%;
  text-align: left;
  padding: 9px 10px;
  border-radius: var(--r-s);
  border: 1px solid transparent;
  background: transparent;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s;
}
@media (hover: hover) { .task:hover { background: var(--glass); } }
.task[aria-pressed="true"] { background: var(--hover); border-color: var(--line-strong); }  /* --hover, not --active: keeps 11px state text at 4.5:1 */
.num {
  grid-row: span 2;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font: 600 11.5px var(--mono);
  color: var(--edge);
  background: var(--c);
}
.t-title { font-size: 14px; font-weight: 500; line-height: 1.3; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.t-meta { font-family: var(--mono); font-size: 11px; color: var(--muted); display: flex; gap: 8px; white-space: nowrap; overflow: hidden; }
.changes { margin-top: 10px; border-top: 1px solid var(--line); padding: 12px 6px 4px; min-height: 214px; display: flex; flex-direction: column; gap: 10px; }
.ch-title { font-size: 13px; font-weight: 500; margin: 0; display: flex; align-items: center; gap: 8px; }
.ch-title .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--c); flex: none; }
.status {
  margin: 0;
  font-family: var(--mono);
  font-size: 11.5px;
  line-height: 1.75;
  color: var(--muted);
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.status .new { color: var(--green); }
.status .mod { color: var(--amber); }
.status .ok { color: var(--paper); }
.merge { background: var(--amber); color: var(--edge); align-self: flex-start; }
@media (hover: hover) { .merge:hover:not(:disabled) { background: var(--orange); } }
.canvas {
  position: relative;
  min-width: 0;
  background-image: radial-gradient(rgba(235, 219, 178, 0.1) 1px, transparent 1.3px);
  background-size: 24px 24px;
}
.canvas svg { display: block; width: 100%; height: auto; }
.canvas .hint { position: absolute; left: 14px; bottom: 10px; pointer-events: none; }

.edge { stroke: rgba(235, 219, 178, 0.24); stroke-width: 1.5; transition: stroke 0.25s, stroke-width 0.25s, opacity 0.25s; }
.edge.config { stroke-dasharray: 5 4; }
.edge.hot { stroke: rgba(235, 219, 178, 0.85); stroke-width: 2.6; }
.card { transition: opacity 0.25s; }
.card rect { fill: var(--card); stroke: var(--glass-edge); stroke-width: 1; transition: stroke 0.25s; }
.card .name { fill: var(--paper); font: 600 15px var(--display); letter-spacing: -0.01em; }
.card .kind { fill: var(--faint); font: 500 9px var(--mono); letter-spacing: 0.14em; }
svg.hovering .card:not(.hot) { opacity: 0.3; }
svg.hovering .edge:not(.hot) { opacity: 0.12; }
.card.hot rect { stroke: var(--amber); stroke-width: 1.5; }
.card.mine rect { stroke: var(--sel); stroke-width: 1.5; stroke-dasharray: 5 4; }
.card.flash rect { animation: flash 1s ease-out; }
@keyframes flash { from { stroke: var(--fc); stroke-width: 3; } }
.shared { display: none; }
.card.has-shared .shared { display: inline; }
.shared circle { stroke: var(--card); stroke-width: 2; fill-opacity: 0.9; }
.token { transition: transform 0.95s var(--ease), opacity 0.4s; }
.token.hidden { opacity: 0; }
.token .body { fill: var(--c); stroke: var(--edge); stroke-width: 2; transform-box: fill-box; transform-origin: center; }
.token.edited .body { animation: bump 0.5s var(--ease); }
@keyframes bump { 40% { transform: scale(1.25); } }
.token .n { fill: var(--edge); font: 700 11px var(--mono); text-anchor: middle; dominant-baseline: central; }
.token .file { fill: var(--c); font: 500 10px var(--mono); text-anchor: middle; }
.token .ring { fill: none; stroke: var(--c); stroke-width: 2; opacity: 0; transform-box: fill-box; transform-origin: center; }
.token.working .ring { animation: ring 1.6s ease-out infinite; }
.token.ask .ring { stroke: var(--amber); animation: ring 1.4s ease-out infinite; }
@keyframes ring { from { opacity: 0.85; transform: scale(1); } to { opacity: 0; transform: scale(2.1); } }
.token .q { display: none; }
.token.ask .q { display: inline; }
.token .q circle { fill: var(--amber); stroke: var(--edge); stroke-width: 1.5; }
.token .q text { fill: var(--edge); font: 700 8px var(--mono); text-anchor: middle; dominant-baseline: central; }
.token.sel .body { stroke: var(--bright); stroke-width: 2.5; }

/* ── 2. workspaces ──────────────────────────────────────── */
.ws {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 70px minmax(0, 1.25fr);
  align-items: center;
  gap: 8px;
  padding: 18px;
}
.repo, .copy, .slot { border-radius: var(--r-s); }
.repo { background: var(--card); border: 1px solid var(--glass-edge); padding: 14px 16px; }
.tree-head { margin: 0 0 8px; display: flex; justify-content: space-between; gap: 10px; font-family: var(--mono); font-size: 12px; }
.tree-head b { font-weight: 600; white-space: nowrap; }
.tree-head span { color: var(--faint); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tree { list-style: none; margin: 0; padding: 0; font-family: var(--mono); font-size: 12px; line-height: 1.8; color: var(--muted); }
.tree li { display: flex; justify-content: space-between; gap: 10px; }
.tree .mod { color: var(--amber); font-weight: 600; }
.tree .ign { color: var(--faint); }
.tree .ign i { font-style: normal; font-size: 11px; }
.repo .pill { margin-top: 12px; background: var(--amber); color: var(--edge); }
@media (hover: hover) { .repo .pill:hover:not(:disabled) { background: var(--orange); } }
.ws-arrow { position: relative; height: 2px; background: linear-gradient(90deg, rgba(235, 219, 178, 0.1), rgba(235, 219, 178, 0.5)); }
.ws-arrow::after {
  content: "";
  position: absolute;
  right: -1px;
  top: -4px;
  border: 5px solid transparent;
  border-left: 7px solid rgba(235, 219, 178, 0.5);
  border-right: 0;
}
.ws-arrow span {
  position: absolute;
  left: 50%;
  bottom: 8px;
  transform: translateX(-50%);
  font-family: var(--mono);
  font-size: 10.5px;
  color: var(--faint);
  white-space: nowrap;
}
.copies { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.copy {
  background: var(--card);
  border: 1px solid var(--glass-edge);
  border-left: 3px solid var(--c);
  padding: 10px 14px;
  animation: arrive 0.5s var(--ease);
  transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
}
.copy .tree-head { margin-bottom: 2px; }
.copy .tree { display: flex; gap: 14px; }
.copy.freeing { opacity: 0; transform: scale(0.96); }
@keyframes arrive { from { opacity: 0; transform: translateX(-10px); } }
.copy-foot { display: flex; align-items: center; gap: 10px; margin-top: 6px; }
.tag { font-family: var(--mono); font-size: 10.5px; color: var(--green); border: 1px solid var(--ok-edge); border-radius: 3px; padding: 0 7px; }
.tag[hidden] { display: none; }
.free { margin-left: auto; background: var(--active); color: var(--paper); border: 1px solid var(--glass-edge); }
.slot { border: 1px dashed rgba(235, 219, 178, 0.14); min-height: 92px; }

/* ── 3. terminals ───────────────────────────────────────── */
.terms { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 12px; transition: grid-template-columns 0.5s var(--ease); }
@media (min-width: 761px) {
  .terms:has(.term:nth-child(1).front) { grid-template-columns: 1.6fr 1fr 1fr; }
  .terms:has(.term:nth-child(2).front) { grid-template-columns: 1fr 1.6fr 1fr; }
  .terms:has(.term:nth-child(3).front) { grid-template-columns: 1fr 1fr 1.6fr; }
}
.term {
  min-width: 0;
  display: flex;
  flex-direction: column;
  background: var(--term);
  border: 1px solid var(--glass-edge);
  border-top: 2px solid var(--c);
  border-radius: var(--r);
  overflow: hidden;
  cursor: pointer;
  transition: opacity 0.3s, box-shadow 0.3s, border-color 0.3s;
}
/* Terminals at the back stay readable (4.5:1): they fade only a little, and
   lose their glow and top stripe instead. */
.term:not(.front) { opacity: 0.92; border-top-color: color-mix(in srgb, var(--c) 45%, var(--glass-edge)); }
.term.front { cursor: default; box-shadow: 0 30px 60px -36px var(--c); }
.term-head {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  padding: 9px 12px;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: rgba(235, 219, 178, 0.03);
  text-align: left;
  cursor: inherit;
  font-family: var(--mono);
  font-size: 11.5px;
  white-space: nowrap;
}
.term-head .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--c); flex: none; }
.term-head .who { color: var(--muted); overflow: hidden; text-overflow: ellipsis; }
.term-head .state { margin-left: auto; }
.term-out {
  margin: 0;
  height: 232px;
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  overflow: hidden;
  font-family: var(--mono);
  font-size: 11.5px;
  line-height: 1.6;
  color: var(--term-fg);
}
.term-out span { display: block; white-space: pre; overflow: hidden; text-overflow: ellipsis; animation: line 0.25s ease-out; }
@keyframes line { from { opacity: 0; } }
.term-out .cmd { color: var(--bright); }
.term-out .dim { color: var(--faint); }
.term-out .new { color: var(--green); }
.term-out .mod { color: var(--amber); }
.term-out .ok { color: var(--green); }
.term-out .ask { color: var(--amber); }
.term .ask-box { margin: 0 10px 10px; }

/* ── 4. branches ────────────────────────────────────────── */
#git-panel { padding: 10px 6px 4px; }
#git-panel svg { display: block; width: 100%; height: auto; }
.trunk { stroke: rgba(235, 219, 178, 0.4); stroke-width: 3; fill: none; }
.trunk-label { fill: var(--muted); font: 600 11px var(--mono); }
.sha-label { fill: var(--faint); font: 500 10px var(--mono); }
.lane { fill: none; stroke: var(--c); stroke-width: 3; stroke-linecap: round; }
.lane-label { fill: var(--c); font: 500 11px var(--mono); }
.g-dot { fill: var(--c); stroke: var(--edge); stroke-width: 2.5; }
.g-dot.new { animation: pop 0.5s var(--ease); transform-box: fill-box; transform-origin: center; }
@keyframes pop { from { transform: scale(0); } }
.merged-lane { opacity: 0.4; }
.merge-path { fill: none; stroke: var(--c); stroke-width: 3; stroke-linecap: round; }
.merge-path.new { stroke-dasharray: 400; stroke-dashoffset: 400; animation: draw 0.9s var(--ease) forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }
.m-dot { fill: var(--c); stroke: var(--paper); stroke-width: 2.5; }
.m-dot.new { animation: pop 0.5s var(--ease) 0.75s both; transform-box: fill-box; transform-origin: center; }
.g-pill { cursor: pointer; }
.g-pill rect { fill: var(--amber); transition: fill 0.2s; }
.g-pill text { fill: var(--edge); font: 600 11px var(--mono); text-anchor: middle; dominant-baseline: central; }
@media (hover: hover) { .g-pill:hover rect { fill: var(--orange); } }
.g-pill:focus { outline: none; }
.g-pill:focus-visible rect { stroke: var(--c); stroke-width: 3; }
.g-wait { fill: var(--faint); font: 500 11px var(--mono); }

/* ── trust ──────────────────────────────────────────────── */
.facts {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
.facts li {
  background: var(--card);
  border: 1px solid var(--glass-edge);
  border-radius: var(--r);
  padding: 16px 18px;
  font-size: 15px;
  line-height: 1.5;
  color: var(--muted);
}
.facts b { display: block; margin-bottom: 4px; font-weight: 600; color: var(--bright); }

/* ── questions ──────────────────────────────────────────── */
.faq { max-width: 760px; border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  list-style: none;
  cursor: pointer;
  padding: 16px 32px 16px 2px;
  position: relative;
  font-weight: 500;
  color: var(--paper);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  position: absolute;
  right: 6px;
  top: 50%;
  transform: translateY(-50%);
  font: 500 18px var(--mono);
  color: var(--amber);
  transition: transform 0.3s var(--ease);
}
.faq details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
@media (hover: hover) { .faq summary:hover { color: var(--bright); } }
.faq p { margin: 0 0 18px; padding-right: 32px; color: var(--muted); font-size: 16px; }
.faq code { font-family: var(--mono); font-size: 0.88em; color: var(--paper); }
.faq a { color: var(--aqua); }

/* ── get started ────────────────────────────────────────── */
.chips { list-style: none; margin: 4px 0 26px; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.chips li { font-family: var(--mono); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); border: 1px solid var(--line-strong); border-radius: var(--r-s); padding: 6px 11px; }
.steps {
  max-width: 460px;
  margin: 0 0 28px;
  padding: 0;
  list-style: none;
  counter-reset: step;
  display: grid;
  gap: 10px;
}
.steps li { counter-increment: step; display: flex; gap: 12px; align-items: baseline; color: var(--muted); font-size: 16px; }
.steps li::before {
  content: counter(step);
  flex: none;
  width: 22px;
  height: 22px;
  border-radius: 3px;
  display: inline-grid;
  place-items: center;
  font: 600 11.5px var(--mono);
  color: var(--edge);
  background: var(--amber);
  transform: translateY(-1px);
}
.center { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 28px; }
.center .brew { margin: 0; }

footer {
  margin-top: clamp(64px, 9vw, 100px);
  padding-top: 18px;
  padding-bottom: calc(36px + env(safe-area-inset-bottom, 0px));
  border-top: 1px solid var(--line);
  font-family: var(--mono);
  font-size: 12px;
  color: var(--faint);
}
.f-row { display: flex; flex-wrap: wrap; gap: 8px 22px; align-items: baseline; }
footer a { color: var(--muted); text-decoration: none; }
@media (hover: hover) { footer a:hover { color: var(--aqua); } }
footer details { margin-top: 12px; }
footer summary { cursor: pointer; color: var(--muted); }
footer code { display: block; margin-top: 6px; overflow-wrap: anywhere; color: var(--muted); }
footer p { margin: 12px 0 0; line-height: 1.6; max-width: 72ch; }

/* ── touch ──────────────────────────────────────────────── */
/* Words for the pointer you have: "Click" with a mouse, "Tap" with a finger. */
.on-touch { display: none; }
@media (hover: none) and (pointer: coarse) {
  .on-mouse { display: none; }
  .on-touch { display: inline; }
}
a, button, summary, .task, .term { -webkit-tap-highlight-color: transparent; }
@media (pointer: coarse) {
  /* Thumb-sized targets: at least 40px tall. */
  .pill { padding: 11px 16px; font-size: 12.5px; }
  .ask-box { padding: 8px 8px 8px 12px; }
  .task { padding: 12px 10px; }
  .faq summary { padding-top: 19px; padding-bottom: 19px; }
  .f-row { gap: 0 22px; }
  .f-row a { display: inline-block; padding: 11px 0; }
  footer summary { padding: 10px 0; }
  .pill:active:not(:disabled), .task:active, .faq summary:active { opacity: 0.75; }
}

/* ── phones ─────────────────────────────────────────────── */
@media (max-width: 760px) {
  .win-body { grid-template-columns: minmax(0, 1fr); }
  .side { border-right: 0; border-bottom: 1px solid var(--line); }
  .changes { min-height: 0; }
  .canvas .hint { display: none; }
  .btn { width: 100%; }
  .cta { gap: 12px; }
  .cta > div { width: 100%; }
  .sub { max-width: none; }
  .ws { grid-template-columns: minmax(0, 1fr); padding: 14px; }
  .ws-arrow { width: 2px; height: 44px; justify-self: center; background: linear-gradient(180deg, rgba(235, 219, 178, 0.1), rgba(235, 219, 178, 0.5)); }
  .ws-arrow::after { right: auto; left: -4px; top: auto; bottom: -1px; border: 5px solid transparent; border-top: 7px solid rgba(235, 219, 178, 0.5); border-bottom: 0; }
  .ws-arrow span { left: 12px; bottom: auto; top: 50%; transform: translateY(-50%); }
  .terms { grid-template-columns: minmax(0, 1fr); }
  .term-out { height: 74px; transition: height 0.4s var(--ease); }
  .term.front .term-out { height: 214px; }
  .facts { grid-template-columns: minmax(0, 1fr); }
}

@media (prefers-reduced-transparency: reduce) {
  .panel, .window { backdrop-filter: none; -webkit-backdrop-filter: none; background: #12100d; }
}

@media (prefers-reduced-motion: reduce) {
  body::before { animation: none; }
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}
