/* NeXtMail Web – Ordnung (nm-favoriten-web8): Ordner ziehen/ausblenden, Wischgesten mit Knöpfen, „Mehr“-Blatt, Einstellung Wischgesten.
   Wird NACH dichte.css und favoriten.css geladen; Maße aus den --d-Tokens. Aktionsfarben aus NEXTMAIL-API-FAVORITEN.md (weiße Schrift).
   © 2026 by Sebastian Hirtreiter */

/* ---------- Ordnerleiste */
.mail .sp-ordner .baum-abschnitt:not(.fv-fav) > .ordner.o8-leer { display: none; }
.mail .sp-ordner .ordner.o8-zieht { opacity: .5; }
.mail .sp-ordner .ordner.o8-ziel-oben { box-shadow: inset 0 2px 0 var(--accent); }
.mail .sp-ordner .ordner.o8-ziel-unten { box-shadow: inset 0 -2px 0 var(--accent); }
.mail .sp-ordner .ordner.o8-ziehbar[draggable="true"] { cursor: grab; }
.o8-zurueck[hidden] { display: none; }

/* ---------- Wischen auf einer Mail (nur Handy mit Touch) */
.nachricht.o8-wischt { overflow: hidden; touch-action: pan-y; }
.nachricht.o8-wischt > :not(.o8-leiste) { transform: translateX(var(--o8-x, 0)); }
.nachricht.o8-gleiten > :not(.o8-leiste), .nachricht.o8-gleiten > .o8-leiste { transition: transform .18s ease, width .18s ease; }
.o8-leiste { position: absolute; top: 0; bottom: 0; width: 0; overflow: hidden; display: flex; align-items: center; background: var(--panel2); z-index: 1; }
.o8-leiste.o8-rechts { left: 0; flex-direction: row; }
.o8-leiste.o8-links { right: 0; flex-direction: row-reverse; }
.o8-kn { flex: none; width: 84px; height: 100%; border: 0; background: transparent; padding: 0 4px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; font: inherit; color: var(--muted); cursor: pointer; -webkit-tap-highlight-color: transparent; }
.o8-kreis { width: 60px; height: 38px; border-radius: 19px; display: inline-flex; align-items: center; justify-content: center; color: #fff; }
.o8-kreis svg.ic { width: 20px; height: 20px; }
.o8-kn-text { font-size: var(--d-schrift-klein); line-height: 1.15; max-width: 80px; overflow: hidden; text-align: center; overflow-wrap: anywhere; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }   /* nm-gleich: „Markierung entfernen“ zweizeilig statt abgeschnitten */
.o8-kn:active .o8-kreis { filter: brightness(.9); }
.o8-lang { position: absolute; inset: 0; display: none; align-items: center; gap: 8px; padding: 0 18px; color: #fff; font-weight: 600; font-size: var(--d-schrift); white-space: nowrap; }
.o8-leiste.o8-rechts .o8-lang { justify-content: flex-end; }
.o8-leiste.o8-links .o8-lang { justify-content: flex-start; }
.o8-lang svg.ic { width: 22px; height: 22px; }
.nachricht.o8-weit .o8-lang { display: flex; }
.nachricht.o8-weit .o8-kn { visibility: hidden; }

/* ---------- „Mehr“-Blatt und Erinnerung (Bild 7) */
.dialog.o8-blatt { background: var(--bg); }
.dialog.o8-blatt .dialog-kopf h2 { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; flex: 1; }
.o8-blatt-betreff { color: var(--muted); font-size: var(--d-schrift-klein); margin: -6px 0 10px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.o8-blatt-inhalt { display: flex; flex-direction: column; gap: 12px; padding-bottom: 8px; }
.o8-kacheln { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.o8-kachel { min-height: 72px; border: 1px solid var(--line); border-radius: var(--karte); background: var(--panel); color: var(--text); font: inherit; font-size: var(--d-schrift); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; cursor: pointer; padding: 8px; }
.o8-kachel svg.ic { width: 22px; height: 22px; }
.o8-kachel.gefahr { color: var(--gefahr); }
.o8-kachel:hover, .o8-kachel:focus-visible { background: var(--hover); }
.o8-gruppe { border: 1px solid var(--line); border-radius: var(--karte); background: var(--panel); overflow: hidden; display: flex; flex-direction: column; }
.o8-blatt-zeile { display: flex; align-items: center; gap: 12px; min-height: 48px; padding: 6px 16px; border: 0; background: transparent; color: var(--text); font: inherit; font-size: var(--d-schrift); text-align: left; cursor: pointer; position: relative; }
.o8-blatt-zeile + .o8-blatt-zeile::before { content: ""; position: absolute; left: 16px; right: 0; top: 0; border-top: 1px solid var(--line); }
.o8-blatt-zeile:hover, .o8-blatt-zeile:focus-visible { background: var(--hover); }
.o8-blatt-zeile > svg.ic { width: 20px; height: 20px; flex: none; color: var(--text); }
.o8-bz-text { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.o8-bz-sub { color: var(--muted); font-size: var(--d-schrift-klein); }
.o8-bz-titel { padding: 10px 16px 4px; color: var(--muted); font-size: var(--d-schrift-klein); }
.o8-eigen { display: flex; gap: 8px; padding: 4px 16px 12px; align-items: center; }
.o8-eigen .feld { flex: 1; min-width: 0; }
@media (max-width: 760px) {
  .dialog.o8-blatt { border-radius: 14px 14px 0 0; max-width: none; }
}

/* ---------- Einstellung Wischgesten */
.o8-wrichtung { margin: 6px 0 10px; }
.o8-wkopf { font-size: var(--d-schrift); font-weight: 600; margin: 10px 0 2px; }
