/* Werkstatt-Tetris – neue, helle Oberfläche (ab Build 105). Bewusst schlicht. */
:root {
  --bg: #f5f6f8;
  --card: #ffffff;
  --line: #e6e8ec;
  --line2: #eef0f3;
  --text: #1f2937;
  --muted: #6b7280;
  --faint: #9ca3af;
  --accent: #2563eb;
  --accent-soft: #eaf1fe;
  --busy: #dfe6f0;
  --busy-text: #334155;
  --ok: #16a34a;
  --ok-soft: #dcfce7;
  --warn: #d97706;
  --off: repeating-linear-gradient(135deg, #f1f2f4 0 5px, #e9ebee 5px 10px);
  --radius: 10px;
  font-size: 14px;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  background: var(--bg); color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}
button, input, select, textarea { font: inherit; color: inherit; }
.muted { color: var(--muted); }

/* ---------- Kopf ---------- */
.top {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; gap: 16px;
  padding: 10px 20px; background: var(--card); border-bottom: 1px solid var(--line);
}
.brand { display: flex; align-items: center; gap: 10px; min-width: 220px; }
.logo { width: 22px; height: 22px; border-radius: 6px; background: var(--accent); }
.b1 { font-weight: 600; letter-spacing: -.01em; }
.b2 { font-size: 12px; color: var(--muted); }
.day { flex: 1; display: flex; align-items: center; justify-content: center; gap: 6px; position: relative; }
.dlabel {
  border: 0; background: none; cursor: pointer; font-size: 17px; font-weight: 600;
  padding: 6px 12px; border-radius: 8px; min-width: 260px;
}
.dlabel:hover { background: var(--bg); }
.heute { font-size: 11px; font-weight: 600; color: var(--accent); background: var(--accent-soft);
  padding: 2px 7px; border-radius: 99px; margin-left: 8px; vertical-align: 2px; }
.dpick { position: absolute; opacity: 0; pointer-events: none; width: 1px; height: 1px; left: 50%; top: 100%; }
.right { display: flex; align-items: center; gap: 8px; min-width: 220px; justify-content: flex-end; }

.primary, .ghost, .icon {
  border-radius: 8px; cursor: pointer; text-decoration: none; white-space: nowrap;
  padding: 7px 14px; border: 1px solid var(--line); background: var(--card); font-size: 13px;
}
.primary { background: var(--accent); border-color: var(--accent); color: #fff; font-weight: 600; }
.primary:hover { filter: brightness(1.06); }
.primary:disabled { opacity: .5; cursor: default; }
.ghost:hover, .icon:hover { background: var(--bg); }
.icon { padding: 5px 10px; font-size: 16px; line-height: 1; }

/* ---------- Startseite ---------- */
.start { max-width: 1280px; margin: 0 auto; padding: 16px 20px 32px; }
.panel { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); }
.abwbar { font-size: 13px; color: var(--muted); padding: 0 4px 10px; }
.abwbar:empty { display: none; }
.abwbar b { color: var(--text); font-weight: 600; }
.abwbar .p { display: inline-block; margin-right: 12px; }
.phead { display: flex; align-items: baseline; gap: 10px; padding: 14px 16px 10px; flex-wrap: wrap; }
.phead h2 { font-size: 15px; margin: 0; font-weight: 600; }
.count { color: var(--muted); font-size: 13px; }
.sum { color: var(--faint); font-size: 12px; }
.sbfilter { margin-left: auto; display: flex; gap: 4px; flex-wrap: wrap; }
.sbf { border: 1px solid transparent; background: none; border-radius: 99px; padding: 3px 9px; font-size: 12px;
  cursor: pointer; color: var(--muted); display: inline-flex; align-items: center; gap: 5px; }
.sbf:hover { background: var(--bg); }
.sbf.on { border-color: var(--line); background: var(--card); color: var(--text); }
.dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; flex: none; }

.tt { width: 100%; border-collapse: collapse; font-size: 13px; }
.tt th { text-align: left; font-weight: 500; font-size: 11px; color: var(--faint); text-transform: uppercase;
  letter-spacing: .04em; padding: 6px 10px; border-bottom: 1px solid var(--line); }
.tt td { padding: 8px 10px; border-bottom: 1px solid var(--line2); vertical-align: middle; }
.tt tr:last-child td { border-bottom: 0; }
.tt tbody tr:hover td { background: #fafbfc; }
.tt tr.dim td { opacity: .35; }
.tt .c-z { width: 64px; font-variant-numeric: tabular-nums; font-weight: 600; white-space: nowrap; }
.tt .c-z.gt { font-weight: 400; color: var(--faint); font-size: 12px; }
.tt .c-sb { width: 18px; padding-left: 0; padding-right: 0; }
.tt .kz { font-weight: 600; white-space: nowrap; }
.tt .arb { color: var(--muted); max-width: 380px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tt .grp, .tt .mech { color: var(--muted); white-space: nowrap; }
.tt .c-st { width: 1%; white-space: nowrap; text-align: right; }
.tag { font-size: 11px; padding: 1px 7px; border-radius: 99px; background: var(--bg); color: var(--muted); margin-left: 4px; }
.tag.w { background: #fef3c7; color: #92400e; }
.tag.ok { background: var(--ok-soft); color: #166534; }
.empty { padding: 28px 16px; color: var(--faint); text-align: center; }
.ueber { border-top: 1px solid var(--line); }
.ueber summary { padding: 10px 16px; cursor: pointer; color: var(--muted); font-size: 13px; }

/* ---------- Tooltip ---------- */
.tip {
  position: fixed; z-index: 1000; pointer-events: none; display: none; max-width: 300px;
  background: #111827; color: #f9fafb; font-size: 12px; line-height: 1.45;
  padding: 7px 10px; border-radius: 7px; box-shadow: 0 6px 20px rgba(0,0,0,.18);
}

/* ---------- Terminfenster ---------- */
dialog {
  border: 0; padding: 0; border-radius: 14px; width: min(1240px, calc(100vw - 24px));
  max-height: calc(100vh - 24px); overflow: auto; box-shadow: 0 24px 60px rgba(15,23,42,.25);
}
dialog::backdrop { background: rgba(15,23,42,.28); }
.dhead { display: flex; align-items: center; justify-content: space-between; padding: 14px 20px 4px; }
.dhead h3 { margin: 0; font-size: 16px; }
.dcols { display: grid; grid-template-columns: 420px 1fr; }
.dleft { border-right: 1px solid var(--line2); }
.dright { min-width: 0; }
.dsec { padding: 4px 0 12px; border-top: 1px solid var(--line2); }
.dleft .dsec:first-child, .dright .dsec:first-child { border-top: 0; }
.sbsec { padding-bottom: 8px; }
.job { padding: 4px 10px !important; font-size: 12.5px !important; }
.dsec-t { padding: 8px 20px 6px; font-size: 11px; color: var(--faint); text-transform: uppercase; letter-spacing: .05em; }
.dgrid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px 10px; padding: 4px 20px; }
.dgrid label { display: flex; flex-direction: column; gap: 4px; font-size: 12px; color: var(--muted); min-width: 0; }
.dgrid .w2 { grid-column: span 2; }
.dgrid .w3 { grid-column: span 3; }
.dgrid input, .dgrid select, .dgrid textarea, .vgrp select {
  border: 1px solid var(--line); border-radius: 8px; padding: 7px 9px; background: #fff; color: var(--text); font-size: 14px; min-width: 0;
}
.dgrid input:focus, .dgrid select:focus, .vgrp select:focus { outline: 2px solid var(--accent-soft); border-color: var(--accent); }
.chk { display: flex; align-items: center; gap: 6px; height: 36px; color: var(--text); font-size: 14px; }
.dcheck { margin: 6px 20px 0; font-size: 13px; min-height: 18px; }
.dcheck .ok { color: var(--ok); }
.dcheck .no { color: var(--warn); }
.dfoot { display: flex; align-items: center; gap: 8px; justify-content: flex-end; padding: 12px 20px 16px; border-top: 1px solid var(--line); }
.dfoot .err { margin-right: auto; color: #dc2626; font-size: 13px; }

/* ---------- Tagesraster: 3/4 Bringen, 1/4 Abholen ---------- */
.start { max-width: 1600px; }
.tagraster { display: grid; grid-template-columns: minmax(0, 3fr) minmax(260px, 1fr); gap: 16px; align-items: start; }
@media (max-width: 1150px) { .tagraster { grid-template-columns: 1fr; } }
.tt .c-au { white-space: nowrap; font-variant-numeric: tabular-nums; color: var(--text); }
.tt .c-au.vage { color: var(--faint); }
.alist { padding: 0 0 6px; }
.ai { display: grid; grid-template-columns: 52px 1fr auto; gap: 2px 10px; padding: 8px 14px; border-top: 1px solid var(--line2); cursor: pointer; }
.ai:first-child { border-top: 0; }
.ai:hover { background: #fafbfc; }
.ai .z { font-weight: 600; font-variant-numeric: tabular-nums; grid-row: span 2; }
.ai .k { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ai .k small { font-weight: 400; color: var(--muted); }
.ai .u { color: var(--muted); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; grid-column: 2 / 4; }
.ai .s { text-align: right; }
.ai.weg { opacity: .45; }
.ai .vt { display: inline-block; font-size: 11px; color: #7c3aed; background: #f3e8ff; border-radius: 99px; padding: 0 7px; margin-left: 4px; }
.ai .fs { grid-column: 2 / 4; display: flex; flex-wrap: wrap; align-items: center; gap: 2px 8px; margin-top: 3px; font-size: 11.5px; }
.ai .fs.leer { color: var(--faint); font-size: 11.5px; grid-column: 2 / 4; }
.ai .fsb { flex: 1 0 100%; height: 5px; border-radius: 99px; background: var(--line2); overflow: hidden; }
.ai .fsb span { display: block; height: 100%; background: #34d399; border-radius: 99px; }
.ai .fsb span.ueber { background: #f87171; }
.ai .fsz { color: var(--muted); font-variant-numeric: tabular-nums; }
.ai .fsz.ueber { color: #dc2626; font-weight: 600; }
.ai .fst { color: var(--muted); }
.ai .fst.ok { color: #15803d; }
.ai .fst.rot { color: #dc2626; font-weight: 600; }
.ai .fst.grau { color: var(--faint); }
.ai .live { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: #22c55e; margin-right: 5px; animation: puls 1.4s infinite; vertical-align: 0; }
@keyframes puls { 0%,100% { opacity: 1; } 50% { opacity: .35; } }
.alist .empty { padding: 14px; color: var(--faint); }

.nm.klickbar { cursor: pointer; }
.nm.klickbar:hover { text-decoration: underline; text-underline-offset: 3px; }

/* ---------- gemeinsames Zeitraster Bringen | Abholen ---------- */
.tagraster { grid-template-columns: 1fr !important; }
.h2sub { font-weight: 400; color: var(--muted); }
.tt th.c-ab, .tt td.c-ab { width: 25%; min-width: 250px; border-left: 1px solid var(--line); vertical-align: top; padding: 0; background: #fcfcfd; }
.tt th.c-ab { padding: 8px 10px; }
.tt tr.hkopf td { background: var(--bg); padding: 5px 10px; font-size: 12px; border-bottom: 1px solid var(--line); }
.tt tr.hkopf td b { font-variant-numeric: tabular-nums; }
.tt tr.hkopf .hanz { color: var(--muted); margin-left: 6px; }
.tt tr.hkopf td.hk { background: var(--bg); }
.tt tr.hleer td.leer { color: var(--faint); font-size: 12px; padding: 4px 10px; }
.tt tr.hleer td { height: 30px; }
.tt tbody tr:hover td.c-ab { background: #fcfcfd; }
.tt td.c-ab .ai { padding: 7px 10px; }
.tt td.c-ab .ai:first-child { border-top: 0; }

/* ---------- Termindetails (nur lesen) ---------- */
dialog.det { width: min(760px, calc(100vw - 24px)); }
.det-body { padding: 4px 20px 18px; }
.det-sub { color: var(--muted); margin: -2px 0 10px; }
.det-marken { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 12px; }
.det-marken .tag { margin-left: 0; font-size: 12px; padding: 2px 9px; }
.det-sec { border-top: 1px solid var(--line2); padding: 10px 0 6px; }
.det-sec h4 { margin: 0 0 6px; font-size: 11px; color: var(--faint); text-transform: uppercase; letter-spacing: .05em; font-weight: 600; }
.det-z { display: grid; grid-template-columns: 150px 1fr; gap: 10px; padding: 3px 0; font-size: 14px; }
.det-z > span:first-child { color: var(--muted); }
.det-a { padding: 3px 0; }
.det-txt { white-space: pre-wrap; background: var(--bg); border-radius: 8px; padding: 8px 10px; font-size: 13px; }
.det-warn { color: var(--warn); }
tbody tr { cursor: pointer; }

/* Suche */
.srch { position: relative; margin: 0 20px 6px; }
.srch input { width: 100%; border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; font-size: 15px; }
.srch input:focus { outline: 2px solid var(--accent-soft); border-color: var(--accent); }
.sres { position: absolute; left: 0; right: 0; top: calc(100% + 4px); z-index: 5; background: #fff;
  border: 1px solid var(--line); border-radius: 10px; box-shadow: 0 12px 30px rgba(15,23,42,.12);
  max-height: 300px; overflow: auto; display: none; }
.sres.open { display: block; }
.sr { padding: 8px 12px; cursor: pointer; border-bottom: 1px solid var(--line2); }
.sr:last-child { border-bottom: 0; }
.sr:hover, .sr.act { background: var(--accent-soft); }
.sr .a { font-size: 13px; } .sr .a b { font-weight: 600; }
.sr .b { font-size: 12px; color: var(--muted); }
.sr .fl { font-size: 11px; background: #fef3c7; color: #92400e; padding: 1px 6px; border-radius: 99px; margin-left: 6px; }
.sr-leer { padding: 10px 12px; color: var(--faint); font-size: 13px; }
.veh { margin: 0 20px 6px; font-size: 13px; }
.veh:empty { display: none; }
.veh .vc { display: flex; flex-wrap: wrap; gap: 4px 12px; align-items: center; padding: 8px 12px;
  background: #f8fafc; border: 1px solid var(--line); border-radius: 10px; }
.veh .rot { color: #dc2626; font-weight: 600; } .veh .gelb { color: var(--warn); font-weight: 600; }

/* Arbeiten */
.jobs { display: flex; flex-wrap: wrap; gap: 6px; padding: 0 20px 8px; }
.job { border: 1px solid var(--line); background: #fff; border-radius: 99px; padding: 5px 11px; font-size: 13px; cursor: pointer; }
.job:hover { background: var(--bg); }
.job.on { background: var(--accent); border-color: var(--accent); color: #fff; }
.notiz { display: flex; gap: 8px; padding: 0 20px; }
.notiz textarea { flex: 1; border: 1px solid var(--line); border-radius: 8px; padding: 7px 9px; font-size: 14px; resize: vertical; }
.mic { width: 44px; border: 1px solid var(--line); background: #fff; border-radius: 8px; font-size: 18px; cursor: pointer; }
.mic.rec { background: #fee2e2; border-color: #ef4444; animation: puls 1.2s infinite; }
.mic.busy { opacity: .5; cursor: progress; }
@keyframes puls { 50% { box-shadow: 0 0 0 4px rgba(239,68,68,.2); } }
.dhint { margin: 6px 20px 2px; font-size: 12px; color: var(--muted); }
.dhint:empty { display: none; }

/* Serviceberater-Wahl */
.sbwahl { display: flex; flex-wrap: wrap; gap: 6px; padding: 0 20px; }
.sbw { border: 1px solid var(--line); background: #fff; border-radius: 99px; padding: 5px 12px; font-size: 13px;
  cursor: pointer; display: inline-flex; align-items: center; gap: 6px; }
.sbw:hover { background: var(--bg); }
.sbw.on { border-color: currentColor; box-shadow: inset 0 0 0 1px currentColor; font-weight: 600; }
.sbw.weg { color: var(--faint); text-decoration: line-through; }
.sbw small { color: var(--faint); font-weight: 400; }

/* Verfügbarkeit */
.vhead { display: flex; align-items: center; justify-content: space-between; padding-right: 20px; }
.vday { display: flex; align-items: center; gap: 6px; padding-top: 6px; }
.vlabel { font-weight: 600; min-width: 190px; text-align: center; }
.vgrp { display: flex; align-items: center; gap: 10px; padding: 0 20px 6px; flex-wrap: wrap; }
.flabel { font-size: 12px; color: var(--muted); }
.vinfo { font-size: 12px; color: var(--muted); }
.vabw { margin: 2px 20px 6px; font-size: 12px; color: var(--muted); padding: 7px 10px; background: #fafafa;
  border: 1px dashed var(--line); border-radius: 8px; }
.vabw:empty { display: none; }
.vabw b { color: var(--text); font-weight: 600; }
.vtl { padding: 0 20px; overflow-x: auto; }
.vrow { display: grid; grid-template-columns: 150px 1fr; align-items: center; gap: 10px; min-width: 640px; padding: 5px 0; }
.vrow + .vrow { border-top: 1px solid var(--line2); }
.vrow.axis { padding: 0; height: 20px; color: var(--faint); font-size: 11px; border: 0; }
.vrow .nm { font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.vrow .nm .sub { display: block; font-size: 11px; color: var(--faint); }
.vrow .nm .sub.ok { color: var(--ok); }
.vrow.sel { background: var(--accent-soft); border-radius: 8px; }
.vrow .scale { position: relative; height: 100%; }
.vrow .scale span { position: absolute; top: 3px; transform: translateX(-50%); font-variant-numeric: tabular-nums; }
.trk { position: relative; height: 26px; border-radius: 6px; background: #fff; box-shadow: inset 0 0 0 1px var(--line); overflow: hidden; cursor: pointer; }
.trk .g { position: absolute; top: 0; bottom: 0; width: 1px; background: var(--line2); }
.trk .off { position: absolute; top: 0; bottom: 0; background: var(--off); }
.trk .okz { position: absolute; top: 0; bottom: 0; background: var(--ok-soft); }
.trk .bk { position: absolute; top: 4px; bottom: 4px; border-radius: 4px; background: var(--busy);
  border-left: 3px solid #94a3b8; font-size: 11px; color: var(--busy-text); padding: 0 4px; line-height: 18px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.trk .an { position: absolute; top: 5px; bottom: 5px; border-radius: 3px; }
.trk .pick { position: absolute; top: 1px; bottom: 1px; border-radius: 5px; border: 2px solid var(--accent);
  background: rgba(37,99,235,.12); z-index: 2; pointer-events: none; }
.trk .now { position: absolute; top: 0; bottom: 0; width: 2px; background: #ef4444; z-index: 3; }
.trk.sbtrk { height: 18px; cursor: default; }
.slots { display: flex; gap: 4px; flex-wrap: wrap; margin-top: 4px; }
.slot { border: 1px solid #86efac; background: #fff; color: #166534; border-radius: 6px; padding: 1px 7px; font-size: 12px;
  cursor: pointer; font-variant-numeric: tabular-nums; }
.slot:hover { background: var(--ok-soft); }
.slot.on { background: var(--ok); color: #fff; border-color: var(--ok); }
.vleer { padding: 16px 0; color: var(--faint); font-size: 13px; }
.vleg { display: flex; gap: 14px; padding: 8px 20px 0; font-size: 12px; color: var(--muted); flex-wrap: wrap; }
.lg { display: inline-block; width: 14px; height: 10px; border-radius: 3px; margin-right: 5px; vertical-align: -1px; }
.lg.ok { background: var(--ok-soft); box-shadow: inset 0 0 0 1px #86efac; }
.lg.busy { background: var(--busy); }
.lg.pause { background: var(--off); }
.wahl { background: #fbfcfd; }

.overlay { position: fixed; inset: 0; background: rgba(245,246,248,.92); display: flex; align-items: center; justify-content: center; z-index: 100; }
.overlay[hidden] { display: none; }
.ocard { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 24px; text-align: center; }

@media (max-width: 1000px) {
  .dcols { grid-template-columns: 1fr; }
  .dleft { border-right: 0; }
  .brand, .right { min-width: 0; }
  .right { flex-wrap: wrap; }
  .brand .b2 { display: none; }
  .tt .arb { max-width: 200px; }
}
@media (max-width: 700px) {
  .top { flex-wrap: wrap; padding: 8px 12px; }
  .day { order: 3; flex-basis: 100%; }
  .dlabel { min-width: 0; font-size: 15px; }
  #btnKlassisch { display: none; }
  .tt .grp, .tt th:nth-child(6) { display: none; }
}

/* Bestätigung nach dem Speichern + Sprung in die Werkstatt */
.okbar { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin: 0 0 12px; padding: 10px 14px;
  background: var(--ok-soft); border: 1px solid #86efac; border-radius: 10px; color: #14532d; font-size: 13px; }
.okbar[hidden] { display: none; }
.okbar b { font-weight: 600; }
.okbar .sp { margin-left: auto; display: flex; gap: 6px; }
.okbar .ghost { background: #fff; }
.tt tr.neu td { background: #f0fdf4; }
.tt tr.neu td:first-child { box-shadow: inset 3px 0 0 var(--ok); }
.tt tbody tr[data-tag] { cursor: pointer; }
.tag.n { background: var(--ok); color: #fff; }
.vlabel.fern { color: var(--accent); }
.c-z .bleibt { display:block; font-size:11px; color: var(--faint); font-weight:400; }
.tt .mech .ff { font-size: 10.5px; color: #b45309; background: #fef3c7; border-radius: 99px; padding: 0 6px; margin-left: 4px; }

/* ---------- Mietwagen (Build 116) ---------- */
.mwp { display:inline-block; font-size:11px; border-radius:99px; padding:1px 7px; margin-left:4px; cursor:pointer; white-space:nowrap;
       background:#ecfdf5; color:#065f46; border:1px solid #a7f3d0; }
.mwp.zurueck { background:#eff6ff; color:#1e40af; border-color:#bfdbfe; }
.mwp.rot { background:#fef2f2; color:#991b1b; border-color:#fecaca; }
.mwp:hover { filter:brightness(.95); }
.ai.mwi { background:#fbfdff; }
.ai.mwi .u { color:var(--muted); }
.mwsec .mwkopf { display:flex; gap:16px; padding:2px 20px 4px; flex-wrap:wrap; }
.mwfrei { padding:4px 20px 10px; display:flex; flex-wrap:wrap; gap:6px; align-items:flex-start; }
.mwfrei .mwl { flex-basis:100%; font-size:11.5px; color:var(--muted); margin-top:4px; }
.mwfrei .mwl.no, .mwfrei .no { color:#b91c1c; }
.mww { border:1px solid var(--line); background:#fff; border-radius:8px; padding:5px 9px; text-align:left; cursor:pointer; font-size:12px; line-height:1.3; }
.mww span { display:block; color:var(--muted); font-size:11px; }
.mww:hover { border-color:var(--accent); }
.mww.on { border-color:var(--accent); background:var(--accent-soft); box-shadow:0 0 0 2px var(--accent) inset; }
.mww.belegt { opacity:.5; cursor:not-allowed; }
.mwbel { flex-basis:100%; font-size:11.5px; color:var(--muted); }
.mwbel summary { cursor:pointer; }
.mwbel .mww { margin:4px 6px 0 0; }
/* Build 117: Wünsche, Lage, Umbuchen */
.mwwunsch { display:flex; gap:12px; align-items:center; flex-wrap:wrap; padding:2px 20px 6px; }
.mwwunsch select { border:1px solid var(--line); border-radius:8px; padding:4px 8px; background:#fff; }
.mwfest { padding:6px 0; color:var(--text); font-size:13px; }
.mwlage { padding:2px 20px 4px; font-size:12.5px; }
.mwlage .ok { color:#15803d; font-weight:600; } .mwlage .no { color:#b91c1c; font-weight:600; }
.mww.umb { border-style:dashed; border-color:#f59e0b; }
.mww i { display:block; font-style:normal; font-size:10.5px; color:#92400e; margin-top:3px; max-width:340px; white-space:normal; }
.mwz { padding:3px 0; border-top:1px solid var(--line2); font-size:12px; }
.mwp.wunsch { background:#fff7ed; color:#9a3412; border:1px dashed #fdba74; }
.mwp.wunsch.extern { background:#f5f3ff; color:#5b21b6; border:1px solid #ddd6fe; cursor:default; }

/* ---------- Tagesleiste im Terminfenster + kräftiger Tag (01.12.2026) ---------- */
.vlabel { font-size: 15px; padding: 4px 12px; border-radius: 99px; background: var(--accent); color: #fff !important; min-width: 210px; }
.vlabel.fern { color: #fff; background: #1d4ed8; }
.vstrip { display: grid; grid-template-columns: repeat(10, minmax(0, 1fr)); gap: 5px; padding: 6px 20px 8px; }
.vst { border: 1px solid var(--line); background: #fff; border-radius: 9px; padding: 5px 2px 4px; cursor: pointer;
       display: flex; flex-direction: column; align-items: center; line-height: 1.15; transition: transform .08s, box-shadow .08s; }
.vst:hover { border-color: var(--accent); transform: translateY(-1px); box-shadow: 0 2px 6px rgba(37,99,235,.15); }
.vst .w { font-size: 11px; color: var(--muted); font-weight: 600; text-transform: uppercase; letter-spacing: .03em; }
.vst .d { font-size: 14px; font-weight: 700; font-variant-numeric: tabular-nums; }
.vst .s { font-size: 10.5px; color: var(--faint); white-space: nowrap; }
.vst.ok { border-bottom: 3px solid #22c55e; } .vst.ok .s { color: #15803d; }
.vst.eng { border-bottom: 3px solid #f59e0b; } .vst.eng .s { color: #b45309; }
.vst.voll { border-bottom: 3px solid #ef4444; background: #fef7f7; } .vst.voll .s { color: #b91c1c; font-weight: 600; }
.vst.heute .w { color: var(--accent); }
.vst.sa { background: #fafafa; }
.vst.on { background: var(--accent); border-color: var(--accent); color: #fff; box-shadow: 0 3px 10px rgba(37,99,235,.35); transform: translateY(-1px); }
.vst.on .w, .vst.on .s, .vst.on .d { color: #fff !important; }
/* Kopf der Startseite: Tag ebenfalls kräftiger */
.top .dlabel { background: var(--accent-soft); color: #1e3a8a; font-weight: 700; font-size: 15px; border-radius: 99px; padding: 6px 16px; }
.top .dlabel:hover { background: #dbe7fd; }

/* Mechaniker zuordnen (Build 124) */
.ghost.klein { padding: 1px 8px; font-size: 12px; margin-left: 8px; }
dialog.zuo { width: min(640px, calc(100vw - 24px)); }
.zuo-info { font-size: 13px; margin: 0 0 10px; color: var(--muted); }
.zuo-liste { display: flex; flex-direction: column; gap: 4px; max-height: 60vh; overflow: auto; }
.zuo-m { display: grid; grid-template-columns: 1.3fr 1.2fr 1.2fr; gap: 10px; align-items: center; text-align: left;
  padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; background: #fff; cursor: pointer; font: inherit; font-size: 13px; }
.zuo-m:hover { border-color: var(--accent); background: var(--bg); }
.zuo-m.vor { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent) inset; }
.zuo-m.ist { background: var(--ok-soft); }
.zuo-m.weg { opacity: .45; cursor: default; }
.zuo-m .zn { font-weight: 600; }
.zuo-m .zz, .zuo-m .zg { color: var(--muted); }
.zuo-fuss { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-top: 12px; font-size: 12px; }
.tag.v { background: #dbeafe; color: #1e40af; }
.zuo .err { color: #dc2626; font-size: 13px; margin-top: 8px; }
.zuo .ghost.danger { color: #dc2626; }

/* Akte im Termindetail (Build 124) */
.ak-st { display: flex; gap: 12px; align-items: baseline; font-size: 13px; padding: 2px 0; }
.ak-st span { color: var(--muted); }
.ak-st.laeuft b:first-child { color: #15803d; }
.ak-n, .ak-f { border-left: 3px solid var(--line); padding: 4px 0 4px 10px; margin: 6px 0; }
.ak-n.r-arbeit { border-left-color: #16a34a; } .ak-n.r-maengel { border-left-color: #dc2626; } .ak-n.r-hinweis { border-left-color: #f59e0b; }
.ak-k { font-size: 12px; color: var(--muted); }
.ak-t { font-size: 14px; white-space: pre-wrap; }
.ak-v { font-size: 12px; color: var(--muted); padding-left: 6px; }
.ak-gal { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.ak-b { width: 92px; height: 70px; border-radius: 6px; overflow: hidden; background: var(--bg); border: 1px solid var(--line);
  display: flex; align-items: center; justify-content: center; font-size: 26px; cursor: zoom-in; }
.ak-b img { width: 100%; height: 100%; object-fit: cover; }
.ak-b.fehlt { opacity: .4; }
.ak-links a { display: inline-block; text-decoration: none; }
.zuo-m .zar { grid-column: 1 / -1; font-size: 12px; color: #15803d; }
.zuo-m.ist .zar { color: #15803d; }

/* ---------- Build 129: Mehrtägig/flexibel, Fertig-Zusage, Auftragsinhalt ---------- */
.fhint { align-self: end; font-size: 11px; color: var(--faint); padding-bottom: 10px; }
.tag.fx { background: #ede9fe; color: #5b21b6; }
.tag.ps { background: #fee2e2; color: #991b1b; }
.kont { display: block; font-size: 11px; color: #5b21b6; font-weight: 500; }
.auin { margin: 6px 0 0; border: 1px solid var(--line); border-radius: 8px; background: var(--card); }
.auin > summary { cursor: pointer; padding: 7px 12px; font-size: 13px; font-weight: 600; color: var(--accent); list-style: none; }
.auin > summary::-webkit-details-marker { display: none; }
.auin > summary::before { content: "▸ "; } .auin[open] > summary::before { content: "▾ "; }
.auin-b { padding: 2px 12px 10px; font-size: 12.5px; max-height: 340px; overflow: auto; }
.auin-k { color: var(--muted); margin-bottom: 6px; }
.auin h5 { margin: 8px 0 3px; font-size: 11px; color: var(--faint); text-transform: uppercase; letter-spacing: .05em; font-weight: 600; }
.auin-z { display: flex; gap: 8px; align-items: baseline; padding: 2px 0; }
.auin-z input { margin: 0; flex: none; }
.auin-z .t { flex: 1; min-width: 0; }
.auin-z .h { color: var(--muted); white-space: nowrap; font-variant-numeric: tabular-nums; }
.auin-z .d { display: block; color: var(--faint); font-size: 11.5px; }
.auin-f { display: flex; gap: 8px; align-items: center; margin-top: 8px; flex-wrap: wrap; }
.auin-ok { color: var(--ok); font-size: 12px; }
.ghost.klein { padding: 3px 9px; font-size: 12px; }
.flexbox { background: #faf5ff; border: 1px solid #ede9fe; border-radius: 8px; padding: 8px 10px; margin-top: 4px; }
.flexbox .fsb { display: inline-block; vertical-align: middle; }

/* ---------- Build 129: schmale Fenster (halber Bildschirm, Laptop) ----------
   Stefan 03.12.2026: Planer auf halbem Bildschirm war schlecht lesbar. Statt fester Mindestbreiten
   bricht der Kopf um, das Terminfenster wird einspaltig, die Tagesliste blendet Nebenspalten aus. */
.panel { overflow-x: auto; }
@media (max-width: 1100px) {
  .top { flex-wrap: wrap; gap: 8px 12px; padding: 8px 12px; }
  .brand, .right { min-width: 0; }
  .right { flex-wrap: wrap; }
  .day { order: 3; flex-basis: 100%; }
  .dlabel { min-width: 0; font-size: 15px; }
  .start { padding: 10px 10px 24px; }
  .dcols { grid-template-columns: 1fr; }
  .dleft { border-right: 0; border-bottom: 1px solid var(--line2); }
  .tt .grp { display: none; }
  .tt th:nth-child(7) { display: none; }
  .tt .arb { white-space: normal; max-width: none; font-size: 12.5px; }
  .tt th.c-ab, .tt td.c-ab { min-width: 210px; width: 30%; }
  .vrow { min-width: 0; grid-template-columns: 120px 1fr; }
}
@media (max-width: 820px) {
  .b2 { display: none; }
  .right .ghost { padding: 6px 9px; }
  .tt td, .tt th { padding: 6px 6px; }
  .tt .c-au, .tt th:nth-child(4) { display: none; }
  .tt .mech { white-space: normal; }
  .tt th.c-ab, .tt td.c-ab { min-width: 170px; }
  .ai { grid-template-columns: 44px 1fr; padding: 6px 8px; }
  .ai .s { grid-column: 1 / 3; }
  .vstrip { grid-template-columns: repeat(5, minmax(0, 1fr)); }
  .dgrid { grid-template-columns: repeat(2, 1fr); padding: 4px 12px; }
  .dgrid .w3 { grid-column: span 2; }
  .dsec-t, .jobs, .sbwahl, .vgrp, .notiz, .vtl, .vstrip { padding-left: 12px; padding-right: 12px; }
  .veh, .dhint, .vabw, .dcheck { margin-left: 12px; margin-right: 12px; }
  .vhead { padding-right: 12px; }
  .vrow { grid-template-columns: 96px 1fr; gap: 6px; }
  .det-z { grid-template-columns: 110px 1fr; }
  .det-body { padding: 4px 12px 14px; }
  dialog { width: calc(100vw - 8px); max-height: calc(100vh - 8px); border-radius: 10px; }
}

/* Kopf-Uhr (Build 129) – wie in der Werkstatt-Ansicht */
.top .clock { font-variant-numeric: tabular-nums; text-align: right; line-height: 1.15; flex: none; }
.top .clock .t { font-size: 20px; font-weight: 600; }
.top .clock .d { font-size: 11.5px; color: var(--muted); }
.top { flex-wrap: wrap; }
@media (max-width: 1100px) {
  .top .brand { flex: 1 1 auto; }
  .top .clock { order: 1; }
  .top .right { order: 2; flex: 1 1 100%; justify-content: flex-start; }
  .top .clock .d { display: none; }
}
.auin-sum { display: flex; flex-wrap: wrap; gap: 6px; margin: 2px 0 6px; }
.auin-sum > span { background: var(--accent-soft); color: #1e3a8a; border-radius: 7px; padding: 4px 9px; font-size: 12.5px; }
.auin-sum > span b { font-size: 14px; font-variant-numeric: tabular-nums; }
.auin-sum > span.leer { background: var(--bg); color: var(--muted); }
.auin-sum i, .auin-z i.np { color: var(--warn); font-style: normal; font-size: 11.5px; }

/* Slotto-Logo (Build 129+, 03.12.2026) – dunkle Teile = currentColor, passt sich dem Farbschema an */
.slotto-logo { display: block; height: 26px; width: auto; color: var(--text); }
.mit-zeichen { display: flex; align-items: center; gap: 9px; }
.slotto-zeichen { height: 17px; width: auto; color: var(--text); flex: none; }

/* ================================================================
   Kompakt-Layout (03.12.2026, Stefan): schmaler Kopf, Seite voll nutzen
   ================================================================ */
.top { padding: 5px 14px; gap: 12px; }
.brand { min-width: 0; gap: 0; }
.brand > div { display: flex; align-items: center; gap: 12px; }
.slotto-logo { height: 21px; }
.b2 { font-size: 11.5px; white-space: nowrap; }
.dlabel { font-size: 15px; padding: 3px 10px; min-width: 230px; }
.primary, .ghost { padding: 4px 11px; font-size: 12.5px; }
.top .icon { padding: 3px 8px; font-size: 14px; }
.top .clock { display: flex; align-items: baseline; gap: 7px; line-height: 1; }
.top .clock .t { font-size: 16px; }
.top .clock .d { font-size: 11px; }
.start { max-width: none; padding: 8px 12px 12px; }
.abwbar { font-size: 12.5px; padding: 0 4px 6px; }
.start > .panel { min-height: calc(100vh - 92px); }
.phead { padding: 8px 12px 6px; }
.tt td { padding: 6px 10px; }
.tt tr.hkopf td { padding: 3px 10px; }
@media (max-width: 760px) {
  .brand > div { gap: 8px; }
  .start > .panel { min-height: 0; }
}
/* Tagesnavigation fest (03.12.2026, Stefan): Datumsfeld hat immer dieselbe Breite, damit
   ‹ › bei jedem Wochentag an derselben Stelle bleiben (Dauerklicken ohne Verrutschen). */
.top .dlabel { flex: none; width: 330px; min-width: 0; max-width: calc(100vw - 190px);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-align: center; }
@media (max-width: 760px) { .top .dlabel { white-space: normal; line-height: 1.2; } }

/* Build 131: Werkstattzeit weicht von der Kundenzeit ab */
.tag.wz { background: #ede9fe; color: #5b21b6; }

/* Build 131: Diktat-Knopf als roter Aufnahme-Punkt; während der Aufnahme Stopp-Quadrat */
.mic { display: inline-flex; align-items: center; justify-content: center; }
.mic .recdot { width: 16px; height: 16px; border-radius: 50%; background: #dc2626; box-shadow: 0 0 0 3px #fee2e2; transition: border-radius .15s; }
.mic:hover .recdot { background: #b91c1c; }
.mic.rec .recdot { border-radius: 3px; width: 14px; height: 14px; box-shadow: none; }
/* Build 131: Abholen-Spalte als eingerahmter Kasten (Rahmen links/rechts/oben/unten, eigener Kopf),
   abgesetzt von der weißen Bringen-Seite */
.tt th.c-ab, .tt td.c-ab, .tt tbody tr:hover td.c-ab, .tt tr.hkopf td.hk {
  background: #f3f6fa; border-left: 0 !important;
  box-shadow: inset 2px 0 0 #8fa1b8, inset -2px 0 0 #8fa1b8; }
.tt th.c-ab { background: #dfe6ef; color: #334155 !important; font-weight: 700;
  box-shadow: inset 2px 0 0 #8fa1b8, inset -2px 0 0 #8fa1b8, inset 0 2px 0 #8fa1b8, inset 0 -1px 0 #b8c4d3;
  border-top-left-radius: 8px; border-top-right-radius: 8px; }
.tt th.c-ab .count { color: #334155; }
.tt tr.hkopf td.hk { background: #e8edf4; }
.tt tbody tr:last-child td.c-ab { box-shadow: inset 2px 0 0 #8fa1b8, inset -2px 0 0 #8fa1b8, inset 0 -2px 0 #8fa1b8;
  border-bottom-left-radius: 8px; border-bottom-right-radius: 8px; }
.tt td.c-ab .ai + .ai { border-top-color: #d3dbe5; }
/* kleiner Abstand: letzte Bringen-Spalte bekommt Luft nach rechts */
.tt th.c-st, .tt td.c-st { padding-right: 14px; }

/* Build 131: Ziehen in der Terminliste */
.tt tr.ziehbar, .tt .ai.ziehbar { cursor: grab; }
.tt tr.ziehbar:hover td:first-child { box-shadow: inset 3px 0 0 #93c5fd; }
.tt .ai.ziehbar:hover { box-shadow: inset 3px 0 0 #93c5fd; }
body.zieht, body.zieht * { cursor: grabbing !important; user-select: none !important; }
.tt tr.zieh-quelle td:not(.c-ab), .tt .ai.zieh-quelle { opacity: .35; }
.tt tr.hkopf.drop-h td:first-child { background: #dbeafe; color: #1d4ed8; }
.zieh-ghost { position: fixed; z-index: 9999; pointer-events: none; background: #1e293b; color: #fff; font-size: 12.5px;
  padding: 6px 11px; border-radius: 9px; box-shadow: 0 8px 24px rgba(15,23,42,.28); white-space: nowrap; }
.zieh-ghost.abholen { background: #334155; }
.zieh-ghost b { color: #93c5fd; } .zieh-ghost b:first-child { color: #fff; }
.zieh-ghost i { color: #94a3b8; font-style: normal; }
.zieh-linie { position: fixed; z-index: 9998; height: 3px; background: #2563eb; border-radius: 3px; pointer-events: none;
  box-shadow: 0 0 0 3px rgba(37,99,235,.18); transition: top .06s linear; }
.zieh-linie::before { content: attr(data-zeit); position: absolute; right: 6px; top: -21px; background: #2563eb; color: #fff;
  font-size: 11px; font-weight: 700; padding: 1px 7px; border-radius: 6px; }
#zToast { position: fixed; left: 50%; bottom: 22px; transform: translate(-50%, 30px); opacity: 0; z-index: 9999;
  background: #0f172a; color: #fff; padding: 10px 14px; border-radius: 11px; font-size: 13px; display: flex; gap: 12px; align-items: center;
  box-shadow: 0 10px 30px rgba(15,23,42,.3); transition: all .2s ease; pointer-events: none; max-width: 90vw; }
#zToast.an { opacity: 1; transform: translate(-50%, 0); pointer-events: auto; }
#zToast.warn { background: #7c2d12; }
#zToast button { background: #fff; color: #0f172a; border: 0; border-radius: 7px; padding: 4px 10px; font-weight: 700; cursor: pointer; }

/* Build 132: Prioritaet in der Kompetenzgruppe */
.prio { display: inline-block; font-size: 10px; font-weight: 700; line-height: 1; padding: 2px 4px; border-radius: 4px;
  margin-right: 5px; vertical-align: 1px; color: #fff; background: #9ca3af; }
.prio.p1 { background: #16a34a; }
.prio.p2 { background: #2563eb; }
.prio.p3 { background: #9ca3af; }
