@font-face {
  font-family: Jost;
  src: url("assets/jost-latin.woff2") format("woff2");
  font-weight: 400 700;
  font-display: swap;
}
@font-face {
  font-family: "Source Sans 3";
  src: url("assets/sourcesans3-latin.woff2") format("woff2");
  font-weight: 400 700;
  font-display: swap;
}

:root {
  color-scheme: light;
  --slate: #3a3d50;
  --ink: #1a1b24;
  --muted: #515567;
  --page: #f5f5f7;
  --line: #d2d4dc;
  --control: #8b8e9d;
  --berry: #b30c37;
  --plum: #760474;
  --heading: Jost, "Segoe UI", sans-serif;
  --body: "Source Sans 3", "Segoe UI", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-padding-block: 1rem; }
body { margin: 0; background: var(--page); color: var(--ink); font: 1rem/1.45 var(--body); }
[hidden] { display: none !important; }
h1, h2, h3, p, dl { margin: 0; }
h1, h2, h3 { font-family: var(--heading); line-height: 1.15; }
h1 { font-size: clamp(2.25rem, 4vw, 3.15rem); font-weight: 700; letter-spacing: -.025em; }
h2 { font-size: clamp(1.4rem, 2.35vw, 1.9rem); font-weight: 650; margin-bottom: .65rem; }
h3 { font-size: 1.2rem; font-weight: 600; }
a { color: inherit; text-underline-offset: .2em; }
a:hover { color: var(--berry); }
:focus-visible { outline: 3px solid var(--plum); outline-offset: 3px; }
button, input, select { font: inherit; }
button, select, summary { cursor: pointer; }
button:disabled { opacity: .65; cursor: wait; }
.sr-only, .message[data-tone="success"] {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}
.skip { position: absolute; z-index: 3; translate: 0 -110%; padding: .7rem; background: white; }
.skip:focus { translate: 0 0; }
.shell { width: min(100% - 5rem, 92rem); margin-inline: auto; }

.masthead { background: white; border-bottom: 1px solid var(--line); }
.utility-bar { background: var(--slate); color: white; font-size: 1.05rem; padding: .54rem 0; }
.masthead-inner { display: flex; align-items: center; min-height: 6.7rem; gap: clamp(1rem, 3vw, 2.6rem); padding-block: .6rem; }
.brand-link { display: block; flex: none; }
.brand { width: clamp(8rem, 12vw, 11rem); height: auto; display: block; }
.service-area { border-left: 1px solid var(--control); padding: .55rem 0 .55rem clamp(1rem, 3vw, 2.6rem); font-size: clamp(1rem, 1.65vw, 1.33rem); }
.site-nav { display: flex; margin-left: auto; align-items: center; gap: clamp(.7rem, 1.75vw, 1.6rem); }
.site-nav a { color: var(--slate); font-weight: 700; font-size: 1.08rem; text-decoration: none; white-space: nowrap; line-height: 1.2; }
.site-nav a + a { border-left: 1px solid var(--control); padding-left: clamp(.7rem, 1.75vw, 1.6rem); }
.site-nav a:hover { color: var(--berry); text-decoration: underline; }

.workspace { padding-block: clamp(1.45rem, 2.4vw, 2.15rem) 2.5rem; }
.intro, .mode-switch { margin-inline: clamp(0rem, .75vw, .65rem); }
.intro p { max-width: 60rem; margin-top: .55rem; font-size: clamp(1.05rem, 1.5vw, 1.25rem); color: var(--slate); }
.intro p + p { margin-top: .5rem; }
.mode-switch { display: flex; gap: .9rem; margin-block: 1.55rem; }
.mode-switch button { border: 1px solid var(--control); border-radius: 999px; background: transparent; padding: .6rem 1.95rem; color: var(--ink); font-size: clamp(1rem, 1.65vw, 1.4rem); }
.mode-switch button[aria-pressed="true"] { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); font-weight: 700; }
.mode-switch button:hover { background: #ebecf1; }

.panel { min-width: 0; border: 1px solid var(--line); border-radius: .95rem; padding: clamp(1rem, 1.55vw, 1.5rem); background: white; }
.lookup-form { display: grid; grid-template-columns: minmax(9rem, 1.25fr) minmax(12rem, 2.15fr) minmax(6rem, 1fr) minmax(8rem, .93fr); align-items: end; gap: clamp(.75rem, 1.65vw, 1.55rem); }
label { display: grid; gap: .4rem; font-weight: 650; font-size: 1rem; }
.lookup label { font-size: clamp(1rem, 1.45vw, 1.28rem); }
input, select {
  appearance: none;
  background: white;
  color: var(--ink);
  border: 1px solid var(--control);
  padding: .62rem .86rem;
  min-height: 2.9rem;
  width: 100%;
  min-width: 0;
  border-radius: .6rem;
  font-weight: 450;
}
.lookup-form input, .lookup-form select, #search { min-height: clamp(3rem, 3.9vw, 3.6rem); }
input::placeholder { color: #636779; opacity: 1; }
input:hover, select:hover { border-color: var(--slate); }
select {
  padding-right: 1.95rem;
  background-image: linear-gradient(45deg, transparent 50%, var(--slate) 50%), linear-gradient(135deg, var(--slate) 50%, transparent 50%);
  background-position: calc(100% - 17px) 50%, calc(100% - 12px) 50%;
  background-size: 5px 5px;
  background-repeat: no-repeat;
}
.primary, .secondary { border: 1px solid var(--control); min-height: 2.9rem; border-radius: .6rem; padding: .6rem .92rem; font-weight: 650; }
.primary { background: var(--slate); color: white; border-color: transparent; }
.primary:hover { background: var(--ink); }
#search { background: linear-gradient(112deg, var(--berry), var(--plum)); font-size: clamp(1.05rem, 1.55vw, 1.4rem); font-weight: 700; }
#search:hover { background: linear-gradient(112deg, #98092e, #5e045d); }
.secondary { background: white; color: var(--ink); }
.secondary:hover { background: #eeeff4; border-color: var(--slate); }
.hint, .support, .message { color: var(--muted); }
.hint { font-size: .94rem; font-weight: 400; margin-top: .55rem; }
.lookup > .hint { font-size: 1.04rem; }
label .hint { margin-top: .08rem; }
.support { margin-bottom: .9rem; }
.message { font-size: .97rem; padding: .65rem .8rem; margin-top: .75rem; background: var(--page); border-radius: .45rem; border-left: .2rem solid var(--slate); }
.message[data-tone="error"] { background: #fff1f3; border-color: var(--berry); color: #81092b; }

.workspace-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2.04fr); gap: clamp(1rem, 1.55vw, 1.5rem); align-items: start; margin-top: 1.55rem; }
.estimate-column { display: grid; min-width: 0; gap: 1rem; }
.match-panel[hidden] + .estimate-column { grid-column: 1 / -1; }
.match-panel { min-height: 16.5rem; }
.matches { padding: .25rem; list-style: none; display: grid; gap: .65rem; margin: .9rem -.25rem 0; max-height: 31rem; overflow-y: auto; }
.match { display: grid; gap: .12rem; width: 100%; background: white; border: 1px solid var(--line); border-radius: .55rem; padding: .75rem .95rem; text-align: left; color: var(--ink); overflow-wrap: anywhere; }
.match strong { font-size: 1.25rem; font-weight: 600; line-height: 1.2; }
.match span, .match small { color: var(--muted); font-size: .88rem; }
.match:hover { border-color: var(--control); background: #f3f3f7; }
.match[aria-pressed="true"] { background: #eaebf0; box-shadow: inset .3rem 0 var(--berry); }
.match[aria-pressed="true"] strong { font-weight: 700; }

details { margin-top: .95rem; border-top: 1px solid var(--line); padding-top: .7rem; }
summary { font-size: .97rem; font-weight: 650; }
details p { margin-top: .6rem; }
.lookup > details:not([open]) { margin-top: .36rem; border-top: 0; padding-top: 0; color: var(--muted); }
.lookup > details:not([open]) summary { font-size: .91rem; }
.manual-form, .scenario-form { display: grid; gap: .85rem; align-items: start; }
.manual-form { margin-top: .7rem; }
.manual-form button, .estimate-button { justify-self: start; }
.field-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .85rem; }
.wide-details { margin-top: .7rem; }
.scenario-property { margin-bottom: .45rem; font-size: 1.12rem; font-weight: 600; }
.scenario-form > .hint { margin-top: -.45rem; }
.scenario-form details, .scenario-form .message { margin-top: 0; }
.property-name { display: block; font-weight: 650; line-height: 1.25; }
.property-meta { margin: .25rem 0 .75rem; color: var(--muted); font-size: .92rem; overflow-wrap: anywhere; }
.facts { display: grid; }
.facts div { display: flex; gap: .6rem; justify-content: space-between; align-items: baseline; border-top: 1px solid var(--line); padding: .48rem 0; }
.facts dt, .facts dd { font-size: .94rem; }
.facts dt { color: var(--muted); }
.facts dd { margin: 0; font-weight: 650; text-align: right; overflow-wrap: anywhere; }
.link-list, .state-links { display: flex; flex-wrap: wrap; gap: .45rem 1.1rem; margin-top: .85rem; }
.link-list a, .state-links a, .source-grid a { font-size: .94rem; }

.results { padding: clamp(1rem, 2.2vw, 2.05rem); }
.result-header { display: flex; align-items: flex-start; justify-content: space-between; gap: .85rem 1rem; margin-bottom: 1.25rem; }
.result-header h2 { font-size: clamp(1.5rem, 2.5vw, 2.2rem); margin-bottom: .3rem; }
.result-header p { color: var(--slate); font-size: clamp(1rem, 1.5vw, 1.3rem); }
.result-header button { flex: none; }
.result-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 14rem), 1fr)); gap: clamp(.75rem, 1.6vw, 1.5rem); }
.result-card { border: 1px solid var(--line); border-radius: .65rem; padding: .8rem 1.2rem; }
.result-year { display: flex; flex-wrap: wrap; gap: .15rem .55rem; align-items: baseline; margin-bottom: .15rem; }
.result-year span { color: var(--muted); font-size: .96rem; }
.result-amount { font: 650 clamp(1.65rem, 2.8vw, 2.55rem)/1.18 var(--heading); letter-spacing: -.025em; font-variant-numeric: tabular-nums; }
.result-period { font-size: clamp(1.05rem, 1.8vw, 1.42rem); font-weight: 650; white-space: nowrap; }
.result-assessment { display: flex; justify-content: space-between; align-items: baseline; gap: .7rem; padding-block: 1.25rem 1rem; }
.result-assessment h3 { font-weight: 500; }
.result-assessment p { color: var(--muted); margin-top: .22rem; }
.result-assessment a { margin-left: .3rem; white-space: nowrap; }
.result-assessment .assessment-amount { margin: 0; color: var(--ink); font-size: 1.18rem; font-weight: 650; white-space: nowrap; }
.result-source { border-top: 1px solid var(--line); padding-top: .72rem; color: var(--slate); }
.result-breakdown { margin-top: .5rem; border: 0; padding-top: 0; }
.result-breakdown .result-grid { margin-top: .85rem; }
.result-details h3 { margin-bottom: .4rem; }
.result-note { color: var(--muted); font-size: .94rem; margin-top: .75rem; }

.sources { margin-top: 1.35rem; }
.sources > p { color: var(--muted); max-width: 64rem; }
.source-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .75rem; margin-top: 1rem; }
.source-grid > div { display: grid; gap: .26rem; padding: .7rem .85rem; background: var(--page); border-radius: .5rem; }
.site-footer { padding: 1rem 0; color: white; background: var(--slate); font-size: .94rem; }

@media (max-width: 64rem) {
  .shell { width: calc(100% - 3rem); }
  .service-area { max-width: 16rem; }
  .result-header { flex-wrap: wrap; }
}
@media (max-width: 49rem) {
  .shell { width: calc(100% - 2rem); }
  .masthead-inner { flex-wrap: wrap; min-height: auto; gap: .65rem 1rem; padding-block: .85rem; }
  .service-area { max-width: none; flex: 1; padding: .25rem 0 .25rem .8rem; font-size: .92rem; }
  .site-nav { flex-basis: 100%; margin-left: 0; }
  .site-nav a { font-size: .96rem; }
  .lookup-form { grid-template-columns: minmax(0, 1fr) minmax(0, 1.55fr); }
  .workspace-grid { grid-template-columns: minmax(0, 1fr); gap: 1rem; margin-top: 1rem; }
  .match-panel { min-height: 0; }
  .matches { max-height: 16rem; }
  .source-grid { grid-template-columns: 1fr; }
}
@media (max-width: 33rem) {
  .mode-switch { gap: .5rem; margin-block: 1.1rem; }
  .mode-switch button { flex: 1; padding: .55rem .45rem; line-height: 1.25; }
  .lookup-form, .field-row { grid-template-columns: minmax(0, 1fr); }
  .lookup-form button { width: 100%; }
  .result-assessment h3 { font-size: 1.06rem; }
  .result-assessment .assessment-amount { font-size: 1rem; }
}
@media print {
  body { background: white; font-size: .89rem; }
  .shell { width: 100%; }
  .utility-bar, .service-area, .site-nav, .intro, .mode-switch, .lookup, .match-panel, .scenario, .sources,
  .site-footer, .link-list, .result-header button, .result-assessment a, .skip { display: none !important; }
  .masthead-inner { min-height: auto; }
  .workspace { padding-block: .4rem; }
  .workspace-grid, .estimate-column { display: block; margin-top: 0; }
  .results { border: 0; padding: .5rem 0 1rem; }
  .result-header { margin-bottom: .7rem; }
  .result-grid { grid-template-columns: repeat(auto-fit, minmax(min(100%, 12rem), 1fr)); }
  .result-card, .result-details, .parcel { break-inside: avoid; }
  .result-breakdown > summary { list-style: none; }
}
