@font-face { font-family: Outfit; src: url('/assets/fonts/outfit-variable.ttf') format('truetype'); font-style: normal; font-weight: 100 900; font-display: swap; }
:root { color-scheme: light; --page: #fbfdfc; --ink: #143e38; --muted: #4d6961; --green: #236e5f; --mist: #eaf4ef; --line: #c5d9cf; --orange: #ffae73; --orange-light: #fff0e2; --orange-ink: #4c2a17; --error: #9a332b; }
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 24px; }
body { margin: 0; background: var(--page); color: var(--ink); font: 17px/1.55 Outfit, system-ui, sans-serif; }
h1, h2, h3, p { margin: 0; }
h1, h2, h3 { font-weight: 500; letter-spacing: -.04em; line-height: 1.13; }
h2 { font-size: clamp(29px, 3vw, 36px); }
h3 { font-size: 23px; }
p { color: var(--muted); }
a { color: inherit; text-underline-offset: 4px; }
button, input, select { font: inherit; }
button, summary { cursor: pointer; }
button, a, input, select, summary { -webkit-tap-highlight-color: transparent; }
:focus, :focus-visible { outline: none; box-shadow: none; }
/* Text entry stays caret-only. Its label marks deliberate keyboard navigation. */
html[data-keyboard] .field:has(input:focus-visible) > label { background: var(--orange-light); color: var(--orange-ink); border-radius: 3px; }
html[data-keyboard] :is(a, button, summary, select):focus-visible { background-color: var(--orange-light); color: var(--orange-ink); }
img { display: block; max-width: 100%; }
[hidden] { display: none !important; }
.wrap { width: min(760px, calc(100% - 48px)); margin-inline: auto; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.skip-link { position: absolute; left: 20px; top: -100px; padding: 12px 20px; background: var(--ink); color: white; z-index: 2; }
.skip-link:focus { top: 10px; }
.site-header { min-height: 84px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-size: 17px; font-weight: 600; letter-spacing: -.025em; line-height: 1.08; }
.site-header nav { display: flex; align-items: center; gap: 30px; font-size: 15px; }
.site-header nav > a:not(.button) { text-decoration: none; }
.site-header nav > a:hover { text-decoration: underline; }
.button { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 12px 23px; border-radius: 100px; background: var(--orange); color: var(--orange-ink); font-size: 16px; font-weight: 550; line-height: 1.2; text-decoration: none; transition: transform .15s, background .15s; }
.button-small { min-height: 44px; font-size: 15px; padding: 10px 19px; background: var(--orange-light); }
.button-dark { background: var(--ink); color: var(--page); }
.button-dark:hover { background: var(--green); }
.button:active, .quiet-button:active { transform: scale(.98); }
.hero { padding-block: 34px 38px; }
.hero h1 { font-size: clamp(36px, 4.7vw, 48px); }
.hero h1 span { display: block; color: var(--green); font-size: .78em; margin-top: 7px; }
.hero > p { max-width: 720px; margin-top: 23px; font-size: 19px; }
.calculator-layout { display: grid; grid-template-columns: minmax(0, 1fr); gap: 24px; }
.inputs-panel { border: 1px solid var(--line); border-radius: 28px; background: white; padding: 28px; min-width: 0; }
.panel-heading { display: flex; justify-content: space-between; align-items: center; gap: 24px; margin-bottom: 24px; }
.panel-heading h2 { font-size: 25px; max-width: 220px; }
label { display: block; font-size: 14px; line-height: 1.4; font-weight: 500; }
label span { font-weight: 400; }
.currency-label { flex: 0 0 104px; font-size: 12px; }
input, select { width: 100%; min-width: 0; min-height: 48px; border: 1px solid #adc5b8; border-radius: 9px; background: white; color: var(--ink); padding: 10px 12px; margin-top: 8px; font-size: 18px; line-height: 1.25; font-variant-numeric: tabular-nums; }
select { font-size: 15px; }
input::placeholder { color: var(--muted); opacity: 1; }
input[aria-invalid=true] { border-color: var(--error); background: #fff8f6; }
.field-help { font-size: 13px; line-height: 1.5; margin-top: 9px; }
.field-pair { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 18px; margin-top: 24px; }
.field-pair label { min-height: 39px; display: flex; align-items: end; }
.field-error { color: var(--error); font-size: 13px; margin-top: 7px; }
.optional-costs { border-top: 1px solid var(--line); margin-top: 24px; padding-top: 18px; }
.optional-costs summary { font-size: 15px; padding-block: 5px; min-height: 38px; }
.optional-costs summary span { color: var(--muted); font-size: 13px; }
.optional-costs .field { padding-block: 15px 3px; }
.toolbar { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 18px; font-size: 12px; color: var(--muted); }
.toolbar > div { display: flex; gap: 8px; }
.quiet-button { background: transparent; border: 0; padding: 8px; color: var(--ink); font-size: 13px; min-height: 44px; text-decoration: underline; text-underline-offset: 4px; border-radius: 6px; transition: transform .15s; }
.results-panel { padding: 35px; background: var(--ink); color: #f5fcf8; border-radius: 28px; min-width: 0; }
.results-panel h2 { font-size: 21px; letter-spacing: -.02em; }
.results-panel p { color: #c5dbd3; font-size: 13px; }
output { display: block; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; letter-spacing: -.045em; line-height: 1.12; }
.main-result { font-size: clamp(40px, 5.5vw, 68px); font-weight: 500; margin: 19px 0 10px; }
.result-details { padding-block: 22px; margin: 0; }
.result-details > div { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; padding-top: 10px; }
.result-details dt { color: #c5dbd3; font-size: 14px; }
.result-details dd { margin: 0; font-size: 20px; font-variant-numeric: tabular-nums; text-align: right; overflow-wrap: anywhere; min-width: 0; }
.after-costs { border-top: 1px solid #52776d; padding-block: 22px; }
.results-panel h3 { font-size: 18px; letter-spacing: -.02em; }
.after-costs output { font-size: 37px; margin-block: 10px; }
.results-panel .loss-note { color: #ffbd98; margin-top: 9px; }
.retention-result { border-top: 1px solid #52776d; padding-top: 24px; }
.retention-result output { color: var(--orange); font-size: clamp(32px, 3.8vw, 46px); margin-block: 10px; }
.retention-result p + p { margin-top: 8px; color: var(--orange); }
.results-panel .result-error { color: #ffd2b8; margin-top: 16px; }
.notice { border-radius: 12px; background: var(--orange-light); padding: 16px; margin-bottom: 18px; color: var(--orange-ink); }
.education { padding-block: 64px 50px; }
.education-layout { display: grid; grid-template-columns: minmax(0, 1fr); gap: 28px; margin-top: 28px; }
.formula { background: var(--mist); border-radius: 24px; padding: 30px; }
.formula p { font-size: 15px; }
.formula strong { display: block; font-size: clamp(26px, 3vw, 38px); font-weight: 500; line-height: 1.2; letter-spacing: -.035em; margin-block: 18px; }
.education-copy h3 { font-size: 22px; margin-bottom: 10px; }
.education-copy p { font-size: 16px; }
.education-copy p + h3 { margin-top: 24px; }
.source-link { display: inline-block; margin-top: 17px; font-size: 13px; color: var(--muted); }
.questions { padding-bottom: 54px; }
.question-list { margin-top: 24px; }
.question-list details { border-bottom: 1px solid var(--line); padding-block: 18px; }
.question-list summary { font-size: 19px; font-weight: 500; }
.question-list p { padding-top: 14px; font-size: 16px; max-width: 780px; }
.next-steps { display: grid; grid-template-columns: minmax(0, 1fr); gap: 28px; }
.help-panel { padding: 34px; background: var(--orange); color: var(--orange-ink); border-radius: 28px; }
.help-panel h2 { font-size: 34px; }
.help-panel p { color: #674026; margin-top: 16px; max-width: 480px; font-size: 17px; }
.help-panel .button { margin-top: 22px; }
.related h3 { font-size: 27px; margin-bottom: 16px; }
.related > a { display: block; padding-block: 12px; font-size: 17px; }
.site-footer { padding-block: 38px; display: flex; align-items: center; justify-content: space-between; gap: 20px; font-size: 13px; }
.site-footer .brand { font-size: 14px; }
@media (max-width: 1050px) {
  .calculator-layout { gap: 20px; }
  .inputs-panel, .results-panel { padding: 24px; }
  .panel-heading { gap: 12px; }
  .panel-heading h2 { font-size: 23px; }
  .education-layout { gap: 28px; }
}
@media (max-width: 760px) {
  .wrap { width: min(760px, calc(100% - 32px)); }
  .site-header { min-height: 74px; }
  .brand { font-size: 14px; }
  .brand img { width: 32px; height: 32px; }
  .site-header nav > a:not(.button) { display: none; }
  .hero { padding-block: 28px 32px; }
  .hero h1 { font-size: clamp(35px, 7vw, 48px); }
  .hero h1 span { font-size: .8em; margin-top: 12px; }
  .hero > p { font-size: 17px; margin-top: 19px; }
  .calculator-layout, .education-layout, .next-steps { grid-template-columns: minmax(0,1fr); }
  .inputs-panel, .results-panel { border-radius: 24px; padding: 23px; }
  .main-result { font-size: clamp(40px, 12vw, 68px); }
  .retention-result output { font-size: 38px; }
  .education { padding-block: 60px 50px; }
  .education-layout { gap: 26px; }
  .formula { padding: 25px; }
  .questions { padding-bottom: 50px; }
  .question-list summary { font-size: 18px; }
  .next-steps { gap: 30px; }
  .help-panel { padding: 28px; }
  .help-panel h2 { font-size: 32px; }
  .related { padding-inline: 8px; }
  .related h3 { max-width: none; }
  .site-footer { flex-wrap: wrap; }
}
@media (max-width: 380px) {
  .inputs-panel, .results-panel { padding: 19px; }
  .panel-heading h2 { font-size: 21px; }
  .field-pair { gap: 12px; }
  label { font-size: 13px; }
  .toolbar { flex-wrap: wrap; }
  .brand { font-size: 13px; }
  .button-small { padding-inline: 14px; font-size: 13px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
  .button:active, .quiet-button:active { transform: none; }
}
