/* ==========================================================================
   Diakonie-HJU – Bootstrap-Theme (Bootstrap 5.3.8, lokal)
   Farben nach Diakonie-Vorgabe:
     Cyan    #1a9dd9  große Überschriften, Flächen, Linien, Hauptbutton
     Violett #5a2574  kleine farbige Schrift, Links, Umrandungs-Buttons, Etiketten
     Violett dunkel #43195a  Hover/aktiv von violetten Elementen
     Grau    #3a3f44  Fließtext, Datum, Nebenangaben (einziges Grau)
     Grün    #267a4d  Erfolg, „freigegeben“
     Hellblau #eef6fb Seitenköpfe, Begrüßung, Flächen
     Orange #f39a3d · Gelb #ffd94d · Hellgelb #fff6d1  Status
   Wird NACH dem seiteneigenen <style> geladen.
   ========================================================================== */

/* ---------- Bootstrap-Variablen ---------- */
:root,[data-bs-theme=light]{
  --bs-primary:#1a9dd9; --bs-primary-rgb:26,157,217;
  --bs-secondary:#5a2574; --bs-secondary-rgb:90,37,116;
  --bs-success:#267a4d; --bs-success-rgb:38,122,77;
  --bs-info:#1a9dd9; --bs-info-rgb:26,157,217;
  --bs-warning:#ffd94d; --bs-warning-rgb:255,217,77;
  --bs-danger:#b42318; --bs-danger-rgb:180,35,24;
  --bs-primary-bg-subtle:#eef6fb; --bs-primary-border-subtle:#a9d8ef; --bs-primary-text-emphasis:#0f6a94;
  --bs-secondary-bg-subtle:#f1eaf5; --bs-secondary-text-emphasis:#43195a;
  --bs-body-font-family:"Carlito","Calibri",system-ui,-apple-system,"Segoe UI",sans-serif;
  --bs-body-font-size:.9375rem; --bs-body-line-height:1.5;
  --bs-body-color:#3a3f44; --bs-body-color-rgb:58,63,68; --bs-body-bg:#ffffff;
  --bs-secondary-color:#3a3f44; --bs-emphasis-color:#3a3f44;
  --bs-heading-color:#1a9dd9;
  --bs-link-color:#5a2574; --bs-link-color-rgb:90,37,116; --bs-link-hover-color:#43195a; --bs-link-hover-color-rgb:67,25,90;
  --bs-border-color:#cfe6f3; --bs-border-radius:.375rem; --bs-border-radius-lg:.5rem;
  --bs-focus-ring-color:rgba(26,157,217,.25);
  color-scheme:light;
}
.btn-primary{--bs-btn-bg:#1a9dd9;--bs-btn-border-color:#1a9dd9;--bs-btn-color:#fff;--bs-btn-hover-bg:#1583b6;--bs-btn-hover-border-color:#1583b6;--bs-btn-hover-color:#fff;--bs-btn-active-bg:#126f9b;--bs-btn-active-border-color:#126f9b;--bs-btn-disabled-bg:#1a9dd9;--bs-btn-disabled-border-color:#1a9dd9;--bs-btn-font-weight:700}
.btn-outline-primary,.btn-outline-secondary{--bs-btn-color:#5a2574;--bs-btn-border-color:#5a2574;--bs-btn-hover-bg:#43195a;--bs-btn-hover-border-color:#43195a;--bs-btn-hover-color:#fff;--bs-btn-active-bg:#43195a;--bs-btn-active-border-color:#43195a;--bs-btn-active-color:#fff;--bs-btn-font-weight:600}
.btn-success{--bs-btn-bg:#267a4d;--bs-btn-border-color:#267a4d;--bs-btn-hover-bg:#1e623e;--bs-btn-hover-border-color:#1e623e}

/* ---------- Farb-Tokens der Anwendung (immer hell, Diakonie-Farben) ---------- */
html:root:not([data-theme="__"]),html:root[data-theme]{
  --bg:#ffffff; --surface:#ffffff; --fg:#3a3f44; --muted:#3a3f44; --line:#cfe6f3;
  --accent:#1a9dd9; --accent-fg:#ffffff; --accent-soft:#eef6fb; --accent-hover:#1583b6;
  --violett:#5a2574; --violett-dunkel:#43195a; --violett-soft:#f1eaf5;
  --bad:#b42318; --bad-soft:#fde7e4;
  --warn:#9a5410; --warn-soft:#fff6d1;
  --ok:#267a4d; --ok-soft:#e4f2ea;
  --zero:#ffd94d; --zero-soft:#fff6d1; --zero-fg:#3a3f44;
  --anw-soft:#eef6fb; --weekend:#f4f8fb; --hol:#fde7e4;
  --font-body:"Carlito","Calibri",system-ui,-apple-system,"Segoe UI",sans-serif;
  --font-mono:"Carlito","Calibri",system-ui,sans-serif;
  color-scheme:light;
}

/* ---------- Grundlayout (bewusst hohe Spezifität: gilt vor den seiteneigenen Regeln) ---------- */
html body{background:var(--bg);color:var(--fg)}
html body h1,html body h2,html body h3{font-weight:700}
html body h1{color:#1a9dd9}
html body legend{float:none;width:auto;font-size:inherit;line-height:inherit;margin:0;padding:0 4px}
html body p{margin-bottom:0}
html body svg.logo{color:#1a9dd9}

/* Seitenkopf: Hellblau, ohne Trennlinie */
html body .wrap>header{background:#eef6fb;border-radius:var(--bs-border-radius-lg);padding:20px 24px}
html body .wrap>header p{color:#3a3f44}

/* Abschnittsüberschriften in Bereichen: kleine violette Schrift */
html body .panel h2,html body .panel>summary h2,html body .sec{color:#5a2574}
html body .panel{border-color:var(--line);box-shadow:0 .125rem .25rem rgba(26,157,217,.06)}

/* Meldungen unten rechts */
html body .hju-toast.ok{background:#267a4d;color:#fff}
html body .hju-toast.warn{background:#f39a3d;color:#3a3f44}
html body .hju-toast{box-shadow:0 .5rem 1rem rgba(0,0,0,.15)}

/* Dialoge (Bootstrap-Modal-Optik) */
html body dialog{border:0;border-radius:var(--bs-border-radius-lg);box-shadow:0 .5rem 1.5rem rgba(0,0,0,.2)}
html body dialog::backdrop{background:rgba(58,63,68,.5)}

/* Anmeldung */
html body .gate{background:#eef6fb}
html body .gatebox{border-color:var(--line);box-shadow:0 .5rem 1rem rgba(26,157,217,.08)}
html body .gatebox h2{color:#1a9dd9}
html body .gatebox input{background:#fff;border-color:#c3dced;border-radius:var(--bs-border-radius)}
html body .gatebox input:focus{outline:none;border-color:#8dceec;box-shadow:0 0 0 .25rem rgba(26,157,217,.25)}
html body .gatebox button{background:#1a9dd9;border-color:#1a9dd9;color:#fff;font-weight:700;border-radius:var(--bs-border-radius)}
html body .gatebox button:not(:disabled):hover,html body .gatebox button:not(:disabled):focus-visible{background:#1583b6;border-color:#1583b6;color:#fff}

/* Startseite: Kacheln wie Bootstrap-Karten */
html body .tile{border-color:var(--line);border-radius:var(--bs-border-radius-lg)}
html body a.tile:hover,html body a.tile:focus-visible{border-color:#1a9dd9;box-shadow:0 .5rem 1rem rgba(26,157,217,.12)}
html body .tile b{color:#1a9dd9}
html body .tile .go{background:#1a9dd9;color:#fff;font-weight:700;border-radius:var(--bs-border-radius)}
html body .tile.admin{background:#f1eaf5;border-color:#d9c3e4}
html body .tile.admin b{color:#5a2574}
html body .tile.admin span{color:#3a3f44}
html body .tile.admin .go{background:#5a2574}
html body a.tile.admin:hover{border-color:#5a2574}
html body .tile.soon b{color:#3a3f44}
html body .tile.ungenutzt{background:#eceeef;border-color:#d3d7da}
html body .tile.ungenutzt b{color:#3a3f44}
html body .tile.ungenutzt .go{background:#6c7378}
html body .out{color:#5a2574;border-color:#5a2574;border-radius:var(--bs-border-radius)}
html body .out:hover,html body .out:focus-visible{background:#43195a;border-color:#43195a;color:#fff}
html body .hju-alert.rot{background:#fde7e4;color:#b42318}

/* ---------- Fallback für Seiten ohne eigene Grundregeln (Spezifität 0) ---------- */
:where(button){font-family:inherit;font-weight:600;border-radius:var(--bs-border-radius);padding:.375rem .85rem;border:1px solid #5a2574;background:#fff;color:#5a2574;cursor:pointer}
:where(button.primary){background:#1a9dd9;border-color:#1a9dd9;color:#fff;font-weight:700}
:where(input[type=text],input[type=search],input[type=date],input[type=time],input[type=number],input[type=email],input[type=password],input:not([type]),select,textarea){border:1px solid #c3dced;border-radius:var(--bs-border-radius);background:#fff;color:#3a3f44}
input[type=checkbox],input[type=radio]{accent-color:#1a9dd9}

/* ==========================================================================
   Einheitliche Knöpfe und Schriften im ganzen Projekt (Stand 31.10.2026)
   Standard-Knopf: 41 px hoch, 15 px Schrift, Innenabstand 14 px, Carlito
   Kompakt (in Tabellenzeilen und .small): 30 px hoch, 13 px Schrift
   Kopf-Knöpfe (Ticket starten, Tickets anzeigen, Übersicht, Abmelden) haben ebenfalls Standardgröße.
   Ausnahmen: Termine im Kalender (.t), Text-Links (.link),
   Listeneinträge in Auswahl-Popups (.ortz, .tz), Kacheln, Schrittleiste, kleine ✕-Knöpfe (.klein),
   Datei-Etiketten (.anlopen, .anldel) und Personen-Chips (.zchip)
   ========================================================================== */
html body :is(button,a.knopf,label.knopfl,.btn,a.ticket):not(.t,.link,.ortz,.tz,.tile,.klein,.small,.wahlbtn,.del,.ico,.anlopen,.anldel,.zchip):not(.stepper button):not(td button,.act button){
  min-height:var(--h-knopf);font-size:.9375rem;line-height:1.2;padding:0 14px;font-family:inherit;box-sizing:border-box;
  display:inline-flex;align-items:center;justify-content:center;gap:6px;border-radius:var(--bs-border-radius);font-weight:600}
html body :is(button.primary,.btn-primary,button.danger.primary){font-weight:700}
html body :is(button.small,td button,.act button,button.del,td a.knopf):not(.link,.t,.klein){
  min-height:30px;height:auto;font-size:.8125rem;line-height:1.2;padding:0 10px;font-family:inherit;box-sizing:border-box;
  display:inline-flex;align-items:center;justify-content:center;border-radius:var(--bs-border-radius)}
html body .wahlbtn{min-height:var(--h-knopf);height:var(--h-knopf);box-sizing:border-box;font-size:.9375rem;padding:0 12px}

/* Schriften einheitlich (Carlito / Bootstrap-Grundgröße 15 px) */
html body .wrap>header h1{font-size:1.9rem}
html body .panel h2,html body .panel>summary h2{font-size:1.15rem}
html body label{font-size:var(--fs-klein)}
html body :is(input[type=text],input[type=search],input[type=date],input[type=time],input[type=number],input[type=email],input[type=password],input:not([type]),select,textarea){font-size:.9375rem;font-family:inherit}
html body td{font-size:.88rem}
html body th{font-size:var(--fs-klein)}

/* Datums- und Uhrzeitfelder überall gleich breit und gleich hoch (wie die Knöpfe 41 px) */
html body input:is([type=date],[type=month]){width:11.5rem!important;max-width:100%;min-height:var(--h-knopf);height:var(--h-knopf);box-sizing:border-box;flex:0 0 auto;font-size:.9375rem}
html body input[type=time]{width:8rem!important;max-width:100%;min-height:var(--h-knopf);height:var(--h-knopf);box-sizing:border-box;flex:0 0 auto;font-size:.9375rem}
html body input[type=datetime-local]{width:15rem!important;max-width:100%;min-height:var(--h-knopf);height:var(--h-knopf);box-sizing:border-box;flex:0 0 auto;font-size:.9375rem}

/* ==========================================================================
   Auswahl-Popups (☰) einheitlich im ganzen Projekt – Vorbild BEM
   Kopf: blaue Überschrift · optional Suchfeld · Einträge als Karten (Rahmen, Name violett,
   Zusatz klein) · Knöpfe unten rechts. Hervorhebung nur beim Darüberfahren (oder Tastatur),
   kein automatischer Fokus ins Suchfeld beim Öffnen.
   ========================================================================== */
html body dialog:is(.wahldlg,.bdlg):not(.wide){width:min(640px,calc(100vw - 32px));padding:0}
html body dialog :is(.wahlin,.bin){padding:20px 22px;display:grid;gap:10px}
html body dialog :is(.wahlin,.bin)>h3{margin:0;font-size:1.12rem;font-weight:700;color:#1a9dd9}
html body dialog h3:focus,html body dialog [tabindex="-1"]:focus{outline:none}
html body dialog :is(.wahlin,.bin) input[type=search]{width:100%;min-height:var(--h-knopf);box-sizing:border-box;padding:7px 10px;border:1px solid #c3dced;border-radius:var(--bs-border-radius);font:inherit;font-size:.9375rem}
html body dialog :is(.wahlin,.bin) input[type=search]:not(:focus-visible){box-shadow:none;outline:none}
html body :is(.ortliste,.tliste,.wahlliste){display:grid;grid-auto-rows:max-content;gap:6px;max-height:55vh;overflow:auto;border:0;padding:2px;border-radius:0}
html body :is(.ortliste .ortz,.tliste .tz,.wahlliste .wahlz){border:1px solid var(--line);border-radius:8px;padding:9px 12px;background:#fff;color:var(--fg);
  text-align:left;width:100%;min-height:0;box-sizing:border-box;font:inherit;font-weight:400;cursor:pointer;line-height:1.35}
html body :is(.ortliste .ortz,.tliste .tz){display:grid;gap:2px}
html body .wahlliste .wahlz{display:flex;align-items:center;gap:10px}
html body :is(.ortliste .ortz,.tliste .tz,.wahlliste .wahlz)[hidden]{display:none}
html body :is(.ortliste .ortz,.tliste .tz,.wahlliste .wahlz) b{color:#5a2574;font-weight:700}
html body :is(.ortliste .ortz,.tliste .tz,.wahlliste .wahlz) small{color:#3a3f44;font-size:var(--fs-klein);font-weight:400}
html body :is(.ortliste .ortz,.tliste .tz,.wahlliste .wahlz):is(:hover,:focus-visible){border-color:#1a9dd9;background:#eef6fb;outline:none}
html body :is(.ortliste .ortz,.tliste .tz,.wahlliste .wahlz):focus:not(:focus-visible){outline:none}
html body :is(.ortliste .ortz,.tliste .tz).akt{border-color:#1a9dd9;background:#eef6fb}
html body :is(.wahlknopf,.bin>.bknopf){display:flex;justify-content:flex-end;gap:8px;align-items:center}

/* ☰-Auswahlknopf überall gleich (wie im BEM): 41 × 41 px, violetter Rahmen, steht vor dem Textfeld */
html body .wahlbtn,html body #pPers .wahlbtn,html body .pkopf .ortbtn,html body .perschips .wahlbtn{width:var(--h-knopf);min-width:var(--h-knopf);height:var(--h-knopf);min-height:var(--h-knopf);padding:0;
  flex:0 0 var(--h-knopf);box-sizing:border-box;display:inline-flex;align-items:center;justify-content:center;border:1px solid #5a2574;border-radius:var(--bs-border-radius);
  background:#fff;color:#5a2574;font-size:1.05rem;font-weight:600;line-height:1}
html body .wahlbtn:not(:disabled):hover,html body #pPers .wahlbtn:not(:disabled):hover,html body .pkopf .ortbtn:not(:disabled):hover{background:#43195a;border-color:#43195a;color:#fff}
html body .wahlbtn:focus:not(:focus-visible){outline:none;box-shadow:none}

/* Kopf-Knöpfe neben dem Seitentitel (Ticket starten, Tickets anzeigen, Übersicht, Abmelden): Standardgröße, violetter Rahmen */
html body :is(a.ticket,button.out,a.out){min-height:var(--h-knopf);font-size:.9375rem;font-weight:600;padding:0 14px;line-height:1.2;box-sizing:border-box;display:inline-flex;align-items:center;justify-content:center;vertical-align:middle;
  border:1px solid #5a2574;border-radius:var(--bs-border-radius);background:#fff;color:#5a2574;text-decoration:none}
html body :is(a.ticket,button.out,a.out):hover{background:#43195a;border-color:#43195a;color:#fff}
html body .wrap>header h1{display:flex;flex-wrap:wrap;align-items:center;gap:8px}
html body .wrap>header h1 a.ticket{margin:0}
html body header .wer:not([hidden]){display:inline-flex;align-items:center;min-height:var(--h-knopf);vertical-align:top;margin-right:6px}
html body header button.out{vertical-align:top;margin-top:10px}
html body header .wer:not([hidden]){margin-top:10px}

/* Gespeicherte Einladung (Protokolle): erst der Dateiname, dahinter „gespeichert …“ in einer Zeile */
html body .einlpdf{display:flex;align-items:center;gap:6px 10px;flex-wrap:wrap}
html body .einlpdf .anl{max-width:100%;min-width:0}
html body .einlpdf .anlopen{max-width:min(520px,70vw);display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
html body .einlpdf .hint{white-space:nowrap}

/* ==========================================================================
   Keine dicken farbigen Ränder links an Kästen (im ganzen Projekt)
   Kästen haben ringsum denselben dünnen Rahmen (1 px). Ein Status wird über die
   Rahmenfarbe ringsum bzw. ein Etikett gezeigt, nicht über einen dicken Strich links.
   ========================================================================== */
html body :is(.ptop,.vkarte,.ptogen,.fk,.hju-card){border-left-width:1px!important}
html body :is(.ptop,.vkarte,.ptogen){border-left-color:var(--line)!important}
html body .ptop.nach{border-color:#f39a3d!important}
html body .fk{border-left-color:#bfe2f4!important}
html body .frr .fk{border-color:#f39a3d!important}
html body .mitfall .fk.ok{border-color:#267a4d!important}
html body .hju-card.s-ok{border-color:var(--ok)!important}
html body .hju-card.s-warn{border-color:var(--warn)!important}
html body .hju-card.s-rot{border-color:var(--bad)!important}
html body .hju-card.s-info{border-color:var(--accent)!important}
html body :is(.frist,.hinweisfeld,.anseck,.anskasten){border:1px solid #cfe6f3!important}
html body .frist.ueber{border-color:#f3b4ac!important}
html body :is(.pnach,.tohinweis,.pgrund){border:1px solid #f6c48e!important}
html body .pgrund.nichtbefassung{border-color:#f3b4ac!important}
html body .ablehnung{border:1px solid #f3b4ac!important}
html body .frl{border-left:0!important;padding-left:0!important}

/* „Keine Auswahl“ steht in jedem Auswahl-Popup als erster Eintrag */
html body :is(.ortliste,.tliste,.wahlliste) .keine{border-style:dashed;background:#fff}
html body :is(.ortliste,.tliste,.wahlliste) .keine b{color:#3a3f44}
html body .wahlliste button.wahlz.keine{display:grid;gap:2px}
/* Textfeld neben dem ☰-Knopf öffnet kein Popup; Hervorhebung des ☰ nur beim Darüberfahren */
html body .wahlzeile input[readonly]{cursor:default}

/* Anzahl hinter dem Bereichstitel („Protokolle / 48 Protokolle“) in derselben Schrift wie der Titel */
html body h2 .anz{font:inherit;color:inherit;letter-spacing:inherit;text-transform:inherit;margin:0;padding:0;background:none;border:0}

/* ==========================================================================
   Schriftgrößen-Skala (im ganzen Projekt nur diese 7 Stufen, festgelegt 31.10.2026)
   Titel 30 · Überschrift 18 · Unterüberschrift 16 · Text 15 · Tabelle 14 · Klein 13 · Etikett 12 (px)
   ========================================================================== */
:root{--h-knopf:37px;--fs-titel:30px;--fs-ueber:18px;--fs-unter:16px;--fs-text:15px;--fs-tab:14px;--fs-klein:13px;--fs-etikett:var(--fs-klein)}  /* Etikett-Stufe entfällt: alles Kleine = 13 px */
/* Titel */
html body header h1{font-size:var(--fs-titel)!important}
/* Überschrift: Bereiche, Schritt-Titel, Popup-Titel, Kennzahlen */
html body h2,html body .skopf h3,html body dialog :is(.wahlin,.bin)>h3,html body .v{font-size:var(--fs-ueber)!important}
/* Unterüberschrift */
html body :is(h3,h4,h5,h6,.kat):not(.skopf h3):not(dialog .wahlin>h3):not(dialog .bin>h3),html body .tile b{font-size:var(--fs-unter)!important}
/* Text */
html body{font-size:var(--fs-text)}
html body :is(p,li,dd,dt,summary,legend,blockquote):not(.hint){font-size:var(--fs-text)}
html body .wahlbtn,html body #pPers .wahlbtn,html body .pkopf .ortbtn{font-size:var(--fs-text)!important}
/* Tabelle */
html body td,html body td :is(b,strong,a,span:not(.st):not(.pst):not(.chip):not(.hju-badge):not(.hint):not(.meta):not(.klein)){font-size:var(--fs-tab)!important}
/* Klein: Hinweise, Beschriftungen, Zusatztexte */
html body :is(.hint,small,code,.flbl,.l,.meta,.klein:not(button),label:not(.knopfl):not(.btn)){font-size:var(--fs-klein)!important}
html body td :is(small,.hint){font-size:var(--fs-klein)!important}
/* Etikett: Status, Tabellenköpfe, Kalender-Einträge */
html body :is(th,.st,.pst,.chip,.hju-badge,.warnz,.sperre,.snr,.vart,.fl-lab),html body th *{font-size:var(--fs-klein)!important}
html body button.t,html body button.t *{font-size:var(--fs-klein)!important}
/* Knöpfe behalten ihre Größe (Standard 15, kompakt 13) – auch wenn sie in einem label stecken */
html body label.knopfl{font-size:var(--fs-text)!important}
html body :is(button.small,td button,.act button,button.del){font-size:var(--fs-klein)!important}
/* Feinabgleich: bisher abweichende Einzelgrößen auf die Skala */
html body :is(.fn,.elab,.wer,.addr,.anzahl,.lbl,.glbl,.btnlink,.arlink,.ptophead .nr,.muted,.art,.zr,footer){font-size:var(--fs-klein)!important}
html body :is(.soffen,.versandweg,.stat,.rotz,.dfrage,.kopfanlhinweis,.tile .go,.epill){font-size:var(--fs-text)!important}
html body td :is(.rotz,.soffen){font-size:var(--fs-tab)!important}
html body button.ico{font-size:var(--fs-text)!important}
html body .wahl .opt,html body .wahl:has([data-wahlweg]) .opt{font-size:var(--fs-klein)!important}
html body b.zr,html body .zr b{font-size:var(--fs-unter)!important}
html body :is(.nr,.pstand){font-size:var(--fs-klein)!important}
html body :is(.hju-toast,.hinweisfeld,.fristst){font-size:var(--fs-text)!important}
html body :is(span.num,span.status){font-size:var(--fs-tab)!important}
html body :is(.kopf>span,.kopf-r span,.panl b,.dirbar span){font-size:var(--fs-klein)!important}
html body :is(.tile span,.slot b,.sinfo b,label.drop span){font-size:var(--fs-text)!important}
html body label.drop b{font-size:var(--fs-unter)!important}
html body button span{font-size:inherit!important}

/* Knöpfe am Ende von Tabellenzeilen (Öffnen, Ansehen, PDF, Bearbeiten …): einheitlich Cyan, beim Darüberfahren Violett.
   Löschen bleibt rot umrandet (Warnfarbe). */
html body td :is(button,a.knopf):not(.danger):not(.del):not(.link):not(.wahlbtn):not(:disabled){background:#1a9dd9!important;border-color:#1a9dd9!important;color:#fff!important;font-weight:600}
html body td :is(button,a.knopf):not(.danger):not(.del):not(.link):not(.wahlbtn):not(:disabled):is(:hover,:focus-visible){background:#5a2574!important;border-color:#5a2574!important;color:#fff!important}
html body td :is(button.danger,button.del):not(:disabled):is(:hover,:focus-visible){background:#b42318!important;border-color:#b42318!important;color:#fff!important}
/* Mehrfachauswahl (Häkchen) in Popups: Häkchen links, Name und Zusatz daneben */
html body .wahlliste .wahlz input[type=checkbox]{width:auto!important;min-width:0!important;flex:0 0 auto;margin:0}
html body .wahlliste .wahlz>span{flex:1;display:grid;gap:1px;text-align:left}
html body .wahlliste button.wahlz.keine{display:grid!important;justify-content:stretch!important;justify-items:start!important;align-items:start;text-align:left;min-height:0!important;padding:9px 12px!important;width:100%;gap:2px}
/* ☰ Auswahl-Knopf (Popup) überall gleich groß – auch in Tabellenzeilen: 41 × 41 px, Schrift 15 px */
html body :is(button.wahlbtn,td button.wahlbtn,.act button.wahlbtn,button.wahlbtn.small){width:var(--h-knopf)!important;min-width:var(--h-knopf)!important;height:var(--h-knopf)!important;min-height:var(--h-knopf)!important;padding:0!important;flex:0 0 var(--h-knopf)!important;font-size:var(--fs-text)!important}
/* Hauptknopf (primary, z. B. Speichern) wie die übrigen Knöpfe: weiß mit violetter Schrift und Rahmen, beim Darüberfahren violett (Stand 02.11.2026) */
html body :is(button.primary,.btn-primary,a.knopf.primary):not(td button):not(.act button),html body #bPos button.primary{background:#fff!important;border-color:#5a2574!important;color:#5a2574!important;font-weight:600!important}
html body :is(button.primary,.btn-primary,a.knopf.primary):not(td button):not(.act button):not(:disabled):is(:hover,:focus-visible),html body #bPos button.primary:not(:disabled):is(:hover,:focus-visible){background:#43195a!important;border-color:#43195a!important;color:#fff!important}
/* Kachel-Knopf „Öffnen“ wie alle Knöpfe: weiß, violette Schrift und Rahmen, 41 px; beim Darüberfahren über die Kachel violett (Stand 02.11.2026) */
html body .tile .go{background:#fff!important;color:#5a2574!important;border:1px solid #5a2574!important;min-height:var(--h-knopf);display:inline-flex;align-items:center;justify-content:center;padding:0 14px!important;font-weight:600!important;box-sizing:border-box;border-radius:var(--bs-border-radius)!important}
html body a.tile:is(:hover,:focus-visible) .go{background:#43195a!important;border-color:#43195a!important;color:#fff!important}

/* Einheitliche Höhe (Stand 02.11.2026): Knöpfe, ☰, Eingabe-, Auswahl- und Datumsfelder = Höhe der Titelschrift h1 = 37 px (--h-knopf) */
html body :is(input[type=text],input[type=search],input[type=email],input[type=number],input[type=password],input[type=tel],input:not([type]),select):not(.form-check-input){height:var(--h-knopf);min-height:var(--h-knopf);box-sizing:border-box;padding-top:0;padding-bottom:0}

/* Kacheln (Startseite) ab 02.11.2026: ohne „Öffnen“-Knopf (die ganze Kachel ist anklickbar), alle gleich hoch:
   Titel + Infozeile für Administratoren („keiner Person zugeordnet“) + höchstens 2 Zeilen Text */
html body .tile{height:var(--kachel-h,116px)!important;min-height:0!important;overflow:hidden;align-content:start!important;gap:3px!important;padding:14px 18px!important;box-sizing:border-box}
html body .tile .go{display:none!important}
html body .tile>span{display:-webkit-box;-webkit-line-clamp:2;line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;line-height:1.4}
html body .tile .unghinweis{font-size:var(--fs-klein)!important;color:#3a3f44;font-style:italic;line-height:1.4}
/* Überschriften-Farben (Stand 02.11.2026):
   Cyan  – Titel im Head (h1), Popup-Titel (erste Überschrift im Fenster), Kacheltitel, Anmeldemaske
   Violett – alle Überschriften darunter: Bereichsüberschriften h2 (GROSSBUCHSTABEN) und Unterüberschriften h3–h6 */
html body :is(h2,h3,h4,h5,h6){color:#5a2574!important}
html body :is(h2,h3,h4,h5,h6) :is(small,.hint){color:#3a3f44!important}
html body header h1,html body .tile b{color:#1a9dd9!important}
html body .tile.admin b{color:#5a2574!important}html body .tile.ungenutzt b{color:#3a3f44!important}
html body dialog>:is(div,form)>:is(h2,h3):first-child,html body dialog>:is(h2,h3):first-child,html body .gatebox h2{color:#1a9dd9!important}

/* Abstand zwischen Knöpfen (02.11.2026): überall 8 px – auch Umschalter (Woche/Monat/Liste) und Blättern (◀ Heute ▶); keine aneinanderklebenden Knöpfe */
html body{--abst-knopf:8px}
html body :is(.seg,.hju-nav){display:inline-flex;flex-wrap:wrap;gap:var(--abst-knopf)!important}
html body :is(.seg,.hju-nav)>button{border-radius:var(--bs-border-radius,.375rem)!important;margin-left:0!important}
html body :is(.aktk,.arq,.doc .act){gap:var(--abst-knopf)!important}
html body :is(.aktk,.arq,.doc .act)>*{margin-left:0!important}
html body :is(td.act,td.akt,div.akt)>:is(button,a,.btnlink){margin-left:0!important}
html body :is(td.act,td.akt,div.akt)>:is(button,a,.btnlink,.pdelaus)+:is(button,a,.btnlink,.pdelaus){margin-left:var(--abst-knopf)!important}
/* Zahl mit ◀ ▶ (Mengen-Stepper, 02.11.2026): gleiche Knöpfe wie Blättern in der Raumbelegung, Zahl auch direkt eintippbar */
html body .hju-stepper{display:inline-flex;align-items:center;gap:var(--abst-knopf);flex-wrap:nowrap}
html body .hju-stepper>input[type=number]{width:5rem;text-align:center;-moz-appearance:textfield;appearance:textfield}
html body .hju-stepper>input[type=number]::-webkit-inner-spin-button,html body .hju-stepper>input[type=number]::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}
html body .hju-stepper>button:not(#_){min-height:var(--h-knopf)!important;height:var(--h-knopf)!important;min-width:44px;padding:0 14px!important;font-size:var(--fs-text)!important;font-weight:600;line-height:1.2;display:inline-flex;align-items:center;justify-content:center;box-sizing:border-box;border-radius:var(--bs-border-radius,.375rem)!important;background:#fff!important;border:1px solid #5a2574!important;color:#5a2574!important}
html body .hju-stepper>button:not(#_):not(:disabled):is(:hover,:focus-visible){background:#43195a!important;border-color:#43195a!important;color:#fff!important}
/* Link- und Datei-Knöpfe (a.knopf, label.knopfl) sehen aus wie normale Knöpfe */
html body :is(a.knopf,label.knopfl){border:1px solid #5a2574;color:#5a2574;background:#fff;border-radius:var(--bs-border-radius,.375rem);text-decoration:none;cursor:pointer;font-weight:600;display:inline-flex;align-items:center;justify-content:center;box-sizing:border-box}
html body :is(a.knopf,label.knopfl):hover{background:#43195a;border-color:#43195a;color:#fff}

/* ===== Dokublock (allgemein, 02.11.2026) – überall gleich: Textfeld + „Text speichern“, Ablagefläche + „Dokument wählen“,
   „Gespeicherte Notizen“ gleich breit wie die Felder, Knöpfe in eigener Spalte (160 px). Vorbild: test/muster.html ===== */
html body .doku{display:grid;gap:10px;border:2px dashed var(--line);border-radius:10px;padding:12px 14px;margin-top:6px}
html body .doku h5{margin:0;font-size:var(--fs-unter);font-weight:600}html body .doku h5 small{font-weight:400}
html body .doku .dfrage{margin:0;font-weight:600;font-size:var(--fs-tab)}
html body .doku :is(.nzeile,.dzeile){display:flex;gap:var(--abst-knopf,8px)}
html body .doku .nzeile{align-items:flex-start}html body .doku .nzeile textarea{flex:1;font:inherit;font-weight:400}
html body .doku .dzeile{align-items:center}html body .doku .dzeile .vdrop{flex:1}
html body .doku :is(.nzeile button,.dzeile .knopfl){width:160px;flex:none;justify-content:center;box-sizing:border-box;height:var(--h-knopf);min-height:var(--h-knopf)}
html body .doku h5.dgesp{margin:4px 0 -4px}
html body .doku .vdrop{border:2px dashed var(--line);border-radius:10px;padding:12px;display:flex;flex-direction:column;flex-wrap:nowrap;align-items:center;text-align:center;justify-content:center;min-height:60px;gap:4px;background:var(--bg)}
html body .doku .vdrop.ueber{border-color:#1a9dd9;background:#eef6fb}
html body .doku .vdrop small{flex-basis:auto}
html body .doku .vliste{list-style:none;margin:0;padding:0;display:grid;gap:6px}
html body .doku .vliste li{display:grid;grid-template-columns:minmax(0,1fr) 160px;gap:var(--abst-knopf,8px);border:0;padding:0;align-items:center;font-size:var(--fs-tab)}
html body .doku .vliste .vbox{display:grid;grid-template-columns:150px 80px minmax(0,1fr) auto;gap:10px;align-items:center;border:1px solid var(--line);border-radius:8px;padding:8px 10px}
html body .doku .vliste .vakt{display:flex;align-items:center;gap:var(--abst-knopf,8px)}
html body .doku .vz{font-weight:600}html body .doku .vvon{color:var(--muted);font-size:var(--fs-klein)}
html body .doku .vart{font-size:var(--fs-klein);font-weight:700;border-radius:999px;padding:2px 8px;text-align:center;background:#eef6fb;color:#1a6f9a;justify-self:start}
html body .doku .vart.mail{background:#f1ecf6;color:#5a2574}html body .doku .vart.notiz{background:#f2f2f2;color:#3a3f44}
html body .doku .vinh small{display:block;color:var(--muted)}html body .doku .vtext{margin-top:2px}
html body .doku .vmail{display:inline-flex;align-items:center;gap:var(--abst-knopf,8px);flex-wrap:wrap}html body .doku .vmail b{font-weight:600}
html body .doku .vmail a.knopf{min-height:30px!important;height:30px!important;font-size:var(--fs-klein)!important;padding:0 10px!important}
html body .doku button.weg{min-height:30px!important;padding:0 8px;color:var(--bad,#c0392b)}
/* Klassifizierung im Block (05.11.2026): Dokumentenart beim Ablegen, Chip und Knopf je Eintrag */
html body .doku .dartw{display:flex;flex-direction:column;gap:4px;flex:none;width:200px;font-weight:600}
html body .doku .dartw select{width:100%;height:var(--h-knopf);font-weight:400}
html body .doku .dkl{display:flex;flex-wrap:wrap;align-items:center;gap:6px;margin-top:4px}
html body .doku .dkl select{width:auto;min-width:12rem;max-width:100%}
html body .doku .dkl button{min-height:30px!important;height:30px!important;padding:0 10px!important;font-size:var(--fs-klein)!important}
html body .doku .dkl .chip{display:inline-block;padding:1px 8px;border-radius:999px;font-size:var(--fs-klein);font-weight:700;background:#eee;color:#555}
html body .doku .dkl .chip.dart{background:#e3f1e6;color:#2c6e3f}html body .doku .dkl .chip.ok{background:#e8f3fb;color:#1572a8}html body .doku .dkl .chip.offen{background:#fff6d1;color:#9a5410}
@media (max-width:700px){html body .doku :is(.vliste li,.vliste .vbox){grid-template-columns:1fr}html body .doku .dzeile{flex-direction:column;align-items:stretch}html body .doku .dartw{width:auto}}
/* E-Mail-Popup (Ansehen) – allgemein */
html body dialog.maildlg{width:min(1100px,96vw);height:85vh;max-height:85vh;padding:0}html body dialog.maildlg[open]{display:flex;flex-direction:column}
html body dialog.maildlg .vkopf{display:flex;gap:var(--abst-knopf,8px);align-items:center;padding:10px 14px;border-bottom:1px solid var(--line)}html body dialog.maildlg .vkopf .sp{flex:1}
html body dialog.maildlg .mkopf{padding:10px 14px;border-bottom:1px solid var(--line);font-size:var(--fs-tab)}
html body dialog.maildlg .mkopf table{border-collapse:collapse}html body dialog.maildlg .mkopf th{text-align:left;color:#5a2574;padding:2px 14px 2px 0;font-weight:700;vertical-align:top}html body dialog.maildlg .mkopf td{padding:2px 0}
html body dialog.maildlg .manh{padding:8px 14px;border-bottom:1px solid var(--line);font-size:var(--fs-tab)}
html body dialog.maildlg iframe{flex:1;border:0;width:100%;background:#fff}
html body dialog.maildlg .mtext{flex:1;margin:0;padding:14px;overflow:auto;white-space:pre-wrap;font-family:inherit;font-size:var(--fs-text)}
/* Baustein Wochenstunden (02.11.2026): ◀ xx,xx ▶ „Std. je Woche“, 0 bis 38,5 in 0,25-Schritten, Feld so breit wie „xx,xx“ */
html body .hju-stepper>input.stdfeld{width:5.2rem;text-align:center}
html body .hju-stepper .einh{font-size:var(--fs-text);color:#3a3f44;white-space:nowrap}
/* PLZ (02.11.2026): immer genau 5 Ziffern, Feld nur so breit wie 5 Ziffern */
html body input.plzfeld{width:6.5rem!important;max-width:6.5rem;text-align:left;letter-spacing:.04em}
html body input.plzfeld.falsch{border-color:var(--bad,#b42318)!important}
html body input.nrfeld{width:5rem!important;max-width:5rem}
/* Personalnummer (02.11.2026): immer „P“ + 5 Ziffern (z. B. P00042), Feld nur so breit */
html body input.persnrfeld{width:7rem!important;max-width:7rem;letter-spacing:.04em}
html body input.persnrfeld.falsch{border-color:var(--bad,#b42318)!important}

/* Seitenbreite: alle Seiten einheitlich höchstens 1600px (06.11.2026) */
html body .wrap{max-width:1600px}
html body footer.schema{max-width:1600px}
/* Kopf auf schmalen Bildschirmen: Titel und Knöpfe umbrechen statt die Seite seitlich zu verbreitern (04.11.2026) */
html body .wrap>*{min-width:0}
html body .wrap>header>div{min-width:0;flex:1 1 auto}
html body .wrap>header h1 a.ticket{white-space:nowrap}
@media (max-width:700px){
  html body .wrap>header{flex-wrap:wrap;padding:14px 16px}
  html body .wrap>header .logo{display:none}
  html body .wrap>header h1{font-size:1.35rem!important}
  html body .tabwrap,html body .tabelle{max-width:100%;overflow-x:auto}
  html body .tbar,html body .seg,html body .hju-row,html body .vrow{flex-wrap:wrap}
  html body .tbar>*,html body .hju-row>*{min-width:0;max-width:100%}
  html body input[type=search]{min-width:0;max-width:100%}
  html body .panel,html body section{max-width:100%;overflow-x:auto}
}

/* Aktenzeichen (05.11.2026): nur lesbar, vom Server vergeben */
html body input.azfeld{background:#f3f6f8;border-style:dashed;font-family:ui-monospace,Consolas,monospace;cursor:default}
html body .azzeile{font-size:var(--fs-klein,13px);color:#555}html body .azzeile b{font-family:ui-monospace,Consolas,monospace;color:#222;font-weight:600}html body .azzeile .leer{font-style:italic;font-weight:400;font-family:inherit;color:#777}
