@keyframes kenburns {
  0% {
    transform: scale(1);
    transition: transform 20000ms linear 0s;
  }

  100% {
    transform: scale(1.4);
    transition: transform 20000ms linear 0s;
  }
}

/* Carousel Wrapper */
.kb-carousel {
  overflow: hidden;
  max-height: 850px;
}

/* Carousel Items */
.kb-carousel .carousel-item {
  transition: transform 0.6s ease-in-out 0s, opacity ease-in-out 0.6s;
}

.kb-carousel .carousel-item.active {
  transition: transform 0.6s ease-in-out 0s, opacity ease-in-out 0.6s;
}

.kb-carousel > .carousel-inner > .carousel-item > img,
.kb-carousel > .carousel-inner > .carousel-item > a > img {
  opacity: 0.8;
  animation: kenburns 20000ms linear 0s infinite alternate;
}

.kb-carousel .carousel-item-next.carousel-item-start .carousel-caption,
.kb-carousel .carousel-item-prev.carousel-item-end .carousel-caption {
  z-index: 0;
  opacity: 0;
}

/* Carousel Captions */
.kb-caption {
  right: 7%;
  left: 7%;
  bottom: 25%;
  padding: 0;
  width: 80%;
}

.kb-caption-left {
  margin-right: auto;
}

.kb-caption-right {
  margin-left: auto;
}

.kb-caption-center {
  margin: auto;
}

.kb-caption h1,
.kb-caption h3 {
  padding: 0.5rem 0;
  margin-bottom: 0;
}

.kb-caption h1 {
  animation-delay: 1s;
  color: #115c1a;
  background: #fff;
}

.kb-caption h3 {
  animation-delay: 1.5s;
  color: #fff;
  background: rgba(0 0 0 / 0.5);
}

@media (min-width: 768px) {
  .kb-caption {
    bottom: 37%;
    width: 40%;
  }
}

@media (min-width: 1200px) {
  .kb-caption {
    bottom: 45%;
  }
}

/* Controls */
.kb-control-prev,
.kb-control-next {
  width: 3.5rem;
  height: 3.5rem;
  margin: auto 0;
  opacity: 0;
  color: #fff;
  background: rgba(0 0 0 / 0.7);
}

.kb-carousel:hover .kb-control-prev,
.kb-carousel:hover .kb-control-next {
  opacity: 1;
}

.kb-control-prev {
  left: 1%;
}

.kb-control-next {
  right: 1%;
}

.kb-control-prev:hover,
.kb-control-prev:focus,
.kb-control-next:hover,
.kb-control-next:focus {
  color: #fff;
  background: rgba(0 0 0 / 1);
}

/* Support for dark mode */
[data-bs-theme="dark"] .carousel .carousel-control-next-icon,
[data-bs-theme="dark"] .carousel .carousel-control-prev-icon {
  filter: none;
}

@media (max-width: 575px) and (min-width: 320px) {
  .kb-carousel {
    overflow: hidden;
    max-height: 300px;
  }
  .kb-carousel img {
    height: 300px;
    object-fit: cover;
  }
  .kb-caption h1 {
    font-size: 1.2rem;
  }

  .kb-caption h3 {
    font-size: 14px;
  }
  .kb-caption {
    bottom: 10%;
  }
  .kb-control-prev,
  .kb-control-next {
    width: 2.5rem;
    height: 2.5rem;
  }
  .carousel-control-next-icon,
  .carousel-control-prev-icon {
    width: 1.5rem !important;
    height: 1.5rem !important;
  }
}

@media (max-width: 991px) and (min-width: 576px) {
  .kb-carousel {
    overflow: hidden;
    max-height: 450px;
  }
  .kb-carousel img {
    height: 450px;
    object-fit: cover;
  }
  .kb-caption h1 {
    font-size: 1.5rem;
  }

  .kb-caption h3 {
    font-size: 16px;
  }
  
  .kb-control-prev,
  .kb-control-next {
    width: 2.5rem;
    height: 2.5rem;
  }
  .carousel-control-next-icon,
  .carousel-control-prev-icon {
    width: 1.5rem !important;
    height: 1.5rem !important;
  }
}

@media (max-width: 1499px) and (min-width: 991px) {
  .kb-carousel {
    overflow: hidden;
    max-height: 600px;
  }
  .kb-carousel img {
    height: 600px;
    object-fit: cover;
  }
  .kb-caption h1 {
    font-size: 2rem;
  }

  .kb-caption h3 {
    font-size: 16px;
  }
  
  .kb-control-prev,
  .kb-control-next {
    width: 2.5rem;
    height: 2.5rem;
  }
  .carousel-control-next-icon,
  .carousel-control-prev-icon {
    width: 1.5rem !important;
    height: 1.5rem !important;
  }
}