:root[data-a11y-text-size="125"] {
	font-size: 125%;
	--a11y-text-scale: 1.25;
	--wp--preset--font-size--small: 22.5px;
	--wp--preset--font-size--medium: 30px;
}

:root[data-a11y-text-size="150"] {
	font-size: 150%;
	--a11y-text-scale: 1.5;
	--wp--preset--font-size--small: 27px;
	--wp--preset--font-size--medium: 36px;
}

:root[data-a11y-contrast] {
	--site-background: #000;
	--site-text: #fff;
	--site-border: #fff;
	--site-border-strong: #fff;
	--site-border-soft: #fff;
	--site-muted: #fff;
	--site-muted-soft: #fff;
	--site-border-subtle: #fff;
	--wp--preset--color--base: #000;
	--wp--preset--color--contrast: #fff;
	--wp--preset--color--primary: #fff;
	--wp--preset--color--surface: #000;
	--wp--preset--color--border: #fff;
	--hero-surface: #000 !important;
	--hero-foreground: #fff !important;
	--hero-rule-color: #fff !important;
	--hero-logo-invert: 1 !important;
	color-scheme: dark;
}

:root[data-a11y-contrast] :where(
	body,
	header.wp-block-template-part,
	.site-header,
	.site-header__bar,
	.site-header__menu,
	.site-header__menu .sub-menu,
	.site-header__search-panel,
	.hero,
	.hero__title,
	.hero__title-compact,
	.hero__navigation,
	.competition-intro,
	.sticky-title,
	.sticky-title__compact,
	.child-pages__tabs,
	.participant-profile__tabs,
	.site-footer
) {
	color: #fff !important;
	background-color: #000 !important;
}

:root[data-a11y-contrast] .site-header__brand-image {
	filter: grayscale(1) brightness(0) invert(1) !important;
}

:root[data-a11y-contrast] .site-header__tool svg path {
	fill: currentColor;
}

:root[data-a11y-contrast] .site-footer__partner-image--light {
	filter: grayscale(1) brightness(0) invert(1);
}

:root[data-a11y-contrast] .site-footer__partner--has-dark-logo .site-footer__partner-image--light {
	display: none;
}

:root[data-a11y-contrast] .site-footer__partner-image--dark {
	display: block;
	filter: none;
}

:root[data-a11y-contrast] .site-footer .wp-social-link {
	color: #fff !important;
}

:root[data-a11y-contrast] :where(a, button, input, select, textarea):focus-visible {
	outline-color: #ffeb3b;
}

:root[data-a11y-underline-links] a:not(.site-header__brand-link) {
	text-decoration: underline !important;
	text-decoration-thickness: 0.1em !important;
	text-underline-offset: 0.2em !important;
}

:root[data-a11y-reduced-motion] {
	scroll-behavior: auto !important;
}

:root[data-a11y-reduced-motion] *,
:root[data-a11y-reduced-motion] *::before,
:root[data-a11y-reduced-motion] *::after {
	scroll-behavior: auto !important;
	animation-duration: 0.01ms !important;
	animation-iteration-count: 1 !important;
	transition-duration: 0.01ms !important;
}

:root[data-a11y-reduced-motion] .sticky-submenu {
	position: relative;
	top: auto;
}

:root[data-a11y-reduced-motion] .hero__media {
	position: absolute;
	transform: none;
	will-change: auto;
}

.accessibility-panel {
	position: fixed;
	top: var(--accessibility-panel-top, 70px);
	right: var(--site-gutter);
	z-index: 1200;
	width: min(390px, calc(100vw - (2 * var(--site-gutter))));
	max-height: calc(100dvh - var(--accessibility-panel-top, 70px) - 16px);
	overflow-y: auto;
	border: 1px solid currentColor;
	color: var(--site-text);
	background: var(--site-background);
	box-shadow: 0 12px 30px rgb(0 0 0 / 16%);
}

.accessibility-panel[hidden] {
	display: none;
}

.accessibility-panel__header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	min-height: 64px;
	padding: 14px 20px;
	border-bottom: 1px solid currentColor;
}

.accessibility-panel__title {
	margin: 0;
	font-family: var(--wp--preset--font-family--primary);
	font-size: calc(20px * var(--a11y-text-scale, 1));
	font-weight: 500;
	line-height: 1.2;
}

.accessibility-panel__close {
	display: grid;
	place-items: center;
	width: 36px;
	height: 36px;
	margin: 0;
	padding: 0;
	border: 0;
	color: inherit;
	background: transparent;
	font-size: 30px;
	font-weight: 300;
	line-height: 1;
	cursor: pointer;
}

.accessibility-panel__content {
	display: grid;
	padding: 8px 20px 20px;
}

.accessibility-panel__group {
	min-width: 0;
	margin: 0;
	padding: 16px 0 20px;
	border: 0;
	border-bottom: 1px solid var(--site-border);
}

.accessibility-panel__group legend {
	margin-bottom: 12px;
	padding: 0;
	font-size: calc(16px * var(--a11y-text-scale, 1));
	font-weight: 500;
}

.accessibility-panel__sizes {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 8px;
}

.accessibility-panel__size {
	position: relative;
	display: grid;
	place-items: center;
	min-height: 44px;
	border: 1px solid currentColor;
	cursor: pointer;
}

.accessibility-panel__size input {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	margin: 0;
	opacity: 0;
	cursor: pointer;
}

.accessibility-panel__size:has(input:checked) {
	color: var(--site-background);
	background: var(--site-text);
}

.accessibility-panel__size:has(input:focus-visible) {
	outline: 2px solid currentColor;
	outline-offset: 3px;
}

.accessibility-panel__option {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 20px;
	min-height: 58px;
	margin: 0;
	padding: 12px 0;
	border: 0;
	border-bottom: 1px solid var(--site-border);
	border-radius: 0;
	color: inherit;
	background: transparent;
	font-size: calc(16px * var(--a11y-text-scale, 1));
	font-weight: 400;
	text-align: left;
	cursor: pointer;
}

.accessibility-panel__switch {
	position: relative;
	flex: 0 0 auto;
	width: 42px;
	height: 24px;
	border: 1px solid currentColor;
	border-radius: 999px;
}

.accessibility-panel__switch::after {
	position: absolute;
	top: 3px;
	left: 3px;
	width: 16px;
	height: 16px;
	border-radius: 50%;
	background: currentColor;
	content: "";
	transition: transform 160ms ease;
}

.accessibility-panel__option[aria-pressed="true"] .accessibility-panel__switch::after {
	transform: translateX(18px);
}

.accessibility-panel__reset {
	justify-self: start;
	margin: 20px 0 0;
	padding: 0;
	border: 0;
	border-radius: 0;
	color: inherit;
	background: transparent;
	font-size: calc(15px * var(--a11y-text-scale, 1));
	font-weight: 400;
	text-decoration: underline;
	text-underline-offset: 4px;
	cursor: pointer;
}

body.has-open-accessibility header.wp-block-template-part {
	transform: none;
}

@media (max-width: 1024px) {
	.accessibility-panel {
		right: 0;
		left: 0;
		width: 100%;
		max-height: calc(100dvh - var(--accessibility-panel-top, 64px));
		border-right: 0;
		border-left: 0;
	}
}
