/* ============================================================
   WANDERERS: component styles
   Styling for the site frame and Zola's markdown output.
   Depends on tokens.css (loaded first).
   ============================================================ */

/* pinned footer: the frame is a full-height flex column and .framebody
   grows to fill it, so the footer is anchored to the bottom of the viewport
   (dvh = the "dynamic" viewport height that accounts for mobile browser bars),
   not to the content. The results list can never push it. */
.frame { max-width: 1180px; margin: 0 auto; padding: 24px 32px 60px;
  display: flex; flex-direction: column; min-height: 100vh; min-height: 100dvh; }
.framebody { flex: 1 0 auto; }

/* --- telemetry strip (shared frame) --- */
.telemetry { display: flex; align-items: center; gap: 10px; padding: 7px 14px;
  border: 1px solid var(--hairline); background: var(--bg); font-size: 10px; letter-spacing: var(--tracking);
  text-transform: uppercase; color: var(--ink-3); }
.telemetry .segment { border: 1px solid var(--hairline); padding: 2px 8px; display: inline-flex; gap: 6px; align-items: center; }
.telemetry .reading { color: var(--ink-2); }
.telemetry .spacer { flex: 1; }
/* error state (404 only): dead red lamp, no breathe, and red status words */
.telemetry .lamp.off { background: var(--red-text); }
.telemetry .reading.off { color: var(--red-text); }

/* segmented plate: a running readout split into hairline-divided compartments.
   Self-contained so it reads identically in the telemetry strip
   and the 404 status line. Sits as a peer of the plain .segment pills. */
.segplate { display: inline-flex; align-items: stretch; border: 1px solid var(--hairline); }
.segplate .compartment { padding: 2px 9px; display: inline-flex; align-items: center; white-space: nowrap; }
.segplate .compartment + .compartment { border-left: 1px solid var(--hairline); }
.segplate .compartment.off { color: var(--red-text); }
.lamp { width: 6px; height: 6px; background: var(--signal-green); display: inline-block; }
.breathe { animation: breathe 3.3s ease-in-out infinite; }
@keyframes breathe { 0%, 100% { opacity: 1; } 50% { opacity: .3; } }
@media (prefers-reduced-motion: reduce) {
  .breathe { animation: none; }
  .blink { animation: none; }
  .lampbank .bar { transition: none; }
  .orbit-rotate { animation: none; }
  .empty-blink { animation: none; }
}

/* --- masthead tab bar (shared frame) --- */
.masthead { display: flex; align-items: stretch; border: 1px solid var(--hairline); border-top: 0; background: var(--bg); }
.masthead .brand { padding: 11px 18px; border-right: 1px solid var(--hairline); color: var(--ink);
  font-size: 12px; letter-spacing: var(--tracking-wide); text-transform: uppercase; text-decoration: none;
  transition: background-color .12s linear, color .12s linear; }
/* hover: invert the brand cell; ink/bg are the ramp's two poles and flip together, so this reads
   as a clean block in both themes (light-on-dark in dark mode, dark-on-light in light mode) */
.masthead .brand:hover { background: var(--ink); color: var(--bg); }
.tab { padding: 11px 18px; font-size: 10px; letter-spacing: var(--tracking);
  text-transform: uppercase; color: var(--ink-3); border-right: 1px solid var(--hairline);
  display: flex; align-items: center; text-decoration: none; }
.tab:hover { color: var(--ink-2); }
.tab.active { color: var(--ink); background: var(--bg-panel); }
.masthead .spacer { flex: 1; border-right: 1px solid var(--hairline); }
.masthead .search { padding: 11px 18px; font-size: 10px; letter-spacing: var(--tracking);
  text-transform: uppercase; color: var(--ink-2); text-decoration: none; display: flex; align-items: center; gap: 9px; }
.masthead .search:hover { color: var(--ink); }
/* key-cap hint: the "/" that opens the palette, styled like the overlay's footer keys.
   Hidden where "/" can't apply: the narrow reflow, and touch devices with no keyboard. */
.search-key { font-family: var(--mono); font-size: 9px; line-height: 1.4; color: var(--ink-3);
  border: 1px solid var(--hairline); border-radius: 2px; padding: 1px 5px; letter-spacing: 0; }
.masthead .search:hover .search-key { color: var(--ink-2); border-color: var(--ink-3); }
@media (hover: none) { .search-key { display: none; } }
.masthead .tabs { display: flex; align-items: stretch; }

/* ============ RECORD SHELL ============ */
.head { margin-top: 30px; }
.doc { border: 1px solid var(--hairline); border-top: 0; background: var(--bg); }
.accent-rule { height: 5px; background: var(--thread, var(--hue-neutral)); }
.namebanner { display: flex; flex-direction: column; padding: 16px 18px; border-bottom: 1px solid var(--hairline); }
.namebanner-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; }
/* eyebrow: conjoined plate above the title. th_eyebrow is an array of parts; each
   non-empty part renders as its own compartment (looped in partials/titlehead.html).
   The cells carry the neutral bg-panel fill and dim text, divided by hairlines, the
   same grammar as the masthead cells and the record back-link. A single part
   (e.g. "Tool", "Introduction") renders as one filled cell. */
.eyebrow-chip { display: inline-flex; align-items: stretch; border: 1px solid var(--hairline);
  font-size: 10px; letter-spacing: var(--tracking-wide); text-transform: uppercase; color: var(--ink-3); }
.eyebrow-chip .compartment { padding: 4px 9px; background: var(--bg-panel); display: inline-flex; align-items: center; white-space: nowrap; }
.eyebrow-chip .compartment + .compartment { border-left: 1px solid var(--hairline); }
/* stack the eyebrow chip above the title (both are inline-level on their own) */
.namebanner-row > div:first-child { display: flex; flex-direction: column; align-items: flex-start; }
.title { display: inline-block; margin: 8px 0 0; padding-bottom: 10px;
  border-bottom: 3px solid var(--ink-2);
  font-size: 46px; line-height: .98; letter-spacing: .02em;
  text-transform: uppercase; font-weight: 500; }
.namerule { height: 1px; background: var(--hairline); }
.datamatrix { flex: none; } .datamatrix rect { fill: var(--ink-2); }

/* dossier band: infobox rail as a horizontal grid, caps at 6 cols, wraps to rows.
   Self-closing borders: each cell draws its own right + bottom hairline and pulls up 1px
   so the shared line collapses to 1px; .cells carries the outer bottom. A partial last row
   stays bounded on every side (no dropped hairline on the short row). */
.band .cells { display: grid; grid-template-columns: repeat(6, 1fr); border-bottom: 1px solid var(--hairline); }
.band .cell { padding: 13px 16px 14px; border-right: 1px solid var(--hairline);
  border-bottom: 1px solid var(--hairline); margin-bottom: -1px;
  display: flex; flex-direction: column; min-height: 64px; }
.band .cell:nth-child(6n) { border-right: 0; }
.band .key { font-size: 10px; letter-spacing: var(--tracking); text-transform: uppercase; color: var(--ink-3); }
/* Multi-value cells stack one value per line (like the footer's link columns),
   not joined on one line. Each value is its own element (see planet/species.html). */
.band .value { margin-top: 8px; display: flex; flex-direction: column; align-items: flex-start; gap: 3px;
  font-size: 15px; line-height: 1.2; color: var(--ink); letter-spacing: var(--tracking);
  text-transform: uppercase; font-variant-numeric: tabular-nums; }
/* merged void (every record band's tail): populated cells are padded with
   silent .blank cells up to the next full row; the blanks drop their vertical dividers
   so the run reads as one continuous void (hidden entirely below the 6-column layout). */
.band.merged .cell.blank { border-right: 0; }
/* event band: five quick-facts fill one exact row (the type lives in the eyebrow). */
.band.cols-5 .cells { grid-template-columns: repeat(5, 1fr); }
.band.cols-5 .cell:nth-child(6n) { border-right: 1px solid var(--hairline); }
.band.cols-5 .cell:nth-child(5n) { border-right: 0; }

/* conditional image band (rendered only when a record declares art) */
.figband { border-bottom: 1px solid var(--hairline); background: var(--bg);
  padding: 24px; display: flex; flex-direction: column; align-items: center; gap: 10px; }
.figband .portrait { width: 100%; max-width: 640px; aspect-ratio: 16/9; border: 1px solid var(--hairline);
  background: var(--void); display: flex; align-items: center; justify-content: center;
  color: var(--ink-3); font-size: 40px; }
.figband .credit { font-size: 9px; letter-spacing: var(--tracking); text-transform: uppercase; color: var(--ink-3); }
.figband .credit a { color: var(--ink-2); text-decoration: none; border-bottom: 1px solid var(--ink-4); }
.figband .credit a:hover { color: var(--hue-blue); border-bottom-color: var(--hue-blue); }

/* --- event participants (labeled bars below the band) ---
   A stack of full-width bars: a primary block of labeled groups (sides) or a flat
   list (participants), then one bar per secondary role. Hairline-separated, flat. */
.parties { border-bottom: 1px solid var(--hairline); }
.parties > * + * { border-top: 1px solid var(--hairline); }
.party-bar { display: flex; align-items: baseline; gap: 12px; padding: 13px 18px 12px; }
.party-bar .key { font-size: 10px; letter-spacing: var(--tracking-wide); text-transform: uppercase; color: var(--ink-3); }
/* labeled groups: equal columns set by --gcols (the number of sides), one hairline between */
.groups { display: grid; grid-template-columns: repeat(var(--gcols, 2), 1fr); }
.group { padding: 15px 18px 17px; }
.group + .group { border-left: 1px solid var(--hairline); }
.group-key { display: inline-block; font-size: 12px; letter-spacing: var(--tracking); text-transform: uppercase;
  color: var(--ink); border-bottom: 2px solid var(--ink-2); padding-bottom: 5px; }
.group-value { margin-top: 13px; display: flex; flex-direction: column; align-items: flex-start; gap: 8px;
  font-size: 14px; letter-spacing: var(--tracking); text-transform: uppercase; }
/* flat group (participants) and secondary-role rows: a wrapped cross-link list */
.flatgroup, .participant-row { display: flex; flex-wrap: wrap; gap: 9px 22px; padding: 14px 18px 16px;
  font-size: 15px; letter-spacing: var(--tracking); text-transform: uppercase; }

/* quotes (character records): a small gray key + tight blockquote list above the prose */
.prose-key { font-size: 10px; letter-spacing: var(--tracking); text-transform: uppercase; color: var(--ink-3); margin: 0 0 12px; }
.prose.quotes { margin-bottom: 24px; }
.prose.quotes blockquote { margin: 0 0 14px; }
.prose.quotes blockquote:last-child { margin-bottom: 0; }

/* --- article / prose (markdown body) --- */
.docbody { padding: 30px 34px 34px; }
.prose { max-width: none; }
.prose > :first-child { margin-top: 0; }
.prose p { margin: 0 0 16px; font-size: 13.5px; line-height: 1.75; color: var(--ink-2); }
.prose strong, .prose b { color: var(--ink); font-weight: 600; }
.prose em, .prose i { font-style: italic; }

/* headings: heavy uppercase readout over a full-width hairline (the "Atlas" head),
   with a far-right data-matrix deep-link mark (from insert_anchor_links) */
.prose h2 { display: flex; align-items: flex-end; gap: 12px; margin: 34px 0 14px;
  font-size: 13px; letter-spacing: var(--tracking-wide); text-transform: uppercase;
  color: var(--ink); font-weight: 600; border-bottom: 1px solid var(--hairline); padding-bottom: 8px; }
.prose h3 { display: flex; align-items: flex-end; gap: 12px; margin: 26px 0 10px; font-size: 11px;
  letter-spacing: var(--tracking); text-transform: uppercase; color: var(--ink); font-weight: 600; }
.prose h4 { display: flex; align-items: flex-end; gap: 12px; margin: 20px 0 8px; font-size: 10px;
  letter-spacing: var(--tracking); text-transform: uppercase; color: var(--ink-3); }

/* anchor mark: neutral at rest, thread hue on hover */
.anchor { text-decoration: none; color: var(--ink-3); line-height: 1;
  display: inline-flex; align-items: center; justify-content: center; }
.anchor:hover, .anchor:focus-visible { color: var(--thread, var(--hue-neutral)); outline: none; }
.anchor.trail { margin-left: auto; margin-bottom: 2px; }
.anchor svg { display: block; width: 12px; height: 12px; }
.anchor svg rect { fill: currentColor; }

/* title mark (H1 / section index): same permalink + thread-hue-on-hover behavior as the
   section anchors, but keeps its full 52px size and ink-2 rest color (overrides .anchor above). */
.datamatrix-link { flex: none; color: var(--ink-2); }
.datamatrix-link .datamatrix { width: 52px; height: 52px; }
.datamatrix-link .datamatrix rect { fill: currentColor; }
/* neutral marks set --thread to --ink-2 (== the mark's rest), so a thread-hue hover shows nothing;
   brighten to --ink instead. Covers the index/search/home pages and any hueless record
   (body.neutral-thread, flagged in core.html). Hued records keep the thread-hue reveal. */
.intro .datamatrix-link:hover, .intro .datamatrix-link:focus-visible,
.idxmain .datamatrix-link:hover, .idxmain .datamatrix-link:focus-visible,
.search-page .datamatrix-link:hover, .search-page .datamatrix-link:focus-visible,
.neutral-thread .datamatrix-link:hover, .neutral-thread .datamatrix-link:focus-visible { color: var(--ink); }

/* lists */
.prose ul, .prose ol { margin: 0 0 16px; }
.prose ul { list-style: none; padding-left: 4px; }
.prose ul > li { position: relative; padding-left: 20px; }
.prose ul > li::before { content: ""; position: absolute; left: 3px; top: .72em; width: 5px; height: 5px; background: var(--ink-4); }
.prose ol { padding-left: 22px; }
.prose ol > li::marker { color: var(--ink-3); font-variant-numeric: tabular-nums; }
.prose li { font-size: 13.5px; line-height: 1.7; color: var(--ink-2); margin: 0 0 8px; }
.prose li > ul, .prose li > ol { margin: 8px 0 0; }

/* in-body cross-links: neutral at rest and when visited, thread hue on hover (per-entity body hues are a follow-up) */
.prose a:not(.anchor) { --thread: var(--ink-2); color: var(--ink); text-decoration: none; border-bottom: 1px solid var(--ink-4); }
.prose a:not(.anchor):visited { color: var(--ink); }
.prose a:not(.anchor):hover { color: var(--thread); border-bottom-color: var(--thread); }

.prose blockquote { margin: 20px 0; padding: 4px 0 4px 18px; border-left: 3px solid var(--thread, var(--hue-neutral));
  color: var(--ink); font-style: italic; font-size: 15px; line-height: 1.7; }
.prose code { font-family: var(--mono); font-size: .85em; border: 1px solid var(--hairline);
  padding: .1em .4em; background: var(--bg-panel); }
.prose hr { border: 0; border-top: 1px solid var(--hairline); margin: 26px 0; }

/* --- backlink (shared frame) --- */
.backlink { display: inline-flex; align-items: stretch; border: 1px solid var(--hairline);
  margin: 44px 0 0; color: var(--ink-2); text-decoration: none; background: var(--bg);
  font-size: 11px; letter-spacing: var(--tracking); text-transform: uppercase; }
.backlink .cell { padding: 10px 12px; border-right: 1px solid var(--hairline); display: flex; align-items: center; }
.backlink .caption { padding: 10px 14px; display: flex; align-items: center; }
.backlink:hover { border-color: var(--ink-2); color: var(--ink); }
.chevron { width: 7px; height: 7px; border-top: 1.5px solid currentColor; border-right: 1.5px solid currentColor;
  display: inline-block; transform: rotate(-135deg); }

/* --- Signal Bank footer (shared frame) --- */
.footer { border: 1px solid var(--hairline); margin-top: 48px; background: var(--bg); }
.footer .cols { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; }
.footer .col { padding: 16px 18px 20px; border-right: 1px solid var(--hairline); }
.footer .col:last-child { border-right: 0; }
.footer .col.signal { display: flex; flex-direction: column; gap: 16px; }
.footer .mark-row { display: flex; align-items: center; gap: 12px; }
.footer .brand { font-size: 14px; letter-spacing: var(--tracking-wide); text-transform: uppercase; color: var(--ink); text-decoration: none; }
.footer .key { font-size: 10px; letter-spacing: var(--tracking); text-transform: uppercase; color: var(--ink-3); margin-bottom: 12px; }
.footer .col a { display: block; font-size: 11px; letter-spacing: var(--tracking);
  text-transform: uppercase; color: var(--ink-2); text-decoration: none; padding: 4px 0; }
.footer .col a:hover { color: var(--ink); }
.footer .footer-telemetry { display: flex; align-items: center; gap: 10px; padding: 7px 14px;
  border-top: 1px solid var(--hairline); font-size: 10px; letter-spacing: var(--tracking);
  text-transform: uppercase; color: var(--ink-3); }
.footer .footer-telemetry .segment { border: 1px solid var(--hairline); padding: 2px 8px; }
.footer .footer-telemetry .reading { color: var(--ink-2); }
.footer .footer-telemetry .spacer { flex: 1; }
/* Rev + mark travel as one unit so the mark can't orphan onto its own line when the bar wraps */
.footer .footer-telemetry .teleset { display: inline-flex; align-items: center; gap: 10px; }
.footer .lampwrap { display: flex; flex-direction: column; gap: 10px; }
.lampbank { display: grid; grid-template-columns: repeat(5, 34px); grid-auto-rows: 6px; gap: 8px; }
.lampbank .bar { width: 34px; height: 6px; background: var(--ink-4); transition: background-color .4s linear; }
.lampbank .bar.on { background: var(--thread, var(--signal-green)); }

/* ============ TITLE-PLATE (shared: section indexes, home, search) ============ */
/* the capped title cell: accent-rule + titleplate wrapping partials/titlehead.html,
   standalone above whatever follows; neutral cap (these carry no entity thread hue) */
.titlehead { margin-top: 30px; }
.titleplate { border: 1px solid var(--hairline); border-top: 0; background: var(--bg); }
.idxmain .sheet, .idxmain .sheet-empty { margin-top: 30px; }

/* contact sheet: plates fill the row (3 across like the reference; 2 then 1 as it
   narrows) so they stay large. Seamless shared hairlines come from collapsing each
   plate's border into its neighbor's (negative margins), NOT a gray container fill,
   so empty cells in a sparse section show the plain page field, with no gray box. */
.sheet { display: grid; grid-template-columns: repeat(3, 1fr); }
.plate { position: relative; aspect-ratio: 1 / 1;
  background: var(--void); text-decoration: none; overflow: hidden; --thread: var(--ink-2);
  border: 1px solid var(--hairline); margin: 0 -1px -1px 0; }
.plate .art { position: absolute; inset: 0; display: flex; align-items: center;
  justify-content: center; color: var(--ink-4); font-size: 28px; transition: color .15s linear; }
.namebox { position: absolute; left: 14px; right: 14px; bottom: 14px;
  border: 1px solid var(--hairline); background: var(--bg-panel); padding: 12px 28px 12px 14px;
  transition: border-color .15s linear, background-color .15s linear; }
/* vertical lamp: spans the two-line namebox height (the footer signal bar, rotated).
   height:auto overrides the global telemetry .lamp { height:6px } so top/bottom can stretch it. */
.namebox .lamp { position: absolute; top: 12px; bottom: 12px; right: 12px; width: 6px;
  height: auto; background: var(--ink-4); transition: background-color .15s linear; }
.namebox .name { display: block; font-size: 18px; line-height: 1.05; letter-spacing: .02em; text-transform: uppercase;
  color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; transition: color .15s linear; }
.namebox .subtitle { display: block; margin-top: 7px; font-size: 9px; letter-spacing: var(--tracking);
  text-transform: uppercase; color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.plate:hover { border-color: var(--thread); z-index: 1; }  /* lift above neighbors' overlapping borders */
.plate:hover .namebox { border-color: var(--thread); }
.plate:hover .namebox .lamp { background: var(--thread); }
.plate:hover .name { color: var(--thread); }
.plate:hover .art { color: color-mix(in srgb, var(--thread) 55%, var(--ink-4)); }
.sheet-empty { border: 1px solid var(--hairline); background: var(--bg); padding: 20px; color: var(--ink-3);
  font-size: 11px; letter-spacing: var(--tracking); text-transform: uppercase; }

/* ============ HOME (intro document) ============ */
.intro .prose { margin-top: 30px; }  /* gap below the title-plate; prose spans the full frame */

/* the "Latest Records" home block: Atlas section head (thick label-width accent over a
   thin full-width hairline) above the shared contact sheet. */
.featured { margin-top: 44px; }
.featured .h-atlas-head { display: flex; align-items: flex-end; gap: 12px; }
.featured .h-atlas { display: inline-block; margin: 0; padding-bottom: 8px;
  border-bottom: 2px solid var(--ink-2); font-size: 13px; letter-spacing: var(--tracking-wide);
  text-transform: uppercase; color: var(--ink); }
/* the mark is a sibling of .h-atlas, not a child like the prose-h2 marks, so the heading's
   8px padding + 2px accent border sit inside the flex row and drag flex-end alignment down.
   Raise margin-bottom past that 10px so the mark rides against the text, matching the prose marks. */
.featured .h-atlas-head .anchor.trail { margin-bottom: 12px; }
.featured .h-atlas-rule { height: 1px; background: var(--hairline); margin: 0 0 18px; }

/* ============ 404: range lock ============ */
.error { margin-top: 30px; }
.status-bar { display: flex; align-items: stretch; border: 1px solid var(--signal-red); background: var(--signal-red);
  color: var(--bg); font-family: var(--mono); font-size: 11px; letter-spacing: var(--tracking); text-transform: uppercase; }
.status-bar .category { min-width: 124px; padding: 8px 12px; font-weight: 600; display: flex; align-items: center; }
.status-bar .message { padding: 8px 12px; display: flex; align-items: center; }
.status-bar .reference { margin-left: auto; min-width: 96px; padding: 8px 12px; display: flex; align-items: center; justify-content: flex-end; }
.error-phrase { font-size: clamp(48px, 8vw, 84px); line-height: .88; letter-spacing: .02em; text-transform: uppercase; color: var(--ink); font-weight: 600; }
.error-code { margin-top: 16px; font-size: 12px; letter-spacing: var(--tracking); text-transform: uppercase; color: var(--ink); }
.error-sub  { margin-top: 6px; font-size: 10px; letter-spacing: var(--tracking); text-transform: uppercase; color: var(--ink-3); }
.actions { margin-top: 24px; display: flex; gap: 10px; flex-wrap: wrap; }
.button { font-size: 10px; letter-spacing: var(--tracking); text-transform: uppercase; color: var(--ink-2);
  text-decoration: none; border: 1px solid var(--hairline); padding: 9px 14px; background: var(--bg-panel);
  transition: border-color .15s linear, color .15s linear; }
.button:hover { color: var(--ink); border-color: var(--ink-2); }
.button.primary { color: var(--ink); border-color: var(--ink-3); }

.barcode { display: inline-flex; flex-direction: column; gap: 6px; }
.barcode .datamatrix { display: block; width: 44px; height: 44px; }
.barcode .datamatrix rect { fill: var(--ink-2); }

.scope { width: 100%; height: auto; display: block; }
/* graduated tick bar (partials/ruler.html): keep the hairline ticks pixel-crisp */
.ruler line { shape-rendering: crispEdges; }
.orbit-rotate { animation: spin 90s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.empty-blink { animation: breathe 3.3s ease-in-out infinite; }

.hud-frame { border: 1px solid var(--hairline); background: var(--bg); }
.a-lock { padding: 30px 28px 26px; }
.a-lock .stage { position: relative; max-width: 460px; margin: 8px auto 4px; }
.a-lock .readout { text-align: center; margin-top: 6px; }
.status-strip { display: flex; justify-content: space-between; align-items: center; gap: 10px;
  padding: 7px 16px; font-size: 10px; letter-spacing: var(--tracking); text-transform: uppercase;
  color: var(--ink-3); border-top: 1px solid var(--hairline); }
.status-strip .live { color: var(--red-text); }
.blink { animation: breathe 3.3s ease-in-out infinite; }

/* ============ ABOUT: ESC OS terminal ("about this system" panel) ============
   A fictional operating-system about-box, shown in the site frame like the 404:
   the data-matrix as an app icon, the OS/program identity in conjoined hairline
   bars (segplate grammar), a system-access notice, and a numbered
   "how to use the site" instruction label. Reuses .actions / .button from the 404. */
.about-page { margin-top: 30px; }
.about-panel { border: 1px solid var(--hairline); background: var(--bg); max-width: 640px; margin: 0 auto; }
.about-body { padding: 34px 30px 30px; text-align: center; }

/* the machine mark as an app icon (partials/datamatrix.html, seeded "ESC OS");
   .datamatrix rect fill (--ink-2) comes from the shared rule above */
.osicon { display: block; width: 56px; height: 56px; margin: 0 auto 22px; }

/* identity: conjoined hairline bars stacked as rows (the segplate/eyebrow join,
   no middot): row 1 the OS name + build, row 2 the program descriptor */
.ids { text-align: center; }
.ids + .ids { margin-top: 10px; }
.idbar { display: inline-flex; border: 1px solid var(--hairline); }
.idbar .c { display: inline-flex; align-items: center; padding: 8px 14px;
  font-size: 11px; letter-spacing: var(--tracking); text-transform: uppercase; color: var(--ink-2); }
.idbar .c + .c { border-left: 1px solid var(--hairline); }
.idbar .name, .idbar .prog { color: var(--ink); font-weight: 600; }   /* OS name / program name */
.idbar .lbl { color: var(--ink-3); }                                  /* Program / Version labels */
.idbar .lbl b { color: var(--ink); font-weight: 600; }

/* system-access notice (government-banner register) */
.about-body .notice { text-align: left; margin: 26px 0 0; }
.about-body .notice .key { font-size: 9px; letter-spacing: var(--tracking-wide); text-transform: uppercase;
  color: var(--ink-3); margin-bottom: 9px; }
.about-body .notice p { margin: 0; font-size: 11.5px; line-height: 1.72; color: var(--ink-2); }

/* operating instructions: a numbered "how to use the site" label */
.about-body .help { margin-top: 26px; text-align: left; }
.paneltitle { display: flex; align-items: baseline; justify-content: space-between; gap: 10px;
  font-size: 10px; letter-spacing: var(--tracking); text-transform: uppercase; color: var(--ink-3);
  border-bottom: 1px solid var(--hairline); padding-bottom: 8px; margin-bottom: 4px; }
.paneltitle b { color: var(--ink); font-weight: 600; }
.oplist { list-style: none; margin: 0; padding: 0; counter-reset: step; }
.oplist li { display: flex; gap: 13px; padding: 11px 0; border-top: 1px solid var(--hairline);
  font-size: 12.5px; line-height: 1.5; color: var(--ink); }
.oplist li:first-child { border-top: 0; }
.oplist li::before { counter-increment: step; content: counter(step, decimal-leading-zero);
  color: var(--ink-3); font-variant-numeric: tabular-nums; letter-spacing: var(--tracking); flex: none; }

/* actions: reuse .button / .button.primary from the 404, centered in the panel */
.about-body .actions { justify-content: center; }

@media (max-width: 620px) { .about-body { padding: 26px 16px 22px; } }

/* ============ SEARCH (Pagefind results) ============ */
.search-page { margin-top: 30px; }
.search-field { display: flex; border: 1px solid var(--hairline); background: var(--bg); margin: 30px 0 8px; }
.search-field .key { padding: 11px 14px; border-right: 1px solid var(--hairline); font-size: 10px;
  letter-spacing: var(--tracking); text-transform: uppercase; color: var(--ink-3); display: flex; align-items: center; }
.search-field input { flex: 1; background: transparent; border: 0; color: var(--ink); font-family: var(--mono);
  font-size: 14px; letter-spacing: .04em; padding: 10px 14px; }
.search-field input:focus { outline: none; }
.search-field input::placeholder { color: var(--ink-4); text-transform: uppercase; letter-spacing: var(--tracking); font-size: 11px; }
.search-status { font-size: 10px; letter-spacing: var(--tracking); text-transform: uppercase; color: var(--ink-3); margin: 12px 0; }
.search-results { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--hairline); }
.search-results li { border-bottom: 1px solid var(--hairline); padding: 16px 2px; }
.search-results a { color: var(--ink); text-decoration: none; font-size: 15px; letter-spacing: .02em;
  text-transform: uppercase; border-bottom: 1px solid var(--ink-4); }
.search-results a:hover { color: var(--hue-blue); border-bottom-color: var(--hue-blue); }
.search-results .excerpt { margin-top: 8px; font-size: 12.5px; line-height: 1.6; color: var(--ink-2); text-transform: none; letter-spacing: 0; }
.search-results .excerpt mark { background: transparent; color: var(--ink); font-weight: 600; }

/* ============ SEARCH OVERLAY (command palette: palette.js) ============
   A floating layer over the page. position:fixed keeps it out of normal flow,
   so opening it, typing, and growing the results list move nothing underneath;
   the page never reflows and there is no footer to jump. Results scroll inside
   the box's own capped height. */
.palette-scrim { position: fixed; inset: 0; z-index: 60; display: none;
  align-items: flex-start; justify-content: center; padding: 12vh 20px 20px;
  background: hsl(240 8% 4% / 0.74); }
.palette-scrim.open { display: flex; }
@supports (backdrop-filter: blur(1px)) { .palette-scrim { backdrop-filter: blur(1.5px); } }
.palette { width: min(620px, 100%); background: var(--bg); border: 1px solid var(--hairline);
  box-shadow: 0 24px 80px hsl(240 8% 2% / 0.6); display: flex; flex-direction: column; max-height: 76vh; }
.palette-cap { display: flex; align-items: center; border-bottom: 1px solid var(--hairline); }
.palette-cap .segment { padding: 9px 14px; font-size: 10px; letter-spacing: var(--tracking-wide);
  text-transform: uppercase; color: var(--ink-2); }
.palette-cap .spacer { flex: 1; }
.palette-close { display: inline-flex; align-items: center; justify-content: center; color: var(--ink-3);
  background: transparent; border: 0; border-left: 1px solid var(--hairline); padding: 9px 14px; cursor: pointer; }
.palette-close:hover { color: var(--ink); background: var(--bg-panel); }
/* CSS-drawn close X: two hairline bars on currentColor, matching the .pf-arrow chevrons */
.palette-close .pf-x { position: relative; display: block; width: 10px; height: 10px; }
.palette-close .pf-x::before, .palette-close .pf-x::after { content: ""; position: absolute; top: 50%; left: 50%;
  width: 100%; height: 1px; background: currentColor; }
.palette-close .pf-x::before { transform: translate(-50%, -50%) rotate(45deg); }
.palette-close .pf-x::after  { transform: translate(-50%, -50%) rotate(-45deg); }
.palette-field { display: flex; border-bottom: 1px solid var(--hairline); }
.palette-field .key { padding: 14px; border-right: 1px solid var(--hairline); font-size: 10px;
  letter-spacing: var(--tracking); text-transform: uppercase; color: var(--ink-3); display: flex; align-items: center; }
.palette-field input { flex: 1; min-width: 0; background: transparent; border: 0; color: var(--ink);
  font-family: var(--mono); font-size: 16px; padding: 0 14px; }
.palette-field input:focus { outline: none; }
.palette-field input::placeholder { color: var(--ink-4); text-transform: uppercase; letter-spacing: var(--tracking); font-size: 12px; }
.palette-status { font-size: 9px; letter-spacing: var(--tracking); text-transform: uppercase; color: var(--ink-3);
  padding: 9px 14px; border-bottom: 1px solid var(--hairline); }
.palette-results { list-style: none; margin: 0; padding: 0; overflow-y: auto; }
.palette-results li { border-bottom: 1px solid var(--hairline); }
.palette-results li:last-child { border-bottom: 0; }
.palette-results a { display: block; padding: 13px 14px; text-decoration: none; color: var(--ink); }
.palette-results li.is-active a, .palette-results a:hover { background: var(--bg-panel); }
.palette-results .result-title { display: block; font-size: 14px; letter-spacing: .02em; text-transform: uppercase; }
.palette-results .excerpt { display: block; font-size: 11.5px; line-height: 1.55; color: var(--ink-3); margin-top: 6px; }
.palette-results mark { background: transparent; color: var(--ink); font-weight: 600; }
.palette-empty { padding: 22px 14px; font-size: 11px; letter-spacing: var(--tracking); text-transform: uppercase; color: var(--ink-3); }
.palette-foot { display: flex; align-items: center; gap: 16px; border-top: 1px solid var(--hairline); padding: 9px 14px; }
.palette-foot span { font-size: 9px; letter-spacing: var(--tracking); text-transform: uppercase; color: var(--ink-4); }
.palette-foot .spacer { flex: 1; }
.palette-foot kbd { font-family: var(--mono); color: var(--ink-3); border: 1px solid var(--hairline); padding: 0 5px; }
.palette-foot .palette-all { display: inline-flex; align-items: stretch; font-size: 9px;
  letter-spacing: var(--tracking); text-transform: uppercase; color: var(--ink-3);
  text-decoration: none; border: 1px solid var(--hairline); }
.palette-foot .palette-all .txt  { display: flex; align-items: center; padding: 0 6px; color: inherit; }
.palette-foot .palette-all .tick { display: flex; align-items: center; padding: 0 6px; border-left: 1px solid var(--hairline); color: inherit; }
.palette-foot .palette-all:hover { color: var(--ink-2); border-color: var(--ink-2); }
.palette-foot .palette-all:hover .tick { border-left-color: var(--ink-2); }
.palette-foot .pf-arrow { color: inherit; }  /* inherit key/link ink, not the ink-4 span default */
/* CSS-drawn hairline chevrons: one item rotated three ways, symmetric as a set.
   The trailing translate slides the corner's ink back onto the box center so each rotation reads as centered. */
.pf-arrow { display: inline-block; width: 5px; height: 5px; border: 1px solid currentColor;
  border-left: 0; border-bottom: 0; vertical-align: middle;
  transform: rotate(var(--pf-rot, 0deg)) translate(-1px, 1px); }
.pf-arrow.up    { --pf-rot: -45deg; }
.pf-arrow.down  { --pf-rot: 135deg; }
.pf-arrow.right { --pf-rot: 45deg; }
@media (max-width: 560px) { .palette-scrim { padding: 8vh 12px 12px; } .palette-foot .hide-sm { display: none; } }

/* ============ RESPONSIVE ============ */
@media (max-width: 860px) {
  .band .cells { grid-template-columns: repeat(3, 1fr); }
  .band .cell:nth-child(6n) { border-right: 1px solid var(--hairline); }
  .band .cell:nth-child(3n) { border-right: 0; }
  .band.merged .cell.blank { display: none; }   /* drop the void's pad cells on tablet/phone */
  /* event stays five across (short values); restore its own divider logic */
  .band.cols-5 .cells { grid-template-columns: repeat(5, 1fr); }
  .band.cols-5 .cell:nth-child(3n) { border-right: 1px solid var(--hairline); }
  .band.cols-5 .cell:nth-child(5n) { border-right: 0; }
  .sheet { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 720px) { .telemetry .opt-lg { display: none; } }
/* masthead: leave the horizontal bar before the six tabs + search overflow it
   (intrinsic min ~844px + frame padding ≈ 908px), and reflow into the box grid.
   8 cells (brand + 6 tabs + search) fill a clean 4-col rectangle. */
@media (max-width: 920px) {
  .masthead { display: grid; grid-template-columns: repeat(4, 1fr); overflow: hidden; }
  .masthead .tabs { display: contents; }
  .masthead .spacer { display: none; }
  .masthead .brand { order: 1; }
  .masthead .tabs .tab { order: 3; }
  .masthead .search { order: 99; }
  .search-key { display: none; }   /* drop the "/" hint once the bar reflows to a grid */
  .masthead .brand,
  .masthead .search,
  .masthead .tabs .tab { border: 1px solid var(--hairline); margin: -1px 0 0 -1px; }
}
@media (max-width: 560px) {
  .frame { padding: 16px 16px 40px; }
  .telemetry { flex-wrap: wrap; }
  .telemetry .opt-sm { display: none; }
  .masthead { grid-template-columns: repeat(2, 1fr); }
  .title { font-size: 34px; }
  .band .cells { grid-template-columns: repeat(2, 1fr); }
  .band .cell:nth-child(3n) { border-right: 1px solid var(--hairline); }
  .band .cell:nth-child(2n) { border-right: 0; }
  /* event band stacks to a single column */
  .band.cols-5 .cells { grid-template-columns: 1fr; }
  .band.cols-5 .cell { border-right: 0; }
  /* participants stack: groups to one column, dividers turn horizontal, rows wrap to columns */
  .groups { grid-template-columns: 1fr; }
  .group + .group { border-left: 0; border-top: 1px solid var(--hairline); }
  .flatgroup, .participant-row { flex-direction: column; align-items: flex-start; }
  .footer .cols { display: grid; grid-template-columns: 1fr 1fr; overflow: hidden; }
  .footer .col { border: 1px solid var(--hairline); margin: -1px 0 0 -1px; }
  .footer .col.signal, .footer .col:last-child { grid-column: 1 / -1; }
  /* wrap, and drop the growing spacer so copyright + Rev/mark pack left instead of
     splitting across the bar (keeps the row on one line where it fits, e.g. ~430px) */
  .footer .footer-telemetry { flex-wrap: wrap; }
  .footer .footer-telemetry .spacer { display: none; }
  .sheet { grid-template-columns: 1fr; }
}

/* ============ HUD SegmentGauge (templates/hud.html) ============
   Geometry rides these classes + custom properties; the Tera component computes
   which rows are lit and the four color roles. */
.seg-gauge { display: flex; align-items: center; gap: var(--seg-gap); border-radius: 0; }
.seg-gauge.is-vertical            { flex-direction: column; }
.seg-gauge.is-horizontal          { flex-direction: row; }
.seg-gauge.is-vertical.is-reverse { flex-direction: column-reverse; }
.seg-gauge.is-horizontal.is-reverse { flex-direction: row-reverse; }

.seg-row { display: flex; align-items: center; gap: var(--seg-spine-gap); flex: none; }
.seg-gauge.is-vertical   .seg-row { flex-direction: row; }
.seg-gauge.is-horizontal .seg-row { flex-direction: column; }
.seg-gauge.is-single     .seg-row { gap: 0; }
.seg-gauge.is-fluid      .seg-row { align-self: stretch; }

/* a wing = cap cell + bar, laid along the row's own length */
.seg-wing { display: flex; flex: none; }
.seg-gauge.is-vertical   .seg-wing { flex-direction: row;    width: var(--seg-length); height: var(--seg-thickness); }
.seg-gauge.is-horizontal .seg-wing { flex-direction: column; width: var(--seg-thickness); height: var(--seg-length); }
.seg-gauge.is-vertical   .seg-wing.cap-at-end { flex-direction: row-reverse; }
.seg-gauge.is-horizontal .seg-wing.cap-at-end { flex-direction: column-reverse; }
/* fluid: wings + spine divide the real container instead of a fixed length */
.seg-gauge.is-fluid.is-vertical   .seg-wing { flex: 1 1 0; width: auto;  min-width: 0; }
.seg-gauge.is-fluid.is-horizontal .seg-wing { flex: 1 1 0; height: auto; min-height: 0; }

.seg-cap { flex: 0 0 var(--seg-cap-size); }
.seg-bar { flex: 1 1 auto; }

.seg-spine { flex: none; }
.seg-gauge.is-vertical   .seg-spine { width: var(--seg-spine-size); height: var(--seg-thickness); }
.seg-gauge.is-horizontal .seg-spine { width: var(--seg-thickness);  height: var(--seg-spine-size); }

/* colors: bars carry state, structure stays neutral; switched by the row's on/off */
.seg-bar { background: var(--seg-off); }
.seg-row.on .seg-bar { background: var(--seg-on); }
.seg-cap, .seg-spine { background: var(--seg-struct-off); }
.seg-row.on .seg-cap, .seg-row.on .seg-spine { background: var(--seg-struct-on); }

/* live pulse: the leading lit row's bars only (both wings), slow ~3s, never a blink */
@keyframes seg-pulse { 0%, 100% { opacity: 1; } 50% { opacity: .3; } }
.seg-gauge.is-live .seg-row.is-leading .seg-bar { animation: seg-pulse 3s linear infinite; }
@media (prefers-reduced-motion: reduce) {
  .seg-gauge.is-live .seg-row.is-leading .seg-bar { animation: none; }
}
