.card-content-custom {
  padding: 5px;
  border: #dee2e6 1px solid;
}

.card-square {
  width: 100%;
  padding-top: 100%;
  /* proporção 1:1 para manter o quadrado */
  position: relative;
  /* necessário para o posicionamento absoluto do conteúdo do card */
}

.card-content {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  right: 0;
}

.modal-body {
  position: relative;
  flex: 1 1 auto;
  padding: 3px;
  background-color: #ccc;
  height: 65vh;
}

.gallery-inner {
  background-color: #656565;
  height: 64.4vh;
}

.gallery-item {
  opacity: 0;
  transition: opacity 0.5s ease;
  display: none;
}

.gallery-item.active {
  opacity: 0;
  transition: opacity 0.5s ease;
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100%;
}

.gallery-image {
  height: 100%;
  width: initial;
}

.gallery-image img {
  height: 100%;
    width: initial;
}

/* Dispositivos móveis pequenos (menos de 576px) */
@media (max-width: 575.98px) {
  .modal {
    --bs-modal-margin: 0;
    border: 0;
    margin: 0;
    padding: 0;
  }

  .modal-header {
    display: none;
  }

  .modal-body {
    padding: 0;
    overflow-y: auto;
    height: 99.5vh;
  }

  .modal-dialog {
    max-width: 100%;
    margin-right: auto;
    margin-left: auto;
  }

  .modal-content {
    height: 100%;
    border-radius: 0;
  }

  .gallery-inner {

    vertical-align: middle;
    height: 99.5vh;
  }

  .gallery-image {
    height: initial;
    width: initial;
  }

  .gallery-image img {
    height: initial;
    width: initial;
  }
}

/* Dispositivos móveis médios (entre 576px e 767.98px) */
@media (min-width: 576px) and (max-width: 767.98px) {
  .modal {
    --bs-modal-margin: 0;
    border: 0;
    margin: 0;
    padding: 0;
  }

  .modal-header {
    display: none;
  }

  .modal-body {
    padding: 0;
    overflow-y: auto;
    height: 99.5vh;
  }

  .modal-dialog {
    max-width: 100%;
    margin-right: auto;
    margin-left: auto;
  }

  .modal-content {
    height: 100%;
    border-radius: 0;
  }

  .gallery-inner {

    vertical-align: middle;
    height: 99.5vh;
  }

  .gallery-image {
    height: initial;
    width: initial;
  }

  .gallery-image img {   
    width: initial;
  }
}

@media (min-width: 576px) and (max-width: 767.98px) and (max-height: 576px) {

  .gallery-image img {   
    width: initial;
    height: 99.5vh;
  }
}

/* Tablets (entre 768px e 991.98px) */
@media (min-width: 768px) and (max-width: 991.98px) {
  
  .modal {
    --bs-modal-margin: 0;
    border: 0;
    margin: 0;
    padding: 0;
  }

  .modal-header {
    display: none;
  }

  .modal-body {
    padding: 0;
    overflow-y: auto;
    height: 99.5vh;
  }

  .modal-dialog {
    max-width: 100%;
    margin-right: auto;
    margin-left: auto;
  }

  .modal-content {
    height: 100%;
    border-radius: 0;
  }

  .gallery-inner {

    vertical-align: middle;
    height: 99.5vh;
  }

  .gallery-image {
    height: initial;
    width: initial;
  }

  .gallery-image img {    
    width: initial;
  }
}

@media (min-width: 768px) and (max-width: 991.98px) and (max-height: 768px) {

  .gallery-image img {   
    width: initial;
    height: 99.5vh;
  }
}


.gallery-control-next-icon {
  background-image: url(../images/gallery/next.png);
}

.gallery-control-prev-icon {
  background-image: url(../images/gallery/prior.png);
}

.gallery-control-next-icon,
.gallery-control-prev-icon {
  display: inline-block;
  width: 2rem;
  height: 2rem;
  background-repeat: no-repeat;
  background-position: 50%;
  background-size: 50% 100%;
}

.gallery-control-prev {
  left: 0;
}

.gallery-control-next {
  right: 0;
}

.gallery-control-next,
.gallery-control-prev {
  position: absolute;
  top: 0;
  bottom: 0;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 15%;
  padding: 0;
  color: #fff;
  text-align: center;
  background: 0 0;
  border: 0;  
}

.gallery-btn-close {
  right: 10px;
  top: 10px;
  position: absolute;
  background: url(../images/gallery/close.png);
  width: 18px;
  height: 18px;
  background-size: 18px;
  background-repeat: no-repeat;
  border: 0;
  z-index: 2;
  padding: 60px 0px 0 60px;
  background-position: 20px 20px;
}