/* L7 Smarthome – Oberfläche (mobile first, hell/dunkel automatisch) */

:root {
  --bg: #f4f6fa;
  --bg-elev: #ffffff;
  --bg-sunken: #e9edf3;
  --fg: #0f172a;
  --fg-muted: #5b6577;
  --fg-faint: #8a93a3;
  --border: #dbe1ea;
  --accent: #0284c7;
  --accent-fg: #ffffff;
  --accent-soft: #e0f2fe;
  --ok: #15803d;
  --ok-soft: #dcfce7;
  --info: #2563eb;
  --info-soft: #dbeafe;
  --warn: #b45309;
  --warn-soft: #fef3c7;
  --crit: #dc2626;
  --crit-soft: #fee2e2;
  --debug: #7c3aed;
  --debug-soft: #ede9fe;
  --shadow: 0 1px 2px rgba(15, 23, 42, .06), 0 2px 8px rgba(15, 23, 42, .06);
  --radius: 14px;
  --radius-sm: 9px;
  --nav-h: 62px;
  --header-h: 56px;
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-t: env(safe-area-inset-top, 0px);
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0b1220;
    --bg-elev: #131c2e;
    --bg-sunken: #0e1626;
    --fg: #e6ebf3;
    --fg-muted: #9aa6b8;
    --fg-faint: #6b778a;
    --border: #233049;
    --accent: #38bdf8;
    --accent-fg: #04121f;
    --accent-soft: #0c2a3d;
    --ok: #4ade80;
    --ok-soft: #0f2e1d;
    --info: #60a5fa;
    --info-soft: #132544;
    --warn: #fbbf24;
    --warn-soft: #33260b;
    --crit: #f87171;
    --crit-soft: #3a1414;
    --debug: #a78bfa;
    --debug-soft: #241b3d;
    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 4px 14px rgba(0, 0, 0, .25);
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font: 15px/1.45 var(--font);
  -webkit-font-smoothing: antialiased;
  overscroll-behavior-y: none;
}
a { color: var(--accent); text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3 { line-height: 1.25; margin: 0; }
code, pre { font-family: var(--mono); font-size: .88em; }
img, svg { display: block; }
[hidden] { display: none !important; }

.boot { min-height: 100vh; display: grid; place-content: center; justify-items: center; gap: 12px; color: var(--fg-muted); }

/* ---------- Grundlayout ---------- */
.app { min-height: 100vh; }
.shell { min-height: 100vh; padding-top: calc(var(--header-h) + var(--safe-t)); padding-bottom: calc(var(--nav-h) + var(--safe-b) + 16px); }

.header {
  position: fixed; inset: 0 0 auto 0; z-index: 20;
  height: calc(var(--header-h) + var(--safe-t)); padding-top: var(--safe-t);
  display: flex; align-items: center; gap: 4px; padding-inline: 6px 8px;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: saturate(160%) blur(12px); -webkit-backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid var(--border);
}
.header-title { flex: 1; min-width: 0; font-size: 17px; font-weight: 650; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; padding-left: 6px; }
.header-actions { display: flex; align-items: center; gap: 2px; }

.main { max-width: 980px; margin: 0 auto; padding: 14px 14px 0; }

.nav {
  position: fixed; inset: auto 0 0 0; z-index: 20;
  height: calc(var(--nav-h) + var(--safe-b)); padding-bottom: var(--safe-b);
  display: grid; grid-template-columns: repeat(5, 1fr);
  background: color-mix(in srgb, var(--bg-elev) 92%, transparent);
  backdrop-filter: saturate(160%) blur(12px); -webkit-backdrop-filter: saturate(160%) blur(12px);
  border-top: 1px solid var(--border);
}
.nav a {
  position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
  color: var(--fg-muted); font-size: 11px; font-weight: 550;
}
.nav a svg { width: 24px; height: 24px; }
.nav a.active { color: var(--accent); }
.nav .badge { position: absolute; top: 6px; left: calc(50% + 6px); }

@media (min-width: 900px) {
  .shell { padding-left: 220px; padding-bottom: 24px; }
  .header { left: 220px; }
  .nav {
    inset: 0 auto 0 0; width: 220px; height: auto; padding: 16px 10px; display: flex; flex-direction: column; gap: 4px;
    border-top: 0; border-right: 1px solid var(--border);
  }
  .nav::before { content: "L7 Smarthome"; font-weight: 700; font-size: 17px; padding: 8px 12px 18px; color: var(--fg); }
  .nav a { flex-direction: row; justify-content: flex-start; gap: 12px; padding: 10px 12px; border-radius: 10px; font-size: 15px; }
  .nav a.active { background: var(--accent-soft); }
  .nav .badge { position: static; margin-left: auto; }
  .main { padding: 22px 24px 0; }
}

/* ---------- Bausteine ---------- */
.icon-btn {
  width: 42px; height: 42px; border: 0; background: transparent; border-radius: 50%;
  display: inline-grid; place-items: center; cursor: pointer; color: var(--fg);
}
.icon-btn:hover { background: var(--bg-sunken); }
.icon-btn.active { background: var(--accent-soft); color: var(--accent); }
.icon-btn svg { width: 22px; height: 22px; }
.icon-btn.small { width: 32px; height: 32px; }
.icon-btn.small svg { width: 18px; height: 18px; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 42px; padding: 0 16px; border-radius: 11px; border: 1px solid var(--border);
  background: var(--bg-elev); color: var(--fg); font-weight: 600; cursor: pointer; white-space: nowrap;
}
.btn svg { width: 18px; height: 18px; }
.btn:disabled { opacity: .55; cursor: default; }
.btn.primary { background: var(--accent); border-color: var(--accent); color: var(--accent-fg); }
.btn.danger { color: var(--crit); }
.btn.danger.solid { background: var(--crit); border-color: var(--crit); color: #fff; }
.btn.ghost { border-color: transparent; background: transparent; }
.btn.small { min-height: 34px; padding: 0 12px; font-size: 14px; border-radius: 9px; }
.btn.block { width: 100%; }
.btn-row { display: flex; flex-wrap: wrap; gap: 8px; }

.card { background: var(--bg-elev); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); }
.card.pad { padding: 14px 16px; }
.card + .card, .section + .section { margin-top: 14px; }
.stats > .card, .tiles > .card { margin-top: 0; }
.section { margin-top: 18px; }
.section-head { display: flex; align-items: center; gap: 8px; margin: 22px 2px 8px; }
.section-head h2 { font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--fg-muted); flex: 1; }
.muted { color: var(--fg-muted); }
.faint { color: var(--fg-faint); }
.small { font-size: 13px; }
.mono { font-family: var(--mono); font-size: 12.5px; word-break: break-all; }
.nowrap { white-space: nowrap; }
.grow { flex: 1; min-width: 0; }
.row { display: flex; align-items: center; gap: 10px; }
.stack > * + * { margin-top: 10px; }
.center { text-align: center; }
.ellipsis { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.badge {
  display: inline-grid; place-items: center; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px;
  background: var(--crit); color: #fff; font-size: 11px; font-weight: 700;
}
.chip {
  display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 10px; border-radius: 13px;
  background: var(--bg-sunken); color: var(--fg-muted); font-size: 12.5px; font-weight: 600; border: 1px solid transparent; white-space: nowrap;
}
button.chip { cursor: pointer; }
.chip .count { font-weight: 500; opacity: .75; }
.chip.on { background: var(--accent-soft); color: var(--accent); border-color: color-mix(in srgb, var(--accent) 35%, transparent); }
.chip.off { text-decoration: line-through; opacity: .6; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }

.sev-info { --sev: var(--info); --sev-soft: var(--info-soft); }
.sev-warning { --sev: var(--warn); --sev-soft: var(--warn-soft); }
.sev-critical { --sev: var(--crit); --sev-soft: var(--crit-soft); }
.lvl-debug { --sev: var(--debug); --sev-soft: var(--debug-soft); }
.lvl-info { --sev: var(--info); --sev-soft: var(--info-soft); }
.lvl-warning { --sev: var(--warn); --sev-soft: var(--warn-soft); }
.lvl-error { --sev: var(--crit); --sev-soft: var(--crit-soft); }
.lvl-critical { --sev: var(--crit); --sev-soft: var(--crit-soft); }
.tag { display: inline-flex; align-items: center; height: 20px; padding: 0 7px; border-radius: 6px; font-size: 11.5px; font-weight: 700; background: var(--sev-soft, var(--bg-sunken)); color: var(--sev, var(--fg-muted)); white-space: nowrap; }

.dot { width: 9px; height: 9px; border-radius: 50%; background: var(--fg-faint); flex: none; }
.dot.ok { background: var(--ok); box-shadow: 0 0 0 3px var(--ok-soft); }
.dot.bad { background: var(--crit); box-shadow: 0 0 0 3px var(--crit-soft); }
.dot.warn { background: var(--warn); box-shadow: 0 0 0 3px var(--warn-soft); }

/* Listen */
.list { background: var(--bg-elev); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.list-item { display: flex; align-items: center; gap: 12px; padding: 12px 14px; min-height: 56px; color: inherit; border-top: 1px solid var(--border); }
.list-item:first-child { border-top: 0; }
a.list-item:hover, button.list-item:hover { background: var(--bg-sunken); }
button.list-item { width: 100%; text-align: left; background: transparent; border-left: 0; border-right: 0; border-bottom: 0; cursor: pointer; }
.list-item .title { font-weight: 600; }
.list-item .sub { color: var(--fg-muted); font-size: 13px; }
.list-item .chev { color: var(--fg-faint); width: 18px; height: 18px; flex: none; }
.list-item .lead { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; background: var(--bg-sunken); color: var(--fg-muted); flex: none; }
.list-item .lead svg { width: 20px; height: 20px; }

/* Status-Kacheln */
.stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
@media (min-width: 640px) { .stats { grid-template-columns: repeat(4, 1fr); } }
.stat { padding: 12px 14px; display: flex; flex-direction: column; gap: 2px; color: inherit; }
.stat .label { font-size: 12.5px; color: var(--fg-muted); font-weight: 600; }
.stat .value { font-size: 22px; font-weight: 700; display: flex; align-items: center; gap: 8px; }
.stat.alert { border-color: color-mix(in srgb, var(--crit) 50%, var(--border)); background: var(--crit-soft); }

/* Favoriten-Kacheln */
.tiles { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
@media (min-width: 640px) { .tiles { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1100px) { .tiles { grid-template-columns: repeat(4, 1fr); } }
.tile { padding: 12px 14px; display: flex; flex-direction: column; gap: 4px; min-height: 104px; cursor: pointer; text-align: left; color: inherit; font: inherit; }
.tile .t-label { font-weight: 650; font-size: 14px; line-height: 1.25; }
.tile .t-device { font-size: 12px; color: var(--fg-muted); }
.tile .t-value { margin-top: auto; font-size: 24px; font-weight: 700; display: flex; align-items: baseline; gap: 4px; flex-wrap: wrap; }
.tile .t-unit { font-size: 14px; color: var(--fg-muted); font-weight: 600; }
.tile .t-time { font-size: 11.5px; color: var(--fg-faint); }
.tile.stale { opacity: .6; }

/* Schalter */
.switch { position: relative; width: 50px; height: 30px; flex: none; }
.switch input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: pointer; z-index: 1; }
.switch span { position: absolute; inset: 0; border-radius: 15px; background: var(--border); transition: background .15s; }
.switch span::after { content: ""; position: absolute; top: 3px; left: 3px; width: 24px; height: 24px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.3); transition: transform .15s; }
.switch input:checked + span { background: var(--ok); }
.switch input:checked + span::after { transform: translateX(20px); }
.switch input:disabled + span { opacity: .5; }
.switch input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }

.val-bool { display: inline-flex; align-items: center; gap: 6px; font-weight: 650; }

/* Formulare */
.form { display: grid; gap: 14px; }
.field { display: grid; gap: 6px; }
.field-label { display: flex; align-items: center; gap: 6px; font-weight: 600; font-size: 14px; }
.field-label .req { color: var(--crit); }
.field-hint { font-size: 12.5px; color: var(--fg-muted); }
.input, select.input, textarea.input {
  width: 100%; min-height: 44px; padding: 10px 12px; border-radius: 10px; border: 1px solid var(--border);
  background: var(--bg-elev); color: var(--fg); outline: none;
}
textarea.input { min-height: 96px; resize: vertical; font-family: var(--mono); font-size: 13px; }
.input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.check { display: flex; align-items: center; gap: 10px; font-weight: 600; font-size: 14px; }
.check input { width: 20px; height: 20px; accent-color: var(--accent); }
.form-actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; padding-top: 4px; }
.fieldset { border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 12px; display: grid; gap: 12px; }
.fieldset-title { font-weight: 700; font-size: 13px; color: var(--fg-muted); text-transform: uppercase; letter-spacing: .05em; }
.segmented { display: flex; background: var(--bg-sunken); border-radius: 10px; padding: 3px; gap: 2px; overflow-x: auto; }
.segmented button { flex: 1; border: 0; background: transparent; padding: 7px 10px; border-radius: 8px; font-weight: 600; font-size: 13px; color: var(--fg-muted); cursor: pointer; white-space: nowrap; }
.segmented button.on { background: var(--bg-elev); color: var(--fg); box-shadow: var(--shadow); }

.info-btn { width: 22px; height: 22px; border-radius: 50%; border: 0; padding: 0; display: inline-grid; place-items: center; background: transparent; color: var(--accent); cursor: pointer; flex: none; }
.info-btn svg { width: 18px; height: 18px; }

/* Bottom-Sheet / Dialog */
.backdrop { position: fixed; inset: 0; z-index: 50; background: rgba(2, 6, 23, .5); display: flex; align-items: flex-end; justify-content: center; animation: fade .15s ease-out; }
.sheet {
  width: 100%; max-width: 680px; max-height: 92vh; display: flex; flex-direction: column;
  background: var(--bg-elev); border-radius: 18px 18px 0 0; box-shadow: 0 -8px 30px rgba(0,0,0,.25);
  padding-bottom: var(--safe-b); animation: up .2s ease-out;
}
@media (min-width: 720px) {
  .backdrop { align-items: center; }
  .sheet { border-radius: 18px; max-height: 86vh; }
}
.sheet-head { display: flex; align-items: center; gap: 8px; padding: 12px 10px 8px 18px; border-bottom: 1px solid var(--border); }
.sheet-head h3 { flex: 1; font-size: 17px; }
.sheet-body { padding: 16px 18px; overflow-y: auto; -webkit-overflow-scrolling: touch; }
.sheet-foot { padding: 10px 18px 14px; border-top: 1px solid var(--border); display: flex; gap: 8px; justify-content: flex-end; flex-wrap: wrap; }
@keyframes fade { from { opacity: 0; } }
@keyframes up { from { transform: translateY(40px); opacity: .4; } }

/* Hinweise / Toast */
.toast-wrap { position: fixed; z-index: 60; left: 0; right: 0; bottom: calc(var(--nav-h) + var(--safe-b) + 12px); display: grid; justify-items: center; gap: 8px; pointer-events: none; padding: 0 12px; }
.toast { pointer-events: auto; max-width: 560px; padding: 11px 16px; border-radius: 12px; background: var(--fg); color: var(--bg); box-shadow: var(--shadow); font-weight: 550; animation: up .2s ease-out; }
.toast.error { background: var(--crit); color: #fff; }
.toast.ok { background: var(--ok); color: #fff; }
.notice { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: 12px; background: var(--sev-soft, var(--accent-soft)); color: var(--fg); border: 1px solid color-mix(in srgb, var(--sev, var(--accent)) 30%, transparent); }
.notice svg { width: 20px; height: 20px; flex: none; color: var(--sev, var(--accent)); margin-top: 1px; }
.notice + .notice { margin-top: 8px; }
.empty { text-align: center; padding: 28px 16px; color: var(--fg-muted); }
.empty svg { width: 40px; height: 40px; margin: 0 auto 10px; color: var(--fg-faint); }
.offline-bar { position: fixed; z-index: 30; left: 0; right: 0; top: calc(var(--header-h) + var(--safe-t)); background: var(--warn); color: #111; font-size: 13px; font-weight: 650; text-align: center; padding: 5px 10px; }

.fab { position: fixed; z-index: 15; right: 18px; bottom: calc(var(--nav-h) + var(--safe-b) + 16px); width: 56px; height: 56px; border-radius: 18px; border: 0; background: var(--accent); color: var(--accent-fg); box-shadow: 0 6px 18px rgba(2, 132, 199, .4); display: grid; place-items: center; cursor: pointer; }
.fab svg { width: 26px; height: 26px; }
@media (min-width: 900px) { .fab { bottom: 24px; right: 28px; } }

/* Alarme */
.alarm { display: flex; gap: 12px; padding: 12px 14px; border-left: 4px solid var(--sev); }
.alarm .a-title { font-weight: 700; }
.alarm .a-msg { font-size: 14px; color: var(--fg-muted); margin-top: 2px; }
.alarm .a-meta { font-size: 12px; color: var(--fg-faint); margin-top: 6px; display: flex; flex-wrap: wrap; gap: 4px 10px; }
.alarm.cleared { opacity: .7; border-left-color: var(--border); }

.timeline { position: relative; margin: 0; padding: 0 0 0 22px; list-style: none; }
.timeline::before { content: ""; position: absolute; left: 7px; top: 6px; bottom: 6px; width: 2px; background: var(--border); }
.timeline li { position: relative; padding: 0 0 14px; }
.timeline li::before { content: ""; position: absolute; left: -20px; top: 5px; width: 12px; height: 12px; border-radius: 50%; background: var(--sev, var(--fg-faint)); box-shadow: 0 0 0 3px var(--bg-elev); }
.timeline .tl-time { font-size: 12px; color: var(--fg-faint); }
.timeline .tl-msg { font-size: 14px; }

/* Protokoll */
.log-toolbar { display: flex; gap: 6px; align-items: center; }
.log-toolbar .input { min-height: 40px; }
.log-filters { margin-top: 10px; padding: 12px; display: grid; gap: 12px; }
.log-filters .f-title { font-size: 12px; font-weight: 700; color: var(--fg-muted); text-transform: uppercase; letter-spacing: .05em; display: flex; align-items: center; gap: 6px; }
.log-day { position: sticky; top: calc(var(--header-h) + var(--safe-t)); z-index: 5; padding: 8px 4px 6px; font-size: 12px; font-weight: 700; color: var(--fg-muted); background: var(--bg); }
.log-entry { display: grid; grid-template-columns: 4px 1fr; background: var(--bg-elev); border: 1px solid var(--border); border-radius: 10px; overflow: hidden; margin-bottom: 6px; cursor: pointer; }
.log-entry .bar { background: var(--sev); }
.log-entry .body { padding: 8px 11px; min-width: 0; }
.log-entry .meta { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--fg-faint); flex-wrap: wrap; }
.log-entry .msg { font-size: 14px; margin-top: 2px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; word-break: break-word; }
.log-entry.open .msg { -webkit-line-clamp: unset; display: block; }
.log-entry.new { animation: flash 1.5s ease-out; }
.log-detail { margin-top: 8px; display: grid; gap: 8px; }
.log-detail pre { margin: 0; padding: 10px; border-radius: 8px; background: var(--bg-sunken); overflow-x: auto; font-size: 12px; max-height: 320px; }
@keyframes flash { from { background: var(--accent-soft); } }

/* Datenpunkte */
.dp { display: flex; align-items: center; gap: 10px; padding: 10px 14px; border-top: 1px solid var(--border); min-height: 58px; }
.dp:first-child { border-top: 0; }
.dp .dp-main { flex: 1; min-width: 0; cursor: pointer; }
.dp .dp-label { font-weight: 600; }
.dp .dp-key { font-size: 12px; color: var(--fg-faint); font-family: var(--mono); }
.dp .dp-value { font-weight: 700; text-align: right; white-space: nowrap; }
.dp .dp-time { font-size: 11.5px; color: var(--fg-faint); text-align: right; }
.dp.hidden-dp { opacity: .55; }
.star { color: var(--fg-faint); }
.star.on { color: #f59e0b; }

/* Diagramm */
.chart { width: 100%; height: 200px; }
.chart .grid { stroke: var(--border); stroke-width: 1; }
.chart .axis { fill: var(--fg-faint); font-size: 10px; }
.chart .line { fill: none; stroke: var(--accent); stroke-width: 2; }
.chart .band { fill: var(--accent); opacity: .12; }
.chart .step { fill: none; stroke: var(--ok); stroke-width: 2; }
.chart-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; text-align: center; margin-top: 8px; }
.chart-stats div { background: var(--bg-sunken); border-radius: 8px; padding: 6px 4px; }
.chart-stats b { display: block; font-size: 14px; }
.chart-stats span { font-size: 11px; color: var(--fg-muted); }

/* Hilfe / Markdown */
.md { line-height: 1.55; }
.md h1 { font-size: 20px; margin: 4px 0 10px; }
.md h2 { font-size: 18px; margin: 18px 0 8px; }
.md h3 { font-size: 15.5px; margin: 16px 0 6px; }
.md h2:first-child, .md h1:first-child { margin-top: 0; }
.md p { margin: 0 0 10px; }
.md ul, .md ol { margin: 0 0 10px; padding-left: 22px; }
.md li { margin: 3px 0; }
.md code { background: var(--bg-sunken); padding: 1px 5px; border-radius: 5px; }
.md pre { background: var(--bg-sunken); padding: 10px 12px; border-radius: 10px; overflow-x: auto; margin: 0 0 12px; }
.md pre code { background: none; padding: 0; }
.md table { border-collapse: collapse; width: 100%; margin: 0 0 12px; font-size: 14px; }
.md th, .md td { border: 1px solid var(--border); padding: 6px 8px; text-align: left; vertical-align: top; }
.md blockquote { margin: 0 0 10px; padding: 8px 12px; border-left: 3px solid var(--accent); background: var(--accent-soft); border-radius: 0 8px 8px 0; }

/* Login */
.login { min-height: 100vh; display: grid; place-items: center; padding: 24px 16px; }
.login .card { width: 100%; max-width: 380px; padding: 26px 22px; }
.login .logo { display: flex; align-items: center; gap: 12px; margin-bottom: 18px; }
.login .logo img { width: 52px; height: 52px; }
.login h1 { font-size: 22px; }

.kv { display: grid; grid-template-columns: max-content 1fr; gap: 6px 14px; font-size: 14px; }
.kv dt { color: var(--fg-muted); }
.kv dd { margin: 0; min-width: 0; word-break: break-word; }

.weekdays { display: flex; gap: 6px; flex-wrap: wrap; }
.weekdays button { width: 40px; height: 36px; }
.action-card { padding: 12px; display: grid; gap: 10px; background: var(--bg-sunken); border-radius: var(--radius-sm); }
.action-card .ac-head { display: flex; align-items: center; gap: 6px; font-weight: 700; }

.spinner { width: 22px; height: 22px; border-radius: 50%; border: 3px solid var(--border); border-top-color: var(--accent); animation: spin .8s linear infinite; margin: 24px auto; }
@keyframes spin { to { transform: rotate(360deg); } }

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }
