.custom-gallery {
  max-width: 1000px;
  margin: auto;
  display: flex;
  flex-direction: column;
  gap: 20px; /* main spacing */
  overflow: hidden;
}

/* COMMON GRID (same gap everywhere) */
.custom-gallery .gallery-row,
.custom-gallery .hidden-gallery {
  display: grid;
  gap: 20px  !important;
}

/* ROW LAYOUT */
.custom-gallery .row-1 {
  grid-template-columns: repeat(3, 1fr);
}

.custom-gallery .row-2 {
  grid-template-columns: repeat(2, 1fr);
  margin: 0 auto;
}

/* HIDDEN GALLERY (FIXED) */
.custom-gallery .hidden-gallery {
  display: none;
  grid-template-columns: repeat(3, 1fr);
  /* ❌ margin-top remove kari didhu */
}

/* IMAGE STYLE */
.custom-gallery .gallery-row img,
.custom-gallery .hidden-gallery img {
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
  border-radius: 12px;
}

/* LIGHTBOX */
.custom-gallery .lightbox {
  display: none;
  position: fixed;
  z-index: 9999;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.9);
  justify-content: center;
  align-items: center;
}

.custom-gallery .lightbox img {
  max-width: 90%;
  max-height: 90%;
  border-radius: 12px;
}

.custom-gallery .lightbox-close {
  position: absolute;
  top: 20px;
  right: 25px;
  font-size: 30px;
  color: #fff;
  cursor: pointer;
  font-weight: bold;
}

/* BUTTON */
.custom-gallery .gallery-btn {
  text-align: center;
  margin-top: 30px;
}

.custom-gallery .gallery-btn button {
  background: #3c3481;
  color: #fff;
  font-family: "Fredoka";
  padding: 20px 40px;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 1.2px;
  border-radius: 99px;
  border: none;
  cursor: pointer;
  transition: 0.3s;
}

.custom-gallery .gallery-btn button:hover {
  background: #de137e;
  transform: translateY(-2px);
}

/* MOBILE */
@media (min-width: 768px) and (max-width: 1024px) {
  .row-1 {
    grid-template-columns: repeat(2, 1fr);
  }
  .row-2 {
    grid-template-columns: repeat(2, 1fr);
  }
  .hidden-gallery {
    grid-template-columns: repeat(2, 1fr);
  }
  .custom-gallery .gallery-row,
  .custom-gallery .hidden-gallery {
    display: grid;
    gap: 15px  !important;
  }
  .custom-gallery {
    display: flex;
    flex-direction: column;
    gap: 20px !important;
  }
}
@media (max-width: 768px){
  .custom-gallery {
    display: flex;
    flex-direction: column;
    gap: 10px;
  }
}