/* Finance Planner UI · September 2026. All fonts and assets are served locally. */
@font-face {
  font-family: 'Quicksand';
  src: url("fonts/quicksand-variable.0539b1674ac7.ttf") format('truetype');
  font-weight: 300 700;
  font-style: normal;
  font-display: swap;
}
:root {
  --accent: #00BFFF;
  --brand: #006c95;
  --ink: #17344b;
  --muted: #536c80;
  --paper: #f5f9fc;
  --pale: #e8f8ff;
  --line: #dce7ef;
  --white: #fff;
  --shadow: 0 4px 24px #103a5305;
  --danger: #ab343e;
}
* { box-sizing: border-box; }
body { margin: 0; color: var(--ink); background: var(--paper); font: 500 15px/1.65 'Quicksand', system-ui, sans-serif; }
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }
button, input, select { font: inherit; }
button, a, input, select, summary { outline-offset: 4px; }
:focus-visible { outline: 3px solid #006c95; }
h1, h2, h3, p { margin-top: 0; }
h1 { font-size: clamp(27px, 2.8vw, 36px); line-height: 1.25; letter-spacing: -.9px; margin-bottom: 12px; font-weight: 700; }
h2 { font-size: 21px; line-height: 1.4; letter-spacing: -.35px; margin-bottom: 12px; }
h3 { font-size: 16px; margin-bottom: 8px; }
p { margin-bottom: 14px; }
small, .small { font-size: 12px; }
.block { display: block; }
.muted { color: var(--muted); }
.green { color: var(--brand); }
.center { text-align: center; }
.icon { display: block; flex: 0 0 auto; }
.shell { display: grid; grid-template-columns: 238px minmax(0, 1fr); min-height: 100vh; }
.sidebar { background: white; border-right: 1px solid var(--line); padding: 30px 20px; display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh; }
.brand { display: flex; align-items: center; gap: 11px; color: var(--ink); font-size: 19px; font-weight: 600; line-height: 1.3; letter-spacing: -.6px; }
.brand:hover { text-decoration: none; }
.sidebar .brand strong { display: block; }
.brand-icon { width: 42px; height: 42px; border-radius: 13px; background: var(--accent); color: #073348; display: grid; place-items: center; flex: 0 0 auto; }
.brand-icon .icon { width: 27px; height: 27px; stroke-width: 2; }
.brand-name {
  display: inline-flex;
  gap: 0;
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -1px;
  white-space: nowrap;
}

.brand-pill {
  color: #17344B;
}

.brand-ai {
  color: #00BFFF;
}
.nav-caption { font-size: 10px; color: #62798b; letter-spacing: 1.15px; font-weight: 700; margin: 38px 12px 13px; }
.sidebar nav { display: grid; gap: 5px; }
.sidebar nav .nav-caption { margin-top: 24px; margin-bottom: 8px; font-size: 9px; }
.sidebar nav a { display: flex; align-items: center; gap: 12px; color: var(--muted); padding: 12px 11px; border-radius: 9px; font-size: 13px; font-weight: 600; }
.sidebar nav a[aria-current] { color: #005d81; background: var(--pale); box-shadow: inset 3px 0 var(--accent); }
.sidebar nav a:hover { background: var(--pale); text-decoration: none; }
.sidebar-bottom { margin-top: auto; padding: 25px 11px 0; }
.privacy-note, .saved-label { display: flex; gap: 7px; align-items: center; color: var(--muted); font-size: 11px; }
.privacy-note .icon, .saved-label .icon { width: 15px; height: 15px; }
.logout { border: 0; background: none; color: var(--muted); cursor: pointer; font-size: 13px; padding: 10px 0; min-height: 44px; font-weight: 600; }
.logout:hover { color: var(--brand); text-decoration: underline; }
.mobile-navigation { display: none; }
.workspace { min-width: 0; }
.topbar { height: 72px; padding: 0 36px; background: #ffffffb3; border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; font-size: 12px; color: var(--muted); }
.currency-badge { background: var(--pale); color: var(--brand); padding: 5px 12px; border-radius: 7px; font-weight: 700; }
.main { max-width: 1480px; margin: auto; padding: 36px 36px 20px; }
.page-heading { margin-bottom: 28px; }
.page-heading p { margin: 0; color: var(--muted); }
.eyebrow { display: block; font-size: 10px; font-weight: 700; letter-spacing: 1.4px; color: var(--brand); margin-bottom: 12px; }
.split { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.split > div { min-width: 0; }
.card { background: white; border: 1px solid var(--line); border-radius: 16px; padding: 26px; box-shadow: var(--shadow); min-width: 0; }
.stats-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.stat { display: flex; flex-direction: column; gap: 10px; padding: 22px; }
.stat > span { font-size: 12px; color: var(--muted); }
.stat > strong { font-size: clamp(19px, 1.8vw, 26px); letter-spacing: -.7px; overflow-wrap: anywhere; }
.stat a, .stat small { font-size: 11px; color: var(--muted); }
.stat.accent { background: var(--pale); border-color: #b3eaff; }
.hero { display: flex; justify-content: space-between; align-items: center; gap: 28px; padding: 34px; background: linear-gradient(110deg, #e4f8ff, #f5fcff); border-color: #b3eaff; }
.hero h2 { font-size: clamp(30px, 3vw, 43px); letter-spacing: -1px; overflow-wrap: anywhere; }
.hero-side { min-width: 210px; padding-left: 30px; border-left: 1px solid #bcdeee; display: flex; flex-direction: column; gap: 6px; }
.hero-side > strong { font-size: 24px; letter-spacing: -.6px; }
.hero-side > small { color: var(--muted); margin-bottom: 8px; }
.hero-badges { display: flex; flex-wrap: wrap; gap: 10px; margin: 18px 0 25px; font-size: 12px; }
.hero-badges span { border: 1px solid #c9e5f1; background: #ffffffc9; padding: 6px 12px; border-radius: 7px; }
.two-grid, .allocation-grid, .record-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; }
.three-grid, .plan-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.section-space { margin-top: 26px; }
.button { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 46px; border: 1px solid var(--accent); border-radius: 10px; padding: 11px 20px; background: var(--accent); color: #083448; font-size: 14px; font-weight: 700; cursor: pointer; text-align: center; }
.button:hover { background: #38ccff; border-color: #38ccff; text-decoration: none; }
.button.secondary { background: white; color: var(--brand); border-color: #bcd5e3; }
.button.secondary:hover { background: var(--pale); }
.button.danger { background: var(--danger); border-color: var(--danger); color: white; }
.full { width: 100%; }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 18px; }
.record .actions { border-top: 1px solid var(--line); padding-top: 12px; margin-top: 16px; font-size: 13px; }
.record .actions a { padding: 7px 0; }
.record h2 { overflow-wrap: anywhere; }
.delete-link { color: var(--danger); }
.stat-number { font-size: 27px; font-weight: 700; letter-spacing: -.7px; margin: 17px 0; overflow-wrap: anywhere; }
.records-total { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px; background: var(--pale); border: 1px solid #c1ebfb; border-radius: 12px; padding: 18px 24px; margin-bottom: 24px; }
.records-total span { font-size: 13px; }
.records-total strong { font-size: 24px; }
.pill { display: inline-block; border-radius: 7px; background: var(--pale); color: #006083; padding: 4px 10px; font-size: 11px; font-weight: 700; }
dl { margin: 12px 0; }
dl > div { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; padding: 13px 0; border-bottom: 1px solid #e6eef3; }
dt { font-size: 13px; color: var(--muted); }
dd { margin: 0; font-size: 13px; font-weight: 700; text-align: right; overflow-wrap: anywhere; }
dl > div.total { border-bottom: 0; }
dl .total dt, dl .total dd { font-size: 15px; color: var(--ink); font-weight: 700; }
.notice { background: #edf8fd; border: 1px solid #c8e8f4; border-radius: 10px; padding: 16px 20px; font-size: 13px; margin-bottom: 20px; }
.notice h2 { font-size: 19px; }
.notice p:last-child { margin-bottom: 0; }
.notice.warning { background: #fff8ea; color: #794d16; border-color: #efdcad; }
.notice.subtle { background: transparent; color: var(--muted); padding: 10px 15px; }
.notice.success { background: #ebf8ff; border-color: #b4e4f7; }
.plan-card { display: flex; flex-direction: column; padding: 24px; }
.plan-card h2 { font-size: 18px; min-height: 50px; margin-top: 10px; }
.plan-card .eyebrow { margin: 0; }
.plan-card > .split { min-height: 28px; }
.plan-card.chosen { border: 2px solid var(--accent); padding: 23px; box-shadow: 0 5px 25px #00bfff0b; }
.plan-card .plan-date { font-size: 26px; letter-spacing: -.8px; font-weight: 700; line-height: 1.3; margin-bottom: 3px; }
.plan-card > .muted { font-size: 11px; }
.plan-card dl div { flex-direction: column; gap: 3px; }
.plan-card dd { font-size: 16px; text-align: left; }
.plan-card .help { margin-top: auto; padding-top: 12px; }
.plan-card form { margin-top: 16px; }
.plan-note { background: var(--pale); border-radius: 12px; padding: 26px; align-self: start; }
.plan-note p { font-size: 13px; }
.table-wrap { padding: 0; overflow-x: auto; }
.table-scroll { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
caption { text-align: left; font-size: 19px; font-weight: 700; padding: 24px 26px; }
th, td { text-align: left; padding: 16px 20px; border-bottom: 1px solid var(--line); vertical-align: middle; }
thead, tfoot { background: #f3f9fc; }
thead th { font-size: 11px; color: var(--muted); font-weight: 700; }
td { white-space: nowrap; font-variant-numeric: tabular-nums; }
tbody th { font-weight: 600; min-width: 140px; }
tfoot th, tfoot td { font-weight: 700; border-bottom: 0; }
progress { width: 100%; height: 8px; display: block; border: 0; border-radius: 20px; background: #e2edf3; margin: 16px 0; }
progress::-webkit-progress-bar { background: #e2edf3; border-radius: 20px; }
progress::-webkit-progress-value { background: var(--accent); border-radius: 20px; }
progress::-moz-progress-bar { background: var(--accent); border-radius: 20px; }
.success-band { display: flex; gap: 30px; flex-wrap: wrap; background: var(--pale); padding: 18px 20px; border-radius: 10px; margin: 20px 0 0; font-size: 13px; }
.ordered { padding-left: 24px; margin: 0; }
.ordered li { padding: 9px 0 9px 4px; }
.ordered .muted { font-size: 12px; }
.month-row { border-top: 1px solid var(--line); }
summary { cursor: pointer; font-weight: 700; padding: 15px 0; font-size: 14px; }
.month-row summary { display: flex; align-items: center; justify-content: space-between; gap: 12px; font-size: 12px; }
.month-row summary::before { content: '+'; color: var(--brand); }
.month-row[open] summary::before { content: '−'; }
.month-row summary > span:first-of-type { margin-right: auto; }
.month-row summary > span:last-child { font-weight: 500; }
.month-row .help { padding: 15px 0 5px; }
.month-row table { font-size: 11px; }
.month-row th, .month-row td { padding: 12px; }
.pagination { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 16px; font-size: 12px; padding-top: 20px; }
.help { font-size: 12px; color: var(--muted); line-height: 1.6; margin: 8px 0 0; }
.help ul { padding-left: 18px; }
.assumptions { padding: 10px 24px; }
.assumptions ul { font-size: 12px; color: var(--muted); padding-left: 20px; }
.assumptions li { margin: 12px 0; }
.form-card { max-width: 740px; }
.field { margin-bottom: 23px; }
.field > label { display: block; font-size: 13px; font-weight: 700; margin-bottom: 8px; }
.field > label > span { color: var(--brand); }
.field input:not([type=checkbox]), .field select { width: 100%; min-height: 48px; border: 1px solid #cbdbe6; border-radius: 9px; background: #fbfdff; padding: 11px 13px; color: var(--ink); }
.field input::placeholder { color: #748a9a; }
.field input:focus, .field select:focus { outline: 2px solid #69d8ff; border-color: var(--brand); }
.field input:disabled, .field select:disabled { background: #f1f6fa; color: var(--muted); }
.check-field label, .empty-confirm > label { display: flex; align-items: flex-start; gap: 10px; font-size: 13px; cursor: pointer; }
input[type=checkbox] { accent-color: #00799f; width: 18px; height: 18px; flex: 0 0 auto; margin: 2px 0 0; }
.errorlist { list-style: none; padding: 0; color: #aa273b; font-size: 13px; }
.errorlist li { margin: 6px 0; }
.align-start { align-self: start; }
.empty { text-align: center; padding: 46px; grid-column: 1 / -1; }
footer { max-width: 1160px; padding: 28px 36px 35px; font-size: 11px; color: var(--muted); line-height: 1.65; }
.public, .setup-shell { min-height: 100vh; }
.public-header { min-height: 88px; padding: 20px 5%; border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; gap: 20px; background: white; }
.public .main { max-width: 1190px; padding-top: 62px; }
.public footer { text-align: center; max-width: 820px; margin: auto; }
.auth-layout { display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: 90px; }
.auth-intro h2 { font-size: clamp(36px, 4vw, 51px); letter-spacing: -1.8px; line-height: 1.22; margin-bottom: 22px; }
.auth-intro > p { max-width: 420px; color: var(--muted); font-size: 16px; }
.auth-benefits { list-style: none; padding: 0; margin: 34px 0 0; }
.auth-benefits li { display: flex; gap: 16px; margin: 22px 0; }
.auth-benefits li > span { display: grid; place-items: center; width: 35px; height: 35px; flex: 0 0 auto; border: 1px solid #b6e6f8; border-radius: 10px; background: var(--pale); color: var(--brand); font-size: 12px; font-weight: 700; }
.auth-benefits strong { font-size: 14px; }
.auth-benefits p { color: var(--muted); font-size: 12px; margin: 4px 0 0; }
.auth-card { width: 100%; max-width: 510px; margin: 0 auto; padding: 36px; }
.auth-card h1 { font-size: 28px; }
.auth-card > p { font-size: 13px; }
.auth-card form { margin-top: 26px; }
.auth-card .help { font-size: 11px; }
.auth-links { text-align: center; font-size: 13px; margin-top: 23px; border-top: 1px solid var(--line); padding-top: 19px; }
.auth-links p { margin: 12px 0 0; }
.setup-shell .main { max-width: 1130px; padding-top: 38px; }
.setup-shell footer { max-width: 1000px; text-align: center; margin: auto; }
.setup-header-actions { display: flex; align-items: center; gap: 25px; }
.setup-progress { margin: 0 auto 42px; max-width: 850px; }
.setup-progress ol { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); list-style: none; padding: 0; margin: 0; }
.setup-progress li { position: relative; }
.setup-progress li:not(:last-child)::after { content: ''; position: absolute; top: 18px; height: 2px; background: var(--line); left: calc(50% + 27px); width: calc(100% - 54px); }
.setup-progress li.done::after { background: #89dcfa; }
.setup-progress a, .locked-step { display: flex; flex-direction: column; align-items: center; gap: 9px; color: var(--muted); font-size: 12px; font-weight: 600; }
.setup-progress a:hover { text-decoration: none; color: var(--brand); }
.step-dot { width: 37px; height: 37px; border-radius: 50%; border: 1px solid #d4e2eb; background: #f9fcfe; display: grid; place-items: center; font-size: 13px; font-weight: 700; }
.active .step-dot { background: var(--accent); border-color: var(--accent); color: #06364d; box-shadow: 0 0 0 5px #e0f6ff; }
.done .step-dot { background: #def6ff; border-color: #93def8; color: #00749b; }
.active .step-label { color: var(--ink); font-weight: 700; }
.setup-heading { margin-bottom: 30px; }
.setup-heading h1 { font-size: clamp(26px, 3vw, 35px); }
.setup-heading p { font-size: 14px; }
.setup-grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); align-items: start; gap: 26px; }
.setup-entry { padding: 30px; }
.section-heading { display: flex; align-items: flex-start; gap: 13px; margin-bottom: 25px; }
.section-heading h2 { margin: 0 0 4px; font-size: 19px; }
.section-heading p { margin: 0; }
.tile-icon { display: grid; place-items: center; background: var(--pale); color: var(--brand); width: 42px; height: 42px; border-radius: 12px; flex: 0 0 auto; }
.saved-records > .split h2 { font-size: 18px; margin: 0; }
.count-badge { display: grid; place-items: center; min-width: 29px; height: 29px; background: var(--pale); color: var(--brand); border-radius: 8px; font-size: 12px; font-weight: 700; }
.setup-total { background: var(--pale); border: 1px solid #c9edfc; border-radius: 12px; padding: 18px 20px; margin: 23px 0 5px; }
.setup-total > span { display: block; color: var(--muted); font-size: 12px; }
.setup-total strong { font-size: clamp(23px, 2.5vw, 29px); font-weight: 700; letter-spacing: -.7px; overflow-wrap: anywhere; }
.saved-list { padding: 0; margin: 0; list-style: none; }
.saved-list li { padding: 19px 0 10px; border-bottom: 1px solid var(--line); }
.saved-list li:last-child { border-bottom: 0; padding-bottom: 0; }
.saved-list .split { align-items: start; gap: 14px; font-size: 13px; }
.saved-list strong { overflow-wrap: anywhere; }
.saved-list p { margin: 4px 0 0; }
.saved-amount { font-weight: 700; white-space: nowrap; }
.row-actions { display: flex; gap: 20px; font-size: 12px; }
.row-actions a { padding: 10px 0; min-height: 38px; }
.setup-empty { text-align: center; padding: 34px 14px 15px; }
.empty-icon { width: 66px; height: 66px; background: #f0f9fd; border: 1px dashed #b4deee; color: var(--brand); border-radius: 18px; margin: 0 auto 18px; display: grid; place-items: center; }
.empty-icon .icon { width: 26px; height: 26px; }
.setup-empty h3 { font-size: 16px; }
.setup-empty p { font-size: 13px; color: var(--muted); max-width: 270px; margin: 0 auto; }
.setup-tip { display: flex; gap: 13px; margin-top: 22px; padding: 4px 8px; }
.setup-tip .tile-icon { width: 34px; height: 34px; background: #e6f3fa; border-radius: 9px; }
.setup-tip .icon { width: 18px; height: 18px; }
.setup-tip h3 { margin-bottom: 5px; font-size: 13px; }
.setup-tip p { font-size: 12px; color: var(--muted); margin: 0; }
.setup-next { border-top: 1px solid var(--line); margin-top: 30px; padding-top: 24px; }
.setup-next-row { display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.back-link { font-size: 13px; font-weight: 700; padding: 10px 0; display: inline-block; }
.empty-confirm { margin-bottom: 22px; color: var(--muted); }
.compact-field { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.compact-field > label { margin: 0; font-size: 12px; font-weight: 500; }
.compact-field select { width: 105px; min-height: 38px; padding: 6px 10px; font-size: 12px; }
.review-totals dt a { display: block; font-size: 11px; }
.review-totals dd { white-space: nowrap; }
.form-final-actions .help { text-align: center; }
.skip { position: fixed; top: -100px; left: 12px; padding: 10px 18px; background: white; z-index: 20; border: 1px solid var(--brand); border-radius: 8px; }
.skip:focus { top: 12px; }
@media (max-width: 1200px) {
  .shell { grid-template-columns: 210px minmax(0, 1fr); }
  .sidebar { padding: 26px 14px; }
  .main { padding: 30px 25px 20px; }
  .plan-card { padding: 20px; }
  .plan-card.chosen { padding: 19px; }
  .plan-card .plan-date { font-size: 23px; }
  .plan-grid { gap: 14px; }
  .auth-layout { gap: 50px; }
}
@media (max-width: 960px) {
  .shell { display: block; }
  .sidebar { position: relative; height: auto; padding: 18px 22px 0; border-right: 0; border-bottom: 1px solid var(--line); }
  .sidebar .brand { font-size: 18px; padding-right: 75px; }
  .sidebar .brand strong { display: inline; }
  .sidebar .desktop-navigation { display: none; }
  .mobile-navigation { display: block; margin-top: 13px; }
  .mobile-navigation summary { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); font-size: 13px; }
  .mobile-navigation summary .small { margin-left: auto; }
  .mobile-navigation summary::after { content: '+'; font-size: 18px; color: var(--brand); }
  .mobile-navigation[open] summary::after { content: '−'; }
  .sidebar .mobile-nav-links { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; margin: 0; padding: 0 0 14px; }
  .sidebar nav a { flex: 0 0 auto; padding: 10px 12px; font-size: 12px; }
  .sidebar nav .icon { width: 17px; height: 17px; }
  .nav-caption, .sidebar nav .nav-caption, .sidebar-bottom .privacy-note { display: none; }
  .sidebar-bottom { position: absolute; top: 16px; right: 23px; padding: 0; }
  .topbar { height: 48px; padding: 0 24px; }
  .stats-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .three-grid { grid-template-columns: 1fr; }
  .plan-grid { grid-template-columns: 1fr; }
  .plan-card { display: grid; grid-template-columns: 1fr 1fr; column-gap: 24px; padding: 26px; }
  .plan-card.chosen { padding: 25px; }
  .plan-card > .split, .plan-card > h2 { grid-column: 1 / -1; }
  .plan-card h2 { min-height: 0; }
  .plan-card dl { grid-column: 2; grid-row: 3 / 7; margin-top: 0; }
  .plan-card dl > div { padding: 9px 0; }
  .plan-card form { grid-column: 1; align-self: end; }
  .plan-card .help { padding-top: 0; }
  .setup-grid { gap: 20px; }
  .setup-entry { padding: 25px; }
  .setup-shell .main { padding: 32px 24px 15px; }
  .auth-layout { gap: 30px; }
  .auth-card { padding: 28px; }
  .auth-intro h2 { font-size: 36px; }
}
@media (max-width: 700px) {
  .setup-grid { grid-template-columns: 1fr; }
  .setup-entry { padding: 26px; }
  .setup-summary { min-width: 0; }
  .setup-tip { margin-bottom: 0; }
  .setup-progress { margin-bottom: 32px; }
  .setup-header-actions .saved-label { display: none; }
  .auth-layout { grid-template-columns: 1fr; }
  .auth-intro { display: none; }
  .public .main { padding-top: 28px; }
  .public-header .saved-label { display: none; }
  .auth-card { padding: 30px; }
}
@media (max-width: 600px) {
  body { font-size: 14px; }
  .main { padding: 26px 16px 16px; }
  .sidebar { padding: 16px 16px 0; }
  .sidebar-bottom { right: 16px; top: 15px; }
  .sidebar .brand-icon { width: 36px; height: 36px; border-radius: 11px; }
  .sidebar nav a { gap: 7px; }
  .topbar { padding: 0 16px; font-size: 11px; }
  .card { padding: 21px; border-radius: 14px; }
  .page-heading.split { flex-direction: column; align-items: start; }
  .stats-grid { gap: 11px; }
  .stat { padding: 16px 14px; gap: 9px; }
  .stat > strong { font-size: 18px; }
  .stat > span { font-size: 11px; }
  .stat small, .stat a { font-size: 10px; }
  .two-grid, .record-grid, .allocation-grid { grid-template-columns: 1fr; gap: 17px; }
  .hero { display: block; padding: 24px; }
  .hero h2 { font-size: 33px; }
  .hero-side { margin-top: 25px; padding: 20px 0 0; border-left: 0; border-top: 1px solid #bcdeee; }
  .hero-badges { gap: 7px; }
  .hero-badges span { font-size: 11px; }
  .split { flex-wrap: wrap; align-items: start; }
  .plan-card { display: flex; padding: 24px; }
  .plan-card.chosen { padding: 23px; }
  .plan-card dl div { flex-direction: row; gap: 17px; }
  .plan-card dd { text-align: right; font-size: 14px; flex: 0 0 auto; max-width: 60%; }
  .plan-card .plan-date { font-size: 29px; }
  .plan-card form { width: 100%; }
  .plan-card .help { padding-top: 12px; }
  .plan-note { padding: 21px; }
  .table-wrap { padding: 0; }
  caption { font-size: 17px; padding: 20px; }
  th, td { padding: 14px; }
  .month-row summary { align-items: start; flex-wrap: wrap; gap: 5px; }
  .month-row summary > span:last-child { flex-basis: 100%; padding-left: 15px; font-size: 11px; }
  .month-row summary > span:last-child .muted { display: block; }
  .success-band { gap: 8px; }
  .records-total { padding: 17px 20px; }
  .records-total strong { font-size: 23px; }
  .record .stat-number { font-size: 25px; }
  .form-card { padding: 23px; }
  .assumptions { padding: 8px 20px; }
  footer { padding: 25px 17px; font-size: 10px; }
  .public-header { padding: 17px 20px; min-height: 77px; }
  .brand { font-size: 17px; gap: 9px; }
  .brand-icon { width: 36px; height: 36px; border-radius: 11px; }
  .auth-card { padding: 25px; }
  .auth-card h1 { font-size: 26px; }
  .setup-shell .main { padding: 27px 18px 14px; }
  .setup-progress a, .locked-step { font-size: 10px; gap: 9px; text-align: center; line-height: 1.5; }
  .step-label { max-width: 70px; }
  .step-dot { width: 33px; height: 33px; }
  .setup-progress li:not(:last-child)::after { top: 16px; left: calc(50% + 22px); width: calc(100% - 44px); }
  .setup-heading h1 { font-size: 28px; }
  .setup-heading .eyebrow { font-size: 9px; letter-spacing: 1px; }
  .setup-heading p { font-size: 13px; }
  .setup-entry { padding: 23px; }
  .section-heading h2 { font-size: 18px; }
  .setup-total strong { font-size: 27px; }
  .saved-records > .split { flex-wrap: nowrap; }
  .saved-list .split { gap: 4px; flex-direction: column; }
  .setup-next-row { flex-direction: column-reverse; align-items: stretch; text-align: center; gap: 12px; }
  .setup-next { margin-top: 25px; padding-top: 20px; }
  .empty-confirm > label { font-size: 12px; }
  .compact-field { justify-content: space-between; }
  .compact-field > label { max-width: 190px; }
  .review-totals dt { font-size: 12px; }
  .review-totals dd { font-size: 12px; }
  /* Lender totals remain visible without sideways scrolling on phones. */
  .payment-table, .payment-table caption, .payment-table tbody, .payment-table tfoot, .payment-table tr { display: block; }
  .payment-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  .payment-table tr { padding: 15px 20px; border-top: 1px solid var(--line); }
  .payment-table th { display: block; padding: 0 0 9px; border: 0; font-size: 15px; }
  .payment-table td { display: flex; gap: 12px; justify-content: space-between; padding: 9px 0; border: 0; font-size: 12px; }
  .payment-table td::before { content: attr(data-label); color: var(--muted); white-space: normal; }
  .payment-table td:last-child { border-top: 1px solid var(--line); margin-top: 4px; font-weight: 700; }
}
.checkout-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 24px;
}

.checkout-actions button:disabled {
  opacity: .6;
  cursor: not-allowed;
}

@media (max-width: 600px) {
  .checkout-actions {
    flex-direction: column;
  }

  .checkout-actions .button {
    width: 100%;
  }
}