/* ADA accessibility helper styles.
 * Use CSS variables so colors and spacing can be defined once.
 */

:root {
	--ada-focus-outline-color: #FFB800;
}

/* Visually hidden, but accessible to screen readers. */
.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;
}

/* Allow global skip link to become visible when focused */
.skip-link:focus,
.skip-link:focus-visible {
	position: absolute;
	width: auto;
	height: auto;
	clip: auto;
	white-space: normal;
	padding: 1rem;
	text-decoration: none;
	z-index: 1000;
}

/* Consistent keyboard focus visibility for interactive elements. */
:where(
	a[href],
	button,
	input:not([type="hidden"]),
	select,
	textarea,
	summary,
	iframe,
	audio[controls],
	video[controls],
	[contenteditable="true"],
	[role="button"],
	[role="link"],
	[tabindex]:not([tabindex="-1"])
):focus-visible {
	outline: 3px solid var(--ada-focus-outline-color) !important;
	outline-offset: 2px !important;
}
