/* Barra contatto fissa (S8 #3). Solo sotto 600 px; sempre caricato, nessun effetto altrove. */
.cc-sticky {
	display: none;
}

@media (max-width: 600px) {
	.cc-sticky {
		position: fixed;
		right: 0;
		bottom: 0;
		left: 0;
		z-index: 15;
		display: flex;
		gap: 8px;
		height: calc(56px + env(safe-area-inset-bottom, 0px));
		padding: 6px 12px env(safe-area-inset-bottom, 0px);
		background: #fff;
		box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.1);
		transition: transform 200ms ease, visibility 200ms;
	}

	/* Senza JS la barra e sempre visibile; con JS compare quando serve. */
	.cc-js .cc-sticky {
		visibility: hidden;
		transform: translateY(100%);
	}

	.cc-js .cc-sticky.is-visible {
		visibility: visible;
		transform: none;
	}

	/* Banner cookie aperto: la barra non lo copre. */
	body:has([data-cc-cookie]:not([hidden])) .cc-sticky {
		visibility: hidden;
		transform: translateY(100%);
	}

	.cc-sticky__btn {
		display: flex;
		flex: 1 1 0;
		align-items: center;
		justify-content: center;
		gap: 8px;
		min-height: 44px;
		border-radius: var(--wp--custom--radius--tondo);
		color: #fff;
		font-weight: 600;
		font-size: var(--wp--preset--font-size--body);
		text-decoration: none;
	}

	.cc-sticky__btn--call {
		background: var(--cc-red);
	}

	.cc-sticky__btn--wa {
		background: var(--cc-wa);
	}

	.cc-sticky__btn img {
		width: 20px;
		height: 20px;
	}

	/* Il footer arriva sotto la barra: padding per non coprire contenuti. */
	.cc-footer {
		padding-bottom: calc(16px + 56px + env(safe-area-inset-bottom, 0px));
	}
}

@media (prefers-reduced-motion: reduce) {
	.cc-sticky {
		transition: none;
	}
}
