:root { --bg:#f4f5f2; --card:#fff; --line:#d9dcd3; --ink:#1d2420; --mut:#66706a; --acc:#2f6b45; --acc2:#e7f1ea;
  --red:#c0392b; --redbg:#fbe4e1; --yel:#b7791f; --yelbg:#fdf1cf; --grn:#2e7d4f; --grnbg:#dff3e5; --blu:#2b6cb0; --blubg:#e2edf9; }
* { box-sizing:border-box; }
body { margin:0; font:14px/1.4 -apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,sans-serif; background:var(--bg); color:var(--ink); }
button, select, input, textarea { font:inherit; }
button { cursor:pointer; border:1px solid var(--line); background:#fff; border-radius:6px; padding:6px 10px; }
button.pri { background:var(--acc); color:#fff; border-color:var(--acc); }
button.dan { color:var(--red); border-color:var(--red); }
button.sm { padding:2px 7px; font-size:12px; }
button:disabled { opacity:.45; cursor:not-allowed; }
select, input, textarea { border:1px solid var(--line); border-radius:6px; padding:6px 8px; background:#fff; max-width:100%; }
textarea { width:100%; min-height:60px; }
h2 { font-size:16px; margin:18px 0 8px; } h3 { font-size:14px; margin:14px 0 6px; }
.mut { color:var(--mut); } .small { font-size:12px; }

header.top { background:#1f3b2b; color:#fff; padding:8px 14px; display:flex; gap:12px; align-items:center; flex-wrap:wrap; }
header.top b { font-size:15px; } header.top .sp { flex:1; }
header.top select { border:0; } header.top .demo { background:#f0b429; color:#1d2420; border-radius:4px; padding:1px 6px; font-size:11px; font-weight:600; }
nav.tabs { display:flex; gap:2px; padding:0 10px; background:#2a4d39; overflow-x:auto; }
nav.tabs button { border:0; border-radius:0; background:transparent; color:#cfe0d5; padding:9px 12px; white-space:nowrap; }
nav.tabs button.on { background:var(--bg); color:var(--ink); border-radius:6px 6px 0 0; font-weight:600; }
nav.tabs .cnt { background:var(--red); color:#fff; border-radius:9px; padding:0 6px; font-size:11px; margin-left:4px; }
main { padding:12px 14px 60px; }
.bar { display:flex; gap:8px; align-items:center; flex-wrap:wrap; margin-bottom:10px; }
.card { background:var(--card); border:1px solid var(--line); border-radius:8px; padding:10px 12px; margin-bottom:10px; }
.legend { display:flex; gap:12px; flex-wrap:wrap; font-size:12px; color:var(--mut); }
.dot { display:inline-block; width:9px; height:9px; border-radius:50%; vertical-align:middle; }
.dot.block, .dot.l1 { background:var(--red); } .dot.warn, .dot.l2 { background:#e0a100; } .dot.info { background:var(--blu); }
.dot.l3 { background:var(--grn); } .dot.l0 { background:#cfd3cc; }

.scroll { overflow:auto; border:1px solid var(--line); border-radius:8px; background:#fff; max-height:72vh; }
table.grid { border-collapse:separate; border-spacing:0; min-width:100%; }
table.grid th, table.grid td { border-right:1px solid var(--line); border-bottom:1px solid var(--line); padding:3px 5px; text-align:center; white-space:nowrap; }
table.grid thead th { position:sticky; top:0; background:#eef0ea; z-index:2; font-weight:600; font-size:12px; }
table.grid th.name, table.grid td.name { position:sticky; left:0; background:#fff; text-align:left; z-index:1; min-width:170px; }
table.grid thead th.name { z-index:3; background:#eef0ea; }
table.grid tr.grp td { background:#e3e8de; font-weight:600; text-align:left; position:sticky; left:0; }
table.grid th.today, table.grid td.today { box-shadow:inset 2px 0 0 var(--acc), inset -2px 0 0 var(--acc); }
table.grid th.we { color:var(--red); }
td.cell { min-width:74px; height:40px; cursor:pointer; position:relative; padding:2px; }
td.cell:hover { outline:2px solid var(--acc); outline-offset:-2px; }
td.cell.ro { cursor:default; } td.cell.ro:hover { outline:0; }
.chip { display:block; border-radius:5px; padding:1px 4px; font-weight:600; font-size:12px; }
.sub { display:block; font-size:10px; color:#3d4741; overflow:hidden; text-overflow:ellipsis; max-width:96px; margin:0 auto; }
.flag { position:absolute; top:2px; right:2px; } .rm { position:absolute; bottom:1px; right:3px; font-size:10px; }
.abs { color:var(--mut); font-weight:600; } .abs.K { color:var(--red); } .abs.q { font-style:italic; }
td.under { background:var(--redbg); color:var(--red); font-weight:600; } td.okc { background:var(--grnbg); } td.over { background:var(--blubg); }
td.conf { background:var(--redbg); } td.busy { background:#eceee8; } td.free { background:var(--grnbg); color:var(--grn); }
table.list { border-collapse:collapse; width:100%; background:#fff; }
table.list th, table.list td { border-bottom:1px solid var(--line); padding:6px 8px; text-align:left; vertical-align:top; }
table.list th { background:#eef0ea; font-size:12px; }
.tag { display:inline-block; border-radius:10px; padding:1px 8px; font-size:12px; background:#eceee8; }
.tag.block, .tag.abgelehnt { background:var(--redbg); color:var(--red); } .tag.warn, .tag.GF, .tag.angefragt, .tag.beantragt, .tag.offen, .tag.läuft { background:var(--yelbg); color:var(--yel); }
.tag.genehmigt, .tag.erfüllt, .tag.abgeschlossen, .tag.aktiv { background:var(--grnbg); color:var(--grn); } .tag.info { background:var(--blubg); color:var(--blu); }
.msg { border-radius:6px; padding:5px 8px; margin:4px 0; font-size:13px; }
.msg.block { background:var(--redbg); color:var(--red); } .msg.warn { background:var(--yelbg); color:#7a5200; } .msg.info { background:var(--blubg); color:var(--blu); }
.msg.ok { background:var(--grnbg); color:var(--grn); }

.ovl { position:fixed; inset:0; background:rgba(20,30,24,.45); display:flex; align-items:flex-start; justify-content:center; padding:5vh 10px; z-index:20; overflow:auto; }
.dlg { background:#fff; border-radius:10px; padding:16px; width:520px; max-width:100%; box-shadow:0 10px 40px rgba(0,0,0,.3); }
.dlg h2 { margin-top:0; } .dlg label { display:block; margin:8px 0 2px; font-size:12px; color:var(--mut); }
.dlg select, .dlg input:not([type=checkbox]) { width:100%; } .dlg .btns { display:flex; gap:8px; margin-top:14px; flex-wrap:wrap; } .dlg .btns .sp { flex:1; }
.toast { position:fixed; bottom:16px; left:50%; transform:translateX(-50%); background:#1d2420; color:#fff; padding:8px 14px; border-radius:8px; z-index:30; }

/* Mein Plan */
.phone { max-width:400px; margin:0 auto; }
.phone .hd { display:flex; align-items:center; gap:8px; margin-bottom:10px; } .phone .hd h2 { margin:0; flex:1; font-size:20px; }
.day { background:#fff; border:1px solid var(--line); border-radius:10px; padding:10px 12px; margin-bottom:8px; }
.day.now { border-color:var(--acc); box-shadow:0 0 0 2px var(--acc2); }
.day .dt { font-size:12px; color:var(--mut); text-transform:uppercase; letter-spacing:.03em; }
.day .big { font-size:18px; font-weight:700; margin:2px 0; } .day .row { font-size:13px; margin:1px 0; }
.day.off { background:transparent; border-style:dashed; color:var(--mut); padding:6px 12px; }
.phone .acts { display:grid; grid-template-columns:1fr 1fr; gap:8px; margin:10px 0; } .phone .acts button { padding:12px 6px; }
.smile { display:flex; gap:8px; } .smile button { flex:1; font-size:15px; padding:10px 4px; } .smile button.on { background:var(--acc2); border-color:var(--acc); font-weight:700; }
@media (max-width:600px) { header.top .hideS { display:none; } main { padding:10px 8px 60px; } }
