/*
 * Safe fixes — frontend styles, scoped by body classes the fixes module
 * sets per active fix. No !important anywhere (the plugin's contract);
 * selector specificity is chosen to beat the usual theme resets instead.
 */

/* Skip link: visually hidden until it receives focus (WCAG 2.4.1). */
.stmbf-skip-link {
	position: absolute;
	left: -9999px;
	top: 0;
	z-index: 100000;
	padding: 0.75em 1.25em;
	background: #1d2327;
	color: #ffffff;
	font-size: 1rem;
	text-decoration: underline;
}

.stmbf-skip-link:focus {
	left: 8px;
	top: 8px;
	outline: 2px solid #ffffff;
	outline-offset: 2px;
}

/*
 * Visible focus (WCAG 2.4.7): specificity 0-2-2 via body class + pseudo-
 * classes beats the classic theme reset `*:focus { outline: none }`
 * (0-1-0) without resorting to !important. currentColor keeps contrast
 * with whatever text color the themed element already has.
 */
body.stmbf-fix-focus-outline a:focus-visible,
body.stmbf-fix-focus-outline button:focus-visible,
body.stmbf-fix-focus-outline input:focus-visible,
body.stmbf-fix-focus-outline select:focus-visible,
body.stmbf-fix-focus-outline textarea:focus-visible,
body.stmbf-fix-focus-outline [tabindex]:focus-visible {
	outline: 2px solid currentColor;
	outline-offset: 2px;
}

/* Screen-reader-only helper used by the new-window hint. */
.stmbf-sr-text {
	position: absolute;
	width: 1px;
	height: 1px;
	margin: -1px;
	padding: 0;
	overflow: hidden;
	clip: rect(0 0 0 0);
	white-space: nowrap;
	border: 0;
}
