/* Vertical register: art and controls share one paper axis, never a split hero. */
.hero {
  align-items: flex-start;
}

@media (min-width: 1180px) {
  .receipt-runway {
    width: min(860px, 60vw);
  }

  .outer-readout {
    width: 250px;
  }

  .outer-readout.left {
    left: max(20px, calc(50% - 700px));
  }

  .outer-readout.right {
    right: max(20px, calc(50% - 700px));
  }
}

.side-stack {
  margin-top: 24px;
  border: 1px solid var(--ink);
  background: rgba(247,247,244,.62);
}

.side-stack > div {
  padding: 13px 12px;
  border-bottom: 1px solid var(--ink);
}

.side-stack > div:last-child {
  border-bottom: 0;
}

.side-stack b {
  display: block;
  margin-top: 6px;
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 400;
  overflow-wrap: anywhere;
}

.counter-section {
  grid-template-columns: 1fr;
}

.counter-section > div:first-child {
  max-width: 760px;
  margin: 0 auto;
  text-align: center;
}

.counter-section .button-row {
  justify-content: center;
}

.counter-section .art-frame {
  width: 100%;
  min-height: 380px;
  margin-top: 18px;
}

.workbench {
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.workbench > .art-frame {
  order: -1;
  width: 100%;
  height: 420px;
}

.workbench > .control-panel,
.workbench > .receipt-ticket,
.workbench > section {
  width: min(760px, 100%);
  margin-right: auto;
  margin-left: auto;
}

.workbench > .art-frame img {
  max-height: 360px;
}

@media (max-width: 719px) {
  .hero-stage .end {
    animation: receipt-state-loop 10s ease-in-out infinite;
  }

  .counter-section > div:first-child {
    text-align: left;
  }

  .counter-section .button-row {
    justify-content: flex-start;
  }

  .counter-section .art-frame {
    min-height: 250px;
  }

  .workbench > .art-frame {
    height: 300px;
  }

  .workbench > .art-frame img {
    max-height: 250px;
  }
}

  .hero-stage .end {
    animation: none;
  }
}

/* Counter operating sheet: dense, edge-conscious and evidence-first. */
.content-shell.counter-board {
  width: calc(100% - 24px);
  max-width: none;
  padding-top: 54px;
}

.counter-board-head {
  border: 2px solid var(--ink);
  background: var(--paper);
  padding: 22px 28px 26px;
}

.counter-board-head h2 {
  margin: 18px 0 22px;
  font-size: clamp(58px, 6.8vw, 112px);
  line-height: .84;
  white-space: nowrap;
}

.counter-intro {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 30px;
  border-top: 2px solid var(--ink);
  padding-top: 18px;
}

.counter-intro p {
  max-width: 720px;
  margin: 0;
  font-size: 18px;
}

.counter-machine {
  position: relative;
  min-width: 0;
  border-right: 2px solid var(--ink);
  background: rgba(247,247,244,.72);
}

.counter-machine > .art-frame {
  height: 310px;
  min-height: 0;
  border: 0;
  background: transparent;
  padding: 24px 26px 52px;
}

.counter-machine > .art-frame img {
  width: 100%;
  max-width: 680px;
  max-height: 225px;
  height: 100%;
  object-fit: contain;
}

.machine-caption {
  position: absolute;
  right: 18px;
  bottom: 12px;
  left: 18px;
  display: flex;
  justify-content: space-between;
  gap: 18px;
  font-family: var(--mono);
  font-size: 10px;
  color: var(--muted);
}

.counter-console {
  display: grid;
  grid-template-columns: minmax(380px, .72fr) minmax(0, 1.28fr);
  border: 2px solid var(--ink);
  border-top: 0;
  background: var(--paper);
}

.counter-controls {
  display: grid;
  min-width: 0;
  grid-template-rows: 1fr auto;
}

.counter-rail {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  border: 0;
  background: var(--ink);
  color: var(--paper);
}

.counter-rail > div {
  min-height: 126px;
  padding: 18px;
  border-right: 1px solid var(--paper);
}

.counter-rail > div:last-child {
  border-right: 0;
}

.counter-rail b,
.counter-rail span,
.counter-rail small {
  display: block;
}

.counter-rail b {
  font-family: var(--display);
  font-size: 42px;
  font-weight: 300;
  line-height: .8;
  color: var(--mint);
}

.counter-rail span {
  margin-top: 12px;
  font-family: var(--mono);
  font-size: 12px;
}

.counter-rail small {
  margin-top: 7px;
  color: #c9d2ce;
}

.counter-matrix {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-inline: 2px solid var(--ink);
  background: var(--paper);
}

.counter-cell {
  min-width: 0;
  min-height: 168px;
  padding: 20px;
  border-right: 1px solid var(--ink);
  border-bottom: 1px solid var(--ink);
}

.counter-cell:nth-child(4n) {
  border-right: 0;
}

.counter-cell strong {
  display: block;
  margin: 8px 0;
  font-family: var(--display);
  font-size: clamp(34px, 3.2vw, 54px);
  font-weight: 300;
  line-height: 1;
  overflow-wrap: anywhere;
}

.counter-cell small {
  display: block;
  font-family: var(--mono);
  font-size: 10px;
  color: var(--muted);
  overflow-wrap: anywhere;
}

.counter-cell.signal {
  background: var(--mint);
}

.counter-cell.compact strong {
  font-size: clamp(30px, 2.6vw, 44px);
}

.counter-bottom {
  display: grid;
  grid-template-columns: 1.1fr 1fr 1.5fr;
  border: 2px solid var(--ink);
  border-top: 0;
  background: var(--counter);
}

.counter-bottom > div {
  min-width: 0;
  padding: 18px 20px;
  border-right: 1px solid var(--ink);
}

.counter-bottom > div:last-child {
  border-right: 0;
}

.counter-bottom strong {
  display: block;
  margin-top: 8px;
  font-family: var(--mono);
  font-size: 12px;
  overflow-wrap: anywhere;
}

.counter-inspector {
  display: grid;
  grid-template-columns: 190px minmax(0, 1.5fr) minmax(300px, .75fr);
  min-height: 218px;
  border: 2px solid var(--ink);
  border-top: 0;
  background: var(--paper);
}

.counter-inspector-head {
  padding: 20px;
  color: var(--paper);
  background: var(--ink);
}

.counter-inspector-head .micro {
  color: var(--mint);
}

.counter-inspector-head strong {
  display: block;
  margin-top: 14px;
  font-family: var(--display);
  font-size: 68px;
  font-weight: 300;
  line-height: .8;
}

.counter-inspector-head p {
  margin: 18px 0 0;
  font-family: var(--mono);
  font-size: 12px;
  text-transform: uppercase;
}

.counter-checks {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  min-width: 0;
}

.counter-check {
  display: grid;
  grid-template-columns: 86px minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  min-width: 0;
  padding: 16px 18px;
  border-right: 1px solid var(--ink);
  border-bottom: 1px solid var(--ink);
  font-family: var(--mono);
  font-size: 11px;
}

.counter-check:nth-child(2n) {
  border-right: 0;
}

.counter-check:nth-last-child(-n+2) {
  border-bottom: 0;
}

.counter-check span {
  color: var(--muted);
}

.counter-check strong {
  min-width: 0;
  font-weight: 400;
  overflow-wrap: anywhere;
}

.counter-check em {
  padding: 5px 7px;
  color: var(--ink);
  background: var(--mint);
  font-size: 9px;
  font-style: normal;
  white-space: nowrap;
}

.counter-payoff {
  display: flex;
  flex-direction: column;
  padding: 22px;
  border-left: 2px solid var(--ink);
  background: var(--counter);
}

.counter-payoff p {
  margin: 18px 0;
  font-size: 16px;
}

.counter-payoff a {
  margin-top: auto;
  font-family: var(--mono);
  font-size: 12px;
  text-transform: uppercase;
}

.counter-ledger {
  border: 2px solid var(--ink);
  border-top: 0;
  background: var(--paper);
}

.counter-ledger-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 36px;
  padding: 22px 24px 18px;
  border-bottom: 2px solid var(--ink);
}

.counter-ledger-head h3 {
  margin: 7px 0 0;
  font-family: var(--display);
  font-size: clamp(42px, 4.2vw, 68px);
  font-weight: 300;
  line-height: .9;
}

.counter-ledger-head p {
  max-width: 420px;
  margin: 0;
  font-family: var(--mono);
  font-size: 11px;
  text-align: right;
  text-transform: uppercase;
}

.counter-ledger-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border-bottom: 1px solid var(--ink);
}

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

.counter-ledger-row > span {
  min-width: 0;
  padding: 13px 16px;
  border-right: 1px solid var(--ink);
  font-family: var(--mono);
  font-size: 11px;
  overflow-wrap: anywhere;
  transition: background-color 180ms ease, color 180ms ease;
}

.counter-ledger-row > span:last-child {
  border-right: 0;
}

.counter-ledger-labels {
  color: var(--paper);
  background: var(--ink);
}

.counter-ledger-labels > span {
  padding-block: 10px;
  color: inherit;
  font-size: 10px;
}

.counter-board[data-step="0"] .counter-ledger-row > span:nth-child(1),
.counter-board[data-step="1"] .counter-ledger-row > span:nth-child(2),
.counter-board[data-step="2"] .counter-ledger-row > span:nth-child(3),
.counter-board[data-step="3"] .counter-ledger-row > span:nth-child(4) {
  background: var(--counter);
}

.counter-board[data-step="0"] .counter-ledger-labels > span:nth-child(1),
.counter-board[data-step="1"] .counter-ledger-labels > span:nth-child(2),
.counter-board[data-step="2"] .counter-ledger-labels > span:nth-child(3),
.counter-board[data-step="3"] .counter-ledger-labels > span:nth-child(4) {
  color: var(--ink);
  background: var(--mint);
}

.counter-outcomes {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border: 2px solid var(--ink);
  border-top: 0;
  background: var(--paper);
}

.counter-outcomes a {
  display: flex;
  flex-direction: column;
  min-height: 176px;
  padding: 20px 22px;
  border-right: 1px solid var(--ink);
  text-decoration: none;
  transition: background-color 180ms ease;
}

.counter-outcomes a:last-child {
  border-right: 0;
}

.counter-outcomes a:hover {
  background: var(--mint);
}

.counter-outcomes span,
.counter-outcomes small,
.counter-outcomes b {
  font-family: var(--mono);
}

.counter-outcomes span {
  color: var(--muted);
  font-size: 10px;
}

.counter-outcomes strong {
  display: block;
  max-width: 420px;
  margin: 12px 0 7px;
  font-family: var(--display);
  font-size: clamp(25px, 2.25vw, 38px);
  font-weight: 300;
  line-height: 1;
}

.counter-outcomes small {
  color: var(--muted);
  font-size: 10px;
}

.counter-outcomes b {
  margin-top: auto;
  padding-top: 16px;
  font-size: 11px;
  font-weight: 400;
  text-transform: uppercase;
}

@media (max-width: 900px) {
  .counter-board-head h2 {
    white-space: normal;
  }

  .counter-intro {
    align-items: stretch;
    flex-direction: column;
  }

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

  .counter-rail > div:nth-child(2) {
    border-right: 0;
  }

  .counter-rail > div:nth-child(-n+2) {
    border-bottom: 1px solid var(--paper);
  }

  .counter-cell:nth-child(2n) {
    border-right: 0;
  }

  .counter-bottom {
    grid-template-columns: 1fr;
  }

  .counter-bottom > div {
    border-right: 0;
    border-bottom: 1px solid var(--ink);
  }

  .counter-bottom > div:last-child {
    border-bottom: 0;
  }
}

@media (max-width: 520px) {
  .content-shell.counter-board {
    width: calc(100% - 16px);
    padding-top: 34px;
  }

  .counter-board-head {
    padding: 18px 16px 20px;
  }

  .counter-board-head h2 {
    font-size: 56px;
  }

  .counter-machine > .art-frame {
    min-height: 210px;
    padding: 10px 12px 34px;
  }

  .machine-caption {
    gap: 8px;
    font-size: 8px;
  }

  .counter-rail > div {
    min-height: 116px;
    padding: 14px;
  }

  .counter-cell {
    min-height: 145px;
    padding: 15px;
  }

  .counter-cell strong {
    font-size: 31px;
  }
}

/* Full-width product frame and register-key navigation. */
body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

#app {
  flex: 1;
}

.register-bar {
  position: sticky;
  top: 0;
  z-index: 40;
  height: 76px;
  grid-template-columns: 180px minmax(0,1fr) 132px;
  padding: 0 12px;
  background: var(--counter);
}

.brand {
  align-self: stretch;
  gap: 6px;
  padding: 0 12px;
  border-right: 1px solid var(--ink);
}

.brand img {
  width: 52px;
  height: 52px;
  flex: 0 0 52px;
}

.register-bar nav {
  align-self: stretch;
  display: grid;
  grid-template-columns: repeat(8, minmax(74px,1fr));
  gap: 0;
  min-width: 0;
  border-right: 1px solid var(--ink);
}

.register-bar nav a {
  display: grid;
  place-items: center;
  padding: 0 8px;
  border-right: 1px solid var(--ink);
  transition: background-color 150ms ease, color 150ms ease;
}

.register-bar nav a:last-child {
  border-right: 0;
}

.register-bar nav a:hover {
  background: var(--mint);
}

.register-bar nav a[aria-current="page"] {
  color: var(--paper);
  background: var(--ink);
  box-shadow: inset 0 -6px var(--mint);
}

.header-actions {
  align-self: stretch;
  display: grid;
  grid-template-columns: 1fr;
  justify-content: stretch;
  align-items: stretch;
  gap: 0;
  padding-left: 0;
}

.header-actions .key {
  align-self: stretch;
  min-height: 0;
  padding-inline: 18px;
  border: 0;
}

.hero {
  padding-inline: 12px;
}

@media (min-width: 1180px) {
  .receipt-runway {
    width: calc(100vw - 24px);
    max-width: none;
  }

  .outer-readout.left {
    left: 32px;
  }

  .outer-readout.right {
    right: 32px;
  }
}

.content-shell,
.route .content-shell {
  width: calc(100% - 24px);
  max-width: none;
}

.route .content-shell {
  margin-top: 24px;
  padding: 0 0 64px;
}

.route-head {
  padding: 58px 28px 42px;
  border: 2px solid var(--ink);
  background: rgba(247,247,244,.68);
}

.route-head-bottom {
  display: grid;
  grid-template-columns: minmax(320px, 1fr) minmax(480px, .85fr);
  align-items: stretch;
  gap: 36px;
  border-top: 2px solid var(--ink);
  padding-top: 18px;
}

.route-head-bottom > p {
  margin: 0;
}

.route-head-rail {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border: 1px solid var(--ink);
  background: var(--paper);
}

.route-head-rail > div {
  min-width: 0;
  padding: 12px 14px;
  border-right: 1px solid var(--ink);
}

.route-head-rail > div:last-child {
  border-right: 0;
}

.route-head-rail span,
.route-head-rail strong {
  display: block;
  font-family: var(--mono);
  font-size: 9px;
}

.route-head-rail span {
  color: var(--muted);
}

.route-head-rail strong {
  margin-top: 8px;
  font-size: 11px;
  font-weight: 400;
  overflow-wrap: anywhere;
}

.route-head-bottom {
  display: grid;
  grid-template-columns: minmax(300px, 1fr) minmax(480px, .85fr);
  align-items: end;
  gap: 42px;
}

.route-head-bottom > p {
  margin: 0;
}

.route-head-rail {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border: 2px solid var(--ink);
  background: var(--paper);
}

.route-head-rail > div {
  min-width: 0;
  padding: 13px 15px;
  border-right: 1px solid var(--ink);
}

.route-head-rail > div:last-child {
  border-right: 0;
}

.route-head-rail span,
.route-head-rail strong {
  display: block;
  font-family: var(--mono);
  font-size: 10px;
}

.route-head-rail span {
  color: var(--muted);
}

.route-head-rail strong {
  margin-top: 7px;
  font-weight: 400;
  overflow-wrap: anywhere;
}

.workbench {
  gap: 0;
  padding-top: 0;
}

.workbench > .art-frame {
  height: 390px;
  border-top: 0;
}

.workbench > .control-panel,
.workbench > .receipt-ticket,
.workbench > section {
  width: 100%;
  max-width: none;
  margin: 0;
}

.workbench > .control-panel,
.workbench > .receipt-ticket {
  border-top: 0;
}

.workbench > section > .boundary-grid:first-child {
  border-top: 0;
}

.counter-rail > button {
  min-height: 126px;
  padding: 18px;
  border: 0;
  border-right: 1px solid var(--paper);
  color: var(--paper);
  background: var(--ink);
  text-align: left;
  cursor: pointer;
}

.counter-rail > button:last-child {
  border-right: 0;
}

.counter-console .counter-rail > button:nth-child(2n) {
  border-right: 0;
}

.counter-console .counter-rail > button:nth-child(-n+2) {
  border-bottom: 1px solid var(--paper);
}

.counter-rail > button:hover,
.counter-rail > button.active {
  color: var(--ink);
  background: var(--mint);
}

.counter-rail > button b,
.counter-rail > button span,
.counter-rail > button small {
  display: block;
}

.counter-rail > button b {
  font-family: var(--display);
  font-size: 42px;
  font-weight: 300;
  line-height: .8;
  color: var(--mint);
}

.counter-rail > button:hover b,
.counter-rail > button.active b {
  color: var(--ink);
}

.counter-rail > button span {
  margin-top: 12px;
  font-family: var(--mono);
  font-size: 12px;
}

.counter-rail > button small {
  margin-top: 7px;
  color: inherit;
}

.counter-focus {
  display: grid;
  grid-template-columns: 160px 1fr minmax(260px, .8fr) 72px;
  align-items: center;
  gap: 20px;
  min-height: 82px;
  padding: 14px 20px;
  border: 2px solid var(--ink);
  border-top: 0;
  background: var(--counter);
}

.counter-console .counter-focus {
  grid-template-columns: 130px minmax(190px, .9fr) minmax(240px, 1.2fr) 64px;
  border: 0;
  border-top: 2px solid var(--ink);
}

.counter-focus strong {
  font-family: var(--display);
  font-size: 28px;
  font-weight: 300;
  text-transform: uppercase;
}

.counter-focus p {
  margin: 0;
}

.counter-focus > span:last-child {
  font-family: var(--mono);
  text-align: right;
}

.counter-machine img {
  transition: transform 320ms ease;
}

.counter-machine[data-step="1"] img {
  transform: translateX(1.5%);
}

.counter-machine[data-step="2"] img {
  transform: translateX(3%);
}

.counter-machine[data-step="3"] img {
  transform: translateX(4.5%);
}

/* Request composer: one connected desk from input through exact output. */
.request-composer {
  background: var(--paper);
}

.request-entry {
  border: 2px solid var(--ink);
  border-top: 0;
  background: var(--paper);
}

.request-entry-head,
.request-result-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 30px;
  padding: 22px 26px;
  border-bottom: 2px solid var(--ink);
}

.request-entry-head h2,
.request-result-head h2 {
  margin: 8px 0 0;
  font-size: clamp(46px, 5.4vw, 86px);
  line-height: .9;
}

.request-fields {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
}

.request-fields .field {
  min-width: 0;
  margin: 0;
  padding: 17px 18px 19px;
  border-right: 1px solid var(--ink);
  border-bottom: 1px solid var(--ink);
}

.request-fields .field:nth-child(1),
.request-fields .field:nth-child(2) {
  grid-column: span 6;
}

.request-fields .field:nth-child(2),
.request-fields .field:nth-child(5) {
  border-right: 0;
}

.request-fields .field:nth-child(3) {
  grid-column: span 2;
}

.request-fields .field:nth-child(4) {
  grid-column: span 3;
}

.request-fields .field:nth-child(5) {
  grid-column: span 7;
}

.request-fields .field input {
  min-width: 0;
  margin: 0;
  background: var(--paper);
}

.request-build-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 290px;
  min-height: 108px;
}

.request-build-row > .btn {
  min-height: 100%;
  border: 0;
  border-left: 2px solid var(--ink);
}

.request-readiness {
  display: grid;
  grid-template-columns: auto minmax(180px, 1fr);
  align-items: center;
  gap: 9px 22px;
  padding: 16px 20px;
  background: var(--counter);
}

.request-readiness strong {
  display: block;
  margin-top: 4px;
  font-family: var(--display);
  font-size: 33px;
  font-weight: 300;
  line-height: 1;
}

.request-readiness p {
  grid-column: 1 / -1;
  margin: 0;
  font-family: var(--mono);
  font-size: 11px;
}

.request-meter {
  height: 12px;
  border: 1px solid var(--ink);
  background: var(--paper);
}

.request-meter i {
  display: block;
  width: 0;
  height: 100%;
  background: var(--mint);
  transition: width 180ms ease;
}

.request-guide {
  display: grid;
  grid-template-columns: minmax(280px, 1.2fr) repeat(4, 1fr);
  border: 2px solid var(--ink);
  border-top: 0;
  background: var(--paper);
}

.request-anatomy,
.request-guide > div {
  min-width: 0;
  min-height: 188px;
  padding: 18px;
  border-right: 1px solid var(--ink);
}

.request-guide > div:last-child {
  border-right: 0;
}

.request-anatomy {
  display: grid;
  grid-template-rows: 1fr auto;
  gap: 10px;
  background: var(--counter);
}

.request-anatomy img {
  width: 100%;
  height: 124px;
  object-fit: contain;
}

.request-anatomy span,
.request-guide > div > span {
  font-family: var(--mono);
  font-size: 10px;
  text-transform: uppercase;
}

.request-guide > div > b {
  display: block;
  margin-bottom: 18px;
  font-family: var(--display);
  font-size: 44px;
  font-weight: 300;
  line-height: .8;
}

.request-guide > div > p {
  margin: 12px 0 0;
  font-size: 14px;
}

.request-result {
  border: 2px solid var(--ink);
  border-top: 0;
  background: var(--paper);
}

.request-result-head {
  background: var(--mint);
}

.request-ready-stamp {
  padding: 8px 10px;
  border: 2px solid var(--ink);
  font-family: var(--mono);
  font-size: 11px;
}

.request-result-body {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr) 330px;
}

.request-qr-stage {
  padding: 22px;
  border-right: 1px solid var(--ink);
  text-align: center;
}

.request-qr-stage .micro {
  text-align: left;
}

.request-qr-stage .qr-output {
  width: 220px;
  height: 220px;
  margin: 18px auto 12px;
}

.request-qr-stage small {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--muted);
}

.request-receipt-data {
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-width: 0;
}

.request-receipt-data > div {
  min-width: 0;
  padding: 16px 18px;
  border-right: 1px solid var(--ink);
  border-bottom: 1px solid var(--ink);
}

.request-receipt-data > div:nth-child(2n) {
  border-right: 0;
}

.request-receipt-data > div.wide {
  grid-column: 1 / -1;
  border-right: 0;
}

.request-receipt-data > div:last-child {
  border-bottom: 0;
}

.request-receipt-data span,
.request-receipt-data strong {
  display: block;
  font-family: var(--mono);
}

.request-receipt-data span {
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 10px;
}

.request-receipt-data strong {
  font-size: 12px;
  font-weight: 400;
  overflow-wrap: anywhere;
}

.request-next {
  display: flex;
  flex-direction: column;
  padding: 22px;
  border-left: 2px solid var(--ink);
  background: var(--counter);
}

.request-next ol {
  margin: 18px 0;
  padding-left: 20px;
}

.request-next li {
  margin-bottom: 12px;
}

.request-next a {
  margin-top: auto;
  font-family: var(--mono);
  font-size: 11px;
  text-transform: uppercase;
}

.request-uri-row {
  display: grid;
  grid-template-columns: 105px minmax(0, 1fr) 190px;
  align-items: stretch;
  border-top: 2px solid var(--ink);
}

.request-uri-row > span,
.request-uri-row > code {
  padding: 16px;
}

.request-uri-row > code {
  border-left: 1px solid var(--ink);
  font-family: var(--mono);
  font-size: 11px;
  overflow-wrap: anywhere;
}

.request-uri-row > .btn {
  min-height: 100%;
  border: 0;
  border-left: 2px solid var(--ink);
}

.request-boundary {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  color: var(--paper);
  background: var(--ink);
}

.request-boundary span {
  padding: 13px 16px;
  border-right: 1px solid var(--paper);
  font-family: var(--mono);
  font-size: 9px;
  text-align: center;
}

.request-boundary span:last-child {
  border-right: 0;
}

/* Receipt inspector: a dense evidence reader, never a fabricated receipt. */
.receipt-inspector {
  background: var(--paper);
}

.receipt-lookup {
  border: 2px solid var(--ink);
  border-top: 0;
  background: var(--paper);
}

.receipt-lookup-head,
.receipt-verdict {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 30px;
  padding: 22px 26px;
  border-bottom: 2px solid var(--ink);
}

.receipt-lookup-head h2,
.receipt-verdict h2 {
  margin: 8px 0 0;
  font-size: clamp(48px, 5.4vw, 86px);
  line-height: .9;
}

.receipt-source-badge,
.receipt-verdict > strong {
  padding: 8px 10px;
  border: 2px solid var(--ink);
  font-family: var(--mono);
  font-size: 10px;
  white-space: nowrap;
}

.receipt-lookup form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
}

.receipt-lookup form .field {
  min-width: 0;
  margin: 0;
  padding: 18px 20px 20px;
}

.receipt-lookup form input {
  min-width: 0;
  margin: 0;
  background: var(--paper);
  font-family: var(--mono);
}

.receipt-lookup form > .btn {
  min-height: 100%;
  border: 0;
  border-left: 2px solid var(--ink);
}

.receipt-read-rail {
  display: grid;
  grid-template-columns: repeat(3, 1fr) minmax(280px, 1.25fr);
  color: var(--paper);
  background: var(--ink);
}

.receipt-read-rail > div,
.receipt-read-rail > p {
  min-width: 0;
  min-height: 96px;
  margin: 0;
  padding: 16px 18px;
  border-right: 1px solid var(--paper);
  font-family: var(--mono);
}

.receipt-read-rail > div span,
.receipt-read-rail > div strong,
.receipt-read-rail > div small {
  display: block;
}

.receipt-read-rail > div span,
.receipt-read-rail > div small {
  font-size: 9px;
}

.receipt-read-rail > div span {
  color: var(--mint);
}

.receipt-read-rail > div strong {
  margin: 8px 0 4px;
  font-size: 13px;
  font-weight: 400;
}

.receipt-read-rail > div small {
  color: #c9d2ce;
}

.receipt-read-rail > p {
  display: grid;
  place-items: center start;
  border-right: 0;
  color: var(--ink);
  background: var(--mint);
  font-size: 12px;
}

.receipt-plan {
  display: grid;
  grid-template-columns: minmax(270px, .8fr) minmax(0, 1.8fr) minmax(280px, .8fr);
  border: 2px solid var(--ink);
  border-top: 0;
  background: var(--paper);
}

.receipt-plan-art {
  display: grid;
  grid-template-rows: 1fr auto;
  gap: 12px;
  min-height: 294px;
  padding: 20px;
  border-right: 1px solid var(--ink);
  background: var(--counter);
}

.receipt-plan-art img {
  width: 100%;
  height: 220px;
  object-fit: contain;
}

.receipt-plan-art span {
  font-family: var(--mono);
  font-size: 9px;
}

.receipt-plan-fields {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  min-width: 0;
}

.receipt-plan-fields > div {
  min-width: 0;
  padding: 20px;
  border-right: 1px solid var(--ink);
  border-bottom: 1px solid var(--ink);
}

.receipt-plan-fields > div:nth-child(3n) {
  border-right: 0;
}

.receipt-plan-fields > div:nth-last-child(-n+3) {
  border-bottom: 0;
}

.receipt-plan-fields span,
.receipt-plan-fields strong,
.receipt-plan-fields small {
  display: block;
}

.receipt-plan-fields span,
.receipt-plan-fields small {
  font-family: var(--mono);
  font-size: 9px;
}

.receipt-plan-fields span,
.receipt-plan-fields small {
  color: var(--muted);
}

.receipt-plan-fields strong {
  margin: 10px 0 6px;
  font-family: var(--display);
  font-size: 27px;
  font-weight: 300;
  line-height: 1;
}

.receipt-policy {
  padding: 20px;
  border-left: 2px solid var(--ink);
}

.receipt-policy > div {
  display: grid;
  grid-template-columns: 54px 1fr;
  align-items: center;
  gap: 14px;
  padding: 16px 0;
  border-bottom: 1px solid var(--ink);
}

.receipt-policy > div > b {
  font-family: var(--display);
  font-size: 48px;
  font-weight: 300;
  line-height: .8;
}

.receipt-policy > div p,
.receipt-policy > p {
  margin: 0;
}

.receipt-policy > div strong,
.receipt-policy > div small {
  display: block;
  font-family: var(--mono);
  font-size: 10px;
}

.receipt-policy > p {
  padding-top: 16px;
  font-size: 12px;
}

.receipt-result {
  border: 2px solid var(--ink);
  border-top: 0;
  background: var(--paper);
}

.receipt-verdict {
  background: var(--mint);
}

.receipt-summary {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
}

.receipt-summary > div {
  min-width: 0;
  min-height: 132px;
  padding: 18px 20px;
  border-right: 1px solid var(--ink);
  border-bottom: 2px solid var(--ink);
}

.receipt-summary > div:last-child {
  border-right: 0;
}

.receipt-summary span,
.receipt-summary strong {
  display: block;
  font-family: var(--mono);
}

.receipt-summary span {
  color: var(--muted);
  font-size: 10px;
}

.receipt-summary strong {
  margin-top: 13px;
  font-family: var(--display);
  font-size: clamp(32px, 3.2vw, 52px);
  font-weight: 300;
  line-height: 1;
  overflow-wrap: anywhere;
}

.receipt-events-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 16px 20px;
  border-bottom: 1px solid var(--ink);
}

.receipt-events-head p {
  margin: 0;
  font-size: 12px;
}

.receipt-transfer-list {
  background: var(--paper);
}

.receipt-event {
  display: grid;
  grid-template-columns: 130px repeat(4, minmax(0, 1fr));
  border-bottom: 1px solid var(--ink);
}

.receipt-event > header,
.receipt-event > div {
  min-width: 0;
  padding: 15px 16px;
  border-right: 1px solid var(--ink);
}

.receipt-event > header {
  color: var(--paper);
  background: var(--ink);
}

.receipt-event > *:last-child {
  border-right: 0;
}

.receipt-event span,
.receipt-event strong {
  display: block;
  font-family: var(--mono);
  font-size: 10px;
}

.receipt-event strong {
  margin-top: 8px;
  font-weight: 400;
  overflow-wrap: anywhere;
}

.receipt-event-empty {
  margin: 0;
  padding: 34px 20px;
  border-bottom: 1px solid var(--ink);
  font-family: var(--mono);
  font-size: 12px;
}

.receipt-provenance {
  display: grid;
  grid-template-columns: 1fr 1fr 2fr;
  background: var(--counter);
}

.receipt-provenance > div {
  min-width: 0;
  padding: 16px 18px;
  border-right: 1px solid var(--ink);
}

.receipt-provenance > div:last-child {
  border-right: 0;
}

.receipt-provenance span,
.receipt-provenance strong {
  display: block;
  font-family: var(--mono);
  font-size: 10px;
}

.receipt-provenance span {
  margin-bottom: 7px;
  color: var(--muted);
}

.receipt-provenance strong {
  font-weight: 400;
  overflow-wrap: anywhere;
}

.receipt-actions {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border: 2px solid var(--ink);
  border-top: 0;
}

.receipt-actions a {
  display: flex;
  flex-direction: column;
  min-height: 148px;
  padding: 18px 20px;
  border-right: 1px solid var(--ink);
  text-decoration: none;
}

.receipt-actions a:last-child {
  border-right: 0;
}

.receipt-actions a:hover {
  background: var(--mint);
}

.receipt-actions span,
.receipt-actions b {
  font-family: var(--mono);
  font-size: 9px;
}

.receipt-actions span {
  color: var(--muted);
}

.receipt-actions strong {
  margin-top: 12px;
  font-family: var(--display);
  font-size: 30px;
  font-weight: 300;
}

.receipt-actions b {
  margin-top: auto;
  font-weight: 400;
}

.receipt-inspector[data-state="reading"] #receipt-rpc-state,
.receipt-inspector[data-state="found"] #receipt-rpc-state,
.receipt-inspector[data-state="found"] #receipt-log-state {
  color: var(--mint);
}

/* Sales ledger: grouped views with evidence retained on every future row. */
.sales-console {
  background: var(--paper);
}

.sales-command {
  border: 2px solid var(--ink);
  border-top: 0;
}

.sales-command > header,
.sales-ledger-table > header {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 30px;
  padding: 22px 26px;
  border-bottom: 2px solid var(--ink);
}

.sales-command h2,
.sales-ledger-table h3,
.sales-evidence h3 {
  margin: 8px 0 0;
  font-family: var(--display);
  font-size: clamp(46px, 5.2vw, 84px);
  font-weight: 300;
  line-height: .9;
}

.sales-group-controls {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  color: var(--paper);
  background: var(--ink);
}

.sales-group-controls button {
  min-height: 142px;
  padding: 18px 20px;
  border: 0;
  border-right: 1px solid var(--paper);
  color: inherit;
  background: transparent;
  text-align: left;
  cursor: pointer;
}

.sales-group-controls button:last-child {
  border-right: 0;
}

.sales-group-controls button:hover,
.sales-group-controls button.active {
  color: var(--ink);
  background: var(--mint);
}

.sales-group-controls b,
.sales-group-controls span,
.sales-group-controls small {
  display: block;
}

.sales-group-controls b {
  font-family: var(--display);
  font-size: 45px;
  font-weight: 300;
  line-height: .8;
}

.sales-group-controls span,
.sales-group-controls small {
  font-family: var(--mono);
}

.sales-group-controls span {
  margin-top: 13px;
  font-size: 11px;
}

.sales-group-controls small {
  margin-top: 6px;
  font-size: 9px;
}

.sales-focus {
  display: grid;
  grid-template-columns: 170px minmax(260px, .9fr) minmax(300px, 1.2fr) 70px;
  align-items: center;
  gap: 20px;
  min-height: 92px;
  padding: 14px 20px;
  border-top: 2px solid var(--ink);
  background: var(--counter);
}

.sales-focus strong {
  font-family: var(--display);
  font-size: 30px;
  font-weight: 300;
}

.sales-focus p {
  margin: 0;
}

.sales-focus > span:last-child {
  font-family: var(--mono);
  font-size: 11px;
  text-align: right;
}

.sales-summary {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border: 2px solid var(--ink);
  border-top: 0;
}

.sales-summary > div {
  min-width: 0;
  min-height: 148px;
  padding: 18px 20px;
  border-right: 1px solid var(--ink);
}

.sales-summary > div:last-child {
  border-right: 0;
}

.sales-summary > div.signal {
  background: var(--mint);
}

.sales-summary span,
.sales-summary strong,
.sales-summary small {
  display: block;
}

.sales-summary span,
.sales-summary small {
  font-family: var(--mono);
  font-size: 9px;
}

.sales-summary span,
.sales-summary small {
  color: var(--muted);
}

.sales-summary strong {
  margin: 12px 0 7px;
  font-family: var(--display);
  font-size: clamp(34px, 3.3vw, 54px);
  font-weight: 300;
  line-height: 1;
}

.sales-ledger-table {
  border: 2px solid var(--ink);
  border-top: 0;
}

.sales-ledger-table > header {
  align-items: end;
}

.sales-ledger-table > header p {
  max-width: 410px;
  margin: 0;
  font-family: var(--mono);
  font-size: 11px;
  text-align: right;
  text-transform: uppercase;
}

.sales-ledger-labels {
  display: grid;
  grid-template-columns: .75fr 1.2fr 1fr 1fr .75fr .9fr;
  color: var(--paper);
  background: var(--ink);
}

.sales-ledger-labels span {
  padding: 11px 14px;
  border-right: 1px solid var(--paper);
  font-family: var(--mono);
  font-size: 9px;
}

.sales-ledger-labels span:last-child {
  border-right: 0;
}

.sales-ledger-labels span:first-child {
  color: var(--ink);
  background: var(--mint);
}

.sales-ledger-empty {
  display: grid;
  grid-template-columns: minmax(260px, .7fr) minmax(0, 1.8fr);
  min-height: 300px;
}

.sales-ledger-empty img {
  width: 100%;
  height: 300px;
  padding: 34px;
  border-right: 1px solid var(--ink);
  object-fit: contain;
  background: var(--counter);
}

.sales-ledger-empty > div {
  display: flex;
  flex-direction: column;
  align-items: start;
  justify-content: center;
  padding: 34px;
}

.sales-ledger-empty strong {
  display: block;
  margin-top: 13px;
  font-family: var(--display);
  font-size: clamp(38px, 4.2vw, 68px);
  font-weight: 300;
  line-height: 1;
}

.sales-ledger-empty p {
  max-width: 650px;
  margin: 15px 0 24px;
}

.sales-ledger-empty a {
  font-family: var(--mono);
  font-size: 11px;
  text-transform: uppercase;
}

.sales-ledger-table > footer {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-top: 2px solid var(--ink);
  color: var(--paper);
  background: var(--ink);
}

.sales-ledger-table > footer span {
  padding: 12px 16px;
  border-right: 1px solid var(--paper);
  font-family: var(--mono);
  font-size: 9px;
  text-align: center;
}

.sales-ledger-table > footer span:last-child {
  border-right: 0;
}

.sales-evidence {
  display: grid;
  grid-template-columns: minmax(300px, 1.4fr) repeat(3, 1fr);
  border: 2px solid var(--ink);
  border-top: 0;
}

.sales-evidence > header {
  grid-row: span 2;
  padding: 24px;
  color: var(--paper);
  background: var(--ink);
}

.sales-evidence h3 {
  font-size: clamp(42px, 4.5vw, 70px);
}

.sales-evidence > div {
  min-height: 156px;
  padding: 18px;
  border-right: 1px solid var(--ink);
  border-bottom: 1px solid var(--ink);
}

.sales-evidence > div:nth-child(4),
.sales-evidence > div:nth-child(7) {
  border-right: 0;
}

.sales-evidence > div:nth-last-child(-n+3) {
  border-bottom: 0;
}

.sales-evidence b,
.sales-evidence span {
  display: block;
}

.sales-evidence b {
  font-family: var(--display);
  font-size: 40px;
  font-weight: 300;
  line-height: .8;
}

.sales-evidence span {
  margin-top: 15px;
  font-family: var(--mono);
  font-size: 10px;
}

.sales-evidence p {
  margin: 9px 0 0;
  font-size: 13px;
}

.sales-actions {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border: 2px solid var(--ink);
  border-top: 0;
}

.sales-actions a {
  display: flex;
  flex-direction: column;
  min-height: 142px;
  padding: 18px 20px;
  border-right: 1px solid var(--ink);
  text-decoration: none;
}

.sales-actions a:last-child {
  border-right: 0;
}

.sales-actions a:hover {
  background: var(--mint);
}

.sales-actions span,
.sales-actions b {
  font-family: var(--mono);
  font-size: 9px;
}

.sales-actions span {
  color: var(--muted);
}

.sales-actions strong {
  margin-top: 10px;
  font-family: var(--display);
  font-size: 30px;
  font-weight: 300;
}

.sales-actions b {
  margin-top: auto;
  font-weight: 400;
}

/* Setup, Convert, Rules and FAQ use distinct full-width work surfaces. */
.setup-entry,.convert-entry,.rules-gates,.rules-matrix,.rules-launch,.faq-intro,.faq-list{border:2px solid var(--ink);border-top:0;background:var(--paper)}
.setup-entry>header,.convert-entry>header,.setup-review>header,.convert-result>header,.rules-gates>header,.rules-matrix>header,.rules-launch>header,.faq-intro{display:flex;align-items:start;justify-content:space-between;gap:30px;padding:22px 26px;border-bottom:2px solid var(--ink)}
.setup-entry h2,.convert-entry h2,.setup-review h2,.convert-result h2,.rules-gates h2,.rules-matrix h3,.rules-launch h3,.faq-intro h2{margin:8px 0 0;font-family:var(--display);font-size:clamp(46px,5.2vw,84px);font-weight:300;line-height:.9}
.setup-fields{display:grid;grid-template-columns:repeat(12,minmax(0,1fr))}
.setup-fields .field{grid-column:span 4;min-width:0;margin:0;padding:17px 18px 19px;border-right:1px solid var(--ink);border-bottom:1px solid var(--ink)}
.setup-fields .field:nth-child(3){border-right:0}.setup-fields .field:nth-child(4),.setup-fields .field:nth-child(5){grid-column:span 6}.setup-fields .field:nth-child(5){border-right:0}
.setup-fields input,.setup-fields textarea{margin:0;background:var(--paper)}.setup-fields textarea{width:100%;min-height:118px;border:2px solid var(--ink);padding:13px 14px;resize:vertical}
.setup-submit{display:grid;grid-template-columns:1fr 310px;min-height:116px}.setup-submit>div{display:grid;grid-template-columns:auto minmax(180px,1fr);align-items:center;gap:8px 22px;padding:16px 20px;background:var(--counter)}
.setup-submit strong{font-family:var(--display);font-size:34px;font-weight:300}.setup-submit p{grid-column:1/-1;margin:0;font-family:var(--mono);font-size:11px}.setup-submit>.btn{min-height:100%;border:0;border-left:2px solid var(--ink)}
.setup-meter{height:12px;border:1px solid var(--ink);background:var(--paper)}.setup-meter i{display:block;width:0;height:100%;background:var(--mint);transition:width 180ms ease}
.setup-wiring,.convert-plan{display:grid;grid-template-columns:minmax(280px,1.2fr) repeat(4,1fr);border:2px solid var(--ink);border-top:0;background:var(--paper)}
.setup-wiring>div,.convert-plan>div{min-width:0;min-height:190px;padding:18px;border-right:1px solid var(--ink)}.setup-wiring>div:last-child,.convert-plan>div:last-child{border-right:0}
.setup-wiring-art,.convert-plan-art{display:grid;grid-template-rows:1fr auto;gap:10px;background:var(--counter)}.setup-wiring-art img,.convert-plan-art img{width:100%;height:128px;object-fit:contain}.setup-wiring span,.convert-plan span{font-family:var(--mono);font-size:10px}.setup-wiring b,.convert-plan b{display:block;margin-bottom:18px;font-family:var(--display);font-size:44px;font-weight:300;line-height:.8}.setup-wiring p,.convert-plan p{margin:12px 0 0;font-size:14px}
.setup-review,.convert-result{border:2px solid var(--ink);border-top:0;background:var(--paper)}.setup-review>header,.convert-result>header{background:var(--mint)}.setup-review>header>span,.convert-result>header>span,.convert-quote{padding:8px 10px;border:2px solid var(--ink);font-family:var(--mono);font-size:10px}
.setup-review-body{display:grid;grid-template-columns:1.45fr 1fr}.setup-review-body pre{min-width:0;margin:0;padding:24px;border-right:2px solid var(--ink);font-family:var(--mono);font-size:12px;white-space:pre-wrap;overflow-wrap:anywhere}.setup-review-body aside{display:grid;grid-template-columns:1fr 1fr}.setup-review-body aside>div,.setup-review-body aside>p{min-width:0;margin:0;padding:16px;border-right:1px solid var(--ink);border-bottom:1px solid var(--ink)}.setup-review-body aside>div:nth-child(2n){border-right:0}.setup-review-body aside>p{grid-column:1/-1;border:0;font-size:12px}.setup-review-body span,.setup-review-body strong{display:block;font-family:var(--mono);font-size:10px}.setup-review-body span{color:var(--muted)}.setup-review-body strong{margin-top:7px;font-weight:400;overflow-wrap:anywhere}
.setup-boundary,.convert-boundary{display:grid;color:var(--paper);background:var(--ink)}.setup-boundary{grid-template-columns:repeat(4,1fr)}.convert-boundary{grid-template-columns:repeat(5,1fr)}.setup-boundary span,.convert-boundary span{padding:12px;border-right:1px solid var(--paper);font-family:var(--mono);font-size:9px;text-align:center}.setup-boundary span:last-child,.convert-boundary span:last-child{border-right:0}
.convert-entry form{display:grid;grid-template-columns:1fr 310px}.convert-entry form .field{min-width:0;margin:0;padding:18px 20px}.convert-entry form input{margin:0;background:var(--paper);font-family:var(--mono)}.convert-entry form>.btn{min-height:100%;border:0;border-left:2px solid var(--ink)}
.convert-read-rail{display:grid;grid-template-columns:repeat(3,1fr) minmax(320px,1.25fr);color:var(--paper);background:var(--ink)}.convert-read-rail>div,.convert-read-rail>p{min-height:94px;margin:0;padding:16px 18px;border-right:1px solid var(--paper);font-family:var(--mono)}.convert-read-rail>p{display:grid;place-items:center start;border:0;color:var(--ink);background:var(--mint)}.convert-read-rail span,.convert-read-rail strong,.convert-read-rail small{display:block;font-size:9px}.convert-read-rail span{color:var(--mint)}.convert-read-rail strong{margin:8px 0 4px;font-size:12px;font-weight:400}.convert-summary{display:grid;grid-template-columns:repeat(4,1fr)}.convert-summary>div{min-width:0;min-height:135px;padding:18px 20px;border-right:1px solid var(--ink);border-bottom:2px solid var(--ink)}.convert-summary>div:last-child{border-right:0}.convert-summary span,.convert-summary strong,.convert-details span,.convert-details strong{display:block}.convert-summary span,.convert-details span{font-family:var(--mono);font-size:9px;color:var(--muted)}.convert-summary strong{margin-top:12px;font-family:var(--display);font-size:clamp(32px,3vw,50px);font-weight:300;overflow-wrap:anywhere}.convert-details{display:grid;grid-template-columns:1fr 1fr}.convert-details>div{min-width:0;padding:17px 20px;border-right:1px solid var(--ink);border-bottom:1px solid var(--ink)}.convert-details>div:nth-child(2n){border-right:0}.convert-details strong{margin-top:8px;font-family:var(--mono);font-size:11px;font-weight:400;overflow-wrap:anywhere}
.rules-gates{display:grid;grid-template-columns:repeat(4,1fr)}.rules-gates>header{grid-column:1/-1;align-items:center}.rules-gates>header img{width:260px;height:120px;object-fit:contain}.rules-gates>div{min-height:230px;padding:22px;border-right:1px solid var(--ink)}.rules-gates>div:last-child{border-right:0}.rules-gates b{display:block;font-family:var(--display);font-size:54px;font-weight:300;line-height:.8}.rules-gates span{display:block;margin-top:22px;font-family:var(--mono);font-size:11px}.rules-gates p{margin:13px 0 0}
.rules-matrix>header,.rules-launch>header{display:block}.rules-matrix-row{display:grid;grid-template-columns:.7fr 1.2fr 1.3fr 1.2fr;border-bottom:1px solid var(--ink)}.rules-matrix-row:last-child{border-bottom:0}.rules-matrix-row span{padding:15px 18px;border-right:1px solid var(--ink);font-family:var(--mono);font-size:11px}.rules-matrix-row span:last-child{border-right:0}.rules-matrix-row.labels{color:var(--paper);background:var(--ink)}
.rules-launch{display:grid;grid-template-columns:1.2fr repeat(3,1fr) 1.4fr}.rules-launch>header{grid-column:1/-1}.rules-launch>div,.rules-launch>aside{min-width:0;min-height:150px;padding:20px;border-right:1px solid var(--ink)}.rules-launch>aside{border:0;display:flex;flex-direction:column;gap:10px;font-family:var(--mono);font-size:11px}.rules-launch span,.rules-launch strong,.rules-launch small{display:block}.rules-launch span,.rules-launch small{font-family:var(--mono);font-size:9px}.rules-launch strong{margin:12px 0 7px;font-family:var(--display);font-size:34px;font-weight:300}
.faq-intro{align-items:end}.faq-intro>p{max-width:520px;margin:0}.faq-list{display:grid;grid-template-columns:1fr 1fr}.faq-list details{border-right:1px solid var(--ink);border-bottom:1px solid var(--ink)}.faq-list details:nth-child(2n){border-right:0}.faq-list summary{display:grid;grid-template-columns:42px 1fr 24px;align-items:center;gap:12px;min-height:82px;padding:14px 18px;cursor:pointer;list-style:none}.faq-list summary::-webkit-details-marker{display:none}.faq-list summary span,.faq-list summary i{font-family:var(--mono);font-size:11px}.faq-list summary i{font-size:20px;font-style:normal;text-align:right}.faq-list details[open] summary{background:var(--mint)}.faq-list details[open] summary i{transform:rotate(45deg)}.faq-list details>p{margin:0;padding:18px 24px 24px 72px;border-top:1px solid var(--ink)}
.faq-actions{display:grid;grid-template-columns:repeat(3,1fr);border:2px solid var(--ink);border-top:0}.faq-actions a{min-height:120px;padding:18px 20px;border-right:1px solid var(--ink);text-decoration:none}.faq-actions a:last-child{border:0}.faq-actions span,.faq-actions strong{display:block}.faq-actions span{font-family:var(--mono);font-size:9px;color:var(--muted)}.faq-actions strong{margin-top:12px;font-family:var(--display);font-size:30px;font-weight:300}.faq-actions a:hover{background:var(--mint)}

/* The final receipt is a separate closing zone. */
.site-footer {
  width: 100%;
  margin-top: 72px;
  padding: 34px 12px 38px;
  border-top: 6px solid var(--mint);
  background: var(--ink);
}

.footer-receipt {
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 20px 22px 18px;
}

.footer-statement {
  width: 100%;
  max-width: none;
  font-size: clamp(46px,6.4vw,104px);
}

.footer-head {
  padding-bottom: 12px;
}

.footer-grid > div {
  padding: 13px 16px;
  gap: 4px;
}

.footer-grid small {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--muted);
}

.footer-socials {
  display: grid;
  grid-template-columns: 1fr 1.45fr;
  gap: 6px;
  margin-top: 9px;
}

.footer-socials > span {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 30px;
  padding: 0 9px;
  border: 1px solid var(--ink);
  font-family: var(--mono);
}

.footer-socials b {
  font-size: 9px;
  font-weight: 400;
}

.footer-socials i {
  color: var(--muted);
  font-size: 7px;
  font-style: normal;
}

.footer-sources p {
  display: flex;
  gap: 18px;
  margin: 0;
  font-family: var(--mono);
  font-size: 11px;
}

.tear-row {
  padding-top: 14px;
}

@media (max-width: 1100px) {
  .register-bar {
    grid-template-columns: 160px minmax(0,1fr);
    height: auto;
    padding: 0;
  }

  .header-actions {
    padding-right: 12px;
  }

  .register-bar nav {
    grid-column: 1 / -1;
    grid-row: 2;
    overflow-x: auto;
    min-height: 48px;
    border-top: 1px solid var(--ink);
    border-right: 0;
  }

  .counter-console {
    grid-template-columns: 1fr;
  }

  .counter-machine {
    border-right: 0;
    border-bottom: 2px solid var(--ink);
  }

  .counter-machine > .art-frame {
    height: 250px;
  }

  .counter-inspector {
    grid-template-columns: 160px minmax(0, 1fr);
  }

  .counter-payoff {
    grid-column: 1 / -1;
    min-height: 150px;
    border-top: 2px solid var(--ink);
    border-left: 0;
  }

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

  .request-anatomy {
    grid-column: 1 / -1;
    min-height: 210px;
  }

  .request-guide > div:nth-child(3),
  .request-guide > div:nth-child(5) {
    border-right: 0;
  }

  .request-guide > div:nth-child(-n+3) {
    border-bottom: 1px solid var(--ink);
  }

  .request-result-body {
    grid-template-columns: 260px minmax(0, 1fr);
  }

  .request-next {
    grid-column: 1 / -1;
    min-height: 190px;
    border-top: 2px solid var(--ink);
    border-left: 0;
  }

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

  .receipt-read-rail > div:nth-child(2) {
    border-right: 0;
  }

  .receipt-read-rail > div:nth-child(-n+2) {
    border-bottom: 1px solid var(--paper);
  }

  .receipt-read-rail > p {
    grid-column: 2;
  }

  .receipt-plan {
    grid-template-columns: 260px minmax(0, 1fr);
  }

  .receipt-policy {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: 150px 1fr 1fr minmax(260px, 1.4fr);
    align-items: center;
    border-top: 2px solid var(--ink);
    border-left: 0;
  }

  .receipt-policy > div {
    border-right: 1px solid var(--ink);
    border-bottom: 0;
    padding: 12px 16px;
  }

  .receipt-policy > p {
    padding: 12px 16px;
  }

  .receipt-event {
    grid-template-columns: 110px repeat(2, 1fr);
  }

  .receipt-event > header {
    grid-row: span 2;
  }

  .receipt-event > div:nth-child(3) {
    border-right: 0;
  }

  .receipt-event > div:nth-child(-n+3) {
    border-bottom: 1px solid var(--ink);
  }

  .sales-focus {
    grid-template-columns: 145px 1fr 1.3fr 60px;
  }

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

  .sales-summary > div:nth-child(2n) {
    border-right: 0;
  }

  .sales-summary > div:nth-child(-n+2) {
    border-bottom: 1px solid var(--ink);
  }

  .sales-evidence {
    grid-template-columns: repeat(3, 1fr);
  }

  .sales-evidence > header {
    grid-column: 1 / -1;
    grid-row: auto;
  }
}

@media (max-width: 719px) {
  .register-bar {
    grid-template-columns: 1fr auto;
  }

  .header-actions {
    grid-template-columns: 1fr;
  }

  .brand {
    padding-left: 12px;
    border-right: 0;
  }

  .register-bar nav {
    display: flex;
    gap: 0;
    padding: 0;
  }

  .register-bar nav a {
    min-width: 92px;
    min-height: 46px;
  }

  .route .content-shell,
  .content-shell {
    width: calc(100% - 16px);
  }

  .route .content-shell {
    margin-top: 8px;
  }

  .route-head {
    padding: 38px 16px 30px;
  }

  .workbench > .art-frame {
    height: 270px;
  }

  .counter-rail > button {
    min-height: 116px;
    padding: 14px;
  }

  .counter-rail > button:nth-child(2) {
    border-right: 0;
  }

  .counter-rail > button:nth-child(-n+2) {
    border-bottom: 1px solid var(--paper);
  }

  .counter-focus {
    grid-template-columns: 1fr auto;
    gap: 8px 14px;
  }

  .counter-focus strong,
  .counter-focus p {
    grid-column: 1 / -1;
  }

  .counter-machine > .art-frame {
    height: 205px;
    padding: 18px 16px 44px;
  }

  .counter-console .counter-focus {
    grid-template-columns: 1fr auto;
  }

  .counter-inspector {
    grid-template-columns: 1fr;
  }

  .counter-inspector-head {
    display: grid;
    grid-template-columns: auto 1fr;
    align-items: end;
    gap: 8px 18px;
    padding: 18px;
  }

  .counter-inspector-head .micro {
    grid-column: 1 / -1;
  }

  .counter-inspector-head strong {
    margin-top: 6px;
    font-size: 56px;
  }

  .counter-inspector-head p {
    margin: 0 0 2px;
  }

  .counter-checks {
    grid-template-columns: 1fr;
  }

  .counter-check {
    border-right: 0;
    border-bottom: 1px solid var(--ink);
  }

  .counter-check:nth-last-child(-n+2) {
    border-bottom: 1px solid var(--ink);
  }

  .counter-check:last-child {
    border-bottom: 0;
  }

  .counter-payoff {
    min-height: 170px;
  }

  .counter-ledger-head {
    display: block;
    padding: 18px 16px;
  }

  .counter-ledger-head h3 {
    font-size: 48px;
  }

  .counter-ledger-head p {
    margin-top: 14px;
    text-align: left;
  }

  .counter-ledger-labels {
    display: none;
  }

  .counter-ledger-row {
    grid-template-columns: 1fr 1fr;
  }

  .counter-ledger-row > span {
    min-height: 76px;
    padding: 28px 12px 12px;
    position: relative;
  }

  .counter-ledger-row > span::before {
    content: attr(data-label);
    position: absolute;
    top: 9px;
    left: 12px;
    color: var(--muted);
    font-size: 8px;
    text-transform: uppercase;
  }

  .counter-ledger-row > span:nth-child(2n) {
    border-right: 0;
  }

  .counter-ledger-row > span:nth-child(-n+2) {
    border-bottom: 1px solid var(--ink);
  }

  .counter-outcomes {
    grid-template-columns: 1fr;
  }

  .counter-outcomes a {
    min-height: 154px;
    border-right: 0;
    border-bottom: 1px solid var(--ink);
  }

  .counter-outcomes a:last-child {
    border-bottom: 0;
  }

  .counter-outcomes strong {
    font-size: 31px;
  }

  .request-entry-head,
  .request-result-head {
    display: block;
    padding: 18px 16px;
  }

  .request-entry-head h2,
  .request-result-head h2 {
    font-size: 48px;
  }

  .request-entry-head .phase,
  .request-ready-stamp {
    display: inline-block;
    margin-top: 16px;
  }

  .request-fields {
    grid-template-columns: 1fr;
  }

  .request-fields .field:nth-child(n) {
    grid-column: auto;
    border-right: 0;
  }

  .request-build-row {
    grid-template-columns: 1fr;
  }

  .request-readiness {
    grid-template-columns: auto 1fr;
  }

  .request-build-row > .btn {
    min-height: 62px;
    border-top: 2px solid var(--ink);
    border-left: 0;
  }

  .request-guide {
    grid-template-columns: 1fr;
  }

  .request-guide > div,
  .request-anatomy {
    grid-column: auto;
    min-height: 154px;
    border-right: 0;
    border-bottom: 1px solid var(--ink);
  }

  .request-guide > div:last-child {
    border-bottom: 0;
  }

  .request-result-body {
    grid-template-columns: 1fr;
  }

  .request-qr-stage {
    border-right: 0;
    border-bottom: 2px solid var(--ink);
  }

  .request-receipt-data {
    grid-template-columns: 1fr;
  }

  .request-receipt-data > div,
  .request-receipt-data > div.wide {
    grid-column: auto;
    border-right: 0;
  }

  .request-next {
    grid-column: auto;
  }

  .request-uri-row {
    grid-template-columns: 1fr;
  }

  .request-uri-row > code {
    border-top: 1px solid var(--ink);
    border-left: 0;
  }

  .request-uri-row > .btn {
    min-height: 58px;
    border-top: 2px solid var(--ink);
    border-left: 0;
  }

  .request-boundary {
    grid-template-columns: 1fr;
  }

  .request-boundary span {
    border-right: 0;
    border-bottom: 1px solid var(--paper);
  }

  .request-boundary span:last-child {
    border-bottom: 0;
  }

  .receipt-lookup-head,
  .receipt-verdict {
    display: block;
    padding: 18px 16px;
  }

  .receipt-lookup-head h2,
  .receipt-verdict h2 {
    font-size: 48px;
  }

  .receipt-source-badge,
  .receipt-verdict > strong {
    display: inline-block;
    margin-top: 16px;
  }

  .receipt-lookup form {
    grid-template-columns: 1fr;
  }

  .receipt-lookup form > .btn {
    min-height: 62px;
    border-top: 2px solid var(--ink);
    border-left: 0;
  }

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

  .receipt-read-rail > div,
  .receipt-read-rail > p {
    grid-column: auto;
    min-height: 88px;
    border-right: 0;
    border-bottom: 1px solid var(--paper);
  }

  .receipt-read-rail > p {
    min-height: 78px;
    border-bottom: 0;
  }

  .receipt-plan {
    grid-template-columns: 1fr;
  }

  .receipt-plan-art {
    min-height: 210px;
    border-right: 0;
    border-bottom: 2px solid var(--ink);
  }

  .receipt-plan-art img {
    height: 155px;
  }

  .receipt-plan-fields {
    grid-template-columns: 1fr 1fr;
  }

  .receipt-plan-fields > div:nth-child(n) {
    border-right: 1px solid var(--ink);
    border-bottom: 1px solid var(--ink);
  }

  .receipt-plan-fields > div:nth-child(2n) {
    border-right: 0;
  }

  .receipt-plan-fields > div:nth-last-child(-n+2) {
    border-bottom: 0;
  }

  .receipt-policy {
    grid-column: auto;
    display: block;
    border-top: 2px solid var(--ink);
  }

  .receipt-policy > div {
    border-right: 0;
    border-bottom: 1px solid var(--ink);
  }

  .receipt-summary {
    grid-template-columns: 1fr 1fr;
  }

  .receipt-summary > div:nth-child(2n) {
    border-right: 0;
  }

  .receipt-summary > div:nth-child(-n+2) {
    border-bottom-width: 1px;
  }

  .receipt-events-head {
    display: block;
  }

  .receipt-events-head p {
    margin-top: 8px;
  }

  .receipt-event {
    grid-template-columns: 1fr;
  }

  .receipt-event > header {
    grid-row: auto;
  }

  .receipt-event > header,
  .receipt-event > div {
    border-right: 0;
    border-bottom: 1px solid var(--ink);
  }

  .receipt-provenance,
  .receipt-actions {
    grid-template-columns: 1fr;
  }

  .receipt-provenance > div,
  .receipt-actions a {
    border-right: 0;
    border-bottom: 1px solid var(--ink);
  }

  .receipt-provenance > div:last-child,
  .receipt-actions a:last-child {
    border-bottom: 0;
  }

  .sales-command > header,
  .sales-ledger-table > header {
    display: block;
    padding: 18px 16px;
  }

  .sales-command h2,
  .sales-ledger-table h3 {
    font-size: 48px;
  }

  .sales-command .phase {
    display: inline-block;
    margin-top: 16px;
  }

  .sales-group-controls {
    grid-template-columns: 1fr;
  }

  .sales-group-controls button {
    min-height: 118px;
    border-right: 0;
    border-bottom: 1px solid var(--paper);
  }

  .sales-group-controls button:last-child {
    border-bottom: 0;
  }

  .sales-focus {
    grid-template-columns: 1fr auto;
    gap: 8px 14px;
  }

  .sales-focus strong,
  .sales-focus p {
    grid-column: 1 / -1;
  }

  .sales-summary {
    grid-template-columns: 1fr 1fr;
  }

  .sales-summary > div {
    min-height: 132px;
    padding: 15px;
  }

  .sales-summary strong {
    font-size: 32px;
  }

  .sales-ledger-table > header p {
    margin-top: 14px;
    text-align: left;
  }

  .sales-ledger-labels {
    display: none;
  }

  .sales-ledger-empty {
    grid-template-columns: 1fr;
  }

  .sales-ledger-empty img {
    height: 210px;
    padding: 24px;
    border-right: 0;
    border-bottom: 1px solid var(--ink);
  }

  .sales-ledger-empty > div {
    padding: 24px 18px;
  }

  .sales-ledger-table > footer {
    grid-template-columns: 1fr;
  }

  .sales-ledger-table > footer span {
    border-right: 0;
    border-bottom: 1px solid var(--paper);
  }

  .sales-ledger-table > footer span:last-child {
    border-bottom: 0;
  }

  .sales-evidence {
    grid-template-columns: 1fr 1fr;
  }

  .sales-evidence > header {
    grid-column: 1 / -1;
  }

  .sales-evidence h3 {
    font-size: 46px;
  }

  .sales-evidence > div {
    min-height: 144px;
  }

  .sales-evidence > div:nth-child(n) {
    border-right: 1px solid var(--ink);
    border-bottom: 1px solid var(--ink);
  }

  .sales-evidence > div:nth-child(odd) {
    border-right: 0;
  }

  .sales-evidence > div:nth-last-child(-n+2) {
    border-bottom: 0;
  }

  .sales-actions {
    grid-template-columns: 1fr;
  }

  .sales-actions a {
    border-right: 0;
    border-bottom: 1px solid var(--ink);
  }

  .sales-actions a:last-child {
    border-bottom: 0;
  }

  .site-footer {
    margin-top: 48px;
    padding: 28px 8px 32px;
  }

  .footer-receipt {
    padding: 16px 14px 14px;
  }

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

  .footer-grid > div {
    padding: 11px 10px;
    border-right: 1px solid var(--ink);
    border-bottom: 0;
  }

  .footer-grid > div:nth-child(2) {
    border-right: 0;
  }

  .footer-grid > div:last-child {
    grid-column: 1 / -1;
    border-top: 1px solid var(--ink);
    border-right: 0;
  }

  .footer-sources p {
    gap: 14px;
  }
}

@media (max-width: 1100px) {
  .route-head-bottom { grid-template-columns: 1fr; gap: 18px; }
  .setup-wiring,.convert-plan { grid-template-columns: 1fr 1fr; }
  .setup-wiring-art,.convert-plan-art { grid-column: 1/-1; min-height: 210px; border-bottom: 1px solid var(--ink); }
  .setup-wiring>div:nth-child(3),.setup-wiring>div:nth-child(5),.convert-plan>div:nth-child(3),.convert-plan>div:nth-child(5){border-right:0}
  .rules-gates { grid-template-columns: 1fr 1fr; }
  .rules-gates>div { border-bottom: 1px solid var(--ink); }
  .rules-gates>div:nth-child(3),.rules-gates>div:nth-child(5){border-right:0}
  .rules-gates>div:nth-last-child(-n+2){border-bottom:0}
  .rules-launch { grid-template-columns: 1fr 1fr; }
  .rules-launch>aside { grid-column:1/-1; border-top:1px solid var(--ink); }
}

@media (max-width: 719px) {
  .route-head-rail { grid-template-columns: 1fr 1fr; }
  .route-head-rail>div:last-child { grid-column:1/-1; border-top:1px solid var(--ink); }
  .route-head-rail>div:nth-child(2){border-right:0}
  .setup-entry>header,.convert-entry>header,.setup-review>header,.convert-result>header,.rules-gates>header,.rules-matrix>header,.rules-launch>header,.faq-intro{display:block;padding:18px 16px}
  .setup-entry h2,.convert-entry h2,.setup-review h2,.convert-result h2,.rules-gates h2,.rules-matrix h3,.rules-launch h3,.faq-intro h2{font-size:48px}
  .setup-entry .phase,.convert-quote,.setup-review>header>span,.convert-result>header>span{display:inline-block;margin-top:16px}
  .setup-fields,.setup-wiring,.convert-plan,.setup-review-body,.setup-boundary,.convert-boundary,.convert-entry form,.convert-read-rail,.rules-gates,.rules-launch,.faq-list,.faq-actions{grid-template-columns:1fr}
  .setup-fields .field:nth-child(n){grid-column:auto;border-right:0}
  .setup-submit { grid-template-columns:1fr; }
  .setup-submit>.btn,.convert-entry form>.btn { min-height:62px;border-top:2px solid var(--ink);border-left:0 }
  .setup-wiring>div,.convert-plan>div,.setup-wiring-art,.convert-plan-art{grid-column:auto;min-height:154px;border-right:0;border-bottom:1px solid var(--ink)}
  .setup-wiring>div:last-child,.convert-plan>div:last-child{border-bottom:0}
  .setup-review-body pre { border-right:0;border-bottom:2px solid var(--ink); }
  .setup-boundary span,.convert-boundary span{border-right:0;border-bottom:1px solid var(--paper)}
  .setup-boundary span:last-child,.convert-boundary span:last-child{border-bottom:0}
  .convert-read-rail>div,.convert-read-rail>p{border-right:0;border-bottom:1px solid var(--paper)}.convert-read-rail>p{border-bottom:0}
  .convert-summary,.convert-details { grid-template-columns:1fr 1fr; }.convert-summary>div:nth-child(2n),.convert-details>div:nth-child(2n){border-right:0}
  .rules-gates>header img { width:100%;height:120px;margin-top:16px; }.rules-gates>div:nth-child(n){min-height:190px;border-right:0;border-bottom:1px solid var(--ink)}.rules-gates>div:last-child{border-bottom:0}
  .rules-matrix-row { grid-template-columns:1fr 1fr; }.rules-matrix-row.labels { display:none; }.rules-matrix-row span{min-height:66px}.rules-matrix-row span:nth-child(2n){border-right:0}.rules-matrix-row span:nth-child(-n+2){border-bottom:1px solid var(--ink)}
  .rules-launch>header,.rules-launch>aside{grid-column:auto}.rules-launch>div{border-right:0;border-bottom:1px solid var(--ink)}
  .faq-intro>p { margin-top:16px; }.faq-list details:nth-child(n){border-right:0}.faq-list details>p{padding-left:18px}.faq-actions a{border-right:0;border-bottom:1px solid var(--ink)}.faq-actions a:last-child{border-bottom:0}
}
/* Rich workstations: Setup, Convert and Rules v3. */
.setup-workstation {
  display: grid;
  grid-template-columns: 210px minmax(0,1fr) 310px;
  border: 2px solid var(--ink);
  border-top: 0;
  background: var(--paper);
}

.setup-stepper {
  color: var(--paper);
  background: var(--ink);
}

.setup-stepper-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  min-height: 78px;
  padding: 16px;
  border-bottom: 1px solid var(--paper);
}

.setup-stepper-head strong {
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 400;
}

.setup-stepper button {
  position: relative;
  display: grid;
  grid-template-columns: 38px 1fr;
  width: 100%;
  min-height: 112px;
  padding: 16px 12px;
  border: 0;
  border-bottom: 1px solid rgba(248,247,242,.45);
  color: var(--paper);
  background: transparent;
  text-align: left;
  cursor: pointer;
}

.setup-stepper button b {
  grid-row: span 3;
  font-family: var(--display);
  font-size: 30px;
  font-weight: 300;
}

.setup-stepper button span,
.setup-stepper button small,
.setup-stepper button i {
  display: block;
  font-family: var(--mono);
  font-size: 9px;
  font-style: normal;
}

.setup-stepper button small { margin-top: 7px; color: #aaa; }
.setup-stepper button i { margin-top: 10px; color: var(--mint); }
.setup-stepper button.active { color: var(--ink); background: var(--mint); }
.setup-stepper button.active small { color: var(--muted); }
.setup-stepper button.active i { color: var(--ink); }
.setup-stepper button.done::after { content: "✓"; position: absolute; top: 12px; right: 12px; color: var(--mint); font: 12px var(--mono); }
.setup-stepper button.active.done::after { color: var(--ink); }

.setup-v3 .setup-entry {
  border: 0;
  border-right: 2px solid var(--ink);
}

.setup-v3 .setup-entry > header { min-height: 126px; }
.setup-v3 .setup-entry h2 { font-size: clamp(48px,4.5vw,76px); }
.setup-v3 .setup-fields { display: block; }
.setup-field-group {
  display: grid;
  grid-template-columns: 72px minmax(150px,.55fr) minmax(0,1.6fr);
  align-items: stretch;
  min-height: 116px;
  border-bottom: 1px solid var(--ink);
}

.setup-field-group > * { min-width: 0; }
.setup-field-group > .setup-group-no {
  display: grid;
  place-items: center;
  border-right: 1px solid var(--ink);
  font-family: var(--display);
  font-size: 40px;
}

.setup-field-group > div:nth-child(2) {
  padding: 18px;
  border-right: 1px solid var(--ink);
}

.setup-field-group > div:nth-child(2) strong { font: 11px var(--mono); }
.setup-field-group > div:nth-child(2) p { margin: 10px 0 0; font-size: 12px; }
.setup-v3 .setup-fields .field { grid-column: auto; margin: 0; padding: 16px 18px; border: 0; }
.setup-v3 .setup-fields .field input { margin-top: 11px; }
.setup-pair { display: grid; grid-template-columns: 1fr 1fr; }
.setup-pair .field + .field { border-left: 1px solid var(--ink); }
.setup-v3 .setup-fields textarea { min-height: 90px; }
.setup-v3 .setup-submit { border-bottom: 0; }

.setup-live {
  display: flex;
  flex-direction: column;
  min-width: 0;
  background: var(--counter);
}

.setup-live-head,
.setup-live-row,
.setup-live-state {
  padding: 15px 17px;
  border-bottom: 1px solid var(--ink);
}

.setup-live-head { display: flex; justify-content: space-between; }
.setup-live-head i { width: 10px; height: 10px; border: 1px solid var(--ink); border-radius: 50%; background: #ff453a; }
.setup-v3[data-ready="true"] .setup-live-head i { background: var(--mint); }
.setup-live-name { padding: 21px 17px 16px; border-bottom: 2px solid var(--ink); }
.setup-live-name span,.setup-live-name small,.setup-live-row span,.setup-live-state span { display: block; font-family: var(--mono); font-size: 9px; }
.setup-live-name strong { display: block; margin: 12px 0 8px; font: 300 42px/.85 var(--display); overflow-wrap: anywhere; }
.setup-live img { width: 100%; height: 150px; padding: 16px; object-fit: contain; border-bottom: 2px solid var(--ink); }
.setup-live-row { display: grid; grid-template-columns: 1fr auto; gap: 12px; }
.setup-live-row strong { max-width: 155px; font: 10px var(--mono); overflow-wrap: anywhere; text-align: right; }
.setup-live-state { margin-top: auto; color: var(--paper); background: var(--ink); }
.setup-live-state strong { display: block; margin-top: 9px; font: 12px var(--mono); color: var(--mint); }

.setup-role-strip {
  display: grid;
  grid-template-columns: 1fr 48px 1fr 48px 1fr 48px 1fr;
  align-items: stretch;
  border: 2px solid var(--ink);
  border-top: 0;
  background: var(--paper);
}

.setup-role-strip div { min-height: 96px; padding: 18px; }
.setup-role-strip b,.setup-role-strip span { display: block; }
.setup-role-strip b { font: 11px var(--mono); }
.setup-role-strip span { margin-top: 12px; font-size: 13px; }
.setup-role-strip i { display: grid; place-items: center; border-right: 1px solid var(--ink); border-left: 1px solid var(--ink); font: 300 30px var(--display); }

.convert-terminal {
  border: 2px solid var(--ink);
  border-top: 0;
  background: var(--ink);
  color: var(--paper);
}

.convert-terminal-top { display: grid; grid-template-columns: minmax(0,1fr) 310px; }
.convert-terminal-top > div:first-child { min-height: 235px; padding: 26px; }
.convert-terminal h2 { margin: 12px 0 0; font: 300 clamp(62px,7vw,116px)/.76 var(--display); }
.convert-mode { display: flex; flex-direction: column; justify-content: flex-end; padding: 24px; border-left: 1px solid var(--paper); background: var(--mint); color: var(--ink); }
.convert-mode span,.convert-mode small { font: 9px var(--mono); }
.convert-mode strong { margin: 12px 0 8px; font: 300 42px/.9 var(--display); }
.convert-terminal form { display: grid; grid-template-columns: minmax(0,1fr) 310px; border-top: 1px solid var(--paper); }
.convert-terminal form .field { margin: 0; padding: 17px 20px; }
.convert-terminal form input { margin-top: 10px; border-color: var(--paper); color: var(--paper); background: transparent; font-family: var(--mono); }
.convert-terminal form input::placeholder { color: #888; }
.convert-terminal form .btn { border: 0; border-left: 1px solid var(--paper); background: var(--mint); }
.convert-presets { display: grid; grid-template-columns: 190px 90px 1fr; align-items: center; min-height: 54px; border-top: 1px solid var(--paper); font: 9px var(--mono); }
.convert-presets > * { padding: 13px 18px; }
.convert-presets button { height: 100%; border: 0; border-right: 1px solid var(--paper); border-left: 1px solid var(--paper); color: var(--ink); background: var(--paper); font: 11px var(--mono); cursor: pointer; }
.convert-presets button:hover { background: var(--mint); }

.convert-map {
  position: relative;
  display: grid;
  grid-template-columns: 1fr minmax(70px,.45fr) 1fr minmax(70px,.45fr) 1fr minmax(70px,.45fr) 1fr;
  align-items: center;
  min-height: 330px;
  padding: 52px 28px;
  overflow: hidden;
  border: 2px solid var(--ink);
  border-top: 0;
  background: var(--counter);
}

.convert-map-grid { position: absolute; inset: 0; opacity: .22; background-image: linear-gradient(var(--mint) 1px,transparent 1px),linear-gradient(90deg,var(--mint) 1px,transparent 1px); background-size: 52px 52px; }
.convert-map > img { position: absolute; right: 2%; bottom: -45px; width: 36%; height: 220px; opacity: .11; object-fit: contain; }
.convert-node { position: relative; z-index: 1; min-width: 0; min-height: 178px; padding: 18px; border: 2px solid var(--ink); background: var(--paper); box-shadow: 7px 7px 0 var(--ink); }
.convert-node b { display: block; font: 300 48px/.8 var(--display); }
.convert-node span,.convert-node small,.convert-node strong { display: block; font-family: var(--mono); }
.convert-node span { margin-top: 24px; font-size: 9px; }
.convert-node strong { margin-top: 8px; font-size: 12px; font-weight: 400; }
.convert-node small { margin-top: 5px; color: var(--muted); font-size: 9px; }
.convert-node.active { background: var(--mint); }
.convert-node.done::after { content: "SOURCE OK"; position: absolute; top: 14px; right: 12px; padding: 4px 5px; border: 1px solid var(--ink); font: 8px var(--mono); }
.convert-line { position: relative; z-index: 1; text-align: center; }
.convert-line i { display: block; height: 2px; background: var(--ink); }
.convert-line i::after { content: ""; display: block; width: 8px; height: 8px; margin-left: auto; border-top: 2px solid var(--ink); border-right: 2px solid var(--ink); transform: translateY(-3px) rotate(45deg); }
.convert-line span { display: inline-block; margin-top: 11px; padding: 4px; background: var(--counter); font: 8px var(--mono); }
.convert-v3[data-state="reading"] .convert-line i { background: var(--mint); animation: convertPulse .8s steps(2,end) infinite; }
@keyframes convertPulse { 50% { opacity: .25; } }

.convert-monitor { display: grid; grid-template-columns: 250px minmax(0,1fr) 170px; min-height: 92px; border: 2px solid var(--ink); border-top: 0; color: var(--paper); background: var(--ink); }
.convert-monitor > * { margin: 0; padding: 17px 20px; border-right: 1px solid var(--paper); }
.convert-monitor > *:last-child { border: 0; }
.convert-monitor span,.convert-monitor strong { display: block; font-family: var(--mono); }
.convert-monitor span { font-size: 9px; color: var(--mint); }
.convert-monitor strong { margin-top: 10px; font-size: 12px; font-weight: 400; }
.convert-monitor p { display: grid; place-items: center start; font: 11px var(--mono); }
.convert-monitor-lamp { display: flex; align-items: center; gap: 12px; }
.convert-monitor-lamp i { width: 14px; height: 14px; flex: 0 0 auto; border-radius: 50%; background: #ff453a; }

.convert-evidence-desk { display: grid; grid-template-columns: repeat(4,1fr) 1.1fr; border: 2px solid var(--ink); border-top: 0; background: var(--paper); }
.convert-evidence-desk header { grid-column: 1/-1; display: flex; justify-content: space-between; align-items: end; padding: 20px 24px; border-bottom: 2px solid var(--ink); }
.convert-evidence-desk h3 { margin: 8px 0 0; font: 300 clamp(44px,4vw,68px)/.9 var(--display); }
.convert-evidence-desk > div,.convert-evidence-desk aside { min-height: 185px; padding: 18px; border-right: 1px solid var(--ink); }
.convert-evidence-desk > div b { display: block; font: 300 40px/.8 var(--display); }
.convert-evidence-desk > div span,.convert-evidence-desk aside span { display: block; margin-top: 19px; font: 9px var(--mono); }
.convert-evidence-desk > div p { margin: 10px 0 0; font-size: 13px; }
.convert-evidence-desk aside { border: 0; color: var(--paper); background: var(--ink); }
.convert-evidence-desk aside strong { display: block; margin-top: 18px; font: 300 34px/.9 var(--display); color: var(--mint); }

.rules-judge { display: grid; grid-template-columns: .82fr 1fr 1.7fr; border: 2px solid var(--ink); border-top: 0; background: var(--paper); }
.rules-judge-copy { padding: 26px; border-right: 2px solid var(--ink); background: var(--mint); }
.rules-judge-copy h2 { margin: 18px 0; font: 300 clamp(70px,7.5vw,124px)/.72 var(--display); }
.rules-judge-copy p { max-width: 270px; }
.rules-scenarios { border-right: 2px solid var(--ink); }
.rules-scenarios button { display: grid; grid-template-columns: 46px 1fr; width: 100%; min-height: 105px; padding: 16px 18px; border: 0; border-bottom: 1px solid var(--ink); background: transparent; text-align: left; cursor: pointer; }
.rules-scenarios button:last-child { border-bottom: 0; }
.rules-scenarios button b { grid-row: span 2; font: 300 34px var(--display); }
.rules-scenarios button span { font: 11px var(--mono); }
.rules-scenarios button small { margin-top: 8px; color: var(--muted); }
.rules-scenarios button.active { color: var(--paper); background: var(--ink); }
.rules-scenarios button.active small { color: var(--mint); }
.rules-verdict { display: grid; grid-template-rows: auto 1fr auto; min-width: 0; }
.rules-verdict-mark { display: grid; grid-template-columns: 1fr auto; align-items: center; min-height: 90px; padding: 17px 20px; border-bottom: 2px solid var(--ink); }
.rules-verdict-mark span,.rules-verdict-body > span { font: 9px var(--mono); }
.rules-verdict-mark strong { font: 300 clamp(42px,4.5vw,72px)/.8 var(--display); }
.rules-verdict[data-verdict="pass"] .rules-verdict-mark { background: var(--mint); }
.rules-verdict[data-verdict="fail"] .rules-verdict-mark { color: var(--paper); background: #d94232; }
.rules-verdict[data-verdict="hold"] .rules-verdict-mark { background: #ffd45c; }
.rules-verdict-body { padding: 24px 22px; }
.rules-verdict-body h3 { margin: 14px 0 12px; font: 300 clamp(40px,3.8vw,64px)/.86 var(--display); }
.rules-verdict-checks { display: grid; grid-template-columns: repeat(5,1fr); border-top: 2px solid var(--ink); }
.rules-verdict-checks span { padding: 13px 8px; border-right: 1px solid var(--ink); font: 8px var(--mono); text-align: center; }
.rules-verdict-checks span:last-child { border: 0; }
.rules-verdict-checks i { display: block; margin-bottom: 5px; font-size: 16px; font-style: normal; }

.rules-constitution { border: 2px solid var(--ink); border-top: 0; background: var(--paper); }
.rules-constitution > header { display: grid; grid-template-columns: 1fr 240px; align-items: center; padding: 22px 24px; border-bottom: 2px solid var(--ink); }
.rules-constitution h3,.rules-flow h3 { margin: 9px 0 0; font: 300 clamp(48px,5vw,82px)/.86 var(--display); }
.rules-constitution header img { width: 220px; height: 100px; object-fit: contain; }
.rules-constitution article { display: grid; grid-template-columns: 105px minmax(0,1fr) 190px; min-height: 148px; border-bottom: 1px solid var(--ink); transition: background 150ms ease; }
.rules-constitution article:last-child { border-bottom: 0; }
.rules-constitution article > b { display: grid; place-items: center; border-right: 1px solid var(--ink); font: 300 50px var(--display); }
.rules-constitution article > div { padding: 20px 24px; }
.rules-constitution article span,.rules-constitution article small { font: 9px var(--mono); }
.rules-constitution article h4 { margin: 10px 0 8px; font: 300 34px/.9 var(--display); }
.rules-constitution article p { max-width: 700px; margin: 0; }
.rules-constitution article > small { display: grid; place-items: center; padding: 16px; border-left: 1px solid var(--ink); text-align: center; }
.rules-constitution article.active { background: var(--counter); box-shadow: inset 8px 0 0 var(--mint); }

.rules-flow { border: 2px solid var(--ink); border-top: 0; background: var(--ink); color: var(--paper); }
.rules-flow header { padding: 22px 24px; border-bottom: 1px solid var(--paper); }
.rules-flow-track { display: grid; grid-template-columns: 1fr 48px 1fr 48px 1fr 48px 1fr; align-items: stretch; }
.rules-flow-track div { min-height: 130px; padding: 18px; }
.rules-flow-track i { display: grid; place-items: center; border-right: 1px solid var(--paper); border-left: 1px solid var(--paper); font-style: normal; }
.rules-flow-track b,.rules-flow-track span,.rules-flow-track small { display: block; font-family: var(--mono); }
.rules-flow-track b { color: var(--mint); font-size: 9px; }
.rules-flow-track span { margin-top: 18px; font-size: 11px; }
.rules-flow-track small { margin-top: 8px; color: #aaa; }
.rules-flow-track .final { color: var(--ink); background: var(--mint); }
.rules-flow-track .final b { color: var(--ink); }

@media (max-width: 1100px) {
  .setup-workstation { grid-template-columns: 175px minmax(0,1fr); }
  .setup-live { grid-column: 1/-1; display: grid; grid-template-columns: 1.3fr 1fr 1fr; border-top: 2px solid var(--ink); }
  .setup-live-head,.setup-live-name,.setup-live img { grid-row: span 2; }
  .setup-live img { height: 100%; border-right: 1px solid var(--ink); border-bottom: 0; }
  .setup-live-state { margin: 0; }
  .convert-map { grid-template-columns: 1fr 45px 1fr 45px 1fr 45px 1fr; padding-right: 18px; padding-left: 18px; }
  .convert-node { min-height: 165px; padding: 14px; }
  .convert-node b { font-size: 38px; }
  .convert-evidence-desk { grid-template-columns: repeat(4,1fr); }
  .convert-evidence-desk aside { grid-column: 1/-1; min-height: 120px; }
  .rules-judge { grid-template-columns: .8fr 1.2fr; }
  .rules-verdict { grid-column: 1/-1; min-height: 360px; border-top: 2px solid var(--ink); }
  .rules-scenarios { border-right: 0; }
}

@media (max-width: 719px) {
  .setup-workstation { grid-template-columns: 1fr; }
  .setup-stepper { display: grid; grid-template-columns: repeat(4,1fr); }
  .setup-stepper-head { grid-column: 1/-1; min-height: 54px; }
  .setup-stepper button { display: block; min-height: 90px; padding: 11px 8px; border-right: 1px solid var(--paper); }
  .setup-stepper button:last-child { border-right: 0; }
  .setup-stepper button b { display: block; font-size: 26px; }
  .setup-stepper button span { margin-top: 7px; font-size: 7px; }
  .setup-stepper button small { display: none; }
  .setup-v3 .setup-entry { border-right: 0; }
  .setup-field-group { grid-template-columns: 52px minmax(0,1fr); }
  .setup-field-group > .setup-group-no { grid-row: span 2; }
  .setup-field-group > div:nth-child(2) { border-right: 0; }
  .setup-field-group > .field,.setup-field-group > .setup-pair { grid-column: 2; }
  .setup-pair { grid-template-columns: 1fr; }
  .setup-pair .field + .field { border-top: 1px solid var(--ink); border-left: 0; }
  .setup-live { display: block; }
  .setup-live img { height: 145px; border-right: 0; border-bottom: 2px solid var(--ink); }
  .setup-role-strip { grid-template-columns: 1fr 34px 1fr; }
  .setup-role-strip i:nth-of-type(2),.setup-role-strip i:nth-of-type(3),.setup-role-strip div:nth-of-type(3),.setup-role-strip div:nth-of-type(4) { border-top: 1px solid var(--ink); }
  .setup-role-strip i:nth-of-type(2) { grid-column: 3; }
  .setup-role-strip div:nth-of-type(3) { grid-column: 1; }
  .setup-role-strip i:nth-of-type(3) { grid-column: 2; }
  .setup-role-strip div:nth-of-type(4) { grid-column: 3; }
  .convert-terminal-top,.convert-terminal form { grid-template-columns: 1fr; }
  .convert-terminal-top > div:first-child { min-height: 195px; }
  .convert-terminal h2 { font-size: 66px; }
  .convert-mode { min-height: 112px; border-top: 1px solid var(--paper); border-left: 0; }
  .convert-terminal form .btn { min-height: 64px; border-top: 1px solid var(--paper); border-left: 0; }
  .convert-presets { grid-template-columns: 1fr auto; }
  .convert-presets small { grid-column: 1/-1; border-top: 1px solid var(--paper); }
  .convert-map { grid-template-columns: 1fr; gap: 38px; min-height: auto; padding: 28px 22px; }
  .convert-line { height: 18px; transform: rotate(90deg); }
  .convert-node { min-height: 145px; }
  .convert-monitor { grid-template-columns: 1fr 1fr; }
  .convert-monitor p { grid-column: 1/-1; grid-row: 2; min-height: 82px; border-top: 1px solid var(--paper); border-right: 0; }
  .convert-monitor-lamp { border-right: 0; }
  .convert-evidence-desk { grid-template-columns: 1fr 1fr; }
  .convert-evidence-desk header { display: block; }
  .convert-evidence-desk > div { border-bottom: 1px solid var(--ink); }
  .convert-evidence-desk > div:nth-of-type(2n) { border-right: 0; }
  .convert-evidence-desk aside { grid-column: 1/-1; }
  .rules-judge { grid-template-columns: 1fr; }
  .rules-judge-copy,.rules-scenarios { border-right: 0; border-bottom: 2px solid var(--ink); }
  .rules-judge-copy h2 { font-size: 86px; }
  .rules-verdict { grid-column: auto; border-top: 0; }
  .rules-verdict-checks { grid-template-columns: repeat(5,1fr); }
  .rules-constitution > header { grid-template-columns: 1fr; }
  .rules-constitution header img { width: 100%; margin-top: 18px; }
  .rules-constitution article { grid-template-columns: 62px 1fr; }
  .rules-constitution article > small { grid-column: 1/-1; min-height: 42px; border-top: 1px solid var(--ink); border-left: 0; }
  .rules-flow-track { grid-template-columns: 1fr; }
  .rules-flow-track i { min-height: 35px; border-top: 1px solid var(--paper); border-right: 0; border-bottom: 1px solid var(--paper); border-left: 0; transform: rotate(90deg); }
}
