.gallery {
  display: flex;
  flex-flow: row wrap;
  align-content: flex-start;
  align-items: stretch;
  width: 100%;
  margin: 0px auto;
  margin-bottom: calc(var(--space-60) * -1);
}
.gallery .galleryItem {
  flex: 1 1 auto;
  margin: 0.3em;
  border-radius: 3px;
  position: relative;
  width: 12em;
  height: 13em;
  overflow: hidden;
}
@media (min-width: 40em) {
  .gallery .galleryItem {
    width: 10em;
    height: 10em;
  }
}
@media (min-width: 80em) {
  .gallery .galleryItem {
    width: 17em;
    height: 17em;
  }
}
.gallery .galleryItem:hover img {
  transform: scale(1.2);
}
.gallery a {
  display: block;
  width: 100%;
  height: 100%;
}
.gallery img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: 0.2s;
}
.gallery figcaption {
  background-color: rgba(245, 237, 224, 0.9);
  color: #7e7f70;
  font-family: "IBM Plex Mono";
  text-transform: uppercase;
  font-size: 0.8rem;
  font-weight: 600;
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 1em;
}
.lightBoxOverlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: rgba(245, 237, 224, 0.9);
  z-index: 9999;
  padding: 1em;
  box-sizing: border-box;
}

.lightBoxOverlay figcaption {
  display: none;
}
.lightBoxOverlay .closeButton {
  position: absolute;
  top: 1em;
  right: 1em;
  background-color: #595a4f;
  color: #fff;
  font-size: 1.2rem;
  font-family: "Poppins", sans-serif;
  border: none;
  border-radius: 50%;
  width: 2em;
  height: 2em;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 10000;
  transition: background 0.3s ease;
}
.lightBoxOverlay .closeButton:hover {
  color: rgba(245, 237, 224);
  background-color: rgb(192, 184, 172);
}
@media (min-width: 80em) {
  .lightBoxOverlay .closeButton {
    font-size: 2em;
    top: 1em;
    right: 1em;
    height: 2em;
    width: 2em;
  }
}
.lightBoxOverlay .container-galeria {
  max-width: 90vw;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}
@media (min-width: 40em) {
  .lightBoxOverlay .container-galeria {
    padding: 3em;
  }
}
@media (min-width: 80em) {
  .lightBoxOverlay .container-galeria {
    padding: 5em;
  }
}
.lightBoxOverlay img {
  max-width: 100%;
  max-height: 80vh;
  height: auto;
  object-fit: contain;
  border-radius: 5px;
}
.lightBoxOverlay figcaption {
  margin-top: 1em;
  padding: 0.5em 1em;
  color: #fff;
  background: rgba(0, 0, 0, 0.8);
  border-radius: 5em;
}

@media (max-width: 600px) {
  .gallery {
    margin-bottom: var(--space-30);
  }

  .lightBoxOverlay .closeButton {
    top: 0.5em;
    right: 0.5em;
    width: 2.5em;
    height: 2.5em;
    font-size: 1.5rem;
  }
}
