/* ============================================================
   BK ARBEITSSCHUTZ - Corporate Identity Stylesheet
   ============================================================
   Zentrales CSS-Modul, eingebunden in allen BK-Tools.
   Basiert auf BK Design Manual Mai 2025 (Katharina Holzer Markendesign).

   Verwendung:
     <link rel="stylesheet" href="bk-ci/bk-ci.css">
     <link rel="stylesheet" href="bk-ci/fonts.css">   (SW-2696: Schriften vom eigenen Server, nie Google Fonts)

   Nutzbare Klassen:
     .bk-header              - Plattform-Header (weiß mit blauer Linie)
     .bk-logo bk-logo--full  - Volles Logo
     .bk-logo bk-logo--mark  - Initialien-Logo
     .bk-btn bk-btn--primary - Primary Button
     .bk-btn bk-btn--accent  - Accent Button
     .bk-btn bk-btn--ghost   - Ghost Button
     .bk-card                - Karte mit Schatten
     .bk-card-gradient       - Karte mit Farbverlauf-Akzent
     .bk-table               - Tabelle im BK-Look
     .bk-input               - Eingabefeld
     .bk-tag                 - Kleine Status-Tags
     .bk-status              - Status-Boxen (info, success, warn, error)
     .bk-gradient-bg         - Farbverlauf-Hintergrund (Login, Hero, Cover)

   Variablen:
     --bk-blue-deep      #00205a  Logo-Verlauf dunkel
     --bk-blue-primary   #004f9e  Logo-Verlauf mittel = Primärfarbe
     --bk-blue-bright    #009ee3  Logo-Verlauf hell = Akzent
     --bk-gray           #7b7f83  Hintergrund-Grau
     --bk-text           #414042  Schrift-Schwarz
   ============================================================ */

:root {
  /* --- BK CI Farben (aus Design Manual) --- */
  --bk-blue-deep:      #00205a;
  --bk-blue-primary:   #004f9e;
  --bk-blue-bright:    #009ee3;
  --bk-gray:           #7b7f83;
  --bk-text:           #414042;

  /* --- Funktionale Farben (BK-Palette-konform) --- */
  --bk-bg:             #f7f9fc;
  --bk-bg-alt:         #ffffff;
  --bk-bg-soft:        #eef3f9;
  --bk-border:         #d8e1ec;
  --bk-border-soft:    #eef2f7;
  --bk-text-muted:     #5a6878;
  --bk-text-light:     #8a96a6;

  /* --- Status-Farben (subtil, ergänzen BK-Palette) --- */
  --bk-success:        #2e7d32;
  --bk-success-bg:     #e8f5e9;
  --bk-warning:        #c55a11;
  --bk-warning-bg:     #fff4e5;
  --bk-error:          #c62828;
  --bk-error-bg:       #fdecea;

  /* --- Gradienten (aus Logo & Visitenkarte) --- */
  --bk-gradient-blue:  linear-gradient(135deg, #00205a 0%, #004f9e 50%, #009ee3 100%);
  --bk-gradient-soft:  linear-gradient(135deg, #004f9e 0%, #009ee3 100%);

  /* --- Typografie --- */
  --bk-font-display:   "Nunito Sans", system-ui, -apple-system, sans-serif;
  --bk-font-body:      "Nunito Sans", system-ui, -apple-system, sans-serif;
  --bk-font-mono:      "SF Mono", "Cascadia Mono", Consolas, Monaco, monospace;

  /* --- Spacing & Sizing --- */
  --bk-radius:         8px;
  --bk-radius-sm:      4px;
  --bk-radius-lg:      14px;

  /* --- Shadows --- */
  --bk-shadow-sm:      0 1px 3px rgba(0, 32, 90, 0.06);
  --bk-shadow:         0 2px 8px rgba(0, 32, 90, 0.08);
  --bk-shadow-lg:      0 8px 24px rgba(0, 32, 90, 0.12);

  /* --- Transitions --- */
  --bk-transition:     all 0.18s ease;
}

/* ============================================================
   GLOBALS
   ============================================================ */

*, *::before, *::after { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  font-family: var(--bk-font-body);
  font-size: 15px;
  line-height: 1.55;
  color: var(--bk-text);
  /* SW-3332: ganz leichter BK-Blauton statt fast Weiß (wie --mp-bg im Medi-Portal),
     damit sich weiße Karten und Tabellen abheben. --bk-bg selbst bleibt, es
     färbt auch Flächen in Karten. */
  background: #eef3fa;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--bk-font-display);
  font-weight: 700;
  color: var(--bk-blue-deep);
  margin: 0 0 0.5em;
  letter-spacing: -0.005em;
}

h1 { font-size: 1.9em; line-height: 1.2; }
h2 { font-size: 1.45em; line-height: 1.25; }
h3 { font-size: 1.18em; line-height: 1.3; }
h4 { font-size: 1.05em; line-height: 1.35; }

p { margin: 0 0 1em; }

a {
  color: var(--bk-blue-primary);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: var(--bk-transition);
}
a:hover {
  color: var(--bk-blue-bright);
  border-bottom-color: var(--bk-blue-bright);
}

code, kbd, pre {
  font-family: var(--bk-font-mono);
}
code {
  background: var(--bk-bg-soft);
  padding: 2px 7px;
  border-radius: var(--bk-radius-sm);
  font-size: 0.9em;
  color: var(--bk-blue-primary);
}

/* ============================================================
   LAYOUT
   ============================================================ */

.bk-container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
}

.bk-container-wide {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ============================================================
   HEADER
   Weißer Hintergrund mit BK-Logo, darunter dezente blaue Linie
   ============================================================ */

.bk-header {
  background: #ffffff;
  border-bottom: 3px solid var(--bk-blue-primary);
  box-shadow: var(--bk-shadow-sm);
  position: relative;
}

.bk-header::after {
  /* Zusätzliche dünne hellere Linie für den BK-Verlaufseffekt */
  content: "";
  position: absolute;
  bottom: -6px;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--bk-blue-bright);
  opacity: 0.8;
}

/* SW-3332: Verlauf wie im Medi-Portal (medi.css .mp-kopf), in BK-Blau: links
   Weiß hinter Logo und Tagline, nach rechts über Hellblau ins BK-Blau.
   Die Elemente rechts (Suche, Kommen/Gehen, Zeiten, Nutzer, Abmelden, runde
   Symbole) tragen eigene helle Flächen und bleiben auf dem Blau lesbar. */
.bk-header {
  background: linear-gradient(90deg, #fff 0%, #fff 30%, #dcebf8 42%, var(--bk-blue-bright) 64%, var(--bk-blue-primary) 84%, var(--bk-blue-deep) 100%);
}
@media (max-width: 1200px) {
  .bk-header { background: linear-gradient(90deg, #fff 0%, #fff 34%, #dcebf8 46%, var(--bk-blue-bright) 70%, var(--bk-blue-primary) 88%, var(--bk-blue-deep) 100%); }
}
@media (max-width: 720px) {
  .bk-header { background: linear-gradient(90deg, #fff 0%, #fff 45%, var(--bk-blue-bright) 80%, var(--bk-blue-primary) 100%); }
}
@media print { .bk-header, html, body { background: #fff; } }
/* Durchsichtige Knöpfe im Kopf (Aktualisieren, Abmelden) bekämen auf dem Blau
   keinen Kontrast – sie erhalten eine weiße Fläche wie die übrigen. */
.bk-header .bk-refresh-btn,
.bk-header .bk-btn--ghost { background: #fff; }
.bk-header .bk-refresh-btn:hover { background: var(--bk-blue-primary); }
.bk-header .bk-btn--ghost:hover:not(:disabled) { background: var(--bk-bg-soft); }
/* SW-3334: dieselbe Tiefe für die übrigen Kopf-Elemente (Kommen/Gehen,
   Nutzer, Suche, runde Symbole, Aktualisieren). Die Zeiten-Pille hat schon
   einen eigenen Schatten (bk-app.js). */
.bk-header #bkStempelBtn,
.bk-header .bk-user-menu-btn,
.bk-header .bk-refresh-btn,
.bk-header-inner > div[style*="margin-left"] > a,
.bk-header-inner > div[style*="margin-left"] > button:not(#btnZeitfenster) {
  box-shadow: 0 1px 2px rgba(0, 32, 90, 0.12), 0 2px 6px rgba(0, 32, 90, 0.10) !important;
}
.bk-header #bkGsWrap { box-shadow: 0 1px 2px rgba(0, 32, 90, 0.10), 0 2px 6px rgba(0, 32, 90, 0.08); }

.bk-header-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 32px;
  max-width: 1400px;
  margin: 0 auto;
  gap: 24px;
  flex-wrap: wrap;
}

.bk-header-brand {
  display: flex;
  align-items: center;
  gap: 16px;
  text-decoration: none;
  border: none;
}

.bk-header-tagline {
  font-size: 0.78em;
  color: var(--bk-text-muted);
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  padding-left: 18px;
  border-left: 2px solid var(--bk-blue-bright);
  display: none;  /* per default versteckt, kann via Modifier eingeblendet werden */
}

.bk-header-tagline--show { display: block; }

/* ============================================================
   SW-1929: Kopfbereich auf Tablet-Breiten
   ============================================================
   Der Kopf ist eine Flex-Zeile mit Umbruch, in der die rechte Gruppe per
   margin-left:auto nach rechts geschoben wird. Sobald der Inhalt nicht mehr
   in eine Zeile passt, bricht er in drei — und weil das auto-Margin auch in
   der neuen Zeile wirkt, klebt dort jede Gruppe am rechten Rand und links
   daneben steht eine große leere Fläche. Auf dem iPad hochkant waren das
   167 px Kopf, davon der größte Teil Leerraum.

   Statt den Umbruch zu verbieten, wird er GEORDNET: Die Suche wandert per
   order ans Ende und nimmt die zweite Zeile ganz ein, alles andere bleibt
   in der ersten. Dazu schrumpfen Logo, Beschriftungen und Symbole in zwei
   Stufen, damit die erste Zeile auch bei 810 px eine Zeile bleibt. */

@media (max-width: 1200px) {
  .bk-header-tagline { display: none !important; }
  .bk-header-inner { padding: 10px 16px; gap: 10px; row-gap: 8px; }
  /* Die Suche ist das einzige Element, das ohne Verlust in eine eigene Zeile
     darf — sie braucht ohnehin Breite. Volle Zeile statt 260 px: In der
     zweiten Zeile ist der Platz da, und ein kurzes Feld mit leerer Fläche
     daneben sähe wieder nach Panne aus. */
  #bkGsWrap { order: 9; flex: 1 1 100% !important; max-width: none !important; margin: 0 !important; }
  .bk-header-brand .bk-logo--full img { height: 38px; }
  /* „Aktualisieren" wird zum Symbol. Der Text kostet 100 px, und auf dem
     Tablet lädt man ohnehin über die Wischgeste neu. Umgesetzt über eine
     feste Breite mit overflow statt über font-size:0 — der Pfeil steht als
     erstes Zeichen im Text, also bleibt genau er stehen, und es braucht kein
     zweites Zeichen aus dem Stylesheet, das bei abweichender Beschriftung
     doppelt erschiene. */
  /* Nur noch das Zeichen. Die Beschriftung ist von bk-app.js in ein eigenes
     Element getrennt (splitRefreshLabel), damit sie hier schlicht wegfallen
     kann — ohne Trick mit Überlauf oder Schriftgröße null, die bei einem
     Flex-Knopf nicht überall greifen. */
  .bk-refresh-btn { width: 38px; padding: 0; gap: 0; justify-content: center; }
  .bk-refresh-btn .bk-rb-text { display: none; }
  .bk-refresh-btn .bk-rb-icon { font-size: 17px; line-height: 1; }
}

@media (max-width: 900px) {
  .bk-header-inner { padding: 8px 12px; gap: 8px; }
  .bk-header-brand .bk-logo--full img { height: 32px; }
  /* Die Zeiterfassungs-Pille ist mit „Gehen · seit 15:18 · 108%" das breiteste
     Einzelstück der Zeile. Kleinere Schrift und weniger Polsterung sparen hier
     mehr als jede andere Maßnahme; der Text bleibt vollständig lesbar. */
  #bkStempelBtn { font-size: 0.78em !important; padding: 6px 11px !important; gap: 5px !important; }
  /* Die runden Symbole zusammenrücken und eine Spur kleiner. */
  .bk-header-inner > div[style*="margin-left"] { gap: 6px !important; }
  .bk-header-inner > div[style*="margin-left"] > a,
  .bk-header-inner > div[style*="margin-left"] > button,
  .bk-header-inner > div[style*="margin-left"] > span { width: 29px !important; height: 29px !important; }

  /* SW-2104: AUSNAHME fuer den Zeiterfassungs-Knopf.

     Die Regel darueber zwingt JEDEN Knopf dieser Gruppe in ein Quadrat von
     29 px - sie war fuer die runden Symbole gedacht, die dort seit jeher
     stehen. Seit SW-2033 steht dort auch die beschriftete Pille "Zeiten".
     Die passt nicht in 29 px: Ihr Inhalt lief aus dem viel zu kleinen Kasten
     heraus und schob sich am Tablet sichtbar unter das Profilbild.

     Wer hier einen weiteren Knopf einhaengt, der nicht rund ist, braucht
     ebenfalls eine Ausnahme - oder besser: eine eigene Klasse fuer die runden
     Symbole statt dieser Regel ueber alle Kinder. Dafuer muessten alle
     Modulseiten angefasst werden, deshalb bleibt es vorerst bei der Ausnahme. */
  .bk-header-inner > div[style*="margin-left"] > #zfWrap,
  .bk-header-inner > div[style*="margin-left"] > #btnZeitfenster {
    width: auto !important; height: auto !important;
  }
  #zfWrap { display: inline-flex; align-items: center; flex: 0 0 auto; }
  /* Auf dem Tablet reicht das Symbol - die Beschriftung kostet Breite, die
     die Zeile dort nicht hat. */
  #btnZeitfenster .zf-label { display: none; }
  #btnZeitfenster { padding: 0 !important; width: 34px; height: 34px !important; }

  /* Bricht die Zeile doch einmal um, sollen die Symbole untereinander stehen
     statt sich zu ueberlagern. */
  .bk-header-inner > div[style*="margin-left"] { flex-wrap: wrap; justify-content: flex-end; }
  /* Der Name verschwindet, das Bild bleibt. Wer angemeldet ist, sieht es am
     Profilbild; der ausgeschriebene Name kostet hier über 100 px und ist die
     erste Angabe, auf die man verzichten kann. */
  .bk-header-user-name { display: none; }
  .bk-header-user { gap: 8px; }
}

@media (max-width: 720px) {
  .bk-header-inner { padding: 8px 10px; gap: 6px; }
}

.bk-header-user {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.92em;
  color: var(--bk-text-muted);
}

.bk-header-user-name {
  font-weight: 600;
  color: var(--bk-text);
}

.bk-refresh-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  background: transparent;
  border: 1.5px solid var(--bk-blue-primary);
  border-radius: 6px;
  color: var(--bk-blue-primary);
  font-size: 0.88em;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.15s, color 0.15s;
}

.bk-refresh-btn:hover {
  background: var(--bk-blue-primary);
  color: #ffffff;
}

.bk-refresh-btn:active {
  opacity: 0.8;
  transform: rotate(20deg);
}

@media (max-width: 720px) {
  .bk-refresh-btn span { display: none; }
  .bk-refresh-btn { padding: 6px 10px; font-size: 1em; }
}

/* ============================================================
   LOGO
   ============================================================ */

.bk-logo {
  display: inline-block;
  line-height: 0;
}

.bk-logo img {
  display: block;
  height: auto;
}

.bk-logo--full img {
  height: 44px;
  width: auto;
}

.bk-logo--full-large img {
  height: 80px;
  width: auto;
}

.bk-logo--mark img {
  height: 48px;
  width: auto;
}

.bk-logo--mark-large img {
  height: 120px;
  width: auto;
}

@media (max-width: 720px) {
  .bk-logo--full img { height: 32px; }
}

/* ============================================================
   BUTTONS
   ============================================================ */

.bk-btn {
  font-family: var(--bk-font-body);
  font-size: 0.92em;
  font-weight: 600;
  padding: 10px 20px;
  border: 1px solid transparent;
  border-radius: var(--bk-radius-sm);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
  transition: var(--bk-transition);
  letter-spacing: 0.01em;
  line-height: 1.3;
  white-space: nowrap;
}

.bk-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* SW-3334: Knöpfe wirkten flach. Ein dezenter Schatten hebt sie vom
   Untergrund ab, beim Überfahren etwas mehr, beim Drücken fast keiner.
   Varianten mit eigenem Schatten (primary/accent beim Hover, finish) setzen
   ihn weiter selbst; gesperrte Knöpfe bleiben flach. */
.bk-btn {
  box-shadow: 0 1px 2px rgba(0, 32, 90, 0.10), 0 2px 5px rgba(0, 32, 90, 0.07);
}
.bk-btn:hover:not(:disabled) {
  box-shadow: 0 2px 4px rgba(0, 32, 90, 0.12), 0 4px 10px rgba(0, 32, 90, 0.10);
}
.bk-btn:active:not(:disabled) {
  box-shadow: 0 1px 2px rgba(0, 32, 90, 0.12);
}
.bk-btn:disabled { box-shadow: none; }

.bk-btn--primary {
  background: var(--bk-blue-primary);
  color: white;
}
.bk-btn--primary:hover:not(:disabled) {
  background: var(--bk-blue-deep);
  box-shadow: var(--bk-shadow);
}

.bk-btn--accent {
  background: var(--bk-blue-bright);
  color: white;
}
.bk-btn--accent:hover:not(:disabled) {
  background: var(--bk-blue-primary);
  box-shadow: var(--bk-shadow);
}

.bk-btn--ghost {
  background: transparent;
  color: var(--bk-blue-primary);
  border-color: var(--bk-border);
}
.bk-btn--ghost:hover:not(:disabled) {
  background: var(--bk-bg-soft);
  border-color: var(--bk-blue-primary);
}

.bk-btn--danger {
  background: var(--bk-error);
  color: white;
}
.bk-btn--danger:hover:not(:disabled) {
  background: #a01f1f;
}

/* Abschließen-Button: kräftiges Rot mit Hervorhebung */
.bk-btn--finish {
  background: #c62828;
  color: white;
  font-weight: 700;
  box-shadow: 0 2px 6px rgba(198, 40, 40, 0.25);
}
.bk-btn--finish:hover:not(:disabled) {
  background: #a01f1f;
  box-shadow: 0 3px 10px rgba(198, 40, 40, 0.4);
}
.bk-btn--finish:active:not(:disabled) {
  transform: translateY(1px);
  box-shadow: 0 1px 4px rgba(198, 40, 40, 0.3);
}

.bk-btn--large {
  padding: 14px 28px;
  font-size: 1em;
}

.bk-btn--small,
.bk-btn--sm {
  padding: 6px 12px;
  font-size: 0.85em;
}

.bk-btn--ms {
  /* Microsoft-Login-Style: Akzent-Farbe als Marker */
  background: var(--bk-blue-bright);
  color: white;
  padding: 14px 28px;
  font-size: 1em;
}
.bk-btn--ms:hover:not(:disabled) {
  background: var(--bk-blue-primary);
}
.bk-btn--ms svg {
  width: 20px;
  height: 20px;
}

/* ============================================================
   CARDS
   ============================================================ */

.bk-card {
  background: var(--bk-bg-alt);
  border: 1px solid var(--bk-border);
  border-radius: var(--bk-radius);
  padding: 24px 28px;
  box-shadow: var(--bk-shadow-sm);
  margin-bottom: 18px;
}

.bk-card--clean {
  padding: 28px 32px;
}

.bk-card-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--bk-border-soft);
}

.bk-card-header h2,
.bk-card-header h3 {
  margin: 0;
}

.bk-card-gradient {
  background: var(--bk-gradient-blue);
  color: white;
  border-radius: var(--bk-radius-lg);
  padding: 32px 36px;
  position: relative;
  overflow: hidden;
}

.bk-card-gradient h1,
.bk-card-gradient h2,
.bk-card-gradient h3 { color: white; }

.bk-card-gradient::before {
  content: "";
  position: absolute;
  top: -50%;
  right: -10%;
  width: 60%;
  height: 200%;
  background: radial-gradient(circle, rgba(255,255,255,0.08) 0%, transparent 60%);
  pointer-events: none;
}

/* ============================================================
   TOOL CARDS (Startseite Tool-Auswahl)
   ============================================================ */

.bk-tool-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}

.bk-tool-card {
  background: var(--bk-bg-alt);
  border: 1px solid var(--bk-border);
  border-radius: var(--bk-radius);
  padding: 28px;
  transition: var(--bk-transition);
  cursor: pointer;
  position: relative;
  overflow: hidden;
  text-decoration: none;
  display: block;
  color: var(--bk-text);
}

.bk-tool-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: var(--bk-gradient-soft);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.25s ease;
}

.bk-tool-card:hover {
  border-color: var(--bk-blue-primary);
  box-shadow: var(--bk-shadow-lg);
  transform: translateY(-2px);
  color: var(--bk-text);
}

.bk-tool-card:hover::before {
  transform: scaleX(1);
}

.bk-tool-card--disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.bk-tool-card--disabled:hover {
  border-color: var(--bk-border);
  box-shadow: var(--bk-shadow-sm);
  transform: none;
}

.bk-tool-card--disabled::before { display: none; }

.bk-tool-card-icon {
  font-size: 2.2em;
  margin-bottom: 14px;
  display: block;
  color: var(--bk-blue-primary);
}

.bk-tool-card h3 {
  margin: 0 0 8px;
  font-size: 1.15em;
}

.bk-tool-card p {
  color: var(--bk-text-muted);
  font-size: 0.92em;
  margin: 0;
  line-height: 1.55;
}

.bk-tool-card-meta {
  margin-top: 14px;
  font-size: 0.82em;
  color: var(--bk-text-light);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 600;
}

/* ============================================================
   TABLES
   ============================================================ */

.bk-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.93em;
}

.bk-table th,
.bk-table td {
  text-align: left;
  padding: 12px 16px;
  border-bottom: 1px solid var(--bk-border-soft);
  vertical-align: top;
}

.bk-table th {
  background: var(--bk-bg-soft);
  color: var(--bk-blue-deep);
  font-weight: 700;
  font-size: 0.78em;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.bk-table tbody tr:hover td {
  background: var(--bk-bg-soft);
}

/* ============================================================
   FORM ELEMENTS
   ============================================================ */

.bk-input,
.bk-textarea,
.bk-select {
  width: 100%;
  padding: 10px 14px;
  font-family: var(--bk-font-body);
  font-size: 0.95em;
  color: var(--bk-text);
  background: white;
  border: 1px solid var(--bk-border);
  border-radius: var(--bk-radius-sm);
  transition: var(--bk-transition);
}

.bk-input:focus,
.bk-textarea:focus,
.bk-select:focus {
  outline: none;
  border-color: var(--bk-blue-primary);
  box-shadow: 0 0 0 3px rgba(0, 79, 158, 0.12);
}

.bk-textarea {
  min-height: 100px;
  resize: vertical;
  font-family: var(--bk-font-body);
}

.bk-label {
  display: block;
  font-size: 0.85em;
  font-weight: 600;
  color: var(--bk-blue-deep);
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.bk-field {
  margin-bottom: 18px;
}

.bk-field-hint {
  font-size: 0.82em;
  color: var(--bk-text-muted);
  margin-top: 4px;
}

/* ============================================================
   STATUS / ALERT BOXES
   ============================================================ */

.bk-status {
  padding: 14px 18px;
  border-radius: var(--bk-radius-sm);
  font-size: 0.93em;
  border-left: 4px solid;
  margin: 14px 0;
}

.bk-status--info {
  background: var(--bk-bg-soft);
  border-color: var(--bk-blue-primary);
  color: var(--bk-blue-deep);
}

.bk-status--success {
  background: var(--bk-success-bg);
  border-color: var(--bk-success);
}

.bk-status--warning {
  background: var(--bk-warning-bg);
  border-color: var(--bk-warning);
}

.bk-status--error {
  background: var(--bk-error-bg);
  border-color: var(--bk-error);
}

/* ============================================================
   TAGS / BADGES
   ============================================================ */

.bk-tag {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: 12px;
  font-size: 0.72em;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.bk-tag--primary { background: var(--bk-bg-soft); color: var(--bk-blue-primary); }
.bk-tag--accent  { background: rgba(0, 158, 227, 0.12); color: var(--bk-blue-bright); }
.bk-tag--success { background: var(--bk-success-bg); color: var(--bk-success); }
.bk-tag--warning { background: var(--bk-warning-bg); color: var(--bk-warning); }
.bk-tag--muted   { background: #ececec; color: var(--bk-text-muted); }

/* ============================================================
   GRADIENT BACKGROUNDS (für Login-Pages, Hero-Bereiche)
   ============================================================ */

.bk-gradient-bg {
  background: var(--bk-gradient-blue);
  min-height: 100vh;
  position: relative;
}

.bk-gradient-bg::before {
  /* Subtile Lichtreflexe wie auf Cover des Manuals */
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background:
    radial-gradient(circle at 30% 20%, rgba(255,255,255,0.06) 0%, transparent 50%),
    radial-gradient(circle at 70% 80%, rgba(0, 158, 227, 0.15) 0%, transparent 50%);
  pointer-events: none;
}

/* ============================================================
   STAT BOXES (für Dashboards)
   ============================================================ */

.bk-stat {
  background: var(--bk-bg-soft);
  border-radius: var(--bk-radius);
  padding: 18px 22px;
  text-align: center;
}

.bk-stat-num {
  font-family: var(--bk-font-display);
  font-size: 2.1em;
  font-weight: 800;
  color: var(--bk-blue-primary);
  line-height: 1;
  letter-spacing: -0.02em;
}

.bk-stat-label {
  font-size: 0.78em;
  color: var(--bk-text-muted);
  margin-top: 6px;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  font-weight: 600;
}

/* ============================================================
   LOG (für Aktivitäts-Anzeigen)
   ============================================================ */

.bk-log {
  background: var(--bk-blue-deep);
  color: #e8eef5;
  padding: 14px 18px;
  border-radius: var(--bk-radius-sm);
  font-family: var(--bk-font-mono);
  font-size: 0.82em;
  line-height: 1.55;
  max-height: 300px;
  overflow-y: auto;
}

.bk-log-ts { color: #5a7da3; }
.bk-log-info { color: #8fb4d8; }
.bk-log-ok { color: #7ec97e; }
.bk-log-err { color: #ff8a80; }

/* ============================================================
   UTILITIES
   ============================================================ */

.bk-text-muted { color: var(--bk-text-muted); }
.bk-text-center { text-align: center; }
.bk-mt-0 { margin-top: 0; }
.bk-mt-1 { margin-top: 8px; }
.bk-mt-2 { margin-top: 16px; }
.bk-mt-3 { margin-top: 24px; }
.bk-mb-0 { margin-bottom: 0; }
.bk-mb-1 { margin-bottom: 8px; }
.bk-mb-2 { margin-bottom: 16px; }
.bk-mb-3 { margin-bottom: 24px; }

.bk-flex { display: flex; gap: 12px; }
.bk-flex-between { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.bk-flex-wrap { flex-wrap: wrap; }

.bk-button-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 14px;
}

/* ============================================================
   FOOTER
   ============================================================ */

.bk-footer {
  text-align: center;
  padding: 24px;
  color: var(--bk-text-light);
  font-size: 0.82em;
  margin-top: 60px;
  border-top: 1px solid var(--bk-border-soft);
}

.bk-footer-brand {
  color: var(--bk-blue-primary);
  font-weight: 700;
}

/* ══════════════════════════════════════════════════════════════════ */
/* SW-605 (Analyse P2-3): Durchgängiges Tablet-/Karten-Layout          */
/* Unter ~920px: größere Touch-Ziele + opt-in Karten statt Tabellen     */
/* (Tabelle bekommt zusätzlich die Klasse .bk-cardify).                 */
/* ══════════════════════════════════════════════════════════════════ */
@media (max-width: 920px) {
  /* Größere Touch-Ziele */
  .bk-btn { min-height: 42px; }
  input.bk-input, select.bk-input, textarea.bk-input, .bk-input {
    min-height: 42px;
    font-size: 16px; /* verhindert Auto-Zoom auf iOS */
  }
  #bkModuleNav a { padding-top: 11px; padding-bottom: 9px; }

  /* Opt-in: Listen-Tabellen als Karten darstellen */
  table.bk-cardify { display: block !important; width: 100% !important; border: none !important; }
  table.bk-cardify thead { display: none !important; }
  table.bk-cardify tbody { display: block !important; width: 100% !important; }
  table.bk-cardify tr {
    display: block !important;
    margin: 0 0 10px !important;
    padding: 6px 12px !important;
    border: 1px solid var(--bk-border, #dce3ec) !important;
    border-radius: 10px !important;
    background: #fff !important;
    box-shadow: 0 1px 3px rgba(0,0,0,.07) !important;
  }
  table.bk-cardify td {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    gap: 12px !important;
    width: auto !important;
    padding: 7px 0 !important;
    border: none !important;
    border-bottom: 1px solid #f0f3f8 !important;
    text-align: right !important;
    min-height: 0 !important;
    white-space: normal !important;
  }
  table.bk-cardify tr td:last-child { border-bottom: none !important; }
  table.bk-cardify td::before {
    content: attr(data-label);
    font-weight: 600;
    color: var(--bk-text-muted, #5a6b8c);
    text-align: left;
    flex: 0 0 42%;
    white-space: normal;
  }
  /* Zellen ohne Spaltenüberschrift (Icon/Aktionen): volle Breite, kein Label */
  table.bk-cardify td[data-label=""]::before,
  table.bk-cardify td:not([data-label])::before { display: none; }
  table.bk-cardify td[data-label=""],
  table.bk-cardify td:not([data-label]) { justify-content: flex-end !important; }
  table.bk-cardify td:empty { display: none !important; }
}

/* SW-606: Inline-Suchfeld im Header – auf schmalen Screens schrumpfen */
#bkGsWrap { transition: border-color .15s, box-shadow .15s; }
#bkGsWrap:focus-within { border-color: var(--bk-blue-primary,#00205a); box-shadow: 0 0 0 3px rgba(0,32,90,.12); }
@media (max-width: 720px) {
  #bkGsWrap { flex-basis: 150px; margin: 0 8px; padding: 5px 11px; }
}
@media (max-width: 520px) {
  #bkGsWrap { flex-basis: 108px; margin: 0 6px; }
}

/* SW-607: Auf Tablet/iPad (≤1024px) das Header-Suchfeld in eine eigene
   volle Zeile UNTER das Logo legen (statt oben rechts gequetscht).
   !important nötig, da #bkGsWrap Inline-Styles trägt. */
@media (max-width: 1024px) {
  #bkGsWrap {
    order: 10 !important;       /* hinter die übrigen Header-Elemente → nächste Zeile */
    flex: 1 1 100% !important;  /* volle Breite → eigener Umbruch */
    max-width: 100% !important;
    margin: 6px 0 2px 0 !important;
  }
  /* SW-714: Tagline auch im Tablet-Bereich (721–1024px) ausblenden. Mit der
     (per applyHeaderOverrides) vergrößerten Tagline wurde die Marke so breit,
     dass Marke + rechte Aktionsgruppe (Diagnose/Sync/Changelog/Hilfe + Name/
     Abmelden) nicht mehr gemeinsam in die erste Zeile passten – die Gruppe brach
     auf dem iPad-Hochformat in eine zweite Zeile um. Ohne Tagline passen beide
     wieder nebeneinander; das Suchfeld bleibt (SW-607) in seiner eigenen Zeile. */
  .bk-header-tagline { display: none !important; }
}

/* ============================================================
   SW-1391: Einheitliche Warte-/Ladeanzeige (projektweit)
   Zentrale, ANIMIERTE Ladeanzeige. Löst die bisher uneinheitlichen,
   statischen ⏳-Platzhalter ab. Da bk-ci.css global eingebunden ist,
   animiert der Spinner auch reine HTML-Initial-Platzhalter sofort beim
   ersten Rendern (bevor JS läuft).
   Nutzung:
     <div class="bk-loading"><span class="bk-loading__wheel"></span>
       <span>Lade Kundendaten…</span></div>
   Einzelnes Rad (in bestehenden zentrierten Empty-States):
     <div class="bk-loading__wheel" style="margin:0 auto 10px;"></div>
   Kompakt (Tabellenzellen/kleine Bereiche): zusätzlich .bk-loading--inline
   ============================================================ */
@keyframes bkSpin { to { transform: rotate(360deg); } }

.bk-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 40px 16px;
  color: var(--bk-text-muted, #5a6878);
  font-size: 0.95em;
  text-align: center;
}
.bk-loading__wheel {
  width: 30px; height: 30px;
  flex-shrink: 0;
  border: 3px solid var(--bk-border, #d8e1ec);
  border-top-color: var(--bk-blue-primary, #004f9e);
  border-radius: 50%;
  animation: bkSpin 0.8s linear infinite;
}
.bk-loading--inline {
  flex-direction: row;
  padding: 14px 12px;
  gap: 10px;
  font-size: 0.9em;
}
.bk-loading--inline .bk-loading__wheel { width: 18px; height: 18px; border-width: 2px; }
@media (prefers-reduced-motion: reduce) {
  .bk-loading__wheel { animation-duration: 1.8s; }
}

/* ============================================================
   SW-1393: Globale Admin-Suche (Command-Palette)
   Suchfeld im Admin-Kopf + Ergebnis-Dropdown. Nur im Admin genutzt,
   liegt aber in der global eingebundenen bk-ci.css (ein Ort für alle
   wiederverwendbaren Bausteine).
   ============================================================ */
.admin-search {
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
  max-width: 520px;
  margin: 4px 0 22px;
  padding: 9px 12px;
  background: var(--bk-surface, #fff);
  border: 1px solid var(--bk-border, #d8e1ec);
  border-radius: 10px;
  box-shadow: 0 1px 3px rgba(0,32,90,.05);
}
.admin-search:focus-within {
  border-color: var(--bk-blue-primary, #004f9e);
  box-shadow: 0 0 0 3px rgba(0,79,158,.12);
}
.admin-search__icon { font-size: 1.05em; opacity: .7; flex: none; }
.admin-search__input {
  flex: 1; min-width: 0;
  border: 0; outline: none; background: transparent;
  font: inherit; color: var(--bk-text, #1a2332);
}
.admin-search__kbd {
  flex: none;
  border: 1px solid #c4ccd8; border-bottom-width: 2px; border-radius: 5px;
  background: #f7f9fc; color: #5a6878;
  padding: 1px 7px; font-family: Consolas, monospace; font-size: .74em;
}
.admin-search__results {
  position: absolute; top: calc(100% + 6px); left: 0; right: 0;
  max-height: 60vh; overflow-y: auto;
  background: var(--bk-surface, #fff);
  border: 1px solid var(--bk-border, #d8e1ec);
  border-radius: 10px;
  box-shadow: 0 12px 32px rgba(0,32,90,.16);
  z-index: 1000;
  padding: 6px;
}
.admin-search__item {
  display: flex; align-items: center; gap: 12px;
  padding: 9px 10px; border-radius: 8px; cursor: pointer;
}
.admin-search__item.is-active,
.admin-search__item:hover { background: var(--bk-soft, #eef4fb); }
.admin-search__item-icon { font-size: 1.15em; flex: none; width: 1.5em; text-align: center; }
.admin-search__item-text { display: flex; flex-direction: column; line-height: 1.25; min-width: 0; }
.admin-search__item-label { font-weight: 700; color: var(--bk-text, #1a2332); }
.admin-search__item-path  { font-size: .78em; color: var(--bk-text-muted, #5a6878); }
.admin-search__empty { padding: 14px 12px; color: var(--bk-text-muted, #5a6878); font-size: .9em; text-align: center; }
.admin-search__head {
  padding: 6px 10px 4px;
  font-size: .72em; font-weight: 800; letter-spacing: .06em; text-transform: uppercase;
  color: var(--bk-text-muted, #5a6878);
}

/* ══════════════════════════════════════════════════════════════════════════
   SW-2341: TELEFON-SCHICHT (bis 760 px)
   ══════════════════════════════════════════════════════════════════════════

   WARUM EINE EIGENE STUFE UNTERHALB DER TABLET-REGELN.

   Die vorhandenen Haltepunkte (1200/1024/920/720 px) sind für das iPad
   entstanden und leisten dort, was sie sollen. Auf einem Telefon mit 410 px
   Fensterbreite greifen sie zwar mit, reichen aber nicht: Gemessen an den
   Bildschirmfotos vom 17.09.2026 (Pixel 8, 412 px) war der Inhaltsbereich der
   UVV-Prüfungen rund 550 px breit — also 140 px breiter als das Gerät. Rechts
   fehlte deshalb auf jeder Ansicht ein Stück: Kennzahl-Kacheln, Knöpfe,
   Fortschrittsbalken, die Spalte „Mit Termin“.

   DIE URSACHE IST FAST IMMER DIESELBE. Eine Zeile aus Knöpfen wird als
   `display:flex` ausgezeichnet, ohne `flex-wrap` dazuzuschreiben. Der
   Vorgabewert ist `nowrap`, Knöpfe tragen `white-space:nowrap` — die Zeile
   kann also nicht schmaler werden als die Summe ihrer Knöpfe. Liegt sie in
   einer Rasterspalte `1fr`, wächst die GANZE SPALTE auf dieses Maß mit
   (`1fr` ist `minmax(auto,1fr)`, und `auto` ist die Mindestbreite des
   Inhalts). Ein einziger zu langer Knopfsatz verbreitert damit die komplette
   Seite, und alles darin steht rechts über.

   Daraus folgt auch etwas, das zunächst wie ein zweiter Fehler aussah: Der
   Dialog „Neues Prüfobjekt“ stand am Telefon halb außerhalb des Bildes. Er
   ist nicht zu breit. Er liegt `position:fixed` korrekt am linken Rand des
   Layout-Fensters — nur hatte der Nutzer die überbreite Seite nach rechts
   geschoben, und feste Elemente wandern dabei mit aus dem Bild. Sobald die
   Seite nicht mehr breiter ist als das Display, sitzt jeder Dialog wieder.

   DESHALB STEHT HIER EINE REGEL STATT HUNDERTSIEBZIG EINZELKORREKTUREN.
   Allein in den Feldmodulen gibt es 172 solcher Zeilen. Sie einzeln zu
   ergänzen hieße, 172 Stellen zu ändern und bei jeder neuen Zeile daran zu
   denken. Die Regel unten setzt stattdessen `flex-wrap:wrap` für alle
   Flex-Behälter, die ihr Umbruchverhalten NICHT selbst festlegen.

   Das ist bewusst so abgegrenzt: Ein Behälter, der `flex-wrap` im
   style-Attribut mitbringt — ob `wrap` oder `nowrap` —, behält seine Angabe,
   weil ein Inline-Stil jede Regel aus einer Datei schlägt. Getroffen wird
   also genau die Menge, bei der niemand eine Entscheidung getroffen hat,
   sondern der Vorgabewert eingesprungen ist. Wer eine Leiste braucht, die am
   Telefon waagerecht rollen SOLL, schreibt `flex-wrap:nowrap` dazu und ist
   ausgenommen.

   Als Fangnetz kommt `overflow-x:clip` auf `main`. `clip` und nicht `hidden`:
   `hidden` macht aus dem Element einen Rollbereich und nimmt allen Kindern
   darin die Klebrigkeit (`position:sticky`) — Auswahlleisten und Werkzeug-
   leisten blieben dann nicht mehr oben stehen. `clip` klippt nur und lässt
   die Gegenachse ausdrücklich `visible`. Voraussetzung: Safari ab 16 und
   Chrome ab 90 — beides auf den Zielgeräten (aktuelles iPhone, Pixel 8)
   erfüllt.
   ══════════════════════════════════════════════════════════════════════════ */

@media (max-width: 760px) {

  /* ── 1 · Nichts darf breiter sein als das Gerät ───────────────────────── */

  html, body { max-width: 100%; }

  /* Fangnetz. Greift nur, wenn eine Zeile trotz allem übersteht; ohne das
     verschiebt ein einziges überbreites Element die gesamte Seite samt
     Kopf, Modulleiste und aller festen Dialoge. */
  main { overflow-x: clip; }

  /* Der Kern (Begründung oben). Dialoge liegen an <body> und nicht in
     <main> — deshalb stehen sie hier ausdrücklich mit drin. Beide
     Schreibweisen mit und ohne Leerzeichen, weil beide im Bestand
     vorkommen. */
  html body main [style*="display:flex"],
  html body main [style*="display: flex"],
  html body .bk-modal-overlay [style*="display:flex"],
  html body .bk-modal-overlay [style*="display: flex"] { flex-wrap: wrap; }

  main img, main video, main canvas { max-width: 100%; height: auto; }
  main pre, main code { overflow-x: auto; }

  /* Eine Tabelle lässt sich nicht umbrechen. Sie bekommt stattdessen ihren
     eigenen waagerechten Rollbereich, damit sie die Seite nicht mitzieht.
     `.bk-cardify` ist ausgenommen — solche Tabellen werden ab 920 px
     ohnehin schon zu Karten aufgelöst. */
  main table:not(.bk-cardify) {
    display: block; max-width: 100%;
    overflow-x: auto; -webkit-overflow-scrolling: touch;
  }

  /* ── 2 · Ränder und Schriftgrade ──────────────────────────────────────── */

  .bk-container, .bk-container-wide { padding-left: 12px; padding-right: 12px; }
  /* Die Module setzen den oberen Abstand als Inline-Stil (meist 32 px).
     Am Telefon ist das eine halbe Zeile Inhalt, die niemand sieht. */
  main.bk-container, main.bk-container-wide { padding-top: 14px !important; }

  h1 { font-size: 1.38em; }
  h2 { font-size: 1.12em; }
  h3 { font-size: 1.02em; }

  /* ── 3 · Bedienbar mit Arbeitshandschuhen ─────────────────────────────── */

  .bk-btn { min-height: 44px; }
  .bk-btn--small { min-height: 38px; }
  input.bk-input, select.bk-input, textarea.bk-input, .bk-input,
  main select,
  main input[type="text"], main input[type="search"], main input[type="number"],
  main input[type="date"], main input[type="time"], main input[type="tel"],
  main input[type="email"] {
    min-height: 44px;
    font-size: 16px;   /* alles darunter löst auf iOS das Hineinzoomen aus */
  }
  main textarea.bk-input, main textarea { font-size: 16px; }

  /* ── 4 · Klebende Leisten stapeln sich unter der Modulleiste ──────────── */
  /* --bk-modulleiste setzt shared/bk-app.js (50 px, sobald die Leiste zur
     Schublade geworden ist). Eine Leiste, die bei `top:0` klebt, verschwände
     sonst hinter der Modulleiste: Sie hat z-index 200, die Auswahlleisten
     der Module liegen darunter. */
  html .zo-ausw { top: calc(var(--bk-modulleiste, 0px) + 32px); }

  /* SW-2344: Auf dem Cockpit traegt die Brotkrumen-Leiste nur „Dashboard“ —
     den Namen der Seite, auf der man steht. shared/bk-app.js markiert diesen
     Fall; hier faellt die Leiste weg. Sobald eine Detailansicht etwas
     anhaengt (BkApp.setBreadcrumb), ist die Markierung weg und die Leiste
     wieder da — dort ist sie der Rueckweg und darf nicht fehlen. */
  html #bkBreadcrumb.bk-bc-nur-heim { display: none; }

  /* ── 5 · Dialoge ──────────────────────────────────────────────────────── */
  /* BkApp.modal legt 40 px Rand um das Fenster und deckelt es auf 560–720 px.
     Am Telefon kostet der Rand ein Zehntel der Breite, ohne etwas zu zeigen.
     !important, weil beides als Inline-Stil gesetzt wird. */
  html .bk-modal-overlay { padding: 8px 8px 28px !important; }
  html .bk-modal-overlay > .bk-modal-box { max-width: none !important; }
  html .bk-modal-overlay .modal-foot { flex-wrap: wrap; }
  /* Das Schließen-Kreuz war 30 px — unter dem, was eine Fingerkuppe
     zuverlässig trifft. */
  html #_bkModalCloseBtn { width: 40px !important; height: 40px !important; font-size: 21px !important; }

  /* ── 6 · Kopfzeile ────────────────────────────────────────────────────── */

  .bk-header-inner { padding: 6px 10px !important; gap: 6px !important; row-gap: 4px !important; }
  .bk-header-brand .bk-logo--full img { height: 26px; }
  .bk-header-inner > div[style*="margin-left"] > a,
  .bk-header-inner > div[style*="margin-left"] > button { width: 30px !important; height: 30px !important; }
  /* ══ SW-2342/2343: DIE SUCHE KLAPPT AUF DIE LUPE EIN ═══════════════════

     Sie lag seit SW-607 unter 1024 px in einer eigenen, vollen Zeile. Auf dem
     iPad ist das richtig; am Telefon war sie die dritte Kopfzeile und kostete
     mit ihrem Abstand rund 44 px — dauerhaft, auf jeder Seite, für etwas, das
     man ein paarmal am Tag braucht.

     SW-2342 klappte sie auf eine 42-px-Pille ein. Das reichte nicht: Die
     erste Kopfzeile ist mit Logo, Zeitpille und Profil schon voll, die Pille
     brach also darunter um — gespart war nichts, es stand nur eine fast leere
     Zeile da. Gemeldet wurde außerdem, dass im eingeklappten Zustand „Su“ aus
     dem Platzhalter herausschaute: Das Eingabefeld trägt inline `flex:1`, und
     Flex-Wachstum schlägt jede Breitenangabe. Es braucht `flex: 0 0 0`.

     SW-2343 verlegt sie in die Modulleiste. Dort ist der Platz frei — es
     stehen nur Griff und Modulname darin —, und die Kopfzeile verliert eine
     ganze Zeile. Beim Hineintippen nimmt die Pille die Leiste ein und der
     Modulname tritt zurück (Regel in shared/bk-app.js, wo die Leiste
     beschrieben ist). Kein Umschalter, kein Zustand, der hängen bleiben kann:
     Das Ausfahren hängt an :focus-within, das Einklappen am Verlassen.

     Das Eingabefeld ist eingeklappt null Pixel breit; getroffen wird die
     Hülle. shared/bk-app.js setzt deshalb beim Klick darauf den Schreibkopf
     ins Feld — ohne das führte kein Weg hinein. */

  html #bkModuleNav .bk-mni-leiste #bkGsWrap {
    order: 0 !important;
    flex: 0 0 40px !important;
    width: 40px !important; max-width: 40px !important; min-width: 0 !important;
    height: 40px;
    margin: 0 0 0 auto !important;
    padding: 0 !important;
    justify-content: center;
    background: rgba(255,255,255,0.16) !important;
    border-color: rgba(255,255,255,0.42) !important;
    overflow: hidden;
    transition: flex-basis .18s ease, background .18s ease;
  }
  html #bkModuleNav .bk-mni-leiste #bkGsWrap svg { stroke: #ffffff; }
  html #bkModuleNav .bk-mni-leiste #bkGsWrap #bkGsInput {
    flex: 0 0 0 !important; width: 0 !important; min-width: 0 !important; padding: 0 !important;
  }
  html #bkModuleNav .bk-mni-leiste #bkGsWrap:focus-within {
    flex: 1 1 auto !important;
    width: auto !important; max-width: none !important;
    padding: 0 14px !important;
    background: #ffffff !important; border-color: #ffffff !important;
    justify-content: flex-start;
  }
  html #bkModuleNav .bk-mni-leiste #bkGsWrap:focus-within svg { stroke: #5a6b8c; }
  html #bkModuleNav .bk-mni-leiste #bkGsWrap:focus-within #bkGsInput {
    flex: 1 1 auto !important; width: auto !important; font-size: 16px; color: #1a2a44;
  }

  /* Rückfall: Seiten ohne Modulleiste (der Umzug findet dort kein Ziel).
     Dieselbe Pille, nur eben im Kopf. */
  html #bkGsWrap {
    order: 10 !important;
    flex: 0 0 40px !important;
    width: 40px !important; max-width: 40px !important;
    margin: 0 0 0 8px !important;
    padding: 4px 0 !important;
    justify-content: center;
    overflow: hidden;
  }
  html #bkGsWrap #bkGsInput {
    flex: 0 0 0 !important; width: 0 !important; min-width: 0 !important; padding: 0 !important;
  }
  html #bkGsWrap:focus-within {
    flex: 1 1 100% !important;
    width: auto !important; max-width: none !important;
    margin: 6px 0 0 0 !important;
    padding: 5px 14px !important;
    justify-content: flex-start;
  }
  html #bkGsWrap:focus-within #bkGsInput {
    flex: 1 1 auto !important; width: auto !important; font-size: 16px;
  }

  /* SW-2342: „Abmelden“ steht jetzt im Benutzermenü hinter dem Profilbild
     (shared/bk-app.js). Als eigener Knopf kostete er rund 100 px in einer
     Zeile, die ohnehin zu eng ist — für etwas, das einmal am Tag gebraucht
     wird. Der Menüeintrag ruft denselben Knopf auf; die Prüfung auf
     ausstehende Übertragungen (SW-1942) bleibt an einer Stelle. */
  html #bkSignOut { display: none; }
}

/* Quer gehaltenes Telefon: 852 px breit, aber nur 393 px hoch. Für die Breite
   gilt dort das Schreibtisch-Layout, für die Höhe darf es das nicht — eine
   dreizeilige Modulleiste und 44-px-Knöpfe fressen sonst das halbe Bild. */
@media (max-height: 480px) and (orientation: landscape) {
  main.bk-container, main.bk-container-wide { padding-top: 10px !important; }
  h1 { font-size: 1.3em; }
}

/* SW-2921: Dateityp-Icons PDF / XLSX statt Emoji (📄 📕 📑 📊 📗).
   Quelle bk-ci/icons/ (Lizenz und Bildnachweis: bk-ci/icons/README.md).
   Pfad relativ zu dieser Datei – gilt so für jede Seite, auch das Kundenportal. */
.bk-ico { display: inline-block; flex: none; width: 1.25em; height: 1.25em; vertical-align: -0.28em;
          background: no-repeat center / contain; }
.bk-ico-pdf  { background-image: url("icons/pdf.png"); }
.bk-ico-xlsx { background-image: url("icons/xlsx-128.png"); }
.bk-ico-docx { background-image: url("icons/docx.png"); }          /* SW-3225: Word-Export */
.bk-ico-oeffnen { background-image: url("icons/ordner-oeffnen-128.png"); }   /* SW-2928: Dokument öffnen */
.bk-ico-neu     { background-image: url("icons/dokument-neu.svg"); }        /* SW-2928: neu erzeugen */
.bk-ico-gross { width: 1.6em; height: 1.6em; vertical-align: middle; }
