/* Restaurant-Terminal. Küche und Fahrer dunkel (blendet nicht, Karten springen ins Auge), Verwaltung hell. */

/* ---------- Anmeldung ---------- */
.login { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.login-box { width: min(400px, 100%); background: var(--paper); border-radius: var(--r-lg); padding: 32px 28px; box-shadow: var(--shadow); }
.login-box h1 { font-size: 26px; font-weight: 800; margin: 18px 0 20px; }
.login-brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; font-weight: 800; font-size: 18px; }
.logo-mark img { width: 24px; height: 24px; display: block; }
.logo-mark { width: 30px; height: 30px; border-radius: 9px; background: #fff; color: var(--lemon); display: grid; place-items: center; font-size: 16px; }
.login-box .btn.ghost { margin-top: 8px; }
.login-note { font-size: 14px; color: var(--muted); margin: 18px 0 0; text-align: center; }

/* ---------- Kopfleiste ---------- */
.app { min-height: 100vh; }
.bar { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: 16px; padding: 10px 16px; background: var(--paper); border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.bar-left { display: flex; align-items: center; gap: 12px; min-width: 0; }
.bar-name { font-size: 17px; font-weight: 800; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 220px; }
.conn { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--ok); font-weight: 600; }
.conn i { width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.conn.off { color: var(--danger); }
.tabs { display: flex; gap: 2px; flex: 1; overflow-x: auto; scrollbar-width: none; }
.tabs button { border: 0; background: none; padding: 9px 14px; border-radius: 999px; font-weight: 650; color: var(--muted); white-space: nowrap; display: inline-flex; align-items: center; gap: 6px; }
.tabs button.active { background: var(--ink); color: #fff; }
.count { background: var(--danger); color: #fff; border-radius: 999px; min-width: 22px; height: 22px; padding: 0 6px; display: inline-grid; place-items: center; font-size: 12px; }
.bar-right { display: flex; gap: 6px; }
.offline { background: var(--danger); color: #fff; font-weight: 700; padding: 12px 16px; text-align: center; }
.demo-note { background: var(--lemon-tint); color: var(--ink); padding: 8px 16px; font-size: 14px; text-align: center; }
.danger-text { color: var(--danger) !important; }
.grow { flex: 1; }

/* ---------- Dunkler Modus für Küche und Fahrer ---------- */
body.dark { background: #0d1612; }
body.dark .bar { background: #121d18; border-color: #22302a; color: #e9f1ec; }
body.dark .tabs button { color: #9fb2a8; }
body.dark .tabs button.active { background: #e9f1ec; color: #0d1612; }
body.dark .bar .btn { background: #1b2a23; border-color: #2c3d35; color: #e9f1ec; }
body.dark .bar .btn.lemon { background: var(--lemon); color: var(--ink); border-color: var(--lemon); }
body.dark .bar .btn.ghost { background: transparent; border-color: transparent; }
body.flash .bar { animation: flash 1.2s ease-out; }
@keyframes flash { 0%, 40% { background: var(--lemon); } }

.shift { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin: 14px 16px 0; padding: 16px 18px; border-radius: var(--r-md); background: #1b2a23; color: #e9f1ec; }
.shift div { display: grid; gap: 2px; }
.shift span { color: #9fb2a8; font-size: 14px; }

/* ---------- Küche ---------- */
.kitchen .cols { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; padding: 14px 16px 40px; align-items: start; }
.col h2 { color: #9fb2a8; font-size: 15px; font-weight: 700; letter-spacing: .01em; margin: 4px 4px 10px; display: flex; gap: 8px; }
.col h2 span { color: #e9f1ec; }
.col-list { display: grid; gap: 12px; }
.col-empty { color: #5f746a; font-size: 15px; padding: 18px 6px; margin: 0; }

.ticket-card { background: #fff; color: var(--ink); border-radius: var(--r-md); padding: 14px 16px 12px; border-left: 8px solid #c9d4ce; }
.ticket-card.is-new { border-left-color: var(--lemon); box-shadow: 0 0 0 3px rgba(243, 211, 74, .35); animation: pulse 2s ease-in-out infinite; }
.ticket-card.late { border-left-color: var(--danger); box-shadow: 0 0 0 3px rgba(200, 65, 43, .45); }
@keyframes pulse { 50% { box-shadow: 0 0 0 6px rgba(243, 211, 74, .15); } }
.ticket-card header { display: flex; align-items: center; gap: 10px; }
.ticket-card .no { font-size: 26px; font-weight: 850; letter-spacing: -.02em; }
.mode { font-size: 12px; font-weight: 800; letter-spacing: .04em; padding: 3px 8px; border-radius: 6px; background: var(--bg); }
.mode.delivery { background: #dfe9ff; color: #1f3f8f; }
.mode.pickup { background: var(--brand-tint); color: var(--brand); }
.age { margin-left: auto; font-size: 13px; color: var(--muted); }
.ticket-card .eta { margin: 4px 0 0; font-size: 15px; }
.ticket-card .eta b { background: var(--lemon); padding: 0 6px; border-radius: 4px; }
.lines { list-style: none; padding: 0; margin: 12px 0 6px; display: grid; gap: 8px; }
.lines li { display: grid; grid-template-columns: 36px 1fr; font-size: 19px; line-height: 1.25; }
.lines .q { font-weight: 850; }
.lines b { font-weight: 750; }
.opts { display: flex; flex-wrap: wrap; gap: 4px 6px; margin-top: 3px; font-size: 15px; color: var(--ink-2); }
.opts span:not(:last-child)::after { content: ','; }
.opts .mod { background: var(--danger); color: #fff; font-weight: 800; padding: 1px 7px; border-radius: 5px; }
.opts .mod::after { content: '' !important; }
.ticket-card .note { background: var(--lemon-tint); border-radius: 8px; padding: 7px 10px; margin: 8px 0 4px; font-weight: 650; font-size: 15px; }
.ticket-card .who { margin: 8px 0 0; font-size: 14px; color: var(--muted); }
.ticket-card .pay { margin: 2px 0 0; font-size: 15px; }
.paid { color: var(--ok); font-weight: 750; }
.actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; align-items: center; }
.actions .btn { padding: 12px 18px; font-size: 16px; }
.actions .btn.lemon { flex: 1; }
.eta-pick { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; width: 100%; }
.eta-pick .btn { padding: 12px 6px; font-size: 16px; border-color: var(--brand); color: var(--brand); }
.eta-pick .btn:hover { background: var(--brand); color: #fff; }
.print-row { display: flex; gap: 4px; flex-wrap: wrap; margin-top: 8px; border-top: 1px solid var(--line); padding-top: 6px; }

/* ---------- Fahrer ---------- */
.drv-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 14px; padding: 14px 16px 40px; }
.drv-card { background: #fff; border-radius: var(--r-md); padding: 16px; }
.drv-card header { display: flex; align-items: center; gap: 10px; }
.drv-card .no { font-size: 24px; font-weight: 850; }
.drv-card .eta { margin-left: auto; font-weight: 700; }
.drv-addr { font-size: 24px; font-weight: 800; line-height: 1.2; margin: 12px 0 6px; letter-spacing: -.01em; }
.drv-extra { margin: 0 0 4px; font-weight: 600; color: var(--ink-2); }
.drv-name { margin: 6px 0 0; color: var(--muted); }
.drv-pay { font-size: 19px; margin: 10px 0 0; }
.drv-pay b { background: var(--lemon); padding: 0 6px; border-radius: 5px; }
.drv-actions { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: 8px; margin-top: 14px; }
.drv-actions .btn { padding: 13px 10px; font-size: 16px; }

/* ---------- Verwaltungsseiten (hell) ---------- */
.page { max-width: 980px; margin: 0 auto; padding: 24px 16px 80px; }
.page-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 18px; }
.page-head h1 { font-size: 30px; font-weight: 850; }
.page-actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.page-actions input[type=date] { width: auto; }

.m-cat { background: var(--paper); border-radius: var(--r-md); padding: 16px; margin-bottom: 14px; box-shadow: var(--shadow); }
.m-cat-head { display: flex; gap: 6px; align-items: center; margin-bottom: 8px; flex-wrap: wrap; }
.m-cat-emoji { width: 52px !important; text-align: center; font-size: 22px !important; padding: 6px !important; }
.m-cat-name { flex: 1; min-width: 160px; font-size: 19px !important; font-weight: 800; border-color: transparent !important; padding-left: 4px !important; }
.m-cat-name:hover, .m-cat-name:focus { border-color: var(--line) !important; }
.m-items { list-style: none; padding: 0; margin: 0 0 12px; }
.m-items li { display: grid; grid-template-columns: minmax(0, 1fr) auto auto auto; gap: 12px; align-items: center; padding: 8px 0; border-top: 1px solid var(--line); }
.m-items li.off .m-item b { text-decoration: line-through; color: var(--muted); }
.m-item { border: 0; background: none; text-align: left; display: grid; gap: 2px; padding: 4px; border-radius: 6px; min-width: 0; }
.m-item:hover { background: var(--bg); }
.m-item .muted { font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.m-price { font-weight: 650; font-variant-numeric: tabular-nums; }
.m-move { display: flex; }
.switch { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600; cursor: pointer; white-space: nowrap; }
.switch input { width: 18px; height: 18px; accent-color: var(--brand); }

.edit-dlg { width: min(680px, calc(100vw - 16px)); }
.edit-dlg form { display: flex; flex-direction: column; max-height: calc(100vh - 32px); }
.dlg-body { padding: 22px; overflow-y: auto; }
.dlg-body h2 { font-size: 22px; font-weight: 800; margin-bottom: 14px; }
.dlg-body h3 { font-size: 17px; margin: 18px 0 4px; }
.dlg-foot { display: flex; gap: 8px; padding: 14px 22px; border-top: 1px solid var(--line); align-items: center; }
.ie-row { display: flex; gap: 10px; align-items: flex-end; }
.ie-row .field.small { width: 110px; flex: none; }
.ie-row .field.grow { flex: 1; }
.price-in { width: 110px !important; text-align: right; font-variant-numeric: tabular-nums; }
.ie-codes { border: 1.5px solid var(--line); border-radius: var(--r-sm); padding: 10px 12px; margin-bottom: 8px; }
.ie-codes summary { cursor: pointer; font-weight: 650; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 5px 10px; border: 1.5px solid var(--line); border-radius: 999px; font-size: 13px; cursor: pointer; }
.chip:has(input:checked) { border-color: var(--brand); background: var(--brand-tint); }
.chip input { accent-color: var(--brand); }
.ie-group { border: 1.5px solid var(--line); border-radius: var(--r-sm); padding: 12px; margin: 10px 0; }
.opt-row { margin-bottom: 6px; align-items: center; }
.opt-row input[type=text]:first-child { flex: 1; }
.ie-group-actions { display: flex; gap: 6px; margin-top: 6px; }
.reasons { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 14px; }

.settings .s-sec { background: var(--paper); border-radius: var(--r-md); padding: 20px; margin-bottom: 14px; box-shadow: var(--shadow); }
.s-sec h2 { font-size: 19px; font-weight: 800; margin-bottom: 12px; }
.s-sec .check { margin-bottom: 12px; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; }
.grid2.tight { grid-template-columns: 110px 1fr; gap: 0 10px; }
.field.narrow { max-width: 300px; }
.link-box { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.link-box code { background: var(--bg); padding: 9px 12px; border-radius: var(--r-sm); font-size: 14px; word-break: break-all; flex: 1; min-width: 200px; }
.hours-ed { display: grid; gap: 6px; }
.hrow { display: grid; grid-template-columns: 110px 1fr auto; gap: 10px; align-items: center; padding: 6px 0; border-top: 1px solid var(--line); }
.hday { font-weight: 650; }
.hivs { display: flex; flex-wrap: wrap; gap: 6px 14px; align-items: center; }
.hiv { display: inline-flex; align-items: center; gap: 4px; }
.hiv input { width: 110px; padding: 7px 8px; }
.zone { display: flex; gap: 10px; align-items: flex-end; flex-wrap: wrap; padding: 10px 0; border-top: 1px solid var(--line); }
.zone .field { margin-bottom: 0; }
.zone .field.grow { flex: 1; min-width: 200px; }
.stripe-box { border-top: 1px solid var(--line); padding-top: 14px; margin-top: 4px; }
.row-btns { display: flex; gap: 8px; flex-wrap: wrap; }

.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin-bottom: 18px; }
.kpis div { background: var(--paper); border-radius: var(--r-md); padding: 14px 16px; box-shadow: var(--shadow); display: grid; gap: 2px; }
.kpis span { font-size: 13px; color: var(--muted); font-weight: 600; }
.kpis strong { font-size: 22px; font-weight: 800; font-variant-numeric: tabular-nums; }
.kpis small { color: var(--muted); }
.table-wrap { overflow-x: auto; background: var(--paper); border-radius: var(--r-md); box-shadow: var(--shadow); }
.sales-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.sales-table th { text-align: left; font-weight: 600; color: var(--muted); padding: 10px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.sales-table td { padding: 10px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.sales-table .r { text-align: right; font-variant-numeric: tabular-nums; }
.sales-table tr.void td { color: var(--faint); text-decoration: line-through; }

@media (max-width: 1000px) {
  .kitchen .cols { grid-template-columns: 1fr; }
  .bar { gap: 8px; }
  .tabs { order: 3; flex: 1 0 100%; }
}
@media (max-width: 640px) {
  .grid2 { grid-template-columns: 1fr; }
  .m-items li { grid-template-columns: minmax(0, 1fr) auto; }
  .m-items .switch, .m-items .m-move { grid-column: span 1; }
  .hrow { grid-template-columns: 1fr auto; }
  .hivs { grid-column: 1 / -1; grid-row: 2; }
  .ie-row { flex-wrap: wrap; }
  .shift { flex-direction: column; align-items: stretch; }
  .bar-right .btn.ghost { display: none; }
}

/* ---------- Bons drucken ---------- */
#print-area { display: none; }
@media print {
  @page { margin: 3mm; }
  body * { visibility: hidden !important; }
  body { background: #fff !important; }
  #print-area, #print-area * { visibility: visible !important; }
  #print-area { display: block; position: absolute; left: 0; top: 0; width: 100%; }
  .print-ticket { break-after: page; page-break-after: always; }
  .print-ticket:last-child { break-after: auto; page-break-after: auto; }
  .print-ticket pre { margin: 0; font: 700 10.5pt/1.35 ui-monospace, 'Courier New', monospace; color: #000; white-space: pre-wrap; }
}

/* Gutschein auf Bestellungen */
.ticket-card .voucher { margin: 10px 0 0; padding: 8px 12px; border-radius: 10px; background: #ffc83d; color: #1b2233; font-weight: 850; font-size: 16px; }
.src-pill { display: inline-block; padding: 2px 8px; border-radius: 999px; background: #fff3c4; color: #6b5200; font-size: 12px; font-weight: 700; }

/* Gutscheinkarten */
.cards-intro { max-width: 760px; color: var(--muted); margin: 0 0 16px; line-height: 1.5; }
.cards-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: 18px; align-items: start; }
.cards-preview { position: sticky; top: 120px; }
.cards-preview h2 { font-size: 19px; font-weight: 800; margin-bottom: 12px; }
.cards-preview h2.mt { margin-top: 28px; }
#c-canvas { width: 100%; max-width: 520px; height: auto; display: block; border-radius: 12px; box-shadow: 0 14px 30px rgba(20, 30, 50, .18), 0 2px 6px rgba(20, 30, 50, .1); background: #fff; }
.logo-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.c-orders { display: grid; gap: 8px; }
.c-order { display: flex; justify-content: space-between; gap: 10px; padding: 12px 14px; background: var(--paper); border-radius: var(--r-md); box-shadow: var(--shadow); font-size: 14px; }
.c-order small { color: var(--muted); display: block; }
@media (max-width: 820px) { .cards-grid { grid-template-columns: 1fr; } .cards-preview { position: static; order: -1; } }

/* Fahrer-Übersicht */
.drv-team { padding: 16px 16px 0; }
.drv-team h2 { font-size: 15px; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; color: rgba(255,255,255,.6); margin: 0 0 10px; }
.team-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 10px; }
.team-card { background: #1f2a24; color: #fff; border-radius: var(--r-md); padding: 14px 16px; border-left: 6px solid #6b7a72; display: grid; gap: 8px; align-content: start; }
.team-card.out { border-left-color: #4da3ff; }
.team-card.return { border-left-color: #f5c84b; background: #2c2a1b; }
.team-card.home { border-left-color: #3bb273; }
.team-top { display: flex; align-items: center; gap: 12px; }
.team-ic { font-size: 28px; }
.team-top b { display: block; font-size: 19px; }
.team-st { font-size: 14px; font-weight: 700; opacity: .85; }
.team-card.return .team-st { color: #f5c84b; opacity: 1; }
.team-card.out .team-st { color: #8cc4ff; opacity: 1; }
.team-detail { margin: 0; font-size: 14px; line-height: 1.45; opacity: .85; }
.team-card .btn { justify-self: start; }
.team-empty { margin: 0; color: rgba(255,255,255,.6); font-size: 14px; }
.drv-me { padding: 14px 16px 0; color: rgba(255,255,255,.85); }
.me-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; font-size: 15px; }
.me-row input { width: 180px; }
.me-row .btn.ghost { color: rgba(255,255,255,.8); }
.big-back { margin-top: 12px; padding: 18px; font-size: 19px; }
.drv-voucher { margin: 8px 0 0; font-weight: 800; color: #6b5200; background: #fff3c4; padding: 6px 10px; border-radius: 8px; }

/* Rollen: Chef / Küche / Fahrer */
.demo-roles { display: inline-flex; gap: 4px; margin-left: 10px; align-items: center; }
.demo-roles button { border: 1px solid currentColor; background: none; border-radius: 999px; padding: 2px 10px; font: inherit; font-weight: 700; cursor: pointer; }
.demo-roles button.on { background: #1b2233; color: #fff; border-color: #1b2233; }
.role-badge { font-size: 13px; font-weight: 700; padding: 3px 10px; border-radius: 999px; background: rgba(255,255,255,.12); }
body:not(.dark) .role-badge { background: #eef1ee; }
.team-list { display: grid; gap: 8px; margin: 10px 0 12px; }
.team-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 10px 12px; border-radius: 12px; background: #f5f6f4; }
.team-row b { font-size: 16px; }
.team-row .grow { flex: 1; min-width: 140px; }
.team-row small { color: var(--muted); display: block; }
.invite { display: grid; gap: 12px; justify-items: center; text-align: center; max-width: 420px; }
.invite canvas { width: 220px; height: 220px; background: #fff; border-radius: 12px; }
.invite code { word-break: break-all; font-size: 13px; }
.drv-hello { padding: 16px 16px 0; color: #fff; }
.drv-hello h1 { font-size: 26px; font-weight: 850; margin: 0; }
.drv-hello p { margin: 4px 0 0; color: rgba(255,255,255,.7); }
.big-back { font-size: 19px; padding: 18px; margin-top: 12px; }
.ticket-card .wait { margin: 0; font-weight: 700; color: var(--muted); align-self: center; }
.invite { margin: 0 auto; }
@media (max-width: 1400px) { .tabs button { padding: 9px 11px; } }

/* Speichern-Leiste unten in den Einstellungen */
.save-bar { position: sticky; bottom: 0; z-index: 15; display: flex; align-items: center; justify-content: flex-end; gap: 14px; margin: 10px -16px -80px; padding: 12px 16px calc(12px + env(safe-area-inset-bottom)); background: rgba(255,255,255,.94); backdrop-filter: blur(8px); border-top: 1px solid var(--line); }
.save-bar span { font-weight: 700; color: var(--muted); }
.save-bar.dirty span { color: #b45309; }
.save-bar.dirty .btn { box-shadow: 0 0 0 4px rgba(245, 200, 75, .45); }

@media (min-width: 701px) and (max-width: 1100px) { .kitchen .cols { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.col-way h2 { color: #8cc4ff; }

/* Fahrer-Kasse */
.drv-cash { padding: 0 16px 60px; }
.drv-cash h2 { font-size: 15px; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; color: rgba(255,255,255,.6); margin: 8px 0 10px; }
.cash-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 14px; }
.cash-card { background: #fff; color: var(--ink); border-radius: var(--r-md); padding: 16px; display: grid; gap: 12px; max-width: 560px; }
.cash-card header { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.cash-card header b { font-size: 20px; font-weight: 850; }
.cash-card header span { color: var(--muted); font-size: 14px; font-weight: 600; }
.cash-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.cash-list li { display: flex; justify-content: space-between; gap: 10px; font-size: 15px; padding: 6px 0; border-bottom: 1px solid var(--line); }
.cash-list small { display: block; color: var(--muted); font-size: 12px; }
.cash-list .r { white-space: nowrap; text-align: right; }
.cash-empty { margin: 0; color: var(--muted); }
.cash-rows { display: grid; gap: 8px; }
.cash-rows > div { display: flex; justify-content: space-between; align-items: center; gap: 10px; font-size: 16px; }
.cash-rows b { font-variant-numeric: tabular-nums; }
.cash-rows .cash-total { padding-top: 10px; border-top: 2px solid var(--ink); font-size: 18px; font-weight: 700; }
.cash-total b { font-size: 24px; background: var(--lemon); padding: 0 8px; border-radius: 6px; }
.cash-note { margin: 0; font-size: 13px; color: var(--muted); }
.float-ed { display: inline-flex; align-items: center; gap: 6px; }
.float-ed input, .pocket input { width: 96px; text-align: right; padding: 8px 10px; }
.pocket summary { cursor: pointer; font-weight: 700; }
.pocket label { display: flex; align-items: center; gap: 8px; margin-top: 10px; flex-wrap: wrap; }
.pocket .tip { margin: 8px 0 0; color: #1e9a62; font-size: 17px; }
.pocket .miss { margin: 8px 0 0; color: #c0392b; font-size: 17px; }

/* Abgeschlossene Bestellungen (aufklappbar) */
.done-sec { margin: 0 16px 60px; background: #18221d; border-radius: var(--r-md); color: #e9f1ec; }
.done-sec > summary { cursor: pointer; list-style: none; display: flex; align-items: center; gap: 10px; padding: 16px 18px; font-size: 17px; font-weight: 800; }
.done-sec > summary::-webkit-details-marker { display: none; }
.done-sec > summary::before { content: "▸"; transition: transform .2s; color: #9fb2a8; }
.done-sec[open] > summary::before { transform: rotate(90deg); }
.done-sec > summary b { color: #9fb2a8; font-weight: 700; font-size: 15px; }
.done-sum { margin-left: auto; color: #9fb2a8; font-weight: 700; font-size: 15px; }
.done-list { display: grid; gap: 6px; padding: 0 12px 14px; }
.done-row { background: #fff; color: var(--ink); border-radius: 12px; }
.done-row.void { opacity: .6; }
.done-row > summary { cursor: pointer; list-style: none; display: grid; grid-template-columns: 52px 54px 90px 1fr auto auto; gap: 10px; align-items: center; padding: 10px 14px; font-size: 15px; }
.done-row > summary::-webkit-details-marker { display: none; }
.done-row .no { font-weight: 850; }
.done-row .when { color: var(--muted); font-variant-numeric: tabular-nums; }
.done-row .who { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.done-row .amt { font-weight: 800; white-space: nowrap; text-align: right; }
.done-row .amt small { color: var(--muted); font-weight: 600; }
.done-row .st { white-space: nowrap; color: var(--muted); font-weight: 600; }
.done-body { padding: 0 14px 12px; border-top: 1px solid var(--line); }
.done-body .lines { margin-top: 10px; }
@media (max-width: 700px) {
  .done-row > summary { grid-template-columns: 44px 48px 1fr auto; }
  .done-row .mode, .done-row .st { display: none; }
}
.done-sec > summary { flex-wrap: wrap; }
@media (max-width: 700px) { .done-sec > summary b { font-size: 13px; } }

.ticket-card .voucher.stampv, .done-body .voucher.stampv { background: #1e9a62; color: #fff; }
.drv-voucher { margin: 8px 0 0; font-weight: 800; color: #1e9a62; }

/* Stammgäste */
.g-sec { background: var(--paper); border-radius: var(--r-md); padding: 18px; box-shadow: var(--shadow); margin-bottom: 14px; }
.g-sec h2 { font-size: 17px; font-weight: 800; margin: 0 0 10px; }
.g-sec h2.mt { margin-top: 22px; }
.g-chart { width: 100%; height: auto; display: block; }
.g-legend { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--muted); margin: 0 0 8px; }
.g-legend i { width: 12px; height: 12px; border-radius: 3px; display: inline-block; margin-left: 6px; }
.g-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 14px; align-items: start; }
.g-top { list-style: none; padding: 0; margin: 0; display: grid; gap: 4px; }
.g-top li { display: grid; grid-template-columns: 28px 1fr auto auto auto; gap: 10px; align-items: center; padding: 8px 4px; border-bottom: 1px solid var(--line); }
.g-top small { display: block; color: var(--muted); font-size: 12px; }
.g-rank { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-size: 13px; background: #f3f3f2; }
.g-top li:nth-child(-n+3) .g-rank { background: #ffc83d; }
.g-n { font-weight: 800; }
.g-sum { color: var(--muted); font-variant-numeric: tabular-nums; }
.g-dots { display: inline-flex; gap: 3px; }
.g-dots i { width: 10px; height: 10px; border-radius: 50%; background: #e6e6e3; }
.g-dots i.on { background: #ffc83d; }
.g-big { font-size: 34px; font-weight: 850; margin: 0; }
.g-sleep { padding-left: 18px; margin: 10px 0 0; font-size: 14px; }
@media (max-width: 820px) { .g-grid { grid-template-columns: 1fr; } .g-top li { grid-template-columns: 26px 1fr auto auto; } .g-top .g-dots { display: none; } }

/* Einstellungen: aufklappbare Reiter */
.settings details.s-sec { padding: 0; overflow: hidden; }
.settings details.s-sec > summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: 14px; padding: 16px 18px; }
.settings details.s-sec > summary::-webkit-details-marker { display: none; }
.settings details.s-sec > summary::after { content: "›"; margin-left: auto; font-size: 26px; line-height: 1; color: var(--muted); transition: transform .2s; }
.settings details.s-sec[open] > summary::after { transform: rotate(90deg); }
.settings details.s-sec > summary:hover { background: rgba(0, 0, 0, .025); }
.s-ic { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; font-size: 21px; background: #f3f3f2; flex: none; }
.s-head { display: grid; gap: 1px; }
.s-head b { font-size: 17px; font-weight: 800; }
.s-head small { color: var(--muted); font-size: 13px; }
.s-body { padding: 4px 20px 20px; border-top: 1px solid var(--line); }
.s-body > .check:first-child, .s-body > p:first-child { margin-top: 14px; }

/* ---------- Demo: „Jetzt starten“ und Beispiel-Gutscheinkarte ---------- */
.start-dlg { width: min(460px, calc(100vw - 16px)); }
.start-dlg .dlg-body { text-align: left; }
.start-badge { display: grid; place-items: center; width: 56px; height: 56px; border-radius: 18px; background: var(--lemon-tint, #fff6d6); font-size: 30px; margin-bottom: 10px; }
.start-dlg h2 { font-size: 26px; font-weight: 900; margin: 0 0 6px; }
.start-ticks { list-style: none; padding: 0; margin: 12px 0 16px; display: flex; flex-wrap: wrap; gap: 6px; }
.start-ticks li { font-weight: 800; font-size: 13px; padding: 6px 10px; border-radius: 999px; background: #e3f6ec; color: #1e7a4f; }
.start-ticks li::before { content: '✓ '; }
.start-dlg .check { display: flex; gap: 10px; align-items: flex-start; font-weight: 600; margin-top: 4px; }
.start-dlg .check input { width: 20px; height: 20px; flex: none; margin-top: 2px; }

.cd-demo { display: grid; grid-template-columns: minmax(280px, 1.05fr) 1fr; gap: 22px; align-items: center; }
.cd-card { display: grid; gap: 8px; justify-items: center; }
.cd-card canvas { width: 100%; max-width: 460px; height: auto; border-radius: 14px; box-shadow: 0 16px 40px rgba(20, 30, 50, .18); transform: rotate(-2deg); background: #fff; }
.cd-card small { color: var(--ink-2, #5a6070); font-weight: 600; }
.cd-tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.cd-tile { display: grid; gap: 2px; padding: 14px; border-radius: 16px; background: #fff; box-shadow: 0 4px 14px rgba(20, 30, 50, .07); }
.cd-tile span { font-size: 26px; line-height: 1; margin-bottom: 4px; }
.cd-tile b { font-size: 15px; font-weight: 850; line-height: 1.2; }
.cd-tile small { color: var(--ink-2, #5a6070); font-weight: 600; font-size: 13px; }
.cd-tile.hot { background: #1d3461; color: #fff; }
.cd-tile.hot small { color: #ffd76a; }
.big-cta { grid-column: 1 / -1; justify-self: center; padding: 16px 34px; font-size: 18px; }
@media (max-width: 760px) { .cd-demo { grid-template-columns: 1fr; } }

/* ---------- Fahrer-Übersicht für den Chef: Spalte je Fahrer ---------- */
#tab-driver .drv-team { padding: 22px clamp(16px, 3vw, 36px) 20px; max-width: 1500px; margin: 0 auto; }
.dq { margin-bottom: 26px; }
.dq-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 12px; }
.dq-item { display: grid; gap: 8px; background: #fff; border-radius: 16px; padding: 12px 14px; border-left: 6px solid #c9d4ce; }
.dq-item.ready { border-left-color: #f5c84b; }
.dq-item .pill { justify-self: start; }
.dq-item .mo { padding: 0; border: 0; background: none; }
.dq-empty { margin: 0; color: rgba(255,255,255,.6); }
.dc-title { margin-top: 4px !important; }
.dcols { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 18px; align-items: start; }
.dcol { background: #18221d; border-radius: 22px; padding: 16px; display: grid; gap: 14px; border-top: 6px solid #6b7a72; }
.dcol.out { border-top-color: #4da3ff; }
.dcol.return { border-top-color: #f5c84b; }
.dcol.home { border-top-color: #3bb273; }
.dc-head { display: flex; align-items: center; gap: 12px; color: #fff; }
.dc-av { width: 46px; height: 46px; flex: none; border-radius: 50%; display: grid; place-items: center; font-weight: 900; font-size: 20px; background: rgba(255,255,255,.12); }
.dcol.out .dc-av { background: #4da3ff; color: #0d2440; }
.dcol.return .dc-av { background: #f5c84b; color: #3a2c00; }
.dcol.home .dc-av { background: #3bb273; color: #082a17; }
.dc-head b { display: block; font-size: 20px; line-height: 1.1; }
.dc-st { display: block; font-size: 14px; font-weight: 800; margin-top: 2px; }
.dcol.out .dc-st { color: #8cc4ff; }
.dcol.return .dc-st { color: #f5c84b; }
.dcol.home .dc-st { color: #7fd6a4; }
.dc-head small { display: block; color: rgba(255,255,255,.55); font-size: 13px; font-weight: 600; }
.dc-body { display: grid; gap: 8px; }
.dc-h { margin: 0; font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; color: rgba(255,255,255,.55); }
.dc-ph { border: 2px dashed rgba(255,255,255,.18); border-radius: 14px; padding: 16px 12px; text-align: center; color: rgba(255,255,255,.6); font-weight: 600; font-size: 14px; line-height: 1.5; }
.dc-body .btn.small { justify-self: start; }
.dc-assign { display: flex; justify-content: space-between; align-items: center; gap: 10px; width: 100%; text-align: left; border: 2px solid #f5c84b; background: rgba(245, 200, 75, .1); color: #fff; border-radius: 14px; padding: 12px 14px; font: inherit; font-weight: 700; cursor: pointer; }
.dc-assign b { color: #f5c84b; white-space: nowrap; }
.dc-assign:hover { background: rgba(245, 200, 75, .22); }
.mo { background: #fff; color: var(--ink); border-radius: 14px; padding: 10px 12px; display: grid; gap: 4px; min-width: 0; }
.dq-item > *, .dcol > *, .dc-body > * { min-width: 0; }
.mo-top { display: flex; align-items: baseline; gap: 8px; }
.mo-top b { font-size: 17px; }
.mo-top span:not(.mo-pay) { flex: 1; font-weight: 700; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mo-pay { white-space: nowrap; font-size: 14px; }
.mo-paid { color: #1e9a62; font-weight: 800; }
.mo-sub { display: flex; justify-content: space-between; align-items: center; gap: 8px; color: var(--muted); font-size: 13px; font-weight: 600; }
.mo-note { font-size: 13px; font-weight: 800; color: #6b5200; background: #fff3c4; border-radius: 8px; padding: 4px 8px; }
.cash-card.mini { max-width: none; padding: 14px; gap: 10px; border-radius: 16px; }
.cash-card.mini h3 { margin: 0; font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.cash-card.mini .cash-rows > div { font-size: 15px; }
.cash-card.mini .cash-total b { font-size: 20px; }
.cash-more summary, .cash-card.mini .pocket summary { cursor: pointer; font-weight: 700; font-size: 14px; color: var(--ink-2, #4a5250); }
.cash-more .cash-list { margin-top: 6px; }
/* schmale Spalten: nichts darf überstehen */
.dcol, .dc-body, .mo, .cash-card.mini, .dq-item { grid-template-columns: minmax(0, 1fr); }
.dcol { padding: 14px 12px; }
.cash-card.mini { padding: 12px; }
.cash-card.mini .float-ed input { width: 64px; padding: 7px 8px; }
.cash-card.mini .float-ed .btn { padding: 6px 10px; }
.cash-card.mini .cash-rows > div > span:first-child { min-width: 0; }
.mo-sub span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mo-sub .btn { flex: none; }
.dq-n { display: inline-block; min-width: 22px; padding: 0 6px; border-radius: 999px; background: rgba(255,255,255,.14); color: #fff; text-align: center; margin-left: 4px; }
#tab-driver .drv-cash { padding: 0 clamp(16px, 3vw, 36px) 60px; max-width: 1500px; margin: 0 auto; }
