/**
 * Featured Articles Carousel Component Styles
 * Optimized for all screen sizes, especially wide and desktop
 *
 * @package Standfast
 * @since 1.0.0
 */

.carousel-section {
  position: relative;
  width: 100%;
  padding: 40px 0;
  z-index: 1;
}

.carousel-container {
  max-width: 100%;
  margin: 0 auto;
  padding: 0 20px;
}

.carousel-title {
  text-align: left;
  margin-bottom: 2rem;
  font-size: 2.2rem;
  color: #fff;
  padding: 0 20px;
}


.featured-carousel {
  width: 100%;
  position: relative;
}

.featured-carousel .slick-list {
  overflow: hidden;
  margin: 0 -15px;
}

.featured-carousel .slick-track {
  display: flex;
  align-items: stretch;
}

.carousel-item {
  padding: 0 15px;
  height: 100%;
  display: flex;
  outline: none;
}

.carousel-item > div {
  width: 100%;
  display: flex;
}

.carousel-card {
  background: rgba(0, 0, 0, 0.1);
  border-radius: 10px;
  overflow: hidden;
  transition: all 0.3s ease;
  backdrop-filter: blur(2px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  padding: 15px;
  gap: 15px;
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 150px;
}

.carousel-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
  gap: 0px;
}

.carousel-image {
  width: 100px;
  height: 100px;
  object-fit: cover;
  border-radius: 8px;
  flex-shrink: 0;
  transition: opacity 0.5s ease-out, width 0.3s ease, padding 0.3s ease, margin 0.3s ease;
  display: block;
}

.carousel-content {
  color: #fff;
  flex: 1;
  display: flex;
  flex-direction: column;
  transition: margin-left 1s ease;
  min-height: 0;
  overflow: hidden;
}

.carousel-content p {
  flex-grow: 1;
  margin-bottom: 10px;
}

.carousel-tag {
  display: inline-block;
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
  font-size: 0.7rem;
  padding: 2px 8px;
  border-radius: 4px;
  margin-bottom: 6px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  width: fit-content;
  transition: opacity 0.5s ease;
}

.carousel-card:hover .carousel-tag {
  opacity: 0;
  display: none;
  pointer-events: none;
}

.carousel-content h3 {
  margin: 0 0 4px 0;
  font-size: 1.2rem;
  line-height: 1.3;
  font-weight: 500;
  color: #fff;
}

.carousel-date {
  font-size: 0.8rem;
  opacity: 0.8;
  margin-top: auto;
  color: rgba(255, 255, 255, 0.9);
}

.carousel-card:hover .carousel-date {
  display: none;
  opacity: 0;
  transition: opacity 1s ease;
}

.carousel-content p {
  display: none;
  font-size: 0.8rem;
  opacity: 0;
  margin: 6px 0 0 0;
  line-height: 1.4;
  transition: opacity 0.3s ease;
  color: rgba(255, 255, 255, 0.9);
}

.carousel-card:hover .carousel-content p {
  display: block;
  opacity: 0.9;
}

.carousel-card:hover .carousel-link {
  display: inline-block;
  opacity: 1;
}

.carousel-link {
  width: fit-content;
  display: none;
  color: #ffffff;
  text-decoration: none;
  font-weight: 600;
  position: relative;
  padding-bottom: 2px;
  margin-top: 10px;
  font-size: 0.9rem;
  opacity: 0;
  transition: opacity 0.5s ease;
}

.carousel-link::after {
  content: "";
  position: absolute;
  width: 0;
  height: 2px;
  bottom: 0;
  left: 0;
  background-color: #ffffff;
  transition: width 0.3s ease;
}

@media (hover: hover) {
  .carousel-link:hover::after {
    width: 100%;
  }
}

.carousel-card:hover .carousel-image {
  opacity: 0;
  width: 0;
  padding: 0;
  margin: 0;
}

.featured-carousel .slick-prev,
.featured-carousel .slick-next {
  z-index: 10;
}

.featured-carousel .slick-prev:before,
.featured-carousel .slick-next:before {
  color: #fff;
  font-size: 24px;
}

.featured-carousel__dots {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  margin-top: 30px;
  list-style: none;
  padding: 0;
}

.featured-carousel__dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.5);
  background-color: transparent;
  cursor: pointer;
  padding: 0;
  transition: all 0.3s ease;
}

.featured-carousel__dot:hover {
  background-color: rgba(255, 255, 255, 0.5);
  border-color: rgba(255, 255, 255, 0.8);
}

.featured-carousel__dot.active {
  background-color: #ffffff;
  border-color: #ffffff;
}

.featured-carousel .slick-slide {
  height: auto;
}

.featured-carousel .slick-slide > div {
  height: 100%;
}

@media (max-width: 600px) {
  .carousel-container {
    padding: 0 10px;
  }

  .carousel-image {
    width: 80px;
    height: 80px;
  }

  .carousel-card {
    padding: 10px;
    min-height: 120px;
  }

  .carousel-content h3 {
    font-size: 1rem;
  }

  .carousel-title {
    font-size: 1.8rem;
    padding: 0 10px;
  }
}

@media (min-width: 601px) and (max-width: 768px) {
  .carousel-container {
    padding: 0 20px;
  }

  .carousel-card {
    flex-direction: row;
    text-align: left;
    padding: 20px;
    min-height: 140px;
  }

  .carousel-image {
    width: 120px;
    height: 120px;
  }

  .carousel-title {
    font-size: 1.8rem;
  }
}

@media (min-width: 769px) and (max-width: 1023px) {
  .carousel-container {
    padding: 0 30px;
    max-width: 1200px;
  }

  .carousel-title {
    font-size: 2rem;
    padding: 0 30px;
  }

  .carousel-card {
    padding: 20px;
    min-height: 160px;
  }

  .carousel-image {
    width: 120px;
    height: 120px;
  }

  .carousel-content h3 {
    font-size: 1.2rem;
  }
}

@media (min-width: 1024px) and (max-width: 1439px) {
  .carousel-container {
    max-width: 1400px;
    padding: 0 40px;
  }

  .carousel-title {
    font-size: 2.5rem;
    padding: 0 40px;
  }

  .carousel-card {
    padding: 20px;
    min-height: 180px;
  }

  .carousel-image {
    width: 120px;
    height: 120px;
  }

  .carousel-content h3 {
    font-size: 1.3rem;
  }
}

@media (min-width: 1440px) and (max-width: 1919px) {
  .carousel-container {
    max-width: 1600px;
    padding: 0 50px;
  }

  .carousel-title {
    font-size: 3rem;
    padding: 0 50px;
  }

  .carousel-card {
    padding: 25px;
    min-height: 200px;
  }

  .carousel-image {
    width: 140px;
    height: 140px;
  }

  .carousel-content h3 {
    font-size: 1.4rem;
  }
}

@media (min-width: 1920px) {
  .carousel-container {
    max-width: 1800px;
    padding: 0 60px;
  }

  .carousel-title {
    font-size: 3.5rem;
    padding: 0 60px;
  }

  .carousel-card {
    padding: 30px;
    min-height: 220px;
  }

  .carousel-image {
    width: 160px;
    height: 160px;
  }

  .carousel-content h3 {
    font-size: 1.5rem;
  }

  .carousel-content p {
    font-size: 0.9rem;
  }
}
