/* Route heatmap (heatmap-ui.js): preview card on Activities + the map sheet. */
.hx-card { display: block; width: 100%; margin: 14px 0 4px; padding: 0; border: 0; border-radius: 20px; overflow: hidden; background: var(--n-hero, #16181b); box-shadow: 0 16px 32px -18px rgba(17, 18, 20, 0.7); color: #f4f5f6; text-align: left; font: inherit; cursor: pointer; }
.hx-prev { position: relative; height: 150px; background:
  radial-gradient(120% 90% at 50% 40%, rgba(var(--acc-400-rgb), 0.10), transparent 70%), #121417; }
.hx-prev-svg { width: 100%; height: 100%; display: block; }
.hx-prev-svg path { fill: none; stroke: var(--acc-400); stroke-width: 1.3; stroke-opacity: 0.32; stroke-linecap: round; stroke-linejoin: round; filter: drop-shadow(0 0 3px rgba(var(--acc-400-rgb), 0.45)); }
.hx-prev-empty { position: absolute; inset: 0; background: repeating-linear-gradient(135deg, rgba(255,255,255,.03) 0 10px, transparent 10px 20px); }
.hx-card-row { display: flex; align-items: center; gap: 10px; padding: 12px 16px 14px; border-top: 1px solid rgba(255, 255, 255, 0.06); }
.hx-card-row > div { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.hx-card-row b { font-size: 15px; font-weight: 600; }
.hx-card-row span { font-size: 12px; color: #c9ccd1; }
.hx-chev { width: 18px; height: 18px; fill: none; stroke: #c9ccd1; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

.hx-chips { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; margin: 0 0 10px; }
.hx-chips:empty { display: none; }
.hx-chip { flex-shrink: 0; height: 32px; padding: 0 13px; border-radius: 999px; border: 1px solid var(--border); background: var(--panel); color: var(--text); font: inherit; font-size: 13px; font-weight: 600; cursor: pointer; }
.hx-chip.on { background: var(--text); color: var(--bg, #fff); border-color: var(--text); }
.hx-seg { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: 4px; padding: 4px; border-radius: 999px; background: var(--panel-2); margin-bottom: 12px; }
.hx-seg button { height: 32px; border-radius: 999px; border: 0; background: transparent; font: inherit; font-size: 13px; font-weight: 600; color: var(--muted); cursor: pointer; }
.hx-seg button.on { background: var(--panel); color: var(--text); box-shadow: 0 1px 2px rgba(var(--n-ink-rgb), 0.08); }

.hx-mapwrap { position: relative; border-radius: 20px; overflow: hidden; box-shadow: var(--u-card, 0 1px 3px rgba(0,0,0,.08)); }
.hx-map { height: min(58vh, 520px); min-height: 300px; background: var(--panel-2); touch-action: none; }
.hx-map .leaflet-control-zoom { border: 0; box-shadow: 0 2px 8px rgba(0,0,0,.18); border-radius: 12px; overflow: hidden; }
.hx-map .leaflet-control-zoom a { width: 34px; height: 34px; line-height: 34px; background: var(--panel); color: var(--text); border-color: var(--border); }
.hx-fit { position: absolute; top: 10px; left: 10px; z-index: 500; display: flex; gap: 2px; padding: 3px; border-radius: 999px; background: color-mix(in srgb, var(--panel) 88%, transparent); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); box-shadow: 0 2px 10px rgba(0,0,0,.16); }
.hx-fit button { height: 28px; padding: 0 12px; border-radius: 999px; border: 0; background: transparent; font: inherit; font-size: 12px; font-weight: 600; color: var(--muted); cursor: pointer; }
.hx-fit button.on { background: var(--text); color: var(--panel); }
.hx-map-note { position: absolute; left: 50%; bottom: 14px; transform: translateX(-50%); z-index: 500; max-width: 86%; padding: 8px 14px; border-radius: 999px; background: color-mix(in srgb, var(--panel) 92%, transparent); box-shadow: 0 2px 10px rgba(0,0,0,.16); font-size: 12.5px; font-weight: 600; text-align: center; }

.hx-sel { display: flex; align-items: center; gap: 10px; min-height: 52px; margin: 10px 0; padding: 8px 8px 8px 14px; border-radius: 16px; background: var(--panel-2); }
.hx-sel > .muted { padding: 0 2px; }
.hx-sel-t { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.hx-sel-t b { font-size: 14px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hx-sel-t span { font-size: 12px; color: var(--muted); }
.hx-sel-btn { height: 34px; padding: 0 14px; border-radius: 999px; border: 0; background: var(--text); color: var(--panel); font: inherit; font-size: 13px; font-weight: 600; cursor: pointer; }
.hx-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.hx-stats > div { display: flex; flex-direction: column; gap: 2px; padding: 12px; border-radius: 16px; background: var(--panel); box-shadow: var(--u-card, 0 1px 3px rgba(0,0,0,.08)); }
.hx-stats b { font-size: 20px; font-weight: 700; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.hx-stats span { font-size: 11.5px; color: var(--muted); font-weight: 500; }
.hx-foot { margin: 12px 2px 4px; line-height: 1.5; }
.view-sheet-body > .vs-content > .hx-sheet { padding-right: 0; }
.hx-sheet > .vs-head { padding-right: 50px; }

/* OpenStreetMap tiles, muted so the routes stand out; inverted in dark mode. */
.hx-tiles { filter: grayscale(.85) brightness(1.04) contrast(.9); }
:root[data-theme="dark"] .hx-tiles { filter: grayscale(1) invert(1) brightness(.78) contrast(.92); }
#hxMap .leaflet-control-attribution { font-size: 9.5px; background: rgba(255, 255, 255, .7); padding: 0 5px; border-radius: 6px 6px 6px 0; margin: 0; }
:root[data-theme="dark"] #hxMap .leaflet-control-attribution { background: rgba(0, 0, 0, .55); color: #aaa; }
:root[data-theme="dark"] #hxMap .leaflet-control-attribution a { color: #ccc; }
