:root {
  --ink: #17231d;
  --muted: #647269;
  --paper: #f5f4ef;
  --white: #fffefa;
  --green: #174b37;
  --green-dark: #0e3427;
  --lime: #bfdb86;
  --line: #d9ddd4;
  --amber: #bf6b2c;
  --shadow: 0 22px 60px rgba(18, 43, 32, .10);
  --radius: 18px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--ink); background: var(--paper); font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; line-height: 1.55; }
a { color: var(--green); text-underline-offset: 3px; }
button, input { font: inherit; }
.skip-link { position: fixed; top: 8px; left: 8px; z-index: 20; padding: 10px 14px; background: var(--white); transform: translateY(-150%); }
.skip-link:focus { transform: none; }
.site-header { min-height: 82px; display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 16px clamp(20px, 5vw, 72px); background: rgba(255, 254, 250, .92); border-bottom: 1px solid var(--line); }
.brand { display: flex; align-items: center; gap: 12px; color: var(--ink); text-decoration: none; }
.brand-mark { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 12px; color: var(--white); background: var(--green); font-weight: 800; letter-spacing: -.04em; }
.brand span:last-child { display: grid; }
.brand strong { letter-spacing: -.02em; }
.brand small { color: var(--muted); font-size: .75rem; }
.site-header nav { display: flex; gap: 22px; }
.site-header nav a { color: var(--ink); text-decoration: none; font-weight: 650; }
.site-header nav a:hover, .site-header nav a.active { color: var(--green); }
.hero { padding: clamp(64px, 9vw, 120px) clamp(20px, 6vw, 88px); }
.home-hero { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(330px, .8fr); align-items: center; gap: clamp(40px, 8vw, 112px); background: radial-gradient(circle at 80% 10%, rgba(191, 219, 134, .23), transparent 30%), linear-gradient(145deg, #f8f7f1, #eef0e9); }
.hero h1, .article-hero h1, .parcel-hero h1, .results-heading h1 { margin: 8px 0 20px; max-width: 850px; font-family: Georgia, "Times New Roman", serif; font-size: clamp(2.6rem, 6vw, 5.8rem); font-weight: 500; line-height: .99; letter-spacing: -.05em; }
.lede { max-width: 760px; color: #44544b; font-size: clamp(1.08rem, 2vw, 1.28rem); }
.eyebrow { margin: 0 0 8px; color: var(--green); font-size: .76rem; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; }
.eyebrow.light { color: var(--lime); }
.status-dot { display: inline-block; width: 8px; height: 8px; margin-right: 8px; border-radius: 50%; background: #60a363; box-shadow: 0 0 0 5px rgba(96, 163, 99, .13); }
.search-card { margin-top: 34px; padding: 20px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--white); box-shadow: var(--shadow); }
.search-card label { display: block; margin-bottom: 10px; font-weight: 800; }
.search-row { display: flex; gap: 10px; }
.search-row input { min-width: 0; flex: 1; padding: 15px 16px; border: 1px solid #bfc8bf; border-radius: 10px; background: white; color: var(--ink); }
.search-row input:focus { outline: 3px solid rgba(23, 75, 55, .18); border-color: var(--green); }
.search-row button, .button-primary { padding: 14px 20px; border: 0; border-radius: 10px; color: white; background: var(--green); font-weight: 800; cursor: pointer; text-decoration: none; }
.search-row button:hover, .button-primary:hover { background: var(--green-dark); }
.search-card p { margin: 10px 0 0; color: var(--muted); font-size: .83rem; }
.hero-preview { padding: 26px; border-radius: 26px; color: white; background: var(--green-dark); box-shadow: 0 28px 80px rgba(11, 47, 35, .24); transform: rotate(1deg); }
.preview-topline, .preview-value, .mini-grid { display: flex; justify-content: space-between; gap: 16px; }
.preview-topline { color: #d7e5dc; font-size: .78rem; text-transform: uppercase; letter-spacing: .09em; }
.pill { padding: 4px 9px; border-radius: 999px; color: var(--green-dark); background: var(--lime); font-weight: 850; }
.preview-address { margin: 38px 0 2px; font-family: Georgia, serif; font-size: 1.55rem; }
.preview-parcel { margin-top: 0; color: #b8c8bf; }
.preview-value { align-items: end; margin: 30px 0 24px; padding-bottom: 24px; border-bottom: 1px solid rgba(255,255,255,.18); }
.preview-value span { color: #c7d6ce; }
.preview-value strong { font-size: 2.5rem; }
.mini-grid > div { display: grid; }
.mini-grid span { color: #b8c8bf; font-size: .78rem; }
.mini-grid strong { margin-top: 4px; }
.preview-link { display: block; margin-top: 28px; color: white; font-weight: 750; }
.section-wrap, .record-section { padding: clamp(58px, 7vw, 96px) clamp(20px, 6vw, 88px); }
.compact-heading { max-width: 820px; }
.section-heading h2 { margin: 6px 0 12px; font-family: Georgia, serif; font-size: clamp(2rem, 4vw, 3.2rem); font-weight: 500; letter-spacing: -.035em; }
.section-heading > p:last-child { color: var(--muted); }
.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 36px; }
.feature-grid article { padding: 28px; border-top: 3px solid var(--green); background: var(--white); }
.feature-number { color: var(--amber); font-size: .75rem; font-weight: 900; }
.feature-grid h3 { font-size: 1.15rem; }
.feature-grid p { color: var(--muted); }
.boundary-section { display: flex; align-items: center; justify-content: space-between; gap: 30px; padding: 56px clamp(20px, 6vw, 88px); color: white; background: var(--green); }
.boundary-copy { max-width: 760px; }
.boundary-copy h2 { margin: 8px 0; font-family: Georgia, serif; font-size: clamp(2rem, 4vw, 3.2rem); font-weight: 500; }
.button-secondary { flex: none; padding: 13px 18px; border: 1px solid currentColor; border-radius: 10px; text-decoration: none; font-weight: 800; }
.light-button { color: white; }
.site-footer { display: flex; justify-content: space-between; gap: 40px; padding: 38px clamp(20px, 6vw, 88px); color: #d9e5de; background: #0e261d; }
.site-footer p { max-width: 580px; margin: 6px 0 0; color: #aebdb5; font-size: .86rem; }
.footer-links { display: flex; flex-wrap: wrap; justify-content: end; gap: 18px; }
.footer-links a { color: white; }
.article-layout, .results-layout, .parcel-layout { width: min(1180px, calc(100% - 40px)); margin: 0 auto; padding: 70px 0 96px; }
.article-hero, .results-heading { margin-bottom: 36px; }
.article-hero h1, .results-heading h1 { font-size: clamp(2.6rem, 5vw, 4.8rem); }
.prose-card, .record-section, .scope-note, .empty-state { padding: clamp(26px, 5vw, 58px); border: 1px solid var(--line); border-radius: var(--radius); background: var(--white); box-shadow: 0 12px 40px rgba(18, 43, 32, .06); }
.prose-card { max-width: 880px; }
.prose-card h2 { margin-top: 38px; font-family: Georgia, serif; font-size: 1.8rem; font-weight: 500; }
.prose-card h2:first-child { margin-top: 0; }
.compact-search { margin: 0 0 26px; }
.results-list { display: grid; gap: 12px; }
.result-card { display: grid; grid-template-columns: minmax(220px, 1fr) minmax(340px, 1.5fr) auto; align-items: center; gap: 24px; padding: 22px 24px; border: 1px solid var(--line); border-radius: 14px; background: var(--white); }
.result-address { margin: 0; font-size: 1.08rem; font-weight: 800; }
.result-parcel { margin: 2px 0 0; color: var(--muted); font-size: .86rem; }
.result-card dl { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin: 0; }
.result-card dl div { display: grid; }
.result-card dt { color: var(--muted); font-size: .72rem; text-transform: uppercase; letter-spacing: .06em; }
.result-card dd { margin: 3px 0 0; font-weight: 700; }
.result-card > a { font-weight: 800; white-space: nowrap; }
.parcel-hero { display: grid; grid-template-columns: 1fr auto; align-items: end; gap: 40px; margin-bottom: 24px; }
.parcel-hero h1 { font-size: clamp(2.5rem, 5.4vw, 5rem); }
.value-panel { min-width: 320px; padding: 24px; border-radius: var(--radius); color: white; background: var(--green); }
.value-panel > span { color: #c6d7ce; font-size: .78rem; text-transform: uppercase; letter-spacing: .07em; }
.value-panel > strong { display: block; margin: 6px 0 18px; font-family: Georgia, serif; font-size: 2.6rem; font-weight: 500; }
.value-panel > div { display: flex; flex-wrap: wrap; gap: 8px 18px; color: #d8e5de; font-size: .82rem; }
.record-section { margin-top: 18px; }
.facts-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 1px; margin: 28px 0 0; border: 1px solid var(--line); background: var(--line); }
.facts-grid > div { min-height: 90px; padding: 16px; background: var(--white); }
.facts-grid dt { color: var(--muted); font-size: .73rem; font-weight: 750; text-transform: uppercase; letter-spacing: .055em; }
.facts-grid dd { margin: 6px 0 0; font-size: 1.02rem; font-weight: 750; overflow-wrap: anywhere; }
.source-note { margin: 20px 0 0; color: var(--muted); font-size: .88rem; }
.address-list { display: grid; gap: 8px; padding: 0; list-style: none; }
.address-list li { display: flex; justify-content: space-between; gap: 20px; padding: 14px 16px; border: 1px solid var(--line); border-radius: 10px; }
.address-list span { color: var(--muted); font-size: .84rem; }
.account-list { display: grid; gap: 12px; margin-top: 28px; }
.account-card { padding: 18px; border: 1px solid var(--line); border-radius: 12px; background: #f8f8f4; }
.account-card h3 { margin: 0; }
.account-card p { margin-bottom: 0; overflow-wrap: anywhere; }
.compact-facts { grid-template-columns: repeat(3, 1fr); margin-top: 14px; }
.compact-facts > div { min-height: 75px; }
.legal-description { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; line-height: 1.75; overflow-wrap: anywhere; }
.scope-note { margin-top: 18px; border-color: #e2c49b; background: #fff9ed; }
.scope-note h2 { margin-top: 0; font-family: Georgia, serif; font-weight: 500; }
.source-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.source-card { padding: 22px; border: 1px solid var(--line); border-radius: 14px; background: var(--white); }
.source-card h2 { margin: 0; overflow-wrap: anywhere; font-size: 1.03rem; }
.source-purpose { min-height: 3.1em; margin: 8px 0 0; color: var(--muted); font-size: .86rem; }
.source-card dl { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin: 20px 0; }
.source-card dl div { display: grid; }
.source-card dt { color: var(--muted); font-size: .67rem; font-weight: 750; letter-spacing: .05em; text-transform: uppercase; }
.source-card dd { margin: 3px 0 0; font-weight: 800; }
.source-card > a { font-weight: 750; }
.complete-badge { color: var(--green); font-size: .78rem; font-weight: 850; }
.timeline-section { padding-left: clamp(20px, 4vw, 48px); padding-right: clamp(20px, 4vw, 48px); }
.timeline { position: relative; display: grid; gap: 14px; margin-top: 34px; padding-left: 34px; }
.timeline::before { content: ""; position: absolute; top: 58px; bottom: 18px; left: 10px; width: 2px; background: #cad3cb; }
.timeline-year { position: relative; z-index: 1; width: max-content; max-width: 100%; margin: 28px 0 4px -34px; padding: 7px 13px; border: 1px solid #bec9bf; border-radius: 999px; color: var(--green-dark); background: var(--paper); font-size: .78rem; font-weight: 850; letter-spacing: .08em; text-transform: uppercase; }
.timeline-year:first-child { margin-top: 0; }
.timeline-card { position: relative; padding: clamp(20px, 3vw, 30px); border: 1px solid var(--line); border-left: 4px solid var(--green); border-radius: 15px; background: var(--white); box-shadow: 0 10px 30px rgba(18, 43, 32, .055); }
.timeline-marker { position: absolute; top: 29px; left: -34px; width: 14px; height: 14px; border: 3px solid var(--paper); border-radius: 50%; background: var(--green); box-shadow: 0 0 0 1px #afbab1; }
.timeline-sale-or-transfer { border-left-color: #9a5f27; }
.timeline-sale-or-transfer .timeline-marker { background: #9a5f27; }
.timeline-appraisal, .timeline-value-change { border-left-color: #315e8a; }
.timeline-appraisal .timeline-marker, .timeline-value-change .timeline-marker { background: #315e8a; }
.timeline-permit, .timeline-improvement { border-left-color: #a94f34; }
.timeline-permit .timeline-marker, .timeline-improvement .timeline-marker { background: #a94f34; }
.event-heading { display: flex; align-items: start; justify-content: space-between; gap: 28px; }
.event-heading h3 { margin: 5px 0 0; font-family: Georgia, "Times New Roman", serif; font-size: clamp(1.3rem, 2.4vw, 1.85rem); font-weight: 500; line-height: 1.15; letter-spacing: -.025em; }
.event-kind { color: var(--green); font-size: .69rem; font-weight: 900; letter-spacing: .1em; text-transform: uppercase; }
.event-date { flex: none; display: grid; justify-items: end; max-width: 220px; text-align: right; }
.event-date time { font-weight: 800; }
.exact-date { margin-top: 3px; color: var(--muted); font-size: .69rem; }
.event-highlights { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1px; margin: 24px 0 0; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; background: var(--line); }
.event-highlights > div { min-width: 0; padding: 13px 14px; background: #fafaf6; }
.event-highlights dt, .event-fields dt { color: var(--muted); font-size: .69rem; font-weight: 800; letter-spacing: .045em; text-transform: uppercase; }
.event-highlights dd, .event-fields dd { margin: 4px 0 0; overflow-wrap: anywhere; font-weight: 700; }
.event-note { margin: 22px 0 0; padding: 18px 20px; border-left: 3px solid var(--amber); color: #384a40; background: #fff9ed; white-space: pre-wrap; overflow-wrap: anywhere; }
.linked-details { margin-top: 22px; padding: 17px 18px; border-radius: 11px; background: #eff4ef; }
.linked-details h3 { margin: 0 0 4px; font-size: .95rem; }
.linked-details > p { margin: 0 0 12px; color: var(--muted); font-size: .79rem; }
.linked-details ul { display: grid; gap: 6px; margin: 0; padding: 0; list-style: none; }
.linked-details li { display: flex; justify-content: space-between; gap: 20px; padding: 8px 0; border-top: 1px solid #d2ddd4; }
.linked-details li:first-child { border-top: 0; }
.linked-details li span { text-align: right; overflow-wrap: anywhere; }
.event-details { margin-top: 20px; border-top: 1px solid var(--line); }
.event-details summary { width: max-content; max-width: 100%; padding-top: 14px; color: var(--green); cursor: pointer; font-size: .83rem; font-weight: 800; }
.event-fields { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1px; margin: 16px 0 0; border: 1px solid var(--line); background: var(--line); }
.event-fields > div { min-width: 0; padding: 12px 13px; background: white; }
.record-provenance { margin: 13px 0 0; color: var(--muted); font-size: .75rem; }
.empty-detail { color: var(--muted); }
.raw-record-section { padding-left: clamp(20px, 4vw, 48px); padding-right: clamp(20px, 4vw, 48px); }
.raw-datasets { display: grid; gap: 10px; margin-top: 30px; }
.raw-dataset { border: 1px solid var(--line); border-radius: 12px; background: white; overflow: hidden; }
.raw-dataset summary { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 16px 18px; cursor: pointer; list-style-position: inside; }
.raw-dataset summary:hover { background: #f5f7f2; }
.raw-dataset summary > span:first-child { display: inline-grid; margin-left: 5px; }
.raw-dataset summary strong { overflow-wrap: anywhere; }
.raw-dataset summary small { color: var(--muted); }
.relation-pill { flex: none; padding: 4px 8px; border-radius: 999px; color: #704018; background: #f7e5cf; font-size: .69rem; font-weight: 850; letter-spacing: .04em; text-transform: uppercase; }
.direct-pill { color: var(--green); background: #e3efe8; }
.raw-table-wrap { max-height: 70vh; overflow: auto; border-top: 1px solid var(--line); }
.raw-table-wrap table { width: max-content; min-width: 100%; border-collapse: collapse; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .76rem; }
.raw-table-wrap caption { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.raw-table-wrap th, .raw-table-wrap td { max-width: 420px; padding: 8px 10px; border-right: 1px solid #e5e8e2; border-bottom: 1px solid #e5e8e2; text-align: left; vertical-align: top; white-space: pre-wrap; overflow-wrap: anywhere; }
.raw-table-wrap thead th { position: sticky; top: 0; z-index: 2; color: white; background: var(--green-dark); white-space: nowrap; }
.raw-table-wrap tbody th { position: sticky; left: 0; z-index: 1; color: var(--green); background: #f3f6f2; white-space: nowrap; }
.raw-table-wrap tbody tr:nth-child(even) td { background: #fafbf8; }
.parse-warning { margin: 0; padding: 12px 18px; border-top: 1px solid #e2c49b; color: #6f431e; background: #fff4df; font-size: .82rem; }
.malformed-row td, .malformed-row th { background: #fff7e8 !important; }
.row-warning { display: block; margin-top: 4px; color: #9b4d17; font-family: Inter, ui-sans-serif, system-ui, sans-serif; font-size: .62rem; font-weight: 850; text-transform: uppercase; }
.standalone-table { max-height: 75vh; border: 1px solid var(--line); border-radius: 12px; background: white; }
.pagination { display: grid; grid-template-columns: 1fr auto 1fr; gap: 18px; align-items: center; margin-top: 18px; font-weight: 750; }
.pagination > *:last-child { text-align: right; }
.error-page { width: min(720px, calc(100% - 40px)); min-height: 100vh; display: grid; align-content: center; justify-items: start; margin: 0 auto; }
.error-brand { margin-bottom: 52px; }
.error-code { margin: 0; color: var(--amber); font-size: .78rem; font-weight: 900; letter-spacing: .14em; }
.error-page h1 { margin: 8px 0 6px; font-family: Georgia, serif; font-size: clamp(2.8rem, 7vw, 5rem); font-weight: 500; letter-spacing: -.04em; }
.error-page p:not(.error-code) { margin-bottom: 26px; color: var(--muted); }

@media (max-width: 900px) {
  .home-hero, .parcel-hero { grid-template-columns: 1fr; }
  .hero-preview { max-width: 620px; transform: none; }
  .feature-grid { grid-template-columns: 1fr; }
  .source-grid { grid-template-columns: 1fr; }
  .source-purpose { min-height: 0; }
  .facts-grid { grid-template-columns: repeat(2, 1fr); }
  .event-highlights, .event-fields { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .result-card { grid-template-columns: 1fr; }
  .result-card dl { grid-template-columns: repeat(3, 1fr); }
  .value-panel { min-width: 0; }
}

@media (max-width: 620px) {
  .site-header { align-items: flex-start; }
  .brand small { display: none; }
  .site-header nav { display: grid; gap: 5px; text-align: right; font-size: .9rem; }
  .search-row { display: grid; }
  .mini-grid, .boundary-section, .site-footer { display: grid; }
  .footer-links { justify-content: start; }
  .facts-grid, .compact-facts, .result-card dl { grid-template-columns: 1fr; }
  .address-list li { display: grid; gap: 4px; }
  .source-card dl { grid-template-columns: repeat(2, 1fr); }
  .timeline { padding-left: 23px; }
  .timeline::before { left: 5px; }
  .timeline-year { margin-left: -23px; }
  .timeline-marker { left: -25px; }
  .event-heading { display: grid; gap: 12px; }
  .event-date { justify-items: start; max-width: none; text-align: left; }
  .event-highlights, .event-fields { grid-template-columns: 1fr; }
  .linked-details li { display: grid; gap: 2px; }
  .linked-details li span { text-align: left; }
  .raw-dataset summary { align-items: flex-start; }
  .relation-pill { white-space: nowrap; }
}
