/* News gallery: slider + thumbnails */

.aff-news-gallery {
  margin: 2rem 0 2.5rem;
  clear: both;
}

.aff-news-gallery__title {
  margin: 0 0 1rem;
  font-size: 1.5rem;
  font-weight: 700;
  color: #1f3d2b;
}

/* Slider */

.aff-news-gallery__slider {
  position: relative;
  margin: 0 -6px;
}

.aff-news-gallery__slider .slick-slide {
  padding: 0 6px;
}

.aff-news-gallery__slider .slick-list,
.aff-news-gallery__slider .slick-track {
  outline: none;
}

.aff-news-gallery__figure {
  margin: 0;
}

.aff-news-gallery__image {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 10px;
}

.aff-news-gallery__caption {
  margin-top: 0.65rem;
  font-size: 0.9rem;
  line-height: 1.45;
  color: #5a5a5a;
  font-style: italic;
}

/* Arrows */

.aff-news-gallery__slider .slick-prev,
.aff-news-gallery__slider .slick-next {
  z-index: 2;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.45);
  transition: background 0.2s ease;
}

.aff-news-gallery__slider .slick-prev:hover,
.aff-news-gallery__slider .slick-next:hover,
.aff-news-gallery__slider .slick-prev:focus,
.aff-news-gallery__slider .slick-next:focus {
  background: #549433;
}

.aff-news-gallery__slider .slick-prev {
  left: 10px;
}

.aff-news-gallery__slider .slick-next {
  right: 10px;
}

/* Thumbnails */

.aff-news-gallery__thumbs {
  display: flex;
  gap: 8px;
  margin-top: 0.9rem;
  overflow-x: auto;
  padding-bottom: 4px;
  scrollbar-width: thin;
}

.aff-news-gallery__thumb {
  flex: 0 0 auto;
  width: 96px;
  padding: 0;
  border: 2px solid transparent;
  border-radius: 6px;
  background: transparent;
  cursor: pointer;
  opacity: 0.55;
  transition: opacity 0.2s ease, border-color 0.2s ease;
}

.aff-news-gallery__thumb img {
  display: block;
  width: 100%;
  height: 64px;
  object-fit: cover;
  border-radius: 4px;
}

.aff-news-gallery__thumb:hover,
.aff-news-gallery__thumb:focus-visible {
  opacity: 0.85;
  outline: none;
}

.aff-news-gallery__thumb.is-active {
  opacity: 1;
  border-color: #549433;
}

@media (max-width: 575px) {
  .aff-news-gallery__thumb {
    width: 72px;
  }

  .aff-news-gallery__thumb img {
    height: 52px;
  }

  .aff-news-gallery__slider .slick-prev,
  .aff-news-gallery__slider .slick-next {
    width: 32px;
    height: 32px;
  }
}
