/* ===== Gallery Page Styles ===== */

.gallery-page-section {
  padding-block: var(--section-padding-y);
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 30px;
  max-width: 1200px;
  margin: 20px auto 0;
  align-items: start;
}

.gallery-item {
  position: relative;
  overflow: hidden;
  border-radius: 12px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  cursor: pointer;
  background: #1a1a1a;
  height: 280px; /* Fixed height for virtualization */
}

.gallery-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(255, 191, 0, 0.15);
}

.gallery-item img {
  width: 100%;
  height: 100%; /* Fill container */
  object-fit: cover;
  display: block;
  transition: transform 0.5s ease;
}

.gallery-item:hover img {
  transform: scale(1.1);
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
  }

  .gallery-item {
    height: 200px;
  }
}

@media (max-width: 480px) {
  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* GSAP Initial States to prevent FOUC */
.section-title,
.gallery-grid {
  opacity: 0;
  visibility: hidden;
}
