:root {
  --paper: #e9edf3;
  --panel: #d9dde8;
  --panel-2: #c9d2d8;
  --ink: #171526;
  --muted: #565d72;
  --rule: #a7b2c2;
  --teal: #0f7c7a;
  --brass: #b88726;
  --plum: #4b2e62;
  --chalk: #f4f7fb;
  --fault: #d66b4f;
  --shadow: rgba(23, 21, 38, 0.14);
  --display: 'Bahnschrift', 'DIN Condensed', 'Arial Narrow', 'Aptos Display', 'Segoe UI Condensed', sans-serif;
  --body: 'Aptos', 'Segoe UI', 'Helvetica Neue', Arial, sans-serif;
  --mono: 'Cascadia Mono', 'SFMono-Regular', Consolas, 'Liberation Mono', monospace;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: var(--body);
  line-height: 1.55;
}

a { color: inherit; }

.accord-site,
.accord-article {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

.mast-bay {
  min-height: 520px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 250px;
  gap: 28px;
  align-items: stretch;
  padding: 42px 0 26px;
}

.mast-left {
  position: relative;
  border: 2px solid var(--ink);
  background: var(--chalk);
  padding: clamp(28px, 5vw, 62px);
  box-shadow: 10px 10px 0 var(--panel-2);
}

.mast-left:before {
  content: '';
  position: absolute;
  inset: 16px auto 16px 18px;
  width: 7px;
  background: var(--teal);
}

.kicker,
.section-label {
  margin: 0 0 14px;
  color: var(--teal);
  font-family: var(--mono);
  font-size: 0.74rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 700;
}

.mast-left h1 {
  margin: 0;
  max-width: 840px;
  font-family: var(--display);
  font-size: clamp(4.8rem, 13vw, 10.8rem);
  line-height: 0.82;
  letter-spacing: -0.075em;
  text-transform: uppercase;
}

.public-description {
  max-width: 760px;
  margin: 32px 0 0;
  color: #2d3142;
  font-size: clamp(1.08rem, 1.8vw, 1.42rem);
  line-height: 1.42;
}

.operator-line {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-top: 34px;
  padding-top: 18px;
  border-top: 1px solid var(--rule);
  color: var(--muted);
  font-size: 0.94rem;
}

.operator-line strong {
  color: var(--ink);
  font-family: var(--mono);
  background: #efe7d6;
  border: 1px solid var(--brass);
  padding: 3px 8px;
}

.seam-gauge {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border: 2px solid var(--ink);
  background: var(--panel);
  padding: 22px 18px;
  min-height: 100%;
  overflow: hidden;
}

.seam-gauge:before {
  content: '';
  position: absolute;
  top: 58px;
  bottom: 28px;
  left: 50%;
  border-left: 2px solid var(--plum);
}

.seam-gauge:after {
  content: '';
  position: absolute;
  top: 58px;
  bottom: 28px;
  left: calc(50% + 10px);
  border-left: 1px dashed var(--fault);
}

.gauge-label {
  position: relative;
  z-index: 1;
  display: block;
  padding-bottom: 15px;
  border-bottom: 1px solid var(--rule);
  color: var(--ink);
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.gauge-tab {
  position: relative;
  z-index: 1;
  width: 48%;
  min-height: 42px;
  display: grid;
  place-items: center;
  border: 1px solid var(--ink);
  background: var(--chalk);
  font-family: var(--mono);
  font-size: 0.74rem;
  text-transform: uppercase;
  box-shadow: 4px 4px 0 rgba(75, 46, 98, 0.17);
}

.tab-a,
.tab-c { align-self: flex-start; }
.tab-b,
.tab-d { align-self: flex-end; }
.tab-b { background: #e7dec8; }
.tab-c { background: #d5eceb; }
.tab-d { background: #ead8d2; }

.route-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  margin: 28px 0;
  border: 2px solid var(--ink);
  background: var(--chalk);
  box-shadow: 8px 8px 0 var(--shadow);
}

.route-node {
  position: relative;
  min-height: 230px;
  padding: 24px 22px 22px;
  border-right: 1px solid var(--rule);
}

.route-node:last-child { border-right: 0; }

.route-node:after {
  content: '';
  position: absolute;
  right: -10px;
  top: 50%;
  width: 18px;
  height: 18px;
  margin-top: -9px;
  border-top: 2px solid var(--teal);
  border-right: 2px solid var(--teal);
  background: var(--chalk);
  transform: rotate(45deg);
  z-index: 2;
}

.route-node:last-child:after { display: none; }

.node-number {
  display: inline-block;
  margin-bottom: 34px;
  color: var(--brass);
  font-family: var(--mono);
  font-size: 0.82rem;
  font-weight: 800;
}

.route-node h2,
.topic-bench h2,
.stress-bench h2,
.bay-title-row h2 {
  margin: 0;
  font-family: var(--display);
  line-height: 0.98;
  letter-spacing: -0.035em;
  text-transform: uppercase;
}

.route-node h2 { font-size: 2rem; }
.route-node p { margin: 14px 0 0; color: var(--muted); font-size: 0.96rem; }

.topic-bench {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 24px;
  align-items: start;
  margin: 34px 0;
  padding: 28px;
  border-left: 9px solid var(--plum);
  background: var(--panel);
}

.topic-bench h2 { font-size: clamp(2rem, 4vw, 4rem); max-width: 620px; }

.chip-rack {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
}

.chip-rack a,
.chip-rack span {
  display: inline-block;
  padding: 10px 13px;
  border: 1px solid var(--ink);
  background: var(--chalk);
  color: var(--ink);
  font-family: var(--mono);
  font-size: 0.78rem;
  text-decoration: none;
  text-transform: uppercase;
  box-shadow: 3px 3px 0 rgba(15, 124, 122, 0.23);
}

.stress-bench {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(320px, 1.05fr);
  gap: 26px;
  margin: 42px 0;
}

.stress-copy {
  padding: 30px;
  border: 2px solid var(--ink);
  background: var(--chalk);
}

.stress-copy h2 { font-size: clamp(2.5rem, 5vw, 5.2rem); }
.stress-copy p:not(.section-label) { color: #33384b; font-size: 1.05rem; }

.mirror-board {
  display: grid;
  grid-template-columns: 1fr 26px 1fr;
  min-height: 300px;
  border: 2px solid var(--ink);
  background: var(--panel-2);
}

.mirror-half {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 26px;
}

.mirror-half span {
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.78rem;
  text-transform: uppercase;
}

.mirror-half strong {
  display: block;
  font-family: var(--display);
  font-size: clamp(2rem, 4vw, 4.2rem);
  line-height: 0.95;
  letter-spacing: -0.045em;
  text-transform: uppercase;
}

.mirror-seam {
  border-left: 2px solid var(--plum);
  border-right: 1px dashed var(--fault);
  background: #ece4d6;
}

.post-bay {
  margin: 50px 0 76px;
}

.bay-title-row {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: end;
  padding-bottom: 16px;
  border-bottom: 2px solid var(--ink);
}

.bay-title-row h2 { font-size: clamp(2.2rem, 5vw, 5rem); max-width: 720px; text-align: right; }

.coupler-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-top: 20px;
}

.post-coupler { min-width: 0; }

.coupler-hit {
  position: relative;
  display: flex;
  min-height: 360px;
  height: 100%;
  flex-direction: column;
  padding: 18px;
  border: 2px solid var(--ink);
  background: var(--chalk);
  color: var(--ink);
  text-decoration: none;
  box-shadow: 6px 6px 0 var(--panel-2);
  transition: transform 120ms ease, box-shadow 120ms ease;
}

.coupler-hit:hover,
.coupler-hit:focus-visible {
  transform: translate(-2px, -2px);
  box-shadow: 10px 10px 0 rgba(15, 124, 122, 0.25);
  outline: 0;
}

.coupler-top,
.card-footer {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.plate-code { color: var(--teal); }

.lane-plate {
  display: grid;
  grid-template-columns: 1fr 12px 1fr;
  align-items: stretch;
  height: 58px;
  margin: 24px 0;
  border: 1px solid var(--ink);
}

.lane {
  display: grid;
  place-items: center;
  font-family: var(--mono);
  font-size: 0.68rem;
  color: var(--muted);
  background: var(--panel);
}

.lane-right { background: #e8dfd2; }

.lane-joint {
  border-left: 2px solid var(--plum);
  border-right: 1px dashed var(--fault);
  background: var(--brass);
}

.post-coupler h3 {
  margin: 0;
  font-family: var(--display);
  font-size: clamp(2.1rem, 3vw, 3.35rem);
  line-height: 0.94;
  letter-spacing: -0.045em;
  text-transform: uppercase;
}

.post-coupler p {
  margin: 18px 0 26px;
  color: #34394b;
  font-size: 1rem;
}

.card-footer {
  margin-top: auto;
  padding-top: 16px;
  border-top: 1px solid var(--rule);
}

.article-return {
  padding: 22px 0 0;
  font-family: var(--mono);
  font-size: 0.82rem;
  text-transform: uppercase;
}

.article-return a {
  display: inline-block;
  padding: 8px 10px;
  border: 1px solid var(--ink);
  background: var(--chalk);
  text-decoration: none;
  box-shadow: 3px 3px 0 var(--panel-2);
}

.article-bay {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr) 190px;
  gap: 22px;
  align-items: stretch;
  margin: 22px 0 28px;
}

.article-brand {
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  display: flex;
  justify-content: flex-end;
  align-items: center;
  padding: 18px;
  border: 2px solid var(--ink);
  background: var(--panel-2);
  font-family: var(--display);
  font-size: 2.35rem;
  line-height: 0.88;
  letter-spacing: -0.05em;
  text-transform: uppercase;
}

.article-title-block {
  border: 2px solid var(--ink);
  background: var(--chalk);
  padding: clamp(26px, 5vw, 54px);
  box-shadow: 8px 8px 0 var(--panel-2);
}

.article-title-block h1 {
  margin: 0;
  font-family: var(--display);
  font-size: clamp(4rem, 10vw, 9rem);
  line-height: 0.84;
  letter-spacing: -0.07em;
  text-transform: uppercase;
}

.article-meta {
  margin-top: 28px;
  padding-top: 16px;
  border-top: 1px solid var(--rule);
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.78rem;
  text-transform: uppercase;
}

.article-gauge { min-height: 430px; }

.treaty-frame {
  display: grid;
  grid-template-columns: 230px minmax(0, 720px) 126px;
  gap: 28px;
  align-items: start;
  margin-bottom: 90px;
}

.treaty-notes {
  position: sticky;
  top: 20px;
  padding: 18px;
  border: 2px solid var(--ink);
  background: var(--panel);
}

.treaty-notes ol {
  margin: 0;
  padding-left: 20px;
  color: #30364a;
  font-size: 0.92rem;
}

.treaty-notes li + li { margin-top: 12px; }

.article-body {
  padding: 38px clamp(24px, 5vw, 54px);
  border: 2px solid var(--ink);
  background: var(--chalk);
  box-shadow: 8px 8px 0 var(--shadow);
}

.article-body > *:first-child { margin-top: 0; }
.article-body > *:last-child { margin-bottom: 0; }

.article-body p,
.article-body li {
  color: #252b3c;
  font-size: 1.08rem;
  line-height: 1.72;
}

.article-body h2,
.article-body h3 {
  margin: 2.1em 0 0.65em;
  font-family: var(--display);
  line-height: 0.98;
  letter-spacing: -0.035em;
  text-transform: uppercase;
}

.article-body h2 {
  font-size: clamp(2.3rem, 4vw, 4.1rem);
  padding-top: 18px;
  border-top: 2px solid var(--ink);
}

.article-body h3 { font-size: 2.1rem; }

.article-body blockquote {
  margin: 28px 0;
  padding: 18px 22px;
  border-left: 8px solid var(--teal);
  background: var(--panel);
  color: var(--ink);
  font-family: var(--display);
  font-size: 2rem;
  line-height: 1.05;
  letter-spacing: -0.035em;
  text-transform: uppercase;
}

.article-body ul,
.article-body ol { padding-left: 1.35rem; }

.article-body code {
  font-family: var(--mono);
  font-size: 0.9em;
  background: #e8dfd2;
  border: 1px solid var(--brass);
  padding: 0.08em 0.3em;
}

.checkpoint-rail {
  position: sticky;
  top: 20px;
  display: grid;
  gap: 12px;
}

.checkpoint {
  min-height: 86px;
  padding: 12px;
  border: 2px solid var(--ink);
  background: var(--panel-2);
}

.checkpoint span {
  display: block;
  margin-bottom: 16px;
  color: var(--brass);
  font-family: var(--mono);
  font-size: 0.75rem;
  font-weight: 800;
}

.checkpoint strong {
  display: block;
  font-family: var(--display);
  font-size: 1.55rem;
  line-height: 0.9;
  text-transform: uppercase;
}

@media (max-width: 980px) {
  .mast-bay,
  .stress-bench,
  .topic-bench,
  .article-bay,
  .treaty-frame {
    grid-template-columns: 1fr;
  }

  .hero-gauge,
  .article-gauge { min-height: 260px; }

  .route-strip,
  .coupler-grid { grid-template-columns: 1fr 1fr; }

  .article-brand {
    writing-mode: horizontal-tb;
    transform: none;
    justify-content: flex-start;
  }

  .treaty-notes,
  .checkpoint-rail { position: static; }

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

@media (max-width: 640px) {
  .accord-site,
  .accord-article { width: min(100% - 22px, 1180px); }

  .mast-bay { padding-top: 18px; }

  .mast-left { padding: 26px 22px 28px 34px; box-shadow: 5px 5px 0 var(--panel-2); }

  .mast-left h1 { font-size: clamp(3.8rem, 18vw, 6rem); }

  .route-strip,
  .coupler-grid,
  .mirror-board,
  .checkpoint-rail { grid-template-columns: 1fr; }

  .route-node { min-height: auto; border-right: 0; border-bottom: 1px solid var(--rule); }
  .route-node:after { display: none; }

  .bay-title-row { display: block; }
  .bay-title-row h2 { text-align: left; }

  .mirror-seam { min-height: 18px; border-left: 0; border-right: 0; border-top: 2px solid var(--plum); border-bottom: 1px dashed var(--fault); }

  .article-title-block h1 { font-size: clamp(3.4rem, 16vw, 5.6rem); }

  .article-body { padding: 28px 20px; }
}