/* Gallery Page Specific Styles */

.page-header {
  background: linear-gradient(rgba(26, 75, 132, 0.9), rgba(44, 83, 100, 0.9)), url("../assets/images/background_images/bg_gallery_header.jpeg") no-repeat center center/cover;
  color: white;
  text-align: center;
  padding: 150px 0 80px;
  margin-top: 80px;
}

.page-header h1 {
  font-size: 3rem;
  margin-bottom: 1rem;
}

.page-header p {
  font-size: 1.3rem;
  opacity: 0.9;
}

/* Gallery Sections */
.gallery-section {
  padding: 4rem 0;
}

.gallery-section:nth-child(even) {
  background: linear-gradient(135deg, #f8f9fa, #e9ecef);
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

.gallery-item {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  transition: all var(--transition-speed) ease;
  cursor: pointer;
  height: 300px;
}

.gallery-item:hover {
  transform: translateY(-10px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-speed) ease;
}

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

.gallery-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
  color: white;
  padding: 2rem;
  transform: translateY(100%);
  transition: transform var(--transition-speed) ease;
}

.gallery-item:hover .gallery-overlay {
  transform: translateY(0);
}

.gallery-overlay h3 {
  color: var(--accent-color);
  margin-bottom: 0.5rem;
  font-size: 1.2rem;
}

.gallery-overlay p {
  margin: 0;
  font-size: 0.9rem;
  opacity: 0.9;
  line-height: 1.4;
}

/* Image Modal */
.image-modal {
  display: none;
  position: fixed;
  z-index: 2000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.9);
  backdrop-filter: blur(5px);
}

.image-modal .modal-content {
  position: relative;
  margin: 2% auto;
  width: 90%;
  max-width: 900px;
  background: white;
  border-radius: 16px;
  overflow: hidden;
  animation: modalFadeIn 0.3s ease-out;
}

@keyframes modalFadeIn {
  from {
    opacity: 0;
    transform: scale(0.9) translateY(-20px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

.close-modal {
  position: absolute;
  top: 15px;
  right: 20px;
  font-size: 28px;
  font-weight: bold;
  cursor: pointer;
  color: white;
  z-index: 10;
  background: rgba(0, 0, 0, 0.5);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
}

.close-modal:hover {
  background: var(--accent-color);
  transform: rotate(90deg);
}

#modalImage {
  width: 100%;
  height: 400px;
  object-fit: cover;
}

.modal-info {
  padding: 2rem;
}

.modal-info h3 {
  color: var(--primary-color);
  margin-bottom: 1rem;
  font-size: 1.5rem;
}

.modal-info p {
  color: #666;
  line-height: 1.6;
  margin: 0;
}

/* Section Navigation */
.gallery-nav {
  position: sticky;
  top: 80px;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  padding: 1rem 0;
  margin-bottom: 2rem;
  z-index: 100;
}

.gallery-nav ul {
  display: flex;
  justify-content: center;
  gap: 2rem;
  flex-wrap: wrap;
  list-style: none;
  margin: 0;
  padding: 0;
}

.gallery-nav a {
  color: var(--primary-color);
  text-decoration: none;
  padding: 0.5rem 1rem;
  border-radius: 25px;
  transition: all var(--transition-speed) ease;
  font-weight: 500;
}

.gallery-nav a:hover,
.gallery-nav a.active {
  background: var(--accent-color);
  color: white;
}

/* Responsive Design */
@media (max-width: 768px) {
  .page-header {
    padding: 120px 0 60px;
  }
  
  .page-header h1 {
    font-size: 2.2rem;
  }
  
  .gallery-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  
  .gallery-item {
    height: 250px;
  }
  
  .gallery-overlay {
    padding: 1.5rem;
  }
  
  .image-modal .modal-content {
    width: 95%;
    margin: 5% auto;
  }
  
  #modalImage {
    height: 250px;
  }
  
  .modal-info {
    padding: 1.5rem;
  }
  
  .gallery-nav ul {
    gap: 1rem;
  }
  
  .gallery-nav a {
    padding: 0.4rem 0.8rem;
    font-size: 0.9rem;
  }
}

@media (max-width: 480px) {
  .gallery-item {
    height: 200px;
  }
  
  .gallery-overlay h3 {
    font-size: 1rem;
  }
  
  .gallery-overlay p {
    font-size: 0.8rem;
  }
  
  #modalImage {
    height: 200px;
  }
}