/* Accessibility helpers
----------------------------------------------------------------------------- */

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

.screen-reader-text:focus {
	z-index: 100000;
	top: var(--wp--preset--spacing--20);
	left: var(--wp--preset--spacing--20);
	display: block;
	width: auto;
	height: auto;
	padding: var(--wp--preset--spacing--20) var(--wp--preset--spacing--30);
	clip-path: none;
	color: var(--wp--preset--color--navy-600);
	background-color: var(--wp--preset--color--white);
	box-shadow: var(--wp--preset--shadow--box-shadow);
	text-decoration: none;
	white-space: normal;
}

:where(a, button, input, textarea, select, summary):focus-visible {
	outline: 2px solid currentcolor;
	outline-offset: 3px;
}

/* Keep keyboard targets clear of the fixed site header.
----------------------------------------------------------------------------- */

html {
	scroll-padding-top: calc(4.75rem + var(--wp-admin--admin-bar--height, 0px) + 1rem);
}

/* Branded Video Caption
----------------------------------------------------------------------------- */

/* The caption describes the silent video for screen readers; the design shows none. */
.wp-block-video.is-style-branded-player figcaption {
	position: absolute;
	overflow: hidden;
	width: 1px;
	height: 1px;
	margin: -1px;
	padding: 0;
	border: 0;
	clip-path: inset(50%);
	white-space: nowrap;
}

/* Forced Colors
----------------------------------------------------------------------------- */

@media (forced-colors: active) {

	/* The expandable plus/minus is drawn with backgrounds, which forced colors drops. */
	.wp-block-details.is-style-expandable summary::after {
		forced-color-adjust: none;
		background-image:
			linear-gradient(CanvasText 0 0),
			linear-gradient(CanvasText 0 0);
	}
}
