:root {
  --color-primary: #00ffd0;
  --color-text-primary: #ffffff;
  --color-text-dark: #002722;
  --color-enemy: #ff4444;
  --color-item: #ffcc00;
  --color-player: #00ff88;
  --color-bg-gradient-1: #071428;
  --color-bg-gradient-2: #0f2330;
  --color-bg-overlay: rgba(0, 0, 0, 0.45);
  --color-shadow: rgba(0, 0, 0, 0.5);
  --spacing-small: 12px;
  --spacing-medium: 10px;
  --radius-default: 8px;
  --shadow-default: 0 4px 10px rgba(0, 0, 0, 0.35);
  --shadow-large: 0 6px 18px rgba(0, 0, 0, 0.5);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: linear-gradient(
    var(--color-bg-gradient-1),
    var(--color-bg-gradient-2) 60%
  );
  font-family: 'Segoe UI', Roboto, Arial, sans-serif;
  color: var(--color-text-primary);
}

.game-container {
  position: relative;
  width: 100%;
  height: 100%;
}

/* Canvas & Video Elements */
canvas {
  display: block;
  width: 100%;
  height: 100%;
  background: transparent;
}

#gameCanvas {
  position: absolute;
  inset: 0;
}

.overlay-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1;
}

#cameraFeed {
  display: none;
}

.camera-mini {
  position: absolute;
  right: 16px;
  bottom: 16px;
  width: 220px;
  height: 165px;
  border-radius: 18px;
  overflow: hidden;
  border: 1px solid rgba(100, 255, 215, 0.48);
  background: #08161a;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.5), 0 0 22px rgba(61, 255, 201, 0.22), inset 0 0 18px rgba(61, 255, 201, 0.08);
  z-index: 16;
}

#virtualHandCanvas {
  width: 100%;
  height: 100%;
  display: block;
  background: radial-gradient(ellipse at 50% 46%, #172b2b 0%, #0b171a 67%, #071114 100%);
}

@media (max-width: 600px) {
  .mode-selection {
    padding: 12px;
  }

  .mode-options {
    grid-template-columns: 1fr;
  }

  .mode-option {
    min-height: 132px;
    padding: 16px;
  }

  .camera-mini {
    right: 10px;
    bottom: 10px;
    width: min(212px, 42vw);
    height: min(160px, 32vw);
    border-radius: 14px;
  }
}

/* HUD – über Overlay-Canvas */
.hud {
  position: absolute;
  top: var(--spacing-small);
  left: var(--spacing-small);
  z-index: 10;
  background: var(--color-bg-overlay);
  padding: 10px 14px;
  border-radius: var(--radius-default);
  min-width: 140px;
  box-shadow: var(--shadow-large);
}

.hud-item {
  font-size: 14px;
  line-height: 1.5;
}

.hud-progress {
  margin-top: 8px;
  padding-top: 6px;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
}

.hud-progress-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 5px;
}

.hud-progress-row:last-child {
  margin-bottom: 0;
}

.hud-progress-label {
  flex: 0 0 72px;
  font-size: 11px;
  opacity: 0.92;
}

.hud-progress-track {
  flex: 1;
  height: 8px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.12);
  overflow: hidden;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.35);
}

.hud-progress-fill {
  height: 100%;
  width: 0%;
  border-radius: 4px;
  transition: width 0.12s ease-out, background 0.2s ease;
}

.hud-progress-fill--level {
  background: linear-gradient(90deg, #26c6da, #00e5ff);
}

.hud-progress-fill--combo {
  background: linear-gradient(90deg, #ffa726, #ffee58);
}

.hud-progress-fill--cal {
  background: linear-gradient(90deg, #66bb6a, #a5d6a7);
}

.hud-progress-fill--ctrl {
  background: linear-gradient(90deg, #78909c, #b0bec5);
}

.hud-tuning {
  margin-top: 8px;
  padding-top: 6px;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
}

/* Streamlined arcade HUD: remove calibration clutter during play. */
.calibration-bar,
.hud-progress,
.hud-tuning,
.hud-item--focus {
  display: none !important;
}

.hud-slider-label {
  display: block;
  font-size: 12px;
  opacity: 0.95;
  margin-bottom: 2px;
}

.hud-slider {
  width: 100%;
  margin: 0 0 6px;
}

@media (max-width: 600px) {
  .hud {
    max-width: 124px;
  }

  .hud-progress,
  .hud-tuning {
    display: none;
  }

  .camera-mini {
    width: min(180px, 38vw);
    height: min(135px, 28vw);
  }

  .play-hint {
    display: none;
  }
}

@media (pointer: coarse) {
  .fallback-controls {
    opacity: 0;
  }

  .fallback-controls.is-visible {
    opacity: 0.92;
  }
}

.hud-icon {
  display: inline-block;
  margin-right: 4px;
  opacity: 0.95;
}

.hud-icon--heart {
  color: #ff6699;
}

/* Controls – größere Klickflächen, klare Zustände */
.controls {
  position: absolute;
  bottom: var(--spacing-small);
  left: var(--spacing-small);
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
  z-index: 15;
}

.fallback-controls {
  position: absolute;
  right: 16px;
  bottom: 16px;
  z-index: 18;
  width: 152px;
  height: 152px;
  display: grid;
  grid-template-columns: repeat(3, 48px);
  grid-template-rows: repeat(3, 48px);
  gap: 4px;
  filter: drop-shadow(0 8px 18px rgba(0, 0, 0, 0.38));
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.fallback-controls.is-visible {
  opacity: 0.92;
  pointer-events: auto;
}

.fallback-key {
  width: 48px;
  height: 48px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 14px;
  background: rgba(7, 22, 29, 0.82);
  color: #fff;
  font-size: 16px;
  font-weight: 800;
  touch-action: none;
  user-select: none;
}

.fallback-key:active,
.fallback-key.is-active {
  background: rgba(0, 255, 208, 0.88);
  color: #08261f;
  transform: scale(0.94);
}

.fallback-key--up { grid-column: 2; grid-row: 1; }
.fallback-key--left { grid-column: 1; grid-row: 2; }
.fallback-key--down { grid-column: 2; grid-row: 2; }
.fallback-key--right { grid-column: 3; grid-row: 2; }
.fallback-key--jump {
  grid-column: 1 / 4;
  grid-row: 3;
  width: 152px;
  font-size: 12px;
  letter-spacing: 0.08em;
}

.play-hint {
  position: absolute;
  left: 50%;
  bottom: 12px;
  z-index: 14;
  transform: translateX(-50%);
  padding: 7px 12px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  background: rgba(4, 14, 20, 0.72);
  color: rgba(255, 255, 255, 0.78);
  font-size: 12px;
  white-space: nowrap;
  pointer-events: none;
}

.btn {
  padding: 10px 18px;
  min-height: 44px;
  font-size: 15px;
  font-weight: 500;
  border-radius: var(--radius-default);
  border: none;
  background: var(--color-primary);
  color: var(--color-text-dark);
  cursor: pointer;
  box-shadow: var(--shadow-default);
  transition: opacity 0.2s ease, transform 0.1s ease, box-shadow 0.2s ease;
}

.btn:hover:not(:disabled) {
  opacity: 0.95;
  transform: translateY(-1px);
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.35);
}

.btn:active:not(:disabled) {
  transform: translateY(0);
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

.btn:focus-visible {
  outline: 2px solid rgba(255, 255, 255, 0.8);
  outline-offset: 2px;
}

.btn-calibrate {
  background: rgba(255, 200, 80, 0.9);
  color: #1a1a0a;
}

.btn-calibrate:hover:not(:disabled) {
  background: rgba(255, 220, 100, 1);
}

.btn-calibrate:disabled {
  opacity: 0.55;
}

.calibration-label {
  display: flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  font-size: 14px;
}

.calibration-label input[type='checkbox'] {
  cursor: pointer;
}

/* Message Overlay – gut lesbar, über allem */
.message {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 20;
  background: rgba(10, 25, 40, 0.92);
  padding: 18px 24px;
  border-radius: 12px;
  font-size: 1.05rem;
  line-height: 1.4;
  text-align: center;
  max-width: 90%;
  min-width: 200px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4), 0 0 0 1px rgba(255, 255, 255, 0.08);
  animation: messageFadeIn 0.25s ease-out;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.message.is-loading {
  color: rgba(255, 255, 255, 0.9);
}

.message.is-error {
  background: rgba(60, 20, 20, 0.95);
  border-color: rgba(255, 100, 100, 0.3);
}

@keyframes messageFadeIn {
  from {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.97);
  }
  to {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
  }
}

.hidden {
  display: none !important;
}

/* 3D game overlays: danger border, low-health vignette, warning text */
.danger-border {
  position: absolute;
  inset: 0;
  pointer-events: none;
  border: 18px solid rgba(255, 50, 50, 0.35);
  border-radius: 4px;
  opacity: 0;
  transition: opacity 0.15s ease;
}

.low-health-pulse {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(ellipse at center, transparent 35%, rgba(180, 0, 0, 0.25) 70%, rgba(120, 0, 0, 0.4) 100%);
  opacity: 0;
  transition: opacity 0.2s ease;
}

.low-health-pulse.visible {
  opacity: 1;
  animation: lowHealthPulse 0.8s ease-in-out infinite;
}

@keyframes lowHealthPulse {
  50% { opacity: 0.7; }
}

.warning-text {
  position: absolute;
  top: 80px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 42px;
  font-weight: bold;
  color: rgba(255, 60, 60, 0.95);
  text-shadow: 0 0 8px rgba(0,0,0,0.9), 0 0 4px #000;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.warning-text.visible {
  opacity: 1;
  animation: warningFlash 0.4s ease-in-out infinite;
}

@keyframes warningFlash {
  50% { opacity: 0.75; }
}

.powerup-indicator {
  margin-top: 8px;
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 12px;
  font-weight: 600;
  background: rgba(255, 200, 0, 0.25);
  border: 1px solid rgba(255, 200, 0, 0.6);
}

.powerup-indicator.shield {
  background: rgba(0, 150, 255, 0.25);
  border-color: rgba(0, 150, 255, 0.6);
}

.powerup-indicator.multiplier {
  background: rgba(255, 100, 255, 0.25);
  border-color: rgba(255, 100, 255, 0.6);
}

/* ========== Begrüßungsfenster ========== */
.welcome-overlay {
  position: fixed;
  inset: 0;
  z-index: 9997;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  box-sizing: border-box;
  animation: welcomeFadeIn 0.25s ease-out;
}

.welcome-overlay.is-closed {
  pointer-events: none;
  visibility: hidden;
  opacity: 0;
  transition: visibility 0.2s, opacity 0.2s ease-out;
}

.mode-selection {
  position: fixed;
  inset: 0;
  z-index: 9998;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.mode-selection.is-hidden {
  display: none;
}

.mode-selection-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(3, 10, 17, 0.82);
  backdrop-filter: blur(8px);
}

.mode-selection-card {
  position: relative;
  width: min(680px, 100%);
  padding: clamp(24px, 5vw, 42px);
  border: 1px solid rgba(97, 255, 216, 0.3);
  border-radius: 24px;
  background: linear-gradient(145deg, rgba(10, 31, 40, 0.98), rgba(8, 18, 30, 0.98));
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.55), 0 0 42px rgba(0, 255, 208, 0.1);
}

.mode-eyebrow {
  margin: 0 0 10px;
  color: #79ffdc;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.18em;
}

.mode-selection-card h1 {
  margin: 0;
  color: #fff;
  font-size: clamp(26px, 5vw, 38px);
}

.mode-intro {
  margin: 10px 0 24px;
  color: rgba(238, 250, 248, 0.74);
  line-height: 1.5;
}

.mode-options {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.mode-option {
  display: grid;
  justify-items: start;
  gap: 10px;
  min-height: 190px;
  padding: 20px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.055);
  color: #fff;
  text-align: left;
  cursor: pointer;
  transition: transform 0.18s ease, border-color 0.18s ease, background 0.18s ease;
}

.mode-option:hover:not(:disabled),
.mode-option:focus-visible {
  transform: translateY(-3px);
  border-color: rgba(90, 255, 216, 0.85);
  background: rgba(0, 255, 208, 0.1);
  outline: none;
}

.mode-option:disabled {
  opacity: 0.55;
  cursor: wait;
}

.mode-option strong {
  font-size: 20px;
}

.mode-option > span:last-child {
  color: rgba(238, 250, 248, 0.72);
  font-size: 13px;
  line-height: 1.45;
}

.mode-option-icon {
  color: #7dffe1;
  font-size: 32px;
}

.mode-status {
  min-height: 1.4em;
  margin: 18px 0 0;
  color: rgba(238, 250, 248, 0.78);
  font-size: 13px;
}

.mode-status.is-error {
  color: #ff9a9a;
}

.controls.is-setup {
  display: none;
}

@keyframes welcomeFadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.welcome-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(5, 15, 28, 0.82);
  backdrop-filter: blur(4px);
  cursor: pointer;
}

.welcome-modal {
  position: relative;
  width: 100%;
  max-width: 480px;
  max-height: 90vh;
  background: linear-gradient(160deg, #0d1f2d 0%, #132a38 100%);
  border-radius: 14px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(0, 255, 208, 0.12);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  animation: welcomeSlideIn 0.3s ease-out;
}

@keyframes welcomeSlideIn {
  from {
    opacity: 0;
    transform: scale(0.96) translateY(-8px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

.welcome-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 36px;
  height: 36px;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.9);
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s, color 0.15s;
  z-index: 2;
}

.welcome-close:hover,
.welcome-close:focus {
  background: rgba(255, 80, 80, 0.35);
  color: #fff;
  outline: none;
}

.welcome-close:active {
  background: rgba(255, 80, 80, 0.5);
}

.welcome-content {
  padding: 28px 24px 24px;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}

.welcome-title {
  margin: 0 0 6px;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--color-primary);
  letter-spacing: 0.02em;
}

.welcome-lead {
  margin: 0 0 10px;
  font-size: 0.95rem;
  line-height: 1.45;
  color: rgba(255, 255, 255, 0.85);
}

.welcome-tldr {
  margin: 0 0 20px;
  padding: 10px 12px;
  background: rgba(0, 255, 208, 0.12);
  border-radius: 8px;
  font-size: 0.85rem;
  line-height: 1.4;
  color: rgba(255, 255, 255, 0.9);
}

.welcome-section {
  margin-bottom: 18px;
}

.welcome-section h2 {
  margin: 0 0 8px;
  font-size: 0.95rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.95);
}

.welcome-section p,
.welcome-list {
  margin: 0;
  font-size: 0.875rem;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.8);
}

.welcome-list {
  padding-left: 1.2em;
  list-style: none;
}

.welcome-list li {
  margin-bottom: 6px;
  padding-left: 0.3em;
}

.welcome-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  margin-right: 6px;
  vertical-align: middle;
}

.welcome-dot--heart {
  background: #ff99cc;
}

.welcome-dot--shield {
  background: #44aaff;
}

.welcome-dot--mult {
  background: #cc44ff;
}

.welcome-footer {
  margin: 18px 0 16px;
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.65);
}

.welcome-ok {
  width: 100%;
  padding: 12px 16px;
  font-size: 1rem;
  font-weight: 600;
  margin-top: 4px;
}

/* One-time calibration hint bar – weich einblendend */
.calibration-bar {
  position: absolute;
  bottom: 58px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 12;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 16px;
  background: rgba(255, 193, 7, 0.18);
  border: 1px solid rgba(255, 193, 7, 0.45);
  border-radius: 10px;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.95);
  max-width: 92%;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.calibration-bar:not(.is-closed) {
  animation: calibrationBarIn 0.35s ease-out;
}

@keyframes calibrationBarIn {
  from {
    opacity: 0;
    transform: translateX(-50%) translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }
}

.calibration-bar.is-closed {
  display: none;
}

.calibration-bar-text strong {
  color: #ffc107;
}

.calibration-bar-close {
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  color: inherit;
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.calibration-bar-close:hover {
  background: rgba(255, 255, 255, 0.25);
}

.calibration-bar-close:focus-visible {
  outline: 2px solid rgba(255, 193, 7, 0.9);
  outline-offset: 2px;
}

/* Calibration progress bar */
.calibration-progress-wrap {
  position: absolute;
  bottom: 58px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 14;
  width: 92%;
  max-width: 440px;
  padding: 12px 14px;
  background: rgba(0, 0, 0, 0.8);
  border-radius: 10px;
  border: 1px solid rgba(255, 193, 7, 0.4);
}

.calibration-progress-wrap.hidden {
  display: none !important;
}

.calibration-progress-label {
  margin: 0 0 8px;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.95);
  text-align: center;
}

.calibration-progress-main {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.calibration-pose-illustration {
  flex: 0 0 auto;
  width: 76px;
  min-height: 92px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  background: rgba(8, 22, 28, 0.65);
  border: 1px solid rgba(0, 255, 200, 0.22);
}

.calibration-pose-illustration svg {
  display: block;
  max-width: 100%;
  height: auto;
}

.calibration-progress-column {
  flex: 1;
  min-width: 0;
}

.calibration-progress-meta {
  margin: 0 0 8px;
  font-size: 12px;
  line-height: 1.4;
  color: rgba(220, 245, 255, 0.9);
  text-align: left;
}

.calibration-progress-bar {
  height: 10px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 5px;
  overflow: hidden;
}

.calibration-progress-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #ffc107, #ffeb3b);
  border-radius: 5px;
  transition: width 0.15s ease-out;
}

.calibration-guide {
  position: absolute;
  right: 12px;
  bottom: 160px;
  z-index: 18;
  width: min(360px, 92vw);
  padding: 12px 14px;
  border-radius: 10px;
  background: rgba(7, 16, 24, 0.9);
  border: 1px solid rgba(130, 230, 255, 0.35);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.35);
}

.calibration-guide h3 {
  margin: 0 0 6px;
  font-size: 15px;
  color: #d5fbff;
}

.calibration-guide p {
  margin: 0 0 6px;
  font-size: 12px;
  opacity: 0.95;
}

.calibration-guide ul {
  margin: 0 0 10px;
  padding-left: 18px;
  font-size: 12px;
  line-height: 1.35;
  opacity: 0.92;
}

.calibration-guide-actions {
  display: flex;
  justify-content: flex-end;
}

.calibration-guide .btn {
  min-height: 36px;
  padding: 7px 12px;
  font-size: 13px;
}

/* Game Over + Leaderboard */
.leaderboard-overlay {
  position: fixed;
  inset: 0;
  z-index: 9000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.leaderboard-overlay.hidden {
  display: none !important;
}

.leaderboard-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.8);
}

.leaderboard-modal {
  position: relative;
  background: linear-gradient(160deg, #0d1f2d 0%, #132a38 100%);
  border-radius: 14px;
  padding: 26px 28px;
  max-width: 380px;
  width: 100%;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(0, 255, 208, 0.2);
  animation: messageFadeIn 0.25s ease-out;
}

.leaderboard-title {
  margin: 0 0 8px;
  font-size: 1.5rem;
  color: #00ffd0;
  text-align: center;
}

.leaderboard-score {
  margin: 0 0 20px;
  font-size: 1rem;
  color: rgba(255, 255, 255, 0.9);
  text-align: center;
}

.leaderboard-heading {
  margin: 0 0 12px;
  font-size: 1rem;
  color: rgba(255, 255, 255, 0.85);
}

.leaderboard-list {
  margin: 0 0 20px;
  padding-left: 1.5em;
  color: rgba(255, 255, 255, 0.9);
  font-size: 1rem;
  line-height: 1.8;
}

.leaderboard-list li {
  margin-bottom: 4px;
}

.leaderboard-restart {
  width: 100%;
  padding: 14px 16px;
  min-height: 48px;
  font-size: 1.05rem;
  font-weight: 600;
  margin-top: 4px;
}

/* Rechtliche Links (Impressum/Datenschutz) – dezent am Seitenende */
.legal-links { position: fixed; right: 12px; bottom: 8px; z-index: 5; font-size: 12px; color: #c9d4ee; background: rgba(16, 26, 53, 0.72); padding: 4px 10px; border-radius: 8px; }
.legal-links a { color: inherit; display: inline-block; padding: 12px 6px; }

/* Schließen-Schaltfläche des Willkommensdialogs: Touch-Ziel 44 px */
.welcome-close { min-width: 44px; min-height: 44px; }
