* {box-sizing: border-box}
.mySlides1, .mySlides2 {display: none}
img {vertical-align: middle;}

/* Slideshow container */
.slideshow-container {
  max-width: 1000px;
  position: relative;
  margin: auto;
}

/* Next & previous buttons */
.prev, .next {
  cursor: pointer;
  position: absolute;
  top: 50%;
  width: auto;
  padding: 16px;
  margin-top: -22px;
  color: white;
  opacity: 0.8;
  font-weight: bold;
  font-size: 18px;
  transition: 0.6s ease;
  border-radius: 0 3px 3px 0;
  user-select: none;
}

/* Position the "next button" to the right */
.next {
  right: 0;
  border-radius: 3px 0 0 3px;
}

/* On hover, add a grey background color */
.prev:hover, .next:hover {
  background-color: rgba(0,0,0,0.3);
  color: white;
}

/* The dots/bullets/indicators */
.dot1, .dot2 {
  cursor: pointer;
  height: 10px;
  width: 10px;
  margin: 0 2px;
  background-color: #bbb;
  border-radius: 50%;
  display: inline-block;
  transition: background-color 0.6s ease;
}

.active, .dot:hover {
  background-color: #4471da;
}

/* Fading animation */
.fade {
  animation-name: fade;
  animation-duration: 1.5s;
}


/* Carousel: 4 items per page */
.carousel { position: relative; overflow: hidden; }
.carousel-track { display: flex; transition: transform .35s ease; flex-wrap: nowrap; }
.carousel-page { flex: 0 0 100%; display: flex; gap: 1rem; align-items: top; justify-content: center; box-sizing: border-box; }
.carousel-item { width: 25%; padding: 0 0.5rem; text-align: center;  box-sizing: border-box; border: none; }
.carousel-item img { max-height: 12rem; width: auto; margin: 0 auto; }
.carousel-button { position: absolute; top: 50%; transform: translateY(-50%); background: rgba(255,255,255,0.9); border: none; padding: 0.5rem 0.65rem; border-radius: 9999px; box-shadow: 0 4px 10px rgba(2,6,23,0.2); cursor: pointer; }
.carousel-button[disabled] { opacity: 0.45; cursor: default; }
.carousel-prev { left: -3rem; top: 40%; }
.carousel-next { right: -3rem; top: 40%; }

/* Mobile: make each carousel page show a 2x2 grid (2 columns x 2 rows) */
@media (max-width: 768px) {
  .carousel-page { flex-wrap: wrap; gap: 0.5rem; padding: 0.05rem; }
  .carousel-item { width: 40%; padding: 0.15rem; }
  .carousel-item img { max-height: 8rem; }
  /* Position controls below the carousel on small screens */
  .carousel-button { top: 42%;  transform: none; }
  .carousel-prev { left: 0rem;}
  .carousel-next { right: 0rem;}
}
