/* Simple Photo Gallery with Modal */

/* Grid of uniform thumbnails */
.photo-thumbs-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 6px;
  padding: 0;
  list-style: none;
  margin: 0;
}

.photo-thumbs-grid li {
  width: 100%;
  aspect-ratio: 1/1;
  overflow: hidden;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

.photo-thumbs-grid li:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.photo-thumbs-grid li img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.photo-thumbs-grid li:hover img {
  transform: scale(1.1);
}

/* Modal Styles */
.photo-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.9);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
}

.photo-modal-content {
  position: relative;
  width: 90%;
  max-width: 1000px;
  height: 90vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.photo-modal-image {
  max-width: 100%;
  max-height: 85vh;
  object-fit: contain;
  border-radius: 4px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
}

.photo-modal-close {
  position: absolute;
  top: 20px;
  right: 20px;
  background: rgba(255, 255, 255, 0.2);
  border: none;
  color: #fff;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.photo-modal-close:hover {
  background: rgba(255, 255, 255, 0.3);
  transform: rotate(90deg);
}

.photo-modal-prev,
.photo-modal-next {
  position: absolute;
  background: rgba(255, 255, 255, 0.2);
  border: none;
  color: #fff;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  top: 50%;
  transform: translateY(-50%);
}

.photo-modal-prev {
  left: 20px;
}

.photo-modal-next {
  right: 20px;
}

.photo-modal-prev:hover,
.photo-modal-next:hover {
  background: rgba(255, 255, 255, 0.3);
  transform: translateY(-50%) scale(1.1);
}

.photo-modal-counter {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(0, 0, 0, 0.7);
  color: #fff;
  padding: 8px 16px;
  border-radius: 20px;
  font-size: 14px;
  font-weight: 600;
}

/* Responsive */
@media (max-width: 991px) {
  .photo-thumbs-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 5px;
  }
}

@media (max-width: 768px) {
  .photo-thumbs-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 5px;
  }

  .photo-modal-prev,
  .photo-modal-next {
    width: 40px;
    height: 40px;
    font-size: 20px;
  }

  .photo-modal-prev {
    left: 10px;
  }

  .photo-modal-next {
    right: 10px;
  }
}

@media (max-width: 576px) {
  .photo-thumbs-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 4px;
  }
}
