/* CoffeeCloud Webapp – Nutzer- und Adminbereich */
:root {
  color-scheme: light;
  --bg: #f4f5f7;
  --surface: #ffffff;
  --surface-2: #f8f9fb;
  --surface-3: #eef0f3;
  --line: #e3e6eb;
  --line-strong: #cfd4dc;
  --text: #111418;
  --text-2: #4a5160;
  --text-3: #737b8a;
  --brand: #c8102e;
  --brand-2: #8f0b22;
  --brand-soft: #fdecee;
  --ink: #15181d;
  --ink-text: #ffffff;
  --ok: #12804a;
  --ok-soft: #e6f4ec;
  --warn: #9a5800;
  --warn-soft: #fdf3e1;
  --bad: #c42b1c;
  --bad-soft: #fdebe9;
  --info: #2a62c9;
  --info-soft: #e9f0fc;
  --free: #0b8a6f;
  --free-soft: #e3f6f1;
  --series-1: #2a78d6;
  /* Zahlungsarten (Automaten-Statistik): feste Reihenfolge, mit dataviz-Validator geprueft */
  --src-cc: #2a78d6; --src-cash: #eb6834; --src-term: #1baf7a; --src-free: #eda100; --src-misc: #9aa3ad;
  --shadow: 0 1px 2px rgba(16, 24, 40, .05), 0 1px 3px rgba(16, 24, 40, .06);
  --shadow-lg: 0 12px 32px rgba(16, 24, 40, .14), 0 2px 6px rgba(16, 24, 40, .08);
  --r: 14px;
  --r-sm: 10px;
  --font: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --bg: #0d1014; --surface: #151a20; --surface-2: #1a2028; --surface-3: #222a33;
    --line: #262e38; --line-strong: #343e4a; --text: #eef1f5; --text-2: #b4bcc8; --text-3: #8a94a2;
    --brand: #ef3b55; --brand-2: #b0162f; --brand-soft: #3a1219; --ink: #eef1f5; --ink-text: #0d1014;
    --ok: #3ccf86; --ok-soft: #12301f; --warn: #f0a83a; --warn-soft: #33250e; --bad: #ff6b5c;
    --bad-soft: #3a1714; --info: #6ea2ff; --info-soft: #15233d; --series-1: #3987e5; --src-cc: #3987e5; --src-cash: #d95926; --src-term: #199e70; --src-free: #c98500; --src-misc: #6b7480;
    --free: #3ed8b4; --free-soft: #0f2e28;
    --shadow: 0 1px 2px rgba(0, 0, 0, .4); --shadow-lg: 0 16px 40px rgba(0, 0, 0, .55);
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0d1014; --surface: #151a20; --surface-2: #1a2028; --surface-3: #222a33;
  --line: #262e38; --line-strong: #343e4a; --text: #eef1f5; --text-2: #b4bcc8; --text-3: #8a94a2;
  --brand: #ef3b55; --brand-2: #b0162f; --brand-soft: #3a1219; --ink: #eef1f5; --ink-text: #0d1014;
  --ok: #3ccf86; --ok-soft: #12301f; --warn: #f0a83a; --warn-soft: #33250e; --bad: #ff6b5c;
  --bad-soft: #3a1714; --info: #6ea2ff; --info-soft: #15233d; --series-1: #3987e5; --src-cc: #3987e5; --src-cash: #d95926; --src-term: #199e70; --src-free: #c98500; --src-misc: #6b7480;
  --free: #3ed8b4; --free-soft: #0f2e28;
  --shadow: 0 1px 2px rgba(0, 0, 0, .4); --shadow-lg: 0 16px 40px rgba(0, 0, 0, .55);
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  background: var(--bg); color: var(--text); font: 15px/1.5 var(--font);
  -webkit-font-smoothing: antialiased; min-height: 100vh;
}
a { color: inherit; }
h1, h2, h3 { margin: 0; letter-spacing: -.01em; }
h1 { font-size: 24px; font-weight: 700; }
h2 { font-size: 17px; font-weight: 650; }
h3 { font-size: 14px; font-weight: 650; }
.mono { font-family: var(--mono); font-size: .92em; letter-spacing: .01em; }
.muted { color: var(--text-3); }
.small { font-size: 13px; }
.num { font-variant-numeric: tabular-nums; }
.right { text-align: right; }
.hidden { display: none !important; }
svg.i { width: 18px; height: 18px; flex: none; stroke: currentColor; fill: none; stroke-width: 1.8;
        stroke-linecap: round; stroke-linejoin: round; }

/* ---------------- Buttons & Inputs ---------------- */
button {
  font: inherit; font-size: 14px; font-weight: 550; border-radius: var(--r-sm); border: 1px solid var(--line-strong);
  background: var(--surface); color: var(--text); padding: 8px 14px; cursor: pointer; display: inline-flex;
  align-items: center; gap: 7px; white-space: nowrap; transition: background .15s, border-color .15s, transform .05s;
}
button:hover { background: var(--surface-2); border-color: var(--text-3); }
button:active { transform: translateY(1px); }
button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, a:focus-visible {
  outline: 2px solid var(--series-1); outline-offset: 2px;
}
button.primary { background: var(--ink); color: var(--ink-text); border-color: var(--ink); }
button.primary:hover { opacity: .9; background: var(--ink); }
a.btnfull { display: flex; justify-content: center; align-items: center; gap: 8px; padding: 12px 16px; border-radius: var(--r-sm);
  font-weight: 650; text-decoration: none; background: var(--ink); color: var(--ink-text); border: 1px solid var(--ink); }
a.btnfull:hover { opacity: .9; }
button.brand { background: var(--brand); color: #fff; border-color: var(--brand); }
button.brand:hover { background: var(--brand-2); border-color: var(--brand-2); }
button.ghost { background: transparent; border-color: transparent; color: var(--text-2); }
button.ghost:hover { background: var(--surface-3); color: var(--text); }
button.danger { color: var(--bad); border-color: color-mix(in srgb, var(--bad) 40%, transparent); background: transparent; }
button.danger:hover { background: var(--bad-soft); border-color: var(--bad); }
button.sm { padding: 5px 10px; font-size: 13px; border-radius: 8px; gap: 5px; }
button.sm svg.i { width: 15px; height: 15px; }
button.icon { padding: 7px; }
button:disabled { opacity: .5; cursor: not-allowed; }
.btns { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }

input, select, textarea {
  font: inherit; font-size: 14px; color: var(--text); background: var(--surface); border: 1px solid var(--line-strong);
  border-radius: var(--r-sm); padding: 9px 12px; width: 100%; min-width: 0;
}
input::placeholder { color: var(--text-3); }
label.f { display: grid; gap: 6px; font-size: 13px; font-weight: 550; color: var(--text-2); }
label.f .h { font-weight: 400; color: var(--text-3); font-size: 12.5px; }
.formgrid { display: grid; gap: 14px; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.search { position: relative; }
.search svg.i { position: absolute; left: 11px; top: 50%; transform: translateY(-50%); color: var(--text-3); }
.search input { padding-left: 36px; }

/* ---------------- Pills / Badges ---------------- */
.pill {
  display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 600; padding: 2px 9px;
  border-radius: 999px; background: var(--surface-3); color: var(--text-2); white-space: nowrap; line-height: 20px;
}
.pill svg.i { width: 13px; height: 13px; stroke-width: 2.2; }
.pill.ok { background: var(--ok-soft); color: var(--ok); }
.pill.warn { background: var(--warn-soft); color: var(--warn); }
.pill.bad { background: var(--bad-soft); color: var(--bad); }
.pill.info { background: var(--info-soft); color: var(--info); }
.pill.free { background: var(--free-soft); color: var(--free); }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--text-3); display: inline-block; flex: none; }
.dot.ok { background: var(--ok); box-shadow: 0 0 0 3px var(--ok-soft); }
.dot.bad { background: var(--bad); box-shadow: 0 0 0 3px var(--bad-soft); }
.dot.warn { background: var(--warn); box-shadow: 0 0 0 3px var(--warn-soft); }
.count { min-width: 20px; height: 20px; border-radius: 10px; padding: 0 6px; font-size: 11.5px; font-weight: 700;
         display: inline-flex; align-items: center; justify-content: center; background: var(--bad); color: #fff; }
.count.warn { background: var(--warn); color: #fff; }

/* ---------------- Panels ---------------- */
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow); }
.panel > .ph { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 20px 0; flex-wrap: wrap; }
.panel > .pb { padding: 16px 20px 20px; }
.panel > .pb.flush { padding: 8px 0 4px; }
.panel .sub { color: var(--text-3); font-size: 13px; }
.stack { display: grid; gap: 20px; }
.grid2 { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 20px; align-items: start; }
.empty { padding: 28px 20px; text-align: center; color: var(--text-3); font-size: 14px; }
.empty svg.i { width: 28px; height: 28px; display: block; margin: 0 auto 8px; opacity: .6; }
.linkbtn { background: none; border: 0; padding: 0; color: var(--text-2); font-size: 13px; font-weight: 550; }
.linkbtn:hover { background: none; color: var(--text); text-decoration: underline; }

/* ---------------- KPIs ---------------- */
.kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.kpi { padding: 16px 18px; }
.kpi .k { font-size: 13px; color: var(--text-2); display: flex; align-items: center; gap: 7px; }
.kpi .k svg.i { width: 16px; height: 16px; color: var(--text-3); }
.kpi .v { font-size: 26px; font-weight: 700; letter-spacing: -.02em; margin-top: 4px; font-variant-numeric: tabular-nums; }
.kpi .s { font-size: 12.5px; color: var(--text-3); margin-top: 2px; }

/* ---------------- Tables ---------------- */
.tbl { width: 100%; border-collapse: collapse; font-size: 14px; }
.tbl th { text-align: left; font-size: 12px; font-weight: 600; color: var(--text-3); text-transform: uppercase;
          letter-spacing: .04em; padding: 8px 20px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.tbl td { padding: 11px 20px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.tbl tr:last-child td { border-bottom: 0; }
.tbl tr.click { cursor: pointer; }
.tbl tr.click:hover td { background: var(--surface-2); }
.tbl tr.off td { color: var(--text-3); }
.tbl th.sel, .tbl td.sel { width: 1%; padding-right: 0; }
.tbl td.sel { cursor: default; }
.tbl input[type=checkbox] { width: 17px; height: 17px; margin: 0; cursor: pointer; accent-color: var(--ink); vertical-align: middle; }
.tbl tr.picked td { background: var(--surface-2); }
.bulkbar { display: flex; align-items: center; justify-content: space-between; gap: 10px 16px; flex-wrap: wrap;
           padding: 10px 14px 10px 18px; border: 1px solid var(--line-strong); border-radius: var(--r);
           background: var(--surface); box-shadow: var(--shadow-lg); position: sticky; top: 12px; z-index: 5; }
.bulkbar[hidden] { display: none; }
.bulkbar .cnt { font-size: 14px; }
.tbl td.right, .tbl th.right { text-align: right; }
.tbl .name { font-weight: 600; }
.tbl .who { display: flex; align-items: center; gap: 12px; }
.tbl .two { display: grid; line-height: 1.3; }
.tbl .two small { color: var(--text-3); font-size: 12.5px; }
.tablewrap { overflow-x: auto; }

/* Liste (Buchungen) */
.list { display: grid; }
.li { display: grid; grid-template-columns: 40px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 10px 20px; }
.li + .li { border-top: 1px solid var(--line); }
.li .ic { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--surface-3); color: var(--text-2); }
.li .ic.up { background: var(--ok-soft); color: var(--ok); }
.li .t { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.li .m { font-size: 12.5px; color: var(--text-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.li .a { font-weight: 650; font-variant-numeric: tabular-nums; text-align: right; white-space: nowrap; }
.li .a.up { color: var(--ok); }
.li .a small { display: block; font-weight: 400; font-size: 12px; color: var(--text-3); }
.daysep { padding: 14px 20px 4px; font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .05em; color: var(--text-3); }
.daysep + .li { border-top: 0; }

/* ---------------- Login ---------------- */
.login { min-height: 100vh; display: grid; place-items: center; padding: 32px 16px; }
.login .box { width: 100%; max-width: 460px; }
.login .brandrow { display: flex; align-items: center; gap: 12px; margin-bottom: 28px; justify-content: center; }
.login h1 { text-align: center; font-size: 26px; }
.login p.lead { text-align: center; color: var(--text-2); margin: 6px 0 24px; }
.tiles { display: grid; gap: 12px; }
.tile {
  display: grid; grid-template-columns: 48px 1fr 20px; gap: 14px; align-items: center; text-align: left;
  padding: 16px; border-radius: var(--r); background: var(--surface); border: 1px solid var(--line);
  box-shadow: var(--shadow); cursor: pointer; width: 100%; font-weight: 400; white-space: normal;
}
.tile:hover { border-color: var(--line-strong); background: var(--surface); box-shadow: var(--shadow-lg); }
.tile .ti { width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand); }
.tile .ti svg.i { width: 24px; height: 24px; }
.tile .ti.dark { background: var(--surface-3); color: var(--text); }
.tile b { display: block; font-size: 16px; }
.tile span { color: var(--text-3); font-size: 13.5px; }
.tile > svg.i { color: var(--text-3); }
.pick { max-height: 340px; overflow: auto; margin-top: 12px; display: grid; gap: 6px; }
.pick button { justify-content: flex-start; width: 100%; padding: 9px 12px; border-color: var(--line); gap: 12px; font-weight: 550; }
.pick button small { margin-left: auto; color: var(--text-3); font-weight: 400; }
.pick .av { width: 32px; height: 32px; font-size: 13px; }
/* ---- Anmeldung ohne Konto: „noch nicht verfügbar“ ----
 * Untertasse von oben mit der Tasse (Wolke fließt wie im Logo), Kaffeeringe daneben,
 * Stecknadel für die Dienststelle. Farben folgen Hell/Dunkel und den Farbschemen. */
.noacc { background:
    radial-gradient(60% 45% at 50% 0%, color-mix(in srgb, #E4C084 26%, transparent), transparent 70%),
    radial-gradient(50% 40% at 100% 100%, color-mix(in srgb, var(--brand) 10%, transparent), transparent 70%); }
.noacc .box { max-width: 520px; text-align: center; }
.noacc h1 { font-size: 25px; line-height: 1.25; letter-spacing: -.02em; margin: 6px auto 22px; max-width: 440px; text-wrap: balance; }
.noacc-art { position: relative; width: min(340px, 86vw); margin: 0 auto 6px; animation: noacc-in .9s cubic-bezier(.2, .8, .2, 1) both; }
.noacc-cup { width: 100%; height: auto; display: block; overflow: visible; }
.noacc-saucer { fill: var(--surface); stroke: var(--line); stroke-width: 2; filter: drop-shadow(0 18px 30px rgba(80, 40, 20, .16)); }
.noacc-cupg { filter: drop-shadow(0 6px 10px rgba(80, 40, 20, .18)); }
.noacc-saucer2 { fill: none; stroke: var(--line); stroke-width: 2; }
.noacc-rings circle { stroke: #C4813F; opacity: .28; }
.noacc-shadow { fill: rgba(0, 0, 0, .14); }
.noacc-pin { animation: noacc-pin 3.2s ease-in-out infinite; transform-box: fill-box; }
.noacc-site { position: absolute; right: -2%; bottom: 3%; display: inline-flex; align-items: center; gap: 6px;
  background: var(--surface); border: 1px solid var(--line); border-radius: 999px; padding: 5px 12px 5px 9px;
  font-size: 13px; font-weight: 650; color: var(--text); box-shadow: 0 6px 16px rgba(0, 0, 0, .10); transform: rotate(-3deg); }
.noacc-site svg.i { width: 15px; height: 15px; color: var(--brand); }
.noacc-act { display: flex; justify-content: center; }
.noacc-act button { background: var(--surface); }
.noacc-sent { display: inline-flex; gap: 10px; align-items: flex-start; text-align: left; margin: 0 auto; max-width: 420px;
  background: var(--ok-soft); color: var(--ok); border-radius: 14px; padding: 12px 16px; font-size: 14px; animation: noacc-in .5s ease both; }
.noacc-sent svg.i { flex: none; margin-top: 2px; }
@keyframes noacc-in { from { opacity: 0; transform: translateY(10px) scale(.98); } to { opacity: 1; transform: none; } }
@keyframes noacc-pin { 0%, 100% { transform: translate(368px, 250px); } 50% { transform: translate(368px, 240px); } }
@media (prefers-reduced-motion: reduce) { .noacc-art, .noacc-pin, .noacc-sent { animation: none; } }
.li.click { cursor: pointer; }
.li.click:hover { background: var(--surface-2); }
.reqpanel { border-color: color-mix(in srgb, var(--warn) 45%, var(--line)); }
.reqpanel .li .t { white-space: normal; }
.notice { font-size: 12.5px; color: var(--text-3); text-align: center; margin-top: 20px; }
.back { margin-bottom: 14px; }

.logo { width: 36px; height: 36px; border-radius: 10px; background: linear-gradient(135deg, var(--brand), var(--brand-2));
        display: grid; place-items: center; color: #fff; flex: none; box-shadow: 0 4px 12px color-mix(in srgb, var(--brand) 35%, transparent); }
.logo svg.i { width: 20px; height: 20px; stroke-width: 2.2; }
.logo:has(img), .logo:has(svg.cc-mark) { background: none; overflow: hidden; box-shadow: 0 4px 12px rgba(168, 39, 28, .28); }
.logo img, .logo svg.cc-mark { width: 100%; height: 100%; display: block; }
.login .logo { width: 48px; height: 48px; border-radius: 13px; }
.wordmark { font-weight: 750; font-size: 17px; letter-spacing: -.02em; line-height: 1.2; }
.wordmark small { display: block; font-size: 11.5px; font-weight: 500; color: var(--text-3); letter-spacing: 0; }

.av { width: 36px; height: 36px; border-radius: 50%; display: inline-grid; place-items: center; font-weight: 650;
      font-size: 14px; color: #fff; flex: none; background: var(--text-3); }

/* ---------------- Nutzerbereich ---------------- */
.ushell { max-width: 760px; margin: 0 auto; padding: 20px 16px 48px; }
.utop { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 22px; }
.utop .who { display: flex; align-items: center; gap: 12px; min-width: 0; }
.utop .who b { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hero {
  border-radius: 20px; padding: 24px; color: #fff; position: relative; overflow: hidden;
  background: radial-gradient(120% 140% at 100% 0%, #ff5a6e 0%, transparent 55%), linear-gradient(135deg, #c8102e, #6d0819);
  box-shadow: 0 14px 36px rgba(160, 16, 40, .28);
}
/* angedeutetes CoffeeCloud-Logo als Wasserzeichen (statt der zwei Kreise) */
:root { --hero-mark: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='92 102 320 278' fill='%23fff'%3E%3Ccircle cx='230.464' cy='240.464' r='114.6' fill='none' stroke='%23fff' stroke-width='23.7'/%3E%3Cpath d='M372.736 212.8H360.88C345.602 212.8 333.216 225.186 333.216 240.464C333.216 255.742 345.602 268.128 360.88 268.128H372.736C388.014 268.128 400.4 255.742 400.4 240.464C400.4 225.186 388.014 212.8 372.736 212.8Z'/%3E%3Cpath d='M188.7 292.464C210.515 292.464 228.2 276.346 228.2 256.464C228.2 236.582 210.515 220.464 188.7 220.464C166.885 220.464 149.2 236.582 149.2 256.464C149.2 276.346 166.885 292.464 188.7 292.464Z'/%3E%3Cpath d='M235.7 273.464C264.695 273.464 288.2 252.198 288.2 225.964C288.2 199.73 264.695 178.464 235.7 178.464C206.705 178.464 183.2 199.73 183.2 225.964C183.2 252.198 206.705 273.464 235.7 273.464Z'/%3E%3Cpath d='M277.745 292.792C296.677 292.792 312.024 277.544 312.024 258.735C312.024 239.926 296.677 224.678 277.745 224.678C258.814 224.678 243.467 239.926 243.467 258.735C243.467 277.544 258.814 292.792 277.745 292.792Z'/%3E%3Cpath d='M277.674 249.464H190.726C182.151 249.464 175.2 259.09 175.2 270.964C175.2 282.838 182.151 292.464 190.726 292.464H277.674C286.249 292.464 293.2 282.838 293.2 270.964C293.2 259.09 286.249 249.464 277.674 249.464Z'/%3E%3C/svg%3E"); }
.hero::after { content: ""; position: absolute; right: -34px; bottom: -58px; width: 270px; height: 235px; pointer-events: none;
               background: var(--hero-mark) no-repeat center / contain; opacity: .13; transform: rotate(-14deg); }
.hero > * { position: relative; z-index: 1; }
/* bewegtes Wasserzeichen aus logo.js ersetzt das statische ::after (gleiche Lage und Deckkraft) */
.hero:has(> .hero-mark)::after { content: none; }
.hero > .hero-mark { position: absolute; z-index: 0; right: -34px; bottom: -58px; width: 270px; height: 235px;
                     pointer-events: none; opacity: .13; transform: rotate(-14deg); }
@media (max-width: 560px) { .hero > .hero-mark { width: 200px; height: 174px; right: -30px; bottom: -44px; } }
.hero .lbl { font-size: 13.5px; opacity: .88; }
.hero .big { font-size: 44px; font-weight: 750; letter-spacing: -.03em; line-height: 1.1; margin: 6px 0 6px; font-variant-numeric: tabular-nums; }
.hero .meta { font-size: 13.5px; opacity: .88; display: flex; gap: 16px; flex-wrap: wrap; position: relative; z-index: 1; }
.hero .heroact { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 16px; }
.hero .heroact .small { opacity: .85; }
.hero button.onhero { background: #fff; color: #8a0b20; border: 0; font-weight: 650; box-shadow: 0 4px 14px rgba(0, 0, 0, .18); }
.hero button.onhero:hover { background: #fff3f4; }
.hero .blocked { background: rgba(0, 0, 0, .28); border-radius: 8px; padding: 6px 10px; display: inline-flex; gap: 6px; align-items: center; margin-top: 12px; font-size: 13px; }
.ustats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin: 16px 0 20px; }
.ustats .kpi .v { font-size: 21px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cardsgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px; }
.ccard { border: 1px solid var(--line); border-radius: var(--r); padding: 14px 16px; background: var(--surface-2); display: grid; gap: 8px; align-content: start; }
.ccard .top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.ccard .lab { font-weight: 650; display: flex; align-items: center; gap: 8px; min-width: 0; }
.ccard .lab span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ccard .uid { color: var(--text-3); font-size: 12.5px; }
.ccard.off { opacity: .7; }
.ccard .acts { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 4px; }
.ccard.add { border-style: dashed; place-items: center; text-align: center; color: var(--text-2); cursor: pointer; min-height: 120px; background: transparent; }
.ccard.add:hover { background: var(--surface-2); color: var(--text); }

/* ---------------- Admin-Layout ---------------- */
.ashell { display: grid; grid-template-columns: 244px minmax(0, 1fr); min-height: 100vh; }
.side { background: var(--surface); border-right: 1px solid var(--line); padding: 18px 12px; position: sticky; top: 0;
        height: 100vh; display: flex; flex-direction: column; gap: 2px; overflow-y: auto; }
.side .brandrow { display: flex; align-items: center; gap: 10px; padding: 4px 8px 18px; }
.nav { display: grid; gap: 2px; }
.nav a { display: flex; align-items: center; gap: 11px; padding: 9px 10px; border-radius: 10px; color: var(--text-2);
         text-decoration: none; font-weight: 550; font-size: 14px; }
.nav a:hover { background: var(--surface-2); color: var(--text); }
.nav a.on { background: var(--surface-3); color: var(--text); }
.nav a.on svg.i { color: var(--brand); }
.nav a .count { margin-left: auto; }
.side .foot { margin-top: auto; border-top: 1px solid var(--line); padding-top: 12px; display: grid; gap: 4px; }
.side .foot .me { display: flex; align-items: center; gap: 10px; padding: 6px 8px; font-size: 13.5px; }
.side .foot button { justify-content: flex-start; }
.main { min-width: 0; }
.topbar { position: sticky; top: 0; z-index: 5; display: flex; align-items: center; gap: 12px; padding: 16px 28px;
          background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
.topbar h1 { font-size: 21px; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.topbar .menu { display: none; }
/* „Beta“-Kennzeichnung (Testphase) */
.beta { display: inline-flex; align-items: center; vertical-align: middle; margin-left: 4px; padding: 2px 7px 2px;
  border-radius: 999px; font-size: 10.5px; font-weight: 750; letter-spacing: .06em; text-transform: uppercase; line-height: 1.3;
  color: #7a4a10; background: linear-gradient(135deg, #f6dfb3, #E4C084); border: 1px solid rgba(160, 100, 30, .25); }
.wordmark .beta { position: relative; top: -2px; }
.utop .btns .beta { margin: 0 4px 0 0; flex: none; }
.beta-top { display: none; }

.content { padding: 4px 28px 40px; max-width: 1240px; }
.crumb { display: inline-flex; align-items: center; gap: 4px; font-size: 13.5px; color: var(--text-3); text-decoration: none; margin-bottom: 12px; }
.crumb:hover { color: var(--text); }
.scrim { display: none; }

/* Detailkopf Nutzer */
.uhead { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; }
.uhead .av { width: 56px; height: 56px; font-size: 20px; }
.uhead .nm { flex: 1; min-width: 200px; }
.uhead .nm h2 { font-size: 22px; display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.balbox { display: flex; gap: 32px; flex-wrap: wrap; align-items: flex-end; }
.balbox .v { font-size: 30px; font-weight: 750; letter-spacing: -.02em; font-variant-numeric: tabular-nums; line-height: 1.2; }
.balbox .k { font-size: 12.5px; color: var(--text-3); }

/* Chart (Verkäufe je Tag) */
.bars { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 10px; height: 180px; padding-top: 34px; }
.bars .col { display: grid; grid-template-rows: 1fr auto; height: 100%; gap: 6px; position: relative; outline: none; }
.bars .bar-wrap { display: flex; align-items: flex-end; justify-content: center; border-bottom: 1px solid var(--line-strong); position: relative; }
.bars .bar { width: min(36px, 72%); background: var(--series-1); border-radius: 4px 4px 0 0; min-height: 0; transition: opacity .15s; }
.bars .bar.zero { height: 0 !important; }
.bars .val { position: absolute; font-size: 12px; color: var(--text-2); font-variant-numeric: tabular-nums; transform: translateY(-100%); padding-bottom: 3px; }
.bars .col:hover .bar { opacity: .82; }
.bars .x { font-size: 12px; color: var(--text-3); text-align: center; }
.bars .x.today { color: var(--text); font-weight: 650; }
.bars .tip { position: absolute; bottom: calc(100% + 2px); left: 50%; transform: translateX(-50%); background: var(--ink); color: var(--ink-text);
             font-size: 12px; padding: 6px 9px; border-radius: 7px; white-space: nowrap; pointer-events: none; opacity: 0; transition: opacity .12s; z-index: 3; line-height: 1.35; }
.bars .col:hover .tip, .bars .col:focus .tip { opacity: 1; }
.toplist { display: grid; gap: 10px; }
.toplist .tr { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 12px; font-size: 14px; }
.toplist .tr .track { grid-column: span 2; height: 6px; border-radius: 3px; background: var(--surface-3); overflow: hidden; }
.toplist .tr .track i { display: block; height: 100%; background: var(--series-1); border-radius: 3px; }

/* Probleme */
.prob { display: grid; grid-template-columns: 34px minmax(0, 1fr) auto; gap: 12px; padding: 14px 20px; align-items: start; }
.prob + .prob { border-top: 1px solid var(--line); }
.prob .pi { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; }
.prob.error .pi { background: var(--bad-soft); color: var(--bad); }
.prob.warn .pi { background: var(--warn-soft); color: var(--warn); }
.prob.info .pi { background: var(--info-soft); color: var(--info); }
.prob .pt { font-weight: 600; }
.prob .pd { color: var(--text-2); font-size: 13.5px; margin-top: 2px; word-break: break-word; }
.prob .ph2 { color: var(--text-3); font-size: 13px; margin-top: 5px; display: flex; gap: 6px; align-items: flex-start; }
.prob .ph2 svg.i { width: 15px; height: 15px; margin-top: 2px; }
.prob .pm { text-align: right; font-size: 12.5px; color: var(--text-3); display: grid; gap: 4px; justify-items: end; }
.allgood { display: flex; gap: 14px; align-items: center; padding: 20px; }
.allgood .pi { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: var(--ok-soft); color: var(--ok); flex: none; }
.seg { display: inline-flex; background: var(--surface-3); border-radius: 10px; padding: 3px; gap: 2px; flex-wrap: wrap; }
.seg button { border: 0; background: transparent; padding: 5px 12px; font-size: 13px; border-radius: 8px; color: var(--text-2); }
.seg button:hover { background: transparent; color: var(--text); }
.seg button.on { background: var(--surface); color: var(--text); box-shadow: var(--shadow); }
.toolbar { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.toolbar .search { flex: 1; min-width: 200px; max-width: 360px; }

/* Kartenleser */
.devs { display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: 16px; }
/* Personen-Auswahl (Ladestationen): Knopf + aufklappende Liste mit Suche */
.ppick { position: relative; flex: 1 1 200px; min-width: 0; }
.ppick .ppbtn { width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 8px; text-align: left;
  background: var(--surface); color: var(--text); border: 1px solid var(--line-strong); font-weight: 500; }
.ppick .ppbtn .pplabel { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.ppick .ppbtn svg.i { flex: none; color: var(--text-3); transform: rotate(90deg); }
.ppick .ppbtn[aria-expanded="true"] svg.i { transform: rotate(-90deg); }
.ppick .pppop { position: absolute; z-index: 40; top: calc(100% + 4px); left: 0; width: max(100%, 300px); max-width: calc(100vw - 32px);
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-sm); box-shadow: var(--shadow-lg); padding: 8px; }
.ppick .pppop .search input { width: 100%; }
.ppick .pplist { max-height: 300px; overflow-y: auto; margin-top: 6px; display: grid; }
.ppick .pph { position: sticky; top: 0; background: var(--surface); font-size: 11.5px; font-weight: 650; letter-spacing: .04em;
  text-transform: uppercase; color: var(--text-3); padding: 8px 8px 4px; }
.ppick .ppi { all: unset; box-sizing: border-box; display: grid; gap: 1px; padding: 7px 8px; border-radius: 8px; cursor: pointer; }
.ppick .ppi .nm { font-size: 14px; font-weight: 550; }
.ppick .ppi .mt { font-size: 12px; color: var(--text-3); }
.ppick .ppi.act, .ppick .ppi:hover { background: var(--surface-3); }
.ppick .ppi.sel .nm { color: var(--info); }
.ppick .ppi:focus-visible { outline: 2px solid var(--info); }
.ppick .ppnone { padding: 14px 8px; color: var(--text-3); font-size: 13.5px; text-align: center; }
.f > .ppick { flex: none; }
/* Geld & Essen (money.js, food.js) */
.reqbox { border-color: color-mix(in srgb, var(--warn) 45%, var(--line)); }
.reqbox .ph h2 { display: flex; align-items: center; gap: 8px; }
.reqbox .ph .count { background: var(--warn); color: #fff; }
.reqli { grid-template-columns: 40px minmax(0, 1fr) auto; }
.reqli .ic { background: var(--warn-soft); color: var(--warn); }
@media (max-width: 560px) { .reqli { grid-template-columns: 40px minmax(0, 1fr); } .reqli .btns { grid-column: 1 / -1; } }
.mysplit { border: 1px solid var(--line); border-radius: var(--r-sm); padding: 10px 12px; display: grid; gap: 6px; }
.mysplit + .mysplit { margin-top: 8px; }
.mysplit .hd { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; }
.mysplit .hd .sm { margin-left: auto; }
.mysplit .parts { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 13px; color: var(--text-2); }
details.notes .li.unread .t { color: var(--info); }
details.notes .li { padding: 8px 4px; }
details.notes summary .count { background: var(--info); color: #fff; margin-left: 6px; }
a.btnlink, span.btnlike { display: inline-flex; align-items: center; padding: 6px 12px; border-radius: 9px; font-size: 13px; font-weight: 600;
  text-decoration: none; color: var(--text); border: 1px solid var(--line); white-space: nowrap; }
span.btnlike.primary { background: var(--ink); color: var(--ink-text); border-color: var(--ink); }
a.li.folink { text-decoration: none; color: inherit; padding: 8px 4px; border-radius: 10px; }
a.li.folink:hover { background: var(--surface-2); }
.sprows { display: grid; gap: 6px; }
.sprow { display: grid; grid-template-columns: minmax(0, 1fr) 96px 34px; gap: 8px; align-items: center; }
.sprow .nm { font-weight: 550; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sprow input { text-align: right; font-variant-numeric: tabular-nums; }
.sprow input.manual { border-color: var(--info); }
.fohead { display: flex; gap: 14px; align-items: flex-start; flex-wrap: wrap; }
.fohead > div:nth-child(2) { flex: 1 1 260px; }
.fohead h2 { margin: 0 0 2px; font-size: 19px; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.fohead .ic { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand); flex: none; }
.foadd { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1.4fr) 80px minmax(0, 1.2fr) auto; gap: 10px; align-items: end; }
.foadd:not(:has(#fa_u)) { grid-template-columns: minmax(0, 1.6fr) 80px minmax(0, 1.2fr) auto; }
@media (max-width: 860px) { .foadd, .foadd:not(:has(#fa_u)) { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } .foadd button { grid-column: 1 / -1; } }
.foperson { padding: 10px 20px; border-top: 1px solid var(--line); }
.foperson:first-child { border-top: 0; }
.foperson .hd { display: flex; align-items: center; gap: 6px; margin-bottom: 4px; }
.foperson .hd .right { margin-left: auto; font-weight: 700; }
.foitem { display: grid; grid-template-columns: minmax(0, 1fr) auto 30px; gap: 8px; align-items: center; font-size: 14px; padding: 2px 0; }
.foitem .num { text-align: right; }
.foitem .icon.sm { width: 28px; height: 28px; padding: 0; }
ul.fosum { margin: 0 0 12px; padding-left: 18px; display: grid; gap: 6px; }
.fogrid { grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); }
.tbl tr.addrow td { background: var(--surface-2); }
.tbl tr.addrow input { width: 100%; }
.panel.off { opacity: .7; }
.fotot { display: grid; gap: 4px; font-size: 14px; }
.fotot > div { display: flex; justify-content: space-between; gap: 12px; color: var(--text-2); }
.fotot > div.sum { color: var(--text); font-weight: 700; border-top: 1px solid var(--line); padding-top: 6px; margin-top: 2px; }
@media (max-width: 560px) { .foadd, .foadd:not(:has(#fa_u)) { grid-template-columns: minmax(0, 1fr) 80px; } .foadd > .f:not(.fa-q) { grid-column: 1 / -1; } }
.dev { padding: 18px 20px; display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; align-content: start; min-width: 0; }
.dev .dh { display: flex; align-items: center; gap: 10px; }
.dev .dh .dn { flex: 1; min-width: 0; display: grid; line-height: 1.3; }
.dev .dh b { font-size: 15.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dev .dh small { font-size: 12.5px; color: var(--text-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.beats { display: grid; grid-template-columns: repeat(30, 1fr); gap: 3px; }
.beats i { height: 16px; border-radius: 3px; background: var(--surface-3); }
.beats i.on { background: var(--ok); }
.beatcap { display: flex; justify-content: space-between; font-size: 11.5px; color: var(--text-3); margin-top: -8px; }
.kv { display: grid; grid-template-columns: 104px minmax(0, 1fr); gap: 7px 12px; margin: 0; font-size: 13.5px; }
.kv dt { color: var(--text-3); }
.kv dd { margin: 0; overflow: hidden; text-overflow: ellipsis; }
.t-ok { color: var(--ok); font-weight: 600; }
.t-bad { color: var(--bad); font-weight: 600; }
.t-warn { color: var(--warn); font-weight: 600; }
.stmgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(84px, 1fr)); gap: 8px; }
.stmgrid div { background: var(--surface-2); border-radius: 8px; padding: 7px 9px; min-width: 0; }
.stmgrid b { display: block; font-size: 15px; font-variant-numeric: tabular-nums; overflow: hidden; text-overflow: ellipsis; }
.stmgrid span { font-size: 11.5px; color: var(--text-3); }
.stmgrid .bad { background: var(--bad-soft); }
.stmgrid .bad b { color: var(--bad); }
details.more summary { cursor: pointer; font-size: 13px; color: var(--text-2); font-weight: 550; list-style: none; display: inline-flex; gap: 6px; align-items: center; }
details.more summary::-webkit-details-marker { display: none; }
details.more[open] summary svg.i { transform: rotate(90deg); }
details.more summary svg.i { width: 14px; height: 14px; transition: transform .15s; }
details.more > div { margin-top: 12px; }

/* Log */
pre.log { margin: 0; height: calc(100vh - 210px); min-height: 320px; overflow: auto; font: 12.5px/1.6 var(--mono);
          background: #0f1318; color: #d6dde6; border-radius: var(--r); padding: 14px 16px; white-space: pre-wrap; word-break: break-word; }
pre.log .lt { color: #6f7b8a; }
pre.log .lsec { color: #ff8a7a; }
pre.log .lsrv { color: #8fb8ff; }
pre.log .lvend { color: #7fe0a8; }

/* Produkte */
.pname { display: flex; gap: 6px; align-items: center; }
.pname input { max-width: 300px; padding: 6px 10px; }
.pname input.dirty { border-color: var(--warn); }
/* Produkte: Automaten-Auswahl */
.mtabs { display: flex; gap: 8px; flex-wrap: wrap; }
.mtabs button { display: flex; align-items: center; gap: 10px; padding: 10px 14px; border-radius: var(--r-sm);
                background: var(--surface); border: 1px solid var(--line); color: var(--text-2); text-align: left; min-width: 0; }
.mtabs button:hover { border-color: var(--line-strong); color: var(--text); }
.mtabs button.on { border-color: var(--text); color: var(--text); box-shadow: var(--shadow); }
.mtabs .mt { display: flex; flex-direction: column; min-width: 0; line-height: 1.25; }
.mtabs .mt b { font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 220px; }
.mtabs .mt small { font-size: 12px; color: var(--text-3); }
.mtabs .count, .pnote .count { background: var(--warn); color: #fff; border-radius: 999px; font-size: 11px; font-weight: 700;
                               min-width: 18px; height: 18px; padding: 0 5px; display: inline-grid; place-items: center; }
.pnote { margin-top: 0; }
.pnote.ok { background: var(--ok-soft); color: var(--ok); }
.pnote .btns button { color: var(--text); }
tr.pnew td:first-child { box-shadow: inset 3px 0 0 var(--warn); }
@media (max-width: 560px) { .mtabs button { flex: 1 1 100%; } .mtabs button .count { margin-left: auto; } }
.subrow td { background: var(--surface-2); font-size: 13px; padding-top: 7px; padding-bottom: 7px; }
.subrow .pname input { max-width: 240px; font-size: 13px; padding: 4px 8px; }

/* ---------------- Modal / Toast ---------------- */
dialog.modal { border: 0; padding: 0; border-radius: 18px; width: min(480px, calc(100vw - 32px)); background: var(--surface);
               color: var(--text); box-shadow: var(--shadow-lg); }
dialog.modal::backdrop { background: rgba(10, 14, 20, .45); }
dialog .mh { display: flex; align-items: center; justify-content: space-between; padding: 18px 20px 4px; gap: 12px; }
dialog .mb { padding: 12px 20px 4px; }
dialog .mb p { margin: 0 0 12px; color: var(--text-2); }
dialog .mf { display: flex; justify-content: flex-end; gap: 8px; padding: 16px 20px 18px; flex-wrap: wrap; }
.amounts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.amounts button { justify-content: center; padding: 10px 0; }
.amounts button.on { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.waiting { display: grid; justify-items: center; gap: 12px; padding: 14px 0 6px; text-align: center; }
.waiting p { margin: 0; }
.pulse { width: 74px; height: 74px; border-radius: 50%; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand);
         animation: pulse 1.6s ease-out infinite; }
.pulse svg.i { width: 32px; height: 32px; }
.pulse.ok { background: var(--ok-soft); color: var(--ok); animation: none; }
.pulse.bad { background: var(--bad-soft); color: var(--bad); animation: none; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--brand) 40%, transparent); }
                   100% { box-shadow: 0 0 0 22px transparent; } }
.err { color: var(--bad); font-size: 13px; min-height: 18px; margin-top: 8px; }
.callout { display: flex; gap: 10px; padding: 10px 12px; border-radius: var(--r-sm); background: var(--warn-soft); color: var(--warn); font-size: 13px; margin-top: 12px; }
.callout svg.i { margin-top: 1px; }

#toasts { position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%); display: grid; gap: 8px; z-index: 100; justify-items: center; pointer-events: none; }
.toast { background: var(--ink); color: var(--ink-text); padding: 10px 16px; border-radius: 12px; box-shadow: var(--shadow-lg);
         font-size: 14px; display: flex; gap: 8px; align-items: center; animation: tin .2s ease-out; max-width: calc(100vw - 32px); }
.toast.bad { background: var(--bad); color: #fff; }
@keyframes tin { from { opacity: 0; transform: translateY(8px); } }

.skel { background: linear-gradient(90deg, var(--surface-3), var(--surface-2), var(--surface-3)); background-size: 200% 100%;
        animation: sk 1.2s linear infinite; border-radius: 8px; height: 14px; }
@keyframes sk { to { background-position: -200% 0; } }
.loading { padding: 40px; display: grid; gap: 12px; }

/* ---------------- Responsiv ---------------- */
@media (max-width: 1100px) {
  .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid2 { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 860px) {
  .ashell { grid-template-columns: minmax(0, 1fr); }
  .side { position: fixed; left: 0; top: 0; z-index: 30; width: 264px; transform: translateX(-100%); transition: transform .2s; box-shadow: var(--shadow-lg); }
  .ashell.navopen .side { transform: none; }
  .ashell.navopen .scrim { display: block; position: fixed; inset: 0; background: rgba(10, 14, 20, .4); z-index: 20; }
  .topbar { padding: 12px 16px; }
  .topbar .menu { display: inline-flex; }
  .topbar h1 { flex: 0 1 auto; }
  .beta-top { display: inline-flex; margin-right: auto; }
  .content { padding: 4px 16px 32px; }
  .tbl th, .tbl td { padding-left: 14px; padding-right: 14px; }
  .tbl .hide-s { display: none; }
  .li { padding: 10px 14px; }
  .daysep { padding-left: 14px; }
  .panel > .ph { padding: 14px 16px 0; }
  .panel > .pb { padding: 14px 16px 16px; }
  .prob { padding: 12px 14px; grid-template-columns: 34px minmax(0, 1fr); }
  .prob .pm { grid-column: 2; justify-items: start; text-align: left; display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
}
@media (max-width: 560px) {
  .kpis { gap: 10px; }
  .kpi { padding: 12px 14px; }
  .kpi .v { font-size: 21px; }
  .ustats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ustats .kpi:last-child { grid-column: span 2; }
  .hero { padding: 20px; }
  .hero .big { font-size: 38px; }
  .hero::after { width: 200px; height: 174px; right: -30px; bottom: -44px; }
  .row2 { grid-template-columns: 1fr; }
  .devs { grid-template-columns: minmax(0, 1fr); }
  .stmgrid { grid-template-columns: repeat(3, 1fr); }
  .amounts { grid-template-columns: repeat(2, 1fr); }
  .balbox { gap: 20px; }
  .tbl .hide-xs { display: none; }
}

/* Automaten: Zahlungsarten, Bus-Scan, Gateway */
.src-coffeecloud { background: var(--src-cc); } .src-cash { background: var(--src-cash); }
.src-terminal { background: var(--src-term); } .src-free { background: var(--src-free); }
.src-token, .src-other, .src-test { background: var(--src-misc); }
.srcbar { display: flex; gap: 2px; height: 12px; border-radius: 4px; overflow: hidden; margin: 2px 0; }
.srcbar i { display: block; min-width: 3px; }
.srclegend { display: flex; flex-wrap: wrap; gap: 6px 18px; margin-top: 10px; font-size: 13.5px; color: var(--text-2); }
.srclegend span { display: inline-flex; align-items: center; gap: 6px; }
.srclegend i { width: 10px; height: 10px; border-radius: 3px; display: inline-block; }
.srclegend b { color: var(--text); }
.mbox { display: grid; gap: 8px; padding: 10px 12px; border-radius: var(--r-sm); background: var(--surface-2); }
.mbox .mh { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.mbox .k { font-size: 13px; color: var(--text-2); }
.btnlink { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; font-weight: 600; color: var(--text); text-decoration: none; }
.btnlink:hover { text-decoration: underline; }
.mstats { grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); }
.daybars { display: flex; align-items: flex-end; gap: 4px; height: 150px; overflow-x: auto; padding-bottom: 2px; }
.daybars .db { flex: 1 0 22px; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; height: 100%; gap: 4px; }
.daybars .col { width: min(28px, 80%); display: flex; flex-direction: column-reverse; gap: 2px; border-radius: 4px 4px 0 0; overflow: hidden; min-height: 2px; }
.daybars .col i { display: block; min-height: 2px; }
.daybars span { font-size: 10.5px; color: var(--text-3); white-space: nowrap; }
.gwbox { display: flex; align-items: center; justify-content: space-between; gap: 12px 16px; flex-wrap: wrap;
         padding: 12px 14px; border-radius: var(--r-sm); background: var(--surface-2); }
.gwbox > div { flex: 1 1 280px; }
.gwbox.ours { background: var(--ok-soft); } .gwbox.free { background: var(--info-soft); }
.kassegrid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }

/* Bargeld-Aufladungen je Automat */
.cashbox { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 12px;
           border-radius: var(--r-sm); background: var(--surface-2); flex-wrap: wrap; }
.cashbox .k { font-size: 12px; color: var(--text-3); }
.cashbox .v { font-size: 17px; font-weight: 700; }

/* Gratis: Automat freigeschaltet / unbegrenztes Konto */
.freebox { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 12px;
           border-radius: var(--r-sm); background: var(--surface-2); flex-wrap: wrap; }
.freebox.on { background: var(--free-soft); color: var(--free); }
.freebox.on.credit { background: var(--info-soft); color: var(--info); }
.hero button.credinfo { background: rgba(255, 255, 255, .18); color: #fff; border: 0; border-radius: 50%; width: 22px; height: 22px;
  padding: 0; margin-left: 6px; display: inline-grid; place-items: center; vertical-align: -5px; cursor: pointer; box-shadow: none; }
.hero button.credinfo:hover { background: rgba(255, 255, 255, .32); }
.hero button.credinfo svg { width: 15px; height: 15px; }
.credinfo-box { display: flex; gap: 12px; align-items: center; padding: 12px 14px; border-radius: var(--r-sm);
  background: var(--info-soft); color: var(--info); margin-bottom: 12px; }
.credinfo-box .k { font-size: 12px; opacity: .85; }
.credinfo-box .v { font-size: 18px; font-weight: 700; }
ul.credlist { margin: 10px 0 14px; padding-left: 18px; display: grid; gap: 8px; font-size: 14px; color: var(--text-2); }
ul.credlist b { color: var(--text); }
.freebox .credwait { display: flex; gap: 8px; align-items: flex-start; margin-top: 8px; padding: 8px 10px; border-radius: var(--r-sm);
  background: var(--warn-soft); color: var(--warn); font-size: 13px; }
.freebox .credwait svg { flex: none; margin-top: 1px; }
.freebox .k { font-size: 12px; color: var(--text-3); }
.freebox.on .k { color: inherit; opacity: .85; }
.freebox .v { font-size: 17px; font-weight: 700; }
.freebox .v.small { font-size: 14px; font-weight: 600; }
.freebox .btns { gap: 6px; }
.freebox.on { flex-direction: column; align-items: stretch; gap: 10px; }
.freebox.on .btns { justify-content: flex-start; }
.freebox .k svg.i { width: 14px; height: 14px; vertical-align: -2px; }
.flag.free { background: var(--free-soft); color: var(--free); }
.freebar { height: 4px; border-radius: 2px; background: color-mix(in srgb, var(--free) 22%, transparent); overflow: hidden; margin-top: 6px; width: 100%; }
.freebar i { display: block; height: 100%; background: var(--free); }
.durs { display: flex; flex-wrap: wrap; gap: 8px; }
/* Guthaben aufladen: Wahl online / am Automaten und die Schritte am Automaten */
.seg.wide { display: grid; grid-template-columns: 1fr 1fr; }
.seg.wide button { justify-content: center; gap: 6px; }
.seg.wide button svg.i { width: 16px; height: 16px; }
.topup-how { display: grid; gap: 8px; background: var(--surface-2); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; font-size: 13.5px; }
.topup-how > div { display: grid; grid-template-columns: 22px 1fr; gap: 8px; align-items: start; }
.topup-how .n { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; font-size: 12px; font-weight: 700;
  background: var(--brand); color: #fff; }
.topup-wait #tLeft { font-variant-numeric: tabular-nums; font-weight: 650; }
.durs button.on { background: var(--free-soft); color: var(--free); border-color: var(--free); }
.a.num.free, .t-free { color: var(--free); }
.li .ic.free { background: var(--free-soft); color: var(--free); }
.hero.free .big { display: flex; align-items: center; gap: 10px; }
.hero.free .big svg.i { width: 40px; height: 40px; stroke-width: 2.4; }

/* ---------------- Schalter (Einstellungen) ---------------- */
.tgl { display: flex; align-items: flex-start; gap: 12px; cursor: pointer; font-size: 14px; }
.tgl input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.tgl .sw { flex: none; width: 38px; height: 22px; border-radius: 999px; background: var(--line-strong); position: relative; transition: background .15s; margin-top: 1px; }
.tgl .sw::after { content: ""; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; transition: transform .15s; box-shadow: 0 1px 2px rgba(0,0,0,.25); }
.tgl input:checked + .sw { background: var(--ok); }
.tgl input:checked + .sw::after { transform: translateX(16px); }
.tgl input:focus-visible + .sw { outline: 2px solid var(--ok); outline-offset: 2px; }
.tgl b { display: block; font-weight: 600; }
.tgl small { display: block; color: var(--text-3); font-size: 12.5px; margin-top: 2px; }
.offdep.off { opacity: .45; pointer-events: none; }
.flag { display: inline-block; font-size: 11px; font-weight: 650; padding: 0 6px; border-radius: 999px; line-height: 17px; background: var(--warn-soft); color: var(--warn); margin-left: 6px; vertical-align: 1px; }
.row2 > label.f { align-content: start; }

/* ---------------- Anmeldung: Warten / 2FA ---------------- */
.login [hidden] { display: none !important; }
.loginwait { display: flex; flex-direction: column; align-items: center; gap: 12px; padding: 24px 8px 8px; text-align: center; }
.loginwait p { margin: 0; }
.loginwait .code { font-family: var(--mono); font-size: 40px; font-weight: 700; letter-spacing: 8px;
  color: var(--brand); background: var(--brand-soft); padding: 12px 20px 12px 28px; border-radius: 14px; }
.spin { width: 30px; height: 30px; border-radius: 50%; border: 3px solid var(--line-strong);
  border-top-color: var(--brand); animation: ccspin 0.8s linear infinite; }
@keyframes ccspin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .spin { animation-duration: 2s; } }

/* ===================== Farbschema "Latte" (Farben des Logos) =====================
 * Kaffeerot #A8271C, Milchschaum #FFFBF5, Latte-Beige #E4C084, Karamell, Espresso.
 * Wird mit data-palette="latte" am <html> aktiv, hell und dunkel.            */
:root[data-palette="latte"] {
  --bg: #f6ede0; --surface: #fffbf5; --surface-2: #fbf3e8; --surface-3: #f2e3cd;
  --line: #ebdcc6; --line-strong: #d9c2a0; --text: #2b1b12; --text-2: #5e4536; --text-3: #8b705d;
  --brand: #a8271c; --brand-2: #7a1a11; --brand-soft: #f8e1da; --ink: #a8271c; --ink-text: #fffbf5;
  --ok: #2e7d4f; --ok-soft: #e5f2e8; --warn: #a15c0b; --warn-soft: #fbedd6; --bad: #b8321f; --bad-soft: #f9e1dc;
  --info: #2f6c8c; --info-soft: #e2eff5; --free: #0f8a70; --free-soft: #ddf2ea; --series-1: #c4813f;
  --accent: #e4c084; --accent-soft: #f6e6cb; --accent-ink: #6b4420; --caramel: #c4813f;
  --shadow: 0 1px 2px rgba(80, 40, 10, .06), 0 2px 6px rgba(80, 40, 10, .06);
  --shadow-lg: 0 14px 34px rgba(80, 40, 10, .16), 0 2px 6px rgba(80, 40, 10, .08);
}
@media (prefers-color-scheme: dark) {
  :root[data-palette="latte"]:not([data-theme="light"]) {
    --bg: #17100c; --surface: #221813; --surface-2: #2a1e18; --surface-3: #35261e;
    --line: #3d2c23; --line-strong: #523c2f; --text: #f7ecdf; --text-2: #d8c3ab; --text-3: #a88e78;
    --brand: #e0584a; --brand-2: #a8271c; --brand-soft: #3c1914; --ink: #e4c084; --ink-text: #24170f;
    --ok: #5fcf8f; --ok-soft: #15301f; --warn: #f0b04f; --warn-soft: #36250f; --bad: #ff7564; --bad-soft: #3d1813;
    --info: #79bde0; --info-soft: #14283a; --free: #4fd9b6; --free-soft: #0f2e27; --series-1: #e4c084;
    --accent: #e4c084; --accent-soft: #3a2a1b; --accent-ink: #f1d9ae; --caramel: #d69a5a;
    --shadow: 0 1px 2px rgba(0, 0, 0, .45); --shadow-lg: 0 16px 40px rgba(0, 0, 0, .6);
  }
}
:root[data-palette="latte"][data-theme="dark"] {
  --bg: #17100c; --surface: #221813; --surface-2: #2a1e18; --surface-3: #35261e;
  --line: #3d2c23; --line-strong: #523c2f; --text: #f7ecdf; --text-2: #d8c3ab; --text-3: #a88e78;
  --brand: #e0584a; --brand-2: #a8271c; --brand-soft: #3c1914; --ink: #e4c084; --ink-text: #24170f;
  --ok: #5fcf8f; --ok-soft: #15301f; --warn: #f0b04f; --warn-soft: #36250f; --bad: #ff7564; --bad-soft: #3d1813;
  --info: #79bde0; --info-soft: #14283a; --free: #4fd9b6; --free-soft: #0f2e27; --series-1: #e4c084;
  --accent: #e4c084; --accent-soft: #3a2a1b; --accent-ink: #f1d9ae; --caramel: #d69a5a;
  --shadow: 0 1px 2px rgba(0, 0, 0, .45); --shadow-lg: 0 16px 40px rgba(0, 0, 0, .6);
}
/* warmer Hintergrund mit sanften Farbflaechen (feste Ebene hinter der Seite,
 * zuverlaessiger als background-attachment: fixed - vor allem auf iOS)        */
:root[data-palette="latte"] body::before {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background: radial-gradient(900px 520px at 105% -8%, color-mix(in srgb, var(--accent) 38%, transparent), transparent 62%),
              radial-gradient(760px 460px at -8% 108%, color-mix(in srgb, var(--brand) 12%, transparent), transparent 60%),
              var(--bg);
}
/* Guthaben-Karte: Kaffeerot mit Latte-Schimmer und Milchschaum-Kreisen */
:root[data-palette="latte"] .hero {
  background: radial-gradient(90% 120% at 100% 0%, rgba(228, 192, 132, .55) 0%, transparent 52%),
              radial-gradient(70% 90% at 0% 100%, rgba(255, 251, 245, .10) 0%, transparent 60%),
              linear-gradient(135deg, #b8342a 0%, #a8271c 45%, #6c160f 100%);
  box-shadow: 0 16px 38px rgba(120, 30, 18, .30);
}
:root[data-palette="latte"] .hero::after, :root[data-palette="latte"] .hero > .hero-mark { opacity: .16; }
/* Kennzahlen: jede Kachel mit eigener Akzentfarbe */
:root[data-palette="latte"] .kpi { position: relative; overflow: hidden; }
:root[data-palette="latte"] .kpi::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 4px; background: var(--k, var(--brand)); }
:root[data-palette="latte"] .kpi .k svg.i { color: var(--k, var(--brand)); }
:root[data-palette="latte"] .kpi:nth-child(4n+1) { --k: var(--brand); background: linear-gradient(180deg, color-mix(in srgb, var(--brand) 7%, var(--surface)), var(--surface) 70%); }
:root[data-palette="latte"] .kpi:nth-child(4n+2) { --k: var(--caramel); background: linear-gradient(180deg, color-mix(in srgb, var(--caramel) 10%, var(--surface)), var(--surface) 70%); }
:root[data-palette="latte"] .kpi:nth-child(4n+3) { --k: var(--free); background: linear-gradient(180deg, color-mix(in srgb, var(--free) 8%, var(--surface)), var(--surface) 70%); }
:root[data-palette="latte"] .kpi:nth-child(4n+4) { --k: var(--info); background: linear-gradient(180deg, color-mix(in srgb, var(--info) 8%, var(--surface)), var(--surface) 70%); }
/* Seitenleiste und Navigation */
:root[data-palette="latte"] .side { background: linear-gradient(180deg, color-mix(in srgb, var(--accent) 14%, var(--surface)), var(--surface) 55%); }
:root[data-palette="latte"] .nav a.on { background: var(--accent-soft); color: var(--accent-ink); font-weight: 600; }
:root[data-palette="latte"] .nav a.on svg.i { color: var(--brand); }
:root[data-palette="latte"] .nav a:hover:not(.on) { background: color-mix(in srgb, var(--accent) 14%, transparent); }
/* Panels mit warmer Kopfzeile, Tabellen mit Latte-Streifen */
:root[data-palette="latte"] .panel { border-color: var(--line); }
:root[data-palette="latte"] .tbl thead th { background: color-mix(in srgb, var(--accent) 16%, var(--surface)); }
:root[data-palette="latte"] .seg { background: var(--accent-soft); }
:root[data-palette="latte"] .mtabs button.on { border-color: var(--brand); box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 14%, transparent); }
:root[data-palette="latte"] .login .box > .panel, :root[data-palette="latte"] .login form.panel { box-shadow: var(--shadow-lg); }
:root[data-palette="latte"] .ccard:not(.add) { background: linear-gradient(135deg, color-mix(in srgb, var(--accent) 22%, var(--surface)), var(--surface-2)); }
:root[data-palette="latte"] .daysep { color: var(--caramel); }

/* ===================== Farbschema "Konfetti" (verspielt) =====================
 * Bonbonfarben, runde Schrift, Sticker-Kacheln, huepfende Knoepfe.
 * Aktiv mit data-palette="konfetti" am <html>, hell und dunkel.               */
:root[data-palette="konfetti"] {
  --bg: #fff7ec; --surface: #ffffff; --surface-2: #fff4f8; --surface-3: #ffe9f1;
  --line: #f1dde9; --line-strong: #cdb4d8; --text: #2b1d3a; --text-2: #55406b; --text-3: #8a77a0;
  --brand: #ff4d6d; --brand-2: #d61f4a; --brand-soft: #ffe1e8; --ink: #2b1d3a; --ink-text: #ffffff;
  --ok: #1f9e6e; --ok-soft: #d9f7ea; --warn: #c76a00; --warn-soft: #fff0c9; --bad: #e0244a; --bad-soft: #ffe0e7;
  --info: #2a7de1; --info-soft: #dff0ff; --free: #12a594; --free-soft: #d6f6f1; --series-1: #7b2ff7;
  --c1: #ff4d6d; --c2: #ffc93c; --c3: #2ec4b6; --c4: #4cc9f0; --c5: #7b2ff7; --c6: #ff8c42;
  --stick: #2b1d3a;
  --r: 22px; --r-sm: 14px;
  --shadow: 3px 3px 0 var(--stick); --shadow-lg: 6px 6px 0 var(--stick);
  --font: ui-rounded, "SF Pro Rounded", "Nunito", "Varela Round", "Quicksand", system-ui, -apple-system, "Segoe UI", sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root[data-palette="konfetti"]:not([data-theme="light"]) {
    --bg: #1a1430; --surface: #261d45; --surface-2: #2e2453; --surface-3: #3a2e66;
    --line: #3b2f63; --line-strong: #5b4a8c; --text: #fff4fb; --text-2: #e1d2f2; --text-3: #b09ccc;
    --brand: #ff6b88; --brand-2: #ff3d66; --brand-soft: #4a1d3a; --ink: #ffc93c; --ink-text: #2b1d3a;
    --ok: #4ee6a6; --ok-soft: #17382e; --warn: #ffc93c; --warn-soft: #43351a; --bad: #ff6b88; --bad-soft: #4a1d30;
    --info: #6fd3ff; --info-soft: #1b2f4f; --free: #4fe3cf; --free-soft: #133a38; --series-1: #c38bff;
    --stick: #0d0919;
  }
}
:root[data-palette="konfetti"][data-theme="dark"] {
  --bg: #1a1430; --surface: #261d45; --surface-2: #2e2453; --surface-3: #3a2e66;
  --line: #3b2f63; --line-strong: #5b4a8c; --text: #fff4fb; --text-2: #e1d2f2; --text-3: #b09ccc;
  --brand: #ff6b88; --brand-2: #ff3d66; --brand-soft: #4a1d3a; --ink: #ffc93c; --ink-text: #2b1d3a;
  --ok: #4ee6a6; --ok-soft: #17382e; --warn: #ffc93c; --warn-soft: #43351a; --bad: #ff6b88; --bad-soft: #4a1d30;
  --info: #6fd3ff; --info-soft: #1b2f4f; --free: #4fe3cf; --free-soft: #133a38; --series-1: #c38bff;
  --stick: #0d0919;
}
/* Konfetti im Hintergrund (feste Ebene) */
:root[data-palette="konfetti"] body::before {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(circle at 20px 24px, var(--c1) 0 3.5px, transparent 4.5px),
    radial-gradient(circle at 74px 60px, var(--c2) 0 4px, transparent 5px),
    radial-gradient(circle at 128px 16px, var(--c3) 0 3px, transparent 4px),
    radial-gradient(circle at 44px 104px, var(--c4) 0 3.5px, transparent 4.5px),
    radial-gradient(circle at 150px 118px, var(--c5) 0 3px, transparent 4px),
    radial-gradient(circle at 104px 150px, var(--c6) 0 3.5px, transparent 4.5px),
    radial-gradient(700px 420px at 100% 0%, color-mix(in srgb, var(--c2) 22%, transparent), transparent 65%),
    radial-gradient(640px 420px at 0% 100%, color-mix(in srgb, var(--c4) 20%, transparent), transparent 65%),
    var(--bg);
  background-size: 170px 170px, 170px 170px, 170px 170px, 170px 170px, 170px 170px, 170px 170px, auto, auto, auto;
  opacity: 1;
}
:root[data-palette="konfetti"] body { font-weight: 500; }
:root[data-palette="konfetti"] h1, :root[data-palette="konfetti"] h2 { font-weight: 800; letter-spacing: 0; }
/* Sticker-Kacheln */
:root[data-palette="konfetti"] .panel { border: 2px solid var(--stick); box-shadow: var(--shadow); }
:root[data-palette="konfetti"] .tbl thead th { background: var(--surface-3); }
:root[data-palette="konfetti"] input, :root[data-palette="konfetti"] select, :root[data-palette="konfetti"] textarea {
  border: 2px solid var(--stick); border-radius: var(--r-sm); }
/* Knoepfe: Pillen, huepfen beim Drueberfahren */
:root[data-palette="konfetti"] button { border-radius: 999px; border: 2px solid var(--stick); font-weight: 700;
  transition: transform .18s cubic-bezier(.3, 1.6, .5, 1), box-shadow .18s, background .15s; }
:root[data-palette="konfetti"] button:not(.ghost):not(:disabled):hover { transform: translateY(-2px) rotate(-1deg); box-shadow: 3px 3px 0 var(--stick); }
:root[data-palette="konfetti"] button:active { transform: translateY(1px) scale(.97); box-shadow: none; }
:root[data-palette="konfetti"] button.primary { background: linear-gradient(135deg, var(--c1), var(--c6)); color: #fff; border-color: var(--stick); }
:root[data-palette="konfetti"] button.primary:hover { background: linear-gradient(135deg, var(--c1), var(--c2)); opacity: 1; }
:root[data-palette="konfetti"] button.ghost { border-color: transparent; }
/* kachelfoermige Knoepfe bleiben Kacheln */
:root[data-palette="konfetti"] .palettes button, :root[data-palette="konfetti"] .mtabs button,
:root[data-palette="konfetti"] button.ccard, :root[data-palette="konfetti"] .modes button { border-radius: var(--r-sm); }
:root[data-palette="konfetti"] button.ghost:hover { background: var(--surface-3); }
:root[data-palette="konfetti"] .seg { border: 2px solid var(--stick); border-radius: 999px; background: var(--surface); }
:root[data-palette="konfetti"] .seg button { border: 0; border-radius: 999px; }
:root[data-palette="konfetti"] .seg button.on { background: var(--c2); color: #2b1d3a; box-shadow: none; }
:root[data-palette="konfetti"] .pill, :root[data-palette="konfetti"] .flag { border: 1.5px solid currentColor; }
/* Guthaben-Banner: Bonbon-Verlauf, das Logo schwebt */
:root[data-palette="konfetti"] .hero { border: 2px solid var(--stick); box-shadow: var(--shadow-lg); border-radius: 28px;
  background: radial-gradient(60% 80% at 100% 0%, rgba(255, 201, 60, .85), transparent 60%),
              radial-gradient(60% 90% at 0% 100%, rgba(76, 201, 240, .55), transparent 60%),
              linear-gradient(135deg, #ff4d6d 0%, #f72585 45%, #7b2ff7 100%); }
:root[data-palette="konfetti"] .hero::after, :root[data-palette="konfetti"] .hero > .hero-mark { opacity: .22; animation: cc-float 6s ease-in-out infinite; }
:root[data-palette="konfetti"] .hero .big { font-weight: 850; text-shadow: 3px 3px 0 rgba(43, 29, 58, .25); }
@keyframes cc-float { 0%, 100% { transform: rotate(-14deg) translateY(0); } 50% { transform: rotate(-8deg) translateY(-10px); } }
/* Kennzahlen: bunte Sticker, leicht schief */
:root[data-palette="konfetti"] .kpi { transition: transform .2s cubic-bezier(.3, 1.6, .5, 1); }
:root[data-palette="konfetti"] .kpi:nth-child(4n+1) { background: color-mix(in srgb, var(--c2) 34%, var(--surface)); transform: rotate(-1deg); }
:root[data-palette="konfetti"] .kpi:nth-child(4n+2) { background: color-mix(in srgb, var(--c3) 30%, var(--surface)); transform: rotate(.8deg); }
:root[data-palette="konfetti"] .kpi:nth-child(4n+3) { background: color-mix(in srgb, var(--c4) 30%, var(--surface)); transform: rotate(-.6deg); }
:root[data-palette="konfetti"] .kpi:nth-child(4n+4) { background: color-mix(in srgb, var(--c1) 22%, var(--surface)); transform: rotate(1deg); }
:root[data-palette="konfetti"] .kpi:hover { transform: rotate(0) scale(1.02); }
:root[data-palette="konfetti"] .kpi .k { color: var(--text); font-weight: 700; }
:root[data-palette="konfetti"] .kpi .k svg.i { color: var(--text); }
:root[data-palette="konfetti"] .kpi .v { font-weight: 850; }
/* Listen-Symbole reihum in Bonbonfarben */
:root[data-palette="konfetti"] .li .ic { border: 2px solid var(--stick); border-radius: 50%; color: #2b1d3a; }
:root[data-palette="konfetti"] .li:nth-child(5n+1) .ic { background: var(--c2); }
:root[data-palette="konfetti"] .li:nth-child(5n+2) .ic { background: var(--c3); }
:root[data-palette="konfetti"] .li:nth-child(5n+3) .ic { background: var(--c4); }
:root[data-palette="konfetti"] .li:nth-child(5n+4) .ic { background: color-mix(in srgb, var(--c1) 70%, #fff); }
:root[data-palette="konfetti"] .li:nth-child(5n+5) .ic { background: color-mix(in srgb, var(--c5) 45%, #fff); }
:root[data-palette="konfetti"] .daysep { color: var(--c5); font-weight: 800; }
/* Karten wie Sammelkarten */
:root[data-palette="konfetti"] .ccard:not(.add) { border: 2px solid var(--stick); box-shadow: var(--shadow);
  background: linear-gradient(135deg, color-mix(in srgb, var(--c4) 30%, var(--surface)), color-mix(in srgb, var(--c2) 30%, var(--surface))); }
:root[data-palette="konfetti"] .ccard.add { border: 2px dashed var(--stick); }
/* Seitenleiste */
:root[data-palette="konfetti"] .side { border-right: 2px solid var(--stick); background: var(--surface); }
:root[data-palette="konfetti"] .nav a { border-radius: 999px; font-weight: 600; }
:root[data-palette="konfetti"] .nav a.on { background: var(--c2); color: #2b1d3a; box-shadow: 2px 2px 0 var(--stick); }
:root[data-palette="konfetti"] .nav a.on svg.i { color: #2b1d3a; }
:root[data-palette="konfetti"] .nav a:hover:not(.on) { background: color-mix(in srgb, var(--c3) 22%, transparent); }
:root[data-palette="konfetti"] .logo { transition: transform .3s cubic-bezier(.3, 1.6, .5, 1); }
:root[data-palette="konfetti"] .brandrow:hover .logo { transform: rotate(-10deg) scale(1.08); }
:root[data-palette="konfetti"] .av { border: 2px solid var(--stick); }
:root[data-palette="konfetti"] .bars .bar { border: 2px solid var(--stick); border-bottom: 0; border-radius: 8px 8px 0 0;
  background: linear-gradient(180deg, var(--c5), var(--c1)); }
:root[data-palette="konfetti"] .mtabs button { border: 2px solid var(--stick); }
:root[data-palette="konfetti"] .mtabs button.on { background: var(--c2); color: #2b1d3a; box-shadow: var(--shadow); }
:root[data-palette="konfetti"] .mtabs button.on .mt small { color: #55406b; }
:root[data-palette="konfetti"] dialog.modal { border: 2px solid var(--stick); box-shadow: var(--shadow-lg); border-radius: 24px; }
:root[data-palette="konfetti"] .toast { border: 2px solid var(--stick); border-radius: 999px; }
:root[data-palette="konfetti"] .login .logo { animation: cc-wiggle 3.5s ease-in-out infinite; }
@keyframes cc-wiggle { 0%, 86%, 100% { transform: rotate(0); } 90% { transform: rotate(-9deg); } 94% { transform: rotate(7deg); } }
@media (prefers-reduced-motion: reduce) {
  :root[data-palette="konfetti"] *, :root[data-palette="konfetti"] *::after { animation: none !important; transition: none !important; }
}

/* ===================== Darstellung (Auswahl-Dialog) ===================== */
.appear { display: grid; gap: 18px; }
.appear .grp > .lbl { font-size: 13px; font-weight: 600; color: var(--text-2); margin-bottom: 8px; }
.palettes { display: grid; grid-template-columns: repeat(auto-fit, minmax(118px, 1fr)); gap: 10px; }
.palettes button { flex-direction: column; align-items: stretch; gap: 8px; padding: 10px; text-align: left; white-space: normal; }
.palettes button.on, .modes button.on { border-color: var(--brand); box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 16%, transparent); }
.palettes .sw { display: flex; height: 38px; border-radius: 8px; overflow: hidden; border: 1px solid var(--line); }
.palettes .sw i { flex: 1; }
.palettes b { font-size: 14px; } .palettes small { color: var(--text-3); font-size: 12px; font-weight: 400; }
.modes { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.modes button { justify-content: center; padding-left: 6px; padding-right: 6px; gap: 5px; min-width: 0; }
@media (max-width: 420px) { .modes button svg.i { display: none; } }

/* ---------------- Ladestationen (ev.js) ---------------- */
.evcard { cursor: pointer; }
.evcard:hover { border-color: var(--line-strong); }
.evconn { display: flex; flex-wrap: wrap; gap: 8px 14px; }
.evconn > div { display: flex; align-items: center; gap: 6px; font-size: 13px; }
.evconn b { font-weight: 600; color: var(--text-2); }
.evlive { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px 12px;
          padding: 10px 12px; border-radius: var(--r-sm); background: var(--info-soft); color: var(--info); font-size: 13.5px; }
.evlive > div:first-child { display: flex; align-items: center; gap: 8px; min-width: 0; }
.evlive .muted { color: inherit; opacity: .75; }
.evlive.big { font-size: 15px; padding: 14px 16px; margin-bottom: 12px; }
.evlive svg.i { width: 18px; height: 18px; }
.evnew { display: flex; gap: 12px; align-items: flex-start; flex-wrap: wrap; background: var(--warn-soft); color: var(--warn); }
.evnew > div:nth-child(2) { flex: 1; min-width: 220px; }
.evnew .small { color: var(--text-2); margin-top: 2px; }
.evicon { width: 56px; height: 56px; border-radius: 16px; display: grid; place-items: center; background: var(--info-soft); color: var(--info); }
.evicon svg.i { width: 28px; height: 28px; }
.evtabs { align-self: start; }
.evurl { display: block; margin-top: 6px; padding: 8px 10px; border-radius: 8px; background: var(--surface-3); word-break: break-all; user-select: all; }
.evcfg td { vertical-align: top; }
.evval { word-break: break-all; max-width: 420px; }
.evres { margin: 0; padding: 12px; border-radius: var(--r-sm); background: var(--surface-3); font-size: 12.5px; overflow: auto; max-height: 320px; }
.evraw { display: grid; gap: 2px; font-size: 12px; max-height: 65vh; overflow: auto; }
.evraw > div { display: grid; grid-template-columns: 70px 18px minmax(0, 1fr); gap: 6px; padding: 3px 0; border-bottom: 1px solid var(--line); }
.evraw .t { color: var(--text-3); font-variant-numeric: tabular-nums; }
.evraw .in .d { color: var(--info); }
.evraw .out .d { color: var(--ok); }
.evraw code { font-family: var(--mono); white-space: pre-wrap; word-break: break-all; }

/* ---------------- Bestand und Vorräte (stock.js) ---------------- */
.stockn { display: inline-block; min-width: 40px; padding: 3px 10px; border-radius: 999px; text-align: center;
          font-weight: 700; font-variant-numeric: tabular-nums; background: var(--ok-soft); color: var(--ok); }
.stockn.warn { background: var(--warn-soft); color: var(--warn); }
.stockn.bad { background: var(--bad-soft); color: var(--bad); }
.lvl { position: relative; height: 30px; border-radius: 10px; background: var(--surface-3); overflow: hidden; }
.lvl i { position: absolute; inset: 0 auto 0 0; background: var(--ok); opacity: .22; transition: width .4s; }
.lvl.warn i { background: var(--warn); opacity: .28; }
.lvl.bad i { background: var(--bad); opacity: .3; }
.lvl span { position: relative; display: block; padding: 0 12px; line-height: 30px; font-size: 13.5px; font-weight: 650; }
.lvlpick { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: 8px; }
.lvlpick button { display: grid; gap: 2px; padding: 14px 10px; text-align: center; border-radius: var(--r-sm); }
.lvlpick button b { font-size: 16px; }
.lvlpick button small { font-size: 11.5px; color: var(--text-3); font-weight: 400; }
.sup .btns .primary { flex: 1; justify-content: center; }
.tbl.compact td, .tbl.compact th { padding: 7px 10px; }
.evgrid > * { min-width: 0; }
.evgrid > .stack { grid-template-columns: minmax(0, 1fr); }
.evgrid .panel { min-width: 0; }
.slimadd { padding: 0 4px; }
.stack.evpage { grid-template-columns: minmax(0, 1fr); }

/* ---------------- Einstellungen: Gruppen (admin.js, SETTING_GROUPS) ---------------- */
.setwrap { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 24px; align-items: start; max-width: 1100px; }
.setnav { display: grid; gap: 4px; position: sticky; top: 16px; }
.setnav a { display: flex; gap: 12px; align-items: flex-start; padding: 10px 12px; border-radius: var(--r-sm);
            color: var(--text-2); text-decoration: none; border: 1px solid transparent; }
.setnav a:hover { background: var(--surface-3); color: var(--text); }
.setnav a.on { background: var(--surface); border-color: var(--line); box-shadow: var(--shadow); color: var(--text); }
.setnav a svg.i { width: 18px; height: 18px; flex: none; margin-top: 1px; }
.setnav a.on svg.i { color: var(--brand); }
.setnav a span { display: grid; gap: 2px; min-width: 0; }
.setnav a b { font-size: 14px; font-weight: 600; }
.setnav a small { font-size: 12px; color: var(--text-3); line-height: 1.35; }
.setbody { min-width: 0; grid-template-columns: minmax(0, 1fr); max-width: 760px; }
.sethead h2 { display: flex; align-items: center; gap: 10px; font-size: 18px; margin: 4px 0 0; }
.sethead h2 svg.i { width: 20px; height: 20px; color: var(--text-3); }
.sethead p { margin: 4px 0 0; }
.setnote { margin: 0; padding: 0 4px; }
@media (max-width: 860px) {
  .setwrap { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .setnav { position: static; display: flex; gap: 6px; overflow-x: auto; padding-bottom: 4px; scrollbar-width: none; }
  .setnav::-webkit-scrollbar { display: none; }
  .setnav a { flex: none; align-items: center; padding: 8px 12px; border-color: var(--line); background: var(--surface); }
  .setnav a small { display: none; }
  .setnav a b { font-size: 13.5px; white-space: nowrap; }
  .sethead { display: none; }
}

/* ======================= Bankeinzug (sepa.js) ======================= */
.sepasteps { list-style: none; margin: 0 0 16px; padding: 0; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; }
.sepasteps li { display: flex; gap: 8px; align-items: flex-start; padding: 10px; border-radius: var(--r-sm); background: var(--surface-2);
  color: var(--text-3); font-size: 12.5px; line-height: 1.35; }
.sepasteps li b { display: block; color: var(--text-2); font-size: 13px; }
.sepasteps li small { display: block; }
.sepasteps .n { flex: none; width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; font-weight: 700;
  font-size: 12px; background: var(--surface-3); color: var(--text-2); }
.sepasteps .n svg.i { width: 13px; height: 13px; stroke-width: 2.6; }
.sepasteps li.done .n { background: var(--ok-soft); color: var(--ok); }
.sepasteps li.now { background: var(--info-soft); color: var(--info); }
.sepasteps li.now b { color: var(--info); }
.sepasteps li.now .n { background: var(--info); color: #fff; }
.sepado { margin: 0; padding: 0; list-style: none; counter-reset: sd; display: grid; gap: 10px; }
.sepado li { counter-increment: sd; display: flex; gap: 12px; align-items: center; justify-content: space-between; flex-wrap: wrap;
  padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--r-sm); font-size: 14px; }
.sepado li > span { flex: 1 1 320px; }
.sepado li > span::before { content: counter(sd) ". "; font-weight: 700; color: var(--text-3); }
.sepakpi { margin-bottom: 16px; }
.sepakpi .kpi { padding: 0; }
.sepakpi .kpi .v { font-size: 22px; }
.sepagrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 12px 20px; font-size: 14px; }
.sepagrid .k { font-size: 12px; color: var(--text-3); margin-bottom: 2px; }
.sepahist { margin-top: 14px; border-top: 1px solid var(--line); font-size: 13.5px; }
.sepahist > div { display: flex; justify-content: space-between; gap: 12px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.mandtext { font-size: 13px; line-height: 1.5; color: var(--text-2); background: var(--surface-2); border-radius: var(--r-sm); padding: 10px 14px; }
.mandtext p { margin: 6px 0; }
.sepatext { margin: 12px 0 4px; }
.sepaagree { display: flex; gap: 10px; align-items: flex-start; margin-top: 12px; font-size: 14px; cursor: pointer; }
.sepaagree input { width: 18px; height: 18px; margin: 1px 0 0; flex: none; accent-color: var(--ink); }
.sepablock { margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--line); }
.sepablock h3 { margin: 0 0 6px; font-size: 15px; display: flex; gap: 8px; align-items: center; }
h3.setsub { margin: 8px 0 -4px; font-size: 13px; text-transform: uppercase; letter-spacing: .04em; color: var(--text-3); font-weight: 650; }
.chip { display: inline-flex; gap: 6px; align-items: center; padding: 4px 10px; border-radius: 999px; background: var(--surface-2);
  border: 1px solid var(--line); font-size: 13px; color: var(--text); text-decoration: none; margin: 0 4px 6px 0; }
.chip:hover { background: var(--surface-3); }
@media (max-width: 860px) { .sepasteps { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .sepasteps { grid-template-columns: 1fr; } .sepasteps li small { display: none; } }
.sepagrid { margin-top: 14px; }
.callout + .sepagrid { margin-top: 16px; }
.tbl td.mono, .tbl small.mono { white-space: nowrap; }
