/* Personaldossier (Runde 2e, DOSSIER): Versand-Fenster, Texte je Kandidat, Unterschrift und Banner in den Einstellungen.
   Nur Klassen mit Präfix .ds-, Farben über die Variablen des Leitstands (hell und dunkel). styles.css bleibt unverändert. */

/* ---------- Versand-Fenster ---------- */
.ds-send .send-left { gap: 2px; }
.ds-format, .ds-anonym { align-self: flex-start; }
.ds-format button, .ds-anonym button { white-space: nowrap; }
.ds-checks label.ds-aus { color: var(--muted); }
.ds-checks .ds-sperre { margin: -4px 0 0 24px; }
.ds-hinweise { list-style: none; margin: 2px 0 0; padding: 8px 10px; border-radius: 9px; background: var(--warn-bg); border: 1px solid var(--warn-ln); color: var(--warn-tx); font-size: 12.5px; display: flex; flex-direction: column; gap: 3px; }
#ds-pdf-hinweis { margin: 0 0 8px; }
.ds-einsatz label { margin-bottom: 0; }
.ds-einsatz .grid-2s { margin-bottom: 0; }
.ds-unter { margin: 8px 0 0; }
.ds-tabs { flex-wrap: wrap; row-gap: 6px; }
.ds-tabs button { white-space: nowrap; }
.ds-nb { white-space: nowrap; }

/* Texte je Kandidat */
#ds-texte { display: flex; flex-direction: column; gap: 10px; max-height: 70vh; overflow: auto; padding-right: 4px; }
.ds-felder { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 14px; }
.ds-felder > label:has(textarea), .ds-felder > div { grid-column: 1 / -1; }
.ds-felder textarea { resize: vertical; min-height: 64px; }
.ds-lbl { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; font-size: 13px; color: var(--muted); margin-bottom: 4px; }
.ds-zaehler { font-variant-numeric: tabular-nums; color: var(--muted-2, var(--muted)); font-size: 11.5px; }
.ds-zaehler.zu-lang { color: var(--warn-tx); font-weight: 700; }
.ds-kz { display: grid; grid-template-columns: 90px 1fr; gap: 8px; margin-bottom: 6px; }
.ds-med { display: flex; flex-direction: column; gap: 8px; padding: 10px 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--flaeche-2); }
.ds-chips { border-radius: 14px; }
.ds-chips button { height: 28px; font-size: 12.5px; }
.ds-knoepfe { gap: 8px; flex-wrap: wrap; align-items: center; }

/* ---------- Einstellungen: Unterschrift und Banner ---------- */
.ds-einst { margin-top: 6px; }
.ds-unterschrift-box, .ds-banner-box { display: flex; align-items: center; justify-content: flex-start; min-height: 64px; padding: 10px 14px; border-radius: 10px; background: #fff; border: 1px solid var(--line); margin: 6px 0 8px; }
.ds-unterschrift-box img { max-height: 70px; max-width: 260px; object-fit: contain; }
.ds-unterschrift-box .muted, .ds-banner-box .muted { color: #5b616e; }
.ds-banner-box { padding: 0; overflow: hidden; min-height: 56px; }
.ds-banner-box img { width: 100%; max-height: 120px; object-fit: cover; display: block; }
.ds-banner-box .muted { padding: 12px 14px; }
.ds-einst-knoepfe { gap: 8px; align-items: center; flex-wrap: wrap; }
.ds-titel-feld { max-width: 320px; margin-top: 10px; }

@media (max-width: 900px) {
  .ds-felder { grid-template-columns: 1fr; }
  #ds-texte { max-height: none; }
  .ds-send .send-left { max-height: none; overflow: visible; padding-right: 0; }
  .ds-format, .ds-anonym { display: flex; width: 100%; border-radius: 16px; }
  .ds-format button, .ds-anonym button { flex: 1 1 130px; white-space: normal; height: auto; min-height: 32px; padding: 4px 10px; border-radius: 13px; }
}

/* ---------- Runde 2m: gleiche Möglichkeiten auf allen Versand-Wegen (Vorschau für, Dateien der Einzelnen PDFs, Status, Laden) ---------- */
.ds-vorschau-fuer { margin: 0 0 8px; }
.ds-vorschau-fuer b { color: var(--text, inherit); }
.ds-dateien { margin: 0 0 8px; line-height: 1.45; overflow-wrap: anywhere; }
.ds-mehrere, .ds-alle { margin: 0 0 6px; }
.ds-laedt { margin: 6px 0 0; }
#ds-status-box:empty { display: none; }
#ds-status-box { margin-top: 10px; display: flex; flex-direction: column; gap: 6px; }
.ds-status { margin: 0; }
.ds-merker .tag { margin-left: 6px; }
.ds-send.ds-sendet { pointer-events: none; opacity: .7; }

/* ---------- Runde 2m, Korrektur 3: Knöpfe und Statuszeile immer sichtbar, der Inhalt läuft in sich (Klasse .ds-box setzt render am Pop-up) ---------- */
.modal-box.ds-box { display: flex; flex-direction: column; height: 92vh; overflow: hidden; }
.ds-box > .ds-send { flex: 1 1 auto; min-height: 0; overflow: auto; border-bottom: 1px solid var(--line); }
.ds-box > #ds-status-box { flex: none; max-height: 28vh; overflow: auto; }
.ds-box > .modal-actions { flex: none; flex-wrap: wrap; margin-top: 12px; }
.ds-ohne-mail { margin: -2px 0 0; color: var(--muted); }
.ds-ohne-mail.leer { color: var(--warn-tx); }
@media (min-width: 1401px) {
  .ds-box > .ds-send { grid-template-rows: minmax(0, 1fr); overflow: hidden; }
  .ds-box .ds-send .send-left { max-height: none; min-height: 0; }
  .ds-box .send-right { min-height: 0; overflow: auto; padding-right: 4px; }
  .ds-box .send-tabbody { flex: 1 0 auto; display: flex; flex-direction: column; }
  .ds-box .send-tabbody > [data-pane="ds-pdf"], .ds-box .send-tabbody > [data-pane="ds-ausweise"] { flex: 1 0 auto; display: flex; flex-direction: column; }
  .ds-box .send-tabbody .pdf-preview.tall { flex: 1 0 auto; height: auto; min-height: 280px; }
  .ds-box #ds-texte { max-height: none; overflow: visible; }
}
@media (max-width: 1400px) {
  .ds-box .ds-send .send-left { max-height: none; overflow: visible; padding-right: 0; }
}
