/**
 * BASE.CSS - Accessibility & Utilities
 * =====================================
 * 
 * Core accessibility features and utility classes.
 * Load this BEFORE main.css for proper cascade.
 */

/* ===========================================
   ACCESSIBILITY
   =========================================== */

/* Skip Link - Essential for keyboard navigation */
.skip-link {
  position: absolute;
  left: 16px;
  top: -60px;
  background: #fff;
  color: #000;
  padding: 12px 18px;
  border-radius: 4px;
  z-index: 20000;
  text-decoration: none;
  font-weight: 700;
  font-size: 14px;
  transition: top 0.2s ease;
}

.skip-link:focus {
  top: 16px;
  outline: 3px solid var(--accent, #E1061F);
  outline-offset: 2px;
}

/* Focus Visible - Modern focus indicator */
:focus-visible {
  outline: 2px solid var(--accent, #E1061F);
  outline-offset: 3px;
}

/* Remove default focus for mouse users */
:focus:not(:focus-visible) {
  outline: none;
}

/* Remove yellow/gold browser default outlines */
button:focus,
button:focus-visible,
[type="button"]:focus,
[type="button"]:focus-visible {
  outline: none !important;
  box-shadow: none !important;
}

/* Interactive elements transition */
a, button, input, select, textarea, [tabindex] {
  transition: outline-offset 0.15s ease;
}

/* Main content focus reset */
main[tabindex='-1'] {
  outline: none;
}

/* Screen Reader Only */
.sr-only {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

/* ===========================================
   REDUCED MOTION
   =========================================== */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto !important;
  }
  
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  
  /* Ensure content is visible when animations are disabled */
  .hero-eyebrow,
  .hero-name,
  .hero-title,
  .hero-desc,
  .hero-ctas,
  .stats-strip,
  .scroll-hint,
  .page-num,
  .page-title,
  .page-subtitle,
  .cta-eyebrow,
  .cta-headline,
  .cta-buttons,
  .reveal {
    opacity: 1 !important;
    transform: none !important;
  }
  
  .cursor, .cursor-ring {
    display: none !important;
  }
}

/* ===========================================
   TOUCH DEVICE OPTIMIZATIONS
   =========================================== */
@media (hover: none), (pointer: coarse) {
  .cursor, .cursor-ring {
    display: none !important;
  }
  
  /* Disable decorative animations on touch */
  .scroll-hint,
  .marquee-wrap {
    display: none !important;
  }
}

/* ===========================================
   LIGHT MODE SUPPORT (Optional)
   =========================================== */
@media (prefers-color-scheme: light) {
  body::before {
    opacity: 0.12 !important;
  }
  
  .hero::after,
  .cta-section::after,
  .page-header::after {
    opacity: 0.2 !important;
  }
}

/* ===========================================
   FORM ACCESSIBILITY
   =========================================== */
.form-group label,
.field-label {
  display: block;
  margin: 0 0 8px;
  color: var(--text-sub, #E5E5E5);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
}

.privacy-note {
  margin-top: 14px;
  font-size: 11px;
  line-height: 1.7;
  color: var(--text-muted, #9A9A9A);
}

/* ===========================================
   TRANSCRIPT ACCESSIBILITY
   =========================================== */
.transcript-list {
  display: grid;
  gap: 14px;
  margin-top: 28px;
}

.transcript-item {
  border: 1px solid rgba(255, 255, 255, 0.08);
  padding: 16px 18px;
  background: rgba(255, 255, 255, 0.02);
}

.transcript-item summary {
  cursor: pointer;
  font-weight: 700;
  color: #fff;
}

.transcript-item summary:focus-visible {
  outline: 2px solid var(--accent, #E1061F);
  outline-offset: 2px;
}

.transcript-item p {
  margin-top: 10px;
  color: #cfcfcf;
}

/* ===========================================
   EXTERNAL LINK INDICATOR
   =========================================== */
.footer-links a[target="_blank"]::after,
a[target="_blank"][rel*="noopener"]::after {
  content: " ↗";
  font-size: 0.75em;
  opacity: 0.6;
}

/* ===========================================
   PRINT STYLES
   =========================================== */
@media print {
  .cursor, .cursor-ring,
  .scroll-hint,
  .marquee-wrap,
  nav,
  .nav-toggle {
    display: none !important;
  }
  
  body::before {
    display: none !important;
  }
  
  * {
    background: white !important;
    color: black !important;
  }
  
  a {
    text-decoration: underline;
  }
  
  a[href]::after {
    content: " (" attr(href) ")";
    font-size: 0.8em;
  }
}
