:root {
  --ink: #172126;
  --paper: #f3f4ef;
  --surface: #ffffff;
  --wash: #e7ece7;
  --line: rgba(23, 33, 38, 0.16);
  --line-strong: rgba(23, 33, 38, 0.28);
  --muted: rgba(23, 33, 38, 0.66);
  --soft: rgba(23, 33, 38, 0.08);
  --teal: #246c67;
  --blue: #345f91;
  --brick: #96474d;
  --gold: #a17124;
  --mono: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
  --sans: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

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

a {
  color: inherit;
  text-decoration: none;
}

a:hover {
  color: var(--teal);
}

.site-shell {
  min-height: 100vh;
}

.masthead {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  min-height: 4.25rem;
  padding: 0.7rem clamp(1rem, 4vw, 3rem);
  border-top: 4px solid var(--ink);
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(14px);
}

.brand-lockup {
  display: grid;
  gap: 0.05rem;
}

.brand-lockup span,
.section-kicker,
.top-nav a,
.hero-actions a,
.status-band span,
.route-label,
.text-link,
.panel-title,
dt,
th,
.process-list span {
  font-size: 0.74rem;
  font-weight: 760;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.brand-lockup span {
  color: var(--muted);
}

.brand-lockup strong {
  font-size: 1.45rem;
  line-height: 1;
}

.top-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.35rem;
}

.top-nav a {
  min-height: 2.1rem;
  display: inline-flex;
  align-items: center;
  border: 1px solid transparent;
  padding: 0.32rem 0.58rem;
  color: var(--muted);
}

.top-nav a:hover {
  border-color: var(--line);
  background: var(--paper);
}

main {
  min-width: 0;
}

.hero-band,
.two-column-band,
.ledger-band,
.compare-band,
.next-band {
  padding: clamp(1.1rem, 4vw, 3rem);
}

.hero-band {
  min-height: calc(100vh - 4.25rem);
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(18rem, 25rem);
  gap: clamp(1rem, 4vw, 3rem);
  align-items: center;
  border-bottom: 1px solid var(--line);
  background:
    linear-gradient(115deg, rgba(36, 108, 103, 0.1), transparent 42%),
    linear-gradient(180deg, #ffffff 0%, #f7f8f5 72%, var(--paper) 100%);
}

.hero-copy {
  max-width: 72rem;
}

.section-kicker {
  margin-bottom: 0.7rem;
  color: var(--teal);
}

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

h1 {
  max-width: 16ch;
  margin-bottom: 1.1rem;
  font-size: clamp(3.2rem, 9vw, 7.6rem);
  line-height: 0.88;
  letter-spacing: 0;
}

h2 {
  max-width: 18ch;
  margin-bottom: 0.8rem;
  font-size: clamp(2rem, 4.2vw, 4rem);
  line-height: 0.98;
  letter-spacing: 0;
}

h3 {
  margin-bottom: 0.45rem;
  font-size: 1.02rem;
}

p {
  color: var(--muted);
}

.hero-copy p {
  max-width: 60rem;
  font-size: clamp(1.05rem, 1.6vw, 1.35rem);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1.5rem;
}

.hero-actions a,
.text-link {
  min-height: 2.45rem;
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--line-strong);
  background: #fff;
  padding: 0.45rem 0.75rem;
  color: var(--ink);
}

.hero-actions a:first-child {
  border-color: var(--ink);
  background: var(--ink);
  color: #fff;
}

.route-panel {
  border: 1px solid var(--line-strong);
  background: #fbfcfb;
  box-shadow: 0 1rem 3rem rgba(23, 33, 38, 0.08);
}

.route-label {
  border-bottom: 1px solid var(--line);
  padding: 0.85rem 1rem;
  color: var(--blue);
  font-family: var(--mono);
  letter-spacing: 0;
  text-transform: none;
}

dl {
  margin: 0;
}

dl div {
  display: grid;
  gap: 0.18rem;
  border-bottom: 1px solid var(--line);
  padding: 0.9rem 1rem;
}

dl div:last-child {
  border-bottom: 0;
}

dt,
th {
  color: var(--muted);
}

dd {
  margin: 0;
  font-size: 1.03rem;
  font-weight: 760;
  overflow-wrap: anywhere;
}

.status-band {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border-bottom: 1px solid var(--line);
  background: var(--ink);
  color: #fff;
}

.status-band article {
  min-height: 13rem;
  display: grid;
  align-content: start;
  gap: 0.45rem;
  border-right: 1px solid rgba(255, 255, 255, 0.14);
  padding: clamp(1rem, 2vw, 1.5rem);
}

.status-band article:last-child {
  border-right: 0;
}

.status-band span {
  color: rgba(255, 255, 255, 0.58);
}

.status-band strong {
  max-width: 12ch;
  font-size: clamp(1.35rem, 2.1vw, 2rem);
  line-height: 1.02;
}

.status-band p {
  margin-bottom: 0;
  color: rgba(255, 255, 255, 0.72);
}

.two-column-band {
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(20rem, 1.08fr);
  gap: clamp(1rem, 4vw, 3rem);
  align-items: start;
  border-bottom: 1px solid var(--line);
  background: #fff;
}

.band-copy {
  max-width: 44rem;
}

.plain-list {
  margin: 1rem 0 1.2rem;
  padding-left: 1.05rem;
  color: var(--ink);
}

.plain-list li + li {
  margin-top: 0.48rem;
}

.code-panel {
  min-width: 0;
  border-left: 5px solid var(--blue);
  background: #172126;
  color: #eef4f2;
  padding: clamp(1rem, 2vw, 1.5rem);
}

.panel-title {
  margin-bottom: 0.9rem;
  color: rgba(238, 244, 242, 0.62);
}

pre {
  max-width: 100%;
  overflow: auto;
  margin: 0;
  font-family: var(--mono);
  font-size: 0.88rem;
  line-height: 1.52;
}

.ledger-band {
  border-bottom: 1px solid var(--line);
  background: var(--paper);
}

.band-heading {
  display: flex;
  justify-content: space-between;
  align-items: start;
  gap: 1rem;
  margin-bottom: clamp(1rem, 2vw, 1.5rem);
}

.ledger-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.ledger-grid article,
.next-grid article {
  border: 1px solid var(--line);
  background: #fff;
  padding: 1rem;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92rem;
}

th,
td {
  border-top: 1px solid var(--line);
  padding: 0.68rem 0;
  text-align: left;
  vertical-align: top;
}

td {
  padding-left: 0.8rem;
  color: var(--ink);
}

.compare-band {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(20rem, 1.2fr);
  gap: clamp(1rem, 4vw, 3rem);
  align-items: start;
  border-bottom: 1px solid var(--line);
  background: #fff;
}

.process-list {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin: 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
}

.process-list li {
  min-height: 11rem;
  display: grid;
  align-content: start;
  gap: 0.42rem;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 0.85rem;
}

.process-list span {
  color: var(--brick);
  font-family: var(--mono);
}

.process-list strong {
  font-size: 1.12rem;
}

.process-list p {
  margin-bottom: 0;
}

.next-band {
  background:
    linear-gradient(90deg, rgba(52, 95, 145, 0.08), transparent 48%),
    var(--wash);
}

.next-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.next-grid p {
  margin-bottom: 0;
}

@media (max-width: 1100px) {
  .hero-band,
  .two-column-band,
  .compare-band {
    grid-template-columns: 1fr;
  }

  .status-band,
  .ledger-grid,
  .process-list,
  .next-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  h1,
  h2 {
    max-width: 18ch;
  }
}

@media (max-width: 700px) {
  .masthead {
    position: static;
    align-items: stretch;
    flex-direction: column;
  }

  .top-nav {
    justify-content: flex-start;
  }

  .hero-band {
    min-height: auto;
  }

  .status-band,
  .ledger-grid,
  .process-list,
  .next-grid {
    grid-template-columns: 1fr;
  }

  .status-band article,
  .process-list li {
    min-height: auto;
  }

  .status-band article {
    border-right: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.14);
  }

  .band-heading {
    align-items: stretch;
    flex-direction: column;
  }

  h1 {
    font-size: clamp(2.8rem, 16vw, 4.2rem);
  }
}
