/**
 * a11y.css — P5 Sprint 10 Task 10.2
 * =================================
 * Site-wide accessibility primitives, included on every page.
 *   - Visible focus indicator (Sand Gold ring) on all interactive elements
 *   - prefers-reduced-motion: instant (no) transitions/animations
 *   - Minimum 44×44px tap targets for buttons, cards, nav links
 *   - Screen-reader-only utility
 *
 * Brand: Ocean Blue #0D3B6E, Forest Green #2D6A4F, Sand Gold #C8963E
 */

/* -------------------------------------------------------------------------
   Visible focus indicator — Sand Gold ring on every focusable element
   ------------------------------------------------------------------------- */
*:focus-visible {
  outline: 3px solid #C8963E; /* Sand Gold */
  outline-offset: 2px;
}

/* Keep custom widget focus rings consistent (fallback for :focus too) */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
[tabindex]:focus-visible,
[role="button"]:focus-visible {
  outline: 3px solid #C8963E;
  outline-offset: 2px;
}

/* -------------------------------------------------------------------------
   Minimum 44×44px tap targets (WCAG 2.5.5 / mobile guidelines)
   ------------------------------------------------------------------------- */
.btn {
  min-height: 44px;
  min-width: 44px;
}

.nav-links a {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
}

/* Cards act as tap targets when they wrap a link — ensure comfortable size */
.card {
  min-height: 44px;
}

/* -------------------------------------------------------------------------
   Screen-reader-only utility (visually hidden, still announced)
   ------------------------------------------------------------------------- */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* -------------------------------------------------------------------------
   Reduced motion — make all transitions/animations instant
   ------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    transition: none !important;
    animation: none !important;
    scroll-behavior: auto !important;
  }
}
