/* Chamaps — shell.css · Phase 5 "liquid glass" shell layout (DESIGN_SPEC.md §3–§6).
 * One DOM, two layouts: desktop cockpit (strip · tiles · tools · scrubber · mode panel) ≥ 861px,
 * floating islands (capsule · chip · cards · side pill · dock · sheet) ≤ 860px — the same breakpoint app.js uses.
 * Loaded last so it can re-position the panels the feature modules style (community.css, routes.css …). */

/* ---------- base for the shell ---------- */
body { font-family: var(--font-body); font-size: 14px; color: var(--text); text-shadow: var(--text-shadow); -webkit-tap-highlight-color: transparent; }
.shell { position: absolute; inset: 0; z-index: 5; pointer-events: none; }
.shell > * { pointer-events: auto; }
svg.ic { width: 20px; height: 20px; flex: 0 0 auto; display: block; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.mono { font-family: var(--font-mono); font-variant-numeric: tabular-nums; font-size: 13px; }
.muted { color: var(--muted); }
.micro { font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); font-weight: 500; }
.dot { color: var(--muted); }
.mark { width: 14px; height: 14px; border-radius: 3px; background: var(--accent); flex: 0 0 auto; clip-path: polygon(0 100%, 50% 0, 100% 100%, 76% 100%, 50% 48%, 24% 100%); }
.icon-btn { width: 32px; height: 32px; border-radius: var(--r-pill); display: inline-flex; align-items: center; justify-content: center; color: var(--text-2); transition: background var(--dur) var(--ease), color var(--dur) var(--ease); }
.icon-btn:hover { background: rgba(255,255,255,.08); color: var(--text); }
.icon-btn .ic { width: 18px; height: 18px; }
.btn--primary, .ilink--primary, .badge, .avypop__lvl { text-shadow: none; }

/* buttons inherit the pill language of the spec */
.btn { border-radius: var(--r-pill); }
.iconbtn { border-radius: var(--r-pill); border-color: transparent; }
.tab { border-radius: var(--r-pill); }
.tab.is-active { background: var(--accent-soft); color: var(--text); }
.route.is-selected, .chip:has(input:checked), .ovl[aria-pressed="true"] { background: var(--accent-soft); border-color: var(--accent); }
.maplibregl-popup-content { backdrop-filter: blur(var(--glass-blur)) saturate(140%); -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(140%); }
html.no-blur .maplibregl-popup-content { background: var(--glass-solid); backdrop-filter: none; -webkit-backdrop-filter: none; }
.maplibregl-ctrl-attrib { background: var(--glass-bg-strong) !important; border-radius: var(--r-pill) 0 0 0; color: var(--text-2); }
.maplibregl-ctrl-attrib.maplibregl-compact-show { max-width: min(420px, 60vw); border-radius: var(--r-md) 0 0 0; }
.maplibregl-ctrl-attrib a { color: var(--text); }

/* ============================================================ */
/* STRIP                                                          */
/* ============================================================ */
.strip { position: absolute; top: 0; left: 0; right: 0; height: var(--strip-h); z-index: 20; display: flex; align-items: center; gap: 0; padding: 0 12px; border-radius: 0; border-width: 0 0 1px 0; box-shadow: var(--glass-highlight), 0 8px 30px rgba(0,0,0,.25); }
.strip-sep { width: 1px; height: 20px; background: var(--glass-line); margin: 0 12px; flex: 0 0 auto; }
.strip-spacer { flex: 1 1 auto; }
.brand { display: inline-flex; align-items: center; gap: 8px; color: var(--text); text-decoration: none; flex: 0 0 auto; }
.brand-name { font-family: var(--font-display); font-weight: 600; font-size: 15px; letter-spacing: -.01em; }
.strip-search { position: relative; display: inline-flex; align-items: center; gap: 8px; height: 28px; width: 264px; padding: 0 10px; border-radius: var(--r-pill); color: var(--muted); flex: 0 0 auto; transition: width var(--dur) var(--ease), border-color var(--dur) var(--ease); }
.strip-search .strip-search__ic { width: 16px; height: 16px; }
.strip-search input { flex: 1; min-width: 0; height: 100%; font-size: 13px; background: none; border: 0; outline: none; color: var(--text); }
.strip-search input::placeholder { color: var(--muted); }
.strip-search input::-webkit-search-cancel-button { filter: invert(1) opacity(.5); }
.search__results { position: absolute; top: calc(100% + 8px); left: 0; right: 0; z-index: 30; max-height: min(60vh, 420px); overflow-y: auto; border-radius: var(--r-md); padding: 4px; text-align: left; color: var(--text); }
.search__results li { border-radius: var(--r-sm); border-top: 0; }
.strip-item { display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; color: var(--text); font-size: 13px; flex: 0 0 auto; }
.strip-item .ic { width: 16px; height: 16px; color: var(--text-2); }
#stripAlt { min-width: 62px; }
#stripTemp { min-width: 34px; }
#stripWind { min-width: 58px; }
#stripTime, #stripSunrise, #stripSunset { min-width: 40px; }
#stripEaws { min-width: 78px; justify-content: center; }
.place { font-weight: 700; text-transform: uppercase; letter-spacing: .06em; font-size: 12px; max-width: 220px; overflow: hidden; text-overflow: ellipsis; }
.eaws-pill { display: inline-flex; align-items: center; height: 20px; padding: 0 8px; border-radius: var(--r-pill); font-size: 12px; font-weight: 500; background: rgba(255,255,255,.10); color: var(--text-2); border: 1px solid var(--glass-line); text-shadow: none; }
.eaws-pill.is-ok { background: var(--accent-soft); color: var(--text); border-color: transparent; }
.eaws-pill.is-warn { background: var(--warn); color: #2a1600; border-color: transparent; }
.eaws-pill.is-danger { background: var(--danger); color: #fff; border-color: transparent; }
.wxchip { cursor: pointer; }
.wxchip .strip-item__more { display: none; }

/* modes (inline on desktop, the dock on phones) */
.modes { display: inline-flex; gap: 2px; align-items: center; }
.mode-btn { width: 32px; height: 32px; border-radius: var(--r-pill); display: inline-flex; align-items: center; justify-content: center; color: var(--text-2); transition: background var(--dur) var(--ease), color var(--dur) var(--ease); }
.mode-btn:hover { color: var(--text); background: rgba(255,255,255,.08); }
.mode-btn[aria-pressed="true"] { color: var(--accent); background: var(--accent-soft); }
.mode-btn .ic { width: 20px; height: 20px; }

/* community cluster: the two legacy toggles stay in the DOM for aria state only */
.cmty-bar { display: inline-flex; align-items: center; gap: 8px; }
#routesBtn, #cmtyBtn { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); opacity: 0; pointer-events: none; }
.cmty-bar__btn--av { height: 28px; min-width: 28px; padding: 0 8px; border-radius: var(--r-pill); background: rgba(255,255,255,.08); border: 1px solid var(--glass-line-strong); color: var(--text); font-size: 12px; font-weight: 600; gap: 6px; backdrop-filter: none; }
.cmty-bar__btn--av svg { width: 16px; height: 16px; color: var(--text-2); }
.cmty-bar__btn--av.is-av { padding: 0; width: 28px; justify-content: center; }
.cmty-bar__btn--av .cmty-av { width: 26px; height: 26px; font-size: 11px; }
.cmty-bar__btn--av[aria-expanded="true"], .cmty-bar__btn--av:hover { border-color: var(--accent); }
.appearance-btn { width: 28px; height: 28px; border-radius: var(--r-pill); }
.appearance-btn .ic { width: 16px; height: 16px; }
.appearance-btn[aria-expanded="true"] { color: var(--accent); border-color: var(--accent); }

/* ============================================================ */
/* TILES (left column)                                            */
/* ============================================================ */
.tiles { position: absolute; top: calc(var(--strip-h) + var(--inset)); left: var(--inset); width: var(--tile-w); z-index: 10; display: flex; flex-direction: column; gap: 8px; max-height: calc(100% - var(--strip-h) - var(--inset) * 3 - var(--scrub-h)); overflow-y: auto; scrollbar-width: none; padding-bottom: 2px; }
.tiles::-webkit-scrollbar { display: none; }
.tiles__handle { display: none; }
.tile { flex: 0 0 auto; overflow: hidden; border-radius: var(--r-lg); }
.tile-head { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 38px; padding: 0 12px 0 14px; text-align: left; color: var(--text); }
.tile-head .micro { color: var(--accent); flex: 0 0 auto; }
.tile-meta { margin-left: auto; color: var(--text-2); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chev { width: 16px; height: 16px; color: var(--muted); transition: transform var(--dur) var(--ease); flex: 0 0 auto; }
.tile--ph .tile-head { cursor: default; }
/* Desktop cockpit: the placeholder tiles were only ever meant as a hint before there was an "Area info" chip. Now the chip covers it, so hide them everywhere on the desktop layout (mobile is already handled in the ≤ 860 px block). */
.tile--ph { display: none; }

.isec__sub { margin: 10px 0 6px; font-size: 11px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); }
.isec__sub .hint { display: inline; text-transform: none; letter-spacing: 0; font-weight: 500; color: var(--muted); }
.isec__sub:first-child { margin-top: 0; }
/* info.js panel → its header and each <details> section become tiles */
.info { display: contents; }
.info__body { display: contents; }
.info__head { position: relative; flex: 0 0 auto; display: flex; align-items: flex-start; gap: 10px; padding: 10px 12px 10px 14px; border-radius: var(--r-lg); background: var(--glass-bg); border: 1px solid var(--glass-line); box-shadow: var(--glass-highlight), var(--shadow); backdrop-filter: blur(var(--glass-blur)) saturate(140%); -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(140%); }
html.no-blur .info__head { background: var(--glass-solid); backdrop-filter: none; -webkit-backdrop-filter: none; }
.info__handle { display: none; }
.info__kicker { color: var(--accent); font-size: 11px; letter-spacing: .12em; }
.info__title { font-size: 17px; }
.info__close { width: 28px; height: 28px; }
.info__close svg { width: 16px; height: 16px; }
.isec { flex: 0 0 auto; border: 1px solid var(--glass-line); border-radius: var(--r-lg); background: var(--glass-bg); box-shadow: var(--glass-highlight), var(--shadow); backdrop-filter: blur(var(--glass-blur)) saturate(140%); -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(140%); overflow: hidden; }
html.no-blur .isec { background: var(--glass-solid); backdrop-filter: none; -webkit-backdrop-filter: none; }
.isec:last-child { border-bottom: 1px solid var(--glass-line); }
.isec__h { min-height: 38px; padding: 0 12px 0 14px; gap: 10px; font-size: 11px; letter-spacing: .12em; text-transform: uppercase; font-weight: 500; color: var(--accent); }
.isec__h::before { display: none; }
.isec__h::after { content: ''; width: 16px; height: 16px; flex: 0 0 auto; background: currentColor; color: var(--muted); clip-path: polygon(50% 62%, 22% 34%, 16% 40%, 50% 74%, 84% 40%, 78% 34%); transition: transform var(--dur) var(--ease); }
.isec[open] > .isec__h::after { transform: rotate(180deg); }
.isec__h > span:first-of-type { flex: 1 1 auto; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.isec__badge { margin-left: auto; flex: 0 1 auto; min-width: 0; background: none; color: var(--text-2); font-size: 12px; letter-spacing: 0; text-transform: none; font-weight: 500; padding: 0; max-width: 140px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: block; }
.isec[open] > .isec__h .isec__badge { display: none; }
.isec__badge.is-good, .isec__badge.is-ok, .isec__badge.is-warn { background: none; }
.isec__badge.is-warn { color: var(--warn); }
.isec__badge.is-good { color: var(--accent); }
.isec__b { padding: 12px 14px 14px; border-top: 1px solid var(--glass-line); background: var(--glass-bg-strong); }
html.no-blur .isec__b { background: var(--glass-solid); }
.info-open { flex: 0 0 auto; align-self: flex-start; display: inline-flex; align-items: center; gap: 8px; height: 32px; padding: 0 12px 0 10px; border-radius: var(--r-pill); font-size: 12px; font-weight: 600; color: var(--text); background: var(--glass-bg); border: 1px solid var(--glass-line); box-shadow: var(--glass-highlight), var(--shadow); backdrop-filter: blur(var(--glass-blur)) saturate(140%); }
.info-open svg { width: 16px; height: 16px; color: var(--accent); }
html.no-blur .info-open { background: var(--glass-solid); backdrop-filter: none; }
.istat, .ilink, .tip__rose { background: rgba(255,255,255,.06); border-color: var(--glass-line); }
.cards { display: none; }

/* ============================================================ */
/* TOOLS (right rail)                                             */
/* ============================================================ */
.tools { position: absolute; right: var(--inset); top: 50%; transform: translateY(-50%); z-index: 12; width: 40px; display: flex; flex-direction: column; align-items: center; padding: 4px 0; border-radius: var(--r-pill); transition: right var(--dur) var(--ease); }
body:is(.has-sidebar, .has-cmty) .tools { right: calc(var(--inset) * 2 + var(--panel-w)); }
.tool { width: 32px; height: 32px; margin: 2px 0; border-radius: var(--r-pill); display: inline-flex; align-items: center; justify-content: center; color: var(--text-2); transition: background var(--dur) var(--ease), color var(--dur) var(--ease); }
.tool:hover { background: rgba(255,255,255,.10); color: var(--text); }
.tool.is-active { color: var(--accent); }
.tool svg { width: 18px; height: 18px; }
.tool--compass svg { width: 22px; height: 22px; }
.tool__txt { font-family: var(--font-display); font-weight: 600; font-size: 12px; }
.tool-group { display: flex; flex-direction: column; align-items: center; position: relative; margin: 2px 0; padding: 2px 0; }
.tool-group::before, .tool-group::after { content: ''; width: 20px; height: 1px; background: var(--glass-line); }

/* layers popover next to the rail */
.pop { position: absolute; z-index: 16; right: calc(var(--inset) + 40px + 8px); top: 50%; transform: translateY(-50%); width: 300px; padding: 14px; display: flex; flex-direction: column; gap: 10px; max-height: calc(100% - var(--strip-h) - var(--inset) * 3 - var(--scrub-h)); overflow-y: auto; scrollbar-width: thin; scrollbar-color: rgba(255,255,255,.2) transparent; background: var(--glass-bg-strong); border: 1px solid var(--glass-line); border-radius: var(--r-lg); box-shadow: var(--glass-highlight), var(--shadow); transition: right var(--dur) var(--ease); }
html.no-blur .pop { background: var(--glass-solid); }
body:is(.has-sidebar, .has-cmty) .pop { right: calc(var(--inset) * 2 + var(--panel-w) + 40px + 8px); }
.ovl { background: rgba(255,255,255,.04); }

/* ============================================================ */
/* SCRUBBER                                                       */
/* ============================================================ */
.scrubber-row { position: absolute; bottom: var(--inset); left: 50%; transform: translateX(-50%); z-index: 11; display: flex; align-items: center; gap: 8px; transition: left var(--dur) var(--ease); }
body:is(.has-sidebar, .has-cmty) .scrubber-row { left: calc(50% + (var(--tile-w) - var(--panel-w)) / 2); }
.scrubber { width: 480px; height: var(--scrub-h); border-radius: var(--r-pill); display: flex; align-items: center; padding: 0 10px 0 12px; gap: 10px; }
.scrub-label { width: 44px; font-size: 12px; flex: 0 0 auto; color: var(--text); }
.scrub-track { position: relative; flex: 1 1 auto; height: 100%; cursor: pointer; touch-action: none; }
.ticks { position: absolute; left: 0; right: 0; bottom: 6px; height: 8px; display: flex; justify-content: space-between; pointer-events: none; }
.ticks span { width: 1px; height: 4px; background: var(--glass-line-strong); align-self: flex-end; }
.ticks span.major { height: 8px; background: rgba(255,255,255,.55); }
.day-band { position: absolute; top: 50%; height: 2px; margin-top: -1px; background: var(--accent-soft); border-radius: 1px; pointer-events: none; left: 0; width: 0; }
.sun-mark { position: absolute; top: 50%; transform: translate(-50%, -50%); color: var(--muted); pointer-events: none; }
.sun-mark .ic { width: 12px; height: 12px; }
.thumb { position: absolute; top: 50%; left: 50%; width: 14px; height: 14px; border-radius: 50%; background: var(--accent); border: 2px solid var(--accent-ink); box-shadow: 0 0 0 2px var(--accent), 0 2px 8px rgba(0,0,0,.4); transform: translate(-50%, -50%); cursor: grab; touch-action: none; }
.thumb:active { cursor: grabbing; }
.scrub-now { height: 22px; padding: 0 8px; border-radius: var(--r-pill); font-size: 11px; font-weight: 600; color: var(--accent); border: 1px solid var(--accent); flex: 0 0 auto; }
.info-btn { width: 32px; height: 32px; border-radius: var(--r-pill); display: inline-flex; align-items: center; justify-content: center; font-family: var(--font-display); font-weight: 600; font-size: 13px; color: var(--text-2); }
.info-btn:hover, .info-btn[aria-expanded="true"] { color: var(--accent); }

/* ============================================================ */
/* MODE PANEL (hosts #sidebar and #cmty, one at a time)           */
/* ============================================================ */
.mode-panel { position: absolute; top: calc(var(--strip-h) + var(--inset)); right: var(--inset); bottom: var(--inset); width: var(--panel-w); z-index: 15; display: flex; flex-direction: column; border-radius: var(--r-lg); overflow: hidden; border: 1px solid var(--glass-line); box-shadow: var(--glass-highlight), var(--shadow); background: var(--glass-bg-strong); animation: panel-in var(--dur) var(--ease); }
html.no-blur .mode-panel { background: var(--glass-solid); }
body:not(.has-sidebar):not(.has-cmty) .mode-panel { display: none; }
@keyframes panel-in { from { transform: translateX(16px); opacity: 0; } to { transform: none; opacity: 1; } }
.mode-panel[data-show="cmty"] #sidebar, .mode-panel[data-show="sidebar"] #cmty { display: none !important; }
.mode-panel > .sidebar, .mode-panel > .cmty { position: static; inset: auto; width: auto; height: auto; max-height: none; flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; background: none; border: 0; border-radius: 0; box-shadow: none; backdrop-filter: none; -webkit-backdrop-filter: none; animation: none; z-index: auto; }
.sidebar__handle, .cmty__handle { display: none; }
/* glass header, strong-glass body */
.sidebar__tabs, .cmty__head { flex: 0 0 auto; background: var(--glass-bg); border-bottom: 1px solid var(--glass-line); backdrop-filter: blur(var(--glass-blur)) saturate(140%); -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(140%); }
html.no-blur .sidebar__tabs, html.no-blur .cmty__head { background: transparent; backdrop-filter: none; -webkit-backdrop-filter: none; }
.sidebar__tabs { padding: 10px 8px; }
.sidebar__tabs .tab { font-size: 12.5px; }
.cmty__head { padding: 12px 12px 12px 16px; }
.cmty__tabs { flex: 0 0 auto; }
.panel, .cmty__body { scrollbar-width: thin; scrollbar-color: rgba(255,255,255,.2) transparent; }
.panel__title { font-size: 18px; }

/* ============================================================ */
/* FLOATING CARDS · HUDs · LEGENDS                                */
/* ============================================================ */
.detail { position: absolute; z-index: 14; left: var(--inset); top: calc(var(--strip-h) + var(--inset)); width: var(--tile-w); max-width: var(--tile-w); max-height: calc(100% - var(--strip-h) - var(--inset) * 3 - var(--scrub-h)); overflow-y: auto; overflow-x: hidden; scrollbar-width: thin; padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 12px; background: var(--glass-bg-strong); border: 1px solid var(--glass-line); border-radius: var(--r-lg); box-shadow: var(--glass-highlight), var(--shadow); animation: rise .3s var(--ease); transition: transform var(--dur) var(--ease); }
html.no-blur .detail { background: var(--glass-solid); }
.detail__handle { display: none; }
/* Desktop: the route detail takes over the left column (same width as the ski-area tiles). The tiles hide while a
   route is open and come back when it closes. Nothing may overflow sideways: the head stacks title over a 4-up button
   row that spans exactly the panel width, and the close cross sits in the panel's top-right corner. */
body.has-detail .tiles { display: none; }
.detail__title { font-size: 17px; }
.detail__body { grid-template-columns: 1fr; }
.detail__head { flex-direction: column; align-items: stretch; gap: 10px; }
.detail__head > div:first-child { padding-right: 36px; min-width: 0; }
.detail__title, .detail__meta { overflow-wrap: anywhere; }
.detail__actions { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; width: 100%; }
.detail__actions .btn { min-width: 0; padding: 0 6px; font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.detail__actions #dClose { position: absolute; top: 12px; right: 12px; width: 30px; height: 30px; }
.stat, .profile { background: rgba(255,255,255,.06); border: 1px solid var(--glass-line); border-radius: var(--r-md); }
.legends { position: absolute; z-index: 12; right: calc(var(--inset) * 2 + 40px); bottom: calc(var(--inset) * 2 + var(--scrub-h)); display: flex; flex-direction: column; align-items: flex-end; gap: 8px; transition: right var(--dur) var(--ease); }
body:is(.has-sidebar, .has-cmty) .legends { right: calc(var(--inset) * 3 + var(--panel-w) + 40px); }
body.layers-open .legends { right: calc(var(--inset) * 2 + 40px + 300px + 8px); }
body.layers-open:is(.has-sidebar, .has-cmty) .legends { right: calc(var(--inset) * 3 + var(--panel-w) + 40px + 300px + 8px); }
.legend { background: var(--glass-bg-strong); border: 1px solid var(--glass-line); border-radius: var(--r-md); box-shadow: var(--glass-highlight), var(--shadow); }
html.no-blur .legend { background: var(--glass-solid); }
.flyhud, .cmty-hud, .rt-hud, .rec-pill { position: absolute; z-index: 18; left: 50%; top: calc(var(--strip-h) + var(--inset)); transform: translateX(-50%); display: flex; align-items: center; gap: 12px; padding: 6px 6px 6px 14px; border-radius: var(--r-pill); background: var(--glass-bg-strong); border: 1px solid var(--glass-line); box-shadow: var(--glass-highlight), var(--shadow); backdrop-filter: blur(var(--glass-blur)) saturate(140%); -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(140%); font-weight: 500; }
.flyhud__hint { font-size: 11px; color: var(--muted, #9aa); white-space: nowrap; opacity: .8; }
.flyhud__hint:empty { display: none; }
html.no-blur :is(.flyhud, .cmty-hud, .rt-hud, .rec-pill) { background: var(--glass-solid); backdrop-filter: none; -webkit-backdrop-filter: none; }
.rec-pill { display: none; }
.toast { position: absolute; z-index: 30; left: 50%; bottom: calc(var(--inset) * 2 + var(--scrub-h) + 8px); transform: translateX(-50%); padding: 10px 16px; background: var(--text); color: var(--glass-solid); border-radius: var(--r-pill); font-weight: 500; box-shadow: var(--shadow); max-width: min(90vw, 480px); text-align: center; text-shadow: none; }
.globehint { position: absolute; left: 50%; bottom: calc(var(--inset) * 2 + var(--scrub-h) + 8px); transform: translateX(-50%); z-index: 6; display: flex; align-items: center; gap: 10px; padding: 10px 16px; border-radius: var(--r-pill); background: var(--glass-bg-strong); border: 1px solid var(--glass-line); backdrop-filter: blur(var(--glass-blur)) saturate(140%); -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(140%); color: var(--text-2); font-size: 13px; white-space: nowrap; pointer-events: none; animation: hintIn .8s .6s both cubic-bezier(.2, .8, .2, 1); transition: opacity .45s ease, transform .45s ease; }
.globehint__k { font-family: var(--font-display); color: var(--accent); }
.modal { background: var(--glass-solid); border-radius: var(--r-lg); }

/* ============================================================ */
/* POPOVERS                                                       */
/* ============================================================ */
.popover { position: absolute; z-index: 40; padding: 12px 14px; font-size: 13px; }
.appearance { width: 260px; top: calc(var(--strip-h) + 8px); right: var(--inset); animation: pop-in var(--dur) var(--ease); }
@keyframes pop-in { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }
.pop-head { display: flex; align-items: center; justify-content: space-between; margin: -4px -6px 6px 0; }
.pop-group { padding: 8px 0; border-top: 1px solid var(--glass-line); display: flex; flex-direction: column; gap: 8px; }
.pop-row { flex-direction: row; align-items: center; justify-content: space-between; }
.pop-label { font-size: 13px; color: var(--text-2); }
.pop-note { font-size: 12px; color: var(--muted); padding-top: 6px; border-top: 1px solid var(--glass-line); }
.pop-select { height: 30px; max-width: 150px; padding: 0 28px 0 10px; border-radius: var(--r-pill); border: 1px solid var(--glass-line-strong); background: rgba(255,255,255,.08) url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23c9d3da' stroke-width='2'><path d='M6 9l6 6 6-6'/></svg>") no-repeat right 8px center / 14px; color: var(--text); font: inherit; font-size: 12.5px; appearance: none; -webkit-appearance: none; cursor: pointer; }
.pop-select:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.pop-select option { background: #131a21; color: #e8eef2; }
.swatches { display: flex; gap: 8px; }
.sw { width: 32px; height: 32px; border-radius: 50%; background: var(--sw); border: 2px solid transparent; box-shadow: 0 0 0 1px rgba(0,0,0,.25) inset; position: relative; }
.sw::before { content: ""; position: absolute; inset: -6px; }
.sw.active { border-color: var(--text); box-shadow: 0 0 0 2px var(--sw); }
.pseg { display: flex; border: 1px solid var(--glass-line-strong); border-radius: var(--r-pill); padding: 2px; }
.pseg button { flex: 1 1 0; height: 28px; border-radius: var(--r-pill); font-size: 12px; font-weight: 500; color: var(--text-2); }
.pseg button.active { background: var(--accent-soft); color: var(--text); }
.switch { width: 44px; height: 26px; border-radius: 13px; background: rgba(255,255,255,.14); border: 1px solid var(--glass-line-strong); position: relative; transition: background var(--dur) var(--ease); }
.switch span { position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: var(--text); transition: transform var(--dur) var(--ease); }
.switch[aria-checked="true"] { background: var(--accent); border-color: var(--accent); }
.switch[aria-checked="true"] span { transform: translateX(18px); background: var(--accent-ink); }
.attribution { max-width: 360px; font-size: 12px; line-height: 1.5; color: var(--text-2); padding: 10px 14px; bottom: calc(var(--inset) + var(--scrub-h) + 8px); left: 50%; transform: translateX(calc(-50% + 260px)); }

/* ============================================================ */
/* DESKTOP-ONLY BITS                                              */
/* ============================================================ */
@media (min-width: 861px) {
  .strip .strip-search { background: none; border: 1px solid transparent; box-shadow: none; backdrop-filter: none; -webkit-backdrop-filter: none; }
  .strip .strip-search:hover { border-color: var(--glass-line); }
  .strip .strip-search:focus-within { width: 300px; border-color: var(--glass-line-strong); color: var(--text); }
  .strip .dock { background: none; border: 0; box-shadow: none; backdrop-filter: none; -webkit-backdrop-filter: none; border-radius: 0; padding: 0; }
  .dock-slot--m { display: none; }
  .appearance-btn { background: none; border: 0; box-shadow: none; backdrop-filter: none; -webkit-backdrop-filter: none; }
  .wxchip { background: none; border: 0; box-shadow: none; backdrop-filter: none; -webkit-backdrop-filter: none; padding: 0; height: auto; border-radius: 0; }
  .sheet-handle { display: none !important; }
  .cards { display: none !important; }
  .has-info .maplibregl-ctrl-bottom-right { bottom: 0; }
}
@media (min-width: 861px) and (max-width: 1180px) {
  .strip-item--sun, .strip-item--sun + .strip-sep, .strip-sep--wx { display: none; }
  .place { max-width: 140px; }
}
@media (min-width: 861px) and (max-width: 1000px) {
  .strip-item--time, .strip-item--time + .strip-sep { display: none; }
  .strip-search { width: 180px; }
}

/* ============================================================ */
/* MOBILE · FLOATING ISLANDS (≤ 860px, matches app.js isMobile)   */
/* ============================================================ */
@media (max-width: 860px) {
  :root { --tile-w: 100%; --panel-w: 100%; }
  /* the strip becomes an invisible frame; its children are the islands */
  :root { --dock-clear: calc(var(--dock-h) + var(--inset) * 2 + env(safe-area-inset-bottom, 0px)); }
  .strip, html.no-blur .strip { inset: 0; height: auto; padding: 0; background: none; border: 0; box-shadow: none; backdrop-filter: none; -webkit-backdrop-filter: none; pointer-events: none; display: block; }
  .strip > * { pointer-events: auto; }
  .strip-sep, .strip-spacer, .brand, .strip-item--place, .strip-item--time, .strip-item--sun { display: none !important; }
  /* capsule */
  .strip-search { position: absolute; top: calc(var(--inset) + env(safe-area-inset-top, 0px)); left: var(--inset); right: calc(var(--inset) + 44px + 8px); width: auto; height: 44px; padding: 0 14px; gap: 10px; }
  .strip-search .strip-search__ic { width: 18px; height: 18px; }
  .strip-search input { font-size: 14px; }
  /* avatar + appearance stacked at the top-right */
  .cmty-bar { position: absolute; top: calc(var(--inset) + env(safe-area-inset-top, 0px)); right: var(--inset); flex-direction: column; gap: 8px; }
  .cmty-bar__btn--av { width: 44px; height: 44px; padding: 0; justify-content: center; font-size: 13px; background: var(--glass-bg); border: 1px solid var(--glass-line); box-shadow: var(--glass-highlight), var(--shadow); backdrop-filter: blur(var(--glass-blur)) saturate(140%); -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(140%); }
  html.no-blur .cmty-bar__btn--av { background: var(--glass-solid); backdrop-filter: none; -webkit-backdrop-filter: none; }
  .cmty-bar__btn--av .cmty-bar__txt { display: none; }
  .cmty-bar__btn--av svg { width: 20px; height: 20px; }
  .cmty-bar__btn--av .cmty-av { width: 32px; height: 32px; font-size: 13px; }
  .appearance-btn { width: 44px; height: 44px; }
  .appearance-btn .ic { width: 18px; height: 18px; }
  /* conditions chip */
  /* the EAWS/weather chip does not exist on phones — the Area info cards carry the same data */
  .wxchip, .strip-sep--wx { display: none !important; }
  .wxchip { position: absolute; top: calc(var(--inset) + 44px + 8px + env(safe-area-inset-top, 0px)); left: var(--inset); height: 32px; z-index: 15; border-radius: var(--r-pill); padding: 0 12px; gap: 8px; font-size: 13px; max-width: calc(100vw - var(--inset) * 2 - 52px); background: var(--glass-bg); border: 1px solid var(--glass-line); box-shadow: var(--glass-highlight), var(--shadow); backdrop-filter: blur(var(--glass-blur)) saturate(140%); -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(140%); }
  html.no-blur .wxchip { background: var(--glass-solid); backdrop-filter: none; -webkit-backdrop-filter: none; }
  body:not(.has-info) .wxchip .mono, body:not(.has-info) .wxchip .dot { display: none; }
  .wxchip .ic { display: none; }
  .wxchip::before { content: ""; position: absolute; inset: -6px 0; }
  /* dock */
  .dock { position: absolute; bottom: calc(var(--inset) + env(safe-area-inset-bottom, 0px)); left: 50%; transform: translateX(-50%); height: var(--dock-h); padding: 4px; border-radius: var(--r-pill); display: flex; gap: 0; z-index: 20; transition: transform var(--dur) var(--ease), opacity var(--dur) var(--ease); }
  .dock-slot { width: 48px; height: 48px; }
  .dock-slot .ic { width: 22px; height: 22px; }
  .dock-slot[data-mode="record"] .ic { width: 24px; height: 24px; }

  /* side pill = the tool rail */
  .tools { right: var(--inset); top: 50%; width: 40px; }
  body:is(.has-sidebar, .has-cmty) .tools { right: var(--inset); }
  .tool { width: 36px; height: 36px; }
  /* a tall sheet owns the screen: the map furniture fades; a peeking sheet (collapsed routes / low tiles) keeps it */
  body.sheet-full .tools, body.sheet-full .legends, body.sheet-full .cards, body.sheet-full .wxchip, body.sheet-full .globehint { opacity: 0; pointer-events: none; }
  body.sheet-open .cards { display: none; }
  .tools, .legends, .cards, .wxchip, .cmty-bar { transition: opacity var(--dur) var(--ease); }
  body:is(.sheet-open, .has-detail) .cmty-bar { opacity: 0; pointer-events: none; }
  body:is(.sheet-open, .has-detail) .appearance { display: none; }
  /* every sheet's close X: 44px hit area, above the sheet's own content */
  .tiles .info__close, #sidebarClose, #cmtyClose, #dClose { width: 44px; height: 44px; flex: none; position: relative; z-index: 30; color: var(--text); background: rgba(255,255,255,.08); border: 1px solid var(--glass-line); }
  .tiles .info__close svg, #sidebarClose svg, #cmtyClose svg, #dClose svg { width: 18px; height: 18px; }
  .tiles .info__close::before, #sidebarClose::before, #cmtyClose::before, #dClose::before { content: ""; position: absolute; inset: -6px; }
  .pop { right: calc(var(--inset) + 40px + 8px); width: min(300px, calc(100vw - 80px)); max-height: calc(100% - 140px - var(--dock-h)); }
  body:is(.has-sidebar, .has-cmty) .pop { right: calc(var(--inset) + 40px + 8px); }
  .scrubber-row { display: none; }

  /* conditions cards, bottom-left above the dock (shell.js fills them) */
  .cards { display: flex; position: absolute; left: var(--inset); bottom: var(--dock-clear); z-index: 12; width: 280px; max-width: calc(100vw - var(--inset) * 2 - 64px); flex-direction: column; gap: 8px; align-items: flex-start; }
  .cards-extra { display: flex; flex-direction: column; gap: 8px; width: 100%; }
  .card { width: 100%; min-height: 56px; padding: 9px 14px; display: flex; flex-direction: column; gap: 2px; text-align: left; border-radius: var(--r-lg); color: var(--text); }
  .card-title { display: inline-flex; align-items: center; gap: 8px; font-family: var(--font-display); font-weight: 600; font-size: 14px; line-height: 1.2; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .card-title .micro { color: var(--accent); }
  .card-detail { font-size: 12px; color: var(--text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
  .more-chip { height: 36px; padding: 0 14px 0 12px; border-radius: var(--r-pill); font-size: 12.5px; font-weight: 500; color: var(--accent); position: relative; display: inline-flex; align-items: center; gap: 6px; }
  .more-chip::before { content: ""; position: absolute; inset: -6px 0; }
  .more-chip .ic { width: 16px; height: 16px; }
  .more-chip[aria-expanded="true"] { color: var(--text); background: var(--accent-soft); }
  .cards.is-open { max-height: calc(100vh - var(--dock-clear) - 120px - env(safe-area-inset-top, 0px)); }
  .cards-extra { max-height: calc(100vh - var(--dock-clear) - 170px - env(safe-area-inset-top, 0px)); overflow-y: auto; scrollbar-width: none; padding: 2px; margin: -2px; }
  .cards-extra__head { display: flex; align-items: center; justify-content: space-between; padding: 0 0 0 4px; }
  .cards-extra__head .micro { color: var(--text-2); font-size: 11px; letter-spacing: .12em; text-transform: uppercase; }
  .cards-x { width: 44px; height: 44px; border-radius: var(--r-pill); display: grid; place-items: center; color: var(--text); background: var(--glass-bg-strong); border: 1px solid var(--glass-line); box-shadow: var(--glass-highlight), var(--shadow); position: relative; z-index: 2; }
  .cards-x .ic { width: 18px; height: 18px; }
  body.has-detail .cards { display: none; }

  /* sheets: the tiles column (Explore) and the mode panel share one recipe */
  .sheet-handle, .sidebar__handle.sheet-handle, .cmty__handle.sheet-handle { display: flex !important; height: 24px; align-items: center; justify-content: center; cursor: grab; flex: 0 0 auto; position: relative; width: auto; margin: 0; background: none; touch-action: none; user-select: none; -webkit-user-select: none; }
  .sheet-handle:active { cursor: grabbing; }
  .sheet-handle::before { content: ""; position: absolute; inset: -10px 0 0 0; }
  .sheet-handle span { width: 40px; height: 4px; border-radius: 2px; background: var(--glass-line-strong); display: block; }
  /* sheets float as cards ABOVE the dock (height-snapped, not translated) so sheet content is never covered by the dock */
  .tiles, .mode-panel { position: absolute; left: var(--inset); right: var(--inset); bottom: var(--dock-clear); top: auto; width: auto; height: var(--sheet-h, 60vh); max-height: calc(100vh - var(--dock-clear) - var(--inset) * 2 - 44px - 8px - env(safe-area-inset-top, 0px)); z-index: 18; border-radius: var(--r-xl); border: 1px solid var(--glass-line); box-shadow: var(--glass-highlight), var(--shadow); background: var(--glass-bg-strong); display: flex; flex-direction: column; gap: 0; overflow: hidden; padding: 0; transform: none; transition: height 260ms var(--ease); animation: none; }
  html.no-blur .tiles, html.no-blur .mode-panel { background: var(--glass-solid); }
  /* mobile sheets sit over busy map labels: denser tint so text stays legible */
  .tiles, .mode-panel { background: rgba(12, 18, 26, 0.88); }
  html[data-glass="clear"] .tiles, html[data-glass="clear"] .mode-panel { background: rgba(20, 26, 34, 0.90); }
  html[data-glass="cool"] .tiles, html[data-glass="cool"] .mode-panel { background: rgba(14, 22, 48, 0.88); }
  .tiles.dragging, .mode-panel.dragging { transition: none; }
  .tiles:not(.is-sheet) { display: none; }
  .tiles.is-sheet { --sheet-h: 60vh; }
  .tiles.is-sheet[data-snap="30"] { --sheet-h: 30vh; }
  .tiles.is-sheet[data-snap="92"] { --sheet-h: 100vh; }
  .mode-panel { --sheet-h: 60vh; }
  .mode-panel[data-snap="30"] { --sheet-h: 30vh; }
  .mode-panel[data-snap="92"] { --sheet-h: 100vh; }
  body:not(.has-sidebar):not(.has-cmty) .mode-panel { display: none; }
  .tiles__handle { order: -2; }
  .tiles__body { display: contents; }
  /* inside the tiles sheet, tiles lose their float and become a list */
  .tiles .tile, .tiles .info__head, .tiles .isec, .tiles .info-open { margin: 0 12px; box-shadow: none; }
  .tiles .info__head { order: -1; border: 0; border-radius: 0; background: none; backdrop-filter: none; -webkit-backdrop-filter: none; padding: 4px 16px 10px; margin: 0; border-bottom: 1px solid var(--glass-line); }
  .tiles .tile--ph { display: none; }
  .tiles .isec { margin-top: 8px; }
  .tiles .isec:last-child { margin-bottom: 12px; }
  .tiles > .isec-scroll { flex: 1 1 auto; overflow-y: auto; }
  .tiles.is-sheet { overflow-y: auto; scrollbar-width: none; }
  .info__body { display: contents; }
  .info__title { font-size: 17px; }
  /* mode panel children on phones */
  .mode-panel > .sidebar, .mode-panel > .cmty { height: auto; max-height: none; }
  .sidebar.is-collapsed .panel { visibility: hidden; }
  .mode-panel:has(> .sidebar.is-collapsed:not([hidden])) { --sheet-h: 150px; }
  .mode-panel:has(> .sidebar.is-expanded:not([hidden])) { --sheet-h: 100vh; }
  .sidebar__close { display: grid; margin-left: auto; }
  .sidebar__tabs { overflow-x: auto; scrollbar-width: none; gap: 0; padding-right: 8px; }
  .sidebar__tabs::-webkit-scrollbar { display: none; }
  .panel, .cmty__body { padding-bottom: 12px; }

  /* floating cards */
  /* Mobile: route detail becomes a bottom sheet with a grey drag-handle at the top.
     Users can drag it down to peek at the map underneath, or fling it away to close. */
  /* The bottom dock (mode island) hides while a route is open, so the sheet sits right at the bottom edge and takes
     less of the screen; the right-hand tools island moves up out from under the sheet. */
  :root { --detail-clear: calc(var(--inset) + env(safe-area-inset-bottom, 0px)); }
  body.has-detail .dock { opacity: 0; pointer-events: none; transform: translate(-50%, 24px); }
  .dock { transition: opacity var(--dur) var(--ease), transform var(--dur) var(--ease); }
  body.has-detail .tools { top: calc(var(--strip-h) + var(--inset) * 2 + env(safe-area-inset-top, 0px)); transform: none; }
  body.has-detail:has(.detail[data-snap="92"]) .tools { opacity: 0; pointer-events: none; }
  .detail { left: var(--inset); right: var(--inset); bottom: var(--detail-clear); top: auto; width: auto; max-width: none;
    height: var(--detail-h, 50vh); max-height: calc(100vh - var(--detail-clear) - var(--inset) - 44px - 8px - env(safe-area-inset-top, 0px));
    padding: 0 12px 12px; margin: 0; z-index: 19;
    display: flex; flex-direction: column; gap: 10px; overflow: hidden;
    transition: height 260ms var(--ease); }
  .detail > :not(.detail__handle) { flex: 0 0 auto; }
  .detail__head { overflow: visible; }
  /* the body is the one flex child allowed to shrink, so it scrolls inside the sheet instead of being clipped */
  .detail > .detail__body { flex: 1 1 auto; min-height: 0; overflow-y: auto; overflow-x: hidden; -webkit-overflow-scrolling: touch; overscroll-behavior: contain; scrollbar-width: thin; padding-bottom: 8px; }
  .detail__head { flex-direction: column; align-items: stretch; gap: 8px; }
  .detail__head > div:first-child { padding-right: 36px; }
  .detail__actions { display: flex; gap: 8px; width: auto; }
  .detail__actions .btn { font-size: 13px; padding: 0 12px; }
  .detail__actions #dClose { top: 22px; right: 12px; }
  body:is(.has-sidebar, .has-cmty) .detail { right: var(--inset); }
  /* the tiles/mode sheet still wins when fully open — but the detail sheet is now sibling, not covered. */
  body.sheet-full .detail { display: none; }
  .detail[data-snap="30"] { --detail-h: 30vh; }
  .detail[data-snap="60"] { --detail-h: 50vh; }
  .detail[data-snap="92"] { --detail-h: calc(100vh - var(--detail-clear) - var(--inset) - 44px - env(safe-area-inset-top, 0px)); }
  .detail.dragging { transition: none; height: var(--sheet-h, var(--detail-h, 60vh)); }
  .detail__handle { display: flex !important; order: -1; height: 24px; align-items: center; justify-content: center; cursor: grab; flex: 0 0 auto; position: relative; width: auto; margin: 0 -12px 2px; background: none; border: 0; touch-action: none; user-select: none; -webkit-user-select: none; padding: 0; }
  .detail__handle:active { cursor: grabbing; }
  .detail__handle::before { content: ""; position: absolute; inset: -10px 0 0 0; }
  .detail__handle span { width: 40px; height: 4px; border-radius: 2px; background: var(--glass-line-strong, rgba(255,255,255,.35)); display: block; }
  body.has-detail .tiles { max-height: none; }
  /* Mobile: while a route detail sheet is open, the Routes/Community/Record/Trips sheet and its dock must fully
     hide behind it, otherwise the mode panel bleeds through the detail card. Reopens when the detail X is
     tapped (JS restores the previous sidebar state); a pull-down close does NOT reopen it. */
  body.has-detail .mode-panel { display: none; }
  /* Single-column stack on phones: force EVERY direct child of .detail__body to occupy the one column,
     including the .profile chart and .stats grid. Without this the profile ends up in an implicit second
     column and paints over the source text/Add-to-my-list block above it. */
  .detail__body { display: flex; flex-direction: column; gap: 10px; }
  .detail__body > * { min-width: 0; width: 100%; grid-column: 1 / -1; }
  .detail .stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
  /* the flex parent doesn't stretch children by default; give the profile block a real height
     so the canvas actually renders and the elevation graph sits between stats and source. */
  .detail .profile { margin: 0; height: 110px; flex: 0 0 auto; }
  .detail .profile canvas { width: 100%; height: 110px; display: block; }
  .detail__extras { gap: 10px; }
  /* the Add-to-my-list row sits in its own block, safely below the elevation profile */
  .detail__extras .rt-block--lists { flex-direction: column; align-items: stretch; gap: 8px; }
  .detail__extras .rt-block--lists .btn, .detail__extras .rt-block--lists .rt-select { width: 100%; max-width: none; }
  .detail__extras .rt-block--lists .rt-vis { margin-left: 0; }
  .detail__actions .btn--ghost { display: none; }
  .legends { right: var(--inset); bottom: calc(var(--inset) * 2 + var(--dock-h) + env(safe-area-inset-bottom, 0px)); flex-direction: row; flex-wrap: wrap-reverse; justify-content: flex-end; align-items: flex-end; gap: 6px; max-width: calc(100vw - 16px); }
  body:is(.has-sidebar, .has-cmty) .legends, body.layers-open .legends, body.layers-open:is(.has-sidebar, .has-cmty) .legends { right: var(--inset); }
  /* the layers popover covers most of a phone screen: legends re-appear as soon as it closes */
  body.layers-open .legends { opacity: 0; pointer-events: none; }
  .legend { padding: 7px 9px; font-size: 10px; min-width: 128px; max-width: 160px; gap: 3px; max-height: max(140px, calc(100vh - 470px)); overflow-y: auto; }
  .legend .hint { display: none; }
  .flyhud, .cmty-hud, .rt-hud, .rec-pill { top: calc(var(--inset) + 44px + 8px + 32px + 8px + env(safe-area-inset-top, 0px)); font-size: 12px; gap: 6px; padding: 6px 6px 6px 12px; max-width: calc(100vw - 24px); }
  .rec-pill:not([hidden]) { display: flex; }
  .toast { bottom: calc(var(--inset) * 2 + var(--dock-h) + 8px + env(safe-area-inset-bottom, 0px)); }
  .globehint { bottom: calc(var(--inset) * 2 + var(--dock-h) + 8px + env(safe-area-inset-bottom, 0px)); flex-direction: column; gap: 2px; text-align: center; font-size: 12.5px; padding: 10px 14px; max-width: 78vw; white-space: normal; border-radius: 14px; }
  .appearance { top: calc(var(--inset) + 44px + 8px + env(safe-area-inset-top, 0px)); right: var(--inset); width: min(260px, calc(100vw - 24px)); }
  .attribution { left: var(--inset); right: var(--inset); bottom: calc(var(--inset) * 2 + var(--dock-h) + env(safe-area-inset-bottom, 0px)); transform: none; max-width: none; }
  .search__results { position: fixed; left: var(--inset); right: var(--inset); top: calc(var(--inset) + 44px + 8px + env(safe-area-inset-top, 0px)); }
  .maplibregl-ctrl-bottom-right { bottom: calc(var(--inset) + var(--dock-h) + 8px); }
  .has-info .maplibregl-ctrl-bottom-left, .has-info .maplibregl-ctrl-bottom-right { bottom: calc(var(--inset) + var(--dock-h) + 8px); }
}

/* ---------- motion ---------- */
@media (prefers-reduced-motion: reduce) {
  .tiles, .mode-panel, .dock, .tools, .detail, .legends { transition: none !important; animation: none !important; }
}

/* Recent disasters — expandable avalanche incident rows */
.inclist { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.inc { border-left: 2px solid var(--line-strong); padding-left: 10px; }
.inc--fatal { border-left-color: #ff6b7a; }
.inc.is-open { border-left-color: var(--accent); }
.inc__head { all: unset; display: flex; flex-direction: column; gap: 2px; width: 100%; cursor: pointer; font: inherit; color: var(--text); padding: 2px 0; -webkit-tap-highlight-color: transparent; }
.inc__head:hover .inc__t, .inc__head:focus-visible .inc__t { color: var(--accent); }
.inc__head:focus-visible { outline: 1px solid var(--accent); outline-offset: 2px; border-radius: 4px; }
.inc__t { font-size: 12.5px; line-height: 1.35; }
.inc__t em { font-style: normal; color: var(--accent); font-weight: 600; }
.inc__s { font-size: 11.5px; color: var(--muted); line-height: 1.35; }
.inc__s b { color: #ff6b7a; font-weight: 600; }
.inc__body { padding: 6px 0 4px; }
.inc__grid { display: grid; grid-template-columns: minmax(84px, auto) 1fr; gap: 3px 10px; font-size: 12px; line-height: 1.4; }
.inc__k { color: var(--muted); }
.inc__v { color: var(--text); overflow-wrap: anywhere; }
.inc__src { display: inline-block; margin-top: 8px; font-size: 12px; color: var(--accent); text-decoration: none; }
.inc__src:hover { text-decoration: underline; }
