/* ALMAS Webdesign-System v2 · hell/premium, fest hell · Passkey-Testplattform
   Desktop: helle Sidebar + Arbeitsfläche · Handy (< 860 px): eigene Oberfläche mit Kopfzeile, Karten,
   Bottom-Nav, Bottom-Sheet (Wischen schließt) und FAB. */
:root {
  color-scheme: light;
  --rot: #FF2325; --rot-text: #D81020; --rot-hover: #B80D1A; --rot-zart: rgba(255, 35, 37, .08);
  --text: #1d1d1f; --text-2: #5f5f66; --text-3: #6b6b71; --schwarz: #1d1d1f;
  --flaeche: #f5f5f7; --karte: #ffffff; --linie: #e6e6eb; --linie-2: #d2d2d7; --weiss: #ffffff;
  --gruen: #147A3D; --gruen-bg: #E9F6EE; --amber: #9A5B00; --amber-bg: #FFF4E0; --blau: #0057B8; --blau-bg: #E8F1FC;
  --teal: #0E7C73; --teal-bg: #E5F5F3; --rot-bg: #FDECEC; --grau-bg: #F0F0F3;
  --schatten-1: 0 1px 2px rgba(17, 17, 26, .04), 0 1px 1px rgba(17, 17, 26, .03);
  --schatten-2: 0 2px 6px rgba(17, 17, 26, .05), 0 8px 24px rgba(17, 17, 26, .06);
  --schatten-3: 0 12px 32px rgba(17, 17, 26, .10), 0 4px 12px rgba(17, 17, 26, .06);
  --r-s: 10px; --r-m: 14px; --r-l: 20px; --r-xl: 26px;
  --schrift: 'Helvetica Neue', Helvetica, -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
  --mono: ui-monospace, 'SF Mono', Menlo, Consolas, monospace;
  --dauer: 180ms; --feder: cubic-bezier(.2, .8, .2, 1);
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; min-height: 100vh; min-height: 100dvh; font-family: var(--schrift); color: var(--text); background: var(--flaeche); font-size: 15px; line-height: 1.5; -webkit-font-smoothing: antialiased; overflow-x: hidden; }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--rot-text); }
h1, h2, h3 { text-wrap: balance; margin: 0; line-height: 1.2; letter-spacing: -.01em; }
p { margin: 0; text-wrap: pretty; }
:focus-visible { outline: 3px solid rgba(216, 16, 32, .4); outline-offset: 2px; border-radius: 8px; }
[tabindex="-1"]:focus { outline: none; }
.zahl { font-variant-numeric: tabular-nums; }
.mono { font-family: var(--mono); font-size: .92em; }
.leise { color: var(--text-2); }
.klein { font-size: 13px; }
.ueber { font-size: 12px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--text-3); }
.gross { font-size: 22px; font-weight: 700; letter-spacing: -.01em; }
.versteckt { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.sprung { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--karte); padding: 10px 16px; border-radius: 999px; box-shadow: var(--schatten-2); }
.sprung:focus { top: 12px; }

/* Knöpfe, Badges, Schalter */
.knopf { text-decoration: none; display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; border: 1px solid var(--linie-2); background: var(--karte); color: var(--text);
  border-radius: 999px; padding: 10px 18px; font-weight: 600; font-size: 14px; cursor: pointer; transition: transform var(--dauer) var(--feder), box-shadow var(--dauer), background var(--dauer), opacity var(--dauer); white-space: nowrap; }
.knopf:hover:not(:disabled) { box-shadow: var(--schatten-2); transform: translateY(-1px); }
.knopf:active:not(:disabled) { transform: scale(.97); }
.knopf:disabled { opacity: .45; cursor: not-allowed; }
.knopf.haupt { background: var(--rot-text); border-color: var(--rot-text); color: var(--weiss); box-shadow: 0 4px 14px rgba(216, 16, 32, .25); }
.knopf.haupt:hover:not(:disabled) { background: var(--rot-hover); }
.knopf.dunkel { background: var(--schwarz); border-color: var(--schwarz); color: var(--weiss); }
.knopf.leicht { border-color: transparent; background: transparent; color: var(--text-2); }
.knopf.leicht:hover:not(:disabled) { background: var(--grau-bg); box-shadow: none; }
.knopf.gefahr { color: var(--rot-text); border-color: rgba(216, 16, 32, .35); }
.knopf.klein { min-height: 36px; padding: 6px 14px; font-size: 13px; }
.knopf.breit { width: 100%; }
.knopf.gross-k { min-height: 54px; font-size: 16px; }
.knopf .ico { width: 20px; height: 20px; flex: none; }
.knopf[aria-busy="true"] { pointer-events: none; }
.knopf[aria-busy="true"]::after { content: ''; width: 16px; height: 16px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; animation: dreh .7s linear infinite; }
.knopfreihe { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.textknopf { border: 0; background: none; padding: 6px 2px; min-height: 36px; color: var(--rot-text); cursor: pointer; font-size: 14px; font-weight: 600; }
.textknopf:hover { text-decoration: underline; }
.ico { width: 20px; height: 20px; flex: none; }

.badge { display: inline-flex; align-items: center; gap: 5px; border-radius: 999px; padding: 3px 10px; font-size: 12px; font-weight: 600; white-space: nowrap; line-height: 1.4; }
.badge::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; opacity: .8; }
.badge.ohne::before { display: none; }
.badge.gruen { color: var(--gruen); background: var(--gruen-bg); }
.badge.amber { color: var(--amber); background: var(--amber-bg); }
.badge.blau { color: var(--blau); background: var(--blau-bg); }
.badge.rot { color: var(--rot-text); background: var(--rot-bg); }
.badge.grau { color: var(--text-2); background: var(--grau-bg); }
.badge.teal { color: var(--teal); background: var(--teal-bg); }
.schalter { position: relative; width: 48px; height: 30px; flex: none; border-radius: 999px; background: var(--linie-2); border: 0; cursor: pointer; transition: background var(--dauer); }
.schalter::after { content: ''; position: absolute; top: 3px; left: 3px; width: 24px; height: 24px; border-radius: 50%; background: var(--weiss); box-shadow: 0 2px 6px rgba(0, 0, 0, .2); transition: transform var(--dauer) var(--feder); }
.schalter[aria-checked="true"] { background: var(--gruen); }
.schalter[aria-checked="true"]::after { transform: translateX(18px); }

/* Felder */
.feld { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.feld > label { font-size: 13px; font-weight: 700; color: var(--text-2); }
.eingabe { border: 1px solid var(--linie-2); border-radius: var(--r-m); padding: 12px 14px; background: var(--weiss); min-width: 0; width: 100%; font-size: 16px; min-height: 48px; transition: border-color var(--dauer), box-shadow var(--dauer); }
.eingabe:focus { outline: none; border-color: var(--rot-text); box-shadow: 0 0 0 4px var(--rot-zart); }
.eingabe[aria-invalid="true"] { border-color: var(--rot-text); }
.formular { display: grid; gap: 14px; }
.meldung { border-radius: var(--r-m); padding: 12px 14px; font-size: 14px; display: flex; gap: 10px; align-items: flex-start; }
.meldung:empty { display: none; }
.meldung.fehler { background: var(--rot-bg); color: #8f0a15; }
.meldung.info { background: var(--blau-bg); color: #0b3f7d; }
.meldung.ok { background: var(--gruen-bg); color: #0d5229; }
.meldung.warn { background: var(--amber-bg); color: #6b3f00; }
.regeln { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; font-size: 13px; }
.regeln li { display: flex; gap: 8px; align-items: center; color: var(--text-2); }
.regeln li::before { content: ''; width: 16px; height: 16px; border-radius: 50%; border: 2px solid var(--linie-2); flex: none; transition: background var(--dauer), border-color var(--dauer); }
.regeln li.ok { color: var(--gruen); }
.regeln li.ok::before { border-color: var(--gruen); background: var(--gruen) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4 8.5l2.5 2.5L12 5.5' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/12px no-repeat; }
.regeln li.nein { color: var(--rot-text); }
.regeln li.nein::before { border-color: var(--rot-text); }

/* Laden */
.lade { min-height: 100vh; display: grid; place-content: center; justify-items: center; gap: 12px; color: var(--text-2); }
.lade-baer, .baer { background: url(/baer.png) center/contain no-repeat; }
.lade-baer { width: 92px; height: 60px; animation: puls 1.4s ease-in-out infinite; }
.skelett { background: linear-gradient(90deg, var(--grau-bg) 0%, #f8f8fa 50%, var(--grau-bg) 100%); background-size: 200% 100%; animation: schimmer 1.2s linear infinite; border-radius: var(--r-m); min-height: 90px; }

/* ---------- Anmeldeseite ---------- */
.anmelde-huelle { min-height: 100vh; min-height: 100dvh; display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); }
.marke { position: relative; overflow: hidden; background: linear-gradient(160deg, #ffffff 0%, #fbf1f1 55%, #f7e3e4 100%); padding: 48px clamp(28px, 5vw, 72px); display: flex; flex-direction: column; justify-content: space-between; gap: 32px; border-right: 1px solid var(--linie); }
.marke .baer { width: 150px; height: 97px; filter: drop-shadow(0 10px 22px rgba(216, 16, 32, .18)); animation: rein .6s var(--feder) both; }
.marke h1 { font-size: clamp(30px, 3.4vw, 44px); max-width: 15ch; animation: rein .6s .08s var(--feder) both; }
.marke .unter { font-size: 17px; color: var(--text-2); max-width: 44ch; margin-top: 12px; animation: rein .6s .14s var(--feder) both; }
.marke-punkte { list-style: none; padding: 0; margin: 0; display: grid; gap: 14px; animation: rein .6s .2s var(--feder) both; }
.marke-punkte li { display: flex; gap: 12px; align-items: flex-start; font-size: 15px; }
.marke-punkte .punkt { width: 34px; height: 34px; border-radius: 11px; background: var(--karte); box-shadow: var(--schatten-2); display: grid; place-items: center; flex: none; color: var(--rot-text); }
.marke-punkte b { display: block; }
.baerwelle { position: absolute; right: -130px; bottom: -130px; width: 440px; height: 440px; background: url(/baer.png) center/contain no-repeat; opacity: .13; transform: rotate(-12deg); pointer-events: none; animation: schweben 16s ease-in-out infinite; }
.anmelde-seite { display: grid; place-items: center; padding: 40px 24px; min-width: 0; }
.anmelde-karte { width: min(440px, 100%); background: var(--karte); border-radius: var(--r-xl); box-shadow: var(--schatten-3); padding: 34px 30px; display: grid; gap: 20px; animation: rein .5s .1s var(--feder) both; min-width: 0; }
.anmelde-karte h2 { font-size: 26px; }
.test-plakette { display: inline-flex; align-self: start; justify-self: start; }
.trenner { display: flex; align-items: center; gap: 12px; color: var(--text-3); font-size: 13px; }
.trenner::before, .trenner::after { content: ''; flex: 1; height: 1px; background: var(--linie); }
.passkey-knopf .ico { width: 24px; height: 24px; }
.hinweis-qr { display: flex; gap: 12px; align-items: flex-start; background: var(--flaeche); border-radius: var(--r-m); padding: 12px 14px; font-size: 13px; color: var(--text-2); }
.hinweis-qr .ico { color: var(--text); margin-top: 1px; }
.wechsel { display: flex; flex-wrap: wrap; gap: 4px 16px; justify-content: center; }
.app-ziel { display: flex; align-items: center; gap: 10px; background: var(--blau-bg); color: #0b3f7d; border-radius: var(--r-m); padding: 10px 14px; font-size: 14px; }
.schritte { display: flex; gap: 6px; }
.schritte i { height: 4px; flex: 1; border-radius: 4px; background: var(--linie); transition: background .3s; }
.schritte i.an { background: var(--rot-text); }
.codes { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin: 0; padding: 0; list-style: none; }
.codes li { font-family: var(--mono); font-size: 15px; letter-spacing: .06em; background: var(--flaeche); border-radius: var(--r-s); padding: 10px; text-align: center; }
.erfolg-kreis { width: 64px; height: 64px; border-radius: 50%; background: var(--gruen-bg); color: var(--gruen); display: grid; place-items: center; animation: plopp .5s var(--feder) both; }
.erfolg-kreis .ico { width: 32px; height: 32px; }

/* ---------- Konto: Rahmen ---------- */
.rahmen { display: grid; grid-template-columns: 264px minmax(0, 1fr); min-height: 100vh; }
.seitenleiste { position: sticky; top: 0; height: 100vh; background: var(--karte); border-right: 1px solid var(--linie); padding: 22px 16px; display: flex; flex-direction: column; gap: 22px; }
.logo { display: flex; align-items: center; gap: 10px; padding: 0 8px; text-decoration: none; color: var(--text); }
.logo .baer { width: 50px; height: 34px; flex: none; }
.logo b { display: block; font-size: 15px; }
.logo small { color: var(--text-3); font-size: 12px; }
.nav { display: grid; gap: 2px; }
.nav a { display: flex; align-items: center; gap: 12px; padding: 11px 12px; border-radius: 12px; color: var(--text-2); text-decoration: none; font-weight: 600; transition: background var(--dauer), color var(--dauer); position: relative; }
.nav a:hover { background: var(--flaeche); color: var(--text); }
.nav a[aria-current="page"] { background: var(--rot-zart); color: var(--rot-text); }
.nav .zaehler { margin-left: auto; min-width: 22px; height: 22px; border-radius: 999px; background: var(--rot-text); color: var(--weiss); font-size: 12px; display: grid; place-items: center; padding: 0 6px; }
.seitenleiste .person { margin-top: auto; display: flex; gap: 10px; align-items: center; padding: 12px; border-radius: var(--r-m); background: var(--flaeche); min-width: 0; }
.avatar { width: 38px; height: 38px; border-radius: 50%; background: linear-gradient(135deg, #ff5a5c, var(--rot-text)); color: var(--weiss); display: grid; place-items: center; font-weight: 700; flex: none; font-size: 14px; }
.person .wer { min-width: 0; }
.person .wer b, .person .wer span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.person .wer span { font-size: 12px; color: var(--text-3); }
.version { font-size: 12px; color: var(--text-3); padding: 0 8px; }
.inhalt { padding: 32px clamp(20px, 3.5vw, 48px) 64px; min-width: 0; max-width: 1180px; width: 100%; }
.seitenkopf { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 22px; }
.seitenkopf h1 { font-size: 30px; }
.seitenkopf p { color: var(--text-2); margin-top: 6px; max-width: 64ch; }
.raster { display: grid; gap: 18px; grid-template-columns: repeat(12, minmax(0, 1fr)); }
.s12 { grid-column: span 12; } .s8 { grid-column: span 8; } .s7 { grid-column: span 7; } .s6 { grid-column: span 6; } .s5 { grid-column: span 5; } .s4 { grid-column: span 4; }
.karte { background: var(--karte); border-radius: var(--r-l); box-shadow: var(--schatten-2); padding: 22px; min-width: 0; }
.karte > h2 { font-size: 18px; margin-bottom: 4px; }
.karte > .unterzeile { color: var(--text-2); font-size: 14px; margin-bottom: 16px; }
.kartenkopf { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.kartenkopf h2 { font-size: 18px; }
.rein { animation: rein .45s var(--feder) both; }
.raster > :nth-child(2) { animation-delay: .05s; } .raster > :nth-child(3) { animation-delay: .1s; } .raster > :nth-child(4) { animation-delay: .15s; } .raster > :nth-child(5) { animation-delay: .2s; } .raster > :nth-child(6) { animation-delay: .25s; }

/* Sicherheitsstand */
@property --wert { syntax: '<number>'; inherits: false; initial-value: 0; }
.stand { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 24px; align-items: start; }
.ring { --wert: 0; width: 132px; height: 132px; border-radius: 50%; display: grid; place-items: center; position: relative;
  background: conic-gradient(var(--ring-farbe, var(--gruen)) calc(var(--wert) * 1%), var(--grau-bg) 0); animation: ringauf 1.1s .15s var(--feder) both; }
.ring::before { content: ''; position: absolute; inset: 12px; border-radius: 50%; background: var(--karte); }
.ring span { position: relative; text-align: center; }
.ring b { display: block; font-size: 30px; line-height: 1; }
.ring small { color: var(--text-3); font-size: 12px; }
.pruefliste { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.pruefliste li { display: flex; gap: 12px; align-items: flex-start; padding: 10px 12px; border-radius: var(--r-m); transition: background var(--dauer); flex-wrap: wrap; }
.pruefliste li:hover { background: var(--flaeche); }
.pruefliste .zeichen { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; flex: none; }
.pruefliste .zeichen .ico { width: 15px; height: 15px; }
.pruefliste .ok .zeichen { background: var(--gruen-bg); color: var(--gruen); }
.pruefliste .offen .zeichen { background: var(--amber-bg); color: var(--amber); }
.pruefliste .text { flex: 1; min-width: 240px; }
.pruefliste li > .knopf { margin-left: 38px; }
.pruefliste .text b { display: block; font-size: 14px; }
.pruefliste .text span { font-size: 13px; color: var(--text-2); }

/* Hinweis neue Anmeldung */
.alarm { display: flex; gap: 14px; align-items: flex-start; background: var(--amber-bg); border-radius: var(--r-l); padding: 16px 18px; flex-wrap: wrap; animation: rein .45s var(--feder) both; }
.alarm .ico { color: var(--amber); width: 24px; height: 24px; margin-top: 2px; }
.alarm .text { flex: 1; min-width: 200px; }
.alarm .text b { display: block; }

/* Geräte */
.geraete { display: grid; gap: 14px; }
.geraet { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 16px; align-items: start; padding: 18px; border-radius: var(--r-l); background: var(--karte); box-shadow: var(--schatten-2); animation: rein .45s var(--feder) both; transition: transform var(--dauer), box-shadow var(--dauer), opacity .3s; }
.geraet.weg { opacity: 0; transform: translateX(30px); }
.geraet .symbol { width: 48px; height: 48px; border-radius: 14px; background: var(--flaeche); display: grid; place-items: center; color: var(--text); }
.geraet.dieses .symbol { background: var(--rot-zart); color: var(--rot-text); }
.geraet .symbol .ico { width: 24px; height: 24px; }
.geraet h3 { font-size: 16px; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.geraet .daten { display: flex; flex-wrap: wrap; gap: 4px 16px; color: var(--text-2); font-size: 13px; margin-top: 4px; }
.geraet .daten span { white-space: nowrap; }
.laufzeit { margin-top: 12px; display: grid; gap: 6px; }
.laufzeit .leiste { height: 6px; border-radius: 6px; background: var(--grau-bg); overflow: hidden; }
.laufzeit .leiste i { display: block; height: 100%; border-radius: 6px; background: linear-gradient(90deg, var(--gruen), #2fa35c); transform-origin: left; animation: wachsen .8s var(--feder) both; }
.laufzeit small { font-size: 12px; color: var(--text-3); }
.app-chips { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 10px; }
.app-chip { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; background: var(--flaeche); border-radius: 999px; padding: 4px 10px 4px 4px; }
.app-chip i { width: 18px; height: 18px; border-radius: 6px; background: var(--app, var(--blau)); color: #fff; font-style: normal; display: grid; place-items: center; font-size: 10px; }

/* Apps */
.apps { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.app-karte { display: grid; gap: 10px; padding: 18px; border-radius: var(--r-l); background: var(--karte); box-shadow: var(--schatten-2); text-decoration: none; color: var(--text); transition: transform var(--dauer) var(--feder), box-shadow var(--dauer); }
.app-karte:hover { transform: translateY(-2px); box-shadow: var(--schatten-3); }
.app-logo { width: 44px; height: 44px; border-radius: 13px; background: var(--app, var(--blau)); color: #fff; display: grid; place-items: center; font-weight: 700; font-size: 18px; box-shadow: 0 6px 16px rgba(0, 0, 0, .12); }
.app-karte h3 { font-size: 16px; }

/* Passkeys */
.passkeys { display: grid; gap: 12px; }
.passkey { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 14px; align-items: start; padding: 16px; border-radius: var(--r-l); border: 1px solid var(--linie); background: var(--karte); }
.passkey .symbol { width: 44px; height: 44px; border-radius: 13px; background: var(--rot-zart); color: var(--rot-text); display: grid; place-items: center; }
.passkey h3 { font-size: 15px; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.passkey .daten { color: var(--text-2); font-size: 13px; display: flex; flex-wrap: wrap; gap: 2px 14px; margin-top: 2px; }

/* Aktivität */
.zeitleiste { list-style: none; margin: 0; padding: 0; display: grid; }
.zeitleiste li { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 14px; padding: 14px 4px; border-bottom: 1px solid var(--linie); align-items: start; }
.zeitleiste li:last-child { border-bottom: 0; }
.zeitleiste .punkt { width: 34px; height: 34px; border-radius: 11px; display: grid; place-items: center; background: var(--flaeche); color: var(--text-2); }
.zeitleiste .punkt .ico { width: 18px; height: 18px; }
.zeitleiste .punkt.rot { background: var(--rot-bg); color: var(--rot-text); }
.zeitleiste .punkt.gruen { background: var(--gruen-bg); color: var(--gruen); }
.zeitleiste .punkt.amber { background: var(--amber-bg); color: var(--amber); }
.zeitleiste b { display: block; font-size: 14px; }
.zeitleiste .wo { font-size: 13px; color: var(--text-2); }
.zeitleiste time { font-size: 12px; color: var(--text-3); white-space: nowrap; }
.filter { display: inline-flex; background: var(--grau-bg); border-radius: 999px; padding: 3px; gap: 2px; flex-wrap: wrap; }
.filter button { border: 0; background: transparent; border-radius: 999px; padding: 7px 14px; font-size: 13px; font-weight: 600; color: var(--text-2); cursor: pointer; min-height: 36px; }
.filter button[aria-pressed="true"] { background: var(--karte); color: var(--text); box-shadow: var(--schatten-1); }

/* Testauswertung */
.kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.kpi { background: var(--karte); border-radius: var(--r-l); box-shadow: var(--schatten-2); padding: 18px; min-width: 0; }
.kpi b { display: block; font-size: 30px; line-height: 1.1; letter-spacing: -.02em; }
.kpi span { color: var(--text-2); font-size: 13px; }
.quote { display: grid; grid-template-columns: minmax(120px, 1.2fr) minmax(0, 2fr) 70px; gap: 12px; align-items: center; padding: 8px 0; font-size: 14px; }
.quote .leiste { height: 10px; border-radius: 10px; background: var(--rot-bg); overflow: hidden; }
.quote .leiste i { display: block; height: 100%; background: var(--gruen); border-radius: 10px; animation: wachsen .8s var(--feder) both; transform-origin: left; }
.quote .wert { text-align: right; font-weight: 700; }
.tabelle-huelle { overflow-x: auto; margin: 0 -6px; }
table.tabelle { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.tabelle th { text-align: left; font-size: 12px; color: var(--text-3); font-weight: 700; padding: 8px 6px; border-bottom: 1px solid var(--linie); white-space: nowrap; }
.tabelle td { padding: 10px 6px; border-bottom: 1px solid var(--linie); vertical-align: top; }
.tabelle tr:last-child td { border-bottom: 0; }
.leer { text-align: center; padding: 30px 16px; color: var(--text-2); display: grid; gap: 8px; justify-items: center; }
.leer .ico { width: 34px; height: 34px; color: var(--text-3); }
.linkfeld { display: flex; gap: 8px; align-items: center; background: var(--flaeche); border-radius: var(--r-m); padding: 8px 8px 8px 14px; min-width: 0; }
.linkfeld code { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; }

/* Dialog / Bottom-Sheet */
.schleier { position: fixed; inset: 0; z-index: 50; background: rgba(20, 20, 26, .38); display: grid; place-items: center; padding: 20px; animation: einblenden .2s ease both; }
.blatt { width: min(500px, 100%); max-height: min(86vh, 760px); overflow: auto; background: var(--karte); border-radius: var(--r-xl); box-shadow: var(--schatten-3); padding: 26px; display: grid; gap: 16px; animation: aufpoppen .28s var(--feder) both; overscroll-behavior: contain; }
.blatt h2 { font-size: 20px; }
.blatt .griff { display: none; }
.blatt-kopf { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; }
.zu { width: 40px; height: 40px; border-radius: 50%; border: 0; background: var(--flaeche); cursor: pointer; display: grid; place-items: center; flex: none; }
.zu:hover { background: var(--grau-bg); }

/* Toasts */
.toasts { position: fixed; z-index: 60; left: 50%; transform: translateX(-50%); bottom: 24px; display: grid; gap: 8px; width: min(440px, calc(100% - 32px)); pointer-events: none; }
.toast { background: var(--schwarz); color: var(--weiss); border-radius: var(--r-m); padding: 12px 16px; box-shadow: var(--schatten-3); font-size: 14px; animation: hoch .3s var(--feder) both; display: flex; gap: 10px; align-items: center; }
.toast.fehler { background: #8f0a15; }

/* Test-Apps */
.testapp { background: radial-gradient(1200px 500px at 50% -10%, color-mix(in srgb, var(--app) 14%, transparent), transparent), var(--flaeche); }
.app-huelle { width: min(560px, 100%); margin: 0 auto; padding: max(28px, env(safe-area-inset-top)) 16px 40px; display: grid; gap: 16px; }
.app-kopf { display: flex; align-items: center; gap: 14px; }
.app-kopf h1 { font-size: 26px; }
.app-kopf .badge { margin-left: auto; }
.app-kopf .app-logo { background: var(--app); }
.token { margin-top: 18px; display: grid; gap: 10px; background: var(--flaeche); border-radius: var(--r-m); padding: 14px; }
.balken-leer { height: 8px; background: var(--grau-bg); border-radius: 8px; overflow: hidden; }
.balken-leer i { display: block; height: 100%; width: 100%; background: var(--app); border-radius: 8px; transition: width 1s linear; }
.liste-knoepfe { display: grid; gap: 10px; margin-top: 14px; }
.fuss { text-align: center; }

/* ---------- Handy-App ---------- */
.handy-kopf, .bottom-nav, .fab { display: none; }
@media (max-width: 860px) {
  body { font-size: 15px; }
  .anmelde-huelle { grid-template-columns: minmax(0, 1fr); }
  .marke { padding: max(22px, env(safe-area-inset-top)) 20px 8px; border-right: 0; background: transparent; gap: 10px; align-items: center; text-align: center; }
  .marke .baer { width: 104px; height: 68px; margin: 0 auto; }
  .marke h1 { font-size: 26px; margin: 0 auto; }
  .marke .unter, .marke-punkte, .baerwelle { display: none; }
  .anmelde-seite { padding: 8px 16px max(24px, env(safe-area-inset-bottom)); place-items: start center; }
  .anmelde-karte { padding: 24px 20px; border-radius: var(--r-l); }

  .rahmen { display: block; }
  .seitenleiste { display: none; }
  .handy-kopf { display: flex; position: sticky; top: 0; z-index: 20; align-items: center; gap: 10px; padding: max(10px, env(safe-area-inset-top)) 16px 10px; background: rgba(245, 245, 247, .88); backdrop-filter: saturate(1.6) blur(14px); -webkit-backdrop-filter: saturate(1.6) blur(14px); border-bottom: 1px solid rgba(0, 0, 0, .04); }
  .handy-kopf .baer { width: 40px; height: 27px; flex: none; }
  .handy-kopf b { font-size: 17px; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .handy-kopf .avatar { width: 44px; height: 44px; border: 0; cursor: pointer; }
  .inhalt { padding: 16px 16px calc(96px + env(safe-area-inset-bottom)); }
  .seitenkopf { margin-bottom: 14px; }
  .seitenkopf h1 { font-size: 24px; }
  .seitenkopf .knopfreihe { display: none; }
  .raster { gap: 14px; }
  .s8, .s7, .s6, .s5, .s4 { grid-column: span 12; }
  .karte { padding: 18px 16px; }
  .stand { grid-template-columns: minmax(0, 1fr); justify-items: center; text-align: left; }
  .pruefliste { width: 100%; }
  .geraet { grid-template-columns: auto minmax(0, 1fr); padding: 16px; gap: 12px; }
  .geraet .aktionen { grid-column: 1 / -1; }
  .geraet .aktionen .knopf { width: 100%; }
  .passkey { grid-template-columns: auto minmax(0, 1fr); }
  .passkey .aktionen { grid-column: 1 / -1; display: flex; gap: 8px; }
  .passkey .aktionen .knopf { flex: 1; }
  .zeitleiste li { grid-template-columns: auto minmax(0, 1fr); }
  .zeitleiste time { grid-column: 2; }
  .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .quote { grid-template-columns: minmax(0, 1fr) 60px; }
  .quote .leiste { grid-column: 1 / -1; grid-row: 2; }
  .nur-desktop { display: none !important; }
  .knopf.klein, .textknopf, .zu { min-height: 44px; }
  .zu { width: 44px; }
  .filter { display: grid; grid-auto-flow: column; grid-auto-columns: auto; width: 100%; }
  .filter button { padding: 7px 6px; min-height: 44px; font-size: 13px; white-space: nowrap; }
  .zeitleiste li { row-gap: 2px; }
  .rahmen:has(.fab) .inhalt { padding-bottom: calc(160px + env(safe-area-inset-bottom)); }
  .app-karte { grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 4px 14px; padding: 14px 16px; }
  .app-karte .app-logo { grid-row: span 3; }

  .bottom-nav { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); position: fixed; z-index: 30; left: 0; right: 0; bottom: 0; padding: 6px 6px max(6px, env(safe-area-inset-bottom)); background: rgba(255, 255, 255, .92); backdrop-filter: saturate(1.6) blur(16px); -webkit-backdrop-filter: saturate(1.6) blur(16px); border-top: 1px solid var(--linie); }
  .bottom-nav a { display: grid; justify-items: center; gap: 2px; padding: 6px 2px; min-height: 52px; border-radius: 12px; color: var(--text-3); text-decoration: none; font-size: 12px; font-weight: 600; position: relative; }
  .bottom-nav a .ico { width: 24px; height: 24px; transition: transform var(--dauer) var(--feder); }
  .bottom-nav a[aria-current="page"] { color: var(--rot-text); }
  .bottom-nav a[aria-current="page"] .ico { transform: translateY(-1px) scale(1.08); }
  .bottom-nav .zaehler { position: absolute; top: 2px; left: calc(50% + 6px); min-width: 18px; height: 18px; border-radius: 9px; background: var(--rot-text); color: #fff; font-size: 11px; display: grid; place-items: center; padding: 0 5px; }
  .fab { display: grid; place-items: center; position: fixed; z-index: 31; right: 18px; bottom: calc(84px + env(safe-area-inset-bottom)); width: 58px; height: 58px; border-radius: 50%; border: 0; background: var(--rot-text); color: #fff; box-shadow: 0 10px 26px rgba(216, 16, 32, .35); cursor: pointer; animation: plopp .4s .2s var(--feder) both; }
  .fab .ico { width: 26px; height: 26px; }
  .toasts { bottom: calc(88px + env(safe-area-inset-bottom)); }

  .schleier { place-items: end stretch; padding: 0; }
  .blatt { width: 100%; max-height: 90vh; border-radius: 24px 24px 0 0; padding: 10px 18px max(22px, env(safe-area-inset-bottom)); animation: hochfahren .32s var(--feder) both; touch-action: pan-y; }
  .blatt .griff { display: block; width: 44px; height: 5px; border-radius: 5px; background: var(--linie-2); margin: 4px auto 6px; }
  .blatt.zieht { transition: none; }
  .blatt.zurueck { transition: transform .25s var(--feder); }
  .tabelle-huelle.als-karten table, .tabelle-huelle.als-karten thead { display: none; }
}
@media (min-width: 861px) { .nur-handy { display: none !important; } }
@media (max-width: 1100px) and (min-width: 861px) { .s4, .s5 { grid-column: span 6; } .s7, .s8 { grid-column: span 12; } .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* Mobile Karten für Tabellen */
.karten-liste { display: none; }
@media (max-width: 860px) { .karten-liste { display: grid; gap: 10px; } .karten-liste .zeile { background: var(--flaeche); border-radius: var(--r-m); padding: 12px 14px; display: grid; gap: 4px; font-size: 14px; } }

/* Animationen */
@keyframes ringauf { from { --wert: 0; } }
@keyframes rein { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes einblenden { from { opacity: 0; } }
@keyframes aufpoppen { from { opacity: 0; transform: translateY(12px) scale(.97); } }
@keyframes hochfahren { from { transform: translateY(100%); } }
@keyframes hoch { from { opacity: 0; transform: translateY(14px); } }
@keyframes plopp { 0% { transform: scale(.4); opacity: 0; } 70% { transform: scale(1.08); } 100% { transform: scale(1); opacity: 1; } }
@keyframes puls { 50% { transform: scale(1.06); opacity: .7; } }
@keyframes dreh { to { transform: rotate(360deg); } }
@keyframes schimmer { to { background-position: -200% 0; } }
@keyframes wachsen { from { transform: scaleX(0); } }
@keyframes schweben { 50% { transform: rotate(-8deg) translateY(-14px); } }
@keyframes wackeln { 20%, 60% { transform: translateX(-6px); } 40%, 80% { transform: translateX(6px); } }
.wackelt { animation: wackeln .4s; }
.ruhig .rein, .ruhig .geraet, .ruhig .alarm, .ruhig .kpi, .ruhig .ring, .ruhig .leiste i, .ruhig .fab { animation: none; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
}
