.easy-carousel {
  display: flex;
  overflow: hidden;
  justify-content: space-between;
  position: relative;
  width: 100%;
}

.carousel-item {
  flex: 1 1 calc(100% / var(--posts-per-slide) - 15px); /* Ensure proper spacing */
  max-width: calc(100% / var(--posts-per-slide) - 15px); /* Define a gap between items */
  box-sizing: border-box;
  padding: 20px;
  border: 2px solid black;
  transition: transform 0.5s ease-in-out;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: center;
  background: #fff;
  text-align: center;
  min-height: 300px;
  margin: 0 10px; /* Add a gap between the carousel items */
}

/* Adjust gap for the first and last items */
.carousel-item:first-child {
  margin-left: 0;
}

.carousel-item:last-child {
  margin-right: 0;
}

.carousel-image {
  display: flex;
  justify-content: center;
  width: 100%;
}

.carousel-image img {
  max-width: 100%;
  height: 180px;
  object-fit: cover; /* Ensure uniform image sizes */
}

/* Title Styling */
.carousel-item h2 {
  font-size: 1.2em;
  margin: 10px 0;
  padding: 0 20px; /* Extend the background left and right */
  text-transform: uppercase;
}

/* View Details Button Styling */
.view-details {
  display: inline-block;
  padding: 10px 20px;
  background-color: black;
  color: white;
  text-align: center;
  text-decoration: none;
  margin-top: 10px;
  font-size: 1em;
  border-radius: 5px;
}

.view-details:hover {
  background-color: white;
  color: black;
  border: 1px solid black;
}

/* Navigation Arrows */
.slick-prev,
.slick-next {
  background-color: black;
  color: white;
  font-size: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  cursor: pointer;
}

/* Remove default arrow duplication */
.slick-prev::before,
.slick-next::before {
  display: none;
}

.slick-prev {
  left: -60px;
}

.slick-next {
  right: -60px;
}

.slick-prev:hover,
.slick-next:hover {
  background-color: #333;
}

/* Responsive Design */
@media (max-width: 768px) {
  .carousel-item {
    max-width: 100%;
    flex: 1 1 100%;
    margin: 0; /* No margin on mobile */
  }
}
