/* Clipwerk Leitstand. Bild: ein Regiepult. Helle Pultflaeche, dunkle Monitore, Signallampen tragen Bedeutung:
   Rot = nimmt auf, Bernstein = wartet oder unklar, Gruen = erlaubt oder erledigt. Kein JavaScript. */

:root {
  --pult: #e3e6e0;
  --platte: #f4f5f1;
  --kante: #b9bfb6;
  --tinte: #1c2a31;
  --leise: #55646b;
  --monitor: #131a1f;
  --rot: #cf332b;
  --bernstein: #b97f00;
  --gruen: #25704f;
  --blau: #245a86;
  --schrift: "Avenir Next", "Segoe UI", system-ui, sans-serif;
  --schmal: "Avenir Next Condensed", "Roboto Condensed", "Arial Narrow", "Avenir Next", system-ui, sans-serif;
}

* { box-sizing: border-box; }
html { background: var(--pult); color: var(--tinte); font: 17px/1.5 var(--schrift); -webkit-text-size-adjust: 100%; }
body { margin: 0; padding-bottom: 5.5rem; }
h1, h2, h3 { font-family: var(--schmal); font-weight: 600; line-height: 1.15; margin: 0; letter-spacing: 0.01em; }
h1 { font-size: 2.05rem; }
h2 { font-size: 1.45rem; margin-top: 2.2rem; margin-bottom: 0.7rem; }
h3 { font-size: 1.15rem; }
p { margin: 0.5rem 0; max-width: 68ch; }
a { color: var(--blau); text-underline-offset: 0.18em; }
small, .leise { color: var(--leise); font-size: 0.88rem; }
.zahl { font-variant-numeric: tabular-nums; }
:focus-visible { outline: 3px solid var(--blau); outline-offset: 2px; }

/* Rahmen der Seite */
.kopf { display: flex; align-items: baseline; gap: 1rem; flex-wrap: wrap; padding: 1.1rem 1.1rem 0.4rem; max-width: 72rem; margin: 0 auto; }
.kopf .marke { font-family: var(--schmal); font-weight: 700; font-size: 1.5rem; color: var(--tinte); text-decoration: none; }
.inhalt { max-width: 72rem; margin: 0 auto; padding: 0 1.1rem 2rem; }
.leiste { position: fixed; left: 0; right: 0; bottom: 0; display: flex; background: var(--tinte); z-index: 5;
  padding-bottom: env(safe-area-inset-bottom); overflow-x: auto; }
.leiste a { flex: 1 0 auto; min-width: 4.6rem; padding: 0.8rem 0.7rem 0.75rem; text-align: center; color: #cfd6d2;
  text-decoration: none; font-family: var(--schmal); font-size: 1.02rem; border-top: 4px solid transparent; }
.leiste a[aria-current="page"] { color: #fff; border-top-color: var(--rot); }

/* Signallampen */
.lampe { display: inline-block; width: 0.72rem; height: 0.72rem; border-radius: 50%; background: var(--kante);
  margin-right: 0.4rem; vertical-align: baseline; }
.lampe.rot { background: var(--rot); box-shadow: 0 0 0 3px rgba(207, 51, 43, 0.22); }
.lampe.bernstein { background: var(--bernstein); }
.lampe.gruen { background: var(--gruen); }
.stand-rot { color: var(--rot); }
.stand-bernstein { color: var(--bernstein); }
.stand-gruen { color: var(--gruen); }
.stand-rot, .stand-bernstein, .stand-gruen { font-weight: 600; }

/* Platten: Bedienfelder auf dem Pult */
.platte { background: var(--platte); border: 1px solid var(--kante); border-bottom-width: 3px; border-radius: 3px;
  padding: 1rem 1.1rem; margin: 0.8rem 0; }
.platte > h3 { margin-bottom: 0.35rem; }
.reihe { display: flex; gap: 0.8rem; flex-wrap: wrap; align-items: center; }
.reihe.auseinander { justify-content: space-between; }
.raster { display: grid; gap: 0.9rem; grid-template-columns: repeat(auto-fill, minmax(16.5rem, 1fr)); }
.meldung { background: #fff; border-left: 6px solid var(--blau); padding: 0.7rem 0.9rem; margin: 0.9rem 0; }
.meldung.fehler { border-left-color: var(--rot); }
.meldung.warnung { border-left-color: var(--bernstein); }
.kennzahlen { display: flex; flex-wrap: wrap; gap: 0.4rem 2rem; margin: 0.3rem 0 0; padding: 0; list-style: none; }
.kennzahlen b { font-family: var(--schmal); font-size: 1.9rem; font-weight: 600; display: block; line-height: 1.1; }

/* Monitore: alles, was Bild zeigt */
.monitor { background: var(--monitor); color: #e8ecea; border-radius: 4px; padding: 0.85rem 0.95rem; }
.monitor h3 { color: #fff; }
.monitor .leise, .monitor small { color: #9eaba9; }
.monitor a { color: #b9d6ee; }
.monitor meter { width: 100%; height: 0.8rem; margin-top: 0.5rem; }
.clips { display: grid; gap: 0.9rem; grid-template-columns: repeat(auto-fill, minmax(9.2rem, 1fr)); }
.clip { display: block; color: inherit; text-decoration: none; }
.clip img { display: block; width: 100%; height: auto; aspect-ratio: 9 / 16; object-fit: cover; background: var(--monitor); border-radius: 4px; }
.clip span { display: block; font-size: 0.86rem; line-height: 1.3; margin-top: 0.3rem; }
.film { background: var(--monitor); border-radius: 4px; padding: 0.6rem; max-width: 24rem; }
.film video { display: block; width: 100%; max-height: 78vh; border-radius: 2px; }

/* Tasten und Felder */
button, .taste { font: 600 1rem var(--schmal); letter-spacing: 0.02em; color: #fff; background: var(--blau); border: 0;
  border-bottom: 3px solid rgba(0, 0, 0, 0.32); border-radius: 3px; padding: 0.62rem 1rem 0.5rem; cursor: pointer;
  text-decoration: none; display: inline-block; min-height: 2.75rem; }
button:active, .taste:active { border-bottom-width: 1px; transform: translateY(2px); }
button.rot { background: var(--rot); }
button.gruen { background: var(--gruen); }
button.still, .taste.still { background: #d3d8d1; color: var(--tinte); }
form.zeile { display: inline; }
label { display: block; font-weight: 600; margin-top: 0.9rem; }
label small { font-weight: 400; display: block; }
input[type="text"], input[type="password"], input[type="number"], select, textarea {
  font: inherit; color: var(--tinte); background: #fff; border: 1px solid var(--kante); border-bottom: 3px solid var(--kante);
  border-radius: 3px; padding: 0.55rem 0.65rem; width: 100%; max-width: 30rem; min-height: 2.75rem; }
textarea { max-width: 44rem; min-height: 7rem; line-height: 1.4; }
input[type="number"] { max-width: 9rem; }
.wahl { display: flex; gap: 0.6rem; align-items: flex-start; font-weight: 400; margin-top: 0.6rem; max-width: 60ch; }
.wahl input { width: 1.35rem; height: 1.35rem; margin-top: 0.15rem; flex: none; }

/* Tabellen: am Handy als Stapel */
table { border-collapse: collapse; width: 100%; }
th, td { text-align: left; padding: 0.55rem 0.6rem; border-bottom: 1px solid var(--kante); vertical-align: top; }
th { font-family: var(--schmal); font-weight: 600; color: var(--leise); }
td.eng { white-space: nowrap; }
details summary { cursor: pointer; color: var(--blau); }
details blockquote { margin: 0.4rem 0 0; padding-left: 0.8rem; border-left: 3px solid var(--kante); font-size: 0.92rem; }

@media (max-width: 46rem) {
  h1 { font-size: 1.7rem; }
  table, tbody, tr, td { display: block; }
  thead { display: none; }
  tr { border-bottom: 3px solid var(--kante); padding: 0.5rem 0; }
  td { border: 0; padding: 0.15rem 0; }
  td[data-kopf]::before { content: attr(data-kopf) ": "; color: var(--leise); font-size: 0.88rem; }
}
@media (min-width: 60rem) {
  body { padding-bottom: 0; padding-top: 3.4rem; }
  .leiste { top: 0; bottom: auto; justify-content: center; }
  .leiste a { flex: 0 0 auto; padding: 0.75rem 1.2rem 0.6rem; border-top: 0; border-bottom: 4px solid transparent; }
  .leiste a[aria-current="page"] { border-bottom-color: var(--rot); }
  .zwei { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 4fr); gap: 2rem; align-items: start; }
}
@media (prefers-reduced-motion: reduce) { button:active, .taste:active { transform: none; } }

/* Anmeldung */
.tor { max-width: 24rem; margin: 12vh auto 0; padding: 0 1.1rem; }
.tor h1 { margin-bottom: 1rem; }
