/* leon_radar — console-stijl: diepzee-blauw met fosforgroen, gemaakt om boven satellietbeelden leesbaar te blijven */

:root {
  --ink: #04121a;
  --panel: rgba(4, 20, 28, 0.9);
  --panel-solid: #061a24;
  --line: #16404b;
  --line-soft: rgba(102, 240, 194, 0.12);
  --text: #d3ebe6;
  --muted: #7a9ba0;
  --phosphor: #66f0c2;
  --cyan: #52c7ea;
  --amber: #ffc857;
  --alert: #ff5d5d;
  --rail: #ffd43b;
  --works: #ff9f43;

  --ac-civ: #c58bff;
  --ac-mil: #ffa24c;
  --ac-heli: #66f0c2;
  --ac-gnd: #8a9ba3;
  --ac-em: #ff4d5e;

  --f-display: "Chakra Petch", "Segoe UI", system-ui, sans-serif;
  --f-data: "IBM Plex Mono", ui-monospace, "Cascadia Mono", Consolas, monospace;

  --top-h: 46px;
  --radius-panel: 10px;
  --radius-ctrl: 6px;
}

* { box-sizing: border-box; }

html, body {
  height: 100%;
  margin: 0;
  background: var(--ink);
  color: var(--text);
  font: 13px/1.45 var(--f-data);
  -webkit-font-smoothing: antialiased;
}

body {
  display: grid;
  grid-template-rows: var(--top-h) minmax(0, 1fr) auto;
  grid-template-columns: minmax(0, 1fr); /* voorkomt dat lange inhoud (nieuwsticker) de pagina breder maakt */
  width: 100%;
  height: 100dvh;
  overflow: hidden;
  padding-top: env(safe-area-inset-top, 0px);
  padding-bottom: env(safe-area-inset-bottom, 0px);
}

button { font: inherit; color: inherit; }
svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
/* De kaart tekent lijnen en cirkels in een eigen svg-vlak: dat mag niet op 18 px blijven staan */
.leaflet-pane > svg, .leaflet-overlay-pane svg { width: auto; height: auto; fill: initial; stroke: initial; stroke-width: initial; }

:focus-visible { outline: 2px solid var(--phosphor); outline-offset: 2px; }

[hidden] { display: none !important; }

/* ---------- Bovenbalk ---------- */
.topbar {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 0 14px;
  background: linear-gradient(180deg, #06202b, var(--ink));
  border-bottom: 1px solid var(--line);
  position: relative;
  z-index: 1000;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--phosphor);
  text-decoration: none;
}
.brand-scope {
  width: 24px; height: 24px;
  border-radius: 50%;
  border: 1.5px solid var(--phosphor);
  background: conic-gradient(from 0deg, rgba(102,240,194,.75), rgba(102,240,194,0) 25%, transparent);
  animation: spin 4s linear infinite;
}
.brand-name {
  font: 700 19px/1 var(--f-display);
  letter-spacing: 0.06em;
  text-shadow: 0 0 12px rgba(102, 240, 194, 0.45);
}

.clock {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  font: 600 18px/1 var(--f-display);
  letter-spacing: 0.08em;
  color: var(--cyan);
  font-variant-numeric: tabular-nums;
}

.status { margin-left: auto; display: flex; align-items: center; gap: 12px; }
.lamp {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 11px; color: var(--muted);
}
.lamp::before {
  content: ""; width: 8px; height: 8px; border-radius: 50%;
  background: #33474d;
  transition: background .2s, box-shadow .2s;
}
.lamp.ok::before { background: var(--phosphor); box-shadow: 0 0 8px var(--phosphor); }
.lamp.bad::before { background: var(--alert); box-shadow: 0 0 8px var(--alert); }
.lamp.ok { color: var(--text); }
.lamp.flash::before { animation: lampflash .9s ease-out; }
@keyframes lampflash {
  0%   { background: #fff; box-shadow: 0 0 0 0 rgba(102,240,194,.9), 0 0 14px #fff; transform: scale(1.5); }
  100% { background: var(--phosphor); box-shadow: 0 0 0 8px rgba(102,240,194,0), 0 0 8px var(--phosphor); transform: scale(1); }
}
#lampData { min-width: 64px; font-variant-numeric: tabular-nums; }

.icon-btn {
  display: inline-grid; place-items: center;
  width: 32px; height: 32px;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: var(--radius-ctrl);
  color: var(--text);
  cursor: pointer;
}
.icon-btn:hover { border-color: var(--phosphor); color: var(--phosphor); }

.only-mobile { display: none; }

/* ---------- Kaart ---------- */
.stage { position: relative; min-height: 0; min-width: 0; overflow: hidden; }
#map { position: absolute; inset: 0; background: #0a2430; }

.leaflet-container { font-family: var(--f-data); }
.leaflet-control-attribution {
  background: rgba(4, 18, 26, 0.75) !important;
  color: var(--muted) !important;
  font-size: 10px;
}
.leaflet-control-attribution a { color: var(--cyan) !important; }

/* Radarsweep: een draaiende wig, gecentreerd op het radarcentrum */
#sweep {
  position: absolute;
  pointer-events: none;
  border-radius: 50%;
  z-index: 450;
  background: conic-gradient(from 0deg, rgba(102,240,194,0.28), rgba(102,240,194,0.06) 14%, transparent 22%);
  animation: spin 6s linear infinite;
  display: none;
  will-change: transform;
}
#sweep.on { display: block; }

@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Panelen ---------- */
.panel {
  position: absolute;
  z-index: 800;
  background: rgba(4, 20, 28, 0.94);
  border: 1px solid var(--line);
  border-radius: var(--radius-panel);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45);
}

.layer-panel {
  top: 12px; left: 12px;
  width: 268px;
  max-height: calc(100% - 24px);
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--line) transparent;
}

.layer-panel details + details { border-top: 1px solid var(--line); }

.layer-panel summary {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 12px;
  cursor: pointer;
  list-style: none;
  font: 600 14px/1 var(--f-display);
  color: var(--cyan);
  letter-spacing: 0.03em;
}
.layer-panel summary::-webkit-details-marker { display: none; }
.layer-panel summary::before {
  content: ""; width: 0; height: 0;
  border-left: 5px solid currentColor;
  border-top: 4px solid transparent;
  border-bottom: 4px solid transparent;
  transition: transform .15s;
}
.layer-panel details[open] > summary::before { transform: rotate(90deg); }
.layer-panel summary .hint { margin-left: auto; font: 400 11px var(--f-data); color: var(--muted); }

.chip-btn {
  margin-left: auto;
  padding: 3px 8px;
  font: 500 11px/1 var(--f-data);
  color: var(--alert);
  background: rgba(255, 93, 93, 0.08);
  border: 1px solid rgba(255, 93, 93, 0.45);
  border-radius: 4px;
  cursor: pointer;
}
.chip-btn:hover { background: rgba(255, 93, 93, 0.18); }

.rows { list-style: none; margin: 0; padding: 0 0 6px; }
.row {
  display: flex; align-items: center; gap: 10px;
  min-height: 36px;
  padding: 0 12px;
  border-top: 1px solid var(--line-soft);
}
.row .ico { color: var(--c); display: inline-grid; }
.row .lbl { flex: 1; }
.row .count {
  font-size: 10.5px;
  color: var(--phosphor);
  background: rgba(102, 240, 194, 0.08);
  padding: 2px 6px;
  border-radius: 4px;
  font-variant-numeric: tabular-nums;
}
.row.is-soon { color: var(--muted); }
.row.is-soon .count { color: var(--muted); background: rgba(122, 155, 160, 0.1); }

.legend-row {
  display: flex; flex-wrap: wrap; gap: 4px 10px;
  padding: 2px 12px 8px 40px;
  font-size: 10.5px; color: var(--muted);
}
.legend-row i {
  display: inline-block; width: 7px; height: 7px; margin-right: 4px;
  border-radius: 50%; background: var(--c); vertical-align: 1px;
}

/* Schakelaar */
.sw {
  position: relative;
  width: 36px; height: 20px;
  flex: none;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #0b2a35;
  cursor: pointer;
  transition: background .15s, border-color .15s;
}
.sw::after {
  content: ""; position: absolute; top: 2px; left: 2px;
  width: 14px; height: 14px; border-radius: 50%;
  background: #56747b;
  transition: transform .15s, background .15s;
}
.sw[aria-checked="true"] { background: rgba(102, 240, 194, 0.25); border-color: var(--phosphor); }
.sw[aria-checked="true"]::after { transform: translateX(16px); background: var(--phosphor); box-shadow: 0 0 8px var(--phosphor); }
.sw.busy::after { background: var(--amber); }

.basemaps { display: flex; gap: 6px; padding: 2px 12px 10px; flex-wrap: wrap; }
.basemaps label {
  flex: 1;
  text-align: center;
  padding: 6px 4px;
  border: 1px solid var(--line);
  border-radius: var(--radius-ctrl);
  cursor: pointer;
  font-size: 12px;
}
.basemaps input { position: absolute; opacity: 0; pointer-events: none; }
.basemaps label:has(input:checked) { border-color: var(--phosphor); color: var(--phosphor); background: rgba(102, 240, 194, 0.08); }
.basemaps label:has(input:focus-visible) { outline: 2px solid var(--phosphor); }

/* ---------- Zoeken ---------- */
.search {
  position: absolute;
  top: 12px; left: 50%;
  transform: translateX(-50%);
  width: min(360px, calc(100% - 620px));
  min-width: 220px;
  z-index: 820;
}
.search input {
  width: 100%;
  padding: 9px 12px;
  font: 13px var(--f-data);
  color: var(--text);
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius-ctrl);
}
.search input::placeholder { color: var(--muted); }
.search input:focus { outline: none; border-color: var(--phosphor); }
.search-results {
  list-style: none; margin: 4px 0 0; padding: 4px;
  background: var(--panel-solid);
  border: 1px solid var(--line);
  border-radius: var(--radius-ctrl);
  max-height: 320px; overflow-y: auto;
}
.search-results li {
  display: flex; gap: 10px; justify-content: space-between;
  padding: 7px 8px; border-radius: 4px; cursor: pointer;
}
.search-results li:hover, .search-results li[aria-selected="true"] { background: rgba(102, 240, 194, 0.1); }
.search-results .cs { color: var(--phosphor); font-weight: 600; }
.search-results .meta { color: var(--muted); }
.search-results .empty { color: var(--muted); cursor: default; }

/* ---------- Detailpaneel ---------- */
.right-col {
  position: absolute;
  top: 12px; right: 12px;
  width: 330px;
  max-height: calc(100% - 150px);
  display: flex; flex-direction: column; gap: 10px;
  z-index: 800;
  pointer-events: none;
}
.right-col > .panel {
  position: relative;
  pointer-events: auto;
  min-height: 0;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--line) transparent;
}
.right-col > .detail-panel { flex: 0 1 auto; min-height: 220px; }
.right-col > .ns-panel { flex: 0 3 auto; min-height: 140px; }
.detail-head {
  display: flex; align-items: flex-start; justify-content: space-between;
  padding: 12px 12px 8px;
}
.detail-head h2 {
  margin: 0;
  font: 700 24px/1.1 var(--f-display);
  color: var(--phosphor);
  letter-spacing: 0.04em;
}
.detail-head .sub { margin: 3px 0 0; color: var(--muted); font-size: 12px; }

.photo {
  margin: 0 12px;
  aspect-ratio: 16 / 9;
  border: 1px solid var(--line);
  border-radius: var(--radius-ctrl);
  overflow: hidden;
  display: grid; place-items: center;
  background: #0a2430;
  position: relative;
}
.photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.photo figcaption {
  position: absolute; left: 0; right: 0; bottom: 0;
  padding: 3px 6px; font-size: 10px;
  background: linear-gradient(transparent, rgba(0,0,0,.75));
}
.photo figcaption a { color: #fff; text-decoration: none; }
.photo-empty { color: var(--muted); font-size: 12px; }

.readout {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 1px;
  margin: 12px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--radius-ctrl);
  overflow: hidden;
}
.readout div { background: var(--panel-solid); padding: 8px 10px; }
.readout span { display: block; font-size: 11px; color: var(--muted); }
.readout b {
  font: 600 17px/1.2 var(--f-display);
  color: var(--cyan);
  font-variant-numeric: tabular-nums;
}
.readout b small { font: 400 11px var(--f-data); color: var(--muted); margin-left: 3px; }

.facts {
  display: grid; grid-template-columns: auto 1fr;
  gap: 5px 12px;
  margin: 0 12px 10px;
  font-size: 12px;
}
.facts dt { color: var(--muted); }
.facts dd { margin: 0; text-align: right; color: var(--text); overflow-wrap: anywhere; }

.lost { margin: 0 12px 10px; color: var(--amber); font-size: 12px; }

.detail-actions { display: flex; gap: 8px; padding: 0 12px 12px; }
.btn {
  flex: 1;
  padding: 8px;
  font: 600 13px var(--f-display);
  letter-spacing: 0.03em;
  color: var(--phosphor);
  background: rgba(102, 240, 194, 0.06);
  border: 1px solid var(--line);
  border-radius: var(--radius-ctrl);
  cursor: pointer;
}
.btn:hover { border-color: var(--phosphor); }
.btn[aria-pressed="true"] { background: var(--phosphor); color: var(--ink); border-color: var(--phosphor); }

/* ---------- Zoombalk, kompas, legenda ---------- */
.zoombar {
  position: absolute;
  bottom: 14px; left: 50%;
  transform: translateX(-50%);
  z-index: 800;
  display: flex; align-items: center; gap: 8px;
  padding: 6px 8px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius-panel);
}
.zoombar input[type=range] { width: 150px; accent-color: var(--phosphor); }

.compass {
  position: absolute;
  right: 14px; bottom: 74px;
  z-index: 800;
  width: 56px; height: 56px;
  padding: 0;
  border-radius: 50%;
  background: var(--panel);
  border: 1px solid var(--line);
  cursor: pointer;
}
.compass svg { width: 100%; height: 100%; stroke-width: 1; }
.compass circle { stroke: var(--line); }
.compass .n { fill: var(--alert); stroke: none; }
.compass .s { fill: #56747b; stroke: none; }
.compass text { fill: var(--muted); stroke: none; font: 600 6px var(--f-display); text-anchor: middle; }
.compass:hover circle { stroke: var(--phosphor); }

.temp-legend {
  position: absolute;
  right: 14px; bottom: 14px;
  z-index: 800;
  width: 190px;
  padding: 6px 10px 5px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius-panel);
  font-size: 10px; color: var(--muted);
}
.tl-title { display: block; margin-bottom: 4px; }
.tl-bar {
  display: block; height: 6px; border-radius: 3px;
  background: linear-gradient(90deg, #3a6cff 0%, #3fd0ff 22%, #66f0c2 44%, #ffd166 67%, #ff7a3d 89%, #ff3d3d 100%);
}
.tl-ticks { display: flex; justify-content: space-between; margin-top: 2px; }
.tl-ticks i { font-style: normal; }

/* ---------- Kaartsymbolen ---------- */
.ac-wrap { background: none; border: none; }
.ac {
  width: 100%; height: 100%;
  color: var(--c);
  transform: rotate(var(--rot, 0deg));
  transition: transform .6s ease-out;
}
/* Donkere rand in het icoon zelf in plaats van een schaduwfilter: veel lichter voor de browser */
.ac svg { width: 100%; height: 100%; fill: currentColor; stroke: rgba(0,0,0,.85); stroke-width: 1.3; paint-order: stroke; }
.ac.sel { color: #fff; filter: drop-shadow(0 0 6px var(--c)) drop-shadow(0 0 2px #000); }
.ac.em { animation: pulse 1s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .35; } }

.temp-wrap { background: none; border: none; }
.temp {
  display: inline-block;
  transform: translate(-50%, -50%);
  padding: 1px 4px;
  font: 600 11px/1.2 var(--f-data);
  color: var(--tc);
  text-shadow: 0 0 3px #000, 0 0 3px #000, 0 0 6px #000;
  white-space: nowrap;
  cursor: pointer;
}

.ring-label {
  background: none; border: none;
  font: 600 11px/14px var(--f-data);
  color: var(--ring-label, #d9fff2);
  text-shadow: 0 0 3px var(--ring-shadow, #000), 0 0 3px var(--ring-shadow, #000), 0 0 6px var(--ring-shadow, #000);
  white-space: nowrap;
}

.me-dot {
  width: 14px; height: 14px; border-radius: 50%;
  background: var(--cyan); border: 2px solid #fff;
  box-shadow: 0 0 0 6px rgba(82, 199, 234, 0.25);
}

.leaflet-tooltip.lr-tip, .leaflet-popup-content-wrapper, .leaflet-popup-tip {
  background: var(--panel-solid);
  color: var(--text);
  border: 1px solid var(--line);
  box-shadow: 0 6px 18px rgba(0,0,0,.5);
  font-family: var(--f-data);
}
.leaflet-tooltip.lr-tip { font-size: 11px; padding: 4px 7px; }
.leaflet-tooltip.lr-tip::before { border-top-color: var(--line); }
.leaflet-tooltip.lr-tip b { color: var(--phosphor); }
.leaflet-popup-content { margin: 10px 12px; font-size: 12px; line-height: 1.5; }
.leaflet-popup-content h3 { margin: 0 0 4px; font: 600 15px var(--f-display); color: var(--amber); }
.leaflet-container a.leaflet-popup-close-button { color: var(--muted); }

/* ---------- Onderbalk ---------- */
.bottom { background: var(--ink); border-top: 1px solid var(--line); position: relative; z-index: 1000; min-width: 0; overflow: hidden; }

.ticker { display: flex; align-items: center; height: 30px; border-bottom: 1px solid var(--line-soft); min-width: 0; }
.ticker-label {
  flex: none;
  padding: 0 12px;
  font: 600 12px var(--f-display);
  color: var(--cyan);
  border-right: 1px solid var(--line);
  height: 100%; display: flex; align-items: center;
}
.ticker-viewport { flex: 1 1 0; min-width: 0; overflow: hidden; height: 100%; position: relative; }
.ticker-track {
  display: inline-flex; gap: 48px;
  white-space: nowrap;
  height: 100%; align-items: center;
  padding-left: 100%;
  animation: ticker var(--dur, 120s) linear infinite;
}
.ticker-track:hover { animation-play-state: paused; }
.ticker-track a { color: var(--text); text-decoration: none; }
.ticker-track a:hover { color: var(--phosphor); }
.ticker-track a::before { content: "▸"; color: var(--phosphor); margin-right: 8px; }
@keyframes ticker { to { transform: translateX(-100%); } }

.statusbar {
  display: flex; gap: 16px; align-items: center;
  height: 24px; padding: 0 12px;
  font-size: 10.5px; color: var(--muted);
  font-variant-numeric: tabular-nums;
  white-space: nowrap; overflow: hidden;
}
.statusbar .grow { flex: 1; }
#online { color: var(--phosphor); }

/* ---------- Mobiel ---------- */
@media (max-width: 700px) {
  .only-mobile { display: inline-grid; }
  .clock { display: none; }
  .lamp { font-size: 0; gap: 0; min-width: 0 !important; }
  .brand-name { font-size: 16px; }

  .layer-panel {
    width: min(300px, calc(100% - 24px));
    transform: translateX(calc(-100% - 20px));
    transition: transform .2s ease-out;
  }
  .layer-panel.open { transform: none; }

  .search { width: calc(100% - 24px); left: 12px; transform: none; }

  .right-col {
    top: auto; bottom: 0; right: 0; left: 0;
    width: auto; max-height: 62%;
    gap: 0;
  }
  .right-col > .panel { border-radius: var(--radius-panel) var(--radius-panel) 0 0; }
  .right-col > .detail-panel:not([hidden]) ~ .ns-panel { display: none; }
  .compass { display: none; }
  .zoombar { bottom: 12px; left: 12px; transform: none; }
  .zoombar input[type=range] { width: 90px; }
  .temp-legend { width: 150px; }
  .statusbar #cursorPos, .statusbar #dataAge { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .brand-scope, #sweep, .ac.em { animation: none; }
  .ticker-track { animation-duration: 0s; animation: none; padding-left: 12px; overflow-x: auto; }
  .ac { transition: none; }
}

/* ---------- NS-paneel ---------- */
.ns-head { display: flex; align-items: center; gap: 6px; padding: 10px 12px 6px; }
.ns-head h2 { flex: 1; margin: 0; font: 700 17px/1.1 var(--f-display); color: var(--rail); letter-spacing: .03em; }
.ns-head .icon-btn { width: 28px; height: 28px; }
.ns-sum {
  margin: 4px 12px 10px; padding: 10px 12px;
  border: 1px solid var(--line); border-radius: var(--radius-ctrl);
  background: var(--panel-solid);
  display: grid; grid-template-columns: auto 1fr; align-items: baseline; gap: 0 10px;
}
.ns-sum > b { font: 700 34px/1 var(--f-display); color: var(--rail); }
.ns-sum > span { color: var(--muted); font-size: 12px; }
.ns-split { grid-column: 1 / -1; display: flex; gap: 14px; list-style: none; margin: 8px 0 0; padding: 0; font-size: 11px; color: var(--muted); }
.ns-split b { color: var(--text); font-weight: 600; }
.ns-split i, .ns-item::before { display: inline-block; width: 8px; height: 8px; border-radius: 2px; margin-right: 5px; }
.t-dis { background: var(--alert); }
.t-mnt { background: var(--works); }
.t-cal { background: #d06bff; }
.ns-list { list-style: none; margin: 0; padding: 0 12px; display: grid; gap: 8px; }
.ns-item {
  padding: 8px 10px 8px 12px;
  border: 1px solid var(--line); border-left: 3px solid var(--tc, var(--works));
  border-radius: var(--radius-ctrl);
  background: rgba(0,0,0,.2);
  cursor: pointer;
}
.ns-item::before { display: none; }
.ns-item:hover, .ns-item.active { border-color: var(--tc); background: rgba(255, 212, 59, .05); }
.ns-item h3 { margin: 0 0 3px; font: 600 13.5px/1.3 var(--f-display); color: var(--text); }
.ns-item p { margin: 0; font-size: 11.5px; color: var(--muted); }
.ns-item .alt { color: var(--rail); margin-top: 4px; }
.ns-empty { color: var(--muted); font-size: 12px; padding: 4px 0; }
.ns-foot { margin: 8px 12px 10px; font-size: 10px; color: var(--muted); }

/* ---------- Treinen ---------- */
.tr-wrap { background: none; border: none; }
.tr {
  width: 100%; height: 100%;
  display: grid; place-items: center;
  transform: rotate(var(--rot, 0deg));
  transition: transform .6s ease-out;
}
.tr span {
  width: 12px; height: 12px;
  border-radius: 3px;
  background: var(--tc, var(--rail));
  border: 1.5px solid #10202a;
  box-shadow: 0 0 5px rgba(255, 212, 59, .6);
  position: relative;
}
.tr span::after {
  content: ""; position: absolute; left: 50%; top: -6px; transform: translateX(-50%);
  border-left: 4px solid transparent; border-right: 4px solid transparent;
  border-bottom: 5px solid var(--tc, var(--rail));
}
.tr.still span::after { display: none; }
.train-pop h3 { color: var(--rail); }
.train-pop .stops { list-style: none; margin: 6px 0 0; padding: 0; max-height: 190px; overflow-y: auto; }
.train-pop .stops li { display: flex; gap: 8px; padding: 2px 0; border-bottom: 1px solid rgba(102,240,194,.07); }
.train-pop .stops time { color: var(--cyan); min-width: 38px; font-variant-numeric: tabular-nums; }
.train-pop .stops .late { color: var(--alert); }
.train-pop .stops .gone { opacity: .45; }
.train-pop .stops .x { text-decoration: line-through; color: var(--alert); }
.train-pop .trk { margin-left: auto; color: var(--muted); }
.ac-wrap .ac { padding: 4px; }

/* ---------- Wegen en pech (NDW) ---------- */
:root {
  --r-file: #ff3b30;
  --r-queue: #ff9500;
  --r-slow: #ffd60a;
  --r-acc: #ff4d6d;
  --r-pech: #ffa24c;
  --r-closed: #d06bff;
  --r-work: #ffd166;
  --r-rush: #34d399;
  --r-other: #52c7ea;
}
.chip-filters { padding-top: 0; }
.chip-filters button {
  display: inline-flex; align-items: center;
  padding: 2px 6px;
  font: inherit; font-size: 10.5px;
  color: var(--text);
  background: rgba(255,255,255,.04);
  border: 1px solid var(--line);
  border-radius: 10px;
  cursor: pointer;
}
.chip-filters button[aria-pressed="false"] { color: var(--muted); opacity: .55; text-decoration: line-through; }
.chip-filters button:hover { border-color: var(--phosphor); }

.rd-wrap { background: none; border: none; }
.rd {
  width: 100%; height: 100%;
  display: grid; place-items: center;
  border-radius: 5px;
  background: var(--rc);
  border: 2px solid rgba(0,0,0,.65);
  color: #10171c;
  font: 800 11px/1 var(--f-display);
  box-shadow: 0 0 7px var(--rc);
  transform: rotate(45deg);
}
.rd span { transform: rotate(-45deg); }
.road-pop h3 { margin: 0 0 4px; }
.road-pop .rdno {
  display: inline-block; padding: 1px 6px; margin-right: 6px;
  border-radius: 3px; background: #c8102e; color: #fff;
  font: 700 11px/16px var(--f-display);
}
.road-pop .rdno.n { background: #f5c400; color: #111; }
.road-pop .meta { color: var(--muted); font-size: 11px; margin-top: 4px; }
.road-item .rdno { display: inline-block; padding: 0 5px; margin-right: 6px; border-radius: 3px; background: #c8102e; color: #fff; font: 700 10.5px/15px var(--f-display); }
.road-item .rdno.n { background: #f5c400; color: #111; }
.road-sum > b { color: var(--r-file) !important; }
.road-panel .ns-head h2 { color: var(--r-file); }
.road-panel .ns-split { flex-wrap: wrap; gap: 6px 14px; }

/* ---------- Bus, tram, metro, veerboot ---------- */
:root {
  --ov-bus: #4cc9f0;
  --ov-tram: #ff5ca8;
  --ov-metro: #ffb703;
  --ov-boot: #2ec4b6;
}
.ov-wrap { background: none; border: none; }
.ov-tag {
  display: inline-block;
  transform: translate(-50%, -50%);
  min-width: 20px;
  padding: 1px 4px;
  border-radius: 4px;
  background: var(--oc);
  color: #06141a;
  border: 1.5px solid rgba(0,0,0,.6);
  font: 700 10px/13px var(--f-display);
  text-align: center;
  white-space: nowrap;
  box-shadow: 0 1px 4px rgba(0,0,0,.6);
  cursor: pointer;
}
.ov-pop h3 { margin: 0 0 3px; }
.ov-pop .lijn {
  display: inline-block; min-width: 22px; padding: 0 6px; margin-right: 6px;
  border-radius: 4px; background: var(--oc); color: #06141a;
  font: 700 12px/18px var(--f-display); text-align: center;
}
.ov-pop .meta { color: var(--muted); font-size: 11px; margin-top: 4px; }

/* ---------- Zeedata en waterstanden (RWS) ---------- */
:root { --sea: #2ec27e; }
.sea-wrap, .wl-wrap { background: none; border: none; }
.sea-bub {
  display: grid; place-items: center;
  width: 100%; height: 100%;
  border-radius: 50%;
  background: radial-gradient(circle, color-mix(in srgb, var(--hc) 55%, transparent) 0%, color-mix(in srgb, var(--hc) 18%, transparent) 60%, transparent 72%);
  color: #fff;
  font: 700 12px/1 var(--f-data);
  text-shadow: 0 0 3px #000, 0 0 3px #000;
  cursor: pointer;
}
.wl-tag {
  display: inline-block;
  transform: translate(-50%, -50%);
  padding: 1px 5px;
  border-radius: 10px;
  background: rgba(4, 20, 28, .88);
  border: 1px solid var(--wc);
  color: var(--wc);
  font: 600 10.5px/14px var(--f-data);
  white-space: nowrap;
  cursor: pointer;
}
.rws-pop h3 { margin: 0 0 6px; color: var(--sea); }
.rws-pop table { border-collapse: collapse; width: 100%; font-size: 12px; }
.rws-pop td { padding: 2px 0; }
.rws-pop td:first-child { color: var(--sea); padding-right: 14px; }
.rws-pop td:last-child { text-align: right; color: var(--cyan); font-weight: 600; white-space: nowrap; }
.rws-pop .arr { display: inline-block; width: 13px; height: 13px; vertical-align: -2px; margin-right: 4px; color: var(--cyan); }
.rws-pop .arr svg { width: 13px; height: 13px; stroke-width: 2.4; }
.rws-pop .src { margin-top: 6px; color: var(--muted); font-size: 10.5px; }

/* ---------- Schepen (AIS) ---------- */
:root {
  --sh-cargo: #4ade80;
  --sh-tanker: #f87171;
  --sh-pass: #60a5fa;
  --sh-fish: #fb923c;
  --sh-work: #facc15;
  --sh-leisure: #f472b6;
  --sh-other: #94a3b8;
}
.sh-wrap { background: none; border: none; }
.sh {
  width: 100%; height: 100%;
  color: var(--sc);
  transform: rotate(var(--rot, 0deg));
  transition: transform .6s ease-out;
}
.sh svg { width: 100%; height: 100%; fill: currentColor; stroke: rgba(0,0,0,.85); stroke-width: 1.4; paint-order: stroke; }
.ship-pop h3 { margin: 0 0 2px; }
.ship-pop .sub { color: var(--muted); font-size: 11px; margin-bottom: 6px; }
.ship-pop table { border-collapse: collapse; width: 100%; font-size: 12px; }
.ship-pop td { padding: 2px 0; vertical-align: top; }
.ship-pop td:first-child { color: var(--muted); padding-right: 12px; white-space: nowrap; }
.ship-pop td:last-child { text-align: right; }
.ship-pop .more {
  margin-top: 8px; width: 100%;
  padding: 5px 8px;
  font: 600 12px var(--f-display);
  color: var(--phosphor);
  background: rgba(102,240,194,.06);
  border: 1px solid var(--line);
  border-radius: var(--radius-ctrl);
  cursor: pointer;
}
.ship-pop .more:hover { border-color: var(--phosphor); }
.ship-pop .extra { margin-top: 6px; }

/* ---------- Route en tijdlijn in het vliegtuigpaneel ---------- */
.route { margin: 12px 12px 0; padding: 10px 12px 8px; border: 1px solid var(--line); border-radius: var(--radius-ctrl); background: var(--panel-solid); }
.rt-ends { display: grid; grid-template-columns: 1fr auto 1fr; align-items: end; gap: 8px; }
.rt-ap { display: flex; flex-direction: column; min-width: 0; }
.rt-ap b { font: 700 20px/1 var(--f-display); color: var(--text); letter-spacing: .03em; }
.rt-ap span { font-size: 11px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rt-to { text-align: right; align-items: flex-end; }
.rt-left { font: 600 12px var(--f-display); color: var(--phosphor); text-align: center; white-space: nowrap; padding-bottom: 2px; }
.rt-bar { position: relative; height: 4px; margin: 14px 4px 10px; border-radius: 2px; background: repeating-linear-gradient(90deg, var(--line) 0 6px, transparent 6px 10px); }
.rt-bar i { position: absolute; left: 0; top: 0; bottom: 0; border-radius: 2px; background: var(--phosphor); box-shadow: 0 0 6px var(--phosphor); transition: width .6s; }
.rt-plane { position: absolute; top: 50%; width: 20px; height: 20px; transform: translate(-50%, -50%) rotate(90deg); color: var(--phosphor); transition: left .6s; filter: drop-shadow(0 0 3px #000); }
.rt-plane svg { width: 100%; height: 100%; fill: currentColor; stroke: none; }
.rt-bar::before, .rt-bar::after { content: ""; position: absolute; top: 50%; width: 8px; height: 8px; border-radius: 50%; transform: translate(-50%, -50%); background: var(--text); }
.rt-bar::before { left: 0; }
.rt-bar::after { left: 100%; }
.rt-meta { margin: 0; font-size: 11px; color: var(--muted); }
.route.doubt .rt-bar i, .route.doubt .rt-plane { background: none; color: var(--amber); box-shadow: none; }
.route.doubt .rt-bar i { background: var(--amber); }
.route.doubt .rt-meta { color: var(--amber); }

/* ---------- NS-stations en vertrekbord ---------- */
.board h3 { margin: 0 0 6px; color: var(--rail); }
.board .tabs { display: flex; gap: 4px; margin-bottom: 6px; }
.board .tabs button {
  flex: 1; padding: 4px 6px;
  font: 600 12px var(--f-display);
  color: var(--muted);
  background: transparent;
  border: 1px solid var(--line);
  border-radius: var(--radius-ctrl);
  cursor: pointer;
}
.board .tabs button[aria-selected="true"] { color: var(--ink); background: var(--rail); border-color: var(--rail); }
.board ol { list-style: none; margin: 0; padding: 0; max-height: 300px; overflow-y: auto; scrollbar-width: thin; }
.board li {
  display: grid; grid-template-columns: 48px 1fr auto; gap: 2px 8px;
  padding: 5px 0; border-bottom: 1px solid rgba(255, 212, 59, .08);
  font-size: 12px;
}
.board .t { font-variant-numeric: tabular-nums; color: var(--text); font-weight: 600; }
.board .t small { display: block; color: var(--alert); font-weight: 600; font-size: 10.5px; }
.board .w b { font-weight: 600; color: var(--text); }
.board .w span { display: block; color: var(--muted); font-size: 10.5px; }
.board .w .cat { display: inline-block; padding: 0 4px; margin-right: 5px; border-radius: 3px; background: rgba(255, 212, 59, .15); color: var(--rail); font: 700 10px/15px var(--f-data); }
.board .sp { text-align: right; font: 700 14px/1.1 var(--f-display); color: var(--cyan); }
.board .sp.chg { color: var(--amber); }
.board .sp s { display: block; font: 400 10px var(--f-data); color: var(--muted); }
.board li.x .t, .board li.x .w b { text-decoration: line-through; color: var(--alert); }
.board .msg { grid-column: 2 / -1; font-size: 10.5px; color: var(--amber); font-style: italic; }
.board .upd { margin-top: 6px; font-size: 10px; color: var(--muted); }

/* ---------- Stationsiconen ---------- */
:root { --st-big: #ffd43b; --st-small: #7dd3fc; }
.st-wrap { background: none; border: none; }
.st-ico {
  width: 100%; height: 100%;
  display: grid; place-items: center;
  border-radius: 28%;
  background: var(--st-bg, var(--st-big));
  border: 2px solid #10202a;
  box-shadow: 0 1px 4px rgba(0,0,0,.7);
  cursor: pointer;
}
.st-ico svg { width: 78%; height: 78%; }
.st-ico .b { fill: #10202a; }
.st-ico .w { fill: var(--st-bg, var(--st-big)); }
.st-ico .r { fill: none; stroke: #10202a; stroke-width: 1.8; stroke-linecap: round; }
.st-s { --st-bg: var(--st-small); }
.st-s .st-ico { border-width: 1.5px; border-radius: 50%; }
.st-xl .st-ico { box-shadow: 0 0 0 2px rgba(255,212,59,.35), 0 2px 6px rgba(0,0,0,.7); }
.st-wrap:hover .st-ico { transform: scale(1.12); }
.st-name {
  position: absolute; left: 100%; top: 50%;
  transform: translate(6px, -50%);
  font: 700 11.5px/1 var(--f-display);
  color: var(--st-big);
  white-space: nowrap;
  text-shadow: 0 0 3px #000, 0 0 3px #000, 0 0 6px #000;
  pointer-events: none;
  display: none;
}
.st-names .st-name { display: block; }
.st-hide-s .st-s, .st-hide-m .st-m { display: none; }

/* ---------- Matrixborden ---------- */
:root { --msi-red: #ff3b30; }
.msi-wrap { background: none; border: none; }
.gantry {
  display: inline-flex; gap: 2px;
  transform: translate(-50%, -50%);
  padding: 2px;
  background: #1b1f22;
  border: 1.5px solid #5b6770;
  border-radius: 3px;
  box-shadow: 0 1px 5px rgba(0,0,0,.8);
  cursor: pointer;
}
.gantry .ms {
  position: relative;
  width: 22px; height: 22px;
  display: grid; place-items: center;
  background: #050607;
  border-radius: 2px;
  font: 700 10px/1 var(--f-data);
  color: #f5f5f5;
}
.gantry.big .ms { width: 34px; height: 34px; font-size: 14px; }
.gantry .ms svg { width: 76%; height: 76%; }
.gantry .ms.ring::before { content: ""; position: absolute; inset: 2px; border: 2px solid var(--msi-red); border-radius: 50%; }
.gantry.big .ms.ring::before { border-width: 3px; }
.gantry .ms.flash::after {
  content: ""; position: absolute; top: 1px; left: 1px; width: 4px; height: 4px; border-radius: 50%;
  background: #ffb020; box-shadow: calc(100% + 11px) 0 0 #ffb020;
  animation: msiflash 1s steps(2) infinite;
}
.gantry.big .ms.flash::after { box-shadow: 26px 0 0 #ffb020, 0 26px 0 #ffb020, 26px 26px 0 #ffb020; }
@keyframes msiflash { 50% { opacity: 0; } }
.msi-pop h3 { margin: 0 0 8px; color: var(--text); }
.msi-pop .rdno { display: inline-block; padding: 0 6px; margin-right: 6px; border-radius: 3px; background: #c8102e; color: #fff; font: 700 12px/18px var(--f-display); }
.msi-pop .gantry { transform: none; }
.msi-pop ul { list-style: none; margin: 8px 0 0; padding: 0; font-size: 12px; }
.msi-pop li { padding: 1px 0; color: var(--muted); }
.msi-pop li b { color: var(--text); font-weight: 600; }
@media (prefers-reduced-motion: reduce) { .gantry .ms.flash::after { animation: none; } }

/* ---------- Verkeerscamera's ---------- */
.cam-wrap { background: none; border: none; }
.cam-ico {
  width: 100%; height: 100%;
  display: grid; place-items: center;
  border-radius: 50%;
  background: #0b3440;
  border: 2px solid var(--cyan);
  color: var(--cyan);
  box-shadow: 0 1px 5px rgba(0,0,0,.7);
  cursor: pointer;
}
.cam-ico svg { width: 60%; height: 60%; stroke-width: 2.2; }
.cam-wrap:hover .cam-ico { background: var(--cyan); color: #06141a; }
.cam-pop h3 { margin: 0 0 2px; color: var(--cyan); }
.cam-pop .rdno { display: inline-block; padding: 0 6px; margin-right: 6px; border-radius: 3px; background: #c8102e; color: #fff; font: 700 12px/18px var(--f-display); }
.cam-pop p { margin: 0 0 8px; color: var(--muted); font-size: 11.5px; }
.cam-pop .player { position: relative; width: 100%; aspect-ratio: 16 / 9; background: #000; border-radius: 6px; overflow: hidden; }
.cam-pop .player iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.cam-pop .links { margin-top: 6px; font-size: 11px; display: flex; justify-content: space-between; gap: 8px; }
.cam-pop .links a { color: var(--cyan); }
.leaflet-popup.cam-popup .leaflet-popup-content { width: 340px !important; }
@media (max-width: 700px) { .leaflet-popup.cam-popup .leaflet-popup-content { width: 76vw !important; } }

/* ---------- Welkomstvenster ---------- */
.welcome {
  width: min(520px, calc(100% - 32px));
  max-height: calc(100% - 40px);
  overflow-y: auto;
  padding: 22px 24px 20px;
  color: var(--text);
  background: var(--panel-solid);
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: 0 20px 60px rgba(0,0,0,.6);
  font-size: 13.5px; line-height: 1.55;
}
.welcome::backdrop { background: rgba(2, 10, 14, .7); backdrop-filter: blur(3px); }
.wl-head { display: flex; align-items: center; gap: 12px; }
.wl-head h2 { margin: 0; font: 700 22px/1.2 var(--f-display); color: var(--phosphor); letter-spacing: .02em; }
.wl-badge {
  display: inline-block; margin: 12px 0 4px; padding: 3px 10px;
  font: 700 11px/1.4 var(--f-display); letter-spacing: .08em; text-transform: uppercase;
  color: var(--ink); background: var(--amber); border-radius: 99px;
}
.welcome p { margin: 10px 0 0; }
.welcome ul { margin: 8px 0 0; padding-left: 20px; }
.welcome li { margin: 3px 0; }
.welcome b { color: var(--cyan); font-weight: 600; }
.wl-check { display: flex; align-items: center; gap: 8px; margin-top: 16px; color: var(--muted); font-size: 12.5px; cursor: pointer; }
.wl-check input { accent-color: var(--phosphor); width: 16px; height: 16px; }
.wl-actions { display: flex; gap: 10px; margin-top: 16px; }
.wl-actions .btn { text-align: center; text-decoration: none; display: inline-flex; align-items: center; justify-content: center; }
.btn.primary { background: var(--phosphor); color: var(--ink); border-color: var(--phosphor); }
.btn.primary:hover { filter: brightness(1.08); }
.sb-link { color: var(--cyan); text-decoration: none; }
.sb-link:hover { text-decoration: underline; }
a.icon-btn { text-decoration: none; }
@media (max-width: 700px) { .topbar a.icon-btn[href="handleiding.php"] { display: none; } }

/* ---------- Weerballonnen ---------- */
:root { --sonde: #e879f9; }
.sonde-wrap { background: none; border: none; }
.sonde {
  width: 100%; height: 100%;
  color: var(--sonde);
  filter: drop-shadow(0 0 4px rgba(232,121,249,.7)) drop-shadow(0 0 1px #000);
  cursor: pointer;
}
.sonde svg { width: 100%; height: 100%; fill: currentColor; stroke: #1a0620; stroke-width: 1.2; }
.sonde.down { color: #f0abfc; }
.sonde-land { background: none; border: none; }
.sonde-land div { width: 14px; height: 14px; border: 2px dashed var(--sonde); border-radius: 50%; background: rgba(232,121,249,.15); }
.sonde-pop h3 { margin: 0 0 6px; color: var(--sonde); }
.sonde-pop table { border-collapse: collapse; width: 100%; font-size: 12px; }
.sonde-pop td { padding: 2px 0; }
.sonde-pop td:first-child { color: var(--muted); padding-right: 12px; }
.sonde-pop td:last-child { text-align: right; font-weight: 600; }
.sonde-pop .pred { margin-top: 6px; font-size: 11.5px; color: var(--sonde); }
.sonde-pop .src { margin-top: 6px; font-size: 10.5px; color: var(--muted); }

/* ---------- Scheepsfoto's ---------- */
.sh-photo { margin: 2px 0 8px; font-size: 11px; color: var(--muted); }
.sh-photo.has img { display: block; width: 100%; aspect-ratio: 16 / 10; object-fit: cover; border-radius: 6px; border: 1px solid var(--line); background: #0a2430; }
.sh-photo .cap { margin-top: 3px; font-size: 10px; line-height: 1.35; }
.sh-photo a { color: var(--cyan); }
.sh-photo.none { padding: 6px 8px; border: 1px dashed var(--line); border-radius: 6px; }

/* ---------- Weerswaarschuwingen ---------- */
:root { --w2: #f5d000; --w3: #ff8a00; --w4: #e3101f; }
.warn-panel .ns-head h2 { color: var(--amber); }
.warn-item { border-left-color: var(--tc) !important; }
.warn-item .lvl { display: inline-block; padding: 0 6px; margin-right: 6px; border-radius: 3px; background: var(--tc); color: #111; font: 700 10.5px/16px var(--f-display); text-transform: uppercase; letter-spacing: .04em; }
.warn-pop h3 { margin: 0 0 6px; }
.warn-pop ul { list-style: none; margin: 0; padding: 0; font-size: 12px; }
.warn-pop li { padding: 3px 0; border-bottom: 1px solid rgba(255,255,255,.06); }
.warn-pop li b { font-weight: 700; }
.warn-pop .t { display: block; color: var(--muted); font-size: 11px; }

/* ---------- Satellieten ---------- */
:root { --sat: #fbbf24; }
.sat-wrap { background: none; border: none; }
.sat-iss { width: 100%; height: 100%; color: var(--sat); filter: drop-shadow(0 0 5px rgba(251,191,36,.8)) drop-shadow(0 0 1px #000); cursor: pointer; }
.sat-iss svg { width: 100%; height: 100%; fill: currentColor; stroke: #1c1300; stroke-width: 1; }
.sat-label { position: absolute; left: 100%; top: 50%; transform: translate(4px, -50%); font: 700 11px var(--f-display); color: var(--sat); white-space: nowrap; text-shadow: 0 0 3px #000, 0 0 3px #000; pointer-events: none; }
.sat-pop h3 { margin: 0 0 6px; color: var(--sat); }
.sat-pop table { border-collapse: collapse; width: 100%; font-size: 12px; }
.sat-pop td { padding: 2px 0; }
.sat-pop td:first-child { color: var(--muted); padding-right: 12px; }
.sat-pop td:last-child { text-align: right; font-weight: 600; }
.sat-pop .up { color: var(--phosphor); }

/* ---------- Weer op luchthavens ---------- */
:root { --vfr: #22c55e; --mvfr: #3b82f6; --ifr: #ef4444; --lifr: #d946ef; }
.ap-wrap { background: none; border: none; }
.ap-dot {
  width: 100%; height: 100%;
  display: grid; place-items: center;
  border-radius: 50%;
  background: var(--fc);
  border: 2px solid #06141a;
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--fc) 35%, transparent), 0 1px 4px rgba(0,0,0,.7);
  cursor: pointer;
}
.ap-dot svg { width: 60%; height: 60%; fill: #06141a; stroke: none; }
.ap-name { position: absolute; left: 100%; top: 50%; transform: translate(5px, -50%); font: 700 11px var(--f-display); color: var(--fc); white-space: nowrap; text-shadow: 0 0 3px #000, 0 0 3px #000; pointer-events: none; display: none; }
.ap-names .ap-name { display: block; }
.ap-pop h3 { margin: 0; color: var(--fc); }
.ap-pop .sub { color: var(--muted); font-size: 11px; margin: 2px 0 8px; }
.ap-pop .cat { display: inline-block; padding: 1px 8px; border-radius: 99px; background: var(--fc); color: #06141a; font: 700 11px/16px var(--f-display); margin-bottom: 6px; }
.ap-pop table { border-collapse: collapse; width: 100%; font-size: 12px; }
.ap-pop td { padding: 2px 0; vertical-align: top; }
.ap-pop td:first-child { color: var(--muted); padding-right: 12px; white-space: nowrap; }
.ap-pop td:last-child { text-align: right; }
.ap-pop h4 { margin: 10px 0 4px; font: 600 12.5px var(--f-display); color: var(--cyan); }
.ap-pop .fc { font-size: 11.5px; padding: 3px 0; border-bottom: 1px solid rgba(255,255,255,.06); }
.ap-pop .fc b { color: var(--text); }
.ap-pop details { margin-top: 8px; font-size: 11px; color: var(--muted); }
.ap-pop details summary { cursor: pointer; color: var(--cyan); }
.ap-pop code { display: block; margin-top: 4px; padding: 5px 7px; background: rgba(0,0,0,.35); border-radius: 4px; font: 11px/1.4 var(--f-data); color: var(--phosphor); white-space: pre-wrap; overflow-wrap: anywhere; }

/* Satellietpictogram (assets/img/satelliet.png als masker, zodat het elke kleur kan krijgen) */
.sat-ico {
  width: 100%; height: 100%;
  background: #e2e8f0;
  -webkit-mask: url("../img/satelliet.png") center / contain no-repeat;
          mask: url("../img/satelliet.png") center / contain no-repeat;
  filter: drop-shadow(0 0 1.5px #000) drop-shadow(0 0 1px #000);
  cursor: pointer;
}
.sat-ico.station { background: var(--sat); filter: drop-shadow(0 0 5px rgba(251,191,36,.8)) drop-shadow(0 0 1px #000); }
.sat-wrap:hover .sat-ico { background: #fff; }

/* ---------- Afspeelbalk neerslag ---------- */
.rain-bar {
  position: absolute;
  bottom: 66px; left: 50%;
  transform: translateX(-50%);
  z-index: 800;
  display: flex; align-items: center; gap: 10px;
  padding: 6px 10px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius-panel);
}
.rain-bar input[type=range] { width: 200px; accent-color: var(--cyan); }
.rain-bar .i-pause { display: none; }
.rain-bar #rainPlay[aria-pressed="true"] .i-play { display: none; }
.rain-bar #rainPlay[aria-pressed="true"] .i-pause { display: block; }
.rain-bar #rainPlay .i-play { fill: currentColor; }
.rain-t { display: flex; flex-direction: column; align-items: center; min-width: 64px; line-height: 1.1; }
.rain-t b { font: 700 15px var(--f-display); color: var(--cyan); font-variant-numeric: tabular-nums; }
.rain-t b.fut { color: var(--amber); }
.rain-t small { font-size: 10px; color: var(--muted); }
.rain-now { color: var(--cyan); background: rgba(82,199,234,.08); border-color: rgba(82,199,234,.45); margin-left: 0; }
@media (max-width: 700px) {
  .rain-bar { left: auto; right: 12px; transform: none; bottom: 12px; }
  .rain-bar input[type=range] { width: 110px; }
}

/* ---------- Vliegtuigfilters ---------- */
.em-note { font-size: 10.5px; color: var(--muted); display: inline-flex; align-items: center; }
.em-note i { display: inline-block; width: 7px; height: 7px; margin-right: 4px; border-radius: 50%; background: var(--c); }
.ac-more { gap: 6px 10px; align-items: center; }
.ac-more label { display: inline-flex; align-items: center; gap: 5px; font-size: 10.5px; color: var(--muted); }
.ac-more input, .ac-more select {
  font: 11px var(--f-data); color: var(--text);
  background: #0b2a35; border: 1px solid var(--line); border-radius: 4px; padding: 2px 5px;
}
.ac-more input { width: 92px; }
.ac-more input:focus, .ac-more select:focus { outline: none; border-color: var(--phosphor); }
.ac-near { margin-left: 0; color: var(--phosphor); background: rgba(102,240,194,.08); border-color: rgba(102,240,194,.45); }

/* ---------- Boven mij ---------- */
.near-panel .ns-head h2 { color: var(--phosphor); }
.near-where { margin: 0 12px 8px; font-size: 11.5px; color: var(--muted); }
.near-item { display: grid !important; grid-template-columns: 30px 1fr auto; gap: 2px 10px; align-items: center; border-left-color: var(--ac-civ) !important; }
.near-item .arr { grid-row: span 2; width: 26px; height: 26px; display: grid; place-items: center; border-radius: 50%; background: rgba(197,139,255,.12); color: var(--ac-civ); }
.near-item .arr svg { width: 16px; height: 16px; stroke-width: 2.4; }
.near-item h3 { margin: 0 !important; }
.near-item .d { grid-row: span 2; text-align: right; font: 700 14px var(--f-display); color: var(--cyan); }
.near-item .d small { display: block; font: 400 10px var(--f-data); color: var(--muted); }

/* ---------- Volgring ---------- */
.ac.follow::before, .ac.follow::after {
  content: ""; position: absolute; inset: -9px;
  border: 2px solid var(--phosphor); border-radius: 50%;
  animation: followring 1.8s ease-out infinite;
  transform: rotate(calc(-1 * var(--rot, 0deg)));
}
.ac.follow::after { animation-delay: .9s; }
.ac { position: relative; }
@keyframes followring { 0% { opacity: .9; scale: .55; } 100% { opacity: 0; scale: 1.5; } }
@media (prefers-reduced-motion: reduce) { .ac.follow::before, .ac.follow::after { animation: none; opacity: .8; } .ac.follow::after { display: none; } }

/* ---------- ISS-overkomsten ---------- */
.sat-pop .passes-btn { margin-top: 8px; width: 100%; padding: 5px 8px; font: 600 12px var(--f-display); color: var(--sat); background: rgba(251,191,36,.08); border: 1px solid rgba(251,191,36,.45); border-radius: var(--radius-ctrl); cursor: pointer; }
.sat-pop .passes { margin-top: 8px; font-size: 11.5px; }
.sat-pop .passes h4 { margin: 0 0 4px; font: 600 12.5px var(--f-display); color: var(--sat); }
.sat-pop .passes li { padding: 3px 0; border-bottom: 1px solid rgba(255,255,255,.06); list-style: none; }
.sat-pop .passes ul { margin: 0; padding: 0; }
.sat-pop .passes b { color: var(--text); }
.sat-pop .passes .note { color: var(--muted); font-size: 10.5px; margin-top: 4px; }

/* ---------- Spotter-modus ---------- */
.spot-btn[aria-pressed="true"] { color: var(--ink); background: var(--phosphor); border-color: var(--phosphor); box-shadow: 0 0 10px var(--phosphor); }
.spot-panel .ns-head h2 { color: var(--phosphor); }
.spot-main { padding: 0 12px 6px; }
.spot-toggle { width: 100%; }
.spot-toggle[aria-pressed="true"] { background: var(--phosphor); color: var(--ink); border-color: var(--phosphor); }
.spot-status { margin: 6px 0 0; font-size: 11.5px; color: var(--muted); }
.spot-set { margin: 8px 12px; padding: 6px 10px 8px; border: 1px solid var(--line); border-radius: var(--radius-ctrl); }
.spot-set legend { padding: 0 6px; font: 600 11.5px var(--f-display); color: var(--cyan); }
.spot-set label { display: flex; align-items: center; gap: 8px; padding: 2px 0; font-size: 12px; cursor: pointer; }
.spot-set label.row2 { justify-content: space-between; }
.spot-set input[type=checkbox] { accent-color: var(--phosphor); width: 15px; height: 15px; }
.spot-set select { font: 12px var(--f-data); color: var(--text); background: #0b2a35; border: 1px solid var(--line); border-radius: 4px; padding: 2px 6px; }
.spot-logh { margin: 10px 12px 4px; font: 600 12.5px var(--f-display); color: var(--text); }
.spot-log { list-style: none; margin: 0; padding: 0 12px; max-height: 220px; overflow-y: auto; font-size: 12px; }
.spot-log li { padding: 5px 0; border-bottom: 1px solid var(--line-soft); }
.spot-log li time { color: var(--muted); margin-right: 6px; font-variant-numeric: tabular-nums; }
.spot-log li.mil { color: var(--ac-mil); }
.spot-log li.emerg { color: var(--alert); }
.spot-log li.iss { color: var(--sat); }
.spot-log li[data-hex] { cursor: pointer; }
.spot-log li[data-hex]:hover { color: var(--phosphor); }
.spot-home { background: none; border: none; }
.spot-home div { width: 16px; height: 16px; border-radius: 50%; background: var(--phosphor); border: 2px solid #fff; box-shadow: 0 0 0 6px rgba(102,240,194,.25); }

/* ---------- Logo rechtsonder (pc en tablet) ---------- */
.brand-logo {
  position: absolute;
  right: 14px; bottom: 26px;
  z-index: 790;
  display: block;
  width: 170px;
  padding: 7px 10px;
  background: rgba(255, 255, 255, 0.88);   /* lichte plaat: de donkere letters blijven zo leesbaar op de satellietkaart */
  border-radius: 10px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.45);
  line-height: 0;
}
.brand-logo img { width: 100%; height: auto; display: block; }
/* Temperatuurlegenda en kompas schuiven een stukje op, zodat niets over elkaar valt */
.temp-legend { right: 198px; }
.compass { bottom: 88px; }
@media (max-width: 1024px) {
  .brand-logo { width: 140px; padding: 6px 8px; }
  .temp-legend { right: 166px; }
  .compass { bottom: 80px; }
}
@media (max-width: 700px) {
  .brand-logo { display: none; }    /* op telefoons niet, daar is de ruimte te krap */
  .temp-legend { right: 14px; }
}

/* ---------- App installeren ---------- */
.install-btn { width: auto; padding: 0 10px; gap: 6px; color: var(--phosphor); border-color: rgba(102,240,194,.5); }
.install-btn span { font: 600 12px var(--f-display); }
.install-btn[hidden] { display: none; }
/* In de geïnstalleerde app: ruimte laten voor de statusbalk van de telefoon */
@media (display-mode: standalone) { .topbar { padding-top: env(safe-area-inset-top, 0px); } }
.ios-install {
  position: fixed; left: 50%; bottom: calc(18px + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%);
  z-index: 3000; width: min(360px, calc(100% - 24px));
  padding: 12px 36px 12px 14px;
  background: var(--panel-solid); border: 1px solid var(--line); border-radius: 12px;
  box-shadow: 0 10px 30px rgba(0,0,0,.6); font-size: 13px; line-height: 1.5;
}
.ios-install b { color: var(--phosphor); }
.ios-install button { position: absolute; top: 6px; right: 6px; background: none; border: 0; color: var(--muted); font-size: 18px; cursor: pointer; }

/* ---------- Luchthaven in 3D (pop-up) ---------- */
.ap3d-btn { margin-top: 10px; width: 100%; padding: 6px 10px; font: 600 12.5px var(--f-display); color: var(--ink); background: var(--phosphor); border: 0; border-radius: var(--radius-ctrl); cursor: pointer; }
.ap3d-btn:hover { filter: brightness(1.08); }
.ap3d-dialog { width: min(1200px, calc(100% - 32px)); height: min(760px, calc(100% - 48px)); padding: 0; border: 1px solid var(--line); border-radius: 14px; background: #000; overflow: hidden; box-shadow: 0 20px 60px rgba(0,0,0,.7); }
.ap3d-dialog::backdrop { background: rgba(2,10,14,.75); }
.ap3d-dialog[open] { display: flex; flex-direction: column; }
.ap3d-bar { display: flex; align-items: center; gap: 14px; padding: 8px 12px; background: var(--panel-solid); border-bottom: 1px solid var(--line); }
.ap3d-bar b { flex: 1; font: 700 15px var(--f-display); color: var(--phosphor); }
.ap3d-bar a { color: var(--cyan); font-size: 12px; }
.ap3d-bar button { background: none; border: 0; color: var(--muted); font-size: 22px; line-height: 1; cursor: pointer; }
.ap3d-dialog iframe { flex: 1; width: 100%; border: 0; }

/* ---------- Smartphone: site uitgeschakeld ---------- */
.phone-block { display: none; }
.is-phone body > *:not(.phone-block) { display: none !important; }
.is-phone .phone-block {
  display: grid; place-items: center;
  position: fixed; inset: 0; z-index: 99999;
  padding: 28px 24px calc(28px + env(safe-area-inset-bottom, 0px));
  background: var(--ink); color: var(--text);
  text-align: center; font: 15px/1.6 var(--f-data);
}
.phone-block h1 { margin: 14px 0 18px; font: 700 24px var(--f-display); color: var(--phosphor); letter-spacing: .03em; }
.phone-block p { margin: 0 auto 12px; max-width: 32ch; color: var(--muted); }
.phone-block p b { color: var(--text); }
.phone-block .url { margin-top: 22px; color: var(--cyan); font-size: 13px; }

.phone-block svg { width: 64px; height: 64px; }
.ac.parked { opacity: .75; }
.ac.parked svg { stroke-dasharray: 2 1.5; }
