/* Site-wide accessibility baseline.
 *
 * Kept in its own hand-written file on purpose: css/webflow.css and
 * css/devsignal-staging.webflow.css are generated by Webflow and are
 * overwritten on every re-export, so nothing here may live in them.
 * Load this LAST so it wins over the generated sheets' `outline: 0`.
 */

:root {
  --focus-ring: #14213a;
  --focus-ring-on-dark: #ffffff;
}

/* ---------- keyboard focus ---------- */

/* webflow.css and normalize.css strip outlines in ~13 places and never put
   anything back. :focus-visible only matches keyboard navigation on buttons
   and links, so this ring is invisible to mouse and touch visitors. */
a:focus-visible,
button:focus-visible,
[role="button"]:focus-visible,
summary:focus-visible,
[tabindex]:not([tabindex="-1"]):focus-visible {
  outline: 2px solid var(--focus-ring);
  outline-offset: 3px;
  border-radius: 4px;
}

/* Pill-shaped controls keep their own radius so the ring hugs the shape. */
.hero25-submit:focus-visible,
.hero25-chip:focus-visible,
.hero25-nav-cta:focus-visible,
.btn:focus-visible,
.is--cta:focus-visible {
  border-radius: 999px;
}

/* Over the hero photo and other dark surfaces, navy on navy disappears — pair
   the ring with a white halo so it reads on any backdrop. */
.hero25-nav a:focus-visible,
.hero25-nav-cta:focus-visible,
.hero25-chip:focus-visible,
.hero25-submit:focus-visible {
  outline-color: var(--focus-ring-on-dark);
  box-shadow: 0 0 0 4px rgba(20, 33, 58, 0.55);
}

/* Form fields match :focus-visible even on mouse focus, so they get a border
   treatment instead of a ring — see the per-field rules in hero.css,
   lead-form.css and candidates.css. */
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
  outline: none;
}

/* ---------- skip link ---------- */

.skip-link {
  position: absolute;
  left: 12px;
  top: -60px;
  z-index: 10000;
  padding: 10px 16px;
  border-radius: 8px;
  background: #080807;
  color: #f0f1fa;
  font-family: inherit;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  transition: top 0.15s ease;
}
.skip-link:focus {
  top: 12px;
  outline: 2px solid #ffffff;
  outline-offset: 2px;
}

/* Targets of the skip link are focused programmatically and are not
   interactive, so they must never paint a ring. */
[tabindex="-1"]:focus {
  outline: none;
}

/* ---------- screen-reader-only text ---------- */

.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 ---------- */

/* hero.css, lead-form.css and the hiring-flow island already honour this;
   the marquees and GSAP-driven reveals in the generated sheets do not. */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}
