:root {
  --cream: #f3ead7; --paper: #fff8ea; --navy: #1b2340; --navy2: #2a3456; --navy3: #3a4470;
  --blue: #2f5bea; --orange: #f26a21; --yellow: #ffd21f; --red: #ff4d5e;
  --fh: 'Anton', Impact, 'Arial Narrow Bold', 'Arial Black', sans-serif;
  --fb: 'Rubik', 'Segoe UI', Roboto, Arial, sans-serif;
  --st: env(safe-area-inset-top, 0px); --sb: env(safe-area-inset-bottom, 0px);
  --sl: env(safe-area-inset-left, 0px); --sr: env(safe-area-inset-right, 0px);
}
* { box-sizing: border-box; margin: 0; padding: 0; -webkit-tap-highlight-color: transparent; }
html, body { height: 100%; overflow: hidden; background: #0e1326; color: var(--navy); font-family: var(--fb); -webkit-user-select: none; user-select: none; touch-action: manipulation; overscroll-behavior: none; -webkit-text-size-adjust: 100%; }
#app { position: fixed; top: 0; bottom: 0; left: 50%; transform: translateX(-50%); width: 100%; max-width: 520px; background: var(--cream); overflow: hidden; box-shadow: 0 0 80px rgba(0, 0, 0, .6); }
img { -webkit-user-drag: none; pointer-events: none; }
button { font: inherit; color: inherit; border: 0; background: none; cursor: pointer; touch-action: manipulation; }
.screen { position: absolute; inset: 0; display: none; flex-direction: column; }
.screen.active { display: flex; }

/* ---------- Laden ---------- */
#scr-loading { background: var(--cream) repeating-linear-gradient(-55deg, transparent 0 46px, rgba(47, 91, 234, .14) 46px 92px); align-items: center; justify-content: center; cursor: pointer; }
.load-wrap { width: min(86%, 560px); display: flex; flex-direction: column; align-items: center; gap: 22px; }
.load-logo { width: 100%; min-height: 120px; object-fit: contain; filter: drop-shadow(0 6px 0 rgba(27, 35, 64, .25)); }
.load-bar { width: 80%; height: 18px; border: 3px solid var(--navy); border-radius: 10px; overflow: hidden; background: var(--paper); }
.load-bar i { display: block; height: 100%; width: 0; background: var(--orange); transition: width .15s; }
.load-text { color: var(--navy); font-family: var(--fh); font-size: 22px; letter-spacing: 2px; }
.blink { animation: blink 1s infinite; }

/* ---------- Lobby ---------- */
#scr-lobby { background-color: var(--cream); background-size: cover; background-position: center; }
.topbar { display: flex; align-items: center; gap: 8px; padding: calc(8px + var(--st)) 12px 6px; }
.avatar { width: 48px; height: 48px; border-radius: 50%; border: 3px solid var(--navy); overflow: hidden; flex: none; box-shadow: 2px 3px 0 var(--navy); background: var(--blue); }
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.avatar.framed { border-color: var(--f1); box-shadow: 0 0 0 2px var(--f2), 2px 3px 0 2px var(--navy); } /* Profilrahmen (INK PASS) */
.ava-wrap { position: relative; flex: none; display: flex; }
/* Level-Abzeichen: Farbe je 50 Level (--lb Hintergrund, --lf Schrift), optional kleiner XP-Balken */
.lvl-badge { display: inline-flex; flex-direction: column; align-items: center; justify-content: center; flex: none; min-width: 28px; padding: 1px 5px 2px; border-radius: 7px; border: 2px solid var(--navy); background: var(--lb, var(--paper)); color: var(--lf, var(--navy)); box-shadow: 1px 2px 0 var(--navy); font-family: var(--fh); line-height: 1; }
.lvl-badge b { font-weight: 400; font-size: 14px; letter-spacing: .5px; }
.lvl-badge i { display: block; align-self: stretch; height: 3px; margin-top: 1px; border-radius: 2px; background: rgba(0, 0, 0, .22); overflow: hidden; }
.lvl-badge u { display: block; height: 100%; width: 0; background: currentColor; }
.lvl-badge.top { position: absolute; left: 50%; bottom: -8px; transform: translateX(-50%); z-index: 1; pointer-events: none; }
.lvl-badge.big { min-width: 46px; height: 46px; border-width: 3px; border-radius: 12px; box-shadow: 2px 3px 0 var(--navy); }
.lvl-badge.big b { font-size: 24px; }
.pill { display: flex; align-items: center; height: 34px; padding: 0 4px 0 0; margin-left: 10px; background: var(--navy); color: #fff; border-radius: 9px; font-family: var(--fh); font-size: 16px; letter-spacing: .5px; min-width: 96px; }
.pill img { width: 34px; height: 34px; margin-left: -14px; filter: drop-shadow(1px 2px 0 rgba(0, 0, 0, .3)); }
.pill span { flex: 1; text-align: center; padding: 0 6px 0 2px; }
.plus { width: 24px; height: 24px; border-radius: 6px; background: var(--orange); color: var(--navy); font-family: var(--fb); font-weight: 900; font-size: 20px; line-height: 20px; border: 2px solid var(--navy); flex: none; }
.spacer { flex: 1; }
.icon-btn { width: 42px; height: 42px; flex: none; display: grid; place-items: center; }
.icon-btn img { width: 36px; height: 36px; }

.tabs { flex: 1; position: relative; min-height: 0; }
.tab { position: absolute; inset: 0; display: none; flex-direction: column; gap: 12px; padding: 4px 14px 16px; overflow-y: auto; -webkit-overflow-scrolling: touch; }
.tab.active { display: flex; }
#tab-home { overflow: hidden; }

.showcase { position: relative; flex: 1; min-height: 150px; display: flex; align-items: flex-end; justify-content: center; }
.hero-full { height: 100%; max-width: 100%; object-fit: contain; object-position: bottom; animation: float 3s ease-in-out infinite; filter: var(--skin,) drop-shadow(6px 8px 0 rgba(27, 35, 64, .22)); } /* --skin: Helden-Skin (Farbfilter) */
.hero-full.poke { animation: poke .45s ease-out, float 3s ease-in-out .45s infinite; }
.hero-tag { position: absolute; left: 0; bottom: 14px; display: flex; flex-direction: column; background: var(--navy); color: #fff; padding: 6px 14px 7px; border-radius: 6px; transform: skewX(-8deg); box-shadow: 4px 4px 0 var(--orange); }
.hero-tag b { font-family: var(--fh); font-size: 26px; letter-spacing: 1px; line-height: 1.1; font-weight: 400; }
.hero-tag span { font-size: 11px; font-weight: 700; letter-spacing: 1px; color: var(--yellow); }
.trophy-badge { position: absolute; left: 0; top: 4px; display: flex; align-items: center; gap: 4px; background: var(--paper); border: 3px solid var(--navy); border-radius: 10px; padding: 2px 10px 2px 4px; font-family: var(--fh); font-size: 18px; box-shadow: 3px 3px 0 var(--navy); z-index: 1; }
.trophy-badge img { width: 28px; height: 28px; }

.arena-card { display: flex; gap: 12px; align-items: center; background: var(--paper); border: 3px solid var(--navy); border-radius: 14px; padding: 8px; box-shadow: 4px 4px 0 var(--navy); text-align: left; flex: none; }
.arena-card .thumb { width: 44%; aspect-ratio: 16 / 10; border-radius: 8px; border: 2px solid var(--navy); object-fit: cover; background: var(--navy); }
.arena-info { flex: 1; min-width: 0; }
.arena-info h3 { font-family: var(--fh); font-weight: 400; font-size: 24px; letter-spacing: .5px; line-height: 1.1; }
.arena-info small { display: block; font-size: 11px; font-weight: 700; color: var(--navy3); margin-bottom: 6px; }
.faces { display: flex; gap: 4px; }
.faces img { width: 25%; max-width: 40px; aspect-ratio: 1; border-radius: 8px; border: 2px solid var(--navy); object-fit: cover; }

/* Spielmodus: SOLO · 2 GEGEN 2 · 6 GEGEN 6 (Controller: links/rechts, A) */
.mode-row { display: flex; gap: 6px; flex: none; }
.mode-btn { flex: 1; min-width: 0; display: flex; flex-direction: column; align-items: center; gap: 1px; padding: 5px 4px 6px; background: var(--paper); border: 3px solid var(--navy); border-radius: 12px; box-shadow: 0 4px 0 var(--navy); transition: transform .07s, box-shadow .07s; }
.mode-btn b { font-family: var(--fh); font-weight: 400; font-size: 18px; letter-spacing: .5px; line-height: 1.05; white-space: nowrap; }
.mode-btn small { font-size: 8px; font-weight: 900; letter-spacing: .5px; color: var(--navy3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.mode-btn.on { background: var(--blue); color: #fff; }
.mode-btn.on small { color: var(--yellow); }
.mode-btn:active { transform: translateY(3px); box-shadow: 0 1px 0 var(--navy); }
.btn-play { flex: none; height: 76px; border-radius: 16px; background: var(--orange); border: 4px solid var(--navy); box-shadow: 0 6px 0 var(--navy); font-family: var(--fh); font-size: 42px; letter-spacing: 2px; color: var(--navy); display: flex; align-items: center; justify-content: center; gap: 22px; transition: transform .08s, box-shadow .08s; }
.btn-play .tri { width: 0; height: 0; border-left: 20px solid var(--navy); border-top: 13px solid transparent; border-bottom: 13px solid transparent; }
.btn-play:active { transform: translateY(5px); box-shadow: 0 1px 0 var(--navy); }

.bottomnav { display: flex; border-top: 3px solid var(--navy); background: var(--cream); padding-bottom: var(--sb); flex: none; }
.bottomnav button { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 8px 0 9px; font-family: var(--fh); font-size: 13px; letter-spacing: .8px; position: relative; }
.bottomnav button + button { border-left: 2px solid rgba(27, 35, 64, .15); }
.bottomnav img { width: 30px; height: 30px; }
.bottomnav button.active::after { content: ''; position: absolute; bottom: 3px; left: 20%; right: 20%; height: 4px; border-radius: 2px; background: var(--orange); }

/* ---------- Karten (Helden / Arena / Shop) ---------- */
.sec-title { font-family: var(--fh); font-weight: 400; font-size: 30px; letter-spacing: 1px; transform: skewX(-6deg); }
.sub { font-family: var(--fh); font-weight: 400; font-size: 20px; letter-spacing: 1px; margin-top: 4px; }
.hint { font-size: 12px; font-weight: 700; color: var(--navy3); text-align: center; }
.card { display: flex; gap: 10px; align-items: center; background: var(--paper); border: 3px solid var(--navy); border-radius: 14px; box-shadow: 4px 4px 0 var(--navy); padding: 10px; flex: none; }
.card.sel { background: #ffe7d3; }
.card .info { flex: 1; min-width: 0; }
.card h3 { font-family: var(--fh); font-weight: 400; font-size: 22px; letter-spacing: .5px; line-height: 1.1; }
.card h3 small, .card .info > small { font-family: var(--fb); font-size: 11px; font-weight: 700; color: var(--navy3); letter-spacing: 0; }
.card .act { flex: none; }
.pic-wrap { position: relative; flex: none; }
.pic { width: 78px; height: 78px; border-radius: 12px; border: 3px solid var(--navy); background: var(--c, var(--blue)); object-fit: cover; display: block; }
.pic.small { width: 56px; height: 56px; }
.pic-wrap .lock { position: absolute; right: -8px; bottom: -8px; width: 32px; height: 32px; }
.ab { font-size: 11px; line-height: 1.3; margin: 3px 0 5px; display: flex; gap: 4px; align-items: flex-start; }
.ab img { width: 18px; height: 18px; flex: none; }
.ab .ab-more { display: block; margin-top: 2px; font-size: 10px; font-weight: 800; color: var(--navy3); } /* Abklingzeit · stark gegen … */
.sub small { font-family: var(--fb); font-size: 12px; font-weight: 800; color: var(--navy3); letter-spacing: 0; }
.stats { display: grid; grid-template-columns: auto 1fr; gap: 3px 8px; align-items: center; font-size: 9px; font-weight: 900; letter-spacing: .5px; }
.bar { height: 8px; border-radius: 4px; background: #e6dac2; border: 1.5px solid var(--navy); overflow: hidden; }
.bar i { display: block; height: 100%; background: var(--c, var(--blue)); }
.hero-card { flex-wrap: wrap; align-items: flex-start; }
.hero-card .act { width: 100%; }
.hero-card .act .btn { width: 100%; }
.athumb { width: 112px; aspect-ratio: 16 / 10; border-radius: 8px; border: 2px solid var(--navy); object-fit: cover; flex: none; background: var(--navy); }
.arena-row.locked .athumb { filter: grayscale(1) brightness(.75); }
.need { display: flex; align-items: center; gap: 3px; font-family: var(--fh); font-size: 18px; }
.need img { width: 24px; height: 24px; }
img.big { width: 64px; height: 64px; flex: none; } /* nur Bilder (Shop-Truhe); .ccard.big / .lvl-badge.big / .banner.big haben eigene Maße */
.price { display: inline-flex; align-items: center; gap: 4px; }
.price img { width: 20px; height: 20px; }

.btn { font-family: var(--fh); font-size: 18px; letter-spacing: 1px; padding: 8px 14px; border-radius: 10px; border: 3px solid var(--navy); background: var(--blue); color: #fff; box-shadow: 0 4px 0 var(--navy); transition: transform .07s, box-shadow .07s; white-space: nowrap; }
.btn.orange { background: var(--orange); color: var(--navy); }
.btn.ghost { background: var(--paper); color: var(--navy); }
.btn:disabled, .btn[aria-disabled="true"] { opacity: .55; box-shadow: 0 2px 0 var(--navy); }
.btn:active:not(:disabled) { transform: translateY(3px); box-shadow: 0 1px 0 var(--navy); }

/* ---------- Match ---------- */
#scr-game { background: var(--navy); }
.hud { display: flex; align-items: center; gap: 5px; padding: calc(6px + var(--st)) 6px 6px; background: var(--navy); border-bottom: 3px solid #0f1428; flex: none; z-index: 2; }
.chips { display: flex; gap: 4px; flex: 1; min-width: 0; }
.chips.r { justify-content: flex-end; }
.chip { display: flex; align-items: center; gap: 2px; background: var(--navy2); border: 2px solid var(--c); border-radius: 8px; padding: 2px 3px 2px 2px; min-width: 0; transition: opacity .3s, filter .3s; }
.chip .face { width: 28px; height: 28px; border-radius: 6px; background: var(--c); object-fit: cover; flex: none; }
.chip .hearts { display: flex; }
.chip .hearts img { width: 12px; height: 12px; }
.chip.ko { filter: grayscale(1); opacity: .45; }
.chip.shield { box-shadow: 0 0 0 2px var(--yellow); }
.timer { font-family: var(--fh); font-size: 22px; color: #fff; background: #0f1428; border: 2px solid var(--navy3); border-radius: 8px; padding: 1px 8px; letter-spacing: 1px; flex: none; }
.timer.danger { color: var(--red); animation: pulse .5s infinite alternate; }
.hud .pause { width: 34px; height: 34px; background: var(--navy3); border-radius: 8px; border: 2px solid #5a669a; }
.hud .pause img { width: 22px; height: 22px; }
.board-wrap { flex: 1; position: relative; min-height: 0; overflow: hidden; }
#board { position: absolute; left: 0; top: 0; display: block; }
/* 6 gegen 6: eigener Chip + je Held ein Strich in der Teamfarbe (grau = K.O.) */
.tdots { display: flex; align-items: center; gap: 3px; padding: 0 3px; }
.td { display: block; width: 7px; height: 20px; border-radius: 3px; background: var(--c); border: 1.5px solid #0f1428; box-shadow: inset 0 2px 0 rgba(255, 255, 255, .35); transition: background .3s, opacity .3s; }
.td.ko { background: #4a5070; opacity: .45; box-shadow: none; }
.chips.r .tdots { margin-left: auto; }
/* Map-Wertung der Clan-Maps (oben im Feld): Zonen-Punkte, Farbanteile, Tresor-HP, Starkstrom */
.objbar { position: absolute; left: 50%; top: 4px; transform: translateX(-50%); display: none; align-items: center; gap: 6px; padding: 2px 10px; background: rgba(15, 20, 40, .82); border: 2px solid var(--navy3); border-radius: 12px; color: #fff; font-family: var(--fh); font-size: 16px; letter-spacing: .5px; pointer-events: none; z-index: 1; white-space: nowrap; }
.objbar.on { display: flex; }
.objbar .t0 { color: #8fb0ff; } .objbar .t1 { color: #ffb27a; }
.objbar small { font-family: var(--fb); font-size: 10px; font-weight: 900; color: #c9cfe6; }
.objbar .zs { display: flex; gap: 3px; }
.objbar .zs i { width: 12px; height: 12px; border-radius: 3px; background: #f3ead7; border: 1.5px solid #0f1428; }
.objbar .zs i.t0 { background: var(--blue); } .objbar .zs i.t1 { background: var(--orange); }
.objbar .pb { position: relative; width: 110px; height: 10px; border-radius: 5px; background: #4a5070; overflow: hidden; border: 1.5px solid #0f1428; }
.objbar .pb i, .objbar .pb u { position: absolute; top: 0; bottom: 0; transition: width .3s; }
.objbar .pb i { left: 0; background: var(--blue); } .objbar .pb u { right: 0; background: var(--orange); }
.objbar .ln { font-size: 14px; } .objbar .ln.warn { color: var(--yellow); animation: pulse .3s infinite alternate; } .objbar .ln.on { color: #7ff3ff; }
/* Zuschauen nach dem K.O. (Team-Modi) */
.spec { position: absolute; left: 50%; top: 36px; transform: translateX(-50%); /* unter der Map-Wertung, frei von Minikarte und Joystick */ display: none; align-items: center; gap: 6px; padding: 3px 4px; background: rgba(15, 20, 40, .85); border: 2px solid var(--navy3); border-radius: 14px; color: #fff; z-index: 2; }
.spec.on { display: flex; }
/* Online-SOLO nach dem eigenen K.O.: Hinweis (zweizeilig) + MATCH VERLASSEN; Bomben-/Fähigkeitsknopf aus */
.spec.out b { white-space: normal; max-width: 210px; font-size: 13px; line-height: 1.15; text-align: center; }
.spec .sp-l { min-height: 0; padding: 5px 10px; font-size: 12px; }
.controls.out .btns { visibility: hidden; }
.spec span { display: flex; flex-direction: column; align-items: center; padding: 0 6px; min-width: 90px; }
.spec small { font-size: 9px; font-weight: 900; letter-spacing: 1px; color: var(--yellow); }
.spec b { font-family: var(--fh); font-weight: 400; font-size: 18px; letter-spacing: .5px; max-width: 150px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sp-b { width: 36px; height: 36px; border-radius: 10px; background: var(--blue); border: 2px solid #8fb0ff; color: #fff; font-size: 16px; }
.countdown, .banner { position: absolute; left: 0; right: 0; text-align: center; font-family: var(--fh); color: #fff; pointer-events: none; opacity: 0; -webkit-text-stroke: 2px var(--navy); text-shadow: 0 5px 0 var(--navy), 0 0 30px rgba(0, 0, 0, .5); }
.countdown { top: 38%; font-size: 96px; }
.countdown.show { animation: count .9s ease-out forwards; }
.banner { top: 18%; font-size: 30px; letter-spacing: 1px; color: var(--yellow); }
.banner.big { width: auto; height: auto; font-size: 46px; color: var(--orange); } /* width/height: nicht die allgemeine .big-Regel (64px) erben */
.banner.show { animation: bannerIn .3s ease-out forwards; }

.controls { height: clamp(150px, 25vh, 210px); position: relative; flex: none; touch-action: none; background: linear-gradient(#141a33, #0f1428); border-top: 3px solid #0b0f1f; padding-bottom: var(--sb); }
.joy-zone { position: absolute; left: 0; top: 0; bottom: 0; width: 55%; touch-action: none; }
.joy-base { position: absolute; left: 92px; top: 50%; width: 132px; height: 132px; margin: -66px 0 0 -66px; border-radius: 50%; background: rgba(255, 255, 255, .07); border: 3px solid rgba(255, 255, 255, .3); transition: background .15s; }
.joy-base::before { content: ''; position: absolute; inset: 14px; border-radius: 50%; border: 2px dashed rgba(255, 255, 255, .12); }
.joy-base.active { background: rgba(255, 255, 255, .13); }
.joy-knob { position: absolute; left: 50%; top: 50%; width: 60px; height: 60px; margin: -30px; border-radius: 50%; background: radial-gradient(circle at 40% 35%, #fff, #c9c7d6); border: 3px solid #fff; box-shadow: 0 5px 0 rgba(0, 0, 0, .35); }
.btns { position: absolute; right: 16px; top: 50%; transform: translateY(-50%); display: flex; align-items: center; gap: 14px; }
.btn-bomb { width: 112px; height: 112px; border-radius: 50%; background: var(--orange); border: 5px solid var(--navy); box-shadow: 0 0 0 5px var(--orange), 0 7px 0 5px #a3410f; position: relative; display: grid; place-items: center; touch-action: none; transition: transform .06s; }
.btn-bomb img { width: 70%; height: 70%; }
.btn-bomb b { position: absolute; right: -4px; top: -4px; min-width: 30px; height: 30px; border-radius: 15px; background: var(--navy); color: #fff; font-family: var(--fh); font-weight: 400; font-size: 18px; line-height: 26px; border: 2px solid var(--orange); }
.btn-ability { width: 72px; height: 72px; border-radius: 50%; background: var(--navy); border: 4px solid var(--yellow); position: relative; display: grid; place-items: center; overflow: hidden; touch-action: none; transition: transform .06s; }
.btn-ability img { width: 64%; height: 64%; }
.btn-ability .cd { position: absolute; inset: 0; border-radius: 50%; }
.btn-ability.ready { box-shadow: 0 0 14px rgba(255, 210, 31, .6); }
.btn-bomb.down, .btn-ability.down { transform: scale(.92); }
.controls.lefty .joy-zone { left: auto; right: 0; }
.controls.lefty .joy-base { left: auto; right: 26px; }
.controls.lefty .btns { right: auto; left: 16px; flex-direction: row-reverse; }

/* ---------- Modal ---------- */
.modal { position: absolute; inset: 0; z-index: 50; display: none; align-items: center; justify-content: center; padding: 18px; background: rgba(12, 16, 34, .72); }
.modal.open { display: flex; }
.panel { width: 100%; max-width: 400px; max-height: 92%; overflow-y: auto; background: var(--cream); border: 4px solid var(--navy); border-radius: 18px; box-shadow: 6px 6px 0 var(--navy); padding: 18px; display: flex; flex-direction: column; gap: 12px; animation: pop .25s ease-out; }
.panel.wide { max-width: 480px; }
.panel h2 { font-family: var(--fh); font-weight: 400; font-size: 30px; letter-spacing: 1px; text-align: center; }
.mtext { font-size: 14px; line-height: 1.4; text-align: center; }
.row { display: flex; gap: 10px; justify-content: center; }
.row .btn { flex: 1; }
.col { display: flex; flex-direction: column; gap: 10px; }
.trow { display: flex; align-items: center; justify-content: space-between; font-weight: 700; font-size: 15px; padding: 6px 2px; border-bottom: 2px dashed rgba(27, 35, 64, .15); cursor: pointer; }
.trow input { display: none; }
.trow i { width: 50px; height: 28px; border-radius: 14px; background: #c9bfa9; border: 3px solid var(--navy); position: relative; transition: background .15s; flex: none; }
.trow i::after { content: ''; position: absolute; left: 2px; top: 2px; width: 18px; height: 18px; border-radius: 50%; background: #fff; border: 2px solid var(--navy); transition: left .15s; }
.trow input:checked + i { background: var(--orange); }
.trow input:checked + i::after { left: 23px; }
.stats-line { font-size: 12px; font-weight: 700; color: var(--navy3); text-align: center; }
.lang-row { width: 100%; text-align: start; }
.lang-row b { font-family: var(--fh); font-weight: 400; font-size: 17px; letter-spacing: .5px; color: var(--blue); }
.lang-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px 8px; }
.lang-grid .btn { padding: 8px 4px; font-size: 16px; overflow: hidden; text-overflow: ellipsis; }
.asset-list { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.arow { display: flex; align-items: center; gap: 6px; background: #ffe2c4; border: 2px solid var(--navy); border-radius: 8px; padding: 3px 6px; font-size: 10px; font-weight: 700; min-width: 0; }
.arow.ok { background: #c9f2d9; }
.arow img { width: 26px; height: 26px; object-fit: contain; flex: none; background: rgba(27, 35, 64, .12); border-radius: 4px; }
.arow span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.arow b { font-size: 9px; }
.res-title { font-family: var(--fh); font-weight: 400; font-size: clamp(38px, 11.5vw, 52px); text-align: center; letter-spacing: 2px; color: var(--navy); transform: skewX(-6deg); }
.res-title.win { color: var(--orange); -webkit-text-stroke: 2px var(--navy); }
.rank-list { display: flex; flex-direction: column; gap: 6px; }
.rrow { display: flex; align-items: center; gap: 10px; background: var(--paper); border: 3px solid var(--navy); border-left: 8px solid var(--c); border-radius: 10px; padding: 4px 10px 4px 6px; }
.rrow.me { background: #ffe7d3; }
.rrow .pl { font-family: var(--fh); font-weight: 400; font-size: 24px; width: 22px; text-align: center; flex: none; }
.rrow > img { width: 38px; height: 38px; border-radius: 8px; background: var(--c); border: 2px solid var(--navy); object-fit: cover; flex: none; }
.rrow > small { font-weight: 700; font-size: 12px; flex: none; white-space: nowrap; }
/* Ergebnis der Team-Modi: Team-Banner, beide Teams nebeneinander, MVP */
.team-res { display: flex; align-items: center; justify-content: center; gap: 8px; }
.team-res > em { font-family: var(--fh); font-style: normal; font-size: 26px; }
.tr { display: flex; flex-direction: column; align-items: center; min-width: 110px; padding: 3px 12px 5px; border-radius: 12px; border: 3px solid var(--navy); color: #fff; box-shadow: 3px 3px 0 var(--navy); }
.tr.t0 { background: var(--blue); } .tr.t1 { background: var(--orange); color: var(--navy); }
.tr.won { box-shadow: 0 0 0 3px var(--yellow), 3px 3px 0 3px var(--navy); }
.tr b { font-family: var(--fh); font-weight: 400; font-size: 14px; letter-spacing: 1px; }
.tr i { font-family: var(--fh); font-style: normal; font-size: 24px; line-height: 1.05; }
.tr-why { text-align: center; font-size: 12px; font-weight: 700; color: var(--navy3); margin-top: -4px; }
.team-cols { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 8px; }
.tcol { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.tcol h3 { font-family: var(--fh); font-weight: 400; font-size: 15px; letter-spacing: 1px; text-align: center; border-radius: 6px; color: #fff; padding: 1px 0; }
.tcol.t0 h3 { background: var(--blue); } .tcol.t1 h3 { background: var(--orange); color: var(--navy); }
.trr { position: relative; display: flex; align-items: center; gap: 5px; background: var(--paper); border: 2px solid var(--navy); border-radius: 8px; padding: 2px 6px 2px 2px; min-width: 0; }
.tcol.t0 .trr { border-left: 5px solid var(--blue); } .tcol.t1 .trr { border-left: 5px solid var(--orange); }
.trr.me { background: #ffe7d3; }
.trr.out { opacity: .6; }
.trr > img { width: 28px; height: 28px; border-radius: 6px; border: 1.5px solid var(--navy); object-fit: cover; flex: none; }
.trr .tn { flex: 1; min-width: 0; font-weight: 900; font-size: 11px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.trr small { font-weight: 700; font-size: 11px; white-space: nowrap; flex: none; }
.trr .mvp { position: absolute; left: 0; bottom: -4px; font-style: normal; font-family: var(--fh); font-size: 9px; line-height: 11px; letter-spacing: .5px; background: var(--yellow); border: 1.5px solid var(--navy); border-radius: 4px; padding: 0 3px; transform: rotate(-6deg); } /* über dem Porträt */
@media (max-aspect-ratio: 13/10) { /* hochkant: 6 gegen 6 passt auf 390 × 844 ohne Scrollen (Zusatzzeilen: Knopfzeile klebt unten) */
  .panel.result.team { gap: 9px; }
  .panel.result.team .res-title { line-height: 1.15; }
}
.rewards { display: flex; justify-content: center; gap: 12px; flex-wrap: wrap; }
.rewards span { display: flex; align-items: center; gap: 4px; background: var(--navy); color: #fff; border-radius: 10px; padding: 4px 12px 4px 6px; font-family: var(--fh); font-size: 20px; }
.rewards img { width: 28px; height: 28px; }
.unlock { text-align: center; font-weight: 700; color: var(--orange); }
/* XP im Ergebnis */
.res-mid { display: flex; flex-direction: column; gap: 12px; }
.res-left { display: contents; } /* hochkant: Belohnungen, XP-Kasten, dann Level-Up */
.res-mid .xp-box { order: 1; }
.res-mid .lvlup { order: 2; }
.xp-box { display: flex; flex-direction: column; gap: 5px; background: var(--paper); border: 3px solid var(--navy); border-radius: 12px; padding: 7px 10px; }
.xp-row { display: flex; align-items: center; gap: 10px; }
.xp-main { flex: 1; min-width: 0; }
.xp-top { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.xp-top b { font-family: var(--fh); font-weight: 400; font-size: 21px; letter-spacing: .5px; color: var(--blue); }
.xp-top small { font-weight: 700; font-size: 12px; color: var(--navy3); }
.xp-bar { height: 14px; margin-top: 3px; border-radius: 7px; background: #e6dac2; border: 2px solid var(--navy); overflow: hidden; }
.xp-bar i { display: block; height: 100%; background: linear-gradient(var(--blue), #2346c4); transition: width 1.1s cubic-bezier(.2, .8, .2, 1) .35s; }
.xp-parts { font-size: 11px; font-weight: 700; color: var(--navy3); text-align: center; }
.lvlup { display: flex; align-items: center; justify-content: center; gap: 10px; flex-wrap: wrap; background: var(--navy); color: #fff; border-radius: 10px; padding: 4px 12px; font-family: var(--fh); font-size: 19px; animation: pop .35s ease-out 1.1s both; }
.lvlup b { font-weight: 400; color: var(--yellow); letter-spacing: 1px; }
.lvlup span { display: flex; align-items: center; gap: 3px; }
.lvlup img { width: 24px; height: 24px; }

/* ---------- Visitenkarte (Calling Card): Bild 4:1, Emblem links überlappend, Name, Titel, Level ---------- */
.r-common { --rc: #8a96ad; --rd: #5d6a85; }
.r-rare { --rc: #3d7bff; --rd: #1d47b8; }
.r-epic { --rc: #a35cf5; --rd: #6a2fbf; }
.r-legendary { --rc: #ffb21f; --rd: #b86400; }
.ccard { position: relative; display: block; width: 100%; aspect-ratio: 4 / 1; container-type: inline-size; flex: none; text-align: start; color: #fff; }
.cc-box { position: absolute; top: 0; bottom: 0; left: 4%; right: 0; border: 3px solid var(--navy); border-radius: 10px; overflow: hidden; background: var(--navy2); box-shadow: 3px 4px 0 var(--navy); }
.cc-art { display: block; width: 100%; height: 100%; object-fit: cover; }
.cc-emb { position: absolute; left: 0; top: -9%; height: 118%; aspect-ratio: 1; object-fit: contain; filter: drop-shadow(2px 3px 0 rgba(14, 19, 38, .6)); z-index: 2; }
.cc-txt { position: absolute; left: 32%; right: 16%; top: 50%; transform: translateY(-50%); display: flex; flex-direction: column; min-width: 0; z-index: 2; }
.cc-txt b { font-family: var(--fh); font-weight: 400; font-size: 24px; font-size: clamp(13px, 7.4cqw, 40px); letter-spacing: .5px; line-height: 1.08; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-shadow: 0 2px 0 var(--navy), 0 0 10px rgba(0, 0, 0, .55); }
.cc-txt small { font-size: 11px; font-size: clamp(9px, 3.5cqw, 18px); font-weight: 900; letter-spacing: .8px; line-height: 1.25; color: var(--yellow); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-shadow: 0 1px 0 var(--navy), 0 0 6px rgba(0, 0, 0, .6); }
.ccard .cc-lvl { position: absolute; right: 3%; top: 50%; transform: translateY(-50%); z-index: 2; }
.ccard.big .cc-lvl { min-width: 38px; padding: 3px 7px 4px; border-width: 3px; }
.ccard.big .cc-lvl b { font-size: 20px; }
/* Glanz für epische und legendäre Karten (legendär zusätzlich Funkeln) */
.ccard.r-epic .cc-box::after, .ccard.r-legendary .cc-box::after { content: ''; position: absolute; top: 0; bottom: 0; left: 0; width: 45%; z-index: 1; pointer-events: none; background: linear-gradient(100deg, transparent, rgba(255, 255, 255, .5) 50%, transparent); transform: translateX(-130%) skewX(-18deg); animation: ccShine 3.8s ease-in-out infinite; }
.ccard.r-legendary .cc-box::after { background: linear-gradient(100deg, transparent, rgba(255, 236, 160, .75) 50%, transparent); animation-duration: 2.8s; }
.ccard.r-legendary .cc-box::before { content: ''; position: absolute; inset: 0; z-index: 1; pointer-events: none; animation: ccSpark 1.4s ease-in-out infinite alternate;
  background: radial-gradient(circle at 46% 22%, #fff 0 1.5px, transparent 2.5px), radial-gradient(circle at 63% 74%, #fff 0 1.5px, transparent 2.5px), radial-gradient(circle at 81% 26%, #ffe27a 0 2px, transparent 3px), radial-gradient(circle at 93% 70%, #fff 0 1.5px, transparent 2.5px), radial-gradient(circle at 72% 50%, #ffe27a 0 1px, transparent 2px); }
@media (prefers-reduced-motion: reduce) { .ccard .cc-box::before { animation: none; } .ccard .cc-box::after { display: none; } }
.ccard.big { max-width: 560px; margin: 2px auto 4px; }
.ccard-btn { display: block; flex: none; align-self: center; width: min(100%, 40vh); padding: 6px 0 2px; }
.ccard.mini .cc-box { box-shadow: 3px 3px 0 var(--navy); }
/* Rangliste: flacher Streifen statt 4:1 */
.ccard.row { aspect-ratio: auto; height: 46px; width: auto; flex: 1; min-width: 0; }
.ccard.row .cc-box { left: 14px; border-width: 2px; border-radius: 8px; box-shadow: none; }
.ccard.row .cc-emb { top: 1px; height: 44px; }
.ccard.row .cc-txt { left: 47px; right: 36px; } /* Platz für dreistellige Level */
.ccard.row .cc-txt b { font-size: 15px; }
.ccard.row .cc-txt small { font-size: 9px; letter-spacing: .3px; }
.ccard.row .cc-lvl { right: 4px; min-width: 22px; padding: 1px 3px 2px; border-width: 1.5px; box-shadow: none; }
.ccard.row .cc-lvl b { font-size: 12px; }
.rrow .ccard.row { margin: -1px 0; }
/* Profilrahmen (INK PASS, IB.Cosmetics.frameHtml): liegt über der Kartenbox, unter Emblem und Text; Farben --f1/--f2 */
.cc-frame { position: absolute; top: -5px; bottom: -5px; left: calc(4% - 5px); right: -5px; z-index: 1; pointer-events: none; border-radius: 14px; border: 4px solid var(--f1); box-shadow: 0 0 0 2px var(--navy), inset 0 0 0 2px var(--f2); }
.cc-frame.s-dashed { border-style: dashed; border-width: 5px; box-shadow: 0 0 0 2px var(--navy), inset 0 0 0 3px var(--f2); }
.cc-frame.s-double { border-style: double; border-width: 7px; }
.cc-frame.s-glow { animation: frGlow 1.6s ease-in-out infinite alternate; }
.cc-frame.s-duo, .cc-frame.s-rainbow { border: 0; padding: 5px; box-shadow: none; background: linear-gradient(135deg, var(--f1), var(--f2) 50%, var(--f1));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0); }
.cc-frame.s-rainbow { background: linear-gradient(90deg, var(--f1), var(--f2), #fff, var(--f1), var(--f2), #fff, var(--f1)) 0 0 / 300% 100%; animation: frSlide 3s linear infinite; }
.ccard.row .cc-frame { top: -3px; bottom: -3px; left: 11px; right: -3px; border-width: 3px; border-radius: 10px; }
.ccard.row .cc-frame.s-duo, .ccard.row .cc-frame.s-rainbow { padding: 3px; }
@media (prefers-reduced-motion: reduce) { .cc-frame { animation: none !important; } }
.panel.result .rrow { gap: 6px; padding: 4px 8px 4px 5px; }
.panel.result .rrow > img { width: 32px; height: 32px; }
/* Level-Up + Aufgaben-Streifen + Freischaltungen passen nicht immer ins Fenster: dann scrollt es,
   die Knopfzeile (LOBBY/NOCHMAL) bleibt aber unten sichtbar (negative Ränder = Innenabstand des Fensters) */
.panel.result > .row { position: sticky; bottom: -18px; margin: 0 -18px -18px; padding: 8px 18px 18px; background: var(--cream); z-index: 1; }

/* ---------- Profil ---------- */
.prof-left, .prof-right { display: flex; flex-direction: column; gap: 12px; flex: none; min-width: 0; }
.prof-lvl { display: flex; align-items: center; gap: 10px; background: var(--paper); border: 3px solid var(--navy); border-radius: 12px; box-shadow: 4px 4px 0 var(--navy); padding: 7px 10px; }
.prof-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.prof-stats div { display: flex; flex-direction: column; gap: 1px; min-width: 0; background: var(--navy); color: #fff; border-radius: 10px; padding: 6px 4px 5px; text-align: center; }
.prof-stats b { font-family: var(--fh); font-weight: 400; font-size: 20px; letter-spacing: .5px; line-height: 1.1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.prof-stats small { font-size: 9px; font-weight: 900; letter-spacing: .8px; color: var(--yellow); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.prof-left > .btn { align-self: center; display: inline-flex; align-items: center; gap: 8px; }
.pk-tabs { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.pk-tabs .btn { display: flex; flex-direction: column; align-items: center; padding: 5px 2px 6px; font-size: 15px; line-height: 1.15; overflow: hidden; text-overflow: ellipsis; }
.pk-tabs .btn small { font-family: var(--fb); font-size: 10px; font-weight: 900; letter-spacing: 0; opacity: .85; }
.pk-info { display: flex; flex-direction: column; gap: 3px; min-height: 54px; background: var(--paper); border: 3px solid var(--navy); border-left: 8px solid var(--rc); border-radius: 10px; padding: 6px 10px 7px; }
.pk-head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.pk-head b { font-family: var(--fh); font-weight: 400; font-size: 19px; letter-spacing: .5px; line-height: 1.1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pk-head span { flex: none; font-size: 10px; font-weight: 900; letter-spacing: .8px; color: var(--rd); }
.pk-info small { font-size: 12px; font-weight: 700; line-height: 1.3; color: var(--navy3); }
.pk-info .bar i { background: var(--blue); }
.pk-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(74px, 1fr)); gap: 8px; }
.pk-grid.k-cards, .pk-grid.k-titles { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
.pk-item { position: relative; display: flex; flex-direction: column; align-items: center; gap: 3px; min-width: 0; padding: 6px 5px 8px; background: var(--paper); border: 3px solid var(--navy); border-radius: 10px; box-shadow: inset 0 -4px 0 var(--rc); text-align: center; }
.pk-item.sel { background: #ffe7d3; box-shadow: inset 0 -4px 0 var(--rc), 0 0 0 3px var(--orange); }
.pk-item b { max-width: 100%; font-family: var(--fh); font-weight: 400; font-size: 13px; letter-spacing: .3px; line-height: 1.15; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pk-item small { max-width: 100%; overflow-wrap: anywhere; font-size: 9px; font-weight: 700; line-height: 1.25; color: var(--navy3); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.pk-pic { width: 100%; max-width: 72px; aspect-ratio: 1; object-fit: contain; }
.pk-art { display: block; width: 100%; aspect-ratio: 4 / 1; border: 2px solid var(--navy); border-radius: 6px; overflow: hidden; background: var(--navy2); }
.pk-art img { display: block; width: 100%; height: 100%; object-fit: cover; }
.pk-item.locked { background: #e6ddca; }
.pk-item.locked .pk-pic, .pk-item.locked .pk-art img { filter: grayscale(1) brightness(.8); opacity: .7; }
.pk-item.locked b { color: var(--navy3); }
.pk-item.locked::after { content: ''; position: absolute; right: 3px; top: 3px; width: 22px; height: 22px; background: var(--lock) center / contain no-repeat; }
.k-titles .pk-item { justify-content: center; min-height: 56px; }
.k-titles .pk-item b { font-size: 16px; white-space: normal; }

/* ---------- Wochenaufgaben ---------- */
/* Knopf auf der Startseite (rechts oben im Helden-Bereich) mit Zahl der abholbaren Belohnungen */
.quest-btn { position: absolute; right: 0; top: 4px; z-index: 1; display: flex; flex-direction: column; align-items: center; background: var(--paper); border: 3px solid var(--navy); border-radius: 12px; padding: 3px 8px 4px; box-shadow: 3px 3px 0 var(--navy); font-family: var(--fh); font-size: 13px; letter-spacing: .8px; line-height: 1.1; transition: transform .07s, box-shadow .07s; }
.quest-btn img { width: 34px; height: 34px; }
.quest-btn:active { transform: translateY(2px); box-shadow: 1px 1px 0 var(--navy); }
.qbadge { position: absolute; right: -9px; top: -9px; display: none; min-width: 24px; height: 24px; padding: 0 5px; border-radius: 12px; background: var(--red); color: #fff; border: 2px solid var(--navy); font-family: var(--fh); font-style: normal; font-size: 14px; line-height: 20px; text-align: center; }
.qbadge.on { display: block; animation: pulse .6s ease-in-out infinite alternate; }
/* Stufen-Farben (Chip und Rand der Zeile) */
.t-easy { --tc: #3fbf6a; --tf: #fff; }
.t-medium { --tc: #2f5bea; --tf: #fff; }
.t-hard { --tc: #f26a21; --tf: #1b2340; }
.t-extreme { --tc: #e8344e; --tf: #fff; }
.t-bonus { --tc: #ffd21f; --tf: #1b2340; }
.t-week { --tc: #1b2340; --tf: #ffd21f; }
.q-chip { display: inline-block; flex: none; padding: 1px 7px; border-radius: 6px; border: 2px solid var(--navy); background: var(--tc); color: var(--tf); font-family: var(--fh); font-size: 12px; letter-spacing: .8px; line-height: 1.3; }
.q-left, .q-right { display: flex; flex-direction: column; gap: 10px; flex: none; min-width: 0; }
.q-head { display: flex; align-items: center; justify-content: space-between; gap: 6px 10px; flex-wrap: wrap; }
.q-timer { font-size: 11px; font-weight: 900; letter-spacing: .5px; color: #fff; background: var(--navy); border-radius: 8px; padding: 4px 9px; box-shadow: 2px 2px 0 var(--orange); }
.q-bonus .q-emb { width: 58px; height: 58px; object-fit: contain; flex: none; filter: drop-shadow(2px 3px 0 rgba(27, 35, 64, .3)); }
.q-bonus .bar { margin: 4px 0 3px; }
.q-bonus .bar i { background: var(--orange); }
.q-bonus.ready { background: #fff1c9; animation: glow 1.6s ease-in-out infinite; }
.q-bonus.got { background: #e3f6e9; }
.q-count { font-family: var(--fh); font-weight: 400; font-size: 20px; letter-spacing: .5px; }
.q-days { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 5px; }
.q-day { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px; min-width: 0; min-height: 46px; padding: 4px 0; background: var(--paper); border: 3px solid var(--navy); border-radius: 10px; box-shadow: 0 3px 0 var(--navy); }
.q-day b { font-family: var(--fh); font-weight: 400; font-size: 16px; letter-spacing: .5px; line-height: 1.1; }
.q-day small { font-size: 10px; font-weight: 900; color: var(--navy3); }
.q-day img { width: 15px; height: 15px; }
.q-day.full { background: #c9f2d9; }
.q-day.locked { background: #e6ddca; }
.q-day.locked b { color: var(--navy3); }
.q-day.sel { background: var(--orange); box-shadow: 0 3px 0 var(--navy), inset 0 0 0 2px var(--paper); }
.q-day.sel small, .q-day.sel b { color: var(--navy); }
.q-dot { position: absolute; right: -6px; top: -6px; width: 14px; height: 14px; border-radius: 50%; background: var(--red); border: 2px solid var(--navy); }
.q-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: 10px; row-gap: 4px; align-items: center; padding: 6px 8px 7px 9px; border-left: 8px solid var(--tc); box-shadow: 3px 3px 0 var(--navy); }
.q-row > * { grid-column: 1; min-width: 0; }
.q-row > .act { grid-column: 2; grid-row: 1 / span 4; }
.q-top { display: flex; align-items: center; gap: 4px 8px; flex-wrap: wrap; }
.q-rw { display: inline-flex; align-items: center; gap: 2px 7px; flex-wrap: wrap; font-family: var(--fh); font-size: 14px; letter-spacing: .3px; }
.q-rw span { display: inline-flex; align-items: center; gap: 2px; white-space: nowrap; }
.q-rw img { width: 18px; height: 18px; }
.q-rw .xp { color: var(--blue); }
.q-rw .pass { color: #8f3fe0; }
.q-rw .emb { font-family: var(--fb); font-size: 11px; font-weight: 900; color: var(--navy3); white-space: normal; }
.q-txt { font-size: 13px; font-weight: 700; line-height: 1.25; }
.q-note { font-size: 10px; font-weight: 700; line-height: 1.2; color: var(--navy3); }
.q-row .bar i { background: var(--tc); }
.q-btn { min-width: 82px; padding: 7px 8px; font-size: 16px; }
.q-row.done:not(.got) { background: #fff1c9; }
.q-row.got { background: #e6ddca; }
.q-row.got .q-txt, .q-row.got .q-rw { opacity: .6; }
.q-btn.got { color: #2a9a52; }
.q-closed { display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; background: var(--paper); border: 3px dashed var(--navy3); border-radius: 14px; padding: 16px 12px; }
.q-closed > img { width: 40px; height: 40px; }
.q-closed b { font-family: var(--fh); font-weight: 400; font-size: 20px; letter-spacing: .5px; }
.q-closed small { font-size: 12px; font-weight: 700; color: var(--navy3); }
.q-tiers { display: flex; gap: 6px; flex-wrap: wrap; justify-content: center; }
/* Ergebnis: Stufen der in diesem Match erledigten Aufgaben (hochkant unten, quer unter den Belohnungen).
   width 0 + min-width 100 %: der Streifen macht die Spalte nicht breiter, er bricht in ihr um */
.q-strip { order: 3; display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 3px 8px; width: 0; min-width: 100%; background: var(--paper); border: 3px solid var(--navy); border-radius: 12px; padding: 2px 8px 3px; animation: pop .35s ease-out .8s both; }
.q-strip > b { font-family: var(--fh); font-weight: 400; font-size: 15px; letter-spacing: .8px; color: var(--orange); }
.q-list { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 3px 6px; min-width: 0; }
.q-ico { width: 22px; height: 22px; flex: none; }
.q-more { font-family: var(--fh); font-size: 15px; }

/* ---------- Stil (Profil → STIL): Unterreiter, Heldenwahl, Vorschauen ---------- */
.cos-subs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
.cos-subs .btn { padding: 5px 2px; font-size: 14px; overflow: hidden; text-overflow: ellipsis; }
.cos-heroes { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.cos-hero { position: relative; display: flex; flex-direction: column; align-items: center; gap: 1px; min-width: 0; padding: 4px 2px 3px; border: 3px solid var(--navy); border-radius: 10px; background: var(--paper); box-shadow: 0 3px 0 var(--navy); }
.cos-hero > img:first-child { width: 38px; height: 38px; border-radius: 8px; border: 2px solid var(--navy); background: var(--c); object-fit: cover; }
.cos-hero b { font-family: var(--fh); font-weight: 400; font-size: 12px; letter-spacing: .5px; line-height: 1.1; }
.cos-hero.sel { background: var(--orange); }
.cos-hero .lk { position: absolute; right: -6px; top: -6px; width: 20px; height: 20px; }
.pk-grid.k-style { grid-template-columns: repeat(auto-fill, minmax(84px, 1fr)); }
.cos-pic { display: block; width: 100%; max-width: 64px; aspect-ratio: 1; }
.pk-item.locked .cos-pic { filter: grayscale(.85) brightness(.85); opacity: .75; }
.cos-skin { border-radius: 10px; border: 2px solid var(--navy); background: var(--c); overflow: hidden; }
.cos-skin img { display: block; width: 100%; height: 100%; object-fit: cover; }
.cos-fr { display: flex; align-items: center; justify-content: center; }
.cos-card { position: relative; display: block; width: 82%; aspect-ratio: 4 / 1; }
.cos-card img { display: block; width: 100%; height: 100%; object-fit: cover; border: 2px solid var(--navy); border-radius: 4px; background: var(--navy2); }
.cos-card .cc-frame { top: -4px; bottom: -4px; left: -4px; right: -4px; border-width: 3px; border-radius: 7px; box-shadow: 0 0 0 1.5px var(--navy), inset 0 0 0 1.5px var(--f2); }
.cos-card .cc-frame.s-duo, .cos-card .cc-frame.s-rainbow { padding: 3px; box-shadow: none; }
.cos-card .cc-frame.s-double { border-width: 5px; }
.cos-none { display: grid; place-items: center; font-family: var(--fh); font-size: 30px; color: var(--navy3); }

/* ---------- INK PASS ---------- */
.pass-btn { top: 76px; }
.quest-btn { min-width: 76px; } /* AUFGABEN und PASS gleich breit */
/* hochkant: alles untereinander (Kopf, Leiste, Infozeile); quer zwei Spalten (siehe Querformat) */
.pass-left, .pass-right { display: contents; }
#tab-pass .q-head { order: 0; } .pass-head { order: 1; } .pass-track { order: 2; } .pass-info { order: 3; } #tab-pass .hint { order: 4; }
.pass-head { flex-direction: column; align-items: stretch; gap: 8px; padding: 8px 10px 10px; background: linear-gradient(135deg, var(--s1), var(--s2)); }
.ps-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.ps-name { display: flex; flex-direction: column; min-width: 0; color: #fff; text-shadow: 0 2px 0 var(--navy); }
.ps-name small { font-size: 11px; font-weight: 900; letter-spacing: 1px; }
.ps-name b { font-family: var(--fh); font-weight: 400; font-size: 25px; letter-spacing: 1px; line-height: 1.05; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ps-prem { flex: none; padding: 2px 8px; border: 2px solid var(--navy); border-radius: 8px; background: var(--yellow); box-shadow: 2px 2px 0 var(--navy); font-family: var(--fh); font-size: 13px; letter-spacing: .8px; }
.ps-tier { display: flex; align-items: center; gap: 10px; padding: 6px 10px; border: 3px solid var(--navy); border-radius: 12px; background: var(--paper); }
.ps-badge { flex: none; display: flex; flex-direction: column; align-items: center; justify-content: center; min-width: 54px; height: 54px; border: 3px solid var(--navy); border-radius: 12px; background: var(--navy); color: var(--yellow); box-shadow: 2px 3px 0 var(--orange); font-family: var(--fh); line-height: 1; }
.ps-badge small { font-size: 10px; letter-spacing: 1px; color: #fff; }
.ps-badge b { font-weight: 400; font-size: 27px; }
.ps-tier .xp-top b { font-size: 17px; }
.ps-tier .xp-top b.pre { font-family: var(--fb); font-size: 12px; font-weight: 700; line-height: 1.3; letter-spacing: 0; color: var(--navy3); }
.ps-tier .xp-bar i { background: linear-gradient(90deg, var(--s1), var(--s2)); }
.ps-btns { display: flex; flex-wrap: wrap; gap: 8px; }
.ps-btns .btn { flex: 1 1 auto; display: inline-flex; align-items: center; justify-content: center; gap: 6px; }
.ps-n { font-style: normal; min-width: 22px; padding: 0 5px; border: 2px solid var(--navy); border-radius: 10px; background: var(--red); color: #fff; font-size: 14px; line-height: 18px; }
.pass-info { --rc: var(--orange); gap: 4px; flex: none; }
#tab-pass .hint { flex: none; }
.pi-row { display: flex; align-items: flex-start; gap: 8px; }
.pi-tag { flex: none; min-width: 70px; white-space: nowrap; padding: 0 4px; border: 2px solid var(--navy); border-radius: 6px; background: var(--paper); font-family: var(--fh); font-size: 12px; letter-spacing: .8px; text-align: center; }
.pi-row.p .pi-tag { background: linear-gradient(135deg, var(--yellow), var(--orange)); }
.pi-txt { display: flex; flex-direction: column; min-width: 0; }
.pi-txt b { font-size: 13px; font-weight: 700; line-height: 1.25; }
.pi-row.claim small { color: var(--orange); }
.pi-row.got b { opacity: .55; }
/* Leiste: waagerecht scrollbar, Beschriftung links klebt; immer links → rechts (auch Arabisch) */
.pass-track { position: relative; display: flex; gap: 6px; flex: none; overflow-x: auto; overflow-y: hidden; padding: 2px 12px 10px 0; direction: ltr; scroll-padding: 0 12px 0 80px; overscroll-behavior-x: contain; -webkit-overflow-scrolling: touch; scrollbar-width: thin; }
.pt-labels { position: sticky; left: 0; z-index: 3; flex: none; display: flex; flex-direction: column; gap: 6px; padding: 26px 6px 0 2px; background: var(--cream); }
.pt-labels span { width: 64px; height: 84px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; border: 3px solid var(--navy); border-radius: 10px; background: var(--paper); box-shadow: 0 3px 0 var(--navy); font-family: var(--fh); font-size: 13px; letter-spacing: .8px; }
.pt-labels .p { background: linear-gradient(160deg, var(--yellow), var(--orange)); }
.pt-labels img { width: 22px; height: 22px; }
.pt-labels img[hidden] { display: none; }
.pt-col { flex: none; width: 76px; display: flex; flex-direction: column; gap: 6px; }
.pt-num { height: 20px; display: grid; place-items: center; border: 2px solid var(--navy); border-radius: 6px; background: #e6dac2; color: var(--navy3); font-family: var(--fh); font-weight: 400; font-size: 13px; letter-spacing: .5px; }
.pt-col.reached .pt-num { background: var(--blue); color: #fff; }
.pt-col.cur .pt-num { background: var(--orange); color: var(--navy); }
.pt-col.bonus .pt-num { background: var(--navy); color: var(--yellow); }
.pt-cell { position: relative; height: 84px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; padding: 4px 3px; border: 3px solid var(--navy); border-radius: 10px; background: var(--paper); box-shadow: 0 3px 0 var(--navy); overflow: hidden; }
.pt-cell.p { background: #fff1c9; }
.pt-cell.empty { visibility: hidden; }
.pt-cell.future > *, .pt-cell.locked > * { opacity: .55; }
.pt-cell.claim { border-color: var(--orange); background: #ffe7d3; animation: ptGlow 1.4s ease-in-out infinite; }
.pt-cell.got > * { opacity: .35; }
.pt-cell.got::after { content: '✔'; position: absolute; inset: 0; display: grid; place-items: center; font-size: 34px; font-weight: 900; color: #2a9a52; text-shadow: 0 2px 0 var(--paper); }
.pt-cell.lock::before { content: ''; position: absolute; right: 2px; top: 2px; z-index: 2; width: 20px; height: 20px; background: var(--lock) center / contain no-repeat; }
.pt-cell > b { font-family: var(--fh); font-weight: 400; font-size: 16px; letter-spacing: .3px; line-height: 1; }
.pt-cell small { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 9px; font-weight: 900; letter-spacing: .3px; line-height: 1.1; color: var(--navy3); }
.pt-ico { width: 34px; height: 34px; }
.pt-emb { width: 50px; height: 50px; object-fit: contain; }
.pt-card { display: block; width: 66px; aspect-ratio: 4 / 1; margin: 10px 0 6px; border: 2px solid var(--navy); border-radius: 4px; overflow: hidden; background: var(--navy2); }
.pt-card img { display: block; width: 100%; height: 100%; object-fit: cover; }
.pt-title { max-width: 100%; padding: 2px 4px; border: 2px solid var(--navy); border-radius: 5px; background: var(--yellow); font-family: var(--fh); font-size: 12px; letter-spacing: .3px; line-height: 1.1; text-align: center; word-break: break-word; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.pt-coupon { padding: 2px 6px; border: 2px dashed var(--paper); border-radius: 6px; outline: 2px solid var(--navy); background: #8f3fe0; color: #fff; font-family: var(--fh); font-size: 18px; white-space: nowrap; }
.pt-cos { display: block; width: 52px; height: 52px; }
.pt-more { position: absolute; left: 3px; top: 2px; z-index: 2; padding: 0 4px; border-radius: 6px; background: var(--navy); color: #fff; font-style: normal; font-family: var(--fh); font-size: 12px; line-height: 16px; }
/* Ergebnis: Pass-XP des Matches */
.rewards .pass-rw { background: #8f3fe0; }
.pass-rw b { margin-left: 4px; font-weight: 400; font-size: 16px; color: var(--yellow); }

/* ---------- Shop: Reiter, Tagesangebote, Legenden, Pakete, Kauf-Fenster, Login-Kalender ---------- */
.shop-tabs .btn { position: relative; }
.shop-tabs .btn small { display: inline-flex; align-items: center; gap: 2px; min-height: 14px; }
.shop-tabs .btn small img { width: 14px; height: 14px; }
.shop-tabs .q-dot { right: 3px; top: 3px; width: 11px; height: 11px; }
.bottomnav .qbadge { right: calc(50% - 34px); top: 2px; min-width: 20px; height: 20px; padding: 0 4px; font-size: 12px; line-height: 16px; }
.shop-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px 8px; padding-top: 6px; flex: none; }
.card.tile { position: relative; flex-direction: column; align-items: stretch; gap: 4px; min-width: 0; padding: 8px 6px; text-align: center; }
.tile > small, .of-txt small { font-size: 9px; font-weight: 900; letter-spacing: .4px; line-height: 1.2; color: var(--navy3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tile .btn { width: 100%; display: inline-flex; align-items: center; justify-content: center; gap: 4px; padding: 6px 3px; font-size: 15px; margin-top: auto; }
.tile .btn.soon { font-size: 12px; line-height: 1.15; white-space: normal; }
.tile .btn s, .leg-price s, .buy-price s { font-family: var(--fh); font-size: .8em; opacity: .55; text-decoration-thickness: 2px; }
/* Tagesangebote: Seltenheit als Streifen unten, TAGES-DEAL hochkant über die ganze Breite */
.offer { box-shadow: 4px 4px 0 var(--navy), inset 0 -5px 0 var(--rc); padding-bottom: 11px; }
.of-pic { display: flex; align-items: center; justify-content: center; height: 70px; }
.of-emb { width: 66px; height: 66px; object-fit: contain; filter: drop-shadow(2px 3px 0 rgba(27, 35, 64, .3)); }
.of-cos { display: block; width: 62px; height: 62px; }
.of-cos.cos-fr { width: 100%; height: auto; }
.of-title { max-width: 100%; padding: 4px 7px; border: 2px solid var(--navy); border-radius: 7px; background: var(--navy); color: var(--yellow); font-family: var(--fh); font-size: 14px; letter-spacing: .5px; line-height: 1.15; transform: skewX(-6deg); box-shadow: 2px 2px 0 var(--orange); word-break: break-word; }
.of-txt { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.of-txt b { font-family: var(--fh); font-weight: 400; font-size: 15px; letter-spacing: .3px; line-height: 1.15; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.of-txt small { color: var(--rd); white-space: normal; } /* Art · Seltenheit darf umbrechen ("Helden-Skin · EPISCH" ist hochkant zu breit) */
.offer.deal { grid-column: 1 / -1; display: grid; grid-template-columns: 86px minmax(0, 1fr) auto; align-items: center; column-gap: 10px; background: #fff1c9; text-align: left; padding: 12px 10px 13px; }
.offer.deal .of-txt b { font-size: 20px; }
.offer.deal .of-txt small { font-size: 10px; }
.offer.deal .btn { width: auto; min-width: 104px; margin: 0; font-size: 17px; padding: 8px 10px; }
.offer.own { background: #e6ddca; }
.offer.own .of-pic { opacity: .55; }
.of-deal { position: absolute; left: -5px; top: -11px; z-index: 1; padding: 1px 8px; border: 2px solid var(--navy); border-radius: 7px; background: var(--red); color: #fff; font-family: var(--fh); font-size: 12px; letter-spacing: .8px; transform: rotate(-3deg); box-shadow: 2px 2px 0 var(--navy); white-space: nowrap; }
.login-card.ready { background: #fff1c9; animation: glow 1.6s ease-in-out infinite; }
.lg-dots { display: flex; gap: 4px; margin-top: 5px; }
.lg-dots i { flex: 1; max-width: 22px; height: 9px; border: 2px solid var(--navy); border-radius: 5px; background: var(--paper); }
.lg-dots i.got { background: #3fbf6a; }
.lg-dots i.today { background: var(--orange); animation: pulse .6s ease-in-out infinite alternate; }
/* Legenden: Klassenfarbe als Rand, Platzhalter-Porträt (Grafik ersetzt es), Preis + Knopf in einer Zeile */
.leg-head { display: flex; align-items: center; gap: 8px; }
.leg-head::before { content: ''; width: 16px; height: 16px; flex: none; border: 3px solid var(--navy); border-radius: 50%; background: var(--cc); }
.leg-card { border-left: 8px solid var(--cc); }
.leg-pic { background: var(--cc); }
.leg-cls { display: inline-block; margin-left: 4px; padding: 0 6px; border: 2px solid var(--navy); border-radius: 6px; background: var(--cc); color: #fff; font-size: 12px; letter-spacing: .8px; line-height: 1.35; vertical-align: 3px; text-shadow: 0 1px 0 rgba(0, 0, 0, .35); }
.hero-card .leg-act { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.hero-card .leg-act .btn { width: auto; flex: 0 1 auto; min-width: 46%; }
.leg-price { display: inline-flex; align-items: center; gap: 5px; font-family: var(--fh); font-size: 20px; letter-spacing: .3px; }
.leg-price .price img { width: 22px; height: 22px; }
.shop-soon, .shop-coupon { flex: none; padding: 7px 10px; border: 3px dashed var(--navy3); border-radius: 12px; background: var(--paper); font-size: 12px; font-weight: 900; line-height: 1.3; text-align: center; }
.shop-coupon { border-style: solid; border-color: #8f3fe0; background: #f1e6ff; color: #5f2aa8; }
/* Pakete: Haufen-Bild, Menge, Name, Preis; BELIEBT / BESTER WERT als Schild oben */
.pa-art { align-self: center; width: 64px; height: 64px; object-fit: contain; }
.pa-n { display: inline-flex; align-items: center; justify-content: center; gap: 3px; font-family: var(--fh); font-weight: 400; font-size: 19px; letter-spacing: .3px; line-height: 1.1; }
.pa-n img { width: 18px; height: 18px; }
.pa-price { font-family: var(--fh); font-size: 15px; letter-spacing: .3px; }
.pack.b-hot, .pack.b-best { background: #fff1c9; }
.pa-badge { position: absolute; left: 50%; top: -12px; z-index: 1; transform: translateX(-50%) rotate(-3deg); padding: 1px 7px; border: 2px solid var(--navy); border-radius: 7px; background: var(--yellow); font-family: var(--fh); font-size: 11px; letter-spacing: .6px; white-space: nowrap; box-shadow: 2px 2px 0 var(--navy); }
.b-best .pa-badge { background: var(--red); color: #fff; }
/* Kauf bestätigen */
.buy-box { display: flex; align-items: center; gap: 12px; padding: 8px 10px; background: var(--paper); border: 3px solid var(--navy); border-left: 8px solid var(--rc); border-radius: 12px; }
.buy-pic { flex: none; width: 72px; height: 72px; display: flex; align-items: center; justify-content: center; }
.buy-pic > img, .buy-pic .of-emb, .buy-pic .of-cos:not(.cos-fr) { width: 72px; height: 72px; object-fit: contain; }
.buy-pic .buy-face { border: 3px solid var(--navy); border-radius: 12px; object-fit: cover; }
.buy-pic .of-cos.cos-fr { width: 100%; }
.buy-txt { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.buy-txt b { font-family: var(--fh); font-weight: 400; font-size: 22px; letter-spacing: .5px; line-height: 1.1; overflow-wrap: anywhere; }
.buy-txt small { font-size: 11px; font-weight: 900; line-height: 1.25; color: var(--rd); }
.buy-price { display: flex; align-items: center; justify-content: center; gap: 8px; font-family: var(--fh); font-size: 28px; letter-spacing: .5px; }
.buy-price .price img { width: 28px; height: 28px; }
/* Login-Kalender: 4 + 3 Felder (Tag 7 doppelt breit), quer alle in einer Reihe */
.lg-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 7px; }
.lg-day { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; min-width: 0; padding: 6px 1px 7px; background: var(--paper); border: 3px solid var(--navy); border-radius: 10px; box-shadow: 0 3px 0 var(--navy); }
.lg-day > b { font-family: var(--fh); font-weight: 400; font-size: 14px; letter-spacing: 0; line-height: 1.1; text-align: center; }
.lg-rw { display: flex; flex-direction: column; align-items: center; gap: 1px; font-family: var(--fh); font-size: 14px; letter-spacing: .3px; }
.lg-rw span { display: inline-flex; align-items: center; gap: 2px; white-space: nowrap; }
.lg-rw img { width: 16px; height: 16px; }
.lg-day.top { grid-column: span 2; background: #fff1c9; }
.lg-day.top .lg-rw { flex-direction: row; gap: 10px; font-size: 18px; }
.lg-day.top .lg-rw img { width: 22px; height: 22px; }
.lg-day.today { background: var(--orange); animation: glow 1.6s ease-in-out infinite; }
.lg-day.got { background: #c9f2d9; }
.lg-day.got > b, .lg-day.got .lg-rw { opacity: .45; }
.lg-ok { position: absolute; inset: 0; display: grid; place-items: center; font-style: normal; font-size: 30px; font-weight: 900; color: #2a9a52; text-shadow: 0 2px 0 var(--paper); }
.lg-day.pop { animation: pop .45s ease-out; }

/* Name (erster Start / Umbenennen) */
.name-row { display: flex; gap: 8px; align-items: stretch; }
.name-in { flex: 1; min-width: 0; font-family: var(--fh); font-size: 20px; letter-spacing: .5px; color: var(--navy); background: var(--paper); border: 3px solid var(--navy); border-radius: 10px; padding: 6px 10px; outline: none; box-shadow: inset 0 3px 0 rgba(27, 35, 64, .12); -webkit-user-select: text; user-select: text; }
.name-in:focus { border-color: var(--blue); }
.name-in::placeholder { color: #9a9282; }
.name-err { min-height: 17px; font-size: 13px; font-weight: 700; color: #d62839; text-align: center; }

.toast { position: absolute; left: 50%; bottom: 110px; transform: translate(-50%, 20px); background: var(--navy); color: #fff; padding: 10px 18px; border-radius: 12px; font-weight: 700; font-size: 14px; opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s; z-index: 60; max-width: 90%; text-align: center; box-shadow: 3px 3px 0 var(--orange); }
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* Controller/Tastatur: Joystick ausblenden (Zone bleibt antippbar, damit der erste Touch zählt; Bomben-/Fähigkeitsknopf
   bleiben als Anzeige für Bombenzahl und Abklingzeit), Auswahlrahmen in Menüs zeigen */
#app[data-input="keys"] .joy-base, #app[data-input="pad"] .joy-base { visibility: hidden; }
#app[data-input="pad"] .pad-focus { outline: 4px solid var(--blue); outline-offset: 3px; animation: padRing .7s ease-in-out infinite alternate; }
#app[data-input="pad"] .bottomnav .pad-focus { outline-offset: -6px; }
@media (max-height: 680px) {
  .btn-play { height: 64px; font-size: 36px; }
  .btn-bomb { width: 96px; height: 96px; }
  .btn-ability { width: 62px; height: 62px; }
  .joy-base { width: 116px; height: 116px; margin: -58px 0 0 -58px; left: 80px; }
  .controls.lefty .joy-base { right: 22px; }
}
/* Schmale Handys: Herzen unter das Porträt, damit 4 Chips + Timer + Pause in eine Zeile passen */
@media (max-width: 440px) {
  .chip { flex-direction: column; gap: 1px; padding: 2px; }
  .chip .face { width: 26px; height: 26px; }
  .chip .hearts img { width: 10px; height: 10px; }
}

/* ---------- Maps: Lobby-Karte, ARENA-Reiter (Bot-Stufe + Maps), Map-Steckbrief ---------- */
.arena-card .thumbs { position: relative; width: 44%; aspect-ratio: 16 / 10; flex: none; }
.arena-card .thumbs img { position: absolute; inset: 0; width: 100%; height: 100%; border-radius: 8px; border: 2px solid var(--navy); object-fit: cover; background: var(--navy); box-shadow: 2px 2px 0 rgba(27, 35, 64, .35); }
.arena-card .thumbs .t0 { transform: translate(-7%, -3%) rotate(-7deg) scale(.84); filter: brightness(.78); }
.arena-card .thumbs .t1 { transform: translate(7%, -4%) rotate(6deg) scale(.88); filter: brightness(.9); }
.arena-card .thumbs .t2 { transform: translateY(5%); }
.diff-row .dicon { width: 60px; height: 60px; flex: none; }
.diff-row.locked .dicon { filter: grayscale(1) brightness(.8); }
.diff-row .info small, .map-row .info small { display: block; }
.diff-row .mul { color: var(--orange); font-weight: 900; margin-top: 1px; }
.map-row { width: 100%; text-align: left; align-items: flex-start; }
.map-row .mn { display: block; font-family: var(--fh); font-weight: 400; font-size: 22px; letter-spacing: .5px; line-height: 1.1; }
.map-row .info .mech { color: var(--orange); font-weight: 900; letter-spacing: .5px; }
.map-row .info .md { color: var(--navy); font-weight: 500; line-height: 1.3; margin: 2px 0; }
.mi-top { display: flex; gap: 10px; align-items: center; justify-content: center; }
.mi-thumb { width: 58%; aspect-ratio: 16 / 10; object-fit: cover; border-radius: 10px; border: 3px solid var(--navy); background: var(--navy); }
.mi-map { width: 34%; max-width: 156px; height: auto; border: 3px solid var(--navy); border-radius: 6px; background: var(--navy); }
.mi-tip { font-size: 12px; line-height: 1.4; text-align: center; font-weight: 500; }
.mi-legend { display: flex; flex-wrap: wrap; justify-content: center; gap: 5px 12px; font-size: 11px; font-weight: 700; }
.mi-k { display: flex; align-items: center; gap: 4px; }
.mi-k i { width: 14px; height: 14px; border-radius: 3px; border: 1.5px solid var(--navy); }
.arow .sw { width: 26px; height: 26px; border-radius: 4px; flex: none; opacity: .55; }
.arow.opt { background: #efe6d3; }
.arow.opt.ok { background: #c9f2d9; }

/* ---------- Map-Abstimmung (js/vote.js) ---------- */
.vote-top { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; }
.panel .vote-top h2 { flex: 1; text-align: left; font-size: 26px; transform: skewX(-6deg); }
.vote-who { order: 3; flex-basis: 100%; display: flex; justify-content: center; gap: 10px; }
.vw { position: relative; display: flex; flex-direction: column; align-items: center; gap: 1px; opacity: .5; transition: opacity .2s; }
.vw.done { opacity: 1; }
.vw small { font-size: 8px; font-weight: 900; letter-spacing: .5px; max-width: 46px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.vw.done::after { content: '✔'; position: absolute; right: -5px; top: -5px; width: 16px; height: 16px; border-radius: 50%; background: #3fbf6a; color: #fff; font-size: 9px; line-height: 14px; text-align: center; border: 1.5px solid var(--navy); }
.vf { width: 30px; height: 30px; border-radius: 8px; border: 2px solid var(--navy); object-fit: cover; flex: none; }
.vf.me { border-color: var(--orange); box-shadow: 0 0 0 2px var(--orange); }
.vf.in { animation: vin .3s ease-out; }
@keyframes vin { from { transform: translateY(-16px) scale(1.5); opacity: 0; } }
.vote-time { position: relative; width: 62px; height: 34px; border-radius: 17px; background: var(--navy); border: 3px solid var(--navy); overflow: hidden; display: grid; place-items: center; flex: none; }
.vote-time i { position: absolute; inset: 0; background: var(--orange); transform-origin: left; transition: transform .1s linear; } /* Breite = Restzeit (vote.js) */
.vote-time b { position: relative; font-family: var(--fh); font-weight: 400; font-size: 20px; color: #fff; text-shadow: 1px 1px 0 var(--navy), -1px -1px 0 var(--navy), 1px -1px 0 var(--navy), -1px 1px 0 var(--navy); }
.panel.vote.done .vote-time i { opacity: .25; }
.vote-head { text-align: center; min-height: 20px; line-height: 1.2; }
.vote-head small { font-size: 12px; font-weight: 700; color: var(--navy3); }
.vote-head b { display: block; font-family: var(--fh); font-weight: 400; font-size: 26px; letter-spacing: 1px; color: var(--orange); -webkit-text-stroke: 1px var(--navy); animation: pop .3s ease-out; }
.vote-cards { display: flex; flex-direction: column; gap: 10px; }
.vote-card { position: relative; display: grid; grid-template-columns: minmax(0, 46%) minmax(0, 1fr); gap: 4px 10px; align-items: center; text-align: left; background: var(--paper);
  border: 3px solid var(--navy); border-radius: 14px; box-shadow: 4px 4px 0 var(--navy); padding: 7px; transition: transform .15s, opacity .25s, background .2s, filter .25s; }
.vote-card:active:not(.lose) { transform: translateY(2px); }
.vote-card:focus-visible { outline: 4px solid var(--blue); outline-offset: 3px; }
.vc-pic { position: relative; aspect-ratio: 16 / 10; border-radius: 8px; border: 2px solid var(--navy); overflow: hidden; background: var(--navy); }
.vc-pic > img { width: 100%; height: 100%; object-fit: cover; display: block; }
.vc-n { position: absolute; right: 4px; top: 4px; min-width: 26px; height: 26px; padding: 0 4px; border-radius: 13px; background: var(--navy); color: #fff; font-family: var(--fh); font-style: normal; font-size: 16px; line-height: 22px; text-align: center; border: 2px solid #fff; opacity: .55; }
.vc-n.on { background: var(--orange); color: var(--navy); opacity: 1; animation: pop .25s ease-out; }
.vc-pic kbd { position: absolute; left: 4px; top: 4px; font: 700 10px var(--fb); background: rgba(27, 35, 64, .78); color: #fff; border-radius: 4px; padding: 1px 5px; }
#app:not([data-input="keys"]) .vc-pic kbd { display: none; }
.vc-faces { position: absolute; left: 4px; bottom: 4px; right: 4px; display: flex; flex-wrap: wrap; gap: 3px; }
.vc-faces .vf { width: 28px; height: 28px; border-radius: 7px; }
.vc-txt { display: flex; flex-direction: column; min-width: 0; }
.vc-txt b { font-family: var(--fh); font-weight: 400; font-size: 21px; line-height: 1.05; letter-spacing: .5px; }
.vc-txt small { font-size: 11px; font-weight: 900; color: var(--orange); letter-spacing: .5px; }
.vc-txt em { align-self: flex-start; margin-top: 4px; font-style: normal; font-size: 9px; font-weight: 900; letter-spacing: .5px; background: var(--yellow); border: 1.5px solid var(--navy); border-radius: 4px; padding: 1px 5px; }
.vote-card.mine { background: #ffe7d3; }
.panel.vote.voted .vote-card:not(.mine) { cursor: default; }
.vote-card.win { background: #fff1b0; border-color: var(--orange); box-shadow: 0 0 0 3px var(--orange), 5px 5px 0 3px var(--navy); animation: vwin .55s ease-in-out infinite alternate; z-index: 1; }
@keyframes vwin { to { transform: scale(1.03); } }
.vote-card.lose { opacity: .4; filter: grayscale(.7); }
/* 12 Wähler (6 gegen 6): kleinere Gesichter, Rahmen in der Teamfarbe (vote.js) */
.vote-who.many { gap: 3px; flex-wrap: wrap; }
.vote-who.many .vf { width: 22px; height: 22px; border-radius: 6px; }
.vote-who.many small { display: none; }
.vote-cards.many .vc-faces .vf { width: 18px; height: 18px; border-radius: 5px; border-width: 1.5px; }
[dir="rtl"] .map-row, [dir="rtl"] .vote-card { text-align: right; }
[dir="rtl"] .panel .vote-top h2 { text-align: right; }

/* ---------- Querformat (Handy quer, Tablet, PC) ---------- */
@media (min-aspect-ratio: 13/10) {
  #app { max-width: calc(125vh + 420px); }
  .load-logo { max-height: 46vh; }

  /* Lobby: Inhalt mittig, Karten in Spalten, Startseite zweispaltig */
  .topbar { padding: calc(5px + var(--st)) calc(14px + var(--sr)) 4px calc(14px + var(--sl)); }
  .avatar { width: 42px; height: 42px; }
  .tab { padding: 4px max(calc(14px + var(--sr)), calc((100% - 980px) / 2)) 14px max(calc(14px + var(--sl)), calc((100% - 980px) / 2)); }
  .tab.active { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); align-content: start; align-items: start; }
  .tab .sec-title, .tab .sub, .tab .hint { grid-column: 1 / -1; }
  #tab-home.active { grid-template-columns: 1fr 1fr; grid-template-rows: 1fr auto auto auto 1fr; align-content: stretch; align-items: stretch; column-gap: 20px; }
  #tab-home .showcase { grid-column: 1; grid-row: 1 / 6; min-height: 0; }
  #tab-home .ccard-btn { grid-column: 2; grid-row: 1; align-self: end; justify-self: center; width: min(100%, 60vh); padding: 4px 0 0; }
  /* Profil: links Karte/Level/Statistik, rechts die Auswahl – beide Spalten scrollen für sich */
  #tab-profile.active { grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); grid-template-rows: minmax(0, 1fr); align-items: stretch; column-gap: 18px; overflow: hidden; }
  .prof-left, .prof-right { min-height: 0; max-height: 100%; overflow-y: auto; padding: 2px 6px 8px 2px; }
  /* Wochenaufgaben: links Countdown/Wochenbonus/Tage, rechts die Aufgaben des Tages – beide Spalten scrollen für sich */
  #tab-quests.active { grid-template-columns: minmax(0, 1fr) minmax(0, 1.3fr); grid-template-rows: minmax(0, 1fr); align-items: stretch; column-gap: 18px; overflow: hidden; }
  .q-left, .q-right { min-height: 0; max-height: 100%; overflow-y: auto; padding: 2px 6px 8px 2px; gap: 8px; }
  .q-right .sub { margin-top: 0; }
  .cos-subs { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  .cos-subs .btn { font-size: 13px; }
  /* Shop: Kopf, Reiter, Raster und Hinweise über die ganze Breite; Legenden-/Heldenkarten fließen in die Spalten */
  .shop-head, .shop-tabs, .shop-grid, .login-card, .shop-soon, .shop-coupon, .shop-note { grid-column: 1 / -1; }
  .shop-tabs .btn { flex-direction: row; justify-content: center; gap: 8px; padding: 6px 4px; }
  .shop-grid { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  .shop-grid.offers { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .offer.deal { grid-column: auto; display: flex; text-align: center; padding: 8px 6px 11px; }
  .offer.deal .btn { width: 100%; min-width: 0; margin-top: auto; font-size: 15px; padding: 6px 3px; }
  .offer.deal .of-txt b { font-size: 15px; }
  .offer.deal .of-txt small { font-size: 9px; }
  .lg-grid { grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 6px; }
  /* INK PASS: links Kopf/Stufe/Infozeile, rechts die Leiste */
  #tab-pass.active { grid-template-columns: minmax(0, 1fr) minmax(0, 1.5fr); grid-template-rows: minmax(0, 1fr); align-items: stretch; column-gap: 16px; overflow: hidden; }
  .pass-left, .pass-right { display: flex; flex-direction: column; gap: 8px; min-width: 0; min-height: 0; max-height: 100%; }
  .pass-left { overflow-y: auto; padding: 2px 6px 8px 2px; }
  .pass-right { justify-content: center; }
  .pass-head { gap: 6px; padding: 6px 10px 8px; }
  .ps-name b { font-size: 22px; }
  .ps-badge { min-width: 48px; height: 48px; }
  .ps-badge b { font-size: 24px; }
  .res-left.has-q { min-width: 255px; }    /* Aufgaben-Streifen: Symbol + bis zu 3 Stufen in einer Zeile */
  .res-left .q-strip > b { display: none; }
  .ccard.big { max-width: none; }
  #tab-home .arena-card { grid-column: 2; grid-row: 2; }
  #tab-home .mode-row { grid-column: 2; grid-row: 3; }
  #tab-home .btn-play { grid-column: 2; grid-row: 4; }
  .bottomnav { padding: 0 var(--sr) var(--sb) var(--sl); }
  .bottomnav button { flex-direction: row; justify-content: center; gap: 8px; padding: 5px 0 7px; font-size: 15px; }
  .bottomnav img { width: 26px; height: 26px; }
  .bottomnav .qbadge { right: calc(50% - 58px); top: 5px; }

  /* Match: Feld in der Mitte, Joystick links und Knöpfe rechts daneben (über dem Arena-Hintergrund) */
  #scr-game.active { display: grid; grid-template-rows: auto minmax(0, 1fr); grid-template-columns: minmax(0, 1fr); }
  .hud { padding: calc(4px + var(--st)) calc(8px + var(--sr)) 4px calc(8px + var(--sl)); }
  .board-wrap, .controls { grid-row: 2; grid-column: 1; }
  .controls { height: auto; background: none; border: 0; padding: 0; pointer-events: none; container-type: size; z-index: 1;
    --side: max(150px, calc((100cqw - 86.7cqh) / 2)); } /* Breite neben dem Feld (13 x 15 Felder) */
  @supports not (width: 1cqw) { /* ältere Browser ohne Container-Einheiten: aus der Fenstergröße schätzen */
    .controls { --side: max(150px, calc((min(100vw, 125vh + 420px) - 0.867 * (100vh - 46px)) / 2)); }
  }
  .joy-zone { width: var(--side); pointer-events: auto; }
  .joy-base { left: 50%; top: 58%; }
  .btns { top: 0; bottom: 0; right: 0; width: var(--side); transform: none; flex-direction: column; justify-content: center; gap: 12px; padding-top: 6%; pointer-events: none; }
  .btns > * { pointer-events: auto; }
  .controls.lefty .joy-zone { left: auto; right: 0; }
  .controls.lefty .joy-base { left: 50%; right: auto; }
  .controls.lefty .btns { right: auto; left: 0; flex-direction: column; }
  /* Zuschauen: links neben dem Feld über dem Joystick (tut nach dem K.O. nichts) statt über den oberen Map-Reihen; Linkshänder rechts */
  .spec { left: calc(8px + var(--sl)); top: 6px; transform: none; width: 134px; flex-wrap: wrap; justify-content: center; gap: 4px 10px; padding: 4px; }
  .spec span { order: -1; flex-basis: 100%; min-width: 0; padding: 0; }
  .spec b { max-width: 122px; font-size: 16px; }
  .spec.out b { max-width: 126px; font-size: 12px; }
  #scr-game:has(.controls.lefty) .spec { left: auto; right: calc(8px + var(--sr)); }
  .toast { bottom: 24px; }

  /* Fenster kompakter, damit sie auf flache Bildschirme passen */
  .modal { padding: 10px calc(18px + var(--sr)) 10px calc(18px + var(--sl)); }
  .panel { max-width: 560px; max-height: 96%; padding: 12px 16px; gap: 9px; }
  .panel.wide { max-width: 760px; }
  .panel.result { max-width: 760px; }
  /* Map-Abstimmung quer: Kopf in einer Zeile, drei Karten nebeneinander (Bild oben) */
  .panel.vote { max-width: 780px; }
  .vote-who { order: 0; flex-basis: auto; flex: none; }
  .panel .vote-top h2 { flex: 1 1 auto; }
  .vote-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
  .vote-card { grid-template-columns: minmax(0, 1fr); align-items: start; padding: 6px; }
  .vc-pic { aspect-ratio: 16 / 9; }
  .vc-txt b { font-size: 19px; }
  .panel.vote > .row .btn { flex: 0 0 auto; min-width: 180px; padding: 4px 18px; font-size: 16px; }
  .mi-thumb { width: 50%; }
  .mi-map { max-width: 130px; }
  .panel h2 { font-size: 26px; }
  .panel .col { flex-direction: row; flex-wrap: wrap; }
  .panel .col .btn { flex: 1 1 auto; }
  .toggles { display: grid; grid-template-columns: 1fr 1fr; column-gap: 18px; }
  .res-title { font-size: 40px; }
  .panel.result .rank-list { display: grid; grid-template-columns: 1fr 1fr; }
  /* Team-Ergebnis quer: Banner und Zeilen kompakter (12 Helden) */
  .panel.result.team { gap: 6px; }
  .team-res .tr { flex-direction: row; gap: 8px; padding: 2px 12px; }
  .tr-why { margin-top: -2px; }
  .team-cols { gap: 12px; }
  .tcol { gap: 3px; }
  .trr { padding: 1px 6px 1px 2px; }
  .trr > img { width: 22px; height: 22px; }
  /* Titel und Wertung nebeneinander, je Team zwei Spalten: 6 gegen 6 passt auf 844 × 390 ohne Scrollen (Controller kann nicht scrollen) */
  .panel.result.team { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; column-gap: 14px; }
  .panel.result.team > * { grid-column: 1 / -1; }
  .panel.result.team > .res-title { grid-column: 1; }
  .panel.result.team > .team-res { grid-column: 2; justify-content: flex-start; }
  .panel.result.team .tcol { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 3px 6px; align-content: start; }
  .panel.result.team .tcol h3 { grid-column: 1 / -1; }
  .asset-list { grid-template-columns: repeat(3, 1fr); }
  .lang-grid { grid-template-columns: repeat(4, 1fr); }
  .lvl-badge.top { bottom: -7px; }
  .lvl-badge.big { min-width: 40px; height: 40px; }
  .lvl-badge.big b { font-size: 21px; }
  .xp-box { padding: 5px 10px; gap: 3px; flex: 1; min-width: 0; }
  .res-mid { flex-direction: row; align-items: center; gap: 10px; }
  .res-left { display: flex; flex-direction: column; gap: 6px; flex: 0 1 auto; }
  .res-mid .rewards { gap: 8px; }
  .lvlup { font-size: 17px; padding: 2px 10px; }
  .res-title { font-size: 36px; line-height: 1.1; }
  .panel.result > .row { bottom: -12px; margin: 0 -16px -12px; padding: 6px 16px 12px; } /* Knopfzeile klebt unten (Innenabstand quer) */
}

/* Flache Querformate (Handy quer): Startseite mit Modus-Schalter passt in die Höhe – Karte, Vorschau und Schalter kompakter */
@media (min-aspect-ratio: 13/10) and (max-height: 500px) {
  #tab-home.active { row-gap: 8px; }
  #tab-home .ccard-btn { width: min(100%, 50vh); }
  #tab-home .arena-card { padding: 6px 8px; }
  #tab-home .arena-card .thumbs { width: 38%; }
  #tab-home .mode-btn { padding: 4px 4px 5px; }
  #tab-home .mode-btn b { font-size: 16px; }
  #tab-home .mode-btn small { display: none; }
}

/* ---------- Von rechts nach links (Arabisch) ----------
   Menüs spiegeln sich automatisch; das Match (Feld, HUD, Joystick/Knöpfe) bleibt bewusst unverändert. */
#scr-game { direction: ltr; }
[dir="rtl"] .pill { margin-left: 0; margin-right: 10px; padding: 0 0 0 4px; }
[dir="rtl"] .pill img { margin-left: 0; margin-right: -14px; }
[dir="rtl"] .pill span { padding: 0 2px 0 6px; }
[dir="rtl"] .arena-card { text-align: right; }
[dir="rtl"] .hero-tag { left: auto; right: 0; transform: skewX(8deg); box-shadow: -4px 4px 0 var(--orange); }
[dir="rtl"] .trophy-badge { left: auto; right: 0; padding: 2px 4px 2px 10px; }
[dir="rtl"] .pic-wrap .lock { right: auto; left: -8px; }
[dir="rtl"] .rrow { border-left: 3px solid var(--navy); border-right: 8px solid var(--c); padding: 4px 6px 4px 10px; }
[dir="rtl"] .cc-box { left: 0; right: 4%; }
[dir="rtl"] .cc-emb { left: auto; right: 0; }
[dir="rtl"] .cc-txt { left: 16%; right: 32%; }
[dir="rtl"] .ccard .cc-lvl { right: auto; left: 3%; }
[dir="rtl"] .ccard.row .cc-box { left: 0; right: 14px; }
[dir="rtl"] .ccard.row .cc-txt { left: 36px; right: 47px; }
[dir="rtl"] .ccard.row .cc-lvl { left: 4px; }
[dir="rtl"] .panel.result .rrow { padding: 4px 5px 4px 8px; }
[dir="rtl"] .pk-info { border-left: 3px solid var(--navy); border-right: 8px solid var(--rc); }
[dir="rtl"] .pk-item.locked::after { right: auto; left: 3px; }
[dir="rtl"] .bottomnav button + button { border-left: 0; border-right: 2px solid rgba(27, 35, 64, .15); }
[dir="rtl"] .sec-title, [dir="rtl"] .res-title { transform: skewX(6deg); }
[dir="rtl"] .quest-btn { right: auto; left: 0; }
[dir="rtl"] .qbadge { right: auto; left: -9px; }
[dir="rtl"] .q-dot { right: auto; left: -6px; }
[dir="rtl"] .q-row { border-left: 3px solid var(--navy); border-right: 8px solid var(--tc); padding: 6px 9px 7px 8px; }
[dir="rtl"] .leg-card { border-left: 3px solid var(--navy); border-right: 8px solid var(--cc); }
[dir="rtl"] .buy-box { border-left: 3px solid var(--navy); border-right: 8px solid var(--rc); }
[dir="rtl"] .leg-cls { margin-left: 0; margin-right: 4px; }
[dir="rtl"] .offer.deal { text-align: right; }
[dir="rtl"] .of-deal { left: auto; right: -5px; transform: rotate(3deg); }
[dir="rtl"] .shop-tabs .q-dot { right: auto; left: 3px; }
[dir="rtl"] .bottomnav .qbadge { right: auto; left: calc(50% - 34px); }
/* Texte im Match nehmen trotzdem die Richtung ihrer Schrift (Satzzeichen arabischer Texte an der richtigen Seite) */
#scr-game .banner, #scr-game .countdown, #scr-game .objbar small, #scr-game .objbar .ln, #scr-game .spec small, #scr-game .spec b { unicode-bidi: plaintext; }

/* ---------- Schriften je Sprache (html lang = angezeigte Sprache, gesetzt von IB.I18N) ----------
   Anton (Überschriften) und Rubik (Fließtext) decken Latein samt Türkisch, Rumänisch (ș ț) und Polnisch ab, Rubik auch
   Kyrillisch – Anton kein Kyrillisch, beide kein Chinesisch/Japanisch/Arabisch/Devanagari. Für ru, zh, ja, ar und hi lädt
   IB.I18N die eigene Schrift des Stapels von Google Fonts nach (nur für die aktive Sprache, nur die fette Stufe); ohne Netz
   greifen die Systemschriften dahinter (iOS/macOS, Windows, Android/Noto). zh/ja/ar/hi: Anton steht vorn, damit Latein und
   Ziffern (Namen, Preise, K.O., XP) wie in allen Sprachen aussehen und schmal bleiben (Dela Gothic One: sehr breites Latein). */
:lang(ru) { --fh: 'Oswald', 'Anton', Impact, 'Roboto Condensed', 'Arial Narrow', 'Arial Black', sans-serif; }
:lang(zh) {
  --fh: 'Anton', 'ZCOOL QingKe HuangYou', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', 'Noto Sans SC', 'Noto Sans CJK SC', 'Source Han Sans SC', sans-serif;
  --fb: 'Rubik', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', 'Noto Sans SC', 'Noto Sans CJK SC', 'Source Han Sans SC', sans-serif;
}
:lang(ja) {
  --fh: 'Anton', 'Dela Gothic One', 'Hiragino Sans', 'Hiragino Kaku Gothic ProN', 'Yu Gothic UI', 'Yu Gothic', Meiryo, 'Noto Sans JP', 'Noto Sans CJK JP', sans-serif;
  --fb: 'Rubik', 'Hiragino Sans', 'Hiragino Kaku Gothic ProN', 'Yu Gothic UI', 'Yu Gothic', Meiryo, 'Noto Sans JP', 'Noto Sans CJK JP', sans-serif;
}
:lang(ar) {
  --fh: 'Anton', 'Lalezar', 'Geeza Pro', 'Noto Sans Arabic', 'Segoe UI', Tahoma, sans-serif;
  --fb: 'Rubik', 'Geeza Pro', 'Noto Sans Arabic', 'Noto Naskh Arabic', 'Segoe UI', Tahoma, sans-serif;
}
:lang(hi) {
  --fh: 'Anton', 'Baloo 2', 'Kohinoor Devanagari', 'Nirmala UI', 'Noto Sans Devanagari', 'Devanagari Sangam MN', Mangal, sans-serif;
  --fb: 'Rubik', 'Kohinoor Devanagari', 'Nirmala UI', 'Noto Sans Devanagari', 'Devanagari Sangam MN', Mangal, sans-serif;
}
/* Arabisch (verbundene Buchstaben) und Devanagari (durchgehende Kopflinie) vertragen keinen Buchstabenabstand */
:lang(ar), :lang(hi) { letter-spacing: 0 !important; }

@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
@keyframes poke { 0% { transform: scale(1); } 35% { transform: scale(1.08, .92); } 70% { transform: scale(.96, 1.05) translateY(-10px); } 100% { transform: scale(1); } }
@keyframes pop { from { transform: scale(.85); opacity: 0; } to { transform: scale(1); opacity: 1; } }
@keyframes pulse { from { transform: scale(1); } to { transform: scale(1.08); } }
@keyframes blink { 50% { opacity: .35; } }
@keyframes padRing { from { outline-color: var(--blue); } to { outline-color: var(--orange); } }
@keyframes glow { 50% { box-shadow: 4px 4px 0 var(--navy), 0 0 18px rgba(242, 106, 33, .55); } }
@keyframes count { 0% { opacity: 0; transform: scale(2.2); } 25% { opacity: 1; transform: scale(1); } 75% { opacity: 1; } 100% { opacity: 0; transform: scale(.8); } }
@keyframes bannerIn { from { opacity: 0; transform: scale(1.6) rotate(-4deg); } to { opacity: 1; transform: scale(1) rotate(-4deg); } }
@keyframes ccShine { 0%, 55% { transform: translateX(-130%) skewX(-18deg); } 100% { transform: translateX(250%) skewX(-18deg); } }
@keyframes ccSpark { from { opacity: .2; } to { opacity: 1; } }
@keyframes ptGlow { 50% { box-shadow: 0 3px 0 var(--navy), 0 0 14px rgba(242, 106, 33, .8); } }
@keyframes frGlow { from { box-shadow: 0 0 0 2px var(--navy), inset 0 0 0 2px var(--f2), 0 0 5px 1px var(--f1); } to { box-shadow: 0 0 0 2px var(--navy), inset 0 0 0 2px var(--f2), 0 0 16px 4px var(--f1); } }
@keyframes frSlide { to { background-position: 300% 0; } }

/* ---------- Online (ONLINE-SPEC 8.3): nur mit Konto sichtbar; neue Regeln mit logischen Eigenschaften ---------- */
.fr-btn[hidden], .home-net[hidden], .party-bar[hidden], .inv-card[hidden], .net-ping[hidden], .res-acts[hidden] { display: none !important; }
.topbar.net { gap: 6px; }
.topbar.net .pill { min-width: 80px; margin-inline-start: 8px; }
.fr-btn { position: relative; width: 38px; height: 38px; }
.fr-btn svg { width: 34px; height: 34px; filter: drop-shadow(1px 2px 0 rgba(0, 0, 0, .25)); }
.fr-btn .qbadge { top: -8px; right: -8px; }
.net-dot { position: absolute; inset-inline-end: -1px; bottom: 1px; width: 12px; height: 12px; border-radius: 50%; border: 2px solid var(--navy); background: #9aa0b4; }
.net-dot.on { background: #3ccf5a; }
.net-dot.wait { background: var(--yellow); animation: blink 1s infinite; }
.acc-box .net-dot { position: static; display: inline-block; }
/* Startseite: Party-Leiste, GEGNER: ONLINE | BOTS, PRIVAT */
.home-net { display: flex; flex-direction: column; gap: 6px; flex: none; }
.opp-row { display: flex; gap: 6px; align-items: stretch; }
.opp { flex: 1; min-width: 0; display: flex; align-items: center; gap: 3px; background: var(--paper); border: 3px solid var(--navy); border-radius: 12px; padding: 3px; box-shadow: 0 4px 0 var(--navy); }
.opp-l { font-family: var(--fh); font-size: 12px; letter-spacing: .5px; padding-inline: 4px 2px; color: var(--navy3); }
.opp-btn { flex: 1; min-width: 0; display: flex; flex-direction: column; align-items: center; padding: 2px; border-radius: 8px; }
.opp-btn b { font-family: var(--fh); font-weight: 400; font-size: 16px; line-height: 1.05; letter-spacing: .5px; }
.opp-btn small { font-size: 8px; font-weight: 900; letter-spacing: .4px; color: var(--navy3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.opp-btn.on { background: var(--blue); color: #fff; }
.opp-btn.on small { color: var(--yellow); }
.opp-btn:disabled { opacity: .35; }
.priv-btn { flex: none; font-size: 17px; padding: 6px 12px; }
.priv-btn.on { background: var(--orange); color: var(--navy); }
.party-bar { display: flex; align-items: center; gap: 8px; min-width: 0; background: var(--navy); color: #fff; border-radius: 12px; padding: 4px 6px; padding-inline-start: 10px; }
.pb-t { font-family: var(--fh); font-weight: 400; font-size: 14px; letter-spacing: 1px; color: var(--yellow); flex: none; }
.pb-ms { flex: 1; min-width: 0; display: flex; gap: 8px; }
.pb-m { position: relative; flex: 1 1 0; display: flex; align-items: center; gap: 4px; min-width: 0; font-weight: 700; font-size: 12px; }
.pb-m bdi { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pb-m.me bdi { color: var(--yellow); }
.pb-m .ou-emb { width: 26px; height: 26px; flex: none; }
.pb-m .crown { position: absolute; top: -9px; inset-inline-start: 7px; font-style: normal; font-size: 12px; color: var(--yellow); }
.pb-leave { flex: none; font-size: 13px; padding: 4px 8px; }
#tab-home.net .btn-play { height: 62px; font-size: 36px; }
#tab-home .btn-play.wait { opacity: .6; }
.ou-emb { object-fit: contain; }
/* Freunde */
.fr-wide { grid-column: 1 / -1; }
.fr-me .fr-code { display: block; font-family: var(--fh); font-weight: 400; font-size: 26px; letter-spacing: 2px; }
.fr-me .info > small, .fr-add + .name-err { font-size: 11px; font-weight: 700; color: var(--navy3); }
.fr-add { gap: 8px; }
.fr-add .name-in { flex: 1; min-width: 0; }
.code-in { text-transform: uppercase; letter-spacing: 2px; }
.fr-row { padding: 8px; gap: 8px; }
.fr-row .ou-emb { width: 40px; height: 40px; flex: none; }
.fr-n { display: block; font-family: var(--fh); font-weight: 400; font-size: 18px; letter-spacing: .5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fr-row .info > small { display: flex; align-items: center; gap: 6px; }
.fr-row .act { display: flex; gap: 6px; }
.fr-row .btn { font-size: 14px; padding: 6px 10px; }
.fr-more { min-width: 40px; }
.fr-st { font-size: 10px; font-weight: 900; letter-spacing: .5px; padding: 1px 6px; border-radius: 6px; background: #c9bfa9; color: var(--navy); }
.fr-st.on { background: #3ccf5a; }
.fr-st.match { background: var(--yellow); }
.fr-pick { display: flex; flex-direction: column; gap: 6px; }
.fr-pick .fr-row { width: 100%; text-align: start; }
/* Suche, Warten */
.mm-dots { display: flex; justify-content: center; gap: 10px; padding: 6px 0; }
.mm-dots i { width: 14px; height: 14px; border-radius: 50%; background: var(--orange); border: 2px solid var(--navy); animation: mmDot 1s infinite ease-in-out; }
.mm-dots i:nth-child(2) { animation-delay: .15s; }
.mm-dots i:nth-child(3) { animation-delay: .3s; }
.mm-dots.done i { animation: none; background: #3ccf5a; }
.mm-count { font-weight: 700; }
@keyframes mmDot { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
/* Private Lobby */
.panel.lob { gap: 10px; }
.panel.lob .btn { font-size: 15px; padding: 7px 10px; }
.lob-row { flex-wrap: wrap; }
.lob-row .btn { flex: 1 1 auto; }
.lob-code { display: flex; align-items: center; justify-content: center; gap: 10px; flex-wrap: wrap; background: var(--paper); border: 3px dashed var(--navy); border-radius: 12px; padding: 6px 10px; }
.lob-code small { font-size: 11px; font-weight: 900; color: var(--navy3); }
.lob-code b { font-family: var(--fh); font-weight: 400; font-size: 32px; letter-spacing: 4px; }
.lob-slots { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
.lob-slot { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; min-width: 0; min-height: 46px; background: var(--paper); border: 3px solid var(--navy); border-radius: 10px; padding: 5px 6px; }
.lob-slot.t0 { border-color: var(--blue); }
.lob-slot.t1 { border-color: var(--orange); }
.lob-slot.me { box-shadow: 0 0 0 2px var(--yellow); }
.lob-slot.off { opacity: .55; }
.lob-slot.free { border-style: dashed; color: var(--navy3); }
.lob-slot .ou-emb { width: 30px; height: 30px; flex: none; }
.ls-free { width: 30px; height: 30px; flex: none; border-radius: 8px; background: repeating-linear-gradient(45deg, #e3d9c4 0 4px, transparent 4px 8px); }
.ls-n { flex: 1; min-width: 0; font-weight: 700; font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ls-host { order: 3; flex-basis: 100%; font-style: normal; font-size: 9px; font-weight: 900; letter-spacing: .5px; color: var(--orange); line-height: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } /* eigene Zeile, nie mit dem Namen abgeschnitten */
.lob-slot.free .ls-n { white-space: normal; line-height: 1.15; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; } /* „Frei – hier spielt ein Bot“ zweizeilig */
.panel.lob .ls-kick { flex-basis: 100%; font-size: 11px; padding: 3px 6px; box-shadow: 0 2px 0 var(--navy); }
.lob-opts { display: flex; flex-direction: column; gap: 6px; }
.seg { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 4px; }
.seg small { font-size: 11px; font-weight: 900; color: var(--navy3); flex-basis: 100%; text-align: center; }
.seg .btn { flex: 1 1 0; min-width: 0; }
.lob-live { color: var(--orange); }
/* Einladung */
.inv-card { position: absolute; inset-inline: 10px; top: calc(60px + var(--st)); z-index: 20; display: flex; align-items: center; flex-wrap: wrap; gap: 8px; background: var(--navy); color: #fff; border: 3px solid var(--yellow); border-radius: 14px; padding: 8px 10px; box-shadow: 4px 4px 0 rgba(0, 0, 0, .3); animation: pop .25s ease-out; }
.inv-card .ou-emb { width: 34px; height: 34px; flex: none; }
.ic-t { flex: 1 1 150px; min-width: 0; font-weight: 700; font-size: 13px; line-height: 1.3; overflow-wrap: anywhere; } /* 16 breite Zeichen ohne Leerzeichen dürfen umbrechen */
.ic-b { display: flex; gap: 6px; margin-inline-start: auto; }
.inv-card .btn { font-size: 14px; padding: 5px 10px; }
/* Konto (Einstellungen) */
.acc-box { display: flex; flex-direction: column; gap: 8px; background: var(--paper); border: 3px solid var(--navy); border-radius: 12px; padding: 10px; }
.acc-box h3 { display: flex; align-items: center; gap: 8px; font-family: var(--fh); font-weight: 400; font-size: 20px; letter-spacing: 1px; }
.acc-st { font-size: 13px; font-weight: 700; line-height: 1.35; }
.acc-code { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }
.acc-code small { font-size: 11px; font-weight: 900; color: var(--navy3); }
.acc-code b { flex: 1; font-family: var(--fh); font-weight: 400; font-size: 22px; letter-spacing: 2px; }
.acc-box .btn { font-size: 15px; padding: 7px 8px; }
.acc-box .row { flex-wrap: wrap; }
.acc-del { color: #b3122a; }
/* Match: Ping unter dem Timer */
.net-ping { position: absolute; top: calc(47px + var(--st)); left: 50%; transform: translateX(-50%); z-index: 3; font-size: 10px; font-weight: 900; color: #fff; background: rgba(15, 20, 40, .75); border-radius: 6px; padding: 0 6px; pointer-events: none; }
/* Ergebnis online: Mitspieler antippen → Aktionen */
[data-act="res-player"] { cursor: pointer; }
.rrow.sel, .trr.sel { outline: 3px solid var(--orange); outline-offset: 1px; }
.res-acts { display: flex; flex-direction: column; gap: 6px; background: var(--paper); border: 3px solid var(--navy); border-radius: 12px; padding: 8px; flex: none; }
.res-acts .row { flex-wrap: wrap; }
.res-acts .btn { font-size: 14px; padding: 6px 8px; }
.ra-n { font-family: var(--fh); font-weight: 400; font-size: 18px; text-align: center; }
.rep-h { font-family: var(--fh); font-weight: 400; font-size: 20px; text-align: center; }
.rep-list { display: flex; flex-direction: column; gap: 6px; }
.rep-list .btn { white-space: normal; font-size: 15px; }
@media (min-aspect-ratio: 13/10) {
  /* quer mit Konto: eigene Rasterzeile für Party/GEGNER/PRIVAT über SPIELEN; dafür ohne Visitenkarte (oben links am Avatar) und
     mit kleinerer Map-Karte – das Offline-Raster bleibt unverändert */
  #tab-home.net.active { grid-template-rows: 1fr auto auto auto auto 1fr; }
  #tab-home.net .showcase { grid-row: 1 / 7; }
  #tab-home.net .ccard-btn { display: none; }
  #tab-home .home-net { grid-column: 2; grid-row: 4; }
  #tab-home.net .btn-play { grid-row: 5; height: 48px; font-size: 28px; }
  #tab-home.net .arena-card { padding: 5px 8px; }
  #tab-home.net .arena-card .thumbs { width: 30%; }
  #tab-home.net .arena-card .faces { display: none; }
  #tab-home.net .party-bar { padding-block: 2px; }
  .net-ping { top: calc(42px + var(--st)); }
  .inv-card { inset-inline: auto 14px; max-width: 420px; top: calc(52px + var(--st)); }
}

/* ---------- Clans (CLAN-SPEC 9): Reiter CLAN, Fenster, Kriegs-Chip, HUD-Zeile; logische Eigenschaften (Arabisch) ---------- */
.bottomnav button[hidden], .war-chip[hidden], .war-vs[hidden], .ch-newer[hidden] { display: none !important; }
.cc-tag { font-family: var(--fh); font-weight: 400; letter-spacing: .5px; opacity: .85; }
.war-chip { display: flex; align-items: center; justify-content: center; min-width: 0; padding: 5px 10px; border: 3px solid var(--navy); border-radius: 12px; background: var(--red); color: #fff; font-family: var(--fh); font-size: 15px; letter-spacing: .5px; box-shadow: 0 3px 0 var(--navy); }
.war-chip b { font-weight: 400; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.war-vs { position: absolute; left: 50%; bottom: 6px; transform: translateX(-50%); z-index: 3; max-width: 92%; overflow: hidden; text-overflow: ellipsis; padding: 2px 10px; border-radius: 8px; background: rgba(15, 20, 40, .78); color: #fff; font-family: var(--fh); font-size: 14px; letter-spacing: .5px; white-space: nowrap; pointer-events: none; }
.war-vs b { font-weight: 400; }
.war-res { text-align: center; font-family: var(--fh); font-size: 18px; letter-spacing: .5px; color: var(--red); }
.war-res b { font-weight: 400; }
.war-res small, .clan-bonus { display: block; font-family: var(--fb); font-size: 12px; font-weight: 800; color: var(--navy3); letter-spacing: 0; }
.clan-bonus { display: flex; align-items: center; justify-content: center; gap: 6px; color: var(--navy); }
.clan-bonus img { width: 20px; height: 20px; }
/* Unter-Reiter und Segmente: nie breiter als der Bildschirm (Text wird gekürzt) */
#tab-clan .cl-seg { flex: none; flex-wrap: nowrap; }
.cl-seg .btn, .cl-filt .btn, .cl-mode .btn, .cl-pol .btn { position: relative; font-size: 14px; padding: 6px 4px; overflow: hidden; text-overflow: ellipsis; }
.cl-mode .btn, .cl-pol .btn { flex: 1 1 auto; } /* lange Beschriftungen („NUR EINLADUNG“) nehmen sich mehr Breite statt gekürzt zu werden */
.cl-n { position: absolute; inset-block-start: 1px; inset-inline-end: 2px; min-width: 16px; height: 16px; padding: 0 3px; border-radius: 8px; background: var(--red); color: #fff; font-family: var(--fb); font-style: normal; font-size: 10px; font-weight: 900; line-height: 16px; letter-spacing: 0; }
.cl-body, .cl-l, .cl-r { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.cl-body { gap: 12px; }
.cl-body .card, .panel .cl-row { min-width: 0; }
.card .info > small.cl-st, .cl-st { font-size: 10px; font-weight: 900; color: var(--navy3); text-align: center; }
/* Wappen auf Clan-Farbe */
.cb-wrap { display: inline-grid; place-items: center; flex: none; width: 56px; height: 56px; border-radius: 14px; background: var(--bc, var(--navy)); border: 3px solid var(--navy); box-shadow: inset 0 -6px 0 rgba(0, 0, 0, .18); }
.cb-wrap img { width: 88%; height: 88%; object-fit: contain; }
.cb-wrap.xs { width: 26px; height: 26px; border-width: 2px; border-radius: 7px; box-shadow: none; }
.cb-wrap.sm { width: 46px; height: 46px; border-radius: 12px; }
.cb-wrap.lg { width: 84px; height: 84px; border-radius: 18px; }
.cb-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(52px, 1fr)); gap: 6px; }
.cb-pick { position: relative; padding: 2px; border: 3px solid transparent; border-radius: 16px; }
.cb-pick .cb-wrap { width: 100%; height: auto; aspect-ratio: 1; }
.cb-pick.on { border-color: var(--orange); }
.cb-pick.locked .cb-wrap { opacity: .45; filter: grayscale(.8); }
.cb-pick.locked::after { content: '🔒'; position: absolute; inset-block-end: 2px; inset-inline-end: 3px; font-size: 12px; }
.cb-colors { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.cb-col { width: 34px; height: 34px; border-radius: 50%; background: var(--bc); border: 3px solid var(--navy); }
.cb-col.on { box-shadow: 0 0 0 3px var(--orange); }
/* Suche, Zeilen, Formular */
.cl-sbox { padding: 8px; gap: 8px; }
.cl-sbox .btn { flex: none; font-size: 15px; padding: 7px 10px; }
.cl-row, .cl-inv, .cl-inb, .cl-live, .cl-rw { padding: 8px; gap: 8px; }
.cl-ri { display: flex; align-items: center; gap: 8px; flex: 1; min-width: 0; text-align: start; }
.cl-ri .info, .cl-inv .info { flex: 1; min-width: 0; }
.cl-ri .info > small, .cl-inv .info > small, .cl-inb .info > small { display: block; }
.cl-row .act, .cl-inv .act { display: flex; flex-direction: column; align-items: stretch; gap: 4px; }
.cl-row .btn, .cl-inv .btn, .cl-inb .btn { font-size: 14px; padding: 6px 10px; }
.cl-form { flex-direction: column; align-items: stretch; gap: 8px; }
.cl-f { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.cl-f > small { font-size: 11px; font-weight: 900; color: var(--navy3); letter-spacing: .5px; }
.cl-f .name-in { flex: none; width: 100%; }
.cl-step { display: flex; align-items: center; gap: 4px; }
.cl-step .btn { flex: none; padding: 4px 10px; font-size: 16px; }
.cl-step b { flex: 1; min-width: 0; text-align: center; font-family: var(--fh); font-weight: 400; font-size: 20px; }
.cl-langb { align-self: flex-start; max-width: 100%; overflow: hidden; text-overflow: ellipsis; font-size: 15px; padding: 5px 12px; }
.cl-prev { justify-content: center; }
.cl-prev .fr-n { font-size: 22px; min-width: 0; }
.cl-need { flex-direction: column; align-items: stretch; text-align: center; }
/* Übersicht, Mitglieder */
.cl-head { gap: 12px; }
.cl-name { display: block; font-family: var(--fh); font-weight: 400; font-size: 26px; line-height: 1.1; overflow-wrap: anywhere; }
.cl-tagrow { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin-top: 4px; }
.cl-tagrow .cc-tag { font-size: 20px; opacity: 1; }
.cl-tagrow .btn { font-size: 13px; padding: 4px 8px; }
.cl-lvbox .info > b, .cl-goal .info > b, .cl-wcard .info > b, .cl-sum .info > b, .cl-rw .info > b, .cl-inb .info > b { display: block; font-family: var(--fh); font-weight: 400; font-size: 19px; letter-spacing: .5px; }
.cl-lvbox .info > small, .cl-goal .info > small, .cl-wcard .info > small, .cl-week .info > small { display: block; margin-top: 3px; }
.cl-gold { color: #a86d00; }
.card.cl-desc p { font-size: 14px; font-weight: 700; overflow-wrap: anywhere; }
.cl-leavehint { color: #d62839; }
.cl-mem { width: 100%; text-align: start; }
.cl-mem.me { background: #fff3c9; }
.cl-num { display: flex; flex-direction: column; align-items: flex-end; flex: none; }
.cl-num small { font-size: 10px; font-weight: 900; color: var(--navy3); }
.cl-role { font-style: normal; font-size: 10px; font-weight: 900; letter-spacing: .5px; padding: 1px 6px; border-radius: 6px; background: #c9bfa9; color: var(--navy); white-space: nowrap; }
.cl-role.r-leader { background: var(--orange); }
.cl-role.r-vice { background: #8fb0ff; }
.cl-role.r-elder { background: var(--yellow); }
.cl-ico { width: 14px; height: 14px; }
.cl-pubm { display: flex; flex-direction: column; gap: 4px; max-height: 40vh; overflow-y: auto; }
.cl-pm { padding: 4px 6px; background: var(--paper); border-radius: 10px; }
.cl-pm .ou-emb { width: 32px; height: 32px; flex: none; }
.panel.cl-view .row { flex-wrap: wrap; align-items: center; }
.panel.cl-menu .col .btn { width: 100%; }
.cl-rws { display: flex; flex-direction: column; gap: 6px; }
.cl-rw.ok { background: #e3f7e6; }
.cl-ok { font-style: normal; font-size: 11px; color: #1f8a3a; }
/* Chat */
.ch-log { display: flex; flex-direction: column; gap: 6px; padding: 8px; background: var(--paper); border: 3px solid var(--navy); border-radius: 14px; overflow-y: auto; overscroll-behavior: contain; }
.ch-m { align-self: flex-start; display: flex; flex-direction: column; align-items: flex-start; gap: 1px; max-width: 86%; padding: 5px 9px 4px; background: #fff; border: 2px solid var(--navy); border-radius: 12px; border-end-start-radius: 4px; text-align: start; }
.ch-m.me { align-self: flex-end; align-items: flex-end; background: #dfe8ff; border-end-start-radius: 12px; border-end-end-radius: 4px; }
.ch-n { font-family: var(--fh); font-weight: 400; font-size: 13px; letter-spacing: .3px; color: var(--navy3); }
.ch-m.r-leader .ch-n { color: #c4500f; }
.ch-m.r-vice .ch-n { color: var(--blue); }
.ch-x { font-size: 14px; font-weight: 700; overflow-wrap: anywhere; white-space: pre-wrap; }
.ch-x.qp { font-family: var(--fh); font-weight: 400; font-size: 16px; color: var(--blue); }
.ch-emo-x { font-size: 30px; line-height: 1; }
.ch-m time, .ch-sys time { font-size: 9px; font-weight: 800; color: var(--navy3); }
.ch-sys { align-self: center; max-width: 92%; padding: 3px 8px; border-radius: 8px; background: #efe5cf; text-align: center; font-size: 11px; font-weight: 800; color: var(--navy3); }
.ch-sys time { margin-inline-start: 6px; }
.ch-col { display: flex; flex-direction: column; gap: 6px; flex: 1 1 auto; min-height: 0; }
.ch-in { display: flex; align-items: center; gap: 6px; flex: none; }
.ch-in .name-in { font-size: 16px; padding-block: 7px; }
.ch-in .btn { flex: none; font-size: 15px; padding: 7px 10px; }
.ch-in .ch-tg { padding: 5px 7px; font-size: 18px; }
.ch-err { flex: none; min-height: 0; }
.ch-err:empty { display: none; }
.ch-newer { align-self: center; flex: none; font-size: 13px; padding: 4px 12px; }
.ch-drawer { flex: none; max-height: 38vh; overflow-y: auto; padding: 6px; background: var(--paper); border: 3px solid var(--navy); border-radius: 12px; }
/* Schnellsprüche in der Schublade: zwei waagrecht scrollende Reihen, damit der Verlauf sichtbar bleibt */
.ch-drawer .ch-qps { grid-auto-flow: column; grid-template-columns: none; grid-template-rows: repeat(2, auto); grid-auto-columns: minmax(44%, max-content); overflow-x: auto; overscroll-behavior-x: contain; }
.ch-qps { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 5px; }
.ch-qps .btn { font-size: 13px; padding: 6px; white-space: normal; line-height: 1.1; letter-spacing: .3px; }
.ch-emos { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 5px; }
.ch-emos .btn { font-family: var(--fb); font-size: 22px; padding: 4px 0; }
.ch-side { display: none; flex-direction: column; gap: 8px; }
.ch-prev { text-align: center; overflow-wrap: anywhere; }
#tab-clan[data-sub="chat"].active { overflow: hidden; }
.cl-chat { flex: 1 1 auto; min-height: 0; }
.cl-chat .cl-r { flex: 1 1 auto; min-height: 0; }
.cl-chat .ch-log { flex: 1 1 auto; min-height: 120px; }
/* Krieg, Rangliste, Postfach */
.cl-wcard .info > b.cl-big { font-size: 25px; color: var(--red); }
.cl-wcard.live { background: #ffe7d3; }
.cl-warn { color: #d62839; }
.cl-names { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 5px; }
.cl-chip { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding: 2px 8px; border-radius: 8px; background: #e6dac2; font-size: 12px; font-weight: 800; }
.cl-chip.me { background: var(--yellow); }
.cl-srch .mm-dots { flex: none; }
.cl-score { flex: none; font-family: var(--fh); font-size: 22px; }
.cl-left { flex: none; font-size: 11px; font-weight: 900; color: var(--navy3); }
.cl-board { flex-direction: column; align-items: stretch; gap: 2px; padding: 6px; }
.cl-board.full { display: flex; }
.cl-brow { display: flex; align-items: center; gap: 8px; min-width: 0; padding: 3px 4px; border-radius: 8px; }
.cl-brow.me { background: #fff3c9; }
.cl-brow .pl { flex: none; width: 28px; text-align: center; font-family: var(--fh); font-weight: 400; font-size: 18px; }
.cl-brow .fr-n { flex: 1; min-width: 0; font-size: 16px; }
.cl-brow small, .cl-hrow small { flex: none; font-size: 11px; font-weight: 900; color: var(--navy3); }
.cl-sep { border-top: 2px dashed var(--navy3); margin: 4px 0; }
.cl-wrow .btn { font-size: 14px; padding: 6px 8px; }
.cl-hrow { display: flex; align-items: center; gap: 8px; min-width: 0; padding: 4px 6px; border-bottom: 2px solid #e6dac2; font-size: 12px; font-weight: 800; }
.cl-hrow .fr-n { flex: 1; min-width: 0; font-size: 15px; }
.cl-res { flex: none; padding: 1px 6px; border-radius: 6px; background: #c9bfa9; font-family: var(--fh); font-weight: 400; font-size: 14px; }
.cl-res.win { background: #3ccf5a; }
.cl-res.draw { background: var(--yellow); }
.cl-res.loss { background: #ff9aa5; }
.cl-rwt { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 4px; }
.cl-rwt span { display: flex; flex-direction: column; align-items: center; padding: 4px 2px; background: var(--paper); border: 2px solid var(--navy); border-radius: 8px; font-size: 12px; font-weight: 900; }
.cl-rwt b { font-family: var(--fh); font-weight: 400; font-size: 16px; }
.cl-rwt img { width: 16px; height: 16px; }
.cl-rwt small { font-size: 9px; color: var(--navy3); text-align: center; }
.cl-rwis { display: flex; flex-direction: column; gap: 4px; margin-top: 6px; }
.cl-rwi { display: flex; align-items: center; gap: 8px; }
.cl-rwi > b { flex: none; min-width: 64px; font-size: 12px; font-weight: 900; }
.cl-rwi .cl-items { margin-top: 0; }
.cl-rwi .cl-ipic { width: 28px; height: 28px; }
.cl-rwi .cl-icard { width: 48px; height: 27px; }
.cl-items { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 4px; }
.panel.cl-claimed .cl-items { justify-content: center; }
.cl-gem { display: inline-flex; align-items: center; gap: 4px; font-family: var(--fh); font-size: 18px; }
.cl-gem img { width: 22px; height: 22px; }
.cl-gem.big { display: flex; justify-content: center; font-size: 30px; }
.cl-gem.big img { width: 36px; height: 36px; }
.cl-ipic { width: 40px; height: 40px; object-fit: contain; }
.cl-icard { display: inline-block; width: 64px; height: 36px; border: 2px solid var(--navy); border-radius: 6px; overflow: hidden; }
.cl-icard img { width: 100%; height: 100%; object-fit: cover; }
.cl-ititle { padding: 2px 6px; border-radius: 6px; background: var(--yellow); font-size: 11px; font-weight: 900; }
@media (max-width: 520px) and (max-aspect-ratio: 13/10) { /* schmal hochkant: Unter-Reiter in zwei Reihen statt gekürzt */
  #tab-clan .cl-seg { flex-wrap: wrap; }
  #tab-clan .cl-seg .btn { flex: 1 1 30%; }
}
@media (min-aspect-ratio: 13/10) {
  /* quer: Unter-Reiter oben, darunter zwei eigenständig scrollende Spalten wie PROFIL */
  #tab-clan.active { grid-template-columns: minmax(0, 1fr); }
  #tab-clan.active:not([data-sub=""]) { grid-template-rows: auto minmax(0, 1fr); align-content: stretch; row-gap: 8px; overflow: hidden; }
  #tab-clan .cl-seg { justify-self: center; width: min(100%, 760px); }
  .cl-body { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); grid-template-rows: minmax(0, 1fr); column-gap: 18px; min-height: 0; align-self: stretch; }
  .cl-l, .cl-r { min-height: 0; max-height: 100%; overflow-y: auto; padding: 2px 6px 8px 2px; }
  .cl-chat .cl-r { overflow: hidden; }
  .cl-chat .ch-log { min-height: 72px; } /* niedrige Höhe: Fehlerhinweis + NEUE NACHRICHTEN dürfen die Eingabe nicht abschneiden */
  .ch-side { display: flex; }
  .ch-in .ch-tg, .ch-drawer { display: none; }
}

/* ---------- Betrieb (OPS-SPEC 6.3): Leiste über dem Menü (im Match schmal), Team-Texte ---------- */
.ops-bar { position: absolute; left: 0; right: 0; top: 0; z-index: 45; display: flex; align-items: center; justify-content: center; gap: 12px; min-height: calc(26px + var(--st)); padding: var(--st) 10px 0; background: var(--navy); color: var(--yellow); border-bottom: 2px solid var(--orange); font-weight: 700; font-size: 12px; white-space: nowrap; overflow: hidden; }
.ops-bar[hidden] { display: none; }
.ops-bar > * { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.ops-bar .ob-m { flex: none; font-variant-numeric: tabular-nums; }
.ops-bar .ob-m.lock, .ops-bar .ob-m.on { color: var(--orange); }
.ops-bar .ob-bc { flex: 0 1 auto; font: inherit; color: #fff; text-decoration: underline dotted; }
.ops-bar .ob-bc.warn { color: var(--red); }
#app.ops-on #scr-lobby { top: 26px; }
#app.ops-on #scr-game { top: 16px; }
#scr-game.active ~ .ops-bar { min-height: calc(16px + var(--st)); font-size: 10px; border-bottom-width: 1px; pointer-events: none; }
.panel .ops-msg { background: var(--paper); border: 2px dashed var(--navy3); border-radius: 10px; padding: 8px 10px; white-space: pre-line; overflow-wrap: anywhere; -webkit-user-select: text; user-select: text; }
.panel .ops-msg.warn { border-color: var(--red); color: #b3122a; }

/* ---------- Konto: Anbieter (OPS-SPEC 6.4) ---------- */
.acc-box .acc-pv.apple { background: #111; color: #fff; }
.acc-box .acc-pv.facebook { background: #1877f2; color: #fff; }

/* ---------- Postfach: Team-Einträge (OPS-SPEC 6.6) ---------- */
.cl-inb .cl-tmsg { white-space: normal; overflow-wrap: anywhere; }

/* ---------- Rechtliches (OPS-SPEC 6.5): Text scrollt im Fenster, Knöpfe bleiben sichtbar ---------- */
.panel.legal { max-width: 480px; }
.panel.legal.page { overflow: hidden; }
.panel .legal-draft { background: var(--yellow); border: 2px solid var(--navy); border-radius: 8px; padding: 4px 8px; font-size: 12px; font-weight: 900; letter-spacing: .5px; text-align: center; }
.legal-list { gap: 0; }
.legal-doc { flex: 1 1 auto; min-height: 0; overflow-y: auto; -webkit-overflow-scrolling: touch; overscroll-behavior: contain; background: var(--paper); border: 2px solid var(--navy); border-radius: 10px; padding: 10px 12px; font-size: 14px; line-height: 1.5; text-align: left; overflow-wrap: anywhere; -webkit-user-select: text; user-select: text; }
.legal-doc.empty { display: flex; align-items: center; justify-content: center; min-height: 90px; }
.panel .legal-doc h1 { font-family: var(--fh); font-weight: 400; font-size: 22px; letter-spacing: .5px; text-align: left; margin: 2px 0 8px; }
.panel .legal-doc h2 { font-family: var(--fb); font-weight: 900; font-size: 16px; letter-spacing: 0; text-align: left; margin: 14px 0 6px; }
.panel .legal-doc h3, .panel .legal-doc h4 { font-size: 14px; font-weight: 900; margin: 10px 0 4px; }
.legal-doc p, .legal-doc ul, .legal-doc ol, .legal-doc table, .legal-doc dl { margin: 0 0 8px; }
.legal-doc ul, .legal-doc ol { padding-inline-start: 20px; }
.legal-doc li { margin: 2px 0; }
.legal-doc a { color: var(--blue); text-decoration: underline; cursor: pointer; }
.legal-doc table { display: block; max-width: 100%; overflow-x: auto; border-collapse: collapse; font-size: 12px; }
.legal-doc th, .legal-doc td { border: 1px solid rgba(27, 35, 64, .25); padding: 4px 6px; text-align: left; vertical-align: top; }
.legal-doc mark.ph { background: var(--yellow); color: var(--navy); border-radius: 3px; padding: 0 2px; font-weight: 700; }
@media (max-height: 500px) {
  .panel.legal { max-height: 98%; gap: 8px; padding: 10px 14px; }
  .panel.legal h2 { font-size: 22px; }
  .panel.legal .lang-row { padding: 4px 2px; }
}

/* ---------- Tutorial (TUTORIAL-SPEC 9): Sprechblase über/neben dem Feld, Ring auf den Touch-Knöpfen ---------- */
.tut-ov { position: absolute; z-index: 2; pointer-events: none; display: flex; justify-content: center; direction: ltr; transition: top .2s; }
.tut-ov[hidden] { display: none; }
.tut-bub { max-width: min(94%, 440px); padding: 7px 12px 8px; background: rgba(15, 20, 40, .92); border: 3px solid var(--yellow); border-radius: 16px; color: #fff; text-align: center; box-shadow: 0 4px 0 #0b0f1f; }
.tut-dots { display: flex; gap: 5px; justify-content: center; margin-bottom: 4px; }
.tut-dots i { width: 8px; height: 8px; border-radius: 50%; background: #3a4570; }
.tut-dots i.done { background: var(--yellow); }
.tut-dots i.on { background: var(--orange); transform: scale(1.35); }
.tut-msg { margin: 0; font-size: 16px; font-weight: 800; line-height: 1.25; unicode-bidi: plaintext; }
.tut-how { margin: 4px 0 0; font-size: 14px; color: var(--yellow); unicode-bidi: plaintext; }
.tut-how span { display: none; }
.tut-ov[data-dev="touch"] .h-touch, .tut-ov[data-dev="keys"] .h-keys, .tut-ov[data-dev="pad"] .h-pad { display: inline; }
.tut-bub.nohow .tut-how { display: none; }
.tut-bub.strong { border-color: var(--orange); animation: tutPulse .8s ease-in-out infinite alternate; }
.tut-bub.mini { padding: 4px 8px; }
.tut-bub.mini .tut-dots, .tut-bub.mini .tut-how { display: none; }
.tut-bub.mini .tut-msg { font-size: 14px; }
.tut-bub.col { max-width: 100%; }
.tut-bub.big .tut-msg { font-size: 18px; }
.tut-bub.big .tut-how { font-size: 15px; }
@keyframes tutPulse { from { transform: scale(1); } to { transform: scale(1.04); } }
.tut-dots .tut-n { margin-inline-start: 6px; font-size: 11px; line-height: 8px; color: #c9cfe6; }
.tut-hl { outline: 4px solid var(--yellow); outline-offset: 4px; animation: tutRing .7s ease-in-out infinite alternate; }
@keyframes tutRing { from { outline-offset: 2px; outline-color: rgba(255, 210, 31, .5); } to { outline-offset: 7px; outline-color: var(--yellow); } }
@media (prefers-reduced-motion: reduce) { .tut-bub.strong, .tut-hl { animation: none; } }
#timer.tut { font-size: 13px; letter-spacing: 1px; }
.chip[hidden] { display: none; } /* Puppe/Trainer erscheinen erst mit ihrem Schritt (.chip setzt sonst display: flex) */
