/* Banner e pannello preferenze cookie (vedi inc/cookie-consent.php e js/cookie-consent.js) */

#cc-root, #cc-root * { box-sizing: border-box; }
#cc-root [hidden] { display: none !important; }
#cc-root { font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 1.5; color: #222; }

#cc-root a { color: #0071b3; text-decoration: underline; }
#cc-root h2 { margin: 0 0 8px; font-size: 18px; line-height: 1.3; color: #111; font-weight: 700; }
#cc-root p { margin: 0 0 10px; color: #333; }
#cc-root code { background: #f1f1f1; padding: 1px 4px; border-radius: 3px; font-size: 12px; }

/* Banner */
#cc-banner {
	position: fixed; left: 0; right: 0; bottom: 0; z-index: 99998;
	background: #fff; border-top: 3px solid #0071b3; box-shadow: 0 -4px 18px rgba(0, 0, 0, .22);
	animation: cc-in .35s ease-out;
}
.cc-banner-inner { position: relative; max-width: 1100px; margin: 0 auto; padding: 18px 56px 18px 20px; }
#cc-banner .cc-close { top: 10px; right: 12px; }

/* Pulsanti: "Rifiuta" e "Accetta" hanno stesso peso visivo */
.cc-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 12px; }
.cc-btn {
	cursor: pointer; font: inherit; font-weight: 700; line-height: 1.2; padding: 11px 20px; min-height: 44px;
	border-radius: 4px; border: 2px solid #0071b3; text-align: center;
}
.cc-btn-main { background: #0071b3; color: #fff; }
.cc-btn-main:hover, .cc-btn-main:focus { background: #005a8f; border-color: #005a8f; }
.cc-btn-outline { background: #fff; color: #0071b3; }
.cc-btn-outline:hover, .cc-btn-outline:focus { background: #eaf4fa; }
.cc-btn-link { background: transparent; color: #0071b3; border-color: transparent; text-decoration: underline; }
.cc-btn:focus-visible, .cc-close:focus-visible, #cc-root summary:focus-visible { outline: 3px solid #f5a623; outline-offset: 2px; }

.cc-close {
	position: absolute; top: 8px; right: 10px; width: 40px; height: 40px; border: 0; background: transparent;
	font-size: 30px; line-height: 1; color: #555; cursor: pointer;
}
.cc-close:hover { color: #000; }

/* Pannello preferenze */
#cc-modal { position: fixed; inset: 0; z-index: 99999; display: flex; align-items: center; justify-content: center; padding: 12px; }
.cc-modal-backdrop { position: absolute; inset: 0; background: rgba(0, 0, 0, .6); }
.cc-modal-box {
	position: relative; width: 100%; max-width: 640px; max-height: 100%; overflow-y: auto; outline: 0;
	background: #fff; border-radius: 6px; padding: 24px 22px 20px; box-shadow: 0 10px 40px rgba(0, 0, 0, .4);
}
.cc-category { border: 1px solid #ddd; border-radius: 4px; padding: 12px 14px; margin: 0 0 12px; }
.cc-category p { margin-bottom: 6px; }
.cc-category-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 4px; }
.cc-category-head label { font-size: 15px; cursor: pointer; }
.cc-category-head input[type=checkbox] { width: 22px; height: 22px; accent-color: #0071b3; cursor: pointer; flex: none; }
.cc-category-head input[disabled] { cursor: not-allowed; }
#cc-root details { margin-top: 4px; }
#cc-root summary { cursor: pointer; color: #0071b3; font-size: 13px; }
#cc-root details ul { margin: 8px 0 0 18px; padding: 0; font-size: 13px; }
#cc-root details li { margin-bottom: 4px; list-style: disc; }
.cc-note { font-size: 13px; color: #555; }
html.cc-modal-open, html.cc-modal-open body { overflow: hidden; }

/* Segnaposto dei contenuti bloccati (iframe) */
.cc-placeholder {
	display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; text-align: center;
	width: 100%; padding: 20px; background: #f2f2f2; border: 1px dashed #bbb; color: #333; font-family: Arial, Helvetica, sans-serif; font-size: 14px;
}
.cc-placeholder p { margin: 0; max-width: 520px; }

@keyframes cc-in { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { #cc-banner { animation: none; } }

@media (max-width: 600px) {
	.cc-banner-inner { padding: 16px 44px 16px 14px; max-height: 80vh; overflow-y: auto; }
	.cc-actions .cc-btn { flex: 1 1 100%; }
}
