.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

/* Shared accessibility contract, loaded after component styles.
   Native semantics and control behaviour are unchanged. */
body { --focus-accent: var(--be-yellow); }
body.theme-paper,
.screen--legal,
.screen--apply { --focus-accent: var(--sec-finance); }
.screen--legal .contact-block { --focus-accent: var(--be-yellow); }

/* Text-entry controls use their existing border, never a second ring.
   Keep explicit keyboard outlines for buttons, links and other controls. */
:is(a, button, input, textarea, select, [tabindex]):not(:is(input:not([type="checkbox"], [type="radio"], [type="range"], [type="button"], [type="submit"], [type="reset"], [type="image"], [type="hidden"]), textarea, select)):focus-visible {
  outline: 2px solid var(--focus-accent, var(--be-yellow)) !important;
  outline-offset: 3px !important;
}

/* Includes dynamically rendered fields (application forms and brief edits).
   Only colour changes: border widths, radii and layout stay untouched. */
:is(input:not([type="checkbox"], [type="radio"], [type="range"], [type="button"], [type="submit"], [type="reset"], [type="image"], [type="hidden"]), textarea, select):focus {
  outline: none !important;
  box-shadow: none !important;
  border-color: var(--focus-accent, var(--be-yellow)) !important;
}

/* Borderless inputs delegate the focus indicator to their enclosing field. */
:is(.chat-composer, .agent-intro__composer, .contained-chat):focus-within {
  border-color: var(--focus-accent, var(--be-yellow));
}
.brief-main,
.brief-sidebar { --focus-accent: var(--sec-finance); }

@media (prefers-reduced-motion: reduce) {
  html, body, *, *::before, *::after {
    scroll-behavior: auto !important;
    /* Finish keyframes rather than removing them: reveal animations often
       supply the final visible state. Completion events still fire. */
    animation-duration: .01ms !important;
    animation-delay: 0ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
    transition-delay: 0ms !important;
  }
}
