/* === GENERAL CONTAINER === */
.block--news_carousel {
  --brand-accent: #E32512;
  --brand-accent-hover: #E32512;
  --brand-accent-strong: #E32512;
  width: 100%;
  display: flex;
  justify-content: center;
  background: transparent;
}

.block--news_carousel .title-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
  flex-wrap: wrap;
}

.block--news_carousel .title-container .title {
  font-size: clamp(1.8rem, 3vw, 2.5rem);
  font-weight: 800;
  color: var(--text-context-color, #111);
}

.all-news a {
  color: #fff;
  font-weight: 600;
  text-decoration: none;
  transition: color .25s ease;
}

.all-news a:hover {
  color: #fff;
}

.btn-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 46px;
  padding: 0 22px 0 24px;
  border-radius: 9999px;
  text-decoration: none;
  font-weight: 750;
  font-size: .95rem;
  letter-spacing: .01em;
  color: #fff;
  background: var(--brand-accent);
  border: 1px solid rgba(0,0,0,0.06);
  box-shadow: 0 12px 24px rgba(227,37,18,0.22), inset 0 1px 0 rgba(255,255,255,0.32);
  transition: transform .12s ease, background .25s ease, box-shadow .25s ease, filter .2s ease;
}

.btn-pill i {
  font-size: 1.35em;
  line-height: 1;
  margin-right: -2px;
}

.btn-pill:hover {
  transform: translateY(-1px);
  color: #fff;
  background: var(--brand-accent);
  filter: brightness(1.03);
  box-shadow: 0 14px 30px rgba(227,37,18,0.28), inset 0 1px 0 rgba(255,255,255,0.18);
}

.btn-pill:active {
  transform: translateY(0);
  filter: brightness(0.98);
}

/* === SWIPER CONTAINER & SLIDES === */
.swiper-container.news-container {
  width: 100%;
  max-width: 100%;
  overflow: hidden;
  position: relative;
  padding: 0 10px;
  box-sizing: border-box;
}

.swiper-wrapper {
  box-sizing: border-box;
}

.swiper-slide {
  display: flex;
  justify-content: center;
  align-items: stretch;
  flex-shrink: 0;
  width: 100%;
  transition: transform 0.3s ease;
  background: transparent;
  padding: 8px 10px;
  box-sizing: border-box;
}

/* === NEWS ITEM === */
.news-item {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  position: relative;
  overflow: hidden;
  border-radius: 20px;
  background: transparent;
  color: #fff;
  text-decoration: none;
  width: 100%;
  aspect-ratio: 16 / 9;
  max-height: 480px; 
  border: 1px solid rgba(255,255,255,0.22);
  transition: transform .25s ease, border-color .25s ease;
}

.news-media {
  position: absolute;
  inset: 0;
  z-index: 0;
  background: transparent;
}

.news-item:hover {
  transform: translateY(-2px) scale(1.01);
  border-color: rgba(255,255,255,0.32);
}

.news-item img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.78);
  transition: filter .3s ease;
  z-index: 1;
}

.news-image {
  z-index: 2;
}

.news-fallback {
  object-fit: cover !important;
  filter: brightness(0.88) contrast(1.02) !important;
  opacity: 0.98;
}

.news-item:hover img {
  filter: brightness(0.95);
}

.news-overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(180deg, rgba(0,0,0,0.00) 0%, rgba(0,0,0,0.34) 100%);
}

.news-title {
  position: relative;
  z-index: 2;
  padding: 1.25rem;
  font-size: clamp(1.1rem, 2vw, 1.8rem);
  font-weight: 800;
  line-height: 1.2;
  color: #fff;
  text-shadow: 0 3px 15px rgba(0, 0, 0, 0.6);
}

/* === SWIPER NAVIGATION (BASE / DESKTOP) === */
.swiper-button-next,
.swiper-button-prev {
  position: absolute;
  top: 50%;
  width: 50px !important;
  height: 50px !important;
  box-sizing: border-box !important;
  flex-shrink: 0 !important;
  border-radius: 50% !important;
  
  /* Fond semi-transparent avec effet verre flouté */
  background: rgba(255, 255, 255, 0.45) !important;
  backdrop-filter: blur(12px) saturate(140%);
  -webkit-backdrop-filter: blur(12px) saturate(140%);
  background-image: none !important;
  
  border: 2px solid rgba(227, 37, 18, 0.85) !important;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
  
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  
  z-index: 10;
  cursor: pointer;
  margin-top: 0 !important;
  overflow: hidden;
  
  /* Transition douce pour le retour à la couleur d'origine */
  transition: background-color 0.25s ease, border-color 0.25s ease, transform 0.15s ease, box-shadow 0.15s ease;
  
  /* Désactive le rectangle gris de sélection par défaut au toucher sur WebKit/iOS */
  -webkit-tap-highlight-color: transparent;
}

.swiper-button-prev { left: 12px; transform: translateY(-50%); }
.swiper-button-next { right: 12px; transform: translateY(-50%); }

.swiper-button-next::before,
.swiper-button-prev::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 100%;
  height: 100%;
  background-color: var(--brand-accent, #E32512);
  border-radius: 50%;
  transform: translate(-50%, -50%) scale(0);
  z-index: -1;
  transition: transform 0.45s cubic-bezier(0.25, 1, 0.5, 1);
}

.swiper-button-next i,
.swiper-button-prev i {
  font-size: 1.3rem;
  color: var(--brand-accent, #E32512) !important;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1 !important;
  transition: color 0.25s ease, transform 0.15s ease;
}

.swiper-button-prev i { transform: translateX(-1px); }
.swiper-button-next i { transform: translateX(1px); }

/* --- CLIC / TOUCHER TACTILE (Devvient bien rouge pendant l'appui, puis revient à la normale) --- */
.swiper-button-prev:active,
.swiper-button-next:active {
  background: var(--brand-accent, #E32512) !important;
  border-color: var(--brand-accent, #E32512) !important;
  transform: translateY(-50%) scale(0.92) !important;
  box-shadow: 0 4px 10px rgba(227, 37, 18, 0.4);
}

.swiper-button-prev:active i,
.swiper-button-next:active i {
  color: #ffffff !important;
}

/* État désactivé */
.swiper-button-disabled {
  opacity: 0.35;
  cursor: not-allowed;
  pointer-events: none;
}

/* Pagination dots */ 
.swiper-pagination-bullet { 
  background: var(--brand-accent) !important; 
  opacity: 0.6; 
} 
.swiper-pagination-bullet-active { 
  opacity: 1;
}

/* --- SURVOL SOURIS UNIQUEMENT (Desktop) --- */
@media (hover: hover) and (pointer: fine) {
  .swiper-button-prev:hover,
  .swiper-button-next:hover {
    background: var(--brand-accent, #E32512) !important;
    border-color: var(--brand-accent, #E32512) !important;
    transform: translateY(-50%) scale(1.1);
    box-shadow: 0 10px 24px rgba(227, 37, 18, 0.35);
  }

  .swiper-button-prev:hover i,
  .swiper-button-next:hover i {
    color: #ffffff !important;
  }
}

/* ==========================================================
   TABLETTE / ÉCRAN INTERMÉDIAIRE (<= 1250px)
   ========================================================== */
@media screen and (max-width: 1250px) {
  .block--news_carousel,
  .outer-container,
  .inner-container,
  .swiper-container.news-container {
    width: 100%;
    max-width: 100%;
    overflow: hidden;
  }

  .swiper-slide {
    padding: 4px !important;
  }

  .news-item {
    aspect-ratio: 16 / 11;
    border-radius: 16px;
  }

  .news-title {
    padding: 1rem;
    font-size: 1.05rem;
    line-height: 1.3;
  }

  .swiper-button-next,
  .swiper-button-prev {
    width: 44px !important;
    height: 44px !important;
    border: 2px solid var(--brand-accent, #E32512) !important;
  }

  .swiper-button-prev { left: 8px; transform: translateY(-50%); }
  .swiper-button-next { right: 8px; transform: translateY(-50%); }

  .swiper-button-next i,
  .swiper-button-prev i {
    font-size: 1.2rem;
    color: var(--brand-accent, #E32512) !important;
  }

  .swiper-button-prev:active,
  .swiper-button-next:active {
    background: var(--brand-accent, #E32512) !important;
    border-color: var(--brand-accent, #E32512) !important;
    transform: translateY(-50%) scale(0.92) !important;
    box-shadow: 0 4px 10px rgba(227, 37, 18, 0.4);
  }

  .swiper-button-prev:active i,
  .swiper-button-next:active i {
    color: #ffffff !important;
  }

  .btn-pill {
    height: 40px;
    padding: 0 16px;
    font-size: 0.85rem;
  }

  .title-container {
    gap: 12px;
    align-items: flex-start;
  }
}

/* ==========================================================
   MOBILE (<= 768px)
   ========================================================== */
@media screen and (max-width: 768px) {
  .swiper-button-next,
  .swiper-button-prev {
    width: 40px !important;
    height: 40px !important;
    background: rgba(255, 255, 255, 0.5) !important;
  }

  .swiper-button-next i,
  .swiper-button-prev i {
    font-size: 1.1rem !important;
  }

  .swiper-button-prev {
    left: 4px;
    transform: translateY(-50%) !important;
  }

  .swiper-button-next {
    right: 4px;
    transform: translateY(-50%) !important;
  }

  .swiper-button-prev:active,
  .swiper-button-next:active {
    background: var(--brand-accent, #E32512) !important;
    border-color: var(--brand-accent, #E32512) !important;
    transform: translateY(-50%) scale(0.88) !important;
  }
  
  .swiper-button-prev:active i,
  .swiper-button-next:active i {
    color: #ffffff !important;
  }
}