/* KeepMySubsidy — survey-chart look: cool paper, green ground, chart-magenta limit line. */

:root {
  --paper: #EEF3F0;
  --card: #FBFCFB;
  --ink: #12211D;
  --ink-2: #4A5B55;
  --rule: #C6D2CC;
  --field: #7C8E87;
  --land: #2F6B58;
  --land-deep: #1B4638;
  --land-soft: #D7E5DC;
  --sea: #DCE7EC;
  --limit: #B3215F;
  --limit-soft: #F7DEE8;
  --amber: #855600;
  --amber-soft: #F4E6C3;
  --display: "Barlow Condensed", "Arial Narrow", "Helvetica Neue", Arial, sans-serif;
  --body: "Public Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --radius: 4px;
}

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

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 400 16px/1.5 var(--body);
  font-variant-numeric: tabular-nums;
}

h1, h2, h3, p, dl, dd, ul, fieldset, legend { margin: 0; padding: 0; }
fieldset { border: 0; min-width: 0; }
ul { list-style: none; }
[hidden] { display: none !important; }

.sr {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip-path: inset(50%); white-space: nowrap;
}

.wrap { max-width: 1160px; margin: 0 auto; padding: 0 24px; }

:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }

/* ---------- Top bar ---------- */

.top { border-bottom: 1px solid var(--rule); }
.top__row { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 60px; }
.top__tools { display: flex; align-items: center; gap: 18px; }

.brand {
  display: inline-flex; align-items: center; gap: 10px;
  font: 600 24px/1 var(--display); letter-spacing: 0.01em; text-transform: uppercase;
  color: var(--ink); text-decoration: none;
}
.brand__mark { width: 32px; height: 20px; }
.brand__mark path { fill: var(--land); }
.brand__mark .brand__limit { fill: none; stroke: var(--limit); stroke-width: 2.5; stroke-dasharray: 3 3; }

.link {
  appearance: none; border: 0; background: none; padding: 0; cursor: pointer;
  font: inherit; color: inherit; text-decoration: underline; text-underline-offset: 3px;
}
.link:hover { color: var(--land); }

/* ---------- Layout ---------- */

.grid {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: 56px;
  align-items: start;
}
.stand { padding-top: 44px; }
.moves { padding-top: 56px; margin-top: 56px; border-top: 1px solid var(--rule); }

h1 {
  font: 600 clamp(36px, 4.4vw, 54px)/1.02 var(--display);
  letter-spacing: -0.005em;
  text-wrap: balance;
}
.lede { margin-top: 18px; color: var(--ink-2); font-size: 17px; max-width: 46ch; }
.private {
  margin-top: 14px; font: 400 12.5px/1.4 var(--mono); letter-spacing: 0.02em; color: var(--ink-2);
}
.need { margin-top: 22px; font-size: 15px; line-height: 1.45; max-width: 46ch; }
.example {
  margin-top: 28px; padding: 10px 14px;
  background: var(--amber-soft); color: var(--ink); border-left: 3px solid var(--amber);
  font-size: 14.5px;
}

/* ---------- Form ---------- */

form { margin-top: 12px; }
.moves form { margin-top: 0; }

.group { margin-top: 36px; display: grid; gap: 18px; }
.moves .group { margin-top: 0; }
.group > legend {
  display: flex; align-items: center; gap: 12px; width: 100%;
  font: 600 17px/1 var(--display); letter-spacing: 0.09em; text-transform: uppercase;
  padding-bottom: 18px;
}
.group > legend::after { content: ""; flex: 1; height: 1px; background: var(--rule); }

.sub {
  margin-top: 10px;
  font: 600 14px/1.2 var(--body); color: var(--ink);
  padding-top: 16px; border-top: 1px dashed var(--rule);
}

.stack { display: grid; gap: 18px; }
.row { display: flex; gap: 16px; align-items: end; }
.row > .field { flex: 1; }
.row > .field--narrow { flex: 0 0 148px; }

.field { display: grid; gap: 6px; }
.field__label { font-weight: 600; font-size: 14.5px; }
.field__label i { font-style: normal; font-weight: 400; color: var(--ink-2); }
.field__hint { font-size: 13.5px; line-height: 1.4; color: var(--ink-2); }

input[type="text"], input:not([type]), select {
  width: 100%; height: 48px; padding: 0 14px;
  border: 1.5px solid var(--field); border-radius: var(--radius);
  background: var(--card); color: var(--ink);
  font: 500 17px/1 var(--body); font-variant-numeric: tabular-nums;
}
select { appearance: none; padding-right: 38px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5 6 6.5 11 1.5' fill='none' stroke='%2312211D' stroke-width='1.8'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 14px center; background-size: 12px 8px;
}
input:hover, select:hover { border-color: var(--ink); }
input::placeholder { color: #93A29C; }

.money { position: relative; display: block; }
.money::before {
  content: "$"; position: absolute; left: 14px; top: 0; line-height: 48px;
  font-weight: 500; font-size: 17px; color: var(--ink-2); pointer-events: none;
}
.money input { padding-left: 28px; }

/* Segmented choice */
.seg { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); position: relative; }
.seg > legend { padding-bottom: 6px; }
.seg label { min-width: 0; position: relative; display: flex; }
.seg label span {
  display: flex; align-items: center; justify-content: center; text-align: center;
  flex: 1; min-height: 44px; padding: 8px 10px;
  border: 1.5px solid var(--ink); margin-left: -1.5px;
  font-weight: 500; font-size: 14.5px; line-height: 1.2; cursor: pointer; background: var(--card);
}
.seg label:first-of-type span { margin-left: 0; border-radius: var(--radius) 0 0 var(--radius); }
.seg label:last-of-type span { border-radius: 0 var(--radius) var(--radius) 0; }
.seg input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.seg input:checked + span { background: var(--ink); color: var(--paper); }
.seg input:focus-visible + span { outline: 2px solid var(--ink); outline-offset: 2px; z-index: 1; position: relative; }
.seg--small label span { min-height: 34px; padding: 4px 14px; font: 500 13px/1 var(--mono); }

/* Checkbox row */
label.check {
  display: grid; grid-template-columns: 22px 1fr; gap: 12px; align-items: start;
  cursor: pointer; font-weight: 500; font-size: 15px; padding: 0;
}
label.check input {
  appearance: none; width: 22px; height: 22px; margin: 1px 0 0;
  border: 1.5px solid var(--ink); border-radius: 3px; background: var(--card); cursor: pointer;
}
label.check input:checked {
  background: var(--ink) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 14 12'%3E%3Cpath d='M1.5 6.5 5 10l7.5-8.5' fill='none' stroke='%23EEF3F0' stroke-width='2'/%3E%3C/svg%3E") center / 13px no-repeat;
}
label.check small { display: block; font-weight: 400; font-size: 13.5px; line-height: 1.4; color: var(--ink-2); margin-top: 2px; }

.readout {
  padding: 10px 14px; background: var(--land-soft); border-left: 3px solid var(--land);
  font-size: 14.5px;
}
.readout:empty { display: none; }
.readout b { font-weight: 700; }

/* ---------- Position card ---------- */

.card {
  background: var(--card); border: 1px solid var(--rule); border-radius: var(--radius);
  padding: 28px;
}

.tag {
  display: inline-block; padding: 5px 9px 4px;
  font: 500 11.5px/1 var(--mono); letter-spacing: 0.08em; text-transform: uppercase;
  background: var(--land-soft); color: var(--land-deep);
}
[data-tone="over"] .tag { background: var(--limit-soft); color: var(--limit); }
[data-tone="edge"] .tag, [data-tone="low"] .tag { background: var(--amber-soft); color: var(--amber); }
[data-tone="idle"] .tag { background: var(--paper); color: var(--ink-2); }

.verdict {
  margin-top: 12px;
  font: 600 clamp(32px, 3.6vw, 44px)/1.04 var(--display);
  text-wrap: balance;
}
[data-tone="over"] .verdict { color: var(--limit); }
.verdict__text { margin-top: 10px; color: var(--ink); max-width: 56ch; }

.profile { position: relative; margin-top: 22px; overflow: hidden; }
.profile svg { display: block; width: 100%; height: auto; }
.profile__caption { margin-top: 6px; font-size: 13px; color: var(--ink-2); }
.profile__caption:empty { display: none; }

.pf-sea { fill: var(--sea); }
.pf-land { fill: var(--land); }
.pf-top { fill: none; stroke: var(--land-deep); stroke-width: 2; stroke-linejoin: round; }
.pf-face { stroke: var(--ink); stroke-width: 3; }
.pf-base { stroke: var(--ink); stroke-width: 1.5; }
.pf-limit { stroke: var(--limit); stroke-width: 1.5; stroke-dasharray: 5 4; }
.pf-tick { stroke: var(--ink); stroke-width: 1; }
.pf-label { font: 500 11px var(--mono); letter-spacing: 0.06em; text-transform: uppercase; fill: var(--ink-2); }
.pf-label--limit { fill: var(--limit); }
.pf-label--land { fill: #EAF3EE; }
.pf-label--axis { fill: var(--ink); }
.pf-dim { stroke: var(--ink-2); stroke-width: 1; fill: none; }

.pin {
  position: absolute; left: 0; top: 0; width: 0; height: 0;
  transition: left 420ms cubic-bezier(0.2, 0.7, 0.2, 1), top 420ms cubic-bezier(0.2, 0.7, 0.2, 1);
  --stem: 26px; --pin: var(--ink);
}
.pin--after { --stem: 54px; --pin: var(--land-deep); }
.pin--you[data-tone="over"] { --pin: var(--limit); }
.pin__dot {
  position: absolute; left: -6px; top: -6px; width: 12px; height: 12px; border-radius: 50%;
  background: var(--pin); border: 2px solid var(--card);
}
.pin--after .pin__dot { background: var(--card); border-color: var(--pin); }
.pin__stem { position: absolute; left: -1px; bottom: 5px; width: 2px; height: var(--stem); background: var(--pin); }
.pin__flag {
  position: absolute; bottom: calc(var(--stem) + 5px); left: 0; transform: translateX(-50%);
  padding: 4px 7px 3px; white-space: nowrap;
  font: 500 11px/1 var(--mono); letter-spacing: 0.07em; text-transform: uppercase;
  background: var(--pin); color: var(--card);
}
.pin--after .pin__flag { background: var(--card); color: var(--pin); border: 1.5px solid var(--pin); }
.pin[data-side="left"] .pin__flag { transform: translateX(-12px); }
.pin[data-side="right"] .pin__flag { transform: translateX(calc(-100% + 12px)); }

.stats {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 18px; border-top: 1px solid var(--rule);
}
.stats div { padding: 14px 14px 0 0; }
.stats div + div { padding-left: 14px; border-left: 1px solid var(--rule); }
.stats dt { font: 500 11px/1.3 var(--mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-2); }
.stats dd { margin-top: 4px; font-weight: 700; font-size: 21px; line-height: 1.2; }
.stats dd small { display: block; font-weight: 400; font-size: 13px; color: var(--ink-2); }

.settle { margin-top: 20px; }
.settle:empty { display: none; }
.settle__row { display: flex; justify-content: space-between; gap: 16px; padding: 7px 0; font-size: 15px; }
.settle__row--total {
  margin-top: 4px; padding-top: 12px; border-top: 1.5px solid var(--ink);
  font-weight: 700; font-size: 17px;
}
.settle__row--owe span:last-child { color: var(--limit); }
.settle__row--back span:last-child { color: var(--land); }
.settle__foot { margin-top: 4px; font-size: 13px; color: var(--ink-2); }

.notes { margin-top: 18px; display: grid; gap: 8px; }
.notes:empty { display: none; }
.notes li { padding: 10px 14px; background: var(--paper); border-left: 3px solid var(--field); font-size: 14px; line-height: 1.45; }
.notes li[data-kind="warn"] { background: var(--amber-soft); border-color: var(--amber); }

/* ---------- Moves ---------- */

.plan__title { font: 600 clamp(28px, 3vw, 36px)/1.05 var(--display); }
.plan__intro { margin-top: 8px; max-width: 58ch; }

.movegroup { margin-top: 26px; }
.movegroup__head {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 12px;
  padding-bottom: 8px; border-bottom: 1.5px solid var(--ink);
}
.movegroup__date { font: 600 19px/1 var(--display); letter-spacing: 0.06em; text-transform: uppercase; }
.movegroup__left { font: 500 11.5px/1 var(--mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--limit); }
.movegroup__why { flex-basis: 100%; font-size: 13.5px; color: var(--ink-2); }

.move {
  display: grid; grid-template-columns: 22px minmax(0, 1fr) auto; gap: 14px; align-items: start;
  padding: 14px 0; border-bottom: 1px solid var(--rule); cursor: pointer;
}
.move input {
  appearance: none; width: 22px; height: 22px; margin: 1px 0 0;
  border: 1.5px solid var(--ink); border-radius: 3px; background: var(--card); cursor: pointer;
}
.move input:checked {
  background: var(--ink) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 14 12'%3E%3Cpath d='M1.5 6.5 5 10l7.5-8.5' fill='none' stroke='%23EEF3F0' stroke-width='2'/%3E%3C/svg%3E") center / 13px no-repeat;
}
.move__title { font-weight: 600; }
.move__how { font-size: 13.5px; line-height: 1.4; color: var(--ink-2); margin-top: 2px; }
.move__amt { text-align: right; white-space: nowrap; }
.move__amt b { display: block; font-weight: 700; font-size: 18px; line-height: 1.2; }
.move__amt small { font-size: 13px; color: var(--ink-2); }
.move[data-off="true"] .move__title, .move[data-off="true"] .move__amt b { color: var(--ink-2); text-decoration: line-through; }
.move[data-idle="true"] .move__amt b { font-weight: 500; color: var(--ink-2); }

.empty { margin-top: 22px; padding: 16px; background: var(--paper); border-left: 3px solid var(--field); font-size: 15px; }

.summary { margin-top: 24px; padding: 16px 18px; background: var(--land-soft); border-left: 3px solid var(--land); }
.summary:empty { display: none; }
.summary[data-tone="short"] { background: var(--limit-soft); border-color: var(--limit); }
.summary p + p { margin-top: 8px; }
.summary b { font-weight: 700; }

.btn {
  appearance: none; margin-top: 22px; min-height: 48px; padding: 0 22px; cursor: pointer;
  border: 1.5px solid var(--ink); border-radius: var(--radius); background: var(--ink); color: var(--paper);
  font: 600 15px/1 var(--body);
}
.btn:hover { background: var(--land-deep); border-color: var(--land-deep); }
.btn[disabled] { opacity: 0.6; cursor: progress; }
.btn--quiet { background: transparent; color: var(--ink); }
.btn--quiet:hover { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.btn--buy { width: 100%; min-height: 56px; font-size: 17px; background: var(--land); border-color: var(--land); }

/* ---------- Paid plan ---------- */

/* The caution that travels with every result, on screen and on the printed plan. */
.estimate { margin-top: 18px; padding-top: 12px; border-top: 1px solid var(--rule); font-size: 13px; line-height: 1.45; color: var(--ink-2); max-width: 64ch; }
.foot a { color: inherit; text-underline-offset: 3px; }

.plan__title:focus { outline: none; }
.plan__access {
  margin-top: 16px; padding: 10px 14px; font-size: 14.5px;
  background: var(--land-soft); border-left: 3px solid var(--land);
}
.plan__access b { font: 500 14px/1 var(--mono); letter-spacing: 0.02em; white-space: nowrap; }

/* A locked move: its place in the list is real, its name and amount are not in the page. */
.move--locked { cursor: default; align-items: center; }
.redact {
  display: block; height: 13px; border-radius: 2px;
  background: repeating-linear-gradient(114deg, var(--rule) 0 5px, #DDE6E1 5px 10px);
}
.redact--box { width: 22px; height: 22px; background: none; border: 1.5px solid var(--rule); border-radius: 3px; }
.redact--thin { height: 9px; margin-top: 9px; opacity: 0.7; }
.redact--amt { width: 86px; height: 18px; margin-left: auto; }

.offer { margin-top: 26px; padding-top: 22px; border-top: 1.5px solid var(--ink); }
.offer__test {
  display: inline-block; margin-bottom: 14px; padding: 6px 10px;
  background: var(--amber-soft); border-left: 3px solid var(--amber);
  font: 500 11.5px/1.35 var(--mono); letter-spacing: 0.05em; text-transform: uppercase;
}
.offer__title { font: 600 22px/1.1 var(--display); letter-spacing: 0.05em; text-transform: uppercase; }
.offer__gets { margin-top: 12px; list-style: none; display: grid; gap: 7px; font-size: 15px; }
.offer__gets li { position: relative; padding-left: 22px; }
.offer__gets li::before { content: ""; position: absolute; left: 0; top: 0.62em; width: 12px; height: 2px; background: var(--land); }
.offer__lead { margin-top: 10px; font-size: 15px; max-width: 60ch; }
.offer__terms { margin-top: 12px; font-size: 13.5px; color: var(--ink-2); }
.offer__terms a { color: inherit; text-underline-offset: 3px; }
.offer__terms a:hover { color: var(--land); }
.offer__msg { margin-top: 10px; font-size: 14px; color: var(--limit); }
.offer__msg:empty { display: none; }
.restore { margin-top: 18px; padding: 14px 0 0; border-top: 1px solid var(--rule); border-bottom: 0; }
.restore summary { font-weight: 500; font-size: 14.5px; }
.restore form { margin-top: 14px; }
.restore .btn { margin-top: 12px; }

.paydemo {
  width: min(440px, calc(100vw - 32px)); padding: 28px;
  border: 1.5px solid var(--ink); border-radius: var(--radius);
  background: var(--card); color: var(--ink);
}
.paydemo::backdrop { background: rgba(18, 33, 29, 0.55); }
.paydemo__tag {
  display: inline-block; padding: 6px 10px; background: var(--amber-soft); border-left: 3px solid var(--amber);
  font: 500 11.5px/1.35 var(--mono); letter-spacing: 0.05em; text-transform: uppercase;
}
.paydemo h2 { margin-top: 14px; font: 600 28px/1.05 var(--display); }
.paydemo p { margin-top: 10px; }
.paydemo .paydemo__line {
  display: flex; justify-content: space-between; align-items: baseline; margin-top: 18px; padding: 12px 0;
  border-top: 1.5px solid var(--ink); border-bottom: 1px solid var(--rule);
}
.paydemo__line b { font-size: 20px; }
.paydemo__actions { display: flex; flex-wrap: wrap; gap: 0 10px; }

/* ---------- Explain ---------- */

.explain { margin-top: 72px; padding-top: 44px; border-top: 1px solid var(--rule); }
.explain h2 { font: 600 30px/1.1 var(--display); }
.explain__cols { margin-top: 18px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 56px; }
details { border-bottom: 1px solid var(--rule); padding: 14px 0; }
summary { cursor: pointer; font-weight: 600; list-style: none; display: flex; justify-content: space-between; gap: 12px; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; font: 400 20px/1 var(--mono); color: var(--ink-2); }
details[open] summary::after { content: "–"; }
details p { margin-top: 8px; color: var(--ink-2); font-size: 15px; max-width: 60ch; }
.sources { margin-top: 22px; font-size: 13.5px; color: var(--ink-2); }
.sources a { color: inherit; text-underline-offset: 3px; }
.sources a:hover { color: var(--land); }

.foot { margin-top: 56px; padding: 24px 0 96px; border-top: 1px solid var(--rule); font-size: 13.5px; color: var(--ink-2); }
.foot__nav { margin-top: 12px; display: flex; flex-wrap: wrap; gap: 6px 20px; }
.foot__nav a { color: inherit; text-underline-offset: 3px; }
.foot__nav a:hover { color: var(--land); }
.noscript { padding: 16px 24px; background: var(--amber-soft); }

/* ---------- Terms, privacy, refunds ---------- */

.legal { max-width: 760px; padding-top: 44px; }
.legal h1 { font: 600 clamp(36px, 6vw, 52px)/1 var(--display); max-width: none; }
.legal__updated { margin-top: 12px; font: 400 12.5px/1.4 var(--mono); letter-spacing: 0.02em; color: var(--ink-2); }
.legal__lead { margin-top: 18px; font-size: 17px; color: var(--ink-2); }
.legal h2 { margin-top: 36px; padding-bottom: 8px; border-bottom: 1.5px solid var(--ink); font: 600 21px/1.1 var(--display); letter-spacing: 0.06em; text-transform: uppercase; }
.legal p { margin-top: 12px; max-width: 68ch; }
.legal ul { margin-top: 12px; padding-left: 20px; max-width: 68ch; }
.legal ul li { list-style: disc; }
.legal .guide__sources li, .legal .guide__more li, .legal .guide__index li, .legal .foot__nav li { list-style: none; }
.legal li + li { margin-top: 6px; }
.legal a { color: inherit; text-underline-offset: 3px; }
.legal a:hover { color: var(--land); }
.legal mark { padding: 1px 5px; background: var(--amber-soft); color: var(--ink); }
.foot--page { padding-bottom: 40px; }
.legal a.btn { display: inline-flex; align-items: center; margin-top: 10px; color: var(--paper); text-decoration: none; }

/* ---------- Mobile status bar ---------- */

.dock { display: none; }

/* ---------- Wide screens: keep the position in view while typing ---------- */

/* ---------- Guides ---------- */

.guide__crumb { margin-bottom: 14px; font: 500 12px/1 var(--mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-2); }
.guide ol { margin-top: 12px; padding-left: 22px; max-width: 68ch; }
.guide ol li + li { margin-top: 6px; }
.guide__table { margin-top: 16px; overflow-x: auto; border: 1px solid var(--rule); border-radius: var(--radius); background: var(--card); }
.guide__table table { width: 100%; min-width: 540px; border-collapse: collapse; font-size: 15px; font-variant-numeric: tabular-nums; }
.guide__table caption { padding: 12px 14px; text-align: left; font: 600 17px/1.2 var(--display); letter-spacing: 0.05em; text-transform: uppercase; border-bottom: 1.5px solid var(--ink); }
.guide__table th, .guide__table td { padding: 9px 14px; text-align: right; border-bottom: 1px solid var(--rule); white-space: nowrap; font-weight: 400; }
.guide__table thead th { font: 500 11.5px/1.3 var(--mono); letter-spacing: 0.05em; text-transform: uppercase; color: var(--ink-2); white-space: normal; }
.guide__table thead th[colspan] { text-align: center; color: var(--ink); border-left: 1px solid var(--rule); }
.guide__table th[scope="row"], .guide__table thead th:first-child { text-align: left; }
.guide__table tbody th { font-weight: 600; }
.guide__table tbody tr:last-child th, .guide__table tbody tr:last-child td { border-bottom: 0; }
.guide__table td b { font-weight: 700; }
.legal .guide__small, .legal .guide__note { font-size: 13.5px; color: var(--ink-2); }
.guide__swipe { display: none; }
.guide__cta { margin-top: 44px; padding: 22px 24px 26px; background: var(--land-soft); border-left: 3px solid var(--land); }
.legal .guide__cta h2 { margin-top: 0; padding: 0; border: 0; font: 600 28px/1.08 var(--display); letter-spacing: 0; text-transform: none; }
.legal .guide__sources, .legal .guide__more, .legal .guide__index { padding-left: 0; list-style: none; max-width: none; }
.guide__sources li, .guide__index li { padding: 12px 0; border-bottom: 1px solid var(--rule); }
.legal .guide__sources li + li, .legal .guide__index li + li { margin-top: 0; }
.guide__sources a { font-weight: 600; }
.guide__sources span, .guide__index span { display: block; margin-top: 2px; font-size: 13.5px; color: var(--ink-2); }
.guide__index a { font: 600 24px/1.15 var(--display); text-decoration: none; }
.guide__index a:hover { text-decoration: underline; text-underline-offset: 4px; }
.guides { margin-top: 26px; }
.guides h3 { font: 600 19px/1 var(--display); letter-spacing: 0.06em; text-transform: uppercase; }
.guides ul { margin-top: 10px; padding: 0; list-style: none; display: grid; gap: 6px; font-size: 15px; }
.guides a { color: inherit; text-underline-offset: 3px; }
.guides a:hover { color: var(--land); }

@media (min-width: 941px) and (min-height: 780px) {
  .position, .plan { position: sticky; top: 16px; }
}

@media (max-width: 940px) {
  .grid { grid-template-columns: minmax(0, 1fr); gap: 36px; }
  .stand { padding-top: 28px; }
  .moves { padding-top: 40px; margin-top: 40px; }
  .explain__cols { grid-template-columns: minmax(0, 1fr); }
  .dock {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 5;
    display: flex; align-items: center; gap: 10px;
    padding: 12px 16px calc(12px + env(safe-area-inset-bottom));
    background: var(--ink); color: var(--paper); text-decoration: none; font-weight: 600; font-size: 15px;
  }
  .dock__dot { width: 10px; height: 10px; border-radius: 50%; background: #7FD1AE; flex: none; }
  .dock[data-tone="over"] .dock__dot { background: #FF7DB0; }
  .dock[data-tone="edge"] .dock__dot, .dock[data-tone="low"] .dock__dot { background: #F2C14E; }
  .dock[data-tone="idle"] .dock__dot { background: #93A29C; }
  .dock__go { margin-left: auto; font: 500 11.5px/1 var(--mono); letter-spacing: 0.06em; text-transform: uppercase; text-decoration: underline; text-underline-offset: 3px; }
}

@media (max-width: 560px) {
  .wrap { padding: 0 16px; }
  .card { padding: 20px 16px; }
  .row { flex-wrap: wrap; }
  .row > .field--narrow { flex: 1 1 120px; }
  .seg { grid-auto-flow: row; }
  .seg label span { margin-left: 0; margin-top: -1.5px; border-radius: 0 !important; }
  .seg label:first-of-type span { margin-top: 0; }
  .seg--small { grid-auto-flow: column; }
  .seg--small label span { margin-top: 0; margin-left: -1.5px; padding: 4px 8px; }
  .seg--small label:first-of-type span { margin-left: 0; }
  .stats { grid-template-columns: minmax(0, 1fr); }
  .stats div, .stats div + div { padding: 12px 0; border-left: 0; border-bottom: 1px solid var(--rule); display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
  .stats dd { text-align: right; font-size: 19px; margin-top: 0; }
  .move { grid-template-columns: 22px minmax(0, 1fr); }
  .move__amt { grid-column: 2; text-align: left; }
  .move__amt b { display: inline; margin-right: 6px; }
  /* The name is long for a phone: shrink it, and let the tools drop to a second row when they don't fit. */
  .top__row { flex-wrap: wrap; gap: 2px 12px; padding-top: 6px; padding-bottom: 6px; }
  .top__tools { flex: 1 0 auto; justify-content: space-between; gap: 12px; }
  /* Wide tables scroll inside their box; say so. A four-column table is squeezed to fit instead. */
  .legal .guide__swipe { display: block; margin-top: 16px; font: 500 11.5px/1.3 var(--mono); letter-spacing: 0.05em; text-transform: uppercase; color: var(--ink-2); }
  .guide__swipe + .guide__table { margin-top: 8px; }
  .guide__table--fit table { min-width: 0; font-size: 14px; }
  .guide__table--fit th, .guide__table--fit td { padding: 9px 8px; white-space: normal; }
  .brand { font-size: 20px; gap: 8px; }
  .brand__mark { width: 26px; height: 16px; }
  #start-over { white-space: nowrap; font-size: 14px; padding: 12px 0; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .pin { transition: none; }
}

@media print {
  body { background: #fff; }
  .top__tools, .dock, .btn, .example, .private, .need, .explain, .offer, .plan__access, .foot__nav, #form-check, #form-options, .lede { display: none !important; }
  .grid { grid-template-columns: 1fr; gap: 16px; }
  .moves { border: 0; margin-top: 16px; padding-top: 0; }
  .position, .plan { position: static; }
  .card { border: 0; padding: 0; }
  h1 { font-size: 24px; }
  .foot { padding-bottom: 0; }
}
