/* ============================================================================
   Fomas Vorsorge — stil.css
   Handy zuerst (Entscheidung 24.09.2026, Nachtanruf-Szenario A1):
   Die Masse ist fuer eine Hand mit Telefon entworfen, der Schreibtisch
   bekommt mehr Platz, nicht umgekehrt.

   PALETTE: aus dem Partnerportal (tokens.css), dort gemessen (WCAG 2.1):
     #704861 auf Weiss 7,53:1 (Text + Flaeche), #1A0F17 18,67:1 (Haupttext),
     #6E5B67 6,26:1 (gedaempft). #9C6B87 traegt KEINEN Text.
   ============================================================================ */
@import url('/assets/css/fonts.css');

:root {
  --tinte:      #1A0F17;
  --leise:      #6E5B67;
  --pflaume:    #704861;
  --pflaume-t:  #F3ECF0;   /* Pillen, Flaechen */
  --linie:      #E5DCE1;
  --grund:      #FAF7F9;
  --karte:      #FFFFFF;
  --warn:       #B3261E;   /* auf Weiss 6,4:1 */
  --gut:        #1E6B40;
  --radius:     14px;
  --schatten:   0 1px 3px rgba(26,15,23,.08), 0 4px 16px rgba(26,15,23,.06);

  /* Schriften der Website (CI): Lora fuer Namen und Ueberschriften,
     Source Sans 3 fuer die Oberflaeche. Lokal gehostet, kein Google-CDN. */
  --schrift:    'Source Sans 3', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --schrift-ue: 'Lora', Georgia, 'Times New Roman', serif;
  --leiste-br:  248px;   /* Breite der Seitenleiste am Schreibtisch */
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--grund); color: var(--tinte);
  font: 16px/1.5 var(--schrift);
}
h1, h2, h3, .sl-wort { font-family: var(--schrift-ue); font-weight: 500; letter-spacing: -.01em; }
button, input, select, textarea { font: inherit; color: inherit; }

/* --- Kopf: bleibt stehen, traegt Suche und Abmelden ----------------------- */
.kopf {
  position: sticky; top: 0; z-index: 20;
  background: var(--karte); border-bottom: 1px solid var(--linie);
  padding: 10px 16px calc(10px);
}
.kopf .zeile1 { display: flex; align-items: center; gap: 10px; }
.kopf h1 { font-size: 17px; margin: 0; flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kopf .betrieb { color: var(--leise); font-size: 13px; }
.kopf .abmelden {
  border: 0; background: none; color: var(--leise); font-size: 14px;
  padding: 8px; cursor: pointer; min-height: 44px;
}

/* --- Zentrale Suche ------------------------------------------------------- */
.suchfeld { position: relative; margin-top: 8px; }
.suchfeld input {
  width: 100%; min-height: 46px; padding: 10px 14px;
  border: 1.5px solid var(--linie); border-radius: 12px; background: var(--grund);
}
.suchfeld input:focus { outline: 2px solid var(--pflaume); border-color: var(--pflaume); }
.suchtreffer {
  position: absolute; left: 0; right: 0; top: calc(100% + 6px); z-index: 30;
  background: var(--karte); border: 1px solid var(--linie); border-radius: var(--radius);
  box-shadow: var(--schatten); max-height: 55vh; overflow: auto;
}
.suchtreffer button {
  display: block; width: 100%; text-align: left; background: none; border: 0;
  border-bottom: 1px solid var(--linie); padding: 12px 14px; cursor: pointer; min-height: 44px;
}
.suchtreffer button:last-child { border-bottom: 0; }
.suchtreffer .t { font-weight: 600; }
.suchtreffer .u { color: var(--leise); font-size: 13px; }
.suchtreffer .leer { padding: 14px; color: var(--leise); }

/* --- Filter-Pillen -------------------------------------------------------- */
.filter {
  display: flex; gap: 8px; overflow-x: auto; padding: 12px 16px 4px;
  -webkit-overflow-scrolling: touch; scrollbar-width: none;
}
.filter::-webkit-scrollbar { display: none; }
.filter button {
  border: 1.5px solid var(--linie); background: var(--karte); color: var(--tinte);
  border-radius: 999px; padding: 8px 14px; white-space: nowrap; cursor: pointer; min-height: 40px;
}
.filter button[aria-pressed="true"] { background: var(--pflaume); border-color: var(--pflaume); color: #fff; }

/* --- Liste ---------------------------------------------------------------- */
/* `hidden` muss `hidden` heissen. Ohne diese Regel gewinnt jedes spaetere
   `display: flex/grid` gegen das Attribut, und ein Kasten, den das Programm
   ausgeblendet hat, steht trotzdem da. Das ist hier zweimal passiert
   (Anzeigen-Kopfzeile, Kundenband) — deshalb einmal zentral statt jedes Mal
   eine eigene Ausnahme. */
[hidden] { display: none !important; }

main { padding: 8px 16px 96px; max-width: 760px; margin: 0 auto; }
.karte {
  background: var(--karte); border: 1px solid var(--linie); border-radius: var(--radius);
  box-shadow: var(--schatten); padding: 14px; margin: 10px 0; cursor: pointer;
}
.karte .oben { display: flex; align-items: baseline; gap: 8px; }
.karte .name { font-weight: 650; flex: 1; }
.karte .zeitpunkt { color: var(--leise); font-size: 13px; white-space: nowrap; }
.karte .grund { color: var(--leise); font-size: 14px; margin-top: 2px; }
.karte .unten { display: flex; align-items: center; gap: 8px; margin-top: 10px; flex-wrap: wrap; }
.leerhinweis { color: var(--leise); text-align: center; padding: 48px 16px; }

/* Status-Pillen: Farbe traegt NIE allein die Information, der Text steht dabei */
.pille {
  display: inline-block; border-radius: 999px; padding: 4px 10px; font-size: 13px;
  background: var(--pflaume-t); color: var(--pflaume);
}
.pille[data-farbe="neu"]    { background: var(--pflaume); color: #fff; }
.pille[data-farbe="warten"] { background: #FDEFD8; color: #7A4B00; }
.pille[data-farbe="fertig"] { background: #E3EFE8; color: var(--gut); }
.pille[data-farbe="frist"]  { background: #F9E3E1; color: var(--warn); font-weight: 600; }

/* --- Schwebender Neu-Knopf ------------------------------------------------ */
.neu-knopf {
  position: fixed; right: 16px; bottom: max(16px, env(safe-area-inset-bottom));
  z-index: 25; min-height: 56px; padding: 0 22px; border: 0; border-radius: 999px;
  background: var(--pflaume); color: #fff; font-size: 16px; font-weight: 600;
  box-shadow: 0 6px 20px rgba(112,72,97,.4); cursor: pointer;
}

/* --- Dialoge (Schnellerfassung + Detail) ---------------------------------- */
dialog {
  border: 0; border-radius: 16px 16px 0 0; padding: 0; margin: 0;
  width: 100%; max-width: none; max-height: 92dvh;
  position: fixed; bottom: 0; top: auto;
  box-shadow: 0 -8px 40px rgba(26,15,23,.25);
}
dialog::backdrop { background: rgba(26,15,23,.35); }
@media (min-width: 700px) {
  dialog { border-radius: 16px; bottom: auto; top: 50%; left: 50%;
           transform: translate(-50%,-50%); width: 620px; max-height: 86vh; }
}
.dialog-kopf {
  position: sticky; top: 0; background: var(--karte); z-index: 5;
  display: flex; align-items: center; gap: 8px;
  padding: 14px 18px; border-bottom: 1px solid var(--linie);
}
.dialog-kopf h2 { margin: 0; font-size: 17px; flex: 1; }
.dialog-kopf .zu { border: 0; background: none; font-size: 26px; line-height: 1;
                   color: var(--leise); cursor: pointer; padding: 6px 10px; }
.dialog-koerper { padding: 16px 18px 24px; overflow: auto; }

/* --- Formular ------------------------------------------------------------- */
.feld { margin-bottom: 14px; }
.feld label { display: block; font-size: 13px; color: var(--leise); margin-bottom: 4px; }
.feld input, .feld select, .feld textarea {
  width: 100%; min-height: 46px; padding: 10px 12px;
  border: 1.5px solid var(--linie); border-radius: 10px; background: #fff;
}
.feld textarea { min-height: 84px; resize: vertical; }
.feld input:focus, .feld select:focus, .feld textarea:focus {
  outline: 2px solid var(--pflaume); border-color: var(--pflaume);
}
/* Zwei Felder nebeneinander erst, wenn dafuer Platz ist. Im schmalen
   Aktenrahmen am Handy standen sonst abgeschnittene Beschriftungen. */
.zeile2 { display: grid; grid-template-columns: 1fr; gap: 10px; }
@media (min-width: 460px) { .zeile2 { grid-template-columns: 1fr 1fr; } }
.haupt {
  width: 100%; min-height: 50px; border: 0; border-radius: 12px;
  background: var(--pflaume); color: #fff; font-size: 16px; font-weight: 600; cursor: pointer;
}
.haupt:disabled { opacity: .6; }
.nebenreihe { display: flex; gap: 10px; margin-top: 10px; }
.neben {
  flex: 1; min-height: 46px; border: 1.5px solid var(--pflaume); border-radius: 12px;
  background: #fff; color: var(--pflaume); font-weight: 600; cursor: pointer;
}

.meldung { border-radius: 10px; padding: 10px 12px; margin: 0 0 12px; font-size: 14px; }
.meldung[data-art="schlecht"] { background: #F9E3E1; color: var(--warn); }
.meldung[data-art="gut"]      { background: #E3EFE8; color: var(--gut); }

/* --- Detail: Statuswahl + Verlauf ---------------------------------------- */
.statuswahl { display: flex; flex-wrap: wrap; gap: 8px; }
.statuswahl button {
  border: 1.5px solid var(--linie); background: #fff; border-radius: 999px;
  padding: 8px 13px; cursor: pointer; min-height: 40px;
}
.statuswahl button[aria-pressed="true"] { background: var(--pflaume); border-color: var(--pflaume); color: #fff; }
.kontaktzeile { display: flex; gap: 10px; flex-wrap: wrap; margin: 6px 0 14px; }
.kontaktzeile a {
  color: var(--pflaume); text-decoration: none; border: 1.5px solid var(--pflaume-t);
  background: var(--pflaume-t); border-radius: 999px; padding: 8px 14px; min-height: 40px;
  display: inline-flex; align-items: center;
}
.verlauf { list-style: none; margin: 10px 0 0; padding: 0; }
.verlauf li { border-left: 2px solid var(--linie); padding: 2px 0 14px 14px; position: relative; }
.verlauf li::before {
  content: ''; position: absolute; left: -5px; top: 8px; width: 8px; height: 8px;
  border-radius: 50%; background: var(--pflaume);
}
.verlauf .vz { color: var(--leise); font-size: 12.5px; }
.trenn { border: 0; border-top: 1px solid var(--linie); margin: 18px 0; }

/* --- Anmeldeseite --------------------------------------------------------- */
.anmeldekapsel {
  max-width: 380px; margin: 10dvh auto; background: var(--karte);
  border: 1px solid var(--linie); border-radius: 18px; box-shadow: var(--schatten);
  padding: 28px 24px;
}
.anmeldekapsel h1 { font-size: 22px; margin: 0 0 4px; }

/* Dieselbe Marke wie in der Seitenleiste, nur groesser: Name oben, „Vorsorge"
   darunter. `.sl-zusatz` wird mitbenutzt statt nachgebaut — zwei Fassungen
   derselben Marke laufen sonst irgendwann auseinander. Als Block, weil
   `.sl-zusatz` ein inline-Element ist und sonst hinter dem Namen stuende. */
h1.marke-gross { display: flex; flex-direction: column; gap: 2px; font-size: 28px; }
.marke-gross .sl-zusatz { display: block; font-size: 11.5px; }
.anmeldekapsel .unterzeile { color: var(--leise); margin: 0 0 18px; font-size: 14px; }

/* ============================ Baustein 2 ================================== */

/* --- Bereichswechsel im Kopf (Anfragen | Board) --------------------------- */
.bereiche { display: flex; gap: 6px; margin-top: 10px; }
.bereiche a {
  text-decoration: none; color: var(--tinte); border-radius: 999px;
  padding: 8px 14px; border: 1.5px solid var(--linie); min-height: 40px;
  display: inline-flex; align-items: center;
}
.bereiche a[aria-current="page"] { background: var(--pflaume); border-color: var(--pflaume); color: #fff; }

/* --- Board ---------------------------------------------------------------- */
.board {
  display: flex; gap: 12px; overflow-x: auto; padding: 12px 16px 40px;
  align-items: flex-start; -webkit-overflow-scrolling: touch; min-height: 60dvh;
}
.spalte {
  flex: 0 0 270px; background: var(--pflaume-t); border-radius: var(--radius);
  padding: 10px; min-height: 120px;
}
.spalte h2 {
  font-size: 13px; letter-spacing: .04em; text-transform: uppercase;
  color: var(--pflaume); margin: 2px 6px 10px; display: flex; justify-content: space-between;
}
.spalte.ziel { outline: 2px dashed var(--pflaume); outline-offset: 2px; }
.fallkarte {
  background: var(--karte); border: 1px solid var(--linie); border-radius: 12px;
  box-shadow: var(--schatten); padding: 10px 12px; margin-bottom: 8px; cursor: pointer;
}
.fallkarte .fk-name { font-weight: 650; }
.fallkarte .fk-nummer { color: var(--leise); font-size: 12.5px; }
.fallkarte[draggable="true"] { user-select: none; }
.fallkarte.schwebt { opacity: .4; }

/* --- Akte ----------------------------------------------------------------- */
.akte-kopf { position: sticky; top: 0; z-index: 20; background: var(--karte);
  border-bottom: 1px solid var(--linie); padding: 10px 16px; }
.akte-kopf .zeile1 { display: flex; align-items: center; gap: 10px; }
.akte-kopf .zurueck { text-decoration: none; color: var(--pflaume); font-size: 22px;
  padding: 6px 10px 6px 0; }
.akte-kopf h1 { font-size: 17px; margin: 0; flex: 1; white-space: nowrap;
  overflow: hidden; text-overflow: ellipsis; }
.akte-kopf .speicherstand { color: var(--leise); font-size: 12.5px; white-space: nowrap; }
.akte-kopf .speicherstand[data-art="konflikt"] { color: var(--warn); font-weight: 600; }

.phasenleiste { display: flex; gap: 6px; overflow-x: auto; padding: 10px 16px 2px;
  scrollbar-width: none; }
.phasenleiste::-webkit-scrollbar { display: none; }
.phasenleiste button {
  border: 1.5px solid var(--linie); background: var(--karte); border-radius: 999px;
  padding: 7px 13px; white-space: nowrap; cursor: pointer; min-height: 38px; font-size: 14px;
}
.phasenleiste button[aria-pressed="true"] { background: var(--pflaume);
  border-color: var(--pflaume); color: #fff; }

.reiter { display: flex; gap: 4px; overflow-x: auto; padding: 10px 16px 0;
  border-bottom: 1px solid var(--linie); scrollbar-width: none; }
.reiter::-webkit-scrollbar { display: none; }
.reiter button {
  border: 0; background: none; padding: 10px 12px; cursor: pointer; white-space: nowrap;
  color: var(--leise); border-bottom: 2.5px solid transparent; min-height: 44px; font-size: 15px;
}
.reiter button[aria-selected="true"] { color: var(--pflaume); font-weight: 650;
  border-bottom-color: var(--pflaume); }
.blatt { display: none; }
.blatt[data-offen] { display: block; }

.ap-karte { background: var(--karte); border: 1px solid var(--linie);
  border-radius: 12px; padding: 12px; margin-bottom: 10px; }
.ap-karte .ap-kopf { display: flex; align-items: baseline; gap: 8px; }
.ap-karte .ap-name { font-weight: 650; flex: 1; }
.ap-karte .ap-weg { border: 0; background: none; color: var(--warn); cursor: pointer;
  font-size: 14px; padding: 4px; }
.ap-karte .ap-rest { color: var(--leise); font-size: 14px; }

/* ============================ Kalkulator ================================== */
.k-abschnitt { background: var(--karte); border: 1px solid var(--linie);
  border-radius: var(--radius); box-shadow: var(--schatten); padding: 16px; margin: 14px 0; }
.k-abschnitt h2 { font-size: 15px; margin: 0 0 10px; }
.k-abschnitt h2 .nr { color: var(--pflaume); margin-right: 6px; }
.k-optionen { display: grid; gap: 8px; }
@media (min-width: 640px) { .k-optionen { grid-template-columns: 1fr 1fr; } }
.k-option { display: flex; align-items: center; gap: 10px; border: 1.5px solid var(--linie);
  border-radius: 12px; padding: 11px 13px; cursor: pointer; background: #fff; min-height: 52px; }
.k-option[aria-pressed="true"] { border-color: var(--pflaume); background: var(--pflaume-t); }
.k-option .kn { flex: 1; }
.k-option .kn b { display: block; font-weight: 600; font-size: 14.5px; }
.k-option .kn small { color: var(--leise); font-size: 12.5px; }
.k-option .kp { font-weight: 650; white-space: nowrap; font-size: 14px; }
.k-option .sym { font-size: 20px; }
.i-marke { display: inline-flex; align-items: center; justify-content: center;
  width: 17px; height: 17px; border-radius: 50%; background: #FDEFD8; color: #7A4B00;
  font-size: 11.5px; font-weight: 700; margin-left: 6px; cursor: help; }
.k-summe { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
  background: var(--tinte); color: #fff; padding: 12px 16px calc(12px + env(safe-area-inset-bottom)); }
.k-summe .zeile { max-width: 760px; margin: 0 auto; display: flex; align-items: center; gap: 12px; }
.k-summe .betrag { font-size: 22px; font-weight: 700; margin-left: auto; white-space: nowrap; }
.k-summe button { border: 0; border-radius: 10px; padding: 10px 16px; font-weight: 600;
  cursor: pointer; background: var(--pflaume); color: #fff; min-height: 44px; }
.k-summe .auf { background: none; border: 1px solid rgba(255,255,255,.35); color: #fff; }
.k-aufstellung { max-width: 760px; margin: 8px auto 0; font-size: 13.5px; display: none; }
.k-aufstellung[data-offen] { display: block; }
.k-aufstellung div { display: flex; justify-content: space-between; gap: 12px;
  padding: 3px 0; border-top: 1px solid rgba(255,255,255,.15); }
.k-hinweis { color: var(--leise); font-size: 12.5px; margin-top: 8px; }

/* ═══ Fallakte-Tiefe (27.09.2026): Leistungen, Aufgaben, Zusatzfelder ══════
   Nachbau der BestattungONE-Reiter in unserer Formensprache. Listen statt
   Tabellen, weil die Akte am Handy im Beratungsgespraech benutzt wird. */

/* Zahl am Reiter: wie viele Positionen/offene Aufgaben warten */
.reiter-zahl {
  display: inline-block; min-width: 18px; padding: 0 5px; margin-left: 4px;
  background: var(--pflaume-t); color: var(--pflaume);
  border-radius: 9px; font-size: 11px; font-weight: 700; line-height: 18px;
  text-align: center; vertical-align: 1px;
}
.reiter-zahl:empty { display: none; }

/* Summe der Leistungen */
.summenleiste { margin-bottom: 14px; }
.summenleiste:empty { display: none; }
.summe-gross { font-size: 27px; font-weight: 600; letter-spacing: -.02em; }
.summe-teil  { color: var(--leise); font-size: 13px; margin-top: 2px; }

/* Eine Position */
.pos-zeile { border-bottom: 1px solid var(--linie); padding: 11px 0; }
.pos-zeile:first-child { border-top: 1px solid var(--linie); }
.pos-weg { opacity: .5; }
.pos-weg .pos-name { text-decoration: line-through; }
.pos-kopf { display: flex; gap: 10px; align-items: baseline; }
.pos-name { font-weight: 600; flex: 1; }
.pos-preis { white-space: nowrap; font-variant-numeric: tabular-nums; }
.pos-meta { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; margin-top: 6px; }
.pos-quelle { color: var(--leise); font-size: 12.5px; }
.pos-notiz  { color: var(--leise); font-size: 12.5px; font-style: italic; flex-basis: 100%; }
.pos-weg-knopf {
  border: 0; background: none; color: var(--warn); font-size: 12.5px;
  cursor: pointer; padding: 4px 2px; margin-left: auto;
}

/* Eine Aufgabe */
.auf-zeile { display: flex; gap: 10px; border-bottom: 1px solid var(--linie); padding: 11px 0; }
.auf-zeile:first-child { border-top: 1px solid var(--linie); }
.auf-fertig { opacity: .55; }
.auf-fertig .auf-titel { text-decoration: line-through; }
.auf-haken { width: 20px; height: 20px; margin-top: 2px; flex: none; accent-color: var(--pflaume); }
.auf-mitte { flex: 1; min-width: 0; }
.auf-titel { font-weight: 600; }
.auf-text  { color: var(--leise); font-size: 13px; margin-top: 2px; line-height: 1.5; }
.auf-meta  { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; margin-top: 6px; }
.auf-wer, .auf-status { color: var(--leise); font-size: 12.5px; }

/* Aufklappbare Abschnitte (Familienangehoerige) */
.klapp { border: 1px solid var(--linie); border-radius: var(--radius); padding: 0 12px; margin-bottom: 14px; }
.klapp > summary {
  cursor: pointer; padding: 12px 2px; font-weight: 600; list-style: none;
  display: flex; align-items: center; gap: 8px;
}
.klapp > summary::-webkit-details-marker { display: none; }
.klapp > summary::before { content: '▸'; color: var(--leise); transition: transform .15s; }
.klapp[open] > summary::before { transform: rotate(90deg); }
.klapp[open] > summary { border-bottom: 1px solid var(--linie); margin-bottom: 12px; }

.feld-hinweis { color: var(--leise); font-size: 12.5px; margin-top: 4px; line-height: 1.5; }

/* Stammdaten: Artikelzeile */
.art-preis { font-variant-numeric: tabular-nums; font-weight: 600; white-space: nowrap; }
.art-oeff { display: flex; gap: 5px; align-items: center; font-size: 12.5px; color: var(--leise); cursor: pointer; white-space: nowrap; }
.art-oeff input { width: 17px; height: 17px; accent-color: var(--pflaume); }
.auf-fall { color: var(--pflaume); font-size: 12.5px; text-decoration: none; margin-left: auto; white-space: nowrap; }
.auf-fall:hover { text-decoration: underline; }

/* ═══════════════════════════════════════════════════════════════════════════
   RAHMENOBERFLAECHE (27.09.2026)
   Aufbau nach BestattungONE: feste Navigation links, Arbeitsflaeche rechts,
   Betrieb und Benutzer unten in der Leiste. Farben und Schrift bleiben unsere.
   Am Handy wird die Leiste zur Schublade.
   ═══════════════════════════════════════════════════════════════════════════ */

/* --- Seitenleiste --------------------------------------------------------- */
.seitenleiste {
  position: fixed; inset: 0 auto 0 0; width: var(--leiste-br); z-index: 60;
  background: var(--karte); border-right: 1px solid var(--linie);
  display: flex; flex-direction: column;
  transform: translateX(-100%); transition: transform .22s ease;
}
.seitenleiste.offen { transform: none; }
.leiste-schatten {
  position: fixed; inset: 0; z-index: 55; background: rgba(26,15,23,.45);
  backdrop-filter: blur(1px);
}

.sl-marke {
  display: flex; align-items: center; gap: 7px;
  padding: 18px 18px 16px; border-bottom: 1px solid var(--linie);
}
/* Name und Zusatz stehen UNTEREINANDER, der Schliessknopf daneben. Deshalb
   ein eigener Kasten um die zwei Zeilen: Stapelte man die ganze Marke, waere
   `margin-left:auto` am Knopf wirkungslos und er sass unter dem Wort. */
.sl-marke-text { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.sl-wort   { font-size: 21px; color: var(--tinte); letter-spacing: .01em; line-height: 1.1; }
.sl-zusatz { font-size: 11px; color: var(--pflaume); letter-spacing: .14em; text-transform: uppercase; }

/* Das @ statt des `a`. Lora setzt es deutlich groesser und runder als einen
   Buchstaben — in voller Groesse reisst es das Wort auf. Kleiner gestellt und
   mit etwas Zug nach innen sitzt es in der Zeile. Pflaume macht aus dem
   Zeichen eine Absicht statt eines Tippfehlers; die Farbe traegt Text
   (7,53:1 auf Weiss, siehe Kopf dieser Datei). */
.sl-at {
  font-size: .78em; color: var(--pflaume); letter-spacing: -.03em;
  position: relative; top: -.02em;   /* setzt den Ring auf die Mittellaenge */
}
.sl-zu {
  margin-left: auto; border: 0; background: none; color: var(--leise);
  font-size: 18px; cursor: pointer; padding: 4px 2px; line-height: 1;
}

.sl-liste { list-style: none; margin: 0; padding: 10px 10px 0; flex: 1; overflow-y: auto; }
.sl-liste li { margin-bottom: 2px; }
.sl-liste a {
  display: flex; align-items: center; gap: 11px;
  padding: 11px 12px; border-radius: 10px; min-height: 46px;
  color: var(--tinte); text-decoration: none; font-size: 15px;
  border-left: 3px solid transparent; transition: background .12s;
}
.sl-liste a:hover { background: var(--grund); }
.sl-liste a[aria-current="page"] {
  background: var(--pflaume-t); color: var(--pflaume);
  font-weight: 600; border-left-color: var(--pflaume);
}
.sl-liste svg { width: 19px; height: 19px; flex: none; fill: none;
  stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }

.sl-fuss { border-top: 1px solid var(--linie); padding: 14px 18px calc(14px + env(safe-area-inset-bottom)); }
.sl-betrieb { font-weight: 600; font-size: 13.5px; }
.sl-nutzer  { color: var(--leise); font-size: 12.5px; margin-top: 1px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sl-abmelden {
  margin-top: 10px; border: 1.5px solid var(--linie); background: none;
  border-radius: 9px; padding: 8px 12px; color: var(--leise);
  cursor: pointer; font-size: 13.5px; width: 100%; min-height: 40px;
}
.sl-abmelden:hover { border-color: var(--pflaume); color: var(--pflaume); }

/* --- Kopfzeile am Handy --------------------------------------------------- */
.handy-kopf {
  position: sticky; top: 0; z-index: 40; display: flex; align-items: center; gap: 12px;
  background: var(--karte); border-bottom: 1px solid var(--linie); padding: 8px 14px;
}
.hk-menue {
  border: 0; background: none; padding: 10px 8px; cursor: pointer;
  display: flex; flex-direction: column; gap: 4px; min-height: 44px; justify-content: center;
}
.hk-menue span { display: block; width: 19px; height: 2px; background: var(--tinte); border-radius: 2px; }
.hk-titel { font-family: var(--schrift-ue); font-size: 17px; }
body.leiste-offen { overflow: hidden; }

/* --- Schreibtisch: Leiste steht fest, Inhalt rueckt nach ------------------- */
@media (min-width: 900px) {
  .seitenleiste { transform: none; }
  .handy-kopf, .sl-zu, .leiste-schatten { display: none !important; }
  body { padding-left: var(--leiste-br); }
}

/* --- Arbeitsflaeche ------------------------------------------------------- */
.flaeche { max-width: 1080px; margin: 0 auto; padding: 22px 16px 80px; }
@media (min-width: 900px) { .flaeche { padding: 34px 32px 80px; } }

.seitenkopf { display: flex; align-items: flex-start; gap: 16px; flex-wrap: wrap; margin-bottom: 20px; }
.seitenkopf .sk-text { flex: 1; min-width: 220px; }
.seitenkopf h1 { font-size: clamp(22px, 3.2vw, 29px); margin: 0 0 3px; }
.seitenkopf .sk-unter { color: var(--leise); font-size: 14.5px; margin: 0; }
.sk-knopf {
  display: inline-flex; align-items: center; gap: 7px; min-height: 44px;
  border: 0; border-radius: 11px; background: var(--pflaume); color: #fff;
  padding: 11px 18px; font-size: 15px; font-weight: 600; cursor: pointer;
  text-decoration: none; white-space: nowrap;
}
.sk-knopf:hover { opacity: .9; }
.sk-knopf.leise { background: var(--karte); color: var(--tinte); border: 1.5px solid var(--linie); }
.sk-knopf.leise:hover { border-color: var(--pflaume); color: var(--pflaume); opacity: 1; }

/* --- Datenkarte: Reiterzeile + Inhalt, wie die Listen in BestattungONE ----- */
.datenkarte {
  background: var(--karte); border: 1px solid var(--linie);
  border-radius: 16px; box-shadow: var(--schatten); overflow: hidden;
}
.dk-kopf { display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  padding: 14px 16px; border-bottom: 1px solid var(--linie); }
.dk-koerper { padding: 4px 16px 16px; }

/* Umschalter „Offen | Archiviert" */
.schalter { display: inline-flex; background: var(--grund); border-radius: 10px; padding: 3px; gap: 2px; }
.schalter button {
  border: 0; background: none; border-radius: 8px; padding: 8px 15px;
  cursor: pointer; color: var(--leise); font-size: 14px; min-height: 38px;
}
.schalter button[aria-pressed="true"] { background: var(--karte); color: var(--tinte);
  font-weight: 600; box-shadow: 0 1px 2px rgba(26,15,23,.1); }

/* --- Tabelle (Schreibtisch) / Karten (Handy) ------------------------------ */
.tabelle { width: 100%; border-collapse: collapse; }
.tabelle th {
  text-align: left; font-weight: 500; font-size: 12.5px; color: var(--leise);
  letter-spacing: .04em; text-transform: uppercase;
  padding: 12px 10px; border-bottom: 1px solid var(--linie); white-space: nowrap;
}
.tabelle td { padding: 13px 10px; border-bottom: 1px solid var(--linie); vertical-align: middle; }
.tabelle tr:last-child td { border-bottom: 0; }
.tabelle tbody tr { cursor: pointer; }
.tabelle tbody tr:hover { background: var(--grund); }
.tz-haupt { font-weight: 600; }
.tz-neben { color: var(--leise); font-size: 13px; }
.tz-zahl  { font-variant-numeric: tabular-nums; white-space: nowrap; }

@media (max-width: 767px) {
  .tabelle, .tabelle tbody, .tabelle tr, .tabelle td { display: block; width: 100%; }
  .tabelle thead { display: none; }
  .tabelle tr {
    border: 1px solid var(--linie); border-radius: 12px;
    padding: 12px 14px; margin-bottom: 10px; background: var(--karte);
  }
  .tabelle td { border: 0; padding: 2px 0; }
  .tabelle td[data-spalte]::before {
    content: attr(data-spalte) ': '; color: var(--leise); font-size: 12.5px;
  }
  .tabelle td[data-spalte="_haupt"]::before { content: none; }
}

/* --- Aktenansicht: Reiter stehen links (wie BestattungONE) ---------------- */
.akte-rahmen {
  background: var(--karte); border: 1px solid var(--linie);
  border-radius: 16px; box-shadow: var(--schatten); overflow: hidden;
}
.akte-leiste { padding: 16px 18px; border-bottom: 1px solid var(--linie); }
.al-oben { display: flex; align-items: flex-start; gap: 12px; flex-wrap: wrap; }
.al-titel { flex: 1; min-width: 200px; }
.al-titel h1 { font-size: clamp(19px, 2.6vw, 24px); margin: 0; }
.al-nummer { color: var(--leise); font-size: 13.5px; margin-top: 2px; display: flex; gap: 8px; align-items: center; }
.al-knoepfe { display: flex; gap: 8px; flex-wrap: wrap; }

/* Phasenbalken: Segmente statt Pillen — zeigt den Fortschritt auf einen Blick */
.phasen-balken { display: flex; align-items: center; gap: 4px; margin-top: 14px; flex-wrap: wrap; }
.phasen-balken .pb-spur { display: flex; gap: 4px; flex: 1; min-width: 180px; }
.phasen-balken button {
  flex: 1; height: 6px; min-width: 14px; border: 0; border-radius: 3px;
  background: var(--linie); cursor: pointer; padding: 0;
  position: relative; min-height: 0;
}
.phasen-balken button::after {
  content: ''; position: absolute; inset: -9px 0;   /* groessere Trefferflaeche */
}
.phasen-balken button[data-stand="erledigt"] { background: var(--pflaume); opacity: .45; }
.phasen-balken button[data-stand="hier"]     { background: var(--pflaume); }
.phasen-balken .pb-name {
  font-size: 11.5px; letter-spacing: .1em; text-transform: uppercase;
  color: var(--pflaume); font-weight: 600; white-space: nowrap;
}

.akte-koerper { display: grid; }
@media (min-width: 900px) { .akte-koerper { grid-template-columns: 208px 1fr; } }
/* Seiten ohne Reiterleiste (Fahrtkosten, Team): Inhalt ueber die volle Breite,
   sonst landet er in der 208-px-Spalte der Reiter (gefunden 11.10.2026). */
.akte-koerper > .akte-inhalt:only-child { grid-column: 1 / -1; }

.akte-reiter { padding: 12px; border-bottom: 1px solid var(--linie); display: flex;
  gap: 4px; overflow-x: auto; scrollbar-width: none; }
.akte-reiter::-webkit-scrollbar { display: none; }
.akte-reiter button {
  display: flex; align-items: center; gap: 8px; white-space: nowrap;
  border: 0; background: none; border-radius: 9px; padding: 10px 13px;
  color: var(--leise); cursor: pointer; font-size: 14.5px; min-height: 44px;
}
.akte-reiter button[aria-selected="true"] { background: var(--pflaume-t); color: var(--pflaume); font-weight: 600; }
@media (min-width: 900px) {
  .akte-reiter {
    flex-direction: column; overflow: visible; border-bottom: 0;
    border-right: 1px solid var(--linie); padding: 14px 12px;
  }
  .akte-reiter button { width: 100%; }
}
.akte-inhalt { padding: 20px 18px 28px; min-width: 0; }
@media (min-width: 900px) { .akte-inhalt { padding: 24px 26px 34px; } }

/* Abschnittsueberschrift im Formular (BestattungONE: „Persönliche Daten" …) */
.abschnitt-ue {
  font-family: var(--schrift-ue); font-size: 17px; margin: 26px 0 14px;
  padding-bottom: 8px; border-bottom: 1px solid var(--linie);
}
.abschnitt-ue:first-child { margin-top: 0; }

/* Am Schreibtisch stehen Felder zu zweit, am Handy untereinander */
@media (min-width: 640px) { .zeile3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 10px; } }

/* Friedhofs-Hinweis in der Fallakte: was am Beisetzungstag zählt */
.fh-kasten { background: #FBF7EC; border: 1px solid rgba(138,111,58,.3); border-radius: 12px;
  padding: 12px 14px; margin: 4px 0 16px; }
.fh-kopf { font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: #8A6F3A;
  font-weight: 700; margin-bottom: 9px; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.fh-zeile { display: flex; gap: 8px; font-size: 13px; line-height: 1.55; color: var(--leise);
  padding: 5px 0; border-bottom: 1px dashed rgba(138,111,58,.18); }
.fh-zeile:last-of-type { border-bottom: 0; }
.fh-zeile strong { color: var(--tinte); font-weight: 600; }
.fh-mark { flex: none; width: 88px; font-weight: 600; color: var(--tinte); font-size: 12.5px; }
.fh-punkt { flex: none; width: 9px; height: 9px; border-radius: 50%; margin-top: 5px; background: var(--leise); }
.fh-zeile[data-art="gut"]   .fh-punkt { background: var(--gut); }
.fh-zeile[data-art="warn"]  .fh-punkt { background: #B98A2F; }
.fh-zeile[data-art="ernst"] .fh-punkt { background: var(--warn); }
.fh-zeile[data-art="ernst"] strong { color: var(--warn); }
.fh-pflege { display: inline-block; margin-top: 8px; font-size: 12.5px; color: var(--pflaume); text-decoration: none; }

/* Belegzeile in der Fallakte */
.beleg-zeile { border-bottom: 1px solid var(--linie); padding: 12px 0; }
.beleg-zeile:first-child { border-top: 1px solid var(--linie); }
.beleg-knoepfe { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 8px; }
.beleg-knoepfe button {
  border: 1.5px solid var(--linie); background: var(--karte); border-radius: 9px;
  padding: 7px 13px; font-size: 13px; cursor: pointer; min-height: 38px; color: var(--tinte);
}
.beleg-knoepfe button:hover { border-color: var(--pflaume); color: var(--pflaume); }
.beleg-knoepfe button.warnend:hover { border-color: var(--warn); color: var(--warn); }

/* Kennzahlen-Kacheln (Abrechnung, später Statistik) */
.kennzahlen { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); }
.kz { background: var(--karte); border: 1px solid var(--linie); border-radius: 14px;
  box-shadow: var(--schatten); padding: 16px 18px; }
.kz-wert { font-size: 25px; font-weight: 600; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.kz-name { color: var(--leise); font-size: 13px; margin-top: 2px; }
.kz-warn .kz-wert { color: var(--warn); }
.tabelle th.r, .tabelle td.r { text-align: right; }

/* Statuswahl in der Abmeldeliste */
.abm-status { border: 1.5px solid var(--linie); border-radius: 8px; padding: 5px 8px;
  font-size: 13px; background: var(--karte); min-height: 34px; }

/* ═══ Kalender ════════════════════════════════════════════════════════════ */
.kal-leiste { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; margin-top: 4px; }
.kal-filter { display: flex; gap: 12px; flex-wrap: wrap; }
.kal-haken { display: flex; align-items: center; gap: 6px; font-size: 13px;
  color: var(--leise); cursor: pointer; white-space: nowrap; }
.kal-haken input { width: 16px; height: 16px; accent-color: var(--pflaume); }
.kal-punkt { width: 9px; height: 9px; border-radius: 50%; display: inline-block; }

.kal-woche { display: grid; grid-template-columns: repeat(7, 1fr); gap: 1px;
  background: var(--linie); border: 1px solid var(--linie); border-radius: 12px; overflow: hidden; }
.kal-tag { background: var(--karte); min-height: 130px; padding: 8px 7px; }
.kal-tag.kal-heute { background: var(--pflaume-t); }
.kal-tagkopf { display: flex; align-items: baseline; gap: 5px; margin-bottom: 7px; }
.kt-name { font-size: 11px; text-transform: uppercase; letter-spacing: .05em; color: var(--leise); }
.kt-zahl { font-size: 16px; font-weight: 600; }
.kal-heute .kt-zahl { color: var(--pflaume); }
.kal-tagliste { display: flex; flex-direction: column; gap: 4px; }

.kal-monat { display: grid; grid-template-columns: repeat(7, 1fr); gap: 1px;
  background: var(--linie); border: 1px solid var(--linie); border-radius: 12px; overflow: hidden; }
.km-kopf { background: var(--grund); padding: 7px; font-size: 11px; text-transform: uppercase;
  letter-spacing: .05em; color: var(--leise); text-align: center; }
.km-tag { background: var(--karte); min-height: 92px; padding: 5px; }
.km-tag.km-fremd { background: var(--grund); opacity: .6; }
.km-tag.kal-heute { background: var(--pflaume-t); }
.km-zahl { font-size: 12.5px; color: var(--leise); margin-bottom: 4px; }
.kal-heute .km-zahl { color: var(--pflaume); font-weight: 700; }

.kal-eintrag { display: block; width: 100%; text-align: left; background: var(--grund);
  border: 0; border-left: 3px solid var(--leise); border-radius: 5px;
  padding: 5px 7px; margin-bottom: 3px; cursor: pointer; font: inherit; }
.kal-eintrag:hover { background: var(--pflaume-t); }
.ke-zeit  { display: block; font-size: 11px; color: var(--leise); font-variant-numeric: tabular-nums; }
.ke-titel { display: block; font-size: 12.5px; font-weight: 600; line-height: 1.35;
  overflow: hidden; text-overflow: ellipsis; }
.ke-fall  { display: block; font-size: 11px; color: var(--pflaume); }

.kal-listentag { margin-bottom: 18px; }
.kl-datum { font-family: var(--schrift-ue); font-size: 15px; margin-bottom: 7px;
  padding-bottom: 5px; border-bottom: 1px solid var(--linie); }
.kal-listentag .kal-eintrag { padding: 10px 12px; }
.kal-listentag .ke-titel { font-size: 14px; }

/* ═══ Anzeigen-Designer ═══════════════════════════════════════════════════
   Drei Spalten: Bibliothek, Leinwand, Eigenschaften. Die Flaeche selbst wird
   NICHT hier gestaltet — ihre Regeln stehen in akte.html unter
   `#anzDruckStil`, weil das Druckfenster genau denselben Text bekommt.
   Hier steht nur, was zum Werkzeug gehoert: Griffe, Auswahl, Galerie. */

.anz-kopfzeile { display: flex; align-items: flex-start; justify-content: space-between;
  gap: 16px; flex-wrap: wrap; margin-bottom: 14px; }

/* --- Liste ------------------------------------------------------------- */
.anz-zeile { display: flex; align-items: center; gap: 14px; padding: 12px 0;
  border-bottom: 1px solid var(--linie); }
.anz-zeile:first-child { border-top: 1px solid var(--linie); }
.anz-zeile-vorschau { flex: none; width: 64px; display: flex; justify-content: center; }
.anz-zeile-text { flex: 1; min-width: 0; }
.anz-zeile-text b { display: block; }
.anz-zeile-text small { color: var(--leise); font-size: 12.5px; }
.anz-zeile .nebenreihe { flex: none; }
.anz-offen { background: var(--pflaume-t); border-radius: 10px;
  margin: 0 -8px; padding: 12px 8px; }

/* --- Galerie ----------------------------------------------------------- */
.anz-galerie { width: min(1100px, 94vw); max-height: 92vh; border: 0; padding: 0;
  border-radius: var(--radius); box-shadow: 0 24px 70px rgba(26,15,23,.28);
  background: var(--karte); color: var(--tinte); overflow: hidden; }
.anz-galerie::backdrop { background: rgba(26,15,23,.45); }
.anz-galerie-kopf { display: flex; justify-content: space-between; align-items: flex-start;
  gap: 16px; padding: 20px 22px 14px; border-bottom: 1px solid var(--linie); }
.anz-galerie-kopf h2 { font-family: var(--schrift-ue); font-size: 21px; margin: 0; }
.anz-galerie-kopf button { flex: none; width: 36px; height: 36px; padding: 0;
  display: grid; place-items: center; border-radius: 9px; }
.anz-galerie-leib { display: grid; grid-template-columns: 300px 1fr;
  max-height: calc(92vh - 150px); }
@media (max-width: 860px) { .anz-galerie-leib { grid-template-columns: 1fr; } }
.anz-galerie-links { padding: 18px 22px; border-right: 1px solid var(--linie);
  overflow-y: auto; }
.anz-galerie-rechts { padding: 18px 22px; overflow-y: auto; background: var(--grund); }
.anz-galerie-rechts-kopf { display: flex; justify-content: space-between;
  align-items: flex-start; gap: 12px; margin-bottom: 14px; }
.anz-galerie-fuss { display: flex; justify-content: space-between; align-items: center;
  gap: 16px; padding: 14px 22px; border-top: 1px solid var(--linie); background: var(--karte); }
.schritt { font-size: 11.5px; text-transform: uppercase; letter-spacing: .07em;
  color: var(--leise); font-weight: 600; margin: 0 0 8px; }

.anz-formate { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; }
.anz-format { text-align: left; border: 1px solid var(--linie); background: var(--karte);
  border-radius: 10px; padding: 8px 10px; cursor: pointer; font: inherit; }
.anz-format b { display: block; font-size: 13px; }
.anz-format small { color: var(--leise); font-size: 11.5px; }
.anz-format:hover { border-color: var(--pflaume); }
.anz-format.aktiv { border-color: var(--pflaume); background: var(--pflaume-t);
  box-shadow: inset 0 0 0 1px var(--pflaume); }
.anz-preisschaetzung { font-size: 13px; margin: 10px 0 0; }
.anz-preisschaetzung small { color: var(--leise); display: block; }

.anz-vorlagen { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 14px; }
.anz-vorlage { display: flex; flex-direction: column; gap: 10px; text-align: left;
  border: 1px solid var(--linie); background: var(--karte); border-radius: 12px;
  padding: 12px; cursor: pointer; font: inherit; }
.anz-vorlage:hover { border-color: var(--pflaume); }
.anz-vorlage.aktiv { border-color: var(--pflaume); box-shadow: 0 0 0 2px var(--pflaume); }
.anz-vorlage-bild { display: flex; justify-content: center; align-items: center;
  min-height: 190px; background: var(--grund); border-radius: 8px; padding: 8px; }
.anz-vorlage-text b { display: block; font-size: 13.5px; margin-bottom: 4px; }
.anz-vorlage-text small { color: var(--leise); font-size: 11.5px; display: block;
  margin-top: 5px; line-height: 1.45; }
.anz-miniatur { overflow: hidden; box-shadow: 0 1px 6px rgba(26,15,23,.16); background: #fff; }

/* --- Werkzeugleiste ---------------------------------------------------- */
.anz-werkzeuge { display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  padding-bottom: 12px; border-bottom: 1px solid var(--linie); margin-bottom: 14px; }
.anz-titel { font-family: var(--schrift-ue); font-size: 17px; }
.anz-masse { color: var(--leise); font-size: 12.5px; }
.anz-werkzeuge-rechts { margin-left: auto; display: flex; gap: 6px; flex-wrap: wrap;
  align-items: center; }
/* .haupt und .neben sind fuer gestapelte Formulare gebaut (width 100 %,
   flex 1). In einer Werkzeugleiste muessen sie sich auf ihre Beschriftung
   zusammenziehen, sonst schiebt ein Knopf die Zeile auseinander. */
.anz-werkzeuge .neben, .anz-werkzeuge .haupt,
.anz-galerie-fuss .neben, .anz-galerie-fuss .haupt,
.anz-kopfzeile .haupt, .anz-zeile .neben {
  width: auto; flex: none; min-height: 38px; padding: 7px 13px;
  font-size: 13px; white-space: nowrap; border-radius: 10px;
}
.anz-werkzeuge .neben[title] { padding: 7px 11px; font-size: 15px; line-height: 1; }
.anz-zeile .neben { min-height: 34px; font-size: 12.5px; padding: 6px 11px; }

/* Ebenen und Elementaktionen: feste Zweierreihen statt Umbruch mitten im Wort. */
.anz-eigenschaften .nebenreihe { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.anz-eigenschaften .neben { width: auto; flex: none; min-height: 34px; padding: 6px 8px;
  font-size: 12.5px; white-space: nowrap; border-radius: 9px; }
.anz-status { font: inherit; font-size: 13px; padding: 7px 10px;
  border: 1px solid var(--linie); border-radius: 9px; background: var(--karte); }

.anz-befund { border: 1px solid var(--linie); border-left: 3px solid var(--warn);
  border-radius: 10px; padding: 12px 14px; margin-bottom: 14px; background: var(--karte); }
.anz-befund.gut { border-left-color: var(--gut); }
.anz-befund ul { margin: 8px 0 0; padding-left: 0; list-style: none; }
.anz-befund li { padding: 5px 0; font-size: 13px; line-height: 1.5; }
.anz-befund li small { color: var(--leise); }
.marke-fehler { background: #FDECEA; color: var(--warn); }
.marke-warnung { background: #FFF4E5; color: #8A5300; }
.marke-hinweis { background: var(--pflaume-t); color: var(--pflaume); }

/* --- Drei Spalten ------------------------------------------------------ */
/* Die Akte ist auf Lesebreite gesetzt: .flaeche auf 1080px, die
   Inhaltsspalte (ein <main>) auf 760px. Richtig fuer Formulare, zu eng fuer
   einen Designer mit drei Spalten und einer Leinwand in Originalgroesse.
   Solange der Editor offen ist, traegt <body> die Marke `anzeige-offen` und
   beide Grenzen fallen. */
body.anzeige-offen .flaeche { max-width: 1680px; }
body.anzeige-offen .akte-inhalt { max-width: none; }


.anz-raster { display: grid; gap: 16px; align-items: start; }
@media (min-width: 1180px) {
  .anz-raster { grid-template-columns: 238px minmax(0,1fr) 284px; }
}
.anz-bibliothek, .anz-eigenschaften { background: var(--karte); border: 1px solid var(--linie);
  border-radius: 12px; padding: 14px; }
.anz-eigenschaften h3 { font-size: 13px; text-transform: uppercase; letter-spacing: .06em;
  color: var(--leise); margin: 0 0 2px; }
@media (min-width: 1180px) {
  .anz-bibliothek, .anz-eigenschaften { position: sticky; top: 16px;
    max-height: calc(100vh - 40px); overflow-y: auto; }
}

.anz-reiter { display: flex; gap: 2px; border-bottom: 1px solid var(--linie);
  margin: -4px -4px 12px; }
.anz-reiter button { flex: 1; border: 0; background: none; font: inherit; font-size: 12.5px;
  padding: 8px 4px; cursor: pointer; color: var(--leise); border-bottom: 2px solid transparent; }
.anz-reiter button[aria-selected="true"] { color: var(--tinte); font-weight: 600;
  border-bottom-color: var(--pflaume); }

.anz-baustein { display: flex; align-items: center; gap: 10px; width: 100%; text-align: left;
  border: 1px solid var(--linie); background: var(--karte); border-radius: 10px;
  padding: 9px 11px; margin-bottom: 6px; cursor: pointer; font: inherit; }
.anz-baustein:hover { border-color: var(--pflaume); background: var(--pflaume-t); }
.anz-bs-icon { flex: none; width: 26px; height: 26px; display: grid; place-items: center;
  border-radius: 7px; background: var(--grund); font-size: 13px; color: var(--leise); }
.anz-baustein b { display: block; font-size: 13px; }
.anz-baustein small { color: var(--leise); font-size: 11.5px; }

.anz-suche { width: 100%; font: inherit; font-size: 13px; padding: 7px 10px;
  border: 1px solid var(--linie); border-radius: 9px; margin-bottom: 10px; }
.anz-motivgitter { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.anz-motivknopf { border: 1px solid var(--linie); background: var(--karte); border-radius: 9px;
  padding: 7px 4px; cursor: pointer; font: inherit; color: var(--tinte);
  display: flex; flex-direction: column; align-items: center; gap: 4px; }
.anz-motivknopf:hover { border-color: var(--pflaume); background: var(--pflaume-t); }
.anz-motivknopf.aktiv { border-color: var(--pflaume); box-shadow: inset 0 0 0 1px var(--pflaume); }
.anz-motivknopf small { font-size: 10px; color: var(--leise); line-height: 1.2;
  text-align: center; }
.anz-motiv-probe { width: 30px; height: 30px; display: block; }
.anz-hg-leer { width: 30px; height: 30px; border: 1px dashed var(--linie); border-radius: 5px; }

.anz-falldatum { display: block; width: 100%; text-align: left; border: 1px solid var(--linie);
  background: var(--karte); border-radius: 9px; padding: 7px 10px; margin-bottom: 5px;
  cursor: pointer; font: inherit; }
.anz-falldatum b { display: block; font-size: 12.5px; }
.anz-falldatum small { color: var(--leise); font-size: 11.5px; display: block;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.anz-falldatum:hover { border-color: var(--pflaume); background: var(--pflaume-t); }
.anz-falldatum.leer { border-color: #F3C9C4; }
.anz-falldatum.leer b, .anz-falldatum.leer small { color: var(--warn); }
.anz-fehlt-kasten { border: 1px dashed var(--linie); border-radius: 9px; padding: 8px 10px; }

/* --- Leinwand ---------------------------------------------------------- */
.anz-leinwand-rahmen { background: var(--karte); border: 1px solid var(--linie);
  border-radius: 12px; padding: 14px; min-width: 0; }
.anz-leinwand-kopf { display: flex; justify-content: space-between; align-items: center;
  gap: 12px; flex-wrap: wrap; margin-bottom: 10px; }
.anz-zoom { display: flex; align-items: center; gap: 6px; font-size: 12.5px;
  font-variant-numeric: tabular-nums; }
.anz-leinwand-platz { background: var(--grund); border-radius: 10px; padding: 16px;
  min-height: 420px; max-height: calc(100vh - 220px); overflow: auto;
  display: flex; justify-content: center; align-items: flex-start; }
.anz-blatt { position: relative; flex: none; box-shadow: 0 2px 16px rgba(26,15,23,.18);
  background: #fff; touch-action: none; }
.anz-blatt:focus-visible { outline: 2px solid var(--pflaume); outline-offset: 4px; }
.anz-fusszeile { margin: 8px 0 0; min-height: 18px; }

/* Der Sicherheitsrand ist eine Arbeitshilfe, keine Gestaltung — er wird
   nicht gedruckt (siehe blattMarkup). */
.anz-sicherheitsrand { position: absolute; border: 1px dashed rgba(112,72,97,.45);
  pointer-events: none; }
.anz-blatt .anz-e { cursor: move; }
.anz-blatt .anz-e:hover { outline: 1px solid rgba(112,72,97,.5); }
.anz-blatt .anz-e[data-gesperrt] { cursor: not-allowed; }
.anz-blatt .anz-e.gewaehlt { outline: 2px solid var(--pflaume); outline-offset: 1px; }
.anz-griff { position: absolute; right: -5px; bottom: -5px; width: 11px; height: 11px;
  background: var(--pflaume); border: 2px solid #fff; border-radius: 3px;
  cursor: nwse-resize; }

/* --- Textbausteine zur Auswahl ----------------------------------------- */
.baustein-knopf { border: 0; background: none; color: var(--pflaume); font-size: 12px;
  cursor: pointer; padding: 0 0 0 8px; text-decoration: underline; }
.anz-vorrat { border: 1px solid var(--linie); border-radius: 10px; margin-top: 6px;
  max-height: 210px; overflow-y: auto; background: var(--karte); box-shadow: var(--schatten); }
.anz-vorrat button { display: block; width: 100%; text-align: left; border: 0;
  background: none; padding: 9px 12px; cursor: pointer; font: inherit; font-size: 13px;
  border-bottom: 1px solid var(--linie); line-height: 1.45; }
.anz-vorrat button:last-child { border-bottom: 0; }
.anz-vorrat button:hover { background: var(--pflaume-t); }
.anz-vorrat small { display: block; color: var(--leise); font-size: 11.5px; margin-top: 2px; }
.anz-schalter { display: flex; align-items: center; gap: 7px; font-size: 13px; margin: 8px 0; }

/* ═══ Kundenaenderung an der Vorsorge ═════════════════════════════════════
   Der Kunde bearbeitet seine Planung im Konfigurator weiter. Der Berater
   muss sehen, DASS und WANN — sonst berät er auf einem alten Stand. */
.kundenband { display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  padding: 12px 18px; border-bottom: 1px solid var(--linie);
  background: var(--pflaume-t); }
.kundenband[data-gelesen="ja"] { background: var(--grund); }
.kb-punkt { flex: none; width: 9px; height: 9px; border-radius: 50%; background: var(--pflaume); }
.kundenband[data-gelesen="ja"] .kb-punkt { background: var(--linie); }
.kb-text { flex: 1; min-width: 220px; font-size: 13.5px; line-height: 1.5; }
.kb-text b { display: block; }
.kb-text span { color: var(--leise); font-size: 12.5px; }
.kundenband .neben { width: auto; flex: none; min-height: 34px; padding: 6px 12px;
  font-size: 12.5px; white-space: nowrap; border-radius: 9px; }
.kundenverlauf { padding: 14px 18px; border-bottom: 1px solid var(--linie); background: var(--karte); }
.kundenverlauf ol { list-style: none; margin: 0; padding: 0; }
.kundenverlauf li { display: flex; gap: 12px; padding: 7px 0; font-size: 13px;
  border-bottom: 1px solid var(--linie); }
.kundenverlauf li:last-child { border-bottom: 0; }
.kundenverlauf li b { min-width: 74px; }
.kundenverlauf li .wann { color: var(--leise); min-width: 130px; }
.kundenverlauf li .was { flex: 1; color: var(--tinte); }
/* Vorsorgeportal (11.10.2026): aktuelle Kundenwuensche ueber dem Verlauf */
.kundenverlauf .kv-portal { margin: 0 0 12px; padding: 10px 12px; border-radius: 8px; background: var(--grund, #FAF7F4); font-size: 13px; }
.kundenverlauf .kv-portal dl { display: grid; grid-template-columns: minmax(120px, max-content) 1fr; gap: 4px 14px; margin: 8px 0 0; }
.kundenverlauf .kv-portal dt { color: var(--leise); }
.kundenverlauf .kv-portal dd { margin: 0; white-space: pre-wrap; }
.kv-neu { color: var(--pflaume); font-weight: 600; }

/* Marke auf der Board-Karte: der Kunde hat seit dem letzten Blick geaendert. */
.fallkarte.fk-kunde-neu { border-left: 3px solid var(--pflaume); }
.fk-kunde { margin-top: 6px; font-size: 11.5px; font-weight: 600; color: var(--pflaume); }

/* --- Seitenleiste: Gruppen und Betriebswahl (25.10.2026) ------------------ */
.sl-gruppe { font-size: 11px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--leise);
  padding: 14px 12px 4px; margin: 0 !important; }
.sl-liste li.sl-gruppe:first-child { padding-top: 4px; }
.sl-liste a { min-height: 42px; padding: 9px 12px; }
.sl-sicht { margin: 12px 12px 2px; padding: 10px 12px; border-radius: 12px; background: var(--grund); border: 1px solid var(--linie); }
.sl-sicht label { display: block; font-size: 11px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--leise); margin-bottom: 5px; }
.sl-sicht select { width: 100%; border: 1.5px solid var(--linie); border-radius: 9px; padding: 8px 10px; background: var(--karte); font-size: 14px; cursor: pointer; }
.sl-sicht select:focus { outline: 2px solid var(--pflaume); border-color: var(--pflaume); }
.sl-sicht small { display: block; margin-top: 6px; font-size: 12px; color: var(--pflaume); line-height: 1.35; }
.sl-sicht.aktiv { background: var(--pflaume-t); border-color: #DCC7D3; }

/* ===================== Übersicht & Nachrichten (27.10.2026) =====================
   Vorbild envital: „Zu erledigen“ als Zeilen aus Zahl, Text und Pfeil, darunter
   das Postfach zweispaltig — links die Unterhaltungen, rechts der Verlauf. */
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.sl-zahl { margin-left: auto; min-width: 20px; padding: 0 6px; border-radius: 10px; background: var(--pflaume);
  color: #fff; font-size: 11.5px; font-weight: 700; line-height: 20px; text-align: center; }

.ue-raster { display: grid; gap: 16px; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); margin-bottom: 18px; }
@media (max-width: 900px) { .ue-raster { grid-template-columns: 1fr; } }
.ue-karte { background: var(--karte); border: 1px solid var(--linie); border-radius: 16px; box-shadow: var(--schatten); padding: 16px 18px; }
.ue-karte h2 { font-size: 19px; margin: 0 0 8px; }
.ue-zeile { display: flex; align-items: center; gap: 14px; padding: 11px 4px; border-top: 1px solid var(--linie);
  color: var(--tinte); text-decoration: none; cursor: pointer; background: none; border-left: 0; border-right: 0; border-bottom: 0;
  width: 100%; font: inherit; text-align: left; }
.ue-zeile:first-of-type { border-top: 0; }
.ue-zeile:hover { color: var(--pflaume); }
.ue-zeile b { min-width: 34px; font-size: 22px; font-weight: 600; font-variant-numeric: tabular-nums; color: var(--pflaume); }
.ue-zeile[data-null] b { color: var(--leise); font-weight: 400; }
.ue-zeile span { flex: 1; }
.ue-zeile i { font-style: normal; color: var(--leise); }

.postfach { display: grid; grid-template-columns: minmax(260px, 360px) minmax(0, 1fr); min-height: 520px; }
@media (max-width: 900px) { .postfach { grid-template-columns: 1fr; } .postfach[data-offen] .pf-liste { display: none; } }
.pf-liste { border-right: 1px solid var(--linie); max-height: 72vh; overflow-y: auto; }
.pf-eintrag { display: block; width: 100%; text-align: left; font: inherit; color: inherit; background: none; border: 0;
  border-bottom: 1px solid var(--linie); padding: 12px 14px; cursor: pointer; }
.pf-eintrag:hover { background: var(--grund); }
.pf-eintrag[aria-current="true"] { background: var(--pflaume-t); }
.pf-name { display: flex; align-items: center; gap: 8px; font-weight: 600; }
.pf-name time { margin-left: auto; font-weight: 400; color: var(--leise); font-size: 12.5px; white-space: nowrap; }
.pf-punkt { width: 9px; height: 9px; border-radius: 50%; background: var(--warn); flex: none; }
.pf-betreff { color: var(--leise); font-size: 13.5px; margin-top: 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pf-verlauf { padding: 16px 18px; min-width: 0; }
.pf-zurueck { display: none; }
@media (max-width: 900px) { .pf-zurueck { display: inline-flex; margin-bottom: 10px; } }

.uh-kopf { display: flex; gap: 12px; align-items: flex-start; flex-wrap: wrap; margin-bottom: 12px; }
.uh-kopf > div:first-child { flex: 1; min-width: 220px; }
.uh-kopf h2 { margin: 0; font-size: 20px; }
.uh-unter { color: var(--leise); font-size: 13.5px; margin-top: 4px; display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.uh-knoepfe { display: flex; gap: 8px; flex-wrap: wrap; }
.uh-knoepfe .sk-knopf { min-height: 38px; padding: 8px 14px; font-size: 14px; }
.uh-verlauf { display: flex; flex-direction: column; gap: 10px; max-height: 52vh; overflow-y: auto; padding: 4px 2px 12px; }
.nb { max-width: 84%; border-radius: 14px; padding: 10px 13px; background: var(--grund); border: 1px solid var(--linie); }
.nb-wir { align-self: flex-end; background: var(--pflaume-t); border-color: transparent; }
.nb-kopf { display: flex; gap: 10px; justify-content: space-between; font-size: 12.5px; color: var(--leise); margin-bottom: 4px; }
.nb-kopf b { color: var(--tinte); font-weight: 600; }
.nb-text { font-size: 15px; line-height: 1.55; overflow-wrap: anywhere; }
.uh-antwort textarea { width: 100%; box-sizing: border-box; border: 1.5px solid var(--linie); border-radius: 12px; padding: 10px 12px;
  font: inherit; resize: vertical; min-height: 84px; }
.uh-antwort textarea:focus { outline: none; border-color: var(--pflaume); }
.uh-fuss { display: flex; gap: 12px; align-items: center; justify-content: space-between; flex-wrap: wrap; margin-top: 8px; }
.uh-fuss span { color: var(--leise); font-size: 12.5px; flex: 1; min-width: 200px; }
.uh-hinweis { background: #FDEFD8; color: #7A4B00; border-radius: 12px; padding: 10px 13px; font-size: 14px; }

/* Akte: Reiter Übersicht */
.ak-raster { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); margin-bottom: 18px; }
.ak-box { border: 1px solid var(--linie); border-radius: 14px; padding: 14px 16px; background: var(--karte); }
.ak-box h3 { font-family: var(--schrift); font-size: 12.5px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase;
  color: var(--leise); margin: 0 0 8px; }
.ak-wert { font-size: 17px; font-weight: 600; }
.ak-klein { color: var(--leise); font-size: 13.5px; margin-top: 3px; }
.ak-liste { list-style: none; margin: 0; padding: 0; }
.ak-liste li { display: flex; gap: 10px; justify-content: space-between; padding: 6px 0; border-top: 1px solid var(--linie); font-size: 14.5px; }
.ak-liste li:first-child { border-top: 0; }
.ak-liste li span:first-child { color: var(--leise); }
.ak-liste li span:last-child { text-align: right; }
.datei { display: flex; align-items: center; gap: 12px; padding: 11px 0; border-top: 1px solid var(--linie); }
.datei:first-child { border-top: 0; }
.datei-symbol { width: 36px; height: 36px; border-radius: 10px; background: var(--pflaume-t); color: var(--pflaume); flex: none;
  display: grid; place-items: center; font-size: 11px; font-weight: 700; letter-spacing: .03em; }
.datei-was { flex: 1; min-width: 0; }
.datei-was b { display: block; font-weight: 600; }
.datei-was small { color: var(--leise); font-size: 13px; }
.datei .sk-knopf { min-height: 36px; padding: 7px 13px; font-size: 14px; }
.uh-klapp { border: 1px solid var(--linie); border-radius: 14px; margin-bottom: 10px; background: var(--karte); }
.uh-klapp > summary { list-style: none; cursor: pointer; padding: 12px 14px; display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.uh-klapp > summary::-webkit-details-marker { display: none; }
.uh-klapp > summary b { flex: 1; }
.uh-klapp > div { padding: 0 14px 14px; }
.kunde-hinweis { color: var(--pflaume); font-size: 13px; margin-top: 4px; }

/* Auswertung */
.aw-filter { display: flex; gap: 10px; flex-wrap: wrap; align-items: end; margin-bottom: 16px; }
.aw-filter .feld { margin: 0; min-width: 170px; }
.aw-balken { display: grid; grid-template-columns: minmax(120px, 34%) 1fr auto; gap: 6px 12px; align-items: center; font-size: 14.5px; }
.aw-balken .spur { height: 14px; border-radius: 7px; background: var(--grund); overflow: hidden; }
.aw-balken .fuell { height: 100%; border-radius: 7px; background: var(--pflaume); }
.aw-balken .zahl { font-variant-numeric: tabular-nums; text-align: right; white-space: nowrap; color: var(--leise); }
.aw-balken .zahl b { color: var(--tinte); }
.aw-tabelle td, .aw-tabelle th { padding: 9px 10px; font-variant-numeric: tabular-nums; }
.aw-tabelle td.leer { color: var(--linie); }
.aw-balken .fuell { display: block; }
.ak-box a { color: var(--pflaume); }

/* ═══ Board für viele Vorsorgen (29.10.2026) ═══════════════════════════════
   Bis zu 1000 laufende Vorsorgen: Filter oben gelten fuer Board und Vollbild,
   jede Spalte laesst sich mit allen Eintraegen als Liste oeffnen. */
.bf-karte { margin-bottom: 14px; }
.bf-zeile { display: flex; flex-wrap: wrap; gap: 10px 12px; align-items: flex-end; padding: 14px 16px 6px; }
.bf-suche { flex: 1 1 260px; margin: 0; }
.bf-suche input { min-height: 42px; }
.bf-wahl { display: flex; flex-direction: column; gap: 3px; font-size: 12px; color: var(--leise); }
.bf-wahl select { min-height: 42px; padding: 8px 10px; border: 1.5px solid var(--linie);
  border-radius: 10px; background: #fff; color: var(--tinte); font-size: 14px; max-width: 220px; }
.bf-wahl select:focus { outline: 2px solid var(--pflaume); border-color: var(--pflaume); }
.bf-zurueck { min-height: 42px; padding: 8px 14px; font-size: 14px; }
.bf-merker { padding: 6px 16px 14px; }
.bf-merker button { min-height: 36px; padding: 6px 13px; font-size: 13.5px; }

.spalte h2 { align-items: center; }
.sp-rechts { display: inline-flex; align-items: center; gap: 6px; }
.sp-zahl { font-variant-numeric: tabular-nums; }
.sp-voll { border: 0; background: var(--karte); color: var(--pflaume); border-radius: 7px;
  width: 28px; height: 28px; cursor: pointer; font-size: 15px; line-height: 1; }
.sp-voll:hover { background: var(--pflaume); color: #fff; }
.sp-mehr { width: 100%; min-height: 38px; border: 1.5px dashed var(--pflaume); background: transparent;
  color: var(--pflaume); border-radius: 10px; font-weight: 600; font-size: 13.5px; cursor: pointer; }
.sp-mehr:hover { background: var(--karte); }
.spalte.sp-online { background: #FDF3E4; }
.spalte.sp-online h2 { color: #7A4B00; }
.sp-hinweis { font-size: 12px; color: #7A4B00; margin: -4px 6px 10px; line-height: 1.4; }

.fk-info { font-size: 12.5px; margin-top: 3px; }
.fk-marken { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px; }
.fk-marken:empty { display: none; }
.fk-marke { font-size: 11px; font-weight: 600; border-radius: 999px; padding: 1px 8px;
  background: var(--pflaume-t); color: var(--pflaume); }
.fk-marke.fk-online { background: #FDEFD8; color: #7A4B00; }
.fk-marke.fk-warn { background: #F9E3E1; color: var(--warn); }
.fk-wer { font-size: 11px; color: var(--leise); margin-left: auto; }
.fk-pruefen { margin-top: 8px; width: 100%; min-height: 34px; border: 0; border-radius: 9px;
  background: var(--pflaume); color: #fff; font-weight: 600; font-size: 13px; cursor: pointer; }
.vb .fk-pruefen { width: auto; padding: 4px 14px; margin-top: 4px; }

.vb-kopf { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-bottom: 12px; }
.vb-kopf .sk-knopf { min-height: 40px; padding: 8px 14px; font-size: 14px; }
.vb-phasen { flex-wrap: wrap; }
.vb-n { font-variant-numeric: tabular-nums; color: var(--leise); font-weight: 400; margin-left: 3px; }
.vb-hinweis { background: #FDF3E4; color: #7A4B00; border-radius: 10px; padding: 10px 14px;
  font-size: 13.5px; margin: 0 0 12px; }
.vb-sammel { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin: 0 0 12px;
  padding: 10px 14px; background: var(--pflaume-t); border-radius: 12px; font-size: 14px;
  position: sticky; top: 8px; z-index: 6; }
.vb-sammel label { display: inline-flex; align-items: center; gap: 6px; }
.vb-sammel select { min-height: 38px; border: 1.5px solid var(--linie); border-radius: 9px; padding: 6px 8px; background: #fff; }
.vb-sammel .sk-knopf { min-height: 38px; padding: 7px 14px; font-size: 14px; }
.vb-tabelle td, .vb-tabelle th { padding: 10px 8px; font-size: 14px; }
.vb-tabelle td[data-spalte="_haupt"]:nth-child(2) { min-width: 190px; }
.vb-tabelle .pille { white-space: nowrap; font-size: 12px; }
.vb-tabelle td[data-spalte="Hinweise"] { min-width: 150px; }
@media (min-width: 768px) { .vb-rolle { overflow-x: auto; } }
#vbGanz { margin-left: auto; }
.bf-auf { display: none; }
@media (max-width: 767px) {
  .bf-auf { display: inline-flex; min-height: 42px; padding: 8px 14px; font-size: 14px; }
  .bf-suche { flex: 1 1 0; min-width: 0; }
  .bf-karte.zu .bf-wahl, .bf-karte.zu .bf-zurueck { display: none; }
  .bf-wahl { flex: 1 1 45%; }
  .bf-wahl select { max-width: none; width: 100%; }
  #vbGanz { display: none; }
  .vb-phasen { width: 100%; }
}
.vb-tabelle th { position: sticky; top: 0; background: var(--karte); z-index: 2; }
.vb-wahl { width: 34px; }
.vb-wahl input { width: 18px; height: 18px; cursor: pointer; }
.vb-kunde { color: var(--pflaume); font-size: 12.5px; }
.vb-warn { color: var(--warn); font-size: 12.5px; }
.vb-seiten { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: flex-end;
  margin-top: 12px; font-size: 14px; color: var(--leise); }
.vb-seiten .sk-knopf { min-height: 38px; padding: 7px 14px; font-size: 14px; }
.vb-seiten .sk-knopf:disabled { opacity: .45; cursor: default; }
:fullscreen .flaeche { padding-top: 16px; }
html:fullscreen { background: var(--grund); overflow: auto; }

.pr-text { font-size: 14px; color: var(--leise); margin: 0 0 14px; line-height: 1.5; }
.dubletten { background: #FDF3E4; border-radius: 10px; padding: 10px 14px; margin: 0 0 14px; font-size: 13.5px; }
.dubletten ul { margin: 6px 0; padding-left: 18px; }
.dubletten a { color: var(--pflaume); font-weight: 600; }

/* Akte: noch ungeprüfte Vorsorge aus dem Portal */
.pruefband { display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  padding: 12px 18px; border-bottom: 1px solid var(--linie); background: #FDF3E4; }
.pruefband .kb-punkt { background: #C77A00; }
.pruefband .sk-knopf { min-height: 38px; padding: 7px 16px; font-size: 14px; }
.ak-einladen { margin-top: 6px; }
.ak-einladen .sk-knopf { min-height: 34px; padding: 5px 12px; font-size: 13px; }

/* ==========================================================================
   Anfragen 13.11.2026 (Rückmeldung Volker Mechler): Anliegen mit Zeichen und
   Farbgruppe, Eingangskanal als Symbol, Zuständigkeit, breitere Dialoge.
   ========================================================================== */
.ico { flex: none; vertical-align: middle; }
[data-gruppe="bestattung"] { --g-f: #A3231B; --g-h: #FBE4E2; --g-s: #C62F25; }
[data-gruppe="vorsorge"]   { --g-f: #94470A; --g-h: #FDEBD9; --g-s: #E07B1F; }
[data-gruppe="anfrage"]    { --g-f: #6B5400; --g-h: #FBF1C4; --g-s: #D9AC00; }
[data-gruppe="termin"]     { --g-f: #1F4F8F; --g-h: #E1ECFA; --g-s: #3B7DD8; }
[data-gruppe="bestand"]    { --g-f: #1E6B40; --g-h: #E3EFE8; --g-s: #3E9B66; }
[data-gruppe="sonst"]      { --g-f: #5C4F57; --g-h: #EEEAEC; --g-s: #9A8B94; }
.anliegen { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap;
  background: var(--g-h); color: var(--g-f); border-radius: 8px; padding: 3px 9px 3px 6px;
  font-size: 13px; font-weight: 600; }
.anliegen.gross { font-size: 15px; padding: 6px 12px 6px 9px; border-radius: 10px; }
.anliegen.gross .ico { width: 22px; height: 22px; }
.kanal { display: inline-flex; color: var(--leise); }
.af-tabelle tbody tr { border-left: 0; }
.af-tabelle tbody td:first-child { box-shadow: inset 4px 0 0 var(--g-s, transparent); padding-left: 14px; }
.af-tabelle .af-kurz { font-weight: 600; margin-top: 3px; max-width: 46ch; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.af-tabelle .af-name { display: flex; align-items: center; gap: 8px; }
.af-wer { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; white-space: nowrap; }
.af-wer .kuerzel { width: 26px; height: 26px; border-radius: 50%; background: var(--pflaume-t); color: var(--pflaume);
  display: inline-grid; place-items: center; font-size: 11.5px; font-weight: 700; }
.af-wer.topf { color: var(--leise); font-style: italic; }
.af-wer.ich .kuerzel { background: var(--pflaume); color: #fff; }
@media (max-width: 767px) {
  .af-tabelle tbody tr { border-left: 5px solid var(--g-s, var(--linie)); }
  .af-tabelle tbody td:first-child { box-shadow: none; padding-left: 0; }
  .af-tabelle .af-kurz { white-space: normal; }
}
.af-filter { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; width: 100%; }
.af-filter .filter { padding: 0; flex: 1 1 auto; }
.af-filter .filter button .zahl { opacity: .75; font-variant-numeric: tabular-nums; margin-left: 4px; }
.af-filter select { min-height: 40px; border: 1.5px solid var(--linie); border-radius: 10px; padding: 6px 10px; background: #fff; font-size: 14px; }

/* Breite Dialoge: Fläche am Schreibtisch nutzen */
@media (min-width: 700px) {
  dialog.breit { width: min(1120px, 96vw); max-height: 92vh; }
  dialog.mittel { width: min(820px, 96vw); max-height: 92vh; }
}
.zeile3 { display: grid; grid-template-columns: 1fr; gap: 10px; }
@media (min-width: 640px) { .zeile3 { grid-template-columns: 1fr 1fr 1fr; } }
.tel-zeile { display: flex; gap: 6px; }
.tel-zeile .tel-land { flex: 0 0 96px; min-height: 46px; border: 1.5px solid var(--linie); border-radius: 10px; padding: 0 6px; background: #fff; font-size: 14px; }
.tel-zeile input { flex: 1; min-width: 0; }
.feld-hinweis { font-size: 12.5px; margin-top: 4px; color: var(--leise); min-height: 0; }
.feld-hinweis:empty { display: none; }
.feld-hinweis[data-art="fehler"] { color: var(--warn); font-weight: 600; }
.feld-hinweis[data-art="warnung"] { color: #8A5300; }
.feld input[aria-invalid] { border-color: var(--warn); }
.feld textarea.gross { min-height: 180px; }

/* Detail: links Inhalt, rechts eine schmale Steuerleiste */
.af-detail { display: grid; grid-template-columns: 1fr; gap: 18px; }
@media (min-width: 900px) { .af-detail { grid-template-columns: minmax(0, 1fr) 280px; align-items: start; } }
.af-kopfband { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; margin-bottom: 12px; }
.af-kopfband .tz-neben { display: inline-flex; align-items: center; gap: 6px; }
.af-seite { background: var(--grund); border: 1px solid var(--linie); border-radius: 14px; padding: 14px; }
@media (min-width: 900px) { .af-seite { position: sticky; top: 64px; } }
.af-seite .feld { margin-bottom: 12px; }
.af-seite .feld select, .af-seite .feld input { min-height: 40px; padding: 6px 10px; }
.af-seite .neben { min-height: 40px; font-size: 14px; width: 100%; flex: none; }
.af-seite .af-knoepfe { display: grid; gap: 8px; }
.af-uebernehmen { border: 0; background: none; color: var(--pflaume); font-weight: 600; cursor: pointer; padding: 4px 0 0; font-size: 13.5px; }
.af-status-wahl { display: flex; align-items: center; gap: 8px; }
.af-status-wahl .punkt { width: 10px; height: 10px; border-radius: 50%; background: var(--pflaume); flex: none; }
.af-status-wahl .punkt[data-farbe="warten"] { background: #C77A00; }
.af-status-wahl .punkt[data-farbe="fertig"] { background: var(--gut); }
.af-status-wahl .punkt[data-farbe="aktiv"] { background: #3B7DD8; }
.af-notizbox { background: #fff; border: 1px solid var(--linie); border-radius: 12px; padding: 12px 14px; white-space: pre-line;
  max-height: 340px; overflow: auto; line-height: 1.55; }
.af-kontakt { display: grid; gap: 10px; grid-template-columns: 1fr; margin-bottom: 4px; }
@media (min-width: 640px) { .af-kontakt { grid-template-columns: 1.1fr 1fr; } }
.af-waehlen { display: inline-flex; align-items: center; gap: 6px; color: var(--pflaume); font-weight: 600; text-decoration: none; font-size: 13.5px; margin-top: 4px; }
.verlauf li[data-art="zuweisung"]::before { background: #3B7DD8; }
.verlauf li[data-art="status"]::before { background: var(--leise); }
