/* Radio Greensboro — site styles. Sections: tokens, shell, player bar, about, map, scanner, advanced. */
:root {
  --bg: #0f1216; --panel: #161b21; --panel2: #1c232b; --line: #2a333d; --text: #dde3ea; --muted: #8794a3;
  --accent: #4ea1ff; --priority: #fe6a04; --fire: #e91922; --ems: #fec109; --police: #226bdc; --traffic: #8235d1;   /* rob's palette, 10-25 (~rob/colors.jpg) */
  --air: #5eead4; --other: #8794a3; --ok: #4cc38a; --bad: #ff5d5d;
  --hdr: 104px;   /* the logo is 88px so its "RADIO GREENSBORO" stays readable */
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--text); font: 14px/1.45 Inter, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; }
body { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; }
a { color: var(--accent); }
button, input, select { font: inherit; color: var(--text); background: var(--panel2); border: 1px solid var(--line); border-radius: 6px; padding: 5px 9px; }
button { cursor: pointer; }
button:hover { border-color: var(--accent); }
button:focus-visible, a:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.muted { color: var(--muted); }
[hidden] { display: none !important; }
.c-police, .f-police { --c: var(--police); } .c-fire, .f-fire { --c: var(--fire); } .c-ems, .f-ems { --c: var(--ems); }
.c-priority { --c: var(--priority); } .c-traffic { --c: var(--traffic); } .c-other, .f-other { --c: var(--other); }
.f-police, .f-fire, .f-ems, .f-other { color: var(--c); }

/* ---------------------------------------------------------------- shell */
header.site { display: flex; align-items: center; gap: 18px; padding: 8px 16px; background: #0b0e12; border-bottom: 1px solid var(--line); min-height: var(--hdr); }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--text); min-width: 0; }
.brand img.logo { width: 88px; height: 88px; flex: none; border-radius: 50%; }
.brand picture { display: flex; flex: none; }   /* (the logo's WebP wrapper: sized by its img) */
.brand b { display: block; font-size: 17px; font-weight: 800; letter-spacing: -.01em; }
.brand small { display: block; color: var(--muted); font-size: 12px; white-space: nowrap; }
nav.views { display: flex; gap: 4px; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 4px; }
nav.views a { text-decoration: none; color: var(--muted); padding: 10px 16px; border-radius: 9px; font-weight: 600; font-size: 15.5px;
  white-space: nowrap; display: inline-flex; align-items: center; gap: 8px; }
nav.views .ni { font-style: normal; font-size: 20px; line-height: 1; }
nav.views .ni img { width: 1.15em; height: 1.15em; display: block; }   /* sized like the emoji icons beside it */
nav.views a:hover { color: var(--text); }
nav.views a.on { background: var(--panel2); color: var(--text); box-shadow: inset 0 0 0 1px var(--line); }
.toplinks { margin-left: auto; display: flex; flex-direction: column; align-items: flex-end; gap: 4px;
  align-self: stretch; justify-content: space-between; }   /* links level with the top of the logo, Users online with its bottom (rob 10-26) */
/* Help | About: plain text, cleaner than buttons, with a bar between them (rob 11-02) */
nav.links { display: flex; align-items: center; gap: 10px; }
nav.links .sep { color: var(--muted); opacity: .55; font-size: 15px; }
/* A screenshot opened over the page (shell.js) */
.lightbox { position: fixed; inset: 0; z-index: 3100; display: flex; align-items: center; justify-content: center; cursor: zoom-out;
  background: rgba(5, 7, 10, .92); padding: max(56px, calc(env(safe-area-inset-top) + 48px)) 16px max(16px, env(safe-area-inset-bottom)); }
.lightbox img { max-width: 100%; max-height: 100%; object-fit: contain; border-radius: 8px; box-shadow: 0 8px 40px rgba(0, 0, 0, .6); }
.lb-x { position: absolute; top: max(10px, env(safe-area-inset-top)); right: 12px; width: 40px; height: 40px; border-radius: 50%; cursor: pointer;
  border: 1px solid var(--line); background: var(--panel2); color: var(--text); font-size: 26px; line-height: 1; }
.online { font-size: 12.5px; color: var(--muted); white-space: nowrap; display: flex; align-items: center; gap: 6px; }
.online[hidden] { display: none; }
.online b { color: var(--text); font-weight: 600; font-variant-numeric: tabular-nums; }
.online i { width: 7px; height: 7px; border-radius: 50%; background: #4cc38a; box-shadow: 0 0 6px #4cc38a; }
nav.links a { color: var(--muted); text-decoration: none; font-size: 15px; font-weight: 600; white-space: nowrap; }
nav.links a:hover, nav.links a.on { color: var(--text); }
main { flex: 1; min-height: 0; display: flex; flex-direction: column; }
.view { flex: 1; min-height: 0; }

/* ---------------------------------------------------------------- player bar */
.playerbar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; padding: 8px 16px; background: var(--panel); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 1010; }   /* (over Leaflet's controls, z-index 1000: the map credit showed through the 📍 and 🔔 menus, 11-02) */
.listen { display: inline-flex; align-items: center; gap: 8px; padding: 7px 16px; border-radius: 999px; font-weight: 700;
  background: #1f6f45; border-color: #2c8c5a; color: #fff; }
.listen:hover { border-color: #5fd69a; }
.listen.on { background: #3a2226; border-color: var(--bad); }
.listen .ic { width: 14px; text-align: center; }
.svc { display: flex; gap: 6px; flex-wrap: wrap; }
.svc button { border-radius: 999px; padding: 4px 12px; display: inline-flex; align-items: center; gap: 6px; }
.svc button i { width: 8px; height: 8px; border-radius: 50%; background: var(--c, var(--muted)); }
.s-police { --c: var(--police); } .s-fire { --c: var(--fire); } .s-ems { --c: var(--ems); } .s-air { --c: var(--air); } .s-all { --c: var(--ok); }
.svc button.on { background: #22303d; border-color: var(--c); }
.chips { display: flex; gap: 6px; flex-wrap: wrap; }
.chip { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; padding: 2px 4px 2px 9px; border-radius: 999px; border: 1px solid var(--line); background: var(--panel2); }
.chip button { padding: 0 6px; border: 0; background: transparent; font-size: 12px; }
.chip.zone { border-color: var(--ok); }
.where { position: relative; }
.where-btn { border-radius: 999px; white-space: nowrap; }
.where-btn.on { border-color: var(--ok); background: #183326; color: #d7f5e5; }
.where-menu { position: absolute; top: calc(100% + 6px); left: 0; z-index: 2000; width: 350px; padding: 10px; border-radius: 10px;
  background: var(--panel); border: 1px solid var(--line); box-shadow: 0 10px 30px rgba(0, 0, 0, .5); }
.wm-h { font-weight: 700; margin: 2px 4px 8px; }
.where-menu [data-where] { display: block; width: 100%; text-align: left; margin-bottom: 6px; padding: 8px 10px; border-radius: 8px; }
.where-menu [data-where] small { display: block; color: var(--muted); font-size: 12px; margin-top: 1px; }
.where-menu [data-where][aria-checked="true"] { border-color: var(--ok); background: #183326; }
.zonepin { font-size: 26px; line-height: 1; filter: drop-shadow(0 1px 2px rgba(0, 0, 0, .7)); cursor: move; }
.zonepin.mini { font-size: 18px; cursor: default; }
.wm-note { color: var(--muted); font-size: 12px; margin: 4px 4px 2px; }
/* Push alerts (push.py): the 🔔 button beside 📍 and its menu; lit in the priority color while alerts are on */
.alert-btn.on { border-color: var(--priority); background: color-mix(in srgb, var(--priority) 16%, var(--panel2)); }
.wm-sub { color: var(--muted); font-size: 12px; margin: 8px 4px 6px; }
.push-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.push-kind { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin-bottom: 8px; }
.pk { text-align: left; padding: 7px 9px; border-radius: 8px; }
.pk small { display: block; color: var(--muted); font-size: 11.5px; margin-top: 1px; }
.pk[aria-pressed="true"] { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 14%, var(--panel2)); }
.push-grid .push-opt { margin: 0; padding: 7px 9px; font-size: 13px; }
.push-opt { display: block; width: 100%; text-align: left; margin-bottom: 6px; padding: 8px 10px; border-radius: 8px; }
.push-opt small { display: block; color: var(--muted); font-size: 12px; margin-top: 1px; }
.push-opt[aria-pressed="true"] { border-color: var(--priority); background: color-mix(in srgb, var(--priority) 14%, var(--panel2)); }
.chip.hold { border-color: var(--ems); color: var(--ems); }
.chip.lo { border-color: var(--bad); color: var(--bad); padding-right: 9px; }
.np { flex: 1 1 140px; min-width: 0; display: flex;   /* (a 260 px basis put the bar at exactly 1180 px on an iPad Air in landscape: the volume wrapped, rob 11-03) */ align-items: center; gap: 8px; font-size: 13px; color: var(--muted);
  -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }   /* phones' font boosting sized long transcriptions bigger than short ones (rob 10-30; the ticker's fix) */
@media (max-width: 1060px) { .np { flex-basis: 400px; } }   /* (narrower: the line and the volume wrap to a second row together, not the volume alone) */
.np-text { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.np-run { display: inline-block; animation: npRun 8s linear infinite; }
@keyframes npRun { 0%, 15% { transform: none; } 85%, 100% { transform: translateX(var(--np-over, 0)); } }
@media (prefers-reduced-motion: reduce) { .np-run { animation: none; } }
.np-text .tr { color: var(--text); }
.cnote { opacity: .72; }   /* a 10-code's meaning after it in a transcript */
.eq { display: inline-flex; gap: 2px; align-items: flex-end; height: 14px; opacity: .25; }
.eq i { width: 3px; height: 14px; background: var(--ok); border-radius: 1px; transform: scaleY(.29); transform-origin: bottom; }
.playerbar.live .eq { opacity: .6; }
.playerbar.live.talking .eq { opacity: 1; }
.playerbar.live.talking .eq i { animation: eq .9s ease-in-out infinite; }
.playerbar.live.talking .eq i:nth-child(2) { animation-delay: .15s; } .playerbar.live.talking .eq i:nth-child(3) { animation-delay: .3s; } .playerbar.live.talking .eq i:nth-child(4) { animation-delay: .45s; }
@keyframes eq { 0%, 100% { transform: scaleY(.29); } 50% { transform: scaleY(1); } }
.vol { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); }
.vol input { width: 90px; padding: 0; accent-color: var(--accent); border: 0; background: none; }
@media (prefers-reduced-motion: reduce) { .playerbar.live.talking .eq i { animation: none; height: 10px; } }

/* ---------------------------------------------------------------- red ticker: priority incidents + squawks */
.ticker { background: rgba(233, 25, 34, .2); color: #fff; border-bottom: 1px solid rgba(233, 25, 34, .55); font-size: 13px; line-height: 1.3; overflow: hidden; white-space: nowrap;
  -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }   /* phones' font boosting blew up the long summary text */
.ticker .track { display: inline-flex; align-items: center; padding: 6px 16px; }
.ticker.scroll .track { padding-left: 0; animation: tick var(--dur, 30s) linear infinite;
  will-change: transform; backface-visibility: hidden; }   /* its own compositor layer: the scroll doesn't wait on the main thread (Chrome on Mac jittered, 10-25) */
.ticker.scroll:hover .track, .ticker.scroll:focus-within .track { animation-play-state: paused; }
@keyframes tick { from { transform: translate3d(0, 0, 0); } to { transform: translate3d(-50%, 0, 0); } }
@media (prefers-reduced-motion: reduce) { .ticker { overflow-x: auto; } .ticker.scroll .track { animation: none; } }
.ticker .ti { color: #fff; text-decoration: none; display: inline-flex; align-items: center; gap: 7px; padding: 0 4px; }
.ticker .ti:hover b { text-decoration: underline; }
.ticker .sq { background: var(--fire); color: #fff; font-weight: 800; border-radius: 4px; padding: 1px 7px; letter-spacing: .02em; font-size: 12px; }
.ticker b { color: #fff; font-weight: 600; font-size: 13px; }
.ticker .ln { color: #fff; font-size: 12px; font-variant-numeric: tabular-nums; }   /* (steady digit widths: "21s ago" -> "1m ago" moves less) */
.ticker .sm { color: #d2d5da; font-size: 12px; }
.ticker .dot { color: #e08a8e; padding: 0 14px; }
.watchpin { display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; }   /* not clickable: the label is the information (11-02) */
.watchpin.sq .g { display: inline-block; font-size: 20px; }   /* an aircraft squawking an emergency: the ✈ turned to its heading */
.watchpin .g { font-size: 18px; line-height: 1; color: var(--c); filter: drop-shadow(0 0 2px #000) drop-shadow(0 0 4px var(--c)); }
.watchpin .t { font-size: 11px; font-weight: 600; color: #fff; background: rgba(11, 14, 18, .85); border: 1px solid var(--c);
  border-radius: 4px; padding: 0 5px; }
.watchpin.mini .g { font-size: 13px; }
.airpin { font-size: 22px; line-height: 1; color: var(--priority); text-shadow: 0 0 6px #000, 0 0 2px #000; }

/* ---------------------------------------------------------------- activity strip */
.activity { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 18px; padding: 4px 16px; font-size: 12px; color: var(--muted);
  background: #12161b; border-bottom: 1px solid var(--line); font-variant-numeric: tabular-nums; min-height: 26px; }
.act-h span { color: var(--text); }
.act-counts { display: contents; }
.act-win { margin-left: auto; display: none; align-items: center; gap: 6px; white-space: nowrap; }
body[data-view="map"] .act-win, body[data-view="scanner"] .act-win { display: inline-flex; }
.act-heat { display: none; align-items: center; gap: 6px; white-space: nowrap; margin: 0 auto; }   /* centred between counts and window */
body[data-view="map"] .act-heat { display: inline-flex; }
body[data-view="map"] .act-heat + .act-win { margin-left: 0; }
.act-heat select { font-size: 12px; padding: 1px 6px; }
/* Traffic (ncdot.py): congestion drawn on the map; a badge where NCDOT has a report on a congested road (map.js) */
.legend i.cong-i { width: 16px; height: 4px; border-radius: 2px; background: linear-gradient(90deg, #ec8d00 50%, #e6002e 50%); }
.roadpin { width: 22px; height: 22px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 12px;
  background: rgba(11, 14, 18, .9); border: 2px solid var(--c); box-shadow: 0 1px 4px rgba(0, 0, 0, .6); }
.roadpop h3 { margin: 0 0 2px; font-size: 14px; }
.roadpop .k { color: var(--muted); font-size: 12px; }
.roadpop p { margin: 4px 0; font-size: 12.5px; line-height: 1.35; }
/* Incident type picker (Map): beside the heatmap, the two centred together; a checklist under its button (rob 11-02) */
.act-type { display: none; position: relative; align-items: center; gap: 6px; white-space: nowrap; }
body[data-view="map"] .act-type { display: inline-flex; margin-right: auto; }
body[data-view="map"] .act-heat { margin: 0 0 0 auto; }
body[data-view="map"] .act-type + .act-win { margin-left: 0; }
.tp-btn { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; padding: 1px 6px; max-width: 190px; cursor: pointer; }
.tp-btn b { font-weight: 400; overflow: hidden; text-overflow: ellipsis; }
.tp-btn i { font-style: normal; color: var(--muted); font-size: 10px; }
.act-type.on .tp-btn { border-color: var(--accent); color: var(--accent); }
.adv-tools .act-type.tp-board { display: inline-flex; }   /* the Incident Board's own picker, beside the district menu */
.adv-tools .tp-board .tp-btn { padding: 3px 8px; }
.adv-tools .tp-row input { padding: 0; }                   /* (not the toolbar's padded inputs) */
.adv-tools .tp-pop { font-family: Inter, system-ui, sans-serif; }   /* the board is monospace: the checklist reads like the Map's */
.adv-tools .tp-row { display: flex; gap: 9px; font-size: 13px; color: var(--text); }
.adv-tools .tp-find { font-size: 13px; padding: 4px 8px; }
.tp-pop { position: absolute; top: calc(100% + 5px); left: 0; z-index: 1200; width: min(290px, calc(100vw - 20px));
  max-height: min(62vh, 440px); display: flex; flex-direction: column; background: var(--panel); border: 1px solid var(--line);
  border-radius: 8px; box-shadow: 0 10px 28px rgba(0, 0, 0, .55); white-space: normal; }
.tp-pop[hidden] { display: none; }
.tp-top { display: flex; gap: 6px; padding: 8px; border-bottom: 1px solid var(--line); }
.tp-find { flex: 1; min-width: 0; font-size: 13px; padding: 4px 8px; }
.tp-all { font-size: 12px; padding: 3px 9px; white-space: nowrap; cursor: pointer; }
.tp-list { overflow-y: auto; padding: 4px 0; overscroll-behavior: contain; }
.tp-row { display: flex; align-items: center; gap: 9px; padding: 6px 12px; cursor: pointer; color: var(--text); font-size: 13px; line-height: 1.3; }
.tp-row:hover { background: var(--panel2); }
.tp-row input { flex: none; width: 15px; height: 15px; margin: 0; padding: 0; accent-color: var(--accent); cursor: pointer; }
.tp-row span { flex: 1; }
.tp-row em { font-style: normal; color: var(--muted); font-size: 12px; font-variant-numeric: tabular-nums; }
.tp-row.untyped span { color: var(--muted); font-style: italic; }
.tp-none { padding: 12px; color: var(--muted); font-size: 13px; }
@media (max-width: 760px) { .tp-row { padding: 9px 12px; font-size: 14px; } .tp-find { font-size: 16px; } }   /* (16px: iOS won't zoom on focus) */
.pager { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; padding: 8px 12px; border-top: 1px solid var(--line); }
.pager button { min-width: 30px; padding: 3px 7px; font-size: 12px; }
.pager button.on { background: var(--accent); color: #0b0e12; border-color: var(--accent); font-weight: 700; }
.pager button:disabled { opacity: .35; cursor: default; }
.pager .muted { margin-left: auto; font-size: 12px; }
/* Heatmap on: incident pins fade almost away (still clickable); aircraft stay. */
.heat-on .leaflet-marker-pane .pin, .heat-on .leaflet-marker-pane .scope-ping { opacity: .1; transition: opacity .2s; }
.heat-on .leaflet-overlay-pane canvas { opacity: .4; transition: opacity .2s; }   /* the small dots, under the heatmap */
/* The four closest zooms: over the heatmap at a real 50% (under it, 50% came to about 13% and looked no different from 40%). */
.heat-on.zoom-close .leaflet-overlay-pane canvas { opacity: .5; }
.heat-on.zoom-close .leaflet-heat-pane { z-index: 350 !important; }
.heat-on .leaflet-marker-pane .leaflet-marker-icon:hover .pin { opacity: .8; }
.act-win select { font-size: 12px; padding: 1px 6px; }
.act-g { display: inline-flex; align-items: center; gap: 5px; white-space: nowrap; color: var(--text);
  font: inherit; background: none; border: 1px solid transparent; border-radius: 999px; padding: 1px 8px; margin: 0 -4px; }
/* Only the Map filters by service: there the counts are buttons, the chosen one outlined. */
body:not([data-view="map"]) .act-g { pointer-events: none; padding: 0; margin: 0; border: 0; }   /* plain counts */
body[data-view="map"] .act-g { cursor: pointer; }
body[data-view="map"] .act-g:hover { border-color: var(--line); }
body[data-view="map"] .act-g.on { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 14%, transparent); }
.act-g b { font-weight: 600; color: var(--muted); margin-right: 2px; }
.act-g i { width: 7px; height: 7px; border-radius: 50%; background: var(--c); }
.act-g em { font-style: normal; font-size: 11px; font-weight: 600; margin-left: 1px; }
.act-g em.up { color: #22c55e; } .act-g em.down { color: #ef4444; } .act-g em.flat { color: var(--muted); font-size: 9px; }
.act-all { --c: var(--ok); } .act-police { --c: var(--police); } .act-fire { --c: var(--fire); } .act-ems { --c: var(--ems); }
@media (max-width: 760px) { .activity { padding: 4px 10px; gap: 2px 12px; }  }

/* ---------------------------------------------------------------- about */
.view[data-view="about"] { overflow-y: auto; }   /* (not Help: an overflow box there would hold its section menu's sticky position) */
.about { max-width: 1060px; margin: 0 auto; padding: 44px 24px 80px; font-size: 16px; line-height: 1.65; }
.about > * { max-width: 800px; margin-left: auto; margin-right: auto; }   /* one column width for every section, the steps too (rob, 10-25: 800px) */
.about p { margin-block: 0 14px; }
.about h1 { font-size: 33px; line-height: 1.15; margin-block: 0 22px; letter-spacing: -.02em; }
/* About opens on the kitchen scanner (rob 11-02, idea 1 of six): the photo wider than the column, the heading on its lower edge */
.about > .hero { position: relative; max-width: none; margin: 0 0 30px; border-radius: 16px; overflow: hidden; aspect-ratio: 994 / 430;
  background: #0b0f14; }
.about .hero img { width: 100%; height: 100%; object-fit: cover; object-position: center 45%; display: block; }
.about .hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to bottom, transparent 45%, rgba(15, 18, 22, .92)); }
.about .hero h1 { position: absolute; left: 0; right: 0; bottom: 16px; z-index: 1; margin: 0 auto; max-width: 800px; padding: 0;
  font-size: 36px; text-shadow: 0 2px 12px rgba(0, 0, 0, .6); }
.about .intro p { font-size: 18px; line-height: 1.7; margin-block: 0 16px; }
.about h2 { font-size: 24px; line-height: 1.25; letter-spacing: -.01em; margin-block: 56px 16px; padding-top: 30px;
  border-top: 1px solid var(--line); }
.about h3 { font-size: 18px; line-height: 1.3; margin-block: 28px 8px; color: var(--text); }
.about ul { padding-left: 22px; margin-block: 0 14px; }
.about li { margin: 10px 0; padding-left: 4px; }
.about li::marker { color: var(--muted); }
/* Help's section menu (rob 11-02): the main menu's look and icons, stuck under the player bar while you read, the section
   you're in lit like the page you're on. On a phone: one row you swipe, icons above labels. */
.about .hnav { display: flex; gap: 4px; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 4px;
  position: sticky; top: calc(var(--pbar-h, 53px) + 8px); z-index: 20; box-shadow: 0 6px 18px rgba(0, 0, 0, .45); margin: 0 auto 8px; }
.about .hnav a { flex: 1; display: inline-flex; align-items: center; justify-content: center; gap: 7px; padding: 9px 10px; border-radius: 9px;
  text-decoration: none; color: var(--muted); font-weight: 600; font-size: 14.5px; white-space: nowrap; }
.about .hnav .ni { font-style: normal; font-size: 18px; line-height: 1; }
.about .hnav .ni img { width: 1.15em; height: 1.15em; display: block; }
.about .hnav a:hover { color: var(--text); }
.about .hnav a.on { background: var(--panel2); color: var(--text); box-shadow: inset 0 0 0 1px var(--line); }
.about.help h2 { scroll-margin-top: calc(var(--pbar-h, 53px) + 84px); }   /* (below the bar and the menu) */
@media (max-width: 760px) {
  .about .hnav { overflow-x: auto; scrollbar-width: none; margin-inline: -4px; }
  .about .hnav::-webkit-scrollbar { display: none; }
  .about .hnav a { flex: 1 0 auto; flex-direction: column; gap: 3px; padding: 7px 3px; font-size: 12px; }
  .about .hnav a[data-to="a-use"] { display: none; }   /* phones: the page opens on Quick Start, so the other seven fit (rob 11-02) */
  .about .hnav .ni { font-size: 20px; height: 22px; display: flex; align-items: center; }
  .about .hnav .ni img { width: 21px; height: 21px; }
  .about.help h2 { scroll-margin-top: calc(var(--pbar-h, 84px) + 92px); }
}
.about > .steps { max-width: 800px; list-style: none; padding: 0; margin-block: 0; counter-reset: step; }
.about .step { counter-increment: step; display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 44px;
  align-items: center; margin: 0; padding: 34px 0; border-top: 1px solid color-mix(in srgb, var(--line) 55%, transparent); }
.about .step:first-child { border-top: 0; padding-top: 14px; }
.about .step h3 { font-size: 20px; margin-block: 0 12px; }
.about .step h3::before { content: counter(step); display: inline-grid; place-items: center; vertical-align: 2px; margin-right: 12px;
  width: 32px; height: 32px;
  border-radius: 50%; background: var(--accent); color: #fff; font-size: 15px; font-weight: 700; }
.about .step p:last-child { margin-bottom: 0; }
.about .note { font-size: 15px; color: var(--muted); background: var(--panel); border-left: 3px solid var(--accent);
  border-radius: 8px; padding: 14px 18px; margin-block: 26px 0; }
.about .note b { color: var(--text); }
.about .step .shot { margin: 0; }
.about .feats .step h3::before { content: none; display: none; }
.about h2 { scroll-margin-top: 76px; }   /* the contents links: the heading lands below the sticky player bar */
@media (max-width: 760px) { .about h2 { scroll-margin-top: 100px; } }   /* (the phone's player bar is two rows) */   /* Help's page guides: blocks like Quick Start's, not numbered steps */
.about h2 + p + .feats .step:first-child { padding-top: 6px; }
.about > .shot { margin-block: 6px 18px; }
.about .shot img { display: block; width: 100%; height: auto; border-radius: 12px; border: 1px solid var(--line); background: #0b0f14;
  box-shadow: 0 14px 36px rgba(0, 0, 0, .35); }
.about .step .shot.phone { justify-self: center; width: 100%; max-width: 390px; }
.about > .shot.phone img { max-width: 390px; }
.about a.cite { white-space: nowrap; }
@media (max-width: 820px) {
  .about { padding: 28px 16px 60px; }
  .about > .hero { margin: -28px -16px 22px; border-radius: 0; aspect-ratio: 4 / 3; }
  .about .hero h1 { font-size: 27px; padding: 0 16px; }
  .about .hero::after { background: linear-gradient(to bottom, transparent 35%, rgba(15, 18, 22, .95)); }
  .about h1 { font-size: 28px; }
  .about .intro p { font-size: 17px; }
  .about h2 { font-size: 22px; margin-block: 44px 14px; padding-top: 24px; }
  .about .step { grid-template-columns: minmax(0, 1fr); gap: 16px; padding: 26px 0; }
  .about .step h3 { font-size: 19px; }
}
.contact { display: flex; gap: 10px; flex-wrap: wrap; }
.contact a { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: var(--panel2);
  border: 1px solid var(--line); color: var(--text); transition: background .15s, color .15s, border-color .15s; }
.contact a:hover, .contact a:focus-visible { background: var(--accent); border-color: var(--accent); color: #fff; }
.contact svg { width: 18px; height: 18px; fill: currentColor; }

/* ---------------------------------------------------------------- map view */
.view[data-view="map"] { position: relative; }
.mapwrap { position: absolute; inset: 0; }
#bigmap { position: absolute; inset: 0; background: #11161b; }
.mpanel { position: absolute; z-index: 500; background: rgba(22, 27, 33, .95); border: 1px solid var(--line); border-radius: 12px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, .45); backdrop-filter: blur(6px); }
.pickbar { top: 12px; left: 50%; transform: translateX(-50%); padding: 10px 14px; display: flex; gap: 12px; align-items: center; border-color: var(--ok); z-index: 1100; }
.evpanel { top: 12px; right: 12px; bottom: 12px; width: 350px; display: flex; flex-direction: column; overflow: hidden; }
.drawer-tab, .drawer-x { display: none; }
.evpanel .head { padding: 10px 12px; border-bottom: 1px solid var(--line); display: flex; align-items: center; gap: 8px; }
.evpanel .head h2 { margin: 0; font-size: 14px; flex: 1; }
.evlist { overflow-y: auto; flex: 1; }
.evlistwrap, .evdetail { display: flex; flex-direction: column; min-height: 0; flex: 1; }
.dhead { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 8px 10px; border-bottom: 1px solid var(--line); font-size: 12px; }
.dhead button { padding: 3px 9px; font-size: 13px; }
/* an incident that isn't on record (map.js showGone): the error pages' look (/var/www/rg-errors, 11-21) */
.gone { margin: 22px 14px; padding: 22px 20px 20px; background: var(--panel); border: 1px solid var(--line); border-radius: 14px; text-align: center; }
.gone-logo { width: 72px; height: 72px; border-radius: 16px; box-shadow: 0 8px 28px rgba(0, 0, 0, .45); }
.gone-status { display: flex; align-items: center; justify-content: center; gap: 8px; margin: 14px 0 8px; font-size: 12px; font-weight: 700;
  letter-spacing: .08em; text-transform: uppercase; color: var(--accent); }
.gone-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--accent); }
.gone p { margin: 0 0 16px; font-size: 14px; color: var(--text); }
.gone-btn { padding: 9px 16px; border: 0; border-radius: 10px; background: var(--accent); color: #0b1220; font-weight: 700; font-size: 14px; }
.gone-btn:hover { filter: brightness(1.08); }
.dbody { display: flex; flex-direction: column; min-height: 0; flex: 1; border-top: 3px solid var(--c); }
.dtitle { font-weight: 700; font-size: 15px; padding: 10px 12px 0; }
.dbody .a { color: var(--accent); font-size: 13px; padding: 2px 12px 0; }
.dbody .s { font-size: 13px; color: #c3ccd6; padding: 6px 12px 0; line-height: 1.45; }
.dctl { display: flex; align-items: center; gap: 6px; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.dctl button { padding: 5px 10px; }
.dctl button.on { border-color: var(--bad); }
.dctl .muted { margin-left: auto; font-size: 12px; }
.dcalls { overflow-y: auto; flex: 1; }
/* A short panel: the summary and the calls scroll as one, the controls staying on top. On their own the calls got no height at all under a long summary (#55466, rob 10-31) */
@media (max-width: 760px), (max-height: 559px) {
  .dbody { overflow-y: auto; overscroll-behavior: contain; }
  .dbody > * { flex: none; }
  .dcalls { overflow: visible; flex: none; }
  .dctl { position: sticky; top: 0; z-index: 2; background: var(--panel); }
}
.dc { display: grid; grid-template-columns: 30px 1fr; gap: 8px; padding: 8px 12px; border-bottom: 1px solid var(--line); cursor: pointer; }
.dc:hover { background: var(--panel2); }
.dc.cur { background: #1b2530; }
.dc.playing { background: #17261c; box-shadow: inset 3px 0 0 var(--ok); }
.dc > button { width: 28px; height: 28px; padding: 0; border-radius: 50%; font-size: 11px; }
.dc .dm { font-size: 11.5px; color: var(--muted); }
.dc .dt { font-size: 13.5px; line-height: 1.4; overflow-wrap: anywhere; }
.dc .dt.none { color: var(--muted); font-style: italic; }
.mev { padding: 10px 12px 10px 15px; border-bottom: 1px solid var(--line); cursor: pointer; position: relative; }
.mev::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 4px; background: var(--c); }
.mev:hover, .mev.sel { background: var(--panel2); }
.mev.inzone { box-shadow: inset 0 0 0 1px rgba(76, 195, 138, .55); }
.mev .t { font-weight: 600; display: flex; justify-content: space-between; gap: 8px; }
.mev .t span { font-weight: 400; color: var(--muted); font-size: 12px; white-space: nowrap; }
.mev .a { color: var(--accent); font-size: 13px; }
.mev .s { font-size: 12.5px; color: #b9c3ce; margin-top: 3px; }
.mev .z { font-size: 11px; color: var(--ok); margin-top: 2px; }
.mev.flash { animation: flash 1.2s ease-out; }
@keyframes flash { from { background: #20352a; } to { background: transparent; } }
.legend { left: 64px; bottom: 12px; padding: 7px 10px; font-size: 12px; display: flex; gap: 10px; flex-wrap: wrap; }
.legend span { display: inline-flex; align-items: center; gap: 5px; }
.legend i { width: 10px; height: 10px; border-radius: 50%; display: inline-block; background: var(--c); }
.legend i.rough-i { background: transparent; border: 1.5px dashed #fff; width: 11px; height: 11px; }
.pin { width: 16px; height: 16px; border-radius: 50%; background: color-mix(in srgb, var(--c) 85%, transparent); border: 2px solid rgba(255, 255, 255, .85); box-shadow: 0 0 0 2px rgba(0, 0, 0, .35); }
/* (the ring on its own layer, transform + opacity only: an animated box-shadow restyled and repainted the whole marker pane every
   frame, 18 s of main thread a minute on a phone with 8 hot pins, 11-11 review) */
.pin.hot { position: relative; }
.pin.hot::after, .scope-ping::after { content: ""; position: absolute; inset: -2px; border-radius: 50%; border: 2px solid var(--c);
  pointer-events: none; will-change: transform, opacity; animation: ring 1.4s ease-out infinite; }
.pin.approx { background: color-mix(in srgb, var(--c) 40%, transparent); border: 2px dashed rgba(255, 255, 255, .8); }
.rough { opacity: .85; }
@keyframes ring { 0% { transform: scale(1); opacity: .9; } 100% { transform: scale(2.6); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .evpanel { transition: none; } }
@media (prefers-reduced-motion: reduce) { .pin.hot::after { animation: none; display: none; } .pin.hot { box-shadow: 0 0 0 4px var(--c); } .mev.flash { animation: none; } }
.leaflet-popup-content-wrapper, .leaflet-popup-tip { background: var(--panel); color: var(--text); border: 1px solid var(--line); }
.leaflet-popup-content { margin: 10px 12px; min-width: 240px; max-width: 300px; }
.leaflet-popup-content h3 { margin: 0 0 4px; font-size: 14px; }
.leaflet-popup-content .s { margin: 6px 0; font-size: 13px; }
.leaflet-popup-content .acts { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 8px; }
.leaflet-container a.leaflet-popup-close-button { color: var(--muted); }
.leaflet-control-layers, .leaflet-bar a { background: var(--panel) !important; color: var(--text) !important; border-color: var(--line) !important; }
.crosshair, .crosshair .leaflet-interactive { cursor: crosshair !important; }

/* ---------------------------------------------------------------- scanner view */
.view[data-view="scanner"] { overflow-y: auto; background: radial-gradient(1200px 600px at 50% -200px, #1d252d, var(--bg)); }
.scan { max-width: 1180px; margin: 0 auto; padding: 18px 16px 50px; display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 18px; align-items: start; }
.radio { grid-column: 1 / -1; display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 18px;
  background: linear-gradient(180deg, #252b31, #1a1e23); border: 1px solid #39424c; border-radius: 20px; padding: 18px;
  box-shadow: 0 20px 50px rgba(0,0,0,.5), inset 0 1px 0 rgba(255,255,255,.05); }
.radio .face { min-width: 0; }
.lcd { --lcd: #9dffb0; background: #0b1a10; border-radius: 10px; padding: 12px 16px; border: 2px solid #050a06; box-shadow: inset 0 0 30px rgba(0,0,0,.8);
  font-family: "Share Tech Mono", ui-monospace, monospace; color: var(--lcd); text-shadow: 0 0 6px rgba(157,255,176,.45); height: 265px; position: relative; overflow: hidden; }   /* a fixed box: nothing on it can move the page (rob 10-31) */
.lcd.pri { --lcd: #ffb4a8; background: #1f0d0b; }
.lcd .top { display: flex; gap: 10px; align-items: center; font-size: 13px; }
.lcd .ind { padding: 0 5px; border: 1px solid currentColor; border-radius: 3px; font-size: 11px; opacity: .25; }
.lcd .ind.on { opacity: 1; }
.lcd .clock { margin-left: auto; opacity: .85; }
.lcd .qstat { position: absolute; top: 31px; right: 16px; text-align: right; font-size: 11px; line-height: 1.35; opacity: .7; }
.lcd .ch { padding-right: 96px; }   /* clear of Delay / Queued */
.lcd .ch { font-size: 30px; line-height: 1.15; margin: 10px 0 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lcd .sub { font-size: 13px; opacity: .8; }
.lcd .tx { font-size: 18px; line-height: 1.35; margin-top: 8px; height: 6.75em; color: #d6ffe0; overflow-wrap: anywhere;   /* five lines, always, so the box doesn't jump; longer ends in … (rob 10-31: 97.7% of a week's calls fit on a phone, 99.7% on a laptop) */
  display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 5; line-clamp: 5; overflow: hidden; }
.lcd.pri .tx { color: #ffe1dc; }
.lcd .ev { font-size: 13px; line-height: 1.3; height: 1.3em; margin-top: 6px; opacity: .85; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }   /* (one line, held open, for the same reason) */
.lcd.link { cursor: pointer; }
.lcd.link:hover .ev, .lcd.link:focus-visible .ev { text-decoration: underline; opacity: 1; }
.lcd.idle .ch { opacity: .45; }
.sig { display: inline-flex; gap: 2px; align-items: flex-end; height: 14px; }
.sig i { width: 4px; background: var(--lcd); opacity: .2; }
.sig i:nth-child(1) { height: 4px; } .sig i:nth-child(2) { height: 7px; } .sig i:nth-child(3) { height: 10px; } .sig i:nth-child(4) { height: 14px; }
.lcd.rx .sig i { opacity: 1; }
.keys { display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; margin-top: 14px; }
.fkeys { display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; margin-top: 10px; }
.key { padding: 13px 6px 10px; border-radius: 12px; border: 1px solid #3a434d; background: linear-gradient(180deg, #2d343b, #22272d);
  text-align: center; font-weight: 800; font-size: 14px; letter-spacing: .06em; box-shadow: 0 3px 0 #0d1013, inset 0 1px 0 rgba(255,255,255,.06);
  display: flex; flex-direction: column; align-items: center; gap: 5px; color: #e9eef3; }
.key:active { transform: translateY(2px); box-shadow: 0 1px 0 #0d1013; }
.key .led { width: 10px; height: 10px; border-radius: 50%; background: #2b2f33; box-shadow: inset 0 1px 2px #000; }
.key.on .led { background: var(--c); box-shadow: 0 0 10px var(--c); }
.key.on { border-color: var(--c); }
.key.fk { font-size: 12.5px; padding: 9px 6px; --c: var(--ems); }
.key.fk.lo { --c: var(--bad); } .key.fk.pri { --c: var(--priority); } .key.fk.big { --c: var(--ok); } .key.fk.rst { --c: var(--muted); }
.knobs { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
/* The buttons on the left and the activity graph on the right end on the same line: both columns stretch to the
   radio's full height, with the keys and the graph pushed to the bottom. */
.radio .face { display: flex; flex-direction: column; }
.radio .face .keys { margin-top: auto; padding-top: 14px; }
.knobs .activity-meter { margin-top: auto; }
.speaker { flex: 1; min-height: 120px; border-radius: 14px; background: radial-gradient(circle, #15191d 1.4px, transparent 1.6px) 0 0 / 9px 9px, #1d2227;
  border: 1px solid #333b44; display: flex; align-items: center; justify-content: center; position: relative; overflow: hidden; }
.speaker.scope { display: block; padding: 0; flex: none; height: 265px; background: #0b0f12;   /* one size, idle or zoomed in */
  box-shadow: inset 0 0 0 3px #15191d, inset 0 0 0 4px #333b44; }
.speaker.scope #s-map { position: absolute; inset: 4px; border-radius: 11px; background: #0b0f12; }
.speaker.scope::after { content: ""; position: absolute; inset: 4px; border-radius: 11px; pointer-events: none; z-index: 450;
  box-shadow: inset 0 0 22px rgba(0, 0, 0, .85); background: repeating-linear-gradient(0deg, rgba(0, 0, 0, .12) 0 1px, transparent 1px 3px); }
.speaker.scope .brandplate { position: absolute; top: 10px; left: 10px; z-index: 460; font-size: 10px; padding: 2px 7px; opacity: .85; }
.scope-win { position: absolute; top: 10px; right: 12px; z-index: 460; font-family: "Share Tech Mono", monospace; font-size: 10px;
  letter-spacing: .15em; color: #8b96a3; }
.scope-tag { position: absolute; bottom: 10px; left: 10px; right: 10px; z-index: 460; font-family: "Share Tech Mono", monospace;
  font-size: 12px; color: #9ff0b8; text-shadow: 0 0 6px rgba(76, 195, 138, .6); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.scope-ping { position: relative; width: 14px; height: 14px; margin: 2px; border-radius: 50%; background: var(--c); }
.scope-ping::after { animation-duration: 1.2s; }
@media (prefers-reduced-motion: reduce) { .scope-ping::after { animation: none; display: none; } .scope-ping { box-shadow: 0 0 0 4px var(--c); } }
.speaker .brandplate { font-family: "Share Tech Mono", monospace; letter-spacing: .3em; color: #8b96a3; font-size: 12px; background: #1d2227; padding: 4px 10px; border-radius: 4px; border: 1px solid #333b44; }
.meter { display: grid; grid-template-columns: repeat(30, 1fr); gap: 2px; height: 40px; align-items: end; }
.meter i { background: #2b3a31; border-radius: 1px; height: 10%; transition: height .4s; }
.meter i.hi { background: var(--ok); }
.knobrow { display: flex; align-items: center; gap: 10px; font-size: 12px; color: var(--muted); font-family: "Share Tech Mono", monospace; }
.knobrow input { flex: 1; padding: 0; accent-color: #9dffb0; border: 0; background: none; }
.box { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; min-width: 0; }
.box h2 { margin: 0; padding: 10px 14px; font-size: 12px; text-transform: uppercase; letter-spacing: .1em; color: var(--muted);
  border-bottom: 1px solid var(--line); display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.box h2 .hint { text-transform: none; letter-spacing: 0; font-weight: 400; font-size: 11px; }
.bank { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 6px; padding: 10px; align-content: start; }
.bankgrp { grid-column: 1 / -1; font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: .1em; margin: 6px 2px 0; }
.ch-cell { position: relative; border: 1px solid var(--line); border-radius: 8px; padding: 7px 34px 6px 22px; background: var(--panel2); cursor: pointer; text-align: left; min-width: 0; }
.ch-cell .led { position: absolute; left: 8px; top: 11px; width: 8px; height: 8px; border-radius: 50%; background: #2b2f33; }
.ch-cell.act .led { background: var(--c); box-shadow: 0 0 8px var(--c); }
.ch-cell .nm { display: block; font-size: 12px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ch-cell .ct { font-size: 11px; color: var(--muted); font-family: "Share Tech Mono", monospace; }
.ch-cell.held { border-color: var(--ems); box-shadow: inset 0 0 0 1px var(--ems); }
.ch-cell.locked { opacity: .45; text-decoration: line-through; }
.ch-cell .lo { position: absolute; right: 4px; top: 4px; font-size: 10px; padding: 0 4px; border-radius: 3px; border: 1px solid var(--line); background: transparent; color: var(--muted); }
.ch-cell .lo:hover { color: var(--bad); border-color: var(--bad); }
.ch-cell.locked .lo { color: var(--bad); border-color: var(--bad); opacity: 1; }
.log { max-height: 520px; overflow-y: auto; }
/* The scanner's incidents and call log scroll without a visible scrollbar (rob 10-26): wheel, touch and keys still work */
.scan .side .log, .evlist, .dcalls { scrollbar-width: none; -ms-overflow-style: none; overscroll-behavior: contain; }
.scan .side .log::-webkit-scrollbar, .evlist::-webkit-scrollbar, .dcalls::-webkit-scrollbar { display: none; width: 0; height: 0; }
/* (and the map page's incident list and an open incident's calls, rob 10-26) */
.lg { display: grid; grid-template-columns: 30px 88px 1fr; gap: 8px; padding: 7px 12px; border-bottom: 1px solid var(--line); align-items: start; }
.lg.playing { background: #17261c; }
.lg .pl { width: 26px; height: 26px; padding: 0; border-radius: 50%; font-size: 11px; }
.lg .tm { font-family: "Share Tech Mono", monospace; font-size: 12px; color: var(--muted); padding-top: 4px; white-space: nowrap; }
.lg .tm small { display: block; font-size: 10.5px; }   /* the short date under the time (rob 10-26) */
.lg .tg { font-size: 12px; color: var(--c); font-weight: 600; }
.lg .tx { font-size: 13px; overflow-wrap: anywhere; }
.lg .tx.none { color: var(--muted); font-style: italic; }
.inc { padding: 9px 14px; border-bottom: 1px solid var(--line); border-left: 3px solid var(--c); cursor: pointer; }
.inc:hover { background: var(--panel2); }
.inc .t { font-weight: 600; font-size: 13px; display: flex; justify-content: space-between; gap: 8px; }
.inc .t span { color: var(--muted); font-weight: 400; font-size: 12px; white-space: nowrap; }
.inc .a { color: var(--accent); font-size: 12px; }
.inc .s { color: #b9c3ce; font-size: 12.5px; margin-top: 2px; }
.empty { padding: 18px; color: var(--muted); text-align: center; font-size: 13px; }
.scan .side { display: flex; flex-direction: column; gap: 18px; min-width: 0; }
/* The channel bank is always its full size, every channel showing and no scrollbar of its own (rob 10-26; it had
   filled its column down to where the call log and incidents beside it end, and scrolled inside). On desktop the
   incidents and call log beside it end where it ends: their column takes the row's height and never sets it
   (contain: size), the incidents keep their seven-row height (scanner.js fitIncidents) and the call log fills the rest,
   both scrolling inside. */
@media (min-width: 981px) {
  .scan .side { align-self: stretch; contain: size; }
  .scan .side > .box { display: flex; flex-direction: column; min-height: 0; }
  .scan .side > .box:first-child { flex: 0 1 auto; }
  .scan .side > .box:last-child { flex: 1 1 0; }
  .scan .side .log { flex: 1 1 auto; min-height: 0; }
  .scan .side > .box:last-child .log { max-height: none; }
}

/* ---------------------------------------------------------------- advanced view */
.view[data-view="advanced"] { display: grid; grid-template-rows: auto auto 1fr; font-size: 13px; min-height: 0; height: calc(100vh - var(--hdr) - 80px); }
.view[data-view="advanced"] { font-family: "JetBrains Mono", ui-monospace, monospace; }
.adv-stat { display: flex; gap: 14px; flex-wrap: wrap; padding: 5px 12px; background: #0b0e12; border-bottom: 1px solid var(--line); font-size: 12px; color: var(--muted); }
.adv-stat b { color: var(--text); font-weight: 600; } .adv-stat .ok { color: var(--ok); } .adv-stat .bad { color: var(--bad); }
.adv-rx { padding-top: 0; }
.adv-tools { display: flex; gap: 8px; align-items: center; padding: 6px 12px; border-bottom: 1px solid var(--line); background: var(--panel); flex-wrap: wrap; }
.adv-tools label { display: inline-flex; gap: 4px; align-items: center; color: var(--muted); font-size: 12px; }
.adv-tools input, .adv-tools select, .adv-tools button { padding: 3px 8px; font-size: 12px; }
.adv-tools input[type=search] { width: 200px; }
.adv-tools .find { margin-left: auto; display: inline-flex; flex-wrap: wrap; gap: 8px; align-items: center; justify-content: flex-end; }
.adv-tools .find input[type=search] { border-color: var(--accent); }
.adv-tools input[type=datetime-local] { color-scheme: dark; }
.seg button { border-radius: 0; margin-left: -1px; } .seg button:first-child { border-radius: 5px 0 0 5px; } .seg button:last-child { border-radius: 0 5px 5px 0; }
.seg button.on { background: #22303d; border-color: var(--accent); position: relative; }
.when.on input { border-color: var(--ems); } .when.on .live { border-color: var(--ok); color: var(--ok); }
.adv-main { display: grid; grid-template-columns: minmax(0, 1fr) minmax(360px, 40%); min-height: 0; }
.adv-tbl { overflow: auto; border-right: 1px solid var(--line); }
.adv-tbl table { border-collapse: collapse; width: 100%; table-layout: fixed; }
.adv-tbl th { position: sticky; top: 0; background: var(--panel); text-align: left; font-weight: 600; color: var(--muted); font-size: 11px; z-index: 1;
  text-transform: uppercase; letter-spacing: .05em; padding: 6px 8px; border-bottom: 1px solid var(--line); cursor: pointer; white-space: nowrap; user-select: none; }
.adv-tbl th.sorted::after { content: " ▾"; } .adv-tbl th.sorted.asc::after { content: " ▴"; }
.adv-tbl td { padding: 5px 8px 2px; vertical-align: top; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.adv-tbl tbody { cursor: pointer; border-bottom: 1px solid #222a33; }
.adv-tbl tbody:hover td { background: #141a20; }
.adv-tbl tbody.sel td { background: #1a2633; }
.adv-tbl tbody.hot td:first-child { box-shadow: inset 3px 0 0 var(--ok); }
.adv-tbl td.ty { border-left: 3px solid var(--c); font-weight: 600; white-space: normal; }
.adv-tbl td.addr { color: var(--accent); }
.adv-tbl td.num { text-align: right; font-variant-numeric: tabular-nums; }
.adv-tbl tr.sum td { white-space: normal; color: #b9c3ce; font-family: Inter, system-ui, sans-serif; font-size: 13px; line-height: 1.45; padding: 0 8px 8px; }
.adv-tbl tr.sum td.sp { border-left: 3px solid var(--c); }
.age-0 { color: var(--ok); } .age-1 { color: var(--text); } .age-2 { color: var(--muted); }
.alert { color: var(--priority); }
.adv-side { display: grid; grid-template-rows: 210px 1fr; grid-template-columns: minmax(0, 1fr); min-height: 0; }   /* (the column, not a camera picture, sets the width) */
#minimap { background: #11161b; border-bottom: 1px solid var(--line); }
.adv-det { overflow: auto; padding: 10px 12px; }
.adv-det h2 { margin: 0; font-size: 16px; color: var(--c); }
.adv-det .meta { color: var(--muted); font-size: 12px; margin: 2px 0 6px; }
.adv-det .sumbox { background: var(--panel); border: 1px solid var(--line); border-radius: 6px; padding: 9px 11px; margin: 8px 0; font-family: Inter, system-ui, sans-serif; font-size: 13.5px; line-height: 1.5; }
.adv-det .chips { margin: 6px 0; }
.adv-det .chip { font-size: 11px; padding: 1px 6px; border-radius: 3px; }
.adv-det .chip.u { border-color: #345; color: #9cc8ff; }
.cl { display: grid; grid-template-columns: 26px 66px 1fr auto; gap: 6px; padding: 5px 0; border-bottom: 1px solid #1f262e; align-items: start; }
.cl.playing { background: #17261c; }
.cl .pl { width: 24px; height: 24px; padding: 0; font-size: 10px; border-radius: 4px; }
.cl .tm { color: var(--muted); font-size: 11px; padding-top: 4px; }
.cl .tx { overflow-wrap: anywhere; }
.cl .why { font-size: 10px; color: var(--muted); }
.cl .act button { font-size: 10px; padding: 1px 5px; opacity: .6; }
.cl .act button:hover { opacity: 1; }

.adv-flyhead { display: none; }
@media (min-width: 900px) and (min-height: 560px) { .adv-tbl td.num .wd { display: none; } }
/* Phones either way up, an iPad held upright (advanced.js `small`; rob 10-30): the page scrolls, the incidents are a list of cards, and
   tapping one opens all of the right side over it. The desktop layout above is untouched. */
@media (max-width: 899px), (max-height: 559px) {
  .view[data-view="advanced"] { display: block; height: auto; font-size: 14px; }
  .adv-tools .when { display: none; }
  .adv-tools select, .adv-tools input, .adv-tools .seg button { padding: 6px 9px; font-size: 13px; }
  .adv-main { display: block; }
  .adv-tbl { overflow: visible; border-right: 0; }
  .adv-tbl table, .adv-tbl tbody, .adv-tbl tbody tr.sum, .adv-tbl tbody td { display: block; width: auto; }
  .adv-tbl thead { display: none; }
  .adv-tbl tbody { padding: 11px 14px 12px 12px; border-left: 3px solid var(--c, var(--line)); }
  .adv-tbl tbody tr:first-child { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 3px 12px; }
  .adv-tbl tbody td { padding: 0; white-space: normal; background: none !important; }
  .adv-tbl tbody td:first-child { display: none; }
  .adv-tbl tbody td.ty { grid-area: 1 / 1; border-left: 0; font-size: 15px; font-family: Inter, system-ui, sans-serif; }
  .adv-tbl tbody td:nth-child(2) { grid-area: 1 / 2; text-align: right; font-size: 12px; }
  .adv-tbl tbody td:nth-child(2) .dt { font-size: 11px; }
  .adv-tbl tbody td.addr { grid-area: 2 / 1 / 2 / -1; white-space: normal; font-size: 13px; }
  .adv-tbl tbody td.num { grid-area: 3 / 2; font-size: 12px; color: var(--muted); }
  .adv-tbl tbody td:nth-child(6) { grid-area: 3 / 1; font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .adv-tbl tr.sum td:not(.sp) { display: none; }
  .adv-tbl tr.sum td.sp { border-left: 0; padding: 6px 0 0; font-size: 14px; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; overflow: hidden; }
  .view[data-view="advanced"] .adv-side { display: none; }
  .view[data-view="advanced"].adv-fly .adv-tbl { display: none; }
  .view[data-view="advanced"].adv-fly .adv-side { display: grid; grid-template-rows: auto 170px auto; align-content: start; min-height: calc(100vh - var(--adv-under, 0px)); background: var(--bg); animation: advFly .22s ease; }
  .adv-flyhead { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 8px 10px;
    border-bottom: 1px solid var(--line); background: var(--panel); position: sticky; top: var(--adv-under, 0); z-index: 2; }
  #minimap { isolation: isolate; z-index: 0; }
  .adv-flyhead button { padding: 8px 12px; font-size: 14px; font-family: Inter, system-ui, sans-serif; }
  .adv-det { overflow: visible; padding-bottom: max(14px, env(safe-area-inset-bottom)); }
  .adv-det .kb { display: none; }
  .adv-det > button { padding: 8px 12px; }
  .cl { grid-template-columns: 34px 58px minmax(0, 1fr) auto; }
  .cl .pl { width: 34px; height: 34px; font-size: 12px; }
}
@media (max-height: 559px) { .view[data-view="advanced"].adv-fly .adv-side { grid-template-rows: auto 110px auto; } }
@keyframes advFly { from { transform: translateX(40px); opacity: 0; } to { transform: none; opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .view[data-view="advanced"].adv-fly .adv-side { animation: none; } }

/* ---------------------------------------------------------------- small screens */
@media (max-width: 980px) {
  .radio { grid-template-columns: 1fr; } .speaker.scope { height: 190px; }
  .scan { grid-template-columns: 1fr; }
}
@media (max-width: 860px) {
  header.site { flex-wrap: wrap; gap: 8px 12px; }
  nav.views { order: 3; width: 100%; justify-content: space-between; }
  nav.views a { flex: 1; text-align: center; padding: 6px 4px; }
  .brand small { font-size: 11px; }
  .adv-main { grid-template-columns: 1fr; grid-template-rows: minmax(300px, 1fr) auto; }
  .view[data-view="advanced"] { height: auto; }
  .adv-side { grid-template-rows: 180px auto; }
}
@media (max-width: 760px) {
  /* incidents as a drawer from the right edge (clipped, so the closed drawer doesn't widen the page) */
  .view[data-view="map"], .mapwrap { overflow: hidden; overflow: clip; }   /* clip: not even scrollable from code */
  .evpanel { top: 8px; bottom: 8px; right: 0; left: auto; width: min(88vw, 380px); height: auto; border-radius: 12px 0 0 12px;
    transform: translateX(105%); transition: transform .25s ease; visibility: hidden; }
  .evpanel.open { transform: none; visibility: visible; }
  .drawer-tab { display: block; top: 60px; right: 0; border-radius: 10px 0 0 10px; padding: 9px 10px 9px 12px; font-weight: 600;
    font-size: 13px; color: var(--text); border-right: 0; cursor: pointer; }
  .drawer-tab b { display: inline-block; min-width: 20px; margin-left: 4px; padding: 0 5px; border-radius: 999px; background: var(--accent);
    color: #fff; font-size: 11px; text-align: center; }
  .drawer-tab[aria-expanded="true"] { display: none; }
  .drawer-x { display: block; position: absolute; top: 6px; right: 8px; z-index: 2; padding: 2px 8px; background: transparent; border: 0;
    font-size: 16px; color: var(--muted); }
  .evpanel .head, .evpanel .dhead { padding-right: 40px; }
  .pickbar { left: 8px; right: 8px; transform: none; font-size: 13px; }
  .legend { display: none; }
  /* the map fills what the header leaves (body is 100dvh), not a fixed height past the bottom of the screen: the county fit its center to a box half off the phone (rob 10-31) */
  .view[data-view="map"] { min-height: 280px; }
  .keys { grid-template-columns: repeat(5, 1fr); gap: 6px; }
  .fkeys { grid-template-columns: repeat(5, 1fr); gap: 6px; }
  .key { padding: 10px 2px 8px; font-size: 12px; letter-spacing: .02em; }
  .key.fk { font-size: 11px; padding: 8px 2px; }
  .lcd { padding: 10px 12px; height: 237px; }
  .lcd .top { gap: 6px; font-size: 12px; }
  .lcd #i-zone, .lcd #i-lo { display: none; }
  .lcd .ch { font-size: 22px; padding-right: 80px; }
  .lcd .qstat { top: 28px; right: 12px; font-size: 10px; }
  .lcd .tx { font-size: 16px; }
  .scan { padding: 12px 10px 40px; }
  .radio { padding: 12px; border-radius: 16px; }
  .playerbar { padding: 7px 10px; gap: 6px 8px; }
  .listen { padding: 6px 12px; }
  .svc button { padding: 3px 9px; }
  .np { flex-basis: 100%; order: 5; }
  .vol, .volrow { display: none; }
  .view[data-view="map"] .leaflet-bottom.leaflet-left { display: none; }
}
@media (max-width: 600px) {
  .where-menu { position: fixed; left: 8px; right: 8px; top: auto; width: auto; }
  nav.views a { display: flex; flex-direction: column; align-items: center; gap: 3px; font-size: 12px; line-height: 1.2; padding: 7px 2px; min-width: 0; }
  /* every icon in the same box, so the labels line up whether the icon is an emoji or an image */
  nav.views .ni { font-size: 21px; height: 24px; width: 24px; line-height: 24px; display: flex; align-items: center; justify-content: center; }
  nav.views .ni img { width: 22px; height: 22px; }
  nav.views a span { white-space: nowrap; line-height: 14px; }
}
@media (max-width: 860px) { .brand img.logo { width: 60px; height: 60px; } }
@media (max-width: 480px) { .brand { gap: 8px; } .brand img.logo { width: 54px; height: 54px; } .brand b { font-size: 15px; }
  nav.links { gap: 8px; } nav.links a { font-size: 14px; } }
@media (max-width: 480px) { .brand small { display: none; } .svc button { padding: 4px 9px; } }

/* ---------------------------------------------------------------- admin bits + toast */
#rg-toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%) translateY(20px); opacity: 0; z-index: 3000;
  background: #1f2a35; border: 1px solid var(--accent); color: var(--text); padding: 8px 14px; border-radius: 8px; transition: .2s; pointer-events: none; }
#rg-toast.on { opacity: 1; transform: translateX(-50%); }

/* The home-screen app draws edge to edge (viewport-fit=cover): what sits on the screen's bottom edge clears the iPhone's home
   indicator, and landscape keeps clear of the notch. env() is 0 everywhere else. (11-11 review) */
body { padding-left: env(safe-area-inset-left, 0px); padding-right: env(safe-area-inset-right, 0px); }
#rg-toast { bottom: calc(24px + env(safe-area-inset-bottom, 0px)); }
.view[data-view="map"] .leaflet-bottom { bottom: env(safe-area-inset-bottom, 0px); }
@media (max-width: 760px) { .evpanel { bottom: calc(8px + env(safe-area-inset-bottom, 0px)); } }
.adv-pick { padding: 6px 12px; background: #3a3220; border-bottom: 1px solid var(--ems); color: #ffe7a3; font-size: 12px; }
.adv-pick button { margin-left: 8px; padding: 1px 8px; font-size: 12px; }
.adm-ev { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 8px; }
.adm-ev button { font-size: 11px; padding: 2px 8px; }
.cl .act { display: flex; gap: 3px; flex-wrap: wrap; justify-content: flex-end; max-width: 150px; }

.dfoot { margin-top: 10px; font-size: 11px; color: var(--muted); opacity: .7; font-variant-numeric: tabular-nums; }

/* ---------------------------------------------------------------- call log + roster */
.lg-tools { position: sticky; top: 0; z-index: 5; }
.lg-tools input[type=search] { width: 260px; }
.lg-list { max-width: 1100px; margin: 0 auto; }
.lg-row { display: grid; grid-template-columns: 30px 96px 190px 1fr; gap: 10px; padding: 8px 14px; border-bottom: 1px solid #1f262e; align-items: start; }
.lg-row.playing { background: #17261c; }
.lg-row .pl { width: 28px; height: 28px; padding: 0; font-size: 11px; border-radius: 50%; }
.lg-row .pl:disabled { opacity: .3; cursor: default; }
.lg-when, .lg-ch { display: flex; flex-direction: column; font-size: 12px; font-variant-numeric: tabular-nums; padding-top: 3px; min-width: 0; }
.lg-when small, .lg-ch small { color: var(--muted); font-size: 11px; }
.lg-ch b { color: var(--text); font-weight: 600; }
td .dt { font-size: 10.5px; color: var(--muted); font-weight: 400; }   /* the short date under an incident's time */
.lg-tg { display: flex; align-items: center; gap: 6px; color: var(--c); font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lg-tg i, .ro-cs i { flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--c); }
.lg-tx { color: var(--text); overflow-wrap: anywhere; padding-top: 2px; }
.lg-meta { display: flex; flex-wrap: wrap; gap: 4px 12px; margin-top: 4px; font-size: 12px; color: var(--muted); }
.lg-inc { color: var(--accent); text-decoration: none; }
.lg-inc:hover { text-decoration: underline; }
.lg-more { text-align: center; padding: 16px 0 40px; }
.ro-wrap { max-width: 1100px; margin: 0 auto; }
.ro-about { margin: 10px 14px; font-size: 12px; }
/* The roster page scrolls as a whole, the table its full length (rob 10-26: no scroll box in the middle of the page);
   the headings stick to the top of the page as it scrolls */
.ro-tbl { border-bottom: 1px solid var(--line); }
.ro-tbl thead th { position: sticky; top: var(--pbar-h, 53px); z-index: 2; background: var(--bg); box-shadow: 0 1px 0 var(--line); }
.ro-tbl table { width: 100%; border-collapse: collapse; font-size: 13px; }
.ro-tbl th { text-align: left; color: var(--muted); font-weight: 600; font-size: 12px; padding: 6px 14px; border-bottom: 1px solid var(--line); }
.ro-tbl td { padding: 6px 14px; border-bottom: 1px solid #1f262e; vertical-align: top; }
.ro-tbl .mono { font-family: "JetBrains Mono", ui-monospace, monospace; font-size: 12px; color: var(--muted); }
.ro-tbl tr { color: var(--text); }
.ro-cs { font-weight: 700; white-space: nowrap; }
@media (max-width: 760px) { .ro-cs { white-space: normal; } }   /* (the Roster scrolled sideways at 390 px, 11-11 review) */
/* (iOS Safari zooms into any field under 16 px when it's focused, and stays zoomed: only the find box had it, 11-11 review) */
@media (max-width: 760px) { input, select, textarea { font-size: 16px; } }
.ro-cs i { display: inline-block; margin-right: 8px; vertical-align: 1px; }
.ro-tbl a { color: var(--accent); text-decoration: none; }
@media (max-width: 760px) {
  .lg-row { grid-template-columns: 30px 1fr; gap: 4px 10px; padding: 8px 10px; }
  .lg-when { flex-direction: row; gap: 8px; grid-column: 2; }
  .lg-ch { flex-direction: row; gap: 8px; grid-column: 2; padding-top: 0; }
  .lg-row .pl { grid-row: 1 / span 3; }
  .lg-tx { grid-column: 2; }
  .lg-tools input[type=search] { width: 100%; }
  .ro-tbl th:nth-child(2), .ro-tbl td:nth-child(2) { display: none; }   /* (the radio id; the key at the top says the colors) */
  .ro-tbl td, .ro-tbl th { padding: 6px 10px; }
}
@media (max-width: 760px) { .adv-tools .find { margin-left: 0; width: 100%; justify-content: flex-start; }
  .adv-tools .find input[type=search] { flex: 1 1 100%; width: 100%; } }
@media (max-width: 380px) { .online { font-size: 11px; } .brand img.logo { width: 46px; height: 46px; } .brand b { font-size: 14px; } nav.links { gap: 6px; } nav.links a { font-size: 13px; } }

/* advanced page: the AI summary thinks the incident type doesn't fit its calls */
.tflag { color: var(--ems); cursor: help; }
.tcheck { margin-top: 6px; padding: 6px 8px; border-left: 3px solid var(--ems); font-size: 13px; }

/* Roster: a unit that signed off (10-42) and hasn't been heard since: the 10-42 note in orange; its dot keeps the service color
   (rob 10-30). The key under the tools says what the colors are (the Service column went 10-30). */
.ro-42 { font-weight: 600; color: var(--priority); }
.ro-key { margin: 0 14px 6px; font-size: 12px; display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }
.ro-key span { display: inline-flex; align-items: center; gap: 6px; }
.ro-key i { width: 8px; height: 8px; border-radius: 50%; background: var(--c); display: inline-block; }
/* A unit tag on an incident (board, map) opens its radio traffic (rob 10-30) */
a.chip.u { text-decoration: none; cursor: pointer; }
a.chip.u:hover { background: #1b2a3a; }

/* ---------------------------------------------------------------- place history (core.js RG.placeHistory) */
a.place-h { color: inherit; text-decoration: underline dotted; text-underline-offset: 3px; cursor: pointer; }
a.place-h:hover { text-decoration-style: solid; }
dialog.place-dlg { width: min(560px, calc(100vw - 32px)); max-height: min(78vh, 720px); padding: 0; display: none;
  flex-direction: column; background: var(--panel); color: var(--text); border: 1px solid var(--line); border-radius: 12px;
  box-shadow: 0 16px 48px rgba(0, 0, 0, .55); font-family: Inter, system-ui, sans-serif; }
dialog.place-dlg[open] { display: flex; }
dialog.place-dlg::backdrop { background: rgba(5, 8, 12, .6); }
.ph-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; padding: 12px 14px;
  border-bottom: 1px solid var(--line); }
.ph-head b { font-size: 15px; } .ph-head small { display: block; color: var(--muted); font-size: 12px; margin-top: 2px; }
.ph-head button { padding: 2px 9px; }
.ph-list { overflow: auto; padding: 4px 0; }
.ph-ev { display: flex; gap: 12px; padding: 9px 14px; text-decoration: none; color: var(--text); border-left: 3px solid var(--c);
  border-bottom: 1px solid #222a33; }
.ph-ev:hover { background: var(--panel2); } .ph-ev.this { background: #1a2633; }
.ph-ev .d { flex: 0 0 62px; color: var(--muted); font-size: 12px; line-height: 1.35; font-variant-numeric: tabular-nums; }
.ph-ev .b { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.ph-ev .t { font-weight: 600; color: var(--c); } .ph-ev .t i { color: var(--muted); font-weight: 400; font-style: normal; }
.ph-ev .s { color: #b9c3ce; font-size: 13px; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 3;
  -webkit-box-orient: vertical; overflow: hidden; }
.ph-ev .m { color: var(--muted); font-size: 11.5px; }

/* The business at an incident's address, its call/unit counts, and the incident tags in the map's incident view */
.biz { color: var(--muted); font-weight: 400; }
.mev .n, .inc .n { color: var(--muted); font-size: 11.5px; margin-top: 1px; }
.dbody .chips { padding: 8px 12px 0; gap: 4px; }
.dbody .chip { font-size: 11px; padding: 1px 6px; border-radius: 3px; }
.dbody .chip.u { border-color: #345; color: #9cc8ff; }
.dbody .chip.alert { border-color: var(--bad); color: var(--bad); }
/* Address history: past 30 days only the summary is kept (no calls), so the row isn't a link */

/* Map incident view: the tags pop up from the call count instead of filling the panel */
.dcount { position: relative; cursor: help; white-space: nowrap; }
.dcount .dtag-i { font-style: normal; margin-left: 4px; color: var(--accent); }
.dcount .dtags { display: none; position: absolute; right: 0; top: calc(100% + 6px); z-index: 1000; width: min(320px, 80vw);
  max-height: 50vh; overflow-y: auto; padding: 8px; background: var(--panel); border: 1px solid var(--line); border-radius: 8px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, .5); white-space: normal; cursor: default; }
.dcount.open .dtags { display: block; }
/* (a tap leaves :hover and focus stuck on a phone, so a second tap could never close it, rob 10-31) */
@media (hover: hover) { .dcount:hover .dtags, .dcount:focus-within .dtags { display: block; } }
.dcount .dtags .chips { padding: 0; gap: 4px; }
.dcount .dtags .chip { font-size: 11px; padding: 1px 6px; border-radius: 3px; }
.dcount .dtags .chip.u { border-color: #345; color: #9cc8ff; }
.dcount .dtags .chip.alert { border-color: var(--bad); color: var(--bad); }

/* Compact player on phones (rob 10-30): it was four wrapped rows, 149 px. Listen, what's playing and where on one row, the services on the next. */
@media (max-width: 600px) {
  .playerbar { flex-wrap: wrap; gap: 6px 8px; padding: 6px 10px; }
  .listen { order: 1; flex: none; padding: 6px 12px; }
  .np { order: 2; flex: 1 1 0; flex-basis: 0; min-width: 0; font-size: 12px; }
  .where { order: 3; flex: none; }
  .where-btn { padding: 5px 8px; }
  .where-btn #where-lbl, .where-btn #alert-lbl { display: none; }
  .svc { order: 4; flex: 1 1 100%; flex-wrap: nowrap; gap: 5px; }
  .svc button { flex: 1 1 0; min-width: 0; justify-content: center; padding: 5px 4px; gap: 4px; font-size: 13px; white-space: nowrap; }
  #selchips { order: 5; flex: 1 1 100%; flex-wrap: nowrap; overflow-x: auto; }   /* (the listen bar's only: on every .chips an incident's units squeezed into one row, a word a line and as tall as the screen, rob 10-31) */
  #selchips:empty { display: none; }
}
/* map credit: the short line, tap "Sources" for all of them; the big map on a desktop has room for the full list */
.leaflet-container .leaflet-control-attribution { background: #1d2227; color: #8b96a3; border-top-left-radius: 4px; opacity: .92; }   /* the scanner's brandplate grey */
.leaflet-container .leaflet-control-attribution a { color: #a9b4c0; }
.leaflet-control-attribution .attr-full { display: none; }
.leaflet-control-attribution { white-space: nowrap; }
.leaflet-control-attribution.open { white-space: normal; max-width: calc(100vw - 16px); }
.leaflet-control-attribution.open .attr-short { display: none; }
.leaflet-control-attribution.open .attr-full { display: inline; }
@media (max-width: 760px) { .leaflet-container .leaflet-control-attribution { font-size: 10px; } }
@media (min-width: 761px) { #bigmap .attr-short { display: none; } #bigmap .attr-full { display: inline; } }
/* NCDOT's cameras (map.js): thumbnails on an active incident's card, under the summary; icons on the map, bigger zoomed in */
.dcams { display: flex; gap: 6px; margin: 8px 0 4px; }
.dcam { flex: 1 1 0; min-width: 0; padding: 0; border: 0; background: transparent; text-align: left; cursor: pointer; color: inherit; text-decoration: none; }
.dcam img { display: block; width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 6px; border: 1px solid var(--line); background: #0b0e12; }
.dcam span { display: block; font-size: 11px; color: var(--muted); margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.campin { --s: 20px; position: relative; display: flex; align-items: center; justify-content: center; width: var(--s); height: var(--s); margin: calc((30px - var(--s)) / 2);
  border-radius: 50%; background: #f4f6f8; border: 1.5px solid #1b1f24; box-shadow: 0 0 0 1.5px rgba(255, 255, 255, .55), 0 1px 4px rgba(0, 0, 0, .7); }
.campin svg { width: 84%; height: 84%; }   /* (rob 11-02: a bigger camera, less white around it) */
.campin .n { position: absolute; top: -5px; right: -7px; min-width: 13px; height: 13px; padding: 0 2px; border-radius: 7px; background: #1b1f24;
  color: #fff; font: 700 9px/13px system-ui, sans-serif; text-align: center; box-shadow: 0 0 0 1px #f4f6f8; }   /* (cameras sharing the icon) */
.cam-s .campin { --s: 15px; }
.cam-m .campin { --s: 20px; }
.cam-l .campin { --s: 25px; }
.campop img { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; margin: 6px 0 4px; border-radius: 6px; background: #0b0e12; }
.campop .k { color: var(--muted); font-size: 11px; }
/* a group of cameras taller than the map scrolls, its bar hidden (rob 11-03) */
.campop-wrap .leaflet-popup-scrolled { scrollbar-width: none; border: 0; }
.campop-wrap .leaflet-popup-scrolled::-webkit-scrollbar { display: none; }
/* the zoom readout on the map (admin setting map_zoom_readout; map.js zbox) */
.zoomtag { background: rgba(11, 14, 18, .85); color: #fff; font: 12px/1.4 ui-monospace, monospace; padding: 2px 7px; border-radius: 4px; border: 1px solid var(--line); }

/* a channel name that opens its call log (rob 11-14) */
a.tg-link { color: inherit; text-decoration: none; border-bottom: 1px dotted currentColor; }
a.tg-link:hover { text-decoration: none; border-bottom-style: solid; }
#lg-tg { max-width: 190px; }
#lg-tg.on { border-color: #4ea1ff; color: #9cc8ff; }

/* Volume sliders only where a page can set the volume with a mouse at hand (rob 11-15): phones and tablets use their own buttons,
   and iOS ignores a page's volume altogether (core.js marks it no-vol) */
@media (hover: none) and (pointer: coarse) { .vol, .volrow { display: none; } }
html.no-vol .vol, html.no-vol .volrow { display: none; }
