/*
  THEMA „tweakcn“ für NEXT (Design-Entscheidung Jeton, 09.11.2026).
  Liegt ÜBER stil.css: stil.css bleibt das klassische NEXT, diese Datei setzt nur das neue Aussehen darauf.
  Wer das alte Aussehen zurück will, nimmt einfach den <link> auf thema.css in kern/templates/kern/basis.html heraus.

  Vorbild ist das tweakcn-Design aus dem Canvas „NEXT Designvergleich“ (Werte von dort übernommen):
  1. Grundlage – warme Farben, Plus Jakarta Sans, große Rundungen, weiche Schatten, Pillen-Knöpfe und -Felder
  2. Rahmen – schwebende Seitenleiste (Firma, Menüsuche, aufklappbare Gruppen, Unterpunkte, Benutzer unten),
     Inhalt als abgesetzte Fläche mit Kopfzeile (Brotkrumen, ⌘K-Suche, Glocke)
  3. Bausteine – Pillen-Reiter, Marken, Tabellen in Karten, Meldungen gestapelt wie „Sonner“
  4. Handy – helle Kopfleiste, Menü als Schublade, schwebende App-Leiste
  5. Startseite – ruhig treibende Farbflächen im Hintergrund, Karten erscheinen nacheinander
  6. Seiteninhalte wie im Canvas (Schritt 3) – Kopf mit Aktionen rechts, Kennzahl-Karten, Filter-Pillen mit Zahl,
     Tabellen mit leisen Spaltenköpfen, Fristen als Punkt + farbiger Text
*/

/* --- Schrift: Plus Jakarta Sans (SIL Open Font License, liegt in schriften/plus-jakarta – kein Google-Abruf) --- */
@font-face { font-family: "Plus Jakarta Sans"; font-weight: 400; font-style: normal; font-display: swap;
  src: url("schriften/plus-jakarta/plus-jakarta-sans-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Plus Jakarta Sans"; font-weight: 500; font-style: normal; font-display: swap;
  src: url("schriften/plus-jakarta/plus-jakarta-sans-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "Plus Jakarta Sans"; font-weight: 600; font-style: normal; font-display: swap;
  src: url("schriften/plus-jakarta/plus-jakarta-sans-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Plus Jakarta Sans"; font-weight: 700; font-style: normal; font-display: swap;
  src: url("schriften/plus-jakarta/plus-jakarta-sans-latin-700-normal.woff2") format("woff2"); }
@font-face { font-family: "Plus Jakarta Sans"; font-weight: 800; font-style: normal; font-display: swap;
  src: url("schriften/plus-jakarta/plus-jakarta-sans-latin-800-normal.woff2") format("woff2"); }
/* M16 (Testlauf 14.11.2026): Namen wie Petrović, Šimić, Łukasz, Yılmaz – erweiterte Buchstaben (latin-ext) */
@font-face { font-family: "Plus Jakarta Sans"; font-weight: 400; font-style: normal; font-display: swap;
  src: url("schriften/plus-jakarta/plus-jakarta-sans-latin-ext-400-normal.woff2") format("woff2");
  unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Plus Jakarta Sans"; font-weight: 500; font-style: normal; font-display: swap;
  src: url("schriften/plus-jakarta/plus-jakarta-sans-latin-ext-500-normal.woff2") format("woff2");
  unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Plus Jakarta Sans"; font-weight: 600; font-style: normal; font-display: swap;
  src: url("schriften/plus-jakarta/plus-jakarta-sans-latin-ext-600-normal.woff2") format("woff2");
  unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Plus Jakarta Sans"; font-weight: 700; font-style: normal; font-display: swap;
  src: url("schriften/plus-jakarta/plus-jakarta-sans-latin-ext-700-normal.woff2") format("woff2");
  unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Plus Jakarta Sans"; font-weight: 800; font-style: normal; font-display: swap;
  src: url("schriften/plus-jakarta/plus-jakarta-sans-latin-ext-800-normal.woff2") format("woff2");
  unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }

/* --- Farben und Formen: dieselben Variablen wie stil.css, nur mit tweakcn-Werten --------------------------------- */
:root {
  --hintergrund: #faf7f5;            /* warmes Off-White statt kühlem Grau */
  --karte: #ffffff;
  --linie: #eee4df;                  /* warme, helle Ränder */
  --feldrand: #e8dcd7;
  --zeile-hover: #fbf3f0;
  --text: #2a2120;                   /* warmes Fast-Schwarz */
  --text-leise: #75655f;             /* warmes Grau, Kontrast auf Weiß 5,6:1 */
  --ueberschrift: #3a1e22;           /* Überschriften: dunkles Bordeaux-Braun */
  --akzent-hell: #f6e9eb;
  --radius: 18px;                    /* Karten */
  --radius-feld: 12px;               /* Felder */
  --ring: 0 0 0 3px rgba(123, 30, 43, .18);
  --schatten: 0 1px 2px rgba(90, 40, 40, .04), 0 4px 12px rgba(90, 40, 40, .05), 0 18px 36px -14px rgba(90, 40, 40, .12);
  --schatten-hoch: 0 2px 6px rgba(90, 40, 40, .06), 0 16px 40px rgba(90, 40, 40, .18);
  --schatten-knopf: inset 0 1px 0 rgba(255, 255, 255, .18), 0 4px 14px rgba(123, 30, 43, .30);
}

/* Am Rechner so dicht wie im Canvas: Grundschrift 14 px statt 16 px (alle rem-Maße schrumpfen mit).
   Am Handy bleiben 16 px – kleinere Eingabefelder würden iPhones beim Antippen hineinzoomen lassen. */
@media (min-width: 901px) { html { font-size: 14px; } }
body { font-size: 1rem; }   /* folgt der Grundschrift (stil.css hatte feste 16 px) */

body {
  font-family: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  background: var(--hintergrund);
  -webkit-font-smoothing: antialiased;
}
h1 { font-weight: 800; letter-spacing: -.03em; color: var(--ueberschrift); }
h2 { font-weight: 700; letter-spacing: -.01em; }

/* --- Karten ------------------------------------------------------------------------------------------------- */
.karte { border-radius: var(--radius); border-color: var(--linie); box-shadow: var(--schatten); }

/* --- Knöpfe: Pillen mit weichem Schatten, geben beim Klicken nach -------------------------------------------- */
.knopf, button.knopf {
  border-radius: 999px; box-shadow: var(--schatten-knopf);
  transition: transform .14s cubic-bezier(.2, .8, .2, 1), box-shadow .14s, background-color .14s, filter .14s;
}
.knopf:hover { transform: translateY(-1px); }
.knopf:active { transform: translateY(1px) scale(.97); }
.knopf.zweit { background: var(--akzent-hell); border: 0; box-shadow: inset 0 -1px 0 rgba(123, 30, 43, .08); }
.knopf.zweit:hover { background: #f1dde0; }
.knopf.gefahr { border-radius: 999px; box-shadow: none; }
.knopf.dunkel { box-shadow: 0 4px 14px rgba(56, 62, 66, .28); }
.knopf.mini { border-radius: 999px; }

/* --- Felder: weicher Rand, Fokus als Ring statt harter Linie ------------------------------------------------- */
input[type=text], input[type=email], input[type=password], input[type=number], input[type=date], input[type=time],
input[type=search], input[type=file], select, textarea {
  border-radius: var(--radius-feld); border-color: var(--feldrand);
  box-shadow: inset 0 1px 2px rgba(90, 40, 40, .05);
  transition: box-shadow .15s, border-color .15s;
}
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--akzent); box-shadow: var(--ring); }
input[type=checkbox], input[type=radio] { accent-color: var(--akzent); }

/* --- Tabellen: ruhige Köpfe wie bei shadcn (nicht in Großbuchstaben) ------------------------------------------ */
th { text-transform: none; letter-spacing: 0; font-size: .84rem; font-weight: 600; border-bottom-width: 1px; }
tbody tr { transition: background-color .15s; }
@media (max-width: 700px) {
  table.handy-karten tr { border-radius: 14px; box-shadow: var(--schatten); border-color: var(--linie); }
}

/* --- Marken und Meldungen --------------------------------------------------------------------------------------- */
.marke { border-radius: 8px; padding: .12rem .55rem; }
.meldung { border-radius: 14px; box-shadow: var(--schatten); }


/* ============================================================================================================
   2. RAHMEN – wie die shadcn-„Sidebar“ (Variante „floating“) im Canvas
   ============================================================================================================ */
:root { --leiste-breite: 256px; --rahmen-grund: #f1e8e3; --leise-warm: #8c7a73; }
html.leiste-schmal { --leiste-breite: 76px; }

body.mit-leiste { background: var(--rahmen-grund); align-items: stretch; }
.seitenleiste {
  position: sticky; top: 8px; margin: 8px; height: calc(100vh - 16px); width: var(--leiste-breite);
  background: #fff; color: #4b403d; border: 1px solid var(--linie); border-radius: 20px;
  box-shadow: 0 1px 2px rgba(90, 40, 40, .04), 0 16px 40px -18px rgba(90, 40, 40, .22);
  padding: 10px 10px 0; gap: 8px; transition: width .2s ease;
  scrollbar-width: thin; scrollbar-color: #e8dcd7 transparent;
}

/* Kopf: „Team-Umschalter“ (NEXT + Firma) */
.sb-team { position: relative; flex: none; }
.sb-team > summary, a.sb-team {
  display: flex; align-items: center; gap: 10px; padding: 8px; border-radius: 14px; background: #faf3f0;
  color: #3a1e22; cursor: pointer; list-style: none; text-decoration: none;
}
.sb-team > summary::-webkit-details-marker { display: none; }
.sb-team > summary:hover, a.sb-team:hover { background: #f6ebe7; text-decoration: none; }
.sb-logo {
  flex: none; display: grid; place-items: center; width: 32px; height: 32px; border-radius: 10px;
  background: var(--akzent); color: #fff; font-weight: 800; font-size: .95rem; box-shadow: 0 4px 10px rgba(123, 30, 43, .35);
}
.sb-team-text { display: grid; line-height: 1.2; min-width: 0; flex: 1; }
.sb-team-text strong { font-size: .9rem; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* Jeton 09.11.2026: oben links der ganze Schriftzug NEXT (X in Bordeaux) statt nur des X im Quadrat */
.sb-wortmarke { font-size: 1.15rem !important; font-weight: 800 !important; letter-spacing: .14em; color: #383e42; line-height: 1.15; }
.sb-wortmarke span { color: var(--akzent); }
html.leiste-schmal .sb-team-text { display: grid !important; }
html.leiste-schmal .sb-team-text small { display: none; }
html.leiste-schmal .sb-wortmarke { font-size: .78rem !important; letter-spacing: .06em; }
.sb-team-text small { font-size: .75rem; color: var(--text-leise); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sb-auf-zu { flex: none; color: var(--leise-warm); }

/* Aufklappfenster (Firma oben, Benutzer unten) */
.sb-pop {
  position: absolute; left: 0; right: 0; z-index: 60; background: #fff; border: 1px solid var(--linie); border-radius: 16px;
  box-shadow: 0 2px 6px rgba(90, 40, 40, .06), 0 16px 40px rgba(90, 40, 40, .18); padding: 6px;
}
.sb-team .sb-pop { top: calc(100% + 6px); }
.sb-pop-titel { font-size: .72rem; font-weight: 700; color: var(--leise-warm); padding: 4px 8px 6px; }
.seitenleiste .firmen-schalter { display: grid; grid-auto-flow: row; gap: 2px; margin: 0; background: #fff; }
.seitenleiste .fs-knopf {
  display: flex; align-items: center; gap: 10px; justify-content: flex-start; min-height: 38px; padding: 4px 10px;
  border-radius: 10px; color: #4b403d; font-weight: 600; font-size: .86rem; text-align: left;
}
.seitenleiste .fs-knopf:hover { background: #faf1ee; }
.seitenleiste .fs-knopf.an { background: var(--akzent-hell); color: var(--akzent); box-shadow: none; }
.seitenleiste .fs-knopf .firmenzeichen { opacity: 1; height: 1.25rem; }
.fs-beide { display: inline-grid; place-items: center; min-width: 2.4rem; height: 1.25rem; border-radius: 6px; background: #f5eeea; font-size: .68rem; font-weight: 800; }
.fs-name { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* Menü durchsuchen */
.sb-suche {
  flex: none; display: flex; align-items: center; gap: 6px; margin: 0; padding: 0 10px; height: 34px; font-weight: 400;
  border: 1px solid var(--linie); border-radius: 999px; background: var(--hintergrund); color: var(--leise-warm);
}
.sb-suche input[type=search] { border: 0; background: transparent; box-shadow: none; padding: 0; height: 100%; font-size: .84rem; min-width: 0; }
.sb-suche input[type=search]:focus { box-shadow: none; }
.sb-suche:focus-within { border-color: var(--akzent); box-shadow: var(--ring); }
kbd { font: 600 .68rem/1 "Plus Jakarta Sans", system-ui, sans-serif; color: var(--leise-warm); background: #fff; border: 1px solid var(--linie); border-radius: 6px; padding: 3px 5px; }

/* Menüpunkte als Pillen */
.menue { gap: 1px; }
.menue a {
  position: relative; min-height: 36px; padding: 7px 10px; gap: 10px; border-radius: 999px;
  color: #4b403d; font-size: .9rem; font-weight: 500; transition: background-color .15s, color .15s;
}
.menue a svg { opacity: 1; width: 17px; height: 17px; }
.menue a:hover { background: #faf1ee; color: #3a1e22; }
.menue a.aktiv { background: var(--akzent); color: #fff; font-weight: 600; box-shadow: 0 6px 14px -4px rgba(123, 30, 43, .45); }
.menue a.eltern-aktiv { color: var(--akzent); font-weight: 600; }
.menue a.passt-nicht { display: none; }
.menue.sucht .sb-unter { display: block; }
.menue.sucht .sb-gruppe { display: block !important; }
.ohne-treffer { display: none !important; }

/* Gruppen-Überschriften: klickbar, mit Pfeil */
.menue .menue-gruppe {
  display: flex; align-items: center; justify-content: space-between; width: 100%; height: 30px; margin: 8px 0 0; padding: 0 10px;
  font: 700 .68rem/1 "Plus Jakarta Sans", system-ui, sans-serif; letter-spacing: .06em; text-transform: uppercase; color: #7a6862;
  background: none; border: 0; border-radius: 8px; cursor: pointer;
}
.menue .menue-gruppe:hover { color: #3a1e22; background: #faf6f4; }
.sb-pfeil { width: 14px; height: 14px; flex: none; transition: transform .2s; }
.menue-gruppe .sb-pfeil { transform: rotate(90deg); }
.menue-gruppe[aria-expanded=false] .sb-pfeil { transform: none; }
.sb-gruppe { display: flex; flex-direction: column; gap: 1px; }

/* Unterpunkte: eingerückt mit Linie, klappen am Pfeil des Hauptpunkts auf */
.sb-unter-knopf {
  margin-left: auto; display: grid; place-items: center; width: 24px; height: 24px; margin-right: -4px; padding: 0;
  border: 0; border-radius: 999px; background: transparent; color: inherit; cursor: pointer; opacity: .7;
}
.sb-unter-knopf:hover { background: rgba(123, 30, 43, .08); opacity: 1; }
.menue a.aktiv .sb-unter-knopf:hover { background: rgba(255, 255, 255, .18); }
.menue a .menue-zahl + .sb-unter-knopf { margin-left: 4px; }
.hat-unter.offen .sb-unter-knopf .sb-pfeil { transform: rotate(90deg); }
.sb-unter { display: none; margin: 2px 0 6px 18px; padding: 2px 0 2px 10px; border-left: 2px solid #f0e3de; }
.hat-unter.offen + .sb-unter { display: block; }
.sb-unter a, .menue a.menue-unter { padding-left: 10px; min-height: 32px; font-size: .86rem; }
.menue .sb-unter a.aktiv { background: var(--akzent-hell); color: var(--akzent); box-shadow: none; }

/* Zahlen im Menü: helle Pillen, „rot“ = Bordeaux, im leuchtenden Punkt weiß */
.menue-zahl { background: var(--akzent-hell); color: var(--akzent); font-size: .68rem; line-height: 18px; padding: 0 7px; border-radius: 999px; }
.menue-zahl.rot { background: var(--akzent); color: #fff; }
.menue-zahl.grau { background: #f5eeea; color: #5f504b; }
.menue a.aktiv .menue-zahl { background: rgba(255, 255, 255, .22); color: #fff; }
.menue-zahl .symbol { width: .9em; height: .9em; margin-right: .15em; }

/* Stempel-Box unten in der Leiste – hell im neuen Rahmen */
.leiste-stempel { margin: 6px 0 0; background: #faf3f0; color: #3a1e22; border-left-color: #c9b8b2; border-radius: 14px; }
.leiste-stempel .leise { color: var(--text-leise); }
.leiste-stempel.laeuft { border-left-color: var(--akzent); }

/* Benutzer unten */
.sb-benutzer { position: sticky; bottom: 0; flex: none; margin: 0 -10px; padding: 8px 10px 10px; background: #fff; border-top: 1px solid #f0e8e4; border-radius: 0 0 20px 20px; z-index: 5; }
.sb-benutzer > summary { display: flex; align-items: center; gap: 10px; padding: 6px; border-radius: 14px; cursor: pointer; list-style: none; }
.sb-benutzer > summary::-webkit-details-marker { display: none; }
.sb-benutzer > summary:hover { background: #faf3f0; }
.sb-avatar { flex: none; display: grid; place-items: center; width: 32px; height: 32px; border-radius: 999px; background: var(--akzent-hell); color: var(--akzent); font-weight: 800; font-size: .78rem; }
.sb-benutzer .sb-pop { bottom: calc(100% - 4px); left: 8px; right: 8px; }
.seitenleiste .benutzer-menue { border-top: 0; padding: 10px; gap: .45rem; color: var(--text); }
.seitenleiste .benutzer-menue a, .seitenleiste .benutzer-menue button { color: #4b403d; }
.seitenleiste .benutzer-menue a:hover, .seitenleiste .benutzer-menue button:hover { color: var(--akzent); }
.seitenleiste .benutzer-name { display: none; }                 /* steht schon im Kopf des Fensters */
.seitenleiste .hilfe-links { display: flex; gap: .8rem; flex-wrap: wrap; align-items: center; }
.seitenleiste .testzugang-wechsel select { font-size: .82rem; }

/* Menü schmal: nur Symbole */
html.leiste-schmal .seitenleiste { padding-left: 8px; padding-right: 8px; }
html.leiste-schmal .sb-team-text, html.leiste-schmal .sb-auf-zu, html.leiste-schmal .sb-suche,
html.leiste-schmal .menue .menue-gruppe, html.leiste-schmal .menue-zahl, html.leiste-schmal .sb-unter-knopf,
html.leiste-schmal .sb-unter, html.leiste-schmal .leiste-stempel { display: none !important; }
html.leiste-schmal .sb-team > summary, html.leiste-schmal a.sb-team, html.leiste-schmal .sb-benutzer > summary { justify-content: center; padding: 8px 0; }
html.leiste-schmal .menue a { justify-content: center; font-size: 0; gap: 0; padding: 0; height: 40px; }
html.leiste-schmal .menue a svg { width: 19px; height: 19px; }
html.leiste-schmal .sb-gruppe { display: flex !important; }
html.leiste-schmal .sb-gruppe + .menue-gruppe { display: block !important; height: 1px; padding: 0; margin: 6px 8px; background: #f0e8e4; font-size: 0; }
html.leiste-schmal .sb-pop { left: 0; right: auto; width: 240px; }

/* Inhalt als abgesetzte Fläche */
body.mit-leiste main {
  position: relative; margin: 8px 8px 8px 0; min-height: calc(100vh - 16px); max-width: none;
  background: var(--hintergrund); border: 1px solid var(--linie); border-radius: 22px;
  box-shadow: 0 1px 2px rgba(90, 40, 40, .04), 0 18px 40px -20px rgba(90, 40, 40, .25);
  padding: 0 2rem 4rem; overflow: clip;
}
main.startseite > :not(.kopf-leiste):not(.hg):not(.ansehen-als-leiste):not(dialog):not(script) { position: relative; z-index: 1; }

/* Kopfzeile: Menüknopf · Zurück · Brotkrumen  |  Suche · + Neu · Glocke */
body.mit-leiste .kopf-leiste {
  position: sticky; top: 0; z-index: 40; margin: 0 -2rem 1.6rem; padding: 10px 1.1rem; min-height: 58px;
  /* Tempo (Jeton, 09.11.2026: „deutlich langsamer“): keine Milchglas-Unschärfe – die rechnet beim Scrollen jedes
     Bild neu. Fast deckende Fläche sieht gleich aus und kostet nichts. */
  background: rgba(250, 247, 245, .97);
  border-bottom: 1px solid #f0e8e4;
}
.kopf-links, .kopf-rechts { display: flex; align-items: center; gap: 8px; min-width: 0; }
.kopf-links { flex: 1; }
.kopf-symbol {
  position: relative; display: grid; place-items: center; width: 36px; height: 36px; flex: none; border: 0; border-radius: 999px;
  background: transparent; color: #5f504b; cursor: pointer; text-decoration: none;
}
.kopf-symbol:hover { background: #f5eeea; color: var(--akzent); text-decoration: none; }
.kopf-glocke { background: #f5eeea; }
.kopf-punkt { position: absolute; top: 7px; right: 8px; width: 8px; height: 8px; border-radius: 50%; background: var(--akzent); border: 2px solid #f5eeea; }
.zurueck-knopf { padding: .32rem .8rem; border: 1px solid var(--linie); border-radius: 999px; background: #fff; font-size: .84rem; color: #4b403d; box-shadow: 0 1px 2px rgba(90, 40, 40, .05); }
.krumen { display: flex; align-items: center; gap: 7px; min-width: 0; font-size: .88rem; color: var(--text-leise); white-space: nowrap; overflow: hidden; }
.krumen a { color: var(--text-leise); }
.krumen a:hover { color: var(--akzent); text-decoration: none; }
.krumen-trenner { color: #c9b8b2; }
.krumen-hier { color: #3a1e22; font-weight: 600; overflow: hidden; text-overflow: ellipsis; }
.kopf-suche {
  display: flex; align-items: center; gap: 8px; height: 36px; padding: 0 8px 0 12px; width: 15rem; cursor: pointer;
  border: 1px solid var(--linie); border-radius: 999px; background: #f5eeea; color: #75655f; font: inherit; font-size: .84rem;
}
.kopf-suche span { flex: 1; text-align: left; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kopf-suche:hover { border-color: #e2d3cd; color: #3a1e22; }
.kopf-rechts .neu-leiste .knopf.klein { height: 36px; padding: 0 .95rem; display: inline-flex; align-items: center; }

/* ⌘K-Fenster */
.befehl-fenster {
  width: min(560px, calc(100vw - 32px)); max-height: min(70vh, 520px); padding: 0; margin: 12vh auto auto; overflow: hidden;
  border: 1px solid var(--linie); border-radius: 22px; background: #fff; color: var(--text);
  box-shadow: 0 4px 12px rgba(90, 40, 40, .08), 0 36px 90px rgba(58, 30, 34, .32);
}
.befehl-fenster[open] { display: flex; flex-direction: column; animation: tw-auf .18s cubic-bezier(.2, .8, .2, 1); }
.befehl-fenster::backdrop { background: rgba(58, 30, 34, .38); }
.befehl-form { display: flex; align-items: center; gap: 10px; padding: 0 16px; height: 56px; border-bottom: 1px solid #f0e8e4; color: var(--leise-warm); }
.befehl-form input[type=search] { border: 0; box-shadow: none; padding: 0; height: 100%; font-size: 1rem; background: transparent; }
.befehl-form input[type=search]:focus { box-shadow: none; }
.befehl-liste { overflow-y: auto; padding: 6px; }
.befehl-gruppe { font-size: .7rem; font-weight: 700; color: var(--leise-warm); padding: 10px 10px 4px; text-transform: uppercase; letter-spacing: .05em; }
.befehl-eintrag { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 12px; color: var(--text); font-size: .92rem; }
.befehl-eintrag svg { width: 17px; height: 17px; color: var(--leise-warm); flex: none; }
.befehl-eintrag:hover, .befehl-eintrag.gewaehlt { background: var(--akzent-hell); color: var(--akzent); text-decoration: none; }
.befehl-eintrag.gewaehlt svg { color: var(--akzent); }
.befehl-leer { padding: 24px; text-align: center; color: var(--text-leise); }

/* ============================================================================================================
   3. BAUSTEINE
   ============================================================================================================ */
h1 { font-size: 1.9rem; line-height: 1.15; }
.seitenkopf { align-items: flex-end; margin-bottom: 1.4rem; }
.seitenkopf .leise { margin-top: .2rem; }

/* Reiter als Pillen (Rechnungen · Offene Posten · …), auch in der Projektakte */
.reiter, .projekt-reiter { border-bottom: 0; gap: 6px; padding-bottom: 4px; }
.reiter a, .projekt-reiter a {
  border: 0; margin: 0; padding: .5rem 1rem; border-radius: 999px; background: #f5eeea; color: #5f504b; font-size: .88rem; font-weight: 600;
  transition: background-color .15s, color .15s, box-shadow .15s;
}
.reiter a:hover, .projekt-reiter a:hover { background: #efe4df; color: #3a1e22; text-decoration: none; }
.reiter a.aktiv, .projekt-reiter a.aktiv { background: var(--akzent); color: #fff; box-shadow: 0 4px 12px rgba(123, 30, 43, .30); }
.reiter-zahl { background: rgba(123, 30, 43, .1); color: inherit; }
.reiter a.aktiv .reiter-zahl, .projekt-reiter a.aktiv .reiter-zahl { background: rgba(255, 255, 255, .22); color: #fff; }

/* Kennzahlen und Karten */
.kennzahl { font-weight: 800; letter-spacing: -.02em; }
.karte { transition: box-shadow .2s, transform .2s; }
a.karte:hover { transform: translateY(-4px); box-shadow: 0 2px 4px rgba(90, 40, 40, .05), 0 22px 44px -10px rgba(90, 40, 40, .22); text-decoration: none; }
.karte h2 { font-size: 1rem; }

/* Felder als Pillen (mehrzeilige Felder bleiben rund-eckig) */
input[type=text], input[type=email], input[type=password], input[type=number], input[type=date], input[type=time],
input[type=search], select { border-radius: 999px; padding-left: 1rem; padding-right: 1rem; }
textarea { border-radius: 14px; }
.start-suche input { padding: .7rem 1.2rem; }

/* Tabellen: ruhig, Zeilen mit Hover, Kopf ohne Großbuchstaben */
th { color: #75655f; padding: .7rem .7rem; border-bottom: 1px solid #f0e8e4; }
td { padding: .8rem .7rem; border-bottom: 1px solid #f5eeea; }
tbody tr:hover { background: #fbf3f0; }
.karte > table:first-child th, .karte > table:first-child thead tr:first-child th { padding-top: .2rem; }

/* Marken wie Badges (eckig-rund, kräftig) */
.marke { font-weight: 700; font-size: .75rem; padding: .18rem .6rem; white-space: nowrap; }
/* N5 (Testlauf 12.11.2026): lange Marken im Fließtext und in Handy-Karten brechen um (z. B. Fahrzeit-Hinweis im
   Auftragsblatt) – sonst wurde die Seite am iPhone breiter als der Bildschirm. In Tabellen bleiben sie einzeilig. */
p .marke, .leise .marke, li .marke { white-space: normal; }
@media (max-width: 900px) { .handy-karten .marke, .karte > .marke { white-space: normal; } }
.marke.gueltig    { background: #e7f3eb; color: #276a3f; }
.marke.laeuft_ab  { background: #fdf0d5; color: #8a560c; }
.marke.abgelaufen { background: #fbe6e3; color: #9e2f24; }
.marke.grau       { background: #f5eeea; color: #5f504b; }

/* Aufklappmenüs (+ Neu, Export, ⋯ Mehr) */
.neu-menue { border-radius: 16px; padding: 6px; box-shadow: 0 2px 6px rgba(90, 40, 40, .06), 0 16px 40px rgba(90, 40, 40, .18); animation: tw-auf .16s cubic-bezier(.2, .8, .2, 1); }
.neu-menue a { border-radius: 12px; }
.neu-menue a:hover { background: #faf1ee; }

/* Meldungen gestapelt unten rechts, wie „Sonner“ */
.meldungen-stapel { position: fixed; right: 20px; bottom: 20px; z-index: 9000; display: flex; flex-direction: column; gap: 10px; width: min(380px, calc(100vw - 32px)); }
.meldungen-stapel .meldung {
  position: relative; margin: 0; padding: 14px 40px 14px 16px; border-radius: 18px; background: #fff; color: var(--text);
  border: 1px solid var(--linie); border-left: 4px solid var(--leise-warm); font-size: .9rem;
  box-shadow: 0 2px 6px rgba(90, 40, 40, .06), 0 18px 40px -8px rgba(90, 40, 40, .28); animation: tw-meldung .3s cubic-bezier(.2, .8, .2, 1);
}
.meldungen-stapel .meldung.success { border-left-color: #2f7d4a; }
.meldungen-stapel .meldung.error   { border-left-color: var(--rot); background: #fffafa; }
.meldungen-stapel .meldung.warning { border-left-color: #c48a1d; }
.meldungen-stapel .meldung.info    { border-left-color: #4a7aa6; }
.meldungen-stapel .meldung.geht { opacity: 0; transform: translateX(24px); transition: opacity .25s, transform .25s; }
.meldung-weg { position: absolute; top: 8px; right: 8px; width: 26px; height: 26px; border: 0; border-radius: 999px; background: transparent; color: var(--leise-warm); font-size: 1.1rem; line-height: 1; cursor: pointer; }
.meldung-weg:hover { background: #f5eeea; color: var(--text); }
@keyframes tw-meldung { from { opacity: 0; transform: translateY(16px) scale(.97); } }
@keyframes tw-auf { from { opacity: 0; transform: translateY(8px) scale(.98); } }

/* Anmeldeseite: warmer Grund, Karte hoch */
body:not(.mit-leiste) { background: #f3e9e6; }
.anmelde-box .logo { color: #3a1e22; font-size: 1.6rem; }
.anmelde-box .karte, .anmelde-box form.karte { border-radius: 22px; box-shadow: 0 2px 4px rgba(90, 40, 40, .05), 0 12px 28px rgba(90, 40, 40, .08), 0 30px 60px -20px rgba(123, 30, 43, .18); }

/* ============================================================================================================
   4. HANDY (bis 900 px Breite)
   ============================================================================================================ */
.handy-titel { display: none; }
@media (max-width: 900px) {
  body.mit-leiste { background: var(--hintergrund); }
  body.mit-leiste main { margin: 0; border: 0; border-radius: 0; box-shadow: none; min-height: 0; padding: 0 1rem 6.5rem; overflow: visible; }
  body.mit-leiste .kopf-leiste { position: static; margin: 0 -1rem 1rem; padding: 8px 1rem; min-height: 0; background: transparent; backdrop-filter: none; border-bottom: 0; }
  .kopf-suche, .kopf-glocke, .krumen, .kopf-rechts .neu-leiste, [data-leiste-schmal] { display: none !important; }
  body.mit-leiste .kopf-leiste:not(:has(.zurueck-knopf:not(.nur-gross))) { display: none; }

  .handy-kopf {
    background: #fff; color: #383e42;      /* Handy: keine Weichzeichner (Canvas-Vorgabe, schont Akku und Tempo) */
    border-bottom: 1px solid var(--linie); box-shadow: 0 6px 20px -12px rgba(90, 40, 40, .18); padding-top: max(.55rem, env(safe-area-inset-top));
  }
  .menue-knopf { color: #3a1e22; display: grid; place-items: center; width: 36px; height: 36px; border-radius: 999px; padding: 0; }
  .menue-knopf:active { background: #f5eeea; }
  .handy-kopf .logo { color: #383e42; padding: 0; }
  .handy-kopf .logo span { color: var(--akzent); }
  .handy-kopf .logo { display: none; }                          /* statt Logo steht der Seitentitel da (wie im Canvas) */
  .handy-titel { display: block; flex: 1; font-weight: 700; font-size: 1.02rem; color: #3a1e22; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; padding-left: .75rem; border-left: 1px solid var(--linie); }
  .handy-chat { margin-left: 0; background: var(--akzent-hell); color: var(--akzent); border-radius: 10px; }

  /* Menü als Schublade von links */
  .seitenleiste { position: fixed; top: 0; bottom: 0; left: 0; margin: 0; height: auto; width: min(300px, 86vw); border-radius: 0 24px 24px 0; border: 0; box-shadow: 0 0 60px rgba(58, 30, 34, .3); }
  html.leiste-schmal .seitenleiste { --leiste-breite: 300px; }
  .menue-schalter:checked ~ .menue-abdunkeln { background: rgba(58, 30, 34, .38); }

  /* Schwebende App-Leiste */
  .app-leiste {
    left: 10px; right: 10px; bottom: calc(10px + env(safe-area-inset-bottom)); padding: .35rem .25rem;
    background: #fff;
    border: 1px solid var(--linie); border-radius: 24px; box-shadow: 0 14px 34px -10px rgba(90, 40, 40, .35);
  }
  .app-leiste a, .app-leiste label { border-radius: 16px; color: #75655f; }
  .app-leiste .aktiv { color: var(--akzent); background: var(--akzent-hell); }

  h1 { font-size: 1.65rem; }
  /* Testlauf 10.11.2026: unten lagen die Meldungen über „Tag einreichen“ – am Handy jetzt oben unter der Kopfleiste */
  .meldungen-stapel { right: 12px; left: 12px; width: auto; top: calc(64px + env(safe-area-inset-top)); bottom: auto; }
}

/* ============================================================================================================
   5. STARTSEITE – bewegter Hintergrund (aus dem Canvas), Karten erscheinen nacheinander
   ============================================================================================================ */
.hg { position: absolute; inset: 0; overflow: hidden; pointer-events: none; z-index: 0; border-radius: inherit; }
.hg i { position: absolute; display: block; }
/* Tempo (09.11.2026): Die Farbflächen sind weiche Verläufe statt weichgezeichneter Kreise (filter: blur kostete die
   Grafikkarte dauernd Rechenzeit). Bewegt wird nur über „transform“ – das verschiebt fertige Bilder, ohne neu zu malen. */
.hg .b1, .hg .b2, .hg .b3 { border-radius: 50%; will-change: transform; }
.hg .b1 { width: 760px; height: 760px; left: -260px; top: -300px; background: radial-gradient(closest-side, rgba(123, 30, 43, .20), rgba(123, 30, 43, 0)); animation: tw-treiben1 22s ease-in-out infinite alternate; }
.hg .b2 { width: 700px; height: 700px; right: -280px; top: 20px; background: radial-gradient(closest-side, rgba(240, 206, 176, .70), rgba(240, 206, 176, 0)); animation: tw-treiben2 26s ease-in-out infinite alternate; }
.hg .b3 { width: 640px; height: 640px; left: 22%; bottom: -320px; background: radial-gradient(closest-side, rgba(232, 163, 173, .45), rgba(232, 163, 173, 0)); animation: tw-treiben3 30s ease-in-out infinite alternate; }
.hg .licht { top: 0; bottom: 0; left: 0; width: 45%; background: linear-gradient(105deg, transparent 20%, rgba(255, 255, 255, .5) 50%, transparent 80%);
  transform: translateX(-120%); will-change: transform; animation: tw-licht 11s ease-in-out infinite; }
@keyframes tw-treiben1 { to { transform: translate(180px, 140px) scale(1.2); } }
@keyframes tw-treiben2 { to { transform: translate(-200px, 90px) scale(.85); } }
@keyframes tw-treiben3 { to { transform: translate(140px, -160px) scale(1.15); } }
@keyframes tw-licht { 0% { transform: translateX(-120%); } 55%, 100% { transform: translateX(260%); } }
main.startseite .kopf-leiste { background: rgba(250, 247, 245, .55); }
/* Tempo (09.11.2026): kurz und fast gleichzeitig – der Inhalt ist sofort lesbar, nur ein Hauch Bewegung */
main.startseite .karte { animation: tw-karte .22s ease-out backwards; }
main.startseite .karte:nth-child(n+3) { animation-delay: .04s; }
@keyframes tw-karte { from { opacity: 0; transform: translateY(6px); } }
/* Handy: keine weichgezeichneten Flächen (schont den Akku) – nur ein ruhiger, sehr langsamer Farbverlauf */
@media (max-width: 900px) {
  /* Handy: ruhiger, stehender Farbverlauf – ohne Bewegung (Akku und Tempo) */
  .hg { position: fixed; border-radius: 0; background: linear-gradient(165deg, rgba(123, 30, 43, .12), rgba(240, 206, 176, .22) 45%, rgba(232, 163, 173, .18)); }
  .hg i { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .hg, .hg i, main.startseite .karte, .meldungen-stapel .meldung, .befehl-fenster[open], .neu-menue { animation: none !important; }
}
@media print {
  body.mit-leiste main { margin: 0; border: 0; box-shadow: none; padding: 0; }
  .kopf-leiste, .hg, .meldungen-stapel, .seitenleiste { display: none !important; }
}

/* --- Hinweis in der Design-Vorschau -------------------------------------------------------------------------- */
/* ============================================================================================================
   6. SEITENINHALTE WIE IM CANVAS (Schritt 3)
   ============================================================================================================ */
/* Seitenkopf: Titel links, Aktionen/Suche rechts auf einer Höhe */
.seitenkopf { align-items: center; gap: 1rem 1.5rem; }
.seitenkopf h1 { margin-bottom: .1rem; }
.seitenkopf > div:first-child { flex: 1 1 22rem; min-width: 0; }
.seitenkopf > div:not(:first-child) { flex: 0 0 auto; }
.filter-reihe input[type=search] { margin-left: auto; }
.filter-reihe .pillen + input[type=hidden] + input[type=search] { margin-left: auto; }

/* Kennzahl-Karten (Startseite „Zu tun“): Bezeichnung klein oben, Zahl groß, Erklärung darunter */
.zu-tun { grid-template-columns: repeat(auto-fill, minmax(13.5rem, 1fr)); gap: 1rem; margin-bottom: 1.2rem; }
.zu-tun-kachel { flex-direction: column; align-items: flex-start; gap: .1rem; padding: 1rem 1.15rem; border-left: 0 !important; }
.zu-tun-titel { font-size: .85rem; font-weight: 600; color: #6b5b55; }
.zu-tun-kachel .zu-tun-zahl { font-size: 1.85rem; font-weight: 800; letter-spacing: -.02em; color: var(--text); text-align: left; min-width: 0; line-height: 1.15; }
.zu-tun-kachel.rot .zu-tun-zahl { color: var(--akzent); }
.zu-tun-kachel.gelb .zu-tun-zahl { color: #a8650b; }
.zu-tun-kachel .leise { font-size: .8rem; }
.zu-tun-kachel:hover { transform: translateY(-2px); }

/* Startseite: Projektsuche rechts neben der Begrüßung (am Handy darunter) */
.seitenkopf .start-suche { margin: 0; flex: 0 1 30rem; display: flex; gap: .5rem; }
.seitenkopf .start-suche input { flex: 1; min-width: 0; }

/* Status-Kacheln (Rechnungen/Angebote) als Kennzahl-Karten */
.beleg-kacheln { gap: 1rem; margin-bottom: 1rem; }
.beleg-kachel { border: 0 !important; border-radius: 18px; padding: .95rem 1.1rem; box-shadow: var(--schatten); background: #fff; }
.beleg-kachel .name { font-size: .85rem; color: #6b5b55; }
.beleg-kachel strong { font-size: 1.5rem; font-weight: 800; letter-spacing: -.02em; }
.beleg-kachel.rot strong { color: var(--akzent); }
.beleg-kachel .anzahl { background: #f5eeea; color: #5f504b; }
.beleg-kachel.aktiv { box-shadow: 0 0 0 2px var(--akzent), var(--schatten); }

/* Filter-Pillen mit Zahl („Alle 10 · Offen 3 …“), Suche rechts daneben */
.filter-reihe { display: flex; align-items: center; justify-content: space-between; gap: .7rem; flex-wrap: wrap; margin-bottom: 1rem; }
.filter-reihe .listenfilter { margin: 0; flex: 0 1 26rem; }
.filter-reihe input[type=search] { min-width: 14rem; }
.pillen { display: flex; gap: .4rem; flex-wrap: wrap; }
.pille { display: inline-flex; align-items: center; gap: .35rem; height: 36px; padding: 0 .95rem; border-radius: 999px; border: 0;
  background: #f5eeea; color: #5f504b; font: inherit; font-size: .9rem; font-weight: 600; cursor: pointer; text-decoration: none !important; }
.pille:hover { background: #efe3de; }
.pille .pille-zahl { font-weight: 500; opacity: .75; }
.pille.aktiv { background: var(--akzent); color: #fff; box-shadow: 0 4px 12px rgba(123, 30, 43, .30); }
.pille.aktiv .pille-zahl { opacity: .85; }
.ampel-aus { display: none !important; }

/* Tabellen: leise Spaltenköpfe in Großbuchstaben, ruhige Zeilen, Zeile hebt sich beim Drüberfahren */
table thead th { font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: #8c7a73; }
table tbody tr:hover > td { background: #fbf7f5; }
.beleg-liste td a strong { color: var(--akzent); letter-spacing: .01em; }

/* Fristen/Ampeln wie im Canvas: Punkt + farbiger Text statt farbiger Pille */
.ampel-punkt { background: none !important; padding: 0; font-size: .85rem; font-weight: 700; border-radius: 0;
  display: inline-flex; align-items: center; gap: .4rem; }
.ampel-punkt::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; flex: none; }
.ampel-punkt.rot { color: #9b2335; }
.ampel-punkt.gelb { color: #a8650b; }
.ampel-punkt.gruen { color: #2e7d4f; }

/* Fällig: Gruppen-Karten mit Zahl rechts, Namen dunkel und fett, darunter leise Nummer · Kunde */
.faellig-gruppe { padding-bottom: .4rem; }
.faellig-gruppe h2 { font-size: 1.05rem; padding-bottom: .6rem; border-bottom: 1px solid #f0e8e4; margin-bottom: .2rem; }
.faellig-gruppe .anzahl { background: #f5eeea; color: #5f504b; font-weight: 700; }
.faellig-gruppe td a strong, .faellig-gruppe td > a { color: var(--text); }
.faellig-gruppe td { padding-top: .7rem; padding-bottom: .7rem; }

/* Filterleisten mit Auswahlfeldern (z. B. Projekte): Felder nur so breit wie nötig, Knopf bleibt in der Reihe */
.filterleiste select { width: auto; flex: 0 1 auto; }
.filterleiste input[type=search] { flex: 1 1 16rem; }

@media (max-width: 900px) {
  .seitenkopf > div:not(:first-child) { flex: 1 1 100%; flex-wrap: wrap; }
  .beleg-kachel strong { font-size: 1.15rem; white-space: nowrap; }
  .beleg-kacheln { gap: .6rem; }
  .seitenkopf .start-suche { flex-basis: 100%; }
  .filter-reihe .listenfilter, .filter-reihe input[type=search] { flex-basis: 100%; min-width: 0; max-width: none !important; }
  .zu-tun { grid-template-columns: 1fr 1fr; gap: .6rem; }
}

/* ============================================================================================================
   7. DATENTABELLE (Schritt 4) – kern/static/kern/datentabelle.js
   ============================================================================================================ */
.dt-leiste { display: flex; justify-content: space-between; align-items: center; gap: .6rem; margin: 0 0 .5rem; min-height: 32px; }
.dt-links, .dt-rechts { display: flex; align-items: center; gap: .5rem; }
.dt-auswahl { font-weight: 700; color: var(--akzent) !important; }
.dt-spalten { position: relative; }
.dt-spalten > summary { list-style: none; }
.dt-spalten > summary::-webkit-details-marker { display: none; }
.dt-spalten-liste { position: absolute; right: 0; top: calc(100% + 6px); z-index: 30; min-width: 13rem; display: grid; gap: .15rem; padding: .5rem .6rem !important; }
.dt-spalten-liste label { display: flex; align-items: center; gap: .45rem; padding: .3rem .35rem; border-radius: 8px; cursor: pointer; font-size: .9rem; }
.dt-spalten-liste label:hover { background: #fbf7f5; }
th.dt-haken, td.dt-haken { width: 2.2rem; padding-left: .7rem !important; padding-right: 0 !important; }
.dt-haken input { width: 16px; height: 16px; accent-color: var(--akzent); cursor: pointer; }
tr.dt-gewaehlt > td { background: #f9eef0 !important; }
tr.dt-aus { display: none; }
th.dt-sortierbar { cursor: pointer; user-select: none; white-space: nowrap; }
th.dt-sortierbar:hover { color: var(--akzent); }
th.dt-sortierbar::after { content: "↕"; opacity: .25; margin-left: .3rem; font-size: .9em; }
th[data-sortiert="auf"]::after { content: "↑"; opacity: 1; color: var(--akzent); }
th[data-sortiert="ab"]::after { content: "↓"; opacity: 1; color: var(--akzent); }
.dt-blaettern { padding: .8rem 1rem; }
@media (max-width: 900px) { .dt-leiste, .dt-haken { display: none !important; } }

/* ============================================================================================================
   8. SEITENFENSTER („Sheet“) UND „RÜCKGÄNGIG“ (Schritt 5) – kern/static/kern/sheet.js, kern/rueckgaengig.py
   ============================================================================================================ */
.sheet { position: fixed; inset: 0 0 0 auto; margin: 0; height: 100vh; max-height: none; width: min(46rem, 92vw); max-width: none;
  border: 0; border-radius: 22px 0 0 22px; padding: 0; background: var(--hintergrund); box-shadow: -20px 0 60px rgba(58, 30, 34, .25);
  flex-direction: column; }
.sheet[open] { display: flex; animation: sheet-rein .2s ease-out; }
.sheet::backdrop { background: rgba(58, 30, 34, .32); }
@keyframes sheet-rein { from { transform: translateX(40px); opacity: 0; } }
.sheet-kopf { display: flex; align-items: center; gap: .6rem; padding: .9rem 1rem .9rem 1.4rem; background: #fff; border-bottom: 1px solid #f0e8e4; }
.sheet-kopf strong { flex: 1; font-size: 1.05rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sheet-zu { border: 0; background: #f5eeea; width: 34px; height: 34px; border-radius: 50%; font-size: 1.3rem; line-height: 1; cursor: pointer; color: #5f504b; }
.sheet-inhalt { flex: 1; overflow-y: auto; padding: 1.2rem 1.4rem 2rem; }
.sheet-inhalt h1 { font-size: 1.5rem; }
.sheet-inhalt .seitenkopf > div:not(:first-child) { display: none; }   /* große Aktionsknöpfe der Seite nicht doppelt */
.sheet-laedt { display: flex; gap: .4rem; justify-content: center; padding: 3rem 0; }
.sheet-laedt span { width: 9px; height: 9px; border-radius: 50%; background: var(--akzent); opacity: .3; animation: sheet-punkt 1s infinite; }
.sheet-laedt span:nth-child(2) { animation-delay: .15s; } .sheet-laedt span:nth-child(3) { animation-delay: .3s; }
@keyframes sheet-punkt { 50% { opacity: 1; transform: translateY(-3px); } }
.sheet-auge { display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; color: #8c7a73; margin-left: .3rem;
  vertical-align: middle; opacity: 0; transition: opacity .15s, background-color .15s; }
tr:hover .sheet-auge, .sheet-auge:focus { opacity: 1; }
.sheet-auge:hover { background: var(--akzent-hell); color: var(--akzent); }
.meldung-rueckgaengig { display: inline; margin-left: .5rem; }
.meldung-rueckgaengig .knopf { vertical-align: middle; }
@media (max-width: 900px) {
  .sheet { inset: auto 0 0 0; width: 100vw; height: 88vh; border-radius: 22px 22px 0 0; }
  @keyframes sheet-rein { from { transform: translateY(40px); opacity: 0; } }
  .sheet-auge { opacity: 1; }
}

/* ============================================================================================================
   9. HANDY-FEINSCHLIFF (Schritt 6) – Akkordeon (kern/static/kern/akkordeon.js) und große Tippflächen
   Alles hier gilt nur am Handy (bis 700 px). Am Rechner ändert sich nichts.
   ============================================================================================================ */
.klapp-nur-handy { display: none; }
@media (max-width: 700px) {
  /* --- Akkordeon: Karten mit data-klapp zeigen zugeklappt nur ihren Kopf --- */
  .klapp-bereit > .klapp-kopf { cursor: pointer; display: flex; align-items: center; flex-wrap: nowrap !important; gap: .5rem;
    min-height: 44px; -webkit-tap-highlight-color: transparent; }
  .klapp-kopf > h2, .klapp-kopf > h3 { min-width: 0; }
  h2.klapp-kopf, h3.klapp-kopf { margin-top: 0; margin-bottom: 0; }
  .klapp-bereit:not(.klapp-zu) > .klapp-kopf { margin-bottom: .6rem; }
  .klapp-bereit.klapp-zu > :not(.klapp-kopf) { display: none !important; }
  .klapp-bereit.klapp-zu { padding-top: .55rem; padding-bottom: .55rem; }
  .klapp-ende { margin-left: auto; display: inline-flex; align-items: center; gap: .4rem; flex: none; }
  .klapp-zahl { display: none; min-width: 1.6rem; height: 1.6rem; padding: 0 .45rem; border-radius: 999px; background: var(--akzent-hell);
    color: var(--akzent); font-size: .8rem; font-weight: 700; align-items: center; justify-content: center; }
  .klapp-zu .klapp-zahl { display: inline-flex; }
  .klapp-pfeil { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: #f5eeea; color: #5f504b;
    transition: transform .2s ease; }
  .klapp-bereit:not(.klapp-zu) .klapp-pfeil { transform: rotate(180deg); }
  .klapp-bereit > .klapp-nur-handy { display: flex; font-size: 1rem; color: var(--text); flex: 1 1 100%; }
  .klapp-kopf > .knopf, .klapp-kopf > a, .klapp-kopf > form { flex: none; }

  /* --- Große Tippflächen: mindestens 44 px hoch (Apple/Google-Empfehlung, auch mit Handschuhen) --- */
  .knopf, button.knopf, summary.knopf { min-height: 44px; display: inline-flex; align-items: center; justify-content: center; }
  .knopf.klein, .knopf.mini, .pille, .zurueck-knopf { min-height: 38px; }
  .stempel-chip { min-height: 44px; }
  input:not([type=checkbox]):not([type=radio]):not([type=hidden]), select { min-height: 44px; }
  input[type=checkbox], input[type=radio] { width: 22px; height: 22px; }
  /* Kleine Symbole behalten ihr Aussehen, bekommen aber eine unsichtbar größere Tippfläche */
  .knopf.klein, .knopf.mini, .pille, .zurueck-knopf, .er-kreis, .er-flagge, .app-tipp-weg, .sheet-auge, .sheet-zu { position: relative; }
  .knopf.klein::after, .knopf.mini::after, .pille::after, .zurueck-knopf::after { content: ""; position: absolute; inset: -4px -2px; }
  .er-kreis::after, .er-flagge::after, .app-tipp-weg::after, .sheet-auge::after, .sheet-zu::after { content: ""; position: absolute; inset: -10px; }
  .er-kreis { width: 1.55rem; height: 1.55rem; }

  /* --- Erinnerungen: die sieben Kacheln als wischbare Reihe statt eines ganzen Bildschirms --- */
  .er-kacheln { display: flex; overflow-x: auto; gap: .45rem; margin: 0; padding: 2px 2px 6px; scroll-snap-type: x proximity;
    scrollbar-width: none; }
  .er-kacheln::-webkit-scrollbar { display: none; }
  .er-kachel { flex: none; scroll-snap-align: start; grid-template-columns: auto auto auto; grid-template-rows: auto; align-items: center;
    gap: .4rem; padding: .35rem .8rem .35rem .4rem; min-height: 44px; border-radius: 999px; border-left-width: 1px; }
  .er-kachel .er-symbol { width: 1.7rem; height: 1.7rem; border-radius: 50%; }
  .er-kachel-name { grid-column: 2; grid-row: 1; font-size: .88rem; color: var(--text); white-space: nowrap; }
  .er-kachel-zahl { grid-column: 3; grid-row: 1; font-size: .95rem; color: var(--text-leise); }
  .er-kachel.aktiv .er-kachel-name { color: var(--akzent); }
  .er-raster { grid-template-columns: minmax(0, 1fr); }
  .er-seite { gap: .6rem; min-width: 0; }
}

/* ============================================================================================================
   10. DUNKLER MODUS (Schritt 7) – Handarbeit
   Das meiste rechnet kern/dunkelmodus.py automatisch in kern/static/kern/dunkel.css um (python manage.py dunkel_erzeugen).
   Hier steht nur, was ein Mensch festlegen muss: die Grundfarben und der Bordeaux-Ton. Eingeschaltet wird der Modus
   über die Klasse „dunkel“ an <html> (Schalter „Darstellung“ im Benutzermenü, gemerkt im Browser).
   ============================================================================================================ */
html.dunkel {
  color-scheme: dark;                /* Bildlaufleisten, Datumsfelder usw. vom Browser ebenfalls dunkel */
  --hintergrund: #171312;            /* warmes Fast-Schwarz */
  --rahmen-grund: #120e0d;
  --karte: #211b1a;
  --linie: #3a302d;
  --feldrand: #4a3e3a;
  --zeile-hover: #2a2321;
  --text: #f1e9e6;
  --text-leise: #b6a7a1;             /* Kontrast auf Karte 7:1 */
  --ueberschrift: #f8eceb;
  --leise-warm: #a8968f;
  --akzent: #c44456;                 /* Bordeaux, aufgehellt: weiße Schrift darauf 4,8:1, als Schrift auf Dunkel 3,9:1 */
  --akzent-dunkel: #b03b4c;
  --akzent-hell: #3a2125;            /* zarter Bordeaux-Grund im Dunklen */
  --akzent-auf-dunkel: #e8a3ad;
  --gruen: #5cbf80;
  --gelb: #e0a243;
  --rot: #ef7a6c;
  --anthrazit: #2b2422;
  --ring: 0 0 0 3px rgba(224, 122, 137, .32);
  --schatten: 0 1px 2px rgba(0, 0, 0, .35), 0 6px 18px rgba(0, 0, 0, .28);
  --schatten-hoch: 0 2px 6px rgba(0, 0, 0, .4), 0 18px 40px rgba(0, 0, 0, .5);
  --schatten-knopf: inset 0 1px 0 rgba(255, 255, 255, .10), 0 4px 14px rgba(201, 74, 91, .28);
}
/* Fließtext-Links etwas heller als Knöpfe, damit sie auf Dunkel gut lesbar sind */
html.dunkel main a:not([class]), html.dunkel .leise a:not([class]) { color: #e58c99; }
html.dunkel ::selection { background: #6b2733; color: #fff; }
/* Bilder und Firmenzeichen nicht grell: minimal abgedunkelt wäre ein Filter – darum bewusst unverändert (Tempo-Regel) */

/* Schalter „Darstellung“ im Benutzermenü */
.thema-wahl { display: flex; align-items: center; gap: .25rem; padding: .25rem; border-radius: 999px; background: #f5eeea; margin: .2rem 0 .4rem; }
.thema-wahl button { flex: 1; border: 0; background: none; border-radius: 999px; padding: .35rem .5rem; font: inherit; font-size: .8rem;
  font-weight: 600; color: var(--text-leise); cursor: pointer; }
.thema-wahl button[aria-pressed="true"] { background: #fff; color: var(--akzent); box-shadow: 0 1px 3px rgba(90, 40, 40, .12); }

/* ============================================================================================================
   11. ANMELDESEITE (Entwurf 10.11.2026) – kern/templates/kern/anmelden.html
   Markenfläche immer schwarz (wie der Startbildschirm), Formular hell bzw. im dunklen Modus dunkel.
   ============================================================================================================ */
main.anmelde-seite { max-width: none; padding: 0; min-height: 100vh; min-height: 100dvh; display: flex; }
.an-buehne { flex: 1; display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(380px, 1fr); min-height: 100vh; min-height: 100dvh; }
.an-marke { position: relative; overflow: hidden; background: #120e0d; color: #f6ece9; display: flex; flex-direction: column;
  justify-content: space-between; padding: 2.6rem 3rem; isolation: isolate; }
.an-marke::before { content: ""; position: absolute; inset: -20%; z-index: -1;
  background: radial-gradient(40% 35% at 78% 22%, rgba(196, 68, 86, .38), transparent 70%),
              radial-gradient(45% 40% at 12% 88%, rgba(123, 30, 43, .45), transparent 70%); }
.an-zinken { position: absolute; z-index: -1; width: min(70%, 640px); right: -6%; bottom: 8%; color: #f6ece9; opacity: .09;
  transform: rotate(-8deg); }
.an-licht { opacity: 1; pointer-events: none; }      /* Easter Egg „Taschenlampe“ (11.11.2026) – nur der Lichtkegel ist sichtbar */
.an-wortmarke, .an-handy-marke { font-weight: 800; letter-spacing: .32em; font-size: 1.5rem; color: #fff; }
/* Jeton 11.11.2026: helles Bordeaux der dunklen Logo-Fassung statt Pink */
.an-wortmarke span, .an-handy-marke span { color: #e58c99; }
.an-mitte { max-width: 34rem; }
.an-klein { text-transform: uppercase; letter-spacing: .18em; font-size: .72rem; font-weight: 700; color: #c9a9a3; margin-bottom: .8rem; }
.an-klein::before { content: ""; display: inline-block; width: 26px; height: 2px; background: #e58c99; vertical-align: middle; margin-right: .6rem; }
.an-spruch { margin: 0; font-size: clamp(2rem, 3.6vw, 3.4rem); line-height: 1.08; font-weight: 800; letter-spacing: -.03em; color: #fff;
  animation: an-rein .5s ease-out both; }
@keyframes an-rein { from { opacity: 0; transform: translateY(12px); } }
.an-fuss { display: flex; justify-content: space-between; align-items: flex-end; gap: 1rem; flex-wrap: wrap; }
.an-uhr strong { display: block; font-size: 2.6rem; font-weight: 300; letter-spacing: -.02em; color: #fff; font-variant-numeric: tabular-nums; line-height: 1; }
.an-uhr span { font-size: .85rem; color: #c9a9a3; }
.an-firmen { font-size: .8rem; color: #a8908a; letter-spacing: .04em; }
.an-punkt { margin: 0 .5rem; color: #e58c99; }

.an-formular { display: flex; align-items: center; justify-content: center; padding: 2.5rem; background: var(--hintergrund); }
.an-formular-innen { width: 100%; max-width: 400px; }
.an-handy-marke { display: none; }
.an-gruss { font-size: 2.1rem; margin: 0 0 .3rem; letter-spacing: -.03em; }
.an-unter { color: var(--text-leise); margin: 0 0 1.8rem; }
.an-fehler { margin-bottom: 1rem; }
.an-form { display: grid; gap: 1.05rem; }
.an-feld label { display: block; font-size: .85rem; font-weight: 600; margin-bottom: .35rem; color: var(--text); }
.an-feld input { width: 100%; height: 52px; font-size: 1.05rem; padding: 0 1rem; border-radius: 14px; background: var(--karte); }
.an-passwort { position: relative; }
.an-passwort input { padding-right: 3.2rem; }
.an-auge { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); width: 40px; height: 40px; border: 0; border-radius: 10px;
  background: none; color: var(--text-leise); cursor: pointer; display: grid; place-items: center; }
.an-auge:hover, .an-auge[aria-pressed="true"] { color: var(--akzent); background: var(--akzent-hell); }
.an-hinweis { font-size: .8rem; color: var(--gelb); font-weight: 600; margin-top: .35rem; }
.an-wieder { display: flex; align-items: center; gap: .75rem; padding: .6rem .7rem; border: 1px solid var(--linie); border-radius: 16px; background: var(--karte); }
.an-wieder[hidden] { display: none; }
.an-avatar { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: var(--akzent); color: #fff; font-weight: 800; font-size: .9rem; }
.an-wieder-text { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.an-wieder-text small { color: var(--text-leise); font-size: .75rem; }
.an-wieder-text strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.an-nicht-du { border: 0; background: none; color: var(--akzent); font: inherit; font-size: .85rem; font-weight: 600; cursor: pointer; padding: .5rem; }
.an-schalter { display: flex; align-items: center; gap: .75rem; cursor: pointer; font-weight: 600; font-size: .92rem; }
.an-schalter small { display: block; font-weight: 400; color: var(--text-leise); font-size: .78rem; }
.an-schalter input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.an-schalter-bahn { flex: none; width: 46px; height: 28px; border-radius: 999px; background: var(--feldrand); position: relative; transition: background-color .15s; }
.an-schalter-bahn::after { content: ""; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, .25); transition: transform .18s ease; }
.an-schalter input:checked + .an-schalter-bahn { background: var(--akzent); }
.an-schalter input:checked + .an-schalter-bahn::after { transform: translateX(18px); }
.an-schalter input:focus-visible + .an-schalter-bahn { box-shadow: var(--ring); }
.an-los { margin-top: .4rem; height: 56px; border: 0; border-radius: 999px; background: var(--akzent); color: #fff; font: inherit; font-size: 1.08rem;
  font-weight: 700; cursor: pointer; display: flex; align-items: center; justify-content: center; gap: .6rem; box-shadow: var(--schatten-knopf);
  transition: transform .12s ease; }
.an-los:hover .an-pfeil { transform: translateX(4px); }
.an-los:active { transform: scale(.98); }
.an-pfeil { transition: transform .15s ease; }
.an-los.laeuft { opacity: .8; pointer-events: none; }
.an-hilfe { margin-top: 1.4rem; font-size: .82rem; color: var(--text-leise); text-align: center; }

@media (max-width: 900px) {
  .an-buehne { grid-template-columns: 1fr; grid-template-rows: auto 1fr; }
  .an-marke { padding: 1.4rem 1.4rem 3.4rem; min-height: 36vh; }
  .an-wortmarke { font-size: 1.15rem; }
  .an-spruch { font-size: 1.85rem; animation: none; }
  .an-uhr strong { font-size: 1.7rem; }
  .an-firmen { display: none; }
  .an-zinken { width: 90%; right: -25%; bottom: -10%; }
  .an-formular { align-items: flex-start; margin-top: -1.6rem; border-radius: 26px 26px 0 0; padding: 1.8rem 1.25rem 2rem; position: relative; }
  .an-gruss { font-size: 1.7rem; }
  .an-unter { margin-bottom: 1.3rem; }
}
@media (prefers-reduced-motion: reduce) { .an-spruch { animation: none; } }

.vorschau-hinweis {
  position: fixed; left: 50%; bottom: 14px; transform: translateX(-50%); z-index: 9999;
  background: #3a1e22; color: #fff; font-size: .78rem; font-weight: 600; padding: .35rem .9rem;
  border-radius: 999px; box-shadow: var(--schatten-hoch); pointer-events: none; white-space: nowrap;
}
@media (max-width: 700px) { .vorschau-hinweis { bottom: 78px; font-size: .72rem; } .vorschau-lang { display: none; } }

/* ============================================================================================================
   12. STEMPELUHR – Variante B „Tagesring“ (Jeton, 10.11.2026)
   Handy: alles untereinander. PC (ab 900 px): links die Jetzt-Karte (380 px), rechts Tätigkeit, Heute, Woche.
   Nur Farben über Variablen – so passt es auch im dunklen Modus. Keine Unschärfe-Effekte (Tempo-Regel).
   ============================================================================================================ */
.su { max-width: 1120px; margin: 0 auto; display: grid; gap: 1rem; }
.su-oben { display: grid; gap: .75rem; }
.su-oben:empty { display: none; }
.su-oben .einreichen-hinweis { margin: 0; }
.su-raster { display: grid; gap: 1rem; align-items: start; }
.su-spalte { display: grid; gap: 1rem; min-width: 0; }
@media (min-width: 900px) { .su-raster { grid-template-columns: 380px minmax(0, 1fr); } }

.su-gesperrt { font-size: .7rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--text-leise); }
.su-projekt { font-weight: 700; font-size: 1.05rem; line-height: 1.3; margin-top: .2rem; color: var(--text); }
.su-unter { font-size: .85rem; margin-top: .1rem; }
.su-klein { font-size: .78rem; }
.su-zeile { display: flex; justify-content: space-between; align-items: baseline; gap: .6rem; }
.su-zeile h2 { margin: 0; font-size: 1.02rem; }
.su-karte-klein { padding: 1.1rem 1.2rem; }

.su-jetzt { padding: 1.2rem 1.25rem 1.1rem; }
.su-kopf { display: flex; justify-content: space-between; align-items: flex-start; gap: .75rem; }
.su-pille { display: inline-flex; align-items: center; gap: .35rem; flex: none; border-radius: 999px; padding: .25rem .65rem;
  font-size: .76rem; font-weight: 700; white-space: nowrap; }
.su-pille.klein { padding: .1rem .5rem; font-size: .7rem; margin-left: .3rem; vertical-align: middle; }
.su-pille.gruen { color: var(--gruen); background: color-mix(in srgb, var(--gruen) 13%, transparent); }
.su-pille.gelb { color: var(--gelb); background: color-mix(in srgb, var(--gelb) 15%, transparent); }
.su-punkt { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }

/* Ring: --anteil (0–100) = Anteil am Tagessoll. Umfang bei r=100: 628 */
.su-ring { position: relative; width: min(230px, 70vw); aspect-ratio: 1; margin: 1rem auto .4rem; }
.su-ring svg { width: 100%; height: 100%; transform: rotate(-90deg); display: block; }
.su-ring circle { fill: none; stroke-width: 16; }
.su-ring-grund { stroke: color-mix(in srgb, var(--linie) 70%, var(--hintergrund)); }
.su-ring-wert { stroke: var(--akzent); stroke-linecap: round; stroke-dasharray: 628;
  stroke-dashoffset: calc(6.28px * (100 - var(--anteil, 0))); transition: stroke-dashoffset .4s ease; }
.su-ring[style*="--anteil:0;"] .su-ring-wert, .su-ring[style="--anteil:0"] .su-ring-wert { stroke: transparent; }
.su-ring-mitte { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.su-ring-mitte b { font-size: 2.9rem; font-weight: 800; line-height: 1.05; font-variant-numeric: tabular-nums; color: var(--text); }
.su-ring-mitte .leise { font-size: .8rem; }

.su-knoepfe { display: grid; grid-template-columns: 1fr 1fr; gap: .6rem; margin-top: .9rem; }
.knopf.su-gross { justify-content: center; font-size: 1.05rem; padding: 1rem .8rem; border-radius: 14px; min-height: 56px; }
.knopf.su-hell { background: var(--karte); color: var(--text); border: 1.5px solid var(--linie); box-shadow: none; }
.knopf.su-hell:hover { border-color: var(--akzent); color: var(--akzent); background: var(--karte); }
.knopf.su-einstempeln { width: 100%; margin-top: .9rem; font-size: 1.2rem; min-height: 60px; }
.su-fuss { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .3rem .8rem; margin-top: .9rem; }
.su-fuss form { margin: 0; }
.su-link { background: none; border: 0; padding: .3rem 0; font: inherit; font-size: .86rem; font-weight: 600; color: var(--text-leise);
  cursor: pointer; text-decoration: none; }
.su-link.akzent { color: var(--akzent); }
.su-link:hover { color: var(--akzent); text-decoration: underline; }

.su-geplant { display: grid; gap: .15rem; border-left: 4px solid var(--akzent); }
.su-geplant .stempel-leiste.inline { border: 0; padding: .6rem 0 0; background: none; }

/* Tagesleiste: Abschnitte absolut nach Uhrzeit */
.su-leiste { position: relative; height: 12px; border-radius: 999px; overflow: hidden; margin: .8rem 0 .4rem;
  background: color-mix(in srgb, var(--linie) 70%, var(--hintergrund)); }
.su-leiste i { position: absolute; top: 0; bottom: 0; }
.su-leiste .arbeit, .su-legende .arbeit { background: var(--akzent); }
.su-leiste .fahrt, .su-legende .fahrt { background: color-mix(in srgb, var(--akzent) 45%, var(--karte)); }
.su-leiste .pause, .su-legende .pause { background: color-mix(in srgb, var(--text-leise) 35%, var(--karte)); }
.su-legende { display: inline-flex; align-items: center; gap: .3rem; flex-wrap: wrap; justify-content: center; }
.su-legende i { display: inline-block; width: 9px; height: 9px; border-radius: 3px; margin-left: .4rem; }

.su-liste { display: grid; margin-top: .4rem; }
.su-liste > div { display: grid; grid-template-columns: 6.6rem 2.8rem minmax(0, 1fr); gap: .6rem; align-items: baseline;
  padding: .55rem 0; border-top: 1px solid var(--linie); font-size: .9rem; }
.su-liste > div:first-child { border-top: 0; }
.su-liste .zeit { font-variant-numeric: tabular-nums; }
.su-liste .dauer { font-weight: 700; text-align: right; font-variant-numeric: tabular-nums; }
.su-liste .was { min-width: 0; }
.su-liste .laeuft .was { font-weight: 700; }

.su-balken { height: 8px; border-radius: 999px; overflow: hidden; margin-top: .7rem;
  background: color-mix(in srgb, var(--linie) 70%, var(--hintergrund)); }
.su-balken i { display: block; height: 100%; border-radius: 999px; background: var(--akzent); }

.su .stempel-links a { border-radius: 14px; }
.su .stempel-chip { background: var(--karte); }
.su .stempel-chip.aktiv { background: var(--akzent-hell); color: var(--akzent); border-color: var(--akzent); }

/* Projektwahl: Einträge nicht wie alte Links unterstreichen (Testlauf 10.11.2026) */
.projektwahl-eintrag, .projektwahl-eintrag:hover, .projektwahl-eintrag:focus { text-decoration: none; }

@media (max-width: 420px) {
  .su-liste > div { grid-template-columns: 5.9rem 2.6rem minmax(0, 1fr); gap: .45rem; font-size: .86rem; }
  .su-ring-mitte b { font-size: 2.6rem; }
}
.su-mehr { margin-top: .7rem; }
.su-mehr summary { cursor: pointer; font-size: .86rem; font-weight: 600; color: var(--akzent); list-style: none; }
.su-mehr summary::-webkit-details-marker { display: none; }
.su-mehr summary::before { content: "＋ "; }
.su-mehr[open] summary::before { content: "－ "; }
.su-mehr .stempel-chips { margin-top: .6rem; }

/* =====================================================================
   VERTRIEB – Wochen-Vorschau nach Zuschlagschance (Jeton, 10.11.2026)
   ===================================================================== */
.kw-legende { display: flex; gap: 1rem; flex-wrap: wrap; margin: .6rem 0 .4rem; font-size: .82rem; color: var(--text-leise); }
.kw-legende span { display: inline-flex; align-items: center; gap: .35rem; }
.kw-legende i { width: .8rem; height: .8rem; border-radius: 3px; display: inline-block; }
.kw-beauftragt { background: #3a3433; }
.kw-hoch { background: var(--akzent); }
.kw-mittel { background: #c4661f; }
.kw-niedrig { background: #e3b48f; }
.kw-ohne { background: repeating-linear-gradient(135deg, #c9b8b1 0 4px, #efe6e2 4px 8px); }
.kw-tabelle th, .kw-tabelle td { padding: .3rem .55rem; white-space: nowrap; }
.kw-tabelle tbody th { font-weight: 700; text-align: left; }
.kw-tabelle tr.leer td, .kw-tabelle tr.leer th { color: var(--text-leise); }
.kw-balken-spalte { width: 34%; min-width: 160px; }
.kw-balken { display: flex; height: .9rem; border-radius: 4px; overflow: hidden; background: color-mix(in srgb, var(--linie) 45%, transparent); }
.kw-balken i { display: block; height: 100%; }
@media (max-width: 700px) { .kw-balken-spalte { display: none; } }
