/* CookieSure banner: six designs (float, card, sheet, center, toast, top). Colours and sizes are CSS variables set by the customizer. */
.cs-root {
	--cs-bg: #fff;
	--cs-text: #0e1b3d;
	--cs-btn: #0e1b3d;
	--cs-btn-text: #fff;
	--cs-accent: #3557e8;
	--cs-radius: 16px;
	--cs-font: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
	--cs-soft: color-mix(in srgb, var(--cs-text) 82%, var(--cs-bg));
	--cs-line: color-mix(in srgb, var(--cs-text) 12%, var(--cs-bg));
	position: fixed;
	z-index: 2147483000;
	box-sizing: border-box;
	font: 14px/1.5 var(--cs-font);
	color: var(--cs-text);
	text-align: left;
}

.cs-root *,
.cs-root *::before,
.cs-root *::after {
	box-sizing: border-box;
}

.cs-root .cs-panel {
	display: flex;
	flex-direction: column;
	gap: 14px;
	padding: 20px;
	border: 1px solid var(--cs-line);
	border-radius: var(--cs-radius);
	background: var(--cs-bg);
	color: var(--cs-text);
	box-shadow: 0 12px 32px rgba(14, 27, 61, 0.12);
}

/* Text. */
.cs-root .cs-title {
	margin: 0;
	font-size: 16px;
	font-weight: 700;
	line-height: 1.3;
	color: inherit;
}

.cs-root .cs-text {
	margin: 0;
	color: var(--cs-soft);
}

.cs-root .cs-text a,
.cs-root .cs-credit {
	color: var(--cs-text);
	text-decoration: underline;
	text-underline-offset: 3px;
}

.cs-root .cs-title-row,
.cs-root .cs-row {
	display: flex;
	align-items: center;
	gap: 10px;
}

.cs-root .cs-row {
	flex-wrap: nowrap;
	align-items: flex-start;
}

.cs-root .cs-row .cs-text {
	flex: 1;
}

.cs-root .cs-col {
	flex: 1;
	display: flex;
	flex-direction: column;
	gap: 6px;
	min-width: 0;
}

.cs-root .cs-icon,
.cs-root .cs-lead {
	display: flex;
	flex-shrink: 0;
	color: var(--cs-accent);
}

.cs-root .cs-credit {
	align-self: flex-end;
	font-size: 12px;
	font-weight: 600;
	color: var(--cs-soft);
	text-decoration: none;
}

.cs-root .cs-credit:hover {
	text-decoration: underline;
}

/* Buttons: Reject and Accept share .cs-main, so they always look the same. */
.cs-root .cs-btns {
	display: grid;
	gap: 8px;
}

.cs-root .cs-btns--2 {
	grid-template-columns: repeat(2, minmax(0, 1fr));
}

.cs-root .cs-btns--3 {
	grid-template-columns: repeat(3, minmax(0, 1fr));
}

.cs-root button.cs-btn {
	min-height: 42px;
	margin: 0;
	padding: 0 14px;
	border-radius: min(var(--cs-radius), 12px);
	font: 700 14px/1.2 var(--cs-font);
	letter-spacing: normal;
	text-transform: none;
	cursor: pointer;
}

.cs-root button.cs-main {
	border: 1.5px solid var(--cs-btn);
	background: var(--cs-btn);
	color: var(--cs-btn-text);
}

.cs-root button.cs-quiet {
	border: 1.5px solid var(--cs-btn);
	background: transparent;
	color: var(--cs-text);
}

.cs-root button.cs-link {
	align-self: center;
	min-height: 36px;
	padding: 0 8px;
	border: 0;
	background: transparent;
	color: var(--cs-text);
	font-weight: 600;
	text-decoration: underline;
	text-underline-offset: 3px;
}

.cs-root button.cs-icon-btn {
	display: flex;
	flex-shrink: 0;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	margin: -8px -8px 0 0;
	padding: 0;
	border: 0;
	border-radius: 10px;
	background: transparent;
	color: var(--cs-accent);
	cursor: pointer;
}

.cs-root button:focus-visible,
.cs-root a:focus-visible,
#cookiesure-float:focus-visible {
	outline: 2px solid var(--cs-accent);
	outline-offset: 2px;
}

.cs-root.cs-outline button.cs-main {
	background: transparent;
	color: var(--cs-btn);
}

/* 1 · Float bar: one line, bottom centre. */
.cs-root.cs-l-float {
	left: 50%;
	bottom: 24px;
	width: min(940px, calc(100% - 32px));
	transform: translateX(-50%);
}

.cs-root.cs-l-float .cs-panel {
	flex-direction: row;
	align-items: center;
	gap: 16px;
	padding: 12px 12px 12px 20px;
	border-radius: max(var(--cs-radius), 14px);
}

.cs-root.cs-l-float .cs-text {
	flex: 1;
}

.cs-root.cs-l-float .cs-btns {
	flex-shrink: 0;
	width: 240px;
}

/* 2 · Corner card. */
.cs-root.cs-l-card {
	left: 24px;
	bottom: 24px;
	width: min(370px, calc(100% - 32px));
}

/* 3 · Bottom sheet, full width. */
.cs-root.cs-l-sheet {
	left: 0;
	right: 0;
	bottom: 0;
}

.cs-root.cs-l-sheet .cs-panel {
	flex-direction: row;
	align-items: center;
	gap: 40px;
	padding: 26px max(24px, calc((100% - 1100px) / 2));
	border-width: 1px 0 0;
	border-radius: max(var(--cs-radius), 12px) max(var(--cs-radius), 12px) 0 0;
	box-shadow: 0 -8px 30px rgba(14, 27, 61, 0.08);
}

.cs-root.cs-l-sheet .cs-title {
	font-size: 17px;
	font-weight: 800;
}

.cs-root.cs-l-sheet .cs-btns {
	flex-shrink: 0;
	width: 420px;
}

/* 4 · Centre with choices, and the privacy settings panel. */
.cs-root.cs-l-center,
.cs-root.cs-prefs {
	inset: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 16px;
	background: rgba(14, 27, 61, 0.32);
}

.cs-root.cs-l-center .cs-panel,
.cs-root.cs-prefs .cs-panel {
	width: 100%;
	max-width: 460px;
	max-height: 100%;
	overflow-y: auto;
	padding: 26px;
	border-radius: max(var(--cs-radius), 14px);
	box-shadow: 0 24px 60px rgba(14, 27, 61, 0.22);
}

.cs-root.cs-l-center .cs-title {
	font-size: 18px;
	font-weight: 800;
}

/* 5 · Toast, small, opposite the usual corner. */
.cs-root.cs-l-toast {
	right: 24px;
	bottom: 24px;
	width: min(350px, calc(100% - 32px));
}

.cs-root.cs-l-toast .cs-panel {
	padding: 18px;
	box-shadow: 0 16px 40px rgba(11, 20, 48, 0.3);
}

/* 6 · Top line, above the page. */
.cs-root.cs-l-top {
	position: relative;
	display: block;
	flex: 0 0 auto;
	align-self: stretch;
	width: 100%;
}

.cs-root.cs-l-top .cs-panel {
	flex-direction: row;
	align-items: center;
	gap: 14px;
	padding: 8px max(20px, calc((100% - 1100px) / 2));
	border-width: 0 0 1px;
	border-radius: 0;
	box-shadow: none;
}

.cs-root.cs-l-top .cs-text {
	flex: 1;
	color: var(--cs-text);
}

.cs-root.cs-l-top .cs-btns {
	flex-shrink: 0;
	width: 210px;
}

.cs-root.cs-l-top button.cs-btn {
	min-height: 38px;
	font-size: 13px;
}

/* Corner side for card and toast. */
.cs-root.cs-l-card.cs-pos-right,
.cs-root.cs-l-toast.cs-pos-right {
	left: auto;
	right: 24px;
}

.cs-root.cs-l-toast.cs-pos-left {
	left: 24px;
	right: auto;
}

/* Compact size. */
.cs-root.cs-compact {
	font-size: 13px;
}

.cs-root.cs-compact .cs-panel {
	gap: 10px;
	padding: 14px 16px;
}

.cs-root.cs-compact .cs-title {
	font-size: 15px;
}

.cs-root.cs-compact button.cs-btn {
	min-height: 38px;
	font-size: 13px;
}

/* Categories and switches (centre design and privacy settings). */
.cs-root .cs-head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
}

.cs-root button.cs-x {
	width: 44px;
	height: 44px;
	margin: -10px -10px -10px 0;
	padding: 0;
	border: 0;
	background: transparent;
	color: inherit;
	font-size: 26px;
	line-height: 1;
	cursor: pointer;
}

.cs-root .cs-cats {
	display: flex;
	flex-direction: column;
}

.cs-root .cs-cat {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 10px 0;
	border-top: 1px solid var(--cs-line);
}

.cs-root .cs-cat-text {
	flex: 1;
	display: flex;
	flex-direction: column;
}

.cs-root .cs-cat-name {
	font-weight: 700;
}

.cs-root .cs-cat-desc {
	font-size: 13px;
	color: var(--cs-soft);
}

.cs-root button.cs-switch {
	flex-shrink: 0;
	display: flex;
	width: 48px;
	height: 28px;
	margin: 0;
	padding: 3px;
	border: 0;
	border-radius: 999px;
	background: #9a958c;
	cursor: pointer;
}

.cs-root button.cs-switch[aria-checked="true"] {
	justify-content: flex-end;
	background: var(--cs-accent);
}

.cs-root button.cs-switch:disabled {
	opacity: 0.6;
	cursor: default;
}

.cs-root .cs-knob {
	display: block;
	width: 22px;
	height: 22px;
	border-radius: 50%;
	background: #fff;
}

/* Floating privacy button. */
#cookiesure-float {
	position: fixed;
	z-index: 2147482999;
	left: 16px;
	bottom: 16px;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: var(--cs-btn, #0e1b3d);
	color: var(--cs-btn-text, #fff);
	box-shadow: 0 6px 16px rgba(14, 27, 61, 0.3);
	cursor: pointer;
}

#cookiesure-float.cs-pos-right {
	left: auto;
	right: 16px;
}

#cookiesure-float.cs-float-label {
	gap: 8px;
	width: auto;
	padding: 0 16px 0 12px;
	border-radius: 999px;
	font: 700 14px/1 var(--cs-font, system-ui, sans-serif);
	letter-spacing: normal;
	text-transform: none;
	white-space: nowrap;
}

/* Phones. */
@media (max-width: 720px) {
	.cs-root.cs-l-float {
		bottom: 12px;
	}

	.cs-root.cs-l-float .cs-panel,
	.cs-root.cs-l-sheet .cs-panel,
	.cs-root.cs-l-top .cs-panel {
		flex-direction: column;
		align-items: stretch;
		gap: 12px;
	}

	.cs-root.cs-l-float .cs-panel {
		padding: 16px;
	}

	.cs-root.cs-l-float .cs-lead,
	.cs-root.cs-l-top .cs-lead {
		display: none;
	}

	.cs-root.cs-l-float .cs-btns,
	.cs-root.cs-l-sheet .cs-btns,
	.cs-root.cs-l-top .cs-btns {
		width: auto;
	}

	.cs-root.cs-l-float .cs-btns,
	.cs-root.cs-l-top .cs-btns {
		order: 1;
	}

	.cs-root.cs-l-float button.cs-link,
	.cs-root.cs-l-top button.cs-link {
		order: 2;
	}

	.cs-root.cs-l-sheet .cs-panel {
		padding: 22px 20px 20px;
	}

	.cs-root.cs-l-card,
	.cs-root.cs-l-toast,
	.cs-root.cs-l-card.cs-pos-right,
	.cs-root.cs-l-toast.cs-pos-left,
	.cs-root.cs-l-toast.cs-pos-right {
		left: 12px;
		right: 12px;
		bottom: 12px;
		width: auto;
	}

	.cs-root .cs-btns--3 {
		grid-template-columns: 1fr;
	}
}

@media (prefers-reduced-motion: no-preference) {
	.cs-root.cs-l-float .cs-panel,
	.cs-root.cs-l-card .cs-panel,
	.cs-root.cs-l-toast .cs-panel,
	.cs-root.cs-l-sheet .cs-panel {
		animation: cs-in 0.25s ease-out;
	}
}

@keyframes cs-in {
	from {
		opacity: 0;
		transform: translateY(12px);
	}
}
