[hidden] { display: none !important; }
:root {
  --bg-panel: rgba(11, 15, 25, 0.82);
  --border: rgba(148, 163, 184, 0.18);
  --text: #f1f5f9;
  --text2: #94a3b8;
  --accent: #38bdf8;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
html, body { width: 100%; height: 100%; overflow: hidden; background: #0b0e14; color: var(--text);
  font-family: Calibri, 'Segoe UI', system-ui, sans-serif; -webkit-font-smoothing: antialiased; }
button, select { font-family: inherit; }

#canvas-container { position: fixed; inset: 0; z-index: 1; }
#canvas-container.pointer-hover canvas { cursor: grab; }
.vignette { position: fixed; inset: 0; pointer-events: none; z-index: 2;
  background: radial-gradient(ellipse at center, transparent 62%, rgba(2,4,9,0.55) 100%); }
#labels-layer { position: fixed; inset: 0; pointer-events: none; z-index: 5; transition: opacity .3s; }
/* „Namen“ aus: nur die Bauteil-Namen ausblenden – Steckplatz-Ziele und Datenweg-Hinweise bleiben */
#labels-layer.hidden .pin-label { opacity: 0; pointer-events: none; }
.pin-label { transition: opacity .3s; }

.glass { background: var(--bg-panel); backdrop-filter: blur(18px) saturate(140%); -webkit-backdrop-filter: blur(18px) saturate(140%);
  border: 1px solid var(--border); border-radius: 14px; box-shadow: 0 12px 40px rgba(0,0,0,.45); }

/* Loader */
#loader { position: fixed; inset: 0; z-index: 50; display: grid; place-content: center; gap: 14px; text-align: center;
  background: #0b0e14; transition: opacity .6s; color: var(--text2); }
#loader.done { opacity: 0; pointer-events: none; }
.spinner { width: 44px; height: 44px; margin: 0 auto; border-radius: 50%; border: 3px solid #1e293b; border-top-color: var(--accent); animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* Kopf */
.top { position: fixed; top: 16px; left: 16px; z-index: 10; padding: 12px 18px; max-width: 420px; }
.top h1 { font-size: 20px; letter-spacing: .02em; }
.top p { font-size: 13px; color: var(--text2); margin-top: 2px; }
.status { display: flex; align-items: center; gap: 8px; font-size: 11px; font-weight: 700; letter-spacing: .12em; color: var(--text2); margin-bottom: 4px; }
.status-led { width: 9px; height: 9px; border-radius: 50%; background: #475569; }
.status-led.on { background: #22c55e; box-shadow: 0 0 10px #22c55e; }
.status-led.busy { background: #f59e0b; box-shadow: 0 0 10px #f59e0b; animation: pulse .6s infinite alternate; }
.status-led.err { background: #ef4444; box-shadow: 0 0 10px #ef4444; }
@keyframes pulse { to { opacity: .35; } }

/* Pins */
.pin-label { display: flex; flex-direction: column; align-items: center; transform: translateY(-50%); pointer-events: auto; cursor: pointer; }
.pin-badge { display: flex; align-items: center; gap: 6px; padding: 4px 10px 4px 7px; border-radius: 999px; white-space: nowrap;
  background: rgba(10,14,24,.88); border: 1px solid rgba(255,255,255,.14); font-size: 12px; font-weight: 600; box-shadow: 0 6px 18px rgba(0,0,0,.5); transition: .2s; }
.pin-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--pin-color); box-shadow: 0 0 8px var(--pin-color); }
.pin-stem { width: 1.5px; height: 16px; background: linear-gradient(var(--pin-color), transparent); }
.pin-label:hover .pin-badge { border-color: var(--pin-color); transform: scale(1.06); }
.pin-label.minor { display: none; }

/* Seitenleiste */
#side { position: fixed; left: 16px; top: 122px; bottom: 110px; z-index: 10; width: 330px; display: none; flex-direction: column; overflow: hidden; }
#side.open { display: flex; }
.tabs { display: flex; gap: 2px; padding: 6px; border-bottom: 1px solid var(--border); }
.tab { flex: 1; padding: 8px 4px; border-radius: 8px; border: 0; background: transparent; color: var(--text2); font-size: 13.5px; font-weight: 600; cursor: pointer; }
.tab.active { background: rgba(56,189,248,.16); color: #fff; }
.tab-page { padding: 12px 14px 16px; overflow: auto; flex: 1; }
.tab-page h3 { font-size: 12px; letter-spacing: .12em; text-transform: uppercase; color: var(--text2); margin: 16px 0 8px; }
.intro { font-size: 13.5px; color: #cbd5e1; line-height: 1.45; margin-bottom: 10px; }
.opts { display: flex; gap: 14px; margin: 10px 2px 0; font-size: 13px; color: var(--text2); }
.opts input { accent-color: #38bdf8; margin-right: 4px; }
#check-list { list-style: none; display: grid; gap: 5px; }
#check-list li { display: flex; gap: 9px; align-items: flex-start; font-size: 13px; padding: 5px 7px; border-radius: 8px; background: rgba(255,255,255,.03); }
#check-list b { display: block; font-weight: 600; }
#check-list small { color: var(--text2); font-size: 12px; }
.ico { flex: 0 0 20px; height: 20px; border-radius: 50%; display: grid; place-content: center; font-size: 12px; font-weight: 800; }
li.ok .ico { background: #14532d; color: #4ade80; }
li.warn .ico { background: #713f12; color: #facc15; }
li.err .ico { background: #7f1d1d; color: #f87171; }
.dbg-row { display: flex; gap: 6px; align-items: center; margin: 12px 0 4px; font-size: 12px; color: var(--text2); }
.dbg-row i { font-style: normal; font-size: 10px; font-weight: 700; padding: 2px 6px; border-radius: 4px; background: #2a1215; color: #7f3a3f; }
.dbg-row i.on { background: #ef4444; color: #fff; box-shadow: 0 0 10px #ef4444; }
.power-btn { width: 100%; padding: 11px; border-radius: 10px; border: 1px solid #22c55e66; background: #14532d; color: #dcfce7; font-weight: 700; font-size: 15px; cursor: pointer; }
.power-btn:hover { background: #166534; }
#boot-steps { list-style: none; display: grid; gap: 3px; margin-top: 8px; counter-reset: s; }
#boot-steps li { display: flex; gap: 8px; align-items: center; font-size: 13px; padding: 5px 7px; border-radius: 7px; color: var(--text2); cursor: pointer; }
#boot-steps li span { flex: 0 0 20px; height: 20px; border-radius: 50%; display: grid; place-content: center; font-size: 11px; font-weight: 700; background: #1e293b; }
#boot-steps li.ok { color: #cbd5e1; } #boot-steps li.ok span { background: #14532d; color: #4ade80; }
#boot-steps li.warn span { background: #713f12; color: #facc15; }
#boot-steps li.act { color: #fff; background: rgba(56,189,248,.14); } #boot-steps li.act span { background: #38bdf8; color: #0b1220; }
#boot-steps li.err { color: #fecaca; background: rgba(239,68,68,.16); } #boot-steps li.err span { background: #ef4444; color: #fff; }
.wide-btn { width: 100%; padding: 9px; border-radius: 9px; border: 1px solid var(--border); background: rgba(255,255,255,.04); color: #fff; font-weight: 600; cursor: pointer; font-size: 14px; }
.wide-btn.active { background: rgba(250,204,21,.16); border-color: #facc1588; }
#route-list { display: grid; gap: 5px; }
.route-btn { display: flex; gap: 10px; align-items: center; padding: 8px 10px; border-radius: 9px; border: 1px solid var(--border); background: rgba(255,255,255,.03); color: #e2e8f0; font-size: 14px; cursor: pointer; text-align: left; }
.route-btn:hover { background: rgba(255,255,255,.08); }
.route-btn span { width: 22px; text-align: center; }
.lg-group h4 { display: flex; align-items: center; gap: 7px; font-size: 13px; margin: 10px 0 4px; }
.lg-group h4 i { width: 14px; height: 4px; border-radius: 2px; background: var(--c); box-shadow: 0 0 8px var(--c); }
.lg-item { display: block; width: 100%; text-align: left; padding: 5px 8px 5px 21px; border: 1px solid transparent; border-radius: 7px; background: transparent; color: #cbd5e1; cursor: pointer; }
.lg-item b { display: block; font-size: 13px; font-weight: 600; } .lg-item span { font-size: 12px; color: var(--text2); }
.lg-item:hover, .lg-item.active { background: rgba(255,255,255,.06); border-color: var(--border); }

/* Bus-Beschriftung */
.bus-label { pointer-events: none; padding: 3px 8px; border-radius: 7px; background: rgba(8,12,20,.9); border: 1px solid var(--c); font-size: 11.5px; white-space: nowrap; box-shadow: 0 0 12px color-mix(in srgb, var(--c) 40%, transparent); }
.bus-label b { color: #fff; margin-right: 6px; } .bus-label span { color: var(--c); }
.bus-label.err { border-color: #ef4444; } .bus-label.err span { color: #f87171; }

/* Ablauf-Anzeige */
#seq-banner { position: fixed; left: 50%; bottom: 96px; transform: translate(-50%, 20px); z-index: 12; width: min(640px, calc(100vw - 32px)); padding: 14px 18px 12px; opacity: 0; pointer-events: none; transition: .35s; }
#seq-banner.open { opacity: 1; transform: translate(-50%, 0); pointer-events: auto; }
.seq-top { display: flex; justify-content: space-between; font-size: 11px; letter-spacing: .14em; font-weight: 700; color: #38bdf8; }
.seq-progress { height: 3px; background: #1e293b; border-radius: 2px; margin: 7px 0 9px; overflow: hidden; }
#seq-bar { height: 100%; background: #38bdf8; transition: width .4s; }
#seq-title { font-size: 21px; line-height: 1.2; }
#seq-desc { font-size: 15px; line-height: 1.5; color: #dbe3ee; margin-top: 5px; }
.seq-msg:empty { display: none; }
.seq-msg { margin-top: 9px; padding: 8px 11px; border-radius: 9px; font-size: 14px; line-height: 1.45; }
.seq-msg.err { background: rgba(239,68,68,.16); border: 1px solid #ef444488; color: #fecaca; }
.seq-msg.warn { background: rgba(250,204,21,.12); border: 1px solid #facc1577; color: #fef08a; }
.seq-msg.info { background: rgba(56,189,248,.12); border: 1px solid #38bdf877; }
#seq-buses { display: flex; flex-wrap: wrap; gap: 5px 12px; margin-top: 9px; font-size: 12.5px; color: #cbd5e1; }
#seq-buses span { display: flex; align-items: center; gap: 5px; } #seq-buses i { width: 12px; height: 4px; border-radius: 2px; background: var(--c); box-shadow: 0 0 6px var(--c); }
#seq-buses em { font-style: normal; color: var(--text2); }
.seq-ctrl { display: flex; gap: 6px; margin-top: 11px; align-items: center; }
.seq-ctrl button, .seq-ctrl select { height: 34px; min-width: 40px; padding: 0 10px; border-radius: 8px; border: 1px solid var(--border); background: rgba(255,255,255,.05); color: #fff; cursor: pointer; font-size: 14px; }
.seq-ctrl select { background: #0f172a; }
.seq-close { margin-left: auto; }

/* Szenarien */
#scen-list { display: grid; gap: 6px; }
.scen-card { text-align: left; padding: 10px 12px; border-radius: 10px; border: 1px solid var(--border); background: rgba(255,255,255,.03); color: #fff; cursor: pointer; }
.scen-card:hover { background: rgba(56,189,248,.1); border-color: #38bdf866; }
.scen-card b { display: block; font-size: 14.5px; margin: 2px 0 3px; } .scen-card small { color: var(--text2); font-size: 12.5px; line-height: 1.35; }
.stars { color: #facc15; font-size: 12px; letter-spacing: 2px; }
.scen-head h3 { font-size: 18px; color: #fff; letter-spacing: 0; text-transform: none; margin: 2px 0 6px; }
.story { font-size: 14.5px; line-height: 1.5; color: #dbe3ee; padding: 10px 12px; border-radius: 10px; background: rgba(56,189,248,.08); border-left: 3px solid #38bdf8; }
#scen-active h4 { font-size: 12px; letter-spacing: .12em; text-transform: uppercase; color: var(--text2); margin: 14px 0 6px; }
.tasks { list-style: none; display: grid; gap: 4px; }
.tasks li { display: flex; gap: 9px; align-items: flex-start; font-size: 14px; padding: 4px 2px; color: #cbd5e1; }
.tasks li span { flex: 0 0 18px; height: 18px; margin-top: 1px; border-radius: 5px; border: 2px solid #475569; }
.tasks li.done { color: #86efac; } .tasks li.done span { background: #22c55e; border-color: #22c55e; }
.tasks li.done span::after { content: '✓'; display: block; text-align: center; color: #052e16; font-size: 12px; font-weight: 900; line-height: 14px; }
.hints p { margin-top: 8px; font-size: 13.5px; line-height: 1.45; padding: 8px 10px; border-radius: 8px; background: rgba(250,204,21,.1); border: 1px solid #facc1544; }
.solved { margin-top: 12px; padding: 10px 12px; border-radius: 10px; background: rgba(34,197,94,.16); border: 1px solid #22c55e88; }
.solved b { display: block; font-size: 16px; color: #86efac; } .solved small { color: #cbd5e1; }
.solution { margin-top: 10px; padding: 10px 12px; border-radius: 10px; background: rgba(168,85,247,.12); border: 1px solid #a855f766; font-size: 13.5px; line-height: 1.5; }
.solution b { color: #e9d5ff; }
.scen-btns { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin-top: 14px; }
.scen-btns button { padding: 8px; border-radius: 8px; border: 1px solid var(--border); background: rgba(255,255,255,.05); color: #fff; cursor: pointer; font-size: 13px; }
.scen-btns button:disabled { opacity: .4; cursor: default; }

/* Multimeter */
.meter { margin-top: 12px; padding: 10px 12px; border-radius: 10px; background: #0a0f0a; border: 1px solid #3f3f46; font-family: Consolas, monospace; }
.meter span { font-size: 11px; color: #a1a1aa; letter-spacing: .1em; display: block; }
.meter b { font-size: 28px; display: block; }
.meter.good b { color: #4ade80; } .meter.bad b { color: #f87171; }
.meter small { font-family: Calibri, sans-serif; font-size: 13px; color: #cbd5e1; }

/* Inspector */
#inspector { position: fixed; right: 16px; top: 16px; bottom: 120px; width: 380px; z-index: 10; display: flex; flex-direction: column;
  transform: translateX(420px); transition: transform .35s cubic-bezier(.22,1,.36,1); border-top: 3px solid var(--accent); }
#inspector.open { transform: none; }
.insp-head { display: flex; justify-content: space-between; gap: 10px; padding: 16px 16px 10px; }
.tag { font-size: 11px; font-weight: 700; letter-spacing: .14em; color: var(--accent); }
#inspector h2 { font-size: 20px; line-height: 1.2; margin-top: 3px; }
.sub { color: var(--text2); font-size: 13px; margin-top: 2px; }
.close-btn { flex: 0 0 30px; height: 30px; border-radius: 8px; border: 1px solid var(--border); background: transparent; color: var(--text2); cursor: pointer; }
.close-btn:hover { color: #fff; border-color: #fff4; }
.insp-body { padding: 0 16px 16px; overflow: auto; }
#inspector-desc { font-size: 14.5px; line-height: 1.5; color: #dbe3ee; }
#specs-grid { display: grid; gap: 1px; margin-top: 12px; border-radius: 10px; overflow: hidden; background: var(--border); }
.spec { display: grid; grid-template-columns: 42% 58%; gap: 8px; padding: 7px 10px; background: rgba(13,18,30,.95); font-size: 13px; }
.spec span { color: var(--text2); }
.spec b { font-weight: 600; }
.tip { margin-top: 12px; padding: 10px 12px; border-radius: 10px; background: color-mix(in srgb, var(--accent) 14%, transparent); border: 1px solid color-mix(in srgb, var(--accent) 40%, transparent); font-size: 13.5px; line-height: 1.45; }
.tip::before { content: '💡 '; }
#inspector-actions { display: grid; gap: 6px; margin-top: 12px; }
.act-btn { padding: 9px 12px; border-radius: 9px; border: 1px solid color-mix(in srgb, var(--accent) 50%, transparent); background: color-mix(in srgb, var(--accent) 18%, transparent); color: #fff; font-weight: 600; cursor: pointer; text-align: left; font-size: 13.5px; }
.act-btn:hover { background: color-mix(in srgb, var(--accent) 30%, transparent); }
.cpu-pick { display: block; margin-top: 12px; font-size: 13px; color: var(--text2); }
.cpu-pick select { margin-left: 6px; padding: 5px 8px; border-radius: 7px; background: #0f172a; color: #fff; border: 1px solid var(--border); font-size: 13px; }
.mini-note { margin-top: 10px; font-size: 13px; color: var(--text2); font-family: Consolas, monospace; }

/* Steuerleiste */
.controls { position: fixed; top: 16px; left: 50%; transform: translateX(-50%); z-index: 10; display: flex; gap: 4px; padding: 5px; }
.controls button { padding: 7px 8px; border-radius: 9px; border: 1px solid transparent; background: transparent; color: var(--text2); font-size: 13px; cursor: pointer; white-space: nowrap; }
.controls button:hover { color: #fff; background: rgba(255,255,255,.06); }
.controls button.active { color: #fff; background: rgba(56,189,248,.18); border-color: rgba(56,189,248,.4); }

/* Dock */
#bottom-dock { position: fixed; bottom: 34px; left: 50%; transform: translateX(-50%); z-index: 10; display: flex; gap: 4px; padding: 6px; max-width: calc(100vw - 32px); overflow-x: auto; }
.dock-item { display: flex; align-items: center; gap: 6px; padding: 6px 10px; border-radius: 8px; border: 1px solid transparent; background: transparent; color: var(--text2); font-size: 12.5px; cursor: pointer; white-space: nowrap; }
.dock-item .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--c); }
.dock-item:hover, .dock-item.active { color: #fff; background: rgba(255,255,255,.07); border-color: color-mix(in srgb, var(--c) 50%, transparent); }
.hint { position: fixed; bottom: 8px; left: 50%; transform: translateX(-50%); z-index: 10; font-size: 12px; color: #64748b; white-space: nowrap; }
.tray-label { font-size: 11px; letter-spacing: .2em; color: #64748b; font-weight: 700; pointer-events: none; }

/* Toast */
.toast { position: fixed; top: calc(var(--hdr, 64px) + 14px); left: 50%; transform: translate(-50%, -10px); z-index: 1000; padding: 10px 16px; border-radius: 10px; font-size: 14px;
  background: #0f172a; border: 1px solid var(--border); opacity: 0; pointer-events: none; transition: .3s; max-width: 560px; text-align: center; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast.warn { border-color: #facc15aa; color: #fef08a; }
.toast.info { border-color: #38bdf8aa; }

@media (max-width: 1100px) {
  #inspector { width: 320px; }
  #side { width: 290px; }
  .hint { display: none; }
}

/* ================= Lexikon / Detailseiten ================= */
#detail { position: fixed; inset: 0; z-index: 40; background: #0b0f18; display: flex; flex-direction: column; --accent: #38bdf8; }
.d-head { display: flex; align-items: center; gap: 10px; padding: 10px 16px; border-bottom: 1px solid var(--border); background: #0e1420; }
.d-btn { padding: 9px 14px; border-radius: 9px; border: 1px solid var(--border); background: rgba(255,255,255,.05); color: #fff; font-size: 14px; cursor: pointer; }
.d-btn:hover { background: rgba(255,255,255,.1); }
.d-mode { margin-left: auto; display: flex; border: 1px solid var(--border); border-radius: 9px; overflow: hidden; }
.d-mode button { padding: 9px 14px; border: 0; background: transparent; color: var(--text2); font-size: 14px; cursor: pointer; }
.d-mode button.active { background: var(--accent); color: #0b1220; font-weight: 700; }
.d-body { flex: 1; display: grid; grid-template-columns: 250px minmax(0, 1fr); min-height: 0; }
#d-nav { padding: 14px 10px; border-right: 1px solid var(--border); overflow: auto; }
#d-nav h4 { font-size: 12px; letter-spacing: .12em; text-transform: uppercase; color: var(--text2); margin: 0 8px 8px; }
#d-nav button { display: flex; align-items: center; gap: 9px; width: 100%; text-align: left; padding: 9px 10px; border: 0; border-radius: 8px; background: transparent; color: #cbd5e1; font-size: 14.5px; cursor: pointer; }
#d-nav button i { width: 9px; height: 9px; border-radius: 50%; background: var(--c); flex: none; }
#d-nav button:hover { background: rgba(255,255,255,.05); }
#d-nav button.active { background: rgba(255,255,255,.09); color: #fff; font-weight: 600; }
#d-article { overflow: auto; padding: 28px clamp(18px, 4vw, 56px) 60px; font-size: 16px; line-height: 1.6; color: #dbe3ee; }
#d-article > * { max-width: 920px; }
.d-cat { color: var(--accent); font-size: 12px; letter-spacing: .16em; font-weight: 700; text-transform: uppercase; }
#d-article h1 { font-size: clamp(28px, 3.4vw, 40px); line-height: 1.1; color: #fff; margin: 4px 0 10px; }
.d-lead { font-size: 18px; color: #e2e8f0; }
.d-toc { display: flex; flex-wrap: wrap; gap: 6px; margin: 16px 0 6px; }
.d-toc a { font-size: 13px; padding: 5px 10px; border-radius: 999px; border: 1px solid var(--border); color: #cbd5e1; text-decoration: none; }
.d-toc a:hover { border-color: var(--accent); color: #fff; }
#d-article section { margin-top: 30px; }
#d-article h2 { font-size: 22px; color: #fff; margin-bottom: 10px; padding-bottom: 6px; border-bottom: 2px solid color-mix(in srgb, var(--accent) 50%, transparent); }
.xp { font-size: 11px; vertical-align: middle; padding: 2px 8px; border-radius: 999px; background: #a855f733; color: #e9d5ff; letter-spacing: .05em; }
#detail:not(.expert-on) section.expert, #detail:not(.expert-on) .d-toc a.expert { display: none; }
#d-article p { margin: 8px 0; } #d-article ul, #d-article ol { margin: 8px 0 8px 22px; } #d-article li { margin: 4px 0; }
#d-article code { font-family: Consolas, monospace; font-size: .9em; padding: 1px 6px; border-radius: 5px; background: #1e293b; color: #e2e8f0; }
.tbl-wrap { overflow-x: auto; margin: 12px 0; }
#d-article table { border-collapse: collapse; width: 100%; font-size: 14.5px; }
#d-article th { text-align: left; background: color-mix(in srgb, var(--accent) 18%, #111827); color: #fff; padding: 8px 10px; font-weight: 600; }
#d-article td { padding: 7px 10px; border-bottom: 1px solid #1f2937; vertical-align: top; }
#d-article tr:nth-child(even) td { background: rgba(255,255,255,.02); }
#d-article td:first-child { color: #cbd5e1; font-weight: 600; }
b.bad { color: #f87171; }
.note { margin: 14px 0; padding: 11px 14px; border-radius: 10px; font-size: 15px; }
.note.merke { background: color-mix(in srgb, var(--accent) 12%, transparent); border-left: 4px solid var(--accent); }
.note.warn { background: rgba(250,204,21,.1); border-left: 4px solid #facc15; }
.formula { font-family: Consolas, monospace; font-size: 17px; padding: 10px 14px; border-radius: 10px; background: #111827; border: 1px dashed #334155; color: #fff; display: inline-block; }
.src { font-size: 13px; color: var(--text2); }
.fig { margin: 16px 0; padding: 16px; border-radius: 14px; background: #0f1623; border: 1px solid #1f2937; }
.fig.small { max-width: 420px; }
.fig svg { width: 100%; height: auto; display: block; }
.fig figcaption { font-size: 13.5px; color: var(--text2); margin-top: 10px; }
.fig .bt { fill: #fff; font: 600 16px Calibri, sans-serif; } .fig .bt.big { font-size: 20px; }
.fig .bs { fill: #94a3b8; font: 13px Calibri, sans-serif; } .fig .lt { font: 600 13px Calibri, sans-serif; }
.ladder { display: grid; gap: 7px; }
.lad-row { display: grid; grid-template-columns: 140px minmax(0,1fr) 80px 170px; gap: 10px; align-items: center; font-size: 14px; }
.lad-bar { height: 14px; background: #1e293b; border-radius: 7px; overflow: hidden; } .lad-bar i { display: block; height: 100%; border-radius: 7px; }
.lad-t { font-weight: 700; color: #fff; text-align: right; } .lad-s { color: var(--text2); font-size: 13px; }
.cpu-sel select, .calc select, .calc input[type=number] { padding: 6px 8px; border-radius: 7px; background: #0f172a; color: #fff; border: 1px solid #334155; font-size: 15px; }
.coremap { margin: 12px 0; padding: 14px; border-radius: 14px; background: #120f14; border: 2px solid #ef444466; }
.cm-title { font-weight: 700; color: #fff; margin-bottom: 10px; }
.cores { display: flex; flex-wrap: wrap; gap: 8px; }
.core { border-radius: 9px; padding: 8px; display: flex; flex-direction: column; justify-content: center; text-align: center; font-size: 12px; }
.core.p { width: 92px; height: 92px; background: #ef444422; border: 1px solid #ef4444; }
.core.e { width: 120px; height: 92px; background: #3b82f622; border: 1px solid #3b82f6; }
.core b { color: #fff; font-size: 14px; } .core small { color: #cbd5e1; } .core em { font-style: normal; color: var(--text2); font-size: 11px; }
.ecs { display: grid; grid-template-columns: repeat(4, 1fr); gap: 3px; margin-bottom: 4px; } .ecs i { height: 12px; border-radius: 3px; background: #3b82f6; }
.l3 { margin-top: 8px; padding: 8px; text-align: center; border-radius: 8px; background: #f59e0b22; border: 1px solid #f59e0b; color: #fde68a; font-weight: 600; }
.cm-row { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 8px; }
.igpu, .mc { padding: 8px; border-radius: 8px; text-align: center; font-size: 13px; }
.igpu { background: #e879f922; border: 1px solid #e879f9; } .igpu.off { background: #1f2937; border: 1px dashed #475569; color: #f87171; }
.mc { background: #22c55e1a; border: 1px solid #22c55e; }
.calc { margin: 14px 0; padding: 14px; border-radius: 12px; background: #0f1a14; border: 1px solid #22c55e55; display: flex; flex-wrap: wrap; gap: 10px 20px; align-items: center; }
.calc-h { width: 100%; font-weight: 700; color: #86efac; font-size: 14px; }
.calc label { display: flex; align-items: center; gap: 8px; font-size: 14.5px; }
.calc input[type=range] { width: 160px; accent-color: #22c55e; } .calc output { min-width: 52px; font-weight: 700; color: #fff; }
.calc-out { width: 100%; } .calc-out b { display: block; font-size: 20px; color: #fff; } .calc-out span { color: #cbd5e1; font-size: 14px; }
.pinout { display: grid; gap: 4px; overflow-x: auto; }
.prow { display: grid; grid-template-columns: repeat(12, minmax(58px, 1fr)); gap: 4px; }
.pin { border-radius: 6px; background: #111827; border: 1px solid #1f2937; padding: 5px 3px; text-align: center; font-size: 11.5px; }
.pin i { display: block; height: 10px; border-radius: 3px; background: var(--pc); border: 1px solid #ffffff22; margin-bottom: 3px; }
.pin b { display: block; color: #fff; } .pin span { color: #cbd5e1; }
.chev { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 4px; }
.ch { padding: 10px 8px 10px 16px; background: color-mix(in srgb, #22d3ee calc(14% + var(--i) * 5%), #0f1623); clip-path: polygon(0 0, 90% 0, 100% 50%, 90% 100%, 0 100%, 10% 50%); font-size: 12.5px; min-height: 108px; }
.ch b { display: block; font-size: 18px; color: #fff; } .ch small { display: block; color: #a5f3fc; } .ch span { color: #e2e8f0; }
.divchain { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; font-size: 13px; }
.divchain span { padding: 4px 8px; border-radius: 6px; background: #1e293b; } .divchain span.q { background: #fb923c33; border: 1px solid #fb923c; } .divchain span.one { background: #22c55e33; border: 1px solid #22c55e; font-weight: 700; }
.divchain i { font-style: normal; color: var(--text2); font-size: 11px; }
.slots { display: grid; gap: 8px; } .sl { display: grid; grid-template-columns: 40px 1fr 70px; gap: 10px; align-items: center; font-size: 14px; }
.slb { height: 22px; border-radius: 4px; background: #111; border: 1px solid #475569; position: relative; } .slb i { position: absolute; left: 6px; right: 6px; top: 9px; height: 3px; background: #a855f7; }
.sl b { color: #fff; } .sl span { color: var(--text2); }
.nand { display: grid; gap: 8px; } .nr { display: grid; grid-template-columns: 50px 1fr 190px; gap: 10px; align-items: center; font-size: 14px; }
.lv { display: flex; gap: 2px; } .lv i { flex: 1; height: 22px; background: #3b82f6; border-radius: 3px; } .nr b { color: #fff; } .nr span { color: var(--text2); }
.m2k { display: grid; gap: 8px; } .m2k > div { display: grid; grid-template-columns: 90px 240px 1fr; gap: 12px; align-items: center; font-size: 14px; }
.mk { position: relative; height: 22px; border-radius: 3px; background: repeating-linear-gradient(90deg, #d8a64a 0 6px, #111827 6px 8px); }
.mk i { position: absolute; top: -1px; width: 16px; height: 15px; background: #0f1623; border-radius: 0 0 3px 3px; }
.m2k b { color: #fff; } .m2k span { color: var(--text2); }
.m2len { display: grid; gap: 4px; margin-top: 14px; } .m2len div { display: flex; align-items: center; gap: 10px; font-size: 13px; color: #cbd5e1; }
.m2len i { display: block; height: 12px; background: #1d5a3a; border: 1px solid #22c55e; border-radius: 2px; max-width: 360px; flex: none; }
.heat { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; } .heat > div { padding: 8px 12px; border-radius: 9px; border: 1px solid var(--c); background: color-mix(in srgb, var(--c) 14%, transparent); }
.heat b { display: block; color: #fff; font-size: 14px; } .heat span { font-size: 12px; color: #cbd5e1; } .heat > i { font-style: normal; color: var(--text2); }
.tflow { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 8px; }
.tq { padding: 10px 12px; border-radius: 10px; background: #111827; border-left: 4px solid #22d3ee; } .tq b { display: block; color: #fff; } .tq span { font-size: 14px; color: #cbd5e1; }
.quiz details { margin: 8px 0; border-radius: 10px; border: 1px solid #1f2937; background: #0f1623; }
.quiz summary { cursor: pointer; padding: 11px 14px; font-weight: 600; color: #fff; list-style: none; }
.quiz summary::after { content: ' – Lösung zeigen'; font-weight: 400; color: var(--accent); font-size: 13px; }
.quiz details[open] summary::after { content: ''; }
.quiz details p { padding: 0 14px 12px; color: #86efac; }
.d-foot { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 34px; padding-top: 18px; border-top: 1px solid #1f2937; }
.act-btn.more { background: rgba(255,255,255,.06); border-color: rgba(255,255,255,.2); }
@media (max-width: 900px) {
  .d-body { grid-template-columns: 1fr; } #d-nav { display: flex; overflow-x: auto; border-right: 0; border-bottom: 1px solid var(--border); padding: 6px; } #d-nav h4 { display: none; } #d-nav button { width: auto; white-space: nowrap; }
  .lad-row { grid-template-columns: 110px 1fr 70px; } .lad-s { display: none; } .chev { grid-template-columns: repeat(3, 1fr); } .m2k > div { grid-template-columns: 80px 1fr; } .m2k span { grid-column: 1 / -1; }
}

/* Druck: A4, weiß, Calibri */
@media print {
  @page { size: A4 portrait; margin: 15mm; }
  body > *:not(#detail) { display: none !important; }
  html, body { overflow: visible !important; height: auto; background: #fff !important; }
  #detail { position: static; background: #fff; display: block; }
  .d-head, #d-nav, .d-toc, .d-foot, .calc { display: none !important; }
  .d-body { display: block; }
  #d-article { overflow: visible; padding: 0; color: #000; font: 12pt/1.45 Calibri, sans-serif; }
  #d-article h1, #d-article h2, #d-article b, .core b, .pin b { color: #000 !important; }
  #d-article h2 { border-color: #888; break-after: avoid; }
  #d-article th { background: #e5e7eb !important; color: #000; } #d-article td { border-color: #ccc; color: #000; }
  .fig, .note, .quiz details, .coremap { background: #fff !important; border-color: #999 !important; color: #000; break-inside: avoid; }
  .fig .bt { fill: #000; } .fig .bs { fill: #333; } .quiz details p { color: #000; } .d-lead, #d-article p, #d-article li { color: #000; }
}

/* ================= Konto, Quiz, Bestenliste ================= */
#account { display: flex; align-items: center; gap: 8px; margin-top: 8px; flex-wrap: wrap; }
#account:empty { display: none; }
.acc-btn { padding: 7px 12px; border-radius: 9px; border: 1px solid #38bdf866; background: #38bdf822; color: #fff; font-size: 13.5px; font-weight: 600; cursor: pointer; }
.acc-btn.small { padding: 5px 9px; font-size: 12.5px; font-weight: 500; background: rgba(255,255,255,.05); border-color: var(--border); }
.acc-chip b { display: block; font-size: 14px; } .acc-chip span { font-size: 12px; color: var(--text2); }
.acc-pts { display: flex; gap: 6px; margin-left: auto; } .acc-pts span { padding: 4px 8px; border-radius: 7px; background: rgba(250,204,21,.14); color: #fde68a; font-size: 13px; font-weight: 700; }
.acc-guest { font-size: 12px; color: var(--text2); padding: 3px 8px; border: 1px dashed #475569; border-radius: 7px; }
.modal { position: fixed; inset: 0; z-index: 45; display: grid; place-items: center; background: rgba(2,4,9,.7); padding: 16px; }
.modal-box { position: relative; width: min(460px, 100%); max-height: calc(100vh - 32px); overflow: auto; padding: 20px; background: #0e1420; }
.modal-box.wide { width: min(980px, 100%); }
.modal-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; } .modal-head h2 { font-size: 22px; }
#auth-close { position: absolute; right: 14px; top: 14px; }
.auth-tabs, .sc-tabs { display: flex; gap: 4px; margin-bottom: 14px; flex-wrap: wrap; }
.auth-tab, .sc-tab { padding: 8px 14px; border-radius: 9px; border: 1px solid var(--border); background: transparent; color: var(--text2); font-size: 14px; font-weight: 600; cursor: pointer; }
.auth-tab.active, .sc-tab.active { background: #38bdf8; color: #0b1220; border-color: #38bdf8; }
#auth form { display: grid; gap: 10px; }
#auth label { display: grid; gap: 4px; font-size: 13.5px; color: #cbd5e1; } #auth label small { color: var(--text2); }
#auth input, #auth select, .sc-filter select { padding: 9px 10px; border-radius: 8px; border: 1px solid #334155; background: #0b1220; color: #fff; font-size: 15px; font-family: inherit; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.primary { padding: 11px; border-radius: 10px; border: 0; background: #22c55e; color: #052e16; font-weight: 700; font-size: 15px; cursor: pointer; }
.privacy { font-size: 12.5px; color: var(--text2); line-height: 1.4; }
.auth-msg { margin-top: 10px; color: #fca5a5; font-size: 14px; min-height: 1em; }
/* Szenario-Wertung */
.scen-track { font-size: 12.5px; margin: 2px 0 8px; } .scen-track .live { color: #4ade80; font-weight: 700; } .scen-track .off { color: var(--text2); }
#sc-timer { float: right; font-family: Consolas, monospace; color: #fff; }
.result { margin-top: 10px; } .res-stars { font-size: 30px; color: #facc15; letter-spacing: 3px; } .res-line { font-size: 13.5px; color: #e2e8f0; }
.res-note { margin-top: 6px; font-size: 13px; color: #fde68a; }
.badge { margin-top: 6px; padding: 6px 9px; border-radius: 8px; background: rgba(250,204,21,.14); border: 1px solid #facc1555; font-size: 13.5px; }
.scen-card .lvl { font-size: 11.5px; color: var(--text2); letter-spacing: 1px; }
.scen-card .my-best { float: right; color: #facc15; font-size: 12.5px; }
/* Quiz */
.q-info { color: #cbd5e1; font-size: 14.5px; margin-bottom: 12px; }
.q-topics { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 8px; }
.q-topic { text-align: left; padding: 12px; border-radius: 11px; border: 1px solid var(--border); background: rgba(255,255,255,.03); color: #fff; cursor: pointer; display: grid; gap: 2px; }
.q-topic:hover { border-color: #a855f7; background: rgba(168,85,247,.1); } .q-topic.mix { border-color: #a855f788; background: rgba(168,85,247,.12); }
.q-topic span { font-size: 12.5px; color: var(--text2); } .q-topic em { font-style: normal; font-size: 12.5px; color: #86efac; }
.q-head { display: flex; justify-content: space-between; font-size: 13px; color: var(--text2); }
.q-prog { height: 4px; border-radius: 2px; background: #1e293b; margin: 8px 0 16px; } .q-prog i { display: block; height: 100%; background: #a855f7; border-radius: 2px; transition: width .3s; }
.q-q { font-size: 22px; line-height: 1.3; margin-bottom: 14px; }
.q-opts { display: grid; gap: 8px; }
.q-opt { display: flex; gap: 12px; align-items: center; text-align: left; padding: 13px 14px; border-radius: 11px; border: 1px solid #334155; background: #111827; color: #fff; font-size: 16px; cursor: pointer; font-family: inherit; }
.q-opt span { flex: 0 0 28px; height: 28px; border-radius: 7px; display: grid; place-content: center; background: #1e293b; font-weight: 700; }
.q-opt:hover:not(:disabled) { border-color: #a855f7; }
.q-opt.right { border-color: #22c55e; background: rgba(34,197,94,.16); } .q-opt.right span { background: #22c55e; color: #052e16; }
.q-opt.wrong { border-color: #ef4444; background: rgba(239,68,68,.16); } .q-opt.wrong span { background: #ef4444; }
.q-fb { margin-top: 14px; padding: 11px 14px; border-radius: 10px; font-size: 15px; } .q-fb.ok { background: rgba(34,197,94,.12); border: 1px solid #22c55e66; } .q-fb.no { background: rgba(239,68,68,.12); border: 1px solid #ef444466; }
.q-next, .q-end-btns button { margin-top: 12px; padding: 10px 16px; border-radius: 10px; border: 0; background: #a855f7; color: #fff; font-weight: 700; font-size: 15px; cursor: pointer; }
.q-end { text-align: center; padding: 20px 0; } .q-score { font-size: 56px; font-weight: 800; color: #fff; } .q-pct { color: var(--text2); margin-bottom: 12px; }
.q-end-btns { display: flex; gap: 10px; justify-content: center; }
/* Bestenliste */
.sc-filter { display: flex; flex-wrap: wrap; gap: 12px; align-items: end; margin-bottom: 12px; } .sc-filter label { display: grid; gap: 3px; font-size: 12.5px; color: var(--text2); }
.sc-table { width: 100%; border-collapse: collapse; font-size: 15px; }
.sc-table th { text-align: left; padding: 8px 10px; font-size: 12.5px; color: var(--text2); border-bottom: 1px solid #334155; font-weight: 600; }
.sc-table td { padding: 8px 10px; border-bottom: 1px solid #1f2937; } .sc-table td.rk { width: 56px; font-size: 18px; }
.sc-table tr.me td { background: rgba(56,189,248,.14); } .sc-table .stars { color: #facc15; }
.rec-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 10px; }
.rec { padding: 12px; border-radius: 11px; background: #111827; border: 1px solid #1f2937; } .rec h4 { font-size: 15px; margin-bottom: 6px; }
.rec-first { font-size: 13.5px; margin-bottom: 6px; } .rec small { color: var(--text2); }
.rec ol { margin: 0 0 6px 18px; font-size: 13.5px; } .rec li { display: list-item; } .rec li span { display: inline-block; min-width: 70%; } .rec li b { float: right; font-family: Consolas, monospace; }
.rec-n { display: block; }
.controls { flex-wrap: wrap; justify-content: center; max-width: calc(100vw - 480px); }
.t-link { display: none; font-size: 12px; color: var(--text2); margin-top: 6px; }
body.is-online .t-link { display: inline-block; }
.seq-beep { margin-top: 8px; padding: 7px 11px; border-radius: 9px; background: rgba(250,204,21,.1); border: 1px dashed #facc1588; font-size: 14px; cursor: pointer; }
.seq-beep b { color: #fde68a; letter-spacing: .03em; } .seq-beep small { color: var(--text2); }
/* Wettkampf-Banner (Schüler) */
#comp-banner { position: fixed; right: 16px; top: 16px; z-index: 13; width: 300px; padding: 12px 14px; border: 1px solid #facc1588; background: rgba(20,16,4,.92); }
#comp-banner .cmp-head { display: flex; align-items: center; gap: 8px; } #comp-banner .cmp-head span { font-size: 11px; letter-spacing: .14em; color: #facc15; font-weight: 800; }
#comp-banner .cmp-head b { font-size: 15px; flex: 1; } .cmp-x { border: 0; background: transparent; color: #cbd5e1; cursor: pointer; font-size: 16px; }
.cmp-big { font: 800 30px Consolas, monospace; color: #facc15; margin: 6px 0 2px; } .cmp-big.warn { color: #f87171; }
.cmp-small { font-size: 13.5px; color: #e2e8f0; } .cmp-top { display: grid; gap: 3px; margin: 6px 0; font-size: 14px; } .cmp-top b { float: right; font-family: Consolas, monospace; }
body.in-comp #inspector { top: 190px; }
.scen-comp { margin: 2px 0 6px; padding: 6px 9px; border-radius: 8px; background: rgba(250,204,21,.12); border: 1px solid #facc1566; font-size: 13.5px; }
/* Prüfung + Bericht */
#comp-banner.exam { border-color: #38bdf8aa; background: rgba(4,14,24,.94); } #comp-banner.exam .cmp-head span { color: #38bdf8; } #comp-banner.exam .cmp-big { color: #7dd3fc; }
body.in-exam #btn-quiz, body.in-exam #btn-scores, body.in-exam:not(.exam-lexikon) #btn-lexikon, body.in-exam:not(.exam-lexikon) .act-btn.more { display: none !important; }
body.in-exam #scen-list { display: none !important; }
.rep-form { display: grid; gap: 12px; } .rep-form label { display: grid; gap: 5px; font-size: 14px; color: #cbd5e1; } .rep-form b { color: #fff; }
.rep-form textarea { padding: 9px 10px; border-radius: 9px; border: 1px solid #334155; background: #0b1220; color: #fff; font: 15px/1.4 Calibri, sans-serif; resize: vertical; }
.tool-box { margin-top: 10px; padding: 10px 12px; border-radius: 10px; background: #0b1220; border: 1px solid #334155; font-size: 13.5px; display: grid; gap: 6px; }
.tool-box small { color: var(--text2); } .tool-box b.bad, .mtab b.bad { color: #f87171; } .mtab b.good { color: #4ade80; }
.tool-box select { padding: 7px; border-radius: 7px; background: #0f172a; color: #fff; border: 1px solid #334155; font-size: 14px; }
.mtab { border-collapse: collapse; font-size: 13.5px; } .mtab td { padding: 3px 8px 3px 0; }
.rep-form label { display: block; } .rep-form textarea { display: block; width: 100%; margin-top: 5px; }

/* ================= BIOS-Setup ================= */
.seq-del { display: block; width: 100%; margin-top: 8px; padding: 7px 11px; border-radius: 9px; border: 1px solid #f59e0b88; background: rgba(245,158,11,.1); color: #fcd34d; font-size: 14px; cursor: pointer; text-align: left; }
.seq-del:hover, .seq-del.on { background: rgba(245,158,11,.25); }
#biosui { position: fixed; inset: 0; z-index: 400; background: radial-gradient(ellipse at 30% 0%, #1d2433 0%, #07090d 70%); color: #d7dde8; font-family: 'Segoe UI', Calibri, system-ui, sans-serif; display: flex; align-items: center; justify-content: center; }
#biosui .b-frame { position: relative; width: min(1180px, 96vw); height: min(760px, 94vh); display: flex; flex-direction: column; border: 1px solid #f59e0b55; border-radius: 6px; background: linear-gradient(180deg, #11151d, #0a0d12); box-shadow: 0 0 60px #000a, inset 0 0 0 1px #ffffff08; overflow: hidden; }
#biosui .b-top { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 12px 20px; background: linear-gradient(90deg, #f59e0b22, transparent 50%); border-bottom: 1px solid #f59e0b44; }
#biosui .b-brand { font-size: 20px; letter-spacing: .04em; } #biosui .b-brand b { color: #f59e0b; font-weight: 800; } #biosui .b-brand small { margin-left: 10px; font-size: 13px; color: #8b95a7; }
#biosui .b-stats { display: flex; gap: 18px; } #biosui .b-stats span { display: flex; flex-direction: column; align-items: flex-end; } #biosui .b-stats small { font-size: 11px; color: #8b95a7; text-transform: uppercase; letter-spacing: .06em; } #biosui .b-stats b { font-size: 16px; font-variant-numeric: tabular-nums; color: #fff; } #biosui .b-stats .bad b { color: #f87171; }
#biosui .b-tabs { display: flex; gap: 2px; padding: 0 14px; background: #0d1016; border-bottom: 2px solid #f59e0b; }
#biosui .b-tabs button { padding: 10px 22px; border: 0; background: transparent; color: #9aa4b5; font-size: 16px; cursor: pointer; border-radius: 4px 4px 0 0; }
#biosui .b-tabs button.on { background: #f59e0b; color: #111; font-weight: 700; }
#biosui .b-body { flex: 1; display: grid; grid-template-columns: 1fr 340px; min-height: 0; }
#biosui .b-list { overflow: auto; padding: 10px 14px 20px; }
#biosui .b-h { margin: 14px 4px 4px; font-size: 12px; text-transform: uppercase; letter-spacing: .1em; color: #f59e0b; border-bottom: 1px solid #f59e0b33; padding-bottom: 3px; }
#biosui .b-row { display: flex; justify-content: space-between; gap: 16px; padding: 7px 10px; border-radius: 4px; cursor: pointer; font-size: 15px; border: 1px solid transparent; }
#biosui .b-row:hover { background: #ffffff08; }
#biosui .b-row.on { background: linear-gradient(90deg, #f59e0b33, #f59e0b11); border-color: #f59e0b88; }
#biosui .b-row.ro .b-l { color: #8b95a7; } #biosui .b-row.ro .b-v { color: #c7cfdc; }
#biosui .b-row.lk .b-v { color: #6b7280; } #biosui .b-row.lk .b-l::after { content: ' 🔒'; font-size: 11px; }
#biosui .b-row.act .b-l { color: #fcd34d; }
#biosui .b-v { color: #7dd3fc; text-align: right; font-variant-numeric: tabular-nums; } #biosui .b-v.ch { color: #fbbf24; font-weight: 700; } #biosui .b-v.ch::before { content: '* '; }
#biosui .b-help { border-left: 1px solid #ffffff14; padding: 16px 18px; background: #0c0f15; overflow: auto; font-size: 14px; line-height: 1.45; }
#biosui .b-help h4 { color: #f59e0b; margin-bottom: 8px; font-size: 15px; } #biosui .b-help p { margin-bottom: 9px; color: #c3cad6; }
#biosui .b-lock { color: #fca5a5 !important; } #biosui .b-keyhint { color: #8b95a7 !important; font-size: 12px; }
#biosui .b-curve { width: 100%; margin-top: 6px; } #biosui .b-curve .ax { fill: none; stroke: #4b5563; } #biosui .b-curve .cv { fill: none; stroke: #f59e0b; stroke-width: 2.5; } #biosui .b-curve circle { fill: #f59e0b; } #biosui .b-curve .now { stroke: #38bdf8; stroke-dasharray: 3 3; } #biosui .b-curve text { fill: #8b95a7; font-size: 10px; }
#biosui .b-keys { display: flex; flex-wrap: wrap; gap: 6px; padding: 9px 14px; border-top: 1px solid #ffffff14; background: #0d1016; }
#biosui .b-keys button { border: 1px solid #ffffff22; background: #161b24; color: #c7cfdc; border-radius: 4px; padding: 5px 10px; font-size: 13px; cursor: pointer; } #biosui .b-keys button:hover { border-color: #f59e0b; color: #fff; }
#biosui .b-flash { position: absolute; left: 50%; bottom: 60px; transform: translate(-50%, 20px); opacity: 0; transition: .25s; padding: 9px 16px; background: #1f2937; border: 1px solid #f59e0b; border-radius: 6px; font-size: 14px; pointer-events: none; max-width: 80%; }
#biosui .b-flash.on { opacity: 1; transform: translate(-50%, 0); }
#biosui .b-pop { position: absolute; inset: 0; background: #0009; display: flex; align-items: center; justify-content: center; }
#biosui .b-box { min-width: 320px; max-width: 560px; background: #141922; border: 1px solid #f59e0b; border-radius: 6px; padding: 14px; box-shadow: 0 10px 40px #000; }
#biosui .b-box h5 { font-size: 15px; color: #f59e0b; margin-bottom: 10px; }
#biosui .b-opt { padding: 7px 10px; border-radius: 4px; cursor: pointer; font-size: 15px; } #biosui .b-opt.on { background: #f59e0b; color: #111; font-weight: 700; } #biosui .b-opt:hover:not(.on) { background: #ffffff10; }
#biosui .b-dlg p { margin-bottom: 8px; font-size: 14px; } #biosui .b-small { color: #8b95a7; font-size: 12px !important; }
#biosui .b-ch { width: 100%; border-collapse: collapse; font-size: 14px; margin-bottom: 8px; } #biosui .b-ch td { padding: 3px 6px; border-bottom: 1px solid #ffffff10; } #biosui .b-ch b { color: #fbbf24; }
#biosui .b-yn { display: flex; gap: 10px; justify-content: flex-end; margin-top: 10px; } #biosui .b-yn button { min-width: 90px; padding: 7px 14px; border-radius: 4px; border: 1px solid #f59e0b88; background: transparent; color: #ddd; font-size: 15px; cursor: pointer; } #biosui .b-yn button.on { background: #f59e0b; color: #111; font-weight: 700; }
@media (max-width: 800px) { #biosui .b-body { grid-template-columns: 1fr; } #biosui .b-help { max-height: 34vh; border-left: 0; border-top: 1px solid #ffffff14; } #biosui .b-stats span:nth-child(n+3):not(.b-clock) { display: none; } }

/* ================= PC-Konfigurator ================= */
#konfig { z-index: 60; padding: 10px; }
.kf { width: min(1400px, 100%); height: calc(100vh - 20px); display: flex; flex-direction: column; background: #0d131e; border-radius: 14px; overflow: hidden; font-size: 15px; }
.kf-head { display: flex; align-items: center; gap: 16px; padding: 12px 18px; border-bottom: 1px solid var(--border); }
.kf-head h2 { font-size: 21px; } .kf-ord { margin-left: auto; color: var(--text2); } .kf-ord select { margin-left: 6px; padding: 6px 8px; border-radius: 8px; background: #141c2a; color: var(--text); border: 1px solid var(--border); font-size: 15px; }
.kf-order { padding: 10px 18px; background: linear-gradient(90deg, #22c55e12, transparent); border-bottom: 1px solid var(--border); }
.kf-order p { margin: 4px 0 8px; color: #cbd5e1; line-height: 1.4; }
.kf-reqs { display: flex; flex-wrap: wrap; gap: 6px; } .kf-reqs span { padding: 3px 10px; border-radius: 99px; background: #1e293b; font-size: 13px; color: #cbd5e1; } .kf-reqs span.ok { background: #14532d; color: #bbf7d0; }
.kf-nav { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 8px 18px; border-bottom: 1px solid var(--border); flex-wrap: wrap; }
.kf-steps, .kf-vars { display: flex; gap: 6px; align-items: center; color: var(--text2); }
.kf-nav button { padding: 7px 14px; border-radius: 8px; border: 1px solid var(--border); background: #141c2a; color: var(--text); cursor: pointer; font-size: 14px; }
.kf-nav button.on { background: var(--accent); color: #04121c; font-weight: 700; border-color: var(--accent); }
.kf-vars button small { display: block; font-size: 11px; opacity: .8; }
.kf-body { flex: 1; min-height: 0; overflow: auto; }
.kf-foot { padding: 6px 18px; font-size: 12px; color: var(--text2); border-top: 1px solid var(--border); }
.kf-parts { display: grid; grid-template-columns: 250px 1fr 340px; height: 100%; }
.kf-cats { border-right: 1px solid var(--border); overflow: auto; padding: 8px; display: flex; flex-direction: column; gap: 4px; }
.kf-cats button { display: flex; gap: 10px; align-items: center; text-align: left; padding: 8px 10px; border-radius: 9px; border: 1px solid transparent; background: transparent; color: var(--text); cursor: pointer; }
.kf-cats button > span { font-size: 18px; width: 22px; text-align: center; } .kf-cats b { display: block; font-size: 14px; } .kf-cats small { font-size: 12px; color: #f87171; }
.kf-cats button.set small { color: #86efac; } .kf-cats button.opt small { color: var(--text2); }
.kf-cats button.on { background: #1e293b; border-color: var(--accent); }
.kf-compat { margin-top: 10px; padding: 8px; font-size: 13px; color: var(--text2); display: flex; gap: 6px; align-items: center; }
.kf-list { overflow: auto; padding: 12px 16px; } .kf-list h3 { margin-bottom: 8px; }
.kf-part { display: grid; grid-template-columns: 20px 1fr auto; gap: 10px; align-items: center; padding: 9px 12px; margin-bottom: 6px; border-radius: 10px; border: 1px solid var(--border); background: #111827; cursor: pointer; }
.kf-part:hover { border-color: #38bdf888; } .kf-part.on { border-color: var(--accent); background: #0c2233; }
.kf-part small { display: block; color: var(--text2); font-size: 13px; margin-top: 2px; } .kf-part i { display: block; color: #f87171; font-size: 12px; font-style: normal; }
.kf-part.bad { opacity: .7; border-style: dashed; border-color: #f8717188; }
.kf-price { font-weight: 700; white-space: nowrap; } .kf-3d { font-style: normal; font-size: 11px; background: #7c3aed; color: #fff; padding: 1px 6px; border-radius: 99px; }
.kf-sum { border-left: 1px solid var(--border); overflow: auto; padding: 12px 14px; display: flex; flex-direction: column; gap: 8px; }
.kf-sum h4 { margin-top: 6px; font-size: 13px; text-transform: uppercase; letter-spacing: .06em; color: var(--text2); }
.kf-total, .kf-power { padding: 10px; border-radius: 10px; background: #111827; display: grid; grid-template-columns: 1fr auto; gap: 2px 8px; }
.kf-total b { font-size: 22px; } .kf-total small, .kf-power small { grid-column: 1 / -1; color: var(--text2); font-size: 12px; } .kf-total.over b { color: #f87171; }
.kf-bar { grid-column: 1 / -1; position: relative; height: 7px; border-radius: 9px; background: #1f2937; margin-top: 4px; } .kf-bar i { position: absolute; inset: 0 auto 0 0; border-radius: 9px; background: #22c55e; } .kf-total.over .kf-bar i { background: #ef4444; }
.kf-bar.pw i { background: #f59e0b; } .kf-bar em { position: absolute; top: -4px; bottom: -4px; width: 3px; background: #38bdf8; border-radius: 2px; }
.kf-issues, .kf-rq { list-style: none; display: flex; flex-direction: column; gap: 5px; font-size: 13px; }
.kf-issues li { padding: 6px 9px; border-radius: 8px; line-height: 1.35; } .kf-issues .err { background: #7f1d1d55; border-left: 3px solid #ef4444; } .kf-issues .warn { background: #78350f55; border-left: 3px solid #f59e0b; } .kf-issues .info { background: #1e293b; border-left: 3px solid #64748b; color: #cbd5e1; } .kf-issues .good { background: #14532d55; border-left: 3px solid #22c55e; }
.kf-rq li { display: grid; grid-template-columns: 18px 1fr; } .kf-rq li span { font-weight: 700; } .kf-rq li.ok span { color: #22c55e; } .kf-rq li.no span { color: #f87171; } .kf-rq small { grid-column: 2; color: var(--text2); }
.kf-hint3d { font-size: 12px; color: var(--text2); }
.kf-matrix, .kf-submit { padding: 14px 18px; } .kf-intro { color: #cbd5e1; margin-bottom: 10px; max-width: 900px; }
.kf-matrix h3, .kf-submit h3 { margin: 14px 0 6px; }
.kf-tab { border-collapse: collapse; width: 100%; max-width: 1000px; font-size: 14px; } .kf-tab th, .kf-tab td { padding: 6px 9px; border-bottom: 1px solid var(--border); text-align: left; } .kf-tab thead th { color: var(--text2); font-weight: 600; } .kf-tab th small { display: block; font-weight: 400; font-size: 11px; }
.kf-tab input { width: 64px; padding: 4px 6px; border-radius: 6px; border: 1px solid var(--border); background: #111827; color: var(--text); font-size: 14px; } .kf-tab input.kf-cn { width: 170px; }
.kf-tab td span[data-ws] { color: var(--text2); font-size: 12px; } .kf-tab tr.sum td, .kf-tab tr.sum th { font-weight: 700; border-top: 2px solid var(--border); }
.kf-tab .bad, .kf-matrix .bad { color: #f87171; } .kf-tab b.best { color: #22c55e; font-size: 17px; } .kf-tab td.r { text-align: right; }
.kf-mx-btns { display: flex; gap: 8px; margin: 10px 0; } .kf-mx-btns button, .kf-sub-btns button { padding: 7px 12px; border-radius: 8px; border: 1px solid var(--border); background: #141c2a; color: var(--text); cursor: pointer; }
.kf-best { padding: 9px 12px; background: #14532d55; border-radius: 9px; display: inline-block; }
.kf-submit { display: grid; grid-template-columns: 1fr 340px; gap: 24px; }
.kf-rb { margin-left: 10px; } .kf-reason { display: block; margin-top: 12px; color: #cbd5e1; } .kf-reason textarea { display: block; width: 100%; margin-top: 6px; padding: 9px; border-radius: 9px; background: #111827; color: var(--text); border: 1px solid var(--border); font: inherit; }
.kf-sub-btns { display: flex; gap: 12px; align-items: center; margin-top: 10px; } .kf-sub-btns .primary { background: var(--accent); color: #04121c; font-weight: 700; border: 0; } .kf-sub-btns button:disabled { opacity: .5; }
#kf-msg { color: #fca5a5; } .kf-prev { padding: 9px; border-radius: 9px; background: #111827; margin-bottom: 8px; font-size: 13px; } .kf-prev p { margin-top: 5px; color: #fde68a; }
.kf-issues.small { margin-top: 8px; }
#kf-3d { padding: 9px; border-radius: 9px; border: 0; background: #7c3aed; color: #fff; font-weight: 700; cursor: pointer; font-size: 14px; }
@media (max-width: 1000px) { .kf-parts { grid-template-columns: 1fr; height: auto; } .kf-cats { flex-direction: row; flex-wrap: wrap; border-right: 0; } .kf-cats button { flex: 1 1 140px; } .kf-sum { border-left: 0; } .kf-submit { grid-template-columns: 1fr; } }

/* ================= Gehäuse & Abzeichen ================= */
.case-check { list-style: none; display: flex; flex-direction: column; gap: 4px; margin: 6px 0 4px; font-size: 14px; }
.case-check li { display: grid; grid-template-columns: 20px 1fr; color: #cbd5e1; } .case-check span { font-weight: 700; color: #64748b; }
.case-check li.ok span { color: #22c55e; } .case-check li.warn span, .case-check li.warn { color: #f87171; }
.bdg-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px; }
.bdg { display: grid; grid-template-columns: 46px 1fr; grid-template-rows: auto auto; gap: 0 10px; padding: 10px; border-radius: 12px; background: #111827; border: 1px solid var(--border); opacity: .45; filter: grayscale(1); }
.bdg.on { opacity: 1; filter: none; border-color: #facc1588; background: linear-gradient(135deg, #2a2208, #111827 60%); }
.bdg > span { grid-row: 1 / 3; font-size: 32px; display: grid; place-items: center; } .bdg b { font-size: 15px; } .bdg small { color: var(--text2); font-size: 12.5px; line-height: 1.3; }
.bdg-mini i { font-style: normal; font-size: 13px; margin-left: 1px; }


/* ================= Zweisprachig ================= */
.top-links { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.lang-l { font-size: 13px; color: var(--text2); display: inline-flex; align-items: center; gap: 4px; }
.lang-sel { background: #141c2a; color: var(--text); border: 1px solid var(--border); border-radius: 7px; padding: 3px 6px; font-size: 13px; }
.tl { display: block; font-size: .84em; line-height: 1.3; color: #7dd3fc; font-style: italic; font-weight: 400; margin-top: 2px; text-transform: none; letter-spacing: 0; }
.tl.in { display: inline; margin: 0 0 0 .45em; }
.tl.in::before { content: '/ '; opacity: .6; }
.tl.tiny { display: block; margin: 0; font-size: .74em; }
.tl.tiny::before { content: none; }
.tl:lang(uk) { font-style: normal; }
.toast .tl { color: #bae6fd; }
@media print { .tl { color: #1d4ed8; } }
x-tl { display: inline; } x-tlw { display: block; min-width: 0; }
x-tl.tl:not(.in):not(.tiny) { display: block; }
.reg-check { font-size: 13.5px; min-height: 1.2em; margin: 2px 0 6px; } .reg-check.bad { color: #fca5a5; } .reg-check.good { color: #86efac; }
#auth button:disabled { opacity: .45; cursor: not-allowed; }

/* ================= Tablet & Smartphone (v12) ================= */
.controls .ic { display: inline; } .controls .lb { display: inline; margin-left: 4px; }
body.ui-touch .pin-badge { padding: 6px 12px 6px 9px; }
body.ui-touch button, body.ui-touch select { touch-action: manipulation; }

/* Tablet: Kopf kompakt oben links, Bedienleiste als Leiste rechts */
body.ui-compact .top { top: 10px; left: 10px; padding: 8px 12px; max-width: 320px; }
body.ui-compact .top h1 { font-size: 16px; }
body.ui-compact .top > p { display: none; }
body.ui-compact #account { margin-top: 6px; }
body.ui-compact .controls { max-width: none; flex-wrap: nowrap; top: 10px; bottom: 10px; right: 10px; left: auto; transform: none; flex-direction: column; justify-content: flex-start;
  width: 72px; padding: 4px; gap: 2px; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: none; }
body.ui-compact .controls::-webkit-scrollbar { display: none; }
body.ui-compact .controls button { display: flex; flex-direction: column; align-items: center; gap: 1px; padding: 5px 2px; white-space: normal; text-align: center; line-height: 1.1; flex: 0 0 auto; }
body.ui-compact .controls .ic { font-size: 18px; line-height: 1.2; }
body.ui-compact .controls .lb { margin: 0; font-size: 10.5px; }
body.ui-compact .controls .tl { font-size: 9px; margin-top: 1px; }
body.ui-compact #side { left: 10px; top: calc(var(--hdr, 94px) + 18px); bottom: 64px; width: 290px; }
body.ui-compact #inspector { right: 92px; top: 10px; bottom: 64px; width: 320px; transform: translateX(calc(100% + 120px)); }
body.ui-compact #inspector.open { transform: none; }
body.ui-compact #bottom-dock { left: 10px; right: 92px; bottom: 10px; transform: none; max-width: none; }
body.ui-compact .dock-item { padding: 6px 9px; font-size: 12px; }
body.ui-compact .hint { display: none; }
body.ui-compact #seq-banner { left: calc((100vw - 82px) / 2); bottom: 64px; width: min(620px, calc(100vw - 112px)); max-height: 48vh; overflow: auto; }
body.ui-compact #comp-banner { right: 92px; top: 10px; }
body.ui-compact.in-comp #inspector { top: 190px; }
body.ui-compact .toast { left: calc((100vw - 82px) / 2); max-width: calc(100vw - 120px); }

/* Schmal (Tablet hochkant): Info-Fenster als Blatt von unten */
body.ui-narrow #inspector { left: 10px; right: 92px; top: auto; bottom: 64px; width: auto; max-height: 52vh; transform: translateY(calc(100% + 30px)); }
body.ui-narrow #inspector.open { transform: none; }
body.ui-narrow #side { width: min(320px, calc(100vw - 112px)); }

/* Smartphone */
body.ui-phone .top { top: 6px; left: 6px; padding: 5px 9px; max-width: calc(100vw - 70px); display: flex; flex-wrap: wrap; align-items: center; gap: 2px 10px; }
body.ui-phone .top .status { margin: 0; font-size: 0; gap: 0; }
body.ui-phone .top .status-led { width: 10px; height: 10px; }
body.ui-phone .top h1 { font-size: 13px; white-space: nowrap; }
body.ui-phone #account { margin: 0; gap: 6px; flex-wrap: nowrap; }
body.ui-phone .acc-btn { padding: 4px 8px; font-size: 12px; }
body.ui-phone .acc-chip b { font-size: 12.5px; } body.ui-phone .acc-chip span, body.ui-phone .acc-pts { display: none; }
body.ui-phone .top-links { gap: 6px; } body.ui-phone .t-link { display: none !important; }
body.ui-phone .lang-sel { font-size: 12px; padding: 2px 4px; max-width: 150px; }
body.ui-phone .controls { top: 6px; bottom: 6px; right: 6px; width: 48px; padding: 3px; }
body.ui-phone .controls button { padding: 6px 0; }
body.ui-phone .controls .lb { display: none; }
body.ui-phone .controls .ic { font-size: 19px; }
body.ui-phone #side { left: 6px; top: calc(var(--hdr, 40px) + 12px); bottom: 6px; width: min(310px, calc(100vw - 66px)); z-index: 14; }
body.ui-phone .tab { font-size: 12.5px; padding: 7px 2px; }
body.ui-phone .tab-page { padding: 8px 10px 12px; }
body.ui-phone #inspector { right: 60px; top: 6px; bottom: 6px; left: auto; width: min(340px, calc(100vw - 72px)); max-height: none; transform: translateX(calc(100% + 80px)); z-index: 14; }
body.ui-phone #inspector.open { transform: none; }
body.ui-phone .insp-head { padding: 10px 12px 6px; } body.ui-phone .insp-body { padding: 0 12px 12px; }
body.ui-phone #inspector h2 { font-size: 17px; } body.ui-phone #inspector-desc { font-size: 13.5px; }
body.ui-phone #bottom-dock { display: none; }
body.ui-phone #seq-banner { left: calc((100vw - 60px) / 2); bottom: 6px; width: calc(100vw - 76px); padding: 8px 12px; max-height: 46vh; }
body.ui-phone #seq-banner h2 { font-size: 16px; } body.ui-phone #seq-desc { font-size: 13px; }
body.ui-phone #comp-banner { right: 60px; top: 6px; width: min(260px, calc(100vw - 72px)); padding: 8px 10px; font-size: 12.5px; }
body.ui-phone .toast { top: 50px; left: calc((100vw - 60px) / 2); max-width: calc(100vw - 80px); font-size: 13px; }
body.ui-phone .pin-badge { font-size: 10.5px; padding: 3px 8px 3px 6px; }
body.ui-phone .pin-stem { height: 10px; }
body.ui-phone .modal { padding: 6px; } body.ui-phone .modal-box { padding: 14px; max-height: calc(100vh - 12px); }
/* Handy hochkant: Info-Fenster als Blatt von unten */
body.ui-phone.ui-portrait #inspector { left: 6px; right: 60px; top: auto; bottom: 6px; width: auto; max-height: 55vh; transform: translateY(calc(100% + 20px)); }
body.ui-phone.ui-portrait #inspector.open { transform: none; }
body.ui-phone.ui-portrait #side { width: calc(100vw - 66px); }
/* Konfigurator auf kleinen Bildschirmen: ganze Box scrollt */
@media (max-height: 640px), (max-width: 700px) {
  #konfig { padding: 4px; }
  .kf { display: block; height: calc(100vh - 8px); overflow: auto; font-size: 14px; }
  .kf-head { padding: 8px 12px; gap: 8px; flex-wrap: wrap; } .kf-head h2 { font-size: 17px; }
  .kf-order { padding: 8px 12px; } .kf-order p { font-size: 13px; margin: 2px 0 6px; } .kf-reqs span { font-size: 12px; }
  .kf-nav { padding: 6px 12px; position: sticky; top: 0; z-index: 2; background: #0d131e; } .kf-nav button { padding: 6px 10px; font-size: 13px; }
  .kf-body { overflow: visible; }
  .kf-parts { grid-template-columns: 1fr; height: auto; }
  .kf-cats { flex-direction: row; flex-wrap: nowrap; overflow-x: auto; border-right: 0; border-bottom: 1px solid var(--border); }
  .kf-cats button { flex: 0 0 auto; padding: 6px 9px; } .kf-cats small { display: none; } .kf-compat { flex: 0 0 auto; margin: 0; }
  .kf-list { overflow: visible; padding: 10px 12px; } .kf-sum { border-left: 0; overflow: visible; } .kf-submit { grid-template-columns: 1fr; }
}

/* ================= AR & Cardboard ================= */
.ar-box { width: min(440px, 100%); }
.ar-text { margin: 6px 0 12px; line-height: 1.45; color: #dbe3ee; }
.ar-go, .ar-dl { display: flex; align-items: center; justify-content: center; gap: 8px; padding: 12px; border-radius: 11px; background: var(--accent); color: #04121c; font-weight: 700; font-size: 16px; text-decoration: none; }
.ar-go img { position: absolute; opacity: 0; }
.ar-dl { background: #1e293b; color: #fff; }
.ar-tips { margin: 14px 0 0 18px; font-size: 13.5px; color: var(--text2); line-height: 1.5; }
body.vr-on header.top, body.vr-on .controls, body.vr-on #side, body.vr-on #inspector, body.vr-on #bottom-dock, body.vr-on .hint,
body.vr-on #seq-banner, body.vr-on #comp-banner, body.vr-on .vignette, body.vr-on .toast { display: none !important; }
#vr-ui { position: fixed; inset: 0; z-index: 70; }
#vr-ui .vr-mid { position: absolute; left: 50%; top: 0; bottom: 0; width: 2px; margin-left: -1px; background: #000; }
#vr-exit { position: absolute; top: max(8px, env(safe-area-inset-top)); left: 50%; transform: translateX(-50%); padding: 6px 12px; border-radius: 9px; border: 1px solid #fff4; background: rgba(0,0,0,.55); color: #fff; font-size: 13px; }
#vr-turn { position: absolute; inset: 0; display: none; align-items: center; justify-content: center; background: rgba(0,0,0,.85); color: #fff; font-size: 22px; pointer-events: none; }

body.xr-on header.top, body.xr-on .controls, body.xr-on #side, body.xr-on #inspector, body.xr-on #bottom-dock, body.xr-on .hint, body.xr-on #seq-banner, body.xr-on .vignette { display: none !important; }

/* ================= Freischalten nach Unterrichtsstand ================= */
.locked { position: relative; opacity: .45; filter: grayscale(.6); }
.locked::after { content: '🔒'; position: absolute; top: 2px; right: 4px; font-size: 11px; filter: none; opacity: 1; }
.controls button.locked::after { top: 0; right: 0; font-size: 10px; }
.scen-card.locked::after, .q-topic.locked::after { top: 6px; right: 8px; font-size: 14px; }

/* ================= Lernpfad ================= */
.tk-prog { font-size: 13.5px; color: #cbd5e1; margin-bottom: 10px; }
.tk-bar { height: 7px; border-radius: 6px; background: #1f2937; margin-top: 4px; overflow: hidden; } .tk-bar i { display: block; height: 100%; background: #22c55e; }
.tk-stage { border: 1px solid var(--border); border-radius: 10px; margin-bottom: 6px; background: rgba(255,255,255,.03); }
.tk-stage summary { display: flex; gap: 8px; align-items: center; padding: 8px 10px; cursor: pointer; list-style: none; font-size: 13.5px; }
.tk-stage summary::-webkit-details-marker { display: none; }
.tk-stage summary b { flex: 1; } .tk-stage summary em { font-style: normal; color: var(--text2); font-size: 12.5px; }
.tk-n { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; background: rgba(56,189,248,.18); color: #7dd3fc; font-size: 12px; font-weight: 700; flex: 0 0 22px; }
.tk-stage ul { list-style: none; padding: 0 10px 8px; display: flex; flex-direction: column; gap: 6px; }
.tk-stage li { display: grid; grid-template-columns: 20px 1fr; gap: 6px; font-size: 13px; }
.tk-stage li small { display: block; color: var(--text2); line-height: 1.35; margin-top: 1px; }
.tk-c { color: #64748b; font-weight: 700; } .tk-stage li.ok .tk-c { color: #22c55e; } .tk-stage li.ok b { color: #86efac; }
.tk-stage.locked::after { top: 8px; right: 34px; }

/* ================= Netzteil-Werkbank ================= */
#psubench .modal-box.pb-box { width: min(1180px, 100%); }
.pb-tabs { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 12px; }
.pb-tabs button, .pb-dial button, .pb-probes button, .pb-plugs button { padding: 7px 12px; border-radius: 9px; border: 1px solid var(--border); background: #141c2a; color: var(--text); cursor: pointer; font-size: 13.5px; }
.pb-tabs button.on, .pb-dial button.on, .pb-probes button.on, .pb-plugs button.on { background: rgba(56,189,248,.2); border-color: var(--accent); }
.pb-grid { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: 18px; }
@media (max-width: 900px) { .pb-grid { grid-template-columns: 1fr; } }
.pb-hint { font-size: 13.5px; color: #cbd5e1; line-height: 1.45; margin: 6px 0 10px; }
.pb-psu { display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: center; padding: 10px 12px; border-radius: 10px; background: #111827; margin-bottom: 10px; font-size: 13.5px; }
.pb-sw { display: flex; gap: 6px; align-items: center; cursor: pointer; }
.pb-fan { font-size: 26px; color: #64748b; display: inline-block; } .pb-fan.spin { color: #38bdf8; animation: spin .6s linear infinite; }
.pb-cw { display: inline-flex; flex-direction: column; gap: 4px; margin: 0 14px 10px 0; font-size: 12.5px; color: var(--text2); vertical-align: top; }
.pb-conn { max-width: 100%; height: auto; } .pb-pin { cursor: pointer; } .pb-pin:hover circle:first-of-type { filter: brightness(1.3); }
.pb-legend { display: flex; flex-wrap: wrap; gap: 4px 12px; font-size: 12px; color: var(--text2); }
.pb-legend i, .pb-tol i { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: 5px; vertical-align: -1px; border: 1px solid #ffffff33; }
.pb-meter { background: linear-gradient(#f59e0b, #d97706); border-radius: 18px; padding: 16px; color: #111; align-self: start; }
.pb-lcd { background: #b6c4a2; border-radius: 8px; padding: 10px 14px; font: 700 44px/1 Consolas, monospace; text-align: right; color: #1a1f12; box-shadow: inset 0 2px 6px #0006; }
.pb-lcd small { font-size: 16px; margin-left: 6px; } .pb-lcd.bad { background: #e8b4a8; }
.pb-msg { min-height: 36px; font-size: 13px; margin: 8px 2px; color: #1f1300; font-weight: 600; }
.pb-dial, .pb-probes { display: flex; flex-wrap: wrap; gap: 5px; margin-bottom: 8px; }
.pb-meter .pb-dial button, .pb-meter .pb-probes button { background: #1f2937; color: #fff; }
.pb-tol { width: 100%; border-collapse: collapse; font-size: 12.5px; margin-top: 8px; background: #0e1420; color: var(--text); border-radius: 8px; overflow: hidden; }
.pb-tol th, .pb-tol td { padding: 5px 7px; border-bottom: 1px solid #1f2937; text-align: left; } .pb-tol tr.sel td { background: rgba(56,189,248,.15); font-weight: 700; }
.pb-plugs { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0; }
.pb-tester { background: #0b1a10; border: 8px solid #1f2937; border-radius: 12px; padding: 12px; font: 600 17px Consolas, monospace; color: #86efac; display: grid; gap: 4px; }
.pb-tester div { display: grid; grid-template-columns: 80px 1fr 40px; } .pb-tester b { text-align: right; } .pb-tester em { font-style: normal; text-align: right; }
.pb-tester em.no { color: #f87171; } .pb-tester.bad { border-color: #7f1d1d; } .pb-off { text-align: center; color: #3f6212; padding: 30px; }
.pb-opts { display: grid; gap: 6px; margin: 10px 0; font-size: 14px; } .pb-ok { color: #86efac; font-weight: 700; margin-top: 8px; } .pb-no { color: #fca5a5; font-weight: 700; margin-top: 8px; }
.pb-form { display: grid; gap: 8px; font-size: 14px; }
.pb-form input, .pb-form select { padding: 5px 8px; border-radius: 7px; border: 1px solid var(--border); background: #111827; color: var(--text); width: 90px; }
.pb-form select { width: auto; } .t-mini { padding: 4px 8px; border-radius: 7px; border: 1px solid var(--border); background: #1e293b; color: #fff; cursor: pointer; font-size: 12px; }
.pb-res { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin: 12px 0; }
.pb-res div { background: #111827; border-radius: 9px; padding: 8px 10px; } .pb-res span { display: block; font-size: 12px; color: var(--text2); } .pb-res b { font-size: 19px; }
.pb-chart { width: 100%; height: auto; background: #0b1220; border-radius: 10px; }

/* ================= Betriebssystem-Installation ================= */
#osui { position: fixed; inset: 0; z-index: 410; }
#osui .os-pick { position: absolute; inset: 0; background: rgba(2,4,9,.8); display: grid; place-items: center; padding: 16px; }
#osui .os-pick-box { width: min(900px, 100%); max-height: calc(100vh - 32px); overflow: auto; background: #0e1420; border: 1px solid var(--border); border-radius: 14px; padding: 20px; }
.os-p { font-size: 13.5px; color: #94a3b8; line-height: 1.45; margin: 8px 0; }
.os-orders { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 10px; }
.os-orders button { text-align: left; padding: 12px; border-radius: 11px; border: 1px solid var(--border); background: #111827; color: var(--text); cursor: pointer; display: grid; gap: 4px; }
.os-orders button:hover { border-color: var(--accent); } .os-orders span { font-size: 12px; color: #7dd3fc; } .os-orders small { color: var(--text2); line-height: 1.35; }
.os-err { color: #dc2626; font-weight: 600; margin-top: 8px; font-size: 14px; }
.os-order { position: absolute; right: 14px; bottom: 14px; width: min(360px, 40vw); background: #fffbeb; color: #422006; border-radius: 10px; padding: 8px 12px; font-size: 13px; box-shadow: 0 6px 24px #0006; z-index: 2; }
.os-order summary { cursor: pointer; font-weight: 700; } .os-order p { margin-top: 6px; line-height: 1.4; }
/* Windows */
.os-win, .os-desk { position: absolute; inset: 0; background: radial-gradient(ellipse at 30% 20%, #3b82c4, #0b3a75 60%, #061d3d); display: grid; place-items: center; font-family: 'Segoe UI', Calibri, sans-serif; }
.ow-dlg, .od-win { width: min(720px, 94vw); max-height: 88vh; display: flex; flex-direction: column; background: #f3f3f3; color: #1b1b1b; border-radius: 8px; box-shadow: 0 20px 60px #0008; overflow: hidden; }
.ow-title { display: flex; justify-content: space-between; align-items: center; padding: 8px 12px; background: #fff; border-bottom: 1px solid #ddd; font-size: 13px; }
.ow-x { border: 0; background: transparent; cursor: pointer; font-size: 14px; }
.ow-body, .od-body { padding: 20px 26px; overflow: auto; display: grid; gap: 10px; font-size: 14px; }
.ow-body h3 { font-size: 20px; font-weight: 400; color: #003e92; }
.ow-body label, .ow-acc label { display: grid; gap: 4px; } .ow-body label.chk { display: flex; gap: 8px; align-items: center; }
.ow-body input, .ow-body select { padding: 6px 8px; border: 1px solid #aaa; border-radius: 4px; font-size: 14px; background: #fff; color: #111; }
.ow-logo { font-size: 30px; color: #0067c0; margin-bottom: 6px; }
.ow-list { display: grid; gap: 6px; } .ow-list label { display: flex !important; gap: 8px; align-items: center; } .ow-list.big label { padding: 10px; border: 1px solid #ccc; border-radius: 6px; background: #fff; }
.ow-foot { display: flex; justify-content: flex-end; gap: 8px; padding: 12px 16px; background: #e9e9e9; border-top: 1px solid #ddd; }
.ow-btn { padding: 7px 22px; border-radius: 4px; border: 1px solid #aaa; background: #fff; cursor: pointer; font-size: 14px; } .ow-btn.pri { background: #0067c0; border-color: #0067c0; color: #fff; } .ow-btn:disabled { opacity: .45; }
.ow-req { list-style: none; display: grid; gap: 4px; } .ow-req .ok { color: #15803d; } .ow-req .no { color: #b91c1c; font-weight: 600; }
.ow-disks table { width: 100%; border-collapse: collapse; background: #fff; font-size: 13.5px; } .ow-disks th, .ow-disks td { padding: 6px 8px; border-bottom: 1px solid #e5e5e5; text-align: left; }
.ow-disks tr[data-r] { cursor: pointer; } .ow-disks tr.sel td { background: #cce4f7; }
.ow-tools { display: flex; gap: 6px; flex-wrap: wrap; } .ow-tools button, .od-tree button, .od-up button { padding: 4px 10px; border: 1px solid #0067c0; background: #fff; color: #0067c0; border-radius: 4px; cursor: pointer; font-size: 13px; }
.ow-prog { display: grid; gap: 6px; } .ow-prog div { display: flex; justify-content: space-between; } .ow-bar { height: 6px; background: #ddd; border-radius: 4px; overflow: hidden; display: block !important; } .ow-bar i { display: block; height: 100%; width: 0; background: #0067c0; transition: width .15s; }
.ow-acc { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.ow-priv { display: grid; gap: 8px; } .tg { display: flex !important; align-items: center; gap: 10px; cursor: pointer; } .tg input { display: none; }
.tg span { width: 40px; height: 20px; border-radius: 10px; background: #888; position: relative; flex: 0 0 40px; } .tg span::after { content: ''; position: absolute; top: 3px; left: 3px; width: 14px; height: 14px; border-radius: 50%; background: #fff; transition: .15s; }
.tg input:checked + span { background: #0067c0; } .tg input:checked + span::after { left: 23px; }
.od-tree { list-style: none; display: grid; gap: 6px; } .od-tree li.warn { color: #a16207; } .od-tree li.ok { color: #15803d; }
.od-up { padding: 10px; background: #fff; border: 1px solid #ddd; border-radius: 6px; }
/* VirtualBox */
.os-vbox { position: absolute; inset: 0; background: #2b3a4a; display: grid; place-items: center; font-family: 'Segoe UI', Calibri, sans-serif; }
.ov-title { padding: 10px 14px; background: #183a64; color: #fff; font-weight: 600; width: min(760px, 94vw); border-radius: 8px 8px 0 0; }
.ov-body { width: min(760px, 94vw); background: #eef2f6; color: #111; padding: 18px; border-radius: 0 0 8px 8px; }
.ov-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 16px; font-size: 14px; } .ov-grid label { display: grid; gap: 4px; } .ov-grid label.chk { display: flex; gap: 8px; align-items: center; }
.ov-grid input, .ov-grid select { padding: 6px 8px; border: 1px solid #9aa; border-radius: 4px; background: #fff; color: #111; }
.ov-foot { display: flex; justify-content: flex-end; gap: 8px; margin-top: 12px; } .ov-btn { padding: 7px 18px; border-radius: 4px; border: 1px solid #889; background: #fff; cursor: pointer; } .ov-btn.pri { background: #1f5fa8; color: #fff; border-color: #1f5fa8; }
.os-vbox { grid-template-rows: auto; align-content: center; } .os-vbox > .ov-title + .ov-body { margin-top: 0; }
/* Ubuntu-Installer */
.os-ubu { position: absolute; inset: 0; background: #111; color: #ddd; font-family: 'Ubuntu Mono', Consolas, monospace; display: flex; flex-direction: column; }
.ou-top { background: #e95420; color: #fff; padding: 8px 16px; font-weight: 700; display: flex; justify-content: space-between; } .ou-top span { font-weight: 400; opacity: .85; }
.ou-body { flex: 1; overflow: auto; padding: 22px max(20px, 12vw); display: grid; gap: 12px; align-content: start; font-size: 15px; }
.ou-sel { display: grid; gap: 2px; max-width: 520px; } .ou-sel button { text-align: left; background: transparent; color: #ddd; border: 0; padding: 4px 8px; font: inherit; cursor: pointer; } .ou-sel button.on, .ou-sel button:hover { background: #e95420; color: #fff; }
.ou-form { display: grid; gap: 8px; max-width: 560px; } .ou-form label { display: grid; grid-template-columns: 180px 1fr; gap: 8px; align-items: center; } .ou-form small { grid-column: 2; color: #999; }
.ou-form input, .ou-body input[type=text] { background: #1d1d1d; border: 1px solid #555; color: #fff; padding: 5px 8px; font: inherit; }
.ou-body label.chk { display: flex; gap: 8px; align-items: center; } .ou-v { color: #fff; }
.ou-t { border-collapse: collapse; max-width: 640px; } .ou-t th, .ou-t td { padding: 3px 12px 3px 0; text-align: left; } .ou-t th { color: #aaa; font-weight: 400; }
.ou-snaps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; max-width: 520px; }
.ou-log { background: #000; padding: 12px; height: 50vh; overflow: auto; color: #ccc; }
.ou-foot { display: flex; justify-content: center; gap: 10px; padding: 12px; } .ou-btn { background: #333; color: #fff; border: 0; padding: 6px 16px; font: inherit; cursor: pointer; } .ou-btn:hover, .ou-btn:focus { background: #e95420; } .ou-btn:disabled { opacity: .4; }
.os-ubu .os-err { color: #ff7b5c; }
/* Konsole */
.os-con { position: absolute; inset: 0; background: #000; display: grid; grid-template-columns: 1fr 300px; }
.oc-term { overflow: auto; padding: 14px; font: 14px/1.35 'Ubuntu Mono', Consolas, monospace; color: #d0d0d0; }
.oc-term pre { white-space: pre-wrap; margin: 0; } .oc-in { display: flex; } .oc-in span { color: #8ae234; white-space: nowrap; }
.oc-in input { flex: 1; background: transparent; border: 0; color: #fff; font: inherit; outline: none; }
.oc-side { background: #1a1a1a; color: #ddd; padding: 14px; display: flex; flex-direction: column; gap: 10px; font-size: 13.5px; }
.oc-quick { display: flex; flex-wrap: wrap; gap: 4px; } .oc-quick button { background: #333; color: #fff; border: 0; padding: 4px 8px; border-radius: 4px; font: 12px Consolas, monospace; cursor: pointer; }
@media (max-width: 760px) { .os-con { grid-template-columns: 1fr; } .oc-side { max-height: 40vh; overflow: auto; } .ow-acc { grid-template-columns: 1fr; } .ov-grid { grid-template-columns: 1fr; } .os-order { position: static; width: auto; margin: 8px; } }
/* Protokoll */
.os-proto { position: absolute; inset: 0; background: rgba(2,4,9,.85); display: grid; place-items: center; padding: 16px; }
.op-box { width: min(860px, 100%); max-height: calc(100vh - 32px); overflow: auto; background: #0e1420; border: 1px solid var(--border); border-radius: 14px; padding: 20px; font-size: 14px; }
.op-t { border-collapse: collapse; margin: 6px 0; } .op-t th, .op-t td { border: 1px solid #334155; padding: 4px 10px; text-align: left; }
.op-checks { list-style: none; display: grid; gap: 3px; } .op-checks .ok { color: #86efac; } .op-checks .no { color: #fca5a5; } .op-checks small { color: #94a3b8; }
.op-log { padding-left: 22px; color: #cbd5e1; font-size: 13px; display: grid; gap: 2px; }
.op-note { display: grid; gap: 4px; margin-top: 12px; } .op-note textarea { background: #111827; color: var(--text); border: 1px solid var(--border); border-radius: 8px; padding: 8px; font: inherit; }
.op-btns { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; }

/* Lexikon: Sprungmarken ins Handbuch, Öffnen-Knöpfe */
.d-manual { display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; margin: 10px 0 4px; padding: 8px 12px; border: 1px solid #334155; border-left: 4px solid var(--accent, #38bdf8); border-radius: 8px; background: #0f172a; font-size: 14px; }
.d-manual a { color: #7dd3fc; text-decoration: none; padding: 2px 8px; border-radius: 999px; background: #1e293b; }
.d-manual a:hover { background: #334155; }
.d-actions { display: flex; flex-wrap: wrap; gap: 8px; }
@media print { .d-manual { background: none; } .d-manual a { color: #000; } .d-actions { display: none; } }

/* Vergleichsboard B550 */
body.board-b550 .dbg-row::after { content: 'keine am B550 – nur Pieptöne'; font-size: 11px; color: var(--text2); }
body.board-b550 .dbg-row i { display: none; }
body.board-b550 #btn-case, body.board-b550 #btn-os, body.board-b550 #btn-konfig { opacity: .45; }
#btn-board { font-weight: 700; }
.d-b550 { margin: 8px 0; }
#status-box { cursor: pointer; }
.kf-copy { margin-left: 8px; font-size: 12px; color: var(--text2); } .kf-copy button { margin-left: 4px; }

/* Klick-und-Ziel: Steckplatz-Markierungen */
.slot-target { pointer-events: auto; cursor: pointer; font: 700 12px/1 system-ui, sans-serif; padding: 5px 9px; border-radius: 999px; border: 1px solid #38bdf8; background: rgba(8, 47, 73, .92); color: #e0f2fe; white-space: nowrap; transform: translateY(-14px); box-shadow: 0 2px 8px rgba(0,0,0,.4); }
.slot-target.best { border-color: #22c55e; background: rgba(5, 46, 22, .94); color: #dcfce7; animation: tgtPulse 1.4s ease-in-out infinite; }
.slot-target.bad { border-color: #ef4444; background: rgba(69, 10, 10, .9); color: #fecaca; opacity: .85; }
.slot-target:hover { filter: brightness(1.25); }
@keyframes tgtPulse { 50% { box-shadow: 0 0 0 6px rgba(34,197,94,.25); } }
body.ui-touch .slot-target { font-size: 14px; padding: 8px 12px; }

/* Aktionen immer sichtbar oben im Info-Fenster */
#inspector #inspector-actions { margin: 4px 0 8px; padding: 0 18px; flex: 0 0 auto; max-height: 40%; overflow-y: auto; }
#inspector #inspector-actions:empty { display: none; }
#inspector .act-btn.more { opacity: .9; }
#inspector-actions .act-btn.more { order: 2; }

/* Rechte Leiste: Menü-Knopf bleibt oben, Ausblenden zeigt, dass man scrollen kann */
body.ui-compact .controls > [data-toggle="side"] { position: sticky; top: -4px; z-index: 2; background: #101826; }
body.ui-compact .controls.more-down { -webkit-mask-image: linear-gradient(to bottom, #000 calc(100% - 46px), transparent); mask-image: linear-gradient(to bottom, #000 calc(100% - 46px), transparent); }
body.ui-compact .controls.more-up.more-down { -webkit-mask-image: linear-gradient(to bottom, #000 0, #000 calc(100% - 46px), transparent); }
.ctl-more { display: none; }
body.ui-compact .ctl-more { display: block; position: fixed; right: 10px; width: 72px; bottom: 12px; z-index: 11; text-align: center; font-size: 11px; color: #cbd5e1; pointer-events: none; text-shadow: 0 1px 3px #000; }
body.ui-compact .ctl-more[hidden] { display: none; }

/* Gehäuse-Modus: Führung */
#case-guide { position: fixed; top: calc(var(--hdr, 64px) + 12px); left: 50%; transform: translateX(-50%); z-index: 13; display: flex; align-items: center; gap: 10px; padding: 9px 12px; max-width: min(760px, calc(100vw - 32px)); border-left: 4px solid #facc15; font-size: 14px; }
#case-guide.done { border-left-color: #22c55e; }
#case-guide .cg-k { font-weight: 800; font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: #facc15; white-space: nowrap; }
#case-guide.done .cg-k { color: #22c55e; }
#case-guide .cg-t { flex: 1; }
#case-guide .cg-b { white-space: nowrap; padding: 6px 10px; border-radius: 8px; border: 1px solid #facc15; background: rgba(250,204,21,.12); color: #fef9c3; font-weight: 700; cursor: pointer; }
body.ui-compact #case-guide { left: 10px; right: 92px; transform: none; max-width: none; top: auto; bottom: 64px; }
.tk-go { margin-left: auto; align-self: center; flex: 0 0 auto; padding: 4px 8px; border-radius: 8px; border: 1px solid #334155; background: #0f172a; color: #e2e8f0; font-size: 12px; cursor: pointer; white-space: nowrap; }
.tk-go:hover { border-color: #38bdf8; }
.close-btn { width: 30px; min-width: 30px; padding: 0; display: inline-grid; place-items: center; }
#auth .modal-box { position: relative; }
#auth-close { position: absolute; top: 12px; right: 12px; }
.op-box { max-height: calc(100dvh - 32px); }
.os-proto { overflow: auto; align-items: start; }
#vr-set { position: absolute; bottom: max(8px, env(safe-area-inset-bottom)); left: 50%; transform: translateX(-50%); display: flex; gap: 6px; align-items: center; padding: 5px; border-radius: 10px; background: rgba(0,0,0,.55); }
#vr-set button { padding: 6px 10px; border-radius: 8px; border: 1px solid #fff4; background: rgba(255,255,255,.08); color: #fff; font-size: 12px; }
#vr-set span { color: #e2e8f0; font-size: 11px; padding: 0 6px; white-space: nowrap; }

/* ================= Bereichs-Tabs oben (v27) ================= */
.controls .area-moved { display: none !important; }
#areas { position: fixed; top: 10px; z-index: 12; display: flex; gap: 3px; padding: 4px; overflow-x: auto; scrollbar-width: none; justify-content: safe center; }
#areas::-webkit-scrollbar { display: none; }
#areas button { flex: 0 0 auto; display: flex; align-items: center; gap: 6px; padding: 8px 12px; border-radius: 10px; border: 1px solid transparent; background: transparent; color: #cbd5e1; font: 600 13.5px/1 system-ui, sans-serif; cursor: pointer; white-space: nowrap; position: relative; }
#areas button .ic { font-size: 16px; }
#areas button:hover { background: rgba(255,255,255,.06); color: #fff; }
#areas button.on { background: rgba(56,189,248,.16); border-color: rgba(56,189,248,.55); color: #fff; }
#areas button.on::after { content: ''; position: absolute; left: 12px; right: 12px; bottom: 2px; height: 2px; border-radius: 2px; background: #38bdf8; }
#areas button.dim { opacity: .45; }
#areas button.locked { opacity: .5; }
#areas button.locked::before { content: '🔒'; font-size: 10px; position: absolute; top: 1px; right: 2px; }
body.areas-below #side { top: calc(var(--hdr, 94px) + 18px + var(--areas-h, 0px)); }
body.ui-phone #areas button { padding: 7px 9px; }
body.ui-phone #areas button .lb { display: none; }
@media (max-width: 1100px) { #areas button { padding: 7px 9px; font-size: 12.5px; } }
body.vr-on #areas { display: none; }
#areas.tight button:not(.on) .lb { display: none; }
#areas.tight button { padding: 7px 10px; }
.pb-steps { list-style: none; margin: 0 0 10px; padding: 8px 10px; display: grid; gap: 3px; font-size: 13px; background: #0b1220; border: 1px solid var(--border); border-radius: 10px; }
.pb-steps li { color: #94a3b8; }
.pb-steps li.ok { color: #86efac; }
.pb-steps li.now { color: #fde68a; font-weight: 700; }
body.ui-touch .pb-pin { cursor: pointer; }
#areas .area-power { border-color: rgba(34,197,94,.6); background: rgba(34,197,94,.14); color: #dcfce7; }
#areas .area-power.on { border-color: rgba(239,68,68,.7); background: rgba(239,68,68,.16); color: #fee2e2; }
#areas .area-power.on::after { display: none; }
#areas .area-sep { flex: 0 0 1px; align-self: stretch; margin: 4px 4px; background: var(--border); }
#areas.tight .area-power .lb { display: none; }

/* ================= iPhone: sichere Bereiche (Uhr, Kamera-Insel, Home-Balken) ================= */
:root { --sat: env(safe-area-inset-top, 0px); --sab: env(safe-area-inset-bottom, 0px); --sal: env(safe-area-inset-left, 0px); --sar: env(safe-area-inset-right, 0px); }
.top { top: calc(16px + var(--sat)); left: calc(16px + var(--sal)); }
body.ui-compact .controls { top: calc(10px + var(--sat)); bottom: calc(10px + var(--sab)); right: calc(10px + var(--sar)); }
body.ui-phone .top { top: calc(6px + var(--sat)); left: calc(6px + var(--sal)); }
body.ui-phone .controls { top: calc(6px + var(--sat)); bottom: calc(6px + var(--sab)); right: calc(6px + var(--sar)); }
/* Handy hochkant: Kopfkasten etwas tiefer und genauso breit wie die Tab-Leiste */
body.ui-phone.ui-portrait .top { top: calc(14px + var(--sat)); left: calc(10px + var(--sal)); right: calc(6px + var(--sar)); max-width: none; }
body.ui-phone.ui-portrait .top h1 { flex: 1 1 calc(100% - 24px); }   /* Zeile 1: Punkt + Boardname, Zeile 2: Anmelden + Sprache */
body.ui-phone.ui-portrait .top-links { margin-left: auto; }
body.ui-phone.ui-portrait .lang-sel { max-width: 118px; }
body.ui-phone.ui-portrait .acc-btn { padding: 4px 7px; }
/* Handy: Start-Ablauf nur mit Schritt-Überschriften; Antippen der Überschrift blendet die Erklärung ein */
body.ui-phone #seq-banner:not(.more) #seq-desc, body.ui-phone #seq-banner:not(.more) #seq-buses { display: none; }
body.ui-phone #seq-title { cursor: pointer; margin: 2px 0; }
body.ui-phone #seq-title::after { content: ' ⓘ'; font-size: 13px; color: var(--text2); }
body.ui-phone #seq-banner.more #seq-title::after { content: ' ▴'; }

body.ui-compact #bottom-dock { bottom: calc(10px + var(--sab)); }
/* Tabs: links beginnen, mittig nur wenn Platz ist (auto-Ränder statt „safe center“ – Safari) */
#areas { justify-content: flex-start; }
#areas > :first-child { margin-left: auto; }
#areas > :last-child { margin-right: auto; }
body.ui-phone .seq-ctrl { gap: 5px; }
body.ui-phone .seq-ctrl button { padding: 5px 8px; white-space: nowrap; }
body.ui-phone #seq-speed { min-width: 56px; padding: 4px 2px; font-size: 13px; }
body.ui-phone #seq-off .sq-l { display: none; }

/* Cardboard: HTML-Hinweise ausblenden (die Inhalte stehen auf den 3D-Tafeln), Einstellleiste flach */
body.vr-on #case-guide, body.vr-on #detail, body.vr-on .slot-target { display: none !important; }
#vr-set { padding: 3px 4px; gap: 4px; }
#vr-set button { padding: 3px 8px; font-size: 11px; line-height: 1.15; min-height: 0; white-space: nowrap; }
#vr-set span { font-size: 10px; }
