/* ================================================================
   Sa’d – Der treue Bogenschütze · Stil (eigene Farbwelt: Himmelblau, Wolkenweiß & Zitrone)
   Helle Oberfläche wie ein klarer, windiger Morgen: Knöpfe in Pfeilform (links Kerbe, rechts Spitze),
   Tafeln mit gestricheltem „Flugbahn“-Rand, Titel in einer Zielscheibe, Kapitelwahl als Köcher.
   ================================================================ */
@font-face { font-family: 'Lexend'; font-weight: 400; font-display: swap; src: url('../fonts/lexend-latin-400-normal.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Lexend'; font-weight: 400; font-display: swap; src: url('../fonts/lexend-latin-ext-400-normal.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Lexend'; font-weight: 500; font-display: swap; src: url('../fonts/lexend-latin-500-normal.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Lexend'; font-weight: 500; font-display: swap; src: url('../fonts/lexend-latin-ext-500-normal.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Lexend'; font-weight: 700; font-display: swap; src: url('../fonts/lexend-latin-700-normal.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Lexend'; font-weight: 700; font-display: swap; src: url('../fonts/lexend-latin-ext-700-normal.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Mali'; font-weight: 600; font-display: swap; src: url('../fonts/mali-latin-600-normal.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Mali'; font-weight: 600; font-display: swap; src: url('../fonts/mali-latin-ext-600-normal.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Mali'; font-weight: 700; font-display: swap; src: url('../fonts/mali-latin-700-normal.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Mali'; font-weight: 700; font-display: swap; src: url('../fonts/mali-latin-ext-700-normal.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Lemonada'; font-weight: 700; font-display: swap; src: url('../fonts/lemonada-arabic-700-normal.woff2') format('woff2'); }
@font-face { font-family: 'Scheherazade New'; font-weight: 400; font-display: swap; src: url('../fonts/scheherazade-new-arabic-400-normal.woff2') format('woff2'); }
@font-face { font-family: 'Scheherazade New'; font-weight: 700; font-display: swap; src: url('../fonts/scheherazade-new-arabic-700-normal.woff2') format('woff2'); }

:root {
  --night: #0f2a44;      /* Abendblau (Text, Nacht, theme-color) */
  --night2: #1c3f63;
  --sky: #7cc4f0;        /* Himmelblau */
  --sky2: #3d8ec9;       /* tiefes Himmelblau */
  --sky3: #1c5f94;
  --skyPale: #d8eefb;
  --cloud: #fbfdff;      /* Wolkenweiß */
  --cloud2: #eef7fd;
  --lemon: #ffe14d;      /* Zitrone */
  --lemon2: #f2c200;
  --lemonPale: #fff6c2;
  --gold: #ffe14d;       /* (Akzent für gemeinsame Teile) */
  --gold2: #f2c200;
  --ink: #16324a;        /* Text auf hellen Tafeln */
  --ink2: #3c5a74;
  --muted: #5f7a92;
  --light: #fbfdff;      /* heller Text auf dunklem Bild */
  --panel: rgba(251, 253, 255, .95);
  --panel2: rgba(238, 247, 253, .97);
  --line: rgba(61, 142, 201, .6);
  --good: #3fa463;
  --bad: #e8743a;
  --radius: 22px;
  --shadow: 0 12px 34px rgba(15, 42, 68, .28);
  --arrow: polygon(0 0, calc(100% - 20px) 0, 100% 50%, calc(100% - 20px) 100%, 0 100%, 14px 50%);
  --font: 'Lexend', 'Trebuchet MS', 'Segoe UI', system-ui, sans-serif;
  --font-title: 'Mali', 'Lexend', 'Trebuchet MS', system-ui, sans-serif;
  --ar: 'Scheherazade New', 'Amiri', 'Geeza Pro', 'Traditional Arabic', 'Noto Naskh Arabic', serif;
  --ar-title: 'Lemonada', 'Scheherazade New', 'Geeza Pro', sans-serif;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; height: 100%; background: var(--night); overflow: hidden; }
body { font-family: var(--font); color: var(--ink); -webkit-font-smoothing: antialiased; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; }
button { font-family: inherit; }

.game-root { position: fixed; inset: 0; width: 100%; height: 100%; overflow: hidden; background: linear-gradient(180deg, #3a8ee0, #d6ecfa); touch-action: pan-y; }
.game-root.playing { touch-action: none; }
.game-canvas { position: absolute; inset: 0; width: 100% !important; height: 100% !important; display: block; outline: none; transition: filter 1.2s ease; }
.hidden { display: none !important; }

/* ---------------------------------------------------------------- Lader: ein Pfeil fliegt in die Zielscheibe */
#loader { position: absolute; inset: 0; z-index: 100; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 18px; background: linear-gradient(180deg, #2f7fcf, #9fd2f3 70%, #e9f5fc); transition: opacity .8s ease; }
#loader.done { opacity: 0; pointer-events: none; }
.ld-scene { position: relative; width: 240px; height: 130px; }
.ld-target { position: absolute; right: 8px; top: 8px; width: 110px; height: 110px; border-radius: 50%; background: radial-gradient(circle closest-side, var(--lemon) 0 16%, var(--sky2) 16% 17%, #fff 17% 36%, var(--sky) 36% 54%, #fff 54% 72%, var(--sky2) 72% 90%, var(--sky3) 90%); box-shadow: 0 8px 20px rgba(15, 42, 68, .3); }
.ld-arrow { position: absolute; left: 0; top: 52px; width: 150px; height: 26px; animation: ldFly 1.6s cubic-bezier(.3, .1, .2, 1) infinite; }
.ld-arrow svg { width: 100%; height: 100%; display: block; }
@keyframes ldFly { 0% { transform: translate(-60px, 26px) rotate(-12deg); opacity: 0; } 15% { opacity: 1; } 55% { transform: translate(58px, -2px) rotate(2deg); } 62%, 85% { transform: translate(62px, 0) rotate(0); opacity: 1; } 100% { transform: translate(62px, 0); opacity: 0; } }
.ld-ar { font-family: var(--ar-title); font-size: 56px; color: #fff; text-shadow: 0 4px 18px rgba(15, 42, 68, .4); line-height: 1.2; }
.nowebgl { max-width: 460px; text-align: center; padding: 0 20px; font-size: 18px; color: var(--ink); }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------------------------------------------------------------- Knöpfe in Pfeilform (Kerbe links, Spitze rechts) */
.btn { position: relative; isolation: isolate; appearance: none; border: 0; background: var(--sky2); color: var(--ink); font-weight: 700; font-size: 18px; padding: 11px 38px 11px 32px; cursor: pointer; clip-path: var(--arrow); transition: transform .15s ease, background .2s ease; min-height: 50px; }
.btn::before { content: ''; position: absolute; inset: 3px 4px; z-index: -1; background: var(--cloud); clip-path: var(--arrow); transition: background .2s; }
.btn:hover { transform: translateX(3px); }
.btn:hover::before { background: #fff; }
.btn:active { transform: translateX(6px) scale(.98); }
.btn:focus-visible { outline: none; background: var(--night); }
.btn.primary { background: var(--night); color: var(--night); }
.btn.primary::before { background: linear-gradient(180deg, #fff3a0, var(--lemon) 50%, var(--lemon2)); }
.btn.primary:hover::before { background: linear-gradient(180deg, #fff8c4, #ffe86c 50%, #f7cc22); }
.btn.ghost { background: rgba(61, 142, 201, .6); }
.btn.ghost::before { background: rgba(251, 253, 255, .82); }
.btn.big { font-size: 22px; padding: 13px 46px 13px 38px; min-height: 58px; }
.btn:disabled { opacity: .5; cursor: default; }
.btn-shadow, .title-buttons, .row, .col, .quiz-a { filter: drop-shadow(0 5px 10px rgba(15, 42, 68, .22)); }
.row { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; margin-top: 18px; }
.col { display: flex; flex-direction: column; gap: 12px; align-items: stretch; width: min(340px, 86vw); }

/* Tafeln: weich rund, gestrichelter „Flugbahn“-Rand innen */
.panel, .set-list, .about-text, .hud-obj, .dlg-box, .stat, .v-badge, .mg-hint, .vp-card, .pc-card, .rh-card {
  background: var(--panel); border: 2.5px solid var(--sky); border-radius: var(--radius);
  outline: 2px dashed rgba(61, 142, 201, .45); outline-offset: -8px; box-shadow: var(--shadow);
}

/* ---------------------------------------------------------------- Menüs */
.menus { position: absolute; inset: 0; z-index: 70; display: none; }
.menus.open { display: block; }
.screen { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: flex-start; padding: 24px 18px; overflow-y: auto; background: linear-gradient(180deg, rgba(216, 238, 251, .55), rgba(124, 196, 240, .55)); animation: fadeIn .45s ease; }
.screen h2 { font-family: var(--font-title); font-size: clamp(30px, 4.6vw, 46px); margin: 0 0 18px; color: var(--night); text-shadow: 0 3px 0 #fff, 0 6px 18px rgba(255, 255, 255, .6); font-weight: 700; }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
.screen > :first-child { margin-top: auto; }
.screen > :last-child { margin-bottom: auto; }
.screen > * { flex-shrink: 0; }

/* ---------------- Hauptmenü: Titel in der Zielscheibe (links), Sa’d mit gespanntem Bogen in 3D (rechts) */
.title-screen { background: linear-gradient(90deg, rgba(216, 238, 251, .5) 0%, rgba(216, 238, 251, .18) 46%, rgba(216, 238, 251, 0) 70%); align-items: flex-start; padding-left: clamp(18px, 6vw, 96px); }
.title-wrap { display: flex; flex-direction: column; align-items: center; width: min(470px, 46vw); animation: rise .9s cubic-bezier(.2, .8, .2, 1); }
@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
.t-target { position: relative; width: min(410px, 46vw, 56vh); aspect-ratio: 1; display: grid; place-items: center; margin-bottom: 6px; filter: drop-shadow(0 12px 26px rgba(15, 42, 68, .32)); }
.t-rings { position: absolute; inset: 0; border-radius: 50%; background: radial-gradient(circle closest-side, var(--cloud) 0 55%, #c4e5f9 55% 63%, var(--cloud) 63% 71%, var(--sky) 71% 80%, var(--cloud) 80% 88%, var(--sky2) 88% 95%, var(--sky3) 95%); animation: tgIn .8s cubic-bezier(.2, 1.4, .4, 1) both; }
.t-rings i { position: absolute; left: 50%; top: 50%; border-radius: 50%; border: 1.5px solid rgba(28, 95, 148, .25); transform: translate(-50%, -50%); }
.t-rings i:nth-child(1) { width: 55%; height: 55%; }
.t-rings i:nth-child(2) { width: 71%; height: 71%; }
.t-rings i:nth-child(3) { width: 88%; height: 88%; }
.t-rings i:nth-child(4) { width: 14px; height: 14px; border: 0; top: 84%; background: var(--lemon); box-shadow: 0 0 0 3px var(--sky2); }
@keyframes tgIn { from { transform: scale(.6) rotate(-30deg); opacity: 0; } to { transform: none; opacity: 1; } }
.t-arrow { position: absolute; right: -4%; top: 63%; width: 62%; height: 12%; z-index: 3; transform-origin: 4% 50%; animation: tArrow 1.2s .45s cubic-bezier(.35, .05, .3, 1) both; }
.t-arrow svg { width: 100%; height: 100%; display: block; overflow: visible; transform: scaleX(-1); }
/* Der Pfeil kommt von rechts – von Sa’d, der rechts im Bild den Bogen spannt */
@keyframes tArrow { 0% { transform: translateX(120vw) rotate(8deg); } 58% { transform: translateX(-4%) rotate(-1deg); } 66% { transform: translateX(0) rotate(2.5deg); } 76% { transform: rotate(-1.8deg); } 86% { transform: rotate(.8deg); } 100% { transform: none; } }
.t-text { position: relative; z-index: 2; text-align: center; margin-top: -6%; }
.title-ar { font-family: var(--ar-title); font-weight: 700; font-size: clamp(40px, 6vw, 70px); line-height: 1.25; color: var(--sky2); text-shadow: 0 3px 0 #fff; }
.title-ar.small { font-size: 46px; margin-bottom: 0; }
.title-main { font-family: var(--font-title); font-size: clamp(48px, 7.5vw, 86px); line-height: .95; margin: 0; font-weight: 700; color: var(--night); text-shadow: 0 4px 0 var(--lemon), 0 8px 18px rgba(15, 42, 68, .2); }
.title-sub { font-family: var(--font-title); font-size: clamp(17px, 2.3vw, 26px); color: var(--sky3); font-weight: 700; margin-top: 6px; }
.title-tag { font-size: 15.5px; color: var(--night); margin: 4px 0 14px; background: rgba(251, 253, 255, .8); padding: 4px 16px; border-radius: 999px; text-align: center; }
.title-buttons { display: flex; flex-direction: column; gap: 10px; width: min(330px, 80vw); margin-bottom: 14px; }
.light-note { font-size: 13px; color: var(--ink); max-width: 430px; line-height: 1.35; margin: 12px 0 0; padding: 7px 14px; background: rgba(251, 253, 255, .8); border-radius: 14px; text-align: center; }

.lang-switch { display: inline-flex; background: var(--panel); border: 2px solid var(--sky); border-radius: 999px; padding: 4px; gap: 4px; }
.lang-switch button, .seg button { border: 0; background: transparent; color: var(--ink); font-weight: 700; font-size: 16px; padding: 7px 16px; border-radius: 999px; cursor: pointer; min-height: 38px; }
.lang-switch button.on, .seg button.on { background: var(--sky2); color: #fff; }

/* ---------------- Kapitelwahl: Sa’ds Köcher mit fünf Pfeilen */
.qv-wrap { position: relative; width: min(820px, 96vw); display: flex; flex-direction: column; align-items: center; }
.qv-arrows { position: relative; z-index: 1; display: flex; justify-content: center; gap: clamp(0px, 0.5vw, 8px); width: 100%; margin-bottom: -58px; }
.qv-quiver { position: relative; z-index: 2; width: min(800px, 94vw); height: 110px; pointer-events: none; filter: drop-shadow(0 10px 16px rgba(15, 42, 68, .3)); }
.qv-quiver svg { width: 100%; height: 100%; display: block; }
.ch-card.qv-arrow { position: relative; appearance: none; background: none; border: 0; padding: 0; cursor: pointer; width: clamp(110px, 15vw, 150px); height: min(380px, 52vh); display: flex; flex-direction: column; align-items: center; transform-origin: 50% 100%; transform: rotate(calc((var(--i) - 2) * 4deg)); transition: transform .25s cubic-bezier(.2, 1.4, .4, 1); color: var(--ink); font-family: inherit; }
.ch-card.qv-arrow:hover:not(:disabled) { transform: rotate(calc((var(--i) - 2) * 4deg)) translateY(-14px); }
.ch-card.qv-arrow:disabled { cursor: default; }
.qv-svg { position: absolute; left: 50%; top: 0; height: 100%; width: auto; transform: translateX(-50%); filter: drop-shadow(0 4px 6px rgba(15, 42, 68, .3)); }
.qv-arrow .ch-num { position: absolute; top: 3.2%; left: 50%; transform: translateX(-50%); z-index: 2; width: 30px; height: 30px; border-radius: 50%; background: var(--night); color: var(--lemon); font-weight: 800; display: grid; place-items: center; font-size: 16px; }
.qv-arrow.locked .ch-num { background: #8a98a6; color: #fff; }
.qv-tag { position: absolute; top: 26%; left: 50%; transform: translateX(-50%); width: 100%; background: var(--cloud); border: 2.5px solid var(--sky2); border-radius: 14px; padding: 7px 6px; display: flex; flex-direction: column; gap: 2px; text-align: center; box-shadow: 0 6px 14px rgba(15, 42, 68, .25); }
.qv-tag::before { content: ''; position: absolute; left: 50%; top: -11px; width: 10px; height: 10px; margin-left: -5px; border-radius: 50%; background: var(--lemon); border: 2px solid var(--sky3); }
.qv-arrow.locked .qv-tag { background: #e3e9ee; border-color: #9aa6b2; color: #6a7884; }
.ch-title { font-weight: 700; font-size: 15px; line-height: 1.15; }
.ch-sub { font-size: 12.5px; color: var(--muted); line-height: 1.2; }
.ch-done { position: absolute; top: 15%; right: 8%; width: 28px; height: 28px; color: var(--lemon2); filter: drop-shadow(0 2px 3px rgba(15, 42, 68, .5)); }
.ch-grid { display: flex; }

/* Einstellungen */
.set-list { display: flex; flex-direction: column; gap: 10px; width: min(620px, 94vw); padding: 20px 24px; margin-bottom: 18px; }
.set-row { display: flex; align-items: center; justify-content: space-between; gap: 14px; font-size: 17px; flex-wrap: wrap; }
.set-row > span { flex: 1 1 200px; }
.seg { display: inline-flex; background: var(--cloud2); border: 2px solid var(--sky); border-radius: 999px; padding: 4px; gap: 4px; }
input[type=range] { width: 200px; accent-color: var(--sky2); height: 28px; }

/* Für Eltern */
.about-text { width: min(760px, 94vw); max-height: 62vh; overflow-y: auto; padding: 12px 28px 22px; margin-bottom: 18px; font-size: 16px; line-height: 1.55; user-select: text; -webkit-user-select: text; }
.about-text h3 { color: var(--sky3); margin: 16px 0 4px; font-size: 19px; font-family: var(--font-title); }
.about-text ul { padding-left: 20px; margin: 6px 0; }
.about-text li { margin: 3px 0; }
.about-text code { background: var(--skyPale); padding: 1px 6px; border-radius: 6px; }
.pause-controls { max-width: 560px; text-align: center; color: var(--ink); font-size: 14px; margin-top: 22px; background: rgba(251, 253, 255, .8); padding: 8px 16px; border-radius: 14px; }

/* Kapitelende */
.done-stars { display: flex; gap: 8px; margin-bottom: 6px; }
.done-stars svg { width: 46px; height: 46px; color: var(--lemon); filter: drop-shadow(0 3px 0 var(--sky3)) drop-shadow(0 6px 12px rgba(15, 42, 68, .3)); animation: pop .6s cubic-bezier(.2, 1.6, .4, 1) both; }
.done-stars svg:nth-child(2) { width: 62px; height: 62px; animation-delay: .12s; }
.done-stars svg:nth-child(3) { animation-delay: .24s; }
@keyframes pop { from { transform: scale(0) rotate(-40deg); opacity: 0; } to { transform: none; opacity: 1; } }
.done-name { font-size: 20px; color: var(--night); margin-top: -10px; background: rgba(251, 253, 255, .8); padding: 2px 16px; border-radius: 999px; }
.done-stats { display: flex; gap: 16px; margin-top: 18px; }
.stat { display: flex; flex-direction: column; align-items: center; padding: 12px 22px; min-width: 128px; }
.stat .ic { width: 30px; height: 30px; color: var(--sky2); }
.stat .ic-pearl { color: #9a86d8; }
.stat b { font-size: 26px; line-height: 1.1; }
.stat small { color: var(--muted); font-size: 14px; }

/* Abschluss & Quiz */
.v-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; width: min(740px, 94vw); }
.v-badge { display: flex; align-items: center; gap: 10px; padding: 10px 14px; font-weight: 700; font-size: 16.5px; opacity: .55; outline: none; }
.v-badge .vi { width: 34px; height: 34px; flex: none; color: #9aa6b2; }
.v-badge.got { opacity: 1; border-color: var(--sky2); }
.v-badge.got .vi { color: var(--sky2); }
.end-text { max-width: 700px; text-align: center; font-size: 18.5px; line-height: 1.5; margin: 20px 16px 0; min-height: 3.2em; color: var(--night); background: rgba(251, 253, 255, .85); border-radius: 18px; padding: 10px 18px; }
.end-text:empty { visibility: hidden; }
.end-text.in { animation: rise .6s ease; }
.quiz-head { color: var(--sky3); font-weight: 700; font-size: 17px; margin-bottom: 10px; background: rgba(251, 253, 255, .85); padding: 3px 16px; border-radius: 999px; }
.quiz-q { font-family: var(--font-title); font-size: clamp(22px, 3.4vw, 32px); font-weight: 700; text-align: center; max-width: 820px; line-height: 1.25; margin-bottom: 22px; color: var(--night); background: rgba(251, 253, 255, .9); padding: 12px 22px; border-radius: 22px; }
.quiz-a { display: flex; flex-direction: column; gap: 12px; width: min(560px, 92vw); }
.btn.answer { font-size: 18px; padding: 14px 40px 14px 30px; text-align: center; font-weight: 500; }
.btn.answer.right { background: var(--good); }
.btn.answer.right::before { background: #c9f0d2; }
.btn.answer.wrong { background: var(--bad); animation: shake .4s; }
.btn.answer.wrong::before { background: #fde0cf; }
@keyframes shake { 20%, 60% { transform: translateX(-6px); } 40%, 80% { transform: translateX(6px); } }
.quiz-fb { margin-top: 16px; font-size: 20px; font-weight: 700; min-height: 1.5em; color: var(--night); }
.quiz-score { font-size: 24px; margin: -6px 0 6px; background: rgba(251, 253, 255, .85); padding: 4px 18px; border-radius: 999px; }
.quiz-score b { font-size: 40px; color: var(--sky2); }

/* ---------------------------------------------------------------- HUD */
.hud { position: absolute; inset: 0; z-index: 10; pointer-events: none; }
.hud-obj { position: absolute; top: max(14px, env(safe-area-inset-top)); left: max(14px, env(safe-area-inset-left)); display: flex; align-items: center; gap: 10px; padding: 11px 16px 11px 11px; max-width: min(440px, 62vw); }
.hud-obj.pop { animation: objPop .5s cubic-bezier(.2, 1.4, .4, 1); }
@keyframes objPop { from { transform: translateX(-20px); opacity: 0; } to { transform: none; opacity: 1; } }
.hud-obj-icon { width: 34px; height: 34px; flex: none; color: var(--sky2); }
.hud-obj-text { font-weight: 700; font-size: 16.5px; line-height: 1.2; }
.hud-obj-hint { font-size: 13.5px; color: var(--muted); line-height: 1.2; margin-top: 2px; }
.hud-obj-count { margin-left: 6px; background: var(--lemon); color: var(--night); font-weight: 800; border-radius: 999px; padding: 2px 11px; font-size: 16px; border: 2px solid var(--sky2); }
.hud-obj-count.bump { animation: bump .45s cubic-bezier(.2, 1.8, .4, 1); }
@keyframes bump { 40% { transform: scale(1.35); } }
.hud-right { position: absolute; top: max(14px, env(safe-area-inset-top)); right: max(14px, env(safe-area-inset-right)); display: flex; gap: 8px; align-items: center; }
.hud-chip { display: flex; align-items: center; gap: 5px; background: var(--panel); border: 2px solid var(--sky); border-radius: 999px; padding: 4px 12px 4px 8px; font-weight: 700; font-size: 16px; box-shadow: 0 4px 12px rgba(15, 42, 68, .2); }
.hud-chip .ic { width: 22px; height: 22px; }
.hud-feathers .ic { color: var(--lemon2); }
.hud-pearls .ic { color: #9a86d8; }
.hud-btn { pointer-events: auto; width: 44px; height: 44px; border-radius: 50%; border: 2px solid var(--sky); background: var(--panel); color: var(--sky3); padding: 9px; cursor: pointer; box-shadow: 0 4px 12px rgba(15, 42, 68, .2); }
.hud-btn:hover { background: #fff; }
.hud-btn svg { width: 100%; height: 100%; display: block; }

.npc-label { position: absolute; left: 0; top: 0; display: flex; align-items: center; gap: 5px; white-space: nowrap; background: rgba(251, 253, 255, .86); color: var(--night); border: 1.5px solid var(--sky); padding: 1px 10px; border-radius: 999px; font-weight: 700; font-size: 14px; transition: opacity .2s; will-change: transform; }
.npc-label .q { display: none; width: 20px; height: 20px; border-radius: 50%; background: var(--lemon); color: var(--night); font-weight: 800; text-align: center; line-height: 20px; font-size: 14px; animation: hop 1s ease-in-out infinite; }
.npc-label.quest .q { display: inline-block; }
@keyframes hop { 50% { transform: translateY(-4px); } }
.hud-prompt { position: absolute; left: 0; top: 0; display: flex; align-items: center; gap: 8px; background: var(--lemon); color: var(--night); font-weight: 800; font-size: 16px; padding: 5px 16px 5px 6px; border-radius: 999px; border: 2px solid var(--sky3); box-shadow: 0 6px 18px rgba(15, 42, 68, .3); will-change: transform; animation: promptIn .25s ease; }
.hud-prompt .key { display: inline-grid; place-items: center; width: 28px; height: 28px; border-radius: 8px; background: #fff; border: 2px solid var(--sky3); font-size: 15px; }
.hud-prompt.touch .key { display: none; }
.hud-prompt.touch { padding-left: 16px; }
@keyframes promptIn { from { opacity: 0; } to { opacity: 1; } }
.hud-edge { position: absolute; left: 0; top: 0; width: 46px; height: 46px; color: var(--lemon); filter: drop-shadow(0 0 2px var(--sky3)) drop-shadow(0 3px 8px rgba(15, 42, 68, .5)); will-change: transform; }
.hud-edge svg { width: 100%; height: 100%; animation: pulse 1.2s ease-in-out infinite; }
@keyframes pulse { 50% { transform: scale(1.15); } }
.hud-toast { position: absolute; top: 82px; left: 50%; transform: translateX(-50%) translateY(-10px); background: var(--panel); border: 2px solid var(--sky2); color: var(--night); border-radius: 999px; padding: 8px 20px; font-weight: 700; opacity: 0; transition: opacity .3s, transform .3s; max-width: 90vw; text-align: center; }
.hud-toast.show { opacity: 1; transform: translateX(-50%); }
.hud-controls { position: absolute; bottom: 18px; left: 50%; transform: translateX(-50%); background: rgba(251, 253, 255, .9); border: 1.5px solid var(--sky); border-radius: 999px; padding: 7px 18px; font-size: 14px; color: var(--night); text-align: center; max-width: 92vw; opacity: 0; transition: opacity .6s; }
.hud-controls.show { opacity: 1; }

/* ---------------------------------------------------------------- Bogen: Zielkreuz und Windanzeige */
/* Bogen: Spannungs-Balken und Hinweis – kein Fadenkreuz, die braunen Punkte der Flugbahn zeigen, wohin der Pfeil fliegt */
.aimbar { position: absolute; left: 50%; bottom: max(26px, 11vh); z-index: 12; transform: translateX(-50%); pointer-events: none; display: flex; flex-direction: column; align-items: center; gap: 8px; }
/* auf dem Handy nur der Hinweis oben (die Spannung zeigt der Ring um den Bogen-Knopf) */
.game-root.is-touch .aimbar { bottom: auto; top: calc(max(14px, env(safe-area-inset-top)) + 64px); }
.game-root.is-touch .ab-bar { display: none; }
.ab-bar { position: relative; width: 136px; height: 12px; border-radius: 999px; background: rgba(251, 253, 255, .88); border: 2px solid var(--night); overflow: hidden; box-shadow: 0 3px 10px rgba(15, 42, 68, .25); }
.ab-bar i { position: absolute; left: 0; top: 0; bottom: 0; width: calc(var(--p, 0) * 100%); background: linear-gradient(90deg, #c98a3a, #7a4a26); }
.aimbar.full .ab-bar i { background: linear-gradient(90deg, var(--lemon2), var(--lemon)); }
.aimbar.blocked .ab-bar i { background: #e8743a; }
.ab-msg { background: rgba(251, 253, 255, .92); color: var(--night); border: 2px solid var(--sky2); font-weight: 700; font-size: 15px; padding: 4px 14px; border-radius: 999px; white-space: nowrap; }
.ab-msg:empty { display: none; }
.aimbar.blocked .ab-msg { border-color: #e8743a; background: #fff1e8; }
.windbox { position: absolute; z-index: 11; right: max(14px, env(safe-area-inset-right)); top: calc(max(14px, env(safe-area-inset-top)) + 56px); display: flex; align-items: center; gap: 6px; background: var(--panel); border: 2px solid var(--sky); border-radius: 999px; padding: 4px 12px 4px 6px; pointer-events: none; box-shadow: 0 4px 12px rgba(15, 42, 68, .2); }
.wb-arrow { width: 26px; height: 26px; color: var(--sky2); transition: transform .4s ease; }
.wb-arrow svg { width: 100%; height: 100%; display: block; }
.wb-bars { display: flex; gap: 3px; align-items: flex-end; }
.wb-bars i { width: 5px; border-radius: 2px; background: #c6d6e2; }
.wb-bars i:nth-child(1) { height: 8px; } .wb-bars i:nth-child(2) { height: 12px; } .wb-bars i:nth-child(3) { height: 16px; }
.wb-bars i.on { background: var(--sky2); }
.wb-lbl { font-size: 13px; font-weight: 700; color: var(--night); }
.game-root.aiming .hud-obj, .game-root.aiming .npc-label, .game-root.aiming .hud-prompt { opacity: .35; }

/* ---------------------------------------------------------------- Dialog: wolkenweiß, Namensschild als Feder */
.dialog { position: absolute; left: 50%; bottom: max(16px, env(safe-area-inset-bottom)); transform: translateX(-50%); width: min(820px, 94vw); z-index: 20; }
.dlg-box { position: relative; padding: 18px 24px 14px; cursor: pointer; min-height: 104px; color: var(--ink); }
.dlg-box.in { animation: dlgIn .28s ease; }
@keyframes dlgIn { from { transform: translateY(12px); opacity: 0; } to { transform: none; opacity: 1; } }
.dlg-name { position: absolute; top: -19px; left: 22px; display: flex; align-items: center; gap: 7px; background: var(--sky2); color: #fff; border-radius: 22px 4px 22px 4px; padding: 3px 18px 3px 10px; font-weight: 700; font-size: 16px; box-shadow: 0 4px 10px rgba(15, 42, 68, .25); }
.dlg-name::after { content: ''; position: absolute; left: 8px; right: 10px; top: 50%; height: 1.5px; background: rgba(255, 255, 255, .45); transform: rotate(-4deg); }
.dlg-speaker { position: relative; z-index: 1; color: #fff !important; }
.dlg-dot { position: relative; z-index: 1; width: 13px; height: 13px; border-radius: 50%; border: 2px solid #fff; }
.dlg-text { font-size: clamp(17px, 2.2vw, 20.5px); line-height: 1.45; font-weight: 400; min-height: 2.8em; }
.dlg-next { position: absolute; right: 22px; bottom: 9px; font-size: 14px; font-weight: 700; color: var(--sky3); opacity: 0; transition: opacity .2s; }
.dlg-next.show { opacity: 1; animation: nudge 1s ease-in-out infinite; }
@keyframes nudge { 50% { transform: translateX(5px); } }
.dialog.narrator .dlg-box { background: rgba(255, 246, 194, .96); border-color: var(--lemon2); outline-color: rgba(242, 194, 0, .55); }
.dialog.narrator .dlg-name { background: var(--lemon2); }
.dialog.narrator .dlg-speaker { color: var(--night) !important; }
.dialog.narrator .dlg-text { color: #2a2a1a; }
.dlg-skip { position: absolute; right: 8px; top: -46px; border: 2px solid var(--sky); background: var(--panel); color: var(--night); border-radius: 999px; padding: 4px 14px; font-weight: 700; font-size: 14px; cursor: pointer; }
.bark { position: absolute; left: 50%; bottom: 120px; transform: translateX(-50%) translateY(8px); z-index: 21; background: var(--panel); border: 2px solid var(--sky); color: var(--night); border-radius: 16px; padding: 8px 18px; font-size: 17px; max-width: min(640px, 90vw); text-align: center; opacity: 0; transition: opacity .3s, transform .3s; pointer-events: none; }
.bark.show { opacity: 1; transform: translateX(-50%); }

/* ---------------------------------------------------------------- Übergänge */
.fade { position: absolute; inset: 0; background: #0b1d33; opacity: 0; pointer-events: none; z-index: 60; transition-property: opacity; transition-timing-function: ease; }
.fade.on { opacity: 1; }
.letterbox { position: absolute; left: 0; right: 0; height: 8vh; background: #0b1d33; z-index: 18; transition: transform .7s ease; pointer-events: none; }
.letterbox.top { top: 0; transform: translateY(-100%); }
.letterbox.bottom { bottom: 0; transform: translateY(100%); }
.letterbox.on { transform: none; }
.title-card { position: absolute; left: 50%; top: 42%; transform: translate(-50%, -50%); z-index: 65; text-align: center; opacity: 0; pointer-events: none; transition: opacity .9s ease, transform 1.2s ease; padding: 24px 56px; }
.title-card::before { content: ''; position: absolute; left: 50%; top: 50%; width: 120%; aspect-ratio: 1; transform: translate(-50%, -50%); border-radius: 50%; background: radial-gradient(circle, rgba(251, 253, 255, .9) 0 40%, rgba(124, 196, 240, .55) 40% 52%, rgba(251, 253, 255, .4) 52% 62%, rgba(124, 196, 240, 0) 70%); z-index: -1; }
.title-card.show { opacity: 1; transform: translate(-50%, -54%); }
.tc-num { font-size: 19px; font-weight: 700; color: var(--sky3); letter-spacing: 4px; text-transform: uppercase; }
.tc-num::before, .tc-num::after { content: '➶'; margin: 0 12px; font-size: 18px; }
.tc-num::after { content: '➴'; }
.tc-title { font-family: var(--font-title); font-size: clamp(36px, 6.2vw, 66px); font-weight: 700; color: var(--night); line-height: 1.05; text-shadow: 0 4px 0 var(--lemon); }
.tc-sub { font-size: clamp(17px, 2.5vw, 24px); color: var(--sky3); margin-top: 8px; font-weight: 500; }

/* Erinnerung (Kapitel 5): sepiafarbenes Bild mit weichem Rand */
.game-root.memory .game-canvas { filter: sepia(.78) saturate(.75) brightness(1.06) contrast(.95); }
.game-root::after { content: ''; position: absolute; inset: 0; z-index: 5; pointer-events: none; background: radial-gradient(ellipse at center, transparent 50%, rgba(70, 48, 22, .6)); opacity: 0; transition: opacity 1.2s ease; }
.game-root.memory::after { opacity: 1; }

/* ---------------------------------------------------------------- Overlays (Tugend, Perle) */
.overlay-layer { position: absolute; inset: 0; z-index: 50; pointer-events: none; }
.overlay { position: absolute; inset: 0; display: grid; place-items: center; background: rgba(15, 42, 68, .35); opacity: 0; transition: opacity .35s; pointer-events: auto; padding: 16px; }
.overlay.open { opacity: 1; }
.vp-card, .pc-card, .rh-card { position: relative; width: min(470px, 92vw); padding: 30px 26px 22px; text-align: center; transform: scale(.85); transition: transform .45s cubic-bezier(.2, 1.5, .4, 1); overflow: hidden; }
.overlay.open .vp-card, .overlay.open .pc-card, .overlay.open .rh-card { transform: none; }
.vp-rays { position: absolute; left: 50%; top: 64px; width: 360px; height: 360px; margin: -180px 0 0 -180px; background: repeating-conic-gradient(rgba(255, 225, 77, .35) 0 10deg, transparent 10deg 20deg); border-radius: 50%; animation: spin 18s linear infinite; mask-image: radial-gradient(circle, #000 20%, transparent 65%); -webkit-mask-image: radial-gradient(circle, #000 20%, transparent 65%); }
.vp-icon { position: relative; width: 86px; height: 86px; margin: 0 auto 8px; color: var(--sky2); background: radial-gradient(circle closest-side, #fff 0 80%, var(--lemon) 80% 90%, transparent 92%); border-radius: 50%; padding: 18px; }
.vp-kicker, .pc-kicker { position: relative; color: var(--sky3); font-weight: 700; letter-spacing: 2px; text-transform: uppercase; font-size: 14px; }
.vp-name { position: relative; font-family: var(--font-title); font-size: 34px; font-weight: 700; color: var(--night); margin: 2px 0 6px; }
.vp-text, .pc-text { position: relative; font-size: 17.5px; line-height: 1.5; margin-bottom: 18px; }
.pc-pearl { width: 70px; height: 70px; margin: 0 auto 10px; border-radius: 50%; background: radial-gradient(circle at 35% 30%, #fff, #efe6ff 35%, #b9a8e8 75%, #8a78c8); box-shadow: 0 0 30px rgba(154, 134, 216, .6); animation: float 2.5s ease-in-out infinite; }
@keyframes float { 50% { transform: translateY(-6px); } }
.pc-card { border-color: #b9a8e8; }
.rh-phone { width: 46px; height: 76px; margin: 0 auto 12px; border: 4px solid var(--sky2); border-radius: 10px; animation: turn 2s ease-in-out infinite; }
@keyframes turn { 50% { transform: rotate(-90deg); } }
.rh-card p { font-size: 18px; margin: 0 0 16px; }

/* ---------------------------------------------------------------- Minispiele (gemeinsam) */
.mg { position: absolute; inset: 0; z-index: 40; display: flex; flex-direction: column; align-items: center; justify-content: space-between; padding: 11vh 16px max(22px, env(safe-area-inset-bottom)); opacity: 0; transition: opacity .5s; touch-action: none; cursor: pointer; }
.mg.open { opacity: 1; }
.mg-hint { padding: 9px 22px; font-weight: 700; font-size: 16.5px; text-align: center; max-width: min(760px, 92vw); color: var(--night); }
.mg-center { position: absolute; left: 72%; top: 50%; width: 0; height: 0; }
.mg-target { position: absolute; left: 0; top: 0; width: 150px; height: 150px; transform: translate(-50%, -50%); border-radius: 50%; border: 6px solid #fff; box-shadow: 0 0 0 3px var(--sky3), 0 0 30px rgba(255, 255, 255, .6), inset 0 0 0 3px var(--sky3); transition: box-shadow .15s, border-color .15s, transform .15s; }
.mg-target.near { border-color: var(--lemon); box-shadow: 0 0 0 3px var(--sky3), 0 0 50px rgba(255, 225, 77, .9), inset 0 0 0 3px var(--sky3); }
.mg-target.hit { transform: translate(-50%, -50%) scale(1.18); }
.mg-ring { position: absolute; left: 0; top: 0; width: 150px; height: 150px; border-radius: 50%; border: 7px solid var(--lemon); box-shadow: 0 0 0 2px var(--sky3), 0 0 24px rgba(255, 225, 77, .8); transform: translate(-50%, -50%) scale(2.7); pointer-events: none; }
.mg-pop { position: absolute; left: 0; top: -130px; transform: translate(-50%, 0); font-family: var(--font-title); font-size: 42px; font-weight: 700; white-space: nowrap; opacity: 0; pointer-events: none; }
.mg-pop.show { animation: popWord 1s ease forwards; }
.mg-pop.good { color: var(--lemon); text-shadow: 0 3px 0 var(--sky3), 0 0 18px rgba(255, 255, 255, .8); }
.mg-pop.miss { color: #fff; font-size: 26px; text-shadow: 0 2px 0 var(--sky3), 0 3px 10px rgba(15, 42, 68, .7); }
@keyframes popWord { 0% { opacity: 0; transform: translate(-50%, 10px) scale(.7); } 25% { opacity: 1; transform: translate(-50%, 0) scale(1.1); } 100% { opacity: 0; transform: translate(-50%, -30px) scale(1); } }
.mg-dots { display: flex; gap: 10px; margin-bottom: 84px; }
.mg-dot { width: 22px; height: 22px; border-radius: 50%; border: 3px solid var(--sky3); background: rgba(251, 253, 255, .8); transition: background .3s, transform .3s; }
.mg-dot.on { background: var(--lemon); box-shadow: 0 0 14px rgba(255, 225, 77, .9); transform: scale(1.15); }
.mg-btn { position: absolute; right: max(22px, env(safe-area-inset-right)); bottom: max(22px, env(safe-area-inset-bottom)); min-width: 150px; height: 74px; border: 0; background: var(--night); color: var(--night); font-size: 25px; font-weight: 700; cursor: pointer; padding: 0 44px 0 34px; clip-path: var(--arrow); isolation: isolate; }
.mg-btn::before { content: ''; position: absolute; inset: 4px 5px; z-index: -1; background: linear-gradient(180deg, #fff3a0, var(--lemon) 50%, var(--lemon2)); clip-path: var(--arrow); }
.mg-btn:active { transform: scale(.95); }
.mg-verse { position: absolute; top: 19vh; left: 50%; transform: translateX(-50%); text-align: center; width: min(820px, 94vw); opacity: 0; transition: opacity .5s; pointer-events: none; background: var(--panel); border: 2.5px solid var(--sky); border-radius: 28px; padding: 12px 22px 16px; box-shadow: var(--shadow); }
.mg-verse.in { opacity: 1; }
.mg-ar { font-family: var(--ar); font-size: clamp(34px, 6.4vw, 62px); color: var(--night); line-height: 1.7; }
.mg-tl { font-size: clamp(17px, 2.6vw, 24px); font-weight: 700; color: var(--sky3); }
.mg-mean { font-size: clamp(15.5px, 2.2vw, 20px); color: var(--ink); margin-top: 4px; line-height: 1.4; }
.mg-verse-game .mg-center { top: 66%; }
@media (max-width: 700px) { .mg-center { left: 50%; top: 66%; } }

/* Pfeil befiedern */
.fl-stage { position: relative; flex: 1; width: min(92vw, 520px); display: grid; place-items: center; }
.fl-svg { width: min(78vw, 44vh, 380px); height: auto; overflow: visible; filter: drop-shadow(0 10px 20px rgba(15, 42, 68, .35)); }
.fl-glow { fill: rgba(251, 253, 255, .92); stroke: var(--sky); stroke-width: 3; stroke-dasharray: 8 6; }
.fl-shaft { fill: #d9b07a; stroke: #8a5a32; stroke-width: 3; }
.fl-nock { fill: #3a2e26; }
.fl-slot path { fill: none; stroke: #9fb6c8; stroke-width: 2.5; stroke-dasharray: 6 5; }
.fl-slot.next path { stroke: var(--sky2); stroke-width: 3.5; fill: rgba(124, 196, 240, .25); animation: slotPulse 1s ease-in-out infinite; }
.fl-stage.near .fl-slot.next path { fill: rgba(255, 225, 77, .55); stroke: var(--lemon2); }
.fl-slot.filled path { stroke: transparent; fill: none; animation: none; }
@keyframes slotPulse { 50% { stroke-opacity: .5; } }
.fl-cur path, .fl-done path { fill: #fbf8f0; stroke: var(--sky3); stroke-width: 2.5; stroke-linejoin: round; }
.fl-cur path:first-child { fill: var(--lemon); }
.fl-done:nth-child(3n+1) path:first-child { fill: var(--lemon); }
.fl-quill { fill: none !important; stroke: #b8864a !important; stroke-width: 3 !important; }
.fl-count { position: absolute; top: 4px; left: 50%; transform: translateX(-50%); background: var(--panel); border: 2px solid var(--sky); border-radius: 999px; padding: 3px 14px; font-weight: 700; font-size: 15px; }
.fl-stage .mg-pop { left: 50%; top: 18%; }

/* Tablett balancieren */
.tr-stage { position: relative; flex: 1; width: min(92vw, 640px); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 18px; }
.tr-tray { position: relative; width: min(66vw, 300px); height: 120px; transition: transform .05s linear; }
.tr-plate { position: absolute; left: 0; right: 0; bottom: 0; height: 22px; border-radius: 50%; background: radial-gradient(ellipse at 50% 30%, #ffe08a, #d8a84a 60%, #a8782a); box-shadow: 0 8px 18px rgba(15, 42, 68, .35); border: 3px solid #8a6020; }
.tr-bowl { position: absolute; left: 14%; bottom: 14px; width: 42%; height: 70px; border-radius: 0 0 50% 50% / 0 0 80% 80%; background: linear-gradient(180deg, #c07a46, #8a4a22); border: 3px solid #5a2e14; overflow: hidden; }
.tr-milk { position: absolute; left: -20%; right: -20%; top: 14%; height: 120%; background: #fffaf0; border-top: 3px solid #fff; transform-origin: 50% 0; }
.tr-milk.spill { animation: spill .7s ease; }
@keyframes spill { 30% { top: 34%; } }
.tr-dates { position: absolute; right: 12%; bottom: 18px; display: flex; gap: 2px; }
.tr-dates i { width: 18px; height: 26px; border-radius: 50%; background: radial-gradient(circle at 35% 30%, #c0662a, #7a3a1a); border: 2px solid #4a1e0a; }
.tr-level { position: relative; width: min(70vw, 320px); height: 20px; border-radius: 999px; background: linear-gradient(90deg, #ffb39a, #fff 22%, #fff 78%, #ffb39a); border: 2.5px solid var(--sky3); }
.tr-zone { position: absolute; left: 32%; right: 32%; top: 2px; bottom: 2px; border-radius: 999px; background: rgba(124, 196, 240, .45); }
.tr-needle { position: absolute; top: -6px; width: 6px; height: 28px; margin-left: -3px; border-radius: 3px; background: var(--night); }
.tr-path { position: relative; width: min(88vw, 560px); height: 46px; border-radius: 999px; background: var(--panel); border: 2.5px solid var(--sky); }
.tr-ob { position: absolute; top: 50%; width: 34px; height: 26px; transform: translate(-50%, -50%); color: var(--sky3); }
.tr-ob svg { width: 100%; height: 100%; }
.tr-ob.past { opacity: .3; }
.tr-walker { position: absolute; top: 50%; width: 30px; height: 30px; margin-left: -15px; transform: translateY(-50%); border-radius: 50%; background: var(--sky2); border: 3px solid #fff; box-shadow: 0 0 0 2px var(--sky3); transition: left .1s linear; }
.tr-goal { position: absolute; right: 8px; top: 50%; transform: translateY(-50%); font-weight: 700; font-size: 13px; color: var(--sky3); }
.tr-stage .mg-pop { left: 50%; top: 4%; }
.tr-btns { display: flex; gap: 22vw; margin-bottom: 10px; }
.tr-btn { width: 96px; height: 80px; border-radius: 24px; border: 3px solid var(--sky3); background: var(--panel); color: var(--sky3); font-size: 36px; font-weight: 700; cursor: pointer; box-shadow: 0 6px 14px rgba(15, 42, 68, .3); touch-action: none; }
.tr-btn.down { background: var(--lemon); transform: scale(.95); }

/* Laternen-Wache */
.mg-lantern { padding-top: 9vh; }
.ln-stage { position: relative; flex: 1; width: min(94vw, 860px); max-height: 62vh; margin: 12px 0; border-radius: 26px; overflow: hidden; border: 3px solid var(--sky2); box-shadow: var(--shadow); cursor: none; --lx: 50%; --ly: 55%; }
.ln-scene { position: absolute; inset: 0; width: 100%; height: 100%; }
.ln-crit { position: absolute; width: 11%; aspect-ratio: 4 / 3; transform: translate(-50%, -50%); opacity: 0; transition: opacity .4s, transform .4s; }
.ln-crit svg { width: 100%; height: 100%; display: block; }
.ln-crit.seen { opacity: 1; transform: translate(-50%, -60%) scale(1.15); }
.ln-lbl { position: absolute; left: 50%; top: -30px; transform: translateX(-50%); white-space: nowrap; background: var(--lemon); color: var(--night); font-weight: 700; font-size: 13px; padding: 2px 10px; border-radius: 999px; border: 2px solid var(--sky3); }
.ln-lbl:empty { display: none; }
.ln-rustle { position: absolute; width: 60px; height: 30px; transform: translate(-50%, -50%); display: none; z-index: 3; }
.ln-rustle.on { display: block; }
.ln-rustle i { position: absolute; top: 40%; width: 14px; height: 4px; border-radius: 4px; background: rgba(255, 255, 255, .55); animation: rustle .6s ease-in-out infinite; }
.ln-rustle i:nth-child(1) { left: 6px; transform: rotate(-30deg); }
.ln-rustle i:nth-child(2) { left: 23px; top: 10%; animation-delay: .15s; }
.ln-rustle i:nth-child(3) { left: 40px; transform: rotate(30deg); animation-delay: .3s; }
@keyframes rustle { 50% { opacity: .1; transform: translateY(-4px) rotate(10deg); } }
.ln-dark { position: absolute; inset: 0; z-index: 2; pointer-events: none; background: radial-gradient(circle at var(--lx) var(--ly), rgba(255, 220, 140, .12) 0, rgba(5, 12, 30, 0) 60px, rgba(5, 12, 30, .93) 120px); }
.ln-lamp { position: absolute; z-index: 4; width: 30px; height: 40px; margin: -20px 0 0 -15px; pointer-events: none; background: radial-gradient(circle at 50% 60%, #fff3b0 0 30%, #ffc04a 32% 46%, transparent 48%), linear-gradient(#3a2e26, #3a2e26) 50% 0 / 4px 10px no-repeat; filter: drop-shadow(0 0 10px rgba(255, 200, 90, .9)); }
.ln-stage .mg-pop { left: 50%; top: 10%; z-index: 5; }

/* Ein Drittel teilen */
.th-stage { position: relative; flex: 1; width: min(94vw, 720px); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px; }
.th-cloth { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; max-width: min(90vw, 460px); padding: 14px 18px; border-radius: 18px; background: repeating-linear-gradient(45deg, #f5ead2 0 12px, #efe0c0 12px 24px); border: 3px solid #c9a06a; min-height: 70px; box-shadow: 0 6px 14px rgba(15, 42, 68, .25); }
.th-item { width: 40px; height: 40px; transition: transform .35s, opacity .35s; }
.th-item svg { width: 100%; height: 100%; }
.th-item.gone { opacity: 0; transform: translateY(40px) scale(.4); }
.th-bowls { display: flex; gap: 16px; width: 100%; justify-content: center; }
.th-bowl { position: relative; flex: 1 1 0; max-width: 320px; appearance: none; cursor: pointer; border: 3px solid var(--sky2); border-radius: 0 0 140px 140px / 0 0 90px 90px; background: linear-gradient(180deg, #fff, var(--cloud2)); padding: 12px 10px 22px; display: flex; flex-direction: column; align-items: center; gap: 6px; box-shadow: 0 8px 18px rgba(15, 42, 68, .28); font-family: inherit; color: var(--ink); transition: transform .15s; }
.th-bowl:active { transform: scale(.97); }
.th-bowl.nope { animation: shake .4s; }
.th-stage[data-need="poor"] .th-bowl.poor, .th-stage[data-need="fam"] .th-bowl.fam { border-color: var(--lemon2); box-shadow: 0 0 0 4px rgba(255, 225, 77, .6), 0 8px 18px rgba(15, 42, 68, .28); }
.th-name { font-weight: 700; font-size: 15px; text-align: center; line-height: 1.15; }
.th-slots { display: flex; flex-wrap: wrap; gap: 4px; justify-content: center; min-height: 32px; }
.th-slots i { width: 28px; height: 28px; opacity: .18; filter: grayscale(1); transition: opacity .3s, filter .3s; }
.th-slots i.on { opacity: 1; filter: none; }
.th-slots i svg { width: 100%; height: 100%; }
.th-frac { font-family: var(--font-title); font-size: 30px; font-weight: 700; color: var(--sky3); line-height: 1; }
.th-key { font-size: 12px; color: var(--muted); }
.th-sum { font-weight: 700; font-size: 16px; background: var(--panel); border: 2px solid var(--sky); border-radius: 999px; padding: 4px 16px; text-align: center; max-width: 92vw; }
.th-stage .mg-pop { left: 50%; top: 0; }

/* ---------------------------------------------------------------- Touch-Steuerung */
.touch-layer { position: absolute; inset: 0; z-index: 15; display: none; }
.game-root.is-touch.playing .touch-layer { display: block; }
.game-root.talking .touch-layer .touch-zone, .game-root.talking .touch-layer .joy { display: none; }
.touch-zone { position: absolute; top: 70px; bottom: 0; }
.touch-left { left: 0; width: 45%; }
.touch-right { right: 0; width: 55%; }
.joy { position: absolute; width: 130px; height: 130px; margin: -65px 0 0 -65px; border-radius: 50%; border: 3px solid rgba(251, 253, 255, .7); background: rgba(61, 142, 201, .2); opacity: 0; transition: opacity .15s; pointer-events: none; left: 110px; top: calc(100% - 130px); }
.joy.active { opacity: 1; }
.game-root.is-touch.playing:not(.talking) .joy:not(.active) { opacity: .5; }
.joy-knob { position: absolute; left: 50%; top: 50%; width: 58px; height: 58px; border-radius: 50%; background: radial-gradient(circle at 40% 35%, #fff, var(--lemon)); border: 3px solid var(--sky3); transform: translate(-50%, -50%); }
.tbtn { position: absolute; border-radius: 50%; border: 3px solid var(--sky2); background: rgba(251, 253, 255, .78); color: var(--sky3); display: grid; place-items: center; padding: 0; touch-action: none; }
.tbtn svg { width: 55%; height: 55%; }
.tbtn.down { transform: scale(.92); background: var(--lemon); }
.tbtn-jump { right: max(28px, env(safe-area-inset-right)); bottom: max(34px, env(safe-area-inset-bottom)); width: 78px; height: 78px; }
.tbtn-action { right: max(118px, calc(env(safe-area-inset-right) + 96px)); bottom: max(78px, env(safe-area-inset-bottom)); width: 70px; height: 70px; opacity: .6; }
.tbtn-action.available { opacity: 1; border-color: var(--lemon2); background: var(--lemon); color: var(--night); animation: glowBtn 1.2s ease-in-out infinite; }
.tbtn-bow { right: max(36px, env(safe-area-inset-right)); bottom: max(130px, calc(env(safe-area-inset-bottom) + 112px)); width: 74px; height: 74px; display: none; }
.game-root.has-bow .tbtn-bow { display: grid; }
.game-root.aiming .tbtn-bow { background: var(--lemon); border-color: var(--night); }
/* Spannung beim Zielen auf dem Handy: brauner Ring um den Bogen-Knopf (statt Balken über dem Bild) */
.tbtn-bow::after { content: ''; position: absolute; inset: -11px; border-radius: 50%; --bowp: 0; background: conic-gradient(#7a4a26 calc(var(--bowp) * 360deg), rgba(251, 253, 255, .55) 0); -webkit-mask: radial-gradient(circle, transparent 62%, #000 64%); mask: radial-gradient(circle, transparent 62%, #000 64%); opacity: 0; pointer-events: none; }
.game-root.aiming .tbtn-bow::after { opacity: 1; }
.game-root.aiming.bow-full .tbtn-bow::after { background: var(--lemon2); }
.game-root.aiming.bow-blocked .tbtn-bow::after { background: #e8743a; }
@keyframes glowBtn { 50% { box-shadow: 0 0 22px rgba(255, 225, 77, .9); } }
.tbtn-label { position: absolute; bottom: -22px; left: 50%; transform: translateX(-50%); white-space: nowrap; font-size: 13px; font-weight: 700; background: var(--panel); color: var(--night); padding: 0 8px; border-radius: 999px; }
.tbtn-label:empty { display: none; }
.game-root.talking .tbtn { opacity: .25; }

/* ---------------------------------------------------------------- Konfetti */
.confetti { position: absolute; inset: 0; z-index: 75; pointer-events: none; overflow: hidden; }
.confetti i { position: absolute; top: -20px; width: 10px; height: 16px; border-radius: 3px; animation: fall linear forwards; }
@keyframes fall { to { transform: translateY(110vh) rotate(720deg); } }

/* ---------------------------------------------------------------- Kleine Bildschirme */
.game-root.small .hud-obj { max-width: 58vw; padding: 7px 10px 7px 7px; border-radius: 16px; outline-offset: -6px; }
.game-root.small .hud-obj-text { font-size: 14px; }
.game-root.small .hud-obj-hint { font-size: 12px; }
.game-root.small .hud-obj-icon { width: 26px; height: 26px; }
.game-root.small .hud-chip { font-size: 14px; padding: 2px 9px 2px 6px; }
.game-root.small .hud-chip .ic { width: 18px; height: 18px; }
.game-root.small .hud-btn { width: 38px; height: 38px; padding: 8px; }
.game-root.small .dlg-box { padding: 14px 16px 10px; min-height: 84px; border-radius: 18px; }
.game-root.small .dlg-text { font-size: 15.5px; }
.game-root.small .mg-target, .game-root.small .mg-ring { width: 110px; height: 110px; }
.game-root.small .mg-btn { height: 62px; font-size: 21px; min-width: 120px; }
.game-root.small .title-buttons .btn { min-height: 44px; padding: 8px 34px 8px 26px; font-size: 16px; }
.game-root.small .title-buttons .btn.big { font-size: 18px; }
.game-root.small .light-note { font-size: 11.5px; }
.game-root.small .screen h2 { margin-bottom: 10px; }
.game-root.small .bark { bottom: 100px; font-size: 15px; }
.game-root.small .windbox { top: calc(max(14px, env(safe-area-inset-top)) + 48px); }
@media (max-width: 760px) {
  .v-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .title-screen { align-items: center; padding-left: 18px; background: rgba(216, 238, 251, .35); }
  .title-wrap { width: min(440px, 94vw); }
  .t-target { width: min(78vw, 40vh, 360px); }
  /* Köcher wird zur Liste: jeder Pfeil liegt quer */
  .qv-quiver { display: none; }
  .qv-arrows { flex-direction: column; gap: 10px; margin-bottom: 0; align-items: stretch; width: min(460px, 92vw); }
  .ch-card.qv-arrow { width: 100%; height: auto; min-height: 62px; transform: none !important; flex-direction: row; align-items: center; padding: 0 28px 0 54px; background: var(--sky2); clip-path: var(--arrow); isolation: isolate; }
  .ch-card.qv-arrow::before { content: ''; position: absolute; inset: 3px 4px; z-index: -1; background: var(--cloud); clip-path: var(--arrow); }
  .ch-card.qv-arrow::after { content: ''; position: absolute; left: 4px; top: 3px; bottom: 3px; width: 28px; z-index: 0; background: repeating-linear-gradient(135deg, var(--lemon) 0 6px, #fff 6px 12px); clip-path: polygon(0 0, 100% 0, 60% 50%, 100% 100%, 0 100%, 40% 50%); }
  .ch-card.qv-arrow.locked { background: #9aa6b2; }
  .ch-card.qv-arrow.locked::after { background: #c6ced6; }
  .qv-svg { display: none; }
  .qv-arrow .ch-num { position: static; transform: none; flex: none; margin-right: 10px; }
  .qv-tag { position: static; transform: none; border: 0; box-shadow: none; background: transparent; text-align: left; padding: 6px 0; }
  .qv-tag::before { display: none; }
  .qv-arrow.locked .qv-tag { background: transparent; }
  .ch-done { top: 50%; right: 34px; transform: translateY(-50%); }
}
@media (max-height: 760px) {
  .title-main { font-size: clamp(40px, 9vh, 76px); }
  .title-ar { font-size: clamp(32px, 7vh, 60px); }
  .title-sub { font-size: clamp(15px, 3vh, 24px); }
  .title-tag { margin-bottom: 10px; font-size: 14px; }
  .title-buttons { display: grid; grid-template-columns: 1fr 1fr; width: min(470px, 86vw); gap: 8px; margin-bottom: 10px; }
  .title-buttons .btn.big { grid-column: span 2; }
  .title-buttons .btn { min-height: 44px; padding: 8px 32px 8px 24px; font-size: 15.5px; }
  .light-note { font-size: 12px; margin-top: 6px; }
  .screen h2 { margin-bottom: 10px; }
}
/* Köcher (nur breite Bildschirme – schmale haben die Liste) */
@media (max-height: 760px) and (min-width: 761px) { .ch-card.qv-arrow { height: min(340px, 50vh); } }
@media (max-height: 520px) {
  .title-screen { justify-content: center; }
  .title-wrap { display: grid; grid-template-columns: auto minmax(0, 1fr); column-gap: 18px; align-items: center; width: min(560px, 64vw); }
  .t-target { grid-column: 1; grid-row: 1 / span 3; width: min(62vh, 250px); }
  .title-tag, .title-buttons, .lang-switch { grid-column: 2; justify-self: center; }
  .title-ar { font-size: 30px; } .title-main { font-size: 40px; } .title-sub { font-size: 14px; }
  .title-buttons { width: 100%; grid-template-columns: 1fr 1fr; }
  .title-buttons .btn { min-height: 40px; font-size: 14.5px; }
  .light-note { display: none; }
  .mg { padding-top: 4vh; }
  .mg-verse { top: 10vh; }
  .mg-dots { margin-bottom: 14px; }
  .screen { padding-top: 10px; padding-bottom: 10px; }
  .screen h2 { font-size: 28px; margin-bottom: 2px; }
  .tr-tray { height: 90px; }
}
@media (max-height: 520px) and (min-width: 761px) {
  .qv-arrows { margin-bottom: -30px; }
  .ch-card.qv-arrow { height: 52vh; }
  .qv-quiver { height: 52px; }
}
@media (max-height: 520px) and (max-width: 760px) {
  .qv-arrows { gap: 4px; }
  .ch-card.qv-arrow { min-height: 42px; }
  .qv-tag { padding: 3px 0; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

/* Touch & Hochformat: Hinweise nicht über den Knöpfen */
.game-root.is-touch .hud-controls { bottom: auto; top: 70px; max-width: min(520px, 92vw); }
.game-root.portrait .hud-obj { top: calc(max(14px, env(safe-area-inset-top)) + 54px); max-width: calc(100vw - 28px); }
.game-root.portrait .windbox { top: calc(max(14px, env(safe-area-inset-top)) + 120px); }
.game-root.portrait.is-touch .hud-controls { top: 130px; }
.game-root.portrait .bark { bottom: 190px; }
.game-root.portrait .mg-btn { right: 50%; transform: translateX(50%); }
.game-root.portrait .mg-btn:active { transform: translateX(50%) scale(.95); }
.game-root.portrait .mg-dots { margin-bottom: 110px; }
.game-root.portrait .tr-btns { gap: 12vw; }
