*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; height: 100%; font-family: ui-sans-serif, system-ui, sans-serif; background: #0f1419; color: #e8eef4; }
a { color: #8cb4ff; }
.shell { min-height: 100%; height: 100%; display: flex; flex-direction: column; }
.top { display: flex; gap: 1.2rem; padding: 0.8rem 1.2rem; background: #1a222c; align-items: center; }
.top .legal { margin-left: auto; font-size: 0.8rem; opacity: 0.7; }
main { padding: 1.2rem; flex: 1; min-height: 0; overflow: auto; display: flex; flex-direction: column; }
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 0.8rem; }
.card { background: #1a222c; padding: 1rem; border-radius: 8px; }
.card h3 { margin: 0 0 0.4rem; font-size: 0.85rem; opacity: 0.7; font-weight: 500; }
.card p { margin: 0; font-size: 1.4rem; }
.banner { padding: 0.7rem 1rem; border-radius: 6px; margin-bottom: 1rem; }
.banner.err { background: #5a1d1d; }
.banner.warn { background: #5a4a1d; }
form, .stack { display: flex; flex-direction: column; gap: 0.6rem; max-width: 40rem; }
label { font-size: 0.85rem; }
.hint { font-size: 0.8rem; opacity: 0.7; margin: 0; max-width: 40rem; }
input, textarea, button, select { font: inherit; padding: 0.45rem 0.6rem; border-radius: 6px; border: 1px solid #334; background: #0f1419; color: inherit; }
button { background: #2b4c7e; cursor: pointer; border: 0; }
button.ghost { background: #333; }
.row { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.toolbar { display: flex; flex-wrap: wrap; gap: 0.5rem 0.8rem; align-items: center; margin-bottom: 0.6rem; background: #1a222c; padding: 0.55rem 0.75rem; border-radius: 8px; }
.toolbar .stats { display: flex; flex-wrap: wrap; gap: 0.35rem 0.9rem; font-size: 0.85rem; margin-right: auto; }
.toolbar .stats b { font-weight: 600; }
.toolbar label { display: flex; align-items: center; gap: 0.35rem; margin: 0; }
.toolbar input[type=number] { width: 3.5rem; }
.toolbar input.jsess { min-width: 12rem; flex: 1; }
.toolbar .hint { max-width: none; }
.map-page { display: flex; flex-direction: column; flex: 1; min-height: 0; }
.map-page h1 { margin: 0 0 0.5rem; font-size: 1.2rem; }
#map { width: 100%; height: 100%; min-height: 16rem; border-radius: 8px; }
.split { flex: 1; min-height: 24rem; display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(20rem, 0.9fr); gap: 0.6rem; }
.tx-pane { display: flex; flex-direction: column; min-height: 0; background: #1a222c; border-radius: 8px; overflow: hidden; }
.tx-head { display: flex; align-items: baseline; justify-content: space-between; gap: 0.6rem; padding: 0.65rem 0.8rem; border-bottom: 1px solid #2a3340; }
.tx-head h2 { margin: 0; font-size: 0.95rem; }
.tx-head span { font-size: 0.8rem; opacity: 0.7; }
.tx-detail { padding: 0.65rem 0.8rem; border-bottom: 1px solid #2a3340; background: #16202b; font-size: 0.85rem; }
.tx-detail strong { display: block; margin-bottom: 0.15rem; }
.tx-facts { display: flex; flex-wrap: wrap; gap: 0.35rem 0.7rem; margin-top: 0.4rem; opacity: 0.9; }
.tx-facts em { font-style: normal; opacity: 0.6; margin-right: 0.25rem; }
.tx-list { flex: 1; min-height: 20rem; overflow: auto; }
.tx-list .hint { padding: 0.8rem; }
.tx-row { display: grid; grid-template-columns: 8px 1fr auto; gap: 0.55rem; align-items: center; padding: 0.45rem 0.7rem; min-height: 58px; border-bottom: 1px solid #2a3340; cursor: pointer; }
.tx-row:hover { background: #22303d; }
.tx-row.on { background: #2b4c7e; }
.tx-swatch { width: 8px; height: 2.2rem; border-radius: 4px; background: #adb5bd; }
.tx-swatch.condo { background: #6ea8fe; }
.tx-swatch.plex { background: #75b798; }
.tx-swatch.uni { background: #ffda6a; }
.tx-title { font-size: 0.9rem; }
.tx-sub { font-size: 0.75rem; opacity: 0.7; }
.tx-amt { font-variant-numeric: tabular-nums; white-space: nowrap; font-size: 0.9rem; }
@media (max-width: 900px) {
  .split { grid-template-columns: 1fr; grid-template-rows: minmax(16rem, 42%) minmax(0, 1fr); }
}
.filters { display: flex; gap: 0.8rem; flex-wrap: wrap; margin-bottom: 0.6rem; align-items: end; }
.filters.facts { gap: 0.45rem 0.7rem; max-height: 28vh; overflow: auto; padding-bottom: 0.3rem; flex-shrink: 0; }
.filters.facts label { display: flex; flex-direction: column; gap: 0.15rem; }
.filters.facts input, .filters.facts select { min-width: 7.5rem; }
.filters.facts .wide { min-width: 16rem; flex: 1; }
.filters.facts .wide input { min-width: 100%; }
.filters.nested { max-height: none; overflow: visible; margin-top: 0.5rem; }
.filters fieldset.types { border: 1px solid #334; border-radius: 6px; padding: 0.3rem 0.6rem; display: flex; gap: 0.7rem; flex-wrap: wrap; align-items: center; }
.filters fieldset.types label { flex-direction: row; align-items: center; gap: 0.3rem; }
.filters details { width: 100%; }
.filters summary { cursor: pointer; opacity: 0.8; }
.place { position: relative; }
.suggest { position: absolute; z-index: 20; left: 0; right: 0; margin: 0; padding: 0.2rem; list-style: none; background: #1a222c; border: 1px solid #334; border-radius: 6px; max-height: 12rem; overflow: auto; }
.suggest button { width: 100%; text-align: left; background: transparent; }
.suggest button:hover { background: #2b4c7e; }
.maplibregl-popup-content { background: #1a222c; color: #e8eef4; border-radius: 8px; max-height: 22rem; overflow: auto; min-width: 16rem; font-size: 0.85rem; }
.maplibregl-popup-content .k { opacity: 0.65; display: inline-block; min-width: 5.5rem; }
.maplibregl-popup-content .hist { margin-top: 0.45rem; padding-top: 0.4rem; border-top: 1px solid #334; }
.maplibregl-popup-anchor-bottom .maplibregl-popup-tip { border-top-color: #1a222c; }
.tx-hist { margin-top: 0.5rem; font-size: 0.8rem; }
.tx-hist em { display: block; font-style: normal; opacity: 0.6; margin-bottom: 0.2rem; }
.tx-thumbs { display: flex; gap: 0.35rem; flex-wrap: wrap; margin-top: 0.45rem; }
.tx-thumbs img { width: 4.5rem; height: 4.5rem; object-fit: cover; border-radius: 4px; background: #0f1419; }
.dlq { background: #1a222c; border-radius: 8px; margin-bottom: 0.8rem; overflow: hidden; }
.dlq .feed-head { gap: 0.8rem; }
.dlq .feed-head h2 { margin-right: auto; }
.dlq-list { overflow: auto; max-height: 22rem; }
.dlq-table { width: 100%; border-collapse: collapse; font-size: 0.85rem; }
.dlq-table th, .dlq-table td { text-align: left; padding: 0.4rem 0.8rem; border-bottom: 1px solid #2a3340; vertical-align: top; }
.dlq-table th { opacity: 0.6; font-weight: 500; }
.dlq-table code { font-size: 0.8rem; }
.feeds { display: grid; grid-template-columns: 1fr 1fr; gap: 0.6rem; margin-top: 0.6rem; flex-shrink: 0; }
@media (max-width: 900px) { .feeds { grid-template-columns: 1fr; } }
.feed { background: #1a222c; border-radius: 8px; display: flex; flex-direction: column; min-height: 0; }
.feed-head { display: flex; align-items: baseline; justify-content: space-between; gap: 0.6rem; padding: 0.55rem 0.8rem; border-bottom: 1px solid #2a3340; }
.feed-head h2 { margin: 0; font-size: 0.95rem; }
.feed-head span { font-size: 0.8rem; opacity: 0.7; }
.feed-list { overflow: auto; min-height: 0; }
.feed .tx-row { min-height: 48px; }
