/* Hallmark · shape: Hardware Interlock Editorial · genre: modern-minimal · theme: custom · job: try · idea: "Swiss railway interlocking hardware and studio photography wrapping a live SQLite rollback console." · vibe: "machined slate steel and signal vermilion" · hero: full-bleed photographic studio hero with dark basalt left third · nav: translucent floating dark mast over hero · footer: single-row architectural colophon · imagery: three cohesive generated Leica studio hardware photographs plus live SQLite interlock console · signature: dark anodized railway interlocking schematic with guarded vermilion rewind actuator
 * axes: full-bleed-photo-hero, mineral-alabaster-editorial, basalt-hardware-console, archivo-display, signal-vermilion, machined-detents · contrast: pass · fold: pass · v2.0.0 */
/* Hallmark · pre-emit critique: P5 H5 E5 S5 R5 V5 · cut all SaaS card boxes, pastel alert banners, and abstract hero dots; anchored the page in one cohesive Leica hardware photo set and a dark anodized interlocking switchboard */

@import "./tokens.css";
@import "./base.css";
@import "./hero-media.css";

section[id] {
  scroll-margin-top: var(--banner-height);
}

/* Floating top mast */
.topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: var(--z-sticky-nav);
  min-height: var(--banner-height);
  background: color-mix(in oklab, var(--color-basalt) 82%, transparent);
  backdrop-filter: blur(12px);
  border-bottom: var(--rule-hair) solid color-mix(in oklab, var(--color-chalk) 12%, transparent);
  color: var(--color-chalk);
}

.topbar__inner {
  min-height: var(--banner-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-lg);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  text-decoration: none;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: var(--text-lg);
  letter-spacing: var(--tracking-display);
  color: var(--color-chalk);
  white-space: nowrap;
}

.brand__mark {
  width: 24px;
  height: 24px;
  flex: none;
}

.nav {
  display: flex;
  align-items: center;
  gap: var(--space-lg);
}

.nav__link {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: var(--text-sm);
  color: var(--color-chalk-2);
  text-decoration: none;
  white-space: nowrap;
  padding-block: var(--space-xs);
  border-bottom: 2px solid transparent;
  transition: color var(--dur-micro) var(--ease-out), border-color var(--dur-micro) var(--ease-out);
}

.nav__link:hover {
  color: var(--color-chalk);
  border-bottom-color: var(--color-accent-on-dark);
}

/* Machined switch controls */
.switch {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-xs);
  min-height: 46px;
  padding: 0 var(--space-lg);
  border: var(--rule-hair) solid var(--color-chassis-edge);
  border-radius: var(--radius-input);
  background: var(--color-chassis-2);
  color: var(--color-chalk);
  font-family: var(--font-display);
  font-weight: 500;
  font-size: var(--text-sm);
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  box-shadow: var(--shadow-switch-dark);
  transition: transform var(--dur-micro) var(--ease-out), background-color var(--dur-micro) var(--ease-out), box-shadow var(--dur-micro) var(--ease-out);
}

.switch:hover:not(:disabled) {
  transform: translateY(-1px);
  background: color-mix(in oklab, var(--color-chassis-2) 86%, var(--color-chalk));
}

.switch:active:not(:disabled) {
  transform: translateY(2px);
  box-shadow: var(--shadow-switch-press);
}

.switch:disabled,
.switch[aria-disabled="true"] {
  opacity: 0.45;
  cursor: not-allowed;
  transform: none;
}

.switch[aria-busy="true"] {
  cursor: progress;
}

.switch--vermilion {
  background: var(--color-accent);
  border-color: var(--color-accent-edge);
  color: var(--color-accent-ink);
  box-shadow: var(--shadow-switch-accent);
}

.switch--vermilion:hover:not(:disabled) {
  background: var(--color-accent-deep);
  color: var(--color-accent-ink);
}

.switch--ghost-dark {
  background: transparent;
  border-color: color-mix(in oklab, var(--color-chalk) 28%, transparent);
  color: var(--color-chalk);
  box-shadow: none;
}

.switch--ghost-dark:hover:not(:disabled) {
  background: color-mix(in oklab, var(--color-chalk) 10%, transparent);
  color: var(--color-chalk);
}

.switch--light {
  background: var(--color-surface);
  border-color: var(--color-rule-2);
  color: var(--color-ink);
  box-shadow: var(--shadow-switch-light);
}

.switch--light:hover:not(:disabled) {
  background: var(--color-paper);
}

.switch--danger-light {
  background: var(--color-surface);
  border-color: color-mix(in oklab, var(--color-accent) 55%, var(--color-rule-2));
  color: var(--color-accent-deep);
  box-shadow: var(--shadow-switch-light);
}

.switch--danger-light:hover:not(:disabled) {
  background: var(--color-accent-wash);
}

.switch--compact {
  min-height: 36px;
  padding: 0 var(--space-md);
}

@media (prefers-reduced-motion: reduce) {
  .switch {
    transition: background-color var(--dur-micro) linear;
  }
  .switch:hover:not(:disabled),
  .switch:active:not(:disabled) {
    transform: none;
  }
}

/* Full-bleed photographic Hero */
.hero {
  position: relative;
  min-height: min(820px, 100svh);
  padding-top: var(--banner-height);
  display: grid;
  align-items: center;
  background: var(--color-basalt);
  color: var(--color-chalk);
  overflow: hidden;
}

.hero__photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: 64% 52%;
  background-repeat: no-repeat;
  z-index: var(--z-base);
}

.hero__veil {
  position: absolute;
  inset: 0;
  z-index: var(--z-base);
  background: linear-gradient(
    90deg,
    color-mix(in oklab, var(--color-basalt) 92%, transparent) 0%,
    color-mix(in oklab, var(--color-basalt) 72%, transparent) 38%,
    color-mix(in oklab, var(--color-basalt) 14%, transparent) 66%,
    transparent 100%
  );
}

.hero__inner {
  position: relative;
  z-index: var(--z-raised);
  padding-block: var(--space-3xl);
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: var(--gap-columns);
  align-items: center;
}

.hero__copy {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--space-lg);
}

.hero__copy h1 {
  color: var(--color-chalk);
}

.hero__lead {
  font-size: var(--text-lead);
  line-height: 1.48;
  max-width: 42ch;
  color: var(--color-chalk-2);
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-sm);
}

/* Editorial bands */
.band {
  padding-block: var(--section-gap-s);
}

.band--alt {
  background: var(--color-paper-2);
  border-top: var(--rule-hair) solid var(--color-rule);
  border-bottom: var(--rule-hair) solid var(--color-rule);
}

.band--basalt {
  background: var(--color-basalt);
  color: var(--color-chalk);
  padding-block: var(--section-gap-s);
}

.band--basalt h2,
.band--basalt h3 {
  color: var(--color-chalk);
}

.story-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: var(--space-2xl);
  align-items: center;
}

.story-grid + .story-grid {
  margin-top: var(--section-gap-s);
  padding-top: var(--section-gap-s);
  border-top: var(--rule-hair) solid var(--color-rule);
}

.story-grid--flip {
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
}

.editorial-frame {
  margin: 0;
  border-radius: var(--radius-card);
  overflow: hidden;
  background: var(--color-basalt);
  border: var(--rule-hair) solid var(--color-rule-2);
}

.editorial-frame img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.story-body {
  display: flex;
  flex-direction: column;
  gap: var(--space-lg);
}

.story-body p {
  color: var(--color-ink-2);
  max-width: 52ch;
}

/* Swiss hairline specification ledger (replaces card grids) */
.spec-list {
  margin: 0;
  padding: 0;
  list-style: none;
  border-top: var(--rule-hair) solid var(--color-rule-2);
}

.spec-row {
  display: grid;
  grid-template-columns: minmax(0, 165px) minmax(0, 1fr);
  gap: var(--space-md);
  padding-block: var(--space-sm);
  border-bottom: var(--rule-hair) solid var(--color-rule);
  align-items: baseline;
}

.spec-row__key {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: var(--text-sm);
  color: var(--color-ink);
}

.spec-row__val {
  font-size: var(--text-sm);
  color: var(--color-ink-2);
}

.mono {
  font-family: var(--font-outlier);
  font-size: var(--text-xs);
}

/* Section header */
.section-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 0.8fr);
  gap: var(--gap-columns);
  align-items: end;
  margin-bottom: var(--space-xl);
}

.section-head__note {
  font-size: var(--text-md);
  color: var(--color-ink-2);
  max-width: 48ch;
  justify-self: end;
}

.band--basalt .section-head__note {
  color: var(--color-chalk-2);
}

/* THE SIGNATURE ELEMENT: Anodized Basalt Interlock Console */
.console {
  background: var(--color-chassis);
  color: var(--color-chalk);
  border: var(--rule-hair) solid var(--color-chassis-edge);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-chassis);
  overflow: hidden;
}

.console__header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
  padding: var(--space-md) var(--space-lg);
  background: var(--color-chassis-well);
  border-bottom: var(--rule-hair) solid var(--color-chassis-rule);
}

.detent-bank {
  display: inline-flex;
  flex-wrap: wrap;
  gap: var(--space-2xs);
  padding: var(--space-2xs);
  background: var(--color-basalt);
  border: var(--rule-hair) solid var(--color-chassis-rule);
  border-radius: var(--radius-input);
  box-shadow: var(--shadow-recess);
}

.detent {
  min-height: 38px;
  padding: 0 var(--space-md);
  border: var(--rule-hair) solid transparent;
  border-radius: var(--radius-input);
  background: transparent;
  color: var(--color-chalk-dim);
  font-family: var(--font-display);
  font-weight: 500;
  font-size: var(--text-sm);
  white-space: nowrap;
  cursor: pointer;
  transition: background-color var(--dur-micro) var(--ease-out), color var(--dur-micro) var(--ease-out), border-color var(--dur-micro) var(--ease-out);
}

.detent:hover {
  color: var(--color-chalk);
  background: color-mix(in oklab, var(--color-chassis-2) 60%, transparent);
}

.detent[aria-pressed="true"] {
  background: var(--color-chassis-2);
  color: var(--color-chalk);
  border-color: var(--color-chassis-edge);
  box-shadow: inset 0 -2px 0 var(--color-accent-on-dark);
}

.console__tools {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-sm);
}

.console__summary {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
  padding: var(--space-sm) var(--space-lg);
  background: var(--color-chassis);
  border-bottom: var(--rule-hair) solid var(--color-chassis-rule);
  font-size: var(--text-sm);
  color: var(--color-chalk-2);
}

.console__hashes {
  font-family: var(--font-outlier);
  font-size: var(--text-xs);
  color: var(--color-chalk-dim);
}

/* Railway Interlocking Track Schematic: one continuous machined plate */
.rail-bay {
  padding: var(--space-lg);
  background: var(--color-chassis-well);
  border-bottom: var(--rule-hair) solid var(--color-chassis-rule);
}

.rail-bay__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
  margin-bottom: var(--space-lg);
}

.rail-bay__caption {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: var(--text-sm);
  color: var(--color-chalk-2);
}

.rail-track {
  position: relative;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 0;
  margin-top: var(--space-lg);
  border-top: var(--rule-hair) solid var(--color-chassis-edge);
  border-bottom: var(--rule-hair) solid var(--color-chassis-rule);
  background: var(--color-chassis);
}

.rail-track::before {
  content: "";
  position: absolute;
  top: -19px;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--color-chassis-edge);
}

.station {
  position: relative;
  text-align: left;
  padding: var(--space-md);
  border: 0;
  border-right: var(--rule-hair) solid var(--color-chassis-rule);
  border-radius: 0;
  background: transparent;
  color: var(--color-chalk);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: var(--space-2xs);
  transition: background-color var(--dur-micro) var(--ease-out);
}

.station:last-child {
  border-right: 0;
}

.station::before {
  content: "";
  position: absolute;
  top: -25px;
  left: var(--space-md);
  width: 12px;
  height: 12px;
  border-radius: var(--radius-pill);
  border: 2px solid var(--color-chassis-edge);
  background: var(--color-chassis-well);
}

.station::after {
  content: "";
  position: absolute;
  top: -13px;
  left: calc(var(--space-md) + 5px);
  width: 2px;
  height: 13px;
  background: var(--color-chassis-rule);
}

.station:hover {
  background: var(--color-chassis-2);
}

.station--in-scope {
  box-shadow: inset 0 2px 0 var(--color-steel-on-dark);
}

.station--in-scope::before {
  border-color: var(--color-steel-on-dark);
  background: var(--color-steel-on-dark);
}

.station--in-scope::after {
  background: var(--color-steel-on-dark);
}

.station--ok {
  box-shadow: inset 0 2px 0 var(--color-ok-on-dark);
}

.station--ok::before {
  border-color: var(--color-ok-on-dark);
  background: var(--color-ok-on-dark);
}

.station--ok::after {
  background: var(--color-ok-on-dark);
}

.station--warn {
  box-shadow: inset 0 2px 0 var(--color-warn-on-dark);
}

.station--warn::before {
  border-color: var(--color-warn-on-dark);
  background: var(--color-warn-on-dark);
}

.station--warn::after {
  background: var(--color-warn-on-dark);
}

.station--conflict {
  background: color-mix(in oklab, var(--color-accent) 20%, var(--color-chassis));
  box-shadow: inset 0 3px 0 var(--color-accent-on-dark);
}

.station--conflict::before {
  border-color: var(--color-accent-on-dark);
  background: var(--color-accent-on-dark);
}

.station--conflict::after {
  background: var(--color-accent-on-dark);
}

.station--target {
  background: var(--color-chassis-2);
  outline: 2px solid var(--color-chalk);
  outline-offset: -2px;
}

.station__top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--space-xs);
}

.station__seq {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: var(--text-xl);
  line-height: 1;
  font-variant-numeric: tabular-nums;
  color: var(--color-chalk);
}

.station__tool {
  font-family: var(--font-outlier);
  font-size: var(--text-xs);
  line-height: 1.5;
  color: var(--color-chalk);
  overflow-wrap: anywhere;
}

.station__meta {
  font-family: var(--font-display);
  font-size: var(--text-xs);
  line-height: 1.45;
  color: var(--color-chalk-dim);
}

/* Console lower split */
.console__body {
  display: grid;
  grid-template-columns: minmax(0, 0.88fr) minmax(0, 1.12fr);
}

.tape-bay {
  padding: var(--space-lg);
  border-right: var(--rule-hair) solid var(--color-chassis-rule);
}

.bay-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--space-md);
  padding-bottom: var(--space-sm);
  margin-bottom: var(--space-md);
  border-bottom: var(--rule-hair) solid var(--color-chassis-rule);
}

.bay-head__title {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: var(--text-md);
  color: var(--color-chalk);
}

.bay-head__sub {
  font-family: var(--font-outlier);
  font-size: var(--text-xs);
  color: var(--color-chalk-dim);
}

.step-list {
  display: flex;
  flex-direction: column;
}

.step-row {
  width: 100%;
  text-align: left;
  border: 0;
  border-bottom: var(--rule-hair) solid var(--color-chassis-rule);
  background: transparent;
  padding: var(--space-md) var(--space-sm);
  cursor: pointer;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) auto;
  gap: var(--space-sm);
  align-items: start;
  color: var(--color-chalk);
  transition: background-color var(--dur-micro) var(--ease-out);
}

.step-row:last-child {
  border-bottom: 0;
}

.step-row:hover {
  background: var(--color-chassis-2);
}

.step-row--selected {
  background: color-mix(in oklab, var(--color-chassis-2) 85%, var(--color-steel));
}

.step-row__num {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: var(--text-lg);
  color: var(--color-chalk-dim);
  font-variant-numeric: tabular-nums;
  line-height: 1.2;
}

.step-row--selected .step-row__num {
  color: var(--color-chalk);
}

.step-row__title {
  font-family: var(--font-body);
  font-weight: 500;
  font-size: var(--text-sm);
  color: var(--color-chalk);
  margin-bottom: var(--space-2xs);
}

.step-row__sub {
  font-family: var(--font-outlier);
  font-size: var(--text-xs);
  color: var(--color-chalk-dim);
  overflow-wrap: anywhere;
}

.step-row__deps {
  margin-top: var(--space-2xs);
  font-family: var(--font-display);
  font-size: var(--text-xs);
  color: var(--color-chalk-2);
}

.step-row__error {
  margin-top: var(--space-2xs);
  font-family: var(--font-outlier);
  font-size: var(--text-xs);
  color: var(--color-error-on-dark);
}

.action-feedback {
  min-height: 1lh;
  margin-top: var(--space-md);
  font-size: var(--text-sm);
  color: var(--color-chalk-2);
}

/* Actuator bay (right column of hardware enclosure) */
.actuator-bay {
  display: flex;
  flex-direction: column;
  background: var(--color-chassis-well);
}

.actuator-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
  padding: var(--space-md) var(--space-lg);
  background: var(--color-chassis);
  border-bottom: var(--rule-hair) solid var(--color-chassis-rule);
}

.actuator-metrics {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  border-bottom: var(--rule-hair) solid var(--color-chassis-rule);
}

.metric-cell {
  padding: var(--space-sm) var(--space-md);
  border-right: var(--rule-hair) solid var(--color-chassis-rule);
}

.metric-cell:last-child {
  border-right: 0;
}

.metric-cell__val {
  display: block;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: var(--text-2xl);
  line-height: 1.05;
  font-variant-numeric: tabular-nums;
  color: var(--color-chalk);
}

.metric-cell__val--steel {
  color: var(--color-steel-on-dark);
}

.metric-cell__val--danger {
  color: var(--color-error-on-dark);
}

.metric-cell__val--zero {
  color: var(--color-chalk-dim);
}

.metric-cell__label {
  display: block;
  margin-top: var(--space-2xs);
  font-family: var(--font-display);
  font-size: var(--text-xs);
  color: var(--color-chalk-dim);
}

.plan-list {
  padding: var(--space-lg);
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.plan-item {
  padding-bottom: var(--space-md);
  border-bottom: var(--rule-hair) solid var(--color-chassis-rule);
}

.plan-item:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.plan-item__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-sm);
  margin-bottom: var(--space-xs);
}

.plan-item__kind {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: var(--text-sm);
  color: var(--color-steel-on-dark);
}

.plan-item__kind--error {
  color: var(--color-error-on-dark);
}

.plan-item__kind--ok {
  color: var(--color-ok-on-dark);
}

.plan-item__kind--warn {
  color: var(--color-warn-on-dark);
}

.plan-item__code {
  margin: var(--space-xs) 0 0;
  padding: var(--space-sm) var(--space-md);
  background: var(--color-basalt);
  border: var(--rule-hair) solid var(--color-chassis-rule);
  border-radius: var(--radius-input);
  font-family: var(--font-outlier);
  font-size: var(--text-xs);
  line-height: 1.6;
  color: var(--color-chalk);
  overflow-x: auto;
  white-space: pre-wrap;
  word-break: break-word;
}

.plan-item__code--error {
  border-color: var(--color-accent-on-dark);
}

.plan-item__code--warn {
  border-color: var(--color-warn-on-dark);
}

.conflict-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-sm);
  margin-top: var(--space-sm);
}

.invariants-bar {
  margin-top: auto;
  padding: var(--space-md) var(--space-lg);
  background: var(--color-chassis);
  border-top: var(--rule-hair) solid var(--color-chassis-rule);
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
}

.invariant-line {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--space-sm);
  font-size: var(--text-xs);
}

.invariant-line__name {
  font-family: var(--font-outlier);
  color: var(--color-chalk-2);
}

.invariant-line__state {
  font-family: var(--font-display);
  font-weight: 500;
  color: var(--color-ok-on-dark);
}

.invariant-line__state--fail {
  color: var(--color-error-on-dark);
}

.invariant-line__detail {
  color: var(--color-chalk-dim);
  width: 100%;
}

/* Status text with icon (never filled pills) */
.status-label {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2xs);
  font-family: var(--font-display);
  font-weight: 500;
  font-size: var(--text-xs);
  white-space: nowrap;
}

.status-label--ok {
  color: var(--color-ok);
}

.status-label--steel {
  color: var(--color-steel);
}

.status-label--error {
  color: var(--color-error);
}

.status-label--warn {
  color: var(--color-warn);
}

.status-label--muted {
  color: var(--color-muted);
}

.console .status-label--ok {
  color: var(--color-ok-on-dark);
}

.console .status-label--steel {
  color: var(--color-steel-on-dark);
}

.console .status-label--error {
  color: var(--color-error-on-dark);
}

.console .status-label--warn {
  color: var(--color-warn-on-dark);
}

.console .status-label--muted {
  color: var(--color-chalk-dim);
}

.status-icon {
  width: 14px;
  height: 14px;
  flex: none;
}

/* Outbox & External Ledger (Light Mineral Editorial) */
.split-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: var(--space-2xl);
  align-items: start;
}

.ledger-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--space-md);
  padding-bottom: var(--space-sm);
  border-bottom: 2px solid var(--color-ink);
  margin-bottom: var(--space-md);
}

.ledger-head--spaced {
  margin-top: var(--space-2xl);
}

/* Twin-gate physical chamber plate */
.gate-plate {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border: var(--rule-hair) solid var(--color-ink);
  border-radius: var(--radius-input);
  background: var(--color-chassis);
  color: var(--color-chalk);
  margin-bottom: var(--space-md);
}

.gate-plate__cell {
  padding: var(--space-sm) var(--space-md);
  border-right: var(--rule-hair) solid var(--color-chassis-rule);
  display: flex;
  flex-direction: column;
  gap: var(--space-3xs);
}

.gate-plate__cell:last-child {
  border-right: 0;
}

.gate-plate__label {
  font-family: var(--font-display);
  font-size: var(--text-xs);
  color: var(--color-chalk-dim);
}

.gate-plate__state {
  font-family: var(--font-outlier);
  font-size: var(--text-xs);
  color: var(--color-chalk);
}

.gate-plate__state--ok {
  color: var(--color-ok-on-dark);
}

.gate-plate__state--warn {
  color: var(--color-warn-on-dark);
}

.gate-plate__state--error {
  color: var(--color-error-on-dark);
}

.chamber-list {
  display: flex;
  flex-direction: column;
}

.chamber-row {
  padding-block: var(--space-md);
  border-bottom: var(--rule-hair) solid var(--color-rule-2);
}

.chamber-row:first-child {
  padding-top: 0;
}

.chamber-row__top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-sm);
  margin-bottom: var(--space-xs);
}

.chamber-row__subject {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: var(--text-md);
  color: var(--color-ink);
}

.chamber-row__body {
  margin-top: var(--space-xs);
  font-size: var(--text-sm);
  color: var(--color-ink-2);
}

.chamber-row__foot {
  margin-top: var(--space-md);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-sm);
}

/* Swiss hairline data tables */
.table-wrap {
  width: 100%;
  overflow-x: auto;
  border-top: 2px solid var(--color-ink);
  border-bottom: var(--rule-hair) solid var(--color-rule-2);
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: var(--text-sm);
}

.data-table th {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: var(--text-xs);
  color: var(--color-muted);
  padding: var(--space-sm) var(--space-md);
  border-bottom: var(--rule-hair) solid var(--color-rule-2);
  white-space: nowrap;
}

.data-table td {
  padding: var(--space-md);
  border-bottom: var(--rule-hair) solid var(--color-rule);
  vertical-align: top;
}

.data-table tbody tr:last-child td {
  border-bottom: 0;
}

.data-table th.num,
.data-table td.num {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.data-table tbody tr.is-highlighted {
  background: var(--color-steel-wash);
}

.data-table tbody tr.is-conflict {
  background: var(--color-accent-wash);
}

/* MCP Technical Specification Block */
.mcp-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.88fr) minmax(0, 1.12fr);
  background: var(--color-chassis);
  color: var(--color-chalk);
  border: var(--rule-hair) solid var(--color-chassis-edge);
  border-radius: var(--radius-card);
  overflow: hidden;
}

.mcp-pane {
  padding: var(--space-lg);
}

.mcp-pane--left {
  border-right: var(--rule-hair) solid var(--color-chassis-rule);
  background: var(--color-chassis-well);
}

.mcp-pane__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-sm);
  margin-bottom: var(--space-sm);
}

.mcp-pane__head--spaced {
  margin-top: var(--space-lg);
}

.mcp-pane__title {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: var(--text-sm);
  color: var(--color-chalk-2);
}

.mcp-tool-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-2xs);
}

.mcp-tool-btn {
  width: 100%;
  text-align: left;
  border: var(--rule-hair) solid transparent;
  border-radius: var(--radius-input);
  background: transparent;
  padding: var(--space-sm) var(--space-md);
  color: var(--color-chalk);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: var(--space-3xs);
  transition: background-color var(--dur-micro) var(--ease-out);
}

.mcp-tool-btn:hover {
  background: var(--color-chassis);
}

.mcp-tool-btn[aria-selected="true"] {
  background: var(--color-chassis-2);
  border-color: var(--color-chassis-edge);
  box-shadow: inset 3px 0 0 var(--color-accent-on-dark);
}

.mcp-tool-btn__name {
  font-family: var(--font-outlier);
  font-size: var(--text-sm);
  color: var(--color-chalk);
}

.mcp-tool-btn__desc {
  font-size: var(--text-xs);
  color: var(--color-chalk-dim);
}

.code-block {
  margin: 0;
  padding: var(--space-md);
  background: var(--color-basalt);
  border: var(--rule-hair) solid var(--color-chassis-rule);
  border-radius: var(--radius-input);
  font-family: var(--font-outlier);
  font-size: var(--text-xs);
  line-height: 1.65;
  color: var(--color-chalk);
  overflow-x: auto;
  white-space: pre;
}

/* Colophon footer */
.footer {
  border-top: var(--rule-hair) solid var(--color-rule-2);
  padding-block: var(--space-xl);
  background: var(--color-paper);
}

.footer__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
}

.footer__meta {
  font-size: var(--text-sm);
  color: var(--color-muted);
}

.footer__links {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-lg);
  font-family: var(--font-display);
  font-size: var(--text-sm);
  color: var(--color-ink-2);
}

/* Responsive */
@media (max-width: 64rem) {
  .hero__inner,
  .story-grid,
  .story-grid--flip,
  .section-head,
  .console__body,
  .split-grid,
  .mcp-grid {
    grid-template-columns: minmax(0, 1fr);
  }
  .section-head__note {
    justify-self: start;
  }
  .tape-bay {
    border-right: 0;
    border-bottom: var(--rule-hair) solid var(--color-chassis-rule);
  }
  .mcp-pane--left {
    border-right: 0;
    border-bottom: var(--rule-hair) solid var(--color-chassis-rule);
  }
  .actuator-metrics {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 48rem) {
  .topbar__inner {
    flex-wrap: wrap;
    padding-block: var(--space-xs);
    row-gap: var(--space-xs);
  }
  .topbar #btn-reset {
    display: none;
  }
  .nav {
    order: 3;
    width: 100%;
    overflow-x: auto;
    gap: var(--space-sm);
    justify-content: space-between;
    padding-top: var(--space-xs);
    border-top: var(--rule-hair) solid color-mix(in oklab, var(--color-chalk) 12%, transparent);
  }
  .nav__link {
    font-size: var(--text-xs);
  }
  .hero {
    min-height: auto;
    padding-top: calc(var(--banner-height) + var(--space-lg));
    display: flex;
    flex-direction: column;
    align-items: stretch;
  }
  .hero__photo {
    position: relative;
    inset: auto;
    width: 100%;
    height: 220px;
    background-size: cover;
    background-position: 68% 48%;
  }
  .hero__veil {
    display: none;
  }
  .hero__inner {
    padding-block: var(--space-lg) var(--space-xl);
  }
  .detent-bank {
    width: 100%;
    flex-direction: column;
  }
  .detent {
    width: 100%;
    text-align: left;
  }
  .rail-track::before {
    display: none;
  }
  .rail-track {
    margin-top: 0;
  }
  .station {
    border-right: 0;
    border-bottom: var(--rule-hair) solid var(--color-chassis-rule);
  }
  .station:last-child {
    border-bottom: 0;
  }
  .station::before,
  .station::after {
    display: none;
  }
  .spec-row {
    grid-template-columns: minmax(0, 1fr);
    gap: var(--space-2xs);
  }
  .actuator-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
