:root {
  --bg: #f7f7f5; --card: #ffffff; --ink: #1d1f23; --muted: #5f6570; --line: #e3e3de;
  --accent: #b5491d; --accent-ink: #ffffff; --good: #1d7a46; --bad: #b42318; --soft: #f1efe9;
  --radius: 12px; --shadow: 0 1px 2px rgba(0,0,0,.05);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #141517; --card: #1d1f22; --ink: #ecebe7; --muted: #a3a7ae; --line: #2e3136;
    --accent: #f08a5d; --accent-ink: #1a1a1a; --good: #5cc98b; --bad: #ff8a80; --soft: #24262a;
  }
}
:root[data-theme="dark"] {
  --bg: #141517; --card: #1d1f22; --ink: #ecebe7; --muted: #a3a7ae; --line: #2e3136;
  --accent: #f08a5d; --accent-ink: #1a1a1a; --good: #5cc98b; --bad: #ff8a80; --soft: #24262a;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 16px/1.55 system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
a { color: var(--accent); }
.wrap { max-width: 920px; margin: 0 auto; padding: 0 16px; }
header.site { border-bottom: 1px solid var(--line); background: var(--card); }
header.site .wrap { display: flex; align-items: center; justify-content: space-between; height: 56px; }
header.site a.brand { color: var(--ink); text-decoration: none; font-weight: 700; letter-spacing: -.01em; }
header.site nav a { color: var(--muted); text-decoration: none; font-size: 14px; margin-left: 16px; }
h1 { font-size: 30px; line-height: 1.2; margin: 28px 0 8px; letter-spacing: -.02em; }
h2 { font-size: 20px; margin: 0 0 12px; }
h3 { font-size: 16px; margin: 0 0 6px; }
.lead { color: var(--muted); margin: 0 0 20px; max-width: 62ch; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 20px; margin-bottom: 16px; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 16px; }
@media (max-width: 640px) { .grid2 { grid-template-columns: 1fr; } h1 { font-size: 25px; } }
label { display: block; font-weight: 600; font-size: 14px; margin-bottom: 4px; }
.hint { display: block; color: var(--muted); font-size: 12.5px; font-weight: 400; margin-top: 3px; }
.money { position: relative; }
.money::before { content: "$"; position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--muted); pointer-events: none; }
.money input[type="number"] { padding-left: 26px; }
.pct input[type="number"] { padding-right: 30px; }
.pct { position: relative; }
.pct::after { content: "%"; position: absolute; right: 12px; top: 50%; transform: translateY(-50%); color: var(--muted); pointer-events: none; }
input[type="number"] {
  width: 100%; font: inherit; font-size: 17px; color: var(--ink); background: var(--bg);
  border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; font-variant-numeric: tabular-nums;
}
select {
  width: 100%; font: inherit; font-size: 16px; color: var(--ink); background: var(--bg);
  border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px;
}
select:focus, input[type="number"]:focus, .seg input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 1px; }
.seg { display: flex; gap: 8px; flex-wrap: wrap; }
.seg label { margin: 0; font-weight: 500; }
.seg input { position: absolute; opacity: 0; }
.seg span { display: inline-block; padding: 8px 12px; border: 1px solid var(--line); border-radius: 8px; cursor: pointer; font-size: 14px; background: var(--bg); }
.seg input:checked + span { border-color: var(--accent); background: var(--soft); font-weight: 700; }
details.more { margin-top: 16px; border-top: 1px dashed var(--line); padding-top: 12px; }
details.more summary { cursor: pointer; font-weight: 600; font-size: 14px; color: var(--muted); }
details.more .grid2 { margin-top: 14px; }
.check { display: flex; gap: 8px; align-items: flex-start; font-weight: 500; }
.check input { margin-top: 4px; }
.outcomes { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 16px; }
@media (max-width: 520px) { .outcomes { grid-template-columns: 1fr; } }
.outcome { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; }
.outcome .tag { font-size: 12.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
.outcome .big { font-size: 32px; font-weight: 800; letter-spacing: -.02em; font-variant-numeric: tabular-nums; margin: 4px 0; }
.outcome .sub { font-size: 14px; color: var(--muted); }
.pos { color: var(--good); } .neg { color: var(--bad); }
table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
th, td { padding: 9px 6px; border-bottom: 1px solid var(--line); text-align: right; vertical-align: top; }
th:first-child, td:first-child { text-align: left; }
td:not(:first-child) { white-space: nowrap; }
.tablewrap { overflow-x: auto; }
@media (max-width: 360px) { th, td { padding: 8px 3px; font-size: 14px; } .card { padding: 16px 12px; } }
thead th { font-size: 12.5px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
td small { display: block; color: var(--muted); font-size: 12px; font-weight: 400; }
tr.total td { font-weight: 700; }
tr.strong td { font-weight: 800; border-bottom: 0; }
.row-target { display: flex; gap: 12px; align-items: end; flex-wrap: wrap; margin-bottom: 12px; }
.row-target > div { flex: 1 1 200px; max-width: 260px; }
.partners { display: grid; gap: 10px; }
.partner { display: block; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; text-decoration: none; color: var(--ink); background: var(--bg); }
.partner b { color: var(--accent); }
.disclose { font-size: 13px; color: var(--muted); margin: 0 0 10px; }
.note { font-size: 13.5px; color: var(--muted); }
.faq details { border-bottom: 1px solid var(--line); padding: 12px 0; }
.faq summary { cursor: pointer; font-weight: 600; }
.faq p { margin: 8px 0 0; }
footer.site { color: var(--muted); font-size: 13px; padding: 24px 0 40px; }
footer.site a { color: var(--muted); }
.tools a.tool { display: block; text-decoration: none; color: var(--ink); }
.tools a.tool b { color: var(--accent); font-size: 18px; }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 16px; top: 8px; background: var(--card); padding: 6px 10px; }
