/* BRANDMAUER – Stylesheet. Cineastischer Nacht-Look: dunkles Glas über der 3D-Szene, Glut-Orange als Akzent.
   Ohne WebGL (html.no3d) zeigt dieselbe Datei die 2D-Mauer. */
@font-face { font-family: 'Familjen Grotesk'; src: url('../fonts/familjen-grotesk-700.woff2') format('woff2'); font-weight: 700; font-display: swap; }
@font-face { font-family: 'Noto Serif'; src: url('../fonts/noto-serif-400.woff2') format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'Noto Serif'; src: url('../fonts/noto-serif-700.woff2') format('woff2'); font-weight: 700; font-display: swap; }
@font-face { font-family: 'Noto Sans Display'; src: url('../fonts/noto-sans-display-400.woff2') format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'Noto Sans Display'; src: url('../fonts/noto-sans-display-700.woff2') format('woff2'); font-weight: 700; font-display: swap; }

:root {
  --bg: #06080c; --bg2: #0c1018; --bg3: #131925;
  --glass: rgba(10, 14, 21, .74); --glass2: rgba(16, 22, 32, .88); --glass3: rgba(255, 255, 255, .05);
  --line: rgba(255, 255, 255, .1); --line2: rgba(255, 255, 255, .2);
  --text: #eef1f5; --text2: #c3cad6; --mute: #8892a4; --dim: #5a6476;
  --accent: #ff7a1a; --accent2: #ffb347; --accent-d: #c24c00; --ember: #ff4a1a; --orange: #ff7a1a;
  --good: #4ee08a; --bad: #ff4a3d; --blue: #4fb8ff; --gold: #ffc24a; --afd: #12a4e6; --bund: #4fb8ff;
  --display: 'Noto Sans Display', 'Arial Narrow', system-ui, sans-serif;
  --num: 'Familjen Grotesk', 'Noto Sans Display', system-ui, sans-serif;
  --serif: 'Noto Serif', Georgia, serif;
  --ui: 'Noto Sans Display', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --cut: 12px; --cut-s: 7px;
  --chamfer: polygon(var(--cut) 0, 100% 0, 100% calc(100% - var(--cut)), calc(100% - var(--cut)) 100%, 0 100%, 0 var(--cut));
  --chamfer-s: polygon(var(--cut-s) 0, 100% 0, 100% calc(100% - var(--cut-s)), calc(100% - var(--cut-s)) 100%, 0 100%, 0 var(--cut-s));
  --safe-b: env(safe-area-inset-bottom, 0px);
  --wallh: clamp(190px, 36dvh, 380px);
  --shadow: 0 18px 50px rgba(0, 0, 0, .55);
  --blur: none;
  color-scheme: dark;
}
@media (pointer: fine) { :root { --blur: blur(14px) saturate(1.2); } }
/* Im Spiel kein Weichzeichner hinter Glasflächen: Die 3D-Szene bewegt sich jedes Frame, der Blur wäre sehr teuer */
html.has3d[data-screen="game"] { --blur: none; --glass: rgba(9, 12, 18, .84); --glass2: rgba(12, 16, 24, .93); }
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; min-height: 100%; }
body { background: var(--bg); color: var(--text); font-family: var(--ui); font-size: 16px; line-height: 1.45; overflow-x: hidden; -webkit-font-smoothing: antialiased; touch-action: manipulation; }
button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; padding: 0; }
input { font: inherit; }
a { color: var(--accent2); }
h1, h2, h3 { font-family: var(--display); font-weight: 700; margin: 0; letter-spacing: .02em; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--accent2); outline-offset: 3px; }
::selection { background: var(--accent); color: #000; }

/* ───────── Bühne: 3D-Szene hinter allem ───────── */
#scene { position: fixed; inset: 0; width: 100vw; height: 100vh; z-index: 0; display: block; }
#scene-fx { position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background:
    radial-gradient(ellipse 120% 90% at 50% 45%, transparent 52%, rgba(0, 0, 0, .62) 100%),
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 1  0 0 0 0 1  0 0 0 0 1  0 0 0 .05 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>"); }
#scene-fx::after { content: ''; position: absolute; inset: 0; transition: opacity .8s; opacity: 0; }
html.has3d[data-screen="home"] #scene-fx::after, html.has3d[data-screen="lobby"] #scene-fx::after, html.has3d[data-screen="results"] #scene-fx::after { opacity: 1; }
html.has3d[data-screen="home"] #scene-fx::after { background: linear-gradient(90deg, rgba(5, 7, 11, .9) 0%, rgba(5, 7, 11, .62) 34%, rgba(5, 7, 11, 0) 56%); }
html.has3d[data-screen="lobby"] #scene-fx::after { background: rgba(5, 7, 11, .62); }
html.has3d[data-screen="results"] #scene-fx::after { background: linear-gradient(270deg, rgba(5, 7, 11, .9) 0%, rgba(5, 7, 11, .55) 48%, rgba(5, 7, 11, .1) 70%); }
@media (max-width: 899px) {
  html.has3d[data-screen="home"] #scene-fx::after { background: linear-gradient(180deg, rgba(5, 7, 11, 0) 0%, rgba(5, 7, 11, .25) 30%, rgba(5, 7, 11, .88) 50%, rgba(5, 7, 11, .96) 100%); }
  html.has3d[data-screen="results"] #scene-fx::after { background: linear-gradient(180deg, rgba(5, 7, 11, 0) 0%, rgba(5, 7, 11, .6) 30%, rgba(5, 7, 11, .94) 46%); }
}
#app { position: relative; z-index: 2; }
html.has3d body { background: #000; }
html.has3d #bg { display: none; }
html:not(.has3d) #scene { display: none; }

/* 2D-Fallback-Hintergrund */
#bg { position: fixed; inset: 0; z-index: 0; background: radial-gradient(120% 80% at 50% -10%, #2a1a26 0%, #0b0f17 55%, var(--bg) 100%); overflow: hidden; }
#bg .orb { position: absolute; border-radius: 50%; filter: blur(80px); opacity: .45; }
#bg .o1 { width: 46vw; height: 46vw; left: -14vw; top: 40%; background: #6a2410; animation: drift 22s ease-in-out infinite alternate; }
#bg .o2 { width: 40vw; height: 40vw; right: -10vw; top: -8vw; background: #10305a; animation: drift 28s ease-in-out infinite alternate-reverse; }
#bg .stars { position: absolute; inset: 0; opacity: .7; background-image:
  radial-gradient(1.5px 1.5px at 12% 18%, #fff8 50%, transparent 51%), radial-gradient(1px 1px at 33% 8%, #fff7 50%, transparent 51%),
  radial-gradient(1.5px 1.5px at 62% 14%, #fff9 50%, transparent 51%), radial-gradient(1px 1px at 81% 26%, #fff7 50%, transparent 51%),
  radial-gradient(1px 1px at 91% 7%, #fff8 50%, transparent 51%), radial-gradient(1.5px 1.5px at 47% 30%, #fff6 50%, transparent 51%); }
@keyframes drift { to { transform: translate3d(6vw, 4vh, 0) scale(1.1); } }

/* ───────── Grundbausteine ───────── */
.screen { display: none; min-height: 100dvh; width: 100%; max-width: 1240px; margin: 0 auto; padding: 0 20px calc(24px + var(--safe-b)); }
.screen.active { display: block; animation: screenin .5s cubic-bezier(.2, .8, .2, 1); }
@keyframes screenin { from { opacity: 0; transform: translateY(10px); } }

.topbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 0; position: relative; z-index: 5; }
.brand { display: flex; align-items: center; gap: 8px; text-decoration: none; color: var(--text); opacity: .85; transition: opacity .2s; }
.brand:hover { opacity: 1; }
.brand .by { font-size: 11px; color: var(--mute); text-transform: uppercase; letter-spacing: .14em; }
.brand .wm { height: 14px; width: auto; }
.top-actions { display: flex; align-items: center; gap: 8px; }
.online { display: inline-flex; align-items: center; gap: 7px; font-size: 11px; color: var(--mute); text-transform: uppercase; letter-spacing: .12em; padding: 7px 11px; background: var(--glass); border: 1px solid var(--line); clip-path: var(--chamfer-s); }
.online i { width: 7px; height: 7px; border-radius: 50%; background: var(--good); box-shadow: 0 0 10px var(--good); animation: blink 2s infinite; }
.online b { color: var(--text); font-family: var(--num); font-size: 13px; letter-spacing: 0; }
@keyframes blink { 50% { opacity: .4; } }
.icon-btn { min-width: 40px; height: 40px; padding: 0 8px; display: inline-flex; align-items: center; justify-content: center; gap: 6px; font-size: 17px; color: var(--text);
  background: var(--glass); border: 1px solid var(--line); clip-path: var(--chamfer-s); backdrop-filter: var(--blur); transition: background .2s, border-color .2s, transform .12s; }
.icon-btn:hover { background: rgba(255, 122, 26, .14); border-color: rgba(255, 122, 26, .5); }
.icon-btn:active { transform: scale(.94); }
.gfx-btn { font-size: 11px; text-transform: uppercase; letter-spacing: .12em; font-weight: 700; color: var(--text2); }
.gfx-btn .gfx-ico { color: var(--accent); font-size: 10px; }

/* Schaltflächen */
.btn { position: relative; display: inline-flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; min-height: 48px; padding: 10px 20px;
  font-family: var(--display); font-weight: 700; font-size: 15px; letter-spacing: .1em; text-transform: uppercase; text-align: center; color: var(--text);
  clip-path: var(--chamfer); transition: transform .15s cubic-bezier(.2, .8, .2, 1), filter .2s, background .2s, color .2s; overflow: hidden; isolation: isolate; }
.btn small { font-family: var(--ui); font-weight: 400; font-size: 12px; letter-spacing: .02em; text-transform: none; opacity: .82; }
.btn::after { content: ''; position: absolute; inset: 0; z-index: -1; background: linear-gradient(105deg, transparent 30%, rgba(255, 255, 255, .28) 48%, transparent 66%); transform: translateX(-120%); transition: transform .6s ease; }
.btn:hover::after { transform: translateX(120%); }
.btn:active { transform: scale(.98); }
.btn.big { min-height: 66px; width: 100%; font-size: 19px; align-items: flex-start; padding: 12px 22px; text-align: left; }
.btn.big span { display: flex; align-items: center; gap: 10px; }
.btn.big span::after { content: '›'; font-size: 26px; line-height: .6; opacity: .7; transition: transform .2s; }
.btn.big:hover span::after { transform: translateX(5px); }
.btn.small { min-height: 34px; padding: 6px 12px; font-size: 12.5px; --cut: 7px; }
.btn.primary { color: #1a0a00; background: linear-gradient(180deg, #ffa24a 0%, var(--accent) 45%, #e65a00 100%); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .5), inset 0 -3px 0 rgba(0, 0, 0, .2); }
.btn.primary small { color: #3a1600; opacity: .9; }
.btn.primary:hover { filter: brightness(1.1) saturate(1.1); }
.btn.secondary { background: linear-gradient(180deg, rgba(40, 52, 72, .92), rgba(20, 28, 42, .92)); box-shadow: inset 3px 0 0 var(--accent), inset 0 0 0 1px var(--line2); }
.btn.secondary:hover { background: linear-gradient(180deg, rgba(56, 70, 94, .95), rgba(28, 38, 56, .95)); }
.btn.ghost { background: var(--glass); box-shadow: inset 0 0 0 1px var(--line2); backdrop-filter: var(--blur); }
.btn.ghost:hover { background: rgba(255, 255, 255, .1); }
.btn[disabled] { opacity: .45; pointer-events: none; }
.linkbtn { color: var(--text2); font-family: var(--display); font-size: 12.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .12em; padding: 10px 12px; position: relative; transition: color .2s; }
.linkbtn::after { content: ''; position: absolute; left: 12px; right: 12px; bottom: 6px; height: 1px; background: var(--accent); transform: scaleX(0); transform-origin: left; transition: transform .25s; }
.linkbtn:hover { color: #fff; } .linkbtn:hover::after { transform: scaleX(1); }

.card { position: relative; background: var(--glass); border: 1px solid var(--line); clip-path: var(--chamfer); padding: 16px; backdrop-filter: var(--blur); }
.hint { color: var(--mute); font-size: 13px; margin: 8px 0 0; }
input[type=text] { flex: 1; min-width: 0; background: rgba(0, 0, 0, .45); color: #fff; border: 1px solid var(--line2); padding: 12px 14px; font-size: 17px; font-family: var(--display); font-weight: 700; letter-spacing: .04em; outline: none;
  clip-path: var(--chamfer-s); transition: border-color .2s, background .2s; }
input[type=text]:focus { border-color: var(--accent); background: rgba(255, 122, 26, .08); }
input::placeholder { color: var(--dim); font-weight: 400; }

/* ───────── Startseite / Hauptmenü ───────── */
#screen-home { max-width: 1320px; }
.hero { display: grid; gap: 22px; padding-bottom: 8px; }
.hero-l, .hero-r { display: grid; gap: 18px; align-content: start; }
.title-block { display: grid; gap: 10px; }
.kicker { margin: 0; font-family: var(--display); font-weight: 700; text-transform: uppercase; letter-spacing: .26em; font-size: 11.5px; color: var(--text2); display: flex; align-items: center; gap: 10px; }
.kicker::before { content: ''; width: 28px; height: 2px; background: var(--accent); box-shadow: 0 0 12px var(--accent); flex: none; }
.kicker span { color: var(--accent2); }
h1 { position: relative; font-size: clamp(54px, 15vw, 132px); line-height: .86; letter-spacing: -.01em; text-transform: uppercase; font-weight: 700;
  background: linear-gradient(100deg, transparent 42%, rgba(255, 255, 255, .85) 50%, transparent 58%) 150% 0 / 250% 100% no-repeat, linear-gradient(178deg, #ffffff 0%, #e9ecf1 38%, #9aa1ad 62%, #d8dce3 78%, #6f7682 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 4px 0 rgba(0, 0, 0, .35)) drop-shadow(0 0 34px rgba(255, 106, 26, .28)); }
.lead { font-family: var(--serif); font-size: 17px; color: var(--text2); margin: 4px 0 0; max-width: 470px; }
.lead strong { color: #fff; font-weight: 700; }
.menu { display: grid; gap: 12px; max-width: 470px; }
.name-card { display: grid; gap: 6px; }
.name-card label { font-family: var(--display); font-weight: 700; font-size: 11px; text-transform: uppercase; letter-spacing: .2em; color: var(--mute); display: flex; justify-content: space-between; gap: 8px; }
.name-card label small { font-family: var(--ui); font-weight: 400; text-transform: none; letter-spacing: 0; color: var(--dim); font-size: 11.5px; }
.name-row, .friends-row { display: flex; gap: 8px; }
.cta { display: grid; gap: 10px; }
.daily { display: flex; align-items: center; gap: 14px; text-align: left; width: 100%; padding: 13px 16px; color: var(--text);
  background: linear-gradient(90deg, rgba(255, 194, 74, .16), rgba(255, 122, 26, .05) 70%), var(--glass); box-shadow: inset 0 0 0 1px rgba(255, 194, 74, .35); clip-path: var(--chamfer); backdrop-filter: var(--blur); transition: filter .2s, transform .15s; }
.daily:hover { filter: brightness(1.18); } .daily:active { transform: scale(.99); }
.daily .d-ico { font-size: 22px; color: var(--gold); text-shadow: 0 0 14px var(--gold); }
.daily .d-txt { flex: 1; display: grid; gap: 1px; }
.daily .d-txt b { font-family: var(--display); font-size: 15px; text-transform: uppercase; letter-spacing: .1em; }
.daily .d-txt small { color: var(--text2); font-size: 12.5px; }
.daily .d-go { font-family: var(--display); font-weight: 700; font-size: 12px; text-transform: uppercase; letter-spacing: .12em; color: var(--gold); white-space: nowrap; }
.daily.done .d-go { color: var(--good); }
.friends { padding: 14px 16px; background: var(--glass); box-shadow: inset 0 0 0 1px var(--line); clip-path: var(--chamfer); backdrop-filter: var(--blur); }
.friends-head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; margin-bottom: 10px; }
.friends-head b { font-family: var(--display); font-size: 13px; text-transform: uppercase; letter-spacing: .14em; }
.friends-head small { color: var(--mute); font-size: 12px; }
.friends-row { flex-wrap: wrap; }
.friends-row .btn { flex: 1; }
.join { display: flex; gap: 8px; flex: 1.4; min-width: 220px; }
.join input { width: 96px; text-align: center; letter-spacing: .3em; text-transform: uppercase; }
.links { display: flex; flex-wrap: wrap; gap: 2px; margin-left: -12px; }
.steps3 { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.steps3 li { display: grid; gap: 2px; align-content: start; padding: 12px; background: var(--glass); box-shadow: inset 0 0 0 1px var(--line); clip-path: var(--chamfer-s); backdrop-filter: var(--blur); }
.steps3 i { font-style: normal; font-family: var(--num); font-size: 22px; line-height: 1; color: var(--accent); }
.steps3 b { font-family: var(--display); font-size: 12.5px; text-transform: uppercase; letter-spacing: .08em; line-height: 1.15; }
.steps3 small { font-size: 11.5px; color: var(--mute); line-height: 1.25; }
.weekly { display: grid; gap: 8px; }
.wk-head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.wk-head b { font-family: var(--display); font-size: 13px; text-transform: uppercase; letter-spacing: .14em; white-space: nowrap; }
.wk-head small { color: var(--mute); font-size: 12px; }
.wk-bar { display: flex; height: 10px; overflow: hidden; background: rgba(255, 255, 255, .07); clip-path: polygon(4px 0, 100% 0, calc(100% - 4px) 100%, 0 100%); }
.wk-bar i { display: block; height: 100%; transition: width .8s ease; }
.wk-dem { background: linear-gradient(90deg, #2fa865, var(--good)); box-shadow: 0 0 12px rgba(78, 224, 138, .6); }
.wk-afd { background: linear-gradient(90deg, #0d7fb5, var(--afd)); }
.wk-foot { display: flex; justify-content: space-between; gap: 6px; font-size: 12px; color: var(--mute); }
.wk-foot span:nth-child(2) { color: var(--gold); text-align: center; }
.plot-teaser h2 { font-size: 13px; text-transform: uppercase; letter-spacing: .18em; color: var(--accent2); margin-bottom: 6px; }
.plot-teaser p { margin: 0; font-family: var(--serif); color: var(--text2); font-size: 14.5px; }
.foot { margin: 34px 0 0; color: var(--dim); font-size: 11.5px; max-width: 640px; }
.foot p { margin: 4px 0; }
.foot a { color: var(--mute); }

@media (min-width: 900px) {
  .hero { grid-template-columns: minmax(0, 500px) minmax(0, 1fr); gap: 40px; min-height: calc(100dvh - 170px); padding-top: 3vh; }
  .hero-r { align-self: end; justify-self: end; width: min(100%, 520px); }
}
@media (max-width: 899px) {
  html.has3d #screen-home .hero-l { padding-top: 30dvh; }
  h1 { font-size: clamp(50px, 16vw, 92px); }
  .hero-r { max-width: 470px; }
}
@media (prefers-reduced-motion: no-preference) {
  #screen-home h1 { animation: sheen 7s ease-in-out 1.2s infinite; }
  .title-block > * { animation: rise .9s cubic-bezier(.2, .8, .2, 1) backwards; }
  .title-block > :nth-child(2) { animation-delay: .08s; } .title-block > :nth-child(3) { animation-delay: .16s; }
  .menu > * { animation: rise .8s cubic-bezier(.2, .8, .2, 1) backwards; }
  .menu > :nth-child(1) { animation-delay: .2s; } .menu > :nth-child(2) { animation-delay: .26s; } .menu > :nth-child(3) { animation-delay: .32s; }
  .menu > :nth-child(4) { animation-delay: .38s; } .menu > :nth-child(5) { animation-delay: .44s; }
}
@keyframes sheen { 0%, 70% { background-position: 150% 0, 0 0; } 100% { background-position: -50% 0, 0 0; } }
@keyframes rise { from { opacity: 0; transform: translateY(16px); } }

/* ───────── Lobby ───────── */
.room-code { display: flex; align-items: center; gap: 10px; }
.room-code .lbl { color: var(--mute); font-size: 11px; text-transform: uppercase; letter-spacing: .2em; }
.room-code b { font-family: var(--num); font-size: 26px; letter-spacing: .16em; color: #fff; text-shadow: 0 0 18px rgba(255, 122, 26, .5); }
.lobby-grid { display: grid; gap: 20px; grid-template-columns: 1fr; }
@media (min-width: 900px) { .lobby-grid { grid-template-columns: 1fr 360px; align-items: start; } .lobby-side { position: sticky; top: 12px; } }
.h-step { font-size: 20px; text-transform: uppercase; letter-spacing: .12em; margin: 6px 0 14px; display: flex; align-items: center; gap: 12px; }
.h-step span { font-family: var(--num); width: 34px; height: 34px; display: inline-grid; place-items: center; background: var(--accent); color: #1a0a00; font-size: 17px; clip-path: var(--chamfer-s); }
.team-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
@media (min-width: 560px) { .team-grid { grid-template-columns: repeat(3, 1fr); } }
.team-card { position: relative; text-align: left; padding: 14px; display: grid; gap: 9px; align-content: start; overflow: hidden; color: var(--text); clip-path: var(--chamfer);
  background: linear-gradient(160deg, color-mix(in srgb, var(--c) 30%, transparent) 0%, transparent 55%), var(--glass2); box-shadow: inset 0 0 0 1px var(--line), inset 4px 0 0 var(--c);
  backdrop-filter: var(--blur); transition: transform .2s cubic-bezier(.2, .8, .2, 1), box-shadow .2s, filter .2s; }
.team-card::after { content: ''; position: absolute; right: -30px; top: -30px; width: 120px; height: 120px; background: radial-gradient(circle, color-mix(in srgb, var(--c) 45%, transparent), transparent 70%); opacity: .5; pointer-events: none; transition: opacity .3s; }
.team-card:hover { transform: translateY(-3px); filter: brightness(1.12); }
.team-card:hover::after { opacity: .9; }
.team-card.mine { box-shadow: inset 0 0 0 2px var(--c), inset 4px 0 0 var(--c); filter: brightness(1.15); }
.team-card.mine .nm::after { content: 'Deine Seite'; display: block; margin-top: 4px; font-family: var(--ui); font-size: 10px; letter-spacing: .18em; color: var(--accent2); }
.team-card.full { opacity: .45; }
.team-card .top { display: flex; align-items: center; gap: 12px; position: relative; }
.team-card .nm { font-family: var(--display); font-size: 17px; line-height: 1.05; text-transform: uppercase; letter-spacing: .06em; }
.team-card .tg { font-size: 12px; color: var(--mute); }
.team-card .sp { position: relative; font-size: 12px; color: var(--text2); background: rgba(0, 0, 0, .35); padding: 7px 9px; clip-path: var(--chamfer-s); }
.team-card .sp b { color: var(--gold); display: block; font-family: var(--display); font-size: 12px; text-transform: uppercase; letter-spacing: .08em; }
.team-card .members { position: relative; display: flex; flex-wrap: wrap; gap: 4px; min-height: 22px; }
.team-card.afd { grid-column: 1 / -1; --c: var(--afd); background: linear-gradient(110deg, rgba(18, 164, 230, .22), rgba(255, 74, 61, .14) 60%, transparent), var(--glass2); }
@media (min-width: 560px) { .team-card.afd { grid-column: span 3; } }
.chip { font-size: 11.5px; background: rgba(0, 0, 0, .45); padding: 2px 8px; border: 1px solid var(--line); white-space: nowrap; max-width: 100%; overflow: hidden; text-overflow: ellipsis; }
.chip.bot { opacity: .55; border-style: dashed; }
.chip.me { background: var(--accent); color: #1a0a00; border-color: transparent; font-weight: 700; }
.afd-roles { display: grid; gap: 8px; margin-top: 10px; grid-template-columns: 1fr 1fr; }
.role { text-align: left; padding: 12px; display: grid; gap: 3px; color: var(--text); background: var(--glass2); box-shadow: inset 0 0 0 1px var(--line); clip-path: var(--chamfer); transition: box-shadow .2s; }
.role.on { box-shadow: inset 0 0 0 2px var(--afd), inset 0 0 30px rgba(18, 164, 230, .2); }
.role b { font-family: var(--display); text-transform: uppercase; letter-spacing: .08em; }
.role span { font-size: 12px; color: var(--mute); }
.role em { font-style: normal; font-size: 12px; color: var(--gold); }

/* Emblem (Schild mit Kürzel) */
.emb { --s: 40px; flex: none; width: var(--s); height: calc(var(--s) * 1.12); display: inline-grid; place-items: center; font-family: var(--display); font-weight: 700; font-size: calc(var(--s) * .29); color: var(--ink-c, #fff);
  background: linear-gradient(160deg, color-mix(in srgb, var(--c) 100%, #fff 22%), var(--c) 55%, color-mix(in srgb, var(--c) 70%, #000)); clip-path: polygon(50% 0, 100% 12%, 100% 60%, 50% 100%, 0 60%, 0 12%);
  letter-spacing: -.01em; padding-bottom: 7%; }
.emb.sm { --s: 24px; } .emb.lg { --s: 52px; }
.emb.afd { background: linear-gradient(160deg, #5fd0ff, var(--afd) 55%, #075f8a); color: #fff; }

.player-list { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 5px; }
.player-list li { display: flex; align-items: center; gap: 9px; padding: 7px 9px; background: rgba(0, 0, 0, .3); font-size: 14px; clip-path: var(--chamfer-s); }
.player-list li .nm { flex: 1; font-family: var(--display); font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.player-list li .tag { font-size: 11px; color: var(--mute); }
.player-list li .rd { color: var(--good); }
.player-list li.me { box-shadow: inset 2px 0 0 var(--accent); }
.player-list li.me .nm::after { content: ' (du)'; color: var(--mute); font-weight: 400; font-size: 12px; }
.seg { display: inline-flex; padding: 3px; background: rgba(0, 0, 0, .45); border: 1px solid var(--line); gap: 2px; flex-wrap: wrap; clip-path: var(--chamfer-s); }
.seg button { padding: 7px 12px; font-family: var(--display); font-weight: 700; font-size: 12px; text-transform: uppercase; letter-spacing: .08em; color: var(--mute); transition: color .2s, background .2s; clip-path: var(--chamfer-s); }
.seg button:hover { color: #fff; }
.seg button.on { background: var(--accent); color: #1a0a00; }
.seg button[disabled] { opacity: .5; cursor: default; }
.lobby-side { display: grid; gap: 12px; }
.lobby-side h3 { font-size: 13px; text-transform: uppercase; letter-spacing: .16em; }
.lobby-start { display: grid; gap: 8px; }
.lobby-start .btn.big { align-items: center; text-align: center; }
.countdown { text-align: center; font-family: var(--display); font-size: 12px; text-transform: uppercase; letter-spacing: .2em; color: var(--mute); }
.countdown b { display: block; font-family: var(--num); font-size: 56px; color: #fff; line-height: 1; text-shadow: 0 0 30px var(--accent); letter-spacing: 0; }
.qr-card h3 { margin-bottom: 8px; }
.qr-wrap { display: flex; gap: 12px; align-items: center; }
#qr { width: 118px; height: 118px; flex: none; overflow: hidden; background: #fff; padding: 0; clip-path: var(--chamfer-s); }
#qr svg { display: block; width: 100%; height: 100%; }
.qr-txt { display: grid; gap: 6px; justify-items: start; }
.qr-code { font-family: var(--num); font-size: 26px; letter-spacing: .16em; }
@media (max-width: 899px) { .lobby-start { position: sticky; bottom: 0; padding: 12px 0 calc(8px + var(--safe-b)); background: linear-gradient(180deg, transparent, rgba(6, 8, 12, .96) 30%); z-index: 8; } }

/* ───────── Spiel ───────── */
#screen-game { max-width: 1240px; padding: 0 10px calc(6px + var(--safe-b)); }
#stage { position: relative; min-height: 100dvh; display: flex; flex-direction: column; gap: 6px; padding-top: 10px; }
#stage.shake { animation: shake .35s; }
@keyframes shake { 20% { transform: translate(-5px, 2px); } 40% { transform: translate(5px, -2px); } 60% { transform: translate(-3px, 1px); } 80% { transform: translate(3px, -1px); } }

.hud { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); align-items: start; gap: 8px; position: relative; z-index: 6; }
.hud-l { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; min-width: 0; padding: 6px 14px 7px 12px; background: var(--glass); box-shadow: inset 0 0 0 1px var(--line), inset 3px 0 0 var(--accent); clip-path: var(--chamfer); backdrop-filter: var(--blur); justify-self: start; max-width: 100%; }
.clock { font-family: var(--num); font-size: 34px; line-height: 1; font-variant-numeric: tabular-nums; color: #fff; text-shadow: 0 0 18px rgba(255, 255, 255, .25); }
.clock.low { color: var(--bad); text-shadow: 0 0 20px var(--bad); animation: pulse 1s infinite; }
.act { font-family: var(--display); font-weight: 700; font-size: 10px; color: var(--accent2); text-transform: uppercase; letter-spacing: .16em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.hud-r { display: flex; justify-content: flex-end; align-items: center; gap: 6px; }
.hud-r .icon-btn { min-width: 36px; height: 36px; font-size: 15px; }
.poll { text-align: right; line-height: 1.1; padding: 5px 12px; background: var(--glass); box-shadow: inset 0 0 0 1px var(--line), inset -3px 0 0 var(--afd); clip-path: var(--chamfer-s); backdrop-filter: var(--blur); }
.poll span { display: block; font-family: var(--display); font-weight: 700; font-size: 9px; color: var(--mute); text-transform: uppercase; letter-spacing: .16em; }
.poll b { font-family: var(--num); font-size: 21px; color: #6fd2ff; font-variant-numeric: tabular-nums; text-shadow: 0 0 14px rgba(18, 164, 230, .6); }
#breach { display: flex; gap: 5px; align-items: center; padding: 8px 12px; background: var(--glass); box-shadow: inset 0 0 0 1px var(--line); clip-path: var(--chamfer-s); backdrop-filter: var(--blur); }
#breach .lbl { font-family: var(--display); font-weight: 700; font-size: 9.5px; text-transform: uppercase; letter-spacing: .18em; color: var(--mute); margin-right: 4px; }
#breach i { width: 18px; height: 14px; background: rgba(255, 255, 255, .1); transform: skewX(-18deg); transition: all .35s cubic-bezier(.2, 1.6, .4, 1); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .16); }
#breach i.on { background: linear-gradient(180deg, #ff7a5a, var(--bad)); box-shadow: 0 0 14px var(--bad), inset 0 0 0 1px rgba(255, 255, 255, .3); transform: skewX(-18deg) scale(1.18); }
@media (max-width: 420px) { #breach .lbl { display: none; } #breach { padding: 7px 8px; gap: 4px; } #breach i { width: 13px; } .poll span { font-size: 8px; } .poll b { font-size: 17px; } .hud-r { gap: 4px; } .clock { font-size: 28px; } .hud-l { padding: 5px 10px 6px 9px; } }

/* Filmische Einblendung */
.banner { position: absolute; left: 50%; top: 70px; transform: translateX(-50%); z-index: 20; width: min(96%, 640px); padding: 12px 24px 13px; text-align: center; pointer-events: none;
  font-family: var(--display); font-weight: 700; font-size: clamp(18px, 3.4vw, 26px); text-transform: uppercase; letter-spacing: .16em; color: #fff; text-shadow: 0 2px 20px rgba(0, 0, 0, .8);
  background: linear-gradient(90deg, transparent, rgba(6, 8, 12, .88) 18%, rgba(6, 8, 12, .88) 82%, transparent); animation: bannerIn .55s cubic-bezier(.2, .8, .2, 1); }
.banner::before, .banner::after { content: ''; position: absolute; left: 10%; right: 10%; height: 1px; background: linear-gradient(90deg, transparent, var(--accent), transparent); }
.banner::before { top: 0; } .banner::after { bottom: 0; }
.banner small { display: block; font-family: var(--ui); font-weight: 400; font-size: 13.5px; letter-spacing: .02em; text-transform: none; color: var(--text2); margin-top: 3px; }
.banner small.src { margin-top: 4px; font-style: italic; color: var(--mute); font-size: 11.5px; }
.banner.good::before, .banner.good::after { background: linear-gradient(90deg, transparent, var(--good), transparent); }
.banner.bad { color: #ffd6d0; } .banner.bad::before, .banner.bad::after { background: linear-gradient(90deg, transparent, var(--bad), transparent); }
@keyframes bannerIn { from { opacity: 0; letter-spacing: .5em; filter: blur(6px); } }

/* Mauer (2D-Grundlage; im 3D-Modus nur Klickflächen und Beschriftung) */
.wall-wrap { position: relative; flex: none; padding: 26px 0 0; }
.wall { max-width: 840px; margin: 0 auto; display: grid; grid-template-columns: repeat(7, 1fr); gap: clamp(4px, 1.2vw, 12px); align-items: end; position: relative; z-index: 2; }
.ground { max-width: 880px; margin: -2px auto 0; height: 10px; background: linear-gradient(180deg, #2a2420, #120e0c); box-shadow: 0 18px 40px rgba(0, 0, 0, .6), 0 -1px 0 rgba(255, 122, 26, .4); position: relative; z-index: 1; }
.col { position: relative; display: flex; flex-direction: column; align-items: stretch; cursor: pointer; user-select: none; -webkit-user-select: none; min-width: 0; }
.col-top { height: 62px; position: relative; display: flex; flex-direction: column-reverse; align-items: center; justify-content: flex-start; gap: 2px; }
.pillar { position: relative; height: var(--wallh); background: rgba(255, 255, 255, .03); border: 1px dashed rgba(255, 255, 255, .14); border-bottom: 0; transition: box-shadow .25s, transform .15s; }
.col:hover .pillar { transform: translateY(-2px); }
.col.sel .pillar { box-shadow: 0 0 0 2px var(--accent), 0 0 28px rgba(255, 122, 26, .45); }
.fill { position: absolute; left: 0; right: 0; bottom: 0; background-color: var(--fill, #9fb4c7); background-image: var(--bricks), linear-gradient(90deg, rgba(255, 255, 255, .18), transparent 30%, transparent 70%, rgba(0, 0, 0, .3));
  background-size: 100% 26px, auto; background-blend-mode: multiply, normal; transition: background-color .3s; }
.fill::before { content: ''; position: absolute; left: -2px; right: -2px; top: -3px; height: 5px; background: var(--accent); box-shadow: 0 0 16px var(--accent), 0 0 4px #fff; }
.fill::after { content: ''; position: absolute; inset: 0; background: var(--crack) center bottom/100% 100% no-repeat; opacity: var(--crackop, 0); mix-blend-mode: multiply; pointer-events: none; }
.col.fallen .fill { filter: grayscale(.9) brightness(.6); }
.col.fallen .fill::before { background: #6b6560; box-shadow: none; }
.rebuild-line { display: none; position: absolute; left: -4px; right: -4px; border-top: 2px dashed rgba(255, 210, 160, .6); pointer-events: none; }
.rebuild-line::after { content: 'Aufbau'; position: absolute; right: 2px; top: -15px; font-size: 9px; color: rgba(255, 210, 160, .8); text-transform: uppercase; letter-spacing: .1em; }
.col.fallen .rebuild-line { display: block; }
.col .glow { position: absolute; inset: -6px; pointer-events: none; opacity: 0; transition: opacity .25s; }
.col.shield .glow { opacity: 1; box-shadow: 0 0 0 2px rgba(79, 184, 255, .9), 0 0 30px rgba(79, 184, 255, .8), inset 0 0 28px rgba(79, 184, 255, .35); animation: pulse 1.2s infinite; }
.col.invuln .glow { opacity: 1; box-shadow: 0 0 0 2px rgba(255, 194, 74, .95), 0 0 36px rgba(255, 194, 74, .9), inset 0 0 28px rgba(255, 194, 74, .4); animation: pulse .9s infinite; }
.col.immune .pillar { box-shadow: 0 0 0 2px rgba(78, 224, 138, .6); }
@keyframes pulse { 50% { opacity: .55; } }
.col-label { margin-top: 6px; text-align: center; display: grid; gap: 1px; justify-items: center; min-height: 54px; pointer-events: none; }
.col-label .ico { font-size: clamp(16px, 4vw, 24px); line-height: 1; filter: drop-shadow(0 2px 4px rgba(0, 0, 0, .7)); }
.col-label .nm { font-size: clamp(8px, 2vw, 10.5px); font-family: var(--display); font-weight: 700; text-transform: uppercase; letter-spacing: .06em; line-height: 1.05; color: var(--text2); overflow-wrap: anywhere; hyphens: auto; text-shadow: 0 1px 6px #000, 0 0 2px #000; }
.col-label .val { font-family: var(--num); font-size: clamp(13px, 3vw, 17px); font-variant-numeric: tabular-nums; color: #fff; text-shadow: 0 0 10px rgba(0, 0, 0, .9), 0 0 2px #000; }
.col.fallen .col-label .nm { text-decoration: line-through; opacity: .6; }
.col.fallen .col-label .val { color: var(--bad); }
.col .home { position: absolute; left: 50%; transform: translateX(-50%); bottom: -8px; z-index: 3; font-size: 11px; pointer-events: none; }
.col .home .emb { --s: 18px; }

/* Angriffe: Zielkreis mit Countdown */
.atk { position: relative; width: clamp(36px, 8.5vw, 50px); height: clamp(36px, 8.5vw, 50px); border-radius: 50%; display: grid; place-items: center; flex: none;
  font-family: var(--num); font-size: clamp(11px, 2.8vw, 14px); color: #fff; background: radial-gradient(circle at 35% 30%, #ff8a7a, #b8241c); box-shadow: 0 0 22px rgba(255, 74, 61, .85); animation: shakeb .35s infinite; }
.atk::before { content: ''; position: absolute; inset: -5px; border-radius: 50%; background: conic-gradient(var(--gold) calc(var(--p, 0) * 1turn), rgba(255, 255, 255, .15) 0);
  -webkit-mask: radial-gradient(circle, transparent 62%, #000 64%); mask: radial-gradient(circle, transparent 62%, #000 64%); }
.atk .shieldn { position: absolute; right: -6px; bottom: -6px; min-width: 18px; height: 18px; border-radius: 9px; background: var(--blue); color: #04121e; font-size: 11px; display: grid; place-items: center; padding: 0 4px; font-family: var(--num); }
.atk.can { cursor: pointer; }
.atk.can::after { content: '🗣️'; position: absolute; top: -9px; left: -9px; font-size: 14px; }
@keyframes shakeb { 25% { transform: translate(-1.5px, 1px) rotate(-3deg); } 75% { transform: translate(1.5px, -1px) rotate(3deg); } }
.fakes { display: flex; gap: 1px; font-size: clamp(14px, 3.6vw, 20px); filter: drop-shadow(0 0 8px rgba(180, 107, 255, .9)); animation: bob 1.4s ease-in-out infinite; cursor: pointer; }
@keyframes bob { 50% { transform: translateY(-3px); } }
.dm { position: absolute; left: 50%; bottom: 40%; transform: translateX(-50%); font-family: var(--num); font-size: 24px; pointer-events: none; z-index: 8; white-space: nowrap; font-style: italic;
  text-shadow: 0 2px 0 #000, 0 0 14px rgba(0, 0, 0, .9); animation: floatup 1.1s cubic-bezier(.2, .8, .2, 1) forwards; }
.dm.hit { color: #ff5a4a; font-size: 32px; } .dm.heal { color: var(--good); } .dm.fx { color: var(--gold); font-size: 15px; font-family: var(--display); font-weight: 700; letter-spacing: .08em; font-style: normal; } .dm.txt { color: #fff; font-size: 15px; }
.dm.ping { font-size: 40px; color: #fff; animation-duration: 1.8s; font-style: normal; }
@keyframes floatup { 0% { opacity: 0; transform: translate(-50%, 10px) scale(.6); } 15% { opacity: 1; transform: translate(-50%, 0) scale(1.25); } 100% { opacity: 0; transform: translate(-50%, -70px) scale(1); } }
.col.flash .pillar { animation: flashr .4s; }
@keyframes flashr { 0% { filter: brightness(2.2) saturate(0); } 100% { filter: none; } }
.col.healflash .pillar { animation: flashg .5s; }
@keyframes flashg { 0% { filter: brightness(1.5) hue-rotate(-30deg); } 100% { filter: none; } }
.col.pinged .pillar { animation: pingring 1.1s ease-out 3; }
@keyframes pingring { 0% { box-shadow: 0 0 0 0 rgba(255, 194, 74, .9); } 100% { box-shadow: 0 0 0 22px rgba(255, 194, 74, 0); } }

/* 3D-Modus: Säulen kommen aus der Szene, das DOM liefert Klickflächen, Zielklammern, Beschriftung */
html.has3d #screen-game { max-width: none; min-height: 0; height: 100dvh; padding-bottom: 0; overflow: hidden; }
html.has3d[data-screen="game"] body { overflow: hidden; }
html.has3d #stage { height: 100dvh; min-height: 0; overflow: hidden; padding-bottom: var(--safe-b); }
html.has3d .wall-wrap { flex: 1 1 auto; min-height: 160px; padding: 0; }
html.has3d .wall { position: absolute; inset: 0; max-width: none; display: block; margin: 0; }
html.has3d .ground { display: none; }
html.has3d .col { position: absolute; display: block; }
html.has3d .pillar { height: 100%; background: none; border: 0; }
html.has3d .col:hover .pillar { transform: none; }
html.has3d .fill, html.has3d .col .glow, html.has3d .rebuild-line { display: none; }
html.has3d .col-top { position: absolute; bottom: 100%; left: -26px; right: -26px; height: auto; padding-bottom: 4px; }
html.has3d .col-label { position: absolute; top: 100%; left: -18px; right: -18px; margin-top: 6px; min-height: 0; }
html.has3d .col .home { bottom: auto; top: -2px; }
html.has3d .col.sel .pillar, html.has3d .col:focus-visible .pillar { box-shadow: none;
  background:
    linear-gradient(var(--accent), var(--accent)) left top / 16px 2px no-repeat, linear-gradient(var(--accent), var(--accent)) left top / 2px 16px no-repeat,
    linear-gradient(var(--accent), var(--accent)) right top / 16px 2px no-repeat, linear-gradient(var(--accent), var(--accent)) right top / 2px 16px no-repeat,
    linear-gradient(var(--accent), var(--accent)) left bottom / 16px 2px no-repeat, linear-gradient(var(--accent), var(--accent)) left bottom / 2px 16px no-repeat,
    linear-gradient(var(--accent), var(--accent)) right bottom / 16px 2px no-repeat, linear-gradient(var(--accent), var(--accent)) right bottom / 2px 16px no-repeat;
  filter: drop-shadow(0 0 6px rgba(255, 122, 26, .9)); }
html.has3d .col:focus-visible { outline: none; }
html.has3d .col.sel .col-label .nm { color: #fff; }
html.has3d .col.flash .pillar, html.has3d .col.healflash .pillar { animation: none; }
/* Angriff als Fadenkreuz: Die glühende Kugel dahinter kommt aus der 3D-Szene */
html.has3d .atk { background: radial-gradient(circle, rgba(255, 60, 40, .14) 0 52%, rgba(255, 60, 40, 0) 53%); box-shadow: 0 0 0 1.5px rgba(255, 90, 70, .9), 0 0 16px rgba(255, 60, 40, .6); animation: none; }
html.has3d .atk span { position: absolute; bottom: -15px; font-size: 12px; color: #ff9a8a; text-shadow: 0 1px 4px #000; }
html.has3d .atk.can:hover { box-shadow: 0 0 0 2px #fff, 0 0 22px rgba(255, 255, 255, .6); }

.ticker { list-style: none; margin: 0 auto; padding: 0; width: 100%; max-width: 840px; min-height: 56px; max-height: 84px; display: flex; flex-direction: column; justify-content: flex-end; gap: 3px; pointer-events: none; overflow: hidden; position: relative; z-index: 4; }
html.has3d .ticker { height: 66px; min-height: 0; max-height: none; flex: none; }
.ticker li { font-size: 12.5px; line-height: 1.25; color: var(--text2); background: linear-gradient(90deg, rgba(6, 8, 12, .85), rgba(6, 8, 12, .5)); border-left: 2px solid var(--c, var(--mute)); padding: 4px 10px; max-width: max-content; animation: slidein .3s ease, fadeout 1s ease 6.5s forwards; }
.ticker li.bad { border-left-color: var(--bad); } .ticker li.good { border-left-color: var(--good); } .ticker li.act { border-left-color: var(--gold); color: var(--gold); }
@keyframes slidein { from { transform: translateX(-14px); opacity: 0; } }
/* Ereignis-Protokoll unter der Live-Tabelle (breite Bildschirme) */
.board .ticker.docked { height: auto; min-height: 0; max-height: none; margin: 12px 0 0; padding-top: 10px; border-top: 1px solid var(--line); justify-content: flex-start; gap: 4px; }
.board .ticker.docked::before { content: 'Ereignisse'; font-family: var(--display); font-weight: 700; font-size: 12px; text-transform: uppercase; letter-spacing: .16em; color: var(--accent2); margin-bottom: 4px; }
.board .ticker.docked li { max-width: none; white-space: normal; animation: slidein .3s ease; background: rgba(255, 255, 255, .04); font-size: 12px; }
.board .ticker.docked li:nth-child(n+6) { opacity: .6; }
@keyframes fadeout { to { opacity: 0; } }

.roster { display: flex; gap: 5px; overflow-x: auto; padding: 2px; scrollbar-width: none; justify-content: safe center; flex-wrap: nowrap; min-height: 32px; position: relative; z-index: 4; }
.roster::-webkit-scrollbar { display: none; }
.rchip { display: flex; align-items: center; gap: 5px; padding: 3px 9px 3px 4px; background: var(--glass); box-shadow: inset 0 0 0 1px var(--line), inset 0 -2px 0 var(--c); font-size: 12px; position: relative; flex: none; clip-path: var(--chamfer-s); backdrop-filter: var(--blur); }
.rchip b { font-family: var(--num); font-variant-numeric: tabular-nums; }
.rchip.mine { box-shadow: inset 0 0 0 1.5px var(--c), inset 0 -2px 0 var(--c); }
.rchip.deb { animation: shakeb .3s infinite; box-shadow: inset 0 0 0 1.5px var(--bad); }
.rchip.deb::after { content: '😤'; position: absolute; top: -2px; right: 1px; font-size: 11px; }
.kz-badge { font-style: normal; font: 700 9.5px/1 var(--display); background: var(--gold); color: #1a0a00; padding: 2px 4px; letter-spacing: .04em; }

/* Fähigkeiten-Leiste */
.dock { position: sticky; bottom: 0; z-index: 10; padding: 8px 0 calc(4px + var(--safe-b)); margin-top: auto; }
html.has3d .dock { position: relative; }
.energy-row { display: flex; gap: 8px; align-items: center; margin-bottom: 8px; }
.energy { flex: 1; position: relative; height: 20px; background: rgba(0, 0, 0, .55); box-shadow: inset 0 0 0 1px var(--line2); overflow: hidden; clip-path: polygon(8px 0, 100% 0, calc(100% - 8px) 100%, 0 100%); }
.energy-fill { position: absolute; inset: 0 auto 0 0; width: 60%; background: linear-gradient(90deg, #1f6fd6, var(--blue) 70%, #c8f0ff); box-shadow: 0 0 18px var(--blue); transition: width .12s linear; }
.energy::after { content: ''; position: absolute; inset: 0; background: repeating-linear-gradient(90deg, transparent 0 calc(10% - 2px), rgba(0, 0, 0, .55) calc(10% - 2px) 10%); pointer-events: none; }
.energy.afd .energy-fill { background: linear-gradient(90deg, #b8201a, var(--bad) 60%, #ffb07a); box-shadow: 0 0 18px var(--bad); }
.energy span { position: absolute; inset: 0; display: grid; place-items: center; font-family: var(--num); font-size: 13px; z-index: 2; text-shadow: 0 1px 3px #000, 0 0 2px #000; }
.energy i { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); font-style: normal; font-size: 10.5px; color: #fff; background: var(--bad); padding: 1px 8px; z-index: 2; text-transform: uppercase; letter-spacing: .08em; font-weight: 700; }
.ping-btn { min-width: 42px; height: 30px; font-size: 15px; }
.actions { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.act-btn { position: relative; padding: 9px 4px 7px; min-height: 86px; display: grid; justify-items: center; align-content: center; gap: 2px; color: var(--text);
  background: linear-gradient(180deg, rgba(34, 44, 62, .92), rgba(12, 16, 24, .94)); box-shadow: inset 0 0 0 1px var(--line2), inset 0 2px 0 rgba(255, 255, 255, .08), inset 0 -3px 0 var(--blue);
  clip-path: var(--chamfer); overflow: hidden; transition: transform .1s, filter .2s; }
.act-btn.afd { background: linear-gradient(180deg, rgba(70, 22, 30, .94), rgba(22, 8, 12, .95)); box-shadow: inset 0 0 0 1px rgba(255, 90, 80, .35), inset 0 2px 0 rgba(255, 255, 255, .06), inset 0 -3px 0 var(--bad); }
.act-btn:hover { filter: brightness(1.15); }
.act-btn:active { transform: scale(.95); }
.act-btn .ic { font-size: 28px; line-height: 1; filter: drop-shadow(0 2px 6px rgba(0, 0, 0, .6)); position: relative; z-index: 1; }
.act-btn .lb { font-family: var(--display); font-weight: 700; font-size: clamp(10px, 2.7vw, 12.5px); text-transform: uppercase; letter-spacing: .06em; line-height: 1.05; text-align: center; position: relative; z-index: 1; }
.act-btn .co { font-family: var(--num); font-size: 11px; opacity: .9; background: rgba(0, 0, 0, .45); padding: 0 7px; position: relative; z-index: 1; }
.act-btn .kb { position: absolute; top: 5px; left: 9px; font-family: var(--num); font-size: 10px; opacity: .7; display: none; z-index: 1; }
@media (hover: hover) and (pointer: fine) { .act-btn .kb { display: block; } }
.act-btn .cdv { position: absolute; inset: 0; z-index: 2; pointer-events: none; background: conic-gradient(rgba(4, 6, 10, .8) calc(var(--cd, 0) * 360deg), transparent 0); }
.act-btn .cdt { position: absolute; inset: 0; z-index: 3; display: none; place-items: center; font-family: var(--num); font-size: 24px; pointer-events: none; text-shadow: 0 0 10px #000; }
.act-btn.cooling .cdt { display: grid; }
.act-btn.poor { filter: grayscale(.75) brightness(.65); }
.act-btn.armed { outline: 2px solid var(--gold); }
.actions .sub { grid-column: 1 / -1; }
/* Superkraft: lädt von unten auf */
.act-btn .tag { position: absolute; top: 5px; right: 8px; font: 700 8.5px/1 var(--display); letter-spacing: .12em; text-transform: uppercase; opacity: .8; z-index: 1; }
.act-btn.sp { color: #fff; background: linear-gradient(180deg, color-mix(in srgb, var(--c, #ff7a1a) 55%, #05070a), color-mix(in srgb, var(--c, #ff7a1a) 18%, #05070a));
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .22), inset 0 -3px 0 var(--gold); }
.act-btn.sp .cdv, .act-btn.sp .cdt { display: none !important; }
.act-btn.sp::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: calc(var(--chg, 0) * 100%); pointer-events: none; transition: height .25s linear;
  background: linear-gradient(0deg, color-mix(in srgb, var(--c, #ff7a1a) 55%, transparent), color-mix(in srgb, var(--c, #ff7a1a) 25%, transparent)); box-shadow: 0 -2px 0 rgba(255, 255, 255, .8), 0 -8px 16px color-mix(in srgb, var(--c, #ff7a1a) 60%, transparent); }
.act-btn.sp:not(.charging)::after { height: 100%; background: radial-gradient(ellipse at 50% 100%, color-mix(in srgb, var(--gold) 45%, transparent), transparent 70%); box-shadow: none; }
.act-btn.sp:not(.charging) { box-shadow: inset 0 0 0 2px var(--gold), inset 0 0 26px rgba(255, 194, 74, .45); animation: spglow 1.4s infinite; }
.act-btn.sp .co { font-weight: 700; }
@keyframes spglow { 50% { filter: brightness(1.3); } }
/* Sofort-Aktionen: Prüfauftrag, Eilantrag, Kanzleramt */
.act-btn.inst { min-height: 50px; grid-auto-flow: column; grid-template-columns: 1fr auto; gap: 1px 10px; padding: 6px 12px; text-align: left; align-content: center; justify-items: start; box-shadow: inset 0 0 0 1px var(--line2), inset 3px 0 0 var(--blue); }
.act-btn.inst .lb { grid-column: 1; font-size: 12.5px; text-align: left; }
.act-btn.inst .sub2 { grid-column: 1; font-size: 11px; color: var(--mute); font-family: var(--ui); position: relative; z-index: 1; }
.act-btn.inst .co { grid-column: 2; grid-row: 1 / span 2; align-self: center; }
.act-btn.inst .kb { top: 4px; right: 8px; left: auto; }
.act-btn.inst.afd { box-shadow: inset 0 0 0 1px rgba(255, 90, 80, .35), inset 3px 0 0 var(--bad); }
.act-btn.inst.kanzler { background: linear-gradient(90deg, rgba(255, 194, 74, .2), rgba(12, 16, 24, .94) 60%); box-shadow: inset 0 0 0 1px rgba(255, 194, 74, .45), inset 3px 0 0 var(--gold); }
.act-btn.inst.kanzler .sub2 { color: var(--accent2); }
.act-btn.inst.kanzler.locked { opacity: .6; }
.act-btn.inst.pruef.locked { opacity: .65; }
.act-btn.inst.eilantrag .sub2 { color: #ff9a8a; }

.spectate { display: grid; gap: 8px; margin-bottom: 8px; padding: 14px; text-align: center; background: var(--glass2); box-shadow: inset 0 0 0 1px var(--line); clip-path: var(--chamfer); position: relative; z-index: 6; }
.spectate b { font-family: var(--display); text-transform: uppercase; letter-spacing: .14em; }
.spectate .grid { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; }

.board { position: fixed; right: 10px; top: 64px; width: min(300px, 92vw); z-index: 30; background: var(--glass2); box-shadow: inset 0 0 0 1px var(--line), var(--shadow); padding: 12px; max-height: 70dvh; overflow: auto; clip-path: var(--chamfer); backdrop-filter: var(--blur); }
.board-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.board-head b { font-family: var(--display); text-transform: uppercase; letter-spacing: .16em; font-size: 12px; color: var(--accent2); }
.board ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 3px; }
.board li { display: flex; align-items: center; gap: 8px; padding: 6px 7px; background: rgba(255, 255, 255, .04); font-size: 13px; }
.board li.me { background: rgba(255, 122, 26, .2); box-shadow: inset 2px 0 0 var(--accent); }
.board li .nm { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.board li b { font-family: var(--num); font-variant-numeric: tabular-nums; }
.board li .r { width: 16px; color: var(--mute); font-size: 11px; font-family: var(--num); }

.sheet { position: fixed; inset: 0; z-index: 40; background: rgba(2, 3, 6, .65); display: grid; align-items: end; justify-items: center; backdrop-filter: blur(3px); }
.sheet-card { width: min(520px, 100%); background: var(--glass2); padding: 18px 16px calc(16px + var(--safe-b)); display: grid; gap: 12px; text-align: center; clip-path: polygon(14px 0, calc(100% - 14px) 0, 100% 14px, 100% 100%, 0 100%, 0 14px); box-shadow: inset 0 1px 0 var(--accent); }
.sheet-card > b { font-family: var(--display); text-transform: uppercase; letter-spacing: .14em; }
.party-pick-list { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.party-pick-list button { display: grid; justify-items: center; gap: 5px; padding: 12px 6px; background: rgba(255, 255, 255, .05); box-shadow: inset 0 0 0 1px var(--line), inset 0 -3px 0 var(--c); font-family: var(--display); font-weight: 700; font-size: 12px; text-transform: uppercase; letter-spacing: .06em; clip-path: var(--chamfer-s); }
.party-pick-list button:hover { background: rgba(255, 255, 255, .1); }
/* Kanzleramt */
.kz-card { gap: 10px; text-align: left; box-shadow: inset 0 2px 0 var(--gold); }
.kz-head { display: grid; gap: 2px; }
.kz-head b { font-family: var(--display); font-size: 18px; text-transform: uppercase; letter-spacing: .16em; color: var(--gold); }
.kz-head span { color: var(--mute); font-size: 13px; }
.kz-list { display: grid; gap: 6px; }
.kz-opt { display: grid; gap: 3px; text-align: left; padding: 12px 14px; color: var(--text); background: rgba(255, 255, 255, .05); box-shadow: inset 0 0 0 1px var(--line), inset 3px 0 0 var(--blue); clip-path: var(--chamfer-s); transition: background .2s, transform .15s; }
.kz-opt:hover { background: rgba(255, 255, 255, .1); transform: translateX(3px); }
.kz-opt.afd { box-shadow: inset 0 0 0 1px var(--line), inset 3px 0 0 var(--bad); }
.kz-opt.own { box-shadow: inset 0 0 0 1px var(--line), inset 3px 0 0 var(--gold); }
.kz-opt .kz-scope { font: 700 9.5px/1 var(--display); letter-spacing: .16em; text-transform: uppercase; color: var(--mute); }
.kz-opt b { font-family: var(--display); font-size: 15px; text-transform: uppercase; letter-spacing: .04em; }
.kz-opt small { font-size: 13px; color: var(--text2); line-height: 1.35; }
#fx { position: fixed; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 60; }

.pingbar { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(150px + var(--safe-b)); z-index: 25; display: flex; gap: 6px; padding: 8px; background: var(--glass2); box-shadow: inset 0 0 0 1px var(--line), var(--shadow); clip-path: var(--chamfer); animation: pop2 .18s ease; }
.pingbar button { font-size: 25px; width: 48px; height: 48px; background: rgba(255, 255, 255, .06); clip-path: var(--chamfer-s); }
.pingbar button:active { transform: scale(.9); }
.pingbar .tgt { align-self: center; font-size: 10px; color: var(--mute); padding: 0 6px; max-width: 80px; line-height: 1.15; text-transform: uppercase; letter-spacing: .08em; }
.offer { position: relative; z-index: 6; padding: 10px; display: grid; gap: 8px; background: linear-gradient(90deg, rgba(78, 224, 138, .16), rgba(79, 184, 255, .08)), var(--glass2); box-shadow: inset 0 0 0 1px rgba(78, 224, 138, .45); clip-path: var(--chamfer); animation: pop2 .25s ease; }
.offer-t { display: flex; justify-content: space-between; font-family: var(--display); text-transform: uppercase; letter-spacing: .1em; font-size: 14px; }
.offer-t span { color: var(--gold); font-family: var(--num); }
.offer-b { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.offer-b .btn { min-height: 54px; font-size: 13px; }
.offer-b .btn small { font-size: 11px; }
.coach { position: relative; z-index: 12; color: #fff; padding: 12px 14px; display: flex; align-items: center; gap: 10px; font-size: 14.5px; line-height: 1.35;
  background: linear-gradient(90deg, rgba(255, 122, 26, .22), rgba(6, 8, 12, .9) 40%); box-shadow: inset 0 0 0 1px rgba(255, 122, 26, .5), inset 3px 0 0 var(--accent); clip-path: var(--chamfer); animation: pop2 .25s ease; }
.coach span { flex: 1; } .coach b { color: var(--accent2); }
.coach .linkbtn { font-size: 10.5px; padding: 4px 8px; white-space: nowrap; color: var(--mute); }
@keyframes pop2 { from { transform: translateY(12px) scale(.98); opacity: 0; } }

.brief { position: absolute; left: 50%; top: 72px; transform: translateX(-50%); z-index: 22; width: min(94%, 480px); padding: 16px 16px 14px; display: grid; gap: 9px;
  background: var(--glass2); box-shadow: inset 0 0 0 1px var(--line2), inset 0 3px 0 var(--accent), var(--shadow); clip-path: var(--chamfer); backdrop-filter: var(--blur); animation: briefIn .45s cubic-bezier(.2, .8, .2, 1); }
@keyframes briefIn { from { opacity: 0; transform: translate(-50%, 14px); } }
.brief .bh { display: flex; align-items: center; gap: 12px; }
.brief .bh b { font-family: var(--display); font-size: 19px; text-transform: uppercase; letter-spacing: .06em; line-height: 1.05; }
.brief .bh small { display: block; color: var(--mute); font-family: var(--ui); font-weight: 400; font-size: 12px; margin-top: 3px; }
.brief ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 5px; }
.brief li { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; line-height: 1.32; background: rgba(255, 255, 255, .05); padding: 8px 10px; color: var(--text2); }
.brief li b { color: #fff; }
.brief li span { font-size: 19px; line-height: 1; }
.brief .goal { font-family: var(--display); font-weight: 700; color: var(--gold); font-size: 12.5px; text-transform: uppercase; letter-spacing: .08em; }

/* Statusleisten: Verfassungsschutz, Opferrolle */
.vs-bar, .opfer-bar { position: relative; z-index: 6; display: flex; align-items: center; gap: 12px; flex-wrap: wrap; padding: 7px 12px; color: #fff; overflow: hidden; clip-path: var(--chamfer-s); }
.vs-bar { background: linear-gradient(90deg, rgba(20, 60, 100, .85), rgba(6, 8, 12, .85)); box-shadow: inset 3px 0 0 var(--blue), inset 0 0 0 1px rgba(79, 184, 255, .35); }
.vs-bar b { font-family: var(--display); font-size: 12.5px; letter-spacing: .16em; text-transform: uppercase; color: #8fd2ff; }
.vs-bar span { font-size: 12.5px; font-weight: 700; }
.vs-bar i { position: absolute; left: 0; bottom: 0; height: 2px; background: var(--blue); box-shadow: 0 0 10px var(--blue); transition: width .2s linear; }
.vs-bar.on { background: linear-gradient(90deg, rgba(20, 90, 50, .85), rgba(6, 8, 12, .85)); box-shadow: inset 3px 0 0 var(--good), inset 0 0 0 1px rgba(78, 224, 138, .4); }
.vs-bar.on b { color: var(--good); } .vs-bar.on i { background: var(--good); box-shadow: 0 0 10px var(--good); }
.opfer-bar { background: linear-gradient(90deg, rgba(120, 20, 10, .85), rgba(6, 8, 12, .85)); box-shadow: inset 3px 0 0 var(--ember), inset 0 0 0 1px rgba(255, 90, 60, .35); }
.opfer-bar b { font-family: var(--display); font-size: 12.5px; letter-spacing: .16em; text-transform: uppercase; color: var(--accent2); }
.opfer-bar span { font-family: var(--num); font-variant-numeric: tabular-nums; }
.opfer-bar em { font-style: normal; font-size: 12.5px; color: var(--text2); }
.opfer-bar i { position: absolute; left: 0; bottom: 0; height: 2px; background: var(--ember); box-shadow: 0 0 10px var(--ember); transition: width .2s linear; }

/* Opferrolle */
.opfer { position: fixed; inset: 0; z-index: 80; display: grid; place-items: center; padding: 20px; text-align: center; cursor: pointer; color: #fff; opacity: 0;
  background: radial-gradient(ellipse at 50% 50%, rgba(80, 10, 6, .82), rgba(4, 2, 3, .95) 70%); }
.opfer.in { animation: opferIn .35s ease forwards; }
.opfer::before, .opfer::after { content: ''; position: absolute; left: 0; right: 0; height: 9vh; background: #000; }
.opfer::before { top: 0; box-shadow: 0 1px 0 var(--ember); } .opfer::after { bottom: 0; box-shadow: 0 -1px 0 var(--ember); }
@keyframes opferIn { to { opacity: 1; } }
.opfer-in { width: min(1100px, 100%); display: grid; gap: clamp(10px, 2.4vh, 22px); justify-items: center; position: relative; z-index: 1; }
.opfer-kick { font-family: var(--display); font-weight: 700; letter-spacing: .3em; text-transform: uppercase; font-size: clamp(11px, 2vw, 14px); color: var(--accent2); }
.opfer-big { display: flex; justify-content: center; font-family: var(--display); font-weight: 700; line-height: 1; font-size: min(12vw, 150px); color: #fff; letter-spacing: .02em; text-shadow: 0 0 40px rgba(255, 60, 20, .8), 0 4px 0 #3a0400; max-width: 100%; }
.opfer-big span { display: inline-block; opacity: 0; transform: translateY(.35em) scale(1.3); filter: blur(8px); animation: opferLetter .55s cubic-bezier(.2, 1.4, .4, 1) forwards; animation-delay: calc(var(--i) * 65ms + 150ms); }
@keyframes opferLetter { to { opacity: 1; transform: none; filter: none; } }
.opfer-q { margin: 0; font-family: var(--serif); font-style: italic; font-size: clamp(19px, 4vw, 36px); color: #ffd0c0; }
.opfer-buffs { list-style: none; margin: 4px 0 0; padding: 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.opfer-buffs li { display: grid; gap: 2px; min-width: 150px; padding: 12px 18px; background: rgba(10, 6, 8, .85); box-shadow: inset 0 0 0 1px rgba(255, 90, 60, .4), inset 0 3px 0 var(--ember); clip-path: var(--chamfer); }
.opfer-buffs li.dem { box-shadow: inset 0 0 0 1px rgba(79, 184, 255, .4), inset 0 3px 0 var(--blue); }
.opfer-buffs li b { font-family: var(--num); font-size: clamp(26px, 5vw, 40px); line-height: 1.05; }
.opfer-buffs li span { font-weight: 700; font-size: 13px; text-transform: uppercase; letter-spacing: .06em; }
.opfer-buffs li small { color: var(--mute); font-size: 11px; text-transform: uppercase; letter-spacing: .14em; }
.opfer-tip { margin: 0; font-weight: 700; font-size: clamp(15px, 2.4vw, 19px); max-width: 640px; }
.opfer.is-afd .opfer-tip { color: var(--accent2); }
.opfer-dismiss { font-size: 10.5px; color: var(--mute); letter-spacing: .2em; text-transform: uppercase; }

/* ───────── Ergebnis ───────── */
.res { max-width: 760px; margin: 0 auto; padding: 22px 0 32px; display: grid; gap: 14px; }
@media (min-width: 900px) { html.has3d .res { margin-right: 0; margin-left: auto; max-width: 620px; padding-top: 6vh; } }
@media (max-width: 899px) { html.has3d .res { padding-top: 28dvh; } }
.res-hero { position: relative; padding: 26px 20px 20px; text-align: center; overflow: hidden;
  background: radial-gradient(ellipse at 50% 0%, rgba(78, 224, 138, .25), transparent 65%), var(--glass2); box-shadow: inset 0 0 0 1px var(--line), inset 0 3px 0 var(--good); clip-path: var(--chamfer); }
.res-hero.lose { background: radial-gradient(ellipse at 50% 0%, rgba(255, 74, 61, .3), transparent 65%), var(--glass2); box-shadow: inset 0 0 0 1px var(--line), inset 0 3px 0 var(--bad); }
.res-hero .big { font-family: var(--display); font-weight: 700; font-size: clamp(34px, 8vw, 58px); line-height: 1; text-transform: uppercase; letter-spacing: .04em; color: #fff; text-shadow: 0 0 30px rgba(78, 224, 138, .55); animation: bannerIn .8s cubic-bezier(.2, .8, .2, 1); }
.res-hero.lose .big { text-shadow: 0 0 30px rgba(255, 74, 61, .7); }
.res-hero .grade { font-family: var(--display); font-weight: 700; font-size: 14px; text-transform: uppercase; letter-spacing: .14em; color: var(--gold); margin-top: 10px; }
.res-hero p { font-family: var(--serif); color: var(--text2); margin: 8px auto 0; max-width: 460px; }
.res-wall { display: flex; justify-content: center; align-items: flex-end; gap: 5px; height: 70px; margin-top: 16px; }
.res-wall i { width: 26px; background: var(--bricks) center/100% 18px, linear-gradient(180deg, #c9c3b9, #8d877e); position: relative; }
.res-wall i::before { content: ''; position: absolute; left: 0; right: 0; top: -2px; height: 3px; background: var(--accent); box-shadow: 0 0 10px var(--accent); }
.res-wall i.f { background: #3a3632; opacity: .8; } .res-wall i.f::before { background: #555; box-shadow: none; }
.me-card { display: grid; gap: 8px; }
.me-card .row { display: flex; justify-content: space-between; gap: 8px; font-size: 14.5px; color: var(--text2); }
.me-card .row b { font-family: var(--num); color: #fff; }
.me-card .row.total { border-top: 1px solid var(--line); padding-top: 10px; font-family: var(--display); font-weight: 700; font-size: 18px; text-transform: uppercase; letter-spacing: .08em; color: #fff; }
.me-card .row.total span:last-child { font-family: var(--num); font-size: 26px; color: var(--accent2); letter-spacing: 0; text-shadow: 0 0 16px rgba(255, 122, 26, .5); }
.me-card h3 { font-size: 14px; text-transform: uppercase; letter-spacing: .14em; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.me-card .sub, .sub { color: var(--mute); font-size: 12.5px; font-family: var(--ui); font-weight: 400; letter-spacing: 0; text-transform: none; }
.score-table { display: grid; gap: 4px; }
.score-row { display: grid; grid-template-columns: 22px 28px 1fr auto; gap: 9px; align-items: center; padding: 8px 12px; background: var(--glass); box-shadow: inset 0 0 0 1px var(--line); font-size: 14px; clip-path: var(--chamfer-s); backdrop-filter: var(--blur); }
.score-row.me { background: linear-gradient(90deg, rgba(255, 122, 26, .22), var(--glass)); box-shadow: inset 0 0 0 1px rgba(255, 122, 26, .55), inset 3px 0 0 var(--accent); }
.score-row .nm { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-family: var(--display); font-weight: 700; }
.score-row .nm small { display: block; font-family: var(--ui); font-weight: 400; color: var(--mute); font-size: 11px; }
.score-row b { font-family: var(--num); font-size: 17px; font-variant-numeric: tabular-nums; }
.score-row .rk { color: var(--mute); text-align: center; font-family: var(--num); }
.res-actions { display: grid; gap: 8px; grid-template-columns: 1fr 1fr; }
.res-actions .btn.primary { grid-column: 1 / -1; align-items: center; text-align: center; }
.res-wait { color: var(--mute); font-size: 13px; text-align: center; }
.res-h { font-family: var(--display); font-size: 13px; text-transform: uppercase; letter-spacing: .16em; margin: 6px 0 -4px; color: var(--gold); }
.awards { display: grid; gap: 8px; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); }
.award { display: flex; gap: 10px; align-items: center; padding: 10px 12px; background: linear-gradient(135deg, rgba(255, 194, 74, .16), transparent 70%), var(--glass); box-shadow: inset 0 0 0 1px rgba(255, 194, 74, .35); clip-path: var(--chamfer-s); animation: pop2 .45s ease backwards; }
.award .ai { font-size: 28px; filter: drop-shadow(0 0 8px rgba(255, 194, 74, .6)); }
.award b { font-family: var(--display); display: block; line-height: 1.1; text-transform: uppercase; letter-spacing: .06em; font-size: 13px; }
.award small { color: var(--text2); display: block; font-size: 12px; } .award em { font-style: normal; color: var(--gold); font-size: 12px; }
.award.me { box-shadow: inset 0 0 0 1px var(--accent), inset 3px 0 0 var(--accent); }

/* ───────── Dialoge ───────── */
.dlg { width: min(700px, calc(100vw - 20px)); max-height: calc(100dvh - 24px); padding: 0; border: 0; color: var(--text); overflow: hidden;
  background: linear-gradient(180deg, rgba(20, 26, 38, .97), rgba(8, 11, 17, .98)); box-shadow: inset 0 0 0 1px var(--line2), inset 0 3px 0 var(--accent); clip-path: polygon(16px 0, 100% 0, 100% calc(100% - 16px), calc(100% - 16px) 100%, 0 100%, 0 16px); }
.dlg[open] { display: flex; flex-direction: column; animation: pop2 .3s cubic-bezier(.2, .8, .2, 1); }
.dlg::backdrop { background: rgba(2, 3, 6, .72); backdrop-filter: blur(5px); }
.dlg-head { display: flex; align-items: center; justify-content: space-between; padding: 16px 18px 14px; border-bottom: 1px solid var(--line); }
.dlg-head h2 { font-size: 17px; text-transform: uppercase; letter-spacing: .16em; }
.lb-controls { display: flex; flex-wrap: wrap; gap: 8px; justify-content: space-between; padding: 14px 18px 0; }
.lb-teams { display: flex; gap: 6px; flex-wrap: wrap; padding: 10px 18px 0; }
.lb-teams button { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px 4px 5px; background: rgba(255, 255, 255, .05); box-shadow: inset 0 0 0 1px var(--line); font-size: 12px; clip-path: var(--chamfer-s); }
.lb-teams button.on { background: var(--accent); color: #1a0a00; font-weight: 700; }
.lb-body { padding: 12px 18px 18px; overflow: auto; display: grid; gap: 4px; align-content: start; min-height: 240px; }
.lb-row { display: grid; grid-template-columns: 34px 28px 1fr auto; align-items: center; gap: 9px; padding: 9px 12px; background: rgba(255, 255, 255, .04); box-shadow: inset 0 0 0 1px var(--line); clip-path: var(--chamfer-s); }
.lb-row .rk { font-family: var(--num); text-align: center; color: var(--mute); }
.lb-row:nth-child(1) .rk { color: var(--gold); font-size: 20px; } .lb-row:nth-child(2) .rk { color: #d4dbe6; font-size: 18px; } .lb-row:nth-child(3) .rk { color: #e0a070; font-size: 17px; }
.lb-row.me { background: rgba(255, 122, 26, .16); box-shadow: inset 0 0 0 1px rgba(255, 122, 26, .55), inset 3px 0 0 var(--accent); }
.lb-row .nm { font-family: var(--display); font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lb-row .nm small { display: block; font-family: var(--ui); font-weight: 400; color: var(--mute); font-size: 11.5px; }
.lb-row b { font-family: var(--num); font-size: 18px; font-variant-numeric: tabular-nums; text-align: right; }
.lb-empty { text-align: center; color: var(--mute); padding: 40px 10px; font-family: var(--serif); }
.lb-controls .seg button.daily-tab { color: var(--gold); }
.lb-controls .seg button.daily-tab.on { color: #1a0a00; }
.how { padding: 16px 18px 20px; overflow: auto; display: grid; gap: 12px; }
.how h3 { font-size: 13px; text-transform: uppercase; letter-spacing: .14em; margin-bottom: 6px; color: #fff; }
.how p, .how li { font-family: var(--serif); color: var(--text2); font-size: 14.5px; margin: 0 0 6px; }
.how b { color: #fff; }
.how ul { margin: 0; padding-left: 20px; }
.how .step { display: grid; grid-template-columns: 44px 1fr; gap: 12px; padding: 12px; background: rgba(255, 255, 255, .04); box-shadow: inset 0 0 0 1px var(--line); align-items: start; clip-path: var(--chamfer-s); }
.how .step .n { width: 44px; height: 44px; display: grid; place-items: center; font-size: 22px; background: rgba(0, 0, 0, .4); clip-path: var(--chamfer-s); }
.how .story { padding: 14px 16px; background: linear-gradient(90deg, rgba(255, 122, 26, .16), transparent 80%); box-shadow: inset 3px 0 0 var(--accent); }
.how .story h3 { color: var(--accent2); }
.how table { width: 100%; border-collapse: collapse; font-size: 13.5px; font-family: var(--ui); }
.how td { padding: 6px 4px; border-bottom: 1px solid var(--line); vertical-align: top; color: var(--text2); }
.how td:first-child { white-space: nowrap; font-family: var(--display); font-weight: 700; color: #fff; }
.prof { padding: 16px 18px 20px; overflow: auto; display: grid; gap: 12px; }
.prof-head { display: flex; align-items: center; gap: 12px; }
.prof-head .nm { font-family: var(--display); font-weight: 700; font-size: 26px; line-height: 1.05; text-transform: uppercase; letter-spacing: .04em; }
.prof-head .ti { color: var(--gold); font-family: var(--display); font-weight: 700; text-transform: uppercase; letter-spacing: .12em; font-size: 12.5px; }
.prof-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.prof-stats div { background: rgba(255, 255, 255, .05); padding: 10px 4px; text-align: center; clip-path: var(--chamfer-s); }
.prof-stats b { display: block; font-family: var(--num); font-size: 21px; }
.prof-stats span { font-size: 10px; color: var(--mute); text-transform: uppercase; letter-spacing: .12em; }
.badges { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 6px; }
.badge { display: flex; gap: 8px; align-items: center; padding: 9px; background: rgba(255, 255, 255, .04); box-shadow: inset 0 0 0 1px var(--line); clip-path: var(--chamfer-s); }
.badge .bi { font-size: 26px; }
.badge b { font-family: var(--display); font-size: 12.5px; display: block; line-height: 1.1; text-transform: uppercase; letter-spacing: .04em; }
.badge small { color: var(--mute); font-size: 11px; line-height: 1.2; display: block; }
.badge.locked { opacity: .35; filter: grayscale(1); }
.badge.earned { background: rgba(255, 194, 74, .1); box-shadow: inset 0 0 0 1px rgba(255, 194, 74, .5); }
.share-body { padding: 16px 18px 20px; display: grid; gap: 12px; overflow: auto; }
.share-preview { overflow: hidden; background: rgba(0, 0, 0, .4); display: grid; place-items: center; min-height: 160px; clip-path: var(--chamfer); }
.share-preview img, .share-preview canvas { width: 100%; max-height: 52dvh; object-fit: contain; display: block; }
.share-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.share-actions .primary { grid-column: 1 / -1; }
.share-links { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; }
.share-links a { padding: 8px 14px; background: rgba(255, 255, 255, .06); box-shadow: inset 0 0 0 1px var(--line); color: var(--text); text-decoration: none; font-family: var(--display); font-weight: 700; font-size: 12px; text-transform: uppercase; letter-spacing: .1em; clip-path: var(--chamfer-s); }
.share-links a:hover { background: rgba(255, 122, 26, .2); }

.toast { position: fixed; left: 50%; bottom: calc(118px + var(--safe-b)); transform: translateX(-50%); z-index: 100; padding: 11px 18px; max-width: 92vw; text-align: center; font-size: 14px;
  background: var(--glass2); box-shadow: inset 0 0 0 1px var(--line2), inset 3px 0 0 var(--accent), var(--shadow); clip-path: var(--chamfer-s); animation: pop2 .3s; }
.toast.err { box-shadow: inset 0 0 0 1px rgba(255, 74, 61, .5), inset 3px 0 0 var(--bad), var(--shadow); }
.rotate-hint { display: none; }

/* Epilog: Kinobalken über der Szene (Sonnenaufgang bzw. Trümmerfeld) */
.epilog { position: fixed; inset: 0; z-index: 70; display: grid; place-items: center; text-align: center; padding: 24px; background: radial-gradient(ellipse at 50% 50%, rgba(4, 6, 10, .25), rgba(4, 6, 10, .75)); animation: fade .8s ease; }
.epilog .bar { position: absolute; left: 0; right: 0; height: 13vh; background: #000; animation: barIn .9s cubic-bezier(.2, .8, .2, 1); }
.epilog .bar.t { top: 0; transform-origin: top; } .epilog .bar.b { bottom: 0; transform-origin: bottom; }
@keyframes barIn { from { transform: scaleY(0); } }
@keyframes fade { from { opacity: 0; } }
.ep-in { max-width: 680px; position: relative; }
.ep-big { font-family: var(--display); font-weight: 700; font-size: clamp(38px, 10vw, 92px); line-height: .95; text-transform: uppercase; letter-spacing: .04em; animation: epTitle 1.4s cubic-bezier(.2, .8, .2, 1); }
@keyframes epTitle { from { opacity: 0; letter-spacing: .4em; filter: blur(10px); } }
.epilog p { font-family: var(--serif); font-size: clamp(16px, 2.4vw, 20px); color: var(--text2); margin-top: 16px; animation: fade 1.2s ease .5s backwards; }
.epilog.lose .ep-big { color: #fff; text-shadow: 0 0 40px var(--bad), 0 0 90px rgba(255, 40, 20, .6); }
.epilog.win .ep-big { color: #fff; text-shadow: 0 0 40px rgba(255, 210, 140, .9), 0 0 90px rgba(255, 170, 80, .6); }

/* Rechtstexte */
body.legal-page { overflow-y: auto; }
.legal { position: relative; z-index: 2; max-width: 800px; margin: 0 auto; padding: 0 16px 40px; }
.legal-card { padding: 24px 22px 28px; line-height: 1.6; font-family: var(--serif); color: var(--text2); }
.legal-card h1 { font-size: clamp(30px, 7vw, 46px); margin-bottom: 10px; filter: none; }
.legal-card h2 { font-size: 15px; text-transform: uppercase; letter-spacing: .14em; margin: 24px 0 6px; color: #fff; }
.legal-card h3 { font-size: 14px; margin: 12px 0 2px; color: var(--gold); }
.legal-card p { margin: 6px 0; } .legal-card .small { font-size: 13.5px; color: var(--mute); font-family: var(--ui); }
.legal-card b { color: #fff; font-weight: 700; }

/* Tutorial-Platz */
#stage.tut { --wallh: calc(clamp(190px, 36dvh, 380px) - 70px); }

/* Querformat / niedrige Bildschirme */
@media (max-height: 520px) and (orientation: landscape) {
  :root { --wallh: clamp(110px, 38dvh, 200px); }
  .col-top { height: 40px; } .col-label { min-height: 40px; margin-top: 2px; } .col-label .nm { display: none; }
  .act-btn { min-height: 54px; padding: 4px; } .act-btn .ic { font-size: 19px; } .act-btn .co { display: none; }
  .act-btn.inst { min-height: 38px; }
  .clock { font-size: 24px; } .roster { display: none; } .hud-l { padding: 4px 10px; }
  html.has3d .ticker { display: none; }
  .energy-row { margin-bottom: 5px; } .energy { height: 16px; }
}
@media (min-width: 900px) {
  :root { --wallh: clamp(220px, 38dvh, 420px); }
  .actions { grid-template-columns: repeat(4, minmax(0, 160px)); justify-content: center; }
  .energy-row { max-width: 664px; margin-left: auto; margin-right: auto; }
  .act-btn { min-height: 94px; }
  .act-btn .ic { font-size: 32px; }
  .act-btn.inst { min-height: 50px; }
  .clock { font-size: 42px; }
}
@media (min-width: 1180px) {
  #screen-game.active { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 14px; align-items: start; }
  #screen-game .board { position: sticky; top: 12px; right: auto; width: auto; max-height: calc(100dvh - 24px); margin-top: 64px; }
  #screen-game .board[hidden] { display: block !important; }
  #board-close, #btn-board { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; animation-delay: 0ms !important; }
}

:root {
  --bricks: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 40 24' preserveAspectRatio='none'><g fill='none' stroke='rgba(15,12,10,.55)' stroke-width='1.6' vector-effect='non-scaling-stroke'><path d='M0 .8H40M0 12.8H40M20 .8V12.8M0 12.8V24M40 12.8V24'/></g></svg>");
  --crack: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 40 100' preserveAspectRatio='none'><g fill='none' stroke='%23000' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round' vector-effect='non-scaling-stroke' opacity='.8'><path d='M20 100 L17 84 L24 70 L15 56 L22 42 L14 28 L19 12'/><path d='M24 70 L33 63 L36 50'/><path d='M15 56 L6 51 L3 38'/><path d='M22 42 L31 35'/><path d='M17 84 L8 80'/></g></svg>");
}

/* Über das Spiel / FAQ (crawlbarer Text auf der Startseite) */
.about { margin: 28px 0 0; max-width: 640px; color: var(--mute); font-size: 12.5px; line-height: 1.55; }
.about summary { cursor: pointer; color: var(--text2); font-size: 12px; text-transform: uppercase; letter-spacing: .12em; list-style: none; }
.about summary::-webkit-details-marker { display: none; }
.about summary::before { content: '▸ '; }
.about[open] summary::before { content: '▾ '; }
.about h2 { font-size: 15px; color: var(--text); margin: 14px 0 6px; }
.about h3 { font-size: 13px; color: var(--text2); margin: 12px 0 2px; }
.about p { margin: 0 0 6px; }

/* Quellen-Seite */
.src-toc { display: flex; flex-wrap: wrap; gap: 6px 14px; margin: 16px 0 4px; font-family: var(--ui); font-size: 13px; }
.src-toc a { color: var(--gold); text-decoration: none; } .src-toc a:hover { text-decoration: underline; }
.src-page .ev { margin: 14px 0 0; padding: 0 0 12px; border-bottom: 1px solid var(--line); scroll-margin-top: 16px; }
.src-page .ev h3 { font-size: 16px; display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; }
.ev-side { font: 700 10px/1 var(--display); text-transform: uppercase; letter-spacing: .1em; padding: 3px 6px; border: 1px solid currentColor; color: var(--mute); }
.ev-side.dem { color: var(--good); } .ev-side.afd { color: var(--afd); } .ev-side.risk { color: var(--bad); }
.ev-src { font-family: var(--ui); font-size: 13px; color: var(--mute); }
.src-list { margin: 6px 0 12px; padding-left: 20px; } .src-list li { margin: 4px 0; }

/* ───────── Handy-Feinschliff: schmale und niedrige Displays ───────── */
@media (max-width: 560px) {
  /* Kopfzeilen dürfen die Seite nicht verbreitern (sonst zoomt das Handy heraus) */
  .topbar { gap: 8px; }
  .brand .by { display: none; }
  .top-actions { gap: 6px; min-width: 0; }
  .online { padding: 7px 8px; gap: 5px; letter-spacing: .06em; }
  .gfx-btn { white-space: nowrap; letter-spacing: .06em; padding: 0 7px; }
  .topbar > * { min-width: 0; }
  .topbar .btn, .topbar .icon-btn { flex: none; white-space: nowrap; }
  .room-code { gap: 6px; }
  .room-code .lbl { display: none; }
  .room-code b { font-size: 22px; letter-spacing: .1em; }
  /* Säulen: nur Symbol + Wert, sonst überlappen sieben Namen */
  html.has3d .col-label { margin-top: 3px; left: -12px; right: -12px; }
  html.has3d .col-label .nm { display: none; }
  /* Parteileiste kompakter, damit alle sieben passen */
  .roster { gap: 3px; }
  .rchip { padding: 2px 5px 2px 2px; gap: 3px; font-size: 10.5px; }
  .rchip .emb.sm { --s: 18px; }
  /* Superkraft-Namen umbrechen statt abschneiden */
  .act-btn.sp .lb { font-size: 9.5px; letter-spacing: .02em; -webkit-hyphens: auto; hyphens: auto; overflow-wrap: anywhere; }
}
@media (max-width: 899px) and (max-height: 760px) {
  /* Kleine Handys: Aktionsleiste muss auch mit Tipp + Koalitionsangebot sichtbar bleiben */
  html.has3d .wall-wrap { min-height: 110px; }
  html.has3d .ticker { height: 46px; }
  .act-btn { min-height: 66px; padding: 6px 4px 5px; }
  .act-btn .ic { font-size: 22px; }
  .act-btn.inst { min-height: 42px; }
  .coach { padding: 8px 12px; font-size: 13px; line-height: 1.3; }
  .energy-row { margin-bottom: 6px; }
}
