/* ============================================
   WhatsApp Sticky Button (floating bottom-right)
   ============================================ */

.ra-wa-sticky {
	position: fixed;
	right: 20px;
	bottom: 20px;
	z-index: 998; /* sotto il modale ma sopra tutto il resto */
	animation: ra-wa-pop-in 0.5s ease-out 1s both;
}

@keyframes ra-wa-pop-in {
	from {
		opacity: 0;
		transform: translateY(20px) scale(0.8);
	}
	to {
		opacity: 1;
		transform: translateY(0) scale(1);
	}
}

.ra-wa-sticky__btn {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	padding: 12px 20px 12px 14px;
	background: #25D366; /* WhatsApp official green */
	color: #fff;
	border-radius: 50px;
	font-family: var(--ra-font-ui);
	font-weight: 600;
	font-size: 15px;
	text-decoration: none;
	box-shadow: 0 6px 20px rgba(37, 211, 102, 0.4);
	transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
	white-space: nowrap;
	cursor: pointer;
}

.ra-wa-sticky__btn:hover {
	background: #1eb557;
	color: #fff;
	transform: translateY(-3px) scale(1.02);
	box-shadow: 0 10px 28px rgba(37, 211, 102, 0.5);
}

.ra-wa-sticky__btn:active {
	transform: translateY(-1px) scale(0.99);
}

.ra-wa-sticky__icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	background: rgba(255, 255, 255, 0.18);
	border-radius: 50%;
	flex-shrink: 0;
	transition: transform 0.4s ease;
}

.ra-wa-sticky__btn:hover .ra-wa-sticky__icon {
	transform: rotate(-8deg) scale(1.05);
}

.ra-wa-sticky__icon .ra-icon {
	width: 22px;
	height: 22px;
	color: #fff;
}

.ra-wa-sticky__label {
	max-width: 260px;
	overflow: hidden;
	text-overflow: ellipsis;
}

/* Pulse ring animation — attira l'attenzione senza essere invadente */
.ra-wa-sticky__btn::before {
	content: '';
	position: absolute;
	inset: 0;
	border-radius: 50px;
	border: 3px solid #25D366;
	opacity: 0;
	animation: ra-wa-pulse 2.5s ease-out infinite;
	animation-delay: 3s;
	pointer-events: none;
}

@keyframes ra-wa-pulse {
	0% { opacity: 0.5; transform: scale(1); }
	100% { opacity: 0; transform: scale(1.15); }
}

.ra-wa-sticky__btn { position: relative; }

/* === Mobile: bottone più piccolo, ma con label sempre visibile === */
@media (max-width: 600px) {
	.ra-wa-sticky {
		right: 14px;
		bottom: 14px;
	}
	.ra-wa-sticky__btn {
		padding: 10px 16px 10px 10px;
		font-size: 14px;
	}
	.ra-wa-sticky__icon {
		width: 30px;
		height: 30px;
	}
	.ra-wa-sticky__icon .ra-icon {
		width: 18px;
		height: 18px;
	}
}

/* === Su schermi molto piccoli: nascondi label se serve === */
@media (max-width: 380px) {
	.ra-wa-sticky__label {
		display: none;
	}
	.ra-wa-sticky__btn {
		padding: 12px;
		gap: 0;
	}
}

/* === Stampa: non mostrare === */
@media print {
	.ra-wa-sticky { display: none !important; }
}

/* === Rispetta reduced motion === */
@media (prefers-reduced-motion: reduce) {
	.ra-wa-sticky { animation: none; }
	.ra-wa-sticky__btn::before { animation: none; }
}
