/* State Consent Banner
   Every rule is scoped to the banner's own IDs so that theme and page-builder styles
   (Elementor, Hello and others restyle every <button>, <a>, <h2> and <label>) cannot override it. */
:is(#scb-banner, #scb-modal, #scb-pill),
:is(#scb-banner, #scb-modal, #scb-pill) * {
	box-sizing: border-box;
}

:is(#scb-banner, #scb-modal, #scb-pill) {
	font-family: var(--scb-font-body, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif);
	font-size: 15px;
	line-height: 1.5;
	color: var(--scb-text, #fff);
	-webkit-font-smoothing: antialiased;
}

:is(#scb-banner, #scb-modal, #scb-pill) p,
:is(#scb-banner, #scb-modal, #scb-pill) h2 {
	margin: 0;
	padding: 0;
	color: inherit;
	font-family: inherit;
}

/* ---------- Banner ---------- */
:is(#scb-banner, #scb-modal, #scb-pill).scb-banner {
	position: fixed;
	z-index: 2147483000;
	background: var(--scb-bg, #182738);
	box-shadow: 0 -2px 24px rgba(0, 0, 0, 0.22);
	padding: 20px 24px;
	display: flex;
	gap: 16px 32px;
	animation: scb-rise 0.28s ease-out;
}

:is(#scb-banner, #scb-modal, #scb-pill).scb-banner--bar {
	left: 0;
	right: 0;
	bottom: 0;
	align-items: center;
	justify-content: space-between;
	border-top: 3px solid var(--scb-accent, #0db3b2);
}

:is(#scb-banner, #scb-modal, #scb-pill).scb-banner--left,
:is(#scb-banner, #scb-modal, #scb-pill).scb-banner--right {
	bottom: 20px;
	width: min(420px, calc(100vw - 32px));
	flex-direction: column;
	border-radius: 18px;
	border-top: 3px solid var(--scb-accent, #0db3b2);
	box-shadow: 0 8px 36px rgba(0, 0, 0, 0.3);
}

:is(#scb-banner, #scb-modal, #scb-pill).scb-banner--left { left: 20px; }
:is(#scb-banner, #scb-modal, #scb-pill).scb-banner--right { right: 20px; }

:is(#scb-banner, #scb-modal, #scb-pill) .scb-copy {
	flex: 1 1 0;
	max-width: 74ch;
	min-width: 0;
}

:is(#scb-banner, #scb-modal, #scb-pill) .scb-title {
	font-family: var(--scb-font-heading, system-ui, sans-serif);
	font-size: 20px;
	font-weight: 500;
	letter-spacing: -0.005em;
	line-height: 1.25;
	margin-bottom: 4px !important;
}

:is(#scb-banner, #scb-modal, #scb-pill) .scb-body {
	opacity: 0.92;
}

:is(#scb-banner, #scb-modal, #scb-pill) .scb-policy {
	color: inherit;
	text-decoration: underline;
	text-underline-offset: 2px;
	white-space: nowrap;
}

:is(#scb-banner, #scb-modal, #scb-pill) .scb-gpc {
	margin-top: 8px !important;
	padding-left: 10px;
	border-left: 3px solid var(--scb-accent, #0db3b2);
	font-size: 13.5px;
}

/* ---------- Buttons ---------- */
:is(#scb-banner, #scb-modal, #scb-pill) .scb-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	align-items: center;
	flex-shrink: 0;
}

:is(#scb-banner, #scb-modal, #scb-pill).scb-banner--bar .scb-actions {
	justify-content: flex-end;
	max-width: 60%;
}

:is(#scb-banner, #scb-modal, #scb-pill) .scb-btn {
	appearance: none;
	font: inherit;
	font-weight: 500;
	line-height: 1.25;
	min-height: 46px;
	padding: 10px 22px;
	border-radius: var(--scb-radius, 999px);
	border: 2px solid var(--scb-accent, #0db3b2);
	cursor: pointer;
	text-align: center;
	transition: filter 0.15s ease;
}

/* Accept, reject and opt-out share one style on purpose: no choice is made harder to pick. */
:is(#scb-banner, #scb-modal, #scb-pill) .scb-btn--solid {
	background: var(--scb-accent, #0db3b2);
	color: var(--scb-accent-text, #182738);
}

:is(#scb-banner, #scb-modal, #scb-pill) .scb-btn--ghost {
	background: transparent;
	color: var(--scb-text, #fff);
	border-color: color-mix(in srgb, var(--scb-text, #fff) 55%, transparent);
}

:is(#scb-banner, #scb-modal, #scb-pill) .scb-btn:hover { filter: brightness(1.08); }

:is(#scb-banner, #scb-modal, #scb-pill) .scb-btn:focus-visible,
:is(#scb-banner, #scb-modal, #scb-pill).scb-pill:focus-visible,
:is(#scb-banner, #scb-modal, #scb-pill) .scb-close:focus-visible,
:is(#scb-banner, #scb-modal, #scb-pill) .scb-switch:focus-visible,
:is(#scb-banner, #scb-modal, #scb-pill) .scb-policy:focus-visible {
	outline: 3px solid var(--scb-text, #fff);
	outline-offset: 2px;
}

/* ---------- Reopen button ---------- */
:is(#scb-banner, #scb-modal, #scb-pill).scb-pill {
	position: fixed;
	z-index: 2147482000;
	left: 16px;
	bottom: 16px;
	appearance: none;
	font-size: 13px;
	font-weight: 600;
	padding: 8px 14px;
	border: 0;
	border-radius: 999px;
	background: var(--scb-bg, #182738);
	color: var(--scb-text, #fff);
	box-shadow: 0 2px 12px rgba(0, 0, 0, 0.25);
	cursor: pointer;
}

/* ---------- Preferences panel ---------- */
:is(#scb-banner, #scb-modal, #scb-pill).scb-overlay {
	position: fixed;
	inset: 0;
	z-index: 2147483600;
	background: rgba(0, 0, 0, 0.55);
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 16px;
}

:is(#scb-banner, #scb-modal, #scb-pill) .scb-panel {
	background: var(--scb-bg, #182738);
	width: min(560px, 100%);
	max-height: calc(100vh - 32px);
	overflow-y: auto;
	border-radius: 18px;
	padding: 28px;
	box-shadow: 0 16px 60px rgba(0, 0, 0, 0.45);
	outline: none;
}

:is(#scb-banner, #scb-modal, #scb-pill) .scb-panel-head {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-bottom: 8px;
}

:is(#scb-banner, #scb-modal, #scb-pill) .scb-panel .scb-title { font-size: 26px; }

:is(#scb-banner, #scb-modal, #scb-pill) .scb-close {
	appearance: none;
	background: none;
	border: 0;
	color: inherit;
	font-size: 28px;
	line-height: 1;
	width: 44px;
	height: 44px;
	cursor: pointer;
	border-radius: 6px;
}

:is(#scb-banner, #scb-modal, #scb-pill) .scb-row {
	display: flex;
	justify-content: space-between;
	align-items: flex-start;
	gap: 20px;
	padding: 16px 0;
	border-bottom: 1px solid rgba(128, 128, 128, 0.35);
}

:is(#scb-banner, #scb-modal, #scb-pill) .scb-row-title {
	display: block;
	font-weight: 600;
	cursor: pointer;
}

:is(#scb-banner, #scb-modal, #scb-pill) .scb-row-desc {
	opacity: 0.85;
	font-size: 14px;
}

:is(#scb-banner, #scb-modal, #scb-pill) .scb-row-text {
	min-width: 0;
	flex: 1 1 auto;
}

:is(#scb-banner, #scb-modal, #scb-pill) .scb-cookies {
	margin-top: 10px;
	font-size: 13.5px;
}

:is(#scb-banner, #scb-modal, #scb-pill) .scb-cookies summary {
	cursor: pointer;
	display: inline-block;
	padding: 4px 0;
	text-decoration: underline;
	text-underline-offset: 3px;
	list-style: none;
}

:is(#scb-banner, #scb-modal, #scb-pill) .scb-cookies summary::-webkit-details-marker { display: none; }
:is(#scb-banner, #scb-modal, #scb-pill) .scb-cookies summary::before { content: "+ "; }
:is(#scb-banner, #scb-modal, #scb-pill) .scb-cookies[open] summary::before { content: "\2212  "; }

:is(#scb-banner, #scb-modal, #scb-pill) .scb-cookies summary:focus-visible {
	outline: 3px solid var(--scb-text, #fff);
	outline-offset: 2px;
}

:is(#scb-banner, #scb-modal, #scb-pill) .scb-cookie-list {
	list-style: none;
	margin: 8px 0 0;
	padding: 0;
	border-radius: 10px;
	background: rgba(128, 128, 128, 0.16);
}

:is(#scb-banner, #scb-modal, #scb-pill) .scb-cookie-list li {
	display: grid;
	grid-template-columns: 1fr auto;
	gap: 2px 12px;
	margin: 0;
	padding: 10px 12px;
	border-bottom: 1px solid rgba(128, 128, 128, 0.3);
}

:is(#scb-banner, #scb-modal, #scb-pill) .scb-cookie-list li:last-child { border-bottom: 0; }

:is(#scb-banner, #scb-modal, #scb-pill) .scb-cookie-name {
	font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
	font-size: 13px;
	font-weight: 600;
	overflow-wrap: anywhere;
}

:is(#scb-banner, #scb-modal, #scb-pill) .scb-cookie-meta {
	text-align: right;
	opacity: 0.85;
}

:is(#scb-banner, #scb-modal, #scb-pill) .scb-cookie-purpose {
	grid-column: 1 / -1;
	opacity: 0.85;
}

:is(#scb-banner, #scb-modal, #scb-pill) .scb-switch {
	appearance: none;
	flex-shrink: 0;
	width: 46px;
	height: 26px;
	margin: 2px 0 0;
	border-radius: 999px;
	background: rgba(128, 128, 128, 0.55);
	position: relative;
	cursor: pointer;
	transition: background 0.15s ease;
}

:is(#scb-banner, #scb-modal, #scb-pill) .scb-switch::after {
	content: "";
	position: absolute;
	top: 3px;
	left: 3px;
	width: 20px;
	height: 20px;
	border-radius: 50%;
	background: #fff;
	transition: transform 0.15s ease;
}

:is(#scb-banner, #scb-modal, #scb-pill) .scb-switch:checked { background: var(--scb-accent, #0db3b2); }
:is(#scb-banner, #scb-modal, #scb-pill) .scb-switch:checked::after { transform: translateX(20px); }
:is(#scb-banner, #scb-modal, #scb-pill) .scb-switch:disabled { opacity: 0.55; cursor: not-allowed; }

:is(#scb-banner, #scb-modal, #scb-pill) .scb-panel .scb-actions {
	margin: 20px 0 12px;
	justify-content: flex-end;
}

@keyframes scb-rise {
	from { transform: translateY(16px); opacity: 0; }
	to { transform: none; opacity: 1; }
}

@media (max-width: 860px) {
	:is(#scb-banner, #scb-modal, #scb-pill).scb-banner--bar {
		flex-direction: column;
		align-items: stretch;
		padding: 16px;
	}
	:is(#scb-banner, #scb-modal, #scb-pill).scb-banner--bar .scb-actions { max-width: none; }
	:is(#scb-banner, #scb-modal, #scb-pill).scb-banner .scb-btn { flex: 1 1 auto; }
	:is(#scb-banner, #scb-modal, #scb-pill).scb-banner--left,
	:is(#scb-banner, #scb-modal, #scb-pill).scb-banner--right { left: 16px; right: 16px; bottom: 16px; width: auto; }
}

@media (prefers-reduced-motion: reduce) {
	:is(#scb-banner, #scb-modal, #scb-pill).scb-banner { animation: none; }
	:is(#scb-banner, #scb-modal, #scb-pill) .scb-switch,
	:is(#scb-banner, #scb-modal, #scb-pill) .scb-switch::after,
	:is(#scb-banner, #scb-modal, #scb-pill) .scb-btn { transition: none; }
}

@media print {
	:is(#scb-banner, #scb-modal, #scb-pill) { display: none !important; }
}

/* ---------- "We do not sell" line shown on every pop-up ---------- */
:is(#scb-banner, #scb-modal) .scb-pledge {
	margin: 8px 0 0;
	font-size: 14px;
}

:is(#scb-banner, #scb-modal) .scb-pledge strong { font-weight: 600; }

#scb-modal .scb-pledge { margin-top: 4px; }

#scb-modal .scb-links {
	display: flex;
	flex-wrap: wrap;
	gap: 4px 18px;
	margin: 8px 0 0;
	font-size: 14px;
}

/* ---------- Corner icon ---------- */
#scb-pill.scb-pill--icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 48px;
	height: 48px;
	padding: 0;
	border: 2px solid var(--scb-accent, #0db3b2);
	border-radius: 50%;
	background: var(--scb-bg, #182738);
	color: var(--scb-text, #fff);
	line-height: 0;
}

#scb-pill.scb-pill--icon svg {
	width: 26px;
	height: 26px;
	display: block;
}

#scb-pill.scb-pill--icon:hover { filter: brightness(1.15); }

/* ---------- Neutralise theme styles the rules above do not set ---------- */
:is(#scb-banner, #scb-modal) :is(button, a, label, p, h2, li, ul, summary, input),
#scb-pill {
	text-transform: none;
	letter-spacing: normal;
	text-shadow: none;
	box-shadow: none;
	font-style: normal;
	float: none;
	background-image: none;
	transform: none;
}

:is(#scb-banner, #scb-modal) :is(button, input),
#scb-pill {
	width: auto;
	min-width: 0;
	max-width: none;
	height: auto;
	margin: 0;
	white-space: normal;
	text-decoration: none;
	opacity: 1;
}

:is(#scb-banner, #scb-modal) :is(a, a:hover, a:focus, a:visited) {
	color: inherit;
	background: none;
	text-decoration: underline;
	font-weight: inherit;
}

:is(#scb-banner, #scb-modal) :is(p, label, li, summary) {
	font-size: inherit;
	line-height: inherit;
	color: inherit;
}

:is(#scb-banner, #scb-modal) .scb-title {
	color: inherit;
	padding: 0;
}

:is(#scb-banner, #scb-modal) li::before { content: none; }
:is(#scb-banner, #scb-modal) :is(ul, li) { list-style: none; }

:is(#scb-banner, #scb-modal) .scb-row-title {
	font-size: 15px;
	margin: 0 0 2px;
}

:is(#scb-banner, #scb-modal) .scb-row-desc { font-size: 14px; }

:is(#scb-banner, #scb-modal) .scb-cookies summary,
:is(#scb-banner, #scb-modal) .scb-cookie-list li,
:is(#scb-banner, #scb-modal) .scb-gpc { font-size: 13.5px; }

#scb-modal .scb-switch {
	width: 46px;
	height: 26px;
	min-height: 0;
	padding: 0;
	border: 0;
	margin: 2px 0 0;
}

#scb-modal .scb-switch:disabled { opacity: 0.55; }

#scb-modal .scb-close {
	width: 44px;
	height: 44px;
	padding: 0;
}

#scb-modal .scb-credit {
	display: block;
	margin-top: 10px;
	font-size: 12px;
	opacity: 0.7;
}
