:root {
  color-scheme: light;
  --paper: #f7f5f0;
  --white: #fffefa;
  --ink: #25222a;
  --muted: #5e5861;
  --plum: #38263e;
  --line: #ded9d3;
  --orange: #f2a776;
  --green: #2b644e;
  --red: #a3313f;
  font-family: system-ui, -apple-system, sans-serif;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--ink); line-height: 1.5; }
a { color: #583969; text-underline-offset: .18em; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid #9754ab; outline-offset: 4px; }
button, input, select { font: inherit; }
button { cursor: pointer; }
[hidden] { display: none !important; }
.wrap { width: min(1200px, 100% - 72px); margin-inline: auto; }
.skip { position: fixed; z-index: 5; top: 1rem; left: 1rem; padding: .6rem; background: white; transform: translateY(-200%); }
.skip:focus { transform: none; }
.site-header { border-bottom: 1px solid var(--line); background: var(--white); }
.header-row, .footer-row { min-height: 72px; display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.brand { display: inline-flex; align-items: center; gap: .65rem; color: var(--ink); text-decoration: none; font-weight: 750; white-space: nowrap; }
.mark { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 9px; background: var(--plum); color: var(--orange); font-size: 24px; line-height: 1; }
nav { display: flex; gap: clamp(.75rem, 3vw, 2.4rem); flex-wrap: wrap; }
nav a { color: var(--muted); font-size: .9rem; font-weight: 650; text-decoration: none; }
nav a[aria-current] { color: var(--plum); text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: .38rem; }
.hero { overflow: hidden; position: relative; isolation: isolate; margin-top: 32px; border-radius: 22px; background: var(--plum); color: var(--white); padding: clamp(1.6rem, 5.4vw, 4.1rem); }
.hero-content { position: relative; z-index: 1; }
.hero .eyebrow { color: #f8b690; }
.eyebrow { margin: 0 0 .6rem; color: #795167; font-size: .875rem; font-weight: 750; letter-spacing: .12em; text-transform: uppercase; }
.dot { display: inline-block; vertical-align: .12em; height: .45rem; width: .45rem; border-radius: 50%; background: currentColor; margin-right: .35rem; }
h1, h2, .total, .budget-stat output { font-family: Georgia, serif; }
h1 { margin: 0; font-size: clamp(2.75rem, 6.8vw, 5.45rem); letter-spacing: -.055em; line-height: .99; font-weight: 500; }
.hero p:not(.eyebrow) { max-width: 36rem; color: #f0e4f0; font-size: clamp(1rem, 2vw, 1.2rem); margin: 1.25rem 0 1.6rem; }
.hero-actions, .button-group { display: flex; flex-wrap: wrap; gap: .65rem; }
.button { display: inline-flex; align-items: center; justify-content: center; border: 1px solid transparent; border-radius: 8px; min-height: 44px; padding: .57rem .9rem; font-weight: 700; font-size: .875rem; text-decoration: none; }
.primary { background: var(--orange); color: #2a1d29; }
.primary:hover { background: #ffba8c; }
.secondary { background: var(--white); border-color: var(--line); color: var(--plum); }
.secondary:hover { background: #f1e8f1; }
.hero .secondary { background: transparent; border-color: #9a839f; color: var(--white); }
.hero .secondary:hover { background: #56415c; }
.hero a:focus-visible { outline-color: var(--orange); }
.hero-art { position: absolute; inset: 0 0 0 auto; width: 49%; pointer-events: none; }
.art-orbit { position: absolute; right: -20%; top: -40%; width: 126%; aspect-ratio: 1; border-radius: 50%; background: repeating-radial-gradient(circle at center, transparent 0 27px, #ffffff14 28px 29px, transparent 30px 47px); }
.art-tiles { position: absolute; right: 10%; top: 50%; transform: translateY(-38%) rotate(-13deg); display: flex; align-items: end; gap: clamp(.4rem, 1.2vw, 1rem); height: 52%; width: 61%; }
.art-tiles i { flex: 1; height: 34%; border-radius: 10px 10px 3px 3px; background: #b393bb; }
.art-tiles i:nth-child(2) { height: 55%; background: #d6bad9; }
.art-tiles i:nth-child(3) { height: 46%; background: #e4cce4; }
.art-tiles i:nth-child(4) { height: 80%; background: #d28570; }
.art-tiles i:nth-child(5) { height: 100%; background: var(--orange); }
.hero-small .art-tiles { opacity: .7; }
.notice { display: flex; align-items: flex-start; gap: .75rem; margin: 1.15rem 0 0; padding: .9rem 1rem; border: 1px solid #ead8ad; border-radius: 10px; background: #fff3d9; color: #503d24; }
.notice p { margin: 0; font-size: .92rem; }
.info { flex: 0 0 20px; height: 20px; border: 1px solid currentColor; border-radius: 50%; text-align: center; font: bold .8rem/18px Georgia, serif; }
.compact { background: #f1eaf1; border-color: #e4d8e6; color: #493650; }
.planner { margin-top: 3.3rem; scroll-margin-top: 1rem; }
.section-head { display: flex; align-items: end; justify-content: space-between; gap: 1rem; margin-bottom: 1rem; }
.section-head h2 { margin: 0; font-size: clamp(2rem, 4.5vw, 3.15rem); letter-spacing: -.045em; line-height: 1.1; font-weight: 500; }
.section-head p:not(.eyebrow) { margin: .42rem 0 0; color: var(--muted); }
.panel { background: var(--white); border: 1px solid var(--line); border-radius: 13px; min-width: 0; }
.common { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; padding: 1.15rem; }
label { display: block; margin-bottom: .35rem; color: var(--ink); font-weight: 650; font-size: .875rem; }
input, select { width: 100%; min-width: 0; min-height: 44px; padding: .5rem .6rem; color: var(--ink); border: 1px solid #bdb3bb; border-radius: 7px; background: #fff; }
input::placeholder { color: #746c76; opacity: 1; }
input:invalid { border-color: var(--red); box-shadow: inset 0 0 0 1px var(--red); }
select { appearance: none; padding-right: 1.5rem; background: linear-gradient(45deg, transparent 50%, #5c4d64 50%) right 15px center / 5px 5px no-repeat, linear-gradient(135deg, #5c4d64 50%, transparent 50%) right 10px center / 5px 5px no-repeat, white; }
.common-note, .budget-note { grid-column: 1 / -1; margin: 0; color: var(--muted); font-size: .875rem; }
.scenario-grid, .resource-grid, .budget-summary { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; margin-top: 1rem; }
.scenario { overflow: hidden; display: flex; flex-direction: column; }
.scenario-head { padding: 1.15rem; min-height: 155px; border-bottom: 1px solid var(--line); background: #ece7f3; }
.scenario:nth-child(2) .scenario-head { background: #f9e4d7; }
.scenario:nth-child(3) .scenario-head { background: #e2ede6; }
h3 { margin: 0; font-size: 1.12rem; line-height: 1.3; }
.scenario-head p { margin: .28rem 0 .6rem; color: #514653; font-size: .875rem; }
.total, .budget-stat output { display: block; font-size: clamp(1.9rem, 3.8vw, 2.75rem); color: var(--plum); line-height: 1; overflow-wrap: anywhere; font-variant-numeric: lining-nums tabular-nums; }
.scenario-body { padding: 1.05rem 1.15rem 1.15rem; display: grid; gap: .8rem; }
.line-items { margin: 0; display: grid; gap: .28rem; }
.line-items div { display: flex; align-items: baseline; justify-content: space-between; gap: .5rem; font-size: .875rem; }
.line-items dt { color: var(--muted); }
.line-items dd { margin: 0; text-align: right; font-weight: 650; }
details { border-top: 1px solid var(--line); padding-top: .7rem; }
summary { cursor: pointer; font-weight: 700; color: #583969; font-size: .875rem; }
.scenario-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .7rem .55rem; padding-top: .75rem; }
.method { margin-top: 1.1rem; padding: .9rem 1rem; border: 1px solid var(--line); border-radius: 10px; font-size: .875rem; }
.method p { margin: .25rem 0 0; color: var(--muted); }
.budget-summary { margin-bottom: 1rem; }
.budget-stat { padding: 1rem 1.15rem; }
.budget-stat span { display: block; color: var(--muted); font-weight: 650; font-size: .875rem; margin-bottom: .5rem; }
.budget-stat output.negative { color: var(--red); }
.budget-stat output.positive { color: var(--green); }
.budget-panel { padding: 1.1rem; }
.budget-row { display: grid; grid-template-columns: minmax(0, 1.2fr) repeat(2, minmax(0, 1fr)); align-items: center; gap: .6rem; padding: .42rem 0; border-bottom: 1px solid #ebe5e9; }
.budget-columns { font-weight: 720; font-size: .875rem; padding: 0 0 .5rem; }
.budget-note { margin-top: .8rem; }
.resource { padding: 1.2rem; display: flex; flex-direction: column; align-items: flex-start; gap: .5rem; }
.resource p { color: var(--muted); margin: 0 0 .2rem; }
.resource a { margin-top: auto; font-size: .9rem; font-weight: 700; }
.resource-picker { margin-top: 1.5rem; padding: 1.15rem; }
.resource-picker select { max-width: 20rem; }
.jurisdiction-status:empty { display: none; }
footer { margin-top: 3rem; border-top: 1px solid var(--line); background: var(--white); }
.footer-row { padding-block: .8rem; font-size: .875rem; }
.footer-row span { font-weight: 750; }
.footer-row p { margin: 0; color: var(--muted); }
@media (max-width: 960px) {
  .common { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hero-art { width: 40%; opacity: .68; }
}
@media (max-width: 720px) {
  .wrap { width: calc(100% - 32px); }
  .header-row, .footer-row { flex-wrap: wrap; gap: .65rem; padding-block: .75rem; }
  .hero { margin-top: 18px; }
  .hero-art { opacity: .22; width: 62%; }
  .wide-only { display: none; }
  .section-head { align-items: start; flex-direction: column; }
  .planner { margin-top: 2.6rem; }
  .scenario-grid, .resource-grid { grid-template-columns: 1fr; gap: .75rem; }
  .scenario-head { min-height: 0; }
  .budget-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .55rem; }
  .budget-stat { padding: .85rem; }
  .budget-stat:last-child { grid-column: 1 / -1; }
}
@media (max-width: 380px) {
  .common { grid-template-columns: 1fr; }
  .budget-row { gap: .35rem; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
@media print {
  .site-header, .hero-actions, .hero-art, .button-group, #reset-cost, footer a, .skip { display: none; }
  body, .hero { color: black; background: white; }
  .hero { padding: 0; margin-top: 0; }
  .hero .eyebrow, .hero p:not(.eyebrow) { color: black; }
  .wrap { width: 100%; }
  .panel, .notice, .budget-row { break-inside: avoid; }
}

.source-list { margin: .45rem 0 .55rem; padding-left: 1.3rem; color: var(--muted); }
.source-list li + li { margin-top: .35rem; }
.benchmark { margin: .1rem 0 0; color: var(--muted); font-size: .875rem; }
.benchmark strong { display: block; color: var(--plum); }
.support-grid { display: grid; grid-template-columns: 2fr 1fr; gap: 1rem; margin-top: 1rem; }
.support-form, .support-result { padding: 1.15rem; }
.support-inputs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .95rem; }
.support-inputs label { min-height: 2.65em; }
.support-inputs :is(input, select) + p { margin-top: .35rem; }
.support-result { background: #e2ede6; }
.support-result p:not(.eyebrow) { margin-top: .6rem; }
.support-result .button { margin-top: .7rem; }
button:disabled { cursor: default; opacity: .65; }
.ad-slot { display: grid; place-content: center; min-height: 110px; margin-top: 2.5rem; padding: 1rem; border: 1px dashed #bdb3bb; border-radius: 10px; text-align: center; color: var(--muted); }
.ad-slot span { font-weight: 700; font-size: .875rem; }
.ad-slot p { margin: .25rem 0 0; }
@media (max-width: 720px) { .support-grid { grid-template-columns: 1fr; } }
@media (max-width: 390px) { .support-inputs { grid-template-columns: 1fr; } .support-inputs label { min-height: 0; } }
@media print { #support-example, #support-apply, .ad-slot { display: none; } }

.worksheet-actions { margin-top: auto; }
.resource .common-note:empty { display: none; }
.worksheet-editor {
  width: min(660px, calc(100% - 24px));
  max-height: 90dvh;
  padding: clamp(1rem, 4vw, 1.5rem);
  border: 1px solid var(--line);
  border-radius: 15px;
  background: var(--white);
  color: var(--ink);
}
.worksheet-editor::backdrop { background: #25222a99; }
.worksheet-heading { display: flex; justify-content: space-between; align-items: start; gap: .8rem; }
.worksheet-heading h2 { margin: 0; font-size: clamp(1.55rem, 5vw, 2.35rem); line-height: 1.12; }
.worksheet-fields { display: grid; gap: .85rem; margin-block: 1.1rem; }
.worksheet-fields textarea {
  min-height: 4.7rem;
  width: 100%;
  resize: vertical;
  padding: .55rem .65rem;
  border: 1px solid #bdb3bb;
  border-radius: 7px;
  color: var(--ink);
  background: white;
  font: inherit;
}
#worksheet-status:not(:empty) { margin-top: .6rem; }
.print-worksheet { display: none; }
.privacy-content { max-width: 52rem; padding: clamp(1rem, 4vw, 1.6rem); }
.privacy-content h2 { margin: 1.45rem 0 .4rem; font-size: 1.45rem; }
.privacy-content h2:first-child { margin-top: 0; }
.privacy-content p { margin: 0; }
@media print {
  body.worksheet-printing > :not(.print-worksheet) { display: none !important; }
  body.worksheet-printing > .print-worksheet { display: block; }
  .worksheet-printing .print-worksheet h1 { font-size: 26pt; }
  .worksheet-printing .print-worksheet h2 { break-after: avoid; font-size: 14pt; margin-bottom: .35rem; }
  .worksheet-printing .print-worksheet p { white-space: pre-wrap; overflow-wrap: anywhere; margin-top: 0; }
}
