.toquetec-post-gallery{
  width:100%;
  margin:0 0 1.5em 0;
}

.toquetec-post-gallery__media img{
  /* Força a imagem ficar grande no slide (evita que venha com largura fixa do WP). */
  width:100% !important;
  max-width: 820px;
  max-height: 40rem;
  object-fit: contain;
  margin: 0 auto;
}

/* Esconde fatias dos slides vizinhos (overflow:visible deixava ver lateral). */
.toquetec-post-gallery .splide__track {
  overflow: hidden;
}

.toquetec-post-gallery__slide{
  display:flex;
  flex-direction:column;
  align-items:center;
  text-align:center;
}

.toquetec-post-gallery__media{
  width:100%;
  display:flex;
  align-items:center;
  justify-content:center;
}

.toquetec-post-gallery__media a.toquetec-post-gallery__link{
  display:flex;
  width:100%;
  max-width:820px;
  align-items:center;
  justify-content:center;
  cursor:pointer;
}

.toquetec-post-gallery__media img{
  /* Mantém borda arredondada e layout */
  height:auto;
  border-radius:5px;
  display:block;
}

.toquetec-post-gallery__caption{
  margin-top:24px;
  font-family:'Hind', sans-serif;
  font-weight:400;
  font-size:16px;
  line-height:22px;
  color:#000;
}

/* Modal / Lightbox */
.toquetec-gallery-modal{
  position:fixed;
  inset:0;
  z-index:99999;
  opacity:0;
  pointer-events:none;
  transition:opacity .2s ease;
}

.toquetec-gallery-modal.is-open{
  opacity:1;
  pointer-events:auto;
}

.toquetec-gallery-modal__backdrop{
  position:absolute;
  inset:0;
  background:rgba(0,0,0,.85);
  z-index:0;
}

.toquetec-gallery-modal__content{
  position:relative;
  width:min(1100px, calc(100% - 32px));
  margin:20px auto;
  height:calc(100% - 40px);
  display:flex;
  align-items:center;
  z-index:1;
}

.toquetec-gallery-modal__close{
  position:absolute;
  top:10px;
  right:10px;
  width:40px;
  height:40px;
  border-radius:50%;
  background:rgba(0,0,0,.6);
  color:#fff;
  font-size:28px;
  line-height:40px;
  text-align:center;
  cursor:pointer;
  z-index:2;
}

.toquetec-gallery-modal__splide{
  width:100%;
}

.toquetec-gallery-modal__figure{
  margin:0;
  width:100%;
  display:flex;
  flex-direction:column;
  align-items:center;
}

.toquetec-gallery-modal__figure img{
  max-height:calc(100vh - 160px);
  width:auto;
  max-width:100%;
  height:auto;
  border-radius:8px;
  display:block;
}

.toquetec-gallery-modal__caption{
  margin-top:12px;
  color:#fff;
  font-family:'Hind', sans-serif;
  font-weight:400;
  font-size:14px;
  line-height:20px;
  text-align:center;
}

body.toquetec-gallery-modal-open{
  overflow:hidden;
}

/* Pagination do Splide dentro do carrossel do post */
.toquetec-post-gallery .splide__pagination {
  bottom: -3.5em;
  left: 0;
  padding: 0 1em;
  position: absolute;
  right: 0;
  z-index: 1;
}

.toquetec-post-gallery .splide__pagination__page.is-active {
  background: #196aa9;
  transform: scale(1.4);
  z-index: 1;
}

/* Ajuste de posição das setas */
.toquetec-post-gallery .splide__arrow--next {
  right: 6em;
}

.toquetec-post-gallery .splide__arrow--prev {
  left: 4em;
}

/* Mobile: remove setas de navegação */
@media (max-width: 768px) {
  .toquetec-post-gallery .splide__arrow {
    display: none !important;
  }
}

