/* B7b · Knospen am Baum (Basis B3b). Farben nur über die App-Variablen (brand.css), Bauteile aus ui.css und baum.css.
   Marke Manual v1.1: Knöpfe nur als Kontur-Pille, gewählt = Fläche #EDE8E5 plus Kontur, keine Schatten, kein Rot, keine Verläufe.
   Schriftgrößen: 40 (Titel, am Handy 24), 16, 13. */
:root { --kopf-h: 190px; --sch-h: 0px; }
html[data-theme="light"] { --bg-s1: #F7F4F2; }
body { margin: 0; }
html, body { height: 100%; }
body { overflow: hidden; }
.seite { height: 100dvh; display: flex; flex-direction: column; overflow: hidden; }

/* ---------- Marke v1.1: Überschreibungen der gemeinsamen Bauteile ---------- */
:focus-visible { outline: 1px solid var(--text-primary); outline-offset: 0; }
.pille[aria-pressed="true"] { background: var(--sel-bg, #EDE8E5); color: var(--sel-fg, #0A0708); border-color: var(--sel-line, #B0ADAC); }
.pille[aria-pressed="true"] .art { color: var(--text-secondary); opacity: 1; }
.schalter[aria-checked="true"] { background: var(--sel-bg, #EDE8E5); color: var(--sel-fg, #0A0708); border-color: var(--sel-line, #B0ADAC); }
.schalter[aria-checked="true"] .spur { border-color: var(--text-primary); }
.schalter[aria-checked="true"] .knauf { background: var(--text-primary); transform: translateX(12px); }
.b-nr { background: var(--bg-body); color: var(--text-primary); border: 1px solid var(--text-primary); line-height: 22px; }
.z-status[data-status="erreicht"] { background: var(--sel-bg, #EDE8E5); color: var(--sel-fg, #0A0708); }
.sb-toast { background: var(--bg-body); color: var(--text-primary); border: 1px solid var(--text-primary); }
.pille, .icon-knopf, .schalter { transition: background var(--dur-base) var(--ease-out), border-color var(--dur-base) var(--ease-out), transform var(--dur-fast) var(--ease-out); }
.pille:active:not(:disabled), .icon-knopf:active:not(:disabled), .schalter:active { transform: scale(.98); }
.icon-knopf:disabled { opacity: .45; cursor: default; }
.feld, .kn-feld { background: #FFFFFF; }

/* ---------- Kopf ---------- */
.kopf { flex: none; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; grid-template-areas: "zur wahl werkzeuge" "titel titel titel"; align-items: center; gap: 8px 16px; padding: 12px 24px 4px; }
.zur-link { grid-area: zur; display: inline-flex; align-items: center; gap: 4px; font-size: var(--s-klein); font-weight: 600; color: var(--text-secondary); min-height: 40px; }
.kundenwahl { grid-area: wahl; display: flex; gap: 8px; flex-wrap: wrap; min-width: 0; }
.werkzeuge { grid-area: werkzeuge; display: flex; gap: 12px; align-items: center; }
.kopf-b { grid-area: titel; display: flex; align-items: center; gap: 4px 24px; flex-wrap: wrap; min-width: 0; }
.titel { font-size: var(--s-gross); }
.kunde-name { margin: 0; font-size: var(--s-text); font-weight: 600; }

/* ---------- Satz statt Lagebild ---------- */
.satz-zeile { flex: none; display: flex; align-items: center; gap: 8px 24px; padding: 4px 24px 8px; min-width: 0; }
.satz { flex: 1 1 auto; min-width: 0; margin: 0; font-size: var(--s-text); line-height: 1.7; }
.satz-teil { display: inline-block; padding: 1px 10px; margin: 0 -2px; border: 1px solid transparent; border-radius: 999px; background: none; font: inherit; font-weight: 600; line-height: 1.5; text-align: left; color: var(--text-primary); transition: border-color var(--dur-base) var(--ease-out), background var(--dur-base) var(--ease-out); }
button.satz-teil:hover { border-color: var(--kontur); }
button.satz-teil[aria-pressed="true"] { background: var(--sel-bg, #EDE8E5); border-color: var(--sel-line, #B0ADAC); }
.satz-teil.still { cursor: default; }
#alle-knoepfe { flex: none; }

/* Die nächsten fünf: Mini-Thumbnails mit Nummer, ohne Text */
.n5-leiste { flex: none; display: flex; align-items: center; gap: 8px; min-width: 0; }
.n5t { flex: none; padding: 0; border: 0; background: none; }
.n5t .b-bild { width: 34px; border-radius: 10px; display: flex; align-items: center; justify-content: center; }
.n5t .b-nr { top: 4px; left: 4px; width: 20px; height: 20px; line-height: 18px; }
.n5t:hover .b-bild { outline: 1px solid var(--text-primary); outline-offset: 2px; }

/* ---------- Werkbank ---------- */
.werkbank { flex: none; display: flex; align-items: center; gap: 12px 16px; margin: 4px 24px 8px; padding: 6px 8px 6px 20px; border: 1px solid var(--kontur); border-radius: 999px; background: var(--bg-s1); }
.werkbank[hidden] { display: none; }
.wb-titel { font-size: var(--s-klein); font-weight: 600; color: var(--text-secondary); flex: none; }
.wb-teile { display: flex; gap: 8px; flex: none; }
.pille.teil { cursor: grab; user-select: none; -webkit-user-select: none; gap: 6px; }
.pille.teil .sb-icon { opacity: .7; }
.meldung { margin: 0 12px 0 auto; font-size: var(--s-klein); color: var(--text-secondary); line-height: 1.35; text-align: right; min-width: 0; }
.meldung.hat-text { color: var(--text-primary); font-weight: 600; }

/* ---------- Plattformen (Desktop: nur Symbole, Handy: eine auf einmal mit Namen) ---------- */
.aeste { display: flex; gap: 8px; margin-left: auto; overflow-x: auto; scrollbar-width: none; position: relative; }
.aeste::-webkit-scrollbar { display: none; }
.aeste .pille { flex: none; }
.pille.ic { width: 44px; padding: 0; justify-content: center; }

/* ---------- Arbeitsfläche: der Baum, daneben bei Bedarf Platz für das Panel ---------- */
.arbeit { flex: 1; min-height: 0; display: grid; grid-template-rows: minmax(0, 1fr); grid-template-columns: minmax(0, 1fr) 0; transition: grid-template-columns var(--dur-base) var(--ease-out); }
body.panel-auf .arbeit { grid-template-columns: minmax(0, 1fr) clamp(300px, 26vw, 360px); }
.panel-platz { min-width: 0; }
.spalte-baum { position: relative; min-width: 0; min-height: 0; display: flex; flex-direction: column; }
.flaeche { flex: 1; min-height: 0; min-width: 0; display: flex; flex-direction: column; }
#baum.baum { flex: 1; min-height: 0; display: flex; flex-direction: column; overflow-x: auto; overflow-y: auto; }
#baum .baum-innen { flex: none; margin-top: auto; margin-bottom: auto; }
.baum .baum-linien { max-width: 100%; max-height: 100%; }
.baum .k-konto .kn-name, .baum .k-ziel .kn-name { -webkit-line-clamp: 3; hyphens: manual; -webkit-hyphens: manual; }
@media (min-width: 720px) { .baum .baum-innen { padding-left: 40px; padding-right: 40px; } }
.baum .plat > .k-konto { width: min(100%, 640px); min-width: 0; align-self: center; }

/* ---------- Der Baum zeigt den Stand selbst ---------- */
/* Stamm mit Coins je Monat (drei Chips, Füllung = Verbrauch gegen Guthaben, dicker Rand = drüber) */
.baum .k-stamm { border-radius: 28px; padding: 8px 24px 10px; max-width: 700px; }
.stamm-coins { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 8px; margin-top: 6px; }
.stamm-coins .mo { position: relative; overflow: hidden; display: inline-flex; align-items: center; padding: 3px 12px; border: 1px solid var(--text-primary); border-radius: 999px; background: none; font-size: var(--s-klein); line-height: 1.3; white-space: nowrap; color: var(--text-primary); }
.stamm-coins .mo:hover { background: var(--bg-s2); }
.mo-fuell { position: absolute; left: 0; top: 0; bottom: 0; background: var(--bg-s2); }
.mo-t { position: relative; }
.mo-t strong { font-weight: 600; }
.stamm-coins .mo.leise { border-color: var(--kontur); color: var(--text-secondary); }
.stamm-coins .mo.ueber { border-width: 2px; padding: 2px 11px; font-weight: 600; }
.stamm-coins .mo.treffer { outline: 1px solid var(--text-primary); outline-offset: 2px; }

/* Zielgruppen als Wurzeln: Füllung nach Abdeckung, zu kurz = gestrichelt und fast leer, ohne Satz */
.k-zg { position: relative; overflow: hidden; min-height: 44px; justify-content: center; cursor: pointer; }
.zg-fuell { position: absolute; inset: 0; pointer-events: none; }
.zg-fuell i { position: absolute; left: 0; right: 0; bottom: 0; background: var(--bg-s2); }
.k-zg .kn-name { position: relative; }

/* Plattform zu: je Ziel ein kleiner Balken (Strich = Soll heute) */
.mini-ziele { display: flex; justify-content: center; gap: 6px; margin-top: 8px; }
.mz { position: relative; display: block; width: 36px; height: 4px; border-radius: 2px; background: var(--line); }
.mz i { display: block; height: 100%; border-radius: 2px; background: var(--text-primary); }
.mz b { position: absolute; top: -3px; width: 1px; height: 10px; background: var(--text-primary); }

/* Richtung zu: eine Zahl und Knospen-Punkte */
.kn-zahlen { display: inline-flex; align-items: center; gap: 6px; font-size: var(--s-klein); line-height: 1.3; color: var(--text-secondary); }
.kn-knosp { display: inline-flex; gap: 3px; }
.kn-knosp i { display: block; width: 9px; height: 15px; border: 1px dashed var(--text-secondary); border-radius: 4px; }

/* Knospen am Zweig */
.knospe.neu .kn-bild { border-style: solid; border-color: var(--text-primary); }
.knospe:focus-visible .kn-bild { border-style: solid; border-color: var(--text-primary); }
button.luecke-blatt:not(:disabled) .sb-icon { color: var(--text-secondary); }

/* Plus am Zweig: am Desktop beim Überfahren, am Handy immer */
.plus-z { opacity: 0; transition: opacity var(--dur-fast) var(--ease-out); }
.zweig:hover .plus-z, .k-richtung:focus-within .plus-z, .plus-z:focus-visible { opacity: 1; }
@media (hover: none), (max-width: 719px) { .plus-z { opacity: 1; } }
body.bearbeiten .plus-z, body.kundenmodus .plus-z, body.zieht-gerade .plus-z { display: none; }

/* ---------- Ablegen: ruhig zeigen, wo ein Fund hinkann ---------- */
#baum.ablegen .k-richtung:not(.leer), #baum.ablegen .k-an[data-id] { outline: 1px dashed var(--kontur); outline-offset: 3px; cursor: copy; }
#baum.ablegen .blatt, #baum.ablegen .knospe, #baum.ablegen .luecke-blatt { opacity: .55; }
#baum.ablegen .ablage-ziel { outline: 2px solid var(--text-primary); background: var(--bg-s2); }
#baum.ablegen .plus-z { display: none; }
.zieh-geist { position: fixed; left: 0; top: 0; z-index: 60; pointer-events: none; padding: 8px 16px; border: 1px solid var(--text-primary); border-radius: 999px; background: var(--bg-body); font-size: var(--s-klein); font-weight: 600; line-height: 1.2; white-space: nowrap; max-width: 260px; overflow: hidden; text-overflow: ellipsis; }

/* ---------- Sammlungs-Schublade (unten angedockt, nur Team) ---------- */
.schublade { flex: none; border-top: 1px solid var(--line); padding: 0 24px; background: var(--bg-body); }
.schublade:empty, body.bearbeiten .schublade { display: none; }
.sch-kopf { display: flex; align-items: center; min-height: 52px; }
.sch-knopf { gap: 8px; }
.sch-pfeil { display: inline-flex; transform: rotate(180deg); transition: transform var(--dur-base) var(--ease-out); }
.sch-knopf[aria-expanded="true"] .sch-pfeil { transform: none; }
.sch-hinweis { margin: 0 0 10px; font-size: var(--s-klein); line-height: 1.4; color: var(--text-secondary); }
.sch-liste { display: flex; gap: 10px; overflow-x: auto; padding: 4px 0 16px; scrollbar-width: thin; }
.sch-leer, .pm-leer { margin: 0; font-size: var(--s-klein); color: var(--text-secondary); }
.fund { flex: none; display: flex; align-items: center; gap: 10px; width: 216px; padding: 6px 14px 6px 6px; border: 1px solid var(--kontur); border-radius: 20px; background: none; text-align: left; touch-action: pan-x; -webkit-user-select: none; user-select: none; cursor: grab; }
.fund:hover { border-color: var(--text-primary); }
.fund[aria-pressed="true"] { background: var(--sel-bg, #EDE8E5); border-color: var(--sel-line, #B0ADAC); }
.fund.gezogen { opacity: .35; }
.fund-bild { flex: none; display: flex; align-items: center; justify-content: center; width: 40px; height: 72px; border-radius: 12px; overflow: hidden; background: var(--bg-s2); }
.fund.geprueft .fund-bild { border: 1px dashed var(--text-secondary); }
.fund-bild img { width: 100%; height: 100%; object-fit: cover; -webkit-user-drag: none; }
.fund-text { display: grid; gap: 4px; min-width: 0; align-content: center; }
.fund-t { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; font-size: var(--s-klein); font-weight: 600; line-height: 1.3; }
.fund-meta { display: flex; gap: 6px; align-items: center; color: var(--text-secondary); }

/* ---------- Plus-Menü und Grundimage-Blatt (liegen am body) ---------- */
.plus-menu { position: fixed; z-index: 48; width: min(420px, calc(100vw - 24px)); max-height: min(72dvh, 560px); overflow-y: auto; display: grid; gap: 10px; align-content: start; padding: 14px 16px 16px; border: 1px solid var(--text-primary); border-radius: 20px; background: var(--bg-body); animation: sb-auftritt var(--dur-slow) var(--ease-out) both; }
.plus-menu[hidden] { display: none; }
.pm-kopf { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.pm-t { font-size: var(--s-text); font-weight: 600; line-height: 1.3; }
.pm-et { margin: 0; font-size: var(--s-klein); color: var(--text-secondary); }
.pm-funde { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 6px; scrollbar-width: thin; }
.pm-fund { flex: none; display: flex; align-items: center; gap: 8px; width: 168px; padding: 4px 10px 4px 4px; border: 1px solid var(--kontur); border-radius: 16px; background: none; text-align: left; }
.pm-fund:hover { border-color: var(--text-primary); }
.pm-fund .fund-bild { width: 32px; height: 58px; border-radius: 10px; }
.pm-zeile { display: flex; gap: 8px; align-items: center; }
.pm-zeile .feld { height: 40px; min-width: 0; }
.pm-fuss { padding-top: 2px; }
.frage-blatt { position: fixed; z-index: 49; width: min(300px, calc(100vw - 16px)); display: grid; gap: 6px; padding: 12px 14px 14px; border: 1px solid var(--text-primary); border-radius: 20px; background: var(--bg-body); animation: sb-auftritt var(--dur-slow) var(--ease-out) both; }
.frage-blatt[hidden] { display: none; }
.fb-kopf { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; }
.fb-t { font-size: var(--s-text); font-weight: 600; line-height: 1.3; }
.fb-gi, .fb-ziel { margin: 0; font-size: var(--s-klein); line-height: 1.4; color: var(--text-secondary); }
.frage-blatt .pillen { margin-top: 4px; }

/* ---------- Panels (Weg, Einplanen, Ziel, Coins, Beitrag direkt planen) ---------- */
.weg-panel { position: fixed; z-index: 30; right: 16px; top: calc(var(--kopf-h) + 8px); width: 400px; max-height: calc(100dvh - var(--kopf-h) - 20px); }
@media (min-width: 720px) { .weg-panel { right: 12px; width: calc(clamp(300px, 26vw, 360px) - 12px); } }
.weg-link { flex: none; padding: 12px 20px; border-top: 1px solid var(--line); background: var(--bg-s1); }
.cp-liste { display: grid; gap: 4px; }
.cp-monat { display: grid; width: 100%; padding: 10px 12px; border: 1px solid transparent; border-radius: 12px; background: none; text-align: left; align-content: start; }
.cp-monat:hover { border-color: var(--kontur); }
.cp-monat[aria-pressed="true"] { border-color: var(--sel-line, #B0ADAC); background: var(--sel-bg, #EDE8E5); }
.cp-zeile .lb-text { margin: 0 0 4px; }
.lb-text { font-size: var(--s-klein); line-height: 1.4; }
.lb-sek { color: var(--text-secondary); }
.lb-fett { font-weight: 600; }
.lb-name { font-size: var(--s-klein); font-weight: 600; line-height: 1.35; }
.lb-hinweis { margin: 8px 0 0; font-size: var(--s-klein); line-height: 1.4; color: var(--text-secondary); }
.lb-bar { position: relative; display: block; height: 4px; margin: 10px 0 8px; border-radius: 2px; background: var(--line); }
.lb-bar i { display: block; height: 100%; border-radius: 2px; background: var(--text-primary); }
.lb-bar s { position: absolute; top: -1px; height: 6px; box-sizing: border-box; text-decoration: none; border: 1px dashed var(--text-primary); border-radius: 3px; background: transparent; }
.lb-bar b { position: absolute; top: -4px; width: 2px; height: 12px; margin-left: -1px; border-radius: 1px; background: var(--text-primary); }

/* ---------- Anpassen (Baum direkt anfassen, wie in B3b) ---------- */
.baum.anpassen .knoten[data-knoten]:not(.k-wurzel):not(.k-zg) { cursor: grab; user-select: none; -webkit-user-select: none; }
.baum.anpassen .knoten[data-knoten]:not(.k-wurzel):not(.k-zg):hover, .baum.anpassen .knoten[data-knoten]:not(.k-wurzel):not(.k-zg):focus-visible { outline: 1px dashed var(--text-primary); outline-offset: 2px; }
.baum.anpassen .knoten.gewaehlt[data-knoten]:not(.k-wurzel) { outline: 2px solid var(--text-primary); outline-offset: 2px; }
.baum.anpassen .blatt, .baum.anpassen .knospe { user-select: none; -webkit-user-select: none; }
.baum.zieht .knoten[data-knoten]:not(.gueltig):not(.gewaehlt) { opacity: .35; }
.baum.anpassen.zieht .knoten[data-knoten]:not(.gueltig):not(.gewaehlt):not(.k-wurzel) { outline-color: transparent; }
.baum.zieht .blatt, .baum.zieht .knospe, .baum.zieht .luecke-blatt { opacity: .55; }
.baum.zieht .knoten.gueltig[data-knoten], .baum.anpassen.zieht .knoten.gueltig[data-knoten]:not(.k-wurzel) { outline: 2px dashed var(--text-primary); outline-offset: 3px; cursor: copy; }
.baum.zieht .knoten.gueltig.aktiv[data-knoten], .baum.anpassen.zieht .knoten.gueltig.aktiv[data-knoten]:not(.k-wurzel) { outline-style: solid; background: var(--bg-s1); }
.baum.zieht .knoten.selbst { opacity: .4; }
.baum.zieht .k-wurzel.gueltig { padding-bottom: 8px; }
.kn-feld { width: 100%; min-width: 0; font: inherit; font-size: var(--s-klein); font-weight: 600; color: var(--text-primary); text-align: center; border: 1px solid var(--text-primary); border-radius: 8px; padding: 6px 8px; }
.k-ziel .kn-feld { font-size: var(--s-text); }
.kn-feld:focus-visible { outline: none; }
body.zieht-gerade { user-select: none; -webkit-user-select: none; cursor: grabbing; }
body.zieht-gerade * { cursor: grabbing !important; }
.einfuege { position: fixed; z-index: 59; width: 2px; border-radius: 1px; background: var(--text-primary); pointer-events: none; }
.einfuege[hidden] { display: none; }

.ablage { position: fixed; right: 24px; bottom: 24px; z-index: 25; display: flex; align-items: center; gap: 12px; min-width: 216px; min-height: 64px; padding: 0 20px; border: 1px dashed var(--kontur); border-radius: 20px; background: var(--bg-body); transition: background var(--dur-base) var(--ease-out), border-color var(--dur-base) var(--ease-out); }
.ablage[hidden] { display: none; }
.ab-text { display: grid; gap: 1px; }
.ab-t { font-size: var(--s-text); font-weight: 600; line-height: 1.2; }
.ab-s { font-size: var(--s-klein); color: var(--text-secondary); line-height: 1.2; }
.ablage.bereit { outline: 2px dashed var(--text-primary); outline-offset: 3px; border-color: var(--text-primary); }
.ablage.bereit.aktiv { outline-style: solid; background: var(--bg-s2); }
body.panel-auf .ablage { right: calc(clamp(300px, 26vw, 360px) + 12px); }

.leiste { position: fixed; left: 24px; bottom: 24px; z-index: 35; width: min(440px, calc(100vw - 48px)); display: grid; gap: 10px; padding: 14px 14px 14px 20px; border: 1px solid var(--kontur); border-radius: 20px; background: var(--bg-body); }
.leiste[hidden] { display: none; }
.le-kopf { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.le-text { display: grid; gap: 2px; min-width: 0; flex: 1; }
.le-name { font-size: var(--s-klein); color: var(--text-secondary); line-height: 1.3; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.le-satz { font-size: var(--s-text); font-weight: 600; line-height: 1.3; }
.le-pfeile, .le-knoepfe { display: flex; gap: 8px; align-items: center; }
.le-knoepfe { flex-wrap: wrap; }

/* Fehlerschild am Knoten (liegt am body) */
.schild { position: fixed; z-index: 55; max-width: 260px; padding: 8px 14px; border: 1px solid var(--text-primary); border-radius: 12px; background: var(--bg-body); font-size: var(--s-klein); font-weight: 600; line-height: 1.35; text-align: center; pointer-events: none; animation: sb-auftritt var(--dur-base) var(--ease-out) both; }

/* Ruhige Meldung nach einer Änderung, mit Rückgängig (sitzt über der Schublade) */
.rueck { position: absolute; left: 24px; bottom: calc(var(--sch-h) + 12px); z-index: 20; display: flex; align-items: center; gap: 10px; max-width: calc(100% - 48px); padding: 5px 5px 5px 18px; border: 1px solid var(--text-primary); border-radius: 999px; background: var(--bg-body); animation: sb-auftritt var(--dur-slow) var(--ease-out) both; }
.rueck[hidden] { display: none; }
.rueck { pointer-events: none; }
.rueck .pille, .rueck .icon-knopf { pointer-events: auto; }
.rueck-t { min-width: 0; font-size: var(--s-klein); font-weight: 600; line-height: 1.35; }
.rueck .pille { flex: none; min-height: 32px; }
.icon-knopf.klein { width: 32px; height: 32px; }

/* Im Baum hervorgehoben (aus dem Satz oder per Adresse): Weg zur Wurzel bleibt, der Rest tritt zurück */
.baum.hat-fokus .baum-linien path:not(.fokus) { opacity: .3; }
.baum.hat-fokus .baum-linien path.fokus { stroke: var(--text-primary); stroke-width: 2; opacity: 1; }
.baum.hat-fokus .knoten:not(.vorn), .baum.hat-fokus .blatt:not(.vorn), .baum.hat-fokus .knospe:not(.vorn), .baum.hat-fokus .luecke-blatt:not(.vorn) { opacity: .3; }
.baum .blatt.fokus .b-bild { outline: 2px solid var(--text-primary); outline-offset: 2px; }
.baum .knoten.fokus { outline: 2px solid var(--text-primary); outline-offset: 2px; }

/* ---------- Handy ---------- */
@media (max-width: 719px) {
  .seite.mit-leiste { padding-bottom: var(--leiste-h, 130px); }
  .kopf { grid-template-columns: auto auto minmax(0, 1fr); grid-template-areas: "zur titel name" "wahl wahl wahl" "werkzeuge werkzeuge werkzeuge" "aeste aeste aeste"; padding: 8px 16px 4px; gap: 6px 10px; }
  .kopf-b { display: contents; }
  .titel { grid-area: titel; }
  .kunde-name { grid-area: name; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .aeste { grid-area: aeste; margin: 0; padding: 0; }
  .werkzeuge { gap: 8px; flex-wrap: nowrap; min-width: 0; }
  .schalter { gap: 6px; padding: 0 10px 0 6px; font-size: var(--s-klein); }
  .schalter .spur { width: 26px; }
  .schalter[aria-checked="true"] .knauf { transform: translateX(9px); }
  .satz-zeile { flex-wrap: wrap; padding: 2px 16px 6px; gap: 4px 12px; }
  .satz { flex: 1 1 100%; font-size: var(--s-klein); line-height: 1.55; }
  .satz-teil { padding: 1px 6px; margin: 0 -3px; }
  .n5-leiste { flex: 1 1 0; overflow-x: auto; scrollbar-width: none; gap: 6px; }
  .n5-leiste::-webkit-scrollbar { display: none; }
  .n5t .b-bild { width: 30px; }
  .arbeit { display: flex; flex-direction: column; }
  .spalte-baum { flex: 1; }
  .rueck { left: 16px; right: 16px; max-width: none; border-radius: 20px; }
  .baum .baum-innen { padding-left: 16px; padding-right: 16px; }
  .baum .ast.zu { width: 160px; min-width: 150px; }
  .baum .k-wurzel { width: min(300px, calc(100vw - 48px)); max-width: none; }
  .baum .k-ziel .kn-name { font-size: var(--s-klein); }
  .kundenwahl { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
  .kundenwahl::-webkit-scrollbar { display: none; }
  .kundenwahl .pille { flex: none; }
  .werkbank { margin: 0 16px 8px; border-radius: 20px; padding: 8px 12px; flex-wrap: wrap; gap: 8px; }
  .wb-titel { display: none; }
  .wb-teile { flex-wrap: wrap; }
  .pille.teil .sb-icon { display: none; }
  .meldung { margin: 0; text-align: left; flex: 1 0 100%; }
  .ablage { display: none; }
  .k-wurzel { max-width: min(300px, 100%); }
  .leiste { left: 0; right: 0; bottom: 0; width: auto; border-radius: 20px 20px 0 0; border-bottom: 0; padding: 14px 16px calc(14px + env(safe-area-inset-bottom)); z-index: 35; }
  .weg-panel { inset: 0; width: auto; max-height: none; border: 0; border-radius: 0; z-index: 45; }
  .schublade { padding: 0 16px; }
  .sch-kopf { min-height: 48px; }
  .fund { width: 200px; }
  .plus-menu { left: 0 !important; right: 0; top: auto !important; bottom: 0; width: auto; max-height: 80dvh; border-radius: 20px 20px 0 0; border-bottom: 0; padding-bottom: calc(16px + env(safe-area-inset-bottom)); }
  .frage-blatt { left: 8px !important; right: 8px; top: auto !important; bottom: 8px; width: auto; }
  .ic { width: 44px; }
}

/* Kleine Beiträge tragen kein Datum im Baum (Titel-Attribut und Panel nennen es), die nächsten fünf behalten es */
.baum .blatt.klein .b-wann { display: none; }

/* Satz: Teile mit Mittelpunkt getrennt, kein Teil bricht in sich um */
.satz-teil { white-space: nowrap; }
.satz-sep { margin: 0 4px; color: var(--text-secondary); }
.satz-teil.ueber[aria-pressed="false"] { border-color: var(--text-primary); }
/* Meldungen (Toast) sitzen über der Sammlungs-Leiste */
.sb-toast { bottom: calc(var(--sch-h) + 72px); }
