/* ===== Full-screen loader band between header and main ===== */
#loader-wrapper {
  width: 100%;
  background: #000;
  min-height: 60vh; /* adjust as you like */
}

/* While loading, hide ONLY the main content.
   Header, footer and WhatsApp float stay visible. */
body.loading main {
  visibility: hidden;
}

/* ========================================

GALLERY PAGE STYLES – COMPLETE PRODUCTION

Grid + Flow Viewer + Animations + Responsive

======================================== */

/* Section backgrounds */

#gallery {
  padding: 4rem 2rem;
  background: linear-gradient(
    135deg,
    rgba(20, 0, 40, 0.8) 0%,
    rgba(0, 20, 60, 0.6) 100%
  );
  min-height: 50vh;
}

#flow-section {
  padding: 3rem 2rem 2rem;
  background: var(--bg-main);
}

/* ═════════════════════════════════════
   FILTER BUTTONS – GLASSMORPHIC
═════════════════════════════════════ */

.gallery-filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: center;
  margin: 2rem 0;
}

.filter-btn {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: white;
  padding: 0.75rem 1.5rem;
  border-radius: 50px;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  font-weight: 500;
  font-size: 0.9rem;
  letter-spacing: 0.5px;
  position: relative;
  overflow: hidden;
}

.filter-btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.25),
    transparent
  );
  transition: left 0.5s;
}

.filter-btn:hover::before {
  left: 100%;
}

.filter-btn:hover,
.filter-btn.active {
  background: rgba(100, 200, 255, 0.3);
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(100, 200, 255, 0.3);
  border-color: rgba(100, 200, 255, 0.5);
}

/* ═════════════════════════════════════
   STATS BOX
═════════════════════════════════════ */

.gallery-stats {
  margin: 1.5rem 0 2rem;
  padding: 1.5rem;
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(20px);
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  text-align: center;
  font-size: 0.95rem;
  color: rgba(255, 255, 255, 0.9);
}

.gallery-stats strong {
  display: inline-block;
  margin: 0 0.8rem;
  font-weight: 600;
}

.gallery-stats div:last-child {
  margin-top: 0.5rem;
  font-size: 0.85rem;
  opacity: 0.8;
}

/* ═════════════════════════════════════
   SECTION HEADERS
═════════════════════════════════════ */

.gallery-section-header {
  margin-top: 2rem;
  margin-bottom: 1rem;
  padding-bottom: 0.8rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.gallery-section-title {
  font-size: 1.2rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.95);
  margin: 0 0 0.3rem 0;
  letter-spacing: 0.05em;
}

.gallery-section-meta {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.6);
  margin: 0;
}

/* ═════════════════════════════════════
   GALLERY GRID CONTAINER
═════════════════════════════════════ */

#drive-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.5rem;
  padding: 1rem 0;
}

.gallery-section-grid {
  display: contents; /* Allows grid items to bypass wrapper */
}

/* ═════════════════════════════════════
   GALLERY ITEMS – CARDS
═════════════════════════════════════ */

.gallery-item {
  position: relative;
  aspect-ratio: 4/3;
  overflow: hidden;
  border-radius: 20px;
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  cursor: pointer;
  animation: fadeInGallery 0.6s ease-out;
}

.gallery-item:hover {
  transform: translateY(-10px) scale(1.02);
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
  border-color: rgba(255, 255, 255, 0.2);
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}

.gallery-item:hover img {
  transform: scale(1.1);
}

.gallery-caption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.9));
  color: white;
  padding: 1.5rem 1rem 1rem;
  transform: translateY(100%);
  transition: transform 0.4s ease;
}

.gallery-item:hover .gallery-caption {
  transform: translateY(0);
}

.gallery-caption strong {
  font-size: 1.05rem;
  display: block;
  margin-bottom: 0.25rem;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.8);
}

.gallery-caption small {
  opacity: 0.85;
  font-size: 0.85rem;
}

/* ═════════════════════════════════════
   FLOW STRIP – CIRCULAR THUMBNAILS
═════════════════════════════════════ */

#flow-stage {
  position: relative;
  width: 100%;
  padding: 1.5rem 0 2.5rem;
  display: flex;
  justify-content: flex-start;
  align-items: center;
  overflow-x: auto;
  overflow-y: visible;
  gap: 1rem;
  scrollbar-width: thin;
  scroll-behavior: smooth;
}

#flow-stage::-webkit-scrollbar {
  height: 6px;
}

#flow-stage::-webkit-scrollbar-track {
  background: transparent;
}

#flow-stage::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.2);
  border-radius: 3px;
}

#flow-stage::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.4);
}

.flow-card {
  flex: 0 0 auto;
  width: 72px;
  height: 72px;
  border-radius: 50%;
  overflow: hidden;
  background: #111;
  border: 2px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.6);
  transform-origin: center;
  transform: translateY(0);
  transition: transform 0.35s ease, box-shadow 0.35s ease,
    border-color 0.35s ease;
  cursor: pointer;
}

.flow-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Wave animation effect – staggered */
.flow-card:nth-child(odd) {
  transform: translateY(-6px);
}

.flow-card:nth-child(3n) {
  transform: translateY(4px);
}

.flow-card:hover {
  transform: translateY(-8px) scale(1.05);
  border-color: rgba(255, 255, 255, 0.6);
  box-shadow: 0 14px 35px rgba(0, 0, 0, 0.8);
}

/* ═════════════════════════════════════
   FLOW MODAL – FULLSCREEN VIEWER
═════════════════════════════════════ */

#flow-modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.98);
  z-index: 10000;
  touch-action: none;
  overflow: hidden;
}

#flow-viewport {
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: grab;
}

#flow-viewport:active {
  cursor: grabbing;
}

#flow-full-img {
  max-width: 95%;
  max-height: 85%;
  object-fit: contain;
  transition: transform 0.1s ease-out;
  pointer-events: none;
  user-select: none;
  border-radius: 12px;
}

/* ═════════════════════════════════════
   FLOW UI BUTTONS – TRANSPARENT
═════════════════════════════════════ */

.flow-ui-btn {
  position: absolute;
  z-index: 1020;
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.25);
  padding: 10px 22px;
  border-radius: 40px;
  font-weight: 600;
  cursor: pointer;
   backdrop-filter: none;/*backdrop-filter: blur(10px);*/
  transition: all 0.3s ease;
  font-size: 0.85rem;
}

.flow-ui-btn:hover {
  background: rgba(255, 255, 255, 0.3);
  border-color: #fff;
  transform: translateY(-1px);
}

.flow-btn-close {
  top: 18px;
  right: 18px;
  font-size: 1.4rem;
  width: 46px;
  height: 46px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.flow-btn-dl {
  bottom: 26px;
  left: 50%;
  transform: translateX(-50%);
  text-decoration: none;
  letter-spacing: 1px;
}

/* ═════════════════════════════════════
   FLOW NAV BUTTONS
═════════════════════════════════════ */

.flow-nav-btn {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 18%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.08);
  z-index: 1010;
  cursor: pointer;
  transition: all 0.25s ease;
}

.flow-nav-btn:hover {
  color: rgba(255, 255, 255, 0.65);
  background: rgba(255, 255, 255, 0.03);
}

.flow-nav-left {
  left: 0;
}

.flow-nav-right {
  right: 0;
}

/* ═════════════════════════════════════
   ANIMATIONS
═════════════════════════════════════ */

@keyframes fadeInGallery {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.gallery-item:nth-child(even) {
  animation-delay: 0.08s;
}

.gallery-item:nth-child(3n) {
  animation-delay: 0.16s;
}

/* ═════════════════════════════════════
   RESPONSIVE – TABLET (768px)
═════════════════════════════════════ */

@media (max-width: 768px) {
  #gallery {
    padding: 2.5rem 1rem;
  }

  #flow-section {
    padding: 2rem 1rem 1.5rem;
  }

  #drive-gallery {
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 1.1rem;
  }

  .filter-btn {
    padding: 0.6rem 1.2rem;
    font-size: 0.8rem;
  }

  .gallery-section-title {
    font-size: 1.05rem;
  }

  .gallery-caption {
    padding: 1.1rem 0.8rem 0.8rem;
  }

  .gallery-caption strong {
    font-size: 1rem;
  }

  .flow-card {
    width: 62px;
    height: 62px;
  }

  .flow-nav-btn {
    font-size: 2.4rem;
    width: 22%;
  }

  .flow-btn-dl {
    bottom: 18px;
    padding: 8px 18px;
    font-size: 0.8rem;
  }
}

/* ═════════════════════════════════════
   RESPONSIVE – MOBILE (480px)
═════════════════════════════════════ */

@media (max-width: 480px) {
  #gallery {
    padding: 2rem 0.75rem;
  }

  #flow-section {
    padding: 1.5rem 0.75rem 1rem;
  }

  #drive-gallery {
    grid-template-columns: 1fr;
    gap: 0.9rem;
  }

  .filter-btn {
    flex: 1;
    min-width: 100px;
    padding: 0.5rem 1rem;
    font-size: 0.75rem;
  }

  .gallery-section-title {
    font-size: 1rem;
  }

  .gallery-section-meta {
    font-size: 0.8rem;
  }

  .gallery-caption {
    padding: 0.9rem 0.7rem 0.7rem;
  }

  .gallery-caption strong {
    font-size: 0.95rem;
  }

  .gallery-caption small {
    font-size: 0.8rem;
  }

  .flow-card {
    width: 62px;
    height: 62px;
  }

  .flow-nav-btn {
    font-size: 2.4rem;
    width: 22%;
  }

  .flow-btn-dl {
    bottom: 18px;
    padding: 8px 18px;
    font-size: 0.8rem;
  }
}
#flow-modal {
  backdrop-filter: blur(10px);
}

#flow-full-img {
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.8);
  animation: popFadeIn 0.25s ease-out;
}

@keyframes popFadeIn {
  from {
    opacity: 0;
    transform: scale(0.94);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}
/* Fix pop-out carousel buttons on mobile */

/* Tablet and below: make side tap areas narrower */
@media (max-width: 768px) {
  .flow-nav-btn {
    width: 18%;          /* was 22% in your existing media query */
    backdrop-filter: none;
    background: transparent;
  }
}

/* Small mobile: make them even slimmer and fully transparent */
@media (max-width: 480px) {
  .flow-nav-btn {
    width: 14%;          /* narrower touch strips */
    background: transparent;
    backdrop-filter: none;     /* remove blur behind image */
    box-shadow: none;
  }

  .flow-nav-btn:hover {
    background: transparent;   /* no overlay on hover */
  }

  /* Optionally move arrows slightly in so they don't sit on the edges */
  .flow-nav-left {
    justify-content: flex-start;
    padding-left: 4px;
  }

  .flow-nav-right {
    justify-content: flex-end;
    padding-right: 4px;
  }
}
