/* navarolink Web — Farben = die drei Skins der App (AvaloniaProbe/Uebersicht.cs, aus den Support-Tokens).
   data-skin am <html>: dunkel | hell | tuerkis („Wie das System" löst app.js auf). */
:root, [data-skin=dunkel] {
  --paper: #0B1220; --panel: #141D2C; --brand: #060C18; --ink: #F8FAFC; --muted: #D5DFEA; --subtle: #B8C5D6;
  --border: #3D4D64; --border-soft: #26374E; --selected: #123C45; --action: #22D3EE; --on-action: #08131F;
  --success: #34D399; --warning: #FBBF24; --favorit: #FACC15; --fehler: #EF4444;
  --radius: 14px; color-scheme: dark;
}
[data-skin=hell] {
  --paper: #F2F5F8; --panel: #FBFDFF; --brand: #0B1220; --ink: #0B1736; --muted: #5D6880; --subtle: #646F88;
  --border: #D5E0EB; --border-soft: #E6EDF4; --selected: #E1F1F0; --action: #077E78; --on-action: #FFFFFF;
  --success: #009B78; --warning: #C88200; --favorit: #A87B00; --fehler: #DC2626; color-scheme: light;
}
[data-skin=tuerkis] {
  --paper: #EAF6F5; --panel: #FBFEFE; --brand: #04353A; --ink: #06282C; --muted: #4A6B6E; --subtle: #527376;
  --border: #BEDFDD; --border-soft: #D8EEED; --selected: #CCEAE7; --action: #02736F; --on-action: #FFFFFF;
  --success: #1F9254; --warning: #B87400; --favorit: #9E7400; --fehler: #DC2626; color-scheme: light;
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--paper); color: var(--ink); font: 16px/1.4 Inter, "Segoe UI", system-ui, -apple-system, sans-serif; }
body.in-sitzung { overflow: hidden; }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--action); }
.leise { color: var(--subtle); }
.klein { font-size: 13px; }
.fehler { color: var(--fehler); margin: 0; }
h3 { margin: 16px 0 6px; font-size: 14px; text-transform: uppercase; letter-spacing: .04em; color: var(--subtle); }

h1 { margin: 0; font-size: 28px; font-weight: 600; }
.karte { background: var(--panel); border: 1px solid var(--border-soft); border-radius: var(--radius); padding: 18px; }
.stapel { display: flex; flex-direction: column; gap: 14px; }
label { display: flex; flex-direction: column; gap: 6px; color: var(--subtle); font-size: 14px; }
label.zeile { flex-direction: row; align-items: center; gap: 8px; color: var(--ink); }
input[type=email], input[type=password], input[type=search], input[type=text], textarea, select {
  background: var(--paper); border: 1px solid var(--border); border-radius: 10px; padding: 12px 14px; color: var(--ink); width: 100%; }
input:focus-visible, button:focus-visible, select:focus-visible, textarea:focus-visible, a:focus-visible { outline: 2px solid var(--action); outline-offset: 2px; }
button.haupt { background: var(--action); color: var(--on-action); border: 0; border-radius: 10px; padding: 12px 18px;
  font-weight: 600; cursor: pointer; min-height: 44px; }
button.haupt:disabled { opacity: .6; cursor: default; }
button.haupt.rot { background: var(--fehler); color: #fff; }
button.zweit { background: transparent; color: var(--ink); border: 1px solid var(--border); border-radius: 10px; padding: 11px 18px; cursor: pointer; min-height: 44px; }

.anmeldung { max-width: 420px; margin: 6vh auto 0; padding: 0 20px 48px; display: flex; flex-direction: column; gap: 14px; }

/* Einstellungen wie die iOS-Liste der App */
.titelzeile { display: flex; align-items: baseline; justify-content: space-between; }
.einstellungen { max-width: 640px; margin: 0 auto; padding: 24px 20px 48px; display: flex; flex-direction: column; gap: 18px; }
.einstellungen .titelzeile { margin: 0; align-items: center; }
.zurueck { background: none; border: 0; color: var(--action); cursor: pointer; padding: 6px 0; font-size: 17px; }
.kontokarte { display: flex; align-items: center; gap: 14px; }
.gruppe { background: var(--panel); border: 1px solid var(--border-soft); border-radius: var(--radius); overflow: hidden; }
.ezeile { display: flex; flex-direction: row; align-items: center; gap: 14px; min-height: 64px; padding: 10px 16px;
  color: var(--ink); font-size: 17px; text-decoration: none; border-bottom: 1px solid var(--border-soft); }
.ezeile:last-child { border-bottom: 0; }
.ezeile > span:nth-child(2) { flex: 1; }
.ezeile select { width: auto; min-width: 150px; }
.kachel { width: 36px; height: 36px; border-radius: 9px; display: grid; place-items: center; color: #fff; font-weight: 700; flex: none; }
.pfeil { color: var(--subtle); font-size: 22px; }
.abmelden { min-height: 56px; border-radius: var(--radius); border: 1px solid var(--border-soft); background: var(--panel);
  color: #EF4444; font-weight: 600; font-size: 17px; cursor: pointer; }

/* Sitzung */
.sitzung { position: fixed; top: var(--kopfhoehe, 62px); left: 0; right: 0; bottom: 0; z-index: 2; display: flex; flex-direction: column; background: #000; }
.sitzung[hidden] { display: none; }
.sitzung:fullscreen { top: 0; }
.sitzungsleiste { display: flex; align-items: center; gap: 12px; padding: 8px 12px; background: #060C18; color: #F8FAFC;
  border-bottom: 1px solid #26374E; }
.sitzungsleiste .leise { color: #B8C5D6; }
.sitzungsname { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.sitzungsname strong { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sitzungsname span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.werkzeuge { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; justify-content: flex-end; }
.werkzeuge button, .bildschirme button { background: transparent; color: #F8FAFC; border: 1px solid #26374E; border-radius: 8px;
  padding: 7px 11px; cursor: pointer; white-space: nowrap; }
.werkzeuge button:hover { border-color: #22D3EE; }
.werkzeuge button.neu { border-color: #FBBF24; color: #FBBF24; }
.bildschirme { display: flex; gap: 4px; }
.bildschirme button[aria-pressed=true] { background: #123C45; border-color: #22D3EE; color: #22D3EE; }
.mehr { display: none; background: transparent; color: #F8FAFC; border: 1px solid #26374E; border-radius: 8px; padding: 6px 12px; font-size: 18px; }
.schutzband { background: #7C2D12; color: #FFF7ED; padding: 8px 14px; font-size: 14px; }
.bildflaeche { position: relative; flex: 1; min-height: 0; overflow: hidden; outline: none; }
.bildflaeche.original { overflow: auto; }
.bildflaeche.original #bild { position: static; width: auto; height: auto; max-width: none; max-height: none; display: block; margin: auto; }
.bildflaeche.ablegen { box-shadow: inset 0 0 0 3px #22D3EE; }
#bild { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; touch-action: none; }
.hinweis { position: absolute; color: #D5DFEA; display: flex; align-items: center; gap: 12px; background: rgba(6,12,24,.85);
  padding: 14px 20px; border-radius: 12px; margin: 0; top: 50%; left: 50%; transform: translate(-50%, -50%); max-width: calc(100% - 32px); }
.hinweis[hidden] { display: none; }
.kreisel { width: 20px; height: 20px; border-radius: 50%; border: 3px solid #26374E; border-top-color: #22D3EE; animation: dreh 0.9s linear infinite; }
@keyframes dreh { to { transform: rotate(360deg); } }

.blatt { position: absolute; top: 0; right: 0; bottom: 0; width: min(380px, 100%); background: var(--panel); color: var(--ink);
  border-left: 1px solid var(--border-soft); display: flex; flex-direction: column; box-shadow: -8px 0 24px rgba(0,0,0,.35); }
.blatt[hidden] { display: none; }
.blattkopf { display: flex; align-items: center; justify-content: space-between; padding: 14px 16px; border-bottom: 1px solid var(--border-soft); }
.blattkopf .zu { background: none; border: 0; font-size: 24px; cursor: pointer; color: var(--subtle); }
.blattinhalt { padding: 14px 16px; overflow: auto; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.blattinhalt h3 { margin-bottom: 0; }
.werkzeug { text-align: left; background: var(--paper); border: 1px solid var(--border-soft); border-radius: 10px; padding: 12px 14px;
  cursor: pointer; display: flex; flex-direction: column; gap: 2px; min-height: 48px; justify-content: center; }
.werkzeug:hover { border-color: var(--action); }
.werkzeug.laeuft { opacity: .6; }
.ausgabe { background: var(--paper); border: 1px solid var(--border-soft); border-radius: 10px; padding: 10px; font-size: 12px;
  white-space: pre-wrap; max-height: 260px; overflow: auto; }
.dateiliste { display: flex; flex-direction: column; gap: 6px; }
.dateizeile { display: grid; grid-template-columns: 1fr auto; gap: 4px 10px; align-items: center; text-align: left; background: var(--paper);
  border: 1px solid var(--border-soft); border-radius: 10px; padding: 10px 12px; cursor: pointer; }
.dateizeile progress { grid-column: 1 / -1; width: 100%; }
.dname { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chatverlauf { flex: 1; display: flex; flex-direction: column; gap: 8px; overflow: auto; min-height: 200px; }
.chatzeile { align-self: flex-start; max-width: 85%; background: var(--paper); border: 1px solid var(--border-soft); border-radius: 12px; padding: 8px 12px; }
.chatzeile.ich { align-self: flex-end; background: var(--selected); border-color: var(--action); }
.chateingabe { display: flex; gap: 8px; }

.toast { position: fixed; left: 50%; bottom: 28px; transform: translateX(-50%); background: #141D2C; color: #F8FAFC;
  border: 1px solid #3D4D64; border-radius: 12px; padding: 12px 18px; z-index: 20; max-width: min(560px, 92vw);
  box-shadow: 0 8px 24px rgba(0,0,0,.4); display: flex; flex-direction: column; gap: 8px; }
.toast progress { width: 100%; }
.dialog { position: absolute; inset: 0; display: grid; place-items: center; background: rgba(0,0,0,.55); z-index: 10; }
.dialog .karte { width: min(360px, 92vw); }

@media (max-width: 900px) {
  .mehr { display: block; }
  .werkzeuge { display: none; position: absolute; top: 56px; right: 8px; z-index: 8; background: #060C18; border: 1px solid #26374E;
    border-radius: 12px; padding: 10px; flex-direction: column; align-items: stretch; }
  .leiste-offen .werkzeuge { display: flex; }
}
.k1 { background: #8B5CF6; } .k2 { background: #0EA5E9; } .k3 { background: #3B82F6; } .k4 { background: #10B981; } .k5 { background: #64748B; }

/* ── Aufbau wie der Windows-Support (11.11. abends, Gabriel: „in Linien … im Stil von navarolink Windows Support“) ──
   Kopf in Markenfarbe mit Reiter, helle Werkzeugleiste, Seitenleiste links, Inhalt mit ID-Karte und Gerätetabelle,
   Statusleiste unten. Alle Farben aus den Skin-Tokens oben. */
body { min-height: 100vh; display: flex; flex-direction: column; }
#seite { flex: 1; display: flex; flex-direction: column; min-height: 0; }
.kopf { position: sticky; top: 0; z-index: 3; display: flex; align-items: stretch; gap: 22px; height: 62px; padding: 0 18px 0 20px;
  background: var(--brand); color: #F8FAFC; }
.logo { height: 38px; align-self: center; cursor: pointer; }
.reiter { align-self: flex-end; display: flex; align-items: center; gap: 10px; height: 46px; padding: 0 22px; border-radius: 8px 8px 0 0;
  background: var(--panel); color: var(--ink); font-weight: 600; box-shadow: inset 0 3px 0 var(--action); }
.reiter[hidden] { display: none; }
.reiter.ruht { background: transparent; color: #D5E3EC; box-shadow: none; cursor: pointer; font-weight: 500; }
.reiter.ruht:hover { background: rgba(255,255,255,.08); }
/* Sitzungen als Reiter wie im Windows-Support (12.11., Gabriel) */
.sitzungsreiter { display: flex; align-items: flex-end; gap: 2px; min-width: 0; overflow-x: auto; scrollbar-width: none; }
.sitzungsreiter[hidden] { display: none; }
.sreiter { display: flex; align-items: center; gap: 8px; height: 46px; padding: 0 8px 0 16px; border-radius: 8px 8px 0 0; border: 0;
  background: transparent; color: #D5E3EC; font: inherit; font-weight: 500; cursor: pointer; white-space: nowrap; max-width: 240px; }
.sreiter:hover { background: rgba(255,255,255,.08); }
.sreiter.aktiv { background: var(--panel); color: var(--ink); font-weight: 600; box-shadow: inset 0 3px 0 var(--action); }
.sreiter .sname { overflow: hidden; text-overflow: ellipsis; }
.sreiter .punkt { width: 8px; height: 8px; border-radius: 50%; background: #F59E0B; flex: none; }
.sreiter .punkt.an { background: #22C55E; }
.sreiter .zu { display: grid; place-items: center; width: 22px; height: 22px; border-radius: 6px; font-size: 16px; line-height: 1; opacity: .7; }
.sreiter .zu:hover { opacity: 1; background: rgba(127,127,127,.25); }
.kopf-rechts { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.skins { display: flex; gap: 4px; padding-right: 12px; margin-right: 4px; border-right: 1px solid rgba(255,255,255,.18); }
.skins[hidden] { display: none; }
.skins button { width: 34px; height: 34px; border-radius: 8px; border: 0; background: transparent; color: #C8D4E4; display: grid; place-items: center; cursor: pointer; }
.skins button:hover { background: rgba(255,255,255,.08); }
.skins button[aria-pressed=true] { background: #22D3EE; color: #04353A; }
.rund { width: 36px; height: 36px; border-radius: 8px; border: 0; background: transparent; color: #C8D4E4; display: grid; place-items: center; cursor: pointer; }
.rund[hidden] { display: none; }
.rund:hover { background: rgba(255,255,255,.08); }
.kontochip { display: flex; align-items: center; gap: 10px; height: 46px; padding: 0 10px 0 6px; margin-left: 6px; border: 0; border-radius: 10px;
  background: transparent; color: #F8FAFC; cursor: pointer; font-weight: 600; }
.kontochip[hidden] { display: none; }
.kontochip:hover { background: rgba(255,255,255,.08); }
.avatar { width: 34px; height: 34px; border-radius: 50%; border: 1.5px solid #22D3EE; background: #123C45; color: #22D3EE;
  font-weight: 600; display: grid; place-items: center; flex: none; }
.avatar.gross { width: 52px; height: 52px; font-size: 22px; }
.kontoname { max-width: 160px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.uebersicht { flex: 1; display: flex; flex-direction: column; min-height: 0; }
.werkzeugleiste { display: flex; align-items: center; gap: 6px; padding: 10px 24px; background: var(--panel); border-bottom: 1px solid var(--border-soft); }
.werkzeugleiste button { display: flex; align-items: center; gap: 10px; padding: 9px 14px; border: 0; border-radius: 8px; background: transparent;
  color: var(--ink); cursor: pointer; font-size: 15px; }
.werkzeugleiste button:hover { background: var(--selected); }
.arbeitsflaeche { flex: 1; display: grid; grid-template-columns: 264px 1fr; min-height: 0; }
.seitenleiste { display: flex; flex-direction: column; justify-content: space-between; gap: 16px; padding: 22px 14px 18px;
  background: var(--paper); border-right: 1px solid var(--border-soft); }
.navliste, .navfuss { display: flex; flex-direction: column; gap: 4px; }
.navfuss { border-top: 1px solid var(--border-soft); padding-top: 16px; }
.navpunkt { display: flex; align-items: center; gap: 14px; width: 100%; min-height: 44px; padding: 0 14px; border: 0; border-radius: 8px;
  background: transparent; color: var(--ink); text-align: left; text-decoration: none; cursor: pointer; font-size: 15px; }
.navpunkt:hover { background: var(--selected); }
.navpunkt[aria-pressed=true] { background: var(--selected); color: var(--action); font-weight: 600; }
.navpunkt svg { flex: none; }
.navtext { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.navpunkt .zahl { color: var(--subtle); font-size: 13px; font-weight: 400; }
.inhalt { padding: 24px 28px; display: flex; flex-direction: column; gap: 20px; min-width: 0; overflow: auto;
  background: color-mix(in srgb, var(--paper) 88%, var(--border)); }
.karte { border-radius: 10px; }
.idkarte { display: flex; gap: 12px; padding: 18px; }
.idkarte input { flex: 1; min-width: 0; background: var(--panel); border-radius: 6px; }
.idkarte .haupt, .verbinden { display: inline-flex; align-items: center; justify-content: center; gap: 10px; }
.idkarte .haupt { border-radius: 6px; padding: 0 26px; }
.listenkarte { padding: 0; overflow: hidden; }
.listenkopf { display: flex; align-items: center; gap: 18px; padding: 18px 20px; border-bottom: 1px solid var(--border-soft); }
.listenkopf strong { font-size: 16px; }
.leiseknopf { margin-left: auto; display: flex; align-items: center; gap: 8px; border: 0; background: transparent; color: var(--ink); cursor: pointer; padding: 6px 8px; border-radius: 6px; }
.leiseknopf:hover { background: var(--selected); }
.tzeile { display: grid; grid-template-columns: 52px 124px 32px minmax(160px, 1fr) 110px 78px 160px 150px; align-items: center; gap: 0 14px; padding: 0 20px; }
.tkopf { min-height: 38px; font-weight: 600; font-size: 15px; border-bottom: 1px solid var(--border-soft); }
.geraet { min-height: 98px; border-bottom: 1px solid var(--border-soft); cursor: default; }
.geraet:last-child { border-bottom: 0; }
.geraet:hover { background: var(--selected); }
.status { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; color: #fff; }
.status.an { background: var(--success); }
.status.weg { background: color-mix(in srgb, var(--fehler) 55%, var(--panel)); }
.vorschau { width: 112px; height: 70px; border-radius: 4px; overflow: hidden; display: grid; place-items: center; color: var(--subtle);
  background: color-mix(in srgb, var(--paper) 70%, var(--border-soft)); }
.vorschau img { width: 100%; height: 100%; object-fit: cover; }
.stern { color: var(--subtle); display: grid; place-items: center; }
.stern.an { color: var(--favorit); }
.stern.an svg { fill: currentColor; }
.info { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.info .name { font-weight: 600; font-size: 16px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.info .zweit, .kennung { font-family: ui-monospace, "Cascadia Mono", Consolas, monospace; font-size: 12.5px; color: var(--subtle); }
.kennung { white-space: nowrap; }
.zustand { color: var(--subtle); display: grid; place-items: center start; padding-left: 14px; }
.zustand.an { color: var(--success); }
.letzte { font-size: 14px; color: var(--subtle); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.verbinden { height: 42px; border-radius: 6px; border: 1px solid var(--action); background: var(--action); color: var(--on-action); font-weight: 600; cursor: pointer; }
.verbinden:hover { filter: brightness(1.08); }
.verbinden:disabled { background: transparent; border-color: var(--border-soft); color: var(--subtle); opacity: .7; cursor: default; filter: none; }
.geraet.aus .info .name, .geraet.aus .vorschau { opacity: .6; }
.leer { color: var(--subtle); padding: 24px 20px; margin: 0; }
.statusleiste { display: flex; justify-content: space-between; align-items: center; padding: 10px 28px; background: var(--panel);
  border-top: 1px solid var(--border-soft); font-size: 14px; }

@media (max-width: 1200px) {
  .tzeile { grid-template-columns: 44px 96px 28px minmax(140px, 1fr) 104px 140px; }
  .tzeile .sp-zustand, .tzeile .sp-letzte { display: none; }
  .vorschau { width: 96px; height: 60px; }
}
@media (max-width: 900px) {
  .kopf { gap: 12px; height: 56px; padding: 0 10px 0 14px; }
  .logo { height: 30px; }
  .skins, .kontoname { display: none !important; }
  .reiter span { display: none; }
  .reiter { padding: 0 12px; }
  .sreiter { max-width: 150px; padding-left: 10px; }
  :root { --kopfhoehe: 56px; }
  .werkzeugleiste { padding: 6px 12px; overflow-x: auto; }
  .arbeitsflaeche { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto 1fr; }
  .seitenleiste { justify-content: flex-start; }
  .inhalt { overflow: visible; }
  .seitenleiste { padding: 10px 12px; border-right: 0; border-bottom: 1px solid var(--border-soft); }
  .navliste { flex-direction: row; overflow-x: auto; gap: 6px; }
  .navliste .navpunkt { width: auto; flex: none; min-height: 38px; border: 1px solid var(--border-soft); border-radius: 999px; padding: 0 14px; gap: 8px; }
  .navliste .navpunkt svg { display: none; }
  .navfuss { display: none; }
  .inhalt { padding: 14px 12px; gap: 14px; }
  .idkarte { padding: 12px; }
  .idkarte .haupt { padding: 0 14px; }
  .listenkopf { flex-wrap: wrap; gap: 6px 12px; padding: 14px; }
  .tkopf { display: none; }
  .tzeile { grid-template-columns: 30px 72px minmax(0, 1fr) auto; gap: 0 10px; padding: 10px 12px; }
  .tzeile .stern, .tzeile .sp-id { display: none; }
  .geraet { min-height: 76px; }
  .vorschau { width: 72px; height: 46px; }
  .status { width: 24px; height: 24px; }
  .verbinden { height: 38px; padding: 0 12px; }
  .verbinden span { display: none; }
  .statusleiste { padding: 8px 14px; font-size: 13px; }
}
