/*
 * What You Keep: Retirement. Quiet Ledger stylesheet.
 *
 * Paper background, teal = what you keep, coral = what leaves, ink for text.
 * Instrument Serif for display, Instrument Sans for body, IBM Plex Mono for money.
 * Audience is 65 plus: large base type, high contrast, generous spacing,
 * print friendly. No network calls: fonts are bundled locally (assets/fonts.css).
 * No em dashes anywhere, ever.
 */

@import url("fonts.css");

:root {
  --paper: #f7f3ea;
  --paper-deep: #efe9db;
  --card: #fffdf7;
  --ink: #1f2a2e;
  --ink-soft: #4a585d;
  --teal: #0e6f66;          /* kept */
  --teal-deep: #0a544d;
  --teal-wash: #0e6f6618;
  --teal-wash-soft: #0e6f660d;
  --coral: #c4503c;         /* leaving */
  --coral-deep: #a23d2c;
  --coral-wash: #c4503c14;
  --coral-wash-soft: #c4503c0a;
  --rule: #d8d0bf;
  --rule-soft: #e6dfcf;
  --focus: #0e6f66;

  --serif: "Instrument Serif", Georgia, "Times New Roman", serif;
  --sans: "Instrument Sans", "Segoe UI", system-ui, Arial, sans-serif;
  --mono: "IBM Plex Mono", "Consolas", monospace;

  --maxw: 1120px;
  --radius: 12px;
  --shadow: 0 1px 2px rgba(31, 42, 46, 0.06), 0 8px 24px rgba(31, 42, 46, 0.06);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 20px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }

.money { font-family: var(--mono); font-weight: 500; white-space: nowrap; font-feature-settings: "tnum" 1; }
.kept { color: var(--teal); font-weight: 600; }
.leaving { color: var(--coral); font-weight: 600; }

a { color: var(--teal-deep); }

:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
  border-radius: 4px;
}

/* ---------- top bar ---------- */
.topbar {
  border-bottom: 1px solid var(--rule);
  background: var(--paper);
}
.topbar .wrap {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; flex-wrap: wrap; padding-top: 16px; padding-bottom: 16px;
}
.brand { font-family: var(--serif); font-size: 30px; line-height: 1.1; }
.brand .sub { font-family: var(--sans); font-size: 14px; color: var(--ink-soft); display: block; letter-spacing: 0.02em; }
.pills { display: flex; gap: 10px; flex-wrap: wrap; }
.pill {
  font-size: 14px; padding: 7px 14px; border: 1px solid var(--rule);
  border-radius: 999px; background: var(--card); color: var(--ink-soft);
  display: inline-flex; align-items: center; gap: 7px;
}
.pill.privacy { border-color: var(--teal); color: var(--teal-deep); font-weight: 600; }
.pill .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--teal); display: inline-block; }

/* ---------- hero ---------- */
.hero { padding: 64px 0 40px; text-align: center; }
.eyebrow {
  font-size: 15px; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--teal-deep); font-weight: 600; margin-bottom: 18px;
}
.hero h1 {
  font-family: var(--serif); font-weight: 400; line-height: 1.05;
  font-size: clamp(40px, 6vw, 68px); letter-spacing: -0.01em;
  max-width: 16ch; margin: 0 auto 22px;
}
.hero .lead {
  font-size: clamp(19px, 2.2vw, 23px); color: var(--ink-soft);
  max-width: 60ch; margin: 0 auto 18px; line-height: 1.5;
}
.hero .lead strong { color: var(--ink); font-weight: 600; }
.hero .reassure { font-size: 17px; color: var(--ink-soft); margin-bottom: 30px; }
.cta-down {
  display: inline-flex; align-items: center; gap: 10px;
  background: var(--ink); color: var(--paper); border: none;
  font-family: var(--sans); font-size: 18px; font-weight: 600;
  padding: 15px 28px; border-radius: 999px; cursor: pointer;
  text-decoration: none;
}
.cta-down:hover { background: var(--teal-deep); }

/* ---------- section scaffold ---------- */
section { padding: 16px 0; }
.section-head { margin-bottom: 18px; }
.section-head h2 {
  font-family: var(--serif); font-weight: 400; font-size: clamp(28px, 3.4vw, 40px);
  line-height: 1.1; margin-bottom: 6px;
}
.section-head p { color: var(--ink-soft); font-size: 18px; max-width: 62ch; }

/* ---------- inputs ---------- */
.calc { padding-top: 24px; }
.panel {
  background: var(--card); border: 1px solid var(--rule);
  border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 26px 28px;
}
.inputs-grid {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px 28px;
}
.field { display: flex; flex-direction: column; gap: 8px; }
.field.full { grid-column: 1 / -1; }
.field label.q { font-size: 18px; font-weight: 600; color: var(--ink); }
.field .help { font-size: 15px; color: var(--ink-soft); line-height: 1.4; }

/* segmented toggle */
.segmented { display: inline-flex; border: 1px solid var(--rule); border-radius: 10px; overflow: hidden; align-self: flex-start; }
.segmented button {
  font-family: var(--sans); font-size: 17px; font-weight: 500;
  padding: 12px 22px; background: var(--card); color: var(--ink-soft);
  border: none; cursor: pointer; min-width: 88px;
}
.segmented button + button { border-left: 1px solid var(--rule); }
.segmented button[aria-pressed="true"] { background: var(--teal); color: #fff; }

/* money / number input */
.money-input { position: relative; display: inline-flex; align-items: center; max-width: 280px; }
.money-input .prefix {
  position: absolute; left: 14px; font-family: var(--mono); color: var(--ink-soft); font-size: 19px;
}
.money-input input {
  font-family: var(--mono); font-size: 21px; font-weight: 500;
  padding: 13px 14px 13px 30px; width: 100%;
  border: 1px solid var(--rule); border-radius: 10px; background: var(--paper);
  color: var(--ink);
}
.money-input.with-suffix input { padding-right: 64px; }
.money-input .suffix { position: absolute; right: 14px; font-size: 15px; color: var(--ink-soft); }
input[type="number"] { -moz-appearance: textfield; appearance: textfield; }
input::-webkit-outer-spin-button, input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }

.wages-row { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.disclosure-btn {
  background: none; border: none; color: var(--teal-deep); font-family: var(--sans);
  font-size: 16px; cursor: pointer; text-decoration: underline; padding: 0; align-self: flex-start;
}

/* ---------- results ---------- */
.results { margin-top: 30px; }

/* the positive headline: total retirement income */
.headline {
  background: var(--teal); color: #fff; border-radius: 16px;
  padding: 28px 30px; margin-bottom: 18px; box-shadow: var(--shadow);
}
.headline-label { font-size: 16px; letter-spacing: 0.04em; text-transform: uppercase; opacity: 0.92; margin-bottom: 6px; }
.headline-figure { font-family: var(--mono); font-size: clamp(40px, 6vw, 64px); font-weight: 500; line-height: 1.05; }
.headline-figure .per { font-family: var(--sans); font-size: 22px; font-weight: 400; opacity: 0.9; }
.headline-note { font-size: 18px; margin-top: 10px; max-width: 60ch; line-height: 1.45; color: #eaf3f1; }

.recap {
  font-size: 18px; color: var(--ink-soft); margin-bottom: 24px;
}
.recap strong { color: var(--ink); }

/* the income map: total income at different super balances */
.incomemap {
  background: var(--card); border: 1px solid var(--rule); border-radius: var(--radius);
  padding: 24px 26px; margin-bottom: 28px;
}
.incomemap h3 { font-family: var(--serif); font-weight: 400; font-size: clamp(24px, 3vw, 32px); margin-bottom: 8px; }
.incomemap p { color: var(--ink-soft); font-size: 17px; max-width: 70ch; margin-bottom: 18px; }
.incomemap .imap-foot { font-size: 14px; margin-top: 14px; margin-bottom: 0; }
.imap-bars { display: flex; align-items: flex-end; gap: 14px; height: 230px; }
.imap-col { flex: 1 1 0; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; height: 100%; text-align: center; }
.imap-val { font-size: 15px; color: var(--ink); margin-bottom: 6px; }
.imap-bar { width: 100%; max-width: 84px; background: var(--teal-wash); border: 1px solid var(--teal); border-bottom: none; border-radius: 6px 6px 0 0; }
.imap-col.here .imap-bar { background: var(--teal); }
.imap-col.here .imap-val { color: var(--teal-deep); font-weight: 700; }
.imap-x { font-size: 13px; color: var(--ink-soft); margin-top: 8px; }
.imap-col.here .imap-x { color: var(--ink); font-weight: 600; }

.bonus {
  border-left: 6px solid var(--teal); background: var(--teal-wash);
  padding: 18px 22px; border-radius: 0 var(--radius) var(--radius) 0; margin-bottom: 28px;
}
.bonus strong.headline { font-family: var(--serif); font-size: clamp(22px, 2.6vw, 28px); font-weight: 400; display: block; margin-bottom: 6px; }

.chart-title { font-family: var(--serif); font-weight: 400; font-size: clamp(26px, 3.2vw, 36px); line-height: 1.1; margin-bottom: 4px; }
.chart-sub { color: var(--ink-soft); font-size: 17px; margin-bottom: 16px; }
.chart-legend { display: flex; gap: 22px; flex-wrap: wrap; font-size: 16px; margin-bottom: 12px; color: var(--ink-soft); }
.chart-legend .swatch { display: inline-block; width: 16px; height: 16px; border-radius: 4px; vertical-align: -2px; margin-right: 7px; }
.chart-legend .swatch.teal { background: var(--teal); }
.chart-legend .swatch.coral { background: var(--coral); }

figure.chart {
  background: var(--card); border: 1px solid var(--rule); border-radius: var(--radius);
  padding: 16px 14px 8px; margin: 0; position: relative;
}
figure.chart svg { width: 100%; height: auto; display: block; touch-action: none; }
figure.chart svg .grid line { stroke: var(--rule); stroke-width: 1; }
figure.chart svg .area-teal { fill: var(--teal); opacity: 0.20; }
figure.chart svg .area-coral { fill: var(--coral); opacity: 0.15; }
figure.chart svg .keepline { fill: none; stroke: var(--teal-deep); stroke-width: 3.5; stroke-linejoin: round; stroke-linecap: round; }
figure.chart svg .ax text { font-family: var(--mono); font-size: 15px; fill: var(--ink-soft); }
figure.chart svg .axtitle { font-family: var(--sans); font-size: 16px; fill: var(--ink-soft); }
figure.chart svg .marks .marker { stroke: var(--ink); stroke-width: 1.4; stroke-dasharray: 6 4; opacity: 0.65; }
figure.chart svg .marks .mlabel { font-family: var(--sans); font-size: 15px; fill: var(--ink); font-weight: 500; }
figure.chart svg .marks .msub { font-family: var(--sans); font-size: 13px; fill: var(--ink-soft); }
figure.chart svg .cursor .cline { stroke: var(--ink); stroke-width: 2; }
figure.chart svg .cursor .cdot { fill: var(--teal-deep); stroke: var(--card); stroke-width: 2.5; }
figure.chart svg .hit { cursor: crosshair; }

.readout {
  margin: 18px 0 26px; padding: 18px 22px; border: 2px solid var(--ink);
  border-radius: var(--radius); background: var(--card); font-size: clamp(19px, 2.2vw, 22px);
  line-height: 1.45;
}

/* dollars summary */
.dollars { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-bottom: 28px; }
.stat { background: var(--card); border: 1px solid var(--rule); border-radius: var(--radius); padding: 16px 18px; }
.stat .label { font-size: 15px; color: var(--ink-soft); margin-bottom: 6px; }
.stat .value { font-family: var(--mono); font-size: clamp(22px, 2.6vw, 28px); font-weight: 500; }
.stat .value.kept { color: var(--teal); }
.stat .note { font-size: 14px; color: var(--ink-soft); margin-top: 4px; }

/* zone cards */
.zones { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 30px; }
.zone { border-radius: var(--radius); padding: 16px 18px; font-size: 16px; border: 1px solid var(--rule); background: var(--card); }
.zone h3 { font-family: var(--serif); font-size: 20px; font-weight: 400; margin-bottom: 4px; }
.zone .rng { font-size: 14px; color: var(--ink-soft); margin-bottom: 8px; }
.zone .keeprate { font-family: var(--mono); font-size: 24px; display: block; margin-bottom: 6px; }
.zone.teal { border-top: 5px solid var(--teal); }
.zone.teal .keeprate { color: var(--teal); }
.zone.coral { border-top: 5px solid var(--coral); }
.zone.coral .keeprate { color: var(--coral); }

/* sweet spot map */
.sweetspot { background: var(--card); border: 1px solid var(--rule); border-radius: var(--radius); padding: 22px 24px; margin-bottom: 28px; }
.sweetspot h3 { font-family: var(--serif); font-weight: 400; font-size: 24px; margin-bottom: 6px; }
.sweetspot p { color: var(--ink-soft); font-size: 17px; margin-bottom: 16px; }
.spot-bar { position: relative; height: 54px; border-radius: 8px; overflow: hidden; border: 1px solid var(--rule); display: flex; }
.spot-seg { display: flex; align-items: center; justify-content: center; font-size: 14px; color: #fff; text-align: center; padding: 0 6px; }
.spot-seg.full { background: var(--teal); }
.spot-seg.part { background: var(--coral); }
.spot-seg.none { background: var(--ink-soft); }
.spot-marker { position: absolute; top: -6px; bottom: -6px; width: 3px; background: var(--ink); }
.spot-marker .lbl { position: absolute; top: -26px; left: 50%; transform: translateX(-50%); white-space: nowrap; font-size: 13px; background: var(--ink); color: var(--paper); padding: 2px 7px; border-radius: 4px; }
.spot-scale { display: flex; justify-content: space-between; font-family: var(--mono); font-size: 13px; color: var(--ink-soft); margin-top: 8px; }

/* ---------- super projection ---------- */
.select {
  font-family: var(--sans); font-size: 19px; padding: 12px 14px;
  border: 1px solid var(--rule); border-radius: 10px; background: var(--paper); color: var(--ink);
  max-width: 280px;
}
.proj-result { margin-top: 24px; }
.proj-figure { display: flex; gap: 16px; flex-wrap: wrap; margin-bottom: 16px; }
.proj-block { flex: 1 1 240px; background: var(--paper-deep); border-radius: var(--radius); padding: 18px 20px; }
.proj-label { font-size: 15px; color: var(--ink-soft); margin-bottom: 6px; }
.proj-val { font-family: var(--mono); font-size: clamp(28px, 4vw, 38px); font-weight: 500; }
.proj-sub { font-size: 14px; color: var(--ink-soft); margin-top: 4px; }
.proj-explain { font-size: 16px; color: var(--ink-soft); margin-bottom: 14px; max-width: 75ch; }
.proj-note { font-size: 17px; color: var(--ink-soft); }
.proj-warn {
  border-left: 6px solid var(--ink-soft); background: var(--paper-deep);
  padding: 14px 18px; border-radius: 0 10px 10px 0; font-size: 15px; color: var(--ink-soft); line-height: 1.45;
}
.proj-warn strong { color: var(--ink); }

/* ---------- offer ---------- */
.offer {
  background: var(--ink); color: var(--paper); border-radius: 16px;
  padding: 40px 36px; margin: 36px 0; text-align: center;
}
.offer h2 { font-family: var(--serif); font-weight: 400; font-size: clamp(28px, 3.6vw, 40px); margin-bottom: 12px; color: var(--paper); }
.offer p { color: #d9e0df; font-size: 18px; max-width: 56ch; margin: 0 auto 16px; }
.offer ul { list-style: none; max-width: 46ch; margin: 0 auto 26px; text-align: left; display: grid; gap: 10px; }
.offer ul li { font-size: 17px; padding-left: 30px; position: relative; color: #eef2f1; }
.offer ul li::before { content: ""; position: absolute; left: 0; top: 9px; width: 13px; height: 8px; border-left: 3px solid var(--teal); border-bottom: 3px solid var(--teal); transform: rotate(-45deg); }
.offer .price { font-family: var(--mono); font-size: 30px; font-weight: 500; margin-bottom: 6px; }
.offer .price small { font-size: 17px; color: #c5cecc; }
.offer .cta {
  display: inline-block; background: var(--teal); color: #fff; font-weight: 700;
  font-size: 19px; padding: 16px 38px; border-radius: 999px; text-decoration: none; border: none; cursor: pointer;
}
.offer .cta:hover { background: #12867b; }
.offer .finehint { font-size: 14px; color: #aebab8; margin-top: 14px; }

/* ---------- honesty + disclaimers ---------- */
.honesty {
  border-left: 6px solid var(--coral); background: var(--coral-wash);
  padding: 16px 22px; border-radius: 0 var(--radius) var(--radius) 0; margin-bottom: 26px; font-size: 17px;
}
.disclaimers { border-top: 1px solid var(--rule); padding: 24px 0 8px; font-size: 16px; color: var(--ink-soft); }
.disclaimers p { margin-bottom: 10px; max-width: 80ch; }
.disclaimers strong { color: var(--ink); }

footer.site { border-top: 1px solid var(--rule); padding: 24px 0 60px; color: var(--ink-soft); font-size: 15px; }
footer.site .wrap { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }

.print-btn {
  background: none; border: 1px solid var(--rule); border-radius: 8px;
  color: var(--ink); font-family: var(--sans); font-size: 15px; padding: 9px 16px; cursor: pointer;
}
.print-btn:hover { border-color: var(--ink); }

.visually-hidden {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* ---------- responsive ---------- */
@media (max-width: 880px) {
  body { font-size: 19px; }
  .inputs-grid { grid-template-columns: 1fr; }
  .dollars { grid-template-columns: 1fr; }
  .zones { grid-template-columns: 1fr 1fr; }
  .hero { padding: 44px 0 28px; }
}
@media (max-width: 520px) {
  .zones { grid-template-columns: 1fr; }
  .wrap { padding: 0 16px; }
  .panel { padding: 20px 18px; }
}

/* ---------- print (the cohort prints results) ---------- */
@media print {
  :root { --paper: #fff; --card: #fff; }
  body { font-size: 13px; background: #fff; }
  .topbar, .hero, .cta-down, .disclosure-btn, .print-btn, .offer .cta, .chart-legend { display: none !important; }
  .offer { background: #fff; color: var(--ink); border: 1px solid #999; }
  .offer h2, .offer p { color: var(--ink); }
  .panel, figure.chart, .stat, .zone, .sweetspot, .bonus, .readout { box-shadow: none; border-color: #bbb; break-inside: avoid; }
  section { padding: 8px 0; }
  a { color: var(--ink); text-decoration: none; }
  .results { margin-top: 0; }
}

/* Free family and retirement tools, September 2026. */
.hero { padding-top: 2rem; padding-bottom: 1rem; }
.hero-title { max-width: 850px; font-size: clamp(2.2rem, 4.4vw, 4rem); }
.hero-sub { max-width: 720px; }
.hero-trust { margin: 1rem 0; }
.tool-nav { display:flex; gap:.7rem; flex-wrap:wrap; padding:1rem 0; align-items:center; }
.tool-nav a { padding:.65rem 1rem; border:1px solid #b6c8c4; border-radius:6px; color:#174e47; font-size:1rem; text-decoration:none; }
.tool-nav a[aria-current] { background:#165e54; color:white; }
.tool-nav a:last-child { margin-left:auto; }
.practice-card { border-top:3px solid #165e54; padding:2rem 0; margin:2rem 0; }
.practice-card h2 { font-size:2rem; margin:.5rem 0; }
.practice-card p { max-width:750px; font-size:1rem; line-height:1.65; }
.practice-note { color:#4b5d58; margin-top:1rem; }
@media(max-width:650px) { .tool-nav a:last-child { margin-left:0; } .header-right .header-cta { display:none; } .rates-badge { white-space:normal; } }
@media print { .tool-nav,.practice-card { display:none; } }
