/* Shared styles for /calculator and /buydown-calculator */
 /* ═══════════════════════════════════════════════════
 CALCULATOR PAGE — design tokens + layout
 Works alongside the main site nav injected by shell.js
 ═══════════════════════════════════════════════════ */
 :root {
 --teal: #80cdcf;
 --teal-mid: #5aabb0;
 --teal-dark: #2e7a80;
 --teal-deeper:#1f5a60;
 --teal-light: #eaf4f5;
 --gold: #efb437;
 --gold-dark: #a8761c;
 --gold-light: #fef8e8;
 --pink: #b0468a;
 --pink-light: #f9ecf5;
 --slate: #5f6464;
 --bg: #f5f7f8;
 --bg-2: #e3e8ea;
 --surface: #ffffff;
 --surface-2: #f9fafb;
 --border: #e2e8ea;
 --border-mid: #c8d4d6;
 --text: #0d1a1c;
 --text-2: #1e3235;
 --text-muted: #4f6669;
 --text-faint: #6f8689;
 --radius-sm: 10px;
 --radius-md: 14px;
 --radius-lg: 18px;
 --radius-xl: 24px;
 --shadow-sm: 0 1px 4px rgba(0,0,0,.06),0 2px 8px rgba(0,0,0,.04);
 --shadow-md: 0 4px 16px rgba(0,0,0,.08),0 2px 6px rgba(0,0,0,.05);
 --shadow-lg: 0 8px 32px rgba(0,0,0,.1),0 4px 12px rgba(0,0,0,.06);
 --ease: cubic-bezier(.4,0,.2,1);
 }

 #calc-page-wrap {
 background: var(--bg);
 min-height: 100vh;
 padding-top: var(--nav-height, 72px);
 }
 #calc-page-wrap *, #calc-page-wrap *::before, #calc-page-wrap *::after { box-sizing: border-box; }
 #calc-page-wrap button { font-family: inherit; }
 #calc-page-wrap :focus-visible { outline: 3px solid var(--teal-mid); outline-offset: 2px; }
 [hidden] { display: none !important; }

 /* ── SCREENS ─────────────────────────────────────── */
 .screen { display: none; }
 .screen.active { display: block; animation: fadeUp .3s var(--ease) both; }
 @keyframes fadeUp { from { opacity:0; transform: translateY(12px); } to { opacity:1; transform: none; } }
 @media (prefers-reduced-motion: reduce) { .screen.active { animation: none; } }

 /* ── WELCOME ─────────────────────────────────────── */
 .welcome-hero {
 background: linear-gradient(160deg, var(--teal-light) 0%, var(--bg) 55%);
 border-bottom: 1px solid var(--border);
 padding: 56px 20px 48px; text-align: center;
 }
 .welcome-eyebrow {
 display: inline-block; background: var(--surface);
 border: 1.5px solid var(--teal-mid); color: var(--teal-dark);
 font-size: .72rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase;
 padding: 5px 16px; border-radius: 999px; margin-bottom: 22px; box-shadow: var(--shadow-sm);
 }
 .welcome-h1 { font-size: clamp(2rem, 6vw, 3.2rem); font-weight: 900; letter-spacing: -.03em; line-height: 1.1; color: var(--text); margin: 0 0 16px; }
 .welcome-h1 .hi-teal { color: var(--teal-dark); }
 .welcome-h1 .hi-gold { color: var(--gold-dark); }
 .welcome-h1 .hi-pink { color: var(--pink); }
 .welcome-sub { font-size: 1.05rem; color: var(--text-muted); max-width: 480px; margin: 0 auto 36px; line-height: 1.6; }

 .choice-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; max-width: 600px; margin: 0 auto 32px; }
 @media (max-width: 540px) { .choice-grid { grid-template-columns: 1fr; } }
 .choice-card {
 background: var(--surface); border: 2px solid var(--border); border-radius: var(--radius-lg);
 padding: 24px 22px; cursor: pointer; text-align: left; font: inherit; color: inherit;
 transition: transform .2s var(--ease), box-shadow .2s var(--ease), border-color .2s;
 display: flex; flex-direction: column; gap: 10px; box-shadow: var(--shadow-sm);
 }
 .choice-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
 .choice-card.primary:hover { border-color: var(--teal); }
 .choice-card.secondary:hover { border-color: var(--gold); }
 .ch-icon { width: 50px; height: 50px; border-radius: var(--radius-md); display: flex; align-items: center; justify-content: center; }
 .choice-card.primary .ch-icon { background: var(--teal-light); }
 .choice-card.secondary .ch-icon { background: var(--gold-light); }
 .ch-title { font-size: 1.02rem; font-weight: 800; }
 .choice-card.primary .ch-title, .choice-card.primary .ch-arrow { color: var(--teal-dark); }
 .choice-card.secondary .ch-title, .choice-card.secondary .ch-arrow { color: var(--gold-dark); }
 .ch-desc { font-size: .84rem; color: var(--text-muted); line-height: 1.5; flex: 1; }
 .ch-arrow { font-size: .85rem; font-weight: 700; }

 .trust-row { display: flex; align-items: center; justify-content: center; gap: 8px 18px; flex-wrap: wrap; font-size: .78rem; color: var(--text-faint); }
 .trust-sep { width: 4px; height: 4px; background: var(--border-mid); border-radius: 50%; }

 /* ── WIZARD ──────────────────────────────────────── */
 .wizard-outer { min-height: calc(100vh - var(--nav-height, 72px)); display: flex; align-items: center; justify-content: center; padding: 32px 16px; }
 .wizard-box { width: 100%; max-width: 560px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-xl); box-shadow: var(--shadow-md); padding: 32px; }
 @media (max-width: 580px) { .wizard-outer { align-items: flex-start; padding: 16px 12px 32px; } .wizard-box { padding: 22px 16px; border-radius: var(--radius-lg); } }

 .prog-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
 .prog-label { font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--teal-dark); }
 .prog-count { font-size: .72rem; color: var(--text-faint); }
 .prog-track { height: 4px; background: var(--bg-2); border-radius: 999px; margin-bottom: 24px; overflow: hidden; }
 .prog-fill { height: 100%; background: linear-gradient(90deg, var(--teal), var(--pink)); border-radius: 999px; }

 .step-q { font-size: clamp(1.25rem, 4vw, 1.55rem); font-weight: 800; color: var(--text); letter-spacing: -.02em; line-height: 1.25; margin: 0 0 6px; }
 .step-hint { font-size: .86rem; color: var(--text-muted); line-height: 1.55; margin: 0 0 20px; }

 .opt-grid { display: grid; gap: 8px; margin-bottom: 18px; }
 .opt-grid.g1 { grid-template-columns: 1fr; }
 .opt-grid.g2 { grid-template-columns: 1fr 1fr; }
 .opt-grid.g3 { grid-template-columns: repeat(3, 1fr); }
 @media (max-width: 400px) { .opt-grid.g2.stack { grid-template-columns: 1fr; } }

 .opt {
 width: 100%; border: 1.5px solid var(--border); border-radius: var(--radius-md);
 background: var(--surface-2); padding: 13px 14px; cursor: pointer; text-align: left;
 font: inherit; color: inherit; min-height: 52px;
 transition: border-color .15s, background .15s;
 display: flex; align-items: center; gap: 12px;
 }
 .opt:hover:not(:disabled) { border-color: var(--teal); background: var(--teal-light); }
 .opt.sel { border-color: var(--teal-dark); background: var(--teal-light); box-shadow: 0 0 0 1px var(--teal-dark); }
 .opt:disabled { opacity: .4; cursor: not-allowed; }
 .opt-body { flex: 1; min-width: 0; }
 .opt-title { display: block; font-size: .92rem; font-weight: 700; color: var(--text); }
 .opt.sel .opt-title { color: var(--teal-dark); }
 .opt-sub { display: block; font-size: .76rem; color: var(--text-muted); margin-top: 2px; }
 .opt-chk { width: 20px; height: 20px; border-radius: 50%; border: 1.5px solid var(--border-mid); flex-shrink: 0; position: relative; }
 .opt.sel .opt-chk { background: var(--teal-dark); border-color: var(--teal-dark); }
 .opt.sel .opt-chk::after { content: ''; position: absolute; left: 6px; top: 3px; width: 5px; height: 9px; border: solid #fff; border-width: 0 2px 2px 0; transform: rotate(45deg); }
 .opt-grid.g3 .opt { justify-content: center; text-align: center; padding: 12px 6px; }
 .opt-grid.g3 .opt .opt-chk { display: none; }

 .sub-section-label { font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--text-muted); margin: 16px 0 8px; }
 .sub-section-label:first-of-type { margin-top: 0; }

 .wiz-nav { display: flex; gap: 10px; align-items: center; margin-top: 8px; }
 .wiz-back { padding: 12px 18px; min-height: 48px; border-radius: var(--radius-sm); border: 1.5px solid var(--border-mid); color: var(--text-muted); font-size: .88rem; font-weight: 600; background: transparent; cursor: pointer; }
 .wiz-back:hover { border-color: var(--teal); color: var(--teal-dark); }
 .wiz-next { flex: 1; padding: 13px 18px; min-height: 48px; border-radius: var(--radius-sm); background: var(--teal-dark); color: #fff; font-size: .95rem; font-weight: 800; border: none; cursor: pointer; box-shadow: 0 4px 14px rgba(46,122,128,.3); transition: background .15s; }
 .wiz-next:hover { background: var(--teal-deeper); }
 .wiz-next:disabled { opacity: .35; cursor: not-allowed; box-shadow: none; }
 .wiz-next.gold-btn { background: var(--gold); color: var(--text); box-shadow: 0 4px 14px rgba(239,180,55,.35); }
 .wiz-next.gold-btn:hover { background: #e0a52a; }

 .custom-lbl { display: block; font-size: .8rem; font-weight: 600; color: var(--text-2); margin-bottom: 6px; }
 .field-err { font-size: .76rem; color: #b42318; margin-top: 6px; }

 /* ── CALCULATOR SCREEN ───────────────────────────── */
 .calc-wrap { max-width: 1220px; margin: 0 auto; padding: 24px 20px 64px; }

 .ans-strip { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; padding: 12px 16px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-md); margin-bottom: 20px; box-shadow: var(--shadow-sm); }
 .ans-label { font-size: .7rem; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; color: var(--text-faint); }
 .chip { padding: 3px 11px; border-radius: 999px; font-size: .76rem; font-weight: 700; }
 .chip-teal { background: var(--teal-light); color: var(--teal-dark); border: 1px solid var(--teal-mid); }
 .chip-gold { background: var(--gold-light); color: var(--gold-dark); border: 1px solid #f0d080; }
 .chip-pink { background: var(--pink-light); color: var(--pink); border: 1px solid #e8b0d8; }
 .ans-edit { margin-left: auto; font-size: .8rem; font-weight: 700; color: var(--teal-dark); padding: 6px 10px; border-radius: 999px; cursor: pointer; background: transparent; border: 1px solid var(--border-mid); }
 .ans-edit:hover { background: var(--teal-light); }

 .calc-hdr { text-align: center; margin-bottom: 20px; }
 .calc-hdr h1 { font-size: clamp(1.45rem, 4vw, 2rem); font-weight: 900; letter-spacing: -.025em; color: var(--text); margin: 0 0 4px; }
 .calc-hdr h1 span { color: var(--teal-dark); }
 .calc-hdr p { font-size: .88rem; color: var(--text-muted); margin: 0; }

 .c-grid { display: grid; grid-template-columns: 380px minmax(0, 1fr); gap: 20px; align-items: start; }
 @media (max-width: 880px) { .c-grid { grid-template-columns: minmax(0, 1fr); } }

 .card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 22px; box-shadow: 0 2px 8px rgba(0,0,0,.05); }
 .card + .card { margin-top: 16px; }
 .card-ttl { font-size: .74rem; font-weight: 800; text-transform: uppercase; letter-spacing: .1em; color: var(--teal-dark); margin: 0 0 18px; }

 /* Inputs */
 .ig { margin-bottom: 20px; }
 .ig:last-child { margin-bottom: 0; }
 .ig-row { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-bottom: 6px; }
 .ig-lbl { display: block; font-size: .84rem; font-weight: 700; color: var(--text-2); }
 .ig > .ig-lbl { margin-bottom: 6px; }
 .ig-badge { font-size: .74rem; font-weight: 700; padding: 2px 9px; border-radius: 999px; white-space: nowrap; }
 .ig-badge-teal { background: var(--teal-light); color: var(--teal-dark); border: 1px solid var(--teal-mid); }
 .ig-badge-gold { background: var(--gold-light); color: var(--gold-dark); border: 1px solid #f0d080; }
 .ig-help { font-size: .76rem; color: var(--text-muted); line-height: 1.5; margin: 6px 0 0; }

 .fld { position: relative; flex: 1; min-width: 0; }
 .pfx, .sfx { position: absolute; top: 50%; transform: translateY(-50%); font-size: .95rem; font-weight: 700; color: var(--text-faint); pointer-events: none; }
 .pfx { left: 13px; }
 .sfx { right: 13px; }

 .inp {
 width: 100%; padding: 11px 14px; min-height: 48px;
 border: 1.5px solid var(--border-mid); border-radius: var(--radius-sm);
 background: var(--surface-2); color: var(--text);
 font-family: inherit; font-size: 16px; font-weight: 700; font-variant-numeric: tabular-nums;
 transition: border-color .15s, box-shadow .15s;
 }
 .inp:focus { outline: none; border-color: var(--teal-dark); box-shadow: 0 0 0 3px rgba(128,205,207,.3); }
 .inp[aria-invalid="true"] { border-color: #b42318; box-shadow: 0 0 0 3px rgba(180,35,24,.12); }
 .inp.hp { padding-left: 28px; }
 .inp.hs { padding-right: 34px; }
 .inp.hs-wide { padding-right: 52px; }
 select.inp { appearance: none; -webkit-appearance: none; padding-right: 38px; cursor: pointer; font-weight: 600;
 background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%232e7a80' stroke-width='2' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
 background-repeat: no-repeat; background-position: right 14px center; }

 /* Native range slider, styled */
 .rng { -webkit-appearance: none; appearance: none; width: 100%; height: 28px; margin: 8px 0 0; background: transparent; cursor: pointer; --p: 50%; }
 .rng:focus { outline: none; }
 .rng::-webkit-slider-runnable-track { height: 6px; border-radius: 999px; background: linear-gradient(to right, var(--teal-dark) var(--p), var(--bg-2) var(--p)); }
 .rng::-moz-range-track { height: 6px; border-radius: 999px; background: linear-gradient(to right, var(--teal-dark) var(--p), var(--bg-2) var(--p)); }
 .rng::-webkit-slider-thumb { -webkit-appearance: none; width: 22px; height: 22px; margin-top: -8px; border-radius: 50%; background: #fff; border: 3px solid var(--teal-dark); box-shadow: 0 1px 6px rgba(0,0,0,.2); }
 .rng::-moz-range-thumb { width: 18px; height: 18px; border-radius: 50%; background: #fff; border: 3px solid var(--teal-dark); box-shadow: 0 1px 6px rgba(0,0,0,.2); }
 .rng:focus-visible::-webkit-slider-thumb { box-shadow: 0 0 0 5px rgba(90,171,176,.45); }
 .rng:focus-visible::-moz-range-thumb { box-shadow: 0 0 0 5px rgba(90,171,176,.45); }

 /* Segmented controls */
 .seg { display: flex; background: var(--bg-2); border-radius: var(--radius-sm); padding: 3px; gap: 3px; }
 .seg-b { flex: 1; min-height: 42px; padding: 8px 6px; border-radius: 8px; font-size: .84rem; font-weight: 700; color: var(--text-muted); background: transparent; border: none; cursor: pointer; transition: background .15s, color .15s; }
 .seg-b.on { background: var(--surface); color: var(--teal-dark); box-shadow: var(--shadow-sm); }
 .dp-row { display: flex; gap: 8px; align-items: stretch; }
 .dp-row .seg { width: 96px; flex-shrink: 0; }

 .term-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
 .term-b { padding: 8px 4px; min-height: 64px; text-align: center; border: 1.5px solid var(--border-mid); border-radius: var(--radius-sm); font-size: 1rem; font-weight: 800; color: var(--text-2); background: transparent; cursor: pointer; transition: background .15s, border-color .15s; line-height: 1.2; }
 .term-b span { display: block; font-size: .64rem; font-weight: 600; color: var(--text-faint); text-transform: uppercase; letter-spacing: .04em; }
 .term-b em { display: block; font-style: normal; font-size: .72rem; font-weight: 700; color: var(--teal-dark); margin-top: 2px; }
 .term-b:hover { border-color: var(--teal-dark); }
 .term-b.on { background: var(--teal-dark); border-color: var(--teal-dark); color: #fff; }
 .term-b.on span, .term-b.on em { color: rgba(255,255,255,.85); }

 .link-btn { background: none; border: none; padding: 4px 0; font-size: .76rem; font-weight: 700; color: var(--teal-dark); text-decoration: underline; cursor: pointer; }

 /* Results */
 .pmt-hero { text-align: center; padding: 8px 8px 18px; border-bottom: 1px solid var(--border); margin-bottom: 18px; }
 .pmt-lbl { font-size: .74rem; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; color: var(--text-faint); margin-bottom: 4px; }
 .pmt-num { font-size: clamp(2.3rem, 7vw, 3.1rem); font-weight: 900; letter-spacing: -.035em; color: var(--teal-dark); font-variant-numeric: tabular-nums; line-height: 1.1; }
 .pmt-num small { font-size: .4em; font-weight: 700; color: var(--text-faint); letter-spacing: 0; }
 .pmt-sub { font-size: .8rem; color: var(--text-muted); margin-top: 6px; line-height: 1.5; }

 .chart-row { display: flex; align-items: center; gap: 20px; }
 .dnt-wrap { flex-shrink: 0; position: relative; width: 128px; height: 128px; }
 .dnt-svg { width: 100%; height: 100%; display: block; }
 .dnt-ctr { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; }
 .dnt-pct { font-size: 1.15rem; font-weight: 900; color: var(--teal-dark); line-height: 1; }
 .dnt-sub { font-size: .6rem; text-transform: uppercase; letter-spacing: .06em; color: var(--text-faint); margin-top: 2px; }

 .piti-list { flex: 1; min-width: 0; list-style: none; margin: 0; padding: 0; }
 .piti-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 9px 4px; border-bottom: 1px solid var(--border); }
 .piti-row:last-child { border-bottom: none; }
 .piti-left { display: flex; align-items: center; gap: 10px; min-width: 0; }
 .piti-dot { width: 10px; height: 10px; border-radius: 3px; flex-shrink: 0; }
 .piti-nm { font-size: .88rem; font-weight: 700; color: var(--text); line-height: 1.25; }
 .piti-nm-s { display: block; font-size: .72rem; color: var(--text-faint); font-weight: 500; }
 .piti-amt { font-size: .95rem; font-weight: 800; font-variant-numeric: tabular-nums; color: var(--text); white-space: nowrap; }

 .notes { margin-top: 16px; display: flex; flex-direction: column; gap: 8px; }
 .note { padding: 11px 14px; border-radius: var(--radius-sm); font-size: .8rem; line-height: 1.55; background: var(--teal-light); border: 1px solid #bfe0e2; color: var(--teal-deeper); }
 .note.warn { background: #fff4e5; border-color: #f5c77a; color: #7a4a00; }
 .note.err { background: #fdecea; border-color: #f3b3ad; color: #8a1c12; }

 .sum-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 12px; }
 @media (max-width: 1080px) { .sum-grid { grid-template-columns: 1fr 1fr; } }
 .sum-cell { background: var(--bg); border-radius: var(--radius-sm); padding: 12px 14px; border: 1px solid var(--border); min-width: 0; }
 .sum-lbl { font-size: .68rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--text-faint); margin-bottom: 4px; }
 .sum-val { font-size: 1.02rem; font-weight: 800; color: var(--text); font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
 .sum-val small { display: block; font-size: .7rem; font-weight: 600; color: var(--text-faint); }
 .sum-val.c-teal { color: var(--teal-dark); }
 .sum-val.c-gold { color: var(--gold-dark); }
 .sum-val.c-pink { color: var(--pink); }

 .ltv-box { background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 12px 14px; }
 .ltv-hdr { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
 .ltv-lbl { font-size: .7rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--text-faint); }
 .ltv-val { font-size: .92rem; font-weight: 800; }
 .ltv-track { height: 8px; background: var(--border); border-radius: 999px; position: relative; }
 .ltv-fill { height: 100%; border-radius: 999px; transition: width .3s var(--ease); }
 .ltv-marker { position: absolute; top: -3px; left: 80%; width: 2px; height: 14px; background: var(--text-muted); }
 .ltv-hint { font-size: .74rem; color: var(--text-muted); margin-top: 6px; }

 /* Amortization */
 .amort-hdr { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; flex-wrap: wrap; gap: 10px; }
 .amort-ttl { font-size: 1rem; font-weight: 800; color: var(--text); margin: 0; }
 .amort-ctrls { display: flex; gap: 6px; flex-wrap: wrap; }
 .btn-view { min-height: 38px; padding: 6px 14px; border-radius: var(--radius-sm); border: 1.5px solid var(--border-mid); background: var(--surface-2); color: var(--text-muted); font-size: .8rem; font-weight: 700; cursor: pointer; }
 .btn-view.on { background: var(--teal-light); border-color: var(--teal-dark); color: var(--teal-dark); }
 .btn-csv { min-height: 38px; padding: 6px 14px; border-radius: var(--radius-sm); background: var(--gold); color: var(--text); font-size: .8rem; font-weight: 700; border: none; cursor: pointer; }
 .btn-csv:hover { background: #e0a52a; }

 .tbl-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; border-radius: var(--radius-md); border: 1px solid var(--border); }
 .amort-tbl { width: 100%; border-collapse: collapse; font-size: .84rem; min-width: 520px; }
 .amort-tbl th { background: var(--teal-dark); color: #fff; font-size: .68rem; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; padding: 10px 12px; text-align: right; white-space: nowrap; position: sticky; top: 0; }
 .amort-tbl th:first-child, .amort-tbl td:first-child { text-align: left; position: sticky; left: 0; }
 .amort-tbl th:first-child { z-index: 1; }
 .amort-tbl td:first-child { background: var(--surface); color: var(--text-2); font-weight: 600; white-space: nowrap; }
 .amort-tbl tbody tr { border-bottom: 1px solid var(--border); }
 .amort-tbl tbody tr:last-child { border-bottom: none; }
 .amort-tbl td { padding: 9px 12px; text-align: right; color: var(--text-muted); font-variant-numeric: tabular-nums; white-space: nowrap; }
 .amort-tbl td.tp { color: var(--teal-dark); font-weight: 700; }
 .amort-tbl td.ti { color: var(--pink); }
 .td-sub { display: block; font-size: .7rem; font-weight: 500; color: var(--text-faint); }
 #pmtCard, .amort-hdr { scroll-margin-top: calc(var(--nav-height, 72px) + 12px); }
 .tbl-hint { display: none; font-size: .72rem; color: var(--text-faint); margin: 0 0 8px; }
 @media (max-width: 600px) { .tbl-hint { display: block; } }

 .pag { display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: 14px; flex-wrap: wrap; }
 .pg { min-width: 40px; height: 40px; padding: 0 8px; border-radius: 8px; border: 1.5px solid var(--border-mid); background: var(--surface-2); color: var(--text-muted); font-size: .82rem; font-weight: 700; cursor: pointer; }
 .pg:hover:not(:disabled) { border-color: var(--teal-dark); color: var(--teal-dark); }
 .pg:disabled { opacity: .35; cursor: not-allowed; }
 .pg-info { font-size: .82rem; font-weight: 700; color: var(--text-2); padding: 0 8px; }

 /* CTA + disclaimer */
 .cta-card { background: linear-gradient(135deg, var(--teal-light), var(--bg)); border: 2px solid var(--teal-mid); border-radius: var(--radius-lg); padding: 24px; text-align: center; margin-top: 16px; }
 .cta-card h3 { font-size: 1.08rem; font-weight: 800; color: var(--text); margin: 0 0 6px; }
 .cta-card h3 span { color: var(--pink); }
 .cta-card p { font-size: .84rem; color: var(--text-muted); margin: 0 0 16px; }
 .cta-card a { display: inline-block; padding: 13px 28px; background: var(--gold); color: var(--text); font-size: .92rem; font-weight: 800; border-radius: var(--radius-sm); box-shadow: 0 4px 14px rgba(239,180,55,.35); text-decoration: none; }
 .cta-card a:hover { background: #e0a52a; }
 .disclaimer { margin-top: 16px; padding: 14px 18px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-md); font-size: .76rem; color: var(--text-muted); line-height: 1.65; }
 .disclaimer p { margin: 0 0 6px; }
 .disclaimer p:last-child { margin-bottom: 0; }

 /* Mobile sticky payment bar */
 .m-bar { display: none; }
 @media (max-width: 880px) {
 .m-bar {
 position: fixed; left: 0; right: 0; bottom: 0; z-index: 50;
 display: flex; align-items: center; justify-content: space-between; gap: 12px;
 padding: 10px 16px calc(10px + env(safe-area-inset-bottom));
 background: var(--surface); border-top: 1px solid var(--border); box-shadow: 0 -4px 16px rgba(0,0,0,.08);
 transition: transform .25s var(--ease);
 }
 .m-bar.off { transform: translateY(110%); }
 .m-bar-lbl { display: block; font-size: .66rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--text-faint); }
 .m-bar-amt { font-size: 1.3rem; font-weight: 900; color: var(--teal-dark); font-variant-numeric: tabular-nums; }
 .m-bar-btn { min-height: 44px; padding: 10px 16px; border-radius: var(--radius-sm); background: var(--teal-dark); color: #fff; font-size: .85rem; font-weight: 800; border: none; cursor: pointer; }
 .calc-wrap { padding-bottom: 96px; }
 }

 @media (max-width: 600px) {
 .calc-wrap { padding: 14px 12px 96px; }
 .card { padding: 16px 14px; }
 .chart-row { flex-direction: column; align-items: stretch; gap: 12px; }
 .dnt-wrap { margin: 0 auto; width: 116px; height: 116px; }
 .sum-grid { grid-template-columns: 1fr 1fr; gap: 6px; }
 .sum-cell { padding: 10px 11px; }
 .sum-val { font-size: .95rem; }
 .term-b { font-size: .95rem; }
 .ans-edit { margin-left: 0; }
 .cta-card a { display: block; }
 }
 @media (max-width: 360px) {
 .sum-grid { grid-template-columns: 1fr; }
 .term-grid { grid-template-columns: 1fr 1fr; }
 .dp-row .seg { width: 84px; }
 }
