/* MwaRent landing. Mobile first; wider layouts are added with min-width queries. */

/* ── Base ─────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: var(--space-3); }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 400 var(--text-base)/var(--leading-body) var(--font-body);
  font-variant-numeric: lining-nums;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}
img, svg { display: block; max-width: 100%; }
/* The hidden SVG symbol sheet: out of the layout without an inline style (the CSP has no style-src 'unsafe-inline'). */
.sprite { position: absolute; }
h1, h2, h3, p, ol, ul, dl, dd, figure { margin: 0; padding: 0; }
ol, ul { list-style: none; }
p { text-wrap: pretty; }
h1, h2, h3 { text-wrap: balance; font-family: var(--font-display); font-weight: 600; }
a { color: inherit; }
button { font: inherit; color: inherit; }
code { font: inherit; }
table { border-collapse: collapse; width: 100%; }
th { font-weight: inherit; text-align: left; }
::selection { background: var(--blue-600); color: var(--white); }

.mono, .num, code {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums slashed-zero;
  letter-spacing: var(--tracking-mono);
}
.owed { color: var(--red-text); }
.on-navy { background: var(--navy-900); color: var(--text-on-navy); }
.on-navy .owed, .owed-on-navy { color: var(--red-300); }
.on-navy .panel .owed { color: var(--red-text); }

:focus-visible { outline: 2px solid transparent; box-shadow: var(--focus-ring); border-radius: var(--radius-1); }
.on-navy :focus-visible { box-shadow: var(--focus-ring-on-navy); }

.skip {
  position: absolute; left: var(--space-2); top: -4rem; z-index: 10;
  padding: var(--space-1) var(--space-2); background: var(--white); color: var(--ink);
}
.skip:focus { top: var(--space-1); }

/* ── Grid ─────────────────────────────────────────────── */
.wrap { width: 100%; max-width: calc(var(--max) + 2 * var(--gutter)); margin-inline: auto; padding-inline: var(--gutter); }
.grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); column-gap: var(--col-gap); }
@media (min-width: 768px) { .grid { grid-template-columns: repeat(12, minmax(0, 1fr)); } }

/* Visible column hairlines behind the hero and footer. */
.gridlines {
  position: absolute; inset: 0 auto 0 50%; width: min(100%, calc(var(--max) + 2 * var(--gutter)));
  translate: -50% 0; padding-inline: var(--gutter);
  display: grid; grid-template-columns: repeat(4, 1fr); column-gap: var(--col-gap);
  pointer-events: none;
}
.gridlines i { border-left: 1px solid var(--rule-on-navy); opacity: 0.5; }
.gridlines i:last-child { border-right: 1px solid var(--rule-on-navy); }
.gridlines i:nth-child(n + 5) { display: none; }
@media (min-width: 768px) {
  .gridlines { grid-template-columns: repeat(12, 1fr); }
  .gridlines i:nth-child(n + 5) { display: block; }
  .gridlines i { border-right: 0; }
  .gridlines i:last-child { border-right: 1px solid var(--rule-on-navy); }
}

/* ── Type ─────────────────────────────────────────────── */
.display {
  font-size: var(--text-3xl); line-height: var(--leading-tight);
  letter-spacing: var(--tracking-display); font-weight: 600;
}
.display--md { font-size: var(--text-2xl); line-height: 1.02; }
.h2 { font-size: var(--text-2xl); line-height: 1.04; letter-spacing: var(--tracking-heading); }
.h2--small { font-size: clamp(1.75rem, 1.2rem + 2vw, 2.75rem); }
.lede { font-size: var(--text-lg); line-height: 1.55; max-width: 34em; color: var(--text-on-navy-soft); }
.body-lg { font-size: var(--text-lg); line-height: 1.55; color: var(--ink-soft); max-width: 32em; }
.label {
  display: flex; align-items: baseline; gap: var(--space-1);
  font: 500 var(--text-xs)/1 var(--font-mono); letter-spacing: var(--tracking-label); text-transform: uppercase;
  color: var(--ink-soft);
}
.on-navy .label { color: var(--text-on-navy-soft); }
.label__no { color: var(--ink); padding-right: var(--space-1); border-right: 1px solid var(--rule-strong); }

/* ── Buttons and links: blue means "press me" ─────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; min-height: 3rem;
  padding: 0 var(--space-3); border: 1px solid transparent; border-radius: var(--radius-2);
  background: var(--blue-600); color: var(--white);
  font: 600 var(--text-base)/1 var(--font-body); text-decoration: none; white-space: nowrap;
  transition: background-color var(--dur-fast), transform var(--dur-fast) var(--ease-out);
}
.btn:hover { background: var(--blue-700); }
.btn:active { transform: translateY(1px); }
.on-navy .btn { box-shadow: inset 0 0 0 1px rgb(255 255 255 / 0.22); }
.on-navy .btn:focus-visible { box-shadow: var(--focus-ring-on-navy); }
.btn--sm { min-height: 2.5rem; padding: 0 var(--space-2); font-size: var(--text-sm); }

.link-arrow {
  display: inline-flex; align-items: center; gap: var(--space-1); min-height: 3rem;
  font-weight: 600; text-decoration: none; color: var(--blue-300);
  background: linear-gradient(currentColor, currentColor) 0 calc(50% + 12px) / 0 1px no-repeat;
  transition: background-size var(--dur-med) var(--ease-out);
}
.link-arrow::after { content: "↓"; transition: translate var(--dur-fast) var(--ease-out); }
.link-arrow[href^="mailto"]::after { content: "→"; }
.link-arrow:hover { background-size: calc(100% - 1.5rem) 1px; }
.link-arrow:hover::after { translate: 0 2px; }
.link-arrow[href^="mailto"]:hover::after { translate: 3px 0; }

.btn-text {
  padding: 0; border: 0; background: none; cursor: pointer;
  font: 600 var(--text-sm)/1.2 var(--font-body); color: var(--blue-600);
  text-decoration: underline; text-decoration-color: transparent; text-underline-offset: 4px; text-decoration-thickness: 1px;
  transition: text-decoration-color var(--dur-fast);
}
button.btn-text:hover { text-decoration-color: currentColor; }
span.btn-text { cursor: default; }

/* ── Header ───────────────────────────────────────────── */
.hero-shell { position: relative; overflow: hidden; }
.site-header {
  position: relative; z-index: 2;
  display: flex; align-items: center; justify-content: space-between;
  padding-block: var(--space-2);
}
.brand { display: flex; align-items: center; min-height: 2.75rem; border-radius: var(--radius-1); }
.brand img { width: 124px; height: auto; }
.site-nav { display: none; }
@media (min-width: 900px) {
  .brand img { width: 148px; }
  .site-nav { display: flex; gap: var(--space-3); font-size: var(--text-sm); font-weight: 500; }
  .site-nav a {
    text-decoration: none; color: var(--text-on-navy-soft); padding-block: var(--space-1);
    border-bottom: 1px solid transparent; transition: color var(--dur-fast), border-color var(--dur-fast);
  }
  .site-nav a:hover { color: var(--white); border-color: var(--white); }
}
@media (min-width: 1200px) { .site-nav { gap: var(--space-4); } }

/* ── Hero ─────────────────────────────────────────────── */
.hero { position: relative; padding-top: var(--space-6); }
.hero .grid { position: relative; z-index: 1; }

/* The logo's roof as a depth layer behind the product. Placement per hero variant: devices.css. */
.hero__roof { position: absolute; z-index: 0; fill: var(--red-600); max-width: none; height: auto; aspect-ratio: 627 / 611; }

.hero__copy { grid-column: 1 / -1; padding-bottom: var(--space-6); }
.hero__copy .label { margin-bottom: var(--space-3); }
.hero__copy .display { margin-bottom: var(--space-3); }
.hero__copy .lede { margin-bottom: var(--space-4); }
.actions { display: flex; flex-wrap: wrap; align-items: center; column-gap: var(--space-4); row-gap: var(--space-1); }
.actions .btn { flex: 1 1 100%; }
@media (min-width: 480px) { .actions .btn { flex: 0 0 auto; } }

.hero__product { grid-column: 1 / -1; position: relative; padding-bottom: var(--space-6); }

@media (min-width: 768px) {
  .hero { padding-top: var(--space-8); }
  .hero__copy { grid-column: 1 / 10; padding-bottom: var(--space-8); }
  .hero__product { grid-column: 3 / -1; padding-bottom: var(--space-8); }
}
@media (min-width: 1100px) {
  .hero__copy { grid-column: 1 / 7; grid-row: 1; padding-bottom: var(--space-12); }
  .hero__product { grid-column: 7 / -1; grid-row: 1; align-self: end; margin-top: var(--space-12); }
}

/* ── Panels (product UI) ──────────────────────────────── */
.panel { background: var(--white); color: var(--ink); border-radius: var(--radius-3); box-shadow: var(--shadow-panel); }
.panel--light { border: 1px solid var(--rule); box-shadow: none; border-radius: var(--radius-2); }
.panel__head, .stmt-head {
  display: flex; justify-content: space-between; align-items: flex-end; gap: var(--space-2);
  padding: var(--space-2) var(--space-2) var(--space-2); border-bottom: 1px solid var(--rule);
}
.panel__title { font: 600 var(--text-sm)/1.3 var(--font-body); }
.panel__sub { font-size: var(--text-xs); color: var(--ink-faint); line-height: 1.3; }
.panel__sum { font-size: var(--text-xs); display: flex; flex-direction: column; align-items: flex-end; color: var(--ink-soft); }
.panel__sum b { font-size: var(--text-xl); line-height: 1; font-weight: 600; }
.panel__foot {
  display: flex; justify-content: space-between; gap: var(--space-2);
  padding: var(--space-2); border-top: 1px solid var(--rule); font-size: var(--text-xs); color: var(--ink-soft);
}

/* The match notification overlaps the panel and the grid. */
.match-chip {
  position: relative; z-index: 2; margin: var(--space-1) 0 0;
  display: flex; gap: var(--space-2); align-items: center;
  padding: var(--space-2); background: var(--paper); color: var(--ink);
  border-radius: var(--radius-2); box-shadow: var(--shadow-float);
  font-size: var(--text-sm); line-height: 1.35;
}
.match-chip span { font-size: var(--text-xs); color: var(--ink-soft); }
.windows { flex: none; width: 24px; height: 24px; fill: var(--blue-600); }

/* ── Sections ─────────────────────────────────────────── */
.section { padding-block: var(--space-8); }
@media (min-width: 768px) { .section { padding-block: var(--space-16); } }

.roofline { grid-column: 1 / -1; display: flex; align-items: flex-end; color: var(--rule-strong); }
.roofline i { flex: 1 1 0; border-bottom: 1px solid currentColor; height: 12px; }
.roofline svg { flex: none; width: 24px; height: 12px; fill: none; stroke: currentColor; stroke-width: 1; stroke-linejoin: round; }
.roofline--a i:first-child { flex: 0 0 25%; }
.roofline--b i:first-child { flex: 0 0 66%; }
@media (min-width: 768px) {
  .roofline--a i:first-child { flex-basis: calc((100% + var(--col-gap)) * 4 / 12 - var(--col-gap) - 12px); }
  .roofline--b i:first-child { flex-basis: calc((100% + var(--col-gap)) * 9 / 12 - var(--col-gap) - 12px); }
}

/* 01 Statements ─ the signature interaction */
.statements__intro, .statements__screen { grid-column: 1 / -1; }
.statements__intro { margin-bottom: var(--space-4); }
.statements__intro .label { margin-bottom: var(--space-3); }
.statements__intro .h2 { margin-bottom: var(--space-3); }

.readout { display: none; }
@media (min-width: 1024px) {
  .statements__intro { grid-column: 1 / 6; margin-bottom: 0; align-self: start; position: sticky; top: var(--space-6); }
  .statements__screen { grid-column: 6 / -1; }
  .readout { display: flex; gap: var(--space-6); margin-top: var(--space-8); padding-top: var(--space-3); border-top: 1px solid var(--rule-strong); }
  .readout dt { font: 500 var(--text-xs)/1 var(--font-mono); letter-spacing: var(--tracking-label); text-transform: uppercase; color: var(--ink-soft); margin-bottom: var(--space-1); }
  .readout dd { font-size: clamp(3.5rem, 2rem + 4vw, 6rem); line-height: 1; font-weight: 500; letter-spacing: -0.06em; }
}

.stmt-panel { background: var(--white); }
.stmt-head { position: sticky; top: 0; z-index: 2; background: var(--white); border-radius: var(--radius-2) var(--radius-2) 0 0; }
.stmt-head { flex-wrap: wrap; }
.stmt-head > div { min-width: 0; }
.stmt-head .panel__title { overflow-wrap: anywhere; }
.stmt-head__counts { display: flex; flex: none; white-space: nowrap; gap: var(--space-2); font-size: var(--text-xs); color: var(--ink-soft); }
.stmt-head__counts b { color: var(--ink); font-weight: 600; }
@media (min-width: 1024px) { .stmt-head__counts { display: none; } }

.stmt__row {
  display: grid; grid-template-columns: auto 1fr; grid-template-areas: "date date" "desc desc" "amt to";
  gap: 4px var(--space-2); padding: var(--space-2); border-bottom: 1px solid var(--rule); position: relative;
}
.stmt__row:last-child { border-bottom: 0; }
.stmt__date { grid-area: date; font-size: var(--text-xs); color: var(--ink-faint); }
.stmt__amt { grid-area: amt; justify-self: start; font-weight: 600; padding-right: var(--space-1); }
.stmt__amt::after { content: "→"; margin-left: var(--space-1); color: var(--ink-faint); font-weight: 400; }
.stmt__desc { grid-area: desc; display: block; min-width: 0; }
.stmt__desc code { display: block; font-size: var(--text-sm); font-weight: 500; overflow-wrap: anywhere; }
.stmt__desc em { display: block; margin-top: 2px; font-style: normal; font-size: var(--text-xs); color: var(--ink-soft); }
.stmt__to { grid-area: to; display: flex; align-items: center; gap: var(--space-1); min-height: 2rem; }
.stmt__tenant { font-size: var(--text-sm); font-weight: 600; }
.stmt__tenant b { display: block; font-size: var(--text-xs); font-weight: 500; }

.chip {
  display: inline-grid; place-items: center; min-width: 2rem; height: 1.5rem; padding: 0 6px;
  background: var(--navy-900); color: var(--white); border-radius: var(--radius-1);
  font: 600 var(--text-xs)/1 var(--font-mono);
}
.chip--lg { height: 2.5rem; min-width: 2.5rem; font-size: var(--text-sm); }

.stmt__bar { height: 4px; width: 100%; background: var(--paper-deep); border-radius: 2px; overflow: hidden; }
.stmt__bar::after { content: ""; display: block; height: 100%; width: 100%; background: var(--navy-900); transform-origin: left; }

@media (min-width: 768px) {
  .stmt__row {
    grid-template-columns: 4rem minmax(0, 1fr) 5rem 11rem; grid-template-areas: "date desc amt to";
    align-items: start; column-gap: var(--space-2);
  }
  .stmt__amt { justify-self: end; padding-right: 0; }
  .stmt__amt::after { content: none; }
  .stmt__to { min-height: 0; flex-wrap: wrap; row-gap: 4px; }
}

/* Row states. Without JS everything shows its final, matched state. */
.js .stmt__row { --reveal: 0; }
.stmt__row[data-state="look"] .chip { background: var(--white); color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.stmt__row[data-state="look"] { background: repeating-linear-gradient(-45deg, transparent 0 7px, rgb(11 27 77 / 0.035) 7px 8px); }

.js .stmt__to > * { opacity: 0; transform: translateX(-8px); }
.js .stmt__row.is-matched .stmt__to > * { opacity: 1; transform: none; }
.js .stmt__row::before {
  content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 3px; background: var(--navy-900);
  transform: scaleY(0); transform-origin: top;
}
.js .stmt__row[data-state="look"]::before { background: transparent; border-left: 3px dotted var(--navy-900); width: 0; }
.js .stmt__row.is-matched::before { transform: scaleY(1); }
.js .stmt__row .stmt__bar::after { transform: scaleX(0); }
.js .stmt__row.is-matched .stmt__bar::after { transform: scaleX(1); }
.js .stmt__row .stmt__desc code { color: var(--ink-soft); }
.js .stmt__row.is-matched .stmt__desc code { color: var(--ink); }

@media (prefers-reduced-motion: no-preference) {
  .js .stmt__to > *, .js .stmt__row::before, .js .stmt__bar::after, .js .stmt__desc code {
    transition: opacity var(--dur-med) var(--ease-out), transform var(--dur-med) var(--ease-out), color var(--dur-med);
  }
  .js .stmt__row[data-state="rest"].is-matched .stmt__bar::after { transition-duration: 900ms; }
}
.js [data-count] { font-variant-numeric: tabular-nums; }

/* 02 Before / after */
.section--before { background: var(--white); }
.before__intro { grid-column: 1 / -1; margin-bottom: var(--space-6); }
.before__intro .label { margin-bottom: var(--space-3); }
.before__intro .h2 { max-width: 11em; }
.before__pair { grid-column: 1 / -1; display: grid; gap: var(--space-8); }
@media (min-width: 768px) { .before__intro { grid-column: 1 / 9; } }
@media (min-width: 1024px) {
  .before__pair { grid-template-columns: minmax(0, 1.1fr) 1px minmax(0, 1fr); gap: var(--space-6); }
  .before__pair::before { content: ""; grid-column: 2; grid-row: 1; background: var(--rule-strong); }
  .side--after { grid-column: 3; grid-row: 1; }
}

.side { min-width: 0; display: flex; flex-direction: column; gap: var(--space-3); }
.side__head { display: flex; justify-content: space-between; align-items: baseline; padding-bottom: var(--space-1); border-bottom: 1px solid var(--rule); }
.side__title { font-size: var(--text-sm); font-weight: 600; font-family: var(--font-body); }
.side__head .mono { font-size: var(--text-xs); color: var(--ink-faint); }
.side__result { margin-top: auto; padding-top: var(--space-2); border-top: 1px solid var(--rule); font-family: var(--font-display); font-weight: 600; font-size: var(--text-xl); letter-spacing: var(--tracking-heading); line-height: 1.15; max-width: 16em; }
.side--before .side__result { color: var(--ink-soft); }

/* Spreadsheet imitation */
.sheet { border: 1px solid #b9bdc8; background: #fff; font: 400 0.8125rem/1 "Liberation Sans", Arial, sans-serif; overflow-x: auto; }
.sheet__file { padding: 6px 8px; background: #e9ebef; border-bottom: 1px solid #b9bdc8; font-size: 0.6875rem; color: #4b5060; }
.sheet table { min-width: 22rem; }
.sheet th, .sheet td { padding: 7px 8px; border: 1px solid #d6d9e0; white-space: nowrap; }
.sheet thead th, .sheet tbody th { background: #f1f2f5; color: #5b6070; text-align: center; font-size: 0.6875rem; font-weight: 400; }
.sheet tbody th { width: 2rem; }
.sheet td { font-variant-numeric: tabular-nums; }
.sheet td:nth-child(n + 4) { text-align: right; }
.sheet .h { font-weight: 700; background: #fafafa; text-align: left !important; }
.sheet .flag { background: #fff3a8; }
.sheet .sum { color: #9a1c14; font-style: italic; }

/* WhatsApp-style thread */
.chat { display: flex; flex-direction: column; gap: 6px; padding: var(--space-2); background: var(--paper); border-radius: var(--radius-2); }
.chat li { width: fit-content; max-width: 85%; padding: 8px 12px 6px; border-radius: var(--radius-2); background: var(--white); font-size: var(--text-sm); line-height: 1.35; display: flex; gap: var(--space-2); align-items: flex-end; box-shadow: 0 1px 0 var(--rule); }
.chat li p { overflow-wrap: anywhere; }
.chat time { flex: none; font: 400 0.6875rem/1 var(--font-mono); color: var(--ink-faint); }
.chat__out { align-self: flex-end; background: #dfe4f5 !important; }

.after-card { padding: var(--space-3); display: flex; flex-direction: column; gap: var(--space-3); }
.after-card__top { display: flex; align-items: center; gap: var(--space-2); }
.after-card__top .status { margin-left: auto; }
.after-card__name { font-weight: 700; line-height: 1.2; }
.after-card__meta { font-size: var(--text-xs); color: var(--ink-faint); }
.after-card__lines { font-size: var(--text-sm); border-block: 1px solid var(--rule); }
.after-card__lines div { display: flex; justify-content: space-between; padding: 10px 0; }
.after-card__lines div + div { border-top: 1px solid var(--rule); }
.after-card__lines .is-total { font-weight: 600; }
.after-card__src { padding: var(--space-2); background: var(--paper); border-radius: var(--radius-1); border-left: 3px solid var(--navy-900); font-size: var(--text-xs); }
.after-card__src > .mono:first-child { color: var(--ink-faint); text-transform: uppercase; letter-spacing: var(--tracking-label); font-size: 0.6875rem; margin-bottom: 4px; }
.after-card__src code { font-size: var(--text-sm); }
.after-card__how { margin-top: var(--space-1); color: var(--ink-soft); font-size: var(--text-sm); }

/* 03 Arrears: one number, set large */
.section--arrears { padding-top: var(--space-8); }
.arrears__figure, .arrears__list { grid-column: 1 / -1; }
.arrears__figure { margin-bottom: var(--space-6); overflow: hidden; }
.arrears__figure .label { margin-bottom: var(--space-3); }
.numeral { display: flex; align-items: baseline; gap: var(--space-2); font-size: var(--text-numeral); line-height: 0.9; font-weight: 500; letter-spacing: -0.07em; }
.numeral__cur { font-size: var(--text-sm); letter-spacing: var(--tracking-label); color: var(--ink-soft); font-weight: 500; align-self: flex-start; padding-top: 0.5em; }
.arrears__note { margin-top: var(--space-3); padding-top: var(--space-1); border-top: 1px solid var(--rule-strong); font-size: var(--text-xs); color: var(--ink-soft); max-width: 24rem; }
@media (min-width: 768px) {
  .section--arrears { padding-top: var(--space-12); }
  .arrears__figure { grid-column: 1 / 8; margin-bottom: 0; align-self: start; padding-top: var(--space-1); }
  .arrears__list { grid-column: 8 / -1; }
}
.arrears__list .h2 { margin-bottom: var(--space-2); }
.arrears__list .body-lg { margin-bottom: var(--space-4); font-size: var(--text-base); }

.owing { border-top: 1px solid var(--ink); }
.owing li {
  display: grid; grid-template-columns: auto 1fr auto; grid-template-areas: "chip who amt";
  align-items: center; gap: 4px var(--space-2); padding-block: var(--space-2); border-bottom: 1px solid var(--rule);
}
.owing .chip { grid-area: chip; }
.owing__who { grid-area: who; font-weight: 600; line-height: 1.25; }
.owing__who small { display: block; font-weight: 400; font-size: var(--text-xs); color: var(--ink-soft); }
.owing__amt { grid-area: amt; font-weight: 600; }

/* 04 Index ─ numbered rows instead of cards */
.section--ledger { padding-top: var(--space-8); background: var(--paper-deep); border-top: 1px solid var(--rule); }
.ledger-intro { grid-column: 1 / -1; margin-bottom: var(--space-6); }
.ledger-intro .label { margin-bottom: var(--space-3); }
.index { grid-column: 1 / -1; }
.index li {
  display: grid; grid-template-columns: 2.5rem 1fr; gap: var(--space-1) var(--space-2);
  padding-block: var(--space-3); border-top: 1px solid var(--rule); position: relative;
  transition: background-color var(--dur-fast);
}
.index li:last-child { border-bottom: 1px solid var(--rule); }
.index__no { font-size: var(--text-xs); color: var(--ink-faint); padding-top: 0.5rem; }
.index h3 { font-size: var(--text-xl); letter-spacing: var(--tracking-heading); line-height: 1.15; margin-bottom: var(--space-1); }
.index__body p { color: var(--ink-soft); max-width: 34em; }
.index__sample { grid-column: 2; margin-top: var(--space-1); padding: var(--space-1) var(--space-2); font-size: var(--text-xs); line-height: 1.6; color: var(--ink-soft); background: var(--paper); border-radius: var(--radius-1); justify-self: start; }
.index li::after { content: ""; position: absolute; left: 0; top: -1px; width: 0; height: 1px; background: var(--blue-600); transition: width var(--dur-med) var(--ease-out); }
.index li:hover::after { width: 100%; }
.index li:hover .index__no { color: var(--blue-600); }

@media (min-width: 768px) {
  .section--ledger { padding-top: var(--space-12); }
  .ledger-intro { margin-bottom: var(--space-6); display: grid; grid-template-columns: subgrid; align-items: end; }
  .ledger-intro .label { grid-column: 1 / -1; }
  .ledger-intro .h2 { grid-column: 1 / 8; margin-bottom: 0; font-size: clamp(1.75rem, 1rem + 2vw, 2.75rem); }
  .ledger-intro .roadmap { grid-column: 8 / -1; margin-top: 0; }
  .index li { grid-template-columns: 3rem minmax(0, 1fr) 10rem; column-gap: var(--space-3); padding-block: var(--space-4); }
  .index__sample { grid-column: 3; grid-row: 1; margin-top: 0; justify-self: stretch; align-self: start; }
}
@media (min-width: 1100px) {
  .index { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: var(--space-6); align-items: stretch; }
  .index li { grid-template-columns: 2.5rem minmax(0, 1fr); column-gap: var(--space-2); }
  .index li:nth-last-child(2) { border-bottom: 1px solid var(--rule); }
  .index__sample { grid-column: 2; grid-row: auto; margin-top: var(--space-1); justify-self: start; }
}

/* ── Footer ───────────────────────────────────────────── */
.site-footer { position: relative; overflow: hidden; padding-top: var(--space-8); }
.site-footer .grid, .footer__bar { position: relative; z-index: 1; }
.footer__roof {
  position: absolute; max-width: none; z-index: 0; fill: var(--navy-800);
  width: 110vw; height: auto; aspect-ratio: 627 / 611; right: -44vw; top: var(--space-4);
}
@media (min-width: 768px) {
  .site-footer { padding-top: var(--space-16); }
  .footer__roof { width: min(48vw, 680px); right: -9vw; top: var(--space-8); }
}
.footer__top { position: relative; z-index: 1; padding-bottom: var(--space-12); row-gap: var(--space-6); }
.footer__cta { grid-column: 1 / -1; }
.footer__cta .label { margin-bottom: var(--space-3); }
.footer__cta .display { margin-bottom: var(--space-3); max-width: 9em; }
.footer__cta .lede { margin-bottom: var(--space-4); max-width: 30em; }
.steps { grid-column: 1 / -1; align-self: end; border-top: 1px solid var(--rule-on-navy); }
.steps li { display: grid; grid-template-columns: 2rem 1fr; gap: var(--space-2); padding-block: var(--space-2); border-bottom: 1px solid var(--rule-on-navy); }
.steps span { font-size: var(--text-xs); color: var(--blue-300); padding-top: 0.25rem; }
.steps p { color: var(--text-on-navy); }
@media (min-width: 768px) {
  .footer__cta { grid-column: 1 / 8; grid-row: 1; }
  .steps { grid-column: 8 / -1; grid-row: 1; align-self: center; }
}

.footer__bar {
  position: relative; z-index: 1; display: flex; flex-direction: column; gap: var(--space-3);
  padding-block: var(--space-4); 
  font-size: var(--text-sm); color: var(--text-on-navy-soft);
}
.footer__bar::before { content: ""; position: absolute; top: 0; left: var(--gutter); right: var(--gutter); height: 1px; background: var(--rule-on-navy); }
.footer__bar img { width: 120px; height: auto; }
.footer__bar nav { display: flex; flex-wrap: wrap; gap: 0 var(--space-3); }
.footer__bar nav a { display: inline-block; min-height: 2.5rem; line-height: 2.5rem; text-decoration: none; color: var(--text-on-navy-soft); }
.footer__bar nav a:hover { color: var(--white); text-decoration: underline; text-underline-offset: 4px; }
.footer__fine { font-size: var(--text-xs); max-width: 28em; }
@media (min-width: 900px) {
  .footer__bar { flex-direction: row; align-items: center; justify-content: space-between; }
  .footer__fine { text-align: right; }
}

/* ── Request a pilot: modal, two steps ────────────────── */
[hidden] { display: none !important; }
.sr {
  position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; border: 0;
  overflow: hidden; clip-path: inset(50%); white-space: nowrap;
}

dialog:not([open]) { display: none; }

/* Native <dialog>: the browser makes the page inert, traps focus and handles Escape. Desktop: a centred card. */
.modal {
  width: min(640px, calc(100% - 2 * var(--space-2)));
  max-width: none; max-height: none; margin: auto; padding: 0; border: 0;
  background: transparent; color: var(--ink); overflow: visible;
  opacity: 0; transform: translateY(12px) scale(0.985);
  transition: opacity 150ms ease-in, transform 150ms ease-in;
}
.modal.is-open {
  opacity: 1; transform: none;
  transition: opacity 220ms var(--ease-out), transform 260ms var(--ease-out);
}
.modal::backdrop { background: rgb(7 18 56 / 0.74); opacity: 0; transition: opacity 150ms ease-in; }
.modal.is-open::backdrop { opacity: 1; transition: opacity 220ms var(--ease-out); }

.modal__panel {
  display: flex; flex-direction: column; width: 100%;
  max-height: calc(100vh - 3rem); max-height: calc(100dvh - 3rem);
  background: var(--white); border-radius: var(--radius-3); box-shadow: var(--shadow-panel); overflow: hidden;
}

/* The header and footer never scroll away: only the body scrolls, and only if it has to. */
.modal__head {
  position: relative; flex: none; display: flex; align-items: center; justify-content: space-between; gap: var(--space-2);
  padding: var(--space-2) var(--space-3);
}
.modal__title { font: 600 var(--text-xl)/1.15 var(--font-display); letter-spacing: var(--tracking-heading); }
.modal__step {
  margin-top: 0.25rem; font-size: var(--text-xs); line-height: 1.2; letter-spacing: var(--tracking-label);
  text-transform: uppercase; color: var(--text-on-navy-soft);
}
.modal__step:focus { outline: none; }
.modal__close {
  flex: none; display: grid; place-items: center; width: 2.75rem; height: 2.75rem; padding: 0; cursor: pointer;
  border: 1px solid rgb(255 255 255 / 0.28); border-radius: var(--radius-2); background: transparent; color: var(--white);
  transition: background-color var(--dur-fast);
}
.modal__close:hover { background: rgb(255 255 255 / 0.12); }
.modal__progress { position: absolute; inset: auto 0 0; height: 3px; display: grid; grid-template-columns: 1fr 1fr; gap: 2px; }
.modal__progress i { background: rgb(255 255 255 / 0.14); transition: background-color var(--dur-med) var(--ease-out); }
.modal__progress i.is-on { background: var(--blue-300); }

.modal__body {
  flex: 1 1 auto; min-height: 0; overflow-y: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch;
  padding: var(--space-3) var(--space-3) var(--space-1);
}
.modal__foot {
  flex: none; display: flex; justify-content: flex-end; gap: var(--space-2);
  padding: var(--space-2) var(--space-3); background: var(--paper); border-top: 1px solid var(--rule);
}
.modal__foot .btn { min-width: 9rem; }

.modal__pane { min-width: 0; margin: 0; padding: 0; border: 0; }
.modal .field { margin-bottom: var(--space-2); }
.modal .lead__intro { margin: 0 0 var(--space-3); }
.field-row { display: grid; grid-template-columns: minmax(0, 1fr); column-gap: var(--space-2); }
@media (min-width: 640px) { .field-row { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.modal .field--message textarea { min-height: 0; padding-block: 0.5rem; resize: vertical; }
.modal .field--message { margin-bottom: var(--space-1); }
.modal .field--check { margin-bottom: var(--space-1); }
.modal .field--check label { font-size: var(--text-sm); line-height: 1.4; }
.modal .lead__check { margin-bottom: var(--space-1); }

/* Phones: a full-height sheet. The viewport height follows the on-screen keyboard (js/lead.js sets --vvh). */
@media (max-width: 639px) {
  .modal { width: 100%; height: 100vh; height: var(--vvh, 100dvh); margin: 0; inset: var(--vvt, 0px) auto auto 0; transform: translateY(32px); }
  .modal__panel { height: 100%; max-height: none; border-radius: 0; }
  .modal__head, .modal__body, .modal__foot { padding-inline: var(--space-2); }
  .modal__foot { padding-bottom: max(var(--space-2), env(safe-area-inset-bottom)); }
  .modal__foot .btn { flex: 1 1 0; min-width: 0; }
  .modal__foot .btn--ghost:first-child:not(:last-child) { flex: 0 0 32%; }
}
@media (prefers-reduced-motion: reduce) { .modal, .modal.is-open { transform: none; } }

/* Field parts shared with the old inline form. */
.lead__intro { margin: var(--space-1) 0 var(--space-3); color: var(--ink-soft); }
.lead__title { font: 600 var(--text-xl)/1.2 var(--font-display); letter-spacing: var(--tracking-heading); }
.lead__intro a, .field a { color: var(--blue-600); text-underline-offset: 3px; }
.field { display: flex; flex-direction: column; gap: 0.375rem; margin-bottom: var(--space-3); }
.field label { font: 600 var(--text-sm)/1.3 var(--font-body); color: var(--ink); }
.field__opt { font-weight: 500; color: var(--ink-soft); }
.field input:not([type="checkbox"]), .field select, .field textarea {
  width: 100%; min-height: 3rem; padding: 0.625rem 0.75rem;
  border: 1px solid var(--rule-strong); border-radius: var(--radius-2);
  background: var(--white); color: var(--ink); font: 500 1rem/1.4 var(--font-body);
  transition: border-color var(--dur-fast);
}
.field input:hover, .field select:hover, .field textarea:hover { border-color: var(--ink-soft); }
.field [aria-invalid="true"] { border-color: var(--red-text); box-shadow: inset 0 0 0 1px var(--red-text); }
.field__hint { font-size: var(--text-xs); color: var(--ink-soft); }
.field__err { font: 600 var(--text-sm)/1.35 var(--font-body); color: var(--red-text); }
.field__err::before { content: "Error: "; }
.field--check { display: grid; grid-template-columns: 1.5rem 1fr; column-gap: var(--space-1); align-items: start; }
.field--check input { width: 1.5rem; height: 1.5rem; margin: 0; accent-color: var(--blue-600); }
.field--check label { font-weight: 500; }
.field--check .field__err { grid-column: 2; }
.lead__trap { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.lead__check { min-height: 65px; margin-bottom: var(--space-2); }
@media (max-width: 359px) { .lead__check { min-height: 140px; } }
#e-turnstile { margin: calc(-1 * var(--space-1)) 0 var(--space-1); }
.lead__status { margin: var(--space-1) 0; padding: var(--space-1) var(--space-2); border-left: 3px solid var(--red-text); background: var(--paper); font-weight: 600; }
.btn:disabled { background: var(--ink-faint); cursor: progress; }
.btn--ghost { background: transparent; color: var(--blue-600); border-color: var(--blue-600); }
.btn--ghost:hover { background: rgb(29 63 216 / 0.08); }
.on-navy .btn--ghost { box-shadow: none; color: var(--white); border-color: rgb(255 255 255 / 0.5); }
.on-navy .btn--ghost:hover { background: rgb(255 255 255 / 0.1); }
.lead__done { padding-block: var(--space-2); }
.lead__done:focus { outline: none; }

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

/* ── Header end cluster, coming-soon, legal ───────────── */
.site-header__end { display: flex; align-items: center; gap: var(--space-3); }

.footer__legal { display: flex; flex-wrap: wrap; gap: 0 var(--space-3); }
.footer__legal a { display: inline-block; min-height: 2.5rem; line-height: 2.5rem; text-decoration: none; color: var(--text-on-navy-soft); }
.footer__legal a:hover { color: var(--white); text-decoration: underline; text-underline-offset: 4px; }
@media (min-width: 900px) { .footer__bar { flex-wrap: wrap; } .footer__legal { flex-basis: 100%; justify-content: flex-end; } }

.legal-header { background: var(--navy-900); }
.legal { padding-block: var(--space-8) var(--space-12); }
.legal__inner { grid-column: 1 / -1; max-width: 44rem; }
@media (min-width: 768px) { .legal__inner { grid-column: 2 / 11; } }
.legal h1 { font-size: var(--text-2xl); line-height: 1.04; letter-spacing: var(--tracking-heading); margin-bottom: var(--space-3); }
.legal h2 { font-size: var(--text-xl); letter-spacing: var(--tracking-heading); margin: var(--space-6) 0 var(--space-1); }
.legal p, .legal li { color: var(--ink-soft); margin-bottom: var(--space-2); max-width: 40rem; }
.legal ul { list-style: disc; padding-left: var(--space-3); }
.legal a { color: var(--blue-600); text-underline-offset: 3px; }
.legal__draft { padding: var(--space-2); border: 1px solid var(--ink); border-left-width: 4px; background: var(--white); color: var(--ink); margin-bottom: var(--space-4); }
.legal__draft p { color: var(--ink); margin: 0; }
.legal__meta { font: 400 var(--text-xs)/1.4 var(--font-mono); color: var(--ink-soft); }

/* Very narrow phones (320px) */
@media (max-width: 359px) {
  .brand img { width: 104px; }
  .btn--sm { padding: 0 12px; font-size: 0.8125rem; }
}

/* ── Positioning pass: doubt-led hero, total check, trust rules ── */
.lede--small { margin-top: var(--space-2); font-size: var(--text-base); }
.hero__copy .display { max-width: 10em; font-size: clamp(2.5rem, 1.5rem + 4.4vw, 4.75rem); line-height: 1; }
.hero__copy .lede + .lede { margin-bottom: var(--space-4); }
.hero__copy .lede { margin-bottom: 0; }
.note { margin-top: var(--space-2); padding: var(--space-1) var(--space-2); border-left: 3px solid var(--navy-900); background: var(--white); font-size: var(--text-xs); color: var(--ink); }
.statements__intro .body-lg + .body-lg { margin-top: var(--space-2); }
.before__intro .body-lg { margin-top: var(--space-3); }

.check { border-top: 1px solid var(--ink); background: var(--paper); border-radius: 0 0 var(--radius-2) var(--radius-2); padding: var(--space-1) var(--space-2) var(--space-2); }
.check__row { display: flex; justify-content: space-between; gap: var(--space-2); padding-block: 10px; border-bottom: 1px solid var(--rule); font-size: var(--text-sm); }
.check__row dt { color: var(--ink-soft); }
.check__row dd { font-weight: 600; }
.check__row--gap { border-bottom: 0; padding-bottom: 4px; }
.check__row--gap dt { color: var(--ink); font-weight: 700; }
.check__row--gap dd { font-size: var(--text-lg); color: var(--red-text); }
.check.is-balanced .check__row--gap dd { color: var(--ink); }
.check__ok { margin: 0; font: 600 var(--text-sm)/1.3 var(--font-display); letter-spacing: var(--tracking-heading); visibility: hidden; display: flex; align-items: center; gap: var(--space-1); }
.check__ok::before { content: ""; width: 8px; height: 8px; background: var(--navy-900); border-radius: 1px; }
.check.is-balanced .check__ok { visibility: visible; }
.check__row dd { font-variant-numeric: tabular-nums; }

.section--trust { background: var(--white); border-block: 1px solid var(--rule); }
.trust__intro { grid-column: 1 / -1; margin-bottom: var(--space-6); }
.trust__intro .label { margin-bottom: var(--space-3); }
.trust__intro .h2 { margin-bottom: var(--space-3); }
.rules { grid-column: 1 / -1; border-top: 1px solid var(--ink); }
.rules > div { display: grid; gap: var(--space-1); padding-block: var(--space-3); border-bottom: 1px solid var(--rule); }
.rules dt { font-size: var(--text-xs); letter-spacing: var(--tracking-label); text-transform: uppercase; color: var(--ink-soft); }
.rules dd { color: var(--ink-soft); max-width: 36em; }
.rules strong { display: block; margin-bottom: 4px; font: 600 var(--text-xl)/1.2 var(--font-display); letter-spacing: var(--tracking-heading); color: var(--ink); }
@media (min-width: 768px) {
  .trust__intro { margin-bottom: var(--space-6); display: grid; grid-template-columns: subgrid; align-items: end; }
  .trust__intro .label { grid-column: 1 / -1; }
  .trust__intro .h2 { grid-column: 1 / 8; margin-bottom: 0; }
  .trust__intro .body-lg { grid-column: 8 / -1; }
  .rules > div { grid-template-columns: 8rem minmax(0, 1fr); column-gap: var(--space-3); }
}
@media (min-width: 1100px) {
  .rules { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); grid-auto-flow: dense; column-gap: var(--space-6); border-top: 0; }
  .rules > div { grid-template-columns: 1fr; align-content: start; border-top: 1px solid var(--ink); border-bottom: 0; padding-block: var(--space-3) var(--space-4); }
  .rules > div:nth-child(2) { grid-column: 1 / -1; }
  .rules > div:nth-child(2) dd { max-width: 48em; }
}

.roadmap { margin-top: var(--space-4); display: flex; flex-direction: column; gap: 4px; font-size: var(--text-xs); color: var(--ink-soft); }
.roadmap span { text-transform: uppercase; letter-spacing: var(--tracking-label); color: var(--ink); }
