/**
 * Widget Offres promotionnelles — Charte SOS Pare-Brise+
 * Desktop first.
 *
 * Structure :
 *   .sospb-offres (flex column, gap 8px, pleine largeur)
 *     ├── .sospb-offres__swiper (bandeau jaune pleine largeur, ARRONDI + overflow:hidden)
 *     │     └── .swiper-slide.sospb-offre (slide SANS radius — évite le saut en transition)
 *     │            ├── .sospb-offre__inner (contenu)
 *     │            ├── .sospb-offre__chevron--prev (triangle navy, centré V, gauche)
 *     │            └── .sospb-offre__chevron--next (triangle navy, centré V, droite)
 *     └── .sospb-offres__pagination (puces navy, hors du conteneur arrondi)
 */

.sospb-offres {
	font-family: "Outfit", sans-serif;
	display: flex;
	flex-direction: column;
	gap: 8px;
	width: 100%;
	margin: 0;
	box-sizing: border-box;
}

.sospb-offres * {
	box-sizing: border-box;
}

/* --- Conteneur Swiper : porte l'arrondi + masque (les slides repassent droites). --- */
.sospb-offres__swiper {
	width: 100%;
	min-width: 0;
	border-radius: 14px 4px 14px 4px;
	overflow: hidden;
}

/* --- Slide / bandeau jaune : PAS d'arrondi (sinon saut visible en transition). --- */
.sospb-offre {
	position: relative;
	background-color: #ffc40c;
	background-image: url("../img/bandeau-bg.jpg");
	background-position: center center;
	background-size: cover;
	background-repeat: no-repeat;
	border-radius: 0;
	overflow: visible;
	width: 100%;
	display: flex;
	flex-direction: column;
	justify-content: center;
}

/* Voile jaune à 88% pour faire apparaître l'image à 12%. */
.sospb-offre::before {
	content: "";
	position: absolute;
	inset: 0;
	background-color: #ffc40c;
	opacity: 0.88;
	pointer-events: none;
	z-index: 1;
}

.sospb-offre__inner {
	position: relative;
	z-index: 2;
	display: flex;
	align-items: center;
	gap: 24px;
	padding: 21px 56px;
	width: 100%;
}

.sospb-offre__media {
	flex: 0 0 auto;
	display: flex;
	align-items: center;
	justify-content: center;
}

.sospb-offre__media img {
	display: block;
	max-height: 56px;
	width: auto;
	height: auto;
}

.sospb-offre__content {
	flex: 1 1 auto;
	min-width: 0;
}

.sospb-offre__titre {
	margin: 0 0 4px;
	font-family: "Outfit", sans-serif;
	font-weight: 800;
	font-size: 15px;
	line-height: 18px;
	color: #21326a;
}

.sospb-offre__description {
	margin: 0;
	font-family: "Outfit", sans-serif;
	font-weight: 400;
	font-size: 12px;
	line-height: 14.4px;
	color: #21326a;
}

/* --- Bouton CTA --- */
.sospb-offre__cta {
	flex: 0 0 auto;
}

.sospb-offre__btn {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	width: fit-content;
	background-color: #21326a;
	color: #ffffff;
	text-decoration: none;
	padding: 10px 20px;
	border-radius: 14px 4px 14px 4px;
	font-family: "Outfit", sans-serif;
	font-weight: 700;
	font-size: 14px;
	line-height: 1;
	white-space: nowrap;
}

.sospb-offre__btn:hover,
.sospb-offre__btn:focus-visible {
	background-color: #182550;
	color: #ffffff;
}

/* --- Chevrons prev / next intégrés au bandeau, centrés verticalement. --- */
/* Override du reset.css du thème qui impose border + color sur tous les <button>. */
.sospb-offre__chevron,
.sospb-offre__chevron:hover,
.sospb-offre__chevron:focus,
.sospb-offre__chevron:active {
	position: absolute;
	z-index: 3;
	top: 50%;
	transform: translateY(-50%);
	width: 24px;
	height: 24px;
	padding: 0 !important;
	margin: 0;
	border: none !important;
	background: transparent !important;
	background-color: transparent !important;
	box-shadow: none !important;
	color: inherit !important;
	border-radius: 0;
	cursor: pointer;
	-webkit-appearance: none;
	appearance: none;
	transition: opacity 0.2s ease;
	opacity: 0.55;
}

.sospb-offre__chevron--prev {
	left: 18px;
}

.sospb-offre__chevron--next {
	right: 18px;
}

/* Triangle navy dessiné en CSS pur (pas d'image). */
.sospb-offre__chevron::before {
	content: "";
	position: absolute;
	top: 50%;
	left: 50%;
	width: 9px;
	height: 9px;
	border-top: 2px solid #21326a;
	border-right: 2px solid #21326a;
}

/* Next : pointe vers la droite. */
.sospb-offre__chevron--next::before {
	transform: translate(-65%, -50%) rotate(45deg);
}

/* Prev : pointe vers la gauche (miroir). */
.sospb-offre__chevron--prev::before {
	transform: translate(-35%, -50%) rotate(-135deg);
}

.sospb-offre__chevron::after {
	content: none;
	display: none;
}

.sospb-offre__chevron:hover {
	opacity: 1;
}

.sospb-offre__chevron:focus-visible {
	outline: 2px solid #21326a;
	outline-offset: 2px;
	border-radius: 50%;
	opacity: 1;
}

/* --- Pagination dots SOUS le bandeau (hors du conteneur arrondi). --- */
.sospb-offres .sospb-offres__pagination {
	position: static !important;
	width: 100%;
	margin: 0;
	padding: 0;
	text-align: center;
	bottom: auto;
	top: auto;
	left: auto;
	right: auto;
	transform: none;
}

.sospb-offres__pagination .swiper-pagination-bullet {
	width: 8px;
	height: 8px;
	background-color: #dbdbd9;
	opacity: 1;
	margin: 0 4px;
	border-radius: 50%;
	transition: background-color 0.2s ease;
}

.sospb-offres__pagination .swiper-pagination-bullet-active {
	background-color: #21326a;
}

/* --- Variante 1 offre : pas de pagination, pas de chevrons. --- */
.sospb-offres--single {
	display: block;
	margin: 0;
}

.sospb-offres--single .sospb-offre__chevron {
	display: none;
}

/* --- Responsive mobile --- */
@media (max-width: 767px) {
	.sospb-offre__inner {
		padding: 18px 40px;
		gap: 14px;
	}

	.sospb-offre__chevron--prev {
		left: 10px;
	}

	.sospb-offre__chevron--next {
		right: 10px;
	}
}
