/* ==========================================================================
   Toegankelijkheid – Widget
   ========================================================================== */

.ta-widget {
	--ta-shadow: 0 4px 24px rgba(0, 0, 0, 0.18);
	--ta-radius: 12px;
	--ta-z: 999999;
	--ta-offset-bottom: 80px;
	--ta-viewport-bottom-offset: 0px;

	position: fixed;
	bottom: calc(var(--ta-offset-bottom) + var(--ta-viewport-bottom-offset));
	right: 24px;
	z-index: var(--ta-z);
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, sans-serif;
	font-size: 16px;
	line-height: 1.4;
}

/* Toggle button */
.ta-toggle-wrap {
	position: relative;
	display: inline-flex;
	width: 56px;
	height: 56px;
}

.ta-toggle {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 56px;
	height: 56px;
	padding: 0;
	border: none;
	border-radius: 50%;
	background: transparent;
	color: var(--ta-primary);
	cursor: pointer;
	box-shadow: var(--ta-shadow);
	transition: color 0.2s, transform 0.2s;
}

.ta-toggle:hover,
.ta-toggle:focus-visible {
	color: var(--ta-primary-hover);
	transform: scale(1.05);
	outline: 3px solid var(--ta-primary);
	outline-offset: 3px;
}

.ta-dismiss-widget {
	position: absolute;
	top: -2px;
	right: -2px;
	z-index: 2;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 20px;
	height: 20px;
	padding: 0;
	border: 2px solid #ffffff;
	border-radius: 50%;
	background: #c62828;
	color: #ffffff;
	font-size: 14px;
	font-weight: 700;
	line-height: 1;
	cursor: pointer;
	box-shadow: 0 1px 4px rgba(0, 0, 0, 0.25);
	transition: transform 0.15s, background 0.15s;
}

.ta-dismiss-widget:hover,
.ta-dismiss-widget:focus-visible {
	background: #b71c1c;
	transform: scale(1.08);
	outline: 2px solid #c62828;
	outline-offset: 2px;
}

.ta-dismiss-widget span {
	display: block;
	margin-top: -1px;
}

.ta-toggle-icon {
	display: block;
	width: 56px;
	height: 56px;
}

.ta-toggle-circle {
	fill: currentColor;
}

.ta-toggle-symbol {
	fill: var(--ta-toggle-icon);
}

.ta-toggle-icon--person .ta-toggle-symbol {
	transform-origin: center;
}

html.ta-active .ta-toggle {
	color: var(--ta-toggle-active);
}

html.ta-active .ta-toggle:hover,
html.ta-active .ta-toggle:focus-visible {
	color: var(--ta-toggle-active-hover);
}

/* Panel */
.ta-panel {
	width: 340px;
	max-width: calc(100vw - 48px);
	background-color: var(--ta-panel-bg, #ffffff);
	color: var(--ta-panel-text, #1a1a1a);
	border: 1px solid var(--ta-border);
	border-radius: var(--ta-radius);
	box-shadow: var(--ta-shadow);
	overflow: hidden;
	isolation: isolate;
	display: flex;
	flex-direction: column;
}

/* Popup panel – fixed to viewport so the header/close button stays visible */
.ta-widget > .ta-panel {
	position: fixed;
	right: 24px;
	bottom: calc(var(--ta-offset-bottom) + 68px + var(--ta-viewport-bottom-offset));
	max-height: min(
		85dvh,
		calc(100dvh - var(--ta-offset-bottom) - 80px - env(safe-area-inset-top, 0px) - var(--ta-viewport-bottom-offset))
	);
}

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

.ta-panel-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	flex-shrink: 0;
	padding: 16px 16px 12px;
	border-bottom: 1px solid var(--ta-border);
	background-color: var(--ta-panel-bg, #ffffff);
	position: sticky;
	top: 0;
	z-index: 2;
}

.ta-panel-title {
	margin: 0;
	font-size: 1.125rem;
	font-weight: 700;
}

.ta-close {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	border: none;
	border-radius: 6px;
	background: transparent;
	color: inherit;
	font-size: 1.5rem;
	line-height: 1;
	cursor: pointer;
}

.ta-close:hover,
.ta-close:focus-visible {
	background: var(--ta-btn-hover, #f0f0f0);
	outline: 2px solid var(--ta-primary);
}

.ta-panel-body {
	padding: 16px;
	display: flex;
	flex-direction: column;
	gap: 20px;
	flex: 1;
	min-height: 0;
	overflow-y: auto;
	-webkit-overflow-scrolling: touch;
	background-color: var(--ta-panel-bg, #ffffff);
}

.ta-section {
	display: flex;
	flex-direction: column;
}

.ta-section-title {
	margin: 0 0 12px;
	font-size: 0.875rem;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.04em;
	color: var(--ta-panel-muted, #555);
}

.ta-field-label {
	margin: 0 0 8px;
	font-size: 0.8125rem;
	font-weight: 500;
	color: var(--ta-panel-muted, #444);
}

.ta-field-label:not(:first-child) {
	margin-top: 16px;
}

.ta-button-group {
	display: flex;
	gap: 8px;
	width: 100%;
}

.ta-button-group--stack {
	flex-direction: column;
	align-items: stretch;
}

.ta-button-group--stack .ta-btn {
	width: 100%;
	flex: 0 0 auto;
	align-self: stretch;
}

.ta-btn {
	flex: 1;
	min-height: 46px;
	padding: 12px 12px;
	border: 1px solid var(--ta-border);
	border-radius: 8px;
	background: var(--ta-btn-bg);
	color: var(--ta-btn-text);
	font-size: 0.9375rem;
	font-weight: 500;
	line-height: 1.25;
	cursor: pointer;
	transition: background 0.15s, border-color 0.15s;
	text-align: center;
	display: flex;
	align-items: center;
	justify-content: center;
}

.ta-button-group:not(.ta-button-group--stack) .ta-btn {
	white-space: nowrap;
	padding-left: 6px;
	padding-right: 6px;
	font-size: 0.875rem;
}

.ta-btn:hover,
.ta-btn:focus-visible {
	background: var(--ta-btn-hover);
	border-color: var(--ta-primary);
	outline: none;
}

.ta-btn.is-active {
	background: var(--ta-btn-active-bg);
	border-color: var(--ta-btn-active-bg);
	color: var(--ta-btn-active-text);
}

.ta-btn--full,
.ta-btn--toggle {
	width: 100%;
	flex: none;
	align-self: stretch;
}

.ta-button-group + .ta-button-group,
.ta-button-group + .ta-btn--full,
.ta-button-group + .ta-btn--toggle {
	margin-top: 16px;
}

.ta-speech-controls {
	margin-top: 12px;
}

.ta-speech-controls + .ta-btn--toggle {
	margin-top: 16px;
}

.ta-btn.ta-speech-stop.is-disabled,
.ta-btn.ta-speech-stop:disabled {
	opacity: 0.45;
	cursor: not-allowed;
}

.ta-btn.ta-speech-stop.is-disabled:hover,
.ta-btn.ta-speech-stop.is-disabled:focus-visible,
.ta-btn.ta-speech-stop:disabled:hover,
.ta-btn.ta-speech-stop:disabled:focus-visible {
	background-color: var(--ta-btn-bg);
	border-color: var(--ta-border);
	outline: none;
}

.ta-btn--reset {
	background-color: var(--ta-panel-bg, #ffffff);
	color: var(--ta-btn-reset);
	border-color: var(--ta-btn-reset);
}

.ta-btn--reset:hover,
.ta-btn--reset:focus-visible {
	background: var(--ta-btn-reset-hover, #ffebee);
}

.ta-status {
	margin: 8px 0 0;
	font-size: 0.8125rem;
	color: var(--ta-panel-muted, #666);
	min-height: 1.2em;
}

.ta-conflict-notice {
	color: var(--ta-notice-text, #8a6d00);
	background: var(--ta-notice-bg, #fff8e1);
	border: 1px solid var(--ta-notice-border, #ffe082);
	border-radius: 6px;
	padding: 10px 12px;
	margin-top: 12px;
	margin-bottom: 0;
}

.ta-conflict-notice:not([hidden]) + .ta-button-group,
.ta-conflict-notice:not([hidden]) + .ta-field-label {
	margin-top: 12px;
}

.ta-conflict-notice[hidden] + .ta-button-group {
	margin-top: 8px;
}

.ta-conflict-notice[hidden] {
	display: none;
}

.ta-btn.is-disabled {
	opacity: 0.45;
	cursor: not-allowed;
}

.ta-btn.is-disabled:hover,
.ta-btn.is-disabled:focus-visible {
	background-color: var(--ta-btn-bg);
	border-color: var(--ta-border);
}

.ta-font-increase[hidden],
.ta-font-decrease[hidden],
.ta-cursor-toggle[hidden] {
	display: none !important;
}

html.ta-touch-primary .ta-cursor-toggle {
	display: none !important;
}

/* Shortcode trigger */
.ta-open-trigger--link {
	display: inline;
	padding: 0;
	border: none;
	background: none;
	color: var(--ta-trigger-link, var(--ta-primary, #b1ce3e));
	font: inherit;
	text-decoration: underline;
	text-underline-offset: 2px;
	cursor: pointer;
}

.ta-open-trigger--link:hover,
.ta-open-trigger--link:focus-visible {
	color: var(--ta-trigger-link-hover, var(--ta-primary-hover, #c0d000));
	outline: 2px solid var(--ta-trigger-link, var(--ta-primary, #b1ce3e));
	outline-offset: 2px;
}

.ta-open-trigger--button {
	display: inline-block;
	min-height: 46px;
	padding: 12px 20px;
	border: 1px solid var(--ta-trigger-button-bg, var(--ta-primary, #b1ce3e));
	border-radius: 8px;
	background: var(--ta-trigger-button-bg, var(--ta-primary, #b1ce3e));
	color: var(--ta-trigger-button-text, #000000);
	font: inherit;
	font-weight: 500;
	cursor: pointer;
	transition: background 0.15s, border-color 0.15s;
}

.ta-open-trigger--button:hover,
.ta-open-trigger--button:focus-visible {
	background: var(--ta-trigger-button-hover, var(--ta-primary-hover, #c0d000));
	border-color: var(--ta-trigger-button-hover, var(--ta-primary-hover, #c0d000));
	outline: 2px solid var(--ta-trigger-button-bg, var(--ta-primary, #b1ce3e));
	outline-offset: 2px;
}

@media (max-width: 1024px) {
	.ta-widget {
		right: 16px;
	}

	.ta-widget > .ta-panel {
		right: 16px;
		width: 340px;
		max-width: calc(100vw - 32px);
		bottom: calc(var(--ta-offset-bottom) + 68px + var(--ta-viewport-bottom-offset));
		max-height: min(
			85dvh,
			calc(100dvh - var(--ta-offset-bottom) - 80px - env(safe-area-inset-top, 0px) - var(--ta-viewport-bottom-offset))
		);
	}

	.ta-panel-body {
		padding: 14px 16px 18px;
	}
}

@media (prefers-reduced-motion: reduce) {
	.ta-toggle {
		transition: none;
	}

	.ta-toggle:hover,
	.ta-toggle:focus-visible {
		transform: none;
	}
}

/* ==========================================================================
   Accessibility effects (applied to entire page)
   ========================================================================== */

/*
 * Font scaling – targeted text scaling only (no page zoom).
 * Page zoom breaks sticky/fixed navigation in GeneratePress and similar themes.
 * Header/footer scale via container font-size so menu links inherit without double scaling.
 */
html.ta-no-zoom[data-ta-font="1"] {
	--ta-text-scale: 1.125;
}

html.ta-no-zoom[data-ta-font="2"] {
	--ta-text-scale: 1.25;
}

html.ta-no-zoom[data-ta-font="3"] {
	--ta-text-scale: 1.5;
}

html.ta-no-zoom[data-ta-font="4"] {
	--ta-text-scale: 1.75;
}

html.ta-no-zoom[data-ta-font="5"] {
	--ta-text-scale: 2;
}

html.ta-no-zoom[data-ta-font] :is(
	p,
	li,
	td,
	th,
	dd,
	dt,
	figcaption,
	blockquote,
	h1,
	h2,
	h3,
	h4,
	h5,
	h6,
	.gb-text,
	.gb-headline,
	.gb-button,
	.gbp-button,
	.wp-block-button__link,
	button,
	input:not([type="submit"]):not([type="button"]):not([type="hidden"]):not([type="checkbox"]):not([type="radio"])
):not(.ta-widget *):not(.ta-inline-page *):not(.site-header *):not(#masthead *):not(.ta-btn):not(.menu-toggle):not(.search-submit) {
	font-size: calc(1em * var(--ta-text-scale, 1)) !important;
	line-height: 1.5 !important;
}

html.ta-no-zoom[data-ta-font] :is(h1, h2, h3, h4, h5, h6):not(.ta-widget *):not(.ta-inline-page *):not(.site-header *):not(#masthead *) {
	line-height: 1.25 !important;
}

/* Prevent double scaling on GenerateBlocks inner text spans. */
html.ta-no-zoom[data-ta-font] :is(p, li, h1, h2, h3, h4, h5, h6, blockquote, figcaption, .gb-button, .gb-headline) .gb-text {
	font-size: inherit !important;
	line-height: inherit !important;
}

html.ta-no-zoom[data-ta-font] :is(
	.site-header,
	#masthead,
	.slideout-navigation,
	#generate-slideout-menu
) {
	font-size: calc(1rem * var(--ta-text-scale, 1)) !important;
	line-height: 1.5 !important;
}

/* Override theme px sizes so header & mobile menu text inherits the scaled container size. */
html.ta-no-zoom[data-ta-font] :is(
	.site-header,
	#masthead,
	.slideout-navigation,
	#generate-slideout-menu
) :where(
	.main-navigation a,
	.main-nav a,
	.main-nav li,
	.menu-item a,
	.menu-item,
	.slideout-menu a,
	.slideout-menu li,
	.sub-menu a,
	.inside-navigation a,
	.gb-button,
	.gbp-button,
	.wp-block-button__link,
	button:not(.menu-toggle):not(.slideout-exit)
) {
	font-size: inherit !important;
	line-height: inherit !important;
}

/* Mobile inline menu (GeneratePress toggled nav inside header). */
@media (max-width: 768px) {
	html.ta-no-zoom[data-ta-font] :is(.site-header, #masthead) .main-navigation .main-nav :is(a, li) {
		font-size: calc(1rem * var(--ta-text-scale, 1)) !important;
		line-height: 1.5 !important;
	}
}

html.ta-no-zoom[data-ta-font] :is(.site-footer, #colophon, footer, [role="contentinfo"]) input::placeholder {
	font-size: inherit;
}

html.ta-no-zoom[data-ta-font] .ta-widget,
html.ta-no-zoom[data-ta-font] .ta-inline-page {
	font-size: 16px !important;
}

/* Typography */
html[data-ta-line-height="1"] body,
html[data-ta-line-height="1"] body *:not(.ta-widget):not(.ta-widget *):not(.ta-inline-page):not(.ta-inline-page *) {
	line-height: 1.75 !important;
}

html[data-ta-line-height="2"] body,
html[data-ta-line-height="2"] body *:not(.ta-widget):not(.ta-widget *):not(.ta-inline-page):not(.ta-inline-page *) {
	line-height: 2.1 !important;
}

html[data-ta-letter-spacing="1"] body,
html[data-ta-letter-spacing="1"] body *:not(.ta-widget):not(.ta-widget *):not(.ta-inline-page):not(.ta-inline-page *) {
	letter-spacing: 0.08em !important;
}

html[data-ta-letter-spacing="2"] body,
html[data-ta-letter-spacing="2"] body *:not(.ta-widget):not(.ta-widget *):not(.ta-inline-page):not(.ta-inline-page *) {
	letter-spacing: 0.14em !important;
}

html[data-ta-word-spacing="1"] body,
html[data-ta-word-spacing="1"] body *:not(.ta-widget):not(.ta-widget *):not(.ta-inline-page):not(.ta-inline-page *) {
	word-spacing: 0.2em !important;
}

html[data-ta-word-spacing="2"] body,
html[data-ta-word-spacing="2"] body *:not(.ta-widget):not(.ta-widget *):not(.ta-inline-page):not(.ta-inline-page *) {
	word-spacing: 0.35em !important;
}

/* Text alignment – content text only, so navigation/layouts stay intact */
html[data-ta-text-align="left"] body :is(
	p, li, h1, h2, h3, h4, h5, h6, blockquote, td, th, dd, dt, figcaption, address, pre, summary, label,
	.entry-content, .entry-summary, .gb-headline, .wp-block-paragraph, .wp-block-heading, .wp-block-quote
):not(.ta-widget *):not(.ta-inline-page *) {
	text-align: left !important;
}

html[data-ta-text-align="center"] body :is(
	p, li, h1, h2, h3, h4, h5, h6, blockquote, td, th, dd, dt, figcaption, address, pre, summary, label,
	.entry-content, .entry-summary, .gb-headline, .wp-block-paragraph, .wp-block-heading, .wp-block-quote
):not(.ta-widget *):not(.ta-inline-page *) {
	text-align: center !important;
}

html[data-ta-text-align="right"] body :is(
	p, li, h1, h2, h3, h4, h5, h6, blockquote, td, th, dd, dt, figcaption, address, pre, summary, label,
	.entry-content, .entry-summary, .gb-headline, .wp-block-paragraph, .wp-block-heading, .wp-block-quote
):not(.ta-widget *):not(.ta-inline-page *) {
	text-align: right !important;
}

html[data-ta-dyslexia="1"] body,
html[data-ta-dyslexia="1"] body *:not(.ta-widget):not(.ta-widget *):not(.ta-inline-page):not(.ta-inline-page *) {
	font-family: "OpenDyslexic", sans-serif !important;
}

/* Visual filters – skip navigation areas so dropdown submenus stay visible.
   Applying filter to header/nav breaks fixed/absolute positioned submenus. */
html[data-ta-filter="grayscale"] body > *:not(.ta-widget):not(.ta-inline-page):not(header):not(.site-header):not(#masthead):not(nav):not([role="navigation"]):not([role="banner"]):not(:has(> header, > .site-header, > #masthead, > nav, > [role="navigation"])) {
	filter: grayscale(100%);
}

html[data-ta-filter="grayscale"] body > *:not(.ta-widget):not(.ta-inline-page):has(> header, > .site-header, > #masthead) > .site-content,
html[data-ta-filter="grayscale"] body > *:not(.ta-widget):not(.ta-inline-page):has(> header, > .site-header, > #masthead) > #content,
html[data-ta-filter="grayscale"] body > *:not(.ta-widget):not(.ta-inline-page):has(> header, > .site-header, > #masthead) > .content-area,
html[data-ta-filter="grayscale"] body > *:not(.ta-widget):not(.ta-inline-page):has(> header, > .site-header, > #masthead) > footer,
html[data-ta-filter="grayscale"] body > *:not(.ta-widget):not(.ta-inline-page):has(> header, > .site-header, > #masthead) > .site-footer,
html[data-ta-filter="grayscale"] body > *:not(.ta-widget):not(.ta-inline-page):has(> header, > .site-header, > #masthead) > #colophon {
	filter: grayscale(100%);
}

html[data-ta-filter="desaturate"] body > *:not(.ta-widget):not(.ta-inline-page):not(header):not(.site-header):not(#masthead):not(nav):not([role="navigation"]):not([role="banner"]):not(:has(> header, > .site-header, > #masthead, > nav, > [role="navigation"])) {
	filter: saturate(40%);
}

html[data-ta-filter="desaturate"] body > *:not(.ta-widget):not(.ta-inline-page):has(> header, > .site-header, > #masthead) > .site-content,
html[data-ta-filter="desaturate"] body > *:not(.ta-widget):not(.ta-inline-page):has(> header, > .site-header, > #masthead) > #content,
html[data-ta-filter="desaturate"] body > *:not(.ta-widget):not(.ta-inline-page):has(> header, > .site-header, > #masthead) > .content-area,
html[data-ta-filter="desaturate"] body > *:not(.ta-widget):not(.ta-inline-page):has(> header, > .site-header, > #masthead) > footer,
html[data-ta-filter="desaturate"] body > *:not(.ta-widget):not(.ta-inline-page):has(> header, > .site-header, > #masthead) > .site-footer,
html[data-ta-filter="desaturate"] body > *:not(.ta-widget):not(.ta-inline-page):has(> header, > .site-header, > #masthead) > #colophon {
	filter: saturate(40%);
}

/* Highlight links */
html[data-ta-highlight-links="1"] body a:not(.ta-widget *):not(.ta-inline-page *) {
	text-decoration: underline !important;
	text-decoration-thickness: 2px !important;
	text-underline-offset: 3px;
	outline: 2px solid var(--ta-highlight-links, var(--ta-primary, #b1ce3e)) !important;
	outline-offset: 2px;
}

/* Text links in content: subtle background (not buttons) */
html[data-ta-highlight-links="1"] body :where(p, li, span, td, th, dd, dt, blockquote, figcaption, label, h1, h2, h3, h4, h5, h6) a:not(.ta-widget *):not(.ta-inline-page *) {
	background-color: color-mix(in srgb, var(--ta-highlight-links, #b1ce3e) 12%, transparent) !important;
}

/* Button-style links: keep theme colors, add visible double ring */
html[data-ta-highlight-links="1"] body a:is(
	.button,
	.btn,
	.wp-block-button__link,
	.wp-element-button,
	.gb-button,
	[class*="gb-button"]
),
html[data-ta-highlight-links="1"] body :is(
	.wp-block-button,
	.gb-button,
	.button,
	.btn
) a {
	box-shadow: 0 0 0 2px #fff, 0 0 0 4px var(--ta-highlight-links, var(--ta-primary, #b1ce3e)) !important;
}

/* Hide images */
html[data-ta-hide-images="1"] body img:not(.ta-widget *):not(.ta-inline-page *),
html[data-ta-hide-images="1"] body picture:not(.ta-widget *):not(.ta-inline-page *),
html[data-ta-hide-images="1"] body video:not(.ta-widget *):not(.ta-inline-page *),
html[data-ta-hide-images="1"] body svg[role="img"]:not(.ta-widget *):not(.ta-inline-page *) {
	display: none !important;
}

html[data-ta-hide-images="1"] body *:not(.ta-widget):not(.ta-widget *):not(.ta-inline-page):not(.ta-inline-page *) {
	background-image: none !important;
}

/* Big cursor */
html[data-ta-big-cursor="1"] body,
html[data-ta-big-cursor="1"] body *:not(.ta-widget):not(.ta-widget *):not(.ta-inline-page):not(.ta-inline-page *) {
	cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='48' height='48' viewBox='0 0 24 24'%3E%3Cpath fill='%23000' stroke='%23fff' stroke-width='1' d='M4 4l7 18 2.5-7.5L21 12z'/%3E%3C/svg%3E") 4 4, auto !important;
}

/* High contrast */
html[data-ta-contrast="high"] body,
html[data-ta-contrast="high"] body *:not(.ta-widget):not(.ta-widget *):not(.ta-inline-page):not(.ta-inline-page *) {
	background-color: #000 !important;
	color: #fff !important;
	border-color: #fff !important;
}

html[data-ta-contrast="high"] body a:not(.ta-widget *):not(.ta-inline-page *),
html[data-ta-contrast="high"] body a:visited:not(.ta-widget *):not(.ta-inline-page *) {
	color: #ffff00 !important;
}

html[data-ta-contrast="high"] body img:not(.ta-widget *):not(.ta-inline-page *),
html[data-ta-contrast="high"] body video:not(.ta-widget *):not(.ta-inline-page *) {
	filter: grayscale(100%) contrast(1.2);
}

/* Dark mode */
html[data-ta-contrast="dark"] body,
html[data-ta-contrast="dark"] body *:not(.ta-widget):not(.ta-widget *):not(.ta-inline-page):not(.ta-inline-page *) {
	background-color: #121212 !important;
	color: #e0e0e0 !important;
	border-color: #444 !important;
}

html[data-ta-contrast="dark"] body a:not(.ta-widget *):not(.ta-inline-page *),
html[data-ta-contrast="dark"] body a:visited:not(.ta-widget *):not(.ta-inline-page *) {
	color: #90caf9 !important;
}

/* Yellow on black */
html[data-ta-contrast="yellow"] body,
html[data-ta-contrast="yellow"] body *:not(.ta-widget):not(.ta-widget *):not(.ta-inline-page):not(.ta-inline-page *) {
	background-color: #000 !important;
	color: #ffff00 !important;
	border-color: #ffff00 !important;
}

html[data-ta-contrast="yellow"] body a:not(.ta-widget *):not(.ta-inline-page *),
html[data-ta-contrast="yellow"] body a:visited:not(.ta-widget *):not(.ta-inline-page *) {
	color: #ffff00 !important;
	text-decoration: underline !important;
}

/* Keep widget readable regardless of page contrast */
.ta-widget .ta-panel,
.ta-widget .ta-panel-header,
.ta-widget .ta-panel-body,
.ta-inline-page .ta-panel,
.ta-inline-page .ta-panel-header,
.ta-inline-page .ta-panel-body {
	background-color: var(--ta-panel-bg, #ffffff) !important;
	color: var(--ta-panel-text, #1a1a1a) !important;
}

.ta-widget .ta-panel-header {
	position: sticky !important;
	top: 0 !important;
	z-index: 2 !important;
}

.ta-widget .ta-panel-title,
.ta-inline-page .ta-panel-title {
	color: var(--ta-panel-text, #1a1a1a) !important;
}

.ta-widget .ta-section-title,
.ta-inline-page .ta-section-title {
	color: var(--ta-panel-muted, #555555) !important;
}

.ta-widget .ta-btn,
.ta-inline-page .ta-btn {
	background-color: var(--ta-btn-bg) !important;
	color: var(--ta-btn-text) !important;
	border-color: var(--ta-border) !important;
}

.ta-widget .ta-btn:hover,
.ta-widget .ta-btn:focus-visible,
.ta-inline-page .ta-btn:hover,
.ta-inline-page .ta-btn:focus-visible {
	background-color: var(--ta-btn-hover) !important;
	border-color: var(--ta-primary) !important;
}

.ta-widget .ta-btn.is-active,
.ta-inline-page .ta-btn.is-active {
	background-color: var(--ta-btn-active-bg) !important;
	border-color: var(--ta-btn-active-bg) !important;
	color: var(--ta-btn-active-text) !important;
}

.ta-widget .ta-btn--reset,
.ta-inline-page .ta-btn--reset {
	background-color: var(--ta-panel-bg, #ffffff) !important;
	color: var(--ta-btn-reset) !important;
	border-color: var(--ta-btn-reset) !important;
}

.ta-widget .ta-btn--reset:hover,
.ta-widget .ta-btn--reset:focus-visible,
.ta-inline-page .ta-btn--reset:hover,
.ta-inline-page .ta-btn--reset:focus-visible {
	background-color: var(--ta-btn-reset-hover, #ffebee) !important;
}

.ta-widget .ta-close {
	background-color: var(--ta-panel-bg, #ffffff) !important;
	color: var(--ta-panel-text, #1a1a1a) !important;
}

.ta-widget .ta-close:hover,
.ta-widget .ta-close:focus-visible {
	background-color: var(--ta-btn-hover, #f0f0f0) !important;
}

.ta-widget .ta-status,
.ta-inline-page .ta-status {
	color: var(--ta-panel-muted, #666666) !important;
}

.ta-widget .ta-conflict-notice,
.ta-inline-page .ta-conflict-notice {
	color: var(--ta-notice-text, #8a6d00) !important;
	background-color: var(--ta-notice-bg, #fff8e1) !important;
	border-color: var(--ta-notice-border, #ffe082) !important;
}

.ta-widget .ta-field-label,
.ta-inline-page .ta-field-label {
	color: var(--ta-panel-muted, #444444) !important;
}

.ta-widget .ta-toggle {
	background-color: transparent !important;
	color: var(--ta-primary) !important;
}

html.ta-active .ta-widget .ta-toggle {
	color: var(--ta-toggle-active) !important;
}

html.ta-active .ta-widget .ta-toggle:hover,
html.ta-active .ta-widget .ta-toggle:focus-visible {
	color: var(--ta-toggle-active-hover) !important;
}

.ta-widget .ta-toggle-symbol {
	fill: var(--ta-toggle-icon) !important;
}

/* ==========================================================================
   Inline settings page (shortcode)
   ========================================================================== */

.ta-inline-page {
	--ta-radius: 12px;

	max-width: 640px;
	margin: 0 auto 2rem;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, sans-serif;
	font-size: 16px;
	line-height: 1.4;
}

.ta-inline-page .ta-panel--inline {
	position: static;
	width: 100%;
	max-width: none;
	max-height: none;
	border: 1px solid var(--ta-border);
	border-radius: var(--ta-radius);
	box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
	overflow: hidden;
	isolation: isolate;
}

.ta-inline-page .ta-panel-header--inline {
	position: static;
	padding: 20px 20px 16px;
}

.ta-inline-page .ta-panel-body {
	padding: 0 20px 20px;
	max-height: none;
	overflow: visible;
}

/* Highlight text being read */
.ta-speaking {
	outline: 3px solid var(--ta-primary) !important;
	outline-offset: 2px;
}

/* Hidden floating widget */
html.ta-widget-hidden #ta-widget {
	display: none !important;
}

/* Notice after hiding the floating widget */
.ta-widget-hidden-notice {
	position: fixed;
	bottom: 24px;
	left: 50%;
	transform: translateX(-50%);
	z-index: 999998;
	display: flex;
	align-items: center;
	gap: 12px;
	max-width: min(560px, calc(100vw - 48px));
	padding: 16px 16px 16px 18px;
	border: 1px solid var(--ta-border, #d0d0d0);
	border-radius: 12px;
	background: var(--ta-panel-bg, #ffffff);
	color: var(--ta-panel-text, #1a1a1a);
	box-shadow: 0 4px 24px rgba(0, 0, 0, 0.18);
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, sans-serif;
	font-size: 0.9375rem;
	line-height: 1.45;
}

.ta-widget-hidden-notice[hidden] {
	display: none !important;
}

.ta-widget-hidden-notice-text {
	margin: 0;
	flex: 1;
	min-width: 0;
}

.ta-widget-hidden-notice-actions {
	display: flex;
	align-items: center;
	gap: 4px;
	flex-shrink: 0;
}

.ta-widget-notice-undo {
	flex-shrink: 0;
	min-height: 36px;
	padding: 8px 12px;
	border: 1px solid var(--ta-btn-active-bg, var(--ta-primary, #b1ce3e));
	border-radius: 8px;
	background: var(--ta-btn-active-bg, var(--ta-primary, #b1ce3e));
	color: var(--ta-btn-active-text, #000000);
	font: inherit;
	font-size: 0.875rem;
	font-weight: 600;
	line-height: 1.2;
	cursor: pointer;
	white-space: nowrap;
}

.ta-widget-notice-undo:hover,
.ta-widget-notice-undo:focus-visible {
	background: var(--ta-primary-hover, #c0d000);
	border-color: var(--ta-primary-hover, #c0d000);
	color: var(--ta-btn-active-text, #000000);
	outline: 2px solid var(--ta-primary, #b1ce3e);
	outline-offset: 2px;
}

.ta-widget-notice-dismiss {
	flex-shrink: 0;
	width: 36px;
	height: 36px;
	padding: 0;
	border: none;
	border-radius: 8px;
	background: transparent;
	color: var(--ta-panel-text, #1a1a1a);
	font-size: 1.5rem;
	line-height: 1;
	cursor: pointer;
}

.ta-widget-notice-dismiss:hover,
.ta-widget-notice-dismiss:focus-visible {
	background: var(--ta-btn-hover, #f0f0f0);
	outline: 2px solid var(--ta-primary, #b1ce3e);
	outline-offset: 2px;
}

@media (max-width: 520px) {
	.ta-widget-hidden-notice {
		flex-wrap: wrap;
		align-items: flex-start;
	}

	.ta-widget-hidden-notice-actions {
		width: 100%;
		justify-content: flex-end;
	}
}

.ta-widget-section-intro--hidden {
	background: var(--ta-info-bg, #f5f8eb);
	border: 1px solid var(--ta-info-border, #d8e6b8);
	border-radius: 8px;
	padding: 10px 12px;
	margin-bottom: 16px;
}

.ta-widget-section .ta-btn--full + .ta-btn--full {
	margin-top: 16px;
}

.ta-widget-section + .ta-reset {
	margin-top: 16px;
}

.ta-widget-section .ta-btn[hidden] {
	display: none !important;
}

html[data-ta-contrast] .ta-widget-hidden-notice,
html[data-ta-filter] .ta-widget-hidden-notice {
	filter: none !important;
	background-color: var(--ta-panel-bg, #ffffff) !important;
	color: var(--ta-panel-text, #1a1a1a) !important;
	border-color: var(--ta-border, #d0d0d0) !important;
}

html[data-ta-contrast] .ta-widget-notice-dismiss,
html[data-ta-filter] .ta-widget-notice-dismiss {
	color: var(--ta-panel-text, #1a1a1a) !important;
	background-color: transparent !important;
}

html[data-ta-contrast] .ta-widget-notice-undo,
html[data-ta-filter] .ta-widget-notice-undo {
	filter: none !important;
	background-color: var(--ta-btn-active-bg, var(--ta-primary, #b1ce3e)) !important;
	border-color: var(--ta-btn-active-bg, var(--ta-primary, #b1ce3e)) !important;
	color: var(--ta-btn-active-text, #000000) !important;
}

/* ==========================================================================
   Reading aids: leeslijn, leesmasker, vergrootglas
   ========================================================================== */

.ta-reading-line,
.ta-reading-mask,
.ta-magnifier {
	filter: none !important;
	pointer-events: none;
	z-index: 999990;
}

.ta-reading-line[hidden],
.ta-reading-mask[hidden],
.ta-magnifier[hidden] {
	display: none !important;
}

.ta-reading-line {
	position: fixed;
	left: 0;
	right: 0;
	height: 0;
	border-top: 3px solid #e53935;
	box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.85);
	transform: translateY(-1px);
}

.ta-reading-mask {
	position: fixed;
	inset: 0;
	z-index: 999989;
	--ta-mask-top: 0px;
	--ta-mask-band: 90px;
	background:
		linear-gradient(
			to bottom,
			rgba(0, 0, 0, 0.72) 0,
			rgba(0, 0, 0, 0.72) var(--ta-mask-top),
			transparent var(--ta-mask-top),
			transparent calc(var(--ta-mask-top) + var(--ta-mask-band)),
			rgba(0, 0, 0, 0.72) calc(var(--ta-mask-top) + var(--ta-mask-band)),
			rgba(0, 0, 0, 0.72) 100%
		);
}

.ta-reading-mask-band {
	display: none;
}

.ta-magnifier {
	position: fixed;
	width: 200px;
	height: 200px;
	border-radius: 50%;
	border: 3px solid #1a1a1a;
	box-shadow:
		0 0 0 3px rgba(255, 255, 255, 0.9),
		0 8px 28px rgba(0, 0, 0, 0.35);
	overflow: hidden;
	background: #ffffff;
	z-index: 999991;
}

.ta-magnifier-lens {
	position: absolute;
	top: 0;
	left: 0;
	transform-origin: 0 0;
	will-change: transform;
}

html.ta-reading-aids-on {
	cursor: crosshair;
}

html.ta-click-to-speak {
	cursor: pointer;
}

html.ta-click-to-speak body :is(p, li, h1, h2, h3, h4, h5, h6, blockquote, td, th, dd, dt, figcaption, pre, summary):not(.ta-widget *):not(.ta-inline-page *) {
	cursor: pointer;
}

html.ta-click-to-speak body :is(p, li, h1, h2, h3, h4, h5, h6, blockquote, td, th, dd, dt, figcaption, pre, summary):not(.ta-widget *):not(.ta-inline-page *):hover {
	outline: 2px dashed var(--ta-primary, #b1ce3e);
	outline-offset: 2px;
}

.ta-click-to-speak-hint {
	margin: 8px 0 0;
	font-size: 0.8125rem;
	color: var(--ta-panel-muted, #666);
}

.ta-magnifier-zoom-controls {
	margin-top: 12px;
}

.ta-magnifier-zoom-controls[hidden] {
	display: none !important;
}

.ta-click-to-speak-hint[hidden] {
	display: none !important;
}

@media (pointer: coarse) {
	.ta-magnifier {
		width: 160px;
		height: 160px;
	}
}
