/* Layout: eine Bildschirmhöhe – Kopfzeile, Inhalt (Grundriss oder Liste), Tab-Leiste; Details im Bottom-Sheet */
:root {
  --bg: #eef1f4;
  --surface: #ffffff;
  --ink: #17283a;
  --muted: #5f6e7d;
  --line: #d7dde4;
  --accent: #0b63c5;
  --accent-ink: #ffffff;
  --bar: #17283a;
  --bar-ink: #f2f5f8;
  --plan: #ffffff;
  --plan-grid: #e4e8ed;
  --plan-bg: #e2e7ec;
  --danger: #c4271c;
  --warn-bg: #fff2c4;
  --warn-ink: #5c4500;
  --st-open-f: #eef1f4;      --st-open-b: #8593a1;
  --st-partial-f: #fff0bf;   --st-partial-b: #c99400;
  --st-appointment-f: #d8e9ff; --st-appointment-b: #0b63c5;
  --st-clarify-f: #ffdcd8;   --st-clarify-b: #c4271c;
  --st-done-f: #d5f1dd;      --st-done-b: #1d8a3b;
  --f-body: "IBM Plex Sans", -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --f-label: "IBM Plex Sans Condensed", "Arial Narrow", "IBM Plex Sans", sans-serif;
  --f-data: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
  --tab-h: 60px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0f1822; --surface: #182431; --ink: #e8eef4; --muted: #9aa9b8; --line: #2b3a4a;
    --accent: #4d9cf0; --accent-ink: #08131f; --bar: #0a121b; --bar-ink: #e8eef4;
    --plan: #1b2836; --plan-grid: #243344; --plan-bg: #111b25; --danger: #ff6b5e;
    --warn-bg: #3d3210; --warn-ink: #ffe08a;
    --st-open-f: #223141;      --st-open-b: #7f90a2;
    --st-partial-f: #3d3210;   --st-partial-b: #e0b225;
    --st-appointment-f: #13314f; --st-appointment-b: #4d9cf0;
    --st-clarify-f: #44201d;   --st-clarify-b: #ff6b5e;
    --st-done-f: #163824;      --st-done-b: #4cc26c;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0f1822; --surface: #182431; --ink: #e8eef4; --muted: #9aa9b8; --line: #2b3a4a;
  --accent: #4d9cf0; --accent-ink: #08131f; --bar: #0a121b; --bar-ink: #e8eef4;
  --plan: #1b2836; --plan-grid: #243344; --plan-bg: #111b25; --danger: #ff6b5e;
  --warn-bg: #3d3210; --warn-ink: #ffe08a;
  --st-open-f: #223141;      --st-open-b: #7f90a2;
  --st-partial-f: #3d3210;   --st-partial-b: #e0b225;
  --st-appointment-f: #13314f; --st-appointment-b: #4d9cf0;
  --st-clarify-f: #44201d;   --st-clarify-b: #ff6b5e;
  --st-done-f: #163824;      --st-done-b: #4cc26c;
  color-scheme: dark;
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
[hidden] { display: none !important; }
html, body { height: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 16px/1.4 var(--f-body); overscroll-behavior: none; }
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.muted { color: var(--muted); }
.mono { font-family: var(--f-data); font-variant-numeric: tabular-nums; }
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }

#app { height: 100%; display: flex; flex-direction: column; }
.topbar { display: flex; align-items: center; gap: 10px; padding: 8px 16px; background: var(--bar); color: var(--bar-ink); }
.plan-picker { flex: 1; min-width: 0; display: flex; align-items: center; gap: 6px; min-height: 44px; border: 0;
  border-radius: 10px; padding: 6px 12px; background: color-mix(in srgb, var(--bar-ink) 9%, transparent); color: var(--bar-ink);
  font-weight: 600; font-size: 17px; text-align: left; }
.plan-picker span:first-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.who { display: flex; align-items: center; gap: 6px; font-size: 12px; color: color-mix(in srgb, var(--bar-ink) 75%, transparent); }
.who img { width: 28px; height: 28px; border-radius: 50%; }
.dot { width: 9px; height: 9px; border-radius: 50%; background: #45c46d; flex: none; }
.dot.off { background: #e9a400; }
.banner { padding: 8px 16px; background: var(--warn-bg); color: var(--warn-ink); font-size: 14px; border-bottom: 1px solid var(--line); }

main { flex: 1; min-height: 0; display: flex; flex-direction: column; }
.view { flex: 1; min-height: 0; overflow: auto; -webkit-overflow-scrolling: touch; }
#view-plan { display: flex; flex-direction: column; overflow: hidden; }

.summary { padding: 10px 16px; background: var(--surface); border-bottom: 1px solid var(--line); display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; }
.sum-row { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; font-size: 14px; }
.sum-row strong { font-size: 20px; }
.bar { height: 8px; border-radius: 4px; background: var(--st-open-f); overflow: hidden; }
.bar > span { display: block; height: 100%; background: var(--st-done-b); transition: width .3s; }
.counts { min-width: 0; display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; }
.count { flex: none; font-size: 12px; padding: 3px 9px; border-radius: 999px; border: 1.5px solid; font-family: var(--f-label); letter-spacing: .02em; }

.stage { position: relative; flex: 1; min-height: 0; background: var(--plan-bg); }
#plan-svg { width: 100%; height: 100%; display: block; touch-action: none; user-select: none; -webkit-user-select: none; }
.p-surface { fill: var(--plan); }
.p-grid { stroke: var(--plan-grid); stroke-width: .02; }
.p-wall { fill: none; stroke: var(--ink); stroke-width: .08; }
.area .box { stroke-width: .08; }
.area .t1 { fill: var(--ink); font-family: var(--f-body); font-weight: 700; pointer-events: none; }
.area .t2 { fill: var(--muted); font-family: var(--f-body); pointer-events: none; }
.area.dim { opacity: .3; }
.area.overdue .box { stroke: var(--danger); stroke-width: .14; stroke-dasharray: .35 .2; }
.area.sel .box { stroke: var(--ink); stroke-width: .2; }
.area.moving { opacity: .75; }
.spot { stroke-width: .06; }
.spot.sp-open { fill: var(--plan); stroke: var(--st-open-b); }
.spot.sp-done { fill: var(--st-done-b); stroke: var(--st-done-b); }
.spot.sp-defect { fill: var(--st-clarify-b); stroke: var(--st-clarify-b); }
.spot.sp-absent { fill: var(--st-partial-b); stroke: var(--st-partial-b); }
.spot.sel { stroke: var(--ink); stroke-width: .12; }
.area.moving .spot, .spot.moving { opacity: .7; }
.rubber { fill: color-mix(in srgb, var(--accent) 18%, transparent); stroke: var(--accent); stroke-width: .08; stroke-dasharray: .3 .15; }
.rubber-label { fill: var(--accent); font-family: var(--f-data); }
.f-open { fill: var(--st-open-f); stroke: var(--st-open-b); } .k-open { fill: var(--st-open-b); }
.f-partial { fill: var(--st-partial-f); stroke: var(--st-partial-b); } .k-partial { fill: var(--st-partial-b); }
.f-appointment { fill: var(--st-appointment-f); stroke: var(--st-appointment-b); } .k-appointment { fill: var(--st-appointment-b); }
.f-clarify { fill: var(--st-clarify-f); stroke: var(--st-clarify-b); } .k-clarify { fill: var(--st-clarify-b); }
.f-done { fill: var(--st-done-f); stroke: var(--st-done-b); } .k-done { fill: var(--st-done-b); }

.floating { position: absolute; display: flex; gap: 8px; }
.tl { left: 12px; top: 10px; flex-wrap: wrap; right: 12px; }
.br { right: 12px; bottom: 12px; flex-direction: column; }
.pill { min-height: 40px; padding: 8px 14px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface);
  color: var(--ink); font-size: 14px; display: inline-flex; align-items: center; gap: 6px; box-shadow: 0 2px 8px rgba(0,0,0,.14); }
.pill input { width: 18px; height: 18px; margin: 0; accent-color: var(--accent); }
.pill.on { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.round { width: 46px; height: 46px; border-radius: 50%; border: 1px solid var(--line); background: var(--surface); font-size: 22px;
  box-shadow: 0 2px 8px rgba(0,0,0,.15); color: var(--ink); }
.edit-hint { position: absolute; left: 12px; right: 70px; bottom: 12px; font-size: 13px; padding: 8px 12px; border-radius: 10px;
  background: var(--surface); color: var(--muted); border: 1px solid var(--line); }
.empty-state { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; gap: 12px; padding: 24px 16px; color: var(--muted); }
.empty-state h2 { margin: 0; color: var(--ink); font-size: 20px; }

.list-head { padding: 10px 16px; background: var(--surface); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 2; display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; }
.list-head input[type=search] { width: 100%; padding: 11px 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); font-size: 16px; }
.chips { min-width: 0; display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; }
.chip { flex: none; min-height: 36px; padding: 6px 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); font-size: 14px; }
.chip.on { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.switch { display: flex; align-items: center; gap: 8px; font-size: 14px; color: var(--muted); }
.switch input { width: 20px; height: 20px; margin: 0; accent-color: var(--accent); }
.cards { list-style: none; margin: 0 auto; padding: 10px 16px 20px; display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; max-width: 720px; }
.card { display: flex; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; min-height: 64px; text-align: left; width: 100%; padding: 0; }
.card .stripe { width: 6px; flex: none; }
.card .ci { flex: 1; min-width: 0; padding: 10px 12px; display: grid; gap: 2px; }
.card .t { font-weight: 600; display: flex; justify-content: space-between; gap: 8px; }
.card .t span:first-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.card .s { font-size: 14px; color: var(--muted); }
.card .n { font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.card.overdue .s { color: var(--danger); font-weight: 600; }
.group-h { font-family: var(--f-label); font-size: 13px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin: 8px 2px 0; }
.note-empty { text-align: center; color: var(--muted); padding: 24px 0; }
.more { padding: 16px; max-width: 640px; margin: 0 auto; display: grid; gap: 14px; }
.more h3 { margin: 6px 0 0; font-family: var(--f-label); text-transform: uppercase; letter-spacing: .06em; font-size: 13px; color: var(--muted); }
.more ul { margin: 0; padding-left: 18px; display: grid; gap: 6px; }

.tabbar { display: flex; height: var(--tab-h); background: var(--surface); border-top: 1px solid var(--line); }
.tabbar button { flex: 1; border: 0; background: none; display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 2px; font-size: 12px; color: var(--muted); position: relative; }
.tabbar .ti { font-size: 21px; line-height: 1; }
.tabbar button[aria-current="page"] { color: var(--accent); font-weight: 600; }
.badge { position: absolute; top: 6px; left: calc(50% + 8px); min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px;
  background: var(--accent); color: var(--accent-ink); font-size: 11px; line-height: 18px; font-weight: 700; }
.badge.warn { background: var(--danger); color: #fff; }

.btn { min-height: 48px; padding: 10px 16px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface); font-weight: 600;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; }
.btn:disabled { opacity: .45; }
.btn.primary { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.btn.danger { color: var(--danger); border-color: color-mix(in srgb, var(--danger) 50%, var(--line)); }
.btn.block { width: 100%; }

.backdrop { position: fixed; inset: 0; background: rgba(8,15,22,.5); z-index: 20; }
.sheet { position: fixed; left: 0; right: 0; bottom: 0; z-index: 21; max-height: 88%; overflow: auto; margin: 0 auto; max-width: 640px;
  background: var(--surface); border-radius: 20px 20px 0 0; padding: 6px 16px calc(18px + env(safe-area-inset-bottom, 0px));
  box-shadow: 0 -10px 30px rgba(0,0,0,.25); animation: up .16s ease-out; display: grid; gap: 10px; }
@keyframes up { from { transform: translateY(30px); } to { transform: none; } }
.grabber { width: 40px; height: 5px; border-radius: 3px; background: var(--line); margin: 4px auto 2px; }
.sheet h2 { margin: 0; font-size: 22px; text-wrap: balance; }
.sheet .sub { margin: -6px 0 0; font-size: 14px; color: var(--muted); }
.st-pill { justify-self: start; padding: 4px 12px; border-radius: 999px; border: 2px solid; font-weight: 600; font-size: 14px; }
.facts { margin: 0; display: grid; grid-template-columns: auto 1fr; gap: 4px 14px; font-size: 15px; }
.facts dt { color: var(--muted); }
.facts dd { margin: 0; white-space: pre-wrap; overflow-wrap: anywhere; }
.actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.actions .wide { grid-column: 1 / -1; min-height: 62px; font-size: 18px; }
.act { min-height: 54px; border-radius: 14px; border: 2px solid; font-weight: 600; font-size: 16px; color: var(--ink); }
.act:disabled { opacity: .4; }
.notice { background: var(--warn-bg); color: var(--warn-ink); border-radius: 10px; padding: 10px 12px; font-size: 14px; }
.field { display: grid; gap: 4px; }
.field > label, .field > .lbl { font-size: 14px; color: var(--muted); }
.field input, .field textarea, .field select { width: 100%; padding: 11px 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); font-size: 16px; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.quick { display: flex; flex-wrap: wrap; gap: 6px; }
.range-row { display: flex; align-items: center; gap: 12px; }
.range-row input { flex: 1; accent-color: var(--st-partial-b); height: 34px; }
.range-row output { font-family: var(--f-data); font-size: 20px; min-width: 60px; text-align: right; }
.btn-row { display: flex; gap: 10px; }
.btn-row .btn { flex: 1; }
.err { color: var(--danger); font-size: 14px; min-height: 1.2em; margin: 0; }
details.hist summary { font-weight: 600; min-height: 34px; display: flex; align-items: center; }
.hist-item { font-size: 14px; padding: 8px 0; border-top: 1px solid var(--line); display: grid; gap: 2px; }
.spots { display: grid; gap: 8px; padding: 12px; border-radius: 14px; background: var(--bg); border: 1px solid var(--line); }
.spots-head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.spot-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.spot-row { display: flex; align-items: stretch; gap: 6px; }
.spot-main { flex: 1; min-width: 0; display: flex; align-items: center; gap: 10px; text-align: left; padding: 8px 10px; min-height: 52px;
  border-radius: 10px; border: 1px solid var(--line); background: var(--surface); }
.spot-ico { flex: none; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; font-size: 15px; font-weight: 700; border: 2px solid; }
.si-open { border-color: var(--st-open-b); color: var(--st-open-b); }
.si-done { background: var(--st-done-b); border-color: var(--st-done-b); color: var(--surface); }
.si-defect { background: var(--st-clarify-b); border-color: var(--st-clarify-b); color: var(--surface); }
.si-absent { background: var(--st-partial-b); border-color: var(--st-partial-b); color: var(--surface); }
.spot-txt { min-width: 0; display: grid; }
.spot-name { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.spot-sub { font-size: 13px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sr-defect .spot-sub { color: var(--danger); }
.spot-quick { flex: none; width: 52px; border-radius: 10px; border: 2px solid var(--st-done-b); background: var(--st-done-f); color: var(--ink); font-size: 20px; font-weight: 700; }
.spot-quick:disabled { opacity: .35; }
.tpl { display: grid; gap: 8px; }
.tpl-row { display: grid; grid-template-columns: minmax(0, 1fr) auto auto auto; gap: 6px; align-items: center; }
.tpl-row > input { min-width: 0; padding: 10px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); font-size: 16px; }
.tpl-dev { display: grid; justify-items: center; font-size: 11px; color: var(--muted); }
.tpl-dev input { width: 52px; padding: 6px; border-radius: 8px; border: 1px solid var(--line); background: var(--bg); font-size: 16px; text-align: center; }
.tpl-del { width: 40px; height: 44px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); font-size: 20px; color: var(--muted); }
.stepper { display: inline-flex; align-items: center; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; background: var(--surface); }
.stepper button { width: 40px; height: 44px; border: 0; background: none; font-size: 20px; color: var(--accent); font-weight: 700; }
.stepper output { min-width: 28px; text-align: center; font-size: 16px; }
.room-list { display: grid; gap: 8px; }
.room-card { display: grid; gap: 8px; padding: 10px 12px; border-radius: 12px; border: 1px solid var(--line); background: var(--bg); }
.room-types { display: grid; gap: 6px; }
.room-type { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.room-type > span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.room-card .chip { justify-self: start; }
.dev-ed { display: grid; gap: 8px; }
.dev-list { display: grid; gap: 6px; }
.dev-row { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: 6px; align-items: center; }
.dev-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 500; }
.dev-add { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 6px; }
.dev-add input { min-width: 0; padding: 10px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); font-size: 16px; }
.dev-add .btn { min-height: 44px; }
.dev-sum { font-size: 14px; overflow-wrap: anywhere; }
.card-toggle { display: flex; justify-content: space-between; align-items: center; gap: 8px; background: none; border: 0; padding: 0; min-height: 36px; text-align: left; }
.tpl-devbtn { display: grid; justify-items: center; min-width: 54px; height: 44px; padding: 2px 6px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); font-size: 11px; color: var(--muted); }
.tpl-devbtn .mono { font-size: 16px; color: var(--ink); line-height: 1.2; }
.tpl-devbtn[aria-expanded="true"] { border-color: var(--accent); }
.tpl-devs { display: grid; gap: 6px; padding: 10px; border-radius: 10px; border: 1px dashed var(--line); }
.preset { display: grid; gap: 8px; }
.preset-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.preset-row { display: grid; grid-template-columns: minmax(0, 1fr) auto auto auto; gap: 4px; align-items: center; }
.chip.static { cursor: default; justify-self: start; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.icon-btn { width: 40px; height: 40px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); font-size: 17px; }
.icon-btn:disabled { opacity: .35; }
.back { justify-self: start; background: none; border: 0; padding: 4px 0; color: var(--accent); font-weight: 600; min-height: 36px; }
.plan-opt { width: 100%; text-align: left; background: none; border: 0; border-top: 1px solid var(--line); padding: 12px 2px; display: grid; gap: 6px; }
.plan-opt[aria-current="true"] strong { color: var(--accent); }
.people { display: grid; gap: 4px; }
.person { display: flex; align-items: center; gap: 10px; padding: 8px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); text-align: left; width: 100%; }
.person img { width: 30px; height: 30px; border-radius: 50%; }
.toast { position: fixed; left: 16px; right: 16px; bottom: calc(var(--tab-h) + 14px + env(safe-area-inset-bottom, 0px)); z-index: 30; max-width: 560px; margin: 0 auto;
  background: var(--ink); color: var(--bg); border-radius: 12px; padding: 12px 14px; display: flex; align-items: center; gap: 12px; box-shadow: 0 6px 20px rgba(0,0,0,.3); }
.toast span { flex: 1; }
.toast button { background: none; border: 0; color: inherit; font-weight: 700; text-decoration: underline; min-height: 40px; }

/* ======================================================================
   Web-Version: Anmeldung, Schließen-Knopf, PC-Layout
   ====================================================================== */
body { padding: env(safe-area-inset-top, 0px) 0 env(safe-area-inset-bottom, 0px); box-sizing: border-box; }
.note { font-size: 13px; margin: 0; }
.sheet { position: fixed; }
.sheet-close { position: absolute; top: 8px; right: 10px; width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--line);
  background: var(--surface); color: var(--muted); font-size: 18px; z-index: 2; }
.sheet > div:not(.grabber) { padding-right: 36px; }
.auth { position: fixed; inset: 0; z-index: 50; display: grid; place-items: center; padding: 24px 16px;
  background: linear-gradient(160deg, var(--bar), var(--accent)); overflow: auto; }
.auth-card { width: 100%; max-width: 400px; background: var(--surface); color: var(--ink); border-radius: 18px; padding: 26px 22px;
  box-shadow: 0 20px 50px rgba(0,0,0,.3); display: grid; gap: 12px; }
.auth-card h1 { margin: 0; font-size: 26px; }
.auth-card .brand { display: flex; align-items: center; gap: 12px; }
.auth-card .brand img { width: 48px; height: 48px; }
.account { display: grid; gap: 10px; }
.user-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; align-items: center; padding: 10px 12px;
  border: 1px solid var(--line); border-radius: 12px; background: var(--surface); }
.user-row .who-txt { min-width: 0; display: grid; }
.user-row .who-txt span { font-size: 13px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.user-row.inactive { opacity: .55; }
.user-edit { grid-column: 1 / -1; display: grid; gap: 8px; padding-top: 6px; border-top: 1px dashed var(--line); }
.inline-form { display: grid; gap: 8px; padding: 12px; border: 1px solid var(--line); border-radius: 12px; background: var(--bg); }

@media (min-width: 900px) {
  :root { --rail: 220px; --panel: 440px; }
  #app { display: grid; grid-template-columns: var(--rail) minmax(0, 1fr); grid-template-rows: auto auto minmax(0, 1fr); }
  .topbar, .banner { grid-column: 1 / -1; }
  .topbar { padding: 10px 20px; }
  .plan-picker { flex: 0 1 520px; }
  .who { margin-left: auto; }
  main { grid-column: 2; grid-row: 3; transition: margin-right .16s; }
  body.panel-open main { margin-right: var(--panel); }
  .tabbar { grid-column: 1; grid-row: 3; flex-direction: column; justify-content: flex-start; height: auto; gap: 4px;
    padding: 14px 10px; border-top: 0; border-right: 1px solid var(--line); }
  .tabbar button { flex: none; flex-direction: row; justify-content: flex-start; gap: 12px; padding: 12px 14px; border-radius: 10px; font-size: 15px; }
  .tabbar button[aria-current="page"] { background: color-mix(in srgb, var(--accent) 12%, transparent); }
  .tabbar .ti { width: 24px; text-align: center; }
  .badge { position: static; margin-left: auto; }
  .backdrop { display: none !important; }
  .sheet { left: auto; right: 0; top: 0; bottom: 0; width: var(--panel); max-width: none; max-height: none; margin: 0;
    border-radius: 0; border-left: 1px solid var(--line); box-shadow: -10px 0 28px rgba(0,0,0,.12); padding: 18px 22px 24px;
    animation: slide .16s ease-out; align-content: start; }
  @keyframes slide { from { transform: translateX(24px); opacity: .6; } to { transform: none; opacity: 1; } }
  .grabber { display: none; }
  .toast { left: auto; right: 24px; bottom: 24px; margin: 0; max-width: 420px; }
  body.panel-open .toast { right: calc(var(--panel) + 24px); }
  .summary { padding: 12px 24px; }
  .list-head { padding: 14px 24px; }
  .cards { max-width: 1200px; padding: 16px 24px 32px; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); }
  .cards .group-h, .cards .note-empty { grid-column: 1 / -1; }
  .more { max-width: 820px; padding: 24px; }
  .floating.tl { left: 20px; top: 14px; }
  .floating.br { right: 20px; bottom: 20px; }
  .card:hover, .spot-main:hover, .plan-opt:hover { border-color: var(--accent); }
  .area:hover .box { stroke-width: .14; }
}
