/* =========================================================
   Nerd4Flirt – Dark Neon UI
   Keine externen Schriften/CDNs: nur Systemschriften (DSGVO).
   ========================================================= */
:root {
  --bg: #07070f;
  --bg-2: #0d0d1c;
  --surface: #12122a;
  --surface-2: #1a1a38;
  --line: #2a2a55;
  --text: #ecebff;
  --muted: #a3a2c9;
  --cyan: #00f0ff;
  --pink: #ff2bd6;
  --purple: #9d4dff;
  --lime: #b6ff3b;
  --amber: #ffc53d;
  --red: #ff4d6d;
  --glow-cyan: 0 0 6px rgba(0, 240, 255, .55), 0 0 22px rgba(0, 240, 255, .25);
  --glow-pink: 0 0 6px rgba(255, 43, 214, .6), 0 0 24px rgba(255, 43, 214, .28);
  --glow-purple: 0 0 8px rgba(157, 77, 255, .6), 0 0 28px rgba(157, 77, 255, .25);
  --radius: 14px;
  --mono: ui-monospace, "Cascadia Code", "JetBrains Mono", "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
/* Das hidden-Attribut muss immer gewinnen, auch gegen display-Regeln einzelner Komponenten */
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background:
    radial-gradient(1200px 600px at 10% -10%, rgba(157, 77, 255, .16), transparent 60%),
    radial-gradient(900px 500px at 100% 0%, rgba(0, 240, 255, .10), transparent 60%),
    var(--bg);
  background-attachment: fixed;
  color: var(--text);
  font: 16px/1.6 var(--sans);
}
body::after { /* dezente Scanlines */
  content: "";
  pointer-events: none;
  position: fixed;
  inset: 0;
  background: repeating-linear-gradient(to bottom, rgba(255, 255, 255, .018) 0 1px, transparent 1px 3px);
  z-index: 100;
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }

a { color: var(--cyan); text-decoration-color: rgba(0, 240, 255, .4); text-underline-offset: 3px; }
a:hover { color: #fff; text-shadow: var(--glow-cyan); }
h1, h2, h3, h4 { font-family: var(--mono); line-height: 1.2; letter-spacing: -.01em; margin: 0 0 .6em; }
h1 { font-size: clamp(1.7rem, 4vw, 2.6rem); }
h2 { font-size: clamp(1.25rem, 2.6vw, 1.6rem); }
h3 { font-size: 1.1rem; }
p { margin: 0 0 1em; }
code, pre, kbd { font-family: var(--mono); }
code { background: var(--surface-2); padding: .1em .35em; border-radius: 5px; font-size: .9em; color: var(--lime); }
pre { background: #05050c; border: 1px solid var(--line); padding: 12px 14px; border-radius: 10px; overflow-x: auto; }
pre code { background: none; padding: 0; color: #d6ffd0; }
kbd { border: 1px solid var(--line); border-bottom-width: 3px; border-radius: 6px; padding: 0 .4em; font-size: .85em; background: var(--surface); }
blockquote { margin: .4em 0; padding: .3em .9em; border-left: 3px solid var(--purple); color: var(--muted); background: rgba(157, 77, 255, .06); }
hr { border: 0; border-top: 1px solid var(--line); margin: 2rem 0; }
img { max-width: 100%; display: block; }
:focus-visible { outline: 2px solid var(--cyan); outline-offset: 3px; border-radius: 6px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.neon-cyan { color: var(--cyan); text-shadow: var(--glow-cyan); }
.neon-pink { color: var(--pink); text-shadow: var(--glow-pink); }
.neon-purple { color: #c9a6ff; text-shadow: var(--glow-purple); }
.neon-lime { color: var(--lime); text-shadow: 0 0 10px rgba(182, 255, 59, .5); }
.muted { color: var(--muted); }
.small { font-size: .875rem; }
.mono { font-family: var(--mono); }
.center { text-align: center; }
.stack > * + * { margin-top: 1rem; }
.row { display: flex; gap: .75rem; flex-wrap: wrap; align-items: center; }
.row.between { justify-content: space-between; }
.grow { flex: 1; }

/* ---------- Layout ---------- */
.wrap { width: min(1120px, 100% - 32px); margin-inline: auto; }
.wrap.narrow { width: min(720px, 100% - 32px); }
main { flex: 1; padding: 28px 0 60px; }

.topbar {
  position: sticky; top: 0; z-index: 50;
  background: rgba(7, 7, 15, .82);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 1px 0 rgba(157, 77, 255, .25), 0 8px 30px rgba(0, 0, 0, .4);
}
.topbar .wrap { display: flex; align-items: center; gap: 16px; min-height: 62px; }
.logo { font: 800 1.35rem/1 var(--mono); text-decoration: none; color: #fff; letter-spacing: -.03em; white-space: nowrap; display: flex; align-items: center; gap: 8px; }
.logo:hover { text-shadow: none; color: #fff; }
.logo .four { color: var(--pink); text-shadow: var(--glow-pink); }
.logo .nerd { color: var(--cyan); text-shadow: var(--glow-cyan); }
.logo svg { width: 28px; height: 28px; filter: drop-shadow(0 0 6px rgba(255, 43, 214, .7)); }
.nav { display: flex; gap: 4px; margin-left: auto; align-items: center; flex-wrap: wrap; }
.nav a, .nav button.linklike {
  font: 600 .9rem var(--mono); color: var(--muted); text-decoration: none;
  padding: 8px 12px; border-radius: 10px; border: 1px solid transparent; position: relative;
}
.nav a:hover, .nav button.linklike:hover { color: #fff; background: var(--surface); text-shadow: none; }
.nav a.active { color: var(--cyan); border-color: rgba(0, 240, 255, .35); box-shadow: inset 0 0 12px rgba(0, 240, 255, .12); }
.nav form { margin: 0; }
.badge-count { display: inline-grid; place-items: center; min-width: 20px; height: 20px; padding: 0 6px; margin-left: 4px; border-radius: 99px; background: var(--pink); color: #fff; font-size: .72rem; box-shadow: var(--glow-pink); }
.nav-toggle { display: none; margin-left: auto; }
@media (max-width: 960px) {
  .nav-toggle { display: inline-flex; }
  .nav { display: none; width: 100%; flex-direction: column; align-items: stretch; padding-bottom: 12px; }
  .nav.open { display: flex; }
  .topbar .wrap { flex-wrap: wrap; }
  .nav a, .nav button.linklike { width: 100%; text-align: left; }
}

.footer { border-top: 1px solid var(--line); background: var(--bg-2); padding: 28px 0; font-size: .9rem; color: var(--muted); }
.footer .wrap { display: flex; flex-wrap: wrap; gap: 12px 24px; justify-content: space-between; }
.footer nav { display: flex; gap: 6px 18px; flex-wrap: wrap; }
.footer a { color: var(--muted); }
.footer a:hover { color: var(--cyan); }

/* ---------- Komponenten ---------- */
.card {
  background: linear-gradient(180deg, rgba(26, 26, 56, .85), rgba(18, 18, 42, .92));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, .35);
}
.card.glow { border-color: rgba(157, 77, 255, .55); box-shadow: var(--glow-purple), 0 10px 40px rgba(0, 0, 0, .4); }
.card + .card { margin-top: 18px; }
.card h2:first-child, .card h3:first-child { margin-top: 0; }
.grid { display: grid; gap: 18px; }
.grid.two { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.grid.three { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }

.btn {
  --c: var(--purple);
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font: 700 .95rem var(--mono); letter-spacing: .02em;
  padding: 11px 20px; border-radius: 12px; cursor: pointer; text-decoration: none;
  color: #fff; background: linear-gradient(120deg, var(--purple), var(--pink));
  border: 1px solid rgba(255, 255, 255, .15);
  box-shadow: 0 0 0 rgba(0, 0, 0, 0);
  transition: transform .15s ease, box-shadow .2s ease, filter .2s;
}
.btn:hover { color: #fff; transform: translateY(-1px); box-shadow: var(--glow-pink); text-shadow: none; filter: brightness(1.1); }
.btn:active { transform: translateY(1px); }
.btn[disabled], .btn.disabled { opacity: .45; pointer-events: none; }
.btn.ghost { background: transparent; border-color: var(--line); color: var(--text); }
.btn.ghost:hover { border-color: var(--cyan); box-shadow: var(--glow-cyan); }
.btn.cyan { background: linear-gradient(120deg, #00b5d8, var(--cyan)); color: #001018; }
.btn.cyan:hover { color: #001018; box-shadow: var(--glow-cyan); }
.btn.danger { background: linear-gradient(120deg, #b3133b, var(--red)); }
.btn.small { padding: 6px 12px; font-size: .82rem; border-radius: 9px; }
.btn.block { width: 100%; }
button.linklike { background: none; border: 0; cursor: pointer; padding: 0; color: var(--cyan); font: inherit; text-decoration: underline; text-underline-offset: 3px; }
.inline-form { display: inline; margin: 0; }

.pill { display: inline-flex; align-items: center; gap: 4px; padding: 3px 10px; border-radius: 99px; font: 600 .78rem var(--mono); border: 1px solid var(--line); background: var(--surface); color: var(--muted); }
.pill.shared { border-color: rgba(182, 255, 59, .6); color: var(--lime); box-shadow: 0 0 10px rgba(182, 255, 59, .18); }
.pill.verified { border-color: rgba(0, 240, 255, .6); color: var(--cyan); }
.pill.mod { border-color: rgba(255, 197, 61, .6); color: var(--amber); }
.pills { display: flex; flex-wrap: wrap; gap: 6px; }

.alert { padding: 12px 16px; border-radius: 12px; border: 1px solid; margin-bottom: 18px; }
.alert.ok { border-color: rgba(182, 255, 59, .5); background: rgba(182, 255, 59, .07); color: #e6ffc2; }
.alert.err { border-color: rgba(255, 77, 109, .6); background: rgba(255, 77, 109, .08); color: #ffd3dc; }
.alert.info { border-color: rgba(0, 240, 255, .45); background: rgba(0, 240, 255, .06); }
.alert.warn { border-color: rgba(255, 197, 61, .55); background: rgba(255, 197, 61, .07); color: #fff1cc; }
.alert ul { margin: 0; padding-left: 1.2em; }

/* ---------- Formulare ---------- */
label { display: block; font-weight: 600; margin-bottom: 6px; font-size: .95rem; }
.field { margin-bottom: 16px; }
.hint { font-size: .82rem; color: var(--muted); margin-top: 4px; }
input[type=text], input[type=email], input[type=password], input[type=date], input[type=datetime-local], input[type=number], input[type=search], select, textarea {
  width: 100%; padding: 11px 13px; border-radius: 10px;
  border: 1px solid var(--line); background: #0a0a18; color: var(--text);
  font: inherit; transition: border-color .15s, box-shadow .15s;
}
textarea { min-height: 120px; resize: vertical; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--cyan); box-shadow: var(--glow-cyan); }
input[type=file] { color: var(--muted); font: .9rem var(--mono); }
input[type=file]::file-selector-button { font: 600 .85rem var(--mono); padding: 8px 12px; margin-right: 10px; border-radius: 8px; border: 1px solid var(--line); background: var(--surface-2); color: var(--text); cursor: pointer; }
.check { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; margin-bottom: 12px; cursor: pointer; }
.check input { margin-top: 4px; width: 18px; height: 18px; accent-color: var(--pink); flex: none; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { position: relative; margin: 0; font-weight: 500; }
.chip input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.chip span { display: inline-block; padding: 6px 12px; border-radius: 99px; border: 1px solid var(--line); background: var(--surface); font: 600 .82rem var(--mono); color: var(--muted); transition: all .15s; }
.chip input:checked + span { color: #fff; border-color: var(--pink); background: rgba(255, 43, 214, .14); box-shadow: var(--glow-pink); }
.chip input:focus-visible + span { outline: 2px solid var(--cyan); outline-offset: 2px; }
.hp { position: absolute !important; left: -10000px !important; width: 1px; height: 1px; overflow: hidden; }
.pow-status { font: .82rem var(--mono); color: var(--muted); display: flex; align-items: center; gap: 8px; }
.pow-status::before { content: ""; width: 10px; height: 10px; border-radius: 50%; background: var(--amber); box-shadow: 0 0 8px var(--amber); animation: blink 1s infinite; }
.pow-status.done { color: var(--lime); }
.pow-status.done::before { background: var(--lime); box-shadow: 0 0 8px var(--lime); animation: none; }
@keyframes blink { 50% { opacity: .3; } }
fieldset { border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px 6px; margin: 0 0 16px; }
legend { font: 700 .85rem var(--mono); color: var(--cyan); padding: 0 6px; text-transform: uppercase; letter-spacing: .08em; }

/* ---------- Landingpage ---------- */
.hero { position: relative; overflow: hidden; padding: 70px 0 120px; margin-top: -28px; }
.hero::before { /* Synthwave-Gitter */
  content: ""; position: absolute; left: -50%; right: -50%; bottom: -10px; height: 300px;
  background:
    linear-gradient(transparent 0 0) ,
    repeating-linear-gradient(90deg, rgba(255, 43, 214, .45) 0 1px, transparent 1px 60px),
    repeating-linear-gradient(0deg, rgba(255, 43, 214, .45) 0 1px, transparent 1px 40px);
  transform: perspective(300px) rotateX(62deg);
  transform-origin: bottom;
  mask-image: linear-gradient(to top, #000 20%, transparent 95%);
  animation: grid 3s linear infinite;
}
@keyframes grid { to { background-position: 0 0, 0 0, 0 40px; } }
.hero::after { /* Sonne */
  content: ""; position: absolute; left: 50%; bottom: 170px; width: 300px; height: 150px; translate: -50% 0;
  border-radius: 300px 300px 0 0;
  background: repeating-linear-gradient(to bottom, transparent 0 8px, rgba(7, 7, 15, .9) 8px 11px), linear-gradient(to bottom, var(--amber), var(--pink) 70%);
  filter: drop-shadow(0 0 40px rgba(255, 43, 214, .6));
  opacity: .55; z-index: 0;
}
.hero .wrap { position: relative; z-index: 1; text-align: center; }
.hero h1 { font-size: clamp(2.2rem, 7vw, 4.6rem); margin-bottom: .2em; }
.hero .tagline { font: 1.15rem/1.5 var(--mono); color: var(--muted); max-width: 660px; margin: 0 auto 28px; }
.glitch { position: relative; display: inline-block; }
.glitch::before, .glitch::after { content: attr(data-text); position: absolute; inset: 0; overflow: hidden; }
.glitch::before { color: var(--cyan); translate: 2px 0; clip-path: inset(0 0 60% 0); animation: glitch 3.5s infinite steps(1); opacity: .8; }
.glitch::after { color: var(--pink); translate: -2px 0; clip-path: inset(55% 0 0 0); animation: glitch 2.7s infinite reverse steps(1); opacity: .8; }
@keyframes glitch { 0%, 92%, 100% { translate: 0 0; } 93% { translate: 3px -1px; } 95% { translate: -3px 1px; } 97% { translate: 1px 2px; } }
.terminal { font: .95rem/1.7 var(--mono); text-align: left; max-width: 560px; margin: 0 auto 30px; background: rgba(5, 5, 12, .85); border: 1px solid var(--line); border-radius: 12px; padding: 14px 18px; box-shadow: var(--glow-cyan); }
.terminal .prompt { color: var(--lime); }
.terminal .cursor { display: inline-block; width: .6em; height: 1.1em; background: var(--cyan); vertical-align: text-bottom; animation: blink 1s steps(1) infinite; }
.stats-strip { display: flex; justify-content: center; gap: 30px; flex-wrap: wrap; margin-top: 34px; font-family: var(--mono); }
.stats-strip b { display: block; font-size: 1.8rem; color: #fff; text-shadow: var(--glow-purple); }
.press-strip { margin: 18px auto 0; max-width: 720px; line-height: 1.5; }
.press-strip a { color: var(--text); }
.feature { text-align: left; }
.feature .icon { font-size: 2rem; margin-bottom: 6px; }
.class-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.class-tile { padding: 14px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface); text-align: center; font: 600 .85rem var(--mono); transition: all .2s; }
.class-tile:hover { border-color: var(--cyan); box-shadow: var(--glow-cyan); transform: translateY(-2px); }
.class-tile .ico { font-size: 1.8rem; display: block; }

/* ---------- Discover / Charakterauswahl ---------- */
.discover { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 24px; align-items: start; }
@media (max-width: 900px) { .discover { grid-template-columns: 1fr; } .discover aside { order: 2; } }
.deck { position: relative; height: 640px; max-width: 440px; margin: 0 auto; perspective: 1200px; }
@media (max-width: 520px) { .deck { height: 600px; } }
.deck-empty { position: absolute; inset: 0; display: grid; place-items: center; text-align: center; padding: 30px; border: 2px dashed var(--line); border-radius: 22px; }
.pcard {
  position: absolute; inset: 0; border-radius: 22px; overflow: hidden;
  background: linear-gradient(180deg, #16163a, #0c0c20);
  border: 2px solid rgba(157, 77, 255, .7);
  box-shadow: var(--glow-purple), 0 20px 60px rgba(0, 0, 0, .6);
  touch-action: pan-y; user-select: none; cursor: grab;
  display: flex; flex-direction: column;
  transition: transform .35s cubic-bezier(.2, .8, .2, 1), opacity .35s;
}
.pcard.dragging { transition: none; cursor: grabbing; }
.pcard.behind { transform: scale(.95) translateY(14px); filter: brightness(.6); pointer-events: none; }
.pcard.fly-right { transform: translateX(140%) rotate(24deg) !important; opacity: 0; }
.pcard.fly-left { transform: translateX(-140%) rotate(-24deg) !important; opacity: 0; }
.pcard.fly-up { transform: translateY(-140%) scale(1.05) !important; opacity: 0; }
.pcard .photo { position: relative; flex: 0 0 52%; background: #05050c; overflow: hidden; }
.pcard .photo img { width: 100%; height: 100%; object-fit: cover; pointer-events: none; }
.pcard .photo::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, #0c0c20 2%, transparent 45%); }
.pcard .dots { position: absolute; top: 10px; left: 10px; right: 10px; display: flex; gap: 4px; z-index: 2; }
.pcard .dots i { flex: 1; height: 3px; border-radius: 3px; background: rgba(255, 255, 255, .3); }
.pcard .dots i.on { background: #fff; box-shadow: 0 0 6px #fff; }
.pcard .photo-nav { position: absolute; inset: 0; display: flex; z-index: 2; }
.pcard .photo-nav button { flex: 1; background: none; border: 0; cursor: pointer; }
.pcard .head { position: absolute; left: 18px; right: 18px; bottom: 10px; z-index: 3; }
.pcard .head h2 { margin: 0; font-size: 1.7rem; text-shadow: 0 2px 10px #000; }
.pcard .lvl { font: 700 .82rem var(--mono); color: var(--lime); text-shadow: 0 0 8px rgba(182, 255, 59, .6); }
.pcard .body { padding: 12px 18px 18px; overflow-y: auto; flex: 1; scrollbar-width: thin; }
.pcard .class { font: 700 .85rem var(--mono); color: var(--cyan); }
.pcard .quest { font-size: .9rem; color: var(--amber); margin: 6px 0; font-family: var(--mono); }
.pcard .bio { font-size: .92rem; color: #d6d5f5; margin: 8px 0 10px; white-space: pre-line; }
.compat { position: absolute; top: 22px; right: 14px; z-index: 3; text-align: center; font: 800 1.2rem/1 var(--mono); color: var(--lime); background: rgba(5, 5, 12, .8); border: 1px solid rgba(182, 255, 59, .6); padding: 8px 10px; border-radius: 12px; box-shadow: 0 0 14px rgba(182, 255, 59, .3); }
.compat small { display: block; font-size: .6rem; color: var(--muted); font-weight: 600; letter-spacing: .1em; margin-top: 3px; }
.super-banner { position: absolute; top: 22px; left: 14px; z-index: 3; font: 800 .78rem var(--mono); color: #001018; background: var(--amber); padding: 6px 10px; border-radius: 8px; box-shadow: 0 0 16px var(--amber); }
.stamp { position: absolute; top: 90px; z-index: 5; font: 900 2rem var(--mono); padding: 6px 14px; border: 4px solid; border-radius: 12px; opacity: 0; transform: rotate(-14deg); pointer-events: none; text-transform: uppercase; }
.stamp.like { left: 22px; color: var(--lime); border-color: var(--lime); text-shadow: 0 0 10px var(--lime); box-shadow: 0 0 20px rgba(182, 255, 59, .4); }
.stamp.nope { right: 22px; color: var(--red); border-color: var(--red); transform: rotate(14deg); text-shadow: 0 0 10px var(--red); }
.stamp.super { left: 50%; top: 40%; translate: -50% 0; transform: none; color: var(--amber); border-color: var(--amber); text-shadow: 0 0 10px var(--amber); }

.statblock { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px 14px; margin: 10px 0; }
.stat { font: .72rem var(--mono); color: var(--muted); }
.stat b { color: #fff; font-size: .8rem; }
.stat progress { display: block; width: 100%; height: 6px; border: 0; border-radius: 6px; background: #22224a; overflow: hidden; appearance: none; margin-top: 2px; }
.stat progress::-webkit-progress-bar { background: #22224a; border-radius: 6px; }
.stat progress::-webkit-progress-value { background: linear-gradient(90deg, var(--purple), var(--cyan)); border-radius: 6px; box-shadow: 0 0 8px var(--cyan); }
.stat progress::-moz-progress-bar { background: linear-gradient(90deg, var(--purple), var(--cyan)); border-radius: 6px; }

.actions { display: flex; justify-content: center; align-items: center; gap: 18px; margin: 22px auto 0; }
.act { width: 64px; height: 64px; border-radius: 50%; border: 2px solid; background: rgba(10, 10, 24, .9); font-size: 1.6rem; cursor: pointer; display: grid; place-items: center; transition: transform .15s, box-shadow .2s; color: #fff; }
.act:hover { transform: scale(1.1); }
.act:active { transform: scale(.94); }
.act.nope { border-color: var(--red); color: var(--red); box-shadow: 0 0 14px rgba(255, 77, 109, .35); }
.act.like { border-color: var(--lime); color: var(--lime); width: 76px; height: 76px; font-size: 2rem; box-shadow: 0 0 18px rgba(182, 255, 59, .35); }
.act.super { border-color: var(--amber); color: var(--amber); box-shadow: 0 0 14px rgba(255, 197, 61, .35); }
.act.undo { border-color: var(--line); color: var(--muted); width: 48px; height: 48px; font-size: 1.1rem; }
.act-label { font: .7rem var(--mono); color: var(--muted); text-align: center; margin-top: 4px; }
.act-wrap { display: flex; flex-direction: column; align-items: center; }
.mana { margin-top: 6px; }
.mana .bar { height: 10px; border-radius: 10px; background: #1b1b3c; overflow: hidden; border: 1px solid var(--line); }
.mana .bar progress { width: 100%; height: 100%; display: block; border: 0; appearance: none; background: transparent; }
.mana .bar progress::-webkit-progress-bar { background: transparent; }
.mana .bar progress::-webkit-progress-value { background: linear-gradient(90deg, #2b6cff, var(--cyan)); box-shadow: 0 0 10px var(--cyan); }
.mana .bar progress::-moz-progress-bar { background: linear-gradient(90deg, #2b6cff, var(--cyan)); }

.match-overlay { position: fixed; inset: 0; z-index: 200; display: none; place-items: center; background: rgba(5, 5, 12, .9); backdrop-filter: blur(6px); text-align: center; padding: 20px; }
.match-overlay.show { display: grid; animation: pop .4s ease; }
.match-overlay h2 { font-size: clamp(2.2rem, 8vw, 4rem); margin: 0 0 6px; }
@keyframes pop { from { opacity: 0; transform: scale(.9); } }
.toast { position: fixed; left: 50%; bottom: 24px; translate: -50% 0; z-index: 210; background: var(--surface-2); border: 1px solid var(--pink); color: #fff; padding: 12px 18px; border-radius: 12px; box-shadow: var(--glow-pink); font: .9rem var(--mono); max-width: calc(100% - 32px); display: none; }
.toast.show { display: block; animation: pop .25s ease; }

/* ---------- Profil ---------- */
.profile-head { display: grid; grid-template-columns: 300px 1fr; gap: 24px; }
@media (max-width: 760px) { .profile-head { grid-template-columns: 1fr; } }
.gallery { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.gallery img, .gallery .ph { aspect-ratio: 3/4; width: 100%; object-fit: cover; border-radius: 10px; border: 1px solid var(--line); }
.gallery .main { grid-column: span 3; aspect-ratio: 4/5; }
.ph { display: grid; place-items: center; background: var(--surface); color: var(--muted); font-size: 2.5rem; }
.photo-edit { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 12px; }
.photo-edit figure { margin: 0; position: relative; }
.photo-edit img { aspect-ratio: 3/4; object-fit: cover; border-radius: 10px; border: 1px solid var(--line); width: 100%; }
.photo-edit figure.first img { border-color: var(--pink); box-shadow: var(--glow-pink); }
.photo-edit figcaption { display: flex; gap: 6px; margin-top: 6px; flex-wrap: wrap; }
.statedit { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.statedit label { font: 700 .82rem var(--mono); }
.statedit label span { color: var(--muted); font-weight: 400; display: block; font-size: .72rem; }
.points { font: 700 .9rem var(--mono); }
.points.over { color: var(--red); }
.avatar { width: 46px; height: 46px; border-radius: 50%; object-fit: cover; border: 2px solid var(--purple); box-shadow: var(--glow-purple); flex: none; background: var(--surface); display: grid; place-items: center; }

/* ---------- Matches & Chat ---------- */
.match-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.match-list a { display: flex; gap: 14px; align-items: center; padding: 12px 14px; border-radius: 12px; background: var(--surface); border: 1px solid var(--line); text-decoration: none; color: var(--text); }
.match-list a:hover { border-color: var(--cyan); box-shadow: var(--glow-cyan); text-shadow: none; }
.match-list .preview { color: var(--muted); font-size: .88rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chat { display: flex; flex-direction: column; height: calc(100vh - 210px); min-height: 420px; }
.chat-log { flex: 1; overflow-y: auto; padding: 14px; display: flex; flex-direction: column; gap: 8px; background: rgba(5, 5, 12, .6); border: 1px solid var(--line); border-radius: 14px; }
.msg { max-width: 78%; padding: 9px 13px; border-radius: 14px; white-space: pre-wrap; word-wrap: break-word; font-size: .95rem; position: relative; }
.msg.theirs { align-self: flex-start; background: var(--surface-2); border: 1px solid var(--line); border-bottom-left-radius: 4px; }
.msg.mine { align-self: flex-end; background: linear-gradient(120deg, rgba(157, 77, 255, .55), rgba(255, 43, 214, .45)); border-bottom-right-radius: 4px; }
.msg time { display: block; font: .68rem var(--mono); color: rgba(255, 255, 255, .55); margin-top: 3px; }
.msg.flagged { border-color: var(--amber); }
.msg .warn { display: block; font: .72rem var(--mono); color: var(--amber); margin-top: 4px; }
.chat-form { display: flex; gap: 10px; margin-top: 12px; }
.chat-form textarea { min-height: 48px; height: 48px; }

/* ---------- Forum ---------- */
.forum-cats { display: grid; gap: 10px; }
.forum-cat { display: grid; grid-template-columns: 54px 1fr auto; gap: 16px; align-items: center; padding: 16px 18px; border-radius: 14px; background: var(--surface); border: 1px solid var(--line); text-decoration: none; color: var(--text); transition: all .15s; }
.forum-cat:hover { border-color: var(--purple); box-shadow: var(--glow-purple); text-shadow: none; color: var(--text); }
.forum-cat .ico { font-size: 2rem; text-align: center; filter: drop-shadow(0 0 8px rgba(157, 77, 255, .6)); }
.forum-cat h3 { margin: 0 0 2px; color: #fff; }
.forum-cat .meta { text-align: right; font: .78rem var(--mono); color: var(--muted); }
@media (max-width: 640px) { .forum-cat { grid-template-columns: 40px 1fr; } .forum-cat .meta { display: none; } }
.threads { width: 100%; border-collapse: collapse; }
.threads th, .threads td { padding: 12px 10px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.threads th { font: 700 .75rem var(--mono); color: var(--muted); text-transform: uppercase; letter-spacing: .08em; }
.threads td.num { text-align: right; font-family: var(--mono); color: var(--muted); white-space: nowrap; }
.threads a.t { font-weight: 600; color: #fff; text-decoration: none; }
.threads a.t:hover { color: var(--cyan); }
.post { display: grid; grid-template-columns: 170px 1fr; border: 1px solid var(--line); border-radius: 14px; overflow: hidden; background: var(--surface); }
.post + .post { margin-top: 14px; }
.post.hidden-post { opacity: .5; border-style: dashed; }
.post .author { padding: 16px; background: rgba(5, 5, 12, .5); border-right: 1px solid var(--line); font-size: .85rem; }
.post .author a { font: 700 1rem var(--mono); text-decoration: none; }
.post .content { padding: 16px 18px; min-width: 0; }
.post .content .text { overflow-wrap: anywhere; }
.post .tools { margin-top: 12px; display: flex; gap: 14px; font: .78rem var(--mono); color: var(--muted); flex-wrap: wrap; align-items: center; }
@media (max-width: 640px) { .post { grid-template-columns: 1fr; } .post .author { border-right: 0; border-bottom: 1px solid var(--line); display: flex; gap: 10px; flex-wrap: wrap; align-items: center; } }
.spoiler { background: #000; color: transparent; border-radius: 4px; padding: 0 4px; cursor: pointer; transition: color .2s; }
.spoiler:hover, .spoiler:focus, .spoiler.open { color: var(--text); background: var(--surface-2); }
.breadcrumbs { font: .82rem var(--mono); color: var(--muted); margin-bottom: 10px; }
.breadcrumbs a { color: var(--muted); }
.pager { display: flex; gap: 6px; margin: 18px 0; flex-wrap: wrap; }
.pager a, .pager span { padding: 6px 12px; border-radius: 8px; border: 1px solid var(--line); font: .85rem var(--mono); text-decoration: none; }
.pager span.cur { border-color: var(--cyan); color: var(--cyan); }

/* ---------- Rechtstexte ---------- */
.legal h2 { margin-top: 2rem; color: var(--cyan); font-size: 1.2rem; }
.legal h3 { margin-top: 1.4rem; color: #c9a6ff; font-size: 1rem; }
.legal p, .legal li { color: #d8d7f2; }
.legal table { border-collapse: collapse; width: 100%; font-size: .9rem; margin: 10px 0 18px; display: block; overflow-x: auto; }
.legal th, .legal td { border: 1px solid var(--line); padding: 8px 10px; text-align: left; vertical-align: top; }
.legal th { background: var(--surface-2); font-family: var(--mono); font-size: .8rem; }
.toc { columns: 2 240px; font-size: .9rem; }

/* ---------- Admin ---------- */
.admin-table { width: 100%; border-collapse: collapse; font-size: .88rem; }
.admin-table th, .admin-table td { border-bottom: 1px solid var(--line); padding: 8px; text-align: left; vertical-align: top; }
.admin-table th { font: 700 .74rem var(--mono); color: var(--muted); text-transform: uppercase; }
.table-scroll { overflow-x: auto; }
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; margin-bottom: 18px; }
.kpi { padding: 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); font-family: var(--mono); }
.kpi b { display: block; font-size: 1.6rem; color: var(--cyan); text-shadow: var(--glow-cyan); }
.quote-box { background: #05050c; border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; white-space: pre-wrap; max-height: 160px; overflow: auto; font-size: .85rem; margin: 6px 0; }
.verify-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.verify-grid img { width: 100%; aspect-ratio: 3/4; object-fit: cover; border-radius: 10px; border: 1px solid var(--line); }
.row.centered { justify-content: center; }
.h-chat { margin: 0; font-size: 1.3rem; }

/* Easter Egg */
body.konami { animation: hue 6s linear infinite; }
@keyframes hue { to { filter: hue-rotate(360deg); } }

/* Korrekturen */
.btn.nav-toggle { display: none; }
@media (max-width: 960px) { .btn.nav-toggle { display: inline-flex; } }
.nav a.btn { color: #fff; }
.nav a.btn:hover { background: linear-gradient(120deg, var(--purple), var(--pink)); }
.grid.three { grid-template-columns: repeat(auto-fit, minmax(290px, 1fr)); }
.hero::after { opacity: .35; bottom: 140px; }
@media (max-width: 520px) { .deck { height: 560px; } .act { width: 56px; height: 56px; } .act.like { width: 66px; height: 66px; } }
.support-card { margin-top: 24px; text-align: center; }
@media (min-width: 961px) { .nav .nav-label { display: none; } }
.faq { border: 1px solid var(--line); border-radius: 12px; background: var(--surface); margin: 8px 0; }
.faq summary { cursor: pointer; padding: 12px 16px; font-weight: 600; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::before { content: "▸ "; color: var(--cyan); font-family: var(--mono); }
.faq[open] summary::before { content: "▾ "; }
.faq[open] { border-color: rgba(0, 240, 255, .4); }
.faq p { padding: 0 16px 14px; margin: 0; }
.toc ol { margin: 0; } .toc li { break-inside: avoid; }

/* SEO-/Inhaltsseiten */
.lead-text { font-size: 1.12rem; color: #d8d7f2; max-width: 70ch; }
.article h2 { margin-top: 2rem; color: var(--cyan); }
.article ul li { margin-bottom: 6px; }
.article header { margin-bottom: 1.5rem; }
.check-list { list-style: none; padding: 0; }
.check-list li { padding-left: 1.6em; position: relative; }
.check-list li::before { content: "✔"; position: absolute; left: 0; color: var(--lime); text-shadow: 0 0 8px rgba(182, 255, 59, .5); }
.theme-tile { display: block; text-decoration: none; color: var(--text); transition: border-color .15s, box-shadow .15s, transform .15s; }
.theme-tile:hover { color: var(--text); text-shadow: none; border-color: var(--cyan); box-shadow: var(--glow-cyan); transform: translateY(-2px); }
.theme-tile .ico { font-size: 2rem; }
.theme-tile h2 { font-size: 1.15rem; margin: 6px 0; color: #fff; }
.link-list { list-style: none; padding: 0; display: grid; gap: 8px; }
.cta-box { margin: 2.5rem 0 1.5rem; }
.small-h { font-size: 1rem; color: var(--muted); }
.centered-pills { justify-content: center; }
a.pill { text-decoration: none; }
a.pill:hover { border-color: var(--cyan); color: var(--cyan); text-shadow: none; }

/* 2FA & Passkeys */
.qr-box { background: #fff; padding: 12px; border-radius: 12px; width: min(240px, 100%); margin: 12px 0; box-shadow: var(--glow-cyan); }
.qr-box svg { display: block; width: 100%; height: auto; }
.setup-steps > li { margin-bottom: 18px; }
.secret { font-size: 1rem; letter-spacing: .08em; word-break: break-all; }
.code-input { max-width: 170px; font: 700 1.4rem var(--mono); letter-spacing: .2em; text-align: center; }
.codes { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; }
.codes code { display: block; text-align: center; font-size: 1.05rem; padding: 8px; }
.key-list { list-style: none; padding: 0; display: grid; gap: 10px; }
.key-list li { display: flex; flex-wrap: wrap; gap: 10px; justify-content: space-between; align-items: center; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; background: rgba(5, 5, 12, .5); }
.key-list input[type=password] { width: 150px; }
.recovery-form { padding: 0 16px 14px; }
.passkey-login { margin-top: 14px; }

/* Neuigkeiten & Roadmap */
.roadmap { list-style: none; padding: 0; display: grid; gap: 12px; }
.roadmap li { display: grid; grid-template-columns: 120px 1fr; gap: 12px; align-items: start; }
@media (max-width: 520px) { .roadmap li { grid-template-columns: 1fr; gap: 4px; } }
.status-lime { border-color: rgba(182, 255, 59, .6); color: var(--lime); }
.status-cyan { border-color: rgba(0, 240, 255, .5); color: var(--cyan); }
.status-purple { border-color: rgba(157, 77, 255, .6); color: #c9a6ff; }
.roadmap-arbeit .status-lime { animation: blink 2s infinite; }
.changelog-h { margin-top: 2rem; }
.release h3 { margin: 0; }
.release-items { list-style: none; padding: 0; margin: 12px 0 0; display: grid; gap: 8px; }
.release-items .pill { min-width: 64px; justify-content: center; }

/* Interessen-Suche */
#interest-filter { margin: 4px 0 8px; }
.realm-group h3 { margin: 14px 0 8px; }
.chip[hidden], .realm-group[hidden] { display: none; }
.statedit label span { line-height: 1.35; margin: 2px 0 4px; }

/* Beta */
.beta-banner { background: linear-gradient(90deg, rgba(157, 77, 255, .18), rgba(0, 240, 255, .1)); border-bottom: 1px solid rgba(157, 77, 255, .4); font-size: .9rem; margin: -28px 0 24px; }
.beta-banner .wrap { display: flex; gap: 10px 16px; align-items: center; justify-content: space-between; flex-wrap: wrap; padding: 10px 0; }
.beta-actions { display: flex; gap: 8px; align-items: center; }
.beta-close { background: none; border: 1px solid var(--line); color: var(--muted); border-radius: 8px; width: 32px; height: 32px; cursor: pointer; }
.beta-close:hover { color: #fff; border-color: var(--pink); }
.pill.founder { border-color: rgba(255, 197, 61, .6); color: var(--amber); }
.beta-hero { margin: 0 0 18px; font-size: .95rem; }
.empty-actions { display: flex; flex-direction: column; gap: 8px; align-items: center; margin: 14px 0; }

/* Leitspruch */
.hero .claim { font: 800 clamp(1.3rem, 3.6vw, 2.2rem)/1.2 var(--mono); color: #fff; margin: -4px 0 14px; letter-spacing: -.02em; }

/* Forum: Zitate & Erwähnungen */
.post .content blockquote { margin: .6em 0; padding: .5em .9em; border-left: 3px solid var(--cyan); background: rgba(0, 240, 255, .05); border-radius: 0 8px 8px 0; color: #c9c8ea; }
.post .content blockquote strong:first-child { color: var(--cyan); }
a.post-ref { font-family: var(--mono); font-size: .9em; }
a.ext { overflow-wrap: anywhere; }
a.ext::after { content: ' ↗'; font-size: .8em; opacity: .7; }
a.mention { color: var(--pink); text-decoration: none; font-weight: 600; }
a.mention:hover { text-shadow: var(--glow-pink); }

/* Tastatur-Hinweise nur auf Geräten mit Maus/Tastatur */
@media (hover: none) and (pointer: coarse) { .kbd-hint { display: none; } }

/* ---------- Loot-Kalender ---------- */
.advent h1 { margin-bottom: .3rem; }
.advent-teaser { margin: 18px auto; max-width: 720px; }
.advent-reveal { scroll-margin-top: 90px; display: flex; gap: 22px; align-items: center; margin: 18px 0; animation: loot-in .6s ease-out; }
.advent-reveal h2 { margin: .2rem 0 .6rem; }
.advent-q { font-size: 1.15rem; font-weight: 600; margin: .2rem 0 1rem; }
.sticker-xl { width: 150px; height: 150px; flex: 0 0 auto; filter: drop-shadow(0 0 18px rgba(255, 43, 214, .45)); animation: loot-spin .9s ease-out; }
.sticker-sm { width: 44px; height: 44px; }
@keyframes loot-in { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
@keyframes loot-spin { from { transform: scale(.3) rotate(-25deg); opacity: 0; } 70% { transform: scale(1.08) rotate(4deg); opacity: 1; } to { transform: none; } }
@media (max-width: 600px) { .advent-reveal { flex-direction: column; text-align: center; } }

.advent-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 12px; margin: 22px 0; }
@media (max-width: 760px) { .advent-grid { grid-template-columns: repeat(4, 1fr); } }
@media (max-width: 420px) { .advent-grid { grid-template-columns: repeat(3, 1fr); gap: 9px; } }
.advent-grid form { margin: 0; }
.door { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; width: 100%; aspect-ratio: 1; border-radius: 16px; border: 2px solid var(--line); background: linear-gradient(145deg, var(--surface-2), var(--surface)); color: var(--text); font: 700 1.5rem var(--mono); text-decoration: none; padding: 0; }
.door .hint { font: 600 .68rem var(--mono); color: var(--muted); text-transform: uppercase; letter-spacing: .05em; }
.door.locked { opacity: .55; }
.door.ready { cursor: pointer; border-color: rgba(182, 255, 59, .6); color: var(--lime); box-shadow: 0 0 12px rgba(182, 255, 59, .18); transition: transform .15s, box-shadow .15s; }
.door.ready:hover, .door.ready:focus-visible { transform: translateY(-2px) rotate(-1deg); box-shadow: 0 0 22px rgba(182, 255, 59, .4); }
.door.today { border-color: var(--pink); color: var(--pink); box-shadow: var(--glow-pink); animation: door-pulse 1.8s ease-in-out infinite; }
.door.today .hint { color: var(--pink); }
@keyframes door-pulse { 50% { box-shadow: 0 0 4px rgba(255, 43, 214, .4), 0 0 30px rgba(255, 43, 214, .45); } }
.door.opened { border-color: rgba(0, 240, 255, .35); background: var(--surface); }
.door.opened img { width: 82%; height: 82%; }
.door.opened .num { position: absolute; top: 4px; left: 8px; font-size: .75rem; color: var(--muted); }
.door.opened:hover { border-color: var(--cyan); text-shadow: none; }
@media (prefers-reduced-motion: reduce) { .door.today, .advent-reveal, .sticker-xl { animation: none; } }

.advent-progress progress { width: 100%; height: 10px; border: 0; border-radius: 8px; background: #22224a; appearance: none; overflow: hidden; }
.advent-progress progress::-webkit-progress-bar { background: #22224a; }
.advent-progress progress::-webkit-progress-value { background: linear-gradient(90deg, var(--pink), var(--cyan)); }
.advent-progress progress::-moz-progress-bar { background: linear-gradient(90deg, var(--pink), var(--cyan)); }

.sticker-pick { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 10px; margin: 12px 0 16px; }
.sticker-opt { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 8px 4px; border: 1px solid var(--line); border-radius: 12px; cursor: pointer; text-align: center; }
.sticker-opt input { position: absolute; opacity: 0; pointer-events: none; }
.sticker-opt:has(input:checked) { border-color: var(--lime); box-shadow: 0 0 12px rgba(182, 255, 59, .3); }
.sticker-opt:has(input:focus-visible) { outline: 2px solid var(--cyan); }
.sticker-opt { position: relative; }
.sticker-opt:has(input:checked)::after { content: '✔'; position: absolute; top: 4px; right: 8px; color: var(--lime); font-weight: 700; }
.vitrine { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.vitrine img { width: 40px; height: 40px; }
.pcard .vitrine img { width: 34px; height: 34px; }
.pill.completionist { border-color: rgba(0, 240, 255, .6); color: var(--cyan); box-shadow: 0 0 10px rgba(0, 240, 255, .2); }
.advent-card { border-color: rgba(255, 43, 214, .5); }
#sammlung { scroll-margin-top: 90px; }
.mod-tools { display: flex; flex-direction: column; gap: 6px; align-items: flex-end; }
.mod-tools form { margin: 0; flex-wrap: wrap; justify-content: flex-end; }
.mod-tools select { width: auto; max-width: 240px; padding-top: 6px; padding-bottom: 6px; }
.mod-tools form.row { flex-wrap: nowrap; align-items: center; gap: 6px; }

/* Forum: Suche & Team-Lounge */
.forum-search { margin: 6px 0 18px; gap: 8px; }
.search-results { display: grid; gap: 10px; }
.search-hit { display: grid; gap: 4px; text-decoration: none; color: var(--text); }
.search-hit:hover { border-color: var(--cyan); text-shadow: none; }
.search-hit mark { background: rgba(255, 197, 61, .25); color: var(--amber); border-radius: 3px; padding: 0 2px; }
.forum-cat.staff { border-color: rgba(255, 197, 61, .45); }

/* Feedback vollständig anzeigen */
.quote-box.full { max-height: none; }

/* ---------- Mini-Dates ---------- */
.minidates { margin: 10px 0; padding: 12px 16px; }
.minidates summary { cursor: pointer; list-style: none; }
.minidates summary::-webkit-details-marker { display: none; }
.minidates summary::before { content: '▸ '; color: var(--muted); }
.minidates[open] summary::before { content: '▾ '; }
.game-list { list-style: none; padding: 0; margin: 10px 0; display: grid; gap: 6px; }
.game-list a { display: flex; justify-content: space-between; gap: 10px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 10px; text-decoration: none; color: var(--text); }
.game-list a:hover { border-color: var(--cyan); text-shadow: none; }
.game-new { margin-top: 8px; gap: 8px; flex-wrap: wrap; }
.game-new select { width: auto; flex: 1; min-width: 180px; }
.game-status { text-align: center; font-size: 1.15rem; margin: 14px 0; padding: 10px; border: 1px dashed var(--line); border-radius: 12px; }
.game-status.mine { border-color: var(--lime); color: var(--lime); box-shadow: 0 0 14px rgba(182, 255, 59, .2); }
.game-actions { margin-top: 22px; gap: 10px; }
.rps-score { text-align: center; font-size: 1.6rem; margin: 6px 0 14px; }
.rps-pick { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.rps-btn { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 18px 6px; border-radius: 16px; border: 2px solid var(--line); background: var(--surface-2); color: var(--text); font: 700 1rem var(--mono); cursor: pointer; transition: transform .12s, border-color .12s; }
.rps-btn span { font-size: 2.6rem; line-height: 1; }
.rps-btn:hover, .rps-btn:focus-visible { transform: translateY(-3px); border-color: var(--pink); box-shadow: var(--glow-pink); }
.rps-rounds { padding-left: 0; list-style: none; display: grid; gap: 6px; margin-top: 16px; }
.rps-rounds li { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; padding: 6px 10px; border: 1px solid var(--line); border-radius: 10px; font-size: .88rem; }
.rps-rounds b { margin-left: auto; }
.tot-form { display: grid; gap: 10px; }
.tot-q { border: 1px solid var(--line); border-radius: 12px; padding: 8px; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 8px; margin: 0; }
.tot-q label { display: block; cursor: pointer; }
.tot-q input { position: absolute; opacity: 0; }
.tot-q label span { display: block; text-align: center; padding: 10px 6px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); }
.tot-q input:checked + span { border-color: var(--lime); color: var(--lime); box-shadow: 0 0 12px rgba(182, 255, 59, .25); }
.tot-q input:focus-visible + span { outline: 2px solid var(--cyan); }
.tot-or { color: var(--muted); font-size: .75rem; }
.tot-result { margin: 10px 0 16px; } .tot-result .mono { font-size: 3rem; }
.tot-table { width: 100%; border-collapse: collapse; } .tot-table td, .tot-table th { padding: 6px 8px; border-bottom: 1px solid var(--line); text-align: left; }
.tot-table tr.same td { color: var(--lime); }
.c4 { max-width: 460px; margin: 0 auto; }
.c4-drop { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; margin-bottom: 6px; }
.c4-drop button { padding: 6px 0; border-radius: 8px; border: 1px solid var(--line); background: var(--surface-2); color: var(--lime); cursor: pointer; font-weight: 700; }
.c4-drop button:hover:not(:disabled) { border-color: var(--lime); }
.c4-drop button:disabled { opacity: .3; cursor: not-allowed; }
.c4-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; padding: 10px; border-radius: 16px; background: #10103a; border: 2px solid var(--purple); box-shadow: var(--glow-purple); }
.c4-cell { aspect-ratio: 1; border-radius: 50%; background: #05050c; box-shadow: inset 0 2px 6px rgba(0, 0, 0, .8); }
.c4-cell.p1, .c4-dot.p1 { background: var(--pink); box-shadow: 0 0 10px rgba(255, 43, 214, .7); }
.c4-cell.p2, .c4-dot.p2 { background: var(--cyan); box-shadow: 0 0 10px rgba(0, 240, 255, .7); }
.c4-cell.last { outline: 3px solid #fff; outline-offset: -3px; }
.c4-cell.win { animation: c4win 1s ease-in-out infinite; }
@keyframes c4win { 50% { transform: scale(.82); } }
.c4-dot { display: inline-block; width: 12px; height: 12px; border-radius: 50%; vertical-align: middle; }
@media (prefers-reduced-motion: reduce) { .c4-cell.win { animation: none; outline: 3px solid var(--lime); } }
.pwf-hint { margin: 12px 0 0; text-align: center; }
.minidates.teaser { border-color: rgba(182, 255, 59, .45); } .neon-amber { color: var(--amber); }
.village-teaser { border-color: rgba(182, 255, 59, .4); }

/* Startseite: Suchbegriff in der H1, FAQ */
.hero h1 .h1-sub { display: block; font: 700 clamp(1rem, 2.6vw, 1.45rem)/1.3 var(--mono); letter-spacing: .02em; color: var(--text); text-shadow: none; margin-top: 10px; }
.home-faq { max-width: 780px; margin: 0 auto; }

/* Mod-Konsole: Anfragen an die Admins */
.admin-req { border-left: 3px solid var(--pink); padding: 6px 0 6px 12px; margin: 12px 0; }
.admin-req.done { border-color: var(--line); opacity: .75; }
.admin-req p { margin: 2px 0; }
.pre-wrap { white-space: pre-wrap; overflow-wrap: anywhere; }

/* Startseite nach dem Login */
.start-kpis a.kpi { color: var(--text); text-decoration: none; transition: border-color .2s; }
.start-kpis a.kpi:hover { border-color: var(--cyan); }
.start-kpis .kpi b { font-size: 1.35rem; }
.start-todo ul, .start-threads, .start-roadmap { list-style: none; padding: 0; margin: 0; }
.start-todo li { margin: 6px 0; }
.start-threads li { padding: 8px 0; border-bottom: 1px solid var(--line); }
.start-threads li:last-child { border-bottom: 0; }
.start-threads .small { display: block; }
.start-release + .start-release { margin-top: 10px; }
.start-roadmap li { margin: 4px 0; }
.start-grid { margin-top: 18px; }
.start-grid .card + .card { margin-top: 0; }
.start-actions { margin-top: 22px; }
.start-grid .row.between { flex-wrap: wrap; gap: 4px 12px; align-items: baseline; margin-bottom: 8px; }
.start-grid h3.small { margin: 14px 0 6px; }

/* Ankündigungen des Admins */
.announce { border-bottom: 1px solid; font-size: .92rem; }
.announce .wrap { display: flex; gap: 12px; align-items: center; justify-content: space-between; padding: 10px 0; }
.announce-text { flex: 1; }
.announce-info { background: rgba(0, 240, 255, .08); border-color: rgba(0, 240, 255, .4); }
.announce-maintenance { background: rgba(255, 197, 61, .1); border-color: rgba(255, 197, 61, .55); color: #fff1cc; }
.announce-important { background: rgba(255, 43, 214, .12); border-color: rgba(255, 43, 214, .55); }
.announces { margin: -28px 0 24px; }
.announces + .beta-banner { margin-top: -24px; }

/* ===== Nerd-Dorf ===== */
.village-facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; margin: 18px 0; }
.village-facts .card { margin: 0; }
.avatar-builder { display: grid; grid-template-columns: 200px 1fr; gap: 24px; align-items: start; }
.avatar-preview { display: grid; place-items: center; padding: 18px; border-radius: var(--radius); background: radial-gradient(circle at 50% 40%, rgba(157, 77, 255, .25), transparent 70%), var(--bg-2); border: 1px solid var(--line); position: sticky; top: 80px; }
.avatar-preview img { image-rendering: pixelated; }
.avatar-options fieldset { border: 0; padding: 0; margin: 0 0 14px; }
.avatar-options legend { font: 600 .8rem var(--mono); color: var(--muted); text-transform: uppercase; letter-spacing: .06em; margin-bottom: 6px; }
.swatches { display: flex; flex-wrap: wrap; gap: 8px; }
.swatch { position: relative; margin: 0; }
.swatch input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.swatch span { display: block; width: 32px; height: 32px; border-radius: 50%; overflow: hidden; border: 2px solid var(--line); transition: all .15s; }
.swatch svg { display: block; width: 100%; height: 100%; }
.swatch input:checked + span { border-color: #fff; box-shadow: var(--glow-pink); transform: scale(1.1); }
.swatch input:focus-visible + span { outline: 2px solid var(--cyan); outline-offset: 2px; }
.village-head { align-items: center; flex-wrap: wrap; gap: 12px; }
.village-me { display: flex; align-items: center; gap: 10px; }
.village-me svg { image-rendering: pixelated; }
.village-nav { flex-wrap: wrap; gap: 8px; margin: 10px 0 14px; }
.village-filter { flex-wrap: wrap; gap: 8px; margin-bottom: 18px; align-items: center; }
.chip-link { padding: 6px 12px; border-radius: 99px; border: 1px solid var(--line); background: var(--surface); font: 600 .8rem var(--mono); color: var(--muted); text-decoration: none; }
.chip-link.on { color: #fff; border-color: var(--cyan); background: rgba(0, 240, 255, .1); }
.village-map { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; }
.district { --d: var(--purple); border: 1px solid var(--line); border-top: 4px solid var(--d); border-radius: var(--radius); padding: 12px; background: linear-gradient(180deg, color-mix(in srgb, var(--d) 12%, transparent), transparent 60%), var(--surface); }
.district.empty { opacity: .6; }
.district-title { display: block; font-weight: 700; color: var(--text); text-decoration: none; margin-bottom: 10px; }
.district-title:hover { color: var(--d); }
.district-motto { margin: -4px 0 10px; font-style: italic; }
.letter-common { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin: 10px 0 0; }
.letter-common .pills { display: contents; }
.district-houses { display: flex; flex-wrap: wrap; gap: 10px; align-items: flex-end; min-height: 40px; }
.house-mini { position: relative; display: flex; flex-direction: column; align-items: center; width: 64px; text-decoration: none; color: var(--text); }
.house-mini .roof { width: 0; height: 0; border-left: 32px solid transparent; border-right: 32px solid transparent; border-bottom: 18px solid var(--d); }
.house-av { display: grid; place-items: end center; width: 56px; height: 62px; overflow: hidden; background: var(--bg-2); border: 2px solid var(--d); border-top: 0; }
.house-av svg { width: 40px; height: 55px; image-rendering: pixelated; }
.house-name { max-width: 64px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .7rem; margin-top: 2px; }
.house-star { position: absolute; top: 14px; right: 2px; color: var(--lime); font-size: .8rem; text-shadow: 0 0 6px var(--lime); }
.house-mini:hover .house-av, .house-mini:focus-visible .house-av { box-shadow: 0 0 12px var(--d); }
.house-more { align-self: center; }
.resident-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 12px; }
.resident { --d: var(--purple); display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 14px 10px; text-align: center; border: 1px solid var(--line); border-bottom: 3px solid var(--d); border-radius: var(--radius); background: var(--surface); color: var(--text); text-decoration: none; }
.resident:hover { box-shadow: 0 0 14px color-mix(in srgb, var(--d) 50%, transparent); }
.resident-av svg { image-rendering: pixelated; }
.resident-name { font-weight: 700; }
.district-h1 { border-left: 6px solid var(--d); padding-left: 12px; }
.house { --d: var(--purple); display: grid; grid-template-columns: 240px 1fr; gap: 28px; align-items: start; margin-bottom: 26px; }
.house-front { position: relative; display: flex; flex-direction: column; align-items: center; }
.house-roof { width: 0; height: 0; border-left: 120px solid transparent; border-right: 120px solid transparent; border-bottom: 70px solid var(--d); filter: drop-shadow(0 0 10px var(--d)); }
.house-door { display: grid; place-items: end center; width: 210px; height: 230px; background: repeating-linear-gradient(0deg, var(--bg-2) 0 22px, var(--surface) 22px 24px); border: 3px solid var(--d); border-top: 0; border-radius: 0 0 8px 8px; }
.house-door svg { image-rendering: pixelated; }
.house-photo { width: 100%; max-width: 320px; aspect-ratio: 1; object-fit: cover; border-radius: 10px; margin-top: 12px; border: 2px solid var(--d); }
.house-bio { white-space: pre-line; }
.letter-form { display: grid; gap: 8px; margin-top: 12px; }
.letter-form textarea { width: 100%; }
.shelves { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 12px; }
.shelf { --d: var(--purple); padding: 10px 12px 12px; border-radius: 10px; background: var(--surface); border-bottom: 6px solid var(--d); box-shadow: inset 0 -6px 0 rgba(0, 0, 0, .25); }
.shelf h3 { margin: 0 0 8px; }
.house-actions { gap: 8px; margin-top: 22px; }
.letter { position: relative; margin-bottom: 12px; }
.letter.unread { border-color: var(--pink); box-shadow: var(--glow-pink); }
.letter-from { display: flex; gap: 12px; align-items: center; color: var(--text); text-decoration: none; }
.letter-from svg { image-rendering: pixelated; flex: none; }
.letter-body { font-style: italic; padding: 10px 14px; border-left: 3px solid var(--pink); background: var(--bg-2); border-radius: 6px; white-space: pre-line; }
.letter .row { flex-wrap: wrap; gap: 8px; }
/* Dorfplatz */
.plaza { position: relative; display: grid; grid-template-columns: 90px 1fr; gap: 18px; margin-bottom: 18px; padding: 16px 18px; border-radius: var(--radius);
  border: 1px solid var(--line); background: radial-gradient(circle at 45px 50%, rgba(0, 240, 255, .14), transparent 160px), repeating-conic-gradient(from 45deg, rgba(255, 255, 255, .025) 0 25%, transparent 0 50%) 0 0 / 28px 28px, var(--surface); }
.plaza h2 { margin: 0 0 2px; }
.plaza-stats { margin: 0 0 12px; color: var(--muted); font-size: .85rem; }
.plaza-stats b { color: var(--cyan); }
.plaza-fountain { align-self: center; justify-self: center; width: 78px; height: 78px; border-radius: 50%; border: 4px solid #6d6a9c; background: radial-gradient(circle, #5ff2ff 0 18%, #1b6c9e 19% 60%, #12304f 61%); box-shadow: 0 0 22px rgba(0, 240, 255, .35); position: relative; }
.plaza-fountain span { position: absolute; left: 50%; top: 50%; width: 10px; height: 10px; margin: -5px; border-radius: 50%; background: #b8fbff; box-shadow: 0 0 10px #b8fbff; animation: plaza-drip 2.4s ease-in-out infinite; }
@keyframes plaza-drip { 50% { transform: scale(1.8); opacity: .5; } }
@media (prefers-reduced-motion: reduce) { .plaza-fountain span { animation: none; } }
.plaza-grid { display: grid; grid-template-columns: 1.3fr 1.3fr 1fr; gap: 18px; }
.plaza-grid h3 { margin: 0 0 8px; }
.plaza-new { display: flex; flex-wrap: wrap; gap: 8px; }
.plaza-person { --d: var(--purple); display: flex; flex-direction: column; align-items: center; width: 58px; color: var(--text); text-decoration: none; }
.plaza-person svg { width: 36px; height: 50px; image-rendering: pixelated; padding: 3px; border-radius: 8px; background: var(--bg-2); border: 2px solid var(--d); box-sizing: content-box; }
.plaza-person span { max-width: 58px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .7rem; margin-top: 2px; }
.plaza-board { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; }
.plaza-board a { overflow-wrap: anywhere; }
@media (max-width: 900px) { .plaza-grid { grid-template-columns: 1fr; } }
@media (max-width: 560px) { .plaza { grid-template-columns: 1fr; } .plaza-fountain { display: none; } }

/* Viertel-Farben (nach den Grundregeln, damit sie gewinnen) */
.d-gaming { --d: #00b8c4; }
.d-tabletop { --d: #7cc400; }
.d-anime { --d: #ff2bd6; }
.d-scifi { --d: #9d4dff; }
.d-tech { --d: #28d9e8; }
.d-maker { --d: #ffb300; }
.d-creative { --d: #ff7a59; }
.d-science { --d: #2ee6a8; }
.d-comics { --d: #ff8be9; }
.d-popkultur { --d: #e0304a; }
.d-sport { --d: #4d7cff; }
.d-neubau { --d: #a3a2c9; }
@media (max-width: 720px) {
  .avatar-builder, .house { grid-template-columns: 1fr; }
  .avatar-preview { position: static; }
  .house-front { margin: 0 auto; }
}
/* Mittlere Breiten (Laptop): Navigation kompakter, damit sie in eine Zeile passt */
@media (min-width: 961px) and (max-width: 1240px) {
  .topbar .wrap { gap: 10px; }
  .nav { gap: 0; flex-wrap: nowrap; }
  .nav a, .nav button.linklike { padding: 8px 7px; font-size: .82rem; white-space: nowrap; }
  .logo { flex: none; }
}

/* Nerd-Dorf: Pixelkarte und Zimmer */
.vmap { margin: 0 0 10px; border: 2px solid var(--line); border-radius: var(--radius); overflow-x: auto; background: #0f1426; }
.vmap-svg { display: block; width: 100%; min-width: 760px; height: auto; image-rendering: pixelated; }
.vmap-svg text { shape-rendering: auto; }
.vmap-svg .vm-house { cursor: pointer; }
.vmap-svg .vm-house:hover, .vmap-svg .vm-house:focus { filter: brightness(1.35) drop-shadow(0 0 1.5px #fff); outline: none; }
.vmap-svg .vm-label:hover rect, .vmap-svg .vm-label:focus rect { fill: rgba(40, 40, 90, .95); }
.vmap-legend { list-style: none; display: flex; flex-wrap: wrap; gap: 6px 18px; padding: 0; margin: 0 0 18px; color: var(--muted); }
.vmap-legend .lg { display: inline-block; width: 11px; height: 11px; margin-right: 6px; vertical-align: -1px; }
.lg-flag { background: #00f0ff; } .lg-mail { background: #ff2bd6; } .lg-me { border: 2px solid #b6ff3b; }
.lg-star { color: #b6ff3b; margin-right: 6px; }
.vroom { max-width: 820px; margin: 0 auto 6px; border: 2px solid var(--d, var(--line)); border-radius: var(--radius); overflow: hidden; background: #1b1636; }
.vroom-svg { display: block; width: 100%; height: auto; image-rendering: pixelated; }
.vroom-svg text { shape-rendering: auto; }
.house-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; align-items: start; }
@media (max-width: 760px) { .house-layout { grid-template-columns: 1fr; } }
.room-items { max-width: 820px; margin: 0 auto 18px; }
.house-layout { grid-template-columns: minmax(0, 260px) 1fr; }
.house-layout > .house-info:only-child { grid-column: 1 / -1; }
.vmap-hint { display: none; margin: 0 0 6px; }
@media (max-width: 800px) { .vmap-hint { display: block; } }
.village-consent { margin: 4px 0 12px; }

/* Pixel-Icons, „Über“-Abschnitt */
.px-icon { image-rendering: pixelated; vertical-align: middle; }
.feature .icon .px-icon { display: block; }
.age-badge { display: inline-grid; place-items: center; width: 44px; height: 40px; border: 3px solid var(--pink); border-radius: 8px; color: var(--pink); font-weight: 800; font-size: 1rem; }
.home-about { display: grid; grid-template-columns: 160px 1fr; gap: 24px; align-items: center; margin: 28px 0 8px; }
.home-about img, .about-photo { width: 100%; height: auto; border-radius: 12px; border: 2px solid var(--line); }
.home-about h2 { margin-bottom: .4em; }
.about-intro { display: grid; grid-template-columns: 240px 1fr; gap: 28px; align-items: start; }
.about-facts { display: flex; flex-wrap: wrap; gap: 8px; margin: 14px 0 0; padding: 0; list-style: none; }
@media (max-width: 640px) { .home-about, .about-intro { grid-template-columns: 1fr; } .home-about img { max-width: 160px; } .about-photo { max-width: 240px; } }
.release-sub { font-size: 1rem; margin: 14px 0 6px; }
.release-sub:first-of-type { margin-top: 4px; }

/* Stilllegung */
.shutdown-banner { background: linear-gradient(90deg, rgba(255, 77, 109, .22), rgba(255, 197, 61, .16)); border-bottom: 1px solid rgba(255, 77, 109, .5); padding: 12px 0; }
.shutdown .lead { font-size: 1.1rem; }
.shutdown-list { padding-left: 1.2em; display: grid; gap: 8px; }
.shutdown-photos { display: flex; flex-wrap: wrap; gap: 10px; }
.shutdown-photos img { width: 120px; height: 150px; object-fit: cover; border-radius: 10px; border: 2px solid var(--line); }
.shutdown-delete { display: grid; gap: 10px; max-width: 420px; }
.shutdown-delete label { display: grid; gap: 4px; }
