/* Escape Rooms (Bit & Byte) – Spieloberfläche in lernen/index.html (js/escape-spiel.js) */
.escape-modus nav.stages, .escape-modus #lernstandLeiste { display: none !important; }
.esc-app { --esc-bg: #0d1117; --esc-karte: #161b22; --esc-linie: #2d333b; --esc-text: #e6edf3; --esc-muted: #9aa7b4; --esc-gelb: #ffe14d; --esc-gruen: #3fd68f; --esc-rot: #ff7b72;
  background: var(--esc-bg); color: var(--esc-text); border-radius: 22px; padding: clamp(14px, 2.4vw, 26px); margin: 20px 0; box-shadow: 0 18px 40px #0b162433; }
.esc-app .btn.ghost { background: #21262d; color: var(--esc-text); border-color: #30363d; }
.esc-eyebrow { font-size: 11px; letter-spacing: .17em; font-weight: 800; text-transform: uppercase; color: var(--esc-gelb); }
.esc-kopf { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; align-items: flex-end; }
.esc-titel { margin: 4px 0 0; font-family: var(--headline); font-size: clamp(26px, 4vw, 40px); line-height: 1; letter-spacing: .01em; }
.esc-kopf-r { display: flex; gap: 18px; align-items: center; flex-wrap: wrap; }
.esc-punkte { min-width: 190px; }
.esc-punkte-zahl strong { font-size: 28px; color: var(--esc-gelb); font-family: var(--headline); }
.esc-punkte-zahl span { color: var(--esc-muted); font-size: 14px; }
.esc-balken { height: 8px; background: #2d333b; border-radius: 99px; overflow: hidden; margin: 4px 0 2px; }
.esc-balken i { display: block; height: 100%; background: linear-gradient(90deg, var(--esc-gelb), var(--esc-gruen)); border-radius: 99px; transition: width .5s; }
.esc-prozent { font-size: 12px; color: var(--esc-muted); }
.esc-ring { display: flex; gap: 6px; }
.esc-key { position: relative; width: 46px; height: 30px; display: grid; place-items: center; border-radius: 10px; background: #21262d; color: #4b5563; border: 1px solid #30363d; }
.esc-key svg { width: 34px; height: 18px; }
.esc-key.hat { color: var(--esc-gelb); border-color: #8a6d1a; background: #2a2410; box-shadow: 0 0 12px #ffe14d33; }
.esc-key-haken { position: absolute; right: -6px; top: -7px; width: 18px; height: 18px; border-radius: 50%; background: var(--esc-gruen); color: #06240f; display: grid; place-items: center; }
.esc-key-haken svg { width: 12px; height: 12px; }
.esc-tabs { display: flex; gap: 6px; flex-wrap: wrap; margin: 16px 0 12px; }
.esc-tab { display: inline-flex; align-items: center; gap: 8px; padding: 7px 12px; border-radius: 12px; border: 1px solid #30363d; background: #161b22; color: var(--esc-text); font: inherit; font-size: 14px; font-weight: 700; cursor: pointer; }
.esc-tab:disabled { opacity: .45; cursor: not-allowed; }
.esc-tab.an { border-color: var(--esc-gelb); box-shadow: 0 0 0 2px #ffe14d55; }
.esc-tab.fertig .esc-tab-nr { background: var(--esc-gruen); color: #06240f; }
.esc-tab-nr { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; background: var(--esc-gelb); color: #111; font-size: 12px; font-weight: 800; flex: none; }
.esc-tab-st { color: var(--esc-muted); font-size: 12px; display: inline-flex; }
.esc-tab-st svg { width: 15px; height: 15px; }
.esc-tab.fertig .esc-tab-st svg { width: 26px; height: 14px; color: var(--esc-gelb); }
.esc-tab-final { border-style: dashed; }
.esc-raumkopf { display: flex; justify-content: space-between; align-items: flex-end; gap: 12px; flex-wrap: wrap; margin-bottom: 10px; }
.esc-raumtitel { margin: 2px 0 0; font-size: clamp(18px, 2.6vw, 24px); }
.esc-raumfort { color: var(--esc-muted); font-size: 14px; }
.esc-raumfort strong { color: var(--esc-gelb); font-size: 18px; }
/* Bühne: Kulisse 1600 × 860, Verstecke in Prozent darüber */
.esc-buehne { position: relative; aspect-ratio: 1600 / 860; border-radius: 16px; overflow: hidden; background: #000; border: 1px solid var(--esc-linie); user-select: none; }
.esc-svg, .esc-svg svg, .esc-bild { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.esc-bild { object-fit: cover; }
.esc-ohne-bild { position: absolute; inset: 0; display: grid; place-items: center; color: var(--esc-muted); }
.esc-spot { position: absolute; border: 3px dashed #ffe14dcc; border-radius: 14px; background: #ffe14d0d; cursor: pointer; padding: 0; color: #111; animation: escPuls 2.4s ease-in-out infinite; transition: background .2s, transform .15s; }
.esc-spot:hover, .esc-spot:focus-visible { background: #ffe14d2e; transform: scale(1.02); outline: none; border-style: solid; }
.esc-spot.ok { border: 3px solid #3fd68fcc; background: #3fd68f14; animation: none; }
.esc-spot-lab { position: absolute; left: 6px; top: 6px; display: inline-flex; align-items: center; gap: 5px; background: var(--esc-gelb); border-radius: 8px; padding: 2px 8px 2px 3px; font-size: clamp(9px, 1.05vw, 13px); font-weight: 800; max-width: calc(100% - 12px); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; box-shadow: 0 2px 6px #0008; }
.esc-spot-lab b { width: 1.6em; height: 1.6em; border-radius: 50%; display: grid; place-items: center; background: #111; color: var(--esc-gelb); flex: none; }
.esc-spot.ok .esc-spot-lab { background: var(--esc-gruen); }
.esc-spot.ok .esc-spot-lab b { color: var(--esc-gruen); }
.esc-spot-bu { position: absolute; right: 6px; bottom: 6px; min-width: 1.7em; height: 1.7em; display: grid; place-items: center; border-radius: 8px; background: #111; color: var(--esc-gruen); font: 800 clamp(12px, 1.6vw, 20px) ui-monospace, Consolas, monospace; border: 2px solid var(--esc-gruen); }
.esc-spot.kaefer .esc-spot-lab { top: auto; bottom: 100%; margin-bottom: 4px; left: 50%; transform: translateX(-50%); }
@keyframes escPuls { 0%, 100% { box-shadow: 0 0 0 0 #ffe14d00; } 50% { box-shadow: 0 0 22px 2px #ffe14d55; } }
@media (prefers-reduced-motion: reduce) { .esc-spot { animation: none; } }
.esc-figur { position: absolute; bottom: 2%; font-size: clamp(30px, 5.4vw, 70px); filter: drop-shadow(0 8px 7px #0009); cursor: pointer; z-index: 3; line-height: 1; }
.esc-bit { left: .6%; }
.esc-byte { right: 11.5%; }
.esc-hood { display: inline-block; background: #14191c; border-radius: 46% 46% 30% 30%; padding: 5px; }
.esc-sprech { position: absolute; z-index: 4; bottom: 17%; max-width: min(46%, 420px); background: #fff; color: #101820; border-radius: 16px; padding: 10px 14px; font-size: clamp(12px, 1.4vw, 15px); font-weight: 600; box-shadow: 0 10px 24px #0007; }
.esc-sprech.bit { left: 2%; border-bottom-left-radius: 4px; }
.esc-sprech.byte { right: 9%; border-bottom-right-radius: 4px; }
/* Unter der Bühne: Liste der Verstecke und Tür */
.esc-unten { display: grid; grid-template-columns: 1.3fr 1fr; gap: 14px; margin-top: 14px; }
@media (max-width: 820px) { .esc-unten { grid-template-columns: 1fr; } .esc-spot-lab span { display: none; } .esc-spot-lab { padding: 2px; } }
.esc-liste, .esc-tuer { background: var(--esc-karte); border: 1px solid var(--esc-linie); border-radius: 16px; padding: 14px; }
.esc-liste h4, .esc-tuer h4 { margin: 0 0 8px; font-size: 13px; letter-spacing: .12em; text-transform: uppercase; color: var(--esc-muted); }
.esc-li { display: grid; grid-template-columns: 28px 1fr auto auto; gap: 10px; align-items: center; width: 100%; text-align: left; background: #0d1117; border: 1px solid #30363d; border-radius: 12px; padding: 8px 10px; margin: 0 0 6px; color: var(--esc-text); font: inherit; font-size: 14px; cursor: pointer; }
.esc-li:hover { border-color: #ffe14d88; }
.esc-li.ok { border-color: #3fd68f66; }
.esc-li-nr { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; background: var(--esc-gelb); color: #111; font-weight: 800; font-size: 12px; }
.esc-li.ok .esc-li-nr { background: var(--esc-gruen); }
.esc-li-name { font-weight: 700; }
.esc-li-art { color: var(--esc-muted); font-size: 12px; }
.esc-li-st { font-size: 12px; color: var(--esc-muted); font-family: ui-monospace, Consolas, monospace; }
.esc-li.ok .esc-li-st { color: var(--esc-gruen); font-weight: 800; }
.esc-slots { display: flex; gap: 6px; margin: 4px 0 10px; }
.esc-slot { width: 44px; height: 52px; border-radius: 10px; display: grid; place-items: center; font: 800 26px ui-monospace, Consolas, monospace; background: #0d1117; border: 2px dashed #30363d; color: #4b5563; }
.esc-slot.da { border: 2px solid var(--esc-gruen); color: var(--esc-gruen); background: #0f2a1d; }
.esc-tuer-text { color: var(--esc-muted); font-size: 14px; margin: 0 0 10px; }
.esc-tuer-form { display: flex; gap: 8px; flex-wrap: wrap; }
.esc-wort { flex: 1 1 140px; min-width: 0; min-height: 48px; border-radius: 10px; border: 1px solid #30363d; background: #0d1117; color: var(--esc-gelb); font: 800 22px ui-monospace, Consolas, monospace; letter-spacing: .35em; text-transform: uppercase; padding: 6px 12px; }
.esc-wort:disabled { opacity: .5; }
.esc-tuer-msg { color: var(--esc-rot); font-size: 14px; min-height: 1.2em; margin: 8px 0 0; }
.esc-tuer-offen { display: grid; grid-template-columns: 54px 1fr; grid-template-rows: auto auto; column-gap: 10px; align-items: center; background: #2a2410; border: 1px solid #8a6d1a; border-radius: 12px; padding: 10px 12px; margin-bottom: 10px; color: var(--esc-gelb); }
.esc-tuer-offen svg { grid-row: span 2; width: 54px; height: 28px; }
.esc-tuer-offen span { color: #d6c27a; font-size: 13px; }
.esc-weiter { width: 100%; }
/* Aufgaben-Dialog */
.esc-dialog { width: min(760px, 94vw); max-height: 90vh; border: 0; border-radius: 20px; padding: 0; color: var(--ink, #101820); box-shadow: 0 30px 70px #0008; }
.esc-dialog::backdrop { background: #05080bcc; }
.esc-dlg-kopf { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 16px 20px; background: #0d1117; color: #e6edf3; position: sticky; top: 0; z-index: 2; }
.esc-dlg-kopf h3 { margin: 0; font-size: 18px; flex: 1 1 auto; }
.esc-dlg-chips { display: flex; gap: 6px; }
.esc-chip { display: inline-block; padding: 3px 10px; border-radius: 99px; background: #e8edf2; color: #334155; font-size: 12px; font-weight: 800; }
.esc-dlg-kopf .esc-chip { background: #21262d; color: #e6edf3; }
.esc-chip.gold { background: #ffe14d; color: #111; }
.esc-dlg-zu { background: none; border: 0; color: #e6edf3; font-size: 28px; line-height: 1; cursor: pointer; padding: 0 4px; }
.esc-dlg-body { padding: 18px 20px 6px; }
.esc-dlg-titel { font-weight: 800; color: #536373; font-size: 13px; text-transform: uppercase; letter-spacing: .08em; margin: 0 0 6px; }
.esc-frage { font-size: 17px; font-weight: 600; margin: 0 0 14px; white-space: pre-wrap; }
.esc-frage-bild { max-width: 100%; border-radius: 12px; margin-bottom: 12px; }
.esc-optionen { display: flex; flex-direction: column; gap: 8px; }
.esc-option { display: flex; gap: 10px; align-items: flex-start; border: 1px solid #dbe3e9; border-radius: 12px; padding: 10px 12px; cursor: pointer; white-space: pre-wrap; }
.esc-option:has(input:checked) { border-color: #00797b; background: #e6f4f4; }
.esc-option input { margin-top: 3px; accent-color: #00797b; }
.esc-luecken { font-size: 17px; line-height: 2.2; }
.esc-luecke { font: inherit; font-size: 16px; min-width: 7em; padding: 4px 8px; border: 2px solid #9fb3c2; border-radius: 8px; margin: 0 4px; }
.esc-luecke:focus { outline: none; border-color: #00797b; }
.esc-dlg-fuss { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; padding: 12px 20px 18px; border-top: 1px solid #e5ebf0; position: sticky; bottom: 0; background: #fff; }
.esc-dlg-msg { flex: 1 1 100%; margin: 0; min-height: 1.2em; font-size: 14px; }
.esc-dlg-msg.falsch { color: #b33737; font-weight: 600; }
.esc-erfolg { display: flex; gap: 14px; align-items: center; background: #e9f8ef; border: 1px solid #b7e4c7; border-radius: 14px; padding: 14px; }
.esc-erfolg strong { color: #176440; font-size: 18px; display: block; }
.esc-kachel { width: 56px; height: 64px; flex: none; border-radius: 12px; display: grid; place-items: center; background: #111; color: #3fd68f; font: 800 34px ui-monospace, Consolas, monospace; border: 3px solid #3fd68f; }
.esc-kachel.klein { width: 30px; height: 34px; font-size: 18px; border-width: 2px; border-radius: 8px; }
.esc-erkl { margin: 12px 0 0; color: #334155; }
/* Finalraum */
.esc-final-kopf { margin-bottom: 12px; }
.esc-final-text { color: var(--esc-muted); max-width: 760px; }
.esc-final-raster { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 420px), 1fr)); gap: 14px; }
.esc-final-raum { background: var(--esc-karte); border: 1px solid var(--esc-linie); border-radius: 16px; padding: 14px; display: flex; flex-direction: column; }
.esc-final-raum.gelesen { border-color: #3fd68f88; }
.esc-final-raumkopf { display: flex; gap: 10px; align-items: center; margin-bottom: 8px; }
.esc-final-raumkopf small { display: block; color: var(--esc-muted); }
.esc-final-liste { list-style: none; padding: 0; margin: 0 0 12px; display: flex; flex-direction: column; gap: 10px; }
.esc-final-liste li { background: #0d1117; border: 1px solid #30363d; border-radius: 12px; padding: 10px 12px; }
.esc-final-zeile { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.esc-final-zeile .esc-chip { background: #21262d; color: var(--esc-muted); }
.esc-final-vers { color: var(--esc-muted); font-size: 12px; margin-left: auto; }
.esc-final-frage { margin: 8px 0 4px; white-space: pre-wrap; }
.esc-final-loesung { margin: 4px 0; color: var(--esc-gruen); white-space: pre-wrap; }
.esc-final-erkl { margin: 4px 0 0; color: var(--esc-muted); font-size: 14px; }
.esc-haken { margin-top: auto; display: flex; gap: 12px; align-items: center; padding: 10px 12px; border-radius: 12px; border: 2px dashed #8a6d1a; background: #2a2410; color: var(--esc-gelb); font-weight: 800; cursor: pointer; }
.esc-haken.an { border-style: solid; border-color: var(--esc-gruen); background: #0f2a1d; color: var(--esc-gruen); }
.esc-haken input { width: 22px; height: 22px; accent-color: #3fd68f; }
.esc-haken-key { position: relative; width: 56px; height: 30px; display: grid; place-items: center; }
.esc-haken-key svg { width: 50px; height: 26px; }
.esc-haken:not(.an) .esc-key-haken { display: none; }
.esc-ausgang { margin-top: 16px; padding: 16px; border-radius: 16px; border: 2px dashed #30363d; text-align: center; }
.esc-ausgang.frei { border-color: var(--esc-gruen); background: #0f2a1d; }
.esc-ausgang p { margin: 0 0 10px; }
/* Ergebnis */
.esc-erg-kopf { display: grid; grid-template-columns: 1.2fr 1fr; gap: 18px; align-items: center; }
@media (max-width: 760px) { .esc-erg-kopf { grid-template-columns: 1fr; } }
.esc-erg-titel { font-family: var(--headline); font-size: clamp(34px, 6vw, 58px); margin: 4px 0 8px; line-height: .95; color: var(--esc-gelb); }
.esc-erg-bild { width: 100%; height: auto; border-radius: 16px; }
.esc-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin: 16px 0; }
.esc-stat { background: var(--esc-karte); border: 1px solid var(--esc-linie); border-radius: 14px; padding: 14px; text-align: center; }
.esc-stat strong { display: block; font-size: clamp(24px, 4vw, 36px); color: var(--esc-gelb); font-family: var(--headline); }
.esc-stat span { color: var(--esc-muted); font-size: 13px; }
.esc-erg-tabelle { width: 100%; border-collapse: collapse; font-size: 14px; }
.esc-erg-tabelle th, .esc-erg-tabelle td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--esc-linie); }
.esc-erg-tabelle th { color: var(--esc-muted); font-size: 12px; text-transform: uppercase; letter-spacing: .08em; }
.esc-erg-hinweis { color: var(--esc-muted); font-size: 14px; }
.esc-erg-knoepfe { display: flex; gap: 10px; flex-wrap: wrap; }
.esc-laden, .esc-fehler { padding: 20px; color: var(--esc-muted); }
.esc-fehler { color: var(--esc-rot); }
@media print { .esc-app { background: #fff; color: #000; } }
