/* Gallery Styles */
.crystal-gallery {
  margin: 2rem 0;
}

.crystal-gallery .swiper {
  width: 100%;
  height: auto;
}

.crystal-gallery .swiper-slide {
  text-align: center;
  font-size: 18px;
  background: #fff;
  display: flex;
  justify-content: center;
  align-items: center;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease;
}

.crystal-gallery .swiper-slide:hover {
  transform: translateY(-5px);
}

.gallery-image-wrapper {
  position: relative;
  width: 100%;
  height: 100%;
}

.crystal-gallery .gallery-image {
  width: 100%;
  height: 250px;
  object-fit: cover;
  cursor: pointer;
  transition: opacity 0.3s ease;
}

.crystal-gallery .gallery-image:hover {
  opacity: 0.9;
}

.gallery-caption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(0, 0, 0, 0.7);
  color: #fff;
  padding: 8px;
  font-size: 14px;
  text-align: center;
}

/* Swiper Navigation */
.crystal-gallery .swiper-button-next,
.crystal-gallery .swiper-button-prev {
  color: #333;
  background: rgba(255, 255, 255, 0.9);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.crystal-gallery .swiper-button-next:hover,
.crystal-gallery .swiper-button-prev:hover {
  background: #fff;
  color: #000;
}

/* Swiper Pagination */
.crystal-gallery .swiper-pagination-bullet {
  background: #333;
  opacity: 0.5;
}

.crystal-gallery .swiper-pagination-bullet-active {
  opacity: 1;
  background: #007cba;
}

/* Lightbox Styles */
.gallery-lightbox {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 9999;
}

.lightbox-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.9);
}

.lightbox-content {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.lightbox-image-container {
  max-width: 90%;
  max-height: 80%;
  text-align: center;
}

.lightbox-image {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.lightbox-caption {
  color: #fff;
  margin-top: 1rem;
  font-size: 1.1rem;
  text-align: center;
  max-width: 80%;
}

.lightbox-close {
  position: absolute;
  top: 20px;
  right: 20px;
  background: rgba(255, 255, 255, 0.2);
  border: none;
  color: #fff;
  font-size: 2rem;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  cursor: pointer;
  transition: background 0.3s ease;
}

.lightbox-close:hover {
  background: rgba(255, 255, 255, 0.3);
}

.lightbox-prev,
.lightbox-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.2);
  border: none;
  color: #fff;
  font-size: 1.5rem;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  cursor: pointer;
  transition: background 0.3s ease;
}

.lightbox-prev {
  left: 20px;
}

.lightbox-next {
  right: 20px;
}

.lightbox-prev:hover,
.lightbox-next:hover {
  background: rgba(255, 255, 255, 0.3);
}

/* Responsive Design */
@media (max-width: 768px) {
  .crystal-gallery .gallery-image {
    height: 200px;
  }

  .lightbox-prev,
  .lightbox-next {
    width: 40px;
    height: 40px;
    font-size: 1.2rem;
  }

  .lightbox-close {
    width: 40px;
    height: 40px;
    font-size: 1.5rem;
  }

  .lightbox-caption {
    font-size: 1rem;
    max-width: 90%;
  }
}

/* Gallery Grid Layout (Alternative to Swiper) */
.gallery-grid {
  display: grid;
  gap: 20px;
  margin: 2rem 0;
}

.gallery-grid.columns-1 {
  grid-template-columns: 1fr;
}

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

.gallery-grid.columns-3 {
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

.gallery-grid.columns-4 {
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}

.gallery-grid-item {
  position: relative;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease;
}

.gallery-grid-item:hover {
  transform: translateY(-5px);
}

.gallery-grid-item img {
  width: 100%;
  height: 250px;
  object-fit: cover;
  cursor: pointer;
}
