/* Intranet PA-Schneider — Hausfarben aus dem Corporate Design:
   Creme als Grund, Orange als Akzent, Kupfer für Linien und Marke,
   sehr dunkles Braun statt Schwarz. */

:root {
  /* Vier Ebenen, von hell nach warm:
       --creme      Seitengrund, hell und ruhig
       --weiss      Karten — heben sich ueber den Rand ab, nicht ueber die Flaeche
       --feld       Eingabefelder, damit sie im hellen Grund als Felder lesbar sind
       --kopf-bg    Kopfleiste, der waermste Ton — sie soll oben stehenbleiben */
  --creme:       #FCF9F3;
  --kopf-bg:     #F4ECDE;
  --feld:        #F5EFE3;
  --creme-tief:  #F0E7D5;
  --sand:        #DCC6A2;
  --weiss:       #FFFFFF;

  --orange:      #E08A2C;
  --orange-tief: #C4741C;
  --kupfer:      #B87038;
  --kupfer-hell: #BC9068;

  --braun:       #2B211A;
  --braun-weich: #55483C;
  --grau:        #8A7B6B;
  --grau-hell:   #B3A695;

  --linie:       #E2D5BC;
  --linie-fein:  #EDE3D0;

  --gruen:       #4A7C59;
  --gruen-tint:  #E6EEE6;
  --rot:         #B5462F;
  --rot-tint:    #F6E5E0;
  --amber:       #B8801A;
  --amber-tint:  #F7EDD8;

  --sans: "Archivo", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;

  --radius: 14px;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--creme);
  color: var(--braun);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--orange-tief); }
a:focus-visible, button:focus-visible, input:focus-visible {
  outline: 2px solid var(--orange);
  outline-offset: 2px;
  border-radius: 4px;
}

/* ── Kopfleiste ──────────────────────────────────────────────────────────── */

.kopf {
  background: var(--kopf-bg);
  border-bottom: 1px solid var(--linie);
}

.kopf-innen {
  max-width: 1180px;
  margin: 0 auto;
  padding: 14px 26px;
  display: flex;
  align-items: center;
  gap: 18px;
}

.marke {
  display: flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  color: var(--braun);
}

.marke img {
  height: 38px;
  width: auto;
  display: block;
}

/* Trennstrich zwischen Wortmarke und Anwendungsname — das Logo gehoert der
   Firma, „Intranet" benennt nur dieses Werkzeug. */
.marke .sperr {
  padding-left: 14px;
  border-left: 1px solid var(--linie);
  align-self: stretch;
  display: flex;
  align-items: center;
}

.anmelde-marke {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  margin-bottom: 26px;
}

.anmelde-marke img {
  width: 76px;
  height: 76px;
  border-radius: 20px;
  display: block;
}

.marke .sperr {
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--grau);
}

.kopf nav { margin-left: auto; display: flex; align-items: center; gap: 20px; }

.kopf nav a {
  color: var(--braun-weich);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
}
.kopf nav a:hover { color: var(--orange-tief); }

.wer {
  font-size: 13px;
  color: var(--grau);
  padding-left: 20px;
  border-left: 1px solid var(--linie);
}
.wer strong { color: var(--braun); font-weight: 600; }

/* ── Grundgerüst ─────────────────────────────────────────────────────────── */

main { max-width: 1180px; margin: 0 auto; padding: 34px 26px 80px; }

.seitenkopf { margin-bottom: 26px; display: flex; align-items: flex-end; gap: 18px; }
.seitenkopf .wachsen { flex: 1; }

.eyebrow {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--kupfer);
  margin: 0 0 5px;
}

h1 {
  font-size: 30px;
  font-weight: 700;
  letter-spacing: -0.025em;
  margin: 0;
  text-wrap: balance;
}

h2 { font-size: 19px; font-weight: 700; letter-spacing: -0.015em; margin: 0 0 12px; }

.leise { color: var(--grau); font-size: 14px; margin: 4px 0 0; }

/* ── Kacheln ─────────────────────────────────────────────────────────────── */

.kacheln {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(258px, 1fr));
  gap: 16px;
}

.kachel {
  background: var(--weiss);
  border: 1px solid var(--linie);
  border-radius: var(--radius);
  padding: 22px 22px 20px;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  gap: 9px;
  transition: border-color .14s, transform .14s, box-shadow .14s;
}

.kachel:hover {
  border-color: var(--kupfer);
  transform: translateY(-2px);
  box-shadow: 0 8px 22px -14px rgba(43, 33, 26, .4);
}

.kachel .marke-zeichen {
  width: 42px; height: 42px;
  border-radius: 12px;
  background: var(--creme-tief);
  color: var(--kupfer);
  display: grid;
  place-items: center;
  font-size: 20px;
  margin-bottom: 3px;
}

.kachel h3 { margin: 0; font-size: 16.5px; font-weight: 700; letter-spacing: -0.01em; }
.kachel p { margin: 0; font-size: 13.5px; color: var(--braun-weich); line-height: 1.5; }

.kachel .fuss {
  margin-top: auto;
  padding-top: 12px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--grau-hell);
}

/* ── Karten & Kennzahlen ─────────────────────────────────────────────────── */

.karte {
  background: var(--weiss);
  border: 1px solid var(--linie);
  border-radius: var(--radius);
  padding: 20px 22px;
  margin-bottom: 16px;
}

.kennzahlen {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 14px;
  margin-bottom: 20px;
}

.kennzahl {
  background: var(--weiss);
  border: 1px solid var(--linie);
  border-radius: var(--radius);
  padding: 17px 19px;
}

.kennzahl .titel {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--grau);
  margin-bottom: 7px;
}

.kennzahl .wert {
  font-size: 25px;
  font-weight: 700;
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
}
.kennzahl .wert.gut { color: var(--gruen); }
.kennzahl .wert.schlecht { color: var(--rot); }
.kennzahl .zusatz { font-size: 12.5px; color: var(--grau); margin-top: 3px; }

/* Kennzahlenband in Markenfarbe — nur einmal pro Seite, als Blickfang. */
.band {
  background: var(--braun);
  color: var(--creme);
  border-radius: var(--radius);
  padding: 22px 24px;
  margin-bottom: 16px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 22px;
}
.band .titel { color: var(--kupfer-hell); }
.band .wert { color: var(--weiss); }
.band .wert.gut { color: #8FC79C; }
.band .wert.schlecht { color: #F0A08C; }
.band .zusatz { color: var(--grau-hell); }

/* ── Anbieteranteile ─────────────────────────────────────────────────────── */

.anbieter + .anbieter { margin-top: 15px; }

.anbieter .zeile {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 6px;
  font-size: 14px;
}
.anbieter .name { font-weight: 700; }
.anbieter .betrag {
  margin-left: auto;
  font-variant-numeric: tabular-nums;
  font-weight: 600;
}
.anbieter .anteil { color: var(--grau); font-size: 12.5px; font-variant-numeric: tabular-nums; }

.balken {
  height: 7px;
  background: var(--creme-tief);
  border-radius: 4px;
  overflow: hidden;
}
.balken > span { display: block; height: 100%; border-radius: 4px; }

/* ── Organisationen ──────────────────────────────────────────────────────── */

details.org {
  background: var(--weiss);
  border: 1px solid var(--linie);
  border-radius: var(--radius);
  margin-bottom: 10px;
}

details.org > summary {
  list-style: none;
  cursor: pointer;
  padding: 16px 20px;
  display: flex;
  align-items: center;
  gap: 15px;
}
details.org > summary::-webkit-details-marker { display: none; }

details.org > summary:hover { background: #FDFBF6; border-radius: var(--radius); }

.kuerzel {
  width: 38px; height: 38px;
  border-radius: 11px;
  background: var(--creme-tief);
  color: var(--kupfer);
  display: grid;
  place-items: center;
  font-size: 13px;
  font-weight: 700;
  flex-shrink: 0;
}

.org-name { font-weight: 700; font-size: 15.5px; }
.org-zusatz { font-size: 12.5px; color: var(--grau); }

.org-zahlen {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 22px;
  font-variant-numeric: tabular-nums;
}
.org-zahlen .spalte { text-align: right; }
.org-zahlen .k {
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--grau-hell);
}
.org-zahlen .v { font-size: 15px; font-weight: 700; }

.pfeil { color: var(--grau-hell); font-size: 13px; transition: transform .15s; }
details.org[open] .pfeil { transform: rotate(90deg); }

.org-detail {
  border-top: 1px solid var(--linie-fein);
  padding: 6px 20px 16px;
  background: #FDFBF6;
  border-radius: 0 0 var(--radius) var(--radius);
}

/* ── Tabellen ────────────────────────────────────────────────────────────── */

.rollen { overflow-x: auto; }

table { border-collapse: collapse; width: 100%; font-size: 13.5px; min-width: 520px; }

th {
  text-align: left;
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--grau);
  padding: 12px 12px 8px 0;
  border-bottom: 1px solid var(--linie);
  white-space: nowrap;
}

td {
  padding: 9px 12px 9px 0;
  border-bottom: 1px solid var(--linie-fein);
  vertical-align: top;
}

tr:last-child td { border-bottom: none; }

.rechts { text-align: right; padding-right: 0; font-variant-numeric: tabular-nums; white-space: nowrap; }
th.rechts { text-align: right; padding-right: 0; }
.feld { font-family: var(--mono); font-size: 11.5px; color: var(--grau); }

/* ── Kleinteile ──────────────────────────────────────────────────────────── */

.marker {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 11.5px;
  font-weight: 600;
  border-radius: 999px;
  padding: 2px 9px;
}
.marker.warn { background: var(--amber-tint); color: var(--amber); }
.marker.gut  { background: var(--gruen-tint); color: var(--gruen); }
.marker.aus  { background: var(--creme-tief); color: var(--grau); }

.knopf {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: var(--orange);
  color: var(--weiss);
  border: none;
  border-radius: 11px;
  padding: 11px 19px;
  font-family: var(--sans);
  font-size: 14.5px;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
}
.knopf:hover { background: var(--orange-tief); }

.knopf.still {
  background: var(--weiss);
  color: var(--braun-weich);
  border: 1px solid var(--linie);
}
.knopf.still:hover { background: var(--creme-tief); color: var(--braun); }

.monatswahl { display: flex; align-items: center; gap: 8px; }
.monatswahl .jetzt {
  font-weight: 700;
  font-size: 14.5px;
  min-width: 130px;
  text-align: center;
}
.monatswahl a, .monatswahl span.leer {
  width: 34px; height: 34px;
  display: grid; place-items: center;
  border: 1px solid var(--linie);
  border-radius: 9px;
  background: var(--weiss);
  color: var(--braun-weich);
  text-decoration: none;
}
.monatswahl a:hover { border-color: var(--kupfer); color: var(--orange-tief); }
.monatswahl span.leer { opacity: .35; }

.hinweis {
  border-left: 3px solid var(--amber);
  background: var(--amber-tint);
  border-radius: 0 10px 10px 0;
  padding: 13px 17px;
  font-size: 13.5px;
  color: #7A5510;
  margin-bottom: 16px;
}

.leerzustand {
  text-align: center;
  padding: 54px 24px;
  color: var(--grau);
}
.leerzustand .zeichen { font-size: 34px; color: var(--kupfer-hell); margin-bottom: 10px; }

/* ── Anmeldung ───────────────────────────────────────────────────────────── */

.anmeldeseite {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    radial-gradient(circle at 82% 12%, var(--creme-tief), transparent 46%),
    var(--creme);
}

.anmeldekarte {
  background: var(--weiss);
  border: 1px solid var(--linie);
  border-radius: 20px;
  padding: 38px 36px 32px;
  width: 100%;
  max-width: 396px;
  box-shadow: 0 22px 46px -30px rgba(43, 33, 26, .5);
}

.anmeldekarte h1 { font-size: 21px; margin-bottom: 22px; text-align: center; }

label {
  display: block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--grau);
  margin-bottom: 6px;
}

input[type=text], input[type=password] {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--linie);
  border-radius: 11px;
  background: var(--feld);
  font-family: var(--sans);
  font-size: 15px;
  color: var(--braun);
  margin-bottom: 17px;
}
input:focus { border-color: var(--orange); background: var(--weiss); }

.anmeldekarte .knopf { width: 100%; justify-content: center; }

.fehlermeldung {
  background: var(--rot-tint);
  color: var(--rot);
  border-radius: 10px;
  padding: 11px 14px;
  font-size: 13.5px;
  margin-bottom: 17px;
}

footer {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 26px 40px;
  color: var(--grau-hell);
  font-size: 12px;
}

@media (max-width: 700px) {
  .org-zahlen { gap: 14px; }
  .org-zahlen .spalte.optional { display: none; }
  main { padding: 24px 18px 60px; }
  .kopf-innen { padding: 12px 18px; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
}

/* ── Formulare ───────────────────────────────────────────────────────────── */

/* Keine kuenstliche Verengung — die Seite ist ohnehin auf 1180px
   begrenzt und zentriert. Ein zusaetzliches Limit liess das Formular
   linksbuendig im Leerraum haengen. */
.formular { max-width: none; }

.feldreihe {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  margin-bottom: 18px;
}

.feld { flex: 1 1 260px; }
.feld.schmal { flex: 0 1 168px; }
.formular > .feld { margin-bottom: 18px; }

.feld select,
.feld textarea,
.feld input[type=text],
.feld input[type=date] {
  width: 100%;
  padding: 11px 13px;
  border: 1px solid var(--linie);
  border-radius: 11px;
  background: var(--feld);
  font-family: var(--sans);
  font-size: 15px;
  color: var(--braun);
}
.feld textarea { resize: vertical; line-height: 1.5; }
.feld select:focus, .feld textarea:focus, .feld input:focus {
  border-color: var(--orange);
  background: var(--weiss);
  outline: none;
}

.feldhinweis {
  margin: 6px 0 0;
  font-size: 12px;
  color: var(--grau);
}
.feldhinweis.warn { color: var(--amber); }
.feldhinweis code {
  font-family: var(--mono);
  font-size: 11.5px;
  background: var(--creme-tief);
  padding: 1px 5px;
  border-radius: 4px;
}

.formularfuss {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-top: 20px;
  margin-top: 6px;
  border-top: 1px solid var(--linie-fein);
}
.formularfuss .wachsen { flex: 1; }

.knopf.gefahr {
  background: transparent;
  color: var(--rot);
  border: 1px solid var(--rot-tint);
}
.knopf.gefahr:hover { background: var(--rot-tint); }

.fehlermeldung.breit { margin-bottom: 18px; }

.leise-link {
  color: var(--grau);
  font-size: 12.5px;
  text-decoration: none;
  border-bottom: 1px solid var(--linie);
}
.leise-link:hover { color: var(--orange-tief); border-bottom-color: var(--orange); }

/* ── Diagramme ───────────────────────────────────────────────────────────── */

.diagramm {
  margin: 0 0 16px;
  background: var(--weiss);
  border: 1px solid var(--linie);
  border-radius: var(--radius);
  padding: 16px 18px 12px;
}

.diagramm figcaption {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin-bottom: 12px;
}

.diagramm .d-titel { font-size: 14px; font-weight: 700; }
.diagramm .d-zusatz { font-size: 12.5px; color: var(--grau); }
.diagramm svg { display: block; width: 100%; height: auto; overflow: visible; }

.d-achse {
  font-family: var(--sans);
  font-size: 10px;
  font-weight: 500;
  fill: var(--grau-hell);
}

.legende { margin-left: auto; display: flex; gap: 16px; }
.l-eintrag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 600;
  color: var(--braun-weich);
}
.l-punkt { width: 9px; height: 9px; border-radius: 3px; }

/* Kompaktstreifen in der Kartenkopfzeile */
.streifen { width: 100%; height: 26px; margin-top: 7px; display: block; }

.org-detail .diagramm { background: var(--weiss); }

.vorschlagszeile { margin-bottom: 10px; gap: 12px; }
.vorschlagszeile .feld input { font-size: 14px; }
.knopf[disabled] { opacity: .45; cursor: not-allowed; }

.optional-marke {
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--grau-hell);
  text-transform: none;
  margin-left: 4px;
}

.feld.winzig { flex: 0 1 104px; }
.vorschlagszeile input[type=date] { font-size: 13.5px; }

/* Ein aus dem Text uebernommenes Datum wird markiert — sonst sieht man nicht,
   ob es aus der Maske stammt oder aus dem, was man geschrieben hat. */
.vorschlagszeile input.aus-text {
  border-color: var(--kupfer);
  background: var(--weiss);
}
.aus-text-hinweis { color: var(--kupfer); font-weight: 600; }

/* ── Auswahl für den Bericht ─────────────────────────────────────────────── */

.karte.zeile { display: flex; align-items: center; gap: 15px; margin-bottom: 10px; }

.auswahlkopf {
  padding-bottom: 10px;
  margin-bottom: 4px;
  border-bottom: 1px solid var(--linie);
}
.wahl-alle {
  display: inline-flex; align-items: center; gap: 9px;
  font-size: 12.5px; font-weight: 600; color: var(--grau); cursor: pointer;
  text-transform: none; letter-spacing: normal;
}

/* Die Zeile ist ein <label>, damit ein Klick irgendwo das Haekchen setzt.
   Der Label-Stil weiter oben macht daraus aber Versalien — hier
   zuruecknehmen, sonst schreit die halbe Seite. */
.wahlzeile {
  text-transform: none;
  letter-spacing: normal;
  font-weight: 400;
  font-size: 14px;
  color: var(--braun);
  display: flex;
  align-items: flex-start;
  gap: 13px;
  padding: 11px 12px;
  border-radius: 10px;
  cursor: pointer;
}
.wahlzeile:hover { background: var(--feld); }
.wahlzeile input { margin-top: 2px; accent-color: var(--orange); }
.wz-datum { width: 88px; flex-shrink: 0; font-size: 13px; font-weight: 600;
            color: var(--grau); text-transform: none; letter-spacing: normal; }
.wz-text { flex: 1; font-size: 14px; }
.wz-wer { display: block; font-size: 12px; color: var(--grau-hell); margin-top: 2px;
          text-transform: none; letter-spacing: normal; font-weight: 500; }
.wz-dauer { font-variant-numeric: tabular-nums; font-weight: 700; font-size: 14px; }

/* ── Der Bericht als Brief ───────────────────────────────────────────────── */

.brief {
  background: var(--weiss);
  border: 1px solid var(--linie);
  border-radius: var(--radius);
  padding: 42px 46px 34px;
  max-width: 800px;
  color: var(--braun);
}

.brief-kopf { display: flex; align-items: flex-start; gap: 26px; margin-bottom: 34px; }
.brief-logo { height: 56px; width: auto; }

.brief-meta {
  margin-left: auto;
  background: var(--creme);
  border: 1px solid var(--linie);
  border-radius: 10px;
  padding: 13px 16px;
  min-width: 244px;
}
.bm-titel { font-size: 13.5px; font-weight: 700; margin-bottom: 7px; }
.brief-meta dl { display: grid; grid-template-columns: auto 1fr; gap: 2px 12px; margin: 0; font-size: 11.5px; }
.brief-meta dt { color: var(--grau); }
.brief-meta dd { margin: 0; font-weight: 600; text-align: right; }

.absenderzeile {
  font-size: 8.5px;
  color: var(--grau);
  padding-bottom: 3px;
  border-bottom: 1px solid var(--linie);
  width: 62%;
  margin-bottom: 13px;
}
.empfaenger { font-size: 14px; line-height: 1.45; margin-bottom: 34px; }
.empfaenger strong { display: block; margin-bottom: 2px; }

.brief-titel {
  font-size: 20px; font-weight: 700; margin: 0 0 4px;
  padding-top: 14px; border-top: 1px solid var(--linie);
}
.brief-zeitraum { font-size: 13px; color: var(--grau); margin: 0 0 18px; }

.brief-tabelle { width: 100%; border-collapse: collapse; font-size: 13px; }
.brief-tabelle thead th {
  background: var(--braun); color: var(--creme);
  font-size: 10px; letter-spacing: 0.09em; text-transform: uppercase;
  padding: 8px 10px; text-align: left; border: none;
}
.brief-tabelle td { padding: 9px 10px; border-bottom: 1px solid var(--linie-fein); vertical-align: top; }
.brief-tabelle tbody tr:nth-child(even) { background: #FCFAF5; }
.t-pos { width: 40px; color: var(--grau); }
.t-datum { width: 92px; white-space: nowrap; }
.t-dauer { width: 76px; text-align: right; font-variant-numeric: tabular-nums; font-weight: 700; }
.brief-tabelle th.t-dauer { text-align: right; }
.t-wer { display: block; font-size: 11.5px; color: var(--grau); margin-top: 2px; }

.brief-summe {
  display: flex; justify-content: space-between; align-items: baseline;
  margin: 16px 0 0 auto; width: 268px;
  padding: 11px 14px;
  background: var(--creme); border: 1px solid var(--linie); border-radius: 9px;
  font-size: 14px;
}
.brief-summe strong { font-size: 17px; font-variant-numeric: tabular-nums; }

.brief-schluss { font-size: 11px; color: var(--grau); margin: 26px 0 0; }
.brief-fuss {
  display: flex; justify-content: space-between; gap: 16px;
  margin-top: 26px; padding-top: 10px;
  border-top: 1px solid var(--linie);
  font-size: 9.5px; color: var(--grau);
}

/* ── Druck ───────────────────────────────────────────────────────────────── */

@media print {
  @page { size: A4; margin: 16mm 15mm; }
  .kopf, footer, .nicht-drucken { display: none !important; }
  body { background: #fff; font-size: 11pt; }
  main { padding: 0; max-width: none; }
  .brief {
    border: none; border-radius: 0; padding: 0; max-width: none;
    background: #fff;
  }
  .brief-tabelle thead th { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .brief-tabelle tbody tr:nth-child(even) { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .brief-tabelle tr { break-inside: avoid; }
  .brief-summe, .brief-fuss { break-inside: avoid; }
}

/* ── Vorschlagszeilen ────────────────────────────────────────────────────── */

.vorschlagszeile {
  padding: 16px 0;
  border-bottom: 1px solid var(--linie-fein);
}
.vorschlagszeile:first-of-type { padding-top: 4px; }
.vorschlagszeile:last-of-type { border-bottom: none; }


textarea.waechst {
  width: 100%;
  min-height: 46px;
  resize: vertical;
  overflow: hidden;
  line-height: 1.5;
  font-size: 14.5px;
}

/* Zweispaltig: links Dauer und Datum nebeneinander — sie brauchen wenig
   Platz —, rechts der Text mit allem, was uebrig bleibt.

   align-items: start statt end. Ein Datumsfeld ist wegen des Kalendersymbols
   hoeher als ein Textfeld; an der Unterkante ausgerichtet rutscht dessen
   Beschriftung nach unten. */
.vorschlagszeile {
  display: grid;
  grid-template-columns: 250px 1fr;
  gap: 24px;
  align-items: start;
}

.vz-links { display: flex; flex-direction: column; gap: 7px; }
.vz-felder { display: flex; gap: 10px; align-items: start; }
.vz-felder .feld { flex: none; margin: 0; }
.vz-dauer { width: 84px; }
.vz-datum { width: 156px; }

.vz-nummer {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--grau-hell);
}

.vz-rechts { min-width: 0; }
.vz-rechts textarea { min-height: 74px; }

@media (max-width: 720px) {
  .vorschlagszeile { grid-template-columns: 1fr; gap: 12px; }
}

/* ── Abrechnung ──────────────────────────────────────────────────────────── */

h3.abschnitt {
  display: flex;
  align-items: baseline;
  gap: 12px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--grau);
  margin: 24px 0 6px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--linie);
}
h3.abschnitt:first-of-type { margin-top: 10px; }
.ab-summe {
  margin-left: auto;
  text-transform: none;
  letter-spacing: normal;
  font-size: 13.5px;
  color: var(--braun);
  font-variant-numeric: tabular-nums;
}

.wz-betrag {
  width: 92px;
  text-align: right;
  font-variant-numeric: tabular-nums;
  font-weight: 700;
  font-size: 14px;
  text-transform: none;
  letter-spacing: normal;
}

.ab-gesamt {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding: 12px 2px;
  margin-top: 6px;
  border-top: 1px solid var(--linie);
  font-size: 15px;
}
.ab-gesamt strong { font-size: 18px; font-variant-numeric: tabular-nums; }
.ab-gesamt.leise-zeile {
  border-top: none;
  padding: 2px 2px;
  margin-top: 0;
  font-size: 13px;
  color: var(--grau);
}
.ab-gesamt.leise-zeile span { font-variant-numeric: tabular-nums; }

.hinweis.gut {
  border-left-color: var(--gruen);
  background: var(--gruen-tint);
  color: var(--gruen);
}
.feld-klein { font-size: 12.5px; color: var(--grau); margin-top: 3px; }

/* ── Positionen mit Zeitleiste ───────────────────────────────────────────── */

.pos-karte { padding: 0; margin-bottom: 12px; }
.pos-kopf { display: flex; align-items: center; gap: 15px; padding: 16px 20px; }

.zeitleiste {
  display: flex;
  align-items: center;
  gap: 5px;
  flex-wrap: wrap;
  padding: 12px 20px 14px;
  border-top: 1px solid var(--linie-fein);
  background: var(--creme);
  border-radius: 0 0 var(--radius) var(--radius);
}

.zl-monat {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  width: 34px;
}
.zl-punkt {
  width: 100%;
  height: 6px;
  border-radius: 3px;
  background: var(--linie);
}
.zl-monat.erledigt .zl-punkt { background: var(--gruen); }
.zl-monat.offen .zl-punkt { background: var(--amber); }
.zl-text {
  font-size: 10px;
  font-weight: 600;
  color: var(--grau-hell);
  font-variant-numeric: tabular-nums;
}
.zl-monat.erledigt .zl-text { color: var(--gruen); }
.zl-monat.offen .zl-text { color: var(--amber); }

.zl-legende {
  margin-left: auto;
  font-size: 12px;
  color: var(--grau);
  align-self: flex-end;
  padding-bottom: 2px;
}

.offen-teile { display: flex; flex-wrap: wrap; gap: 16px; margin-top: 6px; }
.ot-teil {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 12.5px; font-weight: 600; color: var(--braun-weich);
}
.ot-punkt { width: 7px; height: 7px; border-radius: 50%; }
.ot-punkt.stunden { background: var(--kupfer); }
.ot-punkt.lizenz { background: var(--orange); }


/* Steht der Waehler in einem noch nicht angebrochenen Monat, zeigt er das
   selbst — das braucht keinen Erklaersatz daneben. */
.monatswahl.voraus .jetzt { color: var(--orange-tief); }
.monatswahl.voraus a, .monatswahl.voraus span.leer { border-color: var(--kupfer-hell); }

.zl-text { line-height: 1.25; text-align: center; }

.zl-leer { color: var(--grau-hell); font-size: 13px; }

/* ── Systemstatus ────────────────────────────────────────────────────────── */

.befund {
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 11px 0;
  border-bottom: 1px solid var(--linie-fein);
}
.befund:last-child { border-bottom: none; }
.bf-punkt { width: 9px; height: 9px; border-radius: 50%; flex-shrink: 0; }
.bf-text { font-size: 14.5px; }
.bf-name {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--grau-hell);
  margin-top: 2px;
}

.verlaufsband { display: flex; gap: 2px; align-items: flex-end; height: 34px; }
.vb-strich { flex: 1; min-width: 3px; height: 100%; border-radius: 2px; opacity: .85; }

tr.fehler-app td { background: #FDF6F3; }

/* Die Zeitleisten-Monate sind Knoepfe: ein Klick hakt ab oder gibt frei. */
.zl-form { display: inline; margin: 0; }
button.zl-monat {
  background: none;
  border: none;
  padding: 2px 1px;
  cursor: pointer;
  font-family: inherit;
}
button.zl-monat:hover .zl-punkt { outline: 2px solid var(--kupfer); outline-offset: 1px; }
button.zl-monat:hover .zl-text { color: var(--braun); }
