/* FUND-061: shared reading, interface and numeric type roles. */
@font-face {
  font-family: "Public Sans";
  src: url("fonts/public-sans.woff2") format("woff2");
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --font-reading: "Public Sans", system-ui, sans-serif;
  --type-caption: .8125rem;
  --type-ui: .875rem;
  --type-reading: .9375rem;
  font-family: var(--font-reading);
  font-size: 100%;
  font-synthesis: none;
}

body { font-size: 1rem; line-height: 1.65; }
button, input, select { font-family: inherit; }
h1, h2, h3 { text-wrap: balance; font-weight: 650; }
h1 {
  font-size: clamp(2.75rem, 5.2vw, 4.5rem);
  line-height: 1.08;
  letter-spacing: -.045em;
}
.section h2 { font-size: clamp(1.75rem, 3vw, 2.125rem); line-height: 1.2; letter-spacing: -.035em; }
.account-card h2 { font-size: 1.625rem; line-height: 1.3; letter-spacing: -.025em; }
.intro { font-size: 1.125rem; line-height: 1.7; }
.brand { font-size: .8125rem; letter-spacing: 0; }
.brand strong { font-size: 1.125rem; font-weight: 700; }
nav, .button, .tool-nav { font-size: var(--type-ui); line-height: 1.5; }
.button { font-weight: 650; }
.eyebrow, .card-top .eyebrow, .questions span, .plan-firm {
  font-family: var(--font-reading);
  font-size: .75rem;
  font-weight: 650;
  letter-spacing: .075em;
  line-height: 1.5;
}
.tag { font-size: .75rem; line-height: 1.4; }
.card-top, .calc-heading { flex-wrap: wrap; }
.quiet, .account-card small, .result-limit, footer {
  font-size: var(--type-caption);
  line-height: 1.7;
}
.account-card p, .questions p, .learn-grid p, .method p, .comparison-note {
  font-size: var(--type-reading);
  line-height: 1.75;
}
.questions h2 { font-size: 1.125rem; line-height: 1.35; }
.learn-grid h3, .calc-heading h3 { font-size: 1.375rem; line-height: 1.35; letter-spacing: -.02em; }
.notional, .loss-budget > span { font-size: var(--type-caption); line-height: 1.6; }
.notional strong { font-size: 1.375rem; }
.loss-budget strong, .total { letter-spacing: -.035em; line-height: 1.15; }
.formula, .number { font-family: var(--font-reading); font-size: var(--type-ui); line-height: 1.6; }

/* Financial values align without losing their original currency, unit or precision. */
input, output, .notional strong, .loss-budget strong, .plan-facts dd,
.plan-scenario strong, .fee-breakdown, .shortlist-table,
.drawdown-scroll, .drawdown-headroom strong, .payout-figures dd {
  font-variant-numeric: lining-nums tabular-nums;
}
.input-grid label, .drawdown-controls label, .compare-controls label,
.scenario-counts label, .preset-select > label, .plan-choice {
  font-size: var(--type-ui);
  line-height: 1.6;
}
.input-grid input, .drawdown-controls input, .drawdown-controls select,
.compare-controls input, .compare-controls select, .scenario-counts input,
.preset-select select, .payout-shell select {
  font-size: 1rem;
  line-height: 1.5;
}
.extra-options summary, .comparison-scenario summary, .plan-detail summary,
.preset-row, .preset-row button, .shortlist-chip,
.plan-scenario .button, .shortlist-actions .button, .tool-actions .button {
  font-size: var(--type-ui);
  line-height: 1.6;
}
.extra-options .quiet, .preset-select .extra-options { font-size: var(--type-caption); line-height: 1.75; }
.plan-row h3 { font-size: 1.375rem; line-height: 1.35; letter-spacing: -.02em; }
.plan-facts dt { font-size: var(--type-caption); line-height: 1.5; }
.plan-facts dd { font-size: 1.5rem; line-height: 1.3; letter-spacing: -.025em; }
.plan-facts dd small, .plan-scenario small, .plan-detail-content li small,
.shortlist-table small, .shortlist-table ul { font-size: var(--type-caption); line-height: 1.7; }
.plan-scenario > span { font-size: var(--type-ui); }
.plan-detail-content { font-size: var(--type-reading); line-height: 1.75; }
.fee-breakdown, .shortlist-table table, .drawdown-scroll table { font-size: var(--type-ui); line-height: 1.65; }
.fee-breakdown th { font-weight: 500; }
.shortlist-table caption, .drawdown-scroll caption, .drawdown-scroll thead th {
  font-size: var(--type-caption);
  line-height: 1.65;
}
.shortlist-table thead th { font-size: 1rem; line-height: 1.45; }
.drawdown-headroom span, .drawdown-headroom small, .chart-key,
.payout-figures dt, .payout-check p { font-size: var(--type-caption); line-height: 1.7; }
.payout-check strong { font-size: var(--type-ui); line-height: 1.5; }
.payout-shell h3, .drawdown-summary h3 { font-size: 1.5rem; line-height: 1.3; letter-spacing: -.025em; }
.error-message { font-size: var(--type-ui); line-height: 1.7; }

@media (max-width: 700px) {
  .site-header { flex-wrap: wrap; gap: 18px; }
  .brand { font-size: .8125rem; }
  .brand strong { font-size: 1.125rem; }
  nav { font-size: var(--type-ui); gap: 20px; }
  h1 { font-size: clamp(2.5rem, 11.3vw, 3.25rem); }
  .intro { font-size: 1.0625rem; }
  .account-card h2 { font-size: 1.5rem; }
  .notional { flex-wrap: wrap; }
  .formula { flex-wrap: wrap; }
}
