/* Bandeau carrousel promotionnel (exo-bandeau.php). Une création en calques :
   ordinateur = 3 colonnes (titre | photo | offre), mobile = titre en haut, offre à gauche, photo à droite. */

/* Pleine largeur d'écran quel que soit le conteneur : les slides voisines sont coupées par les
   bords de l'écran, pas au milieu de la page (retour de Jérémy, modèle Cdiscount). */
.exo-bandeau {
  --exo-b-fond: #191919;   /* gris foncé de la bande noire du site (demande de Jérémy) */
  --exo-b-accent: #2f74b8;
  --exo-b-accent-2: #4fa3fd;
  --exo-b-largeur: min(1400px, 86vw);
  position: relative;
  width: 100vw;
  max-width: 100vw;
  margin-left: calc(50% - 50vw) !important;
  margin-right: calc(50% - 50vw) !important;
}
.exo-bandeau__piste {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  padding: 4px 0;
}
.exo-bandeau__piste::-webkit-scrollbar { display: none; }

.exo-bandeau__slide {
  position: relative;
  box-sizing: border-box;
  flex: 0 0 var(--exo-b-largeur);
  min-width: 0;
  max-width: var(--exo-b-largeur);
  scroll-snap-align: center;
  display: grid;
  grid-template-columns: 1fr 1.25fr 1fr;
  grid-template-areas: "titre visuel offre";
  grid-template-rows: 100%;
  align-items: center;
  height: clamp(300px, 26vw, 380px);
  padding: 0 clamp(24px, 3vw, 48px);
  overflow: hidden;
  border-radius: 18px;
  background: var(--exo-b-fond);
  color: #fff;
  text-decoration: none;
  isolation: isolate;
}
.exo-bandeau__slide:hover { color: #fff; }

/* Couleurs d'accent : posées par slide (style en ligne, champ accent / accent_2). */

/* Formes graphiques (à la manière des éclats du bandeau Cdiscount). */
.exo-bandeau__forme { position: absolute; z-index: -1; background: var(--exo-b-accent); }
.exo-bandeau__forme--1 {
  left: 30%; top: -10%; width: 38%; height: 120%;
  transform: skewX(-16deg);
  clip-path: polygon(0 6%, 100% 0, 100% 100%, 8% 94%);
}
.exo-bandeau__forme--2 {
  left: 58%; top: 8%; width: 16%; height: 14%;
  background: var(--exo-b-accent-2);
  transform: rotate(-14deg);
}
.exo-bandeau__forme--3 {
  left: 66%; bottom: 8%; width: 9%; height: 8%;
  background: var(--exo-b-accent-2);
  transform: rotate(-14deg);
}

.exo-bandeau__titre {
  grid-area: titre;
  font-size: clamp(2.2rem, 4.6vw, 4.4rem);
  line-height: 0.95;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: -0.01em;
}
.exo-bandeau__titre strong { display: block; font-weight: 900; }

.exo-bandeau__visuel { grid-area: visuel; display: flex; justify-content: center; align-items: center; height: 100%; min-height: 0; }
.exo-bandeau__image {
  width: 100%;
  height: 86%;
  object-fit: contain;
  filter: drop-shadow(0 18px 24px rgba(0, 0, 0, 0.45));
}

.exo-bandeau__offre { grid-area: offre; display: flex; flex-direction: column; align-items: flex-start; gap: 6px; padding-left: 12px; }
.exo-bandeau__contenu { font-size: clamp(1rem, 1.4vw, 1.3rem); line-height: 1.25; }
.exo-bandeau__contenu strong { color: var(--exo-b-accent-2); }
.exo-bandeau__avant { margin-top: 6px; font-size: 0.95rem; font-weight: 700; opacity: 0.85; }
.exo-bandeau__avant del { text-decoration-color: var(--exo-b-accent-2); text-decoration-thickness: 3px; }
.exo-bandeau__prix { display: flex; align-items: center; gap: 14px; line-height: 0.85; }
.exo-bandeau__euros { font-size: clamp(3.4rem, 6vw, 5.6rem); font-weight: 900; letter-spacing: -0.03em; }
.exo-bandeau__devise { display: flex; flex-direction: column; font-size: clamp(1.6rem, 2.4vw, 2.2rem); font-weight: 900; margin-left: -10px; }
.exo-bandeau__devise sup { font-size: 0.6em; top: 0; }
.exo-bandeau__pct {
  padding: 8px 16px;
  border-radius: 999px;
  background: var(--exo-b-accent-2);
  color: #fff;
  font-size: clamp(1.4rem, 2.2vw, 2rem);
  font-weight: 900;
}
.exo-bandeau__pct small { font-size: 0.6em; vertical-align: top; }
.exo-bandeau__bouton {
  white-space: nowrap;
  margin-top: 10px;
  padding: 10px 22px;
  border-radius: 999px;
  background: #fff;
  color: #111;
  font-weight: 700;
  font-size: 0.95rem;
  transition: transform 0.2s ease;
}
.exo-bandeau__slide:hover .exo-bandeau__bouton { transform: translateY(-2px); }

/* Flèches et points */
.exo-bandeau__fleche {
  position: absolute;
  top: calc(50% - 22px);
  z-index: 3;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 50%;
  background: #fff;
  color: #111;
  font-size: 1.8rem;
  line-height: 1;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.2);
  cursor: pointer;
}
.exo-bandeau__fleche { top: calc(50% - 32px); }
/* flèches à cheval sur les bords gauche et droit de la slide du centre (demande de Jérémy) */
.exo-bandeau__fleche--prec { left: calc(50% - var(--exo-b-largeur) / 2 - 22px); }
.exo-bandeau__fleche--suiv { right: calc(50% - var(--exo-b-largeur) / 2 - 22px); }
.exo-bandeau__points { display: flex; justify-content: center; gap: 8px; margin-top: 12px; }
.exo-bandeau__point {
  width: 22px;
  height: 7px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: #c9d1dc;
  cursor: pointer;
  transition: width 0.3s ease, background 0.3s ease;
}
.exo-bandeau__point--actif { width: 44px; background: #5b6778; }
/* Mention propre à chaque promo, en petit dans le coin de la slide. */
.exo-bandeau__mention {
  position: absolute;
  left: clamp(24px, 3vw, 48px);
  bottom: 12px;
  font-size: 0.72rem;
  color: rgba(255, 255, 255, 0.6);
}

/* ---- Mobile : même création, calques réorganisés (titre, photo, offre empilés) ---- */
@media (max-width: 781px) {
  .exo-bandeau { --exo-b-largeur: 86vw; }
  .exo-bandeau__piste { gap: 10px; }
  .exo-bandeau__slide {
    height: auto;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 6px;
    padding: 20px 18px 14px;
  }
  /* sur mobile, la mention suit le bouton dans le flux (pas en position absolue) */
  .exo-bandeau__mention { position: static; margin-top: 6px; font-size: 0.64rem; line-height: 1.3; }
  .exo-bandeau__titre { font-size: 2.3rem; text-align: left; }
  .exo-bandeau__titre strong { display: inline; }
  .exo-bandeau__visuel { height: 170px; margin: 0 -10px; }
  .exo-bandeau__image { width: 100%; height: 100%; object-fit: contain; }
  .exo-bandeau__offre { padding-left: 0; gap: 4px; }
  .exo-bandeau__contenu { font-size: 1rem; }
  .exo-bandeau__avant { margin-top: 2px; font-size: 0.85rem; }
  .exo-bandeau__prix { gap: 10px; }
  .exo-bandeau__euros { font-size: 3.4rem; }
  .exo-bandeau__devise { font-size: 1.5rem; margin-left: -6px; }
  .exo-bandeau__pct { font-size: 1.2rem; padding: 5px 12px; }
  .exo-bandeau__bouton { align-self: stretch; text-align: center; font-size: 0.95rem; padding: 11px 16px; white-space: normal; }
  .exo-bandeau__titre { font-size: clamp(1.8rem, 9vw, 2.3rem); overflow-wrap: anywhere; }
  .exo-bandeau__forme--1 { left: 30%; top: 12%; width: 58%; height: 42%; }
  .exo-bandeau__forme--2 { left: 68%; top: 5%; width: 24%; height: 5%; }
  .exo-bandeau__forme--3 { left: 4%; top: 30%; bottom: auto; width: 14%; height: 4%; }
  .exo-bandeau__fleche { display: none; }
}

/* Titre de section au-dessus du carrousel (1.2). */
.exo-bandeau__entete { margin: 0 auto 14px; text-align: center; }
.exo-bandeau__titre-section { margin: 0 !important; font-size: clamp(1.6rem, 2.6vw, 2.4rem); }
.exo-bandeau__sous-titre { margin: 6px 0 0 !important; color: #4b5563; font-size: clamp(0.95rem, 1.2vw, 1.08rem); }
.exo-bandeau__prefixe { font-size: 1.1rem; font-weight: 700; margin-bottom: -6px; opacity: 0.9; }
@media (max-width: 781px) {
  .exo-bandeau__prefixe { font-size: 0.95rem; margin-bottom: -4px; }
}

/* Slide à photo non détourée (Exoring gris) : la bande centrale a la couleur du fond de la photo
   (#f5f5f5, champ accent) ; la photo, sans ombre, s'y fond. Le reste de la slide reste sombre. */
.exo-bandeau__slide--photo-fond .exo-bandeau__image { filter: none; }
/* ordinateur : photo sur toute la hauteur, bande verticale droite calée en JS sur sa largeur */
@media (min-width: 782px) {
  .exo-bandeau__slide--photo-fond .exo-bandeau__visuel { height: 100%; }
  .exo-bandeau__slide--photo-fond .exo-bandeau__image { height: 100%; width: auto; max-width: 100%; max-height: none; aspect-ratio: 1 / 1; object-fit: cover; }
  .exo-bandeau__slide--photo-fond .exo-bandeau__forme--1 {
    top: 0; height: 100%; transform: none; clip-path: none;
    left: var(--exo-b-photo-gauche, 35%); width: var(--exo-b-photo-largeur, 30%);
  }
  .exo-bandeau__slide--photo-fond .exo-bandeau__offre { padding-left: clamp(16px, 2.4vw, 36px); }
  .exo-bandeau__slide--photo-fond .exo-bandeau__mention { max-width: calc(var(--exo-b-photo-gauche, 35%) - clamp(24px, 3vw, 48px) - 16px); }
}
.exo-bandeau__slide--photo-fond .exo-bandeau__forme--2,
.exo-bandeau__slide--photo-fond .exo-bandeau__forme--3 { display: none; }
@media (max-width: 781px) {
  /* mobile : bande horizontale légèrement inclinée sur toute la largeur, derrière la photo */
  .exo-bandeau__slide--photo-fond .exo-bandeau__forme--1 {
    left: 0; top: 0; width: 100%; height: 100%;
    transform: none; clip-path: none;
    /* bande droite, calée exactement sur la photo (fond identique) */
    top: var(--exo-b-photo-haut, 17%); height: var(--exo-b-photo-hauteur, 34%);
  }
}

/* Hauteur limitée à 300 px sur ordinateur (2026-11-23, « trop agressif » sinon). */
@media (min-width: 782px) {
  .exo-bandeau__slide { height: 300px; }
  .exo-bandeau__titre { font-size: clamp(2rem, 3.4vw, 3.3rem); }
  .exo-bandeau__euros { font-size: clamp(3rem, 4.6vw, 4.4rem); }
  .exo-bandeau__devise { font-size: clamp(1.4rem, 1.9vw, 1.8rem); }
  .exo-bandeau__contenu { font-size: clamp(0.95rem, 1.2vw, 1.15rem); }
  .exo-bandeau__pct { font-size: clamp(1.2rem, 1.8vw, 1.6rem); padding: 6px 14px; }
  .exo-bandeau__bouton { margin-top: 6px; padding: 8px 20px; }
  .exo-bandeau__offre { gap: 4px; }
  .exo-bandeau__mention { bottom: 10px; }
}

/* Liens des slides vers les sections de l'accueil : défilement doux, sous l'en-tête fixe. */
html { scroll-behavior: smooth; }
#exoring-care, #packs { scroll-margin-top: 110px; }

/* ---- Languettes de couleur (slide Exoring gris) : rappel des coloris autour de la photo ---- */
.exo-bandeau__languette {
  position: absolute;
  z-index: 0;
  width: 74px;
  height: 14px;
  border-radius: 3px;
  transform: rotate(-14deg);
}
.exo-bandeau__note {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.92rem;
  font-weight: 400;
}
.exo-bandeau__pastilles { display: inline-flex; gap: 4px; }
.exo-bandeau__pastilles span { width: 11px; height: 11px; border-radius: 50%; box-shadow: 0 0 0 1.5px rgba(255, 255, 255, 0.85); }
@media (min-width: 782px) {
  .exo-bandeau__languette--1 { left: calc(var(--exo-b-photo-gauche, 35%) - 50px); top: 10%; }
  .exo-bandeau__languette--2 { left: calc(var(--exo-b-photo-gauche, 35%) - 30px); top: 30%; width: 44px; transform: rotate(-14deg); }
  .exo-bandeau__languette--3 { left: calc(var(--exo-b-photo-gauche, 35%) - 60px); bottom: 14%; }
  .exo-bandeau__languette--4 { left: calc(var(--exo-b-photo-gauche, 35%) + var(--exo-b-photo-largeur, 30%) - 20px); top: 6%; }
  .exo-bandeau__languette--5 { left: calc(var(--exo-b-photo-gauche, 35%) + var(--exo-b-photo-largeur, 30%) - 10px); bottom: 26%; width: 44px; }
  .exo-bandeau__languette--6 { left: calc(var(--exo-b-photo-gauche, 35%) + var(--exo-b-photo-largeur, 30%) - 30px); bottom: 7%; }
}
@media (max-width: 781px) {
  .exo-bandeau__languette { width: 48px; height: 10px; }
  .exo-bandeau__languette--1 { left: 6%;  top: calc(var(--exo-b-photo-haut, 17%) - 6px); }
  .exo-bandeau__languette--2 { left: 30%; top: calc(var(--exo-b-photo-haut, 17%) - 4px); width: 30px; }
  .exo-bandeau__languette--3 { right: 8%; top: calc(var(--exo-b-photo-haut, 17%) - 8px); }
  .exo-bandeau__languette--4 { left: 10%; top: calc(var(--exo-b-photo-haut, 17%) + var(--exo-b-photo-hauteur, 34%) - 14px); }
  .exo-bandeau__languette--5 { left: 55%; top: calc(var(--exo-b-photo-haut, 17%) + var(--exo-b-photo-hauteur, 34%) - 16px); width: 30px; }
  .exo-bandeau__languette--6 { right: 6%; top: calc(var(--exo-b-photo-haut, 17%) + var(--exo-b-photo-hauteur, 34%) - 14px); }
  .exo-bandeau__note { font-size: 0.85rem; }
}

/* ---- Une disposition par pack : bande et languettes à des places différentes ---- */
@media (min-width: 782px) {
  /* B (Famille) : bande inclinée dans l'autre sens, languettes en haut à gauche et en bas à droite */
  .exo-bandeau__slide--vb .exo-bandeau__forme--1 { left: 32%; transform: skewX(14deg); clip-path: polygon(0 0, 92% 6%, 100% 100%, 0 94%); }
  .exo-bandeau__slide--vb .exo-bandeau__forme--2 { left: 31%; top: auto; bottom: 10%; width: 12%; height: 9%; transform: rotate(12deg); }
  .exo-bandeau__slide--vb .exo-bandeau__forme--3 { left: 64%; top: 7%; bottom: auto; width: 8%; height: 7%; transform: rotate(12deg); }
  /* C (Couleurs) : bande plus étroite et verticale, une languette longue en bas, une courte verticale en haut */
  .exo-bandeau__slide--vc .exo-bandeau__forme--1 { left: 37%; width: 28%; transform: skewX(-6deg); clip-path: none; }
  .exo-bandeau__slide--vc .exo-bandeau__forme--2 { left: 42%; top: auto; bottom: 6%; width: 20%; height: 7%; transform: rotate(-4deg); }
  .exo-bandeau__slide--vc .exo-bandeau__forme--3 { left: 63%; top: 6%; bottom: auto; width: 2.2%; height: 26%; transform: rotate(10deg); }
}
@media (max-width: 781px) {
  .exo-bandeau__slide--vb .exo-bandeau__forme--1 { left: 20%; transform: skewX(12deg); }
  .exo-bandeau__slide--vb .exo-bandeau__forme--2 { left: 6%; top: 30%; }
  .exo-bandeau__slide--vb .exo-bandeau__forme--3 { left: 72%; top: 6%; width: 18%; }
  .exo-bandeau__slide--vc .exo-bandeau__forme--1 { left: 26%; width: 50%; transform: skewX(-4deg); }
  .exo-bandeau__slide--vc .exo-bandeau__forme--2 { left: 62%; top: 7%; width: 28%; height: 4%; }
  .exo-bandeau__slide--vc .exo-bandeau__forme--3 { left: 8%; top: 22%; width: 4%; height: 18%; }
}
