/* Neteuro Product Gallery */
/* —— Gallery —— */
.nww-product-gallery {
	display: grid;
	gap: var(--nww-gap, 12px);
	width: 100%;
}

.nww-product-gallery--thumbs {
	grid-template-columns: 1fr;
}

/* Thumb position via Elementor's prefix_class: nww-thumbs-pos-left etc. */
.nww-thumbs-pos-left .nww-product-gallery--thumbs,
.nww-thumbs-pos-right .nww-product-gallery--thumbs {
	grid-template-columns: auto 1fr;
	align-items: start;
}

.nww-thumbs-pos-left .nww-product-gallery__thumbnails {
	order: 0;
	flex-direction: column;
}

.nww-thumbs-pos-left .nww-product-gallery__stage {
	order: 1;
}

.nww-thumbs-pos-right .nww-product-gallery__thumbnails {
	order: 1;
	flex-direction: column;
}

.nww-thumbs-pos-right .nww-product-gallery__stage {
	order: 0;
}

.nww-thumbs-pos-top .nww-product-gallery__thumbnails {
	order: 0;
}

.nww-thumbs-pos-top .nww-product-gallery__stage {
	order: 1;
}

.nww-thumbs-pos-bottom .nww-product-gallery__thumbnails {
	order: 1;
}

.nww-thumbs-pos-bottom .nww-product-gallery__stage {
	order: 0;
}

.nww-product-gallery__thumbnails {
	display: flex;
	flex-wrap: wrap;
	gap: var(--nww-gap, 8px);
}

.nww-product-gallery__stage {
	position: relative;
	min-width: 0;
}

.nww-product-gallery__main-img,
.nww-product-gallery__slide-img {
	display: block;
	width: 100%;
	height: auto;
	transition: transform 0.3s ease;
}

.nww-product-gallery__main-link,
.nww-product-gallery__slide-link {
	display: block;
	overflow: hidden;
}

.nww-product-gallery__thumb {
	display: block;
	padding: 0;
	margin: 0;
	border: 2px solid transparent;
	background: transparent;
	cursor: pointer;
	overflow: hidden;
	line-height: 0;
	transition: opacity 0.2s ease, border-color 0.2s ease;
}

.nww-product-gallery__thumb img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.nww-product-gallery__thumb.is-active,
.nww-product-gallery__thumb[aria-current="true"] {
	border-color: currentColor;
}

.nww-product-gallery__thumb:focus-visible {
	outline: 2px solid currentColor;
	outline-offset: 2px;
}

.nww-product-gallery__nav {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	z-index: 2;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 40px;
	border: 0;
	background: rgba(255, 255, 255, 0.9);
	cursor: pointer;
	line-height: 1;
}

.nww-product-gallery__nav:focus-visible {
	outline: 2px solid currentColor;
	outline-offset: 2px;
}

.nww-product-gallery__nav--prev {
	inset-inline-start: 8px;
}

.nww-product-gallery__nav--next {
	inset-inline-end: 8px;
}

.nww-product-gallery--single .nww-product-gallery__nav,
.nww-product-gallery--single .swiper-button-prev,
.nww-product-gallery--single .swiper-button-next,
.nww-product-gallery--single .swiper-pagination {
	display: none;
}

/* Hover zoom only on fine pointers — avoid sticky scale on touch. */
@media (hover: hover) and (pointer: fine) {
	.nww-product-gallery--zoom .nww-product-gallery__main-link:hover .nww-product-gallery__main-img,
	.nww-product-gallery--zoom .nww-product-gallery__slide-link:hover .nww-product-gallery__slide-img {
		transform: scale(1.04);
	}
}

.nww-product-gallery__dots {
	display: flex;
	justify-content: center;
	gap: 6px;
	margin-top: 10px;
}

.nww-product-gallery__dot {
	width: 8px;
	height: 8px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: #c3c4c7;
	cursor: pointer;
}

.nww-product-gallery__dot.is-active {
	background: #1d2327;
}

.nww-product-gallery__fraction {
	text-align: center;
	margin-top: 8px;
}

.nww-product-gallery__caption {
	margin-top: 8px;
}

.nww-product-gallery__grid {
	display: grid;
	gap: var(--nww-gap, 12px);
}

.nww-product-gallery__empty {
	padding: 24px;
	text-align: center;
	border: 1px dashed #c3c4c7;
}

.nww-gallery-sticky-yes .nww-product-gallery {
	position: sticky;
}

.nww-is-variation-image .nww-product-gallery__main-img {
	box-shadow: 0 0 0 2px rgba(34, 113, 177, 0.35);
}

@media (max-width: 1024px) {
	.nww-no-sticky-tablet-yes .nww-product-gallery {
		position: static;
	}

	.nww-thumbs-pos-tablet-bottom .nww-product-gallery--thumbs,
	.nww-thumbs-pos-tablet-top .nww-product-gallery--thumbs {
		grid-template-columns: 1fr;
	}
}

@media (max-width: 767px) {
	.nww-no-sticky-mobile-yes .nww-product-gallery {
		position: static;
	}

	.nww-thumbs-pos-mobile-bottom .nww-product-gallery--thumbs,
	.nww-thumbs-pos-mobile-top .nww-product-gallery--thumbs,
	.nww-thumbs-pos-mobile-left .nww-product-gallery--thumbs,
	.nww-thumbs-pos-mobile-right .nww-product-gallery--thumbs {
		grid-template-columns: 1fr;
	}

	.nww-thumbs-pos-mobile-left .nww-product-gallery__thumbnails,
	.nww-thumbs-pos-mobile-right .nww-product-gallery__thumbnails {
		flex-direction: row;
	}
}

@media (prefers-reduced-motion: reduce) {
	.nww-product-gallery__main-img,
	.nww-product-gallery__slide-img,
	.nww-product-gallery__thumb {
		transition: none;
	}
}
