/**
 * Bandeau promotions — intégration page d'accueil / réservation (thème Colvert)
 */

.colvert-home-promotions-section {
	position: relative;
	overflow: hidden;
}

.colvert-home-promotions-section::before {
	content: "";
	position: absolute;
	top: -40%;
	right: -10%;
	width: min(420px, 55vw);
	height: min(420px, 55vw);
	border-radius: 50%;
	background: radial-gradient(circle, rgba(59, 130, 246, 0.08) 0%, transparent 70%);
	pointer-events: none;
}

.colvert-home-promotions-inner {
	position: relative;
	z-index: 1;
}

.colvert-reservation-promotions {
	margin-left: calc(-1 * min(2rem, 5vw));
	margin-right: calc(-1 * min(2rem, 5vw));
}

@media (min-width: 768px) {
	.colvert-reservation-promotions {
		margin-left: -2rem;
		margin-right: -2rem;
	}
}

/* Bouton promo flottant — bas droite accueil */
.colvert-promo-float-widget {
	position: fixed !important;
	right: 1rem !important;
	bottom: 1.25rem !important;
	z-index: 99990 !important;
	display: inline-flex !important;
	align-items: center;
	gap: 0.65rem;
	padding: 0;
	border: 0;
	background: transparent;
	cursor: pointer;
	font: inherit;
	color: inherit;
	text-align: left;
	max-width: min(26rem, calc(100vw - 2rem));
	animation: colvert-promo-float-enter 0.5s ease-out;
}

.colvert-promo-float-widget:hover .colvert-promo-float-bubble,
.colvert-promo-float-widget:focus-visible .colvert-promo-float-bubble {
	transform: translateX(0);
	opacity: 1;
}

.colvert-promo-float-widget:hover .colvert-promo-float-btn,
.colvert-promo-float-widget:focus-visible .colvert-promo-float-btn {
	transform: scale(1.06);
}

.colvert-promo-float-widget:focus-visible {
	outline: none;
}

.colvert-promo-float-widget:focus-visible .colvert-promo-float-btn {
	outline: 3px solid #fff;
	outline-offset: 3px;
}

/* Bulle d'accroche */
.colvert-promo-float-bubble {
	position: relative;
	flex: 1;
	min-width: 0;
	padding: 0.75rem 1rem;
	background: #fff;
	color: #1e293b;
	border-radius: 1rem;
	border: 2px solid #f97316;
	box-shadow: 0 12px 32px -8px rgba(0, 0, 0, 0.35);
	line-height: 1.35;
	font-size: 0.88rem;
	font-weight: 700;
	transition: transform 0.2s ease, opacity 0.2s ease;
}

.colvert-promo-float-bubble::after {
	content: "";
	position: absolute;
	right: -0.45rem;
	top: 50%;
	transform: translateY(-50%);
	width: 0;
	height: 0;
	border-top: 0.5rem solid transparent;
	border-bottom: 0.5rem solid transparent;
	border-left: 0.5rem solid #f97316;
}

.colvert-promo-float-bubble::before {
	content: "";
	position: absolute;
	right: -0.28rem;
	top: 50%;
	transform: translateY(-50%);
	width: 0;
	height: 0;
	border-top: 0.38rem solid transparent;
	border-bottom: 0.38rem solid transparent;
	border-left: 0.38rem solid #fff;
	z-index: 1;
}

.colvert-promo-float-bubble__text {
	display: block;
}

.colvert-promo-float-bubble__discount {
	display: inline-block;
	margin-left: 0.2rem;
	font-size: 1.15em;
	font-weight: 900;
	color: #ea580c;
	letter-spacing: -0.02em;
}

/* Bouton rond orange */
.colvert-promo-float-btn {
	position: relative;
	flex-shrink: 0;
	width: 4.25rem;
	height: 4.25rem;
	display: flex;
	align-items: center;
	justify-content: center;
	border-radius: 9999px;
	background: linear-gradient(145deg, #fb923c 0%, #f97316 45%, #ea580c 100%);
	color: #fff;
	box-shadow:
		0 0 0 4px rgba(249, 115, 22, 0.35),
		0 12px 28px -6px rgba(234, 88, 12, 0.65);
	transition: transform 0.2s ease, box-shadow 0.2s ease;
	animation: colvert-promo-float-btn-pulse 2.2s ease-in-out infinite;
}

.colvert-promo-float-btn__ring {
	position: absolute;
	inset: -6px;
	border-radius: inherit;
	border: 2px solid rgba(251, 146, 60, 0.55);
	animation: colvert-promo-float-ring 2.2s ease-out infinite;
	pointer-events: none;
}

.colvert-promo-float-btn i {
	font-size: 1.45rem;
	font-weight: 900;
	line-height: 1;
}

.colvert-promo-float-btn__count {
	position: absolute;
	top: -0.15rem;
	right: -0.15rem;
	min-width: 1.35rem;
	height: 1.35rem;
	padding: 0 0.3rem;
	display: flex;
	align-items: center;
	justify-content: center;
	border-radius: 9999px;
	background: #dc2626;
	color: #fff;
	font-size: 0.72rem;
	font-weight: 900;
	border: 2px solid #fff;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

@keyframes colvert-promo-float-enter {
	from {
		opacity: 0;
		transform: translateY(1rem);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

@keyframes colvert-promo-float-btn-pulse {
	0%,
	100% {
		box-shadow:
			0 0 0 4px rgba(249, 115, 22, 0.35),
			0 12px 28px -6px rgba(234, 88, 12, 0.65);
	}
	50% {
		box-shadow:
			0 0 0 8px rgba(251, 146, 60, 0.45),
			0 14px 32px -4px rgba(234, 88, 12, 0.75);
	}
}

@keyframes colvert-promo-float-ring {
	0% {
		transform: scale(1);
		opacity: 0.85;
	}
	70%,
	100% {
		transform: scale(1.35);
		opacity: 0;
	}
}

@media (prefers-reduced-motion: reduce) {
	.colvert-promo-float-widget,
	.colvert-promo-float-btn,
	.colvert-promo-float-btn__ring {
		animation: none;
	}
}

@media (min-width: 768px) {
	.colvert-promo-float-widget {
		right: 1.5rem !important;
		bottom: 1.75rem !important;
		gap: 0.85rem;
		max-width: 28rem;
	}

	.colvert-promo-float-bubble {
		padding: 0.9rem 1.15rem;
		font-size: 0.95rem;
		border-radius: 1.1rem;
	}

	.colvert-promo-float-bubble__discount {
		font-size: 1.2em;
	}

	.colvert-promo-float-btn {
		width: 4.75rem;
		height: 4.75rem;
	}

	.colvert-promo-float-btn i {
		font-size: 1.6rem;
	}
}

@media (max-width: 420px) {
	.colvert-promo-float-bubble {
		font-size: 0.8rem;
		padding: 0.65rem 0.85rem;
		max-width: 13.5rem;
	}

	.colvert-promo-float-btn {
		width: 3.85rem;
		height: 3.85rem;
	}

	.colvert-promo-float-btn i {
		font-size: 1.25rem;
	}
}

body.admin-bar .colvert-promo-float-widget {
	bottom: 1.25rem;
}
