.gallery-container {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  margin: 0 auto;
  background-color: rgba(0, 0, 0, 0.85);
  padding: 2rem 1rem 2rem 1rem;
  display: flex;
  justify-content: center;
  align-items: center;
  transform: scale(0);
  opacity: 0;
  z-index: 10000;
  transition: 0.6s all;
}

.gallery-container.active {
  opacity: 1;
  transform: scale(1) !important;
}

.gallery-container *{
    box-sizing: border-box;
}

.gallery-grid div{
  margin-top: -20px;
  margin-bottom: -20px;
}

.gallery-grid div img{
  float: left;
  width: 100%;
  height: 320px;
  object-fit: contain;
  max-width: none;
  cursor: pointer;
  border: 2px solid var(--color-text);
  background-color: #000;
}

  /* Hide the images by default */
.gallery-slide {
    display: none;
    width: 100%;
}

.gallery-slide img{
  max-height: 90vh !important;
  width: auto !important;
  max-width: 80% !important;
  margin: 0 auto;
  display: block;
  border: 2px solid var(--color-text);
}
  
  /* Add a pointer when hovering over the thumbnail images */
.cursor {
    cursor: pointer;
}
  
  /* Next & previous buttons */
.prev,
.next {
    cursor: pointer;
    position: absolute;
    top: 50%;
    width: auto;
    padding: 16px;
    margin-top: -50px;
    color: white !important;
    font-weight: bold;
    font-size: 20px;
    border-radius: 0 3px 3px 0;
    user-select: none;
    -webkit-user-select: none;
}
/* Position the "prev button" to the right */
.prev{ left: 0; }
/* Position the "next button" to the right */
.next { right: 0; }
  
  /* On hover, add a black background color with a little bit see-through */
.prev:hover,
.next:hover {
    background-color: rgba(0, 0, 0, 0.8);
}
  
  /* Number text (1/3 etc) */
.numbertext {
  color: #f2f2f2;
  font-size: 12px;
  padding: 8px 12px;
  position: absolute;
  top: 12px;
  left: 18px;
}
  

.btn-close-gallery-modal
{
  position: absolute;
  top: 12px;
  right: 18px;
  font-size: 32px;
  color: #f2f2f2;
  cursor: pointer;
}

  /* Container for image text */
.caption-container {
    text-align: center;
    padding: 12px 16px;
    color: white;
    width: 100%;
    font-weight: bold;
    min-height: 48px;
}

.caption-container p{
    margin: 0 !important;
    padding: 0 !important;
}

@media (max-width: 576px) {
  .gallery-grid img{ height: 240px; }
  .gallery-container { width: 100% !important; }
}