/* Farb-Tokens fuer Hell/Dunkel/Auto - gleiche Logik wie im Turnierportal:
   "Auto" (kein data-theme-Attribut) folgt prefers-color-scheme, ein explizites
   data-theme="dark"/"light" (Footer-Umschalter, siehe site.js) gewinnt immer.
   Deshalb zwei getrennte Dark-Regeln statt einer gemeinsamen. */
:root {
  color-scheme: light;
  --bg: #ffffff;
  --text: #1c1f24;
  --text-2: #3d434c;
  --muted: #6b717b;
  --border: #e6e8eb;
  --border-strong: #cccccc;
  --accent: #2563a8;
  --accent-soft: #eaf1fd;
  --logo-filter: none;
  --btn-bg: linear-gradient(135deg, #2b2f36 0%, #16181c 100%);
  --btn-text: #ffffff;
  --btn-shadow: rgba(22, 24, 28, 0.55);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --bg: #0b0b0d;
    --text: #f2f2f7;
    --text-2: #c7c7cc;
    --muted: #9a9aa0;
    --border: rgba(255, 255, 255, 0.09);
    --border-strong: rgba(255, 255, 255, 0.22);
    --accent: #5b9beb;
    --accent-soft: #16283f;
    --logo-filter: invert(1);
    --btn-bg: linear-gradient(135deg, #f2f2f7 0%, #c9ccd2 100%);
    --btn-text: #111317;
    --btn-shadow: rgba(0, 0, 0, 0.6);
  }
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0b0b0d;
  --text: #f2f2f7;
  --text-2: #c7c7cc;
  --muted: #9a9aa0;
  --border: rgba(255, 255, 255, 0.09);
  --border-strong: rgba(255, 255, 255, 0.22);
  --accent: #5b9beb;
  --accent-soft: #16283f;
  --logo-filter: invert(1);
  --btn-bg: linear-gradient(135deg, #f2f2f7 0%, #c9ccd2 100%);
  --btn-text: #111317;
  --btn-shadow: rgba(0, 0, 0, 0.6);
}

body {
  background: var(--bg);
  color: var(--text);
}

.site-footer {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 12px 20px;
  padding: 16px 0 4px;
  font-size: 0.75rem;
}

.site-footer > a {
  color: var(--muted);
  text-decoration: none;
}

.site-footer > a:hover,
.site-footer > a:focus-visible {
  color: var(--text);
  text-decoration: underline;
}

/* Pillen-Umschalter wie im Turnierportal (.footer-theme-switcher) */
.switch {
  display: inline-flex;
  gap: 2px;
  padding: 2px;
  border: 1px solid var(--border);
  border-radius: 100px;
}

.switch button,
.switch a {
  padding: 5px 11px;
  border: none;
  border-radius: 100px;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.4;
  text-decoration: none;
  cursor: pointer;
}

.switch button:hover,
.switch a:hover {
  color: var(--text);
}

.switch button.active,
.switch a[aria-current="true"] {
  background: var(--accent-soft);
  color: var(--accent);
}

.switch button:focus-visible,
.switch a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
}
