/**
 * ADA/WCAG 2.2 AA Accessibility Fixes — WordPressRhythm
 *
 * Every rule in this file is annotated with:
 *   - The WCAG criterion it addresses
 *   - The disability type it helps
 *   - What barrier it removes
 *   - Why the fix matters for real users
 *
 * See REMEDIATION-LOG.html for the full remediation manifest.
 */

/* WCAG 2.4.1 Bypass Blocks (Level A) — Blind, Motor, Cognitive
   Barrier: Without a skip link, keyboard and screen reader users must tab through the entire navigation menu on every single page b...
   Fix: A 'Skip to main content' link lets keyboard users bypass repeated navigation with a single keystroke, immediately reachi... */
.ada-skip-link {
  position: absolute;
  top: -100%;
  left: 50%;
  transform: translateX(-50%);
  background: #000;
  color: #fff;
  padding: 12px 24px;
  z-index: 100000;
  text-decoration: none;
  font-size: 16px;
  font-weight: 600;
  border-radius: 0 0 4px 4px;
  transition: top 0.15s ease;
}
.ada-skip-link:focus {
  top: 0;
  outline: 3px solid #005fcc;
  outline-offset: 2px;
}

/* WCAG 2.4.7 Focus Visible (Level AA) — Motor, Low vision, Cognitive
   Barrier: When CSS removes the focus outline (outline: none) without a visible replacement, keyboard users cannot see which elemen...
   Fix: A visible focus indicator (typically a colored outline) shows keyboard users exactly where they are on the page, just as... */
*:focus-visible {
  outline: 3px solid #005fcc;
  outline-offset: 2px;
}
*:focus:not(:focus-visible) {
  outline: none;
}

/* WCAG 1.4.3 Contrast (Minimum) (Level AA) — Low vision, Color blind, Aging vision
   Barrier: Low-contrast text is difficult or impossible to read for the ~300 million people worldwide with color vision deficiencie...
   Fix: Meeting the 4.5:1 contrast ratio ensures text is readable by people with moderately low vision, without requiring contra... */
/* WCAG 1.4.3 — .entry-content p[style*="b0b0b0"] */
.entry-content p[style*="b0b0b0"] { color: #767676 !important; }
/* WCAG 1.4.3 — .entry-content button[type="submit"] */
.entry-content button[type="submit"] { color: #616161 !important; }

/* WCAG 2.5.8 Target Size (Minimum) (Level AA) — Motor, Aging
   Barrier: Small click/tap targets (under 24x24px) are difficult for people with motor impairments — tremors, limited dexterity, ...
   Fix: Minimum 24x24px targets give users with motor impairments a large enough area to activate controls accurately, reducing ... */
a, button, input[type="submit"], input[type="button"],
input[type="checkbox"], input[type="radio"],
select, [role="button"], [role="menuitem"] {
  min-height: 24px;
  min-width: 24px;
}
nav a, nav button, .menu a, .menu button {
  padding: 8px 12px;
}

/* WCAG 2.3.3 Animation from Interactions (Level AAA) — Vestibular, Seizure-prone, Cognitive
   Barrier: Animations and transitions can trigger vestibular disorders (dizziness, nausea, migraines) in people with inner-ear cond...
   Fix: Respecting prefers-reduced-motion disables non-essential animations for users who've indicated sensitivity, preventing p... */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* WCAG 1.4.10 Reflow (Level AA) — Low vision
   Barrier: When content doesn't reflow at 320px or viewport zooming is disabled, low-vision users who magnify content to 400% are f...
   Fix: Reflowing content eliminates horizontal scrolling at high zoom levels. Low-vision users can enlarge text to a comfortabl... */
@media (max-width: 320px) {
  body {
    overflow-x: hidden;
  }
  img, video, iframe, table {
    max-width: 100%;
    height: auto;
  }
}

/* WCAG 1.4.12 Text Spacing (Level AA) — Low vision, Dyslexia, Cognitive
   Barrier: When CSS prevents users from overriding line-height, letter-spacing, word-spacing, or paragraph spacing, people with dys...
   Fix: Allowing text spacing overrides lets users with dyslexia increase letter and word spacing to reduce crowding effects, an... */
* {
  overflow-wrap: break-word;
}

