/*
 * Base styles for wu pages. Every selector is wrapped in :where() so it has zero
 * specificity: any component class overrides it without !important.
 */

:where(.wu-page) {
	display: block;
	color: var(--wu-color-text);
}

:where(.wu-page) :where(img, iframe, video) {
	max-width: 100%;
}

:where(.wu-page) :where(img) {
	display: block;
	height: auto;
}

/* Long German compound words wrap (hyphenated where the browser can) instead of overflowing. */
:where(.wu-page) :where(h1, h2, h3, h4) {
	margin: 0 0 var(--wu-space-sm);
	overflow-wrap: anywhere;
	hyphens: auto;
}

:where(.wu-page) :where(p, ul, ol) {
	margin: 0 0 var(--wu-space-sm);
}

:where(.wu-page) :where(p, ul, ol):where(:last-child) {
	margin-bottom: 0;
}

/* Visually hidden, still read by screen readers. */
.wu-sr-only {
	position: absolute;
	width: 1px;
	height: 1px;
	margin: -1px;
	padding: 0;
	overflow: hidden;
	clip-path: inset(50%);
	white-space: nowrap;
	border: 0;
}

:where(.wu-page) :where(a, button, summary, [tabindex]):where(:focus-visible) {
	outline: 3px solid var(--wu-color-focus);
	outline-offset: 3px;
}
