:root {
  --bg: #f4f5f7;
  --col-bg: #ebedf2;
  --row: #ffffff;
  --row-fade: rgba(255, 255, 255, 0);
  --text: #1f2430;
  --muted: #828a9c;
  --line: #e3e6ee;
  --accent: #4f63d2;
  --accent-soft: #eef1fc;
  --green: #2f9e69;
  --red: #d6453d;
  --orange: #d98410;
  --yellow: #e0a72c;
  --hover: rgba(0, 0, 0, .06);
  --chip: rgba(0, 0, 0, .06);
  --del-soft: #fbe3e1;
  --check-border: #c4cad8;
  color-scheme: light;
}

:root[data-theme="dark"] {
  --bg: #15171c;
  --col-bg: #1d2026;
  --row: #262a31;
  --row-fade: rgba(38, 42, 49, 0);
  --text: #e6e8ee;
  --muted: #8b93a5;
  --line: #333842;
  --accent: #7e8ff2;
  --accent-soft: #2b3350;
  --green: #46b27e;
  --red: #e5615a;
  --orange: #e0a23e;
  --yellow: #e8bb4e;
  --hover: rgba(255, 255, 255, .08);
  --chip: rgba(255, 255, 255, .10);
  --del-soft: #4a2522;
  --check-border: #4a5160;
  color-scheme: dark;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Segoe UI", system-ui, -apple-system, Roboto, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.4;
  transition: background .2s, color .2s;
}

.app {
  max-width: 1900px;
  margin: 0 auto;
  padding: 24px 26px 56px;
  padding-top: max(24px, env(safe-area-inset-top));
  padding-left: max(26px, env(safe-area-inset-left));
  padding-right: max(26px, env(safe-area-inset-right));
  padding-bottom: max(56px, env(safe-area-inset-bottom));
}

/* ---------- Kopf ---------- */
.topbar {
  position: relative;   /* Anker fuer das Umschalter-Menue am Titel */
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 18px;
}
.topbar h1 {
  font-size: 24px;
  margin: 0;
  font-weight: 700;
  letter-spacing: -.3px;
}
.save-status {
  font-size: 13.5px;
  color: var(--muted);
  margin-left: 6px;
}
.save-status.ok { color: var(--green); }
.save-status.err { color: var(--red); }

.btn {
  border: 1px solid var(--line);
  background: var(--row);
  color: var(--text);
  padding: 7px 13px;
  border-radius: 9px;
  font-size: 14px;
  font-family: inherit;
  font-weight: 600;
  cursor: pointer;
  transition: all .15s;
  white-space: nowrap;
}
.btn:hover { border-color: var(--accent); color: var(--accent); }
.btn.primary {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}
.btn.primary:hover { filter: brightness(1.06); color: #fff; }
.btn.add-cat {
  color: var(--muted);
  background: transparent;
  border-color: transparent;
}
.btn.add-cat:hover { color: var(--accent); background: var(--row); border-color: var(--line); }
.btn.icon-only { padding: 7px 10px; font-size: 16px; line-height: 1; }
#themeBtn {
  position: fixed;
  top: max(16px, env(safe-area-inset-top));
  right: max(16px, env(safe-area-inset-right));
  z-index: 30;
}
/* Links neben dem Design-Schalter. 42px = dessen Breite plus Abstand. */
#einstellungenBtn {
  position: fixed;
  top: max(16px, env(safe-area-inset-top));
  right: calc(max(16px, env(safe-area-inset-right)) + 42px);
  z-index: 30;
}
#einstellungenBtn[hidden] { display: none; }

input[type="text"],
input[type="date"] {
  border: 1px solid var(--line);
  background: var(--row);
  color: var(--text);
  padding: 8px 10px;
  border-radius: 8px;
  font-size: 15px;
  font-family: inherit;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
input[type="text"]:focus,
input[type="date"]:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

/* ---------- Board / Spalten ---------- */
.board {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 16px;
  align-items: flex-start;
}

.column {
  flex: 1 1 280px;
  min-width: 250px;
  max-width: 560px;
  background: var(--col-bg);
  border-radius: 12px;
  padding: 9px;
  display: flex;
  flex-direction: column;
  gap: 7px;
  transition: outline-color .12s, background .12s;
  outline: 2px solid transparent;
  outline-offset: -2px;
}
.column.drop-target {
  background: var(--accent-soft);
  outline-color: var(--accent);
  outline-style: dashed;
}

.col-head {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 2px 4px 0;
}
.col-title {
  font-size: 16px;
  font-weight: 700;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
  cursor: grab;
}
.col-title:active { cursor: grabbing; }
.col-title .name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.column.col-dragging { opacity: .5; }
/* Ampel: grau ohne offene ToDos, blau mit offenen, rot wenn etwas draengt. */
.col-count {
  font-size: 12.5px;
  font-weight: 700;
  border-radius: 999px;
  padding: 0 7px;
  flex: none;
  transition: background .15s, color .15s;
}
.col-count.zero   { color: var(--muted);  background: var(--chip); }
.col-count.normal { color: var(--accent); background: var(--accent-soft); }
.col-count.urgent { color: var(--red);    background: var(--del-soft); }

/* Bereichsname im Doppelklick-Bearbeitungsmodus */
.cat-edit {
  flex: 1;
  min-width: 0;
  font-size: 16px;
  font-weight: 700;
  font-family: inherit;
  padding: 4px 8px;
  border: 1px solid var(--accent);
  border-radius: 8px;
  background: var(--row);
  color: var(--text);
  outline: none;
  box-shadow: 0 0 0 3px var(--accent-soft);
}
/* Loeschen erscheint nur im Bearbeiten-Modus (Doppelklick auf den Namen). */
.col-actions {
  margin-left: auto;
  display: flex;
  gap: 2px;
  flex: none;
}
.col-actions .act { width: 28px; height: 28px; font-size: 13px; }

/* ---------- Eingabe pro Spalte ---------- */
.col-add-btn {
  width: 100%;
  text-align: left;
  border: 1px dashed transparent;
  background: transparent;
  color: var(--muted);
  font-size: 14.5px;
  font-weight: 600;
  font-family: inherit;
  padding: 6px 8px;
  border-radius: 8px;
  cursor: pointer;
  transition: all .12s;
}
.col-add-btn:hover {
  background: var(--row);
  color: var(--accent);
  border-color: var(--line);
}
.col-add.open { display: flex; flex-direction: column; gap: 6px; }
.add-line { display: flex; gap: 5px; }
.add-line .add-text { flex: 1; min-width: 0; }
.add-icon {
  border: 1px solid var(--line);
  background: var(--row);
  color: var(--muted);
  min-width: 34px;
  height: 36px;
  padding: 0 8px;
  flex: none;
  border-radius: 8px;
  cursor: pointer;
  font-size: 13px;
  font-family: inherit;
  font-weight: 600;
  white-space: nowrap;
  transition: all .12s;
}
.add-icon:hover { border-color: var(--accent); color: var(--accent); }
.add-icon.active { background: var(--accent-soft); border-color: var(--accent); color: var(--accent); }

/* Termin: nur das Kalender-Icon ist sichtbar, es oeffnet den nativen Dialog.
   Das Datumsfeld bleibt im Layout (showPicker braucht ein gerendertes Feld),
   ist aber unsichtbar und nicht anklickbar. */
.date-field { position: relative; flex: none; display: flex; }
.date-field input[type="date"] {
  position: absolute;
  left: 0;
  bottom: 0;
  width: 1px;
  height: 1px;
  padding: 0;
  border: 0;
  opacity: 0;
  pointer-events: none;
}

/* Touch-Geraete: Auf iOS oeffnet showPicker() kein zusammengeschrumpftes Feld,
   ein Tipp auf das Datumsfeld selbst dagegen immer. Deshalb liegt es hier
   unsichtbar ueber dem Icon und faengt den Tipp ab; das Icon ist nur Optik. */
@media (pointer: coarse) {
  .date-field input[type="date"] {
    inset: 0;
    width: 100%;
    height: 100%;
    margin: 0;
    opacity: 0;
    pointer-events: auto;
    -webkit-appearance: none;
    appearance: none;
  }
  .date-field .add-cal { pointer-events: none; }
}
.col-add .add-note {
  width: 100%;
  font-family: inherit;
  font-size: 13px;
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--row);
  color: var(--text);
  resize: vertical;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
.col-add .add-note:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }

/* ---------- ToDo-Liste ---------- */
.todo-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.todo {
  position: relative;
  display: flex;
  align-items: center;
  gap: 9px;
  background: var(--row);
  border: 1px solid var(--line);
  border-left: 4px solid var(--accent);
  border-radius: 8px;
  padding: 9px 11px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, .07);
  transition: border-left-color .15s;
}
/* Streifen-Ampel: blau ohne Termin, gelb mit Termin, rot ab morgen. */
.todo.dated  { border-left-color: var(--yellow); }
.todo.urgent { border-left-color: var(--red); }
.todo[draggable="true"] { cursor: grab; }
.todo.dragging { opacity: .4; }

.check {
  appearance: none;
  -webkit-appearance: none;
  width: 18px;
  height: 18px;
  border: 2px solid var(--check-border);
  border-radius: 5px;
  cursor: pointer;
  flex: none;
  position: relative;
  transition: all .15s;
}
.check:hover { border-color: var(--accent); }
.check:checked { background: var(--green); border-color: var(--green); }
.check:checked::after {
  content: "";
  position: absolute;
  left: 5px; top: 1px;
  width: 4px; height: 9px;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.todo-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 0; cursor: text; }
.todo-text { font-size: 15.5px; line-height: 1.3; word-break: break-word; }

/* Erledigte ToDos bewusst zurueckgenommen: flach, kleiner, gedaempft. */
.todo.is-done {
  background: transparent;
  border-color: transparent;
  border-left-color: transparent;
  box-shadow: none;
  opacity: .65;
  padding-top: 3px;
  padding-bottom: 3px;
}
.todo.is-done:hover { opacity: 1; }
.todo.is-done .todo-text { text-decoration: line-through; color: var(--muted); font-size: 14px; }
.todo.is-done .check { width: 16px; height: 16px; }
.todo.is-done .check:checked { background: var(--muted); border-color: var(--muted); }
.todo.is-done .check:checked::after { left: 4px; top: 1px; height: 8px; }
.todo.is-done .actions { background: var(--col-bg); padding-left: 12px; }

.todo-note {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.35;
  margin-top: 3px;
  white-space: pre-wrap;
  word-break: break-word;
}

.due {
  font-size: 12.5px;
  color: var(--muted);
  font-weight: 600;
  margin-top: 1px;
}
.due.overdue { color: var(--red); }
.due.today { color: var(--orange); }

/* Zeilen-Aktionen: nur beim Hovern, ueberlagern rechts (kein Layout-Sprung) */
.actions {
  position: absolute;
  right: 4px;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  gap: 1px;
  opacity: 0;
  pointer-events: none;
  transition: opacity .12s;
  padding-left: 22px;
  background: linear-gradient(to right, var(--row-fade) 0, var(--row) 24%);
}
.todo:hover .actions { opacity: 1; pointer-events: auto; }
.act {
  border: none;
  background: transparent;
  color: var(--muted);
  width: 28px; height: 28px;
  border-radius: 7px;
  cursor: pointer;
  font-size: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all .12s;
}
.act:hover { background: var(--hover); color: var(--text); }
.act.del:hover { background: var(--del-soft); color: var(--red); }

/* Inline-Bearbeiten */
.edit-row { display: flex; flex-direction: column; gap: 6px; flex: 1; min-width: 0; }
.edit-row .edit-buttons { display: flex; align-items: center; gap: 6px; }
.edit-row input[type="text"] { width: 100%; }
.edit-row .btn { padding: 6px 11px; font-size: 13px; margin-left: auto; }
.edit-row .btn + .btn { margin-left: 0; }
.edit-row .add-icon { height: 32px; }
.edit-row textarea {
  width: 100%;
  font-family: inherit;
  font-size: 13px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--row);
  color: var(--text);
  resize: vertical;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
.edit-row textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }

/* Erledigt-Bereich */
.done-section { display: flex; flex-direction: column; gap: 4px; }
.done-head { display: flex; align-items: center; gap: 4px; }
.done-toggle {
  flex: 1;
  border: none;
  background: transparent;
  color: var(--muted);
  font-size: 11.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .5px;
  cursor: pointer;
  padding: 6px 4px 2px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.done-toggle:hover { color: var(--text); }
.done-toggle .arrow { transition: transform .15s; display: inline-block; font-size: 10px; }
.done-toggle.collapsed .arrow { transform: rotate(-90deg); }

.empty {
  color: var(--muted);
  font-size: 12.5px;
  padding: 3px 6px;
  margin: 0;
}
.board > .empty { width: 100%; text-align: center; padding: 30px; }

/* ---------- Sperrbildschirm ---------- */
.lock {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg);
}
.lock.hidden { display: none; }
.lock-box {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: min(320px, 90vw);
  padding: 28px 24px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--row);
  text-align: center;
}
/* display:flex oben schlaegt sonst das eingebaute [hidden] des Browsers -
   der Bestaetigungskasten waere immer sichtbar. */
.lock-box[hidden] { display: none; }
.lock-icon { font-size: 32px; line-height: 1; }
/* Gruener Haken als Kreis statt Emoji: sieht auf allen Systemen gleich aus
   und traegt die Bestaetigung deutlicher als ein Zeichen in Textgroesse. */
.lock-haken {
  align-self: center;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: var(--green);
  color: #fff;
  font-size: 26px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}
.lock-box h2 { margin: 0; font-size: 18px; }
.lock-hint { margin: 0; font-size: 12.5px; color: var(--muted); }
.lock-box input {
  border: 1px solid var(--line);
  background: var(--bg);
  color: var(--text);
  padding: 10px 12px;
  border-radius: 10px;
  font: inherit;
  text-align: center;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
.lock-box input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}
.lock-box button {
  padding: 10px 12px;
  border: 0;
  border-radius: 10px;
  background: var(--accent);
  color: #fff;
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}
.lock-box button:hover { filter: brightness(1.06); }
.lock-msg { min-height: 1.2em; font-size: 12.5px; color: var(--red); }
.lock-msg.ok { color: var(--green); }
/* Umschalter zwischen Anmelden und Warteliste - sieht aus wie ein Link,
   ist aber ein Knopf (Tastaturbedienung, kein Ziel-Dokument).
   Mit .lock-box davor, sonst gewinnt die allgemeinere Regel
   ".lock-box button" und macht daraus einen blauen Hauptknopf. */
.lock-box .lock-link {
  background: none;
  border: 0;
  padding: 4px;
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  text-decoration: underline;
  cursor: pointer;
}
.lock-box .lock-link:hover { color: var(--accent); }
.lock-box .lock-link[hidden] { display: none; }

/* Rückgängig-Hinweis */
.snackbar {
  position: fixed;
  left: 50%;
  bottom: 24px;
  transform: translateX(-50%) translateY(20px);
  background: #2b2f37;
  color: #fff;
  padding: 11px 16px;
  border-radius: 11px;
  display: flex;
  align-items: center;
  gap: 16px;
  box-shadow: 0 8px 28px rgba(0, 0, 0, .28);
  font-size: 14px;
  opacity: 0;
  pointer-events: none;
  transition: opacity .18s, transform .18s;
  z-index: 50;
}
.snackbar.show { opacity: 1; transform: translateX(-50%) translateY(0); pointer-events: auto; }
.snack-undo {
  border: none;
  background: transparent;
  color: #8ea2ff;
  font-weight: 700;
  font-size: 14px;
  font-family: inherit;
  cursor: pointer;
  padding: 0;
}
.snack-undo:hover { text-decoration: underline; }

/* ---------- Verwaltung (admin.html) ---------- */
.admin-block { margin-bottom: 30px; }
.admin-block h2 {
  font-size: 15px;
  margin: 0 0 10px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.admin-block h2 .zahl {
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
  background: var(--accent-soft);
  border-radius: 20px;
  padding: 1px 8px;
}
.admin-liste { display: flex; flex-direction: column; gap: 8px; }
.admin-zeile {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  border: 1px solid var(--line);
  background: var(--row);
  border-radius: 11px;
  padding: 12px 14px;
}
.admin-name { font-weight: 600; font-size: 14.5px; }
.admin-meta { font-size: 12.5px; color: var(--muted); margin-top: 2px; word-break: break-all; }
.admin-aktionen { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.admin-leer { color: var(--muted); font-size: 13.5px; margin: 2px 0; }
.admin-hinweis {
  border: 1px solid var(--line);
  background: var(--row);
  border-radius: 12px;
  padding: 22px;
  text-align: center;
}
.admin-hinweis p { margin: 0 0 14px; color: var(--muted); font-size: 14px; }
.admin-hinweis[hidden], #inhalt[hidden] { display: none; }

.btn.primaer { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn.primaer:hover { filter: brightness(1.06); }
.btn.still { color: var(--muted); }

.admin-marke {
  font-size: 12px;
  font-weight: 600;
  border-radius: 20px;
  padding: 3px 10px;
}
.admin-marke.gut      { background: var(--accent-soft); color: var(--green); }
.admin-marke.schlecht { background: var(--accent-soft); color: var(--muted); }
.admin-marke.admin    { background: var(--accent-soft); color: var(--accent); }

/* Der Zurueck-Link in der Kopfzeile ist ein <a>, kein <button> - .btn deckt
   die Optik ab, die Textausrichtung fehlt dort aber. */
.topbar a.btn { text-decoration: none; display: inline-flex; align-items: center; }

/* ---------- Verwaltungs-Popup (Doppelklick auf den Titel) ---------- */
#titel.klickbar { cursor: pointer; }
.admin-popup {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, .45);
  padding: 20px;
}
.admin-popup[hidden] { display: none; }
.admin-popup-box {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: min(320px, 100%);
  padding: 26px 24px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--row);
  text-align: center;
}
.admin-popup-icon { font-size: 30px; line-height: 1; }
.admin-popup-box h2 { margin: 0; font-size: 18px; }
.admin-popup-box p { margin: 0; font-size: 13px; color: var(--muted); }
.admin-popup-box .btn {
  text-decoration: none;
  display: inline-flex;
  justify-content: center;
  padding: 10px 12px;
}
.admin-popup-box .lock-link {
  background: none;
  border: 0;
  padding: 4px;
  font: inherit;
  font-size: 12.5px;
  color: var(--muted);
  cursor: pointer;
}
.admin-popup-box .lock-link:hover { color: var(--text); }

/* Loeschen und andere unwiderrufliche Aktionen. Bewusst kein gefuelltes Rot:
   der Knopf soll warnen, aber nicht staerker ziehen als der harmlose
   Hauptknopf daneben. Erst beim Hovern wird er voll rot. */
.btn.gefahr { color: var(--red); border-color: var(--del-soft); }
.btn.gefahr:hover { background: var(--red); border-color: var(--red); color: #fff; filter: none; }

/* ---------- Einstellungen ---------- */
/* Breiter und scrollbar als die schmalen Ja/Nein-Dialoge, links ausgerichtet
   (die einzelnen Ansichten teilen sich einen Dialog). */
.admin-popup-box.einstellungen {
  width: min(440px, 100%);
  max-height: min(82vh, 660px);
  overflow-y: auto;
  text-align: left;
  gap: 4px;
}
.admin-popup-box.einstellungen > div { display: flex; flex-direction: column; gap: 12px; }
.admin-popup-box.einstellungen > div[hidden] { display: none; }
/* Icon und Ueberschrift jeder Ansicht mittig, wie in den anderen Dialogen. */
.admin-popup-box.einstellungen > div > .admin-popup-icon { align-self: center; }
.admin-popup-box.einstellungen h2 { text-align: center; }

.ein-abschnitt {
  display: flex; flex-direction: column; gap: 8px;
  padding-top: 14px; margin-top: 2px;
  border-top: 1px solid var(--line);
}
#einstellungenHaupt > .ein-abschnitt:first-of-type { border-top: 0; padding-top: 4px; }
.ein-abschnitt h3 {
  margin: 0; font-size: 12px; font-weight: 700;
  text-transform: uppercase; letter-spacing: .04em; color: var(--muted);
}
.ein-hinweis { font-size: 12px; color: var(--muted); margin: 0; }
.ein-konto-name { font-size: 15px; font-weight: 600; margin: 0; }
.ein-konto-mail { font-size: 12.5px; color: var(--muted); margin: 0; word-break: break-all; }
.ein-konto-knoepfe { display: flex; gap: 8px; }
.ein-konto-knoepfe .btn { flex: 1; justify-content: center; }
#neueListe { align-self: flex-start; }
#neueListe:disabled { opacity: .5; cursor: not-allowed; }
#neueListe:disabled:hover { color: var(--text); border-color: var(--line); }
#einstellungenZu { align-self: center; margin-top: 8px; }

/* Listen-Zeilen (Meine Listen / Geteilt mit mir / Mitglieder) */
.listen-liste { display: flex; flex-direction: column; gap: 8px; }
.listen-liste:empty { display: none; }
.listen-zeile {
  display: flex; flex-direction: column; gap: 8px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: var(--bg);
}
.lz-kopf { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.lz-name { font-size: 15px; font-weight: 600; }
.lz-name.aktiv::after {
  content: "aktiv"; margin-left: 8px;
  font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em;
  color: var(--accent); background: var(--accent-soft);
  padding: 1px 6px; border-radius: 6px;
}
.lz-von { font-size: 12px; color: var(--muted); word-break: break-all; }
.lz-knoepfe { display: flex; gap: 6px; flex-wrap: wrap; }
.btn.klein { padding: 5px 10px; font-size: 12.5px; }
.lz-geteilt {
  align-self: flex-start;
  background: none; border: 0; padding: 2px 0;
  font: inherit; font-size: 12px; font-weight: 600; color: var(--accent);
  cursor: pointer; text-align: left;
}
.lz-geteilt:hover { text-decoration: underline; }
.lz-geteilt-info { font-size: 12px; color: var(--muted); }
#alleEntfernen { align-self: flex-start; }

/* Leerer Board-Zustand ohne jede Liste. */
.leer-liste { display: flex; flex-direction: column; align-items: center; gap: 14px; }

/* ---------- Umschalter-Menue am Titel ---------- */
.switcher { line-height: 1; }
.switcher[hidden] { display: none; }
.listen-menue {
  position: absolute;
  top: 100%; left: 0;
  margin-top: 6px;
  z-index: 40;
  min-width: 200px; max-width: 280px;
  display: flex; flex-direction: column;
  padding: 6px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--row);
  box-shadow: 0 10px 30px rgba(0, 0, 0, .18);
}
.listen-menue[hidden] { display: none; }
.menue-eintrag {
  display: flex; flex-direction: column; align-items: flex-start; gap: 1px;
  width: 100%;
  padding: 8px 10px;
  border: 0; border-radius: 8px;
  background: none; color: var(--text);
  font: inherit; font-size: 14px; font-weight: 600;
  text-align: left; cursor: pointer;
}
.menue-eintrag:hover { background: var(--hover); }
.menue-eintrag.aktiv { color: var(--accent); background: var(--accent-soft); }
.menue-von { font-size: 11.5px; font-weight: 500; color: var(--muted); }

/* "＋ Bereich" ohne aktive Liste ausgrauen. */
.btn.add-cat:disabled { opacity: .4; cursor: not-allowed; }
.btn.add-cat:disabled:hover { color: var(--muted); background: transparent; border-color: transparent; }

/* Ein- und Ausblenden der Ansichten im Einstellungs-Dialog. */
#einstellungenPopup .btn { justify-content: center; }
#kontoAdresse { word-break: break-all; }
#kontoLoeschenEmail {
  border: 1px solid var(--line);
  background: var(--bg);
  color: var(--text);
  padding: 10px 12px;
  border-radius: 10px;
  font: inherit;
  text-align: center;
  outline: none;
}
#kontoLoeschenEmail:focus { border-color: var(--red); box-shadow: 0 0 0 3px var(--del-soft); }

/* Turnstile-Kasten in der Anmeldemaske. Kein Mindestmass mehr: das Widget
   laeuft unsichtbar (appearance "interaction-only"), reservierter Platz waere
   ein Loch im Formular. Muss Turnstile doch mal fragen, bringt das Widget
   seine eigenen Masse mit und der Kasten waechst mit. */
.lock-turnstile { display: flex; justify-content: center; }
.lock-turnstile[hidden] { display: none; }

/* "Du" in der Nutzerliste - graugruen statt blau, damit es sich von der
   Admin-Marke daneben unterscheidet. */
.admin-marke.du { background: var(--chip); color: var(--text); }
