:root {
  --cream: #fffaf0;
  --paper: #fffdf8;
  --ink: #193c35;
  --ink-soft: #45665d;
  --green: #24755c;
  --green-dark: #1b5c48;
  --orange: #f3a849;
  --sky: #cdebf3;
  --sage: #e9f0e4;
  --peach: #f5d7be;
  --line: #d9e4d9;
  --muted: #496159;
  --danger: #9b3f2f;
  --ended: #b42332;
  --shadow: 0 16px 44px rgba(25, 60, 53, .16);
  --dock-reserve: calc(140px + env(safe-area-inset-bottom, 0px));
  --surface-blur: blur(10px);
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html,
body { width: 100%; min-width: 0; height: 100%; margin: 0; overflow: hidden; background: var(--cream); }
body {
  color: var(--ink);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Noto Sans KR", sans-serif;
  line-height: 1.5;
}
img { display: block; max-width: 100%; }
button, input, select { font: inherit; }
button, select, input[type="date"], input[type="search"] { min-height: 44px; }
button, select, input { color: var(--ink); }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; opacity: .55; }
:focus-visible { outline: 3px solid var(--paper); outline-offset: 2px; box-shadow: 0 0 0 6px var(--ink); }
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

#mapWorkspace { position: relative; width: 100%; height: 100dvh; min-height: 100%; overflow: hidden; isolation: isolate; }
.map-panel { position: absolute; inset: 0; z-index: 0; overflow: hidden; background: var(--sky); }
#map { position: absolute; inset: 0; width: 100%; height: 100%; min-height: 0; background: var(--sky); }

.brand-tile {
  --map-edge: top;
  position: absolute;
  top: max(16px, env(safe-area-inset-top, 0px));
  left: 16px;
  z-index: 780;
  width: min(286px, calc(100vw - 32px));
  padding: 8px 12px;
  border: 1px solid rgba(36, 117, 92, .2);
  border-radius: 15px;
  background: rgba(255, 253, 248, .96);
  box-shadow: var(--shadow);
  backdrop-filter: var(--surface-blur);
  -webkit-backdrop-filter: var(--surface-blur);
  pointer-events: auto;
}
.brand-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 36px; }
.brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
  min-height: 44px;
  color: var(--ink);
  font-size: 1.1rem;
  font-weight: 800;
  text-decoration: none;
  white-space: nowrap;
}
.brand img { width: 36px; height: 36px; border-radius: 11px; }
.brand small { color: var(--green-dark); font-size: .7rem; font-weight: 700; letter-spacing: .08em; margin-left: 4px; }
.kids-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 8px;
  border-radius: 999px;
  border: 1px solid var(--orange);
  background: #fff6e8;
  color: #8c4e09;
  font-size: .68rem;
  font-weight: 800;
  letter-spacing: -.01em;
  white-space: nowrap;
}
.brand-note { margin: 3px 0 0; color: var(--ink-soft); font-size: .78rem; font-weight: 600; }
.hero-stat {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 30px;
  padding: 4px 9px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  color: var(--ink-soft);
  font-size: .72rem;
  line-height: 1.2;
  white-space: nowrap;
}
.hero-stat strong { color: var(--green-dark); font-size: .9rem; }
.freshness { margin: 7px 0 0; color: var(--muted); font-size: .72rem; overflow-wrap: anywhere; }
.primary-nav { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin-top: 10px; }
.primary-tab { min-width: 0; min-height: 44px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 12px; background: var(--sage); color: var(--ink-soft); font-size: .8rem; font-weight: 800; transition: background-color .18s ease, border-color .18s ease, color .18s ease; }
.primary-tab:hover { border-color: var(--green); color: var(--green-dark); }
.primary-tab[aria-pressed="true"] { border-color: var(--green); background: var(--green); color: #fff; }
.primary-tab:focus-visible { outline: 3px solid var(--paper); outline-offset: 2px; box-shadow: 0 0 0 5px var(--ink); }

.search-dock {
  --map-edge: bottom;
  position: absolute;
  bottom: calc(16px + env(safe-area-inset-bottom, 0px));
  left: 50%;
  z-index: 750;
  display: flex;
  flex-direction: column-reverse;
  gap: 8px;
  width: min(560px, calc(100vw - 32px));
  max-height: max(180px, calc(100dvh - 340px));
  min-height: 0;
  transform: translateX(-50%);
  pointer-events: auto;
}
.search-row { margin: 0; }
.search-label { display: block; min-width: 0; }
.search-label input {
  display: block;
  width: 100%;
  min-width: 0;
  min-height: 56px;
  padding: 12px 18px;
  border: 2px solid var(--green);
  border-radius: 16px;
  background: rgba(255, 253, 248, .98);
  box-shadow: 0 12px 32px rgba(25, 60, 53, .16);
  backdrop-filter: var(--surface-blur);
  -webkit-backdrop-filter: var(--surface-blur);
  color: var(--ink);
  font-size: 1.02rem;
}
.search-label input::placeholder { color: var(--muted); }
.filter-menu {
  --map-edge: bottom;
  min-height: 0;
  max-height: min(calc(68dvh + 46px), 666px, calc(100dvh - 92px));
  overflow: hidden;
  border: 1px solid rgba(36, 117, 92, .18);
  border-radius: 14px;
  background: rgba(255, 253, 248, .97);
  box-shadow: var(--shadow);
  backdrop-filter: var(--surface-blur);
  -webkit-backdrop-filter: var(--surface-blur);
}
.filter-menu > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 44px;
  padding: 8px 13px;
  border-radius: 13px;
  color: var(--ink);
  cursor: pointer;
  font-size: .86rem;
  font-weight: 800;
  list-style: none;
}
.filter-menu > summary:focus-visible {
  outline: 3px solid var(--ink);
  outline-offset: -3px;
  box-shadow: inset 0 0 0 1px var(--paper);
}
.filter-menu > summary::-webkit-details-marker { display: none; }
.filter-menu > summary::after { content: "＋"; color: var(--green-dark); font-size: 1.1rem; line-height: 1; }
.filter-menu[open] > summary { border-bottom: 1px solid var(--line); border-radius: 13px 13px 0 0; }
.filter-menu[open] > summary::after { content: "－"; }
.filter-toggle-hint { color: var(--muted); font-size: .72rem; font-weight: 650; }
.filter-label-close { display: none; }
.filter-menu[open] .filter-label-open { display: none; }
.filter-menu[open] .filter-label-close { display: inline; }
.filter-drawer { max-height: min(68dvh, 620px, calc(100dvh - 138px)); overflow: auto; padding: 12px 13px 14px; overscroll-behavior: contain; }
.filter-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }
.filter-grid label { display: grid; gap: 5px; min-width: 0; color: var(--ink-soft); font-size: .76rem; font-weight: 750; }
.filter-grid input, .filter-grid select {
  width: 100%;
  min-width: 0;
  min-height: 44px;
  padding: 7px 9px;
  border: 1px solid #bad0c3;
  border-radius: 10px;
  background: #fff;
}
.filter-options { display: flex; flex-wrap: wrap; align-items: center; gap: 7px; margin-top: 11px; }
.check-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 44px;
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #f6fbf4;
  color: var(--ink);
  font-size: .78rem;
  font-weight: 750;
  cursor: pointer;
}
.check-pill:has(input:checked) { border-color: var(--green); background: var(--green); color: #fff; }
.check-pill input { width: 18px; height: 18px; accent-color: var(--green); }
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 8px 13px;
  border: 1px solid transparent;
  border-radius: 11px;
  font-weight: 800;
  text-decoration: none;
  transition: background-color .18s ease, border-color .18s ease, transform .18s ease;
}
.button:hover { transform: translateY(-1px); }
.button-primary { background: var(--green); color: #fff; }
.button-primary:hover { background: var(--green-dark); }
.button-quiet { border-color: var(--line); background: rgba(255, 253, 248, .96); color: var(--ink-soft); }
.button-quiet:hover { border-color: var(--green); color: var(--green-dark); }
.icon-btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; min-width: 44px; min-height: 44px; }
.control-icon { flex: 0 0 auto; display: block; width: 20px; height: 20px; object-fit: contain; }
.control-icon path, .control-icon circle { fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.control-label { white-space: nowrap; }

.quick-regions { padding: 16px 0 2px; }
.quick-experiences { padding: 16px 0 0; }
.section-kicker, .panel-heading { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.section-kicker h2, .panel-heading h2, .results-head h2 { margin: 0; font-size: .98rem; letter-spacing: -.02em; }
.section-kicker span, .panel-heading span { color: var(--muted); font-size: .72rem; }
.region-quick { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 9px; }
.region-chip {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-height: 44px;
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--paper);
  color: var(--ink);
  font-size: .76rem;
  font-weight: 750;
}
.region-chip strong { color: var(--green-dark); }
.region-chip[aria-pressed="true"] { border-color: var(--green); background: var(--green); color: #fff; }
.region-chip[aria-pressed="true"] strong { color: #fff; }
#activityQuick { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
#activityQuick > div { min-width: 0; }
.activity-chip { width: 100%; min-height: 76px; justify-content: flex-start; gap: 10px; padding: 9px; background: var(--sage); text-align: left; }
.activity-chip[data-activity="만들기·예술"] { background: var(--peach); }
.activity-chip[aria-pressed="true"] { background: var(--green); color: #fff; }
.activity-art { flex: 0 0 48px; width: 48px; height: 48px; border-radius: 10px; object-fit: cover; }
.activity-copy { display: grid; gap: 2px; min-width: 0; font-size: .86rem; }
.activity-copy strong { color: var(--ink-soft); font-size: .75rem; font-weight: 500; }
.activity-chip[aria-pressed="true"] .activity-copy strong { color: #edf9ef; }
.subfacets { padding: 12px 0 2px; }
.subfacets-body { display: grid; gap: 8px; margin-top: 9px; }
.subfacet-group { display: flex; flex-wrap: wrap; align-items: center; gap: 7px; padding: 10px; border: 1px solid var(--line); border-radius: 11px; background: var(--paper); }
.subfacet-label { min-width: 78px; color: var(--muted); font-size: .72rem; font-weight: 750; }
.subfacet-chip { min-height: 44px; font-size: .72rem; }
.source-notes { display: grid; gap: 4px; margin-top: 12px; padding-top: 10px; border-top: 1px solid var(--line); }
.date-hint, .data-note, .source-freshness { margin: 0; color: var(--muted); font-size: .72rem; overflow-wrap: anywhere; }
.region-chip { transition: background-color .18s ease, border-color .18s ease, transform .18s ease; }
.region-chip:hover { transform: translateY(-1px); border-color: var(--green); }
.check-pill { transition: background-color .18s ease, border-color .18s ease; }

.map-tools { --map-edge: left; position: absolute; top: calc(var(--brand-bottom, 128px) + 8px); left: 72px; z-index: 550; display: block; max-width: min(264px, calc(100vw - 32px)); pointer-events: auto; }
.map-tools .button { box-shadow: 0 8px 20px rgba(25, 60, 53, .12); }
.map-tools:has(.tools-menu[open]) { z-index: 850; }
.tools-menu { position: relative; min-width: 0; }
.tools-menu > summary { display: inline-flex; align-items: center; justify-content: center; gap: 7px; min-width: 44px; min-height: 44px; padding: 8px 11px; border: 1px solid rgba(36, 117, 92, .2); border-radius: 12px; background: rgba(255, 253, 248, .95); box-shadow: 0 8px 20px rgba(25, 60, 53, .12); color: var(--ink-soft); cursor: pointer; font-size: .78rem; font-weight: 800; list-style: none; }
.tools-menu > summary::-webkit-details-marker { display: none; }
.tools-menu > summary:focus-visible { outline: 3px solid var(--paper); outline-offset: 2px; box-shadow: 0 0 0 5px var(--ink); }
.tools-menu[open] > summary { border-color: var(--green); border-radius: 12px 12px 8px 8px; color: var(--green-dark); }
.tools-glyph { display: inline-flex; align-items: center; justify-content: center; width: 20px; height: 20px; color: currentColor; font-size: 1rem; letter-spacing: .1em; line-height: 1; }
/* Reserve the 44px toggle, two 8px gaps, and the search dock. */
.tools-drawer { display: grid; gap: 8px; width: min(264px, calc(100vw - 32px)); max-height: max(64px, calc(100dvh - var(--brand-bottom, 128px) - var(--dock-reserve) - 60px)); overflow-y: auto; margin-top: 8px; padding: 10px; border: 1px solid rgba(36, 117, 92, .18); border-radius: 12px; background: rgba(255, 253, 248, .97); box-shadow: var(--shadow); backdrop-filter: var(--surface-blur); -webkit-backdrop-filter: var(--surface-blur); }
.tools-drawer .button { width: 100%; justify-content: flex-start; }
.tools-drawer .control-label { position: static; width: auto; height: auto; padding: 0; margin: 0; overflow: visible; clip: auto; white-space: normal; }
.map-hint { max-width: 240px; margin: 0; padding: 7px 9px; border: 1px solid rgba(36, 117, 92, .15); border-radius: 10px; background: rgba(255, 253, 248, .9); color: var(--muted); font-size: .7rem; line-height: 1.35; }
.map-fallback { --map-edge: bottom; position: absolute; left: 16px; bottom: var(--dock-reserve); z-index: 760; width: min(420px, calc(100vw - 32px)); margin: 0; padding: 12px 14px; border: 1px solid #e0a28d; border-radius: 12px; background: rgba(255, 253, 248, .96); backdrop-filter: var(--surface-blur); -webkit-backdrop-filter: var(--surface-blur); color: var(--danger); font-size: .82rem; }
.leaflet-control-zoom { --map-edge: left; margin-top: calc(var(--brand-bottom, 128px) + 8px) !important; margin-left: 16px !important; }
.leaflet-control-zoom a { width: 44px; min-width: 44px; height: 44px; min-height: 44px; line-height: 44px; }
.leaflet-container .leaflet-control-attribution { --map-edge: bottom; right: 8px; bottom: calc(var(--dock-reserve) + 8px); z-index: 800; max-width: calc(100vw - 32px); background: rgba(255, 253, 248, .96); color: var(--ink); }
.leaflet-container { color: var(--ink); font-family: inherit; }
/* Filter-open lifts the attribution into the fixed 283–300px band: below the
   map-tools buttons (bottom ≈280 once the hint below is hidden) and above the
   capped dock (top pins at 324px), so the OSM credit is never painted under
   the expanded panel. */
#mapWorkspace:has(#filterMenu[open]) .leaflet-container .leaflet-control-attribution { bottom: calc(100dvh - 300px); }
/* The locate hint is redundant while the filter panel is open; hiding it
   keeps the map-tools block (buttons only) clear of the dock and attribution. */
#mapWorkspace:has(#filterMenu[open]) .map-hint { display: none; }

.results {
  --map-edge: right;
  position: absolute;
  top: 16px;
  right: 16px;
  bottom: var(--dock-reserve);
  z-index: 700;
  display: flex;
  flex-direction: column;
  width: min(380px, calc(100vw - 32px));
  min-width: 0;
  min-height: 0;
  border: 1px solid rgba(36, 117, 92, .2);
  border-radius: 18px;
  background: rgba(255, 253, 248, .97);
  box-shadow: var(--shadow);
  backdrop-filter: var(--surface-blur);
  -webkit-backdrop-filter: var(--surface-blur);
  overflow: hidden;
  pointer-events: auto;
}
.results-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 14px; border-bottom: 1px solid var(--line); }
.results-summary { display: flex; flex-wrap: wrap; align-items: baseline; gap: 7px; min-width: 0; }
.results-head h2 { font-size: 1.1rem; }
.result-count { display: flex; align-items: baseline; gap: 4px; margin: 0; color: var(--green-dark); }
.result-count strong { font-size: 1.35rem; line-height: 1; }
.result-count span { color: var(--muted); font-size: .78rem; }
.results-head-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 6px; }
.results-head-actions .button { min-height: 44px; padding-inline: 10px; font-size: .78rem; }
.results-toggle { display: none; min-width: 44px; min-height: 44px; }
.results-body { flex: 1 1 auto; min-height: 0; overflow: auto; padding: 0 14px 16px; overscroll-behavior: contain; }
.sort-row { display: flex; flex-wrap: wrap; gap: 7px; margin: 12px 0 0; }
.sort-chip { min-height: 44px; padding: 7px 12px; border: 1px solid var(--line); border-radius: 999px; background: var(--paper); color: var(--ink-soft); font-size: .76rem; font-weight: 750; transition: background-color .18s ease, border-color .18s ease; }
.sort-chip[aria-pressed="true"] { border-color: var(--green); background: var(--green); color: #fff; }
.sort-chip:disabled { opacity: .45; cursor: not-allowed; }
.result-hint { min-height: 1.4em; margin: 10px 0; color: var(--muted); font-size: .78rem; }
.state-panel { margin: 12px 0; padding: 14px; border: 1px dashed #b7cbbd; border-radius: 13px; background: rgba(255, 255, 255, .7); color: var(--ink-soft); font-size: .84rem; }
.state-panel strong { display: block; color: var(--ink); font-size: .94rem; }
.state-panel p { margin: 5px 0 0; }
.error-panel { border-color: #e0a28d; color: var(--danger); }
.error-panel strong { color: var(--danger); }
.cards { display: grid; gap: 9px; list-style: none; margin: 0; padding: 0; }
.card { min-width: 0; padding: 14px; border: 1px solid var(--line); border-radius: 14px; background: #fff; animation: card-in .32s ease both; }
@keyframes card-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.card:hover { border-color: #a8c8b5; box-shadow: 0 7px 20px rgba(36, 117, 92, .08); }
.card-title { margin: 0; color: var(--ink); font-size: 1.02rem; line-height: 1.4; overflow-wrap: anywhere; }
.card-title button { width: 100%; padding: 0; border: 0; background: transparent; color: inherit; text-align: left; font: inherit; font-weight: 800; }
.card-meta { display: flex; flex-wrap: wrap; gap: 6px 9px; margin-top: 7px; color: var(--ink-soft); font-size: .78rem; }
.card-venue { color: var(--ink); font-weight: 700; }
.card-distance { color: var(--green-dark); font-weight: 750; }
.event-date.is-ended { text-decoration: line-through; text-decoration-color: var(--ended); text-decoration-thickness: 1.5px; color: var(--ended); }
.card-experience { margin: 9px 0 0; padding: 8px 9px; border-left: 3px solid var(--green); background: #eef8f1; color: var(--ink-soft); font-size: .78rem; }
.card-evidence { margin: 9px 0 0; padding: 8px 9px; border-left: 3px solid var(--orange); background: #fff7e6; color: #725124; font-size: .78rem; }
.badge { display: inline-flex; align-items: center; min-height: 24px; padding: 2px 8px; border-radius: 999px; background: #eaf3ee; color: var(--green-dark); font-size: .68rem; font-weight: 750; }
.badge.free { background: #fff0cf; color: #7b4d10; }
.badge.family { background: #fff3e0; color: #884307; border: 1px solid #ffd499; font-weight: 800; }
.badge.age-band { background: #ebf6f0; color: #14532d; border: 1px solid #cbe6d6; font-weight: 750; }
.badge.open { background: #dff3e7; color: #17603f; }
.badge.before { background: #e7f2f5; color: #356571; }
.badge.imminent { background: #ffe7d1; color: #8b4b1d; }
.badge.closed { background: #edf0ee; color: var(--ink-soft); }
.badge.ended, .badge-ended { background: var(--ended); color: #fff; }
.badge.discovered { background: #eaf0fa; color: #375687; }
.badge.experience { background: #dff3e7; color: #17603f; }
.badge.experience-category { background: #edf7ef; color: var(--green-dark); }
.card-actions { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 10px; }
.card-actions .button { min-height: 44px; padding: 6px 10px; font-size: .78rem; }
.link-status { display: inline-flex; align-items: center; max-width: 100%; min-height: 44px; padding: 6px 10px; border: 1px solid var(--line); border-radius: 11px; color: var(--muted); font-size: .76rem; white-space: normal; }
.link-status.verified { color: var(--green-dark); }
.pager { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 11px; }
.pager .button { min-width: 80px; }
.page-info { margin: 0; color: var(--muted); font-size: .76rem; text-align: center; }
.rec-open { padding: 0; border: 0; background: transparent; color: var(--green-dark); font: inherit; font-weight: 800; text-align: left; }
.rec-open:hover { text-decoration: underline; }
/* Shared itinerary, directions, and result card surfaces. */
.directions-actions, .timeline-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 12px; }
.directions-actions .button, .timeline-actions .button { min-height: 44px; }
.directions-actions > a { display: inline-flex; align-items: center; justify-content: center; max-width: 100%; min-height: 44px; padding: 8px 11px; border: 1px solid var(--line); border-radius: 11px; background: var(--paper); color: var(--green-dark); font-size: .78rem; font-weight: 800; line-height: 1.3; text-decoration: none; overflow-wrap: anywhere; }
.directions-actions > a:hover { border-color: var(--green); background: #eef8f1; }
.directions-actions > .directions-google { border-color: var(--green); background: var(--green); color: #fff; }
.directions-actions > .directions-google:hover { border-color: var(--green-dark); background: var(--green-dark); }
.directions-options { display: grid; flex: 1 1 100%; gap: 10px; min-width: 0; margin-top: 4px; padding: 12px; border: 1px solid var(--line); border-radius: 13px; background: #f2f8f2; }
.directions-options > *, .directions-option { min-width: 0; }
.directions-options summary { min-height: 44px; padding: 8px 10px; border-radius: 10px; color: var(--ink-soft); cursor: pointer; font-size: .78rem; font-weight: 800; }
.directions-options-list { display: flex; flex-wrap: wrap; gap: 8px; }
.directions-options-list > a { display: inline-flex; align-items: center; min-height: 44px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 10px; background: var(--paper); color: var(--green-dark); font-size: .76rem; font-weight: 750; line-height: 1.3; text-decoration: none; overflow-wrap: anywhere; }
.directions-options-list > a:hover { border-color: var(--green); background: #fff; }
.directions-option { display: flex; align-items: flex-start; gap: 9px; padding: 9px; border: 1px solid var(--line); border-radius: 11px; background: var(--paper); color: var(--ink-soft); }
.directions-option input { flex: 0 0 auto; width: 18px; height: 18px; margin-top: 3px; accent-color: var(--green); }
.directions-option strong { color: var(--ink); }
.directions-naver-app { display: none; }
@media (pointer: coarse) {
  .directions-naver-app { display: inline-flex; }
}
.directions-naver-app-hint { display: none; margin: 0; color: var(--muted); font-size: .7rem; }
@media (pointer: coarse) {
  .directions-naver-app-hint { display: block; }
}
.directions-options:not([open]) { padding: 0; border-color: transparent; background: transparent; }
.directions-options:not([open]) summary { border: 1px solid var(--line); background: var(--paper); }
.timeline-panel { --map-edge: right; position: absolute; top: max(112px, calc(env(safe-area-inset-top, 0px) + 96px)); right: max(16px, env(safe-area-inset-right, 0px)); bottom: calc(var(--dock-reserve) + 12px); z-index: 735; display: flex; flex-direction: column; width: min(720px, calc(100vw - 32px)); min-width: 0; min-height: 0; border: 1px solid rgba(36, 117, 92, .2); border-radius: 18px; background: rgba(255, 253, 248, .98); box-shadow: var(--shadow); backdrop-filter: var(--surface-blur); -webkit-backdrop-filter: var(--surface-blur); overflow: hidden; pointer-events: auto; }
.timeline-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; padding: 16px 18px; border-bottom: 1px solid var(--line); }
.timeline-heading { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px 12px; min-width: 0; }
.timeline-head h2 { margin: 0; font-size: 1.1rem; letter-spacing: -.02em; }
.timeline-count { display: inline-flex; align-items: baseline; gap: 4px; margin: 0; color: var(--green-dark); font-size: .78rem; }
.timeline-count strong { font-size: 1.15rem; line-height: 1; }
.timeline-close { flex: 0 0 auto; min-width: 44px; }
.timeline-body { flex: 1 1 auto; min-height: 0; overflow: auto; padding: 16px 16px calc(24px + env(safe-area-inset-bottom, 0px)); overscroll-behavior: contain; }
.timeline-intro { margin: 0; color: var(--ink-soft); font-size: .84rem; }
.timeline-filters { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto; align-items: end; gap: 12px; margin-top: 16px; }
.timeline-filters label { display: grid; gap: 4px; min-width: 0; color: var(--muted); font-size: .72rem; font-weight: 750; }
.timeline-filters input, .timeline-filters select { width: 100%; min-width: 0; min-height: 44px; padding: 7px 9px; border: 1px solid #bad0c3; border-radius: 10px; background: #fff; }
.timeline-filters button { min-width: 0; min-height: 44px; white-space: normal; }
.history-import { min-width: 0; margin-top: 16px; border: 1px solid var(--line); border-radius: 13px; background: #f6fbf4; }
.history-import > summary { position: relative; min-height: 44px; padding: 9px 34px 9px 11px; border-radius: 12px; color: var(--ink-soft); cursor: pointer; font-size: .8rem; font-weight: 800; list-style: none; overflow-wrap: anywhere; }
.history-import > summary::-webkit-details-marker { display: none; }
.history-import > summary::after { position: absolute; top: 9px; right: 11px; content: "＋"; color: var(--green-dark); font-size: 1rem; }
.history-import[open] > summary { border-bottom: 1px solid var(--line); border-radius: 12px 12px 0 0; }
.history-import[open] > summary::after { content: "－"; }
.history-import-body { display: grid; gap: 12px; min-width: 0; padding: 12px; }
.history-import-privacy, .history-import-hint, .history-import-status, .history-export-help { margin: 0; color: var(--muted); font-size: .74rem; overflow-wrap: anywhere; }
.history-import-privacy { color: var(--ink-soft); font-weight: 700; }
.history-file-label { display: grid; gap: 5px; min-width: 0; color: var(--ink-soft); font-size: .76rem; font-weight: 750; }
.history-file-label input { display: block; width: 100%; max-width: 100%; min-width: 0; min-height: 44px; padding: 8px 9px; border: 1px solid #bad0c3; border-radius: 10px; background: #fff; font-size: .78rem; overflow: hidden; }
.history-candidates { display: grid; gap: 8px; min-width: 0; }
.history-candidate { display: flex; align-items: flex-start; gap: 9px; min-width: 0; min-height: 44px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 10px; background: #fff; color: var(--ink-soft); font-size: .76rem; line-height: 1.35; overflow-wrap: anywhere; }
.history-candidate input { flex: 0 0 auto; width: 18px; height: 18px; margin: 4px 0 0; accent-color: var(--green); }
.history-candidate span, .history-candidate strong { min-width: 0; overflow-wrap: anywhere; }
.history-import-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.history-import-actions .button { min-width: 0; flex: 1 1 160px; }
.history-export-help { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.history-export-help a { color: var(--green-dark); font-weight: 750; overflow-wrap: anywhere; }
.timeline-visited { border-color: #bad0c3; font-weight: 800; }
.timeline-visited[aria-pressed="true"] { border-color: var(--green); background: #dff3e7; color: var(--green-dark); }
.timeline-notice { margin: 10px 0 0; padding: 9px 11px; border: 1px solid #b7cbbd; border-radius: 11px; background: #eef8f1; color: var(--green-dark); font-size: .78rem; }
.timeline-empty { margin: 16px 0 0; }
.timeline-list { display: grid; gap: 16px; margin: 16px 0 0; padding: 0; list-style: none; }
.timeline-day { grid-column: 1 / -1; min-width: 0; margin: 0 0 2px; padding: 0; border: 0; border-radius: 0; background: transparent; color: var(--green-dark); font-size: .94rem; line-height: 1.35; }
.timeline-item { display: grid; grid-template-columns: minmax(58px, auto) minmax(0, 1fr); gap: 10px 12px; min-width: 0; padding: 14px; border: 1px solid var(--line); border-radius: 14px; background: #fff; }
.timeline-time { grid-column: 1; align-self: start; margin: 2px 0 0; color: var(--green-dark); font-size: .8rem; font-weight: 800; line-height: 1.35; }
.timeline-event-title, .timeline-place, .timeline-fields, .timeline-item > .timeline-note, .timeline-leg, .timeline-actions { grid-column: 2; min-width: 0; }
.timeline-event-title { margin: 0; color: var(--ink); font-size: .92rem; line-height: 1.35; overflow-wrap: anywhere; }
.timeline-event-title .rec-open { font-weight: 800; overflow-wrap: anywhere; }
.timeline-place { margin: 0; color: var(--ink-soft); font-size: .78rem; overflow-wrap: anywhere; }
.timeline-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.timeline-fields label { display: grid; gap: 4px; min-width: 0; color: var(--muted); font-size: .72rem; font-weight: 750; }
.timeline-fields input { width: 100%; min-height: 44px; padding: 8px 9px; border: 1px solid var(--line); border-radius: 9px; background: var(--paper); }
.timeline-leg { margin: 0; padding: 8px 9px; border-left: 3px solid var(--green); border-radius: 0 8px 8px 0; background: #eef8f1; color: var(--ink-soft); font-size: .76rem; overflow-wrap: anywhere; }
.timeline-note { margin: 0; padding: 8px 9px; border-left: 3px solid var(--orange); background: #fff7e6; color: #725124; font-size: .76rem; overflow-wrap: anywhere; }
.timeline-leg .timeline-note { margin: 0; padding: 0; border: 0; background: transparent; color: inherit; }
.timeline-actions { margin: 0; }
#mapWorkspace:has(#timelinePanel:not([hidden])) #resultsPanel { display: none; }
mark { padding: 0 2px; border-radius: 4px; background: #ffe9b8; color: inherit; }
#loading { position: relative; overflow: hidden; }
#loading::after { content: ""; position: absolute; inset: 0; background: linear-gradient(100deg, transparent 30%, rgba(36,117,92,.12) 50%, transparent 70%); animation: shimmer 1.4s infinite; }
@keyframes shimmer { from { transform: translateX(-100%); } to { transform: translateX(100%); } }

dialog { width: min(560px, calc(100% - 28px)); max-height: min(720px, calc(100dvh - 28px)); overflow: auto; padding: 22px; border: 1px solid var(--line); border-radius: 20px; background: var(--paper); color: var(--ink); box-shadow: 0 24px 80px rgba(25, 60, 53, .22); animation: dialog-in .22s ease both; }
@keyframes dialog-in { from { opacity: 0; transform: translateY(10px) scale(.99); } to { opacity: 1; transform: none; } }
dialog::backdrop { background: rgba(25, 60, 53, .35); }
dialog h2 { margin: 0 34px 10px 0; line-height: 1.3; }
noscript { position: fixed; inset: 12px; z-index: 2000; display: block; pointer-events: auto; }
noscript .state-panel { max-width: 560px; max-height: calc(100dvh - 24px); margin: 0 auto; overflow: auto; box-shadow: var(--shadow); }
dialog p { color: var(--ink-soft); }
dialog .close { position: absolute; top: 12px; right: 14px; min-width: 44px; min-height: 44px; border: 0; border-radius: 10px; background: transparent; color: var(--ink-soft); font-size: 1.4rem; }
.detail-meta { display: grid; gap: 7px; margin: 14px 0; padding: 13px; border-radius: 13px; background: #f2f8f2; color: var(--ink-soft); font-size: .86rem; }
.experience-detail { margin: 14px 0; padding: 13px; border-radius: 13px; background: #eef8f1; color: var(--ink-soft); }
.experience-detail p { margin: 5px 0 0; }
.dialog-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.recommendations { margin: 16px 0 0; padding-left: 22px; }
.recommendations li { padding: 9px 0; color: var(--ink-soft); }
.recommendations li strong { color: var(--ink); }

/* Marker geometry is owned by Leaflet/app.js: root 44x48, SVG 32x40 at 6/4, tip at 22/44. */
.event-marker { width: 44px !important; height: 48px !important; border: 0 !important; border-radius: 0 !important; background: transparent !important; box-shadow: none !important; }
.event-marker svg { position: absolute; top: 4px; left: 6px; display: block; width: 32px; height: 40px; overflow: visible; }
.event-marker svg path { fill: var(--green); stroke: #fff; stroke-width: 1.8; }
.event-marker svg circle { fill: var(--orange); stroke: #fff; stroke-width: 1.6; }
.marker-count { position: absolute; top: -2px; right: -7px; z-index: 1; min-width: 22px; height: 22px; padding: 0 5px; border: 2px solid var(--paper); border-radius: 999px; background: var(--orange); color: #193c35; font-size: .68rem; font-weight: 800; line-height: 18px; text-align: center; }
.map-popup-list, .map-popup { display: grid; gap: 6px; min-width: 0; max-width: 100%; }
.map-popup-title { min-height: 44px; padding: 0; border: 0; background: transparent; color: var(--green-dark); text-align: left; font-size: .98rem; font-weight: 800; line-height: 1.35; overflow-wrap: anywhere; }
.map-popup-title:hover { text-decoration: underline; }
.map-popup-meta { color: var(--muted); font-size: .78rem; }
.map-popup-venue { font-weight: 800; font-size: .84rem; }
.map-popup-addr { color: var(--muted); font-size: .74rem; overflow-wrap: anywhere; }
.map-popup-dist { color: var(--green-dark); font-size: .78rem; font-weight: 750; }
.map-popup-actions { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.map-popup-actions .button { min-height: 44px; padding: 4px 9px; font-size: .76rem; }
.map-popup-event { display: grid; gap: 2px; padding-top: 7px; border-top: 1px solid var(--line); }
.map-popup-event button { min-height: 44px; padding: 5px 0; border: 0; background: transparent; color: var(--green-dark); text-align: left; font-weight: 800; overflow-wrap: anywhere; }
.map-popup-event small { color: var(--muted); }
.map-source-link { display: inline-flex; align-items: center; min-height: 44px; color: var(--green-dark); font-weight: 750; }
.leaflet-popup { margin-bottom: 12px; }
.leaflet-popup-content-wrapper {
  max-width: min(340px, calc(100vw - 32px));
  background: rgba(255, 253, 248, .96);
  backdrop-filter: var(--surface-blur);
  -webkit-backdrop-filter: var(--surface-blur);
}
.leaflet-popup-content { max-height: min(48dvh, 440px); margin: 14px; overflow: auto; }
.leaflet-popup-tip-container { width: 24px; height: 12px; left: 50%; margin-left: -12px; margin-top: 0; }
.leaflet-popup-tip { width: 24px; height: 12px; margin: 0; padding: 0; border: 0; border-radius: 0; background: var(--paper); box-shadow: none; clip-path: polygon(0 0, 100% 0, 50% 100%); transform: none; }

@media (min-width: 641px) and (max-width: 1352px) and (min-height: 561px) {
  /* Dock lives in the map space left of the 380px results drawer, so it can
     never slide under it. left/right reserve the drawer + margins; margin
     auto centers the capped 560px dock inside that free corridor. Short
     viewports (<=560px) use the collapsed icon drawer, leaving full width
     free, so the dock stays viewport-centered there. */
  #mapWorkspace:has(#resultsPanel) .search-dock { left: 16px; right: 412px; width: auto; max-width: 560px; margin: 0 auto; transform: none; }
  .filter-menu { width: 100%; }
  /* Attribution sits left of the results drawer, above the dock reserve. */
  .leaflet-container .leaflet-control-attribution { right: calc(380px + 24px); }
  .filter-grid { grid-template-columns: repeat(auto-fit, minmax(min(100%, 160px), 1fr)); }
}
@media (min-width: 1353px) {
  .leaflet-container .leaflet-control-attribution { right: calc(380px + 24px); }
}
@media (min-width: 641px) and (max-height: 560px) {
  .filter-menu { width: min(560px, calc(50vw + 196px)); }
}
@media (min-width: 641px) and (max-width: 1080px) and (min-height: 561px) {
  .timeline-panel { top: max(164px, calc(var(--brand-bottom, 148px) + 16px)); right: 16px; left: 16px; width: auto; }
}

@media (max-height: 560px) {
  /* Keep the open filter below the brand/tools header; the drawer scrolls inside the reserved panel. */
  .filter-menu { max-height: min(calc(68dvh + 46px), 666px, calc(100dvh - 168px)); }
  .filter-drawer { max-height: min(620px, calc(100dvh - 214px)); }
}
@media (max-width: 760px) {
  .brand-note { display: none; }
}
@media (max-width: 640px) {
  .brand-tile { top: 8px; left: 12px; width: min(238px, calc(100vw - 24px)); padding: 6px 8px; border-radius: 13px; }
  .brand-row { min-height: 32px; }
  .brand small { display: none; }
  .brand img { width: 32px; height: 32px; }
  .kids-badge { padding: 2px 6px; font-size: .62rem; }
  .hero-stat { min-height: 28px; padding-inline: 7px; font-size: .68rem; }
  .search-dock { width: calc(100vw - 24px); }
  .search-label input { min-height: 52px; padding-inline: 14px; border-radius: 14px; font-size: .94rem; }
  .filter-menu > summary { justify-content: center; gap: 6px; padding: 8px 12px; }
  .map-tools { --map-edge: top; top: 80px; right: 12px; left: auto; max-width: 190px; grid-template-columns: max-content max-content; gap: 6px; }
  .leaflet-control-zoom { margin-left: 12px !important; }
  .map-fallback { right: 12px; left: 12px; bottom: var(--dock-reserve); width: auto; max-height: 46dvh; overflow: auto; }
  .leaflet-container .leaflet-control-attribution { right: 8px; bottom: var(--dock-reserve); max-width: 52vw; white-space: normal; }
  .source-notes { margin: 0; padding: 0; border: 0; }

  /* Mobile results: icon-triggered right drawer (replaces the old bottom sheet). */
  .results { right: 16px; left: auto; width: 52px; min-width: 52px; border-radius: 16px; }
  .results[data-collapsed="true"] { top: 16px; bottom: auto; height: 52px; }
  .results[data-collapsed="false"] { top: max(256px, min(280px, calc(100dvh - var(--dock-reserve) - 180px))); bottom: var(--dock-reserve); height: auto; width: min(280px, calc(100vw - 72px)); }
  .results-head { flex-direction: row; align-items: center; justify-content: space-between; gap: 6px; padding: 8px 10px; }
  .results-summary { justify-content: flex-start; }
  .results-head-actions { flex-direction: row; justify-content: flex-end; gap: 6px; }
  .results-toggle { display: inline-flex; }
  .results-body { padding-inline: 10px; }
  .results[data-collapsed="true"] .results-head { height: 100%; padding: 0; justify-content: center; align-items: center; border-bottom: 0; }
  .results[data-collapsed="true"] .results-summary,
  .results[data-collapsed="true"] #aiBtn { display: none; }
  .results[data-collapsed="true"] .results-head-actions { width: auto; height: auto; }
  .results[data-collapsed="true"] .results-body { display: none; }
  /* Mobile mutual exclusion: an open conditions popup always wins over the results drawer
     (same spatial corridor as the full-width dock), independent of the drawer's own state. */
  #mapWorkspace:has(#filterMenu[open]) .results {
    top: 16px; bottom: auto; height: 52px; width: 52px;
  }
  #mapWorkspace:has(#filterMenu[open]) .results .results-head {
    height: 100%; padding: 0; justify-content: center; align-items: center; border-bottom: 0;
  }
  #mapWorkspace:has(#filterMenu[open]) .results .results-summary,
  #mapWorkspace:has(#filterMenu[open]) .results #aiBtn,
  #mapWorkspace:has(#filterMenu[open]) .results .results-body {
    display: none;
  }
  .icon-btn { min-width: 44px; min-height: 44px; padding-inline: 10px; }
  .brand-note,
  .freshness,
  .map-hint,
  .filter-toggle-hint,
  .icon-btn .control-label,
  .section-kicker span,
  .date-hint,
  .data-note,
  .source-freshness,
  .results-summary h2,
  .result-hint {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
  }
  .state-panel { padding: 12px; }
  .card { padding: 12px; }
  .dialog-actions { gap: 7px; }
}
@media (max-width: 640px) {
  .timeline-panel { top: max(136px, calc(var(--brand-bottom, 120px) + 16px)); right: max(12px, env(safe-area-inset-right, 0px)); bottom: calc(var(--dock-reserve) + 40px); left: max(12px, env(safe-area-inset-left, 0px)); width: auto; border-radius: 16px; }
  .timeline-head { padding: 12px 14px; }
  .timeline-body { padding: 16px 16px calc(24px + env(safe-area-inset-bottom, 0px)); }
  .timeline-item { grid-template-columns: minmax(50px, auto) minmax(0, 1fr); gap: 10px; }
  .timeline-list { gap: 12px; }
  .timeline-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .timeline-filters button { grid-column: 1 / -1; width: 100%; }
  .history-import-actions .button { flex-basis: 100%; }
  .tools-menu > summary .control-label { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
  .tools-drawer { position: absolute; top: 52px; right: 0; width: min(264px, calc(100vw - 24px)); margin-top: 0; }
  .tools-drawer .control-label { position: static; width: auto; height: auto; padding: 0; margin: 0; overflow: visible; clip: auto; white-space: normal; }
}

@media (max-width: 380px) {
  .brand small { display: none; }
  .kids-badge { padding: 2px 4px; font-size: .58rem; }
  .results-head h2 { font-size: 1rem; }
}
@media (max-height: 560px) {
  :root { --compact-results-width: min(380px, max(224px, calc(100vw - 344px))); }
  .brand-tile { top: 8px; left: 12px; width: min(238px, calc(100vw - 24px)); padding: 6px 8px; border-radius: 13px; }
  .brand-note { display: none; }
  .brand-row { min-height: 32px; }
  .brand small { display: none; }
  .brand img { width: 32px; height: 32px; }
  .kids-badge { padding: 2px 6px; font-size: .62rem; }
  .hero-stat { min-height: 28px; padding-inline: 7px; font-size: .68rem; }
  .map-tools { --map-edge: top; top: calc(var(--brand-bottom, 120px) + 8px); right: auto; left: 72px; max-width: 240px; grid-template-columns: repeat(3, max-content); row-gap: 0; }
  .freshness,
  .map-hint,
  .map-tools .button .control-label,
  .filter-menu > summary .control-label,
  .icon-btn .control-label {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
  }
  .leaflet-control-zoom { margin-left: 12px !important; }
  .leaflet-container .leaflet-control-attribution { left: 8px; right: auto; bottom: calc(var(--dock-reserve) - 10px); max-width: 52vw; white-space: normal; }
  .leaflet-bottom.leaflet-right { left: 8px; right: auto; }
  .filter-toggle-hint { display: none; }
  .filter-menu > summary { justify-content: center; gap: 6px; }
  .results { right: 16px; left: auto; width: 52px; min-width: 52px; border-radius: 16px; }
  .results[data-collapsed="true"] { top: 16px; bottom: auto; height: 52px; }
  .results[data-collapsed="false"] { top: 16px; bottom: var(--dock-reserve); height: auto; width: var(--compact-results-width); }
  .results-head { flex-direction: row; align-items: center; gap: 6px; padding: 8px; }
  .results-summary { flex: 0 0 auto; justify-content: flex-start; flex-wrap: nowrap; gap: 4px; }
  .results-summary h2 { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
  .results-head-actions { flex: 0 0 auto; flex-direction: row; flex-wrap: nowrap; justify-content: flex-end; gap: 4px; }
  .results-head-actions #aiBtn { padding-inline: 10px; }
  .results-toggle { display: inline-flex; }
  .results-toggle .control-label { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
  .results-body { padding-inline: 10px; }
  .results[data-collapsed="true"] .results-head { height: 100%; padding: 0; justify-content: center; align-items: center; border-bottom: 0; }
  .results[data-collapsed="true"] .results-summary,
  .results[data-collapsed="true"] #aiBtn { display: none; }
  .results[data-collapsed="true"] .results-head-actions { width: auto; height: auto; }
  .results[data-collapsed="true"] .results-body { display: none; }
  #mapWorkspace:has(#filterMenu[open]) .results { top: 16px; bottom: auto; height: 52px; width: 52px; }
  #mapWorkspace:has(#filterMenu[open]) .results .results-head { height: 100%; padding: 0; justify-content: center; align-items: center; border-bottom: 0; }
  #mapWorkspace:has(#filterMenu[open]) .results .results-summary,
  #mapWorkspace:has(#filterMenu[open]) .results #aiBtn,
  #mapWorkspace:has(#filterMenu[open]) .results .results-body { display: none; }
}
@media (max-height: 560px) {
  .timeline-panel { top: max(128px, calc(var(--brand-bottom, 120px) + 8px)); bottom: calc(var(--dock-reserve) + 40px); }
  .tools-drawer { position: relative; top: auto; right: auto; grid-template-columns: repeat(4, 44px); width: max-content; max-height: none; overflow: visible; margin-top: 8px; }
}
@media (min-width: 520px) and (max-height: 560px) {
  .brand-tile { display: grid; grid-template-columns: minmax(0, 1fr) 160px; align-items: center; column-gap: 12px; width: min(560px, calc(100vw - 96px)); }
  .brand-row { grid-column: 1; grid-row: 1; }
  .primary-nav { grid-column: 2; grid-row: 1; margin-top: 0; }
  .brand > span { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
  .brand img { flex-shrink: 0; }
  body:has(#resultsPanel:not([hidden])[data-collapsed="false"]) .brand-tile { width: min(560px, calc(100vw - 36px - var(--compact-results-width))); }
  body:has(#resultsPanel:not([hidden])[data-collapsed="false"]) .brand-row :is(.kids-badge, .hero-stat) { display: none; }
  body:has(#resultsPanel:not([hidden])[data-collapsed="false"]) .brand { min-width: 44px; gap: 6px; font-size: .96rem; }
}


@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
  .button:hover, .region-chip:hover { transform: none; }
  .card { animation: none; }
  #loading::after { display: none; }
  dialog { animation: none; }
}

@media (prefers-reduced-transparency: reduce) {
  .brand-tile,
  .search-label input,
  .filter-menu,
  .button-quiet,
  .map-hint,
  .map-fallback,
  .results,
  .leaflet-popup-content-wrapper,
  .leaflet-container .leaflet-control-attribution {
    background-color: var(--paper);
    background-image: none;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    opacity: 1;
  }
  .leaflet-control-attribution { color: var(--ink); }
}

