/* Ghaliweb Büro – Ghaliweb-Stil: #0A0A0A / #F2F2F2 / Weiß / #7A7A7A, Funnel Display + Inter, runde Karten, schwarze Pill-Buttons */
:root{
  --bg:#F2F2F2; --card:#FFFFFF; --ink:#0A0A0A; --muted:#7A7A7A; --line:#E4E4E4; --soft:#F7F7F7; --floor:#FBFBFB;
  --ok:#1F8A55; --warn:#C27C0E; --bad:#C2372B; --info:#3559B5; --pause:#8A6A3E; --learn:#6B4FB3; --off:#B9B9B9;
  --display:"Funnel Display","Inter",system-ui,sans-serif; --text:"Inter",system-ui,-apple-system,"Segoe UI",sans-serif;
}
*{box-sizing:border-box}
html,body{margin:0}
body{background:var(--bg);color:var(--ink);font:15px/1.5 var(--text)}
h1,h2{font-family:var(--display);font-weight:600;margin:0;letter-spacing:-.01em}
h1{font-size:24px} h2{font-size:18px}
.muted{color:var(--muted)} .pad{padding:4px 0}
a{color:inherit}

/* Kopf */
.top{background:var(--card);border-bottom:1px solid var(--line);position:sticky;top:0;z-index:20}
.top-in{max-width:1440px;margin:0 auto;display:flex;align-items:center;gap:20px;padding:12px max(16px,env(safe-area-inset-left))}
.brand{display:flex;align-items:center;gap:12px;text-decoration:none}
.brand img{height:26px;width:auto;display:block}
.brand-sep{width:1px;height:22px;background:var(--line)}
.brand-name{font-family:var(--display);font-weight:600;font-size:18px}
.top-mid{display:flex;gap:8px;flex-wrap:wrap;flex:1}
.chip{display:inline-flex;align-items:center;gap:7px;padding:5px 12px;border-radius:999px;background:var(--soft);border:1px solid var(--line);font-size:13px;font-weight:500;white-space:nowrap}
.chip b{font-variant-numeric:tabular-nums}
.top-right{display:flex;align-items:center;gap:14px;font-size:14px}
.clock{font-variant-numeric:tabular-nums;color:var(--muted)}
.me{font-weight:600}
.ghost{border:1px solid var(--line);border-radius:999px;padding:6px 14px;text-decoration:none;font-size:13px}
.ghost:hover{border-color:var(--ink)}

/* Raster */
.wrap{max-width:1440px;margin:0 auto;padding:20px max(16px,env(safe-area-inset-left)) 48px;display:grid;grid-template-columns:minmax(0,1fr) 380px;gap:20px;align-items:start}
.card{background:var(--card);border:1px solid var(--line);border-radius:22px;padding:20px;min-width:0}
.card-head{display:flex;flex-direction:column;gap:4px;margin-bottom:14px}
.card-head.row{flex-direction:row;align-items:center;justify-content:space-between}
.side{display:flex;flex-direction:column;gap:20px;min-width:0}
.team{grid-column:1/-1}

/* Grundriss */
.floor-scroll{overflow-x:auto;border-radius:16px;background:var(--bg)}
#plan{display:block;width:100%;min-width:640px;height:auto}
#plan text{font-family:var(--text)}
#plan .room{fill:var(--card);stroke:#DCDCDC;stroke-width:1.5}
#plan .room-label{font-family:var(--display);font-size:15px;font-weight:600;fill:var(--ink)}
#plan .room-sub{font-size:11px;fill:var(--muted)}
#plan .door{fill:var(--bg)}
#plan .furn{fill:var(--soft);stroke:#D6D6D6;stroke-width:1.2}
#plan .furn-dark{fill:var(--ink)}
#plan .icon{fill:none;stroke:#9A9A9A;stroke-width:1.6;stroke-linecap:round;stroke-linejoin:round}
#plan .icon-ink{fill:none;stroke:var(--ink);stroke-width:1.6;stroke-linecap:round;stroke-linejoin:round}
#plan .plate{font-size:10px;fill:var(--muted)}
#plan .screen-on{fill:#DDE8FF}
#plan .person{cursor:pointer}
#plan .person:focus{outline:none}
#plan .person:focus-visible .ring{stroke:var(--info);stroke-width:4}
#plan .body{fill:var(--ink)}
#plan .initial{font-size:12px;font-weight:600;fill:#fff;text-anchor:middle;dominant-baseline:central;pointer-events:none}
#plan .ring{fill:none;stroke-width:3}
#plan .name-bg{fill:var(--card);stroke:var(--line)}
#plan .name{font-size:11px;font-weight:600;text-anchor:middle;fill:var(--ink)}
#plan .bubble rect{fill:var(--card);stroke:var(--line)}
#plan .bubble text{font-size:12px;font-weight:700;text-anchor:middle;dominant-baseline:central}
#plan .off .body{fill:#CFCFCF}
#plan .off .name{fill:var(--muted)}
#plan .walking .figure{animation:bob .42s ease-in-out infinite}
#plan .typing circle{fill:var(--ok);animation:blink 1.2s infinite}
#plan .typing circle:nth-child(3){animation-delay:.2s}
#plan .typing circle:nth-child(4){animation-delay:.4s}
#plan .pulse{animation:pulse 1.6s ease-in-out infinite;transform-box:fill-box;transform-origin:center}
#plan .chef .body{fill:var(--ink)}
#plan .badge circle{fill:var(--bad)} #plan .badge text{fill:#fff;font-size:11px;font-weight:700;text-anchor:middle;dominant-baseline:central}
@keyframes bob{0%,100%{transform:translateY(0)}50%{transform:translateY(-3px)}}
@keyframes blink{0%,80%,100%{opacity:.25}40%{opacity:1}}
@keyframes pulse{0%,100%{transform:scale(1)}50%{transform:scale(1.12)}}
@media (prefers-reduced-motion:reduce){#plan .walking .figure,#plan .typing circle,#plan .pulse{animation:none}}

.legend{display:flex;flex-wrap:wrap;gap:6px 16px;margin-top:12px;font-size:12.5px;color:var(--muted)}
.legend span{display:inline-flex;align-items:center;gap:6px}
.dot{width:9px;height:9px;border-radius:50%;display:inline-block}
.s-arbeitet{background:var(--ok)} .s-wartet{background:var(--warn)} .s-fest{background:var(--bad)} .s-besprechung{background:var(--info)} .s-frei{background:var(--pause)} .s-lernt{background:var(--learn)} .s-inaktiv{background:var(--off)}

/* Listen */
.count{min-width:28px;height:28px;padding:0 9px;border-radius:999px;background:var(--ink);color:#fff;display:inline-grid;place-items:center;font-weight:600;font-size:13px}
.list{display:flex;flex-direction:column}
.item{padding:12px 0;border-top:1px solid var(--line);display:flex;flex-direction:column;gap:6px}
.item:first-child{border-top:0;padding-top:0}
.item-t{font-weight:600}
.item-m{font-size:12.5px;color:var(--muted)}
.item-d{font-size:14px;overflow-wrap:anywhere}
.pill{font:600 13px var(--text);border:0;border-radius:999px;background:var(--ink);color:#fff;padding:7px 7px 7px 16px;display:inline-flex;align-items:center;gap:10px;cursor:pointer;align-self:flex-start}
.pill .plus{width:22px;height:22px;border-radius:50%;background:#fff;color:var(--ink);display:grid;place-items:center;font-size:15px;line-height:1}
.pill:disabled{opacity:.5;cursor:default}
.pill:focus-visible,.ghost:focus-visible{outline:2px solid var(--info);outline-offset:2px}
.done-sum{font-size:13px;color:var(--muted);cursor:pointer;margin-top:10px}

/* Autopilot */
.pill-state{font-size:12.5px;font-weight:600;padding:4px 11px;border-radius:999px;background:var(--soft);border:1px solid var(--line)}
.pill-state.on{background:#E5F3EC;border-color:#CBE6D8;color:var(--ok)}
.ap{display:flex;flex-direction:column;gap:14px}
.ap-acc{display:flex;gap:8px;flex-wrap:wrap}
.ap h3{font:600 13px var(--text);margin:0 0 6px;color:var(--muted)}
.ap-row{display:grid;grid-template-columns:86px 1fr;gap:10px;font-size:14px;padding:6px 0;border-top:1px solid var(--line)}
.ap-row:first-of-type{border-top:0}
.ap-row .t{font-variant-numeric:tabular-nums;color:var(--muted);font-size:13px}
.ap-row a{text-decoration:none;border-bottom:1px solid var(--line)}
.ap-warn{font-size:13px;color:var(--bad)}
.link-out{display:inline-block;margin-top:14px;font-size:13px;font-weight:600;text-decoration:none}

/* Tabelle */
.table-scroll{overflow-x:auto}
.tbl{width:100%;border-collapse:collapse;font-size:14px}
.tbl th{font-size:12px;font-weight:600;color:var(--muted);text-align:left;padding:0 12px 8px 0;border-bottom:1px solid var(--line)}
.tbl td{padding:11px 12px 11px 0;border-bottom:1px solid var(--line);vertical-align:middle}
.tbl tr:last-child td{border-bottom:0}
.who{display:flex;align-items:center;gap:10px}
.av{width:32px;height:32px;border-radius:50%;background:var(--ink);color:#fff;display:grid;place-items:center;font-weight:600;font-size:13px;flex:none}
.av.off{background:#CFCFCF}
.st{display:inline-flex;align-items:center;gap:7px;font-size:13px;font-weight:500;white-space:nowrap}
.lv{min-width:150px}
.bar{height:5px;background:var(--soft);border-radius:9px;overflow:hidden;margin-top:5px}
.bar i{display:block;height:100%;background:var(--ink)}
.task{max-width:360px;overflow-wrap:anywhere}

/* Popover */
.pop{position:fixed;z-index:50;background:var(--card);border:1px solid var(--line);border-radius:16px;box-shadow:0 10px 30px rgba(0,0,0,.12);padding:14px 16px;width:260px;font-size:14px}
.pop h3{font:600 16px var(--display);margin:0}
.pop .r{color:var(--muted);font-size:13px;margin-bottom:8px}

/* Login */
.auth-body{display:grid;place-items:center;min-height:100vh;padding:16px}
.auth{background:var(--card);border:1px solid var(--line);border-radius:24px;padding:32px;width:100%;max-width:400px;display:flex;flex-direction:column;gap:10px}
.auth-logo{height:auto;margin-bottom:8px}
.stack{display:flex;flex-direction:column;gap:12px;margin-top:6px}
.stack label{display:flex;flex-direction:column;gap:5px;font-size:13px;font-weight:600}
.stack input{font:15px var(--text);padding:11px 13px;border:1px solid var(--line);border-radius:12px;background:var(--soft)}
.stack input:focus{outline:2px solid var(--ink);outline-offset:0;background:#fff}
.err{color:var(--bad);font-size:14px;margin:0}

@media (max-width:1100px){.wrap{grid-template-columns:1fr}.side{display:grid;grid-template-columns:repeat(auto-fit,minmax(280px,1fr))}}
@media (max-width:640px){.top-mid{display:none}.brand-name{display:none}.me{display:none}.card{padding:16px;border-radius:18px}}
