body.dialog-open {
  overflow: hidden;
}

.dialog {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.8);
  justify-content: center;
  align-items: center;
  z-index: 9999;
  opacity: 0;
  transition: opacity 0.25s ease;
}

.dialog.fadeIn {
  opacity: 1;
}

.dialog.fadeOut {
  opacity: 0;
}

.dialog-content {
  padding: 20px;
  width: 100%;
  position: relative;
}

.close-btn {
  position: absolute;
  z-index: 9;
  right: 15px;
  top: 15px;
  cursor: pointer;
  font-size: 45px;
  color: #fff;
  font-weight: 100;
}

.swiper {
  overflow: visible !important;
}

.swiper-slide {
  align-self: center;

  & img {
    width: 100%;
  }
}

.swiper-button-prev,
.swiper-button-next {
  width: 50px !important;

  &::after {
    display: none !important;
  }
}

.swiper-button-prev {
  left: 9% !important;
}

.swiper-button-next {
  right: 9% !important;
}

.swiper-pagination {
  bottom: -40px !important;
}

.swiper-pagination-bullet {
  width: 12px !important;
  height: 12px !important;
  margin-inline: 8px !important;
  background-color: #fff !important;

  &.swiper-pagination-bullet-active {
    background-color: #fff !important;
  }
}

.openSliderBtn {
  cursor: pointer;
}

/* Loader styling */
.slider-loader {
  font-weight: 200;
  text-align: center;
  padding: 40px 0;
  font-size: 18px;
  color: #fff;
  display: none; /*hidden until needed */
  justify-content: center;
}

.spinner {
  width: 40px;
  height: 40px;
  border: 4px solid #fff;
  border-top-color: var(--primary-color);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.spinner-white {
  width: 32px;
  height: 32px;
  border: 3px solid rgba(255, 255, 255, 0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}

/* Prevent dialog shrinking */
.mySlider {
  min-height: 320px; /* adjust if needed */
  display: none; /* start hidden until ready */
}

@media screen and (max-width: 992px) {
  .close-btn {
    top: -35px;
  }
}

@media screen and (max-width: 768px) {
  .mySlider {
    min-height: 250px;
  }

  .swiper-button-prev,
  .swiper-button-next {
    width: 30px !important;
  }

  .swiper-button-prev {
    left: 6% !important;
  }

  .swiper-button-next {
    right: 6% !important;
  }

  .swiper-pagination {
    bottom: -30px !important;
  }

  .swiper-pagination-bullet {
    width: 8px !important;
    height: 8px !important;
    margin-inline: 6px !important;
  }
}

@media screen and (max-width: 576px) {
  .mySlider {
    min-height: 150px;
  }

  .swiper-button-prev {
    left: 0% !important;
  }

  .swiper-button-next {
    right: 0% !important;
  }
}
