/* apps/public-api/public/navigation.css */
.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
:root,
[data-theme=dark] {
  --rf-hdr-bg: #090d16;
  --rf-hdr-surface: #111827;
  --rf-hdr-subtle: #1e293b;
  --rf-hdr-border: #243044;
  --rf-hdr-border-strong: #3b4b66;
  --rf-hdr-text: #f8fafc;
  --rf-hdr-muted: #94a3b8;
  --rf-hdr-link: #38bdf8;
  --rf-hdr-link-subtle: rgba(56, 189, 248, 0.14);
  --rf-hdr-shadow: 0 16px 40px rgba(0, 0, 0, 0.5);
}
:root[data-theme=light],
[data-theme=light] {
  --rf-hdr-bg: #f8fafc;
  --rf-hdr-surface: #ffffff;
  --rf-hdr-subtle: #f1f5f9;
  --rf-hdr-border: #e2e8f0;
  --rf-hdr-border-strong: #cbd5e1;
  --rf-hdr-text: #0f172a;
  --rf-hdr-muted: #64748b;
  --rf-hdr-link: #0284c7;
  --rf-hdr-link-subtle: #e0f2fe;
  --rf-hdr-shadow: 0 16px 40px rgba(15, 23, 42, 0.12);
}
.rf-site-header {
  position: relative;
  z-index: 40;
  background: var(--rf-hdr-bg);
  color: var(--rf-hdr-text);
  border-bottom: 1px solid var(--rf-hdr-border);
  font:
    16px/1.5 system-ui,
    -apple-system,
    "Segoe UI",
    Roboto,
    sans-serif;
}
.rf-site-header-inner {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  max-width: 72rem;
  margin: 0 auto;
  padding: 0.8rem 1.25rem;
  box-sizing: border-box;
}
.rf-site-header.app-header .rf-site-header-inner {
  max-width: none;
  padding: 0.85rem var(--rf-app-gutter, 1.25rem);
}
.rf-site-header.rf-site-has-search .rf-site-header-inner {
  display: grid;
  grid-template-columns: auto minmax(12rem, 1fr) auto;
  align-items: center;
  gap: 0.85rem;
}
.rf-site-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--rf-hdr-text);
  font-weight: 700;
  font-size: 0.95rem;
  text-decoration: none;
  white-space: nowrap;
  flex-shrink: 0;
}
.rf-site-brand:hover {
  color: var(--rf-hdr-text);
  text-decoration: none;
}
.rf-site-logo {
  display: inline-grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 7px;
  background: #0284c7;
  color: #ffffff;
  font-weight: 800;
  font-size: 0.85rem;
  letter-spacing: -0.02em;
  flex-shrink: 0;
  transition: transform 0.15s ease, background 0.15s ease;
}
.rf-site-brand:hover .rf-site-logo {
  background: #0369a1;
  transform: scale(1.04);
}
.rf-site-header-right {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  flex-shrink: 0;
}
.rf-site-menu-btn {
  appearance: none;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  background: transparent;
  color: var(--rf-hdr-text);
  border: 1px solid var(--rf-hdr-border);
  border-radius: 7px;
  padding: 0.32rem 0.7rem;
  font: inherit;
  font-size: 0.82rem;
  font-weight: 600;
  line-height: 1.4;
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
  transition:
    color 0.15s ease,
    border-color 0.15s ease,
    background 0.15s ease;
}
.rf-site-menu-btn:hover,
.rf-site-menu-btn[aria-expanded=true] {
  border-color: var(--rf-hdr-border-strong);
  background: var(--rf-hdr-subtle);
}
.rf-site-menu-bars {
  position: relative;
  display: inline-block;
  width: 13px;
  height: 2px;
  background: currentColor;
  border-radius: 1px;
  box-shadow: 0 -4px 0 currentColor, 0 4px 0 currentColor;
}
.rf-site-header nav.rf-site-menu-panel {
  position: absolute;
  top: calc(100% + 4px);
  right: 1.25rem;
  z-index: 80;
  display: grid;
  flex-direction: column;
  gap: 0.15rem;
  width: 244px;
  max-width: calc(100% - 2.5rem);
  padding: 0.4rem;
  background: var(--rf-hdr-surface);
  border: 1px solid var(--rf-hdr-border-strong);
  border-radius: 10px;
  box-shadow: var(--rf-hdr-shadow);
  box-sizing: border-box;
}
.rf-site-header nav.rf-site-menu-panel[hidden] {
  display: none !important;
}
.rf-site-header nav.rf-site-menu-panel a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 40px;
  padding: 0.35rem 0.75rem;
  border-radius: 7px;
  color: var(--rf-hdr-text);
  font-size: 0.88rem;
  font-weight: 550;
  text-decoration: none;
  transition: background 0.15s ease, color 0.15s ease;
}
.rf-site-header nav.rf-site-menu-panel a:hover,
.rf-site-header nav.rf-site-menu-panel a[aria-current=page] {
  background: var(--rf-hdr-link-subtle);
  color: var(--rf-hdr-link);
  text-decoration: none;
}
.rf-site-menu-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-top: 0.25rem;
  padding: 0.55rem 0.65rem 0.25rem;
  border-top: 1px solid var(--rf-hdr-border);
}
.rf-site-menu-footer-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--rf-hdr-muted);
}
.rf-site-theme-btn {
  appearance: none;
  background: transparent;
  color: var(--rf-hdr-muted);
  border: 1px solid var(--rf-hdr-border);
  border-radius: 7px;
  padding: 0.26rem 0.65rem;
  font: inherit;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
  transition:
    color 0.15s ease,
    border-color 0.15s ease,
    background 0.15s ease;
}
.rf-site-theme-btn:hover {
  color: var(--rf-hdr-text);
  border-color: var(--rf-hdr-border-strong);
  background: var(--rf-hdr-subtle);
}
.rf-site-header :is(a, button, input):focus-visible {
  outline: 2px solid var(--rf-hdr-link);
  outline-offset: 2px;
}
.rf-site-header .rf-search {
  position: relative;
  min-width: 0;
  margin: 0;
  padding: 0;
  width: 100%;
}
.rf-site-header :is(input[type=search], #nav-search) {
  width: 100%;
  min-width: 0;
  height: auto;
  font: inherit;
  font-size: 0.9rem;
  padding: 0.5rem 0.8rem;
  color: var(--rf-hdr-text);
  background: var(--rf-hdr-surface);
  border: 1px solid var(--rf-hdr-border);
  border-radius: 0.5rem;
  box-shadow: none;
}
.rf-site-header :is(input[type=search], #nav-search):focus {
  border-color: var(--rf-hdr-link);
  outline: none;
}
.rf-site-header input::placeholder {
  color: var(--rf-hdr-muted);
  opacity: 1;
}
.rf-search-results {
  position: absolute;
  z-index: 70;
  inset: auto 0 auto;
  max-height: 24rem;
  overflow-y: auto;
  list-style: none;
  margin: 0.35rem 0 0;
  padding: 0.4rem;
  border: 1px solid var(--rf-hdr-border-strong);
  border-radius: 0.5rem;
  background: var(--rf-hdr-surface);
  box-shadow: var(--rf-hdr-shadow);
}
.rf-search-results[hidden] {
  display: none;
}
.rf-search-results a {
  display: block;
  padding: 0.6rem 0.55rem;
  color: var(--rf-hdr-text);
  text-decoration: none;
  border-radius: 6px;
}
.rf-search-results a:hover {
  background: var(--rf-hdr-subtle);
  color: var(--rf-hdr-link);
}
@media (max-width: 820px) {
  .rf-site-header.rf-site-has-search .rf-site-header-inner {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 0.65rem;
  }
  .rf-site-header.rf-site-has-search .rf-search {
    grid-column: 1 / -1;
    grid-row: 2;
  }
}
@media (max-width: 440px) {
  .rf-site-header-inner {
    padding: 0.7rem 0.95rem;
    gap: 0.5rem;
  }
  .rf-site-brand {
    font-size: 0.86rem;
    gap: 0.45rem;
  }
  .rf-site-header nav.rf-site-menu-panel {
    left: 0.95rem;
    right: 0.95rem;
    width: auto;
    max-width: none;
  }
}

/* apps/public-api/public/area-research.css */
:is(.area-filters, .town-filters) {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: .75rem;
  padding: .85rem 0;
  margin: .75rem 0;
  border-bottom: 1px solid var(--town-border);
}
:is(.area-filters, .town-filters) h3 {
  flex-basis: 100%;
  margin: 0;
  font-size: 1rem;
  color: var(--town-heading);
}
:is(.area-filters, .town-filters) label {
  display: flex;
  flex-direction: column;
  gap: .35rem;
  font-size: .85rem;
  flex: 1 1 10rem;
  min-width: 0;
}
:is(.area-filters, .town-filters) :is(select, button) {
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
  font: inherit;
  padding: .6rem;
  border: 1px solid var(--town-border-strong);
  border-radius: 7px;
  color: var(--town-heading);
  background: var(--town-raised);
}
:is(.area-filters, .town-filters) :is(select, button):disabled {
  opacity: .75;
}
:is(.area-filters, .town-filters) button {
  width: auto;
  min-height: 2.6rem;
}
:is(#realfast-town-overview, #realfast-district-overview) :is(.area-filters, .town-filters) :is(.area-filter-note, .town-filter-note) {
  margin: 0;
  max-width: none;
  flex-basis: 100%;
  font-size: .85rem;
  color: var(--town-muted);
}
.area-research {
  --area-surface:var(--surface,var(--seo-surface,#111827));
  --area-raised:var(--surface-subtle,var(--seo-surface-raised,#1e293b));
  --area-text:var(--text-main,var(--seo-heading,#f8fafc));
  --area-muted:var(--text-muted,var(--seo-muted,#94a3b8));
  --area-border:var(--border-strong,var(--seo-border-strong,#334155));
  --area-link:var(--blue,var(--seo-link,#38bdf8));
  --area-input:var(--input-bg,var(--seo-surface,#111827));
  margin: 1.25rem 0;
  padding: 1rem;
  border: 1px solid var(--area-border);
  border-radius: 10px;
  background: var(--area-surface);
  min-width: 0;
}
.area-research > summary {
  cursor: pointer;
  font-weight: 650;
  color: var(--area-text);
}
.area-research .hint,
.area-research-status {
  color: var(--area-muted);
  font-size: .9rem;
}
.area-research .area-research-form {
  display: flex;
  flex-wrap: wrap;
  gap: .75rem;
  align-items: flex-end;
  margin-top: .8rem;
}
.area-research .area-research-form label {
  display: flex;
  flex: 1 1 9rem;
  flex-direction: column;
  gap: .35rem;
  max-width: 100%;
  min-width: 0;
  margin: 0;
  font-size: .9rem;
}
.area-research .area-research-form :is(input, select) {
  width: 100%;
  box-sizing: border-box;
  min-width: 0;
  min-height: 42px;
  padding: .45rem .6rem;
  border: 1px solid var(--area-border);
  border-radius: 6px;
  background: var(--area-input);
  color: var(--area-text);
  font: inherit;
}
.area-research button {
  min-height: 42px;
  max-width: 100%;
  font: inherit;
  color: var(--area-link);
  background: var(--area-raised);
  border: 1px solid var(--area-border);
  border-radius: 6px;
  padding: .4rem .7rem;
  cursor: pointer;
}
.area-price-distribution {
  margin-top: 1.4rem;
  max-width: 850px;
  min-width: 0;
}
.area-price-distribution h3 {
  margin: .4rem 0;
  font-size: 1.05rem;
}
.area-price-distribution :is(.chart-head, .chart-axis, .chart-actions) {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: .5rem;
  font-size: .85rem;
}
.area-price-distribution :is(.chart-head span, .hist-count-label, .chart-axis) {
  color: var(--area-muted);
}
.area-price-distribution .hist-count-label {
  font-size: .8rem;
  margin: .5rem 0;
}
.area-price-distribution .hist-plot {
  display: grid;
  height: 160px;
  gap: 2px;
  border-bottom: 1px solid var(--area-border);
}
.area-research .area-price-distribution .hist-bin {
  display: flex;
  align-items: flex-end;
  height: 160px;
  min-width: 0;
  min-height: 0;
  border: 0;
  background: transparent;
  padding: 0 3px;
}
.area-price-distribution .hist-bin:is(:hover, :focus-visible) {
  background: var(--area-raised);
}
.area-price-distribution .hist-total {
  display: block;
  position: relative;
  width: 100%;
  min-height: 2px;
  background: var(--area-border);
  border-radius: 4px 4px 0 0;
}
.area-price-distribution .hist-selected {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  background: var(--area-link);
  border-radius: 4px 4px 0 0;
}
.area-price-distribution .chart-axis {
  margin-top: .4rem;
}
.area-price-distribution .chart-readout {
  font-size: .85rem;
  margin: .6rem 0;
  min-height: 2.6em;
}
.area-price-distribution .budget-slider-label {
  display: flex;
  justify-content: space-between;
  gap: .5rem;
  font-size: .9rem;
}
.area-research .area-price-distribution input[type=range] {
  width: 100%;
  margin: .5rem 0;
  padding: 0;
  accent-color: var(--area-link);
}
.area-price-distribution .chart-key {
  display: flex;
  flex-wrap: wrap;
  gap: .4rem;
  align-items: center;
}
.area-price-distribution .chart-key i {
  display: inline-block;
  width: 10px;
  height: 10px;
  background: var(--area-link);
}
.area-price-distribution .chart-key i.faded {
  background: var(--area-border);
}
@media (max-width: 400px) {
  .area-research {
    padding: .75rem;
  }
  .area-research .area-research-form label {
    flex-basis: 100%;
  }
}

/* apps/public-api/public/town.css */
.town-guidance-intro {
  max-width: 72ch;
  color: var(--town-muted);
  margin: .7rem 0;
}
.town-guidance-skip {
  margin: .6rem 0 1.3rem;
  font-size: .9rem;
}
.area-introduction .area-intro-purpose {
  max-width: 72ch;
  margin: .7rem 0;
}
.area-section-links {
  display: flex;
  flex-wrap: wrap;
  gap: .4rem 1.2rem;
  margin: .7rem 0;
  font-size: .9rem;
}
.area-introduction .area-intro-meta {
  margin: .7rem 0 .15rem;
  color: var(--town-muted);
  font-size: .85rem;
}
.area-introduction .area-intro-note {
  margin: .15rem 0 1.3rem;
  color: var(--town-muted);
  font-size: .8rem;
}
:is(.district-data-details, .town-data-details) {
  margin: 1.2rem 0;
  color: var(--town-muted);
  font-size: .85rem;
}
:is(.district-data-details, .town-data-details) > summary {
  padding: .65rem 0;
  cursor: pointer;
  color: var(--town-link);
}
.town-guidance-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: .8rem;
}
.town-guidance-card {
  min-width: 0;
  padding: 1rem 1.15rem;
  border: 1px solid var(--town-border);
  border-radius: 10px;
  background: var(--town-surface);
}
.town-guidance-card:last-child:nth-child(odd) {
  grid-column: 1/-1;
}
.town-guidance-title {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: .3rem .8rem;
}
.town-guidance-title h3 {
  margin: 0;
  font-size: 1.05rem;
  line-height: 1.4;
}
.town-guidance-title > span {
  color: var(--town-muted);
  font-size: .8rem;
}
.town-guidance-card p {
  margin: .7rem 0 0;
  font-size: .9rem;
}
.town-guidance-anchors {
  display: flex;
  flex-wrap: wrap;
  gap: .25rem .8rem;
  margin: .5rem 0;
  font-size: .8rem;
}
.town-guidance-anchors span {
  color: var(--town-muted);
}
.town-guidance-tradeoff,
.town-guidance-origin {
  color: var(--town-muted);
}
.town-guidance-card .town-guidance-origin {
  font-size: .75rem;
}
.town-guidance-more {
  margin: .8rem 0;
}
.town-guidance-more > summary,
.town-guidance-sources > summary {
  padding: .65rem 0;
  cursor: pointer;
  color: var(--town-link);
}
.town-guidance-more[open] > .town-guidance-grid {
  margin-top: .4rem;
}
.town-guidance-takeaways {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.2rem;
  background: var(--town-raised);
  border-radius: 10px;
  padding: 1rem;
  margin: 1.2rem 0 .8rem;
}
.town-guidance-takeaways p {
  margin: 0;
  font-size: .85rem;
}
.town-guidance-takeaways strong {
  display: block;
  color: var(--town-heading);
  margin-bottom: .25rem;
}
.town-guidance-scope,
.town-guidance-sources {
  color: var(--town-muted);
  font-size: .8rem;
}
.town-guidance-sources ul {
  padding-left: 1.2rem;
}
.town-guidance-sources li {
  margin: .4rem 0;
  overflow-wrap: anywhere;
}
:is(#town-guide, #district-guide) a {
  text-underline-offset: 3px;
}
:is(#town-guide, #district-guide) :is(a, summary):focus-visible {
  outline: 3px solid var(--town-link);
  outline-offset: 3px;
  border-radius: 2px;
}
@media (max-width: 650px) {
  .town-guidance-grid,
  .town-guidance-takeaways {
    grid-template-columns: 1fr;
  }
  .town-guidance-card {
    padding: .9rem;
  }
  .town-guidance-card p {
    font-size: .85rem;
  }
  .town-guidance-title {
    display: block;
  }
}
:root {
  --town-surface:#111827;
  --town-raised:#1e293b;
  --town-heading:#f8fafc;
  --town-text:#e2e8f0;
  --town-muted:#94a3b8;
  --town-border:#243044;
  --town-border-strong:#334155;
  --town-link:#38bdf8;
}
html[data-theme=light] {
  --town-surface:#fff;
  --town-raised:#f1f5f9;
  --town-heading:#0f172a;
  --town-text:#334155;
  --town-muted:#475569;
  --town-border:#cbd5e1;
  --town-border-strong:#94a3b8;
  --town-link:#0369a1;
}
#realfast-town-overview,
.town-directory,
[aria-labelledby=town-methodology-heading] {
  font-size: 1rem;
  line-height: 1.55;
  color: var(--town-text);
}
#realfast-town-overview a:is(:link, :visited),
.town-directory a:is(:link, :visited),
[aria-labelledby=town-methodology-heading] a:is(:link, :visited) {
  color: var(--town-link);
  text-decoration: underline;
}
#realfast-town-overview {
  text-align: left;
  --surface:var(--town-surface);
  --surface-muted:var(--town-raised);
  --surface-hover:var(--town-raised);
  --text:var(--town-heading);
  --text-main:var(--town-heading);
  --text-muted:var(--town-muted);
  --border:var(--town-border);
  --border-strong:var(--town-border-strong);
  --blue:var(--town-link);
  --emerald:#34d399;
  --radius:8px;
  --input-bg:var(--town-surface);
}
#realfast-town-overview h1 {
  margin: 0 0 .45rem;
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  line-height: 1.25;
}
#realfast-town-overview h2,
#town-directory-heading,
#town-methodology-heading {
  margin: 2.25rem 0 .65rem;
  font-size: 1.35rem;
  line-height: 1.25;
  color: var(--town-heading);
}
#realfast-town-overview p,
[aria-labelledby=town-methodology-heading] p {
  max-width: 75ch;
  margin: .65rem 0 1rem;
  line-height: 1.55;
}
#realfast-town-overview .seo-lede {
  font-size: 1.05rem;
  color: var(--town-text);
}
.seo-breadcrumbs ol {
  display: flex;
  flex-wrap: wrap;
  gap: .25rem .55rem;
  margin: 0 0 1.5rem;
  padding: 0;
  list-style: none;
  color: var(--town-muted);
  font-size: .85rem;
}
.seo-breadcrumbs li:not(:last-child)::after {
  content: "/";
  margin-left: .55rem;
}
.town-comparison-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 18rem), 1fr));
  gap: 1rem;
  margin: 1rem 0 1.5rem;
}
.town-comparison-grid:has(> .town-comparison-card:only-child) {
  grid-template-columns: minmax(0, 26rem);
}
.town-comparison-card {
  min-width: 0;
  padding: 1.1rem;
  border: 1px solid var(--town-border-strong);
  border-radius: 12px;
  background: var(--town-surface);
}
.town-comparison-card h3 {
  font-size: 1rem;
  margin: 0 0 .65rem;
}
.town-comparison-card p {
  font-size: .9rem;
  margin: .6rem 0;
}
.town-comparison-card .town-median {
  font-size: 1.7rem;
  font-weight: 700;
  color: var(--town-heading);
  line-height: 1.3;
}
.town-median span {
  display: block;
  font-size: .8rem;
  font-weight: 400;
  color: var(--town-muted);
  margin-top: .2rem;
}
.town-muted,
.town-filter-note {
  color: var(--town-muted);
}
.town-card-count {
  font-weight: 650;
}
.town-sparse {
  font-weight: 650;
  color: var(--town-heading);
}
.town-research,
.town-directory {
  margin: 1.25rem 0;
  padding: 1rem;
  border: 1px solid var(--town-border-strong);
  border-radius: 10px;
  background: var(--town-surface);
}
.town-research > summary,
.town-directory > summary {
  cursor: pointer;
  font-weight: 650;
  color: var(--town-heading);
}
.town-empty {
  padding: 1rem;
  background: var(--town-surface);
  border-radius: 8px;
}
.town-sales th,
.town-sales td {
  overflow-wrap: anywhere;
}
:is(#realfast-town-overview, #realfast-district-overview) .town-sales {
  display: table;
  table-layout: fixed;
  width: 100%;
  border-collapse: collapse;
  margin: 1rem 0 1.5rem;
  font-size: .875rem;
  line-height: 1.5;
  color: var(--town-heading);
}
.town-sales th,
.town-sales td {
  padding: .7rem .65rem;
  border-bottom: 1px solid var(--town-border-strong);
  text-align: left;
}
.town-sales th {
  background: var(--town-raised);
  color: var(--town-heading);
}
:is(#realfast-town-overview, #realfast-district-overview) .town-sales :is(th, td) {
  font-size: .875rem;
  line-height: 1.5;
  letter-spacing: normal;
  text-transform: none;
  color: var(--town-heading);
}
:is(#realfast-town-overview, #realfast-district-overview) .town-sales th {
  font-weight: 600;
  background: var(--town-raised);
}
:is(#realfast-town-overview, #realfast-district-overview) .town-sales :is(tbody tr, td) {
  background: var(--town-surface);
}
:is(#realfast-town-overview, #realfast-district-overview) .town-sales a:is(:link, :visited) {
  color: var(--town-link);
  text-decoration: underline;
}
:is(#realfast-town-overview, #realfast-district-overview) .town-sales a:hover {
  text-decoration-thickness: 2px;
}
:is(#realfast-town-overview, #realfast-district-overview) .town-sales caption {
  text-align: left;
  font-size: .875rem;
  line-height: 1.5;
  color: var(--town-muted);
  padding: 0 0 .5rem;
}
.town-sales td[data-label=Price] {
  font-weight: 700;
}
.town-comparison-card button {
  font: inherit;
  font-weight: 700;
  color: var(--town-heading);
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
  text-align: left;
}
.town-comparison-card:has(button[aria-pressed=true]) {
  border-color: var(--town-link);
  box-shadow: inset 0 0 0 1px var(--town-link);
}
.town-mode-controls,
.town-budget-presets,
.town-pagination {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
  margin: .75rem 0;
  align-items: center;
}
#realfast-town-overview :is(.town-mode-controls, .town-budget-presets, .town-pagination, .town-load-status, form) button {
  font: inherit;
  padding: .5rem .7rem;
  min-height: 44px;
  border: 1px solid var(--town-border-strong);
  border-radius: 7px;
  color: var(--town-heading);
  background: var(--town-raised);
  cursor: pointer;
}
.town-mode-controls button[aria-pressed=true] {
  border-color: var(--town-link);
}
#realfast-town-overview [data-town-budget] {
  display: flex;
  flex-wrap: wrap;
  gap: .75rem;
  align-items: flex-end;
}
#realfast-town-overview :is([data-town-budget], #town-research-controls) label {
  display: inline-flex;
  flex-direction: column;
  gap: .35rem;
  max-width: 100%;
  margin: .5rem 0;
}
#realfast-town-overview :is(input, select) {
  font: inherit;
  max-width: 100%;
  min-width: 0;
  padding: .5rem;
  border: 1px solid var(--town-border-strong);
  border-radius: 6px;
  color: var(--town-heading);
  background: var(--town-surface);
}
.town-load-status {
  margin: .6rem 0;
}
.town-research-form {
  display: flex;
  flex-wrap: wrap;
  gap: .75rem;
  align-items: flex-end;
  margin-top: .8rem;
}
#realfast-town-overview .town-research-form label {
  flex: 1 1 9rem;
  margin: 0;
}
.town-research-form input {
  width: 100%;
  box-sizing: border-box;
}
.town-price-distribution {
  margin-top: 1.4rem;
  max-width: 850px;
}
.town-price-distribution h3 {
  margin: .4rem 0;
  font-size: 1.05rem;
}
.town-price-distribution .chart-head,
.town-price-distribution .chart-axis,
.town-price-distribution .chart-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: .5rem;
  font-size: .85rem;
}
.town-price-distribution .chart-head span {
  color: var(--town-muted);
}
#realfast-town-overview .town-price-distribution .hist-count-label {
  font-size: .8rem;
  color: var(--town-muted);
  margin: .5rem 0;
}
.town-price-distribution .hist-plot {
  display: grid;
  height: 160px;
  gap: 2px;
  border-bottom: 1px solid var(--town-border-strong);
}
#realfast-town-overview .town-price-distribution .hist-bin {
  display: flex;
  align-items: flex-end;
  height: 160px;
  min-width: 0;
  border: 0;
  background: transparent;
  padding: 0 3px;
  cursor: pointer;
}
.town-price-distribution .hist-bin:hover,
.town-price-distribution .hist-bin:focus-visible {
  background: var(--town-raised);
}
.town-price-distribution .hist-total {
  display: block;
  position: relative;
  width: 100%;
  min-height: 2px;
  background: var(--town-border-strong);
  border-radius: 4px 4px 0 0;
}
.town-price-distribution .hist-selected {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  background: var(--town-link);
  border-radius: 4px 4px 0 0;
}
.town-price-distribution .chart-axis {
  margin-top: .4rem;
  color: var(--town-muted);
}
#realfast-town-overview .town-price-distribution .chart-readout {
  font-size: .85rem;
  margin: .6rem 0;
  min-height: 2.6em;
}
.town-price-distribution .budget-slider-label {
  display: flex;
  justify-content: space-between;
  gap: .5rem;
  font-size: .9rem;
}
#realfast-town-overview .town-price-distribution input[type=range] {
  width: 100%;
  margin: .5rem 0;
  padding: 0;
  accent-color: var(--town-link);
}
.town-price-distribution .chart-key {
  display: flex;
  flex-wrap: wrap;
  gap: .4rem;
  align-items: center;
}
.town-price-distribution .chart-key i {
  display: inline-block;
  width: 10px;
  height: 10px;
  background: var(--town-link);
}
.town-price-distribution .chart-key i.faded {
  background: var(--town-border-strong);
}
.town-price-distribution .chart-clear {
  font: inherit;
  color: var(--town-link);
  background: transparent;
  border: 1px solid var(--town-border-strong);
  border-radius: 6px;
  min-height: 40px;
  padding: .35rem .7rem;
  cursor: pointer;
}
.town-directory .street-group {
  padding: .7rem;
  margin: .5rem 0;
  border: 1px solid var(--town-border);
  border-radius: 8px;
}
.town-directory .block-links {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem 1rem;
}
#realfast-town-overview :is(button, select, input, a):focus-visible {
  outline: 2px solid var(--town-link);
  outline-offset: 3px;
}
#realfast-town-overview .price-history {
  margin: 1rem 0;
}
#realfast-town-overview .price-history-controls {
  display: flex;
  flex-wrap: wrap;
  gap: .75rem 1rem;
  align-items: center;
}
#realfast-town-overview .price-history-chart {
  display: block;
  width: 100%;
  max-width: 720px;
  height: auto;
  margin: .5rem 0;
  overflow: visible;
}
#realfast-town-overview .history-grid {
  stroke: var(--town-border-strong);
  stroke-width: 1;
}
#realfast-town-overview .history-axis-label {
  fill: var(--town-muted);
  font-size: 11px;
}
#realfast-town-overview :is(.history-sale-dot, .history-median-dot) {
  fill: var(--dot-fill,var(--town-link));
}
#realfast-town-overview .history-median-line {
  stroke: var(--town-link);
  stroke-width: 2;
}
#realfast-town-overview .history-volume-bar {
  fill: #34d399;
  opacity: .7;
}
#realfast-town-overview .history-legend {
  display: flex;
  flex-wrap: wrap;
  gap: .2rem .9rem;
  list-style: none;
  padding: 0;
  color: var(--town-muted);
  font-size: .78rem;
}
#realfast-town-overview .history-legend li {
  display: inline-flex;
  gap: .35rem;
  align-items: center;
}
#realfast-town-overview .price-history-table {
  width: 100%;
  max-width: 720px;
  border-collapse: collapse;
  font-size: .85rem;
}
#realfast-town-overview .price-history-table :is(th, td) {
  padding: .35rem .5rem;
  border-bottom: 1px solid var(--town-border);
  text-align: left;
  overflow-wrap: anywhere;
}
@media (max-width: 600px) {
  #realfast-town-overview .town-sales,
  #realfast-town-overview .town-sales tbody {
    display: block;
  }
  #realfast-town-overview .town-sales thead {
    display: none;
  }
  #realfast-town-overview .town-sales tbody tr {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: .15rem .7rem;
    padding: .8rem 0;
    border-bottom: 1px solid var(--town-border-strong);
  }
  #realfast-town-overview .town-sales td {
    border: 0;
    padding: 0;
    min-width: 0;
  }
  #realfast-town-overview .town-sales td::before {
    content: attr(data-label) ": ";
    display: block;
    font-size: .78rem;
    color: var(--town-muted);
  }
  #realfast-town-overview .town-sales td:is([data-label=Block], [data-label="Flat type"]) {
    grid-column: 1/-1;
  }
  #realfast-town-overview .price-history-table {
    table-layout: fixed;
  }
}
header.seo-header.rf-nav.rf-pilot-shell {
  background: var(--seo-bg,#090d16);
  border-bottom: 0;
}
header.rf-pilot-shell .rf-nav-inner {
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-rows: auto auto;
  gap: 0;
  padding-top: .85rem;
  padding-bottom: .25rem;
}
header.rf-pilot-shell .rf-brand {
  grid-column: 1;
  grid-row: 1;
  justify-self: start;
  padding-bottom: .85rem;
}
header.rf-pilot-shell .rf-nav-actions {
  grid-column: 2;
  grid-row: 1;
  justify-self: end;
  padding-bottom: .85rem;
}
header.rf-pilot-shell button[data-theme-toggle] {
  background: transparent;
  color: var(--town-muted);
  border: 1px solid var(--town-border);
  border-radius: 7px;
  padding: .28rem .65rem;
  font-size: .8rem;
  font-weight: 600;
}
header.rf-pilot-shell button[data-theme-toggle]:hover {
  color: var(--town-heading);
  border-color: var(--town-border-strong);
  background: var(--town-raised);
}
header.rf-pilot-shell .rf-search {
  grid-column: 1 / -1;
  grid-row: 2;
  padding-top: 1.1rem;
  border-top: 1px solid var(--town-border);
}
header.rf-pilot-shell .rf-pilot-search-icon {
  position: absolute;
  left: 1.1rem;
  top: calc(1.1rem + 24px);
  width: 14px;
  height: 14px;
  color: var(--town-muted);
  border: 1.8px solid currentColor;
  border-radius: 50%;
  transform: translateY(calc(-50% - 2px));
  pointer-events: none;
}
header.rf-pilot-shell .rf-pilot-search-icon::after {
  content: "";
  position: absolute;
  width: 6px;
  height: 2px;
  right: -4px;
  bottom: -3px;
  border-radius: 1px;
  background: currentColor;
  transform: rotate(45deg);
}
header.rf-pilot-shell input#nav-search {
  height: 48px;
  padding: 0 1rem 0 2.75rem;
  border-radius: 12px;
  border: 1px solid var(--town-border-strong);
  background: var(--town-surface);
  font-size: .95rem;
}
header.rf-pilot-shell input#nav-search:focus {
  border-color: var(--town-link);
  outline: none;
  box-shadow: 0 0 0 3px rgba(56, 189, 248, .14);
}
header.rf-pilot-shell + main {
  padding-top: 1.25rem;
}
@media (max-width: 600px) {
  header.rf-pilot-shell .rf-nav-inner {
    grid-template-columns: 1fr auto;
  }
  header.rf-pilot-shell .rf-nav-actions {
    grid-column: 2;
    grid-row: 1;
    justify-content: flex-end;
  }
  header.rf-pilot-shell .rf-search {
    grid-column: 1 / -1;
    grid-row: 2;
  }
}
.town-hero {
  margin: 0 0 1.4rem;
}
:is(#realfast-town-overview, #realfast-district-overview) .town-hero h1 {
  margin: 0 0 .35rem;
  font-size: clamp(1.9rem, 4.2vw, 2.75rem);
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1.12;
  color: var(--town-heading);
}
:is(#realfast-town-overview, #realfast-district-overview) .town-hero-sub {
  margin: 0;
  max-width: none;
  font-size: .95rem;
  color: var(--town-muted);
}
:is(#realfast-town-overview, #realfast-district-overview) .town-hero-meta {
  margin: .22rem 0 0;
  max-width: none;
  font-size: .82rem;
  color: var(--town-muted);
  opacity: .85;
}
.town-explore-hub {
  margin: 0 0 2.25rem;
}
.town-hub-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: .65rem 1rem;
  margin: 0 0 1rem;
}
.town-pill-nav {
  display: flex;
  flex-wrap: wrap;
  gap: .45rem;
}
:is(#realfast-town-overview, #realfast-district-overview) .town-pill {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  min-height: 40px;
  padding: .4rem .9rem;
  border-radius: 999px;
  border: 1px solid var(--town-border);
  background: var(--town-surface);
  color: var(--town-text);
  font: inherit;
  font-size: .86rem;
  font-weight: 600;
  cursor: pointer;
  transition:
    border-color .15s ease,
    background .15s ease,
    color .15s ease;
}
:is(#realfast-town-overview, #realfast-district-overview) .town-pill span {
  font-size: .76rem;
  font-weight: 500;
  color: var(--town-muted);
  font-variant-numeric: tabular-nums;
}
:is(#realfast-town-overview, #realfast-district-overview) .town-pill:hover {
  border-color: var(--town-border-strong);
  background: var(--town-raised);
  color: var(--town-heading);
}
:is(#realfast-town-overview, #realfast-district-overview) .town-pill.is-active {
  border-color: var(--town-link);
  background: rgba(56, 189, 248, .12);
  color: var(--town-heading);
}
html[data-theme=light] :is(#realfast-town-overview, #realfast-district-overview) .town-pill.is-active {
  background: #e0f2fe;
}
.town-ft-pills {
  display: inline-flex;
  flex-wrap: wrap;
  gap: .25rem;
  padding: .2rem;
  border-radius: 999px;
  border: 1px solid var(--town-border);
  background: var(--town-surface);
}
:is(#realfast-town-overview, #realfast-district-overview) .town-ft-pill {
  min-height: 32px;
  padding: .2rem .65rem;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--town-muted);
  font: inherit;
  font-size: .8rem;
  font-weight: 600;
  cursor: pointer;
}
:is(#realfast-town-overview, #realfast-district-overview) .town-ft-pill:hover {
  color: var(--town-heading);
}
:is(#realfast-town-overview, #realfast-district-overview) .town-ft-pill.is-active {
  background: var(--town-raised);
  color: var(--town-heading);
}
.town-hub-panels > [hidden] {
  display: none !important;
}
.town-card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: .75rem;
}
.town-minimal-card {
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border-radius: 12px;
  border: 1px solid var(--town-border);
  background: var(--town-surface);
  transition: border-color .15s ease, background .15s ease;
}
.town-minimal-card:hover {
  border-color: var(--town-border-strong);
  background: var(--town-raised);
}
:is(#realfast-town-overview, #realfast-district-overview) a.town-card-primary:is(:link, :visited),
:is(#realfast-town-overview, #realfast-district-overview) a.town-card-link:is(:link, :visited) {
  display: flex;
  flex-direction: column;
  gap: .3rem;
  padding: .95rem 1.05rem;
  color: var(--town-heading);
  text-decoration: none;
}
:is(#realfast-town-overview, #realfast-district-overview) a.town-card-primary:hover,
:is(#realfast-town-overview, #realfast-district-overview) a.town-card-link:hover {
  color: var(--town-heading);
  text-decoration: none;
}
.town-card-head {
  display: flex;
  align-items: center;
  gap: .45rem;
  min-width: 0;
}
.town-card-title {
  font-size: .95rem;
  font-weight: 650;
  color: var(--town-heading);
  line-height: 1.35;
}
.town-card-arrow {
  margin-left: auto;
  color: var(--town-muted);
  font-size: .95rem;
  flex-shrink: 0;
}
.town-code-chip {
  display: inline-flex;
  align-items: center;
  gap: .3rem;
  padding: .1rem .45rem;
  border-radius: 999px;
  border: 1px solid var(--town-border);
  background: var(--town-raised);
  font-size: .72rem;
  font-weight: 600;
  color: var(--town-muted);
  white-space: nowrap;
}
.town-line-dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 999px;
  flex-shrink: 0;
}
.town-card-meta {
  font-size: .82rem;
  color: var(--town-muted);
  line-height: 1.45;
  font-variant-numeric: tabular-nums;
}
.town-card-streets {
  font-size: .78rem;
  color: var(--town-muted);
  opacity: .85;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.town-card-foot {
  padding: .45rem 1.05rem .7rem;
  border-top: 1px solid var(--town-border);
  display: flex;
  gap: .8rem;
  align-items: center;
}
:is(#realfast-town-overview, #realfast-district-overview) a.town-card-sublink:is(:link, :visited) {
  font-size: .78rem;
  font-weight: 500;
  color: var(--town-muted);
  text-decoration: none;
}
:is(#realfast-town-overview, #realfast-district-overview) a.town-card-sublink:hover {
  color: var(--town-heading);
  text-decoration: none;
}
.town-more-disclosure {
  margin-top: .85rem;
}
.town-more-disclosure > summary {
  cursor: pointer;
  font-size: .84rem;
  font-weight: 600;
  color: var(--town-muted);
  padding: .45rem 0;
  list-style: none;
  display: inline-flex;
  align-items: center;
  gap: .4rem;
}
.town-more-disclosure > summary::-webkit-details-marker {
  display: none;
}
.town-more-disclosure > summary::before {
  content: "\25b8";
  font-size: .75rem;
  transition: transform .15s ease;
}
.town-more-disclosure[open] > summary::before {
  transform: rotate(90deg);
}
.town-more-disclosure > summary:hover {
  color: var(--town-heading);
}
.town-more-disclosure[open] > .town-card-grid {
  margin-top: .6rem;
}
.town-street-search-wrap {
  margin: 0 0 .75rem;
}
:is(#realfast-town-overview, #realfast-district-overview) .town-street-search {
  width: 100%;
  max-width: 26rem;
  padding: .6rem .95rem;
  border-radius: 999px;
  border: 1px solid var(--town-border);
  background: var(--town-surface);
  color: var(--town-heading);
  font-size: .9rem;
}
[data-district-map-slot] .district-map-toggle-bar {
  display: none;
}
#realfast-district-overview .town-pagination button {
  font: inherit;
  padding: .5rem .7rem;
  min-height: 40px;
  border: 1px solid var(--town-border-strong);
  border-radius: 7px;
  color: var(--town-heading);
  background: var(--town-raised);
  cursor: pointer;
}
#realfast-district-overview .town-pagination button:disabled {
  opacity: .45;
  cursor: default;
}
.town-street-list {
  display: flex;
  flex-direction: column;
  gap: .4rem;
}
.town-street-row {
  border: 1px solid var(--town-border);
  border-radius: 10px;
  background: var(--town-surface);
  overflow: hidden;
}
.town-street-row[hidden] {
  display: none !important;
}
.town-street-row > summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .35rem .85rem;
  padding: .7rem .95rem;
  color: var(--town-heading);
}
.town-street-row > summary::-webkit-details-marker {
  display: none;
}
.town-street-row > summary:hover {
  background: var(--town-raised);
}
.town-street-name {
  font-weight: 650;
  font-size: .9rem;
  color: var(--town-heading);
}
.town-street-meta {
  font-size: .82rem;
  color: var(--town-muted);
  font-variant-numeric: tabular-nums;
}
.town-street-blocks {
  margin-left: auto;
  font-size: .8rem;
  color: var(--town-muted);
  white-space: nowrap;
}
.town-street-blocks::after {
  content: "\25b8";
  display: inline-block;
  margin-left: .45rem;
  transition: transform .15s ease;
}
.town-street-row[open] .town-street-blocks::after {
  transform: rotate(90deg);
}
.town-street-block-links {
  display: flex;
  flex-wrap: wrap;
  gap: .4rem .85rem;
  padding: .65rem .95rem .85rem;
  border-top: 1px solid var(--town-border);
  font-size: .84rem;
}
.town-street-block-links a {
  white-space: nowrap;
}
.town-street-block-links a span {
  color: var(--town-muted);
  font-size: .76rem;
}
.town-built-year {
  margin-left: .35rem;
  font-size: .76rem;
  color: var(--town-muted);
  font-variant-numeric: tabular-nums;
}
.town-sales-minimal {
  margin-top: 2rem;
  padding-top: .4rem;
  border-top: 1px solid var(--town-border);
}
.town-sources-minimal {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}
.town-minimal-disclosure > summary,
.town-minimal-disclosure > summary#town-methodology-heading,
.town-minimal-disclosure > summary#district-methodology-heading {
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  min-height: 38px;
  margin: 0;
  color: var(--town-muted);
  font-size: .82rem;
  font-weight: 400;
  line-height: 1.4;
  list-style: none;
  cursor: pointer;
}
.town-minimal-disclosure > summary::-webkit-details-marker {
  display: none;
}
.town-minimal-disclosure > summary::after {
  content: "\203a";
  font-size: 1rem;
  line-height: 1;
  transition: transform .15s ease;
}
.town-minimal-disclosure[open] > summary::after {
  transform: rotate(90deg);
}
.town-minimal-disclosure > summary:hover {
  color: var(--town-heading);
  text-decoration: underline;
}
.town-sales-disclosure-body {
  padding: .4rem 0 1rem;
}
.town-provenance-body {
  padding: .4rem 0 .8rem;
  font-size: .82rem;
  color: var(--town-muted);
}
.town-provenance-body p {
  margin: .35rem 0 .6rem !important;
  max-width: 78ch;
}
.town-sources-refs {
  margin-top: .5rem;
  line-height: 1.6;
}
.is-minimal-pilot-page .town-load-status:empty {
  display: none;
  margin: 0;
}
@media (max-width: 900px) {
  .town-card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 640px) {
  .town-card-grid {
    grid-template-columns: 1fr;
  }
  .town-hub-bar {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* apps/public-api/public/app/main.css */
:root,
[data-theme=dark] {
  color-scheme: dark;
  --bg: #090d16;
  --surface: #111827;
  --surface-subtle: #1e293b;
  --surface-elevated: #1a2234;
  --border: #243044;
  --border-strong: #3b4b66;
  --blue: #38bdf8;
  --blue-hover: #0284c7;
  --blue-subtle: rgba(56, 189, 248, 0.12);
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --emerald: #34d399;
  --emerald-subtle: rgba(52, 211, 153, 0.12);
  --purple: #c084fc;
  --purple-subtle: rgba(192, 132, 252, 0.12);
  --amber: #fbbf24;
  --amber-subtle: rgba(251, 191, 36, 0.12);
  --rose: #fb7185;
  --rose-subtle: rgba(251, 113, 133, 0.12);
  --input-bg: #111827;
  --navy: #38bdf8;
  --navy-hover: #7dd3fc;
  --navy-light: rgba(56, 189, 248, 0.15);
  --accent-amber: #fbbf24;
  --accent-teal: #34d399;
  --accent-red: #fb7185;
  --shadow: 0 16px 40px rgba(0, 0, 0, 0.5);
  font-family:
    system-ui,
    -apple-system,
    "Segoe UI",
    Roboto,
    sans-serif;
}
[data-theme=light] {
  color-scheme: light;
  --bg: #f8fafc;
  --surface: #ffffff;
  --surface-subtle: #f1f5f9;
  --surface-elevated: #ffffff;
  --border: #e2e8f0;
  --border-strong: #cbd5e1;
  --blue: #0284c7;
  --blue-hover: #0369a1;
  --blue-subtle: #e0f2fe;
  --text-main: #0f172a;
  --text-muted: #64748b;
  --emerald: #059669;
  --emerald-subtle: #ecfdf5;
  --purple: #7e22ce;
  --purple-subtle: #faf5ff;
  --amber: #b45309;
  --amber-subtle: #fffbeb;
  --rose: #e11d48;
  --rose-subtle: #fff1f2;
  --input-bg: #ffffff;
  --navy: #0b1f3a;
  --navy-hover: #1e3a5f;
  --navy-light: #e0e7ff;
  --accent-amber: #b45309;
  --accent-teal: #0f766e;
  --accent-red: #be123c;
  --shadow: 0 16px 40px rgba(15, 23, 42, 0.09);
}
* {
  box-sizing: border-box;
}
body {
  --rf-app-gutter: 1.25rem;
  margin: 0 auto;
  max-width: 1440px;
  padding: 0 var(--rf-app-gutter) 3rem;
  line-height: 1.5;
  background: var(--bg);
  color: var(--text-main);
  min-height: 100vh;
}
.header-brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-width: 0;
  flex: 1 1 auto;
  overflow: hidden;
}
.btn-settings {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: var(--surface-subtle);
  border: 1px solid var(--border);
  color: var(--text-main);
  border-radius: 8px;
  font-size: 1.15rem;
  cursor: pointer;
  line-height: 1;
  transition: background 0.15s ease, border-color 0.15s ease;
  flex-shrink: 0;
}
.btn-settings:hover {
  background: var(--surface-elevated);
  border-color: var(--border-strong);
}
.status {
  font-size: 0.75rem;
  color: var(--text-muted);
  white-space: nowrap;
}
.status[hidden],
.startup-error[hidden] {
  display: none;
}
.status.fallback {
  display: inline-flex;
  align-items: center;
  color: var(--text-muted);
  background: var(--surface-subtle);
  border: 1px solid var(--border);
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  white-space: nowrap;
}
.startup-error {
  max-width: 42rem;
  margin: 1.25rem auto 0;
  color: var(--text-main);
  background: var(--rose-subtle);
  border: 1px solid var(--rose);
  border-radius: 8px;
  padding: 0.75rem 1rem;
  text-align: left;
}
.home-tools {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem;
  max-width: 45rem;
  margin: 0 auto;
}
.home-tools a {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-content: start;
  gap: 0.35rem 0.5rem;
  padding: 0.95rem 1rem;
  border-radius: 12px;
  color: var(--text-main);
  text-decoration: none;
  background: var(--surface);
  border: 1px solid var(--border);
  transition: border-color 0.15s ease, background 0.15s ease;
}
.home-tools strong {
  font-size: 0.95rem;
}
.home-tools span {
  color: var(--text-muted);
}
.home-tools span:last-child {
  grid-column: 1 / -1;
  font-size: 0.825rem;
}
.home-tool-arrow {
  line-height: 1.35;
}
.home-tools a:hover {
  border-color: var(--border-strong);
  background: var(--surface-elevated);
}
.home-tools a.home-tool-rents {
  background:
    linear-gradient(
      160deg,
      rgba(192, 132, 252, 0.14) 0%,
      var(--surface) 78%);
  border-color: rgba(192, 132, 252, 0.48);
}
.home-tools a.home-tool-rents strong,
.home-tools a.home-tool-rents .home-tool-arrow {
  color: var(--purple);
}
.home-tools a.home-tool-rents:hover {
  border-color: var(--purple);
  background:
    linear-gradient(
      160deg,
      rgba(192, 132, 252, 0.22) 0%,
      var(--surface-elevated) 82%);
}
[data-theme=light] .home-tools a.home-tool-rents {
  background:
    linear-gradient(
      160deg,
      #faf5ff 0%,
      #ffffff 78%);
  border-color: rgba(126, 34, 206, 0.4);
}
[data-theme=light] .home-tools a.home-tool-rents:hover {
  border-color: var(--purple);
  background:
    linear-gradient(
      160deg,
      #f3e8ff 0%,
      #ffffff 82%);
}
.home-tools a:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 2px;
}
.home-articles {
  max-width: 45rem;
  margin: 1.5rem auto 0;
  text-align: left;
}
.home-articles-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  margin-bottom: 0.75rem;
}
.home-articles-heading {
  margin: 0;
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--text-main);
}
.home-articles-all {
  font-size: 0.825rem;
  font-weight: 600;
  color: var(--blue);
  text-decoration: none;
  white-space: nowrap;
}
.home-articles-all:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}
.home-articles-all:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 2px;
  border-radius: 4px;
}
.home-articles-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
  margin: 0;
  padding: 0;
  list-style: none;
}
.home-articles-grid li {
  display: flex;
}
.home-article-card {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  width: 100%;
  padding: 0.9rem 1rem;
  border-radius: 12px;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text-main);
  text-decoration: none;
  transition: border-color 0.15s ease, background 0.15s ease;
}
.home-article-card:hover {
  border-color: var(--border-strong);
  background: var(--surface-elevated);
}
.home-article-card:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 2px;
}
.home-article-meta {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-muted);
  letter-spacing: 0.01em;
}
.home-article-title {
  font-size: 0.92rem;
  font-weight: 650;
  line-height: 1.35;
  color: var(--text-main);
}
.home-article-desc {
  font-size: 0.8125rem;
  line-height: 1.45;
  color: var(--text-muted);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
@media (max-width: 600px) {
  .home-tools {
    grid-template-columns: minmax(0, 1fr);
    gap: 0.55rem;
  }
  .home-articles-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 0.55rem;
  }
}
.home-directory {
  max-width: 45rem;
  margin: 0 auto 0.9rem;
  display: grid;
  gap: 0.65rem;
  text-align: left;
}
.home-directory-triggers {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
}
.home-directory-trigger {
  appearance: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  width: 100%;
  min-height: 44px;
  padding: 0.6rem 0.95rem;
  border-radius: 12px;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  color: var(--text-main);
  font: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  text-align: left;
  transition: border-color 0.15s ease, background 0.15s ease;
}
.home-directory-label {
  display: inline;
  min-width: 0;
}
.home-directory-count {
  margin-left: 0.25rem;
  font-size: 0.8rem;
  font-weight: 700;
  white-space: nowrap;
}
.home-directory-trigger-hdb .home-directory-count {
  color: var(--emerald);
}
.home-directory-trigger-private .home-directory-count {
  color: var(--blue);
}
.home-directory-trigger-hdb:hover,
.home-directory-trigger-hdb[aria-expanded=true] {
  border-color: var(--emerald);
  background: var(--emerald-subtle);
}
.home-directory-trigger-private:hover,
.home-directory-trigger-private[aria-expanded=true] {
  border-color: var(--blue);
  background: var(--blue-subtle);
}
.home-directory-trigger:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 2px;
}
.home-directory-chevron {
  width: 0.5rem;
  height: 0.5rem;
  flex-shrink: 0;
  border-right: 2px solid var(--text-main);
  border-bottom: 2px solid var(--text-main);
  transform: translateY(-2px) rotate(45deg);
  transition: transform 0.15s ease;
}
.home-directory-trigger[aria-expanded=true] .home-directory-chevron {
  transform: translateY(2px) rotate(-135deg);
}
.home-directory-panel {
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: 12px;
  padding: 0.9rem 1rem 1rem;
}
.home-directory-panel[hidden] {
  display: none;
}
.home-directory-panel-hdb {
  border-color: rgba(52, 211, 153, 0.38);
}
.home-directory-panel-private {
  border-color: rgba(56, 189, 248, 0.38);
}
[data-theme=light] .home-directory-panel-hdb {
  border-color: rgba(5, 150, 105, 0.32);
}
[data-theme=light] .home-directory-panel-private {
  border-color: rgba(2, 132, 199, 0.32);
}
.home-directory-overview {
  margin: 0;
}
.home-directory-overview a {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.875rem;
  font-weight: 650;
  text-decoration: none;
}
.home-directory-panel-hdb .home-directory-overview a {
  color: var(--emerald);
}
.home-directory-panel-private .home-directory-overview a {
  color: var(--blue);
}
.home-directory-overview a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}
.home-directory-overview a:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 2px;
  border-radius: 4px;
}
.home-directory-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.48rem;
  margin: 0.75rem 0 0;
  padding: 0;
  list-style: none;
}
.home-directory-links a {
  display: inline-flex;
  align-items: center;
  padding: 0.34rem 0.72rem;
  border-radius: 999px;
  font-size: 0.84rem;
  font-weight: 500;
  color: var(--text-main);
  text-decoration: none;
  transition:
    background 0.15s ease,
    border-color 0.15s ease,
    color 0.15s ease;
}
.home-directory-panel-hdb .home-directory-links a {
  background: rgba(52, 211, 153, 0.13);
  border: 1px solid rgba(52, 211, 153, 0.42);
}
.home-directory-panel-hdb .home-directory-links a:hover {
  background: rgba(52, 211, 153, 0.25);
  border-color: var(--emerald);
  color: #ffffff;
}
.home-directory-panel-private .home-directory-links a {
  background: rgba(56, 189, 248, 0.13);
  border: 1px solid rgba(56, 189, 248, 0.42);
}
.home-directory-panel-private .home-directory-links a:hover {
  background: rgba(56, 189, 248, 0.25);
  border-color: var(--blue);
  color: #ffffff;
}
[data-theme=light] .home-directory-panel-hdb .home-directory-links a {
  background: #ecfdf5;
  border-color: rgba(5, 150, 105, 0.38);
  color: #0f172a;
}
[data-theme=light] .home-directory-panel-hdb .home-directory-links a:hover {
  background: #d1fae5;
  border-color: var(--emerald);
  color: #064e3b;
}
[data-theme=light] .home-directory-panel-private .home-directory-links a {
  background: #e0f2fe;
  border-color: rgba(2, 132, 199, 0.38);
  color: #0f172a;
}
[data-theme=light] .home-directory-panel-private .home-directory-links a:hover {
  background: #bae6fd;
  border-color: var(--blue);
  color: #0c4a6e;
}
.home-directory-links a:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 2px;
}
@media (max-width: 440px) {
  .home-directory-triggers {
    gap: 0.5rem;
  }
  .home-directory-trigger {
    padding: 0.55rem 0.7rem;
    font-size: 0.82rem;
  }
  .home-directory-count {
    font-size: 0.75rem;
  }
}
#update {
  padding: 0.3rem 0.65rem;
  font-size: 0.8rem;
  border-radius: 6px;
  background: var(--navy);
  color: #fff;
  border: none;
  cursor: pointer;
}
#update:hover {
  background: var(--navy-hover);
}
.hero-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: clamp(2.25rem, 5vw, 3.5rem) 0 clamp(0.85rem, 2vw, 1.1rem);
  max-width: 45rem;
  margin: 0 auto;
  text-align: center;
  transition: padding 0.2s ease;
}
.hero-title {
  font-size: clamp(1.9rem, 4.5vw, 3rem);
  font-weight: 800;
  letter-spacing: -0.045em;
  line-height: 1.1;
  margin: 0 0 0.65rem;
  color: var(--text-main);
  text-wrap: balance;
}
.hero-subtitle {
  font-size: 1rem;
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto clamp(0.95rem, 2.5vw, 1.35rem);
  line-height: 1.5;
}
.search-pane {
  width: 100%;
  position: relative;
  text-align: left;
}
.search-mode-toggle {
  display: flex;
  width: fit-content;
  align-items: center;
  gap: 0.2rem;
  padding: 0.22rem;
  margin: 0 auto 0.85rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 999px;
}
body.view-active .search-mode-toggle {
  margin: 0 0 0.5rem;
}
.search-mode-btn {
  appearance: none;
  border: 1px solid transparent;
  background: transparent;
  color: var(--text-muted);
  font: inherit;
  font-size: 0.84rem;
  font-weight: 650;
  padding: 0.34rem 0.95rem;
  border-radius: 999px;
  cursor: pointer;
  line-height: 1.2;
  transition:
    background 0.15s ease,
    color 0.15s ease,
    border-color 0.15s ease;
}
.search-mode-btn:hover {
  color: var(--text-main);
}
.search-mode-btn.is-active {
  background: var(--surface-subtle);
  border-color: var(--border-strong);
  color: var(--text-main);
}
.search-mode-btn[data-search-mode=rents].is-active {
  background: var(--purple-subtle);
  border-color: var(--purple);
  color: var(--purple);
}
.search-mode-btn:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 2px;
}
.dossier-rent-link {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  margin-top: 0.55rem;
  padding: 0.34rem 0.75rem;
  border-radius: 999px;
  background: var(--purple-subtle);
  border: 1px solid var(--purple);
  color: var(--purple);
  font-size: 0.82rem;
  font-weight: 650;
  text-decoration: none;
  transition: background 0.15s ease, color 0.15s ease;
}
.dossier-rent-link:hover {
  background: var(--purple);
  color: var(--bg);
}
.dossier-rent-link:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 2px;
}
.nearby-primary-actions .dossier-rent-link {
  margin-top: 0;
}
.search-input-wrap {
  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
}
.search-icon {
  position: absolute;
  left: 1.2rem;
  top: 50%;
  width: 15px;
  height: 15px;
  color: var(--text-muted);
  border: 1.8px solid currentColor;
  border-radius: 50%;
  transform: translateY(calc(-50% - 2px));
  pointer-events: none;
}
.search-icon::after {
  content: "";
  position: absolute;
  width: 7px;
  height: 2px;
  right: -5px;
  bottom: -3px;
  border-radius: 1px;
  background: currentColor;
  transform: rotate(45deg);
}
#search {
  width: 100%;
  height: 58px;
  padding: 0 0.9rem 0 3rem;
  font: inherit;
  font-size: 1rem;
  background: var(--input-bg);
  border: 1px solid var(--border-strong);
  border-radius: 12px;
  color: var(--text-main);
  outline: none;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
#search:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 4px var(--blue-subtle), 0 8px 24px rgba(0, 0, 0, 0.15);
}
#search::placeholder {
  color: var(--text-muted);
  opacity: 1;
  font-size: 0.95rem;
}
.hint,
#search-hint {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin: 0.55rem 0 0;
  padding: 0 0.5rem;
}
body:not(.view-active) #dossier-pane {
  max-width: 680px;
  margin: 1.5rem auto 0;
  text-align: center;
}
body:not(.view-active) #dossier > p:first-child {
  color: var(--text-muted);
  font-size: 0.85rem;
  margin-bottom: 0.75rem;
}
#private-sales-entry {
  margin: 0.75rem 0;
}
#private-sales-entry button {
  background: var(--surface-subtle);
  border: 1px solid var(--border);
  color: var(--blue);
  font-size: 0.82rem;
  font-weight: 600;
  padding: 0.45rem 0.85rem;
  border-radius: 8px;
  cursor: pointer;
  max-width: 100%;
  white-space: normal;
  line-height: 1.35;
  transition: background 0.15s ease, border-color 0.15s ease;
}
#private-sales-entry button:hover {
  background: var(--surface-elevated);
  border-color: var(--border-strong);
}
body.view-active .hero-section {
  padding: 0.75rem 0;
  max-width: 100%;
  margin: 0;
  text-align: left;
}
body.view-active .hero-title,
body.view-active .hero-subtitle,
body.view-active .home-tools,
body.view-active .home-articles,
body.view-active .home-directory {
  display: none;
}
body.view-active .search-pane {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0.25rem 0 0.5rem;
}
body.view-active #search {
  height: 46px;
}
body.view-active #dossier-pane {
  display: block;
  max-width: 1080px;
  margin: 0 auto;
  text-align: left;
}
body.view-active #dossier-pane:has(.has-map) {
  max-width: 1400px;
}
.search-suggestions {
  position: absolute;
  z-index: 30;
  top: 100%;
  left: 0;
  right: 0;
  margin-top: 0.35rem;
}
.search-suggestions[hidden] {
  display: none !important;
}
.search-suggestions[data-placement=above] {
  top: auto;
  bottom: 100%;
  margin-top: 0;
  margin-bottom: 0.35rem;
}
.results {
  position: relative;
  margin: 0;
  max-height: min(24rem, 50dvh);
  max-width: 100%;
  overflow-y: auto;
  overscroll-behavior: contain;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: 12px;
  box-shadow: var(--shadow);
  list-style: none;
  padding: 0;
}
.results[hidden] {
  display: none !important;
  pointer-events: none !important;
}
.results li {
  display: flex;
  gap: 0;
  border-bottom: 1px solid var(--border);
}
.results li:last-child {
  border-bottom: none;
}
.search-results-notice {
  padding: 0.65rem 1.1rem;
  background: var(--surface-subtle);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
}
.search-notice-content {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}
.search-notice-title {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-main);
}
.search-notice-hint {
  font-size: 0.78rem;
  color: var(--text-muted);
}
.results :is(button, a[data-kind=area]) {
  width: 100%;
  text-align: left;
  padding: 0.8rem 1.1rem;
  font-size: 0.92rem;
  background: transparent;
  border: none;
  cursor: pointer;
  color: var(--text-main);
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  transition: background 0.12s ease;
}
.results :is(button, a[data-kind=area]):hover,
.results :is(button, a[data-kind=area]):focus-visible {
  background: var(--surface-subtle);
  outline: none;
}
.search-result-title-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  gap: 0.5rem;
}
.result-pill {
  font-size: 0.68rem;
  font-weight: 700;
  padding: 0.15rem 0.5rem;
  border-radius: 9999px;
  letter-spacing: 0.02em;
  white-space: nowrap;
  flex-shrink: 0;
}
.pill-postal {
  background: var(--amber-subtle);
  color: var(--amber);
  border: 1px solid rgba(251, 191, 36, 0.35);
}
.pill-hdb {
  background: var(--blue-subtle);
  color: var(--blue);
  border: 1px solid rgba(56, 189, 248, 0.35);
}
.pill-ura {
  background: var(--emerald-subtle);
  color: var(--emerald);
  border: 1px solid rgba(52, 211, 153, 0.35);
}
.pill-town {
  background: var(--rose-subtle);
  color: var(--rose);
  border: 1px solid rgba(251, 113, 133, 0.35);
}
.pill-transit {
  background: var(--purple-subtle);
  color: var(--purple);
  border: 1px solid rgba(192, 132, 252, 0.35);
}
.pill-district {
  background: var(--purple-subtle, rgba(168, 85, 247, 0.12));
  color: var(--purple, #a855f7);
  border: 1px solid rgba(168, 85, 247, 0.35);
}
.results :is(button, a[data-kind=area], a[data-kind=district], a[data-kind=project], a[data-kind=private-sales]) {
  width: 100%;
  text-align: left;
  padding: 0.7rem 0.8rem;
  font-size: 0.92rem;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-main);
}
.search-result-title,
.search-result-destination {
  display: block;
}
.search-result-title {
  font-weight: 650;
  min-width: 0;
  overflow-wrap: anywhere;
}
.search-result-destination {
  margin-top: 0.12rem;
  color: var(--text-muted);
  font-size: 0.78rem;
}
.search-result-note a {
  display: inline-block;
  margin: 0.4rem 1rem 0 0;
}
.search-result-note {
  display: block;
  padding: 0.7rem 0.8rem;
  color: var(--text-muted);
  font-size: 0.88rem;
  line-height: 1.35;
}
.property-postal-label {
  margin: 0.15rem 0 0;
  color: var(--text-muted);
  font-size: 0.82rem;
  letter-spacing: 0.01em;
}
.results :is(button, a[data-kind=area]):hover,
.results :is(button, a[data-kind=area]):focus-visible {
  background: var(--surface-subtle);
  outline: 2px solid var(--navy);
  outline-offset: -2px;
}
.results li > :is(button, a[data-kind=area]):first-child {
  flex: 1;
}
.nearby-txn-action {
  flex: 0 0 auto;
  font-size: 0.8rem;
  padding: 0.5rem 0.75rem;
  cursor: pointer;
  background: var(--surface-subtle);
  border: 1px solid var(--border);
  border-radius: 6px;
  margin: 0.25rem 0.4rem;
}
.nearby-txn-action:hover,
.nearby-txn-action:focus-visible {
  background: var(--navy-light);
  border-color: var(--navy);
}
#dossier-pane {
  margin-top: 0.5rem;
}
.dossier h2:focus,
h2[tabindex="-1"]:focus {
  outline: none;
}
.property-heading-pane {
  margin-bottom: 0.8rem;
}
.property-heading-pane h2 {
  font-size: 1.45rem;
  margin-bottom: 0.15rem;
}
.property-town-label {
  font-size: 0.92rem;
  color: var(--text-muted);
  margin: 0 0 0.5rem;
}
.property-fact-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 0.5rem;
  margin: 0.25rem 0 0.6rem;
}
.property-composition-line {
  font-size: 0.9rem;
  color: var(--text-main);
  margin: 0;
}
.fact-pill {
  font-size: 0.85rem;
  font-weight: 400;
  color: var(--text-muted);
}
.property-fact-pills > * + *::before {
  content: "\b7";
  margin-right: 0.5rem;
  color: var(--text-muted);
}
.property-fact-pills .property-composition-line {
  font-size: inherit;
  color: inherit;
}
.fact-pill.pill-subtle {
  color: var(--text-muted);
}
.property-facts {
  font-size: 0.9rem;
  font-weight: 600;
  margin: 0.5rem 0 0.25rem;
}
.availability-details {
  width: fit-content;
  margin-top: 0.25rem;
  color: var(--text-muted);
  font-size: 0.78rem;
}
.availability-details summary {
  cursor: pointer;
}
.unavailable {
  color: var(--accent-amber);
  font-size: 0.85rem;
  margin: 0.25rem 0;
}
.back-to-nearby {
  font-size: 0.85rem;
  font-weight: 500;
  padding: 0.4rem 0.75rem;
  cursor: pointer;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: 6px;
  margin-bottom: 0.6rem;
  display: inline-flex;
  align-items: center;
  color: var(--navy);
}
.back-to-nearby:hover,
.back-to-nearby:focus-visible {
  background: var(--surface-subtle);
  border-color: var(--navy);
}
.property-workspace-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-areas: "nearby" "prices" "research";
  gap: 1rem;
  align-items: start;
}
.property-workspace-grid > * {
  min-width: 0;
  width: 100%;
}
.property-price-pane {
  grid-area: prices;
}
.property-right-column {
  grid-area: nearby;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}
.property-research-pane {
  grid-area: research;
}
.block-answer-intro {
  margin: 0 0 0.65rem;
  color: var(--text-muted);
  font-size: 0.9rem;
}
.property-recorded-summary {
  margin-top: 0.75rem;
}
.property-recorded-summary > h3 {
  margin: 0 0 0.55rem;
  font-size: 0.95rem;
}
.property-research-pane .price-history {
  margin: 0 0 0.6rem;
}
.transaction-footer {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 0.75rem;
  align-items: center;
  justify-content: space-between;
  margin-top: 0.45rem;
}
.transaction-footer .property-facts {
  color: var(--text-muted);
  font-size: 0.78rem;
  font-weight: 400;
  margin: 0;
  flex: 1 1 16rem;
}
.property-transactions-section > h3 {
  margin: 0 0 0.2rem;
  font-size: 1rem;
}
.project-workspace {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-areas: "aside" "main" "history";
  gap: 1rem;
  align-items: start;
}
.project-workspace > * {
  min-width: 0;
  width: 100%;
}
.project-main-col {
  grid-area: main;
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
}
.project-aside {
  grid-area: aside;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}
.private-location-card-host,
.private-location-map-host {
  min-width: 0;
  width: 100%;
}
.private-location-map-host .expandable-map-panel {
  max-width: 100%;
}
.project-history-area {
  grid-area: history;
}
.property-workspace-grid .expandable-map-panel:not([hidden]),
.project-workspace .expandable-map-panel:not([hidden]) {
  min-height: 310px;
}
@media (min-width: 1024px) {
  .property-workspace-grid .expandable-map-panel:not([hidden]),
  .project-workspace .expandable-map-panel:not([hidden]) {
    min-height: 410px;
  }
}
.project-overall-count {
  margin: 0.2rem 0 0;
}
.project-summary-heading {
  margin: 0 0 0.45rem;
  font-size: 0.95rem;
}
.project-summary-scope {
  margin: -0.2rem 0 0.45rem;
  font-size: 0.78rem;
}
.private-reference-note {
  margin: 0.3rem 0 0.6rem;
  font-size: 0.78rem;
}
.private-filters-bar {
  margin-bottom: 0.4rem;
}
.private-reference {
  margin: 0.3rem 0 0.6rem;
}
.private-reference-line {
  margin: 0;
  font-size: 0.78rem;
}
.private-reference-details {
  margin-top: 0.15rem;
  font-size: 0.78rem;
}
.private-reference-details > summary {
  cursor: pointer;
  color: var(--blue);
  font-weight: 600;
}
.private-reference-details > summary:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 2px;
}
.private-reference-details > p {
  margin: 0.25rem 0 0;
}
.seller-group-block {
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.6rem 0.75rem;
  margin-top: 0.6rem;
}
.seller-group-label {
  margin: 0 0 0.35rem;
  font-weight: 600;
}
.secondary-disclosure {
  margin: 1rem 0;
  border: 1px solid var(--border);
  border-radius: 9px;
  background: var(--surface);
}
.secondary-disclosure > summary {
  cursor: pointer;
  padding: 0.85rem 1rem;
  color: var(--blue);
  font-weight: 650;
}
.secondary-disclosure > summary:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 2px;
}
.secondary-disclosure > div {
  padding: 0 1rem 1rem;
}
.lens-filter-chip {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.82rem;
  color: var(--text-main);
  background: var(--surface-subtle);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 0.35rem 0.6rem;
  margin: 0.3rem 0 0.4rem;
}
.single-type-transactions th:nth-child(2),
.single-type-transactions td:nth-child(2) {
  text-align: center;
}
.single-type-transactions th:nth-child(3),
.single-type-transactions td:nth-child(3) {
  text-align: right;
}
.price-history {
  margin: 1rem 0;
  border: 1px solid var(--border);
  border-radius: 9px;
  background: var(--surface);
}
.price-history > summary {
  cursor: pointer;
  padding: 0.85rem 1rem;
  color: var(--blue);
  font-weight: 650;
}
.price-history > summary:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 2px;
}
.price-history-content {
  padding: 0 1rem 1rem;
}
.price-history-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1rem;
  align-items: center;
}
.price-history-controls label {
  color: var(--text-muted);
  font-size: 0.9rem;
}
.price-history-controls select {
  margin-left: 0.25rem;
  max-width: 100%;
  padding: 0.4rem;
  border: 1px solid var(--border-strong);
  border-radius: 5px;
  color: var(--text-main);
  background: var(--input-bg);
}
.price-history-chart {
  display: block;
  width: 100%;
  max-width: 720px;
  height: auto;
  margin: 0.5rem 0;
  overflow: visible;
}
.history-grid {
  stroke: var(--border-strong);
  stroke-width: 1;
}
.history-axis-label {
  fill: var(--text-muted);
  font-size: 11px;
}
.history-sale-dot,
.history-median-dot {
  fill: var(--dot-fill, var(--blue));
}
.history-legend {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.2rem 0.9rem;
  margin: 0.2rem 0 0.35rem;
  padding: 0;
  font-size: 0.78rem;
  color: var(--text-muted);
}
.history-legend li {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}
.history-legend svg {
  flex: none;
}
.history-legend .history-sale-dot {
  cursor: default;
}
.price-history-controls label {
  min-width: 0;
}
.price-history-controls select {
  min-width: 0;
}
.overview-sales-table {
  table-layout: fixed;
}
.overview-sales-table th,
.overview-sales-table td {
  overflow-wrap: anywhere;
}
.overview-sales-table th:nth-child(3) {
  width: 19%;
}
.overview-sales-table th:last-child {
  width: 33%;
}
.history-median-line {
  stroke: var(--blue);
  stroke-width: 2;
}
.history-volume-bar {
  fill: var(--emerald);
  opacity: 0.7;
}
.price-history-table {
  border-collapse: collapse;
  width: 100%;
  max-width: 560px;
  margin-top: 0.5rem;
  font-size: 0.85rem;
}
.price-history-table th,
.price-history-table td {
  padding: 0.35rem 0.5rem;
  border-bottom: 1px solid var(--border);
  text-align: left;
}
.history-sale-dot {
  cursor: pointer;
}
.history-sale-dot:focus-visible {
  stroke: var(--navy);
  stroke-width: 2.5px;
  fill: var(--navy);
  outline: none;
}
.sparse-sales-table th,
.sparse-sales-table td {
  white-space: normal;
}
.insufficient-card .sparse-sales-table {
  margin: 0.5rem 0 0.6rem;
}
.recorded-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.6rem;
}
.btn-secondary {
  font-size: 0.85rem;
  font-weight: 500;
  padding: 0.45rem 0.8rem;
  cursor: pointer;
  background: var(--surface-subtle);
  border: 1px solid var(--border-strong);
  border-radius: 6px;
  color: var(--text-main);
  min-height: 44px;
}
.btn-secondary:hover,
.btn-secondary:focus-visible {
  background: var(--navy-light);
  border-color: var(--navy);
}
#property-nearby-compare {
  margin: 1rem 0;
  padding: 0.7rem 0.9rem;
  background: var(--surface-subtle);
  border: 1px solid var(--border);
  border-radius: 8px;
}
#property-nearby-compare h3 {
  font-size: 0.95rem;
  margin: 0 0 0.3rem;
}
#property-nearby-compare .hint {
  margin: 0 0 0.55rem;
  font-size: 0.8rem;
}
.older-sales-toggle {
  margin: 0.4rem 0 0.9rem;
}
.transaction-footer .older-sales-toggle {
  margin: 0;
}
.block-nearby-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem 0.9rem;
  align-items: center;
  margin: 0.6rem 0;
}
.block-nearby-controls select {
  padding: 0.4rem;
  border: 1px solid var(--border-strong);
  border-radius: 5px;
  background: var(--input-bg);
  color: var(--text-main);
  min-height: 44px;
}
.size-match-control {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.85rem;
  color: var(--text-main);
  min-height: 44px;
}
.size-match-control:has(input:disabled) {
  color: var(--text-muted);
}
.block-nearby-median {
  font-size: 0.9rem;
  font-weight: 600;
  margin: 0.5rem 0;
}
.back-to-block {
  font-size: 0.85rem;
  font-weight: 500;
  padding: 0.4rem 0.75rem;
  cursor: pointer;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: 6px;
  margin-bottom: 0.6rem;
  display: inline-flex;
  align-items: center;
  color: var(--navy);
}
.back-to-block:hover,
.back-to-block:focus-visible {
  background: var(--surface-subtle);
  border-color: var(--navy);
}
.property-filters-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  align-items: center;
  padding: 0.65rem 0.85rem;
  background: var(--surface-subtle);
  border: 1px solid var(--border);
  border-radius: 8px;
  margin-bottom: 0.75rem;
}
.filter-select.single-flat-type {
  appearance: none;
  background-image: none;
  padding-right: 0.75rem;
  cursor: default;
  opacity: 1;
}
.area-unit-control {
  display: inline-flex;
  margin-left: auto;
  border: 1px solid var(--border-strong);
  border-radius: 6px;
  overflow: hidden;
}
.area-unit-control button {
  border: 0;
  padding: 0.4rem 0.65rem;
  min-height: 44px;
  background: var(--surface);
  cursor: pointer;
  color: var(--text-muted);
}
.area-unit-control button[aria-pressed=true] {
  background: var(--blue);
  color: var(--bg);
  font-weight: 650;
}
.area-unit-control button:focus-visible {
  outline-offset: -3px;
}
.filter-group {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.filter-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-main);
}
.filter-select {
  padding: 0.45rem 2rem 0.45rem 0.75rem;
  font-size: 0.88rem;
  font-weight: 500;
  border: 1px solid var(--border-strong);
  border-radius: 6px;
  background-color: var(--surface);
  color: var(--text-main);
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.65rem center;
  background-size: 12px;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.filter-select:hover {
  border-color: var(--navy);
}
.filter-select:focus-visible {
  border-color: var(--navy);
  outline: 2px solid var(--navy);
  outline-offset: 1px;
}
.price-cards-section {
  margin-bottom: 0.85rem;
}
.price-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 0.55rem;
}
.price-evidence-card {
  padding: 0.65rem 0.75rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}
.price-evidence-card.primary-card {
  border-color: var(--navy);
  background: light-dark(#f8fafc, #1e293b);
  box-shadow: 0 2px 6px rgba(11, 31, 58, 0.08);
}
.price-evidence-card .card-label {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin: 0 0 0.25rem;
}
.price-evidence-card .card-value {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--text-main);
  margin: 0;
  letter-spacing: -0.02em;
}
.price-evidence-card .card-value.highlight-value {
  color: var(--navy);
}
.price-evidence-card .card-value-small {
  font-size: 0.95rem;
  font-weight: 600;
  margin: 0;
}
.insufficient-card {
  background: var(--surface-subtle);
  border: 1px dashed var(--border-strong);
  padding: 0.85rem 1rem;
}
.insufficient-card .card-title {
  font-size: 0.95rem;
  font-weight: 600;
  margin: 0 0 0.25rem;
}
.insufficient-card .card-subtext {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin: 0;
}
.price-cutoff-note {
  margin-top: 0.4rem;
  font-size: 0.75rem;
  margin-bottom: 0;
  max-width: 100%;
  white-space: normal;
  overflow-wrap: anywhere;
}
.property-transactions-section {
  margin-bottom: 0;
}
.table-responsive {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
}
table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}
th,
td {
  text-align: left;
  padding: 0.55rem 0.75rem;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}
th {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  background: var(--surface-subtle);
  border-bottom: 2px solid var(--border);
}
tr:last-child td {
  border-bottom: none;
}
.transactions-table th:nth-child(3),
.transactions-table td:nth-child(3) {
  text-align: center;
}
.transactions-table th:nth-child(4),
.transactions-table td:nth-child(4),
.transactions-table th:nth-child(5),
.transactions-table td:nth-child(5),
.transactions-table th:nth-child(6),
.transactions-table td:nth-child(6) {
  text-align: right;
}
.transactions-table td {
  font-variant-numeric: tabular-nums;
}
.transactions-table tbody tr:hover td {
  background: var(--surface-subtle);
}
.table-order-note {
  margin-bottom: 0.35rem;
}
.table-pagination {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-top: 0.75rem;
}
.btn-pager {
  padding: 0.4rem 0.75rem;
  font-size: 0.82rem;
  font-weight: 500;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: 6px;
  cursor: pointer;
  color: var(--text-main);
  transition: all 0.15s ease;
}
.btn-pager:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}
.btn-pager:not(:disabled):hover {
  background: var(--surface-subtle);
  border-color: var(--navy);
  color: var(--navy);
}
.pager-indicator {
  font-size: 0.82rem;
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
}
.nearby-transactions-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
}
@media (min-width: 601px) {
  .nearby-transactions-table th:nth-child(1),
  .nearby-transactions-table td:nth-child(1) {
    width: 100px;
    padding-left: 1rem;
  }
  .nearby-transactions-table th:nth-child(2),
  .nearby-transactions-table td:nth-child(2) {
    min-width: 220px;
    white-space: normal;
  }
  .nearby-transactions-table th:nth-child(3),
  .nearby-transactions-table td:nth-child(3) {
    width: 110px;
  }
  .nearby-transactions-table th:nth-child(4),
  .nearby-transactions-table td:nth-child(4) {
    width: 100px;
  }
  .nearby-transactions-table th:nth-child(5),
  .nearby-transactions-table td:nth-child(5) {
    width: 105px;
    text-align: right;
  }
  .nearby-transactions-table th:nth-child(6),
  .nearby-transactions-table td:nth-child(6) {
    width: 125px;
    text-align: right;
    font-weight: 750;
    color: var(--text-main);
    padding-right: 1rem;
  }
  .nearby-transactions-table td {
    font-variant-numeric: tabular-nums;
  }
  .nearby-transactions-table tbody tr:hover td {
    background: var(--surface-subtle);
  }
}
.segment-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 0.85rem 0 1rem;
}
.segment-tab-btn {
  background: var(--surface-subtle);
  border: 1px solid var(--border);
  color: var(--text-muted);
  padding: 0.45rem 0.95rem;
  border-radius: 9999px;
  font-size: 0.84rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}
.segment-tab-btn:hover {
  background: var(--surface-elevated);
  border-color: var(--border-strong);
  color: var(--text-main);
}
.segment-tab-btn.active {
  background: var(--blue);
  border-color: var(--blue);
  color: #fff;
  box-shadow: 0 2px 6px rgba(43, 90, 237, 0.25);
}
.buyer-compare-columns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
  margin-top: 1rem;
}
@media (max-width: 860px) {
  .buyer-compare-columns {
    grid-template-columns: 1fr;
  }
}
.buyer-compare-col {
  background: var(--surface-subtle);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0.85rem;
}
.buyer-col-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.75rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--border);
}
.buyer-col-title {
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--text-main);
  display: flex;
  align-items: center;
  gap: 0.4rem;
}
.buyer-col-badge {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.15rem 0.5rem;
  border-radius: 6px;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text-muted);
}
.tradeoff-banner {
  background:
    linear-gradient(
      135deg,
      var(--blue-subtle) 0%,
      var(--surface-elevated) 100%);
  border: 1px solid var(--border);
  border-left: 4px solid var(--blue);
  border-radius: 8px;
  padding: 0.75rem 1rem;
  margin: 0.75rem 0 1rem;
  font-size: 0.85rem;
  color: var(--text-main);
  display: flex;
  align-items: center;
  gap: 0.6rem;
  line-height: 1.4;
}
.tradeoff-banner-icon {
  font-size: 1.2rem;
  flex-shrink: 0;
}
.seller-sub-toggle {
  display: inline-flex;
  gap: 0.35rem;
  background: var(--surface-subtle);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.25rem;
  margin-bottom: 0.85rem;
}
.seller-sub-btn {
  background: transparent;
  border: none;
  border-radius: 6px;
  padding: 0.35rem 0.8rem;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.12s ease;
}
.seller-sub-btn:hover {
  color: var(--text-main);
}
.seller-sub-btn.active {
  background: var(--surface);
  color: var(--text-main);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}
.dual-lens-workspace {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.15rem;
  margin: 1rem 0 1.25rem;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.05);
}
.dual-lens-toggle {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  margin-bottom: 0.85rem;
}
@media (max-width: 640px) {
  .dual-lens-toggle {
    grid-template-columns: 1fr;
  }
}
.lens-tab-btn {
  background: var(--surface-subtle);
  border: 1.5px solid var(--border);
  border-radius: 9px;
  padding: 0.75rem 1rem;
  text-align: left;
  cursor: pointer;
  transition: all 0.15s ease;
  color: var(--text-main);
}
.lens-tab-btn:hover {
  border-color: var(--border-strong);
  background: var(--surface-elevated);
}
.lens-tab-btn.active {
  border-color: var(--blue);
  background: var(--blue-subtle);
}
.lens-tab-title {
  font-weight: 700;
  font-size: 0.92rem;
  display: flex;
  align-items: center;
  gap: 0.45rem;
  margin-bottom: 0.2rem;
  color: var(--text-main);
}
.lens-tab-desc {
  font-size: 0.78rem;
  color: var(--text-muted);
  line-height: 1.35;
}
.dual-lens-content {
  margin-top: 0.75rem;
}
.buyer-budget-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}
.budget-bar-label {
  font-size: 0.82rem;
  font-weight: 650;
  color: var(--text-main);
}
.budget-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}
.budget-pill-btn {
  background: var(--surface-subtle);
  border: 1px solid var(--border);
  color: var(--text-muted);
  padding: 0.35rem 0.8rem;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}
.budget-pill-btn:hover {
  color: var(--text-main);
  border-color: var(--border-strong);
}
.budget-pill-btn.active {
  background: var(--blue-subtle);
  border-color: var(--blue);
  color: var(--blue);
}
.affordability-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 0.75rem;
  margin-top: 0.6rem;
}
.afford-card {
  background: var(--surface-subtle);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.75rem 0.85rem;
  cursor: pointer;
  transition: all 0.15s ease;
  text-align: left;
}
.afford-card:hover {
  border-color: var(--blue);
  background: var(--surface-elevated);
}
.afford-card.active {
  border-color: var(--blue);
  box-shadow: 0 0 0 1px var(--blue);
}
.afford-card-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.8rem;
  font-weight: 700;
  margin-bottom: 0.35rem;
}
.afford-tag-yes {
  color: var(--emerald);
  background: var(--emerald-subtle);
  padding: 0.12rem 0.4rem;
  border-radius: 4px;
  font-size: 0.72rem;
  font-weight: 600;
}
.afford-tag-stretch {
  color: var(--amber);
  background: var(--amber-subtle);
  padding: 0.12rem 0.4rem;
  border-radius: 4px;
  font-size: 0.72rem;
  font-weight: 600;
}
.afford-tag-none {
  color: var(--text-muted);
  font-size: 0.72rem;
  font-weight: 500;
}
.afford-price {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--text-main);
  line-height: 1.2;
}
.afford-range {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 0.25rem;
}
.seller-controls-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  align-items: center;
  margin-bottom: 0.85rem;
}
.seller-picker-group {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.82rem;
  color: var(--text-muted);
}
.seller-select {
  background: var(--input-bg);
  color: var(--text-main);
  border: 1px solid var(--border-strong);
  border-radius: 6px;
  padding: 0.35rem 0.65rem;
  font-size: 0.82rem;
  font-weight: 600;
}
.seller-benchmark-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  background: var(--surface-subtle);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.9rem 1.1rem;
}
@media (max-width: 640px) {
  .seller-benchmark-row {
    flex-direction: column;
    align-items: flex-start;
  }
}
.benchmark-stat-group {
  display: flex;
  gap: 2rem;
  flex-wrap: wrap;
}
.benchmark-stat-item {
  display: flex;
  flex-direction: column;
}
.benchmark-label {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  font-weight: 600;
}
.benchmark-value {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--text-main);
}
.benchmark-sub {
  font-size: 0.75rem;
  color: var(--text-muted);
}
.benchmark-corridor {
  font-size: 1rem;
  font-weight: 750;
  color: var(--blue);
}
.floor-premium-badge {
  background: var(--emerald-subtle);
  border: 1px solid rgba(52, 211, 153, 0.3);
  color: var(--emerald);
  padding: 0.55rem 0.85rem;
  border-radius: 6px;
  font-size: 0.82rem;
  font-weight: 600;
}
.benchmark-psf,
.corridor-psf {
  font-size: 0.85em;
  font-weight: 600;
  color: var(--blue);
  margin-left: 0.35rem;
}
.psf-badge {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--blue);
  margin-left: 0.35rem;
  font-variant-numeric: tabular-nums;
}
.range-psf {
  color: var(--blue);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  margin-left: 0.25rem;
}
.cell-sub {
  display: block;
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--text-muted);
  line-height: 1.25;
  margin-top: 2px;
}
.cell-psf {
  color: var(--blue);
  font-variant-numeric: tabular-nums;
  font-weight: 600;
}
.nearby-amenities-card {
  padding: 0;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}
.nearby-heading {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.nearby-strip-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem;
}
.amenity-items-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem;
}
.amenity-item {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.24rem 0.65rem;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--border);
  font-size: 0.8rem;
  line-height: 1.25;
}
.amenity-icon {
  font-size: 0.9rem;
  line-height: 1;
}
.amenity-text {
  display: inline-flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 0.3rem;
}
.amenity-name {
  font-weight: 600;
}
.amenity-name .address-link {
  font-size: inherit;
  text-decoration: none;
}
.amenity-name .address-link:hover {
  text-decoration: underline;
}
.amenity-distance {
  font-size: 0.75rem;
  color: var(--text-muted);
  white-space: nowrap;
}
.amenity-detail {
  display: inline;
  font-weight: 400;
  font-size: 0.75rem;
}
.nearby-amenities-card[data-expanded=false] .amenity-item:nth-child(n+3) {
  display: none;
}
.nearby-amenities-card[data-expanded=false] .distance-note {
  display: none;
}
.amenities-toggle {
  margin: 0;
  padding: 0.24rem 0.6rem;
  border-radius: 999px;
  border: 1px dashed var(--border-strong);
  background: transparent;
  color: var(--text-muted);
  font-size: 0.78rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
}
.amenities-toggle:hover {
  color: var(--text);
  border-color: var(--navy);
  background: var(--surface);
}
.nearby-amenities-card .distance-note {
  font-size: 0.74rem;
  margin: 0.45rem 0 0;
  border-top: 0;
  padding-top: 0;
}
.distance-note {
  margin-top: 0.5rem;
}
.btn-toggle-map {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.4rem 0.85rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--navy);
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
  min-height: 32px;
}
.btn-toggle-map:hover {
  background: var(--surface-hover);
  border-color: var(--navy);
}
.btn-toggle-map.is-open {
  background: var(--navy);
  color: #ffffff;
  border-color: var(--navy);
}
#property-distance-diagram,
.private-location-map-host {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.45rem;
}
#property-distance-diagram > .btn-toggle-map.is-open,
.private-location-map-host > .btn-toggle-map.is-open {
  align-self: flex-end;
  padding: 0.22rem 0.65rem;
  font-size: 0.76rem;
  min-height: 26px;
  background: transparent;
  color: var(--text-muted);
  border-color: var(--border);
}
#property-distance-diagram > .btn-toggle-map.is-open:hover,
.private-location-map-host > .btn-toggle-map.is-open:hover {
  color: var(--text);
  border-color: var(--border-strong);
  background: var(--surface);
}
.btn-show-on-map {
  display: inline-flex;
  align-items: center;
  padding: 0.15rem 0.45rem;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--text-muted);
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 4px;
  cursor: pointer;
  margin-left: 0.4rem;
  vertical-align: middle;
}
.btn-show-on-map:hover {
  color: var(--navy);
  border-color: var(--navy);
  background: var(--surface-subtle);
}
.expandable-map-panel {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  width: 100%;
}
.expandable-map-panel[hidden] {
  display: none !important;
}
.nearby-workspace {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  width: 100%;
}
.nearby-workspace.has-map {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.nearby-workspace.has-map > .nearby-map-panel {
  order: 1;
  min-width: 0;
  width: 100%;
}
.nearby-workspace.has-map > .nearby-state {
  order: 2;
  min-width: 0;
  width: 100%;
}
.building-details-accordion {
  margin-top: 0;
  border-top: 1px solid var(--border);
  padding-top: 1rem;
}
.details-block {
  margin-bottom: 0.75rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  overflow: hidden;
}
.details-summary-heading {
  padding: 0.6rem 0.85rem;
  font-size: 0.92rem;
  font-weight: 600;
  cursor: pointer;
  background: var(--surface-subtle);
}
.details-content {
  padding: 0.75rem 0.85rem;
}
.composition {
  margin: 0.8rem 0;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.6rem 0.8rem;
  background: var(--surface);
}
.composition h3 {
  font-size: 0.85rem;
  margin: 0 0 0.3rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}
.composition table {
  margin-top: 0.25rem;
}
.composition .composition-total {
  font-size: 0.85rem;
  margin: 0.25rem 0 0;
}
.empty-history {
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.6rem 0.8rem;
  margin-top: 0.5rem;
  background: var(--surface);
}
.empty-history p {
  margin: 0.2rem 0;
  font-size: 0.9rem;
}
.empty-history .next-actions {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  margin-top: 0.5rem;
}
.address-link {
  background: none;
  border: none;
  padding: 0;
  font: inherit;
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 2px;
  cursor: pointer;
}
.address-link:hover,
.address-link:focus-visible {
  text-decoration-thickness: 2px;
  color: var(--navy);
}
.summary {
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.6rem 0.8rem;
  margin: 0.8rem 0;
  background: var(--surface);
}
.summary-label {
  font-weight: 600;
  margin: 0 0 0.15rem;
}
.summary-caveat {
  color: var(--accent-amber);
  font-size: 0.82rem;
  margin: 0 0 0.3rem;
}
.summary-figures {
  margin: 0 0 0.2rem;
  font-size: 1.05rem;
}
.summary-definition {
  color: var(--text-muted);
  font-size: 0.78rem;
  margin: 0;
}
.nearby-coverage {
  border-left: 3px solid var(--accent-amber);
  background: rgba(180, 83, 9, 0.1);
  padding: 0.5rem 0.7rem;
  font-size: 0.85rem;
  margin: 0.6rem 0;
}
.nearby-coverage-short {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin: 0.4rem 0 0.2rem;
}
.nearby-coverage-details {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin: 0 0 0.4rem;
}
.nearby-coverage-details summary {
  cursor: pointer;
}
.nearby-coverage-details p {
  margin: 0.3rem 0;
}
.nearby-flat-type,
.nearby-period {
  margin-left: 0.5rem;
  font-size: 0.82rem;
}
.properties-table {
  margin-top: 0.3rem;
}
.properties-table td,
.properties-table th {
  vertical-align: middle;
}
.nearby-scope {
  font-weight: 600;
  font-size: 0.9rem;
  margin: 0.5rem 0 0.2rem;
}
.nearby-town-switcher {
  margin-left: 0.7rem;
  font-size: 0.85rem;
}
.nearby-return-search {
  font-size: 0.82rem;
  padding: 0.3rem 0.55rem;
  cursor: pointer;
  background: none;
  border: 1px solid var(--border-strong);
  border-radius: 6px;
  margin-left: 0.7rem;
}
.nearby-return-search:hover,
.nearby-return-search:focus-visible {
  background: var(--surface-subtle);
}
.nearby-count {
  font-size: 0.85rem;
  font-weight: 600;
  margin: 0.6rem 0 0.2rem;
}
.empty-nearby {
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.6rem 0.8rem;
  font-size: 0.9rem;
}
.nearby-pagination button {
  margin-right: 0.5rem;
}
.nearby-pagination button:disabled {
  opacity: 0.45;
  cursor: default;
}
.nearby-tx-filter {
  font-size: 0.82rem;
  margin-left: 0.7rem;
}
.nearby-view-switch {
  margin-right: 0.7rem;
}
.nearby-view-switch button {
  font-size: 0.82rem;
  padding: 0.3rem 0.55rem;
  cursor: pointer;
  background: none;
  border: 1px solid var(--border-strong);
}
.nearby-view-switch button:first-child {
  border-radius: 6px 0 0 6px;
}
.nearby-view-switch button:last-child {
  border-radius: 0 6px 6px 0;
}
.nearby-view-switch button.active {
  background: var(--navy);
  color: #fff;
  border-color: var(--navy);
}
.nearby-primary-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.65rem;
  margin: 0.65rem 0;
}
.nearby-primary-actions .nearby-view-switch {
  margin-right: 0;
}
.nearby-refinement-controls {
  width: fit-content;
  margin: 0 0 0.7rem;
}
.nearby-refinement-body {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.55rem;
  max-width: 60rem;
  padding: 0.5rem 0.65rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface-subtle);
}
.nearby-refinement-body .nearby-flat-type,
.nearby-refinement-body .nearby-period,
.nearby-refinement-body .nearby-town-switcher,
.nearby-refinement-body .nearby-return-search,
.nearby-refinement-body .nearby-tx-filter {
  margin-left: 0;
}
.nearby-refinement-body > .hint {
  flex: 1 1 24rem;
  margin: 0;
}
.nearby-townwide-action {
  display: block;
  margin-top: 0.5rem;
  font-size: 0.85rem;
  padding: 0.45rem 0.6rem;
  cursor: pointer;
  background: none;
  border: 1px dashed var(--border-strong);
  border-radius: 6px;
  text-align: left;
}
.nearby-townwide-action:hover,
.nearby-townwide-action:focus-visible {
  background: var(--surface-subtle);
}
#diagnostics {
  margin-top: 2.5rem;
  font-size: 0.8rem;
  color: var(--text-muted);
  border-top: 1px solid var(--border);
  padding-top: 1rem;
}
#diagnostics summary {
  cursor: pointer;
}
.diagnostics-body dt {
  font-weight: 600;
  margin-top: 0.4rem;
}
.diagnostics-body dd {
  margin: 0 0 0.2rem;
  overflow-wrap: anywhere;
}
footer {
  margin-top: 2.5rem;
  font-size: 0.75rem;
  color: var(--text-muted);
  border-top: 1px solid var(--border);
  padding-top: 1rem;
}
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}
.panel-loading {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 1rem 0;
  color: var(--text-muted);
  font-size: 0.88rem;
}
.spinner {
  width: 18px;
  height: 18px;
  border: 2px solid var(--border);
  border-top-color: var(--navy);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
.panel-error {
  padding: 0.75rem;
  background: rgba(190, 18, 60, 0.08);
  border: 1px solid rgba(190, 18, 60, 0.2);
  border-radius: 6px;
  color: var(--accent-red);
  font-size: 0.88rem;
  margin: 0.5rem 0;
}
.btn-retry {
  margin-top: 0.4rem;
  padding: 0.3rem 0.6rem;
  font-size: 0.82rem;
  cursor: pointer;
}
@media (prefers-color-scheme: dark) {
  :root {
    --navy: #38bdf8;
    --navy-hover: #7dd3fc;
  }
  .status,
  .hint,
  .summary-definition,
  footer {
    color: #94a3b8;
  }
  .unavailable,
  .summary-caveat {
    color: #fbbf24;
  }
  .price-evidence-card.primary-card {
    border-color: #38bdf8;
  }
  .filter-select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2394a3b8' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  }
}
.search-paths {
  position: relative;
  width: fit-content;
}
.search-paths > summary {
  cursor: pointer;
  color: var(--navy);
  font-size: 0.8rem;
  font-weight: 600;
  list-style: none;
}
.search-paths > summary::-webkit-details-marker {
  display: none;
}
.search-path-options {
  position: absolute;
  z-index: 22;
  top: 100%;
  left: 0;
  width: min(22rem, calc(100vw - 2rem));
  padding: 0.35rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: 0 8px 20px #0002;
}
.search-path-options button {
  display: block;
  width: 100%;
  padding: 0.55rem 0.65rem;
  border: 0;
  border-radius: 5px;
  background: none;
  text-align: left;
  cursor: pointer;
  font-weight: 600;
}
.search-path-options button span {
  display: block;
  color: var(--text-muted);
  font-size: 0.75rem;
  font-weight: 400;
}
.search-path-options button:hover,
.search-path-options button:focus-visible {
  background: var(--surface-subtle);
}
.coverage-note {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin: 0.8rem 0 1.2rem;
}
.area-answer-header {
  max-width: 58rem;
  margin-bottom: 0.8rem;
}
.area-answer-header h2 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  margin-bottom: 0.2rem;
}
.area-answer-lede {
  margin: 0;
  font-size: 1rem;
}
.area-answer-summary {
  margin: 0.55rem 0 0;
  font-weight: 650;
}
.area-answer-truth {
  margin-top: 0.2rem;
}
.area-answer-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 0.65rem;
  margin: 0.8rem 0;
}
.secondary-controls {
  border: 0;
}
.secondary-controls > summary {
  cursor: pointer;
  min-height: 32px;
  color: var(--navy);
  font-size: 0.85rem;
  font-weight: 650;
}
.area-filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  padding-top: 0.45rem;
}
.area-filter-row .nearby-flat-type,
.area-filter-row .nearby-period {
  margin-left: 0;
  min-height: 40px;
}
.area-recorded-sales > table {
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
}
.area-recorded-sales .nearby-townwide-note {
  color: var(--text-muted);
  font-size: 0.82rem;
}
.property-details-section {
  border: 1px solid var(--border);
  border-radius: 8px;
  margin-bottom: 0.7rem;
  padding: 0.6rem 0.8rem;
  background: var(--surface);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
}
.property-details-summary {
  font-weight: 600;
  cursor: pointer;
}
.property-details-summary:hover {
  color: var(--navy);
}
.property-details-section[open] > .property-details-summary {
  margin-bottom: 0.65rem;
  border-bottom: 1px solid var(--border);
  padding-bottom: 0.45rem;
}
.property-details-section > .composition,
.property-details-section > .summary {
  border: 0;
  padding: 0;
}
.filter-group {
  min-width: 0;
  flex-wrap: wrap;
}
.filter-select {
  max-width: 100%;
  min-height: 44px;
}
.amenity-text {
  min-width: 0;
  overflow-wrap: anywhere;
}
table {
  display: block;
  max-width: 100%;
  overflow-x: auto;
}
.table-responsive table {
  display: table;
}
.responsive-transaction-table {
  display: table;
  table-layout: auto;
}
.dossier {
  min-width: 0;
}
button,
summary {
  min-height: 32px;
}
button {
  color: inherit;
  font: inherit;
}
.btn-retry,
.btn-pager {
  min-height: 44px;
}
button:focus-visible,
select:focus-visible,
summary:focus-visible,
.table-responsive:focus-visible {
  outline: 2px solid var(--navy);
  outline-offset: 2px;
}
.panel-error {
  color: var(--text-main);
}
@media (max-width: 600px) {
  body {
    --rf-app-gutter: 1rem;
    padding-inline: var(--rf-app-gutter);
  }
  .header-brand h1 {
    font-size: 1rem;
  }
  .property-heading-pane h2 {
    font-size: 1.25rem;
  }
  .property-filters-bar {
    gap: 0.5rem;
    padding: 0.6rem;
  }
  .property-filters-bar .filter-group {
    flex: 1 1 9rem;
  }
  .property-filters-bar .filter-select {
    width: 100%;
  }
  .price-cards-grid {
    grid-template-columns: minmax(0, 1fr);
  }
  .price-cards-grid .price-evidence-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
  }
  .price-cards-grid .card-label {
    max-width: 45%;
    margin: 0;
  }
  .price-cards-grid .card-value,
  .price-cards-grid .card-value-small {
    text-align: right;
    max-width: 55%;
    font-size: 1rem;
  }
  .search-path-options {
    position: fixed;
    top: 7.1rem;
    left: 1rem;
    right: 1rem;
    width: auto;
  }
  .area-answer-actions {
    align-items: center;
  }
  .nearby-primary-actions {
    align-items: stretch;
  }
  .nearby-primary-actions .nearby-view-switch {
    display: flex;
    flex: 1 1 100%;
  }
  .nearby-primary-actions .nearby-view-switch button {
    flex: 1 1 50%;
    min-height: 44px;
  }
  .nearby-refinement-controls {
    width: 100%;
  }
  .nearby-refinement-body {
    align-items: stretch;
  }
  .nearby-refinement-body select {
    width: 100%;
    min-height: 44px;
  }
  .table-responsive {
    overflow: visible;
    border: 0;
    background: transparent;
    box-shadow: none;
  }
  .table-responsive table,
  .responsive-transaction-table,
  .responsive-transaction-table tbody {
    display: block;
    width: 100%;
    max-width: 100%;
    overflow: visible;
  }
  .table-responsive thead,
  .responsive-transaction-table thead {
    display: none;
  }
  .responsive-transaction-table tbody {
    display: grid;
    gap: 0.65rem;
  }
  .responsive-transaction-table .responsive-transaction-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 0.45rem 0.75rem;
    padding: 0.7rem;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
  }
  .responsive-transaction-table .responsive-transaction-row td {
    min-width: 0;
    padding: 0;
    border: 0;
    white-space: normal;
    text-align: left;
    overflow-wrap: anywhere;
  }
  .responsive-transaction-table .responsive-transaction-row td::before {
    content: attr(data-label);
    display: block;
    margin-bottom: 0.06rem;
    color: var(--text-muted);
    font-size: 0.65rem;
    font-weight: 600;
    letter-spacing: 0.03em;
    text-transform: uppercase;
  }
  .responsive-transaction-table .responsive-transaction-row td[data-label=Price] {
    grid-column: 2;
    grid-row: 1;
    color: var(--text-main);
    font-weight: 750;
    text-align: right;
    white-space: nowrap;
  }
  .responsive-transaction-table .responsive-transaction-row td[data-label=Date] {
    grid-column: 1;
    grid-row: 1;
    font-weight: 650;
  }
  .nearby-transaction-row td[data-label=Property] {
    grid-column: 1 / -1;
  }
  .nearby-transaction-row td[data-label="Flat type"],
  .nearby-transaction-row td[data-label="Floor band"],
  .nearby-transaction-row td[data-label=Area] {
    grid-column: auto;
  }
  .block-transaction-row td[data-label="Flat type"] {
    grid-column: 1 / -1;
  }
  .btn-show-on-map {
    margin: 0.25rem 0 0 0.5rem;
  }
  .table-pagination,
  .nearby-pagination {
    justify-content: space-between;
    flex-wrap: wrap;
  }
}
@media (prefers-reduced-motion: reduce) {
  .spinner {
    animation: none;
  }
  .drawer,
  .drawer-overlay {
    transition: none !important;
  }
}
.drawer-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  z-index: 998;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}
.drawer-overlay.open {
  opacity: 1;
  pointer-events: auto;
}
.drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: 380px;
  max-width: 90vw;
  background: var(--surface);
  border-left: 1px solid var(--border);
  z-index: 999;
  box-shadow: -8px 0 32px rgba(0, 0, 0, 0.35);
  transform: translateX(100%);
  display: flex;
  flex-direction: column;
  padding: 1.5rem;
  overflow-y: auto;
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}
.drawer.open {
  transform: translateX(0);
}
.drawer[hidden] {
  display: none !important;
}
.drawer-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border);
  margin-bottom: 1.5rem;
}
.drawer-header h2 {
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--text-main);
  margin: 0;
}
.btn-close {
  background: none;
  border: none;
  font-size: 1.25rem;
  color: var(--text-muted);
  cursor: pointer;
  padding: 0.2rem 0.5rem;
  line-height: 1;
}
.btn-close:hover {
  color: var(--text-main);
}
.drawer-section {
  margin-bottom: 1.5rem;
}
.drawer-section h3 {
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  margin: 0 0 0.8rem;
}
.theme-segmented {
  display: flex;
  background: var(--surface-subtle);
  padding: 0.25rem;
  border-radius: 8px;
  border: 1px solid var(--border);
}
.theme-btn {
  flex: 1;
  padding: 0.5rem;
  font-size: 0.82rem;
  font-weight: 600;
  border: none;
  background: transparent;
  color: var(--text-muted);
  border-radius: 6px;
  cursor: pointer;
  transition:
    background 0.15s ease,
    color 0.15s ease,
    box-shadow 0.15s ease;
}
.theme-btn.active {
  background: var(--surface);
  color: var(--text-main);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}
.provenance-table {
  width: 100%;
  table-layout: fixed;
  border-collapse: collapse;
  font-size: 0.85rem;
}
.provenance-table tr {
  border-bottom: 1px solid var(--border);
}
.provenance-table td {
  padding: 0.5rem 0;
  color: var(--text-muted);
  white-space: normal;
  overflow-wrap: anywhere;
  vertical-align: top;
}
.provenance-table td:first-child {
  width: 46%;
  padding-right: 0.65rem;
}
.provenance-table td:last-child {
  text-align: right;
  font-weight: 600;
  color: var(--text-main);
  font-variant-numeric: tabular-nums;
}
.rules-list {
  list-style: none;
  font-size: 0.82rem;
  color: var(--text-muted);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding: 0;
  margin: 0;
}
.rules-list li strong {
  color: var(--text-main);
  display: block;
  margin-bottom: 0.15rem;
}
.drawer #diagnostics {
  margin-top: 0;
  border-top: none;
  padding-top: 0;
}
.drawer-footer {
  margin-top: auto;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border);
  font-size: 0.75rem;
  color: var(--text-muted);
  line-height: 1.45;
}
.results a[data-kind=area],
.results a[data-kind=district],
.results a[data-kind=project],
.results a[data-kind=private-sales] {
  text-decoration: none;
  box-sizing: border-box;
}
.private-directory-container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 1.5rem 1rem;
  text-align: left;
}
.directory-breadcrumbs ol {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 0.55rem;
  margin: 0 0 1.5rem;
  padding: 0;
  list-style: none;
  color: var(--text-muted);
  font-size: 0.85rem;
}
.directory-breadcrumbs li:not(:last-child)::after {
  content: "/";
  margin-left: 0.55rem;
}
.directory-breadcrumbs a {
  color: var(--blue);
  text-decoration: underline;
}
.directory-header h1 {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  margin: 0 0 0.5rem;
  color: var(--text-main);
}
.directory-lead {
  font-size: 1.05rem;
  color: var(--text-muted);
  margin-bottom: 2rem;
  max-width: 70ch;
}
.directory-districts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1rem;
}
.directory-district-card {
  display: flex;
  flex-direction: column;
  padding: 1.25rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  text-decoration: none;
  color: var(--text-main);
  transition: border-color 0.15s, background-color 0.15s;
}
.directory-district-card:hover {
  border-color: var(--blue);
  background: var(--surface-subtle);
}
.district-badge {
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--blue);
  margin-bottom: 0.35rem;
}
.district-localities {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.4;
}
.education-view {
  max-width: 1120px;
  margin-inline: auto;
  min-width: 0;
}
.education-view h2 {
  margin-bottom: .35rem;
  overflow-wrap: anywhere;
}
.education-type,
.education-address {
  margin: .3rem 0;
  color: var(--text-muted);
}
.education-intro {
  max-width: 65ch;
}
.education-controls {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: .7rem 1.2rem;
  margin: 1.3rem 0 .6rem;
}
.education-controls label {
  display: flex;
  align-items: center;
  gap: .4rem;
}
.education-controls select,
.education-controls button,
.education-pagination button {
  min-height: 40px;
  max-width: 100%;
  background: var(--surface);
  color: var(--text-main);
  border: 1px solid var(--border);
  border-radius: 5px;
  padding: .45rem .65rem;
}
.education-view a {
  color: var(--blue);
}
.education-view :is(a, button, select):focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 3px;
}
.education-pagination button:disabled {
  opacity: .45;
}
.education-distance-note {
  font-size: .85rem;
  color: var(--text-muted);
  max-width: 85ch;
}
.education-map {
  height: auto;
  min-width: 0;
  margin: 1rem 0;
}
.education-map .map-viewport {
  height: 380px;
  flex: 0 0 auto;
}
.education-map[hidden] {
  display: none;
}
.education-results-summary {
  font-weight: 600;
  margin-top: 1.5rem;
}
.education-properties {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 2rem;
}
.education-property {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: .35rem .75rem;
  padding: 1rem 0;
  border-bottom: 1px solid var(--border,#273449);
}
.education-property > a {
  grid-column: 1;
  overflow-wrap: anywhere;
  font-weight: 600;
}
.education-property-type {
  grid-column: 1;
  font-size: .8rem;
  color: var(--text-muted);
}
.education-property-distance {
  grid-column: 2;
  grid-row: 1 / 3;
  align-self: center;
  font-size: .9rem;
  white-space: nowrap;
}
.education-property p {
  grid-column: 1 / -1;
  font-size: .85rem;
  margin: .2rem 0;
  color: var(--text-muted);
}
.education-pagination {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: .75rem;
  margin: 1rem 0 1.8rem;
}
.education-view details {
  margin-top: 1rem;
  font-size: .85rem;
  max-width: 80ch;
}
.education-view summary {
  cursor: pointer;
}
@media (max-width: 600px) {
  .education-properties {
    grid-template-columns: 1fr;
  }
  .education-map .map-viewport {
    height: 320px;
  }
  .education-controls {
    align-items: flex-start;
    gap: .7rem;
  }
  .education-controls label {
    flex: 1 1 100%;
    justify-content: space-between;
  }
  .education-controls label select {
    width: 65%;
  }
  .education-view h2 {
    font-size: 1.5rem;
  }
}
.site-footer {
  max-width: 68rem;
  margin: 1.5rem auto 0;
  padding: 0;
  border: 0;
}
body:not(.view-active) .site-footer {
  max-width: 45rem;
}
.provenance-bar-summary {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  min-height: 44px;
  color: var(--text-muted);
  font-size: 0.8rem;
  list-style: none;
  cursor: pointer;
}
.provenance-bar-summary::-webkit-details-marker {
  display: none;
}
.provenance-bar-summary:hover {
  color: var(--text-main);
  text-decoration: underline;
}
.provenance-bar-summary::after {
  content: "";
  width: 0.35rem;
  height: 0.35rem;
  border: solid currentColor;
  border-width: 1px 1px 0 0;
  transform: rotate(45deg);
}
.provenance-bar[open] > .provenance-bar-summary::after {
  transform: rotate(135deg);
}
.provenance-bar-meta {
  grid-column: 1 / -1;
  margin: 0;
  font-size: 0.78rem;
  color: var(--text-muted);
}
.provenance-bar-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 1rem 1.5rem;
  padding: 1rem 0;
  border-top: 1px solid var(--border);
}
@media (max-width: 820px) {
  .provenance-bar-body {
    grid-template-columns: minmax(0, 1fr);
  }
}
.provenance-col h3 {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-main);
  margin: 0 0 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.provenance-diagnostics {
  margin-top: 1rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--border);
  font-size: 0.82rem;
}
.provenance-diagnostics summary {
  cursor: pointer;
  color: var(--text-muted);
  font-weight: 600;
}
.provenance-bar-foot {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem;
  padding: 0.65rem 0;
  border-top: 1px solid var(--border);
  font-size: 0.75rem;
  color: var(--text-muted);
}
.property-estimate-cta {
  margin-top: 0.75rem;
}
.property-estimate-cta .val-entry-btn {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
}
.val-shell {
  max-width: 1040px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 1.15rem;
  min-width: 0;
}
.val-header h2 {
  margin: 0 0 0.3rem;
  font-size: clamp(1.45rem, 3vw, 1.95rem);
  color: var(--text-main);
}
.val-trust-bar {
  margin: 0;
  display: inline-block;
  padding: 0.35rem 0.75rem;
  border-radius: 8px;
  background: var(--emerald-subtle);
  color: var(--emerald);
  font-size: 0.82rem;
  font-weight: 600;
}
.val-picker-section {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 0.95rem 1.05rem;
}
.val-picker-label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-main);
  margin-bottom: 0.45rem;
}
.val-picker-row {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}
.val-picker-row input {
  flex: 1 1 auto;
  min-width: 0;
  min-height: 44px;
  padding: 0.5rem 0.85rem;
  font: inherit;
  font-size: 0.95rem;
  background: var(--input-bg);
  color: var(--text-main);
  border: 1px solid var(--border-strong);
  border-radius: 8px;
}
.val-picker-row input:focus {
  outline: none;
  border-color: var(--blue);
  box-shadow: 0 0 0 3px var(--blue-subtle);
}
.val-picker-submit {
  min-height: 44px;
  padding: 0 1.05rem;
  background: var(--blue);
  color: #ffffff;
  border: 1px solid var(--blue);
  border-radius: 8px;
  font: inherit;
  font-size: 0.92rem;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.15s ease, border-color 0.15s ease;
}
.val-picker-submit:hover {
  background: var(--blue-hover);
  border-color: var(--blue-hover);
}
.val-picker-submit:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 2px;
}
.val-picker-clear {
  min-height: 44px;
  white-space: nowrap;
}
.val-picker-status {
  margin: 0.55rem 0 0;
}
.val-picker-status--warn {
  padding: 0.55rem 0.8rem;
  border-radius: 8px;
  border: 1px solid rgba(251, 191, 36, 0.35);
  background: var(--amber-subtle);
  color: var(--amber);
  font-weight: 600;
}
.val-picker-status--error {
  padding: 0.55rem 0.8rem;
  border-radius: 8px;
  border: 1px solid rgba(251, 113, 133, 0.35);
  background: var(--rose-subtle);
  color: var(--rose);
  font-weight: 600;
}
[data-theme=light] .val-picker-status--warn {
  border-color: rgba(180, 83, 9, 0.28);
}
[data-theme=light] .val-picker-status--error {
  border-color: rgba(225, 29, 72, 0.28);
}
.val-picker-results {
  list-style: none;
  margin: 0.55rem 0 0;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface-elevated);
  overflow: hidden;
}
.val-picker-results li + li {
  border-top: 1px solid var(--border);
}
.val-picker-option {
  width: 100%;
  text-align: left;
  background: transparent;
  border: none;
  padding: 0.65rem 0.85rem;
  color: var(--text-main);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}
.val-picker-option:hover,
.val-picker-option:focus-visible {
  background: var(--blue-subtle);
  outline: none;
}
.val-landing-guide,
.val-target-card,
.val-headline-card,
.val-receipt-card,
.val-comps-section,
.val-refusal-card,
.val-proceeds-drawer {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.05rem 1.15rem;
}
.val-landing-lead {
  margin: 0 0 0.65rem;
  font-weight: 600;
  color: var(--text-main);
}
.val-landing-bullets {
  margin: 0;
  padding-left: 1.2rem;
  color: var(--text-muted);
  font-size: 0.9rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}
.val-workspace,
.val-results-root {
  display: flex;
  flex-direction: column;
  gap: 1.05rem;
  min-width: 0;
}
.val-target-top {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.75rem;
}
.val-target-title {
  margin: 0;
  font-size: 1.25rem;
  color: var(--text-main);
}
.val-target-meta {
  margin: 0.2rem 0 0;
  font-size: 0.88rem;
  color: var(--text-muted);
}
.val-controls-grid {
  margin-top: 1rem;
  padding-top: 0.9rem;
  border-top: 1px solid var(--border);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 0.85rem;
  align-items: end;
}
.val-control-wide {
  grid-column: 1 / -1;
}
.val-control-block {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  min-width: 0;
}
.val-control-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
}
.val-pill-group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}
.val-pill {
  min-height: 36px;
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  border: 1px solid var(--border-strong);
  background: var(--surface-subtle);
  color: var(--text-main);
  font: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
}
.val-pill.active {
  background: var(--blue);
  border-color: var(--blue);
  color: #ffffff;
}
.val-controls-grid select,
.val-area-input-row input,
.val-proceeds-grid input,
.val-proceeds-grid select {
  min-height: 40px;
  padding: 0.4rem 0.65rem;
  background: var(--input-bg);
  color: var(--text-main);
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  font: inherit;
  font-size: 0.9rem;
  min-width: 0;
}
.val-area-input-row {
  display: flex;
  gap: 0.45rem;
  align-items: center;
}
.val-area-input-row input {
  flex: 1 1 90px;
}
.val-headline-top {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.75rem;
}
.val-eyebrow {
  margin: 0 0 0.2rem;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted);
}
.val-range-figure {
  font-size: clamp(1.55rem, 3.8vw, 2.2rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text-main);
  line-height: 1.15;
}
.val-midpoint-line {
  margin: 0.35rem 0 0;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--blue);
}
.val-confidence-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.3rem 0.75rem;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 700;
  white-space: nowrap;
}
.val-confidence-badge.confidence-high {
  background: var(--emerald-subtle);
  color: var(--emerald);
}
.val-confidence-badge.confidence-moderate {
  background: var(--blue-subtle);
  color: var(--blue);
}
.val-confidence-badge.confidence-low {
  background: var(--amber-subtle);
  color: var(--amber);
}
.val-headline-meta {
  margin: 0.65rem 0 0;
  font-size: 0.85rem;
  color: var(--text-muted);
}
.val-split-bar {
  margin-top: 0.7rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 0.55rem;
}
.val-split-chip {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: baseline;
  gap: 0.25rem 0.6rem;
  padding: 0.5rem 0.75rem;
  border-radius: 8px;
  background: var(--surface-subtle);
  border: 1px solid var(--border);
}
.val-split-chip--primary {
  border-color: var(--blue);
  background: var(--blue-subtle);
}
.val-split-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
}
.val-split-chip--primary .val-split-label {
  color: var(--text-main);
}
.val-split-val {
  font-size: 0.94rem;
  font-weight: 700;
  color: var(--text-main);
  font-variant-numeric: tabular-nums;
}
.val-split-chip--primary .val-split-val {
  color: var(--blue);
}
.val-skew-note {
  margin: 0.6rem 0 0;
  padding: 0.5rem 0.75rem;
  border-radius: 8px;
  background: var(--surface-subtle);
  border-left: 3px solid var(--blue);
  color: var(--text-muted);
  font-size: 0.83rem;
}
.val-private-scope-note {
  margin: 0.65rem 0 0;
  padding: 0.58rem 0.8rem;
  border-radius: 8px;
  background: var(--surface-subtle);
  border: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 0.83rem;
  line-height: 1.45;
}
.val-private-scope-note strong {
  color: var(--text-main);
}
.val-notice-warn {
  margin: 0.65rem 0 0;
  padding: 0.5rem 0.75rem;
  border-radius: 8px;
  background: var(--amber-subtle);
  color: var(--amber);
  font-size: 0.84rem;
  font-weight: 600;
}
.val-share-bar {
  margin-top: 0.85rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}
.val-share-btn {
  text-decoration: none;
  display: inline-flex;
  align-items: center;
}
.val-pdf-btn {
  min-height: 40px;
  padding: 0.45rem 0.95rem;
  border-radius: 8px;
  background: var(--blue);
  border: 1px solid var(--blue);
  color: #ffffff;
  font: inherit;
  font-size: 0.88rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
}
.val-pdf-btn:hover:not(:disabled) {
  background: var(--blue-hover);
  border-color: var(--blue-hover);
}
.val-pdf-btn:disabled {
  opacity: 0.65;
  cursor: wait;
}
.val-pdf-note-drawer {
  margin-top: 0.85rem;
  padding: 0.7rem 0.85rem;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--surface-subtle);
}
.val-pdf-note-drawer summary {
  cursor: pointer;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-main);
}
.val-pdf-note-body {
  margin-top: 0.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.val-pdf-note-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.7rem;
}
.val-pdf-note-grid label {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
  min-width: 0;
}
.val-pdf-note-wide {
  grid-column: 1 / -1;
}
.val-pdf-note-grid input,
.val-pdf-note-grid textarea {
  width: 100%;
  min-width: 0;
  padding: 0.45rem 0.65rem;
  background: var(--input-bg);
  color: var(--text-main);
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  font: inherit;
  font-size: 0.88rem;
  resize: vertical;
}
.val-pdf-note-grid input:focus,
.val-pdf-note-grid textarea:focus {
  outline: none;
  border-color: var(--blue);
  box-shadow: 0 0 0 3px var(--blue-subtle);
}
.val-pdf-note-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.6rem;
}
.val-receipt-card h3,
.val-comps-section h3,
.val-refusal-card h3 {
  margin: 0 0 0.35rem;
  font-size: 1.08rem;
  color: var(--text-main);
}
.val-waterfall-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 0.75rem;
}
.val-waterfall-table td {
  padding: 0.55rem 0.25rem;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
  white-space: normal;
  overflow-wrap: anywhere;
}
.val-wf-step {
  display: block;
  font-weight: 600;
  color: var(--text-main);
  font-size: 0.9rem;
}
.val-wf-detail {
  display: block;
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 0.1rem;
}
.val-waterfall-table td.val-wf-amount {
  text-align: right;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  color: var(--text-main);
}
.val-wf-total td {
  background: var(--surface-subtle);
  padding-inline: 0.5rem;
}
.val-wf-headline td {
  border-bottom: none;
  padding-top: 0.7rem;
}
.val-wf-headline .val-wf-step,
.val-wf-headline .val-wf-amount {
  color: var(--blue);
  font-size: 0.98rem;
}
.val-wf-user td {
  background: var(--blue-subtle);
  padding-inline: 0.5rem;
}
.val-wf-user .val-wf-step,
.val-wf-user .val-wf-amount {
  color: var(--text-main);
}
.val-condition-banner {
  margin: 0.6rem 0 0;
  padding: 0.5rem 0.75rem;
  border-radius: 8px;
  background: var(--blue-subtle);
  border: 1px solid var(--blue);
  color: var(--text-main);
  font-size: 0.83rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.4rem 0.75rem;
}
.val-condition-banner[hidden] {
  display: none;
}
.val-inline-reset {
  appearance: none;
  background: transparent;
  border: 1px solid var(--border-strong);
  border-radius: 6px;
  color: var(--blue);
  font: inherit;
  font-size: 0.78rem;
  font-weight: 700;
  padding: 0.2rem 0.55rem;
  cursor: pointer;
  white-space: nowrap;
}
.val-inline-reset:hover {
  background: var(--surface);
  border-color: var(--blue);
}
.val-formula-details {
  margin-top: 0.85rem;
  font-size: 0.85rem;
}
.val-formula-details summary {
  cursor: pointer;
  color: var(--blue);
  font-weight: 600;
}
.val-formula-body {
  margin-top: 0.5rem;
  padding: 0.65rem 0.8rem;
  border-radius: 8px;
  background: var(--surface-subtle);
  color: var(--text-muted);
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}
.val-formula-body p {
  margin: 0;
}
.val-condition-box {
  margin-top: 0.95rem;
  padding: 0.75rem 0.9rem;
  border: 1px dashed var(--border-strong);
  border-radius: 10px;
  background: var(--surface-subtle);
}
.val-condition-header {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.86rem;
  margin-bottom: 0.4rem;
}
.val-condition-header-right {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.val-condition-box input[type=range] {
  width: 100%;
}
.val-condition-scale {
  display: flex;
  justify-content: space-between;
  gap: 0.5rem;
  font-size: 0.75rem;
  color: var(--text-muted);
  margin: 0.2rem 0 0.45rem;
}
.val-condition-result {
  margin: 0.45rem 0 0;
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--blue);
}
.val-comps-header {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem 0.75rem;
}
.val-comps-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
}
.val-impact-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.3rem 0.65rem;
  border-radius: 999px;
  background: var(--blue-subtle);
  color: var(--blue);
  font-size: 0.8rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.val-comps-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 0.65rem;
  font-size: 0.86rem;
}
.val-comps-table th,
.val-comps-table td {
  padding: 0.55rem 0.5rem;
  border-bottom: 1px solid var(--border);
  text-align: left;
  vertical-align: top;
  white-space: normal;
}
.val-comps-table th {
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--text-muted);
}
.val-comps-table tr.val-comp-excluded {
  opacity: 0.5;
}
.val-weight-bar {
  display: block;
  width: 64px;
  height: 5px;
  margin-top: 0.25rem;
  background: var(--surface-subtle);
  border-radius: 999px;
  overflow: hidden;
}
.val-weight-bar-fill {
  display: block;
  height: 100%;
  background: var(--blue);
}
.val-proceeds-drawer summary {
  cursor: pointer;
  font-weight: 700;
  color: var(--text-main);
}
.val-proceeds-body {
  margin-top: 0.9rem;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}
.val-proceeds-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 0.75rem;
}
.val-proceeds-grid label {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-muted);
}
.val-proceeds-output {
  padding: 0.75rem 0.9rem;
  background: var(--surface-subtle);
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}
.val-proceeds-output p {
  margin: 0;
  font-size: 0.9rem;
  color: var(--text-main);
}
.val-proceeds-links a {
  color: var(--blue);
  font-weight: 600;
}
.val-loading {
  color: var(--text-muted);
  font-size: 0.92rem;
}
.val-not-found-card {
  border-left: 4px solid var(--amber);
}
.val-not-found-card p {
  margin: 0.45rem 0 0;
  color: var(--text-muted);
  font-size: 0.92rem;
}
.val-not-found-list {
  margin: 0.75rem 0 1rem;
  padding-left: 1.2rem;
  color: var(--text-muted);
  font-size: 0.88rem;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}
.val-not-found-list strong {
  color: var(--text-main);
}
@media (max-width: 640px) {
  .val-picker-row {
    flex-wrap: wrap;
  }
  .val-picker-row input {
    flex: 1 1 100%;
  }
  .val-picker-submit {
    flex: 1 1 auto;
  }
  .val-pdf-note-grid {
    grid-template-columns: minmax(0, 1fr);
  }
  .val-target-card,
  .val-headline-card,
  .val-receipt-card,
  .val-comps-section,
  .val-refusal-card,
  .val-proceeds-drawer,
  .val-picker-section {
    padding: 0.85rem 0.9rem;
  }
  .val-comps-table thead {
    display: none;
  }
  .val-comps-table,
  .val-comps-table tbody,
  .val-comps-table tr,
  .val-comps-table td {
    display: block;
    width: 100%;
  }
  .val-comps-table tr {
    padding: 0.65rem 0;
    border-bottom: 1px solid var(--border-strong);
  }
  .val-comps-table td {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: flex-start;
    gap: 0.2rem 0.75rem;
    padding: 0.28rem 0;
    border-bottom: none;
    text-align: right;
    white-space: normal;
    min-width: 0;
  }
  .val-comps-table td > span {
    max-width: 100%;
    min-width: 0;
    overflow-wrap: anywhere;
  }
  .val-comps-table td .cell-sub {
    flex: 1 1 100%;
    text-align: right;
  }
  .val-comps-table td::before {
    content: attr(data-label);
    font-weight: 600;
    color: var(--text-muted);
    text-align: left;
    flex-shrink: 0;
  }
  .val-weight-bar {
    margin-left: auto;
  }
}
