:root {
  color-scheme: light;
  --ink: #273322;
  --muted: #697164;
  --paper: #eee9dc;
  --panel: #fffdf5;
  --line: #d8d1bf;
  --blue: #4b7890;
  --teal: #5f8f4e;
  --red: #c65b44;
  --amber: #df9a35;
  --violet: #7b6f58;
  --mint: #e3efd9;
  --sky: #e1edf0;
  --rose: #f7e6dc;
  --road: #d95f2b;
  --shadow: none;
}

* {
  box-sizing: border-box;
}

.startup-loader {
  position: fixed;
  z-index: 3000;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 24px;
  background: #fffdf5;
  opacity: 1;
  transition: opacity 180ms ease;
}

.startup-loader.is-complete {
  opacity: 0;
  pointer-events: none;
}

.startup-loader-card {
  width: min(340px, 100%);
  padding: 0;
  text-align: center;
}

.startup-coat-of-arms {
  display: block;
  width: 70px;
  height: 70px;
  margin: 0 auto 18px;
}

.startup-loader-title {
  margin: 0;
  color: var(--ink);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 32px;
  font-weight: 700;
}

.startup-loader-status {
  min-height: 22px;
  margin: 7px 0 18px;
  color: var(--muted);
  font-size: 14px;
}

.startup-progress {
  width: 100%;
  height: 9px;
  overflow: hidden;
  border: 1px solid #c9c2b1;
  border-radius: 4px;
  background: #ebe6d9;
}

.startup-progress-fill {
  display: block;
  width: 6%;
  height: 100%;
  background: #c8102e;
  transition: width 180ms ease;
}

/* Local fallback for the critical Leaflet layout rules. If the CDN CSS is blocked,
   map tiles otherwise behave like regular page images and scatter across the UI. */
.leaflet-container {
  position: relative;
  overflow: hidden;
  outline-offset: 1px;
  background: #ddd;
  font: 12px/1.5 "Helvetica Neue", Arial, Helvetica, sans-serif;
  touch-action: none;
}

.leaflet-pane,
.leaflet-tile,
.leaflet-marker-icon,
.leaflet-marker-shadow,
.leaflet-tile-container,
.leaflet-pane > svg,
.leaflet-pane > canvas,
.leaflet-zoom-box,
.leaflet-image-layer,
.leaflet-layer {
  position: absolute;
  left: 0;
  top: 0;
}

.leaflet-map-pane {
  z-index: auto;
}

.leaflet-tile-pane {
  z-index: 200;
}

.leaflet-overlay-pane {
  z-index: 400;
}

.leaflet-shadow-pane {
  z-index: 500;
}

.leaflet-marker-pane {
  z-index: 600;
}

.leaflet-tooltip-pane {
  z-index: 650;
}

.leaflet-popup-pane {
  z-index: 700;
}

.leaflet-highlight-pane {
  z-index: 680;
}

.selected-street-line {
  filter: none;
}

.battle-site-marker {
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  border: 2px solid #fffdf7;
  border-radius: 50%;
  background: #c65b44;
  box-shadow: none;
  font-style: normal !important;
}

.battle-site-glyph {
  display: block;
  width: 13px;
  height: 13px;
  color: #fffdf7;
  stroke-width: 2.4;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  font-style: normal !important;
}

.battle-site-marker.active {
  width: 26px;
  height: 26px;
  background: #df9a35;
  box-shadow: none;
}

.building-site-marker {
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border: 2px solid #fffdf7;
  border-radius: 5px;
  background: #4b7890;
  box-shadow: none;
  transition: background-color 120ms ease, border-color 120ms ease;
  font-style: normal !important;
}

.building-site-marker--cemetery {
  background: #6e556e;
}

.building-site-marker--park {
  background: #5f8f4e;
}

.building-site-marker--palace {
  background: #9c6a3d;
}

.building-site-marker--school {
  background: #4b7890;
}

.building-site-marker--church {
  background: #78618e;
}

.building-site-marker--synagogue {
  background: #547b67;
}

.building-site-marker--mosque {
  background: #2f7d7b;
}

.building-site-marker--culture {
  background: #9a5d73;
}

.building-site-marker--hospital {
  background: #b65252;
}

.building-site-marker--hotel {
  background: #a87845;
}

.building-site-marker--sport {
  background: #497ca2;
}

.building-site-marker--transport {
  background: #556b80;
}

.building-site-marker--housing {
  background: #8a7253;
}

.building-site-marker--water {
  background: #3c879a;
}

.building-site-marker--tower {
  background: #59697d;
}

.building-site-marker--skyscraper {
  background: #415d78;
}

.building-site-marker--monument {
  background: #8a6b3d;
}

.building-site-marker--former {
  background: #827664;
}

.building-site-marker:hover,
.building-site-marker:focus {
  background: #c65b44;
}

.building-site-marker.active {
  width: 30px;
  height: 30px;
  background: #c65b44;
  box-shadow: none;
}

.building-marker-glyph {
  display: grid;
  place-items: center;
  width: 15px;
  height: 15px;
  color: #fffdf7;
  stroke-width: 2.35;
  fill: none;
  line-height: 1;
  font-style: normal;
  font-family: Arial, sans-serif;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.building-marker-glyph--synagogue {
  stroke: currentColor;
  stroke-linejoin: round;
}

.manual-street-highlight {
  position: absolute !important;
  inset: 0;
  z-index: 660 !important;
  display: block;
  width: 100%;
  height: 100%;
  pointer-events: none;
  overflow: visible;
}

.leaflet-tile,
.leaflet-marker-icon,
.leaflet-marker-shadow {
  user-select: none;
  -webkit-user-drag: none;
}

.leaflet-tile {
  max-width: none !important;
  max-height: none !important;
}

.leaflet-container img {
  max-width: none !important;
}

.leaflet-container.leaflet-touch-zoom {
  touch-action: pan-x pan-y;
}

.leaflet-control {
  position: relative;
  z-index: 800;
  pointer-events: auto;
}

.leaflet-top,
.leaflet-bottom {
  position: absolute;
  z-index: 1000;
  pointer-events: none;
}

.leaflet-top {
  top: 0;
}

.leaflet-right {
  right: 0;
}

.leaflet-bottom {
  bottom: 0;
}

.leaflet-left {
  left: 0;
}

.leaflet-control {
  float: left;
  clear: both;
}

.leaflet-right .leaflet-control {
  float: right;
}

.leaflet-top .leaflet-control {
  margin-top: 10px;
}

.leaflet-bottom .leaflet-control {
  margin-bottom: 10px;
}

.leaflet-left .leaflet-control {
  margin-left: 10px;
}

.leaflet-right .leaflet-control {
  margin-right: 10px;
}

.leaflet-control-zoom a {
  display: block;
  width: 34px;
  height: 34px;
  border-bottom: 1px solid var(--line);
  background: #fffdf5;
  color: var(--teal);
  font: bold 20px/34px Arial, Helvetica, sans-serif;
  text-align: center;
  text-decoration: none;
}

.leaflet-control-zoom a:hover {
  background: var(--mint);
}

.leaflet-control-attribution {
  padding: 1px 3px;
  background: rgba(255, 255, 255, 0.58);
  color: #596155;
  font-size: 9px;
  opacity: 0.72;
}

.leaflet-popup {
  position: absolute;
  margin-bottom: 20px;
  text-align: center;
}

.leaflet-popup-content-wrapper {
  padding: 1px;
  border-radius: 8px;
  background: #fff;
  box-shadow: none;
  text-align: left;
}

.leaflet-popup-content {
  margin: 13px 18px;
  line-height: 1.35;
}

.leaflet-popup-tip-container {
  position: absolute;
  left: 50%;
  width: 40px;
  height: 20px;
  margin-left: -20px;
  overflow: hidden;
  pointer-events: none;
}

.leaflet-popup-tip {
  width: 17px;
  height: 17px;
  margin: -10px auto 0;
  transform: rotate(45deg);
  background: #fff;
  box-shadow: none;
}

.leaflet-interactive {
  cursor: pointer;
}

.leaflet-zoom-animated {
  transform-origin: 0 0;
}

.leaflet-zoom-anim .leaflet-zoom-animated {
  transition: transform 0.16s cubic-bezier(0, 0, 0.25, 1);
}

.leaflet-fade-anim .leaflet-tile {
  transition: opacity 0.2s linear;
}

.leaflet-zoom-anim .leaflet-tile,
.leaflet-pan-anim .leaflet-tile {
  transition: none;
}

body {
  margin: 0;
  width: 100%;
  height: 100vh;
  height: 100dvh;
  overflow: hidden;
  color: var(--ink);
  background: var(--paper);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

button,
input,
select {
  font: inherit;
}

body.sidebar-resize-active {
  cursor: col-resize;
  user-select: none;
}

.app-shell {
  --sidebar-width: 430px;
  --mobile-sidebar-height: 70dvh;
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 12px var(--sidebar-width);
  width: 100%;
  height: 100vh;
  height: 100dvh;
  overflow: hidden;
}

.map-stage {
  position: relative;
  min-width: 0;
  min-height: 0;
  isolation: isolate;
  z-index: 1;
}

.sidebar-resizer {
  position: relative;
  z-index: 4;
  width: 12px;
  min-width: 12px;
  cursor: col-resize;
  touch-action: none;
  outline: none;
}

.sidebar-resizer::after {
  content: "";
  position: absolute;
  z-index: 1;
  top: 0;
  bottom: 0;
  left: 5px;
  width: 2px;
  background: rgba(95, 143, 78, 0.24);
  transition: background-color 120ms ease, width 120ms ease, left 120ms ease;
}

.sidebar-resizer:hover::after,
.sidebar-resizer:focus-visible::after,
.sidebar-resizer.is-resizing::after {
  left: 3px;
  width: 6px;
  background: #5f8f4e;
}

#map {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  isolation: isolate;
  background: #ded8c8;
}

.side-panel {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
  height: 100%;
  border-left: 1px solid rgba(95, 143, 78, 0.24);
  background: #fffdf5;
  box-shadow: none;
}

.panel-section {
  padding: 16px 18px;
  border-bottom: 1px solid rgba(216, 209, 191, 0.9);
}

.panel-title {
  padding-top: 22px;
  padding-bottom: 16px;
  background: #fffdf5;
  position: relative;
}

.panel-title::after {
  content: "";
  position: absolute;
  right: 18px;
  bottom: 14px;
  width: 54px;
  height: 5px;
  border-radius: 999px;
  background: #df9a35;
}

.panel-title h2 {
  margin: 0;
  color: #25351f;
  font-size: 28px;
  line-height: 1;
  letter-spacing: 0;
}

.panel-title .eyebrow {
  margin-bottom: 6px;
  color: var(--teal);
}

.controls {
  display: grid;
  gap: 9px;
  background: #fffdf5;
}

label {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

select,
input {
  width: 100%;
  min-height: 42px;
  border: 1px solid #cfc5ad;
  border-radius: 5px;
  padding: 9px 12px;
  background: #fffdf8;
  color: var(--ink);
  outline: none;
  box-shadow: none;
}

.district-checklist {
  position: relative;
}

.district-checklist summary {
  display: flex;
  align-items: center;
  min-height: 48px;
  padding: 0 42px 0 15px;
  border: 1px solid #d7d1c5;
  border-radius: 5px;
  background: #fffdfa;
  color: #27323b;
  cursor: pointer;
  list-style: none;
}

.district-checklist summary::-webkit-details-marker {
  display: none;
}

.district-checklist summary::after {
  position: absolute;
  right: 16px;
  width: 9px;
  height: 9px;
  content: "";
  border-right: 2px solid #566258;
  border-bottom: 2px solid #566258;
  transform: rotate(45deg) translate(-2px, -2px);
}

.district-checklist[open] summary::after {
  transform: rotate(225deg) translate(-1px, -1px);
}

.district-checklist-options {
  display: grid;
  max-height: 248px;
  margin-top: 6px;
  padding: 7px;
  overflow-y: auto;
  border: 1px solid #d7d1c5;
  border-radius: 5px;
  background: #fffdfa;
}

.district-checklist-option {
  display: flex;
  align-items: center;
  gap: 9px;
  min-height: 34px;
  padding: 0 8px;
  color: #344033;
  cursor: pointer;
}

.district-checklist-option:hover {
  background: #eef4e7;
}

.district-checklist-option input {
  width: 16px;
  height: 16px;
  margin: 0;
  accent-color: #628b46;
}

.marker-cluster {
  background: rgba(105, 143, 70, 0.22);
  border-radius: 50%;
}

.marker-cluster div {
  display: grid;
  width: 32px;
  height: 32px;
  margin: 4px;
  place-items: center;
  border: 2px solid #fffdf8;
  border-radius: 50%;
  background: #628b46;
  color: #fff;
  font: 700 12px/1 system-ui, sans-serif;
  box-shadow: none;
}

select:focus,
input:focus {
  border-color: var(--teal);
  outline: 2px solid var(--teal);
  outline-offset: 1px;
}

.segmented {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 4px;
  padding: 4px;
  border: 1px solid #cfc5ad;
  border-radius: 5px;
  background: #e6dfcf;
}

.segmented button {
  min-height: 36px;
  border: 0;
  border-radius: 4px;
  background: transparent;
  color: #3f4c59;
  cursor: pointer;
}

.segmented button.active {
  background: #fffdf8;
  color: #496f3d;
  box-shadow: none;
}

.selection {
  flex: 0 1 auto;
  min-height: 0;
  max-height: min(48vh, 560px);
  overflow-x: hidden;
  overflow-y: auto;
  padding-bottom: 24px;
  scroll-padding-bottom: 24px;
  background: #fffdf5;
}

.selection.has-selection {
  flex: 1 1 auto;
  min-height: 0;
  max-height: none;
}

.selection.is-empty {
  display: none;
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--red);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.selection h2 {
  margin: 0 0 10px;
  color: #25351f;
  font-size: 25px;
  line-height: 1.1;
  letter-spacing: 0;
}

.selection p {
  margin: 0 0 12px;
  color: #4d5a66;
  line-height: 1.45;
}

.selection.has-selection ~ .list-head,
.selection.has-selection ~ .result-list {
  display: none;
}

.detail-header {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 8px;
  align-items: start;
  margin-bottom: 10px;
}

.detail-back {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  padding: 0;
  border: 1px solid #cfc5ad;
  border-radius: 4px;
  background: #fffdf8;
  color: #496f3d;
  font-size: 24px;
  font-weight: 800;
  line-height: 1;
  cursor: pointer;
  transition: border-color 0.16s ease, background-color 0.16s ease;
}

.detail-back:hover {
  border-color: var(--teal);
  background: #eef4e7;
}

.detail-back:focus-visible {
  outline: 2px solid var(--teal);
  outline-offset: 2px;
}

.detail-description {
  max-height: none;
  overflow: visible;
  color: #4d5a66;
  line-height: 1.45;
  padding-right: 4px;
}

.detail-description a {
  color: var(--blue);
  font-weight: 700;
  text-decoration: none;
}

.detail-description a:hover {
  text-decoration: underline;
}

.article-loading {
  color: var(--muted);
  font-size: 0.9rem;
  margin: 0.8rem 0 0;
}

.people-section {
  margin-top: 14px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 253, 248, 0.78);
}

.people-section h3 {
  margin: 0 0 8px;
  color: #25351f;
  font-size: 15px;
  letter-spacing: 0;
}

.people-section p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.street-places-section {
  margin-top: 14px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 253, 248, 0.78);
}

.street-places-section h3 {
  margin: 0 0 8px;
  color: #25351f;
  font-size: 15px;
}

.street-places-section > p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.street-places-list {
  display: grid;
  gap: 7px;
  max-height: 220px;
  overflow: auto;
}

.street-place-row {
  display: grid;
  width: 100%;
  gap: 2px;
  padding: 8px;
  border: 1px solid #d8d1bf;
  border-radius: 8px;
  background: #fffdf8;
  color: inherit;
  text-align: left;
  cursor: pointer;
}

.street-place-row:hover,
.street-place-row:focus-visible {
  background: #eef4e7;
}

.street-place-row:focus-visible {
  outline: 2px solid var(--teal);
  outline-offset: -2px;
}

.street-place-row span {
  color: var(--muted);
  font-size: 12px;
}

.street-place-row strong {
  color: #25351f;
  font-size: 13px;
}

.people-list {
  display: grid;
  gap: 7px;
  max-height: 220px;
  overflow: auto;
}

.people-list a {
  display: grid;
  gap: 2px;
  padding: 8px;
  border: 1px solid #d8d1bf;
  border-radius: 8px;
  background: #fffdf8;
  color: inherit;
  text-decoration: none;
}

.people-list strong {
  color: #25351f;
  font-size: 13px;
}

.people-list span {
  color: var(--muted);
  font-size: 12px;
}

.detail-topline {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 0;
}

.detail-topline span {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 3px 8px;
  border-radius: 999px;
  background: rgba(95, 143, 78, 0.14);
  color: #496f3d;
  font-size: 12px;
  font-weight: 800;
}

.detail-actions {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 8px;
  margin-top: 14px;
}

.detail-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  border: 1px solid #cfc5ad;
  border-radius: 4px;
  background: #fffdf8;
  color: #496f3d;
  font-weight: 800;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.16s ease, border-color 0.16s ease;
}

.detail-button:hover {
  border-color: var(--teal);
  background: #eef4e7;
}

.detail-button.primary {
  border-color: var(--teal);
  background: var(--teal);
  color: #fff;
  box-shadow: none;
}

.metadata {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 12px;
}

.tag {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 4px 8px;
  border: 1px solid rgba(0, 139, 128, 0.26);
  border-radius: 999px;
  background: var(--mint);
  color: #00685f;
  font-size: 12px;
  font-weight: 700;
}

.battle-section {
  display: grid;
  grid-template-columns: max-content 1fr;
  gap: 7px 10px;
  margin-top: 14px;
  padding: 12px;
  border: 1px solid #d8d1bf;
  border-radius: 8px;
  background: rgba(247, 230, 220, 0.48);
  color: #33422e;
}

.battle-section span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.battle-section strong {
  color: #25351f;
  font-size: 13px;
}

.street-length {
  margin-bottom: 14px;
  background: #f8f6ef;
}

.media-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin: 0 0 14px;
  clear: both;
}

.media-strip[hidden] {
  display: none;
}

.media-thumb {
  position: relative;
  width: 100%;
  height: 76px;
  min-width: 0;
  padding: 0;
  border: 1px solid #cfc5ad;
  border-radius: 4px;
  background: #e6dfcf;
  cursor: zoom-in;
  display: block;
  overflow: hidden;
}

.media-thumb-placeholder {
  cursor: default;
  position: relative;
  background: #e6dfcf;
}

.media-thumb-placeholder::after {
  content: "";
  position: absolute;
  inset: 16px 20px;
  border-radius: 5px;
  border: 2px solid rgba(95, 143, 78, 0.18);
}

.media-thumb-preview {
  display: block;
  width: 100%;
  height: 100%;
  background-color: #e6dfcf;
  background-position: center;
  background-size: cover;
  object-fit: cover;
}

.media-thumb:focus-visible {
  outline: 2px solid var(--teal);
  outline-offset: 2px;
}

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 3000;
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  place-items: center;
  gap: 12px;
  padding: 28px;
  background: rgba(12, 18, 24, 0.82);
}

.lightbox[hidden] {
  display: none;
}

.lightbox > #lightboxImage {
  display: block;
  width: clamp(320px, 72vw, 1100px) !important;
  height: clamp(280px, 78vh, 800px) !important;
  max-width: calc(100vw - 56px) !important;
  max-height: calc(100vh - 112px) !important;
  object-fit: contain !important;
  object-position: center;
  border-radius: 8px;
  box-shadow: none;
}

.lightbox p {
  max-width: min(92vw, 900px);
  margin: 0;
  color: #fff;
  font-size: 14px;
  text-align: center;
}

.lightbox-close {
  position: absolute;
  top: 18px;
  right: 18px;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(255, 255, 255, 0.32);
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  font-size: 30px;
  line-height: 1;
  cursor: pointer;
}

.lightbox-nav {
  position: absolute;
  top: 50%;
  width: 52px;
  height: 64px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  font-size: 54px;
  line-height: 0.8;
  cursor: pointer;
  transform: translateY(-50%);
}

.lightbox-prev {
  left: 22px;
}

.lightbox-next {
  right: 22px;
}

.lightbox-nav:hover,
.lightbox-close:hover {
  background: rgba(255, 255, 255, 0.24);
}

.list-head {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding-top: 12px;
  padding-bottom: 12px;
  background: #eef4e7;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.result-list {
  flex: 1;
  min-height: 0;
  overflow: auto;
  padding: 0 12px;
  background: #f5f1e7;
}

.result-item {
  width: 100%;
  display: block;
  margin: 0;
  border: 0;
  border-bottom: 1px solid #d8d1bf;
  border-radius: 0;
  padding: 10px 11px;
  background: #fffdf8;
  color: inherit;
  text-align: left;
  cursor: pointer;
  transition: border-color 0.16s ease, background-color 0.16s ease;
}

.result-item.with-thumb {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  min-height: 78px;
  padding: 8px 10px 8px 8px;
}

.result-item.with-thumb:has(.item-thumb:not(.has-image)) {
  grid-template-columns: minmax(0, 1fr);
  padding-left: 10px;
}

.result-item.with-thumb:has(.item-thumb:not(.has-image)) .item-thumb {
  display: none;
}

.item-thumb {
  display: grid;
  place-items: center;
  width: 76px;
  height: 60px;
  overflow: hidden;
  border: 1px solid #d8d1bf;
  border-radius: 7px;
  background: #e6dfcf;
  contain: paint;
  isolation: isolate;
  transform: translateZ(0);
  backface-visibility: hidden;
}

.item-thumb > span {
  width: 18px;
  height: 18px;
  border: 2px solid rgba(95, 143, 78, 0.5);
  border-top-color: rgba(198, 91, 68, 0.72);
  border-radius: 50%;
}

.item-thumb.no-image > span {
  position: relative;
  width: 30px;
  height: 24px;
  border: 2px solid rgba(95, 143, 78, 0.66);
  border-top: 7px solid rgba(198, 91, 68, 0.7);
  border-radius: 3px 3px 4px 4px;
}

.item-thumb.no-image > span::before,
.item-thumb.no-image > span::after {
  content: "";
  position: absolute;
  bottom: 4px;
  width: 5px;
  height: 7px;
  background: rgba(95, 143, 78, 0.45);
}

.item-thumb.no-image > span::before {
  left: 6px;
}

.item-thumb.no-image > span::after {
  right: 6px;
}

.item-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  background-color: #e6dfcf;
  opacity: 1;
  transition: none;
  transform: translateZ(0);
  backface-visibility: hidden;
}

.item-copy {
  display: block;
  min-width: 0;
}

.result-item:hover {
  border-bottom-color: #a8c493;
  background: #f4f8ef;
}

.result-item:focus-visible {
  position: relative;
  z-index: 1;
  outline: 2px solid var(--teal);
  outline-offset: -2px;
}

.result-item.active {
  border-top: 2px solid var(--teal);
  border-bottom-color: var(--teal);
  background: #edf4e5;
}

.result-item strong {
  display: block;
  margin-bottom: 4px;
  font-size: 15px;
  line-height: 1.18;
}

.item-meta {
  display: block;
  margin-bottom: 4px;
  color: var(--teal);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.result-item .item-description {
  display: -webkit-box;
  overflow: hidden;
  color: #5d6874;
  font-size: 13px;
  line-height: 1.35;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.leaflet-popup-content {
  min-width: 180px;
}

.popup-title {
  display: block;
  margin-bottom: 4px;
  color: var(--ink);
  font-weight: 800;
}

.popup-kind {
  color: var(--muted);
  font-size: 12px;
}

@media (max-width: 720px) {
  .app-shell {
    grid-template-columns: 1fr;
    grid-template-rows: minmax(160px, calc(100dvh - var(--mobile-sidebar-height))) var(--mobile-sidebar-height);
  }

  .sidebar-resizer {
    position: absolute;
    z-index: 12;
    top: calc(100dvh - var(--mobile-sidebar-height) - 12px);
    right: 0;
    left: 0;
    display: block;
    width: auto;
    min-width: 0;
    height: 24px;
    cursor: row-resize;
  }

  .sidebar-resizer::after {
    top: 10px;
    bottom: auto;
    left: calc(50% - 28px);
    width: 56px;
    height: 4px;
    background: #5f8f4e;
  }

  .sidebar-resizer:hover::after,
  .sidebar-resizer:focus-visible::after,
  .sidebar-resizer.is-resizing::after {
    top: 8px;
    left: calc(50% - 34px);
    width: 68px;
    height: 8px;
  }

  body.sidebar-resize-active {
    cursor: row-resize;
  }

  .side-panel {
    height: 100%;
    border-left: 0;
    border-top: 1px solid var(--line);
  }

  .panel-section {
    padding: 14px;
  }

  .panel-title {
    padding-top: 14px;
    padding-bottom: 12px;
  }

  .panel-title h2 {
    font-size: 24px;
  }

  .controls {
    gap: 7px;
  }

  select,
  input {
    min-height: 38px;
  }

  .segmented button {
    min-height: 32px;
  }

  .selection {
    min-height: auto;
  }

  .selection.has-selection {
    flex: 1 1 auto;
    min-height: 0;
    max-height: none;
  }

  .selection.is-empty {
    display: none;
  }

  .result-list {
    min-height: 110px;
  }

  .selection h2 {
    margin-bottom: 6px;
    font-size: 20px;
  }

  .selection p {
    margin-bottom: 8px;
  }

}

@media (max-width: 620px) {
  .selection h2 {
    font-size: 21px;
  }
}
