/* =============================================
   HERYERPARKOUR — Gallery Page
   ============================================= */

/* ——— Gallery Filter Tabs ——— */
.gallery-filters {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 40px;
}
.gal-filter-btn {
  background: transparent;
  border: 2px solid rgba(0, 0, 0, 0.12);
  color: var(--text-primary);
  font-family: var(--font-heading);
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  padding: 8px 20px;
  clip-path: var(--clip-btn);
  cursor: pointer;
  transition: all 0.3s;
}
.gal-filter-btn:hover,
.gal-filter-btn.active {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--white);
}

/* ——— Masonry Grid ——— */
.gallery-masonry {
  columns: 3;
  column-gap: 16px;
}
.gal-item {
  break-inside: avoid;
  margin-bottom: 16px;
  clip-path: var(--clip-card);
  overflow: hidden;
  position: relative;
  cursor: pointer;
}
.gal-item img {
  width: 100%;
  display: block;
  transition: transform 0.5s;
}
.gal-item:hover img { transform: scale(1.05); }

/* Overlay on hover */
.gal-item::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.6) 0%, transparent 60%);
  opacity: 0;
  transition: opacity 0.3s;
}
.gal-item:hover::after { opacity: 1; }

.gal-item-caption {
  position: absolute;
  bottom: 16px;
  left: 16px;
  right: 16px;
  color: var(--white);
  font-family: var(--font-heading);
  font-size: 0.9rem;
  font-weight: 600;
  text-transform: uppercase;
  opacity: 0;
  transform: translateY(8px);
  transition: all 0.3s;
  z-index: 2;
}
.gal-item:hover .gal-item-caption {
  opacity: 1;
  transform: translateY(0);
}

/* ——— Lightbox ——— */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.92);
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;
}
.lightbox.open { display: flex; }
.lightbox-img {
  max-width: 90vw;
  max-height: 85vh;
  object-fit: contain;
}
.lightbox-close {
  position: absolute;
  top: 24px;
  right: 24px;
  width: 48px;
  height: 48px;
  background: none;
  border: none;
  color: var(--white);
  font-size: 2rem;
  cursor: pointer;
}
.lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.1);
  border: none;
  color: var(--white);
  width: 48px;
  height: 48px;
  font-size: 1.5rem;
  cursor: pointer;
  transition: background 0.3s;
  clip-path: var(--clip-btn);
}
.lightbox-nav:hover { background: var(--accent); }
.lightbox-prev { left: 24px; }
.lightbox-next { right: 24px; }

/* ——— Video Section ——— */
.gallery-videos {
  margin-top: 64px;
}
.gallery-vid-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
}
.gallery-vid-card {
  aspect-ratio: 16/9;
  clip-path: var(--clip-card);
  overflow: hidden;
  position: relative;
  background: var(--bg-dark);
}

/* ——— Responsive ——— */
@media (max-width: 768px) {
  .gallery-masonry { columns: 2; }
  .gallery-filters { gap: 6px; }
  .gal-filter-btn { padding: 6px 14px; font-size: 0.75rem; }
}
@media (max-width: 480px) {
  .gallery-masonry { columns: 1; }
}
