/* Woo Product Media Gallery block + image lightbox (videos stay inline, no popup) */
body.single {
	overflow-y: auto;
    overflow-x: hidden;
}
.td-product-media-gallery {
	margin: 0 0 1.5em;
}

.td-product-media-gallery__grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 16px;
	align-items: start;
}

.td-product-media-gallery__cell {
	background: #fff;
	border: 1px solid #e8e8e8;
	box-sizing: border-box;
	overflow: hidden;
	line-height: 0;
}

/* Clickable image thumbnail */
.td-product-media-gallery__open {
	appearance: none;
	border: 0;
	padding: 0;
	margin: 0;
	background: transparent;
	display: block;
	width: 100%;
	cursor: zoom-in;
	text-align: left;
	font: inherit;
	color: inherit;
}

.td-product-media-gallery__open:focus-visible {
	outline: 2px solid #333;
	outline-offset: 2px;
}

.td-product-media-gallery__cell img {
	display: block;
	width: 100%;
	height: auto;
	object-fit: contain;
	vertical-align: top;
}

.td-product-media-gallery__cell--video video {
	display: block;
	width: 100%;
	height: auto;
	background: #fafafa;
}

@media (max-width: 600px) {
	.td-product-media-gallery__grid {
		grid-template-columns: 1fr;
		gap: 12px;
	}
}

/* ---------- Lightbox ---------- */

body.td-pmg-lightbox-open {
	overflow: hidden;
}

.td-pmg-lightbox {
	position: fixed;
	inset: 0;
	z-index: 100000;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 16px;
	box-sizing: border-box;
}

.td-pmg-lightbox[hidden] {
	display: none;
}

.td-pmg-lightbox__backdrop {
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.88);
	cursor: pointer;
}

.td-pmg-lightbox__inner {
	position: relative;
	z-index: 1;
	display: flex;
	align-items: center;
	justify-content: center;
	max-width: min(96vw, 1400px);
	max-height: 92vh;
	width: 100%;
	height: 100%;
	pointer-events: none;
}

.td-pmg-lightbox__inner > * {
	pointer-events: auto;
}

.td-pmg-lightbox__img {
	display: block;
	max-width: 100%;
	max-height: 85vh;
	width: auto;
	height: auto;
	object-fit: contain;
	margin: 0 auto;
	user-select: none;
	-webkit-user-drag: none;
}

.td-pmg-lightbox__close,
.td-pmg-lightbox__prev,
.td-pmg-lightbox__next {
	position: absolute;
	z-index: 2;
	border: 0;
	margin: 0;
	cursor: pointer;
	background: rgba(255, 255, 255, 0.12);
	color: #fff;
	border-radius: 4px;
	line-height: 1;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: background 0.15s ease;
}

.td-pmg-lightbox__close:hover,
.td-pmg-lightbox__prev:hover,
.td-pmg-lightbox__next:hover,
.td-pmg-lightbox__close:focus-visible,
.td-pmg-lightbox__prev:focus-visible,
.td-pmg-lightbox__next:focus-visible {
	background: rgba(255, 255, 255, 0.28);
}

.td-pmg-lightbox__close {
	top: 8px;
	right: 8px;
	width: 44px;
	height: 44px;
	font-size: 28px;
	font-weight: 300;
}

.td-pmg-lightbox__prev,
.td-pmg-lightbox__next {
	top: 50%;
	transform: translateY(-50%);
	width: 48px;
	height: 48px;
	font-size: 22px;
}

.td-pmg-lightbox__prev {
	left: 8px;
}

.td-pmg-lightbox__next {
	right: 8px;
}

.td-pmg-lightbox__prev[hidden],
.td-pmg-lightbox__next[hidden] {
	display: none;
}

.td-pmg-lightbox__counter {
	position: absolute;
	bottom: 12px;
	left: 50%;
	transform: translateX(-50%);
	color: #ddd;
	font-size: 14px;
	letter-spacing: 0.02em;
	pointer-events: none;
}

@media (max-width: 480px) {
	.td-pmg-lightbox__prev,
	.td-pmg-lightbox__next {
		width: 40px;
		height: 40px;
		font-size: 18px;
	}
}



/* Step 1: Fix the theme wrapper that breaks sticky */
#td-outer-wrap,
.td-theme-wrap {
  overflow: visible !important;
}

/* Step 2: Remove float from columns inside your flex row */
.tdi_57 .wpb_column {
  float: none !important;
}

#tdi_78 {
	overflow: hidden !important;
}

/* Step 3: Make the RIGHT column (tdi_62) sticky */
.tdi_62 {
  position: sticky !important;
  top: 120px !important;        /* matches your .tdi_57 margin-top */
  align-self: flex-start !important;
  height: fit-content !important;
}

/* Step 4: Do NOT make the left gallery sticky */
.tdi_59 {
  position: relative !important;
  align-self: flex-start !important;
}