/* Kopf an Kopf – EU Battle · Neon-Violett, für Handy & Tablet gebaut */
:root {
  --bg: #0a0414;
  --bg2: #160a2e;
  --panel: rgba(30, 12, 60, .72);
  --rand: rgba(190, 120, 255, .35);
  --neon: #b14dff;
  --neon2: #e05cff;
  --cyan: #3de8ff;
  --text: #f6efff;
  --muted: #b9a6d9;
  --a: #ff4fd8;
  --b: #3de8ff;
  --c: #a3ff4f;
  --ok: #39ff9a;
  --bad: #ff4f6d;
  --gold: #ffd84f;
  --radius: 18px;
  --glow: 0 0 6px rgba(177, 77, 255, .9), 0 0 22px rgba(177, 77, 255, .55), 0 0 48px rgba(224, 92, 255, .25);
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; min-height: 100dvh; color: var(--text);
  font: 17px/1.4 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  background:
    radial-gradient(ellipse 90% 55% at 50% -8%, rgba(177, 77, 255, .45), transparent 70%),
    radial-gradient(ellipse 60% 40% at 100% 100%, rgba(61, 232, 255, .14), transparent 70%),
    linear-gradient(180deg, var(--bg2), var(--bg) 60%);
  background-attachment: fixed;
  padding: max(12px, env(safe-area-inset-top)) max(14px, env(safe-area-inset-right)) max(20px, env(safe-area-inset-bottom)) max(14px, env(safe-area-inset-left));
}
body::before { /* Neon-Bühnenboden */
  content: ""; position: fixed; inset: auto 0 0 0; height: 38vh; pointer-events: none; z-index: -1; opacity: .35;
  background:
    repeating-linear-gradient(90deg, rgba(177,77,255,.5) 0 1px, transparent 1px 60px),
    repeating-linear-gradient(0deg, rgba(177,77,255,.5) 0 1px, transparent 1px 40px);
  transform: perspective(300px) rotateX(55deg); transform-origin: bottom;
  mask-image: linear-gradient(transparent, #000 70%);
}
.wrap { max-width: 760px; margin: 0 auto; }
.wrap.breit { max-width: 1180px; }

/* Kopf */
header.top { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.logo { flex: 1; min-width: 0; font-weight: 900; letter-spacing: .02em; line-height: 1; text-transform: uppercase; }
.logo .k { display: block; font-size: clamp(22px, 6.4vw, 36px); color: #fff; text-shadow: var(--glow); }
.logo .eu { display: inline-block; margin-top: 4px; font-size: clamp(12px, 3.3vw, 15px); letter-spacing: .32em; color: var(--cyan); text-shadow: 0 0 8px rgba(61,232,255,.8); }
.logo .eu b { color: var(--gold); text-shadow: 0 0 8px rgba(255,216,79,.8); }
.wer { font-size: 14px; color: var(--muted); text-align: right; }
.wer b { color: var(--text); display: block; font-size: 15px; }

/* Bausteine */
.panel { background: var(--panel); border: 1px solid var(--rand); border-radius: var(--radius); padding: 18px; margin-bottom: 14px;
  box-shadow: 0 0 0 1px rgba(177,77,255,.08) inset, 0 10px 40px rgba(0,0,0,.4); backdrop-filter: blur(8px); }
h1, h2, h3 { margin: 0 0 12px; line-height: 1.2; }
h2 { font-size: 20px; } h3 { font-size: 16px; color: var(--muted); text-transform: uppercase; letter-spacing: .1em; }
.muted { color: var(--muted); }
.mitte { text-align: center; }
.zeile { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.zeile > .wachsen { flex: 1; }
.versteckt { display: none !important; }

button, .btn {
  font: inherit; font-weight: 700; cursor: pointer; border: 0; border-radius: 14px;
  min-height: 52px; padding: 12px 20px; color: #fff; touch-action: manipulation; user-select: none;
  background: linear-gradient(135deg, var(--neon), var(--neon2));
  box-shadow: 0 0 18px rgba(177,77,255,.55), 0 0 0 1px rgba(255,255,255,.15) inset;
  transition: transform .08s, filter .15s, opacity .15s;
}
button:active { transform: scale(.97); }
button:disabled { opacity: .45; cursor: default; box-shadow: none; }
button.zweit { background: transparent; border: 1.5px solid var(--rand); box-shadow: none; color: var(--text); }
button.gefahr { background: transparent; border: 1.5px solid var(--bad); color: var(--bad); box-shadow: none; }
button.klein { min-height: 40px; padding: 6px 12px; font-size: 14px; border-radius: 10px; }
button.gross { width: 100%; min-height: 64px; font-size: 20px; }
button:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible { outline: 3px solid var(--cyan); outline-offset: 2px; }

label { display: block; font-size: 14px; color: var(--muted); margin: 12px 0 6px; }
input, textarea, select {
  width: 100%; font: inherit; font-size: 17px; /* ≥16px verhindert Zoom auf iPhone */
  color: var(--text); background: rgba(10, 4, 20, .7); border: 1.5px solid var(--rand); border-radius: 12px; padding: 13px 14px; min-height: 52px;
}
textarea { resize: vertical; min-height: 80px; }
.fehler { color: var(--bad); min-height: 1.4em; margin-top: 10px; font-weight: 600; }

.reiter { display: flex; gap: 6px; background: rgba(10,4,20,.6); padding: 5px; border-radius: 14px; margin-bottom: 14px; border: 1px solid var(--rand); }
.reiter button { flex: 1; min-height: 46px; background: transparent; box-shadow: none; color: var(--muted); padding: 8px 6px; font-size: 15px; }
.reiter button.aktiv { background: linear-gradient(135deg, var(--neon), var(--neon2)); color: #fff; box-shadow: 0 0 14px rgba(177,77,255,.6); }

/* Plätze */
.plaetze { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
@media (min-width: 640px) { .plaetze { grid-template-columns: repeat(4, 1fr); } }
.platz { border: 1.5px dashed var(--rand); border-radius: 16px; padding: 14px 10px; text-align: center; min-height: 92px; display: flex; flex-direction: column; justify-content: center; gap: 4px; }
.platz.belegt { border-style: solid; border-color: var(--neon); background: rgba(177,77,255,.14); box-shadow: 0 0 16px rgba(177,77,255,.35); }
.platz.ich { border-color: var(--cyan); box-shadow: 0 0 16px rgba(61,232,255,.45); }
.platz .n { font-weight: 800; font-size: 18px; overflow-wrap: anywhere; }
.platz .s { font-size: 13px; color: var(--muted); }
.punkt { display: inline-block; width: 9px; height: 9px; border-radius: 50%; background: #6b5a85; margin-right: 6px; vertical-align: middle; }
.punkt.an { background: var(--ok); box-shadow: 0 0 8px var(--ok); }

/* Frage */
.fragekopf { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; font-weight: 700; color: var(--muted); }
.timer { font-variant-numeric: tabular-nums; font-size: 22px; font-weight: 900; color: var(--cyan); text-shadow: 0 0 10px rgba(61,232,255,.8); }
.timer.knapp { color: var(--bad); text-shadow: 0 0 10px rgba(255,79,109,.9); animation: puls .5s infinite alternate; }
@keyframes puls { to { transform: scale(1.12); } }
.balken { height: 8px; border-radius: 99px; background: rgba(255,255,255,.08); overflow: hidden; margin-bottom: 16px; }
.balken > i { display: block; height: 100%; width: 100%; background: linear-gradient(90deg, var(--cyan), var(--neon2)); box-shadow: 0 0 10px var(--neon2); transform-origin: left; }
.fragetext { font-size: clamp(22px, 5.6vw, 32px); font-weight: 800; line-height: 1.25; margin: 6px 0 18px; text-align: center; overflow-wrap: anywhere; }
.antworten { display: grid; gap: 12px; }
@media (min-width: 900px) and (orientation: landscape) { .antworten.quer { grid-template-columns: repeat(3, 1fr); } }
.antwort {
  --f: var(--a); position: relative; display: flex; align-items: center; gap: 14px; width: 100%; text-align: left;
  min-height: 74px; padding: 14px 16px; border-radius: 18px; font-size: clamp(18px, 4.6vw, 22px); font-weight: 700; color: var(--text);
  background: rgba(10,4,20,.65); border: 2px solid var(--f); box-shadow: 0 0 14px color-mix(in srgb, var(--f) 45%, transparent), 0 0 0 1px rgba(255,255,255,.05) inset;
}
.antwort:nth-child(2) { --f: var(--b); } .antwort:nth-child(3) { --f: var(--c); }
.antwort .bu { flex: none; width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; font-weight: 900; font-size: 22px; color: #12061f; background: var(--f); box-shadow: 0 0 14px var(--f); }
.antwort .tx { flex: 1; overflow-wrap: anywhere; }
.antwort .wer2 { font-size: 13px; font-weight: 600; color: var(--muted); text-align: right; }
.antwort.gewaehlt { background: color-mix(in srgb, var(--f) 28%, rgba(10,4,20,.8)); box-shadow: 0 0 26px var(--f); }
.antwort.gedimmt { opacity: .35; }
.antwort.richtig { --f: var(--ok); opacity: 1; background: rgba(57,255,154,.18); animation: blink .6s 3; }
.antwort.falsch { --f: var(--bad); opacity: 1; }
.antwort:disabled { opacity: 1; }
.antwort.gedimmt:disabled { opacity: .35; }
@keyframes blink { 50% { box-shadow: 0 0 40px var(--ok); } }
.marke { position: absolute; top: -10px; right: 12px; font-size: 12px; font-weight: 800; padding: 2px 8px; border-radius: 99px; background: var(--f); color: #12061f; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin-top: 16px; }
.chip { padding: 6px 12px; border-radius: 99px; border: 1px solid var(--rand); font-size: 14px; color: var(--muted); }
.chip.fertig { color: #12061f; background: var(--cyan); border-color: var(--cyan); box-shadow: 0 0 10px rgba(61,232,255,.6); font-weight: 700; }

.meldung { text-align: center; font-size: clamp(24px, 7vw, 36px); font-weight: 900; margin: 6px 0 4px; }
.meldung.gut { color: var(--ok); text-shadow: 0 0 14px rgba(57,255,154,.8); }
.meldung.schlecht { color: var(--bad); text-shadow: 0 0 14px rgba(255,79,109,.7); }

/* Rangliste */
.rang { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.rang li { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 14px; background: rgba(10,4,20,.55); border: 1px solid var(--rand); }
.rang .pl { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; font-weight: 900; background: rgba(177,77,255,.25); flex: none; }
.rang li:first-child .pl { background: var(--gold); color: #12061f; box-shadow: 0 0 14px var(--gold); }
.rang .nm { flex: 1; font-weight: 700; overflow-wrap: anywhere; }
.rang .pk { font-weight: 900; font-variant-numeric: tabular-nums; color: var(--cyan); }
.rang .plus { color: var(--ok); font-size: 13px; font-weight: 700; margin-left: 6px; }
.rang li.ich { border-color: var(--cyan); }

.sieger { text-align: center; padding: 10px 0 18px; }
.sieger .krone { font-size: 56px; filter: drop-shadow(0 0 14px var(--gold)); }
.sieger .name { font-size: clamp(30px, 9vw, 48px); font-weight: 900; color: var(--gold); text-shadow: 0 0 18px rgba(255,216,79,.8); overflow-wrap: anywhere; }

.warte { display: inline-block; width: 10px; height: 10px; border-radius: 50%; background: var(--neon2); box-shadow: 0 0 10px var(--neon2); animation: puls .7s infinite alternate; margin-right: 8px; }
.verbindung { position: fixed; left: 50%; bottom: max(12px, env(safe-area-inset-bottom)); transform: translateX(-50%); background: var(--bad); color: #fff; font-weight: 700; padding: 8px 16px; border-radius: 99px; z-index: 9; font-size: 14px; }

/* Admin */
.raster { display: grid; gap: 14px; }
@media (min-width: 960px) { .raster { grid-template-columns: 1.35fr 1fr; align-items: start; } }
.steuer { display: grid; gap: 10px; grid-template-columns: 1fr 1fr; }
.steuer button { min-height: 58px; }
.steuer .voll { grid-column: 1 / -1; }
.live { display: grid; gap: 10px; }
.live .sp { display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: 14px; background: rgba(10,4,20,.55); border: 1px solid var(--rand); }
.live .sp .nm { flex: 1; font-weight: 700; min-width: 0; overflow-wrap: anywhere; }
.live .sp .st { font-size: 14px; color: var(--muted); text-align: right; }
.wahl { display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 10px; font-weight: 900; color: #12061f; }
.wahl.w0 { background: var(--a); } .wahl.w1 { background: var(--b); } .wahl.w2 { background: var(--c); }
.wahl.leer { background: transparent; border: 1.5px dashed var(--rand); color: var(--muted); }
.wahl.ok { box-shadow: 0 0 0 3px var(--ok); } .wahl.no { box-shadow: 0 0 0 3px var(--bad); }
.protokoll { max-height: 340px; overflow-y: auto; font-size: 14px; display: grid; gap: 6px; -webkit-overflow-scrolling: touch; }
.protokoll div { padding: 6px 10px; border-left: 3px solid var(--neon); background: rgba(10,4,20,.45); border-radius: 0 8px 8px 0; overflow-wrap: anywhere; }
.protokoll time { color: var(--muted); font-variant-numeric: tabular-nums; margin-right: 6px; }
.tabelle-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
table { border-collapse: collapse; width: 100%; font-size: 14px; }
th, td { padding: 8px; text-align: center; border-bottom: 1px solid rgba(190,120,255,.18); white-space: nowrap; }
th:first-child, td:first-child { text-align: left; }
.fliste { display: grid; gap: 10px; }
.fitem { padding: 14px; border-radius: 14px; background: rgba(10,4,20,.55); border: 1px solid var(--rand); }
.fitem .ft { font-weight: 700; margin-bottom: 8px; overflow-wrap: anywhere; }
.fitem ol { margin: 0 0 10px; padding-left: 0; list-style: none; display: grid; gap: 4px; font-size: 15px; }
.fitem li { overflow-wrap: anywhere; }
.fitem li.r { color: var(--ok); font-weight: 700; }
.fitem li.r::after { content: " ✓"; }
.ant-eingabe { display: grid; grid-template-columns: auto 1fr; gap: 10px; align-items: center; margin-bottom: 10px; }
.ant-eingabe .rb { display: flex; align-items: center; gap: 8px; min-height: 52px; padding: 0 12px; border-radius: 12px; border: 1.5px solid var(--rand); cursor: pointer; font-weight: 800; color: var(--text); margin: 0; }
.ant-eingabe .rb input { width: 22px; height: 22px; min-height: 0; accent-color: var(--ok); }
.ant-eingabe .rb:has(input:checked) { border-color: var(--ok); box-shadow: 0 0 10px rgba(57,255,154,.5); }
.hinweis { padding: 12px 14px; border-radius: 12px; border: 1px solid var(--gold); color: var(--gold); background: rgba(255,216,79,.08); margin-bottom: 14px; font-size: 15px; }
.phase { display: inline-block; padding: 4px 12px; border-radius: 99px; font-size: 13px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; background: rgba(61,232,255,.15); color: var(--cyan); border: 1px solid var(--cyan); }

/* Macher-Hinweis unten rechts */
body { padding-bottom: max(44px, calc(env(safe-area-inset-bottom) + 34px)); }
.macher {
  position: fixed; right: max(12px, env(safe-area-inset-right)); bottom: max(8px, env(safe-area-inset-bottom));
  z-index: 5; pointer-events: none; font-size: 12px; font-weight: 600; letter-spacing: .02em;
  color: var(--muted); background: rgba(10, 4, 20, .7); border: 1px solid var(--rand); border-radius: 99px; padding: 4px 12px;
  text-shadow: 0 0 6px rgba(177, 77, 255, .6);
}
.macher b { color: var(--neon2); font-weight: 800; }

@media (prefers-reduced-motion: reduce) { *, *::before { animation: none !important; transition: none !important; } }
