/* Statusseite status.medimerge.de. ERZEUGT von statusseite/bauen.ts, nicht von Hand aendern.
   Farben aus lib/brand/markenfarben.ts und globals.css, Masse aus der Leiter des Designsystems. */

@font-face { font-family: "Geist"; font-style: normal; font-weight: 400; font-display: swap; src: url("/schrift/geist-400.woff2") format("woff2"); }
@font-face { font-family: "Geist"; font-style: normal; font-weight: 500; font-display: swap; src: url("/schrift/geist-500.woff2") format("woff2"); }
@font-face { font-family: "Geist"; font-style: normal; font-weight: 600; font-display: swap; src: url("/schrift/geist-600.woff2") format("woff2"); }
@font-face { font-family: "Source Serif 4"; font-style: normal; font-weight: 600; font-display: swap; src: url("/schrift/source-serif-4-600.woff2") format("woff2"); }

:root {
  color-scheme: light dark;
  --seite: #f4f7fa;
  --karte: #ffffff;
  --text: #101317;
  --leise: #697179;
  --kante: #e1e6eb;
  --flaeche: #f4f7fa;
  --marke: #144fc3;
  --marke-hover: #0d40a4;
  --marke-schwach: #eff6ff;
  --ring: #144fc3;
  --ok: #137d41;
  --ok-schwach: #e7f2ec;
  --ok-kante: #a1cbb3;
  --warn: #ac4f00;
  --warn-schwach: #f7eedd;
  --warn-kante: #e0ba77;
  --fehl: #cb0002;
  --fehl-schwach: #fbdfe4;
  --fehl-kante: #f17f95;
  --balken-leer: #e1e6eb;
  --balken-wart: #a9b2bc;
  --raster-linie: rgba(16, 19, 23, 0.07);
  --raster-zelle: rgba(16, 19, 23, 0.05);
}
@media (prefers-color-scheme: dark) {
  :root {
    --seite: #101317;
    --karte: #1e2227;
    --text: #f4f7fa;
    --leise: #a9b2bc;
    --kante: rgba(255, 255, 255, 0.1);
    --flaeche: #343a40;
    --marke: #6fa2ff;
    --marke-hover: #96c0ff;
    --marke-schwach: #092661;
    --ring: #6fa2ff;
    --ok: #4dbf74;
    --ok-schwach: #1c362a;
    --ok-kante: #29583c;
    --warn: #f19b37;
    --warn-schwach: #3d2e1d;
    --warn-kante: #6a4924;
    --fehl: #ff6467;
    --fehl-schwach: #402327;
    --fehl-kante: #703337;
    --balken-leer: #343a40;
    --balken-wart: #697179;
    --raster-linie: rgba(244, 247, 250, 0.09);
    --raster-zelle: rgba(244, 247, 250, 0.05);
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--seite);
  color: var(--text);
  font: 400 16px/1.625 Geist, ui-sans-serif, system-ui, sans-serif;
  overflow-wrap: break-word;
}
h1, h2 { font-family: "Source Serif 4", Georgia, serif; font-weight: 600; letter-spacing: -0.01em; line-height: 1.25; }
h2 { font-size: 20px; margin: 0 0 12px; }
h3 { font-size: 16px; font-weight: 500; line-height: 1.375; margin: 0; }
p { margin: 0; }
ul { list-style: none; margin: 0; padding: 0; }
a { color: var(--marke); }
a:focus-visible, main:focus-visible { outline: 3px solid var(--ring); outline-offset: 2px; border-radius: 4px; }
main:focus { outline: none; }

.rahmen { max-width: 880px; margin: 0 auto; padding: 0 24px; }
@media (max-width: 400px) { .rahmen { padding: 0 16px; } }

/* Der Sprunglink: erstes Ziel, sichtbar bei Tastaturfokus, deckend. */
.sprung {
  position: absolute; left: 16px; top: -64px; z-index: 10;
  padding: 8px 16px; border-radius: 10px;
  background: var(--karte); color: var(--text); border: 1px solid var(--kante);
  font-size: 14px; font-weight: 500; text-decoration: none;
}
.sprung:focus-visible { top: 16px; }

.kopf-leiste { background: var(--karte); border-bottom: 1px solid var(--kante); }
.kopf-innen { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 64px; }
.logo-link { display: inline-flex; border-radius: 6px; }
.logo-link img { display: block; height: 28px; width: auto; }
.aktion {
  display: inline-flex; align-items: center; gap: 4px;
  font-size: 14px; font-weight: 500; text-decoration: none; color: var(--marke);
  min-height: 24px;
}
.aktion:hover { text-decoration: underline; text-underline-offset: 3px; }
.pfeil { flex: none; transition: transform 220ms cubic-bezier(0.22, 1, 0.36, 1); }
.aktion:hover .pfeil { transform: translateX(3px); }

.kopf { padding: 32px 0 0; }
.etikett { font-size: 12px; font-weight: 500; letter-spacing: 0.1em; text-transform: uppercase; color: var(--leise); }
.absatz { margin-top: 12px; max-width: 65ch; }

.lage {
  position: relative; overflow: hidden;
  display: flex; gap: 16px; align-items: flex-start;
  margin-top: 24px; padding: 24px;
  background: var(--karte); border: 1px solid var(--kante); border-radius: 14px;
}
.lage-text { position: relative; min-width: 0; }
.lage h1 { margin: 0; font-size: 24px; }
@media (min-width: 640px) { .lage h1 { font-size: 30px; } }
.lage-satz { margin-top: 4px; }
/* Auf der getoenten Lage steht die Zeit in Textfarbe: das leise Grau haelt
   dort hell keine 4,5:1 (gerechnet beim Bau: 3,96 bis 4,32). */
.lage-zeit { margin-top: 4px; color: var(--text); font-size: 14px; line-height: 1.375; }
.lage-alt { margin-top: 12px; color: var(--leise); font-size: 14px; line-height: 1.375; }
.punkt { position: relative; flex: none; width: 14px; height: 14px; margin-top: 10px; border-radius: 999px; background: var(--leise); }
@media (min-width: 640px) { .punkt { margin-top: 14px; } }
.lage-ok { background: var(--ok-schwach); border-color: var(--ok-kante); }
.lage-ok .punkt { background: var(--ok); }
.lage-warn { background: var(--warn-schwach); border-color: var(--warn-kante); }
.lage-warn .punkt { background: var(--warn); }
.lage-fehl { background: var(--fehl-schwach); border-color: var(--fehl-kante); }
.lage-fehl .punkt { background: var(--fehl); }
.lage-info { background: var(--marke-schwach); }
.lage-info .punkt { background: var(--marke); }
.lage-leise .punkt { background: var(--leise); }

/* Das Rasterfeld (ui/raster-feld.tsx): grau, von rechts oben auslaufend. */
.raster-feld {
  position: absolute; top: 0; right: 0; width: 72%; height: 100%; pointer-events: none;
  background-image: linear-gradient(to left, var(--raster-linie) 1px, transparent 1px), linear-gradient(to bottom, var(--raster-linie) 1px, transparent 1px);
  background-size: 28px 28px; background-position: top right;
  -webkit-mask-image: radial-gradient(farthest-side at 100% 0, #000, transparent);
  mask-image: radial-gradient(farthest-side at 100% 0, #000, transparent);
}
.zelle { position: absolute; width: 28px; height: 28px; background: var(--raster-zelle); }
.zelle-1 { right: 28px; top: 0; }
.zelle-2 { right: 84px; top: 56px; }

section { margin-top: 48px; }
.kopf + section { margin-top: 48px; }
.karte { background: var(--karte); border: 1px solid var(--kante); border-radius: 14px; }
.liste > li { padding: 16px 20px; border-top: 1px solid var(--kante); }
.liste > li:first-child { border-top: 0; }
.oben { display: flex; justify-content: space-between; gap: 12px; align-items: baseline; flex-wrap: wrap; }
.was { margin-top: 2px; color: var(--leise); font-size: 14px; line-height: 1.375; }
.wort { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; font-weight: 500; line-height: 1.375; }
.wort-punkt { width: 10px; height: 10px; border-radius: 999px; background: currentColor; flex: none; }
.wort-ok { color: var(--ok); }
.wort-warn { color: var(--warn); }
.wort-fehl { color: var(--fehl); }
.wort-info { color: var(--marke); }
.wort-leise { color: var(--leise); }

.balken { display: grid; grid-template-columns: repeat(90, minmax(0, 1fr)); gap: 2px; margin-top: 12px; height: 28px; }
.balken i { border-radius: 2px; background: var(--balken-leer); }
.balken .b-ok { background: var(--ok); }
.balken .b-eing { background: var(--warn); }
.balken .b-gest { background: var(--warn); }
.balken .b-weg { background: var(--fehl); }
.balken .b-wart { background: var(--balken-wart); }
.skala { display: flex; justify-content: space-between; gap: 8px; margin-top: 4px; font-size: 12px; line-height: 1.375; color: var(--leise); }
.schmal { display: none; }
@media (max-width: 640px) {
  .balken { grid-template-columns: repeat(30, minmax(0, 1fr)); }
  .balken i:nth-child(-n+60) { display: none; }
  .breit { display: none; }
  .schmal { display: inline; }
}

.raster { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
@media (max-width: 640px) { .raster { grid-template-columns: minmax(0, 1fr); } }
.zahl { padding: 16px 20px; display: flex; flex-direction: column; gap: 4px; }
.zahl-wert { font-size: 24px; font-weight: 600; line-height: 1.25; font-variant-numeric: tabular-nums; }
.zahl-leer { font-size: 16px; font-weight: 500; color: var(--leise); }
.zahl-label { color: var(--leise); font-size: 14px; line-height: 1.375; }

.hinweis { padding: 16px 20px; background: var(--marke-schwach); border-radius: 14px; }
.hinweis strong { font-weight: 600; }
.hinweis-warn { margin-top: 24px; background: var(--warn-schwach); border: 1px solid var(--warn-kante); }
.wartungen li + li { margin-top: 8px; }

.vorfall .datum { font-size: 14px; color: var(--leise); line-height: 1.375; }
.vorfall h3 { margin: 4px 0 8px; font-weight: 600; }
.vorfall p + p { margin-top: 4px; }
.vorfall strong { font-weight: 600; }
.vorfall-leer { color: var(--leise); font-size: 14px; }
.pille { display: inline-block; margin-left: 6px; padding: 0 8px; border-radius: 999px; font-size: 12px; font-weight: 500; line-height: 1.6; }
.pille-ok { background: var(--ok-schwach); color: var(--ok); }
.pille-warn { background: var(--warn-schwach); color: var(--warn); }

.fuss { margin-top: 48px; padding-top: 24px; padding-bottom: 48px; border-top: 1px solid var(--kante); color: var(--leise); font-size: 14px; line-height: 1.375; }
.fuss .links { display: flex; flex-wrap: wrap; gap: 8px 24px; margin-top: 12px; }
.fuss a { color: var(--leise); text-decoration: underline; text-underline-offset: 2px; }
.fuss a:hover { color: var(--text); text-decoration-thickness: 2px; }

.nur-vorlesen { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.liste > li { position: relative; }

@media (prefers-reduced-motion: reduce) { .pfeil { transition: none; } }
