/*
 * Konform – Barrierefreiheits-Assistent.
 * Panel-Styles plus die Regeln, die am <html>-Element greifen.
 * Keine eigenen Schriften, keine externen Ressourcen.
 */

/* ---------- Sprunglink ---------- */

.kf-skip {
	position: absolute;
	top: 0;
	left: -9999px;
	z-index: 2147483100;
	padding: 0.75rem 1.125rem;
	background: var(--kf-accent, #1f6feb);
	color: var(--kf-accent-fg, #fff);
	font: inherit;
	font-weight: 600;
	text-decoration: none;
	border-radius: 0 0 calc(var(--kf-radius, 14px) / 2) 0;
}

.kf-skip:focus {
	left: 0;
}

/* ---------- Panel ---------- */

.kf-a11y .kf-box {
	width: min(30rem, calc(100% - 2rem));
}

.kf-close {
	margin-left: auto;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 2rem;
	height: 2rem;
	padding: 0;
	border: 1px solid var(--kf-border, #e2e5ea);
	border-radius: 50%;
	background: transparent;
	color: var(--kf-muted, #5b6472);
	cursor: pointer;
}

.kf-close:hover {
	color: var(--kf-fg, #16181d);
}

.kf-a-row {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 0.5rem;
	padding: 0.625rem 0;
	border-top: 1px solid var(--kf-border, #e2e5ea);
}

.kf-a-row__label {
	font: inherit;
	font-size: 0.875em;
	font-weight: 600;
}

.kf-a-step {
	display: inline-flex;
	align-items: center;
	gap: 0.375rem;
}

.kf-a-step__btn {
	font: inherit;
	font-size: 1em;
	font-weight: 700;
	line-height: 1;
	width: 2.25rem;
	height: 2.25rem;
	border: 1px solid var(--kf-border, #e2e5ea);
	border-radius: calc(var(--kf-radius, 14px) / 2);
	background: var(--kf-surface, #f5f6f8);
	color: inherit;
	cursor: pointer;
}

.kf-a-step__btn[aria-disabled="true"] {
	opacity: 0.4;
	cursor: default;
}

.kf-a-step__out {
	font: inherit;
	font-size: 0.8125em;
	font-variant-numeric: tabular-nums;
	min-width: 3.5rem;
	text-align: center;
	color: var(--kf-muted, #5b6472);
}

.kf-a-seg {
	display: flex;
	flex-wrap: wrap;
	gap: 0.25rem;
}

.kf-a-seg button {
	font: inherit;
	font-size: 0.75em;
	padding: 0.4375rem 0.625rem;
	border: 1px solid var(--kf-border, #e2e5ea);
	border-radius: calc(var(--kf-radius, 14px) / 2);
	background: var(--kf-surface, #f5f6f8);
	color: inherit;
	cursor: pointer;
}

.kf-a-seg button[aria-pressed="true"] {
	background: var(--kf-accent, #1f6feb);
	border-color: var(--kf-accent, #1f6feb);
	color: var(--kf-accent-fg, #fff);
	font-weight: 600;
}

.kf-a-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(10rem, 1fr));
	gap: 0.375rem;
	margin: 0.75rem 0 0;
}

.kf-a-toggle {
	font: inherit;
	font-size: 0.8125em;
	display: flex;
	align-items: center;
	gap: 0.5rem;
	padding: 0.625rem 0.75rem;
	text-align: left;
	border: 1px solid var(--kf-border, #e2e5ea);
	border-radius: calc(var(--kf-radius, 14px) / 2);
	background: var(--kf-surface, #f5f6f8);
	color: inherit;
	cursor: pointer;
}

.kf-a-toggle__dot {
	flex: 0 0 auto;
	width: 0.75rem;
	height: 0.75rem;
	border: 2px solid var(--kf-muted, #5b6472);
	border-radius: 50%;
}

.kf-a-toggle[aria-pressed="true"] {
	border-color: var(--kf-accent, #1f6feb);
	box-shadow: inset 0 0 0 1px var(--kf-accent, #1f6feb);
}

.kf-a-toggle[aria-pressed="true"] .kf-a-toggle__dot {
	background: var(--kf-accent, #1f6feb);
	border-color: var(--kf-accent, #1f6feb);
}

.kf-a-hint:empty {
	display: none;
}

.kf-a-hint {
	font: inherit;
	font-size: 0.75em;
	margin: 0.75rem 0 0;
	padding: 0.5rem 0.625rem;
	border-radius: calc(var(--kf-radius, 14px) / 2);
	background: var(--kf-surface, #f5f6f8);
	color: var(--kf-fg, #16181d);
}

.kf-a-note {
	font-size: 0.75em;
	margin: 0.75rem 0 1rem;
}

/* ---------- Lesemaske ---------- */

.kf-mask {
	position: fixed;
	left: 0;
	right: 0;
	z-index: 2147482000;
	background: rgba(0, 0, 0, 0.7);
	pointer-events: none;
}

/* ---------- Wirkung am <html>-Element ---------- */

html[data-kf-space="1"] body :is(p, li, dd, dt, blockquote, td, th, figcaption) {
	line-height: 1.6 !important;
	letter-spacing: 0.06em !important;
	word-spacing: 0.1em !important;
}

html[data-kf-space="2"] body :is(p, li, dd, dt, blockquote, td, th, figcaption) {
	line-height: 2 !important;
	letter-spacing: 0.12em !important;
	word-spacing: 0.16em !important;
}

html[data-kf-contrast="high"] body,
html[data-kf-contrast="high"] body * {
	background-color: #000 !important;
	background-image: none !important;
	color: #fff !important;
	border-color: #fff !important;
	text-shadow: none !important;
}

html[data-kf-contrast="high"] body a,
html[data-kf-contrast="high"] body a * {
	color: #ffff00 !important;
	text-decoration: underline !important;
}

html[data-kf-contrast="high"] .kf-btn--accent,
html[data-kf-contrast="high"] .kf-a-seg button[aria-pressed="true"],
html[data-kf-contrast="high"] .kf-icon {
	background-color: #ffff00 !important;
	color: #000 !important;
}

html[data-kf-contrast="high"] .kf-switch input:checked + .kf-switch__track {
	background-color: #ffff00 !important;
}

html[data-kf-contrast="invert"] {
	filter: invert(1) hue-rotate(180deg);
	background: #fff;
}

html[data-kf-contrast="invert"] img,
html[data-kf-contrast="invert"] picture,
html[data-kf-contrast="invert"] video,
html[data-kf-contrast="invert"] iframe,
html[data-kf-contrast="invert"] .kf {
	filter: invert(1) hue-rotate(180deg);
}

html[data-kf-contrast="gray"] {
	filter: grayscale(1);
}

html.kf-a-links body a {
	text-decoration: underline !important;
	text-underline-offset: 0.15em;
}

html.kf-a-readable body,
html.kf-a-readable body :is(p, li, dd, dt, h1, h2, h3, h4, h5, h6, blockquote, figcaption, label, a, span, strong, em, td, th, button, input, select, textarea) {
	font-family: system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif !important;
}

html.kf-a-focus :focus {
	outline: 3px solid #ffbf00 !important;
	outline-offset: 3px !important;
	border-radius: 2px;
}

html.kf-a-motion *,
html.kf-a-motion *::before,
html.kf-a-motion *::after {
	animation-duration: 0.001s !important;
	animation-iteration-count: 1 !important;
	transition-duration: 0.001s !important;
	scroll-behavior: auto !important;
}

html.kf-a-images body :is(img, picture, video, canvas) {
	visibility: hidden !important;
}

html.kf-a-images .kf img,
html.kf-a-images .kf svg {
	visibility: visible !important;
}

html.kf-a-cursor,
html.kf-a-cursor * {
	cursor: url("data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20width='42'%20height='42'%20viewBox='0%200%2024%2024'%3E%3Cpath%20d='M5%202l14%209-6%201%203%207-3%201-3-7-5%204z'%20fill='%23ffffff'%20stroke='%23000000'%20stroke-width='1.4'/%3E%3C/svg%3E") 3 2, auto !important;
}

html.kf-a-tts body :is(p, li, h1, h2, h3, h4, h5, h6, blockquote, dd, figcaption):hover {
	outline: 2px dashed var(--kf-accent, #1f6feb);
	outline-offset: 2px;
	cursor: help;
}

@media print {
	.kf-skip,
	.kf-mask {
		display: none !important;
	}
}
