/* Modern Gallery Styles */
:root {
  --primary: #2a2a2a;
  --secondary: #4a90e2;
  --accent: #f7d794;
  --text: #333;
  --background: #f8f9fa;
  --white: #ffffff;
  --shadow: 0 8px 30px rgba(0,0,0,0.12);
  --transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Page Header */
.page-header {
  background: linear-gradient(45deg, var(--primary), var(--secondary));
  padding: 6rem 2rem;
  text-align: center;
  color: var(--white);
  margin-bottom: 2rem;
}

.page-header h1 {
  font-size: 3.5rem;
  margin: 0;
  text-shadow: 2px 2px 4px rgba(0,0,0,0.2);
}

/* Gallery Filters */
.gallery-filters {
  display: flex;
  justify-content: center;
  gap: 1rem;
  padding: 2rem;
  flex-wrap: wrap;
  max-width: 1200px;
  margin: 0 auto;
}

.filter-btn {
  padding: 0.8rem 1.5rem;
  border: none;
  background: var(--white);
  color: var(--text);
  border-radius: 50px;
  cursor: pointer;
  font-weight: 500;
  transition: var(--transition);
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.filter-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.filter-btn.active {
  background: var(--secondary);
  color: var(--white);
}

/* Gallery Grid */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  padding: 2rem;
  max-width: 1200px; /* Set a maximum width */
  margin: 0 auto; /* Center the gallery */
}

.gallery-item {
  position: relative;
  border-radius: 1rem;
  overflow: hidden;
  box-shadow: var(--shadow);
  cursor: pointer;
  transform-origin: center;
  transition: var(--transition);
  background: var(--white);
  aspect-ratio: 1;
}

.gallery-item::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.7), transparent);
  opacity: 0;
  transition: var(--transition);
  z-index: 1;
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: var(--transition);
}

.gallery-item:hover {
  transform: scale(1.02);
}

.gallery-item:hover img {
  transform: scale(1.1);
}

.gallery-item:hover::before {
  opacity: 1;
}

.overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 2rem;
  color: var(--white);
  z-index: 2;
  transform: translateY(100%);
  transition: var(--transition);
}

.gallery-item:hover .overlay {
  transform: translateY(0);
}

.overlay h3 {
  font-size: 1.5rem;
  margin: 0 0 0.5rem 0;
  font-weight: 600;
}

.overlay p {
  margin: 0;
  opacity: 0.9;
}

/* Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.95);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
}

.lightbox.active {
  opacity: 1;
  visibility: visible;
}

.lightbox-content {
  position: relative;
  max-width: 90vw;
  max-height: 90vh;
  transform: scale(0.9);
  transition: var(--transition);
}

.lightbox.active .lightbox-content {
  transform: scale(1);
}

.lightbox-close {
  position: absolute;
  top: -2rem;
  right: -2rem;
  width: 2.5rem;
  height: 2.5rem;
  background: var(--white);
  border: none;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  color: var(--primary);
  transition: var(--transition);
}

.lightbox-close:hover {
  background: var(--secondary);
  color: var(--white);
  transform: rotate(90deg);
}

.lightbox img {
  max-width: 100%;
  max-height: 80vh;
  border-radius: 0.5rem;
  box-shadow: var(--shadow);
}

.lightbox-caption {
  color: var(--white);
  text-align: center;
  margin-top: 1rem;
  font-size: 1.2rem;
}

/* Loading Animation */
.gallery-item.loading {
  animation: shimmer 1.5s infinite;
  background: linear-gradient(
    90deg,
    var(--background) 0%,
    #f0f0f0 50%,
    var(--background) 100%
  );
  background-size: 200% 100%;
}

@keyframes shimmer {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

/* Responsive Design */
@media (max-width: 768px) {
  .page-header {
    padding: 4rem 1rem;
  }

  .page-header h1 {
    font-size: 2.5rem;
  }

  .gallery-grid {
    grid-template-columns: repeat( auto-fit, minmax(250px, 1fr));
    gap: 1rem;
    padding: 1rem;
  }

  .filter-btn {
    padding: 0.6rem 1.2rem;
    font-size: 0.9rem;
  }

  .overlay {
    padding: 1.5rem;
  }

  .overlay h3 {
    font-size: 1.2rem;
  }
}
/* Default navigation for large screens */
.nav-links {
  display: flex;  /* Always visible on large screens */
  list-style: none;
  gap: 20px;
}

/* Hide the menu on small screens initially */
@media (max-width: 768px) {
  .nav-links {
      display: none;  /* Hide by default on small screens */
      flex-direction: column;
      background-color: #003366;
      position: absolute;
      top: 60px; /* Adjust based on header height */
      right: 0;
      width: 200px;
      border-radius: 5px;
  }

  .nav-links.show {
      display: flex;  /* Show when clicked */
  }

  .hamburger {
      display: flex;  /* Show hamburger only on small screens */
      flex-direction: column;
      cursor: pointer;
  }
}

