/* ===============================
   BANNER (scoped, deduplicated)
   =============================== */

#banner {
  padding: 0;
}

/* Desktop/tablet: real height so children can size reliably */
#banner .carousel {
  position: relative;
  width: 100%;
  height: clamp(520px, 70vh, 900px);
  background: #000;
}

#banner .carousel-inner,
#banner .carousel-item,
#banner .banner-item {
  position: relative;
  height: 100%;
  overflow: hidden;
}

/* Image: full-bleed on larger screens */
#banner .banner-img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 1;
}

/* Soft readability gradient from the bottom (not a box) */
#banner .banner-item::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 28vh; /* desktop fade height */
  background: linear-gradient(to top, rgba(0, 0, 0, 0.45), rgba(0, 0, 0, 0));
  pointer-events: none;
  z-index: 2; /* below caption, above image */
}

/* Caption: bottom-centered, just above the dots */
#banner .banner-caption {
  position: absolute;
  left: 50%;
  bottom: 3rem; /* ~1.5–2rem above dots */
  transform: translateX(-50%);
  width: 100%;
  max-width: 960px;
  padding: 0.75rem 1rem;
  text-align: center;
  z-index: 5; /* above gradient + dots */
  background: rgba(0, 0, 0, 0.45); /* overlay */
  backdrop-filter: saturate(120%) blur(4px); /* optional: soft glass effect */
  border-radius: 12px;
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.25);
}

/* Ensure no “box” behind caption */
/* #banner .banner-caption::before {
  content: none;
} */

/* Type */
#banner .banner-title {
  margin: 0 0 0.35rem;
  color: #fff;
  font-weight: 700;
  font-size: clamp(26px, 3.6vw, 46px); /* was clamp(22px, 3vw, 40px) */
  line-height: 1.15;
}

#banner .banner-sub {
  margin: 0 auto;
  max-width: 92%;
  color: #fff;
  font-size: clamp(15px, 2.2vw, 20px); /* was clamp(14px, 2vw, 18px) */
  line-height: 1.45;
  text-align: justify;
  opacity: 0.98;
}

/* Controls & indicators */
#banner .carousel-indicators {
  bottom: 0.75rem;
}
#banner .carousel-control-prev,
#banner .carousel-control-next,
#banner .carousel-indicators {
  z-index: 5;
}

/* ========= Mobile (≤768px) ========= */
@media (max-width: 768px) {
  /* Let the image dictate height; show full image (no crop) */
  #banner .carousel,
  #banner .carousel-inner,
  #banner .carousel-item,
  #banner .banner-item {
    height: auto;
  }

  #banner .banner-img {
    height: auto;
    object-fit: contain;
  }

  /* Extend gradient a bit on phones */
  #banner .banner-item::after {
    height: 35vh;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.35), rgba(0, 0, 0, 0));
  }

  /* Keep caption bottom-centered, a touch tighter */
  #banner .banner-caption {
    bottom: 2.25rem;
    max-width: 92%;
    padding: 0.5rem 0.75rem;
    background: rgba(0, 0, 0, 0.35);
    border-radius: 10px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
    /* bottom: 2.25rem;
    max-width: 92%;
    padding: 0.5rem 0.75rem; */
  }

  /* Softer, smaller title on phones */
  #banner .banner-title {
    font-size: clamp(20px, 5.5vw, 26px); /* was clamp(18px, 5vw, 24px) */
    font-weight: 700;
    letter-spacing: 0.1px;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.25);
  }

  /* Hide subtitle on phones (accessibility-friendly) */
  #banner .banner-sub {
    position: absolute !important;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip-path: rect(0 0 0 0);
    white-space: nowrap;
    border: 1;
    /* If you prefer to remove it entirely, replace the block above with:
       display: none !important;  */
  }
}
