.lightgallery {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1000;
  display: flex;
  justify-content: center;
  align-items: center;
}

.backdrop {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.9);
  z-index: -1;
}

.closeButton {
  position: absolute;
  top: 2.4rem;
  right: 2.4rem;
  background: rgba(0, 0, 0, 0.4);
  border: none;
  color: white;
  font-size: 1.6rem;
  cursor: pointer;
  z-index: 10;
  width: 4rem;
  height: 4rem;
  display: flex;
  justify-content: center;
  align-items: center;
  border-radius: 50%;
  transition: background-color 0.3s;
}

.closeButton:hover {
  background-color: rgba(255, 255, 255, 0.2);
}

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

.imageContainer {
  width: 100%;
  height: 90%;
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
}

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

.galleryVideo {
  max-width: 100%;
}

.navButton {
  background: rgba(0, 0, 0, 0.4);
  border: none;
  color: white;
  cursor: pointer;
  width: 3.2rem;
  height: 3.2rem;
  display: flex;
  justify-content: center;
  align-items: center;
  border-radius: 50%;
  transition: background-color 0.3s;
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10000;
}

.prevButton {
  left: 0.8rem;
}

.nextButton {
  right: 0.8rem;
}

.closeButton {
  top: 1.6rem;
  right: 1.6rem;
  width: 3.2rem;
  height: 3.2rem;
}

.thumbnails {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  display: flex;
  justify-content: center;
  gap: 0.8rem;
  padding: 1.6rem;
  overflow-x: auto;
  background-color: rgba(0, 0, 0, 0.3);
}

.thumbnail {
  width: 6.4rem;
  height: 6.4rem;
  position: relative;
  border-radius: 0.4rem;
  overflow: hidden;
  cursor: pointer;
  opacity: 0.6;
  transition: opacity 0.3s, transform 0.3s;
  flex-shrink: 0;
  border: 0.2rem solid transparent;
}

.thumbnail:hover {
  opacity: 0.8;
}

.activeThumbnail {
  opacity: 1;
  border-color: var(--white, white);
  transform: scale(1.05);
}

.thumbnailYouTube {
  position: relative;
  width: 100%;
  height: 100%;
}

.playButtonSmall {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 2.4rem;
  height: 2.4rem;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1;
}

.counter {
  position: absolute;
  bottom: 0.8rem;
  left: 50%;
  transform: translateX(-50%);
  color: white;
  background-color: rgba(0, 0, 0, 0.6);
  padding: 0.8rem 1.6rem;
  border-radius: 2.4rem;
  font-size: 1.4rem;
}

@media (min-width: 768px) {
  .navButton:hover {
    background-color: rgba(255, 255, 255, 0.2);
  }
  .imageContainer {
    width: 80%;
    height: 80%;
  }

  .navButton {
    width: 4.8rem;
    height: 4.8rem;
  }

  .prevButton {
    left: 2.4rem;
  }

  .nextButton {
    right: 2.4rem;
  }

  .closeButton {
    top: 2.4rem;
    right: 2.4rem;
    width: 4rem;
    height: 4rem;
  }
}
