/* Japan Surveyor Explorer - Airbnb-style light theme (Rocket, 30 Oct 2026). Loads after app.css. */
body.explorer {
  --x-bg: #ffffff; --x-ink: #222222; --x-soft: #717171; --x-line: #dddddd; --x-faint: #f7f7f7;
  --x-accent: #ff385c; --x-dark: #222222; --x-ok: #1f7a4d; --x-warn: #b4501a;
  --x-r: 14px; --x-shadow: 0 6px 20px rgba(0,0,0,.12);
  background: var(--x-bg); color: var(--x-ink);
  font-family: "Inter", "Helvetica Neue", Arial, system-ui, sans-serif; font-size: 14px;
  display: flex; flex-direction: column; height: 100vh; overflow: hidden;
}
body.x-noscroll { overflow: hidden; }
.explorer button { font: inherit; cursor: pointer; }
.explorer a { color: var(--x-ink); }
[hidden] { display: none !important; }

/* top bar */
.x-top { flex: 0 0 auto; border-bottom: 1px solid var(--x-line); background: #fff; z-index: 1100; }
.x-top-row { display: flex; align-items: center; gap: 16px; padding: 10px 20px; }
.x-brand { display: flex; align-items: center; gap: 10px; min-width: 210px; }
.x-logo { width: 34px; height: 34px; border-radius: 10px; background: var(--x-accent); color: #fff; font-weight: 800; display: grid; place-items: center; }
.x-brand h1 { font-size: 16px; margin: 0; }
.x-sub { margin: 0; font-size: 11px; color: var(--x-soft); }
.x-search { flex: 1 1 auto; display: flex; align-items: center; gap: 6px; border: 1px solid var(--x-line); border-radius: 40px; padding: 4px 6px 4px 6px; box-shadow: 0 1px 2px rgba(0,0,0,.08), 0 4px 12px rgba(0,0,0,.05); max-width: 860px; margin: 0 auto; }
.x-modes { display: flex; gap: 2px; }
.x-modes button { border: 0; background: transparent; padding: 8px 12px; border-radius: 30px; font-weight: 600; color: var(--x-soft); white-space: nowrap; }
.x-modes button span { font-weight: 400; font-size: 12px; }
.x-modes button.on { background: var(--x-faint); color: var(--x-ink); box-shadow: inset 0 0 0 1px var(--x-line); }
.x-search-box { flex: 1; display: flex; align-items: center; gap: 6px; border-left: 1px solid var(--x-line); padding-left: 10px; }
.x-search-box input { flex: 1; border: 0; outline: 0; font: inherit; padding: 8px 4px; background: transparent; min-width: 120px; color: var(--x-ink); }
.x-actions { display: flex; align-items: center; gap: 8px; }
.x-actions select, .x-mapbar select { font: inherit; border: 1px solid var(--x-line); border-radius: 10px; padding: 7px 8px; background: #fff; color: var(--x-ink); max-width: 230px; }
.x-btn { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--x-ink); background: #fff; color: var(--x-ink); border-radius: 10px; padding: 8px 14px; font-weight: 600; text-decoration: none; }
.x-btn:hover { background: var(--x-faint); }
.x-btn:disabled { opacity: .35; cursor: default; }
.x-btn-ghost { border-color: transparent; background: transparent; text-decoration: underline; }
.x-btn-dark { background: var(--x-dark); color: #fff; border-color: var(--x-dark); }
.x-btn-dark:hover { background: #000; }
.x-btn-filters { border-color: var(--x-line); }
.x-badge { background: var(--x-ink); color: #fff; border-radius: 20px; font-size: 11px; min-width: 18px; height: 18px; display: inline-grid; place-items: center; padding: 0 5px; }
.x-linkbtn { border: 0; background: none; padding: 0; text-decoration: underline; color: var(--x-ink); }

/* category ribbon */
.x-ribbon { display: flex; gap: 26px; overflow-x: auto; padding: 6px 20px 0; scrollbar-width: thin; }
.x-cat { flex: 0 0 auto; border: 0; background: none; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 6px 0 10px; color: var(--x-soft); border-bottom: 2px solid transparent; opacity: .8; }
.x-cat:hover { opacity: 1; color: var(--x-ink); border-bottom-color: var(--x-line); }
.x-cat.on { color: var(--x-ink); border-bottom-color: var(--x-ink); opacity: 1; }
.x-cat-i { font-size: 20px; line-height: 1; }
.x-cat-l { font-size: 12px; font-weight: 600; white-space: nowrap; }
.x-cat-n { font-size: 11px; color: var(--x-soft); }

/* split */
.x-split { flex: 1 1 auto; display: grid; grid-template-columns: 55% 45%; min-height: 0; }
.x-left { overflow-y: auto; padding: 18px 22px 30px; }
.x-results-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
.x-results-head h2 { margin: 0; font-size: 18px; }
.x-meta { margin: 2px 0 0; color: var(--x-soft); font-size: 12px; }
.x-flags { display: grid; gap: 6px; margin: 12px 0; }
.x-sirflag { background: #fff8e6; border: 1px solid #f1d58a; border-radius: 10px; padding: 7px 10px; font-size: 12px; display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.x-sirflag-k, .x-sirpill { background: #b7791f; color: #fff; font-weight: 700; font-size: 10px; text-transform: uppercase; letter-spacing: .04em; padding: 2px 7px; border-radius: 20px; }
.x-muted { color: var(--x-soft); font-size: 12px; }
.x-seg { display: inline-flex; border: 1px solid var(--x-line); border-radius: 10px; overflow: hidden; }
.x-seg button { border: 0; background: #fff; padding: 6px 10px; color: var(--x-ink); }
.x-seg button + button { border-left: 1px solid var(--x-line); }
.x-seg button.on { background: var(--x-dark); color: #fff; }
.x-seg-sm button { padding: 3px 8px; font-size: 12px; }
.x-chip { display: inline-flex; align-items: center; gap: 5px; border: 1px solid var(--x-line); border-radius: 30px; padding: 4px 10px; background: #fff; font-size: 12px; cursor: pointer; user-select: none; }
.x-chip em { color: var(--x-soft); font-style: normal; font-size: 11px; }
.x-chip input { accent-color: var(--x-dark); margin: 0; }
.x-chip-sm { padding: 2px 8px; }

/* grid + cards */
.x-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 22px 18px; }
.x-card { position: relative; cursor: pointer; border-radius: var(--x-r); outline: none; }
.x-card:focus-visible { box-shadow: 0 0 0 2px var(--x-ink); }
.x-thumb { aspect-ratio: 20/13; border-radius: var(--x-r); display: flex; flex-direction: column; justify-content: flex-end; padding: 10px; color: #fff; background: linear-gradient(135deg, #8a9bb0, #3f4e63); position: relative; overflow: hidden; }
.x-thumb::after { content: ""; position: absolute; inset: 0; background: radial-gradient(circle at 80% 20%, rgba(255,255,255,.25), transparent 55%); }
.x-thumb-ski { background: linear-gradient(135deg, #cfe3f5, #5b8def 70%, #2c4f8f); }
.x-thumb-beach_coast { background: linear-gradient(135deg, #b9ecec, #3fa7b5 65%, #1e6377); }
.x-thumb-island { background: linear-gradient(135deg, #d6f5d0, #3fb58a 60%, #1e7760); }
.x-thumb-mountain, .x-thumb-mountain_lake { background: linear-gradient(135deg, #d9e8c8, #6a9b5a 60%, #3d5f33); }
.x-thumb-onsen { background: linear-gradient(135deg, #f3d9c7, #c77b5a 60%, #7d4430); }
.x-thumb-rural, .x-thumb-countryside { background: linear-gradient(135deg, #efe4c3, #b8a05a 60%, #6f5d2a); }
.x-thumb-pref { background: linear-gradient(135deg, #ffd6de, #ff385c 70%, #a3122f); }
.x-thumb-kind { font-weight: 700; font-size: 14px; position: relative; z-index: 1; text-shadow: 0 1px 3px rgba(0,0,0,.35); }
.x-thumb-tag { font-size: 11px; position: relative; z-index: 1; opacity: .95; text-shadow: 0 1px 3px rgba(0,0,0,.35); }
.x-thumb-big { aspect-ratio: auto; height: 150px; margin-bottom: 12px; }
.x-card-top { position: absolute; top: 10px; left: 10px; right: 10px; display: flex; justify-content: space-between; align-items: center; z-index: 2; }
.x-score { background: #fff; color: var(--x-ink); font-weight: 700; font-size: 12px; padding: 3px 9px; border-radius: 20px; box-shadow: 0 1px 4px rgba(0,0,0,.2); }
.x-score.hi { background: #1f7a4d; color: #fff; }
.x-score.mid { background: #fff; }
.x-score.lo { background: #f3f3f3; color: #555; }
.x-score.min, .x-score.none { background: #eee; color: #888; }
.x-heart { border: 0; background: rgba(0,0,0,.25); color: #fff; width: 32px; height: 32px; border-radius: 50%; font-size: 18px; line-height: 1; display: grid; place-items: center; }
.x-heart.on { color: var(--x-accent); background: #fff; }
.x-card-body { padding: 8px 2px 0; }
.x-card-body h3 { font-size: 14px; margin: 2px 0; font-weight: 600; }
.x-price strong { font-size: 15px; }
.x-price span { color: var(--x-soft); font-size: 12px; }
.x-specs, .x-ratings, .x-src { margin: 2px 0; color: var(--x-soft); font-size: 12px; }
.x-src a { color: var(--x-soft); }
.x-tags, .x-tracks { display: flex; flex-wrap: wrap; gap: 4px; margin: 5px 0 2px; }
.x-tag { font-size: 11px; border: 1px solid var(--x-line); border-radius: 6px; padding: 1px 6px; color: #444; background: #fff; }
.x-tag.ok { border-color: #b7dfc8; background: #eef8f2; color: var(--x-ok); }
.x-tag.warn { border-color: #f1c7aa; background: #fdf1e8; color: var(--x-warn); }
.x-tag.est { border-color: #c9d6f2; background: #eef3fc; color: #2f4f8f; }
.x-tag.zy { border-color: #222; background: #222; color: #fff; font-weight: 700; }
.x-tax { margin: 6px 0 0; font-size: 13px; color: #333; display: flex; flex-wrap: wrap; gap: 4px; align-items: center; }
.x-track { font-size: 10.5px; border-radius: 6px; padding: 1px 6px; color: #fff; background: var(--c); }
.x-bars { display: grid; gap: 3px; margin: 6px 0; }
.x-bar { display: grid; grid-template-columns: 1fr 70px 34px; align-items: center; gap: 6px; font-size: 11px; color: #444; }
.x-bar-t { height: 5px; background: #eee; border-radius: 4px; overflow: hidden; }
.x-bar-t i { display: block; height: 100%; background: var(--x-dark); }
.x-bar-v { text-align: right; font-variant-numeric: tabular-nums; }
.x-empty { grid-column: 1 / -1; text-align: center; padding: 40px 10px; color: var(--x-soft); }
.x-empty h3 { color: var(--x-ink); }
.x-more { text-align: center; margin: 22px 0; }
.x-foot { color: var(--x-soft); font-size: 11px; border-top: 1px solid var(--x-line); padding-top: 12px; margin-top: 10px; }

/* map pane */
.explorer .x-right.map-pane { position: sticky; top: 0; height: 100%; background: #e9ecef; border-left: 1px solid var(--x-line); }
.explorer #map { position: absolute; inset: 0; background: #e9ecef; }
.x-mapbar { position: absolute; top: 12px; left: 56px; right: 12px; z-index: 900; display: flex; flex-wrap: wrap; gap: 6px; align-items: flex-start; pointer-events: none; }
.x-mapbar > * { pointer-events: auto; }
.x-mapbar .x-chip, .x-mapbar .x-seg, .x-mapbar select { box-shadow: 0 2px 8px rgba(0,0,0,.15); }
.x-mapbar .x-chip { font-weight: 600; }
.explorer .error-banner { position: absolute; bottom: 12px; left: 12px; right: 12px; z-index: 950; display: none; background: #fdecec; color: #8a1c1c; border: 1px solid #f3b4b4; border-radius: 10px; padding: 8px 12px; }
.explorer .error-banner.visible { display: block; }

/* pills on the map */
.ll-pin-wrap { background: none !important; border: 0 !important; }
.airbnb-pill { display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; background: #fff; color: #222; border-radius: 20px; padding: 3px 9px; font-weight: 700; font-size: 12px; box-shadow: 0 1px 4px rgba(0,0,0,.28), 0 0 0 1px rgba(0,0,0,.06); transform: translate(-50%, -50%); transition: transform .12s, background .12s; position: relative; }
.airbnb-pill .pill-s { font-weight: 600; font-size: 11px; color: #555; }
.airbnb-pill.band-top .pill-s { color: var(--x-ok); }
.airbnb-pill.band-good .pill-s { color: #2c5fb0; }
.airbnb-pill.is-hovered, .airbnb-pill:hover { transform: translate(-50%, -50%) scale(1.12); z-index: 10; background: #222; color: #fff; }
.airbnb-pill.is-hovered .pill-s, .airbnb-pill:hover .pill-s { color: #fff; }
.airbnb-pill.is-selected { background: var(--x-accent); color: #fff; }
.airbnb-pill.is-selected .pill-s { color: #fff; }
.ll-group.is-hovered span { outline: 3px solid #222; }

/* legend */
.explorer .x-legend { background: #fff; color: var(--x-ink); border-radius: 12px; box-shadow: var(--x-shadow); max-width: 250px; max-height: 38vh; overflow: auto; font-size: 11.5px; border: 0; }
.explorer .x-legend .map-legend-toggle { width: 100%; text-align: left; border: 0; background: #fff; font-weight: 700; padding: 8px 10px; color: var(--x-ink); }
.explorer .x-legend.collapsed .map-legend-body { display: none; }
.explorer .x-legend .map-legend-body { padding: 0 10px 10px; }
.lg-h { font-weight: 700; margin: 8px 0 2px; }
.lg-layer { margin: 0 0 4px; }
.lg-note { margin: 2px 0; color: var(--x-soft); }
.x-grad { height: 10px; border-radius: 4px; }
.x-grad-l { display: flex; justify-content: space-between; color: var(--x-soft); }
.x-sw { display: inline-block; width: 12px; height: 12px; border-radius: 3px; vertical-align: middle; }
.x-pills-demo { display: flex; gap: 4px; }
.x-pd { background: #fff; border-radius: 12px; padding: 1px 6px; font-weight: 700; box-shadow: 0 0 0 1px #ccc; }
.x-pd.hi { color: var(--x-ok); } .x-pd.mid { color: #2c5fb0; } .x-pd.lo { color: #555; } .x-pd.min { color: #999; }
.lg-tracks { list-style: none; padding: 0; margin: 2px 0; }
.lg-tracks .dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: 5px; vertical-align: middle; }
.x-legend-base { border-top: 1px solid var(--x-line); margin-top: 8px; padding-top: 4px; }

/* modal + drawer */
.x-modal { position: fixed; inset: 0; z-index: 3000; background: rgba(0,0,0,.45); display: grid; place-items: center; padding: 24px; }
.x-modal-card { background: #fff; border-radius: 16px; width: min(780px, 100%); max-height: calc(100vh - 48px); display: flex; flex-direction: column; box-shadow: 0 10px 40px rgba(0,0,0,.3); outline: none; }
.x-modal-head { display: flex; align-items: center; justify-content: center; position: relative; padding: 14px; border-bottom: 1px solid var(--x-line); }
.x-modal-head h2 { margin: 0; font-size: 16px; }
.x-close { position: absolute; left: 12px; border: 0; background: none; font-size: 22px; width: 34px; height: 34px; border-radius: 50%; }
.x-close:hover { background: var(--x-faint); }
.x-modal-body { overflow-y: auto; padding: 6px 24px 20px; }
.x-modal-foot { display: flex; justify-content: space-between; padding: 12px 24px; border-top: 1px solid var(--x-line); }
.x-sec { border-bottom: 1px solid var(--x-line); padding: 16px 0; }
.x-sec:last-child { border-bottom: 0; }
.x-sec h3 { margin: 0 0 10px; font-size: 17px; }
.x-sec h4 { margin: 14px 0 6px; font-size: 13px; color: var(--x-soft); text-transform: uppercase; letter-spacing: .04em; }
.x-fs { border: 0; padding: 0; margin: 0 0 12px; }
.x-fs legend { font-weight: 600; margin-bottom: 6px; padding: 0; }
.x-chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 6px 0; }
.x-chips-scroll { max-height: 140px; overflow-y: auto; padding: 2px; }
.x-chipbtn { border: 1px solid var(--x-line); background: #fff; border-radius: 30px; padding: 6px 12px; font-size: 12px; color: var(--x-ink); }
.x-chipbtn.on { border-color: var(--x-ink); background: var(--x-ink); color: #fff; }
.x-range { display: grid; grid-template-columns: minmax(170px, 1.4fr) 1fr auto 1fr auto; gap: 8px; align-items: center; margin: 6px 0; }
.x-range input[type=number] { font: inherit; border: 1px solid var(--x-line); border-radius: 8px; padding: 6px 8px; width: 100%; min-width: 0; }
.x-range-l small { color: var(--x-soft); font-weight: 400; }
.x-dash { color: var(--x-soft); font-size: 12px; }
.x-slider { grid-template-columns: minmax(170px, 1.4fr) 2fr 46px auto; }
.x-slider input[type=range] { accent-color: var(--x-dark); width: 100%; }
.x-slider output { font-variant-numeric: tabular-nums; text-align: right; font-size: 12px; }
.x-range-off { grid-template-columns: minmax(170px, 1.4fr) 1fr; opacity: .7; }
.x-drawer { place-items: stretch end; padding: 0; }
.x-drawer-card { background: #fff; width: min(560px, 100vw); height: 100vh; display: flex; flex-direction: column; box-shadow: -10px 0 30px rgba(0,0,0,.2); }
.x-drawer-head { display: flex; align-items: center; gap: 4px; padding: 8px 10px; border-bottom: 1px solid var(--x-line); position: relative; }
.x-drawer-head .x-close { position: static; }
.x-grow { flex: 1; }
.x-drawer-body { overflow-y: auto; padding: 16px 22px 30px; }
.x-d-head h2 { margin: 0 0 4px; font-size: 20px; }
.x-d-sec { border-top: 1px solid var(--x-line); padding: 14px 0; }
.x-d-sec h3 { margin: 0 0 8px; font-size: 15px; }
.x-table { width: 100%; border-collapse: collapse; font-size: 12.5px; margin: 6px 0; }
.x-table th { text-align: left; font-weight: 600; color: #444; width: 42%; padding: 4px 8px 4px 0; vertical-align: top; }
.x-table td { padding: 4px 0; border-bottom: 1px solid #f0f0f0; }
.x-dl dt { font-weight: 600; margin-top: 6px; text-transform: capitalize; }
.x-dl dd { margin: 2px 0 0; color: #444; }
.x-warnline { background: #fdf1e8; border: 1px solid #f1c7aa; color: var(--x-warn); border-radius: 8px; padding: 6px 9px; font-size: 12px; }
.x-src-list { padding-left: 18px; font-size: 12px; }
.x-mini { padding-left: 18px; }
.explorer details summary { cursor: pointer; font-weight: 600; margin: 6px 0; }

/* Leaflet popups/tooltips in light theme */
.explorer .leaflet-popup-content-wrapper, .explorer .leaflet-popup-tip { background: #fff; color: var(--x-ink); }
.explorer .leaflet-tooltip { background: #fff; color: var(--x-ink); border: 0; box-shadow: 0 2px 8px rgba(0,0,0,.2); }

@media (max-width: 980px) {
  .x-split { grid-template-columns: 1fr; grid-template-rows: 1fr 45vh; }
  .x-brand { min-width: 0; } .x-sub { display: none; }
  .x-top-row { flex-wrap: wrap; }
}


/* ---- Jeeves fix list, 30 Oct 2026 ---- */
/* 2: merged map options dropdown (replaces the old Leaflet layer switcher) */
.x-mapopts { position: relative; }
.x-mapopts > summary { list-style: none; box-shadow: 0 2px 8px rgba(0,0,0,.15); font-weight: 600; }
.x-mapopts > summary::-webkit-details-marker { display: none; }
.x-mapopts > summary::after { content: "▾"; margin-left: 4px; font-size: 10px; }
.x-mapopts[open] > summary::after { content: "▴"; }
.x-mapopts-body { position: absolute; top: calc(100% + 6px); left: 0; width: 280px; max-height: 70vh; overflow: auto; background: #fff; border-radius: 12px; box-shadow: var(--x-shadow), 0 4px 18px rgba(0,0,0,.18); padding: 4px 12px 12px; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; z-index: 1000; }
.x-mapopts-body select { max-width: 100%; width: 100%; }
.x-mo-h { flex: 1 0 100%; margin: 8px 0 0; font-size: 11px; font-weight: 700; color: var(--x-soft); text-transform: uppercase; letter-spacing: .04em; }
/* Legend: clearly collapsible */
.explorer .x-legend .map-legend-toggle { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.x-lg-caret::after { content: "Hide ▾"; font-weight: 600; font-size: 11px; color: var(--x-soft); }
.explorer .x-legend.collapsed .x-lg-caret::after { content: "Show ▴"; }
.explorer .x-legend.collapsed { max-height: none; overflow: visible; }

/* 3 + 5: clusters styled, singles drawn above clusters, strong hover/selected */
.ll-group .airbnb-cluster { display: inline-flex; flex-direction: column; align-items: center; transform: translate(-50%, -50%); background: #fff; color: #222; border: 2px solid var(--cluster-border, #222); border-radius: 18px; padding: 2px 10px; font-size: 12px; line-height: 1.15; box-shadow: 0 1px 4px rgba(0,0,0,.3); white-space: nowrap; transition: transform .12s, background .12s; }
.ll-group .airbnb-cluster small { font-size: 10px; color: #555; font-weight: 600; }
.ll-group .airbnb-cluster:hover, .ll-group .airbnb-cluster.is-hovered, .ll-group.is-hovered .airbnb-cluster { background: #222; color: #fff; transform: translate(-50%, -50%) scale(1.25); box-shadow: 0 0 0 4px rgba(255,56,92,.55), 0 3px 10px rgba(0,0,0,.4); }
.ll-group .airbnb-cluster.is-hovered small, .ll-group.is-hovered .airbnb-cluster small, .ll-group .airbnb-cluster:hover small { color: #fff; }
.airbnb-pill.is-hovered, .airbnb-pill:hover { transform: translate(-50%, -50%) scale(1.3); background: #222; color: #fff; box-shadow: 0 0 0 4px rgba(255,56,92,.6), 0 3px 10px rgba(0,0,0,.4); }
.airbnb-pill.is-selected { background: var(--x-accent); color: #fff; transform: translate(-50%, -50%) scale(1.2); box-shadow: 0 0 0 3px #fff, 0 0 0 6px var(--x-accent); }
.x-card.is-hot { box-shadow: 0 0 0 3px var(--x-accent), 0 6px 18px rgba(255,56,92,.25); }
.x-card.is-hot .x-card-body h3 { color: var(--x-accent); }
.x-card:hover { box-shadow: 0 0 0 2px var(--x-ink); }

/* 1: phone layout */
.x-viewtoggle { display: none; }
@media (max-width: 760px) {
  body.explorer { height: 100dvh; }
  .x-top-row { padding: 8px 10px; gap: 8px; flex-wrap: wrap; }
  .x-brand { min-width: 0; flex: 1 1 auto; }
  .x-brand h1 { font-size: 14px; } .x-sub { display: none; } .x-logo { width: 28px; height: 28px; font-size: 12px; }
  .x-actions { order: 2; gap: 6px; }
  .x-actions select { max-width: 120px; padding: 6px; font-size: 12px; }
  .x-btn-filters { padding: 6px 10px; }
  .x-search { order: 3; flex: 1 0 100%; flex-wrap: wrap; border-radius: 16px; padding: 4px; gap: 2px; max-width: none; min-width: 0; }
  .x-modes { flex: 1 0 100%; overflow-x: auto; scrollbar-width: none; }
  .x-modes button { padding: 6px 10px; font-size: 13px; }
  .x-search-box { flex: 1 0 100%; border-left: 0; border-top: 1px solid var(--x-line); padding: 2px 6px 0; }
  .x-search-box input { min-width: 0; font-size: 16px; }
  .x-ribbon { gap: 16px; padding: 2px 10px 0; scrollbar-width: none; }
  .x-cat { padding: 4px 0 6px; } .x-cat-i { font-size: 16px; } .x-cat-l { font-size: 11px; }
  .x-split { display: block; position: relative; }
  .x-left { height: 100%; padding: 12px 12px 80px; }
  .x-grid { grid-template-columns: 1fr; gap: 16px; }
  .explorer .x-right.map-pane { position: absolute; inset: 0; height: auto; border-left: 0; }
  body.x-view-list .x-right.map-pane { visibility: hidden; pointer-events: none; }
  body.x-view-map .x-left { display: none; }
  .x-mapbar { left: 52px; right: 8px; top: 8px; }
  .x-mapbar .x-chip { font-size: 12px; }
  .x-mapopts-body { width: min(280px, calc(100vw - 70px)); max-height: 60vh; }
  .explorer .x-legend { max-width: min(250px, calc(100vw - 30px)); max-height: 45vh; }
  .x-viewtoggle { display: inline-flex; position: fixed; left: 50%; bottom: 18px; transform: translateX(-50%); z-index: 1150; background: var(--x-dark); color: #fff; border: 0; border-radius: 30px; padding: 11px 22px; min-height: 44px; align-items: center; font-weight: 700; box-shadow: 0 4px 14px rgba(0,0,0,.3); }
  .x-viewtoggle::before { content: "▦ "; margin-right: 4px; }
  body.x-view-list .x-viewtoggle::before { content: "⌖ "; }
  .x-modal-card, .x-drawer-card { width: 100vw !important; max-width: 100vw !important; height: 100dvh !important; max-height: 100dvh !important; border-radius: 0 !important; }
  .x-drawer-head { flex-wrap: wrap; gap: 4px; }
  .x-drawer-head .x-btn { padding: 6px 8px; font-size: 12px; }
}
@media (max-width: 760px) { .x-modal { padding: 0 !important; } }
@media (max-width: 760px) {
  body.x-view-map .x-ribbon { display: none; }
  .explorer .leaflet-control-attribution { max-width: calc(100vw - 16px); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 9px; }
  .explorer .leaflet-bottom.leaflet-right .x-legend { margin-bottom: 64px; }
}
@media (max-width: 760px) { .x-mapopts-body { left: auto; right: 0; } }
