/* BKB Cookie-Consent – Styles (keine externen Assets, keine Webfonts) */

#bkb-cc {
	--bkb-bg: #ffffff;
	--bkb-fg: #14181d;
	--bkb-muted: #59626d;
	--bkb-line: #dfe3e7;
	--bkb-btn: #14181d;
	--bkb-btn-fg: #ffffff;
	--bkb-focus: #1f6feb;
	--bkb-radius: 14px;

	position: relative;
	z-index: 999999;
	color: var(--bkb-fg);
	font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
	font-size: 15px;
	line-height: 1.5;
	-webkit-font-smoothing: antialiased;
}

#bkb-cc[hidden],
#bkb-cc [hidden] {
	display: none !important;
}

#bkb-cc *,
#bkb-cc *::before,
#bkb-cc *::after {
	box-sizing: border-box;
}

#bkb-cc p {
	margin: 0;
}

/* Theme-Abwehr: Astra & Co. setzen eigene Schriften/Transformationen auf
   p, h2 und button. Der Banner bleibt in seiner eigenen Typografie. */
#bkb-cc,
#bkb-cc * {
	font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif !important;
	text-transform: none !important;
	letter-spacing: normal !important;
	font-style: normal !important;
}

#bkb-cc .bkb-cc__title {
	font-size: 16px !important;
	line-height: 1.4 !important;
}

#bkb-cc .bkb-cc__panel-title {
	font-size: 18px !important;
	line-height: 1.3 !important;
}

#bkb-cc .bkb-cc__btn {
	font-size: 15px !important;
	font-weight: 600 !important;
}

#bkb-cc .bkb-cc__link,
#bkb-cc .bkb-cc__privacy {
	font-size: 15px !important;
}

#bkb-cc .bkb-cc__text,
#bkb-cc .bkb-cc__panel-intro,
#bkb-cc .bkb-cc__item-desc {
	font-size: 15px !important;
	font-weight: 400 !important;
	line-height: 1.5 !important;
}

#bkb-cc .bkb-cc__meta,
#bkb-cc .bkb-cc__legal {
	font-size: 12.5px !important;
}

#bkb-cc .bkb-cc__badge {
	font-size: 12px !important;
}

#bkb-cc .bkb-cc__item-label {
	font-size: 15px !important;
	font-weight: 600 !important;
}

/* ---------- Banner ---------- */

#bkb-cc .bkb-cc__banner {
	position: fixed;
	left: 16px;
	right: 16px;
	bottom: 16px;
	max-width: 760px;
	margin: 0 auto;
	background: var(--bkb-bg);
	border: 1px solid var(--bkb-line);
	border-radius: var(--bkb-radius);
	box-shadow: 0 18px 40px -12px rgba(9, 13, 20, 0.28), 0 2px 8px rgba(9, 13, 20, 0.06);
	padding: 20px;
	animation: bkb-cc-in 220ms ease-out;
}

@keyframes bkb-cc-in {
	from {
		opacity: 0;
		transform: translateY(8px);
	}
	to {
		opacity: 1;
		transform: none;
	}
}

#bkb-cc .bkb-cc__inner {
	display: flex;
	flex-direction: column;
	gap: 16px;
}

#bkb-cc .bkb-cc__title {
	font-size: 16px;
	font-weight: 650;
	margin-bottom: 4px;
}

#bkb-cc .bkb-cc__text {
	color: var(--bkb-muted);
	max-width: 62ch;
}

#bkb-cc .bkb-cc__meta {
	margin-top: 10px;
	font-size: 12.5px;
	color: var(--bkb-muted);
	display: flex;
	flex-wrap: wrap;
	gap: 4px 12px;
}

#bkb-cc .bkb-cc__privacy {
	color: var(--bkb-fg);
	text-decoration: underline;
	text-underline-offset: 2px;
}

#bkb-cc .bkb-cc__actions {
	display: flex;
	flex-direction: column;
	gap: 8px;
}

/* Akzeptieren und Ablehnen bewusst gleich gestaltet (kein Dark Pattern). */
#bkb-cc .bkb-cc__btn {
	width: 100%;
	min-height: 44px;
	padding: 10px 18px;
	border: 1px solid var(--bkb-btn);
	border-radius: 10px;
	background: var(--bkb-btn);
	color: var(--bkb-btn-fg);
	font: inherit;
	font-weight: 600;
	cursor: pointer;
	transition: opacity 120ms ease;
}

#bkb-cc .bkb-cc__btn:hover {
	opacity: 0.88;
}

#bkb-cc .bkb-cc__link {
	width: 100%;
	min-height: 44px;
	padding: 6px 12px;
	text-align: center;
	border: 0;
	background: none;
	color: var(--bkb-fg);
	font: inherit;
	text-decoration: underline;
	text-underline-offset: 3px;
	cursor: pointer;
}

/* ---------- Einstellungen ---------- */

#bkb-cc .bkb-cc__modal {
	position: fixed;
	inset: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 16px;
}

#bkb-cc .bkb-cc__backdrop {
	position: absolute;
	inset: 0;
	background: rgba(9, 13, 20, 0.5);
	backdrop-filter: blur(2px);
}

#bkb-cc .bkb-cc__panel {
	position: relative;
	width: 100%;
	max-width: 620px;
	max-height: min(86vh, 720px);
	display: flex;
	flex-direction: column;
	background: var(--bkb-bg);
	border-radius: var(--bkb-radius);
	box-shadow: 0 24px 60px -20px rgba(9, 13, 20, 0.45);
	overflow: hidden;
}

#bkb-cc .bkb-cc__panel-head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	padding: 18px 20px;
	border-bottom: 1px solid var(--bkb-line);
}

#bkb-cc .bkb-cc__panel-title {
	margin: 0;
	font-size: 18px;
	font-weight: 650;
}

#bkb-cc .bkb-cc__close {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 40px;
	border: 1px solid var(--bkb-line);
	border-radius: 10px;
	background: none;
	color: var(--bkb-fg);
	cursor: pointer;
}

#bkb-cc .bkb-cc__close svg {
	display: block !important;
	width: 18px !important;
	height: 18px !important;
	max-width: none !important;
	overflow: visible !important;
	color: inherit !important;
}

#bkb-cc .bkb-cc__close svg path {
	fill: none !important;
	stroke: currentColor !important;
	stroke-width: 2 !important;
	stroke-linecap: round !important;
}

#bkb-cc .bkb-cc__panel-body {
	padding: 20px;
	overflow-y: auto;
	display: flex;
	flex-direction: column;
	gap: 16px;
}

#bkb-cc .bkb-cc__panel-intro {
	color: var(--bkb-muted);
}

#bkb-cc .bkb-cc__list {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	gap: 10px;
}

#bkb-cc .bkb-cc__item {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 16px;
	padding: 14px;
	border: 1px solid var(--bkb-line);
	border-radius: 12px;
}

#bkb-cc .bkb-cc__item--locked {
	background: #f6f7f8;
}

#bkb-cc .bkb-cc__item-copy {
	display: flex;
	flex-direction: column;
	gap: 3px;
	cursor: pointer;
}

#bkb-cc .bkb-cc__item-label {
	font-weight: 600;
}

#bkb-cc .bkb-cc__item-desc {
	font-size: 13.5px;
	color: var(--bkb-muted);
}

#bkb-cc .bkb-cc__badge {
	flex: 0 0 auto;
	align-self: center;
	padding: 4px 10px;
	border-radius: 999px;
	background: #e8eaed;
	color: var(--bkb-muted);
	font-size: 12px;
	white-space: nowrap;
}

#bkb-cc .bkb-cc__switch {
	position: relative;
	flex: 0 0 auto;
	width: 48px;
	height: 28px;
	align-self: center;
}

#bkb-cc .bkb-cc__switch input {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	margin: 0;
	opacity: 0;
	cursor: pointer;
	z-index: 2;
}

#bkb-cc .bkb-cc__switch-ui {
	position: absolute;
	inset: 0;
	border-radius: 999px;
	background: #c9ced4;
	transition: background 140ms ease;
	pointer-events: none;
}

#bkb-cc .bkb-cc__switch-ui::after {
	content: "";
	position: absolute;
	top: 3px;
	left: 3px;
	width: 22px;
	height: 22px;
	border-radius: 50%;
	background: #ffffff;
	box-shadow: 0 1px 2px rgba(9, 13, 20, 0.3);
	transition: transform 140ms ease;
}

#bkb-cc .bkb-cc__switch input:checked + .bkb-cc__switch-ui {
	background: var(--bkb-btn);
}

#bkb-cc .bkb-cc__switch input:checked + .bkb-cc__switch-ui::after {
	transform: translateX(20px);
}

#bkb-cc .bkb-cc__legal {
	font-size: 12.5px;
	color: var(--bkb-muted);
}

#bkb-cc .bkb-cc__panel-foot {
	display: flex;
	gap: 8px;
	padding: 16px 20px;
	border-top: 1px solid var(--bkb-line);
}

/* ---------- Footer-Link ---------- */

.bkb-cc__footer-wrap {
	text-align: center;
	padding: 8px 0;
}

#bkb-cc .bkb-cc__footer-link,
.bkb-cc__footer-link,
.bkb-cc-open {
	font-family: inherit !important;
	text-transform: none !important;
	letter-spacing: normal !important;
	background: none !important;
	background-color: transparent !important;
	border: 0 !important;
	border-radius: 0 !important;
	box-shadow: none !important;
	min-height: 0 !important;
	line-height: 1.4 !important;
	display: inline;
	padding: 4px 6px;
	border: 0;
	background: none;
	font: inherit;
	font-size: 13px;
	color: inherit;
	text-decoration: underline;
	text-underline-offset: 3px;
	cursor: pointer;
}

/* ---------- Fokus ---------- */

#bkb-cc :focus-visible,
.bkb-cc__footer-link:focus-visible,
.bkb-cc-open:focus-visible {
	outline: 3px solid var(--bkb-focus);
	outline-offset: 2px;
	border-radius: 6px;
}

/* ---------- Scroll-Sperre ---------- */

html.bkb-cc--locked,
html.bkb-cc--locked body {
	overflow: hidden;
}

/* ---------- Größere Bildschirme ---------- */

@media (min-width: 640px) {
	#bkb-cc .bkb-cc__banner {
		padding: 22px 24px;
	}

	#bkb-cc .bkb-cc__inner {
		flex-direction: row;
		align-items: flex-end;
		justify-content: space-between;
		gap: 24px;
	}

	#bkb-cc .bkb-cc__copy {
		flex: 1 1 auto;
	}

	#bkb-cc .bkb-cc__actions {
		flex: 0 0 300px;
	}
}

/* ---------- Dunkles System-Design ---------- */

@media (prefers-color-scheme: dark) {
	#bkb-cc {
		--bkb-bg: #171b21;
		--bkb-fg: #f2f4f7;
		--bkb-muted: #a5aeb9;
		--bkb-line: #2c333c;
		--bkb-btn: #f2f4f7;
		--bkb-btn-fg: #14181d;
	}

	#bkb-cc .bkb-cc__item--locked {
		background: #1e232b;
	}

	#bkb-cc .bkb-cc__badge {
		background: #262d36;
	}

	#bkb-cc .bkb-cc__switch-ui {
		background: #3a424d;
	}

	#bkb-cc .bkb-cc__switch-ui::after {
		background: #e9edf2;
	}
}

@media (prefers-reduced-motion: reduce) {
	#bkb-cc .bkb-cc__banner {
		animation: none;
	}

	#bkb-cc .bkb-cc__switch-ui,
	#bkb-cc .bkb-cc__switch-ui::after,
	#bkb-cc .bkb-cc__btn {
		transition: none;
	}
}