/* ═══════════════════════════════════════════════════════════════
   Traumstart e.V. — Barrierefreiheits-Widget
   ═══════════════════════════════════════════════════════════════ */

/* ── Floating-Button + Panel ── */
.a11y-widget { position: fixed; bottom: 20px; right: 20px; z-index: 9000; }
.a11y-toggle {
  width: 48px; height: 48px; border-radius: 50%;
  background: var(--teal-dark); color: white;
  border: none; cursor: pointer;
  box-shadow: 0 4px 12px rgba(0,0,0,0.25);
  display: flex; align-items: center; justify-content: center;
  transition: background 0.2s, transform 0.15s;
}
.a11y-toggle:hover { background: var(--teal); transform: scale(1.08); }
.a11y-toggle:focus-visible { outline: 3px solid var(--teal); outline-offset: 3px; }

.a11y-panel {
  position: absolute; bottom: 60px; right: 0;
  width: 300px;
  background: white; border-radius: 14px;
  padding: 22px 20px 16px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.18);
  border: 1px solid var(--border);
}
.a11y-panel[hidden] { display: none; }
.a11y-panel h3 {
  font-family: var(--font-h); font-size: 15px; font-weight: 800;
  color: var(--teal-dark); margin-bottom: 16px;
  padding-bottom: 12px; border-bottom: 1px solid var(--border);
}

/* ── Options ── */
.a11y-option { margin-bottom: 14px; }
.a11y-switch {
  display: flex; align-items: center; gap: 10px;
  cursor: pointer; font-family: var(--font-h);
  font-size: 14px; font-weight: 700; color: var(--dark);
}
.a11y-switch input[type="checkbox"] {
  width: 18px; height: 18px; accent-color: var(--teal-dark);
  cursor: pointer; flex-shrink: 0;
}
.a11y-hint { font-size: 12px; color: var(--medium); margin-top: 4px; margin-left: 28px; line-height: 1.4; }

/* ── Schriftgröße ── */
.a11y-label { font-family: var(--font-h); font-size: 14px; font-weight: 700; color: var(--dark); display: block; margin-bottom: 8px; }
.a11y-fontsize { display: flex; gap: 8px; }
.a11y-fontsize button {
  flex: 1; padding: 8px 4px;
  background: var(--light); border: 2px solid var(--border);
  border-radius: 8px; cursor: pointer;
  font-family: var(--font-h); font-weight: 800; color: var(--medium);
  transition: all 0.15s;
}
.a11y-fontsize button[aria-pressed="true"] {
  background: var(--teal-dark); border-color: var(--teal-dark); color: white;
}
.a11y-fontsize button:hover:not([aria-pressed="true"]) {
  border-color: var(--teal); color: var(--teal-dark);
}

/* ── Reset + Footer ── */
.a11y-reset {
  width: 100%; margin-top: 14px; padding: 9px;
  background: none; border: 1.5px solid var(--border);
  border-radius: 8px; cursor: pointer;
  font-family: var(--font-h); font-size: 13px; font-weight: 700;
  color: var(--medium); transition: all 0.15s;
}
.a11y-reset:hover { border-color: var(--teal); color: var(--teal-dark); }
.a11y-footer {
  font-size: 11px; color: var(--medium); margin-top: 12px;
  padding-top: 10px; border-top: 1px solid var(--border);
  line-height: 1.5; text-align: center;
}
.a11y-footer a { color: var(--teal); font-weight: 600; }

/* ── Mobile ── */
@media (max-width: 400px) {
  .a11y-widget { bottom: 16px; right: 12px; }
  .a11y-toggle { width: 44px; height: 44px; }
  .a11y-panel { width: calc(100vw - 32px); right: -4px; }
}

/* ═══════════════════════════════════════════════════════════════
   Toggle-Klassen am <html> (gesetzt via JS)
   ═══════════════════════════════════════════════════════════════ */

/* ── Bewegung reduzieren ── */
html.a11y-reduce-motion *,
html.a11y-reduce-motion *::before,
html.a11y-reduce-motion *::after {
  animation-duration: 0.01ms !important;
  animation-iteration-count: 1 !important;
  transition-duration: 0.01ms !important;
  scroll-behavior: auto !important;
}

/* ── Hoher Kontrast ── */
html.a11y-high-contrast {
  --medium: #1E2E34;
  --border: #7AAAB4;
}
html.a11y-high-contrast :focus-visible {
  outline-width: 4px;
  outline-offset: 3px;
}
/* Footer: h4-Labels sind teal auf teal-dark → explizit weiß */
html.a11y-high-contrast .footer { background: #044050; }
html.a11y-high-contrast .footer h4 { color: rgba(255,255,255,0.9); }
html.a11y-high-contrast .footer a,
html.a11y-high-contrast .footer span.addr { color: rgba(255,255,255,0.92); }
html.a11y-high-contrast .footer-desc { color: rgba(255,255,255,0.85); }
html.a11y-high-contrast .footer-bottom { color: rgba(255,255,255,0.7); }
html.a11y-high-contrast .footer-bottom a { color: rgba(255,255,255,0.8); }

/* ── Schriftgröße +10% / +20% ──
   zoom auf body statt font-size auf html, weil alle Größen
   in style.css px-basiert sind (kein rem) */
html.a11y-fs-10 body { zoom: 1.1; }
html.a11y-fs-20 body { zoom: 1.2; }
