/* Skyspace – Farben je Tageszeit-Phase.
   Die Farb-Variablen sind mit @property registriert, damit der Wechsel
   zwischen den Phasen weich überblendet (auch in Verläufen). */

@property --bg        { syntax: "<color>"; inherits: true; initial-value: #FBF4EC; }
@property --surface   { syntax: "<color>"; inherits: true; initial-value: #FFFFFF; }
@property --line      { syntax: "<color>"; inherits: true; initial-value: #F0E4D8; }
@property --text      { syntax: "<color>"; inherits: true; initial-value: #4A2E2A; }
@property --text-soft { syntax: "<color>"; inherits: true; initial-value: #A0716A; }
@property --accent    { syntax: "<color>"; inherits: true; initial-value: #C86E56; }
@property --nav-bg    { syntax: "<color>"; inherits: true; initial-value: #FFFFFF; }
@property --nav-icon  { syntax: "<color>"; inherits: true; initial-value: #C9B3A8; }
@property --hero-a    { syntax: "<color>"; inherits: true; initial-value: #F7B9A0; }
@property --hero-b    { syntax: "<color>"; inherits: true; initial-value: #C9A7D9; }
@property --hero-text { syntax: "<color>"; inherits: true; initial-value: #3B2233; }
@property --wir-bg    { syntax: "<color>"; inherits: true; initial-value: #F9DDD2; }
@property --wir-fg    { syntax: "<color>"; inherits: true; initial-value: #8A3B22; }
@property --a-bg      { syntax: "<color>"; inherits: true; initial-value: #E7DDF3; }
@property --a-fg      { syntax: "<color>"; inherits: true; initial-value: #5B3D7A; }
@property --b-bg      { syntax: "<color>"; inherits: true; initial-value: #F5E6C8; }
@property --b-fg      { syntax: "<color>"; inherits: true; initial-value: #7A5418; }

:root {
  --font-head: "Fraunces", Georgia, serif;
  --font-body: "Nunito", system-ui, sans-serif;
  --radius: 18px;
  --fade: 2.5s ease;
  transition: --bg var(--fade), --surface var(--fade), --line var(--fade),
    --text var(--fade), --text-soft var(--fade), --accent var(--fade),
    --nav-bg var(--fade), --nav-icon var(--fade), --hero-a var(--fade),
    --hero-b var(--fade), --hero-text var(--fade), --wir-bg var(--fade),
    --wir-fg var(--fade), --a-bg var(--fade), --a-fg var(--fade),
    --b-bg var(--fade), --b-fg var(--fade);
}

[data-phase="morning"] {
  --bg: #FDF1E6; --surface: #FFFFFF; --line: #F4E2D2;
  --text: #4A2E2A; --text-soft: #B57C64; --accent: #E08A5A;
  --nav-bg: #FFFFFF; --nav-icon: #D8C2B4;
  --hero-a: #FFD3A8; --hero-b: #F7B9A0; --hero-text: #5A2E1A;
  --wir-bg: #FCE0CF; --wir-fg: #8A3B22; --a-bg: #EDE2F5; --a-fg: #5B3D7A; --b-bg: #F7EACB; --b-fg: #7A5418;
}
[data-phase="day"] {
  --bg: #FBF4EC; --surface: #FFFFFF; --line: #F0E4D8;
  --text: #4A2E2A; --text-soft: #A0716A; --accent: #C86E56;
  --nav-bg: #FFFFFF; --nav-icon: #C9B3A8;
  --hero-a: #F7B9A0; --hero-b: #C9A7D9; --hero-text: #3B2233;
  --wir-bg: #F9DDD2; --wir-fg: #8A3B22; --a-bg: #E7DDF3; --a-fg: #5B3D7A; --b-bg: #F5E6C8; --b-fg: #7A5418;
}
[data-phase="evening"] {
  --bg: #4B3352; --surface: #5C4064; --line: #6C4F74;
  --text: #F6E6EC; --text-soft: #E3A9A0; --accent: #FFB59A;
  --nav-bg: #3E2A45; --nav-icon: #8C6D8F;
  --hero-a: #E8836B; --hero-b: #A6639A; --hero-text: #FFF1EC;
  --wir-bg: #7A4A5E; --wir-fg: #FFD2C2; --a-bg: #634A80; --a-fg: #E3D0F7; --b-bg: #7A5A48; --b-fg: #FBE2B8;
}
[data-phase="night"] {
  --bg: #17162E; --surface: #222140; --line: #2E2D52;
  --text: #E8E4F5; --text-soft: #8C8FB8; --accent: #F2C9A0;
  --nav-bg: #100F22; --nav-icon: #4B4A75;
  --hero-a: #2B2A55; --hero-b: #3D2C55; --hero-text: #F2C9A0;
  --wir-bg: #3A2A3E; --wir-fg: #F2A98E; --a-bg: #2E2850; --a-fg: #C3A8E8; --b-bg: #3A3324; --b-fg: #F0D29A;
}

* { box-sizing: border-box; }
/* Keine sichtbaren Scrollbalken (Scrollen geht weiterhin per Wischen, Mausrad und Tastatur) */
* { scrollbar-width: none; }
*::-webkit-scrollbar { display: none; }
[hidden] { display: none !important; } /* sonst überschreiben z. B. .field { display: flex } das Ausblenden */
html, body { margin: 0; }
body {
  min-height: 100dvh;
  background: var(--bg);
  color: var(--text);
  font: 400 16px/1.5 var(--font-body);
  -webkit-tap-highlight-color: transparent;
}
h1, h2, h3 { font-family: var(--font-head); font-weight: 400; margin: 0; }

.view {
  max-width: 520px;
  margin: 0 auto;
  padding: calc(20px + env(safe-area-inset-top)) 16px calc(96px + env(safe-area-inset-bottom));
  display: flex;
  flex-direction: column;
  gap: 14px;
}

/* Kopfbereich */
.eyebrow { font-size: 13px; color: var(--text-soft); }
.title { font-size: 30px; line-height: 1.15; }

/* Karten */
.card {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 14px 16px;
}
.card-head {
  display: flex; justify-content: space-between; align-items: baseline;
  margin-bottom: 4px;
}
.card-head h2 { font-size: 18px; }
.card-head .hint { font-size: 12px; color: var(--text-soft); }

/* Summenkarte (Fixkosten) im Himmelsverlauf */
.card.total {
  color: var(--hero-text);
  background: linear-gradient(135deg, var(--hero-a), var(--hero-b));
}
.card.total .eyebrow, .card.total .sub { color: inherit; opacity: .8; }
.card.total .big { font-family: var(--font-head); font-size: 34px; line-height: 1.1; }
.card.total .split { display: flex; flex-wrap: wrap; gap: 8px 16px; margin-top: 10px; font-size: 14px; }
.card.total .split .tag { margin-right: 6px; }

/* Listenzeilen */
.rows { list-style: none; margin: 0; padding: 0; }
.rows li {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 0;
  border-top: 1px solid var(--line);
}
.rows li:first-child { border-top: 0; }
.rows .main { flex: 1; min-width: 0; }
.rows .sub { font-size: 13px; color: var(--text-soft); }

.tag { font-size: 12px; font-weight: 600; padding: 2px 10px; border-radius: 99px; white-space: nowrap; }
.tag.wir { background: var(--wir-bg); color: var(--wir-fg); }
.tag.a   { background: var(--a-bg);   color: var(--a-fg); }
.tag.b   { background: var(--b-bg);   color: var(--b-fg); }

.tag       { background: var(--bg); color: var(--text-soft); }
.tag.warn  { background: var(--b-bg);   color: var(--b-fg); }
.tag.vegan { background: #DDEFD6; color: #2F5E28; }
[data-phase="evening"] .tag.vegan, [data-phase="night"] .tag.vegan { background: #2F4A2C; color: #C5EBB9; }
.tag .ico { width: 13px; height: 13px; vertical-align: -2px; margin-right: 3px; }
.vegan-check .card-head { align-items: center; }
.tag.bad   { background: var(--wir-bg); color: var(--wir-fg); }

/* Leerer Bereich */
.empty { text-align: center; padding: 40px 16px; }
.empty .icon { width: 44px; height: 44px; color: var(--accent); margin-bottom: 8px; }
.empty p { color: var(--text-soft); margin: 6px 0 0; }

/* Einstellungen */
.field { display: flex; flex-direction: column; gap: 6px; padding: 10px 0; border-top: 1px solid var(--line); }
.card-head + .field, .segmented + .field, .card-head + p + .field { border-top: 0; }
.field label { font-size: 13px; color: var(--text-soft); }
.field small { font-size: 12px; color: var(--text-soft); }
.field input:not([type="checkbox"]), .field select, .field textarea {
  font: inherit; color: var(--text);
  background: var(--bg); border: 1px solid var(--line); border-radius: 12px;
  padding: 10px 12px;
}
.segmented { display: flex; background: var(--bg); border-radius: 12px; padding: 4px; gap: 4px; }
.segmented button {
  flex: 1; font: inherit; font-size: 14px; color: var(--text-soft);
  background: transparent; border: 0; border-radius: 9px; padding: 8px 4px; cursor: pointer;
}
.segmented button[aria-pressed="true"] { background: var(--surface); color: var(--text); font-weight: 600; }
.info-line { display: flex; justify-content: space-between; align-items: center; gap: 12px; font-size: 14px; padding: 4px 0; }
.info-line span:first-child { color: var(--text-soft); }
.info-line .value { display: flex; align-items: center; gap: 2px; text-align: right; overflow-wrap: anywhere; }
.info-line small { color: var(--text-soft); margin-left: 4px; }
.info-list { margin-top: 12px; }

/* Untere Navigation */
.nav {
  position: fixed; left: 0; right: 0; bottom: 0;
  display: flex; justify-content: space-around;
  max-width: 520px; margin: 0 auto;
  padding: 8px 8px calc(8px + env(safe-area-inset-bottom));
  background: var(--nav-bg);
  border-radius: 22px 22px 0 0;
}
.nav a {
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  flex: 1; padding: 6px 0;
  color: var(--nav-icon); text-decoration: none; font-size: 11px;
}
.nav svg, .empty .icon {
  fill: none; stroke: currentColor; stroke-width: 1.8;
  stroke-linecap: round; stroke-linejoin: round;
}
.nav svg { width: 24px; height: 24px; }
.nav a[aria-current="page"] { color: var(--accent); font-weight: 700; }
.nav { z-index: 10; }

/* ---------- Bausteine ---------- */

.ico {
  width: 20px; height: 20px; flex: none;
  fill: none; stroke: currentColor; stroke-width: 1.8;
  stroke-linecap: round; stroke-linejoin: round;
}
.page-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 12px; }
.muted { color: var(--text-soft); margin: 4px 0; }
.small { font-size: 13px; }
.center { text-align: center; }
.loading { padding: 40vh 0; }
a { color: var(--accent); }
.card-head .hint { text-decoration: none; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  font: inherit; font-size: 15px; font-weight: 600;
  color: var(--text); background: var(--bg);
  border: 1px solid var(--line); border-radius: 99px;
  padding: 9px 16px; cursor: pointer; text-decoration: none;
}
.btn.primary { background: var(--accent); border-color: var(--accent); color: var(--surface); }
.btn.danger { color: var(--wir-fg); background: var(--wir-bg); border-color: transparent; }
.btn.small { font-size: 13px; padding: 6px 12px; }
.btn .ico { width: 18px; height: 18px; }
.empty .btn { margin-top: 14px; }
.link { font: inherit; color: var(--accent); background: none; border: 0; padding: 0; cursor: pointer; text-decoration: underline; }

.icon-btn {
  display: inline-flex; align-items: center; justify-content: center; flex: none;
  width: 40px; height: 40px; border-radius: 50%;
  color: var(--text); background: var(--surface); border: 0; cursor: pointer;
}
.icon-btn.accent { background: var(--accent); color: var(--surface); }
.icon-btn.subtle { width: 34px; height: 34px; background: transparent; color: var(--text-soft); }
.page-head .icon-btn { width: 44px; height: 44px; }

.actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.actions.center { justify-content: center; }

.back { display: inline-flex; align-items: center; gap: 2px; align-self: flex-start; color: var(--text-soft); text-decoration: none; font-size: 14px; margin-bottom: -8px; }
.back .ico { width: 18px; height: 18px; }

.banner { background: var(--wir-bg); color: var(--wir-fg); border-radius: 14px; padding: 10px 14px; font-size: 14px; }
.summary-line { display: flex; align-items: center; gap: 6px; font-size: 14px; color: var(--text-soft); padding: 0 4px; }
.summary-line .ico { width: 16px; height: 16px; }

/* Zeilen */
.rows li.tap { cursor: pointer; }
.rows li.done .main { color: var(--text-soft); text-decoration: line-through; }
.row-link { display: flex; align-items: center; gap: 10px; flex: 1; min-width: 0; color: inherit; text-decoration: none; }
.row-link > .ico { color: var(--text-soft); width: 18px; }
.row-link.plain .main { color: var(--text); }
.rows .days, .rows .amount { font-weight: 700; color: var(--accent); white-space: nowrap; text-align: right; }
.rows .amount { color: var(--text); }
.rows .fav { color: var(--accent); display: flex; }
.menu-icon { display: flex; align-items: center; justify-content: center; width: 38px; height: 38px; border-radius: 12px; background: var(--bg); color: var(--accent); }
.card.faded { opacity: .75; }

/* Abhak-Kreis */
.tick {
  display: flex; align-items: center; justify-content: center; flex: none;
  width: 24px; height: 24px; border-radius: 50%;
  border: 2px solid var(--line); color: var(--surface);
}
.done .tick { background: var(--accent); border-color: var(--accent); }
.tick .ico { width: 16px; height: 16px; stroke-width: 3; }

/* Schnell-Eingabe Einkauf */
.quick { display: flex; gap: 8px; align-items: center; padding: 8px; }
.quick input, .quick select, .search input {
  font: inherit; color: var(--text); background: var(--bg);
  border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; min-width: 0;
}
.quick input { flex: 1; }
.quick select { width: 118px; font-size: 14px; }

.search { display: flex; align-items: center; gap: 8px; padding: 8px 12px; color: var(--text-soft); }
.search input { flex: 1; border: 0; background: transparent; padding: 6px 0; outline: none; }

/* Chips */
.chips { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.chips-label { font-size: 13px; color: var(--text-soft); margin-right: 4px; }
.chip {
  display: inline-flex; align-items: center; gap: 4px;
  font: inherit; font-size: 13px; color: var(--text);
  background: var(--surface); border: 0; border-radius: 99px; padding: 6px 12px; cursor: pointer;
}
.chip .ico { width: 14px; height: 14px; color: var(--accent); }
.chip.on { background: var(--accent); color: var(--surface); }
.chip.on .ico { color: inherit; }

/* Reiter als Links */
.segmented a {
  flex: 1; text-align: center; font-size: 14px; color: var(--text-soft);
  text-decoration: none; border-radius: 9px; padding: 8px 4px;
}
.segmented a[aria-current="page"] { background: var(--surface); color: var(--text); font-weight: 600; }

/* Rezepte */
.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.steps { margin: 0; padding-left: 22px; }
.steps li { padding: 6px 0; }
.note { white-space: pre-wrap; margin: 8px 0 0; font-size: 14px; }
.group-title { font-size: 16px; color: var(--text-soft); margin: 6px 4px -4px; font-family: var(--font-body); font-weight: 600; }
details summary { cursor: pointer; font-size: 14px; color: var(--text-soft); padding: 6px 0; }

/* Schalter */
.field.check { flex-direction: row; align-items: center; justify-content: space-between; gap: 12px; }
.field.check span { display: flex; flex-direction: column; }
.switch {
  appearance: none; flex: none; position: relative; cursor: pointer;
  width: 46px; height: 28px; border-radius: 99px; margin: 0;
  background: var(--line); transition: background .2s;
}
.switch::after {
  content: ""; position: absolute; top: 3px; left: 3px;
  width: 22px; height: 22px; border-radius: 50%; background: var(--surface);
  transition: transform .2s;
}
.switch:checked { background: var(--accent); }
.switch:checked::after { transform: translateX(18px); }

/* Formular-Blatt */
.sheet-backdrop {
  position: fixed; inset: 0; z-index: 50;
  display: flex; align-items: flex-end; justify-content: center;
  background: rgba(20, 12, 24, .45);
  animation: fade .2s ease;
}
.sheet {
  width: 100%; max-width: 520px; max-height: 92dvh; overflow-y: auto;
  background: var(--surface); color: var(--text);
  border-radius: 24px 24px 0 0;
  padding: 8px 18px calc(18px + env(safe-area-inset-bottom));
  animation: up .25s ease;
}
.sheet h2 { font-size: 22px; margin: 4px 0 8px; }
.sheet .field { border-top: 0; padding: 6px 0; }
.sheet-grip { width: 40px; height: 4px; border-radius: 4px; background: var(--line); margin: 4px auto 10px; }
.sheet-actions { display: flex; gap: 8px; margin-top: 14px; }
.sheet-actions .spacer { flex: 1; }
.field textarea { resize: vertical; }
::placeholder { color: var(--text-soft); opacity: .7; }
.form-error { color: var(--wir-fg); background: var(--wir-bg); border-radius: 10px; padding: 8px 12px; font-size: 14px; }
.clamp { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; }
.thumb { width: 48px; height: 48px; flex: none; object-fit: contain; border-radius: 10px; background: #fff; }
.sheet-image { display: block; max-width: 100%; max-height: 180px; margin: 0 auto 6px; object-fit: contain; border-radius: 14px; background: #fff; }
.btn:disabled { opacity: .6; cursor: progress; }
.btn.manual { width: 100%; margin: 4px 0 6px; }
.btn.wide { width: 100%; margin-top: 10px; }

/* Startbildschirm (Anmeldung) */
body.logged-out .nav { display: none; }
body.logged-out .view { padding-bottom: calc(24px + env(safe-area-inset-bottom)); }
.auth-screen { display: flex; flex-direction: column; gap: 14px; padding-top: 6vh; }
.auth-logo { width: 84px; height: 84px; margin: 0 auto; border-radius: 22px; }
.auth-title { font-size: 40px; text-align: center; }
.auth-screen > .muted { margin: -8px 16px 6px; }
.auth-form .field:first-child { border-top: 0; }
.auth-form .field { border-top: 0; padding: 6px 0; }
.card.center { text-align: center; }
.card.center h2 { margin-bottom: 6px; }
.center-link { display: block; margin: 12px auto 0; font-size: 14px; }
/* Unterwegs */
.btn.big { width: 100%; padding: 14px 18px; font-size: 17px; margin: 6px 0 4px; }
.btn.big .ico { width: 22px; height: 22px; }
.card h2 .ico { width: 20px; height: 20px; vertical-align: -3px; margin-right: 4px; }
.card p { margin: 4px 0; }
.card .link.small { display: inline-flex; align-items: center; gap: 6px; margin-top: 8px; font-size: 14px; }
.card .link .ico { width: 16px; height: 16px; }
.trip-alert { color: var(--hero-text); background: linear-gradient(135deg, var(--hero-a), var(--hero-b)); }
.trip-alert .muted, .trip-alert .hint { color: inherit; opacity: .85; }
.trip-alert .btn { margin-top: 6px; }
.map-card { padding: 6px; }
.map-slot, .map { height: 52vh; min-height: 280px; border-radius: 14px; overflow: hidden; }
.map-slot { display: flex; align-items: center; justify-content: center; background: var(--bg); }
.map { position: relative; z-index: 0; } /* eigene Ebene, damit die Karte nicht über der Leiste liegt */
/* Karte: Farben kommen aus js/karte.js (je Tageszeit). Hier nur der Quellenhinweis, möglichst unauffällig */
.map { background: var(--bg); }
.map .maplibregl-ctrl-attrib { font-size: 10px; background: transparent !important; color: var(--text-soft); }
.map .maplibregl-ctrl-attrib a { color: inherit; }
.map .maplibregl-ctrl-attrib-button { opacity: .5; filter: grayscale(1); }
.pin {
  display: flex; align-items: center; justify-content: center;
  width: 38px; height: 38px; border-radius: 50%;
  font: 700 16px var(--font-body); color: #fff;
  border: 3px solid #fff; box-shadow: 0 2px 8px rgba(0, 0, 0, .35);
}
.pin.a { background: #7E5BA8; }
.pin.b { background: #D08A3A; }
.pin.stale { opacity: .55; filter: grayscale(.6); }
.pin.home { width: 30px; height: 30px; background: var(--surface); color: var(--accent); border-color: var(--accent); }
.pin.home .ico { width: 16px; height: 16px; }
.gpin { position: absolute; transform: translate(-50%, -50%); }
.head-tools { display: flex; gap: 8px; }
.sub.nr { display: flex; align-items: center; gap: 2px; }
.icon-btn.mini { width: 26px; height: 26px; }
.icon-btn.mini .ico { width: 15px; height: 15px; }

/* Zeitstrahl: Auto fährt von "los" bis nach Hause. --pos läuft weich von --from nach --to. */
@property --pos { syntax: "<number>"; inherits: true; initial-value: 0; }
.trip-line { --pos: var(--to); position: relative; height: 40px; margin: 10px 2px 0; }
.trip-line.move { animation: tl-drive 1.8s cubic-bezier(.45, 0, .2, 1) both; }
.trip-line.enter { animation: tl-drive 2.4s cubic-bezier(.45, 0, .2, 1) .5s both; }
@keyframes tl-drive { from { --pos: var(--from); } to { --pos: var(--to); } }
.tl-track {
  position: absolute; left: 8px; right: 14px; top: 26px; height: 6px; border-radius: 6px;
  background: repeating-linear-gradient(90deg, var(--line) 0 10px, transparent 10px 18px);
  animation: tl-road 1.2s linear infinite;
}
.trip-alert .tl-track { background: repeating-linear-gradient(90deg, rgba(255, 255, 255, .55) 0 10px, transparent 10px 18px); }
.trip-line.enter .tl-track { animation: tl-grow .7s ease-out both, tl-road 1.2s linear infinite; }
@keyframes tl-road { to { background-position: -18px 0; } }
@keyframes tl-grow { from { clip-path: inset(0 100% 0 0); } to { clip-path: inset(0 0 0 0); } }
.tl-fill {
  position: absolute; inset: 0 auto 0 0; width: calc(var(--pos) * 100%); border-radius: 6px;
  background: linear-gradient(90deg, var(--hero-a), var(--accent));
}
.trip-alert .tl-fill { background: currentColor; opacity: .85; }
.tl-start { position: absolute; left: 2px; top: 23px; width: 12px; height: 12px; border-radius: 50%; background: var(--accent); }
.trip-alert .tl-start { background: currentColor; }
.tl-end { position: absolute; right: 0; top: 17px; color: var(--accent); }
.trip-alert .tl-end { color: inherit; }
.tl-end .ico { width: 22px; height: 22px; }
.tl-car {
  position: absolute; top: 0; left: calc(8px + var(--pos) * (100% - 22px - 30px));
  width: 30px; height: 30px; display: flex; color: var(--text);
  animation: tl-bump .45s ease-in-out infinite alternate;
}
.trip-alert .tl-car { color: inherit; }
.tl-car .ico { width: 30px; height: 30px; stroke-width: 1.7; }
.trip-line.enter .tl-car { animation: tl-pop .5s ease-out both, tl-bump .45s ease-in-out .5s infinite alternate; }
@keyframes tl-bump { to { transform: translateY(-2px); } }
@keyframes tl-pop { from { transform: scale(0); opacity: 0; } }
.trip-line.no-home .tl-car { animation: tl-bump .45s ease-in-out infinite alternate; }
.tl-labels { display: flex; justify-content: space-between; font-size: 12px; color: var(--text-soft); margin: 2px 2px 6px; }
.trip-alert .tl-labels { color: inherit; opacity: .85; }
@media (prefers-reduced-motion: reduce) {
  .trip-line, .tl-track, .tl-car { animation: none !important; }
}
.eta { display: flex; align-items: center; gap: 6px; font-weight: 600; color: var(--accent); }
.trip-alert .eta { color: inherit; }
.eta .ico { width: 18px; height: 18px; }

.lock-button {
  display: flex; align-items: center; justify-content: center;
  width: 96px; height: 96px; margin: 18px auto 6px; border-radius: 50%;
  border: 0; cursor: pointer; color: var(--hero-text);
  background: linear-gradient(135deg, var(--hero-a), var(--hero-b));
}
.lock-button .ico { width: 52px; height: 52px; stroke-width: 1.5; }
.lock-button:disabled { opacity: .6; }
/* Liegt genau über dem Fingerabdrucksensor im Display (Position siehe Einstellungen) */
.lock-button.sensor { position: fixed; margin: 0; transform: translate(-50%, -50%); z-index: 20; box-shadow: 0 0 0 10px color-mix(in srgb, var(--accent) 18%, transparent); }

/* Sensor einmessen */
.calibrate {
  position: fixed; inset: 0; z-index: 70; display: flex; flex-direction: column; align-items: center;
  padding: calc(40px + env(safe-area-inset-top)) 24px; text-align: center;
  background: var(--bg); color: var(--text); cursor: crosshair;
}
.calibrate h2 { font-size: 24px; margin-bottom: 8px; }
.calibrate .ghost { position: fixed; width: 96px; height: 96px; border-radius: 50%; transform: translate(-50%, -50%); border: 2px dashed var(--accent); opacity: .6; pointer-events: none; }
.calibrate .btn { margin-top: 18px; }
.qr { display: flex; justify-content: center; padding: 8px 0; }
.qr svg { width: 240px; height: 240px; background: #fff; border-radius: 12px; }

.toast {
  position: fixed; left: 50%; bottom: calc(96px + env(safe-area-inset-bottom)); z-index: 60;
  transform: translateX(-50%);
  background: var(--text); color: var(--bg);
  padding: 10px 18px; border-radius: 99px; font-size: 14px;
  animation: fade .2s ease;
}

@keyframes fade { from { opacity: 0; } }
@keyframes up { from { transform: translateY(40px); opacity: .6; } }
