/* CSS custom untuk membuat slider full-screen dan teks di tengah */
.swiper {
  width: 100%;
  height: 94vh;
}

.swiper-slide {
  text-align: center;
  font-size: 18px;
  background: #634d32;
  display: flex;
  justify-content: center;
  align-items: center;
  color: white;
  overflow: hidden;
  position: relative;
}

.swiper-slide img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  position: absolute;
  top: 0;
  left: 0;
  z-index: 1;
}

/* Gambar default (belum aktif) berada di bawah layar */
.swiper-slide img {
  transform: translateY(100%);
  opacity: 0.5;
  transition: transform 1s ease-out, opacity 1s ease-out;
}

/* VIDEO: gunakan aturan yang sama dengan gambar sehingga video juga muncul dari bawah */
.swiper-slide video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  position: absolute;
  top: 0;
  left: 0;
  z-index: 1;
  transform: translateY(100%);
  opacity: 0;
  transition: transform 1s ease-out, opacity 1s ease-out;
}

/* Gambar yang sedang aktif akan naik dari bawah */
.swiper-slide.swiper-slide-active img {
  transform: translateY(0);
  opacity: 1;
  z-index: 2;
}

/* Video yang sedang aktif juga akan naik dari bawah dan tampil seperti gambar */
.swiper-slide.swiper-slide-active video {
  transform: translateY(0);
  opacity: 1;
  z-index: 2;
}

/* Gambar yang sudah pernah aktif akan tetap di tempat (tidak beranimasi lagi) */
.swiper-slide.slide-shown img {
  transform: translateY(0) !important;
  opacity: 1 !important;
  transition: none !important;
  z-index: 1;
}

/* Jika Anda ingin mempertahankan slide-shown behavior untuk video juga */
.swiper-slide.slide-shown video {
  transform: translateY(0) !important;
  opacity: 1 !important;
  transition: none !important;
  z-index: 1;
}

.slide-text {
  position: absolute;
  z-index: 10;
  color: white;
  text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.7);
  transform: translateY(50px);
  opacity: 0;
  transition: transform 0.8s ease-out, opacity 0.8s ease-out;
  transition-delay: 0.5s;
}

.swiper-slide.swiper-slide-active .slide-text {
  transform: translateY(0);
  opacity: 1;
}

/* Reset animasi teks ketika slide tidak aktif */
.swiper-slide:not(.swiper-slide-active) .slide-text {
  transform: translateY(50px);
  opacity: 0;
}

.slide-text h1 {
  display: inline-block;
  color: white;
  font-size: 1.5rem;
  font-weight: 700;
  padding: 0.5rem 0.5rem;
  border-radius: 8px;
  word-wrap: break-word;
  text-shadow: 2px 2px 3px rgba(0, 0, 0, 0.9);
  background-color: rgba(0, 0, 0, 0.5);
}

.slide-text p {
  display: inline-block;
  color: white;
  font-weight: 700;
  padding: 0.5rem 0.5rem;
  border-radius: 8px;
  word-wrap: break-word;
  text-shadow: 2px 2px 3px rgba(0, 0, 0, 0.9);
  background-color: rgba(0, 0, 0, 0.5);
}

.slide-text a {
  color: white;
  background-color: rgba(0, 0, 0, 0.5);
}

.swiper-slide .btn {
  display: inline-block;
  position: absolute;
  bottom: -75px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 20;
  color: #fff;
  border-radius: 10px; /* border radius sekiranya */
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.45);
  text-decoration: none;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.18s ease, box-shadow 0.18s ease,
    background-color 0.18s ease;
}

.swiper-slide .btn:hover,
.swiper-slide .btn:focus {
  transform: translateX(-50%) translateY(-4px);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.9);
  background-color: #111;
  outline: none;
}

.swiper-slide .video-limas-wates {
  width: 100%; /* Lebar video 100% dari container */
  height: 100vh; /* Tinggi video 100% dari tinggi layar */

  /* INI BAGIAN TERPENTINGNYA */
  object-fit: cover;
}

@media (min-width: 768px) {
  .swiper-slide .textkegiatansantri {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    text-align: center;
    margin-top: 85px;
    z-index: 20;
  }

  .swiper-slide .textkegiatansantri .ahrefkegiatans {
    font-size: 1.5rem;
    margin-left: 15vw;
    margin-top: 300px;
    text-align: left;
  }

  .swiper-slide .texttokohpondok {
    display: inline-block;
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    text-align: center;
    margin-top: 25px;
    padding-top: 16px;
    z-index: 20;
  }

    /*.divtokohpondok .texttokohpondok a {*/
    /*    margin-top: 25px;*/
       
    /*}  */
}

@media (max-width: 768px) {
  .slide-text h1 {
    font-size: 0.9rem;
  }
  .swiper-slide .textvideopp {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    text-align: center;
    margin-top: 25px;
    /* background-color: #634d32; */
    z-index: 20;
    padding-top: 16px;
  }

  .swiper-slide .btn {
    display: inline-block;
    position: absolute;
    font-size: 15px !important;
    bottom: -225px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 20;
    color: #fff;
    border-radius: 10px; /* border radius sekiranya */
    border: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.45);
    text-decoration: none;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.18s ease, box-shadow 0.18s ease,
      background-color 0.18s ease;
    white-space: nowrap;
  }

  .swiper-slide .textvideoputraputri {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    text-align: center;
    margin-top: 125px !important;
    /* background-color: #634d32; */
  }

  .swiper-slide .textkegiatansantri {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    text-align: center;
    margin-top: 45px;
    /* background-color: #634d32; */
    z-index: 20;
  }

  .swiper-slide .textkegiatansantri .ahrefkegiatans {
    text-align: left;
    margin-left: 30px;
    margin-top: 300px;
  }

  .swiper-slide .texttokohpondok {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    text-align: center;
    margin-top: 25px;
    /* background-color: #634d32; */
    z-index: 20;
    padding-top: 16px;
  }

  .swiper-slide .texttokohpondok h1 {
    font-size: 0.9rem;
  }
}

/** CHAT GPT */
