/* Galeria do Produto — front */
.forte-gallery { --fg-accent: var( --lb-color-primary, #0a66e0 ); position: relative; }
.forte-gallery--bottom { display: flex; flex-direction: column; gap: .6rem; }
.forte-gallery--left, .forte-gallery--right { display: flex; gap: .6rem; align-items: flex-start; }
.forte-gallery--right { flex-direction: row-reverse; }

.forte-gallery__stage { position: relative; flex: 1; min-width: 0; }
.forte-gallery__viewport { position: relative; overflow: hidden; border-radius: 10px; background: #fafafa; }
.forte-gallery__track { display: flex; }
.forte-gallery__slide { position: relative; flex: 0 0 100%; min-width: 100%; }
.forte-gallery__img { display: block; width: 100%; height: auto; cursor: zoom-in; }
.forte-gallery.has-zoom .forte-gallery__img { transition: transform .15s ease; }

/* fade */
.forte-gallery.is-fade .forte-gallery__track { display: block; position: relative; }
.forte-gallery.is-fade .forte-gallery__slide { position: absolute; inset: 0; opacity: 0; transition: opacity .4s ease; }
.forte-gallery.is-fade .forte-gallery__slide.is-current { position: relative; opacity: 1; }

/* setas / ferramentas / dots */
.forte-gallery__nav { position: absolute; top: 50%; transform: translateY( -50% ); z-index: 3; width: 38px; height: 38px; border: 0; border-radius: 50%; background: rgba( 255, 255, 255, .9 ); box-shadow: 0 2px 8px rgba( 0, 0, 0, .15 ); cursor: pointer; font-size: 1.4rem; line-height: 1; color: #222; }
.forte-gallery__nav--prev { left: .5rem; } .forte-gallery__nav--next { right: .5rem; }
.forte-gallery__tools { position: absolute; top: .5rem; right: .5rem; z-index: 3; display: flex; gap: .35rem; }
.forte-gallery__tool { width: 34px; height: 34px; border: 0; border-radius: 8px; background: rgba( 255, 255, 255, .9 ); box-shadow: 0 2px 8px rgba( 0, 0, 0, .12 ); cursor: pointer; }
.forte-gallery__dots { display: none; gap: .35rem; justify-content: center; margin-top: .4rem; }
.forte-gallery__dot { width: 8px; height: 8px; border-radius: 50%; border: 0; background: #cfcfcf; cursor: pointer; padding: 0; }
.forte-gallery__dot.is-active { background: var( --fg-accent ); }

/* miniaturas */
.forte-gallery__thumbs { display: flex; gap: .4rem; list-style: none; margin: 0; padding: 0; overflow: auto; }
.forte-gallery--left .forte-gallery__thumbs, .forte-gallery--right .forte-gallery__thumbs { flex-direction: column; width: 72px; max-height: 520px; }
.forte-gallery__thumb button { position: relative; display: block; width: 64px; height: 64px; padding: 0; border: 2px solid transparent; border-radius: 8px; overflow: hidden; background: none; cursor: pointer; }
.forte-gallery__thumb.is-active button { border-color: var( --fg-accent ); }
.forte-gallery__thumb img { width: 100%; height: 100%; object-fit: cover; }

/* vídeo */
.forte-gallery__video { position: relative; display: block; width: 100%; border: 0; padding: 0; background: #000; cursor: pointer; }
.forte-gallery__video img { width: 100%; height: auto; display: block; opacity: .85; }
.forte-gallery__video iframe, .forte-gallery__video video { width: 100%; aspect-ratio: 16/9; display: block; border: 0; }
.forte-gallery__play, .forte-gallery__thumb-play { position: absolute; top: 50%; left: 50%; transform: translate( -50%, -50% ); width: 56px; height: 56px; border-radius: 50%; background: rgba( 0, 0, 0, .55 ); }
.forte-gallery__play::after, .forte-gallery__thumb-play::after { content: ""; position: absolute; top: 50%; left: 54%; transform: translate( -50%, -50% ); border-style: solid; border-width: 10px 0 10px 17px; border-color: transparent transparent transparent #fff; }
.forte-gallery__thumb-play { width: 22px; height: 22px; }
.forte-gallery__thumb-play::after { border-width: 5px 0 5px 8px; }
.forte-gallery__video.is-playing img, .forte-gallery__video.is-playing .forte-gallery__play { display: none; }

/* lightbox */
.forte-lightbox { position: fixed; inset: 0; z-index: 100000; background: rgba( 12, 12, 14, .94 ); display: flex; align-items: center; justify-content: center; }
.forte-lightbox__stage { max-width: 92vw; max-height: 88vh; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.forte-lightbox__img { max-width: 92vw; max-height: 88vh; object-fit: contain; cursor: zoom-in; transition: transform .2s ease; }
.forte-lightbox__img.is-zoomed { transform: scale( 2.4 ); cursor: zoom-out; }
.forte-lightbox__stage iframe, .forte-lightbox__stage video { width: min( 92vw, 1100px ); aspect-ratio: 16/9; border: 0; }
.forte-lightbox__close, .forte-lightbox__full, .forte-lightbox__nav { position: absolute; background: rgba( 255, 255, 255, .12 ); color: #fff; border: 0; cursor: pointer; border-radius: 8px; }
.forte-lightbox__close { top: 1rem; right: 1rem; width: 44px; height: 44px; font-size: 1.6rem; }
.forte-lightbox__full { top: 1rem; right: 4rem; width: 44px; height: 44px; }
.forte-lightbox__nav { top: 50%; transform: translateY( -50% ); width: 48px; height: 64px; font-size: 2rem; }
.forte-lightbox__prev { left: 1rem; } .forte-lightbox__next { right: 1rem; }
.forte-lightbox__counter { position: absolute; bottom: 1rem; left: 50%; transform: translateX( -50% ); color: #fff; font-size: .85rem; opacity: .8; }
body.forte-gallery-lock { overflow: hidden; }

@media ( max-width: 768px ) {
	.forte-gallery--left, .forte-gallery--right { flex-direction: column; }
	.forte-gallery--left .forte-gallery__thumbs, .forte-gallery--right .forte-gallery__thumbs { flex-direction: row; width: auto; max-height: none; }
	.forte-gallery__dots { display: flex; }
	.forte-gallery__thumbs { order: 2; }
}
