/* Aurea CMP — banner brandizzato aureamedia.it */

.aurea-cmp,
.aurea-cmp * {
	box-sizing: border-box;
}

.aurea-cmp {
	position: fixed;
	inset: auto 0 0 0;
	z-index: 999999;
	padding: 24px;
	font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

.aurea-cmp[hidden] {
	display: none !important;
}

.aurea-cmp__panel {
	max-width: 720px;
	margin: 0 auto;
	background: #FFFFFF;
	border: 1px solid #DDDDDD;
	border-radius: 12px;
	box-shadow: 0 24px 60px rgba(10, 10, 10, 0.18), 0 2px 8px rgba(10, 10, 10, 0.08);
	overflow: hidden;
}

.aurea-cmp__body {
	padding: 28px 28px 20px;
}

.aurea-cmp__logo {
	display: block;
	width: 130px;
	height: auto;
	margin: 0 0 22px;
}

#aurea-cmp .aurea-cmp__title {
	margin: 0 0 12px;
	font-family: 'Inter', sans-serif;
	font-size: 17px;
	font-weight: 800;
	line-height: 1.3;
	color: #0A0A0A;
	letter-spacing: -0.01em;
}

.aurea-cmp__text {
	margin: 0 0 18px;
	font-size: 14px;
	font-weight: 500;
	line-height: 1.65;
	color: #333333;
}

/* toggle preferenze */
#aurea-cmp .aurea-cmp__toggle {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 0;
	border: 0;
	background: none;
	cursor: pointer;
	font-family: inherit;
	font-size: 13px;
	font-weight: 600;
	color: #0A0A0A !important;
	text-decoration: underline;
	text-underline-offset: 3px;
	text-decoration-color: #777777;
	text-decoration-thickness: 2px;
	border: 0 !important;
	background: none !important;
	outline-offset: 2px;
}

.aurea-cmp__chevron {
	width: 7px;
	height: 7px;
	border-right: 2px solid #0A0A0A;
	border-bottom: 2px solid #0A0A0A;
	transform: rotate(45deg) translateY(-2px);
	transition: transform 0.2s ease;
}

.aurea-cmp__toggle[aria-expanded="true"] .aurea-cmp__chevron {
	transform: rotate(-135deg) translateY(-2px);
}

.aurea-cmp__details {
	margin-top: 18px;
	padding-top: 18px;
	border-top: 1px solid #EEEEEE;
	max-height: 46vh;
	overflow-y: auto;
}

.aurea-cmp__cat {
	padding: 14px 0;
	border-bottom: 1px solid #F5F5F5;
}

.aurea-cmp__cat:last-of-type {
	border-bottom: 0;
}

.aurea-cmp__cat-head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
}

.aurea-cmp__cat-name {
	font-size: 14px;
	font-weight: 700;
	color: #0A0A0A;
}

.aurea-cmp__cat-desc {
	margin: 6px 0 0;
	font-size: 12.5px;
	font-weight: 500;
	line-height: 1.6;
	color: #777777;
}

.aurea-cmp__cat.is-locked .aurea-cmp__cat-name {
	color: #777777;
}

.aurea-cmp__badge {
	flex: 0 0 auto;
	padding: 3px 8px;
	border-radius: 3px;
	background: #F5F5F5;
	font-size: 10px;
	font-weight: 600;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: #777777;
}

/* switch */
.aurea-cmp__switch {
	position: relative;
	display: inline-block;
	flex: 0 0 auto;
	width: 42px;
	height: 24px;
}

.aurea-cmp__switch input {
	position: absolute;
	opacity: 0;
	width: 100%;
	height: 100%;
	margin: 0;
	cursor: pointer;
}

.aurea-cmp__slider {
	position: absolute;
	inset: 0;
	border-radius: 999px;
	background: #DDDDDD;
	transition: background 0.2s ease;
	pointer-events: none;
}

.aurea-cmp__slider::before {
	content: "";
	position: absolute;
	top: 3px;
	left: 3px;
	width: 18px;
	height: 18px;
	border-radius: 50%;
	background: #FFFFFF;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
	transition: transform 0.2s ease;
}

.aurea-cmp__switch input:checked + .aurea-cmp__slider {
	background: #0A0A0A;
}

.aurea-cmp__switch input:checked + .aurea-cmp__slider::before {
	transform: translateX(18px);
}

.aurea-cmp__switch input:focus-visible + .aurea-cmp__slider {
	outline: 2px solid #777777;
	outline-offset: 2px;
}

.aurea-cmp__links {
	margin: 18px 0 0;
	font-size: 12px;
	font-weight: 500;
	color: #777777;
}

.aurea-cmp__links a {
	color: #0A0A0A;
	text-decoration: underline;
	text-underline-offset: 2px;
}


/* Il tema AUREA impone bordo e radius sui button: azzeriamo con specificità ID */
#aurea-cmp button,
#aurea-cmp .aurea-cmp__btn {
	appearance: none;
	-webkit-appearance: none;
	border-radius: 6px;
	font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif !important;
	text-transform: none;
	box-shadow: none;
	line-height: 1.2;
}

#aurea-cmp button::before,
#aurea-cmp button::after {
	content: none;
	display: none;
}

/* azioni */
.aurea-cmp__actions {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	padding: 18px 28px 24px;
	background: #F5F5F5;
	border-top: 1px solid #EEEEEE;
	flex-wrap: wrap;
}

.aurea-cmp__btn {
	flex: 1 1 auto;
	min-width: 132px;
	padding: 12px 20px;
	border-radius: 6px;
	border: 1px solid transparent;
	font-family: inherit;
	font-size: 13px;
	font-weight: 700;
	letter-spacing: 0.01em;
	cursor: pointer;
	transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

/* Rifiuta e Accetta: peso visivo identico (Linee guida Garante) */
#aurea-cmp .aurea-cmp__btn--equal {
	flex: 1 1 0;
	background: #0A0A0A !important;
	border: 1px solid #0A0A0A !important;
	color: #FFFFFF !important;
	text-decoration: none !important;
}

#aurea-cmp .aurea-cmp__btn--equal:hover {
	background: #333333 !important;
	border-color: #333333 !important;
	color: #FFFFFF !important;
}

/* Salva preferenze: secondario, sotto, meno peso */
#aurea-cmp .aurea-cmp__btn--save {
	flex: 1 0 100%;
	order: 2;
	background: transparent !important;
	border: 1px solid #DDDDDD !important;
	color: #0A0A0A !important;
	text-decoration: none !important;
}

#aurea-cmp .aurea-cmp__btn--save:hover {
	border-color: #0A0A0A !important;
	background: #FFFFFF !important;
}

.aurea-cmp__btn:focus-visible {
	outline: 2px solid #777777;
	outline-offset: 2px;
}

/* bottone rivalidabile: solo icona biscotto, basso a destra */
#aurea-cmp-reopen.aurea-cmp-reopen {
	position: fixed;
	bottom: 16px;
	right: 16px;
	left: auto;
	z-index: 999998;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	min-width: 36px;
	min-height: 36px;
	padding: 0;
	margin: 0;
	border: 0 !important;
	border-radius: 50%;
	background: #0A0A0A !important;
	color: #FFFFFF !important;
	cursor: pointer;
	box-shadow: 0 2px 10px rgba(10, 10, 10, 0.28);
	line-height: 1;
	transition: background 0.15s ease, transform 0.15s ease;
	appearance: none;
	-webkit-appearance: none;
}

#aurea-cmp-reopen.aurea-cmp-reopen:hover {
	background: #333333 !important;
	transform: translateY(-1px);
}

#aurea-cmp-reopen.aurea-cmp-reopen:focus-visible {
	outline: 2px solid #777777;
	outline-offset: 2px;
}

#aurea-cmp-reopen.aurea-cmp-reopen svg {
	display: block;
	width: 18px;
	height: 18px;
	fill: currentColor;
	pointer-events: none;
}

@media (max-width: 600px) {
	.aurea-cmp {
		padding: 12px;
	}

	.aurea-cmp__body {
		padding: 22px 20px 16px;
	}

	.aurea-cmp__logo {
	display: block;
	width: 130px;
	height: auto;
	margin: 0 0 22px;
}

.aurea-cmp__title {
		font-size: 19px;
	}

	.aurea-cmp__actions {
		padding: 14px 20px 18px;
	}

	.aurea-cmp__btn--equal {
		flex: 1 1 calc(50% - 5px);
		min-width: 0;
		padding: 12px 10px;
		font-size: 12.5px;
	}

	.aurea-cmp__btn--save {
		flex: 1 0 100%;
	}
}
