/* =====================================================
   Galerie produit unique — mobile first
   ===================================================== */

/* Mobile : colonne (image en haut, miniatures en bas) */
.wvc-gallery {
	display: flex;
	flex-direction: column;
	align-items: stretch;
	gap: 10px;
	width: 100%;
	flex-shrink: 0;
	align-self: flex-start;
	min-width: 0;
}

/* Desktop : ligne (miniatures a gauche, image a droite) */
@media (min-width: 992px) {
	.wvc-gallery {
		flex-direction: row;
		align-items: flex-start;
	}

	/* Layout cote a cote avec .summary */
	.wvc-container-active {
		display: flex !important;
		flex-wrap: wrap;
		align-items: flex-start;
		gap: 30px;
	}

	.wvc-container-active .wvc-gallery {
		width: calc((100% - 30px) / 2);
	}

	.wvc-container-active .wvc-summary-active {
		flex: 1;
		min-width: 280px;
	}
}

/* =====================================================
   Miniatures
   ===================================================== */

/* Mobile : rangee horizontale sous l'image */
.wvc-thumbs {
	order: 2;
	width: 100%;
	flex-shrink: 0;
}

.wvc-thumbs-container {
	display: flex;
	flex-direction: row;
	gap: 6px;
	overflow-x: auto;
	overflow-y: hidden;
	scrollbar-width: thin;
}

.wvc-thumb {
	width: 72px;
	height: 72px;
	border: 2px solid #ddd;
	border-radius: 2px;
	overflow: hidden;
	cursor: pointer;
	background: #111;
	flex-shrink: 0;
	transition: border-color 0.15s ease;
}

/* Desktop : colonne verticale a gauche */
@media (min-width: 992px) {
	.wvc-thumbs {
		order: 0;
		width: 100px;
	}

	.wvc-thumbs-container {
		flex-direction: column;
		overflow-x: hidden;
		overflow-y: auto;
	}

	.wvc-thumb {
		width: 100px;
		height: 100px;
	}
}

.wvc-thumb:hover {
	border-color: #888;
}

.wvc-thumb.active {
	border-color: #333;
}

.wvc-thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.wvc-thumb-video {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 100%;
	background: #222;
}

.wvc-thumb-video svg {
	width: 30px;
	height: 30px;
	opacity: 0.85;
}

/* =====================================================
   Zone principale
   ===================================================== */

.wvc-main-wrap {
	order: 1;
	flex: 1;
	min-width: 0;
	position: relative;
}

.wvc-main-display {
	width: 100%;
	background: transparent;
	overflow: hidden;
	position: relative;
	cursor: grab;
	user-select: none;
	transition: height 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.wvc-main-display:active {
	cursor: grabbing;
}

.wvc-main-display video,
.wvc-main-display a,
.wvc-main-display button {
	cursor: auto;
}

/* Track coulissant : flex row, transition CSS */
.wvc-slides-track {
	display: flex;
	flex-direction: row;
	align-items: flex-start;
	transform: translateX(0);
	transition: transform 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94);
	will-change: transform;
}

.wvc-main-item {
	flex-shrink: 0;
	width: 100%;
	height: 100%;
	position: relative;
}

.wvc-main-item video.wvc-video {
	display: block;
	width: 100%;
	height: auto;
	object-fit: contain;
	background: #000;
}

.wvc-image-link {
	display: block;
	line-height: 0;
}

.wvc-main-item img.wvc-image {
	display: block;
	width: 100%;
	height: auto;
	object-fit: contain;
}

/* Bouton fullscreen : bas droite de l'image */
.wvc-main-item .product-group-btns {
	position: absolute;
	bottom: 10px;
	right: 10px;
}

.wvc-main-item .photoswipe-toggle-button {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	background: rgba(255, 255, 255, 0.85);
	border: none;
	border-radius: 2px;
	cursor: pointer;
	padding: 0;
	transition: background 0.15s;
}

.wvc-main-item .photoswipe-toggle-button:hover {
	background: #fff;
}

/* =====================================================
   Fleches de navigation prev / next
   ===================================================== */

.wvc-main-wrap .flickity-prev-next-button {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	z-index: 10;
	width: 36px;
	height: 36px;
	background: rgba(255, 255, 255, 0.85);
	border: none;
	border-radius: 50%;
	cursor: pointer;
	padding: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: background 0.15s;
}

.wvc-main-wrap .flickity-prev-next-button:hover {
	background: #fff;
}

.wvc-main-wrap .flickity-prev-next-button.previous {
	left: 10px;
}

.wvc-main-wrap .flickity-prev-next-button.next {
	right: 10px;
}

/* =====================================================
   PhotoSwipe — Bandeau de miniatures
   ===================================================== */

/* Desktop >= 992px : bandeau vertical a GAUCHE de l'image */
.pswp.wvc-pswp-desktop-thumbs .pswp__thumbnails {
	position: absolute;
	top: 0;
	left: 0;
	bottom: 0;
	width: 110px;
	z-index: 1600;
	display: flex;
	flex-direction: column;
	gap: 5px;
	overflow-y: auto;
	overflow-x: hidden;
	padding: 10px 6px;
	scrollbar-width: thin;
}

/* Decale le viewer principal pour liberer la place du bandeau */
.pswp.wvc-pswp-desktop-thumbs .pswp__scroll-wrap {
	left: 110px !important;
	width: calc(100% - 110px) !important;
}

/* La fleche gauche ne doit pas deborder sur le bandeau */
.pswp.wvc-pswp-desktop-thumbs .pswp__button--arrow--left {
	left: 0 !important;
}

/* Mobile < 992px : bandeau horizontal EN BAS de l'image */
.pswp.wvc-pswp-mobile-thumbs .pswp__thumbnails {
	position: absolute;
	bottom: 0;
	left: 0;
	right: 0;
	height: 88px;
	z-index: 1600;
	background: rgba(0, 0, 0, 0.75);
	display: flex;
	flex-direction: row;
	gap: 5px;
	overflow-x: auto;
	overflow-y: hidden;
	padding: 6px 10px;
	scrollbar-width: thin;
}

/* Decale le viewer pour liberer la place du bandeau en bas */
.pswp.wvc-pswp-mobile-thumbs .pswp__scroll-wrap {
	height: calc(100% - 88px) !important;
}

/* Miniatures communes */
.pswp__thumbnails .thumbnail-item {
	flex-shrink: 0;
	width: 72px;
	height: 72px;
	cursor: pointer;
	opacity: 0.5;
	border: 2px solid transparent;
	border-radius: 2px;
	overflow: hidden;
	transition: opacity 0.2s ease;
}

.pswp__thumbnails .thumbnail-item:hover {
	opacity: 0.8;
}

.pswp__thumbnails .thumbnail-item.active {
	opacity: 1;
	border-color: #fff;
}

.pswp__thumbnails .thumbnail-item img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

/* =====================================================
   Miniature boucle produits (boutique / categories)
   ===================================================== */

.wvc-loop-video {
	display: block;
	width: 100%;
	height: auto;
	aspect-ratio: 3 / 4;
	object-fit: cover;
	border-radius: 4px;
	background: #000;
}