/**
 * Gensoft Enterprise Reset & Core Accessibility Utilities
 * Conforms to WCAG 2.2 AA (Non-text Contrast, Focus Appearance, Target Size)
 */

/* ── 1. Skip-to-Content Navigation Link ── */
.skip-link {
  position: absolute;
  top: -120px;
  left: 1.5rem;
  background: var(--gs-primary, #1d4ed8);
  color: #ffffff !important;
  padding: 0.75rem 1.25rem;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 700;
  border-radius: var(--radius-sm, 6px);
  z-index: 100000;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.25);
  text-decoration: none;
  transition: top var(--transition-fast, 150ms ease-out);
}
.skip-link:focus,
.skip-link:focus-visible {
  top: 1rem;
  outline: 3px solid var(--gs-accent, #f97316) !important;
  outline-offset: 3px !important;
}

/* ── 2. Universal WCAG 2.2 AA Focus Appearance (Criterion 2.4.13) ── */
:focus-visible {
  outline: var(--focus-ring-width, 3px) solid var(--focus-ring-color, #1d4ed8) !important;
  outline-offset: var(--focus-ring-offset, 3px) !important;
}

/* Clear standard outline when mouse clicked */
:focus:not(:focus-visible) {
  outline: none;
}

/* ── 3. Touch Target Minimums (WCAG 2.2 Target Size - Minimum 44px recommended) ── */
a, button, input, select, textarea, .btn, .hero-pill, .sub-menu-item {
  touch-action: manipulation;
}

/* ── 4. Screen-Reader / Visually Hidden Utility ── */
.visually-hidden,
.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;
}

/* ── 5. Typography Readability & Optimal Measure (60-80 chars) ── */
.gs-measure {
  max-width: var(--max-ch, 68ch);
}

.gs-readable-lead {
  font-size: var(--text-lead, 1.15rem);
  line-height: var(--lh-normal, 1.6);
  color: var(--gs-text-secondary, #334155);
  max-width: var(--max-ch, 68ch);
}

/* ── 6. Responsive Image & Media Best Practices ── */
img:not(.logo-light-mode):not(.logo-dark-mode),
svg, video {
  max-width: 100%;
}

#topnav .logo img,
.logo img,
.logo-light-mode,
.logo-dark-mode {
  height: 44px !important;
  width: auto !important;
  max-width: 200px !important;
  object-fit: contain;
}

.logo-footer img {
  height: 36px !important;
  width: auto !important;
  max-width: 180px !important;
  object-fit: contain;
}

/* ── 7. Cookie Consent Banner (GDPR / ePrivacy / CCPA Compliant) ── */
#gs-cookie-consent {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(11, 27, 51, 0.98);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: #ffffff;
  padding: 1.25rem;
  z-index: 99990;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  box-shadow: 0 -8px 30px rgba(0, 0, 0, 0.2);
  display: none;
}
#gs-cookie-consent.show {
  display: block;
}
#gs-cookie-consent .cookie-btn-accept {
  background: var(--gs-accent, #f97316);
  color: #ffffff;
  border: 0;
  padding: 0.55rem 1.4rem;
  font-weight: 700;
  border-radius: 9999px;
  font-size: 0.9rem;
  min-height: 42px;
  cursor: pointer;
  transition: background 150ms ease;
}
#gs-cookie-consent .cookie-btn-accept:hover {
  background: var(--gs-accent-hover, #ea580c);
}
#gs-cookie-consent .cookie-btn-reject {
  background: transparent;
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.4);
  padding: 0.55rem 1.25rem;
  font-weight: 600;
  border-radius: 9999px;
  font-size: 0.9rem;
  min-height: 42px;
  cursor: pointer;
  transition: all 150ms ease;
}
#gs-cookie-consent .cookie-btn-reject:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: #ffffff;
}
