.sls-pm-gallery {
	display: flex;
	flex-direction: column;
	gap: 0.75rem;
	width: 100% !important;
	max-width: 100% !important;
	box-sizing: border-box;
}

.sls-pm-gallery.is-thumbs-side {
	flex-direction: row;
	align-items: flex-start;
	gap: 0.75rem;
}

.sls-pm-gallery.is-thumbs-side .sls-pm-gallery-thumbs {
	flex: 0 0 84px;
	width: 84px;
	flex-direction: column;
}

.sls-pm-gallery.is-thumbs-side .sls-pm-gallery-stage {
	flex: 1 1 280px;
	width: auto !important;
	min-width: 280px !important;
	max-width: calc(100% - 96px) !important;
}

.sls-pm-gallery.is-thumbs-bottom .sls-pm-gallery-stage {
	order: 1;
}

.sls-pm-gallery.is-thumbs-bottom .sls-pm-gallery-thumbs {
	order: 2;
	width: 100% !important;
}

.sls-pm-gallery-stage {
	position: relative;
	width: 100% !important;
	max-width: 100% !important;
	min-width: 0;
	overflow: visible;
	line-height: 0;
	box-sizing: border-box;
}

.sls-pm-gallery-frame {
	display: block !important;
	width: 100% !important;
	max-width: 100% !important;
	min-width: 0 !important;
	min-height: 200px;
	aspect-ratio: inherit;
	background-position: center center !important;
	background-repeat: no-repeat !important;
	background-size: contain !important;
}

.sls-pm-gallery-main,
.sls-pm-featured-image,
.sls-pm-gallery.is-empty img,
.sls-pm-single img.sls-pm-gallery-main,
.sls-pm-single img.sls-pm-featured-image,
.woocommerce div.product.sls-pm-single .sls-pm-gallery-main,
.woocommerce div.product.sls-pm-single img.sls-pm-featured-image,
.woocommerce .sls-pm-single-gallery img.sls-pm-gallery-main,
button.sls-pm-gallery-open img,
.sls-pm-gallery-open img {
	display: block !important;
	width: 100% !important;
	max-width: 100% !important;
	height: auto !important;
	min-width: 1px !important;
	min-height: 1px !important;
	max-height: none !important;
	opacity: 1 !important;
	visibility: visible !important;
	position: relative !important;
	clip: auto !important;
	clip-path: none !important;
	transform: none !important;
	filter: none !important;
	object-fit: contain !important;
	margin: 0 !important;
	padding: 0 !important;
	cursor: zoom-in;
	line-height: normal;
}

.sls-pm-gallery.is-zooming .sls-pm-gallery-main {
	transform: scale(1.8);
	cursor: zoom-in;
}

.sls-pm-gallery-thumbs {
	display: flex !important;
	flex-wrap: wrap;
	gap: 0.5rem;
	list-style: none;
	margin: 0;
	padding: 0;
	width: 100%;
	opacity: 1 !important;
	visibility: visible !important;
}

.sls-pm-gallery-thumbs li {
	display: block;
	flex: 0 0 auto;
}

.sls-pm-gallery-thumbs button,
.sls-pm-gallery-thumbs .sls-pm-gallery-thumb {
	display: block !important;
	width: 72px !important;
	height: 72px !important;
	min-width: 72px !important;
	min-height: 72px !important;
	padding: 0;
	border: 1px solid #d3ced2;
	background-color: #fff;
	background-size: cover !important;
	background-position: center !important;
	background-repeat: no-repeat !important;
	cursor: pointer;
	opacity: 1 !important;
	visibility: visible !important;
	overflow: hidden;
}

.sls-pm-gallery-thumbs button.is-active,
.sls-pm-gallery-thumbs button[aria-current="true"] {
	border-color: #7f54b3;
}

.sls-pm-gallery-thumbs img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.sls-pm-gallery-thumbs button:focus-visible,
.sls-pm-gallery-main:focus-visible,
.sls-pm-lightbox button:focus-visible {
	outline: 2px solid #fff;
	outline-offset: 2px;
}

.sls-pm-lightbox {
	position: fixed;
	inset: 0;
	z-index: 100000;
	background: rgba(0, 0, 0, 0.88);
	display: grid;
	place-items: center;
}

.sls-pm-lightbox[hidden] {
	display: none;
}

.sls-pm-lightbox-dialog {
	position: relative;
	width: min(1100px, calc(100% - 2rem));
	max-height: calc(100% - 2rem);
	display: grid;
	grid-template-columns: auto 1fr auto;
	align-items: center;
	gap: 0.5rem;
}

.sls-pm-lightbox img {
	max-width: 100%;
	max-height: calc(100vh - 4rem);
	margin: 0 auto;
	object-fit: contain;
}

.sls-pm-lightbox button {
	border: 0;
	background: transparent;
	color: #fff;
	font-size: 2rem;
	line-height: 1;
	min-width: 44px;
	min-height: 44px;
	cursor: pointer;
}

.sls-pm-lightbox-close {
	position: absolute;
	top: -0.25rem;
	right: 0;
}

@media (max-width: 782px) {
	.sls-pm-gallery.is-thumbs-side {
		flex-direction: column;
	}

	.sls-pm-gallery.is-thumbs-side .sls-pm-gallery-stage {
		min-width: 0 !important;
		max-width: 100% !important;
	}

	.sls-pm-gallery.is-thumbs-side .sls-pm-gallery-thumbs {
		flex-direction: row;
		width: 100%;
		flex: 1 1 auto;
	}
}

@media (prefers-reduced-motion: reduce) {
	.sls-pm-gallery.is-zooming .sls-pm-gallery-main {
		transform: none;
	}
}
