/* AffiLink – fiches produits */

/* height: 100% permet aux cartes voisines de s'aligner sur la plus haute ;
   sans conteneur qui impose une hauteur, la valeur est simplement ignorée. */
.affx-card {
	height: 100%;
	--affx-border: #e3e6ea;
	--affx-ink: #14181d;
	--affx-muted: #5f6b76;
	--affx-cta-bg: #14181d;
	--affx-cta-color: #ffffff;
	/* Carrousel : les aspects prédéfinis ne redéfinissent que ces variables.
	   Les réglages Elementor écrivent, eux, les propriétés directement, et
	   restent donc toujours prioritaires quel que soit l'aspect choisi. */
	--affx-nav-size: 34px;
	--affx-nav-font: 20px;
	--affx-nav-bg: rgba(255, 255, 255, .92);
	--affx-nav-color: var(--affx-ink);
	--affx-nav-border-width: 1px;
	--affx-nav-border-color: var(--affx-border);
	--affx-nav-radius: 999px;
	--affx-nav-shadow: none;
	--affx-nav-opacity: 0;
	--affx-nav-display: flex;
	--affx-nav-text-shadow: none;
	--affx-dots-display: flex;
	--affx-dot-w: 7px;
	--affx-dot-h: 7px;
	--affx-dot-r: 999px;
	--affx-dot-bg: rgba(0, 0, 0, .22);
	--affx-dot-bg-active: var(--affx-ink);
	--affx-dot-border-width: 0;
	--affx-dot-border-color: transparent;
	position: relative;
	display: flex;
	flex-direction: column;
	border: 1px solid var(--affx-border);
	border-radius: 12px;
	background: #fff;
	overflow: hidden;
	max-width: 100%;
}

.affx-card * {
	box-sizing: border-box;
}

.affx-media {
	display: block;
	background: #f6f7f9;
}

.affx-media img {
	display: block;
	width: 100%;
	height: 240px;
	object-fit: contain;
	padding: 14px;
	margin: 0;
}

/* Carrousel */
.affx-carousel {
	position: relative;
	width: 100%;
}

.affx-slides {
	display: flex;
	overflow-x: auto;
	scroll-snap-type: x mandatory;
	scroll-behavior: smooth;
	scrollbar-width: none;
	-ms-overflow-style: none;
}

.affx-slides::-webkit-scrollbar {
	display: none;
}

.affx-slide {
	flex: 0 0 100%;
	max-width: 100%;
	scroll-snap-align: center;
}

/* Les thèmes appliquent souvent leur style de bouton à tout <button>.
   Ce bloc, plus spécifique qu'une règle de thème courante mais moins que
   les règles générées par Elementor, remet les commandes du carrousel à
   plat sans jamais prendre le pas sur vos réglages. */
.affx-carousel .affx-nav {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	display: var(--affx-nav-display);
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
	width: var(--affx-nav-size);
	height: var(--affx-nav-size);
	min-width: 0;
	min-height: 0;
	max-width: none;
	margin: 0;
	padding: 0;
	border: var(--affx-nav-border-width) solid var(--affx-nav-border-color);
	border-radius: var(--affx-nav-radius);
	background: var(--affx-nav-bg);
	color: var(--affx-nav-color);
	box-shadow: var(--affx-nav-shadow);
	font-family: inherit;
	font-size: var(--affx-nav-font);
	font-weight: 400;
	text-transform: none;
	text-decoration: none;
	text-indent: 0;
	letter-spacing: normal;
	line-height: 1;
	-webkit-appearance: none;
	appearance: none;
	cursor: pointer;
	opacity: var(--affx-nav-opacity);
	transition: opacity .15s ease;
}

.affx-carousel:hover .affx-nav,
.affx-carousel .affx-nav:focus-visible {
	opacity: 1;
}

.affx-carousel .affx-nav[disabled] {
	opacity: 0;
	pointer-events: none;
}

.affx-carousel .affx-prev { left: 8px; }
.affx-carousel .affx-next { right: 8px; }

.affx-carousel .affx-dots {
	position: absolute;
	left: 0;
	right: 0;
	bottom: 8px;
	display: var(--affx-dots-display);
	justify-content: center;
	gap: 6px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.affx-carousel .affx-dot {
	box-sizing: border-box;
	width: var(--affx-dot-w);
	height: var(--affx-dot-h);
	min-width: 0;
	min-height: 0;
	margin: 0;
	padding: 0;
	border: var(--affx-dot-border-width) solid var(--affx-dot-border-color);
	border-radius: var(--affx-dot-r);
	background: var(--affx-dot-bg);
	box-shadow: none;
	font-size: 0;
	line-height: 0;
	text-indent: 0;
	-webkit-appearance: none;
	appearance: none;
	cursor: pointer;
	transition: background .15s ease;
}

/* L'état actif ne fait que changer une variable : un réglage Elementor
   « couleur des points » s'applique donc bien à tous les points, et la
   couleur du point actif reste prioritaire par-dessus. */
.affx-carousel .affx-dot.is-active {
	--affx-dot-bg: var(--affx-dot-bg-active);
}

@media (hover: none) {
	.affx-card .affx-carousel .affx-nav { opacity: 1; }
}


.affx-body {
	display: flex;
	flex-direction: column;
	gap: 8px;
	padding: 18px 20px 20px;
	flex: 1;
}

.affx-merchant {
	font-size: 12px;
	letter-spacing: .06em;
	text-transform: uppercase;
	color: var(--affx-muted);
}

.affx-card .affx-title {
	margin: 0;
	font-size: 19px;
	line-height: 1.3;
	color: var(--affx-ink);
}

.affx-card .affx-title a {
	color: inherit;
	text-decoration: none;
}

.affx-card .affx-title a:hover {
	text-decoration: underline;
}

.affx-desc {
	color: var(--affx-muted);
	font-size: 15px;
	line-height: 1.55;
}

.affx-desc p {
	margin: 0 0 .6em;
}

.affx-desc p:last-child {
	margin-bottom: 0;
}

.affx-foot {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 14px;
	flex-wrap: wrap;
	margin-top: auto;
	padding-top: 6px;
}

.affx-prices {
	display: flex;
	align-items: baseline;
	gap: 8px;
}

.affx-price {
	font-size: 22px;
	font-weight: 700;
	color: var(--affx-ink);
	white-space: nowrap;
}

.affx-card .affx-cta {
	display: inline-block;
	padding: 11px 22px;
	border-radius: 8px;
	background: var(--affx-cta-bg);
	color: var(--affx-cta-color);
	font-weight: 600;
	font-size: 15px;
	line-height: 1.2;
	text-align: center;
	text-decoration: none;
	transition: transform .15s ease, opacity .15s ease;
}

/* Pas de couleur ici : elle écraserait la couleur normale choisie dans
   Elementor dès que le visiteur survole le bouton. */
.affx-card .affx-cta:hover,
.affx-card .affx-cta:focus {
	opacity: .88;
	transform: translateY(-1px);
}

.affx-card .affx-cta:focus-visible {
	outline: 2px solid var(--affx-ink);
	outline-offset: 2px;
}

.affx-disclosure {
	display: block;
	margin-top: 4px;
	font-size: 12px;
	color: var(--affx-muted);
}

.affx-admin-warning {
	display: block;
	margin-top: 8px;
	padding: 6px 10px;
	border-radius: 6px;
	background: #fbe6e6;
	color: #b32020;
	font-size: 12px;
}

.affx-missing {
	padding: 16px 20px;
	border-style: dashed;
	color: #8a6100;
	background: #fdf3dc;
}

/* Disposition horizontale */
.affx-layout-row {
	flex-direction: row;
	align-items: stretch;
}

.affx-layout-row .affx-media {
	flex: 0 0 34%;
	max-width: 34%;
	display: flex;
	align-items: center;
}

.affx-layout-row .affx-media img {
	height: 100%;
	min-height: 180px;
}

.affx-layout-row .affx-carousel {
	align-self: stretch;
}

/* Disposition compacte */
.affx-layout-compact .affx-media img {
	height: 150px;
}

.affx-layout-compact .affx-desc {
	display: none;
}

/* Grille de plusieurs fiches */
.affx-grid-list > * {
	height: 100%;
}

.affx-grid-list {
	display: grid;
	align-items: stretch;
	gap: 22px;
	grid-template-columns: repeat(3, minmax(0, 1fr));
}

.affx-grid-list.affx-cols-1 { grid-template-columns: minmax(0, 1fr); }
.affx-grid-list.affx-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.affx-grid-list.affx-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

@media (max-width: 880px) {
	.affx-grid-list,
	.affx-grid-list.affx-cols-2,
	.affx-grid-list.affx-cols-3,
	.affx-grid-list.affx-cols-4 {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@media (max-width: 600px) {
	.affx-grid-list,
	.affx-grid-list.affx-cols-2,
	.affx-grid-list.affx-cols-3,
	.affx-grid-list.affx-cols-4 {
		grid-template-columns: minmax(0, 1fr);
	}

	.affx-layout-row {
		flex-direction: column;
	}

	.affx-layout-row .affx-media {
		flex: none;
		max-width: 100%;
	}

	.affx-layout-row .affx-media img {
		height: 200px;
		min-height: 0;
	}

	.affx-foot {
		flex-direction: column;
		align-items: stretch;
	}

	.affx-card .affx-cta {
		width: 100%;
	}
}

@media (prefers-reduced-motion: reduce) {
	.affx-slides {
		scroll-behavior: auto;
	}

	.affx-card .affx-cta {
		transition: none;
	}
	.affx-card .affx-cta:hover {
		transform: none;
	}
}
