/*!
 * Bludoors Consenso Cookie 1.0.0 - stile
 * Usa i token del Design System Bludoors (variabili del kit Elementor) con valori di riserva.
 */

.bd-cc,
.bd-cc-modal {
	--bd-ink: var(--neutral-800, #2E2E2E);
	--bd-muted: var(--neutral-600, #616161);
	--bd-title: var(--blu-700, #101D54);
	--bd-primary: var(--blu-700, #101D54);
	--bd-primary-hover: var(--blu-500, #2F4582);
	--bd-soft: var(--blu-050, #E3EEFC);
	--bd-line: var(--neutral-100, #E0E0E0);
	--bd-field: var(--neutral-400, #949494);
	--bd-focus: var(--blu-300, #5D79B2);
	--bd-radius: var(--radius-lg, 16px);
	--bd-radius-lg: var(--radius-xxl, 24px);
	--bd-font: var(--font-body, 'Montserrat'), system-ui, -apple-system, 'Segoe UI', sans-serif;
	--bd-font-head: var(--font-heading, 'Poppins'), system-ui, -apple-system, 'Segoe UI', sans-serif;
	--bd-ease: cubic-bezier(.4, 0, .2, 1);
	font-family: var(--bd-font);
	font-size: 16px;
	line-height: 1.55;
	color: var(--bd-ink);
}

.bd-cc *,
.bd-cc-modal * { box-sizing: border-box; }

.bd-cc p,
.bd-cc-modal p,
.bd-cc-modal h2,
.bd-cc-modal h3 { margin: 0; }

.bd-cc a,
.bd-cc-modal a {
	color: var(--blu-500, #2F4582);
	text-decoration: underline;
	text-underline-offset: 2px;
}
.bd-cc a:hover,
.bd-cc-modal a:hover { color: var(--bd-primary); }

/* Barra in basso */
.bd-cc {
	position: fixed;
	z-index: 99998;
	left: 16px;
	right: 16px;
	bottom: 16px;
	max-width: 1080px;
	margin: 0 auto;
	background: #fff;
	border: 1px solid var(--bd-line);
	border-radius: var(--bd-radius-lg);
	box-shadow: 0 16px 48px rgba(16, 29, 84, .16);
	opacity: 0;
	transform: translateY(16px);
	transition: opacity .25s var(--bd-ease), transform .25s var(--bd-ease);
	max-height: calc(100vh - 32px);
	overflow-y: auto;
}
.bd-cc[hidden] { display: none; }
.bd-cc.is-visible { opacity: 1; transform: none; }
.bd-cc:focus { outline: none; }

.bd-cc__inner {
	position: relative;
	display: grid;
	gap: 20px;
	padding: 24px 56px 24px 24px;
}

.bd-cc__title {
	font-family: var(--bd-font-head);
	font-weight: 600;
	font-size: 18px;
	line-height: 1.3;
	color: var(--bd-title);
	margin-bottom: 8px !important;
}
.bd-cc__text { font-size: 14px; color: var(--bd-ink); max-width: 68ch; }

.bd-cc__actions {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
}

.bd-cc__close {
	position: absolute;
	top: 12px;
	right: 12px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	padding: 0;
	border: 0;
	border-radius: 999px;
	background: transparent;
	color: var(--bd-title);
	cursor: pointer;
	transition: background-color .15s var(--bd-ease);
}
.bd-cc__close:hover { background: var(--bd-soft); }

@media (min-width: 900px) {
	.bd-cc__inner {
		grid-template-columns: minmax(0, 1fr) auto;
		align-items: center;
		gap: 32px;
		padding: 24px 72px 24px 32px;
	}
	.bd-cc__actions { flex-wrap: nowrap; }
}

@media (max-width: 599px) {
	.bd-cc__actions { flex-direction: column; }
	.bd-cc__actions .bd-btn { width: 100%; }
}

/* Pulsanti: "Rifiuta" e "Accetta" hanno lo stesso peso visivo */
.bd-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 48px;
	padding: 0 24px;
	border: 2px solid var(--bd-primary);
	border-radius: var(--bd-radius);
	font-family: var(--bd-font-head);
	font-weight: 600;
	font-size: 15px;
	line-height: 1.2;
	white-space: nowrap;
	cursor: pointer;
	transition: background-color .25s var(--bd-ease), color .25s var(--bd-ease), border-color .25s var(--bd-ease);
}
.bd-btn--fill { background: var(--bd-primary); color: #fff; }
.bd-btn--fill:hover { background: var(--bd-primary-hover); border-color: var(--bd-primary-hover); }
.bd-btn--line { background: #fff; color: var(--bd-primary); }
.bd-btn--line:hover { background: var(--bd-soft); }

.bd-btn:focus-visible,
.bd-cc__close:focus-visible,
.bd-cc a:focus-visible,
.bd-cc-modal a:focus-visible,
.bd-switch__input:focus-visible + .bd-switch__track,
.bd-cc-link:focus-visible {
	outline: 3px solid var(--bd-focus);
	outline-offset: 2px;
}

/* Finestra delle preferenze */
.bd-cc-modal {
	position: fixed;
	inset: 0;
	z-index: 99999;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 16px;
}
.bd-cc-modal[hidden] { display: none; }

.bd-cc-modal__backdrop {
	position: absolute;
	inset: 0;
	background: rgba(1, 5, 17, .55);
}

.bd-cc-modal__panel {
	position: relative;
	width: 100%;
	max-width: 640px;
	max-height: calc(100vh - 32px);
	overflow-y: auto;
	padding: 32px 24px 24px;
	background: #fff;
	border-radius: var(--bd-radius-lg);
	box-shadow: 0 16px 48px rgba(16, 29, 84, .24);
}
.bd-cc-modal__panel:focus { outline: none; }

.bd-cc-modal__title {
	font-family: var(--bd-font-head);
	font-weight: 700;
	font-size: 24px;
	line-height: 1.2;
	color: var(--bd-title);
	margin-bottom: 12px !important;
	padding-right: 48px;
}
.bd-cc-modal__intro { font-size: 14px; margin-bottom: 20px !important; }

.bd-cc-modal__panel .bd-cc__close { top: 16px; right: 16px; }

.bd-cat {
	padding: 16px;
	margin-bottom: 12px;
	border: 1px solid var(--bd-line);
	border-radius: var(--bd-radius);
}
.bd-cat__head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	margin-bottom: 6px;
}
.bd-cat__title {
	font-family: var(--bd-font-head);
	font-weight: 600;
	font-size: 16px;
	line-height: 1.3;
	color: var(--bd-title);
	cursor: pointer;
}
h3.bd-cat__title { cursor: default; }
.bd-cat__fixed {
	flex: 0 0 auto;
	padding: 2px 10px;
	border-radius: 999px;
	background: var(--bd-soft);
	color: var(--blu-700, #101D54);
	font-size: 12px;
	font-weight: 600;
}
.bd-cat__text { font-size: 14px; color: var(--bd-muted); }

/* Interruttore */
.bd-switch {
	position: relative;
	flex: 0 0 auto;
	width: 52px;
	height: 32px;
}
.bd-switch__input {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	margin: 0;
	opacity: 0;
	cursor: pointer;
	z-index: 1;
}
.bd-switch__track {
	position: absolute;
	inset: 0;
	border-radius: 999px;
	background: var(--bd-field);
	transition: background-color .25s var(--bd-ease);
}
.bd-switch__track::after {
	content: '';
	position: absolute;
	top: 4px;
	left: 4px;
	width: 24px;
	height: 24px;
	border-radius: 999px;
	background: #fff;
	transition: transform .25s var(--bd-ease);
}
.bd-switch__input:checked + .bd-switch__track { background: var(--bd-primary); }
.bd-switch__input:checked + .bd-switch__track::after { transform: translateX(20px); }

.bd-cc__actions--modal { margin-top: 20px; }

/* Link "Preferenze cookie" (shortcode) */
.bd-cc-link {
	padding: 0;
	border: 0;
	background: none;
	font: inherit;
	color: inherit;
	text-decoration: underline;
	text-underline-offset: 2px;
	cursor: pointer;
}

.bd-cc-lock { overflow: hidden; }

@media (prefers-reduced-motion: reduce) {
	.bd-cc,
	.bd-btn,
	.bd-switch__track,
	.bd-switch__track::after,
	.bd-cc__close { transition: none; }
	.bd-cc { transform: none; }
}

/* Fix 1.0.1: il tema (Hello Elementor) colora i <button> di fucsia #c36 e vince sulle regole a una sola classe. Qui si impone il blu del Design System con piu' specificita'. */
.bd-cc .bd-btn,
.bd-cc-modal .bd-btn {
	display: inline-flex;
	padding: 0 24px;
	border: 2px solid var(--bd-primary);
	border-radius: var(--bd-radius);
	font-family: var(--bd-font-head);
	font-size: 15px;
	font-weight: 600;
	white-space: nowrap;
}
.bd-cc .bd-btn--fill,
.bd-cc-modal .bd-btn--fill {
	background: var(--bd-primary);
	border-color: var(--bd-primary);
	color: #fff;
}
.bd-cc .bd-btn--fill:hover,
.bd-cc .bd-btn--fill:focus,
.bd-cc-modal .bd-btn--fill:hover,
.bd-cc-modal .bd-btn--fill:focus {
	background: var(--bd-primary-hover);
	border-color: var(--bd-primary-hover);
	color: #fff;
}
.bd-cc .bd-btn--line,
.bd-cc-modal .bd-btn--line {
	background: #fff;
	border-color: var(--bd-primary);
	color: var(--bd-primary);
}
.bd-cc .bd-btn--line:hover,
.bd-cc .bd-btn--line:focus,
.bd-cc-modal .bd-btn--line:hover,
.bd-cc-modal .bd-btn--line:focus {
	background: var(--bd-soft);
	border-color: var(--bd-primary);
	color: var(--bd-primary);
}
.bd-cc .bd-cc__close,
.bd-cc-modal .bd-cc__close {
	padding: 0;
	border: 0;
	background: transparent;
	color: var(--bd-title);
}
.bd-cc .bd-cc__close:hover,
.bd-cc .bd-cc__close:focus,
.bd-cc-modal .bd-cc__close:hover,
.bd-cc-modal .bd-cc__close:focus {
	background: var(--bd-soft);
	color: var(--bd-title);
}
button.bd-cc-link {
	display: inline;
	padding: 0;
	border: 0;
	background: none;
	font: inherit;
	color: var(--blu-500, #2F4582);
	text-decoration: underline;
	text-underline-offset: 2px;
	white-space: normal;
	text-align: left;
}
button.bd-cc-link:hover,
button.bd-cc-link:focus {
	background: none;
	color: var(--blu-700, #101D54);
}