/* Moving Map — zweites Fenster der Messkarte: Karte groß, Auswahl rechts oben, Zeit unten. Farben wie app.css. */
:root { --navy: #1a3550; --flaeche: #f3f5f7; --tafel: #ffffff; --text: #1c2733; --text-2: #55616e; --linie: #d6dce2; --akzent: #1a3550; --akzent-text: #ffffff; }
* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body { display: flex; flex-direction: column; background: var(--flaeche); color: var(--text); font: 14px/1.4 system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif; }

.kopf { display: flex; align-items: center; gap: 14px; padding: 8px 16px; color: #fff; flex: none; }
.kopf .logo { height: 30px; display: block; }
.kopf .titel { display: flex; flex-direction: column; line-height: 1.2; min-width: 0; }
.kopf .titel strong { font-size: 16px; font-weight: 600; }
.kopf .titel span { font-size: 12px; opacity: .8; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kopf .zurueck { margin-left: auto; color: #fff; font-size: 13px; text-decoration: none; padding: 4px 12px; border-radius: 999px; background: rgba(255,255,255,.12); white-space: nowrap; }
.kopf .zurueck:hover { background: rgba(255,255,255,.22); }

.buehne { position: relative; flex: 1 1 auto; min-height: 360px; }
#map { position: absolute; inset: 0; }
.leaflet-container { background: #20262c; font: inherit; }
#ov { position: absolute; inset: 0; pointer-events: none; z-index: 650; display: block; }

.menue { position: absolute; top: 10px; right: 10px; z-index: 700; width: 272px; max-width: calc(100% - 20px); max-height: calc(100% - 20px); overflow: auto; background: rgba(255,255,255,.94); border: 1px solid var(--linie); border-radius: 10px; box-shadow: 0 2px 10px rgba(0,0,0,.18); font-size: 13px; }
.menue .klapp { width: 100%; text-align: left; font: inherit; font-weight: 600; padding: 8px 12px; border: 0; background: var(--akzent); color: var(--akzent-text); border-radius: 10px 10px 0 0; cursor: pointer; }
.menue .klapp[aria-expanded="false"] { border-radius: 10px; }
.menue .klapp[aria-expanded="false"] + #menueInhalt { display: none; }   /* mit #id, sonst gewinnt die Flex-Regel darunter (Spezifität) und das Menü klappt nie ein */
.menue #menueInhalt { padding: 8px 12px 10px; display: flex; flex-direction: column; gap: 7px; }
.feld { display: flex; align-items: center; justify-content: space-between; gap: 8px; color: var(--text-2); }
.feld select { font: inherit; max-width: 170px; padding: 3px 4px; border: 1px solid var(--linie); border-radius: 6px; background: #fff; color: var(--text); }
.schalter { display: flex; align-items: center; gap: 6px; color: var(--text); }
.gruppe { color: var(--text-2); display: flex; flex-direction: column; gap: 3px; }
.gruppe .schalter { padding-left: 4px; }
.knopf { font: inherit; padding: 6px 12px; border: 1px solid var(--linie); border-radius: 8px; background: var(--tafel); color: var(--text); cursor: pointer; }
.knopf[aria-pressed="true"] { background: var(--akzent); color: var(--akzent-text); border-color: var(--akzent); }
.hinweis { margin: 0; font-size: 12px; color: var(--text-2); }
.hinweis:empty { display: none; }

.legende { position: absolute; left: 10px; bottom: 10px; z-index: 700; background: rgba(255,255,255,.92); border: 1px solid var(--linie); border-radius: 8px; padding: 6px 10px; font-size: 12px; min-width: 190px; }
.legende .lt { font-weight: 600; margin-bottom: 3px; }
.legende .balken { height: 10px; border-radius: 3px; }
.legende .enden { display: flex; justify-content: space-between; gap: 14px; font-variant-numeric: tabular-nums; margin-top: 2px; }

.profil { flex: none; background: var(--tafel); border-top: 1px solid var(--linie); padding: 4px 16px 0; }
.profil[hidden] { display: none; }
.profil canvas { display: block; width: 100%; height: 84px; cursor: crosshair; touch-action: none; }
.profil .pk { display: flex; justify-content: space-between; gap: 12px; font-size: 11px; color: var(--text-2); padding: 1px 0 4px; }
.profil .pk span:last-child { font-variant-numeric: tabular-nums; color: var(--text); white-space: nowrap; }

.zeit { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; padding: 6px 16px; background: var(--tafel); border-top: 1px solid var(--linie); flex: none; }
.zeit input[type=range] { flex: 1 1 240px; min-width: 160px; }
.aus { font-variant-numeric: tabular-nums; font-size: 13px; white-space: nowrap; }
.aus b { margin-left: 10px; color: var(--text-2); font-weight: 600; }
.aus b:first-child { margin-left: 0; }

@media (max-width: 700px) {
  .kopf .titel span { display: none; }
  .menue { width: 230px; }
  .aus { white-space: normal; }
}
