:root {
  --bg: #14161a;
  --panel: #1c1f26;
  --line: #2b303a;
  --fg: #e6e8ec;
  --muted: #8b93a1;
  --accent: #4a9eff;
  --ok: #3fb950;
  --warn: #d29922;
  --err: #f85149;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font: 15px/1.5 ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

header { border-bottom: 1px solid var(--line); background: var(--panel); }
main { max-width: 1100px; margin: 0 auto; padding: 24px 20px 64px; }
footer { color: var(--muted); text-align: center; padding: 24px; font-size: 13px; }

h1 { font-size: 22px; margin: 0 0 20px; }
h2 { font-size: 16px; margin: 32px 0 12px; color: var(--muted);
     text-transform: uppercase; letter-spacing: .06em; }
h3 { margin: 0 0 12px; }
h4 { margin: 20px 0 8px; font-size: 13px; color: var(--muted); }

/* --- Menue: eine Reihe, Marke links, alles rechts ---------------------- */
.nav { display: flex; gap: 4px; align-items: center; flex-wrap: wrap;
       max-width: 1100px; margin: 0 auto; padding: 10px 20px; }
.nav .brand { font-weight: 700; margin-right: 18px; letter-spacing: .02em; }
/* Der Block rechts buendelt Links, Untermenues UND Pills. `margin-left:
   auto` drueckt ihn an den rechten Rand — so ist alles in einer Reihe und
   rechtsbuendig statt auf zwei Reihen verteilt. */
.nav .nav-body { display: flex; gap: 4px; align-items: center;
                 margin-left: auto; flex-wrap: wrap; }
.navlink { padding: 5px 10px; border-radius: 6px; color: var(--muted); font-size: 14px; }
.navlink.on { background: var(--bg); color: var(--fg); }
.navlink:hover { text-decoration: none; color: var(--fg); }

/* Burger-Menue: unsichtbarer Schalter + Label. Reines CSS, kein JS. */
.burger { display: none; }
.nav-toggle { display: none; }

.table { width: 100%; border-collapse: collapse; font-size: 14px; }
.table th, .table td { text-align: left; padding: 8px 10px;
                       border-bottom: 1px solid var(--line); vertical-align: top; }
.table th { color: var(--muted); font-weight: 600; font-size: 12px;
            text-transform: uppercase; letter-spacing: .05em; }
.table tr.picked td:first-child { color: var(--ok); }
.table tr.rejected { opacity: .55; }
.table td.text { max-width: 380px; }
.table td.reason { max-width: 340px; color: var(--muted); font-size: 13px; }

.badge { display: inline-block; padding: 1px 8px; border-radius: 999px;
         font-size: 12px; background: var(--line); color: var(--fg); }
.b-done, .b-fertig { background: rgba(63,185,80,.16); color: var(--ok); }
.b-pending, .b-geplant { background: rgba(210,153,34,.16); color: var(--warn); }
.b-running { background: rgba(74,158,255,.16); color: var(--accent); }
.b-failed { background: rgba(248,81,73,.16); color: var(--err); }
.b-unread { background: rgba(248,81,73,.16); color: var(--err); }

.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
         gap: 12px; }
.tile { background: var(--panel); border: 1px solid var(--line);
        border-radius: 8px; padding: 14px 16px; }
.tile-label { color: var(--muted); font-size: 12px; text-transform: uppercase;
              letter-spacing: .05em; }
.tile-value { font-size: 26px; font-weight: 650; margin-top: 4px; }
.tile-sub { color: var(--muted); font-size: 13px; }

.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
         gap: 16px; }
.card { background: var(--panel); border: 1px solid var(--line);
        border-radius: 10px; padding: 16px; }

.drawn { display: flex; gap: 10px; align-items: center; padding: 7px 0;
         border-bottom: 1px solid var(--line); }

.notif { border-bottom: 1px solid var(--line); padding: 9px 0; }
.notif.unread { border-left: 2px solid var(--err); padding-left: 10px; }
.notif-head { display: flex; justify-content: space-between; gap: 12px; }
.notif-body { color: var(--muted); font-size: 13px; }

.bar-row { display: flex; align-items: center; gap: 10px; padding: 3px 0; }
.bar-label { width: 110px; color: var(--muted); font-size: 13px; }
.bar-track { flex: 1; height: 9px; background: var(--line); border-radius: 999px; }
.bar-fill { display: block; height: 100%; background: var(--accent);
            border-radius: 999px; }
.bar-num { width: 46px; text-align: right; font-size: 13px; }

label { display: block; margin-bottom: 10px; font-size: 13px; color: var(--muted); }
label.check { display: flex; gap: 8px; align-items: center; }
input, select { width: 100%; margin-top: 4px; padding: 7px 9px; border-radius: 6px;
                border: 1px solid var(--line); background: var(--bg);
                color: var(--fg); font: inherit; }
input[type="checkbox"] { width: auto; margin: 0; }
label.check input { width: auto; }

button { padding: 8px 14px; border-radius: 6px; border: 1px solid var(--accent);
         background: var(--accent); color: #08121f; font-weight: 600; cursor: pointer; }

.toolbar { margin-bottom: 14px; max-width: 220px; }

.muted { color: var(--muted); }
.err { color: var(--err); }
.run-head { display: flex; gap: 12px; align-items: center; margin-bottom: 8px; }

.kv { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
      gap: 8px 18px; margin: 0; }
.kv dt { color: var(--muted); font-size: 12px; }
.kv dd { margin: 0 0 6px; }

.raw { background: var(--panel); border: 1px solid var(--line); border-radius: 6px;
       padding: 10px; font-size: 13px; white-space: pre-wrap; }

body.center { display: grid; place-items: center; min-height: 100vh; }
form.login { width: 300px; }
form.login h1 { margin-bottom: 20px; }
form.login button { width: 100%; margin-top: 6px; }
/* --- Konten und Accounts (Etappe: eigene Ansicht) --- */
.mono { font-family: ui-monospace, "SF Mono", Menlo, monospace; font-size: 12px; }

.live { display: grid; grid-template-columns: auto auto; gap: 3px 12px;
        margin: 10px 0; font-size: 13px; }
.live span { color: var(--muted); }
.live strong { text-align: right; }

.acct-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
              gap: 8px; margin: 12px 0; }
.acct-stats dt { color: var(--muted); font-size: 11px; text-transform: uppercase;
                 letter-spacing: .05em; }
.acct-stats dd { margin: 0; font-size: 17px; font-weight: 600; }
.acct h3 { margin-bottom: 2px; }

.pw-form { margin: 14px 0 10px; padding-top: 12px; border-top: 1px solid var(--line); }
.pw-form label { margin-bottom: 8px; }
.pw-form button { width: 100%; }

/* --- Wer ist angemeldet (Pills, rechts im Menue) --- */
.whobar { display: flex; gap: 8px; align-items: center; font-size: 13px; }
.whobar .chip { padding: 2px 9px; border-radius: 999px; background: var(--bg);
                border: 1px solid var(--line); font-size: 12px; }

/* --- Personenprofil --- */
.person-note { margin-top: 8px; }
.pf-form { display: grid; gap: 12px; max-width: 760px; }
.pf-field label { display: block; }
.pf-field textarea { width: 100%; margin-top: 4px; padding: 8px 10px;
                     border-radius: 6px; border: 1px solid var(--line);
                     background: var(--bg); color: var(--fg);
                     font: inherit; resize: vertical; }
.pf-form button { width: auto; }
td.text { max-width: 320px; }

.kw-source { display: flex; gap: 12px; padding: 6px 0;
             border-bottom: 1px solid var(--line); font-size: 13px; }
.kw-source .muted { min-width: 190px; }

.tabs { display: flex; gap: 6px; margin: 24px 0 8px; }
.tabs .navlink { border: 1px solid var(--line); }
.ok { color: var(--ok); }

/* --- Detailansichten auf weissem Grund -----------------------------------
   Die App ist dunkel. Ein laengerer Text ist darauf nicht zum Lesen —
   deshalb bekommen Detail-Seiten eine helle Leseplaette. */

.sheet {
    background: #ffffff;
    color: #17191c;
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 26px 30px;
}
.sheet h2 { color: #17191c; margin-top: 0; }
.sheet h4 { color: #5c6470; }
.sheet .muted { color: #5c6470; }
.sheet a { color: #1459a6; }
.sheet .chip { background: #eef1f5; border: 1px solid #d8dde4; color: #17191c; }

.sheet-head { display: flex; align-items: center; gap: 14px; margin-bottom: 16px; }
.sheet-head h2 { margin: 0; }

.sheet .meta {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 6px 20px; margin-bottom: 22px;
    padding-bottom: 18px; border-bottom: 1px solid #e3e7ec;
}
.sheet .meta dt { color: #5c6470; font-size: 12px; text-transform: uppercase;
                  letter-spacing: .05em; }
.sheet .meta dd { margin: 0; font-size: 14px; word-break: break-word; }

/* Formular auf hellem Grund */
.sheet .pf-field label { color: #3a404a; }
.sheet .pf-field textarea,
.sheet input[type="text"],
.sheet input[type="password"],
.sheet input[type="email"],
.sheet input[type="number"] {
    background: #ffffff; color: #17191c; border-color: #c9d0d8;
}
.sheet input::placeholder,
.sheet textarea::placeholder { color: #8b93a1; }
.sheet .pf-form button { background: #1459a6; border-color: #1459a6; color: #fff; }
.sheet .ok { color: #16794a; }
.sheet .err { color: #b4232a; }
.sheet .mono { color: #3a404a; }

.prompt { margin-bottom: 22px; }
.prompt h3 { margin: 0 0 6px; }
.prompt textarea { width: 100%; margin: 8px 0 10px; padding: 12px 14px;
                   border-radius: 8px; border: 1px solid #c9d0d8;
                   background: #fff; color: #17191c;
                   font: 13px/1.55 ui-monospace, "SF Mono", Menlo, monospace;
                   resize: vertical; }
.prompt button { width: auto; }

/* --- Untermenue unter Aktionen (kein JS, nur <details>) --- */
.navmenu { position: relative; }
.navmenu > summary { list-style: none; cursor: pointer; }
.navmenu > summary::-webkit-details-marker { display: none; }
.navmenu > summary::after { content: " ▾"; font-size: 11px; opacity: .6; }
.navmenu-list {
    position: absolute; top: 100%; left: 0; z-index: 20;
    background: var(--panel); border: 1px solid var(--line);
    border-radius: 8px; padding: 6px; min-width: 150px;
    display: grid; gap: 2px; margin-top: 6px;
}
.navmenu-list .navlink { display: block; }
.navmenu:hover > .navmenu-list { display: grid; }

/* --- Marke verlinkt --- */
.brand { color: var(--fg); text-decoration: none; }
.brand:hover { text-decoration: none; color: var(--accent); }

/* --- Aktiv-Haken in der Profil-Liste --- */
.icon-on { color: var(--ok); font-size: 16px; }
.icon-off { color: var(--err); font-size: 16px; opacity: .7; }
.center { text-align: center; }
.table th.center { text-align: center; }

/* --- Passwortfeld ein- und ausblenden -----------------------------------
   Eingabe und Knopf in einer Zeile, damit nichts verrutscht. Der Knopf
   traegt keine eigene Farbe, sondern nur currentColor — so steht er auf der
   dunklen Flaeche UND auf der hellen Leseplatte (.sheet) korrekt da.

   Der Knopf braucht die Spezifitaet `.pw-zeile .auge`: `form.login button`
   setzt width:100%, und mit nur `.auge` reisst der Knopf die ganze Zeile an
   sich, waehrend die Eingabe auf 20 px stehen bleibt.                       */
.pw-zeile { display: flex; gap: 6px; align-items: center; }
.pw-zeile input { flex: 1 1 0; min-width: 0; }
.pw-zeile .auge {
    display: inline-flex; align-items: center; justify-content: center;
    flex: 0 0 auto; width: 32px; height: 32px; padding: 0; margin: 0;
    border: 1px solid var(--line); border-radius: 6px;
    background: transparent; color: var(--muted);
    font-weight: 400; cursor: pointer;
}
.pw-zeile .auge:hover { border-color: var(--accent); color: var(--accent); }
.pw-zeile .auge:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.auge-auf { display: none; }
.auge.auf .auge-zu { display: none; }
.auge.auf .auge-auf { display: block; }

/* --- Kleine Zahlenboxen fuer die Statistik --- */
.tiles.sm { grid-template-columns: repeat(auto-fit, minmax(96px, 1fr)); gap: 8px; }
.tile.sm {
    display: flex; align-items: baseline; justify-content: space-between;
    gap: 8px; padding: 6px 10px;
}
.tile.sm .tile-label { font-size: 11px; }
.tile.sm .tile-value { font-size: 17px; margin: 0; }

/* Meldungschip in der Menueleiste */
.whobar .chip.mute { color: var(--muted); font-weight: 400; }
.whobar .chip.mute:hover { color: var(--fg); text-decoration: none; }

/* --- Vorschlaege --- */
.proposal {
    background: #fff; color: #17191c;
    border: 1px solid #d8dde4; border-left: 3px solid #1459a6;
    border-radius: 8px; padding: 14px 16px; margin-bottom: 14px;
}
.proposal.edit { border-left-color: var(--warn); }
.proposal-head { display: flex; justify-content: space-between; align-items: center;
                 gap: 12px; margin-bottom: 8px; }
.proposal-head strong { font-size: 14px; }
.proposal .badge { background: #eef1f5; color: #3a404a; border: 1px solid #d8dde4; }
.proposal blockquote {
    margin: 0 0 10px; padding: 8px 12px;
    background: #f3f5f8; border-left: 2px solid #c9d0d8;
    color: #4a515c; font-size: 13px; line-height: 1.5;
    display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical;
    overflow: hidden;
}
.proposal-text { margin: 0 0 6px; font-size: 15px; line-height: 1.55; white-space: pre-wrap; }
.proposal textarea { width: 100%; margin-top: 4px; padding: 10px 12px;
                     border: 1px solid #c9d0d8; border-radius: 6px;
                     background: #fff; color: #17191c;
                     font: 15px/1.55 ui-monospace, "SF Mono", Menlo, monospace;
                     resize: vertical; }
.proposal .btnrow { margin-top: 12px; }
.counter { font: 12px ui-monospace, Menlo, monospace; color: #5c6470;
           white-space: nowrap; }
.counter.over { color: #b4232a; font-weight: 700; }

.btnrow { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.btnrow button, .btnrow .chip {
    display: inline-block; width: auto;
}
.btnrow button.alt { background: #fff; color: #17191c; border: 1px solid #c9d0d8; }
.dangerzone { margin: 6px 0 18px; }
.dangerzone button { background: #fff; color: #b4232a; border: 1px solid #e0b4b8; }
.proposal .err { color: #b4232a; font-size: 13px; margin: 6px 0 0; }
.proposal .ok { color: #16794a; font-size: 13px; margin: 6px 0 0; }

/* --- Icon-Buttons in der Profil-Liste --- */
.iconbtns { display: flex; gap: 4px; justify-content: flex-end; }
.iconbtn {
    display: inline-flex; align-items: center; justify-content: center;
    width: 28px; height: 28px; border-radius: 6px;
    background: #eef1f5; color: #3a404a;
    border: 1px solid #d8dde4; text-decoration: none;
}
.iconbtn:hover { background: #dfe5ec; color: #1459a6; border-color: #b9c4d1; }
.iconbtns .iconbtn { flex: 0 0 auto; }

/* Nur fuer Bildschirmleser: lesbar, aber nicht sichtbar */
.sr {
    position: absolute; width: 1px; height: 1px;
    padding: 0; margin: -1px; overflow: hidden;
    clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.table td:last-child { text-align: right; }

/* --- Anbieterwahl --- */
.presets { display: flex; flex-wrap: wrap; gap: 8px; margin: 4px 0 14px; }
.preset {
    display: inline-flex; align-items: center; gap: 7px;
    padding: 7px 13px; border-radius: 999px; cursor: pointer;
    background: #fff; color: #17191c;
    border: 1px solid #c9d0d8; font-size: 14px; margin: 0;
}
.preset:hover { border-color: #1459a6; }
.preset input { margin: 0; width: auto; }
.preset:has(input:checked) {
    background: #1459a6; color: #fff; border-color: #1459a6;
}
.hint {
    color: #5c6470; font-size: 12.5px; margin: -4px 0 10px;
}
.sheet .pf-field input,
.sheet .pf-field select,
.sheet .pf-field textarea { width: 100%; }
.sheet optgroup { font-weight: 700; }

/* --- Rueckfrage vor dem Lauf --- */
.warnbox {
    background: #fff8e6; border: 1px solid #e8d9a8;
    border-left: 3px solid #c9a227; border-radius: 6px;
    padding: 12px 15px; margin: 14px 0;
}
.warnbox p { margin: 0 0 6px; font-size: 14px; }
.warnbox p:last-child { margin: 0; }

.whatlist { margin: 14px 0; padding-left: 20px; }
.whatlist li { margin-bottom: 5px; font-size: 14.5px; color: #3a404a; }
.whatlist code { background: #f0f3f7; padding: 1px 5px; border-radius: 4px;
                 font-size: 13px; }

/* Lauf-Start-Button bekommt eine Auffaelligkeit */
.iconbtn.accent { background: #1459a6; color: #fff; border-color: #1459a6; }
.iconbtn.accent:hover { background: #0f4a8f; color: #fff; border-color: #0f4a8f; }

/* --- Laufstatus: Spinner + Verweildauer --- */
.runstatus { margin: 4px 0 14px; }
.runstatus-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.spinner {
    width: 15px; height: 15px; border-radius: 50%;
    border: 2px solid #c9d0d8; border-top-color: #1459a6;
    animation: dreht .8s linear infinite; display: inline-block;
    flex: 0 0 auto;
}
@keyframes dreht { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .spinner { animation: none; } }
.spinner-row { display: flex; align-items: center; gap: 8px; font-size: 14px; }

.runerror {
    background: #fdeef0; border: 1px solid #e8c2c7;
    border-left: 3px solid var(--err); border-radius: 6px;
    padding: 10px 13px; margin-top: 10px; font-size: 13.5px;
    color: #8a1a20; word-break: break-word;
}
.runerror strong { display: block; margin-bottom: 3px; }
.runerror span { color: #5a2a30; }

/* --- Zugangspruefung --- */
.pw-check { margin-top: 26px; padding-top: 16px; border-top: 1px solid #e3e7ec; }
#pruefergebnis { margin-top: 6px; }
.pruef-ok, .pruef-fehl {
    padding: 11px 14px; border-radius: 7px; font-size: 14px; margin-bottom: 10px;
}
.pruef-ok  { background: #eaf6ee; border: 1px solid #b6dfc4; color: #14653c; }
.pruef-fehl { background: #fdeef0; border: 1px solid #eec2c9; color: #8a1a20; }
.pruef-ok p, .pruef-fehl p { margin: 0 0 8px; }
.pruef-ok button, .pruef-fehl button {
    background: #fff; color: #17191c; border: 1px solid #c9d0d8; width: auto;
}

/* --- Freigabe: Zeilen, Schalter, Knoepfe --- */
.btncell { display: flex; gap: 6px; flex-wrap: wrap; }
.table tr.picked td { background: #f2f8f4; }
.table td.mono { font: 12px ui-monospace, Menlo, monospace; color: #4a515c; }

button.mini {
    padding: 3px 10px; font-size: 12.5px; border-radius: 999px;
    background: #fff; color: #3a404a; border: 1px solid #c9d0d8; width: auto;
}
button.mini:hover { border-color: #1459a6; color: #1459a6; }
button.mini.on {
    background: #1459a6; border-color: #1459a6; color: #fff;
}
button.mini.on:hover { background: #0f4a8f; color: #fff; }
button.mini:disabled { opacity: .45; cursor: not-allowed; }
button.mini.alt:hover { border-color: var(--err); color: var(--err); }

.releasebox {
    background: #f7f9fb; border: 1px solid var(--line);
    border-radius: 8px; padding: 14px 16px; margin: 0 0 18px;
}
.releasebox p { margin: 0 0 10px; }
.sheet .releasebox button { background: #1459a6; border-color: #1459a6; }
.actionline td { vertical-align: top; }

.chip.accent { background: #1459a6; border-color: #1459a6; color: #fff; }
.chip.accent:hover { background: #0f4a8f; color: #fff; }

/* --- Aktionstabelle: kompakt, kurzer Handle, Link daneben --- */
.act-label { width: 62px; white-space: nowrap; font-weight: 600; }
.act-link  { font-size: 14px; }
.act-link a { color: #1459a6; font-weight: 500; }
.act-undo  { width: 110px; }
.act-time  { width: 96px; color: #5c6470; font-size: 12.5px; white-space: nowrap; }
.actionline td { padding: 5px 10px 5px 0; vertical-align: middle; }
.table th { padding-bottom: 4px; }


/* ==== Helle Leseplatte ====================================================
   Der Rest der App ist dunkel; die Detail-Seiten stehen auf weiss. Der Kniff:
   die Farb-VARIABLEN werden innerhalb von .sheet lokal umdefiniert. Sonst
   erben Kinder weiter var(--muted) = #8b93a1 und erscheinen grau auf weiss.
   ======================================================================= */
.sheet {
    --fg: #111111;
    --muted: #555555;
    --line: #ccd2da;
    --accent: #0b57d0;
    background: #ffffff;
    color: #111111;
    border: 1px solid #ccd2da;
    border-radius: 12px;
    padding: 26px 30px;
}
.sheet h1, .sheet h2, .sheet h3, .sheet h4 { color: #111111; }
.sheet p, .sheet li, .sheet span, .sheet td, .sheet div { color: #111111; }
.sheet .muted, .sheet .mono, .sheet .hint { color: #555555; }
.sheet .err { color: #b4232a; }

/* Tabellen auf der Platte */
.sheet table, .sheet .table { width: 100%; color: #111111; }
.sheet .table th, .sheet .table td {
    color: #111111;
    border-bottom: 1px solid #ccd2da;
    text-align: left;
}
.sheet .table th {
    color: #555555;
    font-weight: 600;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: .05em;
}
.sheet a { color: #0b57d0; }

/* Aktionstabelle: kurz, Link daneben */
.act-label { width: 62px; white-space: nowrap; font-weight: 600; color: #111111; }
.act-link a { color: #0b57d0; font-weight: 500; }
.act-time  { width: 96px; color: #555555; font-size: 12.5px; white-space: nowrap; }
.act-undo  { width: 110px; }
.actionline td { padding: 5px 10px 5px 0; vertical-align: middle; }

/* Knoepfe auf der Platte */
.sheet button { background: #0b57d0; color: #ffffff; border-color: #0b57d0; }
.sheet button.alt { background: #ffffff; color: #111111; border-color: #c1c8d2; }
.sheet button.mini { background: #ffffff; color: #111111; border: 1px solid #c1c8d2; }
.sheet button.mini.on { background: #0b57d0; color: #ffffff; }
.sheet .chip { background: #eef1f5; color: #111111; border-color: #ccd2da; }

/* ==== Handy ================================================================
   Unter 820 px kippt die Kopfzeile auf ein Burger-Menue, die Inhalte
   bekommen mehr Zeilenhoehe, und Tabellen rollen seitlich, statt Zeilen
   zu zerquetschen. Eine Klasse steuert, was auf dem kleinen Display
   keinen Platz hat: `.only-desktop` faellt weg.
   ======================================================================== */
@media (max-width: 820px) {
    /* Kopfzeile bleibt beim Scrollen oben */
    header { position: sticky; top: 0; z-index: 30; }

    /* Burger: sichtbar, alles andere bleibt zu */
    .burger {
        display: flex; flex-direction: column; justify-content: center;
        gap: 4px; width: 38px; height: 34px; padding: 6px 7px;
        margin-left: auto; order: 2; cursor: pointer;
        border: 1px solid var(--line); border-radius: 6px; background: var(--bg);
    }
    .burger:hover { border-color: var(--accent); }
    .burger-bar { display: block; height: 2px; border-radius: 2px; background: var(--fg); }

    .nav .nav-body {
        display: none; width: 100%; margin: 10px 0 2px; padding-top: 10px;
        flex-direction: column; align-items: stretch; gap: 2px;
        border-top: 1px solid var(--line);
    }
    .nav-toggle:checked ~ .nav-body { display: flex; }

    .nav .navlink, .nav .navmenu > summary { display: block; padding: 9px 10px; }
    .nav .navmenu { display: block; width: 100%; }
    .nav .navmenu > summary::after { content: " ▾"; float: right; font-size: 11px; }
    .nav .navmenu[open] > summary::after { content: " ▴"; }

    /* Untermenues klappen nach unten auf statt nach rechts zu schweben */
    .navmenu-list {
        position: static; display: none; min-width: 0; margin: 2px 0 6px;
        padding: 0 0 0 12px; border: 0; border-left: 1px solid var(--line);
        border-radius: 0; background: transparent;
    }
    .navmenu:hover > .navmenu-list { display: none; }
    .navmenu[open] > .navmenu-list { display: grid; }

    .nav .whobar { margin-left: 0; padding: 8px 0 2px; flex-wrap: wrap; gap: 6px; }
    .whobar .chip { font-size: 13px; padding: 5px 11px; }

    /* Inhalt */
    main { padding: 16px 14px 48px; }
    h1 { font-size: 20px; margin-bottom: 14px; }
    h2 { margin-top: 26px; }
    .sheet { padding: 16px 14px; border-radius: 10px; }
    .sheet-head { flex-wrap: wrap; gap: 8px; }
    .toolbar { max-width: none; }
    footer { padding: 16px 14px; }

    /* Tabellen: lieber seitlich rollen als die Zeilen zerquetschen */
    main .table, .sheet .table {
        display: block; width: 100%; overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    main .table th, main .table td { white-space: nowrap; }
    main .table td.text,
    main .table td.reason { white-space: normal; }

    /* iOS zoomt in ein Feld, sobald die Schrift darin kleiner als 16 px ist */
    input, select, textarea { font-size: 16px; }

    /* Was auf dem kleinen Display keinen Platz hat */
    .only-desktop { display: none !important; }
}
