/* AssistUK Abenteuerinsel — nur was über kern/css/spiel.css und js/welt/leiste.css hinausgeht (14.11.2026) */
html, body { background: radial-gradient(ellipse at 50% 25%, #2d5a33 0%, var(--grund) 72%); }
#buehne { position: fixed; inset: 0; }
#welt { position: fixed; inset: 0; z-index: 1; }
#welt[hidden] { display: none; }
#spiel { position: fixed; inset: 0; z-index: 3; pointer-events: none; }
#spiel[hidden] { display: none; }
/* Startseite: Bild des Dorfs schimmert durch (ruhig, kein Wandern) */
.bildschirm.insel-start { background: linear-gradient(180deg, rgba(16, 38, 26, .2) 0%, rgba(16, 38, 26, .78) 72%), url("../assets/img/start.webp") center / cover no-repeat; }
body.bf-cvi .bildschirm.insel-start { background: #000; }
.figur-knopf svg { width: 44px; height: 44px; }
.figur-bild { display: block; width: 92px; height: 92px; object-fit: contain; }
.figur-knopf .figur-bild { width: 52px; height: 52px; }
.figur-zeichen { display: none; }
body.bf-cvi .figur-bild { display: none; }
body.bf-cvi .figur-zeichen { display: block; }
/* Figurenwahl: 6 Figuren + Rollstuhl, Knöpfe ≥ 120 × 96, kein Scrollen */
.figur-schirm { display: flex; flex-direction: column; }
.figur-wahl { flex: 1 1 auto; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: var(--luecke, 12px);
  padding: var(--oben, 12px) var(--rechts, 12px) calc(var(--leiste-h, 130px) + 8px) var(--links, 12px); min-height: 0; }
.figur-wahl .titel { margin: 0; }
.figur-text { margin: 0; font-size: var(--s-text, 18px); }
.figur-gitter { display: grid; grid-template-columns: repeat(4, minmax(120px, 190px)); gap: var(--luecke, 12px); width: min(100%, 820px); }
.figur-gitter .knopf { min-height: 96px; flex-direction: column; gap: 2px; padding-top: 6px; padding-bottom: 6px; }
.figur-gitter .knopf svg { width: 54px; height: 54px; }
.figur-gitter .knopf.gewaehlt { outline: 5px solid var(--gold, #ffd23f); outline-offset: -5px; }
.figur-stuhl { grid-column: span 2; }
@media (max-width: 700px) { .figur-gitter { grid-template-columns: repeat(2, minmax(120px, 1fr)); } .figur-text { display: none; } }
@media (max-height: 500px) { .figur-gitter { grid-template-columns: repeat(4, minmax(120px, 1fr)); } .figur-gitter .knopf { min-height: 72px; } .figur-gitter .figur-bild { width: 56px; height: 56px; }
  .figur-gitter .knopf svg { width: 34px; height: 34px; } .figur-text { display: none; } .figur-wahl .titel { font-size: 22px; } }
@media (max-height: 500px) and (max-width: 600px) { .figur-gitter { grid-template-columns: repeat(3, minmax(96px, 1fr)); } }
@media (max-height: 420px) { .figur-wahl .titel { display: none; } .figur-gitter .knopf { min-height: 72px; min-width: 96px; } }
/* Auswahl-Tafel im Spiel (Rucksack, Karte, Bauen, Geben) */
.ai-tafel { position: absolute; z-index: 7; left: 50%; top: 50%; transform: translate(-50%, -50%); pointer-events: auto;
  width: min(94vw, 980px); max-height: 92vh; box-sizing: border-box; padding: 14px 16px; border-radius: 26px;
  background: rgba(250, 246, 236, .97); color: #1b2430; box-shadow: 0 14px 40px rgba(0, 0, 0, .5); font-family: 'DM Sans', system-ui, sans-serif; }
.ai-tafel-titel { margin: 0 0 10px; font-size: clamp(20px, .8vw + 1.2vh, 30px); text-align: center; }
.ai-tafel-gitter { display: grid; grid-template-columns: repeat(3, minmax(120px, 1fr)); gap: 10px; }
.ai-tafel-leiste { display: flex; justify-content: space-between; gap: 10px; margin-top: 10px; flex-direction: row-reverse; }
.ai-tafel .wz-feld { position: relative; min-height: 104px; background: #12324d; }
.ai-tafel-leiste .wz-feld { min-width: 180px; background: #3a4654; }
.ai-tafel .ai-aus { opacity: .55; }
.ai-unter { display: block; font-weight: 500; font-size: 14px; opacity: .9; }
@media (max-width: 560px) { .ai-tafel-gitter { grid-template-columns: repeat(2, minmax(120px, 1fr)); } .ai-tafel-leiste .wz-feld { min-width: 120px; } }
@media (max-height: 420px) { .ai-tafel { padding: 6px 10px; } .ai-tafel-titel { font-size: 16px; margin-bottom: 4px; }
  .ai-tafel-gitter { grid-template-columns: repeat(4, minmax(96px, 1fr)); gap: 6px; } .ai-tafel .wz-feld { min-height: 72px; }
  .ai-tafel-leiste { margin-top: 6px; } .ai-unter { display: none; } }
body.bf-cvi .ai-tafel { background: #000; color: #fff; border: 4px solid #ffd400; }
/* kurzer Hinweis (gesammelt, gebaut) — nur zusätzlich zu Klang und Vorlesen, nicht bedienbar */
.ai-hinweis { position: absolute; z-index: 5; left: 50%; bottom: 24%; transform: translate(-50%, 20px); opacity: 0; pointer-events: none;
  display: flex; align-items: center; gap: 10px; padding: 10px 18px; border-radius: 999px; background: rgba(10, 26, 16, .88); color: #fff;
  font: 700 22px/1.1 'DM Sans', system-ui, sans-serif; transition: opacity .25s, transform .25s; }
.ai-hinweis.an { opacity: 1; transform: translate(-50%, 0); }
.ai-hinweis-symbol { width: 36px; height: 36px; color: #ffd23f; }
.ai-hinweis-symbol svg { width: 100%; height: 100%; }
/* Überblendung (Bewegung reduzieren) */
.ai-blende { position: absolute; inset: 0; z-index: 2; background: #0b1a12; pointer-events: none; animation: ai-blende .45s ease-out forwards; }
@keyframes ai-blende { from { opacity: 1; } to { opacity: 0; } }
/* Taster: kleiner Pause-Knopf für die Begleitperson (kein Scan-Ziel) */
.pause-begleitung { position: absolute; left: max(8px, env(safe-area-inset-left)); top: max(8px, env(safe-area-inset-top)); width: 56px; height: 56px;
  border-radius: 14px; background: rgba(10, 26, 42, .7); color: #fff; display: grid; place-items: center; pointer-events: auto; z-index: 5; }
.pause-begleitung svg { width: 30px; height: 30px; }
@media (prefers-reduced-motion: reduce) { .ai-hinweis { transition: none; } .ai-blende { animation: none; opacity: 0; } }
#spiel.mit-begleitung .wz-leiste { left: 76px; }
/* Die Pause bleibt Teil der flexiblen Weltleiste; diese reserviert ihren Platz
   und schiebt weitere Weltaktionen bei Bedarf um. */
#spiel .wz-leiste .wz-l-pause { left: auto; top: auto; min-width: 200px; min-height: 128px; }
@media (min-width: 1100px) and (min-height: 600px) {
  #spiel .wz-leiste .wz-l-pause { min-width: 240px; min-height: 128px; }
}
@media (min-width: 1600px) and (min-height: 900px) {
  #spiel .wz-leiste .wz-l-pause { min-width: 260px; min-height: 140px; }
}
@media (max-width: 640px), (max-height: 420px) {
  #spiel .wz-leiste .wz-l-pause { min-width: 160px; min-height: 104px; }
}
/* Sechs Ziele passen auf kleinen Hochformaten nicht untereinander: zwei
   Spalten halten alle Aktionen ohne Scrollen im sichtbaren Bereich. */
@media (min-width: 300px) and (max-width: 400px) and (min-height: 520px) and (max-height: 700px) and (orientation: portrait) {
  #spiel .wz-leiste { --wz-leiste-lage: oben; display: grid; grid-template-columns: 144px 148px; gap: 4px; width: 296px; right: auto; bottom: auto; }
  #spiel.mit-begleitung .wz-leiste { left: max(10px, env(safe-area-inset-left)); top: 76px; }
}
/* Blick-Sperre: Hinweis auf den Rahmen-Bildschirmen (Startseite, Figurenwahl) */
.ai-wegschauen { position: fixed; z-index: 50; left: 50%; top: 40%; transform: translate(-50%, -50%); padding: 14px 24px; border-radius: 999px;
  background: rgba(10, 26, 16, .92); color: #fff; font: 700 24px/1.2 'DM Sans', system-ui, sans-serif; pointer-events: none; opacity: 0; transition: opacity .2s; }
.ai-wegschauen.an { opacity: 1; }
.ai-direktblick { position: fixed; width: 52px; height: 52px; z-index: 8; pointer-events: none !important; transform: translate(-50%, -50%); border: 3px solid #fff; border-radius: 50%; box-shadow: 0 0 0 3px #10261a; background: conic-gradient(rgba(255,210,63,.8) var(--fort, 0deg), rgba(0,0,0,.35) 0); }
.ai-direktblick[hidden] { display: none; }
body.bf-cvi .ai-wegschauen { background: #000; border: 4px solid #ffd400; }
