/* ===================================================================
   watchME Kommandobrücke – Gestaltung

   Dasselbe Haus wie das PrAx-Dashboard: gleiche Seitenleiste, gleiche
   Kopfzeile, gleiche Karten, Tabellen und Etiketten, gleiche Abstände.
   Was watchME unterscheidet, ist der Akzent: Gold statt Grün – die Farbe
   des Produkts, das die Kunden sehen. Wer von PrAx herüberkommt, findet
   sich sofort zurecht; wer hier ist, weiß am Gold, wo er ist.

   Alle Schriften kommen vom Gerät, keine externen Requests. Hell ist der
   Grundzustand, dunkel folgt dem System oder der Wahl im Menü.
   =================================================================== */

:root {
  color-scheme: light;

  --sans: "Avenir Next", "Segoe UI", Roboto, -apple-system, BlinkMacSystemFont, "Helvetica Neue", sans-serif;
  --mono: ui-monospace, "SF Mono", "Cascadia Mono", Menlo, Consolas, monospace;

  --paper:      #f3f2ee;
  --paper-deep: #e8e6df;
  --surface:    #ffffff;
  --surface-2:  #fbfaf7;
  --surface-3:  #f6f4ee;

  --ink:        #17150f;
  --ink-soft:   #524d40;
  --ink-faint:  #86806f;
  --ink-ghost:  #aca594;

  --line:       #e1ded4;
  --line-soft:  #ebe9e1;
  --line-hard:  #cdc8b9;

  --brand:      #1b2126;
  --brand-deep: #171c21;
  --brand-soft: #39434a;
  --accent:     #c9a24d;   /* Gold – die Farbe von watchME */
  --accent-ink: #8a6a1c;   /* dunkler, wo Gold Text tragen muss */
  --accent-weich: #f7efd9;
  --on-brand:   #ffffff;
  --on-accent:  #1a1406;

  --amber:      #8a5b0c;
  --amber-soft: #fbf0da;
  --rust:       #a3392a;
  --rust-soft:  #fbeae7;
  --moss:       #2f7340;
  --moss-soft:  #e6f3e8;
  --lagune:     #2c6b8f;
  --lagune-soft:#e4f0f6;
  --flieder:    #6a51a1;

  --radius-xs: 5px;
  --radius-sm: 8px;
  --radius:    12px;
  --radius-lg: 16px;

  --s1: .25rem;  --s2: .5rem;   --s3: .75rem;  --s4: 1rem;
  --s5: 1.25rem; --s6: 1.5rem;  --s8: 2rem;    --s10: 2.75rem;

  --shadow-xs: 0 1px 2px rgba(23, 21, 15, .05);
  --shadow:    0 1px 2px rgba(23, 21, 15, .05), 0 8px 20px -14px rgba(23, 21, 15, .35);
  --shadow-lg: 0 4px 8px rgba(23, 21, 15, .06), 0 32px 60px -26px rgba(23, 21, 15, .42);
  --ring: 0 0 0 3px color-mix(in srgb, var(--accent) 32%, transparent);

  --schnell: .12s cubic-bezier(.4, 0, .2, 1);
  --ruhig:   .22s cubic-bezier(.22, .8, .3, 1);

  --sidebar: 244px;
  --topbar:  60px;
  --breite:  1280px;
  --nav-h:   62px;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="hell"]) {
    color-scheme: dark;
    --paper:      #131311;
    --paper-deep: #0d0d0b;
    --surface:    #1b1b18;
    --surface-2:  #1f1f1b;
    --surface-3:  #25241f;
    --ink:        #ece9e0;
    --ink-soft:   #aba69a;
    --ink-faint:  #84806f;
    --ink-ghost:  #625e50;
    --line:       #33322c;
    --line-soft:  #292823;
    --line-hard:  #42403a;
    --brand:      #d9b96a;
    --brand-deep: #121210;
    --brand-soft: #b3934a;
    --accent:     #d9b96a;
    --accent-ink: #e2c37a;
    --accent-weich: #2a2415;
    --on-brand:   #1a1406;
    --amber:      #dda75a;
    --amber-soft: #2e2617;
    --rust:       #dd8471;
    --rust-soft:  #2e1c18;
    --moss:       #8bc79a;
    --moss-soft:  #16261a;
    --lagune:     #77b3d4;
    --lagune-soft:#152630;
    --flieder:    #a68fd8;
    --shadow-xs: 0 1px 2px rgba(0, 0, 0, .28);
    --shadow:    0 1px 2px rgba(0, 0, 0, .3), 0 8px 20px -14px rgba(0, 0, 0, .7);
    --shadow-lg: 0 4px 8px rgba(0, 0, 0, .4), 0 32px 60px -26px rgba(0, 0, 0, .8);
  }
}
:root[data-theme="dunkel"] {
  color-scheme: dark;
  --paper:      #131311;
  --paper-deep: #0d0d0b;
  --surface:    #1b1b18;
  --surface-2:  #1f1f1b;
  --surface-3:  #25241f;
  --ink:        #ece9e0;
  --ink-soft:   #aba69a;
  --ink-faint:  #84806f;
  --ink-ghost:  #625e50;
  --line:       #33322c;
  --line-soft:  #292823;
  --line-hard:  #42403a;
  --brand:      #d9b96a;
  --brand-deep: #121210;
  --brand-soft: #b3934a;
  --accent:     #d9b96a;
  --accent-ink: #e2c37a;
  --accent-weich: #2a2415;
  --on-brand:   #1a1406;
  --amber:      #dda75a;
  --amber-soft: #2e2617;
  --rust:       #dd8471;
  --rust-soft:  #2e1c18;
  --moss:       #8bc79a;
  --moss-soft:  #16261a;
  --lagune:     #77b3d4;
  --lagune-soft:#152630;
  --flieder:    #a68fd8;
  --shadow-xs: 0 1px 2px rgba(0, 0, 0, .28);
  --shadow:    0 1px 2px rgba(0, 0, 0, .3), 0 8px 20px -14px rgba(0, 0, 0, .7);
  --shadow-lg: 0 4px 8px rgba(0, 0, 0, .4), 0 32px 60px -26px rgba(0, 0, 0, .8);
}

/* Die alten Namen bleiben gültig – so viele Stellen im Skript kennen sie. */
:root {
  --text: var(--ink); --text-dim: var(--ink-soft); --text-faint: var(--ink-faint);
  --lume: var(--accent); --lume-deep: var(--accent-ink); --brass: var(--accent-ink);
  --lume-glow: var(--accent-weich);
  --mint: var(--moss); --mint-dim: var(--moss-soft);
  --danger: var(--rust); --danger-dim: var(--rust-soft);
  --warn: var(--amber); --warn-dim: var(--amber-soft);
  --bg: var(--paper); --bg-panel: var(--surface); --bg-raised: var(--surface-3); --bg-input: var(--surface);
  --line-strong: var(--line-hard);
  --font-display: var(--sans); --font-sans: var(--sans); --font-mono: var(--mono);
  --edge: none;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body, #app { height: 100%; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 400 15px/1.55 var(--sans);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4 { font-weight: 700; letter-spacing: -.02em; line-height: 1.2; margin: 0; }
h1 { font-size: 1.72rem; letter-spacing: -.028em; }
h2 { font-size: 1.18rem; }
h3 { font-size: 1rem; }
h4 { font-size: .95rem; }
a { color: var(--accent-ink); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }
code, pre, .mono { font-family: var(--mono); font-variant-numeric: tabular-nums; }
code { font-size: .86em; background: var(--surface-3); padding: .08em .35em; border-radius: var(--radius-xs); }
::selection { background: color-mix(in srgb, var(--accent) 30%, transparent); }
:focus-visible { outline: none; box-shadow: var(--ring); border-radius: var(--radius-xs); }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: var(--line-hard); border-radius: 6px; border: 3px solid var(--paper); }

@keyframes rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@keyframes einblenden { from { opacity: 0; } to { opacity: 1; } }
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; } }

/* ===================================================================
   Anmeldung – immer dunkel, wie bei PrAx: der Markenauftritt vor der Arbeit
   =================================================================== */

.gate {
  --surface: #1b1b17; --ink: #efece2; --ink-soft: #a8a293; --ink-faint: #7f7a6b;
  --line: #34322b; --line-hard: #43413a; --accent: #d9b96a; --accent-ink: #e2c37a; --on-accent: #1a1406;
  min-height: 100vh; min-height: 100dvh; display: grid; place-items: center; padding: 2rem;
  color: var(--ink); color-scheme: dark;
  background:
    radial-gradient(900px 460px at 18% -10%, rgba(217, 185, 106, .12), transparent 62%),
    radial-gradient(700px 380px at 88% 112%, rgba(140, 151, 158, .07), transparent 60%),
    linear-gradient(168deg, #24241f 0%, #1a1a16 56%, #111110 100%);
}
.gate-card {
  width: 100%; max-width: 384px; padding: 2.1rem 1.95rem;
  background: linear-gradient(180deg, rgba(255, 255, 255, .045), rgba(255, 255, 255, .015));
  border: 1px solid rgba(255, 255, 255, .09); border-radius: 14px;
  box-shadow: 0 30px 70px -30px rgba(0, 0, 0, .8), inset 0 1px 0 rgba(255, 255, 255, .06);
  animation: rise .45s cubic-bezier(.22, .8, .3, 1) both;
}
.gate .seal { margin: 0 0 1.2rem; }
.gate h1 { font-size: 1.55rem; margin-bottom: .2rem; }
.gate p { color: var(--ink-soft); margin: 0 0 1.4rem; font-size: .9rem; }
.gate input { background: rgba(255, 255, 255, .04); border-color: var(--line-hard); color: var(--ink); }
.gate .btn.gold { width: 100%; margin-top: .3rem; }

/* Das Siegel: watchME-Monogramm – im Sidebar-Kopf, auf der Anmeldung. */
.seal {
  width: 34px; height: 34px; flex: none; display: grid; place-items: center;
  border-radius: 9px; font-weight: 800; font-size: .85rem; letter-spacing: -.04em;
  color: var(--on-accent, #1a1406);
  background: linear-gradient(150deg, #e2c37a, #b3934a);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .25);
}
.gate .seal { width: 56px; height: 56px; font-size: 1.3rem; border-radius: 14px; }

/* ===================================================================
   Gerüst: Seitenleiste, Kopfzeile, Fläche
   =================================================================== */

.shell { display: grid; grid-template-columns: var(--sidebar) 1fr; min-height: 100vh; min-height: 100dvh; }
.arbeitsflaeche { display: flex; flex-direction: column; min-width: 0; min-height: 100vh; min-height: 100dvh; }

.sidebar {
  background: linear-gradient(178deg, #24272a 0%, #171c21 46%, #0f1417 100%);
  color: #b8c2be;
  padding: var(--s5) var(--s3) var(--s4);
  display: flex; flex-direction: column; gap: var(--s5);
  position: sticky; top: 0; height: 100vh; height: 100dvh;
  border-right: 1px solid rgba(0, 0, 0, .3);
  z-index: 40;
}
/* Der goldene Faden – bei PrAx ist er grün. */
.sidebar::before {
  content: ''; position: absolute; inset: 0 0 auto; height: 2px;
  background: linear-gradient(90deg, #d9b96a 0 38%, #8c979e 38% 76%, #5c666d 76% 100%);
  opacity: .9;
}
.brand { display: flex; align-items: center; gap: .65rem; padding: .2rem .4rem; text-decoration: none; color: inherit; }
.brand:hover { text-decoration: none; }
.brand-text { display: flex; flex-direction: column; min-width: 0; }
.brand-name { font-size: 1.1rem; font-weight: 700; letter-spacing: -.035em; color: #f2f5f6; line-height: 1.1; }
.brand-sub { font-family: var(--mono); font-size: .53rem; letter-spacing: .22em; text-transform: uppercase; color: #a9946a; }

.nav { display: flex; flex-direction: column; gap: 1px; flex: 1; overflow-y: auto; margin: 0 -.15rem; padding: 0 .15rem; }
.nav::-webkit-scrollbar { width: 6px; }
.nav::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, .12); border: 0; }
.nav-gruppe {
  font-size: .62rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase;
  color: #5f6a6f; padding: var(--s4) .6rem .3rem;
}
.nav-gruppe:first-child { padding-top: .2rem; }
.nav a {
  position: relative; display: flex; align-items: center; gap: .6rem;
  padding: .48rem .6rem; border-radius: var(--radius-sm);
  color: #a3aeaa; text-decoration: none; font-size: .9rem; white-space: nowrap;
  transition: background var(--schnell), color var(--schnell);
}
.nav a:hover { background: rgba(255, 255, 255, .06); color: #eef4f1; text-decoration: none; }
.nav a.active { background: rgba(255, 255, 255, .1); color: #fff; font-weight: 600; }
.nav a.active::before {
  content: ''; position: absolute; left: -.15rem; top: 50%; transform: translateY(-50%);
  width: 3px; height: 17px; border-radius: 0 3px 3px 0; background: #d9b96a;
}
.nav a svg { width: 17px; height: 17px; flex: none; opacity: .82; }
.nav a.active svg { opacity: 1; color: #d9b96a; }
.nav a > span { overflow: hidden; text-overflow: ellipsis; }
.nav a .lamp { margin-left: auto; }
.nav-zahl {
  margin-left: auto; font-size: .7rem; font-weight: 700; font-variant-numeric: tabular-nums;
  min-width: 19px; text-align: center; padding: .05rem .32rem; border-radius: 999px;
  background: rgba(255, 255, 255, .12); color: #d5ddda;
}
.nav-zahl.dringend { background: color-mix(in srgb, #dd8471 70%, #000); color: #ffe6e0; }

.sidebar-foot { border-top: 1px solid rgba(255, 255, 255, .1); padding-top: var(--s3); display: flex; flex-direction: column; gap: .4rem; }
.sidebar-foot .stand { font-family: var(--mono); font-size: .68rem; color: #79847f; padding: 0 .4rem; }
.sidebar-foot .segmente { background: rgba(255, 255, 255, .06); }
.sidebar-foot .segmente button { color: #a3aeaa; }
.sidebar-foot .segmente button[aria-pressed="true"] { background: rgba(255, 255, 255, .12); color: #fff; box-shadow: none; }
.sidebar-foot .abmelden {
  display: flex; align-items: center; gap: .5rem; padding: .42rem .6rem; border-radius: var(--radius-sm);
  color: #a3aeaa; font-size: .86rem; text-decoration: none;
}
.sidebar-foot .abmelden:hover { background: rgba(255, 255, 255, .06); color: #eef4f1; text-decoration: none; }
.sidebar-foot .abmelden svg { width: 16px; height: 16px; }

.topbar {
  position: sticky; top: 0; z-index: 35;
  display: flex; align-items: center; gap: var(--s3);
  min-height: var(--topbar); padding: 0 var(--s6);
  background: color-mix(in srgb, var(--paper) 86%, transparent);
  backdrop-filter: saturate(1.6) blur(10px);
  border-bottom: 1px solid var(--line-soft);
}
.topbar-pfad { display: flex; align-items: center; gap: .35rem; min-width: 0; overflow: hidden; }
.topbar-pfad a { color: var(--ink-faint); font-size: .88rem; white-space: nowrap; }
.topbar-pfad .sep { color: var(--ink-ghost); }
.topbar-titel { font-size: .95rem; font-weight: 600; letter-spacing: -.01em; color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.topbar-rechts { display: flex; align-items: center; gap: var(--s2); margin-left: auto; }
.topbar-stand { font-size: .78rem; color: var(--ink-faint); font-variant-numeric: tabular-nums; white-space: nowrap; }
.topbar-stand.alt { color: var(--amber); }

.ikonknopf {
  position: relative; display: grid; place-items: center; width: 34px; height: 34px; flex: none;
  border: 1px solid transparent; border-radius: var(--radius-sm);
  background: transparent; color: var(--ink-soft); cursor: pointer; text-decoration: none; font: inherit;
  transition: background var(--schnell), color var(--schnell), border-color var(--schnell);
}
.ikonknopf:hover { background: var(--surface); border-color: var(--line); color: var(--ink); text-decoration: none; }
.ikonknopf svg { width: 18px; height: 18px; }
.ikonknopf[disabled] svg { animation: spin .8s linear infinite; }
.leiste-auf { display: none; }

.segmente { display: flex; gap: 2px; padding: 3px; background: var(--surface-3); border-radius: var(--radius-sm); }
.segmente button {
  flex: 1; padding: .32rem .4rem; border: 0; border-radius: var(--radius-xs);
  background: none; color: var(--ink-soft); font: 600 .74rem var(--sans); cursor: pointer;
  transition: background var(--schnell), color var(--schnell);
}
.segmente button:hover { color: var(--ink); }
.segmente button[aria-pressed="true"] { background: var(--surface); color: var(--ink); box-shadow: var(--shadow-xs); }

.stage { padding: var(--s6) var(--s6) var(--s10); max-width: var(--breite); width: 100%; flex: 1; animation: rise .3s cubic-bezier(.22, .8, .3, 1) both; }
.stage-inner { display: flex; flex-direction: column; gap: var(--s5); }
.stage-inner > * { min-width: 0; }

/* Seitenkopf: Vorspann, Überschrift, Satz – Knöpfe rechts. */
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: var(--s4) var(--s6); flex-wrap: wrap; margin-bottom: var(--s1); }
.page-head h2 { font-size: 1.72rem; letter-spacing: -.028em; order: -2; flex: 1 1 auto; }
.page-head .sub { order: 10; flex: 1 0 100%; max-width: 100%; margin: 0; color: var(--ink-soft); font-size: .92rem; text-wrap: pretty; }
.page-head .sub::after { content: ''; }
.page-head .spacer { display: none; }
.page-head > .btn, .page-head > a.btn, .page-head > button { flex: none; }
.page-head .eyebrow { order: -3; flex-basis: 100%; }
.eyebrow {
  font-size: .69rem; font-weight: 700; letter-spacing: .13em; text-transform: uppercase;
  color: var(--ink-faint); margin: 0 0 .55rem;
}
.tabbar { display: none; }

/* ===================================================================
   Bausteine
   =================================================================== */

.card {
  background: var(--surface); border: 1px solid var(--line-soft); border-radius: var(--radius);
  box-shadow: var(--shadow-xs); padding: var(--s5);
}
.card > h3:first-child {
  margin: calc(var(--s5) * -1) calc(var(--s5) * -1) var(--s4);
  padding: var(--s4) var(--s5); background: var(--surface-2); border-bottom: 1px solid var(--line-soft);
  border-radius: var(--radius) var(--radius) 0 0;
  font-size: .98rem; display: flex; align-items: center; gap: .6rem; flex-wrap: wrap;
}
.card > h3:first-child .chip, .card > h3:first-child .pill { font-weight: 600; }
.card h3 + .help { margin-top: calc(var(--s2) * -1); }
.card h4 { margin: var(--s4) 0 var(--s2); }
.card.vorfuehrung { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent-weich) inset; }
.help { color: var(--ink-soft); font-size: .88rem; margin: 0 0 var(--s4); max-width: 66ch; }
.card > .help:last-child, .card > p:last-child { margin-bottom: 0; }

.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s5); align-items: start; }
@media (max-width: 900px) { .grid-2 { grid-template-columns: 1fr; } }

/* Kennzahlen */
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(176px, 100%), 1fr)); gap: var(--s4); }
.kpi {
  background: var(--surface); border: 1px solid var(--line-soft); border-radius: var(--radius);
  padding: var(--s4) var(--s5); transition: border-color var(--schnell), box-shadow var(--schnell);
}
.kpi:hover { border-color: var(--line); box-shadow: var(--shadow); }
.kpi .label { font-size: .72rem; font-weight: 600; letter-spacing: .05em; text-transform: uppercase; color: var(--ink-faint); margin-bottom: .45rem; }
.kpi .value { font-size: 1.62rem; font-weight: 700; letter-spacing: -.035em; line-height: 1.05; font-variant-numeric: tabular-nums; }
.kpi .value.gold { color: var(--accent-ink); }
.kpi .value.mint { color: var(--moss); }
.kpi .value.bad  { color: var(--rust); }
.kpi .hint { font-size: .78rem; color: var(--ink-faint); margin-top: .5rem; padding-top: .5rem; border-top: 1px solid var(--line-soft); }
.kpi.flat { background: var(--surface-3); border-color: transparent; }
.kpi.flat .value { font-size: 1.3rem; }
.card .kpis { margin-top: var(--s2); }

/* Flotte: die Karten der Kunden und Demos */
.fleet { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(300px, 100%), 1fr)); gap: var(--s4); }
.fleet-card {
  text-align: left; cursor: pointer; font: inherit; color: var(--ink);
  background: var(--surface); border: 1px solid var(--line-soft); border-radius: var(--radius);
  box-shadow: var(--shadow-xs); padding: var(--s4) var(--s5);
  display: flex; flex-direction: column; gap: .7rem;
  transition: border-color var(--schnell), box-shadow var(--schnell), transform var(--schnell);
}
.fleet-card:hover { border-color: var(--line); box-shadow: var(--shadow); transform: translateY(-1px); }
.fleet-head { display: flex; align-items: center; gap: .55rem; flex-wrap: wrap; }
.fleet-head .lamp { width: 9px; height: 9px; }
.fleet-name { font-size: 1.02rem; font-weight: 700; letter-spacing: -.015em; }
.fleet-head .pill { margin-left: auto; }
.fleet-url { font-family: var(--mono); font-size: .76rem; color: var(--ink-faint); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fleet-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: .5rem; border-top: 1px solid var(--line-soft); padding-top: .7rem; }
.mini { min-width: 0; }
.mini .label { font-size: .64rem; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-faint); }
.mini .value { font-size: .95rem; font-weight: 600; font-variant-numeric: tabular-nums; color: var(--ink); }
.mini .value.mint { color: var(--moss); }
.mini .value.bad { color: var(--rust); }

/* Lampen und Etiketten */
.lamp { width: 8px; height: 8px; border-radius: 50%; background: var(--ink-ghost); flex: none; }
.lamp.on  { background: var(--moss); box-shadow: 0 0 0 3px color-mix(in srgb, var(--moss) 22%, transparent); }
.lamp.off { background: var(--rust); box-shadow: 0 0 0 3px color-mix(in srgb, var(--rust) 22%, transparent); }
.lamp.dim { background: var(--amber); box-shadow: 0 0 0 3px color-mix(in srgb, var(--amber) 22%, transparent); }

.chip, .pill {
  display: inline-flex; align-items: center; gap: .3rem;
  font-size: .73rem; font-weight: 600; padding: .2rem .55rem; border-radius: 999px;
  background: var(--surface-3); color: var(--ink-soft); border: 1px solid transparent; white-space: nowrap;
  font-family: var(--sans); letter-spacing: 0; text-transform: none;
}
.chip .lamp { margin: 0; }
.chip.ok, .pill.aktiv        { background: var(--moss-soft); color: var(--moss); }
.chip.bad, .pill.gekuendigt  { background: var(--rust-soft); color: var(--rust); }
.chip.warn, .pill.pausiert   { background: var(--amber-soft); color: var(--amber); }
.chip.gold, .pill.test       { background: var(--accent-weich); color: var(--accent-ink); }
.pill.interessent            { background: transparent; border-color: var(--line); color: var(--ink-faint); }

/* Knöpfe */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .45rem;
  padding: .5rem .9rem; border-radius: var(--radius-sm);
  border: 1px solid var(--line); background: var(--surface); color: var(--ink);
  font: 600 .88rem/1.2 var(--sans); cursor: pointer; text-decoration: none; white-space: nowrap;
  transition: transform var(--schnell), filter var(--schnell), background var(--schnell), border-color var(--schnell);
}
.btn:hover { background: var(--surface-3); border-color: var(--line-hard); text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn svg { width: 15px; height: 15px; }
.btn.gold { background: var(--brand); border-color: var(--brand); color: var(--on-brand); }
.btn.gold:hover { filter: brightness(1.14); background: var(--brand); }
.btn.danger { background: transparent; color: var(--rust); }
.btn.danger:hover { background: var(--rust-soft); border-color: color-mix(in srgb, var(--rust) 40%, transparent); }
.btn.small { padding: .3rem .6rem; font-size: .8rem; }
.btn[disabled] { opacity: .5; cursor: wait; }

/* Eingaben */
input, select, textarea {
  width: 100%; padding: .5rem .65rem;
  border: 1px solid var(--line-hard); border-radius: var(--radius-sm);
  background: var(--surface); color: var(--ink); font: 400 .91rem/1.5 var(--sans);
  transition: border-color var(--schnell), box-shadow var(--schnell);
}
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--accent); box-shadow: var(--ring); }
input::placeholder, textarea::placeholder { color: var(--ink-ghost); }
input[type=checkbox], input[type=radio] { width: auto; accent-color: var(--accent-ink); }
textarea { resize: vertical; min-height: 60px; }
label { font-size: .8rem; font-weight: 600; color: var(--ink-soft); }
.form-row { display: flex; flex-direction: column; gap: .3rem; margin-bottom: var(--s3); }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 var(--s4); }
@media (max-width: 560px) { .form-grid { grid-template-columns: 1fr; } }
.check-row { display: flex; align-items: center; gap: .5rem; font-size: .88rem; color: var(--ink-soft); margin-bottom: var(--s3); }
.check-row input { width: auto; }
.form-error { color: var(--rust); font-size: .85rem; min-height: 1.2rem; margin-top: .5rem; }

/* Tabellen */
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; margin: 0 calc(var(--s5) * -1); }
.table-wrap table { min-width: 100%; }
table { width: 100%; border-collapse: collapse; font-size: .89rem; }
th {
  text-align: left; font-size: .68rem; letter-spacing: .1em; text-transform: uppercase;
  color: var(--ink-faint); padding: .55rem var(--s5); border-bottom: 1px solid var(--line); white-space: nowrap;
  background: var(--surface-2);
}
td { padding: .62rem var(--s5); border-bottom: 1px solid var(--line-soft); vertical-align: middle; }
tr:last-child td { border-bottom: none; }
tbody tr { transition: background var(--schnell); }
tbody tr:hover { background: color-mix(in srgb, var(--ink) 2.5%, transparent); }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
tr.off td { opacity: .45; }
.watch-name { font-weight: 600; }
.watch-query { font-family: var(--mono); font-size: .78rem; color: var(--ink-faint); }
.interval-edit { display: inline-flex; align-items: center; gap: .3rem; }
.interval-edit input { width: 64px; padding: .25rem .45rem; font-size: .8rem; text-align: right; }
.interval-edit span { color: var(--ink-faint); font-size: .78rem; }

/* Hinweise und Regelverstöße */
.violations { display: flex; flex-direction: column; gap: .45rem; }
.violation {
  display: flex; align-items: center; gap: .6rem; flex-wrap: wrap;
  border: 1px solid color-mix(in srgb, var(--amber) 32%, transparent); background: var(--amber-soft);
  color: var(--ink); border-radius: var(--radius-sm); padding: .55rem .85rem; font-size: .86rem;
}
.violation .who { font-weight: 700; color: var(--amber); flex: none; }
.violation.ok { border-color: color-mix(in srgb, var(--moss) 32%, transparent); background: var(--moss-soft); }
.violation.ok .who { color: var(--moss); }
.empty { color: var(--ink-faint); font-size: .9rem; padding: .5rem 0; }
.card > .empty:only-child, .card > h3 + .empty { padding: 1.2rem 0; text-align: center; }

.sys-row { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; }
.meter { flex: 1 1 150px; min-width: 150px; }
.meter .label { display: flex; justify-content: space-between; font-size: .74rem; color: var(--ink-faint); margin-bottom: .25rem; font-variant-numeric: tabular-nums; }
.meter .bar { height: 6px; border-radius: 999px; background: var(--paper-deep); overflow: hidden; }
.meter .fill { height: 100%; background: var(--accent); border-radius: 999px; transition: width var(--ruhig); }
.meter .fill.hot { background: var(--rust); }

/* Paket-Kasten */
.paket { margin: var(--s4) 0 var(--s1); padding: .8rem .95rem; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface-3); }
.paket:has(input:checked) { border-color: var(--accent); background: var(--accent-weich); }
.paket-kopf { display: flex; align-items: center; gap: .55rem; font-size: .92rem; font-weight: 600; color: var(--ink); cursor: pointer; }
.paket-kopf input { width: auto; cursor: pointer; }
.paket .help { margin: .4rem 0 0; }
.paket-warn { margin-top: .6rem; padding: .55rem .7rem; border-radius: var(--radius-sm); border: 1px solid color-mix(in srgb, var(--amber) 40%, transparent); background: var(--amber-soft); color: var(--amber); font-size: .82rem; line-height: 1.5; }

pre.logs {
  background: var(--paper-deep); border: 1px solid var(--line-soft); border-radius: var(--radius-sm);
  padding: .9rem; font-size: .76rem; line-height: 1.6; max-height: 420px; overflow: auto;
  white-space: pre-wrap; word-break: break-word; color: var(--ink-soft); margin: 0;
}
.error-item { font-size: .82rem; padding: .45rem 0; border-bottom: 1px solid var(--line-soft); }
.error-item:last-child { border-bottom: none; }
.error-item .when { font-family: var(--mono); color: var(--ink-faint); font-size: .72rem; }
.error-item .msg { color: var(--rust); }

/* Zugangsdaten */
.secret-row {
  display: flex; align-items: center; gap: .5rem; flex-wrap: wrap;
  background: var(--surface-3); border: 1px solid var(--line-soft); border-radius: var(--radius-sm);
  padding: .5rem .5rem .5rem .8rem; margin-bottom: .55rem;
}
.secret-row .key { font-size: .78rem; color: var(--ink-faint); flex: none; min-width: 76px; font-weight: 600; }
.secret-row .val { font-family: var(--mono); font-size: .84rem; flex: 1; min-width: 120px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.secret-row .val.hidden-dots { letter-spacing: .2em; color: var(--ink-faint); }

/* Checkliste */
.todo { display: flex; flex-direction: column; gap: .25rem; }
.todo label {
  display: flex; align-items: center; gap: .6rem; padding: .55rem .75rem;
  border: 1px solid var(--line-soft); border-radius: var(--radius-sm); cursor: pointer; font-size: .9rem; font-weight: 500; color: var(--ink);
  transition: border-color var(--schnell), background var(--schnell);
}
.todo label:hover { border-color: var(--line-hard); background: var(--surface-2); }
.todo input { width: 17px; height: 17px; flex: none; }
.todo label.done { color: var(--ink-faint); text-decoration: line-through; }
.todo .todo-hint { margin-left: auto; font-size: .75rem; color: var(--ink-faint); text-decoration: none; font-weight: 400; }

/* Tagebuch */
.timeline { display: flex; flex-direction: column; max-height: 320px; overflow-y: auto; }
.timeline .entry { display: flex; gap: .7rem; padding: .45rem 0; border-bottom: 1px solid var(--line-soft); font-size: .86rem; }
.timeline .entry:last-child { border-bottom: none; }
.timeline .when { font-family: var(--mono); color: var(--ink-faint); font-size: .72rem; flex: none; width: 110px; padding-top: .15rem; }
.note-row { display: flex; gap: .5rem; margin-top: var(--s3); }
.note-row input { flex: 1; }

/* Anleitung: nummerierte Schritte */
.steps { display: flex; flex-direction: column; gap: var(--s3); counter-reset: step; }
.step {
  display: grid; grid-template-columns: 44px 1fr; gap: var(--s4);
  background: var(--surface); border: 1px solid var(--line-soft); border-radius: var(--radius);
  box-shadow: var(--shadow-xs); padding: var(--s4) var(--s5);
}
.step-num { counter-increment: step; font-size: 1.5rem; font-weight: 800; color: var(--accent-ink); line-height: 1; text-align: center; padding-top: .1rem; letter-spacing: -.04em; }
.step-num::before { content: counter(step); }
.step h4 { margin: .1rem 0 .3rem; font-size: 1rem; }
.step p { margin: 0 0 .6rem; color: var(--ink-soft); font-size: .88rem; max-width: 66ch; }
.step ul { margin: 0 0 .6rem; padding-left: 1.1rem; color: var(--ink-soft); font-size: .88rem; }
.step li { margin-bottom: .2rem; }
.cmd { display: flex; align-items: center; gap: .6rem; background: var(--paper-deep); border: 1px solid var(--line-soft); border-radius: var(--radius-sm); padding: .55rem .75rem; margin-bottom: .5rem; }
.cmd code { flex: 1; font-size: .8rem; color: var(--ink); background: none; padding: 0; overflow-x: auto; white-space: nowrap; scrollbar-width: none; }
.cmd .btn { flex: none; }

/* Tresor */
.vault-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(300px, 100%), 1fr)); gap: var(--s4); }
.vault-card { background: var(--surface); border: 1px solid var(--line-soft); border-radius: var(--radius); box-shadow: var(--shadow-xs); padding: var(--s4) var(--s5); }
.vault-card .vault-head { display: flex; align-items: baseline; gap: .5rem; margin-bottom: .6rem; flex-wrap: wrap; }
.vault-card .vault-label { font-size: 1rem; font-weight: 700; letter-spacing: -.015em; }
.vault-card .vault-user { font-family: var(--mono); font-size: .76rem; color: var(--ink-faint); }
.vault-card .vault-note { font-size: .84rem; color: var(--ink-soft); margin-top: .5rem; }
.vault-card .vault-actions { display: flex; gap: .4rem; margin-top: .6rem; flex-wrap: wrap; }

/* Quick Links */
.links-group h3 { margin: var(--s5) 0 var(--s3); font-size: .74rem; font-weight: 700; letter-spacing: .13em; text-transform: uppercase; color: var(--ink-faint); }
.links-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(240px, 100%), 1fr)); gap: var(--s3); }
.link-card {
  display: flex; align-items: center; gap: .7rem; position: relative;
  background: var(--surface); border: 1px solid var(--line-soft); border-radius: var(--radius-sm);
  padding: .8rem .95rem; color: var(--ink); font-weight: 600; font-size: .9rem;
  transition: border-color var(--schnell), transform var(--schnell), box-shadow var(--schnell);
}
.link-card:hover { border-color: var(--line); box-shadow: var(--shadow); text-decoration: none; transform: translateY(-1px); }
.link-card > div > div:first-child { display: flex; align-items: center; gap: .5rem; }
.link-card svg { width: 17px; height: 17px; color: var(--accent-ink); }
.link-card .arrow { margin-left: auto; color: var(--ink-ghost); }
.link-card .host { font-family: var(--mono); font-size: .7rem; color: var(--ink-faint); font-weight: 400; }
.link-card .del {
  position: absolute; top: -7px; right: -7px; width: 20px; height: 20px; border-radius: 50%;
  border: 1px solid var(--line); background: var(--surface); color: var(--ink-soft); font-size: .7rem; line-height: 1; cursor: pointer; display: none;
}
.link-card:hover .del { display: block; }
.link-card .del:hover { color: var(--rust); border-color: var(--rust); }

/* Finanzen */
.months { display: flex; flex-direction: column; gap: .35rem; }
.month-row { display: grid; grid-template-columns: 64px 1fr 110px; gap: .6rem; align-items: center; font-size: .82rem; }
.month-row .m { font-variant-numeric: tabular-nums; color: var(--ink-soft); }
.month-row .bars { display: flex; flex-direction: column; gap: 3px; }
.month-row .bar-in, .month-row .bar-out { height: 7px; border-radius: 999px; min-width: 2px; }
.month-row .bar-in  { background: var(--accent); }
.month-row .bar-out { background: color-mix(in srgb, var(--rust) 60%, transparent); }
.month-row .saldo { text-align: right; font-variant-numeric: tabular-nums; font-weight: 600; }
.month-row .saldo.plus { color: var(--moss); }
.month-row .saldo.minus { color: var(--rust); }
.betrag-in  { color: var(--moss); font-variant-numeric: tabular-nums; white-space: nowrap; font-weight: 600; }
.betrag-out { color: var(--rust); font-variant-numeric: tabular-nums; white-space: nowrap; }

/* Papier: Rechnung und Vertrag */
.paper-toolbar { display: flex; gap: .5rem; align-items: center; flex-wrap: wrap; }
.paper {
  background: #fff; color: #211c12; border-radius: var(--radius-sm); box-shadow: var(--shadow);
  padding: 48px 52px; max-width: 800px; font-size: 13.5px; line-height: 1.6; border: 1px solid var(--line-soft);
}
.paper h1 { font-size: 24px; font-weight: 700; margin: 0 0 4px; }
.paper .paper-head { display: flex; justify-content: space-between; gap: 20px; margin-bottom: 34px; }
.paper .absender { font-size: 11px; color: #6f6754; border-bottom: 1px solid #d8d0bd; padding-bottom: 4px; margin-bottom: 10px; }
.paper .meta { text-align: right; font-size: 12.5px; color: #4a4130; }
.paper .meta strong { color: #211c12; }
.paper table { width: 100%; border-collapse: collapse; margin: 20px 0; font-size: 13px; }
.paper th { color: #6f6754; border-bottom: 1.5px solid #211c12; padding: 6px 8px; text-transform: none; letter-spacing: 0; font-size: 12px; background: none; }
.paper td { border-bottom: 1px solid #d8d0bd; padding: 8px; color: #211c12; }
.paper tr.total td { border-top: 2px solid #211c12; border-bottom: none; font-weight: 700; font-size: 14.5px; }
.paper .fuss { margin-top: 30px; font-size: 12px; color: #4a4130; }
.paper pre { font-family: var(--sans); white-space: pre-wrap; font-size: 13px; line-height: 1.65; margin: 0; }
.paper[contenteditable='true'] { outline: 2px dashed color-mix(in srgb, var(--accent) 50%, transparent); outline-offset: 6px; }

/* Meldungen und Ladezustand */
.toast {
  position: fixed; right: 1.1rem; bottom: calc(1.1rem + env(safe-area-inset-bottom, 0px)); z-index: 400;
  max-width: min(90vw, 360px); padding: .7rem .9rem; border-radius: var(--radius);
  background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-lg);
  font-size: .88rem; color: var(--ink); animation: rise .2s cubic-bezier(.22, .8, .3, 1) both;
}
.toast.error { border-color: color-mix(in srgb, var(--rust) 40%, var(--line)); color: var(--rust); }
.loading {
  display: grid; place-items: center; padding: 80px 0; color: var(--ink-faint);
  font-size: .78rem; letter-spacing: .12em; text-transform: uppercase; font-weight: 600;
}
.loading::before {
  content: ''; width: 26px; height: 26px; border-radius: 50%;
  border: 2px solid var(--line); border-top-color: var(--accent); animation: spin .8s linear infinite; margin-bottom: 12px;
}

/* Spielregeln-Vorschau */
.regeln-vorschau { display: flex; flex-direction: column; gap: .7rem; margin: var(--s3) 0 var(--s4); }
.rv-note { font-size: .78rem; color: var(--ink-faint); margin: 0; }
.rv-sec { border: 1px solid var(--line-soft); border-radius: var(--radius-sm); background: var(--surface-3); padding: .75rem .9rem; display: flex; flex-direction: column; gap: .55rem; }
.rv-head { font-size: .68rem; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-faint); font-weight: 700; display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; }
.rv-line { font-size: .84rem; color: var(--ink-soft); margin: 0; line-height: 1.55; }
.rv-chips { display: flex; flex-wrap: wrap; gap: .35rem; }
.rv-hint { font-size: .8rem; color: var(--amber); margin-top: .3rem; line-height: 1.5; }
.regeln-vorschau .meter { min-width: 0; flex: none; }
.regeln-vorschau .meter.rv-locked { opacity: .4; }
.regeln-vorschau .meter.rv-locked .fill { background: var(--line-hard); }
.rv-wie summary { cursor: pointer; font-size: .84rem; color: var(--accent-ink); user-select: none; font-weight: 600; }
.rv-wie p { font-size: .84rem; color: var(--ink-soft); margin: .5rem 0 0; line-height: 1.6; }
.rv-wie p strong { color: var(--ink); }

/* KI-Prüfung */
.ki-liste { display: flex; flex-direction: column; }
.ki-zeile { display: flex; flex-direction: column; gap: .65rem; padding: var(--s4) 0; border-bottom: 1px solid var(--line-soft); }
.ki-zeile:first-child { padding-top: .2rem; }
.ki-zeile:last-child { border-bottom: none; padding-bottom: .1rem; }
.ki-zeile.aus { opacity: .6; }
.ki-kopf { display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; }
.ki-name { font-size: 1rem; font-weight: 700; color: var(--ink); padding: 9px 0; margin: -9px 0; letter-spacing: -.015em; }
.ki-name:hover { color: var(--accent-ink); text-decoration: none; }
.ki-zahlen { display: flex; flex-wrap: wrap; gap: .6rem 1.7rem; }
.ki-zahl { display: flex; flex-direction: column; min-width: 84px; }
.ki-zahl .wert { font-variant-numeric: tabular-nums; font-size: 1rem; font-weight: 600; line-height: 1.25; color: var(--ink); }
.ki-zahl .was { font-size: .66rem; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-faint); white-space: nowrap; }
.ki-zeile .meter { flex: none; min-width: 0; }
.ki-verlauf { display: flex; align-items: flex-end; gap: 4px; height: 58px; }
.ki-tag { flex: 1 1 0; min-width: 4px; height: 100%; display: flex; align-items: flex-end; }
.ki-saeule { display: block; width: 100%; min-height: 2px; border-radius: 3px 3px 0 0; background: var(--accent); }
.ki-tag.leer .ki-saeule { background: var(--paper-deep); }
.ki-achse { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 2px 10px; margin-top: .4rem; font-size: .68rem; color: var(--ink-faint); font-variant-numeric: tabular-nums; }

/* Kundenakte: Reiter */
.akte-tabs { display: flex; gap: .35rem; flex-wrap: wrap; margin-bottom: var(--s1); }
.akte-tab {
  appearance: none; background: var(--surface); border: 1px solid var(--line); border-radius: 999px;
  color: var(--ink-soft); font: 600 .85rem var(--sans); padding: .34rem .8rem; cursor: pointer;
  transition: all var(--schnell);
}
.akte-tab:hover { border-color: var(--line-hard); color: var(--ink); }
.akte-tab.active { background: var(--brand); border-color: var(--brand); color: var(--on-brand); }

.demo-einstellungen { margin-top: var(--s3); border-top: 1px solid var(--line-soft); padding-top: var(--s3); }
.demo-einstellungen summary { cursor: pointer; color: var(--ink-soft); font-size: .88rem; font-weight: 600; list-style: none; }
.demo-einstellungen summary::-webkit-details-marker { display: none; }
.demo-einstellungen summary::before { content: '▸ '; color: var(--ink-faint); }
.demo-einstellungen[open] summary::before { content: '▾ '; }
.demo-einstellungen summary:hover { color: var(--ink); }
.demo-einstellungen .check-row label { font-size: .86rem; color: var(--ink-soft); display: inline-flex; align-items: center; gap: .4rem; font-weight: 500; }

/* Ein Symbol ohne Maß füllt seinen Platz ganz aus – in einer Überschrift wird
   daraus ein Riesenzeichen. Deshalb bringt jedes Symbol sein Maß mit. */
svg { flex: none; }
h2 svg, h3 svg, .prax-bezug svg, .chip svg, .pill svg { width: 17px; height: 17px; }
.btn svg { width: 14px; height: 14px; }

/* PrAx-Bezug in Kunden- und Demoakte */
.prax-bezug { display: flex; align-items: center; gap: .7rem; flex-wrap: wrap; font-size: .88rem; }
.prax-bezug .avatar {
  flex: none; display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%;
  background: linear-gradient(150deg, #4fb37a, #2d8a58); color: #08170f; font-size: .72rem; font-weight: 700;
}
.prax-bezug .was { flex: 1; min-width: 160px; }
.prax-bezug .was strong { display: block; }
.prax-bezug .was span { color: var(--ink-faint); font-size: .8rem; }

/* ===================================================================
   Schmale Fläche: Seitenleiste wird Schublade, unten eine Leiste
   =================================================================== */

@media (max-width: 900px) {
  .shell { grid-template-columns: 1fr; }
  .sidebar {
    position: fixed; inset: 0 auto 0 0; width: min(288px, 86vw); height: 100dvh;
    transform: translateX(-100%); transition: transform var(--ruhig);
    box-shadow: var(--shadow-lg); z-index: 120; overscroll-behavior: contain;
  }
  body.leiste-offen .sidebar { transform: none; }
  body.leiste-offen { overflow: hidden; }
  body.leiste-offen::after { content: ''; position: fixed; inset: 0; z-index: 110; background: rgba(10, 14, 16, .5); backdrop-filter: blur(2px); }
  .leiste-auf { display: grid; }
  .topbar { padding: 0 max(var(--s4), env(safe-area-inset-left)) 0 max(var(--s4), env(safe-area-inset-right)); }
  .topbar-stand { display: none; }
  .stage { padding: var(--s4) max(var(--s4), env(safe-area-inset-right)) calc(var(--nav-h) + var(--s8) + env(safe-area-inset-bottom, 0px)) max(var(--s4), env(safe-area-inset-left)); }
  .page-head h2 { font-size: 1.42rem; }
  .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s3); }
  .kpi { padding: var(--s3) var(--s4); }
  .kpi .value { font-size: 1.35rem; }
  .fleet { grid-template-columns: 1fr; }
  .step { grid-template-columns: 32px 1fr; padding: var(--s4); gap: .6rem; }
  .step-num { font-size: 1.2rem; }
  .card { padding: var(--s4); }
  .card > h3:first-child { margin: calc(var(--s4) * -1) calc(var(--s4) * -1) var(--s3); padding: var(--s3) var(--s4); }
  .table-wrap { margin: 0 calc(var(--s4) * -1); }
  th, td { padding: .5rem var(--s4); }
  .secret-row .key { min-width: 64px; }
  .timeline .when { width: 84px; }
  .ki-verlauf { height: 46px; }
  .ki-zahlen { display: grid; grid-template-columns: 1fr 1fr; gap: .7rem 1rem; }
  .akte-tabs { flex-wrap: nowrap; overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-width: none; margin: 0 calc(var(--s4) * -1); padding: 0 var(--s4); }
  .akte-tab { flex: none; }

  .tabbar {
    display: grid; grid-template-columns: repeat(5, 1fr);
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 100;
    height: calc(var(--nav-h) + env(safe-area-inset-bottom, 0px)); padding-bottom: env(safe-area-inset-bottom, 0px);
    background: color-mix(in srgb, var(--surface) 92%, transparent); backdrop-filter: blur(12px);
    border-top: 1px solid var(--line-soft);
  }
  .tabbar a { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; color: var(--ink-faint); font-size: .64rem; font-weight: 600; letter-spacing: .03em; text-decoration: none; }
  .tabbar a.active { color: var(--accent-ink); }
  .tabbar a svg { width: 21px; height: 21px; }
}

@media (pointer: coarse) {
  input, select, textarea { font-size: 16px; }
  .ikonknopf { width: 42px; height: 42px; }
  .btn.small { padding: .42rem .7rem; }
}

@media print {
  body { background: #fff; }
  .sidebar, .tabbar, .topbar, .paper-toolbar, .toast, .page-head { display: none !important; }
  .shell { display: block; }
  .stage { padding: 0; max-width: none; }
  .stage-inner { gap: 0; }
  .paper { box-shadow: none; border: 0; border-radius: 0; max-width: none; padding: 0; }
}
