/* Zwei Looks auf einer Seite (Bauplan: hell = KAVALLERIE, dunkel = BEAST), nur über Variablen.
   Hell: Grund Off-White #F2F4F7 (die KAVALLERIE setzt kein reines Weiß mehr als Seitenfläche ein, Michael 19.11.2026),
   Bedienflächen (Felder, Pillen-Grund, Platzhalter, Dialoge) weiß über --flaeche; sonst Flächen nur Rot #FF003C,
   Rot nie als Textfarbe, keine Karten, keine Schatten.
   Dunkel: Near-Black, warmes Off-White, Gelb als Akzent.
   Leitsatz: Eckig ist Inhalt, rund ist Bedienung (Pillen-Knöpfe, runde Kürzel, eckige Listen und Dialoge).
   Linienraster: 2 px für Kopf und Spalten, 1 px für Abschnitte, leise 1 px zwischen Zeilen.
   Schriften: Webfonts in /schriften/ (README dort). Hell: PP Formula Condensed und Helvetica Now Display aus den
   DK-Schnitten der Agentur (Web-Lizenz wird laut Michael am 19.11.2026 besorgt). Dunkel: Inter (OFL). */

@font-face {
  font-family: "PP Formula Condensed";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("/schriften/pp-formula-condensed-700.woff2") format("woff2");
}
@font-face {
  font-family: "PP Formula Condensed";
  font-style: normal;
  font-weight: 900;
  font-display: swap;
  src: url("/schriften/pp-formula-condensed-900.woff2") format("woff2");
}
@font-face {
  font-family: "Helvetica Now Display";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/schriften/helvetica-now-display-400.woff2") format("woff2");
}
@font-face {
  font-family: "Helvetica Now Display";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/schriften/helvetica-now-display-500.woff2") format("woff2");
}
@font-face {
  font-family: "Helvetica Now Display";
  font-style: normal;
  font-weight: 600 700;
  font-display: swap;
  src: url("/schriften/helvetica-now-display-700.woff2") format("woff2");
}
@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/schriften/inter-latin-ext-400-normal.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, 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: "Inter";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/schriften/inter-latin-400-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/schriften/inter-latin-ext-500-normal.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, 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: "Inter";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/schriften/inter-latin-500-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/schriften/inter-latin-ext-600-normal.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, 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: "Inter";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/schriften/inter-latin-600-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 700 900;
  font-display: swap;
  src: url("/schriften/inter-latin-ext-700-normal.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, 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: "Inter";
  font-style: normal;
  font-weight: 700 900;
  font-display: swap;
  src: url("/schriften/inter-latin-700-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root,
:root[data-darstellung="hell"] {
  --grund: #F2F4F7;
  --flaeche: #FFFFFF;
  --text: #1D1D1D;
  --text-leise: #5A5F66;
  --kopf-flaeche: #FF003C;
  --kopf-text: #FFFFFF;
  --haupt-flaeche: #FF003C;
  --haupt-text: #FFFFFF;
  --zweit-flaeche: #1D1D1D;
  --zweit-text: #FFFFFF;
  --linie: #1D1D1D;
  --linie-leise: #E3E6EB;
  --segment-an: #FFFFFF;
  --segment-an-text: #1D1D1D;
  --an-flaeche: #1D1D1D;
  --an-text: #FFFFFF;
  --zahl-flaeche: #FFFFFF;
  --zahl-text: #1D1D1D;
  --punkt: #FF003C;
  --abdunkeln: rgba(29, 29, 29, 0.55);
  --schrift-titel: "PP Formula Condensed", "PP Formula", "Arial Narrow", "Helvetica Neue", Arial, sans-serif;
  --schrift-text: "Helvetica Now Display", "Helvetica Neue", Helvetica, Arial, sans-serif;
  color-scheme: light;
}

:root[data-darstellung="dunkel"] {
  --grund: #0A0A0A;
  --flaeche: #0A0A0A;
  --text: #EDEBE4;
  --text-leise: #9A978F;
  --kopf-flaeche: #161616;
  --kopf-text: #EDEBE4;
  --haupt-flaeche: #FFFF00;
  --haupt-text: #0A0A0A;
  --zweit-flaeche: #EDEBE4;
  --zweit-text: #0A0A0A;
  --linie: #EDEBE4;
  --linie-leise: #2A2A2A;
  --segment-an: #FFFF00;
  --segment-an-text: #0A0A0A;
  --an-flaeche: #FFFF00;
  --an-text: #0A0A0A;
  --zahl-flaeche: #FFFF00;
  --zahl-text: #0A0A0A;
  --punkt: #FFFF00;
  --abdunkeln: rgba(0, 0, 0, 0.7);
  --schrift-titel: "Inter", "Helvetica Neue", Arial, sans-serif;
  --schrift-text: "Inter", "Helvetica Neue", Arial, sans-serif;
  color-scheme: dark;
}

/* Vor der Anmeldung folgt die Seite dem System */
@media (prefers-color-scheme: dark) {
  :root:not([data-darstellung]) {
    --grund: #0A0A0A;
    --flaeche: #0A0A0A;
    --text: #EDEBE4;
    --text-leise: #9A978F;
    --kopf-flaeche: #161616;
    --kopf-text: #EDEBE4;
    --haupt-flaeche: #FFFF00;
    --haupt-text: #0A0A0A;
    --zweit-flaeche: #EDEBE4;
    --zweit-text: #0A0A0A;
    --linie: #EDEBE4;
    --linie-leise: #2A2A2A;
    --segment-an: #FFFF00;
    --segment-an-text: #0A0A0A;
    --an-flaeche: #FFFF00;
    --an-text: #0A0A0A;
    --zahl-flaeche: #FFFF00;
    --zahl-text: #0A0A0A;
    --punkt: #FFFF00;
    --abdunkeln: rgba(0, 0, 0, 0.7);
    --schrift-titel: "Inter", "Helvetica Neue", Arial, sans-serif;
    --schrift-text: "Inter", "Helvetica Neue", Arial, sans-serif;
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }

html, body { margin: 0; }

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--grund);
  color: var(--text);
  font-family: var(--schrift-text);
  font-size: 18px;
  line-height: 1.35;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

[hidden] { display: none !important; }

/* ---- Icons: einfarbige Linien (24er-Raster, 2 px, eckige Enden), als Maske in Textfarbe ---- */

.ic {
  display: inline-block;
  flex: none;
  width: 1.15em;
  height: 1.15em;
  vertical-align: -0.22em;
  background: currentColor;
  -webkit-mask: var(--ic) center / contain no-repeat;
  mask: var(--ic) center / contain no-repeat;
}
.ic-suche { --ic: url("/icons/suche.svg"); }
.ic-schloss { --ic: url("/icons/schloss.svg"); }
.ic-schloss-offen { --ic: url("/icons/schloss-offen.svg"); }
.ic-glocke { --ic: url("/icons/glocke.svg"); }
.ic-chevron { --ic: url("/icons/chevron.svg"); }
.ic-kreuz { --ic: url("/icons/kreuz.svg"); }
.ic-aufnehmen { --ic: url("/icons/aufnehmen.svg"); }
.ic-eintreten { --ic: url("/icons/eintreten.svg"); }
.ic-protokoll { --ic: url("/icons/protokoll.svg"); }
.ic-haken { --ic: url("/icons/haken.svg"); }
.ic-warnung { --ic: url("/icons/warnung.svg"); }
.ic-verwaltung { --ic: url("/icons/verwaltung.svg"); }
.ic-sonne { --ic: url("/icons/sonne.svg"); }
.ic-mond { --ic: url("/icons/mond.svg"); }

/* ---- Kopf ------------------------------------------------------------------------------- */

.kopf {
  background: var(--kopf-flaeche);
  color: var(--kopf-text);
}

.kopf-innen {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
  padding: 14px 24px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 24px;
  min-height: 72px;
}

.marke {
  font-family: var(--schrift-titel);
  font-weight: 900;
  font-size: 22px;
  line-height: 1;
  text-transform: uppercase;
}

.marke-produkt {
  color: inherit;
  text-decoration: none;
  white-space: nowrap;
}
.marke-produkt:focus-visible { outline: 3px solid var(--kopf-text); outline-offset: 4px; }

.bereiche {
  display: flex;
  gap: 4px;
  margin-right: auto;
}

.bereiche a {
  display: inline-flex;
  align-items: center;
  height: 44px;
  padding: 0 18px;
  border: 2px solid transparent;
  border-radius: 59px;
  color: var(--kopf-text);
  font: 700 15px/1 var(--schrift-text);
  text-decoration: none;
}
.bereiche a:hover { border-color: var(--kopf-text); }
.bereiche a[aria-current="page"] {
  background: var(--segment-an);
  border-color: var(--segment-an);
  color: var(--segment-an-text);
}
.bereiche a:focus-visible { outline: 3px solid var(--kopf-text); outline-offset: 2px; }

.kopf-rechts {
  display: flex;
  align-items: center;
  gap: 8px;
}

.kopf-knopf {
  appearance: none;
  position: relative;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 2px solid transparent;
  border-radius: 50%;
  background: transparent;
  color: var(--kopf-text);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font: 700 14px/1 var(--schrift-text);
}
.kopf-knopf:hover,
.kopf-knopf[aria-expanded="true"] { border-color: var(--kopf-text); }
.kopf-knopf:focus-visible { outline: 3px solid var(--kopf-text); outline-offset: 2px; }
.kopf-knopf .ic { width: 22px; height: 22px; }

/* Profilblase: Kürzel im Kreis */
.kuerzel {
  border-color: var(--kopf-text);
}
.kuerzel[aria-expanded="true"] {
  background: var(--segment-an);
  border-color: var(--segment-an);
  color: var(--segment-an-text);
}

.glocke-zahl {
  position: absolute;
  top: -4px;
  right: -6px;
  min-width: 22px;
  height: 22px;
  padding: 0 6px;
  border-radius: 11px;
  background: var(--zahl-flaeche);
  color: var(--zahl-text);
  border: 2px solid var(--kopf-flaeche);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font: 700 12px/1 var(--schrift-text);
}

/* Aufgeklappte Felder unter dem Kopf: eckig, Linie, keine Schatten */
.aufklapp {
  position: absolute;
  top: calc(100% - 6px);
  right: 24px;
  z-index: 30;
  width: 420px;
  max-width: calc(100vw - 32px);
  max-height: min(72vh, 680px);
  overflow: auto;
  background: var(--flaeche);
  color: var(--text);
  border: 2px solid var(--linie);
  font-size: 16px;
}

.aufklapp-kopf {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 60px;
  padding: 8px 20px;
  border-bottom: 2px solid var(--linie);
}

.aufklapp-titel {
  margin: 0;
  font: 900 22px/1 var(--schrift-titel);
  text-transform: uppercase;
}

.aufklapp-leer { padding: 16px 20px; }

.aufklapp-profil { width: 340px; }

.profil-kopf {
  padding: 18px 20px 16px;
  border-bottom: 2px solid var(--linie);
}
.profil-name { margin: 0 0 4px; font-weight: 700; font-size: 18px; }
.profil-zusatz { margin: 0; color: var(--text-leise); font-size: 15px; overflow-wrap: anywhere; }

.profil-zeile {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 64px;
  padding: 10px 20px;
}
.profil-zeile + .profil-zeile { border-top: 1px solid var(--linie-leise); }
.profil-zeile .knopf { width: 100%; }

/* ---- Fläche vor der Anmeldung (Stufe 0) -------------------------------------------------- */

.flaeche {
  flex: 1;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 72px 24px;
}

.block { max-width: 760px; }

.label {
  margin: 0 0 12px;
  font-family: var(--schrift-titel);
  font-weight: 900;
  font-size: 24px;
  line-height: 1;
  text-transform: uppercase;
}

.label-mit-icon {
  display: flex;
  align-items: center;
  gap: 10px;
}

.titel {
  margin: 0 0 24px;
  font-family: var(--schrift-titel);
  font-weight: 900;
  font-size: clamp(56px, 11vw, 120px);
  line-height: 1;
  text-transform: uppercase;
  overflow-wrap: break-word;
}

.zeile {
  margin: 0 0 32px;
  font-size: 22px;
  line-height: 1.25;
  max-width: 34ch;
}

.pille {
  appearance: none;
  border: 0;
  border-radius: 59px;
  height: 56px;
  padding: 0 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font: 700 18px/1 var(--schrift-text);
  cursor: pointer;
}

.pille:disabled { opacity: 0.45; cursor: not-allowed; background: transparent; color: var(--text); box-shadow: inset 0 0 0 2px var(--text); }

.pille-haupt { background: var(--haupt-flaeche); color: var(--haupt-text); }
.pille-zweit { background: var(--zweit-flaeche); color: var(--zweit-text); }

.pille:focus-visible { outline: 3px solid var(--text); outline-offset: 3px; }

.hinweis {
  margin: 20px 0 0;
  color: var(--text-leise);
  font-size: 16px;
  max-width: 46ch;
}

.fuss {
  border-top: 1px solid var(--linie-leise);
  padding: 16px 24px;
  font-size: 14px;
  color: var(--text-leise);
  text-align: center;
}

/* ---- Bedienung: Knöpfe, Segment-Pillen, Felder ------------------------------------------ */

.knopf {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 44px;
  padding: 0 20px;
  border: 2px solid transparent;
  border-radius: 59px;
  background: transparent;
  color: var(--text);
  font: 700 15px/1 var(--schrift-text);
  white-space: nowrap;
  text-decoration: none;
  cursor: pointer;
}
.knopf .ic { width: 18px; height: 18px; }
.knopf:focus-visible { outline: 3px solid var(--text); outline-offset: 2px; }
.knopf:disabled { opacity: 0.45; cursor: not-allowed; }

.knopf-haupt { background: var(--haupt-flaeche); border-color: var(--haupt-flaeche); color: var(--haupt-text); }
/* Gesperrt nie als blasses Rot (Flächen nur Rot oder Weiß): dann als Umriss */
.knopf-haupt:disabled,
.knopf-zweit:disabled { background: transparent; border-color: var(--text); color: var(--text); }
.knopf-zweit { background: var(--zweit-flaeche); border-color: var(--zweit-flaeche); color: var(--zweit-text); }
.knopf-rand { border-color: var(--text); }
.knopf-rand:hover:not(:disabled),
.knopf-rand[aria-expanded="true"] { background: var(--an-flaeche); border-color: var(--an-flaeche); color: var(--an-text); }

.knopf-klein { height: 40px; padding: 0 16px; font-size: 14px; }

.knopf-pfeil { transition: transform 0.15s ease; }
.knopf-pfeil.ist-offen { transform: rotate(180deg); }

.textknopf {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--text);
  min-height: 44px;
  padding: 0;
  font: 700 14px/1 var(--schrift-text);
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
}
.textknopf:focus-visible { outline: 3px solid var(--text); outline-offset: 2px; }

.rund-knopf {
  appearance: none;
  flex: none;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 2px solid var(--text);
  border-radius: 50%;
  background: transparent;
  color: var(--text);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.rund-knopf .ic { width: 20px; height: 20px; }
.rund-knopf:hover { background: var(--an-flaeche); border-color: var(--an-flaeche); color: var(--an-text); }
.rund-knopf:focus-visible { outline: 3px solid var(--text); outline-offset: 2px; }

/* Segment-Pille im Inhalt (eine Wahl aus wenigen Werten) */
.wahl {
  display: inline-flex;
  flex: none;
  height: 40px;
  padding: 2px;
  border: 2px solid var(--text);
  border-radius: 59px;
}
.wahl button {
  appearance: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 32px;
  padding: 0 14px;
  border: 0;
  border-radius: 59px;
  background: transparent;
  color: var(--text);
  font: 600 14px/1 var(--schrift-text);
  white-space: nowrap;
  cursor: pointer;
}
.wahl button .ic { width: 16px; height: 16px; }
.wahl button[aria-pressed="true"] { background: var(--an-flaeche); color: var(--an-text); font-weight: 700; }
.wahl button:focus-visible { outline: 3px solid var(--text); outline-offset: 1px; }
.wahl button:disabled { opacity: 0.45; cursor: not-allowed; }

/* Suchfeld: rund (Bedienung) */
.suchfeld {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 48px;
  padding: 0 18px;
  border: 2px solid var(--text);
  border-radius: 59px;
  background: var(--flaeche);
  color: var(--text);
  cursor: text;
}
.suchfeld .ic { width: 20px; height: 20px; }
.suchfeld:focus-within { outline: 3px solid var(--text); outline-offset: 2px; }
.suchfeld-eingabe {
  flex: 1;
  min-width: 0;
  height: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--text);
  font: 400 17px/1.2 var(--schrift-text);
  outline: none;
}
.suchfeld-eingabe::placeholder { color: var(--text-leise); opacity: 1; }

/* Notiz: eckig (Inhalt) */
.notizfeld {
  display: block;
  width: 100%;
  min-height: 104px;
  padding: 12px 14px;
  border: 2px solid var(--text);
  border-radius: 0;
  background: var(--flaeche);
  color: var(--text);
  font: 400 17px/1.4 var(--schrift-text);
  resize: vertical;
}
.notizfeld:focus-visible { outline: 3px solid var(--text); outline-offset: 2px; }
.notizfeld::placeholder { color: var(--text-leise); opacity: 1; }

.kuerzel-feld {
  width: 88px;
  height: 40px;
  padding: 0 12px;
  border: 2px solid var(--text);
  border-radius: 59px;
  background: var(--flaeche);
  color: var(--text);
  font: 700 15px/1 var(--schrift-text);
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.kuerzel-feld:focus-visible { outline: 3px solid var(--text); outline-offset: 2px; }

/* Runder Haken zum Auswählen von Personen */
.haken-feld {
  appearance: none;
  flex: none;
  width: 24px;
  height: 24px;
  margin: 0;
  border: 2px solid var(--text);
  border-radius: 50%;
  background: var(--flaeche);
  cursor: pointer;
}
.haken-feld:checked { background: var(--text); box-shadow: inset 0 0 0 4px var(--flaeche); }
.haken-feld:disabled { cursor: default; }
.haken-feld:focus-visible { outline: 3px solid var(--text); outline-offset: 2px; }

.knopfreihe {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.knopfreihe-zwischen { justify-content: space-between; }

/* ---- Kürzelblasen ----------------------------------------------------------------------- */

.blase {
  flex: none;
  width: 36px;
  height: 36px;
  border: 2px solid var(--text);
  border-radius: 50%;
  background: var(--flaeche);
  color: var(--text);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font: 700 12px/1 var(--schrift-text);
  letter-spacing: 0.02em;
}
.blase-ich { background: var(--an-flaeche); border-color: var(--an-flaeche); color: var(--an-text); }
.blase-klein { width: 30px; height: 30px; font-size: 11px; }
.blase-rest { font-weight: 600; }

.blasen { display: inline-flex; align-items: center; }
.blasen > .blase + .blase { margin-left: -8px; }

/* ---- Gerüst der Seiten ------------------------------------------------------------------ */

.app {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.innen {
  width: 100%;
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 24px;
  padding-right: 24px;
}

.seite { padding-top: 40px; padding-bottom: 64px; }

.seitenkopf {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px 24px;
  padding-bottom: 20px;
  border-bottom: 2px solid var(--linie);
}

.seitentitel {
  margin: 0;
  font: 900 40px/1 var(--schrift-titel);
  text-transform: uppercase;
}

.seitenkopf .suchfeld {
  flex: 0 1 420px;
  margin-left: auto;
}

.abgleich {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  padding: 12px 0;
  color: var(--text-leise);
  font-size: 15px;
}
.abgleich.ist-warnung { color: var(--text); align-items: flex-start; }
.abgleich.ist-warnung .ic { margin-top: 1px; }

.leer {
  margin: 0;
  padding: 8px 0 16px;
  color: var(--text-leise);
  font-size: 16px;
}

/* ---- Raumwahl --------------------------------------------------------------------------- */

.abschnitt {
  padding: 24px 0 8px;
  border-top: 1px solid var(--linie);
}

.abschnitt-kopf {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin-bottom: 8px;
}

.abschnitt-titel {
  margin: 0;
  font: 900 24px/1 var(--schrift-titel);
  text-transform: uppercase;
}

.abschnitt-zahl {
  color: var(--text-leise);
  font-size: 15px;
}

.raumliste {
  list-style: none;
  margin: 0;
  padding: 0;
}
.raumliste > li + li > .raumzeile { border-top: 1px solid var(--linie-leise); }

.raumzeile {
  display: grid;
  grid-template-columns: 9.5em minmax(0, 1fr) auto;
  align-items: center;
  gap: 4px 24px;
  min-height: 68px;
  padding: 12px 0;
  color: inherit;
  text-decoration: none;
}
.raumzeile:hover .raum-name { text-decoration: underline; text-underline-offset: 3px; }
.raumzeile:focus-visible { outline: 3px solid var(--text); outline-offset: 2px; }

.raum-nummer {
  font-size: 15px;
  font-weight: 700;
}

.raum-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.raum-name { font-size: 18px; font-weight: 700; overflow-wrap: anywhere; }
.raum-kunde { color: var(--text-leise); font-size: 15px; }

.raum-rechts {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 8px 16px;
}

.zustand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 15px;
}
.zustand .ic { width: 18px; height: 18px; }

/* ---- Raum: Leiste oben im Arbeitsbereich ------------------------------------------------- */

.raumleiste { border-bottom: 2px solid var(--linie); }

.raumleiste-innen {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 16px;
  min-height: 72px;
  padding-top: 12px;
  padding-bottom: 12px;
}

/* Knöpfe der Leiste etwas schmaler, damit Titel, Zustand und Handlungen auf eine Zeile passen */
.raumleiste .knopf { padding: 0 16px; font-size: 14px; }

.raumleiste-titel {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 4px 10px;
  min-width: 0;
  min-height: 44px;
  color: inherit;
  text-decoration: none;
}
.raumleiste-titel:hover .raumleiste-name { text-decoration: underline; text-underline-offset: 3px; }
.raumleiste-titel:focus-visible { outline: 3px solid var(--text); outline-offset: 2px; }
.raumleiste-vorsatz,
.raumleiste-nummer { color: var(--text-leise); font-size: 16px; }
.raumleiste-name { font-size: 19px; font-weight: 700; overflow-wrap: anywhere; }
.raumleiste-pfeil { width: 18px; height: 18px; }

.raumleiste-mitte {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 20px;
  flex: 1 1 auto;
}

.mitwirkende {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text-leise);
  font-size: 15px;
}

/* Ohne margin-left: Auf einer Zeile schiebt die wachsende Mitte die Handlungen nach rechts,
   umgebrochen stehen sie links bündig unter dem Titel. */
.raumleiste-aktionen {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

/* Aufgeklappte Bereiche unter der Leiste */
.raum-bereich { border-bottom: 1px solid var(--linie); }
.raum-bereich > .innen { padding-top: 20px; padding-bottom: 12px; }

.bereich-kopf {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 6px 16px;
  margin-bottom: 8px;
}
.bereich-zusatz { color: var(--text-leise); font-size: 15px; }

.zeilenliste {
  list-style: none;
  margin: 0;
  padding: 0;
}

.listenzeile {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 64px;
  padding: 10px 0;
  border-top: 1px solid var(--linie-leise);
}

.listen-wer {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1 1 auto;
  min-width: 0;
}
.listen-name { font-weight: 700; }
.listen-text { font-size: 17px; }
.listen-zusatz { color: var(--text-leise); font-size: 14px; }
.als-verwaltung { font-weight: 700; }

.notiz {
  font-size: 16px;
  overflow-wrap: anywhere;
}

.anfrage-zeile { flex-wrap: wrap; }
.anfrage-zeile .listen-wer { flex: 1 1 240px; }

/* Inhalt des Raums (ab Stufe 2: Bilder, Videos, Stile) */
.raum-inhalt { padding-top: 48px; padding-bottom: 64px; }

.raum-gross {
  margin: 0 0 20px;
  font: 900 clamp(44px, 8vw, 104px)/1 var(--schrift-titel);
  text-transform: uppercase;
  overflow-wrap: anywhere;
  hyphens: auto;
}

/* Außenansicht eines geschlossenen Raums */
.aussen { padding-top: 48px; padding-bottom: 64px; }
.aussen > * { max-width: 760px; }

.titel-mittel {
  margin: 0 0 20px;
  font: 900 clamp(40px, 7vw, 80px)/1 var(--schrift-titel);
  text-transform: uppercase;
  overflow-wrap: break-word;
}

.aussen .zeile { margin-bottom: 0; max-width: 40ch; }

.aussen-block {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 32px;
  padding-top: 24px;
  border-top: 1px solid var(--linie);
}

.feld-titel {
  margin: 0;
  font-weight: 700;
  font-size: 17px;
}
.leise { color: var(--text-leise); font-weight: 400; }

.text { margin: 0; font-size: 17px; max-width: 56ch; }

.zustand-zeile {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  font-size: 17px;
}
.zustand-zeile .ic { width: 22px; height: 22px; }

.zaehler { color: var(--text-leise); font-size: 14px; }

/* ---- Dialoge: eckig, Linien, kein Schatten ----------------------------------------------- */

.dialog {
  width: min(600px, calc(100vw - 32px));
  max-width: none;
  max-height: calc(100dvh - 48px);
  margin: auto;
  padding: 0;
  border: 2px solid var(--linie);
  border-radius: 0;
  background: var(--flaeche);
  color: var(--text);
  font-size: 17px;
}
.dialog[open] { display: flex; flex-direction: column; }
.dialog::backdrop { background: var(--abdunkeln); }

.dialog-kopf {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 16px 14px 24px;
  border-bottom: 2px solid var(--linie);
}

.dialog-titel {
  margin: 0;
  font: 900 28px/1 var(--schrift-titel);
  text-transform: uppercase;
}

.dialog-koerper {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
  padding: 20px 24px 8px;
}

.dialog-text { margin: 0 0 16px; max-width: 52ch; }

.dialog-fehler {
  display: flex;
  gap: 8px;
  margin: 8px 0 12px;
  font-weight: 700;
}

.dialog-fuss {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  padding: 16px 24px;
  border-top: 2px solid var(--linie);
}
.fuss-text {
  margin-right: auto;
  color: var(--text-leise);
  font-size: 15px;
}

/* Personenwahl in den Dialogen */
.wahl-gruppe { padding: 12px 0 8px; border-top: 1px solid var(--linie); }

.wahl-titel {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin: 0 0 8px;
  font: 900 18px/1 var(--schrift-titel);
  text-transform: uppercase;
}
.wahl-hinweis {
  font: 400 14px/1 var(--schrift-text);
  text-transform: none;
  color: var(--text-leise);
}

.wahl-zeile {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 56px;
  padding: 6px 0;
  border-top: 1px solid var(--linie-leise);
  cursor: pointer;
}
.wahl-zeile.ist-fest { cursor: default; }
.wahl-titel + .wahl-zeile,
.wahl-titel + .suchfeld + .wahl-zeile { border-top: 0; }

.wahl-wer { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.wahl-name { font-weight: 700; }
.wahl-zusatz { color: var(--text-leise); font-size: 14px; }

.wahl-gruppe .suchfeld { margin: 4px 0 8px; height: 44px; }

.wahl-treffer {
  max-height: 300px;
  overflow: auto;
}
.wahl-treffer > .wahl-zeile:first-child { border-top: 0; }

/* ---- Meldungen -------------------------------------------------------------------------- */

.meldungsliste {
  list-style: none;
  margin: 0;
  padding: 0;
}

.meldung {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 14px 20px 14px 12px;
  border-top: 1px solid var(--linie-leise);
}
.meldung:first-child { border-top: 0; }

.meldung-punkt {
  flex: none;
  width: 8px;
  height: 8px;
  margin-top: 11px;
  border-radius: 50%;
}
.meldung.ist-neu .meldung-punkt { background: var(--punkt); }

.meldung-inhalt {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
  flex: 1;
}

.meldung-text {
  margin: 0;
  color: inherit;
  text-decoration: none;
  overflow-wrap: anywhere;
}
a.meldung-text:hover { text-decoration: underline; text-underline-offset: 3px; }
a.meldung-text:focus-visible { outline: 3px solid var(--text); outline-offset: 2px; }
.meldung.ist-neu .meldung-text { font-weight: 700; }

.meldung .notiz { margin: 0; font-size: 15px; }
.meldung-zeit,
.meldung-status { margin: 0; color: var(--text-leise); font-size: 14px; }
.meldung-status { font-weight: 700; }
.meldung .knopfreihe { margin-top: 4px; }

.nur-vorlesen {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* ---- Personen (Verwaltung) --------------------------------------------------------------- */

.personen-zahl { margin: 4px 0 0; }

.personenliste {
  list-style: none;
  margin: 8px 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto auto auto;
  column-gap: 20px;
}

.person-zeile {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: subgrid;
  align-items: center;
  row-gap: 10px;
  min-height: 72px;
  padding: 12px 0;
  border-top: 1px solid var(--linie-leise);
}

.personen-spalten {
  min-height: 0;
  padding: 0 0 10px;
  border-top: 0;
  border-bottom: 2px solid var(--linie);
  color: var(--text-leise);
  font-size: 14px;
  font-weight: 700;
}
.personen-spalten + .person-zeile { border-top: 0; }

.person-wer {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}
.person-wer .listen-zusatz { overflow-wrap: anywhere; }

.person-feld {
  display: flex;
  align-items: center;
  gap: 10px;
}
.feld-name { display: none; color: var(--text-leise); font-size: 14px; font-weight: 700; min-width: 4.5em; }

.person-aktionen {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}
.knopf-sperren { min-width: 112px; }

.person-zeile.ist-gesperrt .person-wer { color: var(--text-leise); }
.person-zeile.ist-gesperrt .blase { border-style: dashed; }

.marke-klein {
  display: inline-flex;
  align-items: center;
  height: 22px;
  margin-left: 6px;
  padding: 0 8px;
  border: 1px solid var(--text);
  color: var(--text);
  font-size: 12px;
  font-weight: 700;
  vertical-align: 2px;
}

.zeilen-fehler,
.person-protokoll { grid-column: 1 / -1; }

.zeilen-fehler {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  font-weight: 700;
  font-size: 15px;
}

.person-protokoll {
  margin-left: 50px;
  padding-top: 4px;
}

/* ---- Hinweis unten ---------------------------------------------------------------------- */

.hinweis-leiste {
  position: fixed;
  left: 50%;
  bottom: 24px;
  z-index: 60;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 10px;
  width: max-content;
  max-width: calc(100vw - 32px);
  padding: 14px 20px;
  border: 2px solid var(--linie);
  background: var(--flaeche);
  color: var(--text);
  font-size: 16px;
  font-weight: 600;
}
.hinweis-leiste .ic { width: 20px; height: 20px; }

/* ---- Schmale Fenster ------------------------------------------------------------------- */

@media (max-width: 1000px) {
  .personenliste { display: block; }
  .person-zeile {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px 20px;
  }
  .personen-spalten { display: none; }
  .personen-spalten + .person-zeile { border-top: 1px solid var(--linie-leise); }
  .person-wer { flex: 1 1 100%; }
  .feld-name { display: inline; }
  .person-aktionen { flex: 1 1 auto; justify-content: flex-start; }
  .zeilen-fehler,
  .person-protokoll { flex: 1 1 100%; }
}

@media (max-width: 760px) {
  .raumzeile { grid-template-columns: minmax(0, 1fr); gap: 4px; }
  .raum-rechts { justify-content: flex-start; }
  .raumleiste-aktionen { width: 100%; }
  .raumleiste-aktionen .knopf,
  .raumleiste-mitte .knopf { flex: 1 1 auto; }
}

@media (max-width: 600px) {
  .kopf-innen { padding: 12px 16px; min-height: 64px; gap: 10px 12px; }
  .marke { font-size: 15px; }
  #marke span { display: block; white-space: nowrap; }
  .marke-produkt { font-size: 20px; }
  .bereiche { order: 3; flex: 1 1 100%; margin-right: 0; }
  .bereiche a { height: 40px; padding: 0 16px; }
  .aufklapp { right: 16px; left: 16px; width: auto; max-width: none; }
  .flaeche { padding: 48px 16px; }
  .zeile { font-size: 19px; }
  .pille { width: 100%; }
  .innen { padding-left: 16px; padding-right: 16px; }
  .seite { padding-top: 28px; }
  .seitentitel { font-size: 34px; }
  .seitenkopf .suchfeld { flex: 1 1 100%; margin-left: 0; }
  .raum-inhalt,
  .aussen { padding-top: 32px; }
  .dialog {
    width: 100vw;
    height: 100dvh;
    max-height: 100dvh;
    border: 0;
  }
  .dialog-kopf { padding: 10px 12px 10px 16px; }
  .dialog-koerper { padding: 16px 16px 8px; }
  .dialog-fuss { padding: 12px 16px; }
  .dialog-fuss .fuss-text { flex: 1 1 100%; }
  .dialog-fuss .knopf { flex: 1 1 0; }
  .knopfreihe-zwischen .knopf { flex: 1 1 100%; }
  .aussen-block .knopfreihe .knopf { flex: 1 1 100%; }
  .person-protokoll { margin-left: 0; }
  .hinweis-leiste { bottom: 16px; width: calc(100vw - 32px); }
}
