:root {
  --ground: #090d1a;
  --panel: #14265b;
  --plate: #f5f7ff;
  --ink: #10131a;
  --accent: #4d6bff;
  --confirmed: #00c805;
  --muted: #b9c6e0;
  --rule: rgba(185, 198, 224, 0.28);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --max: 1480px;
  --radius: 16px;
  color-scheme: dark;
  font-synthesis: none;
}

* {
  box-sizing: border-box;
}

html {
  background: var(--ground);
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  background:
    linear-gradient(rgba(77, 107, 255, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(77, 107, 255, 0.045) 1px, transparent 1px),
    var(--ground);
  background-size: 72px 72px;
  color: var(--plate);
  font-family: "DM Sans", sans-serif;
  overflow-x: hidden;
}

button,
input,
select {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

a {
  color: inherit;
}

.mono,
code,
.eyebrow,
.status-chip,
th,
.field-label,
.source-line,
.metric-label,
.rule-index,
.brand em {
  font-family: "Azeret Mono", monospace;
}

.boot {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 18px;
  background: var(--ground);
  font: 600 12px/1 "Azeret Mono", monospace;
  letter-spacing: 0.14em;
  transition: opacity 0.45s var(--ease), visibility 0.45s;
}

.boot i {
  display: block;
  width: 210px;
  height: 2px;
  overflow: hidden;
  background: rgba(185, 198, 224, 0.18);
}

.boot i::after {
  content: "";
  display: block;
  width: 54%;
  height: 100%;
  background: var(--accent);
  animation: boot-scan 1.1s var(--ease) infinite alternate;
}

.boot.is-done {
  display: none;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

@keyframes boot-scan {
  from { transform: translateX(-100%); }
  to { transform: translateX(185%); }
}

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  height: 70px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 28px;
  padding: 0 max(28px, calc((100vw - var(--max)) / 2));
  border-bottom: 1px solid var(--rule);
  background: rgba(9, 13, 26, 0.34);
  backdrop-filter: blur(16px);
  transition: background 0.25s ease;
}

.site-header.is-solid {
  background: rgba(9, 13, 26, 0.96);
}

.brand {
  width: max-content;
  display: flex;
  align-items: center;
  gap: 11px;
  text-decoration: none;
}

.brand img {
  border-radius: 8px;
}

.brand span {
  font-family: "Bodoni Moda", serif;
  font-size: 21px;
  font-weight: 700;
  letter-spacing: -0.03em;
}

.brand em {
  color: var(--accent);
  font-size: 9px;
  font-style: normal;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 28px;
}

.desktop-nav a,
.mobile-nav a {
  color: var(--muted);
  font-size: 13px;
  text-decoration: none;
  transition: color 0.2s ease;
}

.desktop-nav a:hover,
.desktop-nav a[aria-current="page"],
.mobile-nav a:hover {
  color: var(--plate);
}

.social-state {
  display: flex;
  justify-self: end;
  gap: 8px;
}

.social-state button,
.social-state a,
.menu-button {
  border: 1px solid var(--rule);
  border-radius: 999px;
  background: rgba(20, 38, 91, 0.45);
  color: var(--muted);
  padding: 9px 12px;
  font: 600 9px/1 "Azeret Mono", monospace;
  letter-spacing: 0.05em;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
}

.menu-button,
.mobile-nav {
  display: none;
}

.hero-track {
  position: relative;
  height: 320vh;
}

.hero-stage {
  position: sticky;
  top: 0;
  min-height: 100svh;
  overflow: hidden;
  background: #102558;
}

.hero-media,
.hero-poster {
  position: absolute;
  top: 0;
  bottom: 0;
  left: -2%;
  width: 104%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.hero-media {
  z-index: 1;
  opacity: 0;
  transition: opacity 0.5s ease;
}

.hero-media.is-ready {
  opacity: 1;
}

.hero-poster {
  z-index: 0;
  background: center / cover no-repeat url("assets/hero_poster.png");
  transform: scale(calc(1 + var(--hero-progress, 0) * 0.018));
  transform-origin: 66% 56%;
  transition: transform 0.08s linear;
}

.hero-poster::after {
  content: "";
  position: absolute;
  right: 11.4%;
  bottom: 9.5%;
  width: 14px;
  height: 14px;
  border: 4px solid var(--ink);
  background: var(--confirmed);
  opacity: calc(0.22 + var(--hero-progress, 0) * 0.78);
  box-shadow: 0 0 calc(var(--hero-progress, 0) * 20px) rgba(0, 200, 5, 0.65);
}

.instrument-data {
  position: absolute;
  z-index: 3;
  top: 39%;
  left: 65.2%;
  width: clamp(280px, 22vw, 350px);
  display: grid;
  justify-items: center;
  color: var(--ink);
  pointer-events: none;
  transform: translate(-50%, -50%);
  font-family: "Azeret Mono", monospace;
}

.instrument-data span,
.instrument-data small,
.instrument-data em {
  font-size: clamp(11px, 0.85vw, 14px);
  font-style: normal;
  font-weight: 600;
  letter-spacing: 0.055em;
  line-height: 1.25;
}

.instrument-data strong {
  margin: 9px 0 12px;
  font-size: clamp(72px, 6.5vw, 106px);
  line-height: 1;
}

.instrument-data i {
  width: 100%;
  height: 3px;
  margin: 3px 0 17px;
  background: var(--ink);
}

.instrument-data em {
  margin-top: 16px;
  font-size: clamp(10px, 0.74vw, 12px);
}

.hero-content {
  position: relative;
  z-index: 3;
  width: min(var(--max), calc(100% - 56px));
  height: 100svh;
  min-height: 720px;
  margin: 0 auto;
  padding-top: 148px;
  pointer-events: none;
}

.hero-copy {
  position: absolute;
  top: 23%;
  left: 0;
  width: min(510px, 38vw);
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.45s var(--ease), transform 0.45s var(--ease);
}

.hero-copy.is-active {
  opacity: 1;
  transform: translateY(0);
}

.eyebrow {
  margin: 0 0 24px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

.hero-copy h1 {
  margin-bottom: 28px;
  font-family: "Bodoni Moda", serif;
  font-size: clamp(66px, 6vw, 106px);
  font-weight: 500;
  line-height: 0.9;
  letter-spacing: -0.055em;
  max-width: 620px;
}

.hero-copy p {
  max-width: 430px;
  color: var(--muted);
  font-size: 19px;
  line-height: 1.55;
}

.hero-actions {
  position: absolute;
  z-index: 4;
  left: 0;
  bottom: 22%;
  display: flex;
  align-items: center;
  gap: 12px;
  pointer-events: auto;
}

.button {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--accent);
  border-radius: 999px;
  padding: 0 20px;
  background: var(--accent);
  color: var(--ink);
  font-weight: 700;
  text-decoration: none;
  transition: transform 0.2s ease, background 0.2s ease;
}

.button:hover {
  transform: translateY(-2px);
}

.button.secondary {
  border-color: var(--muted);
  background: rgba(9, 13, 26, 0.55);
  color: var(--plate);
}

.command-rail {
  position: absolute;
  left: 0;
  bottom: 8.5%;
  display: flex;
  width: min(510px, 38vw);
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border: 1px solid rgba(77, 107, 255, 0.58);
  border-radius: 12px;
  padding: 14px 14px 14px 18px;
  background: rgba(9, 13, 26, 0.82);
  color: var(--plate);
  pointer-events: auto;
}

.command-rail div {
  min-width: 0;
}

.command-rail small {
  display: block;
  margin-bottom: 7px;
  color: var(--accent);
  font: 600 9px/1 "Azeret Mono", monospace;
}

.command-rail code {
  display: block;
  overflow: hidden;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.copy-button {
  flex: 0 0 auto;
  border: 1px solid var(--rule);
  border-radius: 8px;
  background: var(--panel);
  color: var(--plate);
  padding: 11px 12px;
  cursor: pointer;
  font: 600 9px/1 "Azeret Mono", monospace;
}

.hero-meter {
  position: absolute;
  z-index: 5;
  right: max(28px, calc((100vw - var(--max)) / 2));
  bottom: 30px;
  left: max(28px, calc((100vw - var(--max)) / 2));
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid var(--rule);
  padding-top: 14px;
}

.hero-meter span {
  position: relative;
  color: var(--muted);
  font: 600 9px/1 "Azeret Mono", monospace;
  letter-spacing: 0.04em;
}

.hero-meter span::before {
  content: "";
  position: absolute;
  top: -17px;
  left: 0;
  width: calc(var(--hero-progress, 0) * 100%);
  max-width: 100%;
  height: 3px;
  background: var(--accent);
}

.hero-meter span.is-current {
  color: var(--plate);
}

.route-shell,
.home-content {
  position: relative;
  z-index: 4;
  background: var(--ground);
}

.home-content {
  padding: 110px 0 0;
}

.content-wrap {
  width: min(var(--max), calc(100% - 56px));
  margin: 0 auto;
}

.section-heading {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 8vw;
  align-items: end;
  margin-bottom: 64px;
}

.section-heading h2,
.route-title h1 {
  margin-bottom: 0;
  font-family: "Bodoni Moda", serif;
  font-size: clamp(54px, 7vw, 104px);
  font-weight: 500;
  line-height: 0.94;
  letter-spacing: -0.055em;
}

.section-heading p,
.route-title > p {
  color: var(--muted);
  font-size: 17px;
  line-height: 1.65;
}

.status-rail {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  margin-bottom: 52px;
}

.floor-brief {
  display: grid;
  grid-template-columns: 1.15fr 0.925fr 0.925fr;
  gap: 14px;
  margin: 0 0 86px;
}

.brief-card {
  min-height: 330px;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  padding: 28px;
  background: rgba(20, 38, 91, 0.24);
}

.brief-card-primary {
  background: var(--plate);
  color: var(--ink);
}

.brief-index,
.evidence-state {
  color: var(--accent);
  font: 600 9px/1 "Azeret Mono", monospace;
  letter-spacing: 0.08em;
}

.brief-card h3 {
  margin: 42px 0 18px;
  font-family: "Bodoni Moda", serif;
  font-size: clamp(28px, 2.4vw, 39px);
  font-weight: 500;
  line-height: 1.02;
}

.brief-card p {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.7;
}

.brief-card-primary p {
  color: rgba(16, 19, 26, 0.68);
}

.brief-card > a {
  display: flex;
  justify-content: space-between;
  border-top: 1px solid var(--rule);
  margin-top: auto;
  padding-top: 18px;
  color: var(--plate);
  font: 600 10px/1.4 "Azeret Mono", monospace;
  text-decoration: none;
}

.brief-card > a span {
  color: var(--accent);
}

.brief-facts {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  border-top: 1px solid rgba(16, 19, 26, 0.14);
  margin: auto 0 0;
  padding-top: 18px;
}

.brief-facts div {
  min-width: 0;
}

.brief-facts dt,
.brief-facts dd {
  margin: 0;
  font-family: "Azeret Mono", monospace;
}

.brief-facts dt {
  margin-bottom: 8px;
  color: rgba(16, 19, 26, 0.48);
  font-size: 8px;
}

.brief-facts dd {
  font-size: 10px;
  font-weight: 600;
  overflow-wrap: anywhere;
}

.metric {
  min-height: 122px;
  padding: 22px;
  border-right: 1px solid var(--rule);
}

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

.metric-label {
  display: block;
  margin-bottom: 19px;
  color: var(--muted);
  font-size: 9px;
  letter-spacing: 0.08em;
}

.metric strong {
  display: block;
  font: 600 clamp(22px, 2.6vw, 38px)/1 "Azeret Mono", monospace;
  letter-spacing: -0.04em;
}

.metric strong.accent {
  color: var(--accent);
}

.source-line {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.5;
}

.floor-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 26px;
}

.floor-controls .eyebrow {
  margin-bottom: 10px;
}

.floor-controls h3,
.data-section h2 {
  margin: 0;
  font-family: "Bodoni Moda", serif;
  font-size: 30px;
  font-weight: 500;
}

.sorts {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.sorts button {
  border: 1px solid var(--rule);
  border-radius: 999px;
  padding: 9px 12px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font: 600 9px/1 "Azeret Mono", monospace;
}

.sorts button.is-active {
  border-color: var(--accent);
  color: var(--plate);
}

.empty-state {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 40px;
  padding: 34px;
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  background: rgba(20, 38, 91, 0.28);
}

.empty-state h3 {
  margin-bottom: 12px;
  font-size: 28px;
}

.empty-state p {
  color: var(--muted);
  line-height: 1.65;
}

.floor-anatomy {
  display: grid;
  grid-template-columns: 0.72fr 1.28fr;
  gap: 7vw;
  margin: 118px 0 0;
  padding-top: 74px;
  border-top: 1px solid var(--rule);
}

.section-kicker {
  position: sticky;
  top: 112px;
  align-self: start;
}

.section-kicker h2,
.evidence-section h2,
.read-intro h2 {
  margin-bottom: 24px;
  font-family: "Bodoni Moda", serif;
  font-size: clamp(42px, 4.7vw, 72px);
  font-weight: 500;
  line-height: 0.98;
  letter-spacing: -0.045em;
}

.section-kicker > p:last-child,
.evidence-section header > p,
.read-intro > p:last-child {
  color: var(--muted);
  font-size: 15px;
  line-height: 1.7;
}

.anatomy-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  border-top: 1px solid var(--rule);
  border-left: 1px solid var(--rule);
}

.anatomy-grid article {
  min-height: 230px;
  display: flex;
  flex-direction: column;
  border-right: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  padding: 24px;
}

.anatomy-grid article > span {
  color: var(--accent);
  font: 600 9px/1 "Azeret Mono", monospace;
}

.anatomy-grid h3 {
  margin: 42px 0 10px;
  font-family: "Bodoni Moda", serif;
  font-size: 27px;
  font-weight: 500;
}

.anatomy-grid p {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.anatomy-grid code {
  margin-top: auto;
  color: var(--accent);
  font-size: 9px;
}

.gate-list,
.plain-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.gate-list li,
.plain-list li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  border-bottom: 1px solid var(--rule);
  padding: 12px 0;
  font-size: 13px;
}

.gate-list li:last-child,
.plain-list li:last-child {
  border-bottom: 0;
}

.gate-list span:last-child,
.status-chip {
  color: var(--accent);
  font-size: 9px;
  text-transform: uppercase;
}

.art-panel {
  position: relative;
  min-height: 480px;
  display: grid;
  place-items: center;
  margin: 86px 0;
  overflow: hidden;
  border: 1px solid var(--rule);
  border-radius: 28px;
  background: rgba(20, 38, 91, 0.23);
}

.evidence-section {
  border-top: 1px solid var(--rule);
  margin: 20px 0 0;
  padding: 86px 0 108px;
}

.evidence-section > header {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 8vw;
  align-items: end;
  margin-bottom: 54px;
}

.evidence-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.evidence-grid article {
  min-height: 370px;
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  padding: 28px;
  background: rgba(20, 38, 91, 0.24);
}

.evidence-grid article:nth-child(2) {
  background: rgba(77, 107, 255, 0.12);
}

.evidence-grid h3 {
  margin: 78px 0 24px;
  font-family: "Bodoni Moda", serif;
  font-size: 29px;
  font-weight: 500;
}

.evidence-grid ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.evidence-grid li {
  border-top: 1px solid var(--rule);
  padding: 12px 0;
  color: var(--muted);
  font-size: 12px;
}

.evidence-grid li::before {
  content: "↳";
  margin-right: 10px;
  color: var(--accent);
}

.read-surface {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 8vw;
  border-top: 1px solid var(--rule);
  padding: 100px 0;
}

.endpoint-stack {
  display: grid;
  gap: 12px;
}

.endpoint-stack article {
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  padding: 24px;
  background: rgba(20, 38, 91, 0.24);
}

.endpoint-stack article > div {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 30px;
}

.endpoint-stack span {
  color: var(--accent);
  font: 600 9px/1 "Azeret Mono", monospace;
}

.endpoint-stack code {
  color: var(--plate);
  font-size: 13px;
}

.endpoint-stack p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.endpoint-stack .schema-line {
  display: flex;
  align-items: center;
  gap: 20px;
  background: var(--plate);
}

.endpoint-stack .schema-line code {
  color: var(--ink);
  overflow-wrap: anywhere;
}

.art-panel::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(185, 198, 224, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(185, 198, 224, 0.05) 1px, transparent 1px);
  background-size: 48px 48px;
}

.art-panel img {
  position: relative;
  z-index: 1;
  width: min(92%, 1240px);
  max-height: 640px;
  object-fit: contain;
}

.art-caption {
  position: absolute;
  z-index: 2;
  right: 22px;
  bottom: 18px;
  color: var(--muted);
  font: 600 9px/1 "Azeret Mono", monospace;
  letter-spacing: 0.07em;
}

.boundary-strip {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 8vw;
  align-items: start;
  border-top: 1px solid var(--rule);
  padding: 100px 0 110px;
}

.boundary-strip h2 {
  font-family: "Bodoni Moda", serif;
  font-size: 43px;
  font-weight: 500;
  line-height: 1;
}

.boundary-strip p {
  color: var(--muted);
  font-size: 17px;
  line-height: 1.7;
}

.route-shell {
  min-height: 100svh;
  padding-top: 145px;
}

.route-title {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 8vw;
  align-items: end;
  border-bottom: 1px solid var(--rule);
  padding-bottom: 46px;
}

.route-title .eyebrow {
  margin-bottom: 18px;
}

.route-grid {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 52px;
  align-items: start;
  padding: 72px 0;
}

.route-grid.reverse {
  grid-template-columns: 1.15fr 0.85fr;
}

.route-grid > .art-panel {
  min-height: 520px;
  margin: 0;
  position: sticky;
  top: 98px;
}

.route-grid > .art-panel img {
  max-height: 500px;
}

.data-stack {
  display: grid;
  gap: 18px;
}

.data-card {
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  padding: 24px;
  background: rgba(20, 38, 91, 0.24);
}

.data-card.plate {
  background: var(--plate);
  color: var(--ink);
}

.data-card h2,
.data-card h3 {
  margin-bottom: 18px;
  font-family: "Bodoni Moda", serif;
  font-weight: 500;
}

.data-card h2 {
  font-size: 34px;
}

.data-card h3 {
  font-size: 24px;
}

.data-card p {
  color: var(--muted);
  line-height: 1.65;
}

.data-card.plate p {
  color: rgba(16, 19, 26, 0.7);
}

.settled-stack {
  gap: 22px;
}

.settlement-overview {
  padding: 30px;
}

.settlement-overview > p {
  max-width: 660px;
}

.settlement-totals {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid rgba(16, 19, 26, 0.14);
  border-bottom: 1px solid rgba(16, 19, 26, 0.14);
  margin: 28px 0 18px;
}

.settlement-totals div {
  min-height: 104px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border-right: 1px solid rgba(16, 19, 26, 0.14);
  padding: 18px;
}

.settlement-totals div:first-child {
  padding-left: 0;
}

.settlement-totals div:last-child {
  border-right: 0;
  padding-right: 0;
}

.settlement-totals span,
.empty-count {
  color: rgba(16, 19, 26, 0.52);
  font: 600 8px/1.4 "Azeret Mono", monospace;
  letter-spacing: 0.05em;
}

.settlement-totals strong {
  font: 600 32px/1 "Azeret Mono", monospace;
}

.card-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 26px;
}

.card-heading h3 {
  margin: 12px 0 0;
}

.card-heading > code,
.empty-count {
  flex: 0 0 auto;
  border: 1px solid var(--rule);
  border-radius: 999px;
  padding: 8px 10px;
  color: var(--muted);
  font-size: 8px;
}

.settlement-flow {
  margin: 0;
  padding: 0;
  list-style: none;
}

.settlement-flow li {
  position: relative;
  display: grid;
  grid-template-columns: 42px 1fr;
  gap: 18px;
  border-top: 1px solid var(--rule);
  padding: 20px 0;
}

.settlement-flow li:last-child {
  padding-bottom: 0;
}

.settlement-flow li > span {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border: 1px solid var(--accent);
  border-radius: 50%;
  color: var(--accent);
  font: 600 9px/1 "Azeret Mono", monospace;
}

.settlement-flow strong {
  font-size: 14px;
}

.settlement-flow p {
  margin: 7px 0 0;
  font-size: 13px;
}

.table-scroll {
  overflow-x: auto;
}

.settlement-table {
  min-width: 720px;
}

.receipt-table td:nth-child(2) {
  color: var(--ink);
  font-family: "DM Sans", sans-serif;
  font-size: 13px;
}

.receipt-table td:last-child {
  text-transform: uppercase;
}

.admission-card {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 30px;
  align-items: stretch;
}

.admission-card > div {
  padding: 10px 0;
}

.admission-card > code {
  display: grid;
  align-content: center;
  border: 1px solid rgba(77, 107, 255, 0.52);
  border-radius: 12px;
  padding: 24px;
  background: rgba(77, 107, 255, 0.1);
  color: var(--plate);
  font-size: 12px;
  line-height: 1.8;
}

.failure-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  border-top: 1px solid var(--rule);
  border-left: 1px solid var(--rule);
}

.failure-grid article {
  min-height: 150px;
  border-right: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  padding: 20px;
}

.failure-grid article > span {
  color: var(--accent);
  font: 600 8px/1.4 "Azeret Mono", monospace;
  letter-spacing: 0.04em;
}

.failure-grid article p {
  margin: 34px 0 0;
  font-size: 12px;
  line-height: 1.55;
}

.immutable-card {
  display: grid;
  grid-template-columns: 0.78fr 1.22fr;
  gap: 38px;
}

.immutable-card h3 {
  margin-top: 12px;
}

.house-stack {
  gap: 22px;
}

.house-overview {
  padding: 30px;
}

.house-overview > p {
  max-width: 680px;
}

.house-totals {
  grid-template-columns: repeat(4, 1fr);
}

.custody-flow li {
  padding-top: 22px;
  padding-bottom: 22px;
}

.ownership-table {
  min-width: 760px;
}

.registry-table td:nth-child(2) {
  color: rgba(16, 19, 26, 0.72);
  font-family: "DM Sans", sans-serif;
  font-size: 13px;
}

.house-controls-card {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px;
  padding: 0;
  overflow: hidden;
}

.house-controls-card > div {
  padding: 28px;
}

.house-controls-card > div + div {
  border-left: 1px solid var(--rule);
  background: rgba(77, 107, 255, 0.08);
}

.house-controls-card h3 {
  margin-top: 12px;
}

.house-invariants {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  border-top: 1px solid var(--rule);
  border-left: 1px solid var(--rule);
}

.house-invariants article {
  min-height: 190px;
  display: flex;
  flex-direction: column;
  border-right: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  padding: 20px;
}

.house-invariants article > span {
  color: var(--accent);
  font: 600 8px/1 "Azeret Mono", monospace;
}

.house-invariants strong {
  margin-top: 38px;
  font-size: 14px;
}

.house-invariants p {
  margin: 10px 0 0;
  font-size: 12px;
  line-height: 1.55;
}

.custody-boundary {
  display: grid;
  grid-template-columns: 0.72fr 1.28fr;
  gap: 34px;
  align-items: center;
  border-color: rgba(77, 107, 255, 0.55);
  background: rgba(77, 107, 255, 0.1);
}

.custody-boundary h3 {
  margin: 12px 0 0;
}

.custody-boundary > p {
  margin: 0;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.data-table th,
.data-table td {
  padding: 15px 12px;
  border-bottom: 1px solid var(--rule);
  text-align: left;
  vertical-align: top;
}

.data-card.plate .data-table th,
.data-card.plate .data-table td {
  border-color: rgba(16, 19, 26, 0.14);
}

.data-table th {
  color: var(--muted);
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.data-card.plate .data-table th {
  color: rgba(16, 19, 26, 0.56);
}

.data-table td:last-child {
  color: var(--accent);
  font-family: "Azeret Mono", monospace;
  font-size: 11px;
}

.formula {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 14px;
  margin: 22px 0;
}

.formula code {
  min-height: 90px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(16, 19, 26, 0.14);
  border-radius: 12px;
  background: rgba(77, 107, 255, 0.1);
  font-size: 12px;
  text-align: center;
}

.formula span {
  color: var(--accent);
  font-family: "Azeret Mono", monospace;
}

.rule-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

.rule-card {
  min-height: 245px;
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  padding: 26px;
  background: rgba(20, 38, 91, 0.24);
}

.rule-index {
  display: inline-grid;
  width: 34px;
  height: 34px;
  place-items: center;
  margin-bottom: 52px;
  border: 1px solid var(--accent);
  border-radius: 50%;
  color: var(--accent);
  font-size: 10px;
}

.rule-card h2 {
  font-family: "Bodoni Moda", serif;
  font-size: 26px;
  font-weight: 500;
}

.rule-card p {
  color: var(--muted);
  line-height: 1.6;
}

.join-form {
  display: grid;
  gap: 14px;
}

.join-form label {
  display: grid;
  gap: 8px;
}

.join-form span {
  color: var(--muted);
  font: 600 9px/1 "Azeret Mono", monospace;
  letter-spacing: 0.06em;
}

.join-form input,
.join-form select {
  width: 100%;
  border: 1px solid var(--rule);
  border-radius: 10px;
  padding: 15px;
  background: rgba(9, 13, 26, 0.7);
  color: var(--plate);
  outline: none;
}

.join-form input:focus,
.join-form select:focus {
  border-color: var(--accent);
}

.join-form button {
  min-height: 48px;
  border: 0;
  border-radius: 999px;
  background: var(--accent);
  color: var(--ink);
  font-weight: 700;
}

.join-form button:disabled {
  background: rgba(185, 198, 224, 0.26);
  color: var(--muted);
}

.site-footer {
  position: relative;
  border-top: 1px solid var(--rule);
  background: #070a13;
  padding: 24px 0 16px;
}

.footer-compact {
  display: grid;
  grid-template-columns: minmax(320px, 1.25fr) auto auto;
  gap: 34px;
  align-items: center;
}

.footer-identity {
  display: flex;
  align-items: center;
  gap: 18px;
}

.footer-mark {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 10px;
}

.footer-mark strong {
  font-family: "Bodoni Moda", serif;
  font-size: 23px;
}

.site-footer p {
  max-width: 390px;
  margin: 0;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.5;
}

.footer-links {
  display: flex;
  align-items: center;
  gap: 18px;
}

.footer-links a {
  color: var(--muted);
  font: 600 9px/1.4 "Azeret Mono", monospace;
  text-decoration: none;
}

.footer-links a:hover {
  color: var(--plate);
}

.footer-state {
  display: grid;
  gap: 6px;
  border-left: 1px solid var(--rule);
  padding-left: 24px;
  color: var(--muted);
  font: 400 8px/1.35 "Azeret Mono", monospace;
  white-space: nowrap;
}

.footer-state strong {
  margin-left: 7px;
  color: var(--plate);
  font-weight: 600;
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  border-top: 1px solid var(--rule);
  margin-top: 18px;
  padding-top: 13px;
  color: var(--muted);
  font: 400 8px/1.4 "Azeret Mono", monospace;
}

.toast {
  position: fixed;
  z-index: 90;
  right: 22px;
  bottom: 22px;
  transform: translateY(20px);
  border: 1px solid var(--accent);
  border-radius: 10px;
  padding: 12px 16px;
  background: var(--panel);
  color: var(--plate);
  opacity: 0;
  pointer-events: none;
  font: 600 10px/1 "Azeret Mono", monospace;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.toast.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 1180px) {
  .site-header {
    grid-template-columns: 1fr auto;
  }

  .desktop-nav {
    display: none;
  }

  .hero-copy,
  .command-rail {
    width: 42vw;
  }

  .hero-media,
  .hero-poster {
    object-position: 58% center;
  }

  .instrument-data {
    left: 68%;
  }
}

@media (max-width: 880px) {
  .social-state {
    display: none;
  }

  .menu-button {
    display: block;
    justify-self: end;
  }

  .mobile-nav {
    position: absolute;
    top: 70px;
    right: 20px;
    width: min(300px, calc(100vw - 40px));
    display: none;
    grid-template-columns: 1fr 1fr;
    gap: 4px;
    border: 1px solid var(--rule);
    border-radius: 14px;
    padding: 12px;
    background: rgba(9, 13, 26, 0.98);
  }

  .mobile-nav.is-open {
    display: grid;
  }

  .mobile-nav a {
    padding: 12px;
  }

  .hero-content {
    width: calc(100% - 36px);
    min-height: 650px;
  }

  .hero-copy {
    top: 17%;
    width: 56vw;
  }

  .hero-copy h1 {
    font-size: clamp(52px, 9.5vw, 76px);
  }

  .hero-copy p {
    max-width: 330px;
    font-size: 16px;
  }

  .hero-actions {
    bottom: 25%;
  }

  .command-rail {
    bottom: 11%;
    width: min(520px, 70vw);
  }

  .hero-meter {
    left: 18px;
    right: 18px;
  }

  .section-heading,
  .route-title,
  .boundary-strip,
  .floor-anatomy,
  .evidence-section > header,
  .read-surface,
  .route-grid,
  .route-grid.reverse,
  .empty-state {
    grid-template-columns: 1fr;
  }

  .footer-compact {
    grid-template-columns: 1fr auto;
    gap: 18px;
  }

  .footer-state {
    grid-column: 1 / -1;
    display: flex;
    flex-wrap: wrap;
    gap: 10px 22px;
    border-top: 1px solid var(--rule);
    border-left: 0;
    padding-top: 13px;
    padding-left: 0;
  }

  .section-heading,
  .route-title,
  .boundary-strip,
  .floor-anatomy,
  .evidence-section > header,
  .read-surface {
    gap: 24px;
  }

  .floor-brief,
  .evidence-grid {
    grid-template-columns: 1fr;
  }

  .admission-card,
  .immutable-card,
  .house-controls-card,
  .custody-boundary {
    grid-template-columns: 1fr;
  }

  .house-controls-card > div + div {
    border-top: 1px solid var(--rule);
    border-left: 0;
  }

  .brief-card,
  .evidence-grid article {
    min-height: 0;
  }

  .section-kicker {
    position: relative;
    top: auto;
  }

  .route-grid > .art-panel {
    position: relative;
    top: auto;
    min-height: 420px;
  }

  .status-rail {
    grid-template-columns: repeat(2, 1fr);
  }

  .metric:nth-child(2) {
    border-right: 0;
  }

  .metric:nth-child(-n + 2) {
    border-bottom: 1px solid var(--rule);
  }
}

@media (max-width: 560px) {
  body {
    background-size: 42px 42px;
  }

  .site-header {
    height: 62px;
    padding: 0 16px;
  }

  .brand img {
    width: 34px;
    height: 34px;
  }

  .brand span {
    font-size: 18px;
  }

  .mobile-nav {
    top: 62px;
    right: 12px;
    width: calc(100vw - 24px);
  }

  .hero-track {
    height: 270vh;
  }

  .hero-stage,
  .hero-content {
    min-height: 720px;
  }

  .hero-poster {
    top: auto;
    bottom: 0;
    left: -20%;
    width: 140%;
    height: 70%;
    background-position: 68% center;
    background-size: cover;
  }

  .hero-media {
    top: auto;
    bottom: 0;
    left: -20%;
    width: 140%;
    height: 70%;
    object-position: 68% center;
  }

  .instrument-data {
    top: 55%;
    left: 66%;
    width: 190px;
    opacity: 0.92;
  }

  .instrument-data span,
  .instrument-data small {
    font-size: 9px;
  }

  .instrument-data strong {
    font-size: 54px;
  }

  .instrument-data em {
    font-size: 8px;
  }

  .hero-content {
    width: calc(100% - 30px);
    padding-top: 88px;
  }

  .hero-copy {
    top: 11.5%;
    width: 92%;
  }

  .hero-copy .eyebrow {
    margin-bottom: 14px;
  }

  .hero-copy h1 {
    width: 310px;
    margin-bottom: 20px;
    font-size: 48px;
  }

  .hero-copy p {
    width: 270px;
    color: #d8e0f1;
    font-size: 14px;
  }

  .hero-actions {
    bottom: 27%;
    flex-wrap: wrap;
  }

  .button {
    min-height: 44px;
    padding: 0 16px;
    font-size: 13px;
  }

  .command-rail {
    bottom: 11.5%;
    width: 100%;
  }

  .hero-meter {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    bottom: 18px;
  }

  .hero-meter span {
    padding-right: 6px;
    font-size: 7px;
    line-height: 1.35;
  }

  .content-wrap {
    width: calc(100% - 30px);
  }

  .home-content {
    padding-top: 76px;
  }

  .section-heading {
    margin-bottom: 42px;
  }

  .section-heading h2,
  .route-title h1 {
    font-size: 54px;
  }

  .section-heading p,
  .route-title > p {
    font-size: 15px;
  }

  .status-rail {
    grid-template-columns: 1fr;
  }

  .metric {
    min-height: 102px;
    border-right: 0;
    border-bottom: 1px solid var(--rule);
  }

  .metric:last-child {
    border-bottom: 0;
  }

  .floor-controls {
    align-items: flex-start;
    flex-direction: column;
  }

  .floor-brief {
    margin-bottom: 66px;
  }

  .brief-card {
    padding: 22px;
  }

  .brief-card h3 {
    margin-top: 34px;
  }

  .brief-facts {
    margin-top: 32px;
  }

  .floor-anatomy {
    margin-top: 78px;
    padding-top: 58px;
  }

  .anatomy-grid {
    grid-template-columns: 1fr;
  }

  .anatomy-grid article {
    min-height: 205px;
  }

  .evidence-section {
    padding: 68px 0 76px;
  }

  .evidence-grid h3 {
    margin-top: 54px;
  }

  .read-surface,
  .boundary-strip {
    padding: 72px 0;
  }

  .endpoint-stack .schema-line {
    align-items: flex-start;
    flex-direction: column;
  }

  .settlement-overview {
    padding: 22px;
  }

  .house-overview {
    padding: 22px;
  }

  .settlement-totals {
    grid-template-columns: 1fr;
  }

  .settlement-totals div,
  .settlement-totals div:first-child,
  .settlement-totals div:last-child {
    min-height: 78px;
    border-right: 0;
    border-bottom: 1px solid rgba(16, 19, 26, 0.14);
    padding: 14px 0;
  }

  .settlement-totals div:last-child {
    border-bottom: 0;
  }

  .card-heading {
    align-items: flex-start;
    flex-direction: column;
    gap: 10px;
  }

  .failure-grid {
    grid-template-columns: 1fr;
  }

  .house-invariants {
    grid-template-columns: 1fr;
  }

  .failure-grid article {
    min-height: 130px;
  }

  .settlement-table,
  .ownership-table {
    min-width: 0;
  }

  .empty-state,
  .data-card,
  .rule-card {
    padding: 20px;
  }

  .art-panel,
  .route-grid > .art-panel {
    min-height: 330px;
    margin: 54px 0;
    border-radius: 18px;
  }

  .route-shell {
    padding-top: 106px;
  }

  .route-grid {
    gap: 12px;
    padding: 48px 0;
  }

  .route-grid > .art-panel {
    margin: 0 0 28px;
  }

  .rule-list {
    grid-template-columns: 1fr;
  }

  .data-table thead {
    display: none;
  }

  .data-table,
  .data-table tbody,
  .data-table tr,
  .data-table td {
    display: block;
    width: 100%;
  }

  .data-table tr {
    border-bottom: 1px solid var(--rule);
    padding: 10px 0;
  }

  .data-table td {
    display: grid;
    grid-template-columns: 42% 58%;
    gap: 10px;
    border: 0;
    padding: 7px 0;
    overflow-wrap: anywhere;
  }

  .data-table td::before {
    content: attr(data-label);
    color: var(--muted);
    font: 600 9px/1.4 "Azeret Mono", monospace;
    text-transform: uppercase;
  }

  .formula {
    grid-template-columns: 1fr;
  }

  .formula span {
    transform: rotate(90deg);
    justify-self: center;
  }

  .footer-bottom {
    flex-direction: column;
  }

  .footer-compact {
    grid-template-columns: 1fr;
  }

  .footer-identity {
    align-items: flex-start;
  }

  .footer-links {
    gap: 22px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation: none !important;
    transition-duration: 0.01ms !important;
  }

  .hero-track {
    height: 100svh;
  }

  .hero-media {
    display: none;
  }

  .hero-copy {
    display: none;
  }

  .hero-copy:first-of-type {
    display: block;
    opacity: 1;
    transform: none;
  }
}
