.irannet-sp-gallery {
	--irannet-sp-gallery-main-height: 560px;
	--irannet-sp-gallery-gap: 12px;
	--irannet-sp-gallery-thumb-size: 84px;
	--irannet-sp-gallery-thumbs-visible: 6;
	--irannet-sp-gallery-arrow-size: 46px;
	--irannet-sp-gallery-zoom: 1.35;
	position: relative;
	display: grid;
	width: 100%;
	max-width: 100%;
	gap: var(--irannet-sp-gallery-gap);
	box-sizing: border-box;
	isolation: isolate;
}

.irannet-sp-gallery *,
.irannet-sp-gallery *::before,
.irannet-sp-gallery *::after {
	box-sizing: border-box;
}

.irannet-sp-gallery__notice {
	padding: 16px 18px;
	border: 1px dashed color-mix(in srgb, var(--irannet-sp-gallery-global-secondary) 45%, transparent);
	border-radius: 12px;
	background: color-mix(in srgb, var(--irannet-sp-gallery-global-secondary) 7%, transparent);
	color: var(--irannet-sp-gallery-global-text);
	font-size: 13px;
	line-height: 1.9;
}

.irannet-sp-gallery__main,
.irannet-sp-gallery__viewport,
.irannet-sp-gallery__track,
.irannet-sp-gallery__slide,
.irannet-sp-gallery__image-action {
	min-width: 0;
}

.irannet-sp-gallery__main {
	grid-area: main;
	position: relative;
}

.irannet-sp-gallery__viewport {
	position: relative;
	height: var(--irannet-sp-gallery-main-height);
	overflow: hidden;
	outline: none;
	isolation: isolate;
}


/* Intrinsic image mode: the active product image drives the viewport ratio. */
.irannet-sp-gallery--height-auto .irannet-sp-gallery__viewport {
	height: auto;
	aspect-ratio: var(--irannet-sp-gallery-active-ratio, 1 / 1);
	transition: aspect-ratio .22s ease;
}

.irannet-sp-gallery--height-auto .irannet-sp-gallery__track,
.irannet-sp-gallery--height-auto .irannet-sp-gallery__slide,
.irannet-sp-gallery--height-auto .irannet-sp-gallery__image-action {
	height: 100%;
}

.irannet-sp-gallery__viewport:focus-visible {
	box-shadow: 0 0 0 3px color-mix(in srgb, var(--irannet-sp-gallery-global-primary) 22%, transparent);
}

.irannet-sp-gallery__track {
	display: flex;
	height: 100%;
	direction: ltr;
	transform: translate3d(0, 0, 0);
	transition: transform var(--irannet-sp-gallery-speed, 420ms) cubic-bezier(.22, .75, .25, 1);
	will-change: transform;
}

.irannet-sp-gallery__slide {
	position: relative;
	flex: 0 0 100%;
	width: 100%;
	height: 100%;
	margin: 0;
	overflow: hidden;
	background: transparent;
}

.irannet-sp-gallery__image-action {
	display: block;
	width: 100%;
	height: 100%;
	padding: 0;
	margin: 0;
	border: 0;
	background: transparent;
	color: inherit;
	text-decoration: none;
	cursor: zoom-in;
	overflow: hidden;
}

.irannet-sp-gallery[data-settings*='"action":"none"'] .irannet-sp-gallery__image-action {
	cursor: default;
}

.irannet-sp-gallery[data-settings*='"action":"product"'] .irannet-sp-gallery__image-action,
.irannet-sp-gallery[data-settings*='"action":"full"'] .irannet-sp-gallery__image-action {
	cursor: pointer;
}

.irannet-sp-gallery .irannet-sp-gallery__image {
	display: block;
	width: 100% !important;
	height: 100% !important;
	max-width: none;
	max-height: none;
	margin: 0;
	transition: transform .55s cubic-bezier(.2, .7, .2, 1), opacity .3s ease;
	transform-origin: var(--irannet-sp-gallery-zoom-x, 50%) var(--irannet-sp-gallery-zoom-y, 50%);
	user-select: none;
	-webkit-user-drag: none;
}

/*
 * WooCommerce and many product themes apply `height:auto` to images inside
 * `.woocommerce div.product`. In a fixed-height gallery frame that rule makes
 * object-fit ineffective and the viewport's overflow then visually crops the
 * image. Keep an explicit image box equal to the gallery frame so Contain,
 * Cover and object-position work predictably.
 */
.irannet-sp-gallery.irannet-sp-gallery--fit-contain .irannet-sp-gallery__image {
	object-fit: contain !important;
}

.irannet-sp-gallery.irannet-sp-gallery--fit-cover .irannet-sp-gallery__image {
	object-fit: cover !important;
}

.irannet-sp-gallery--zoom-hover .irannet-sp-gallery__slide.is-active .irannet-sp-gallery__image-action:hover .irannet-sp-gallery__image,
.irannet-sp-gallery--zoom-follow .irannet-sp-gallery__slide.is-active .irannet-sp-gallery__image-action:hover .irannet-sp-gallery__image {
	transform: scale(var(--irannet-sp-gallery-zoom));
}

.irannet-sp-gallery--transition-fade .irannet-sp-gallery__track {
	position: relative;
	display: block;
	transform: none !important;
}

.irannet-sp-gallery--transition-fade .irannet-sp-gallery__slide {
	position: absolute;
	inset: 0;
	opacity: 0;
	visibility: hidden;
	pointer-events: none;
	transition: opacity var(--irannet-sp-gallery-speed, 420ms) ease, visibility var(--irannet-sp-gallery-speed, 420ms) ease;
}

.irannet-sp-gallery--transition-fade .irannet-sp-gallery__slide.is-active {
	opacity: 1;
	visibility: visible;
	pointer-events: auto;
}

.irannet-sp-gallery__arrow {
	position: absolute;
	top: 50%;
	z-index: 7;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: var(--irannet-sp-gallery-arrow-size);
	height: var(--irannet-sp-gallery-arrow-size);
	padding: 0;
	border: 1px solid color-mix(in srgb, var(--irannet-sp-gallery-global-secondary) 35%, transparent);
	border-radius: 999px;
	box-shadow: 0 8px 24px color-mix(in srgb, var(--irannet-sp-gallery-global-text) 12%, transparent);
	transform: translateY(-50%);
	cursor: pointer;
	transition: transform .2s ease, color .2s ease, background-color .2s ease, opacity .2s ease;
}

.irannet-sp-gallery__arrow:hover {
	transform: translateY(-50%) scale(1.06);
}

.irannet-sp-gallery__arrow:focus-visible {
	outline: 3px solid color-mix(in srgb, var(--irannet-sp-gallery-global-primary) 25%, transparent);
	outline-offset: 2px;
}

.irannet-sp-gallery__arrow:disabled {
	opacity: .35;
	cursor: not-allowed;
}

.irannet-sp-gallery__arrow svg,
.irannet-sp-gallery__arrow i {
	display: block;
	width: 1em;
	height: 1em;
	font-size: inherit;
}

.irannet-sp-gallery__arrow--previous {
	right: 14px;
}

.irannet-sp-gallery__arrow--next {
	left: 14px;
}

.irannet-sp-gallery:dir(ltr) .irannet-sp-gallery__arrow--previous {
	right: auto;
	left: 14px;
}

.irannet-sp-gallery:dir(ltr) .irannet-sp-gallery__arrow--next {
	left: auto;
	right: 14px;
}

.irannet-sp-gallery__counter {
	position: absolute;
	right: 14px;
	bottom: 14px;
	z-index: 7;
	display: inline-flex;
	align-items: center;
	gap: 5px;
	min-width: 52px;
	padding: 7px 11px;
	border-radius: 999px;
	font-size: 12px;
	font-variant-numeric: tabular-nums;
	line-height: 1;
	backdrop-filter: blur(8px);
}

.irannet-sp-gallery:dir(ltr) .irannet-sp-gallery__counter {
	right: auto;
	left: 14px;
}

.irannet-sp-gallery__dots {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 7px;
	padding-top: 12px;
}

.irannet-sp-gallery__dot {
	width: 8px;
	height: 8px;
	padding: 0;
	border: 0;
	border-radius: 999px;
	cursor: pointer;
	transition: width .2s ease, transform .2s ease, background-color .2s ease;
}

.irannet-sp-gallery__dot.is-active {
	width: 24px;
}

.irannet-sp-gallery__thumbs {
	grid-area: thumbs;
	display: flex;
	gap: var(--irannet-sp-gallery-gap);
	overflow: auto;
	scroll-snap-type: both proximity;
	scrollbar-width: none;
	overscroll-behavior: contain;
}

.irannet-sp-gallery__thumbs::-webkit-scrollbar {
	display: none;
}

.irannet-sp-gallery__thumb {
	position: relative;
	flex: 0 0 var(--irannet-sp-gallery-thumb-size);
	width: var(--irannet-sp-gallery-thumb-size);
	height: var(--irannet-sp-gallery-thumb-size);
	padding: 3px;
	border: 1px solid color-mix(in srgb, var(--irannet-sp-gallery-global-secondary) 24%, transparent);
	overflow: hidden;
	cursor: pointer;
	scroll-snap-align: start;
	opacity: .74;
	transition: opacity .2s ease, transform .2s ease, border-color .2s ease, box-shadow .2s ease;
}

.irannet-sp-gallery__thumb:hover,
.irannet-sp-gallery__thumb.is-active {
	opacity: 1;
	transform: translateY(-1px);
}

.irannet-sp-gallery__thumb:focus-visible {
	outline: 3px solid color-mix(in srgb, var(--irannet-sp-gallery-global-primary) 20%, transparent);
	outline-offset: 2px;
}

.irannet-sp-gallery__thumb img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	border-radius: inherit;
	user-select: none;
	-webkit-user-drag: none;
}

/* Ready-made frames */
.irannet-sp-gallery--style-clean {
	background: transparent;
}

.irannet-sp-gallery--style-card {
	padding: 14px;
	border: 1px solid color-mix(in srgb, var(--irannet-sp-gallery-global-secondary) 24%, transparent);
	border-radius: 22px;
	background: color-mix(in srgb, var(--irannet-sp-gallery-global-secondary) 5%, transparent);
}

.irannet-sp-gallery--style-floating {
	padding: 16px;
	border: 1px solid color-mix(in srgb, var(--irannet-sp-gallery-global-secondary) 22%, transparent);
	border-radius: 26px;
	background: color-mix(in srgb, var(--irannet-sp-gallery-global-secondary) 5%, transparent);
	box-shadow: 0 24px 60px color-mix(in srgb, var(--irannet-sp-gallery-global-text) 12%, transparent);
}

.irannet-sp-gallery--style-glass {
	padding: 14px;
	border: 1px solid color-mix(in srgb, var(--irannet-sp-gallery-global-secondary) 28%, transparent);
	border-radius: 24px;
	background: color-mix(in srgb, var(--irannet-sp-gallery-global-secondary) 10%, transparent);
	box-shadow: 0 18px 50px color-mix(in srgb, var(--irannet-sp-gallery-global-text) 12%, transparent);
	backdrop-filter: blur(16px);
}

.irannet-sp-gallery--style-accent {
	padding: 14px;
	border: 1px solid color-mix(in srgb, var(--irannet-sp-gallery-global-secondary) 24%, transparent);
	border-top: 4px solid var(--irannet-sp-gallery-global-accent);
	border-radius: 20px;
	background: color-mix(in srgb, var(--irannet-sp-gallery-global-secondary) 5%, transparent);
}

.irannet-sp-gallery--style-cinematic {
	padding: 14px;
	border: 1px solid rgba(148, 163, 184, .22);
	border-radius: 22px;
	background: color-mix(in srgb, var(--irannet-sp-gallery-global-text) 92%, #000);
	box-shadow: 0 24px 70px rgba(2, 6, 23, .28);
}

.irannet-sp-gallery--style-cinematic .irannet-sp-gallery__viewport,
.irannet-sp-gallery--style-cinematic .irannet-sp-gallery__thumb {
	background: color-mix(in srgb, var(--irannet-sp-gallery-global-text) 97%, #000);
}

.irannet-sp-gallery--style-cinematic .irannet-sp-gallery__thumb {
	border-color: color-mix(in srgb, var(--irannet-sp-gallery-global-secondary) 35%, transparent);
}

/* Desktop layouts */
@media (min-width: 1025px) {
	.irannet-sp-gallery--desktop-thumbs-bottom {
		grid-template-areas: "main" "thumbs";
		grid-template-columns: minmax(0, 1fr);
	}

	.irannet-sp-gallery--desktop-thumbs-top {
		grid-template-areas: "thumbs" "main";
		grid-template-columns: minmax(0, 1fr);
	}

	.irannet-sp-gallery--desktop-thumbs-left {
		grid-template-areas: "thumbs main";
		grid-template-columns: var(--irannet-sp-gallery-thumb-size) minmax(0, 1fr);
		align-items: start;
	}

	.irannet-sp-gallery--desktop-thumbs-right {
		grid-template-areas: "main thumbs";
		grid-template-columns: minmax(0, 1fr) var(--irannet-sp-gallery-thumb-size);
		align-items: start;
	}

	.irannet-sp-gallery--desktop-thumbs-left .irannet-sp-gallery__thumbs,
	.irannet-sp-gallery--desktop-thumbs-right .irannet-sp-gallery__thumbs {
		flex-direction: column;
		max-height: var(--irannet-sp-gallery-main-height);
		overflow-x: hidden;
		overflow-y: auto;
	}

	.irannet-sp-gallery--desktop-mosaic,
	.irannet-sp-gallery--desktop-stacked {
		display: block;
	}

	.irannet-sp-gallery--desktop-mosaic .irannet-sp-gallery__viewport,
	.irannet-sp-gallery--desktop-stacked .irannet-sp-gallery__viewport {
		height: auto;
		overflow: visible;
		background: transparent;
	}

	.irannet-sp-gallery--desktop-mosaic .irannet-sp-gallery__track {
		display: grid;
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: var(--irannet-sp-gallery-gap);
		transform: none !important;
	}

	.irannet-sp-gallery--desktop-mosaic .irannet-sp-gallery__slide {
		display: block;
		height: calc(var(--irannet-sp-gallery-main-height) / 2);
		opacity: 1 !important;
		visibility: visible !important;
		pointer-events: auto !important;
	}

	.irannet-sp-gallery--desktop-mosaic .irannet-sp-gallery__slide:first-child {
		grid-row: span 2;
		height: var(--irannet-sp-gallery-main-height);
	}

	.irannet-sp-gallery--desktop-stacked .irannet-sp-gallery__track {
		display: grid;
		gap: var(--irannet-sp-gallery-gap);
		transform: none !important;
	}

	.irannet-sp-gallery--desktop-stacked .irannet-sp-gallery__slide {
		display: block;
		height: var(--irannet-sp-gallery-main-height);
		opacity: 1 !important;
		visibility: visible !important;
		pointer-events: auto !important;
	}

	.irannet-sp-gallery--desktop-mosaic .irannet-sp-gallery__thumbs,
	.irannet-sp-gallery--desktop-mosaic .irannet-sp-gallery__arrow,
	.irannet-sp-gallery--desktop-mosaic .irannet-sp-gallery__dots,
	.irannet-sp-gallery--desktop-mosaic .irannet-sp-gallery__counter,
	.irannet-sp-gallery--desktop-stacked .irannet-sp-gallery__thumbs,
	.irannet-sp-gallery--desktop-stacked .irannet-sp-gallery__arrow,
	.irannet-sp-gallery--desktop-stacked .irannet-sp-gallery__dots,
	.irannet-sp-gallery--desktop-stacked .irannet-sp-gallery__counter {
		display: none !important;
	}
}

/* Tablet layouts */
@media (min-width: 768px) and (max-width: 1024px) {
	.irannet-sp-gallery--tablet-thumbs-bottom {
		grid-template-areas: "main" "thumbs";
		grid-template-columns: minmax(0, 1fr);
	}

	.irannet-sp-gallery--tablet-thumbs-top {
		grid-template-areas: "thumbs" "main";
		grid-template-columns: minmax(0, 1fr);
	}

	/* Physical left/right must stay literal in RTL as well. CSS Grid's bidi
	 * column flow reverses named areas, so the declarations are intentionally
	 * mirrored here to match the labels shown in Elementor. */
	.irannet-sp-gallery--tablet-thumbs-left {
		grid-template-areas: "main thumbs";
		grid-template-columns: minmax(0, 1fr) var(--irannet-sp-gallery-thumb-size);
		align-items: start;
	}

	.irannet-sp-gallery--tablet-thumbs-right {
		grid-template-areas: "thumbs main";
		grid-template-columns: var(--irannet-sp-gallery-thumb-size) minmax(0, 1fr);
		align-items: start;
	}

	.irannet-sp-gallery--tablet-thumbs-left .irannet-sp-gallery__thumbs,
	.irannet-sp-gallery--tablet-thumbs-right .irannet-sp-gallery__thumbs {
		flex-direction: column;
		max-height: var(--irannet-sp-gallery-main-height);
		overflow-x: hidden;
		overflow-y: auto;
	}

	.irannet-sp-gallery--tablet-mosaic,
	.irannet-sp-gallery--tablet-stacked {
		display: block;
	}

	.irannet-sp-gallery--tablet-mosaic .irannet-sp-gallery__viewport,
	.irannet-sp-gallery--tablet-stacked .irannet-sp-gallery__viewport {
		height: auto;
		overflow: visible;
		background: transparent;
	}

	.irannet-sp-gallery--tablet-mosaic .irannet-sp-gallery__track {
		display: grid;
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: var(--irannet-sp-gallery-gap);
		transform: none !important;
	}

	.irannet-sp-gallery--tablet-mosaic .irannet-sp-gallery__slide {
		height: calc(var(--irannet-sp-gallery-main-height) / 2);
		opacity: 1 !important;
		visibility: visible !important;
		pointer-events: auto !important;
	}

	.irannet-sp-gallery--tablet-mosaic .irannet-sp-gallery__slide:first-child {
		grid-column: 1 / -1;
		height: var(--irannet-sp-gallery-main-height);
	}

	.irannet-sp-gallery--tablet-stacked .irannet-sp-gallery__track {
		display: grid;
		gap: var(--irannet-sp-gallery-gap);
		transform: none !important;
	}

	.irannet-sp-gallery--tablet-stacked .irannet-sp-gallery__slide {
		height: var(--irannet-sp-gallery-main-height);
		opacity: 1 !important;
		visibility: visible !important;
		pointer-events: auto !important;
	}

	.irannet-sp-gallery--tablet-mosaic .irannet-sp-gallery__thumbs,
	.irannet-sp-gallery--tablet-mosaic .irannet-sp-gallery__arrow,
	.irannet-sp-gallery--tablet-mosaic .irannet-sp-gallery__dots,
	.irannet-sp-gallery--tablet-mosaic .irannet-sp-gallery__counter,
	.irannet-sp-gallery--tablet-stacked .irannet-sp-gallery__thumbs,
	.irannet-sp-gallery--tablet-stacked .irannet-sp-gallery__arrow,
	.irannet-sp-gallery--tablet-stacked .irannet-sp-gallery__dots,
	.irannet-sp-gallery--tablet-stacked .irannet-sp-gallery__counter {
		display: none !important;
	}
}

/* Mobile layouts */
@media (max-width: 767px) {
	.irannet-sp-gallery--mobile-thumbs-bottom,
	.irannet-sp-gallery--mobile-thumbs-left,
	.irannet-sp-gallery--mobile-thumbs-right {
		grid-template-areas: "main" "thumbs";
		grid-template-columns: minmax(0, 1fr);
	}

	.irannet-sp-gallery--mobile-thumbs-top {
		grid-template-areas: "thumbs" "main";
		grid-template-columns: minmax(0, 1fr);
	}

	.irannet-sp-gallery--mobile-thumbs-left .irannet-sp-gallery__thumbs,
	.irannet-sp-gallery--mobile-thumbs-right .irannet-sp-gallery__thumbs {
		flex-direction: row;
		max-height: none;
		overflow-x: auto;
		overflow-y: hidden;
	}

	.irannet-sp-gallery--mobile-mosaic,
	.irannet-sp-gallery--mobile-stacked {
		display: block;
	}

	.irannet-sp-gallery--mobile-mosaic .irannet-sp-gallery__viewport,
	.irannet-sp-gallery--mobile-stacked .irannet-sp-gallery__viewport {
		height: auto;
		overflow: visible;
		background: transparent;
	}

	.irannet-sp-gallery--mobile-mosaic .irannet-sp-gallery__track {
		display: grid;
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: var(--irannet-sp-gallery-gap);
		transform: none !important;
	}

	.irannet-sp-gallery--mobile-mosaic .irannet-sp-gallery__slide {
		height: calc(var(--irannet-sp-gallery-main-height) / 2.2);
		opacity: 1 !important;
		visibility: visible !important;
		pointer-events: auto !important;
	}

	.irannet-sp-gallery--mobile-mosaic .irannet-sp-gallery__slide:first-child {
		grid-column: 1 / -1;
		height: var(--irannet-sp-gallery-main-height);
	}

	.irannet-sp-gallery--mobile-stacked .irannet-sp-gallery__track {
		display: grid;
		gap: var(--irannet-sp-gallery-gap);
		transform: none !important;
	}

	.irannet-sp-gallery--mobile-stacked .irannet-sp-gallery__slide {
		height: var(--irannet-sp-gallery-main-height);
		opacity: 1 !important;
		visibility: visible !important;
		pointer-events: auto !important;
	}

	.irannet-sp-gallery--mobile-mosaic .irannet-sp-gallery__thumbs,
	.irannet-sp-gallery--mobile-mosaic .irannet-sp-gallery__arrow,
	.irannet-sp-gallery--mobile-mosaic .irannet-sp-gallery__dots,
	.irannet-sp-gallery--mobile-mosaic .irannet-sp-gallery__counter,
	.irannet-sp-gallery--mobile-stacked .irannet-sp-gallery__thumbs,
	.irannet-sp-gallery--mobile-stacked .irannet-sp-gallery__arrow,
	.irannet-sp-gallery--mobile-stacked .irannet-sp-gallery__dots,
	.irannet-sp-gallery--mobile-stacked .irannet-sp-gallery__counter {
		display: none !important;
	}

	.irannet-sp-gallery__arrow {
		box-shadow: 0 5px 16px rgba(15, 23, 42, .12);
	}

	.irannet-sp-gallery__arrow--previous {
		right: 8px;
	}

	.irannet-sp-gallery__arrow--next {
		left: 8px;
	}

	.irannet-sp-gallery:dir(ltr) .irannet-sp-gallery__arrow--previous {
		left: 8px;
	}

	.irannet-sp-gallery:dir(ltr) .irannet-sp-gallery__arrow--next {
		right: 8px;
	}

	.irannet-sp-gallery__counter {
		right: 9px;
		bottom: 9px;
		padding: 6px 9px;
	}
}

/* Fullscreen viewer */
.irannet-sp-gallery__lightbox[hidden] {
	display: none !important;
}

.irannet-sp-gallery__lightbox {
	position: fixed;
	inset: 0;
	z-index: 999999;
	display: grid;
	grid-template-columns: minmax(48px, 8vw) minmax(0, 1fr) minmax(48px, 8vw);
	align-items: center;
	padding: 24px;
}

.irannet-sp-gallery__lightbox-stage {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: calc(100vh - 48px);
	min-width: 0;
}

.irannet-sp-gallery__lightbox-image {
	display: block;
	max-width: 100%;
	max-height: 100%;
	object-fit: contain;
	user-select: none;
	-webkit-user-drag: none;
}

.irannet-sp-gallery__lightbox-button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 52px;
	height: 52px;
	padding: 0;
	border: 1px solid rgba(255, 255, 255, .2);
	border-radius: 999px;
	background: rgba(255, 255, 255, .08);
	backdrop-filter: blur(12px);
	cursor: pointer;
	transition: background-color .2s ease, transform .2s ease;
}

.irannet-sp-gallery__lightbox-button:hover {
	background: rgba(255, 255, 255, .18);
	transform: scale(1.05);
}

.irannet-sp-gallery__lightbox-button svg,
.irannet-sp-gallery__lightbox-button i {
	width: 22px;
	height: 22px;
	font-size: 22px;
}

.irannet-sp-gallery__lightbox-close {
	position: absolute;
	top: 20px;
	right: 20px;
	z-index: 2;
}

.irannet-sp-gallery:dir(ltr) .irannet-sp-gallery__lightbox-close {
	right: auto;
	left: 20px;
}

.irannet-sp-gallery__lightbox-previous {
	justify-self: center;
}

.irannet-sp-gallery__lightbox-next {
	grid-column: 3;
	justify-self: center;
}

body.irannet-sp-gallery-lightbox-open {
	overflow: hidden;
}

.irannet-sp-gallery.is-dragging,
.irannet-sp-gallery.is-dragging * {
	cursor: grabbing !important;
}

@media (max-width: 767px) {
	.irannet-sp-gallery__lightbox {
		grid-template-columns: 48px minmax(0, 1fr) 48px;
		padding: 12px;
	}

	.irannet-sp-gallery__lightbox-stage {
		height: calc(100vh - 24px);
	}

	.irannet-sp-gallery__lightbox-button {
		width: 42px;
		height: 42px;
	}

	.irannet-sp-gallery__lightbox-close {
		top: 12px;
		right: 12px;
	}
}


/* Runtime device bridge ---------------------------------------------------
 * Elementor's editor preview and sites with custom breakpoints do not
 * necessarily land inside the legacy 768/1024 media-query ranges. JS keeps
 * data-irannet-device in sync with Elementor's actual device mode so the
 * editor and frontend use the same layout/visibility contract. */
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--tablet-thumbs-bottom {
	grid-template-areas: "main" "thumbs" !important;
	grid-template-columns: minmax(0, 1fr) !important;
}
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--tablet-thumbs-top {
	grid-template-areas: "thumbs" "main" !important;
	grid-template-columns: minmax(0, 1fr) !important;
}
/* In an RTL grid the visual column order is reversed, hence these mirrored
 * templates produce literal physical LEFT / RIGHT positions. */
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--tablet-thumbs-left {
	grid-template-areas: "main thumbs" !important;
	grid-template-columns: minmax(0, 1fr) var(--irannet-sp-gallery-thumb-size) !important;
	align-items: start;
}
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--tablet-thumbs-right {
	grid-template-areas: "thumbs main" !important;
	grid-template-columns: var(--irannet-sp-gallery-thumb-size) minmax(0, 1fr) !important;
	align-items: start;
}
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--tablet-thumbs-left .irannet-sp-gallery__thumbs,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--tablet-thumbs-right .irannet-sp-gallery__thumbs {
	flex-direction: column;
	max-height: var(--irannet-sp-gallery-main-height);
	overflow-x: hidden;
	overflow-y: auto;
}

/* Action visibility: class state is the source of truth. This also makes
 * old saved Elementor documents deterministic inside the editor preview. */
.irannet-sp-gallery[data-irannet-device="desktop"].irannet-sp-gallery--actions-visible-desktop-hide .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-visible-tablet-hide .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="mobile"].irannet-sp-gallery--actions-visible-mobile-hide .irannet-sp-gallery__product-actions {
	display: none !important;
}
.irannet-sp-gallery[data-irannet-device="desktop"].irannet-sp-gallery--actions-visible-desktop-show .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-visible-tablet-show .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="mobile"].irannet-sp-gallery--actions-visible-mobile-show .irannet-sp-gallery__product-actions {
	display: flex !important;
}

/* Tablet action positioning also follows the runtime device marker so the
 * Elementor tablet preview cannot fall back to desktop geometry. */
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-right .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-left .irannet-sp-gallery__product-actions { flex-direction: column; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-right .irannet-sp-gallery__product-actions { right: var(--irannet-sp-gallery-action-offset); left: auto; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-left .irannet-sp-gallery__product-actions { left: var(--irannet-sp-gallery-action-offset); right: auto; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-right.irannet-sp-gallery--actions-align-tablet-start .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-left.irannet-sp-gallery--actions-align-tablet-start .irannet-sp-gallery__product-actions { top: var(--irannet-sp-gallery-action-offset); bottom: auto; transform: none; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-right.irannet-sp-gallery--actions-align-tablet-center .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-left.irannet-sp-gallery--actions-align-tablet-center .irannet-sp-gallery__product-actions { top: 50%; bottom: auto; transform: translateY(-50%); }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-right.irannet-sp-gallery--actions-align-tablet-end .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-left.irannet-sp-gallery--actions-align-tablet-end .irannet-sp-gallery__product-actions { top: auto; bottom: var(--irannet-sp-gallery-action-offset); transform: none; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-top .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-bottom .irannet-sp-gallery__product-actions { flex-direction: row; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-top .irannet-sp-gallery__product-actions { top: var(--irannet-sp-gallery-action-offset); bottom: auto; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-bottom .irannet-sp-gallery__product-actions { bottom: var(--irannet-sp-gallery-action-offset); top: auto; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-top.irannet-sp-gallery--actions-align-tablet-start .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-bottom.irannet-sp-gallery--actions-align-tablet-start .irannet-sp-gallery__product-actions { left: var(--irannet-sp-gallery-action-offset); right: auto; transform: none; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-top.irannet-sp-gallery--actions-align-tablet-center .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-bottom.irannet-sp-gallery--actions-align-tablet-center .irannet-sp-gallery__product-actions { left: 50%; right: auto; transform: translateX(-50%); }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-top.irannet-sp-gallery--actions-align-tablet-end .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-bottom.irannet-sp-gallery--actions-align-tablet-end .irannet-sp-gallery__product-actions { left: auto; right: var(--irannet-sp-gallery-action-offset); transform: none; }

@media (prefers-reduced-motion: reduce) {
	.irannet-sp-gallery__track,
	.irannet-sp-gallery__slide,
	.irannet-sp-gallery__image,
	.irannet-sp-gallery__arrow,
	.irannet-sp-gallery__thumb,
	.irannet-sp-gallery__dot {
		transition-duration: .01ms !important;
		animation-duration: .01ms !important;
		animation-iteration-count: 1 !important;
	}
}

/* v2 semantic/progressive-enhancement hardening */
.irannet-sp-gallery {
	--irannet-sp-gallery-global-primary: var(--e-global-color-primary, #1167d8);
	--irannet-sp-gallery-global-secondary: var(--e-global-color-secondary, #64748b);
	--irannet-sp-gallery-global-text: var(--e-global-color-text, #334155);
	--irannet-sp-gallery-global-accent: var(--e-global-color-accent, #1167d8);
}

.irannet-sp-gallery__viewport {
	touch-action: pan-y pinch-zoom;
}

.irannet-sp-gallery__image-action,
.irannet-sp-gallery__image-action:hover,
.irannet-sp-gallery__image-action:focus,
.irannet-sp-gallery__image-action:active,
.irannet-sp-gallery__image-action:visited {
	appearance: none;
	-webkit-appearance: none;
	font: inherit;
	line-height: inherit;
	text-transform: none;
	box-shadow: none;
	outline-offset: 3px;
}

.irannet-sp-gallery__image-action:focus-visible {
	outline: 2px solid var(--irannet-sp-gallery-global-primary);
}

.irannet-sp-gallery__arrow,
.irannet-sp-gallery__thumb,
.irannet-sp-gallery__dot,
.irannet-sp-gallery__lightbox-button {
	appearance: none;
	-webkit-appearance: none;
	font: inherit;
	line-height: 1;
	text-transform: none;
	box-shadow: none;
	min-width: 0;
	min-height: 0;
	-webkit-tap-highlight-color: transparent;
}

.irannet-sp-gallery__arrow:focus-visible,
.irannet-sp-gallery__thumb:focus-visible,
.irannet-sp-gallery__dot:focus-visible,
.irannet-sp-gallery__lightbox-button:focus-visible {
	outline: 2px solid var(--irannet-sp-gallery-global-primary);
	outline-offset: 3px;
}

/* A closed dialog must never be forced visible by theme or widget CSS. */
.irannet-sp-gallery__lightbox:not([open]):not([data-fallback-open]) {
	display: none !important;
}

.irannet-sp-gallery__lightbox[open],
.irannet-sp-gallery__lightbox[data-fallback-open] {
	position: fixed;
	inset: 0;
	z-index: 2147483000;
	display: block;
	width: 100vw;
	height: 100vh;
	height: 100dvh;
	max-width: none;
	max-height: none;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: 0;
	overflow: hidden;
	color: inherit;
}

.irannet-sp-gallery__lightbox::backdrop {
	background: transparent;
}

.irannet-sp-gallery__lightbox-shell {
	position: relative;
	display: grid;
	grid-template-columns: minmax(48px, 8vw) minmax(0, 1fr) minmax(48px, 8vw);
	align-items: center;
	width: 100%;
	height: 100%;
	padding: 24px;
}

.irannet-sp-gallery__lightbox-stage {
	position: relative;
	flex-direction: column;
	gap: 12px;
	height: calc(100dvh - 48px);
}

.irannet-sp-gallery__lightbox-caption {
	max-width: min(900px, 90vw);
	margin: 0;
	padding: 8px 12px;
	border-radius: 8px;
	background: rgba(15, 23, 42, .62);
	color: #fff;
	font: inherit;
	font-size: 13px;
	line-height: 1.8;
	text-align: center;
}

.irannet-sp-gallery__lightbox-button[hidden] {
	display: none !important;
}

html.irannet-sp-gallery-lightbox-open,
body.irannet-sp-gallery-lightbox-open {
	overflow: hidden !important;
}

@media (max-width: 767px) {
	.irannet-sp-gallery__lightbox-shell {
		grid-template-columns: 44px minmax(0, 1fr) 44px;
		padding: 12px;
	}

	.irannet-sp-gallery__lightbox-stage {
		height: calc(100dvh - 24px);
	}
}

/* =========================================================
 * Product action rail — Wishlist / Compare / Price History
 * Uses companion plugins' public DOM contracts while keeping
 * presentation isolated inside the product gallery.
 * ======================================================= */
.irannet-sp-gallery {
	--irannet-sp-gallery-action-size: 42px;
	--irannet-sp-gallery-action-icon-size: 18px;
	--irannet-sp-gallery-action-gap: 8px;
	--irannet-sp-gallery-action-offset: 12px;
	--irannet-sp-gallery-action-color: var(--irannet-sp-gallery-global-text);
	--irannet-sp-gallery-action-bg: #fff;
	--irannet-sp-gallery-action-hover-color: var(--irannet-sp-gallery-global-primary);
	--irannet-sp-gallery-action-hover-bg: #fff;
	--irannet-sp-gallery-action-active-color: var(--irannet-sp-gallery-global-accent);
	--irannet-sp-gallery-action-active-bg: #fff;
}

.irannet-sp-gallery__product-actions {
	position: absolute;
	z-index: 12;
	display: flex;
	align-items: center;
	justify-content: flex-start;
	gap: var(--irannet-sp-gallery-action-gap);
	max-width: calc(100% - (2 * var(--irannet-sp-gallery-action-offset)));
	max-height: calc(100% - (2 * var(--irannet-sp-gallery-action-offset)));
	pointer-events: auto;
	isolation: isolate;
}

/* All three companion actions use exactly one geometry in the gallery. */
.irannet-sp-gallery__product-action,
.irannet-sp-gallery__product-actions .iwi-button.irannet-sp-gallery__product-action,
.irannet-sp-gallery__product-actions .irn-compare-toggle.irannet-sp-gallery__product-action,
.irannet-sp-gallery__product-actions .irannet-ph-trigger.irannet-sp-gallery__product-action {
	appearance: none !important;
	-webkit-appearance: none !important;
	position: relative !important;
	inset: auto !important;
	float: none !important;
	clear: none !important;
	display: inline-flex !important;
	align-items: center !important;
	justify-content: center !important;
	flex: 0 0 var(--irannet-sp-gallery-action-size) !important;
	inline-size: var(--irannet-sp-gallery-action-size) !important;
	block-size: var(--irannet-sp-gallery-action-size) !important;
	min-inline-size: var(--irannet-sp-gallery-action-size) !important;
	min-block-size: var(--irannet-sp-gallery-action-size) !important;
	max-inline-size: var(--irannet-sp-gallery-action-size) !important;
	max-block-size: var(--irannet-sp-gallery-action-size) !important;
	margin: 0 !important;
	padding: 0 !important;
	border: 1px solid color-mix(in srgb, var(--irannet-sp-gallery-global-secondary) 18%, transparent);
	background: var(--irannet-sp-gallery-action-bg) !important;
	background-image: none !important;
	color: var(--irannet-sp-gallery-action-specific, var(--irannet-sp-gallery-action-color)) !important;
	font: inherit !important;
	font-size: 0 !important;
	line-height: 1 !important;
	letter-spacing: 0 !important;
	text-indent: 0 !important;
	text-transform: none !important;
	text-decoration: none !important;
	vertical-align: middle !important;
	white-space: nowrap !important;
	overflow: hidden !important;
	cursor: pointer;
	touch-action: manipulation;
	-webkit-tap-highlight-color: transparent;
	transition: color .18s ease, background-color .18s ease, border-color .18s ease, box-shadow .18s ease, transform .18s ease, opacity .18s ease;
}

.irannet-sp-gallery__product-action:hover,
.irannet-sp-gallery__product-action:focus-visible {
	color: var(--irannet-sp-gallery-action-hover-color) !important;
	background: var(--irannet-sp-gallery-action-hover-bg) !important;
	transform: translateY(-1px);
}

.irannet-sp-gallery__product-action:focus-visible {
	outline: 2px solid var(--irannet-sp-gallery-global-primary) !important;
	outline-offset: 3px !important;
}

.irannet-sp-gallery__product-action.is-active,
.irannet-sp-gallery__product-action.is-open,
.irannet-sp-gallery__product-action[aria-pressed="true"] {
	color: var(--irannet-sp-gallery-action-active-color) !important;
	background: var(--irannet-sp-gallery-action-active-bg) !important;
}

.irannet-sp-gallery__product-action.is-loading,
.irannet-sp-gallery__product-action[aria-busy="true"],
.irannet-sp-gallery__product-action:disabled {
	opacity: .5;
	cursor: wait;
	pointer-events: none;
}

.irannet-sp-gallery__product-action.is-editor-preview:disabled {
	opacity: 1;
	cursor: default;
}

/* Native labels remain in the accessibility tree but are visually hidden. */
.irannet-sp-gallery__product-actions .iwi-button__text,
.irannet-sp-gallery__product-actions .irn-compare-toggle__text {
	position: absolute !important;
	inline-size: 1px !important;
	block-size: 1px !important;
	padding: 0 !important;
	margin: -1px !important;
	overflow: hidden !important;
	clip: rect(0 0 0 0) !important;
	clip-path: inset(50%) !important;
	white-space: nowrap !important;
	border: 0 !important;
}

/* Normalize native/custom icon boxes without changing action behavior. */
.irannet-sp-gallery__product-action-icon,
.irannet-sp-gallery__product-actions .iwi-icon,
.irannet-sp-gallery__product-actions .irn-compare-toggle__icon,
.irannet-sp-gallery__product-actions .irannet-ph-trigger [class*="icon"] {
	display: inline-grid !important;
	place-items: center !important;
	flex: 0 0 var(--irannet-sp-gallery-action-icon-size) !important;
	inline-size: var(--irannet-sp-gallery-action-icon-size) !important;
	block-size: var(--irannet-sp-gallery-action-icon-size) !important;
	min-inline-size: 0 !important;
	min-block-size: 0 !important;
	margin: 0 !important;
	padding: 0 !important;
	font-size: var(--irannet-sp-gallery-action-icon-size) !important;
	line-height: 1 !important;
	color: currentColor !important;
}

.irannet-sp-gallery__product-action-icon > i,
.irannet-sp-gallery__product-action-icon > svg,
.irannet-sp-gallery__product-actions .iwi-icon > i,
.irannet-sp-gallery__product-actions .iwi-icon > svg,
.irannet-sp-gallery__product-actions .irn-compare-toggle__icon > i,
.irannet-sp-gallery__product-actions .irn-compare-toggle__icon > svg,
.irannet-sp-gallery__product-actions .irannet-ph-trigger svg,
.irannet-sp-gallery__product-actions .irannet-ph-trigger i {
	display: block !important;
	inline-size: 100% !important;
	block-size: 100% !important;
	max-inline-size: 100% !important;
	max-block-size: 100% !important;
	margin: 0 !important;
	padding: 0 !important;
	line-height: 1 !important;
	fill: currentColor;
}

/* If an Elementor icon is explicitly selected, do not show the module's second icon. */
.irannet-sp-gallery__product-action--wishlist.has-irannet-gallery-custom-icon .iwi-icon {
	display: none !important;
}
.irannet-sp-gallery__product-action--price-history.has-irannet-gallery-custom-icon > :not(.irannet-sp-gallery__product-action-icon) {
	display: none !important;
}

.irannet-sp-gallery__product-action--wishlist {
	color: var(--irannet-sp-gallery-action-specific, var(--irannet-sp-gallery-action-color)) !important;
}
.irannet-sp-gallery__product-action--compare {
	color: var(--irannet-sp-gallery-action-specific, var(--irannet-sp-gallery-action-color)) !important;
}
.irannet-sp-gallery__product-action--price-history {
	color: var(--irannet-sp-gallery-action-specific, var(--irannet-sp-gallery-action-color)) !important;
}

/* Position helpers: physical edge is explicit; alignment is along that edge. */
@media (min-width: 1025px) {

	.irannet-sp-gallery--actions-desktop-right .irannet-sp-gallery__product-actions,
	.irannet-sp-gallery--actions-desktop-left .irannet-sp-gallery__product-actions {
		flex-direction: column;
	}
	.irannet-sp-gallery--actions-desktop-right .irannet-sp-gallery__product-actions { right: var(--irannet-sp-gallery-action-offset); left: auto; }
	.irannet-sp-gallery--actions-desktop-left .irannet-sp-gallery__product-actions { left: var(--irannet-sp-gallery-action-offset); right: auto; }
	.irannet-sp-gallery--actions-desktop-right.irannet-sp-gallery--actions-align-desktop-start .irannet-sp-gallery__product-actions,
	.irannet-sp-gallery--actions-desktop-left.irannet-sp-gallery--actions-align-desktop-start .irannet-sp-gallery__product-actions { top: var(--irannet-sp-gallery-action-offset); bottom: auto; transform: none; }
	.irannet-sp-gallery--actions-desktop-right.irannet-sp-gallery--actions-align-desktop-center .irannet-sp-gallery__product-actions,
	.irannet-sp-gallery--actions-desktop-left.irannet-sp-gallery--actions-align-desktop-center .irannet-sp-gallery__product-actions { top: 50%; bottom: auto; transform: translateY(-50%); }
	.irannet-sp-gallery--actions-desktop-right.irannet-sp-gallery--actions-align-desktop-end .irannet-sp-gallery__product-actions,
	.irannet-sp-gallery--actions-desktop-left.irannet-sp-gallery--actions-align-desktop-end .irannet-sp-gallery__product-actions { top: auto; bottom: var(--irannet-sp-gallery-action-offset); transform: none; }

	.irannet-sp-gallery--actions-desktop-top .irannet-sp-gallery__product-actions,
	.irannet-sp-gallery--actions-desktop-bottom .irannet-sp-gallery__product-actions {
		flex-direction: row;
	}
	.irannet-sp-gallery--actions-desktop-top .irannet-sp-gallery__product-actions { top: var(--irannet-sp-gallery-action-offset); bottom: auto; }
	.irannet-sp-gallery--actions-desktop-bottom .irannet-sp-gallery__product-actions { bottom: var(--irannet-sp-gallery-action-offset); top: auto; }
	.irannet-sp-gallery--actions-desktop-top.irannet-sp-gallery--actions-align-desktop-start .irannet-sp-gallery__product-actions,
	.irannet-sp-gallery--actions-desktop-bottom.irannet-sp-gallery--actions-align-desktop-start .irannet-sp-gallery__product-actions { left: var(--irannet-sp-gallery-action-offset); right: auto; transform: none; }
	.irannet-sp-gallery--actions-desktop-top.irannet-sp-gallery--actions-align-desktop-center .irannet-sp-gallery__product-actions,
	.irannet-sp-gallery--actions-desktop-bottom.irannet-sp-gallery--actions-align-desktop-center .irannet-sp-gallery__product-actions { left: 50%; right: auto; transform: translateX(-50%); }
	.irannet-sp-gallery--actions-desktop-top.irannet-sp-gallery--actions-align-desktop-end .irannet-sp-gallery__product-actions,
	.irannet-sp-gallery--actions-desktop-bottom.irannet-sp-gallery--actions-align-desktop-end .irannet-sp-gallery__product-actions { left: auto; right: var(--irannet-sp-gallery-action-offset); transform: none; }
}

@media (min-width: 768px) and (max-width: 1024px) {

	.irannet-sp-gallery--actions-tablet-right .irannet-sp-gallery__product-actions,
	.irannet-sp-gallery--actions-tablet-left .irannet-sp-gallery__product-actions { flex-direction: column; }
	.irannet-sp-gallery--actions-tablet-right .irannet-sp-gallery__product-actions { right: var(--irannet-sp-gallery-action-offset); left: auto; }
	.irannet-sp-gallery--actions-tablet-left .irannet-sp-gallery__product-actions { left: var(--irannet-sp-gallery-action-offset); right: auto; }
	.irannet-sp-gallery--actions-tablet-right.irannet-sp-gallery--actions-align-tablet-start .irannet-sp-gallery__product-actions,
	.irannet-sp-gallery--actions-tablet-left.irannet-sp-gallery--actions-align-tablet-start .irannet-sp-gallery__product-actions { top: var(--irannet-sp-gallery-action-offset); bottom: auto; transform: none; }
	.irannet-sp-gallery--actions-tablet-right.irannet-sp-gallery--actions-align-tablet-center .irannet-sp-gallery__product-actions,
	.irannet-sp-gallery--actions-tablet-left.irannet-sp-gallery--actions-align-tablet-center .irannet-sp-gallery__product-actions { top: 50%; bottom: auto; transform: translateY(-50%); }
	.irannet-sp-gallery--actions-tablet-right.irannet-sp-gallery--actions-align-tablet-end .irannet-sp-gallery__product-actions,
	.irannet-sp-gallery--actions-tablet-left.irannet-sp-gallery--actions-align-tablet-end .irannet-sp-gallery__product-actions { top: auto; bottom: var(--irannet-sp-gallery-action-offset); transform: none; }

	.irannet-sp-gallery--actions-tablet-top .irannet-sp-gallery__product-actions,
	.irannet-sp-gallery--actions-tablet-bottom .irannet-sp-gallery__product-actions { flex-direction: row; }
	.irannet-sp-gallery--actions-tablet-top .irannet-sp-gallery__product-actions { top: var(--irannet-sp-gallery-action-offset); bottom: auto; }
	.irannet-sp-gallery--actions-tablet-bottom .irannet-sp-gallery__product-actions { bottom: var(--irannet-sp-gallery-action-offset); top: auto; }
	.irannet-sp-gallery--actions-tablet-top.irannet-sp-gallery--actions-align-tablet-start .irannet-sp-gallery__product-actions,
	.irannet-sp-gallery--actions-tablet-bottom.irannet-sp-gallery--actions-align-tablet-start .irannet-sp-gallery__product-actions { left: var(--irannet-sp-gallery-action-offset); right: auto; transform: none; }
	.irannet-sp-gallery--actions-tablet-top.irannet-sp-gallery--actions-align-tablet-center .irannet-sp-gallery__product-actions,
	.irannet-sp-gallery--actions-tablet-bottom.irannet-sp-gallery--actions-align-tablet-center .irannet-sp-gallery__product-actions { left: 50%; right: auto; transform: translateX(-50%); }
	.irannet-sp-gallery--actions-tablet-top.irannet-sp-gallery--actions-align-tablet-end .irannet-sp-gallery__product-actions,
	.irannet-sp-gallery--actions-tablet-bottom.irannet-sp-gallery--actions-align-tablet-end .irannet-sp-gallery__product-actions { left: auto; right: var(--irannet-sp-gallery-action-offset); transform: none; }
}

@media (max-width: 767px) {

	.irannet-sp-gallery--actions-mobile-right .irannet-sp-gallery__product-actions,
	.irannet-sp-gallery--actions-mobile-left .irannet-sp-gallery__product-actions { flex-direction: column; }
	.irannet-sp-gallery--actions-mobile-right .irannet-sp-gallery__product-actions { right: var(--irannet-sp-gallery-action-offset); left: auto; }
	.irannet-sp-gallery--actions-mobile-left .irannet-sp-gallery__product-actions { left: var(--irannet-sp-gallery-action-offset); right: auto; }
	.irannet-sp-gallery--actions-mobile-right.irannet-sp-gallery--actions-align-mobile-start .irannet-sp-gallery__product-actions,
	.irannet-sp-gallery--actions-mobile-left.irannet-sp-gallery--actions-align-mobile-start .irannet-sp-gallery__product-actions { top: var(--irannet-sp-gallery-action-offset); bottom: auto; transform: none; }
	.irannet-sp-gallery--actions-mobile-right.irannet-sp-gallery--actions-align-mobile-center .irannet-sp-gallery__product-actions,
	.irannet-sp-gallery--actions-mobile-left.irannet-sp-gallery--actions-align-mobile-center .irannet-sp-gallery__product-actions { top: 50%; bottom: auto; transform: translateY(-50%); }
	.irannet-sp-gallery--actions-mobile-right.irannet-sp-gallery--actions-align-mobile-end .irannet-sp-gallery__product-actions,
	.irannet-sp-gallery--actions-mobile-left.irannet-sp-gallery--actions-align-mobile-end .irannet-sp-gallery__product-actions { top: auto; bottom: var(--irannet-sp-gallery-action-offset); transform: none; }

	.irannet-sp-gallery--actions-mobile-top .irannet-sp-gallery__product-actions,
	.irannet-sp-gallery--actions-mobile-bottom .irannet-sp-gallery__product-actions { flex-direction: row; }
	.irannet-sp-gallery--actions-mobile-top .irannet-sp-gallery__product-actions { top: var(--irannet-sp-gallery-action-offset); bottom: auto; }
	.irannet-sp-gallery--actions-mobile-bottom .irannet-sp-gallery__product-actions { bottom: var(--irannet-sp-gallery-action-offset); top: auto; }
	.irannet-sp-gallery--actions-mobile-top.irannet-sp-gallery--actions-align-mobile-start .irannet-sp-gallery__product-actions,
	.irannet-sp-gallery--actions-mobile-bottom.irannet-sp-gallery--actions-align-mobile-start .irannet-sp-gallery__product-actions { left: var(--irannet-sp-gallery-action-offset); right: auto; transform: none; }
	.irannet-sp-gallery--actions-mobile-top.irannet-sp-gallery--actions-align-mobile-center .irannet-sp-gallery__product-actions,
	.irannet-sp-gallery--actions-mobile-bottom.irannet-sp-gallery--actions-align-mobile-center .irannet-sp-gallery__product-actions { left: 50%; right: auto; transform: translateX(-50%); }
	.irannet-sp-gallery--actions-mobile-top.irannet-sp-gallery--actions-align-mobile-end .irannet-sp-gallery__product-actions,
	.irannet-sp-gallery--actions-mobile-bottom.irannet-sp-gallery--actions-align-mobile-end .irannet-sp-gallery__product-actions { left: auto; right: var(--irannet-sp-gallery-action-offset); transform: none; }
}


/* Runtime device bridge ---------------------------------------------------
 * Elementor's editor preview and sites with custom breakpoints do not
 * necessarily land inside the legacy 768/1024 media-query ranges. JS keeps
 * data-irannet-device in sync with Elementor's actual device mode so the
 * editor and frontend use the same layout/visibility contract. */
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--tablet-thumbs-bottom {
	grid-template-areas: "main" "thumbs" !important;
	grid-template-columns: minmax(0, 1fr) !important;
}
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--tablet-thumbs-top {
	grid-template-areas: "thumbs" "main" !important;
	grid-template-columns: minmax(0, 1fr) !important;
}
/* In an RTL grid the visual column order is reversed, hence these mirrored
 * templates produce literal physical LEFT / RIGHT positions. */
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--tablet-thumbs-left {
	grid-template-areas: "main thumbs" !important;
	grid-template-columns: minmax(0, 1fr) var(--irannet-sp-gallery-thumb-size) !important;
	align-items: start;
}
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--tablet-thumbs-right {
	grid-template-areas: "thumbs main" !important;
	grid-template-columns: var(--irannet-sp-gallery-thumb-size) minmax(0, 1fr) !important;
	align-items: start;
}
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--tablet-thumbs-left .irannet-sp-gallery__thumbs,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--tablet-thumbs-right .irannet-sp-gallery__thumbs {
	flex-direction: column;
	max-height: var(--irannet-sp-gallery-main-height);
	overflow-x: hidden;
	overflow-y: auto;
}

/* Action visibility: class state is the source of truth. This also makes
 * old saved Elementor documents deterministic inside the editor preview. */
.irannet-sp-gallery[data-irannet-device="desktop"].irannet-sp-gallery--actions-visible-desktop-hide .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-visible-tablet-hide .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="mobile"].irannet-sp-gallery--actions-visible-mobile-hide .irannet-sp-gallery__product-actions {
	display: none !important;
}
.irannet-sp-gallery[data-irannet-device="desktop"].irannet-sp-gallery--actions-visible-desktop-show .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-visible-tablet-show .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="mobile"].irannet-sp-gallery--actions-visible-mobile-show .irannet-sp-gallery__product-actions {
	display: flex !important;
}

/* Tablet action positioning also follows the runtime device marker so the
 * Elementor tablet preview cannot fall back to desktop geometry. */
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-right .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-left .irannet-sp-gallery__product-actions { flex-direction: column; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-right .irannet-sp-gallery__product-actions { right: var(--irannet-sp-gallery-action-offset); left: auto; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-left .irannet-sp-gallery__product-actions { left: var(--irannet-sp-gallery-action-offset); right: auto; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-right.irannet-sp-gallery--actions-align-tablet-start .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-left.irannet-sp-gallery--actions-align-tablet-start .irannet-sp-gallery__product-actions { top: var(--irannet-sp-gallery-action-offset); bottom: auto; transform: none; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-right.irannet-sp-gallery--actions-align-tablet-center .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-left.irannet-sp-gallery--actions-align-tablet-center .irannet-sp-gallery__product-actions { top: 50%; bottom: auto; transform: translateY(-50%); }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-right.irannet-sp-gallery--actions-align-tablet-end .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-left.irannet-sp-gallery--actions-align-tablet-end .irannet-sp-gallery__product-actions { top: auto; bottom: var(--irannet-sp-gallery-action-offset); transform: none; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-top .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-bottom .irannet-sp-gallery__product-actions { flex-direction: row; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-top .irannet-sp-gallery__product-actions { top: var(--irannet-sp-gallery-action-offset); bottom: auto; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-bottom .irannet-sp-gallery__product-actions { bottom: var(--irannet-sp-gallery-action-offset); top: auto; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-top.irannet-sp-gallery--actions-align-tablet-start .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-bottom.irannet-sp-gallery--actions-align-tablet-start .irannet-sp-gallery__product-actions { left: var(--irannet-sp-gallery-action-offset); right: auto; transform: none; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-top.irannet-sp-gallery--actions-align-tablet-center .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-bottom.irannet-sp-gallery--actions-align-tablet-center .irannet-sp-gallery__product-actions { left: 50%; right: auto; transform: translateX(-50%); }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-top.irannet-sp-gallery--actions-align-tablet-end .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-bottom.irannet-sp-gallery--actions-align-tablet-end .irannet-sp-gallery__product-actions { left: auto; right: var(--irannet-sp-gallery-action-offset); transform: none; }

@media (prefers-reduced-motion: reduce) {
	.irannet-sp-gallery__product-action { transition-duration: .01ms !important; }
}

/* =========================================================
 * Native share action + controlled accessible dialog.
 * This is local to the gallery and does not alter companion modules.
 * ======================================================= */
.irannet-sp-gallery {
	--irannet-sp-gallery-share-width: 420px;
	--irannet-sp-gallery-share-bg: #fff;
	--irannet-sp-gallery-share-color: var(--irannet-sp-gallery-global-text);
	--irannet-sp-gallery-share-overlay: rgba(2,6,23,.55);
	--irannet-sp-gallery-share-item-bg: #f8fafc;
	--irannet-sp-gallery-share-item-hover-bg: #f1f5f9;
	--irannet-sp-gallery-share-icon-color: var(--irannet-sp-gallery-global-primary);
	--irannet-sp-gallery-share-service-icon-size: 20px;
}

.irannet-sp-gallery__product-action--share {
	color: var(--irannet-sp-gallery-action-specific, var(--irannet-sp-gallery-action-color)) !important;
}

.irannet-sp-gallery__share-dialog {
	box-sizing: border-box;
	inline-size: min(var(--irannet-sp-gallery-share-width), calc(100vw - 32px));
	max-inline-size: calc(100vw - 32px);
	max-block-size: min(760px, calc(100dvh - 32px));
	margin: auto;
	padding: 0;
	border: 1px solid color-mix(in srgb, var(--irannet-sp-gallery-share-color) 12%, transparent);
	background: var(--irannet-sp-gallery-share-bg);
	color: var(--irannet-sp-gallery-share-color);
	overflow: hidden;
}

.irannet-sp-gallery__share-dialog:not([open]):not([data-fallback-open]) {
	display: none;
}

.irannet-sp-gallery__share-dialog::backdrop {
	background: var(--irannet-sp-gallery-share-overlay);
	backdrop-filter: blur(3px);
	-webkit-backdrop-filter: blur(3px);
}

.irannet-sp-gallery__share-dialog[data-fallback-open] {
	position: fixed;
	z-index: 100002;
	inset: 50% auto auto 50%;
	display: block;
	transform: translate(-50%, -50%);
}

.irannet-sp-gallery__share-dialog[data-fallback-open]::before {
	content: '';
	position: fixed;
	z-index: -1;
	inset: -100vh -100vw;
	background: var(--irannet-sp-gallery-share-overlay);
}

.irannet-sp-gallery__share-panel {
	display: flex;
	flex-direction: column;
	gap: 18px;
	max-block-size: min(760px, calc(100dvh - 32px));
	overflow: auto;
	overscroll-behavior: contain;
}

.irannet-sp-gallery__share-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
}

.irannet-sp-gallery__share-title {
	min-inline-size: 0;
	margin: 0;
	color: inherit;
	font-size: 1.05rem;
	line-height: 1.5;
}

.irannet-sp-gallery__share-close {
	appearance: none;
	-webkit-appearance: none;
	display: inline-grid;
	place-items: center;
	flex: 0 0 36px;
	inline-size: 36px;
	block-size: 36px;
	margin: 0;
	padding: 0;
	border: 1px solid color-mix(in srgb, currentColor 14%, transparent);
	border-radius: 10px;
	background: transparent;
	color: inherit;
	cursor: pointer;
	touch-action: manipulation;
}

.irannet-sp-gallery__share-close:hover {
	background: color-mix(in srgb, currentColor 7%, transparent);
}

.irannet-sp-gallery__share-close:focus-visible,
.irannet-sp-gallery__share-service:focus-visible {
	outline: 2px solid var(--irannet-sp-gallery-global-primary);
	outline-offset: 2px;
}

.irannet-sp-gallery__share-services {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 10px;
}

.irannet-sp-gallery__share-service {
	appearance: none;
	-webkit-appearance: none;
	display: flex;
	align-items: center;
	justify-content: flex-start;
	gap: 10px;
	min-inline-size: 0;
	min-block-size: 48px;
	margin: 0;
	padding: 10px 12px;
	border: 1px solid color-mix(in srgb, var(--irannet-sp-gallery-share-color) 10%, transparent);
	border-radius: 12px;
	background: var(--irannet-sp-gallery-share-item-bg);
	color: var(--irannet-sp-gallery-share-color);
	font: inherit;
	font-size: 14px;
	line-height: 1.5;
	text-align: start;
	text-decoration: none !important;
	cursor: pointer;
	touch-action: manipulation;
	transition: background-color .18s ease, border-color .18s ease, transform .18s ease;
}

.irannet-sp-gallery__share-service:hover {
	background: var(--irannet-sp-gallery-share-item-hover-bg);
	border-color: color-mix(in srgb, var(--irannet-sp-gallery-share-icon-color) 22%, transparent);
	transform: translateY(-1px);
	color: var(--irannet-sp-gallery-share-color);
}

.irannet-sp-gallery__share-service.is-copied {
	border-color: color-mix(in srgb, var(--irannet-sp-gallery-global-accent) 45%, transparent);
	background: color-mix(in srgb, var(--irannet-sp-gallery-global-accent) 9%, var(--irannet-sp-gallery-share-item-bg));
}

.irannet-sp-gallery__share-service > span:last-child {
	min-inline-size: 0;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.irannet-sp-gallery__share-service-icon {
	display: inline-grid;
	place-items: center;
	flex: 0 0 var(--irannet-sp-gallery-share-service-icon-size);
	inline-size: var(--irannet-sp-gallery-share-service-icon-size);
	block-size: var(--irannet-sp-gallery-share-service-icon-size);
	color: var(--irannet-sp-gallery-share-icon-color);
	line-height: 0;
}

.irannet-sp-gallery__share-service-icon svg {
	display: block;
	inline-size: 100%;
	block-size: 100%;
	margin: 0;
	padding: 0;
}

.irannet-sp-gallery__share-close .irannet-sp-gallery__share-service-icon {
	inline-size: 18px;
	block-size: 18px;
	flex-basis: 18px;
	color: currentColor;
}

html.irannet-sp-gallery-share-open,
html.irannet-sp-gallery-share-open body {
	overflow: hidden;
}

@media (max-width: 767px) {
	.irannet-sp-gallery__share-dialog {
		inline-size: min(var(--irannet-sp-gallery-share-width), calc(100vw - 16px));
		max-inline-size: calc(100vw - 16px);
		max-block-size: calc(100dvh - 16px);
		margin-block-end: 8px;
	}

	.irannet-sp-gallery__share-services {
		grid-template-columns: minmax(0, 1fr);
	}

	.irannet-sp-gallery__share-panel {
		max-block-size: calc(100dvh - 16px);
	}
}


/* Runtime device bridge ---------------------------------------------------
 * Elementor's editor preview and sites with custom breakpoints do not
 * necessarily land inside the legacy 768/1024 media-query ranges. JS keeps
 * data-irannet-device in sync with Elementor's actual device mode so the
 * editor and frontend use the same layout/visibility contract. */
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--tablet-thumbs-bottom {
	grid-template-areas: "main" "thumbs" !important;
	grid-template-columns: minmax(0, 1fr) !important;
}
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--tablet-thumbs-top {
	grid-template-areas: "thumbs" "main" !important;
	grid-template-columns: minmax(0, 1fr) !important;
}
/* In an RTL grid the visual column order is reversed, hence these mirrored
 * templates produce literal physical LEFT / RIGHT positions. */
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--tablet-thumbs-left {
	grid-template-areas: "main thumbs" !important;
	grid-template-columns: minmax(0, 1fr) var(--irannet-sp-gallery-thumb-size) !important;
	align-items: start;
}
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--tablet-thumbs-right {
	grid-template-areas: "thumbs main" !important;
	grid-template-columns: var(--irannet-sp-gallery-thumb-size) minmax(0, 1fr) !important;
	align-items: start;
}
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--tablet-thumbs-left .irannet-sp-gallery__thumbs,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--tablet-thumbs-right .irannet-sp-gallery__thumbs {
	flex-direction: column;
	max-height: var(--irannet-sp-gallery-main-height);
	overflow-x: hidden;
	overflow-y: auto;
}

/* Action visibility: class state is the source of truth. This also makes
 * old saved Elementor documents deterministic inside the editor preview. */
.irannet-sp-gallery[data-irannet-device="desktop"].irannet-sp-gallery--actions-visible-desktop-hide .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-visible-tablet-hide .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="mobile"].irannet-sp-gallery--actions-visible-mobile-hide .irannet-sp-gallery__product-actions {
	display: none !important;
}
.irannet-sp-gallery[data-irannet-device="desktop"].irannet-sp-gallery--actions-visible-desktop-show .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-visible-tablet-show .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="mobile"].irannet-sp-gallery--actions-visible-mobile-show .irannet-sp-gallery__product-actions {
	display: flex !important;
}

/* Tablet action positioning also follows the runtime device marker so the
 * Elementor tablet preview cannot fall back to desktop geometry. */
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-right .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-left .irannet-sp-gallery__product-actions { flex-direction: column; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-right .irannet-sp-gallery__product-actions { right: var(--irannet-sp-gallery-action-offset); left: auto; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-left .irannet-sp-gallery__product-actions { left: var(--irannet-sp-gallery-action-offset); right: auto; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-right.irannet-sp-gallery--actions-align-tablet-start .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-left.irannet-sp-gallery--actions-align-tablet-start .irannet-sp-gallery__product-actions { top: var(--irannet-sp-gallery-action-offset); bottom: auto; transform: none; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-right.irannet-sp-gallery--actions-align-tablet-center .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-left.irannet-sp-gallery--actions-align-tablet-center .irannet-sp-gallery__product-actions { top: 50%; bottom: auto; transform: translateY(-50%); }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-right.irannet-sp-gallery--actions-align-tablet-end .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-left.irannet-sp-gallery--actions-align-tablet-end .irannet-sp-gallery__product-actions { top: auto; bottom: var(--irannet-sp-gallery-action-offset); transform: none; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-top .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-bottom .irannet-sp-gallery__product-actions { flex-direction: row; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-top .irannet-sp-gallery__product-actions { top: var(--irannet-sp-gallery-action-offset); bottom: auto; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-bottom .irannet-sp-gallery__product-actions { bottom: var(--irannet-sp-gallery-action-offset); top: auto; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-top.irannet-sp-gallery--actions-align-tablet-start .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-bottom.irannet-sp-gallery--actions-align-tablet-start .irannet-sp-gallery__product-actions { left: var(--irannet-sp-gallery-action-offset); right: auto; transform: none; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-top.irannet-sp-gallery--actions-align-tablet-center .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-bottom.irannet-sp-gallery--actions-align-tablet-center .irannet-sp-gallery__product-actions { left: 50%; right: auto; transform: translateX(-50%); }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-top.irannet-sp-gallery--actions-align-tablet-end .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-bottom.irannet-sp-gallery--actions-align-tablet-end .irannet-sp-gallery__product-actions { left: auto; right: var(--irannet-sp-gallery-action-offset); transform: none; }

@media (prefers-reduced-motion: reduce) {
	.irannet-sp-gallery__share-service {
		transition-duration: .01ms !important;
	}
}

/* =========================================================
 * Product video action + lazy accessible dialog.
 * Video data is resolved server-side through IranNet Fields.
 * ======================================================= */
.irannet-sp-gallery {
	--irannet-sp-gallery-video-width: 960px;
	--irannet-sp-gallery-video-bg: #fff;
	--irannet-sp-gallery-video-color: var(--irannet-sp-gallery-global-text);
	--irannet-sp-gallery-video-overlay: rgba(2,6,23,.78);
}

.irannet-sp-gallery__product-action--video {
	color: var(--irannet-sp-gallery-action-specific, var(--irannet-sp-gallery-action-color)) !important;
}

.irannet-sp-gallery__product-action--video.is-unavailable,
.irannet-sp-gallery__product-action--video[aria-disabled="true"] {
	opacity: .48;
	cursor: not-allowed;
	transform: none !important;
	filter: grayscale(.25);
}

.irannet-sp-gallery__product-action--video.is-unavailable:hover,
.irannet-sp-gallery__product-action--video.is-unavailable:focus-visible,
.irannet-sp-gallery__product-action--video[aria-disabled="true"]:hover,
.irannet-sp-gallery__product-action--video[aria-disabled="true"]:focus-visible {
	color: var(--irannet-sp-gallery-action-specific, var(--irannet-sp-gallery-action-color)) !important;
	background: var(--irannet-sp-gallery-action-bg) !important;
	transform: none !important;
}

.irannet-sp-gallery__video-dialog {
	box-sizing: border-box;
	inline-size: min(var(--irannet-sp-gallery-video-width), calc(100vw - 32px));
	max-inline-size: calc(100vw - 32px);
	max-block-size: calc(100dvh - 32px);
	margin: auto;
	padding: 0;
	border: 1px solid color-mix(in srgb, var(--irannet-sp-gallery-video-color) 12%, transparent);
	background: var(--irannet-sp-gallery-video-bg);
	color: var(--irannet-sp-gallery-video-color);
	overflow: hidden;
}

.irannet-sp-gallery__video-dialog:not([open]):not([data-fallback-open]) {
	display: none;
}

.irannet-sp-gallery__video-dialog::backdrop {
	background: var(--irannet-sp-gallery-video-overlay);
	backdrop-filter: blur(3px);
	-webkit-backdrop-filter: blur(3px);
}

.irannet-sp-gallery__video-dialog[data-fallback-open] {
	position: fixed;
	z-index: 100003;
	inset: 50% auto auto 50%;
	display: block;
	transform: translate(-50%, -50%);
}

.irannet-sp-gallery__video-dialog[data-fallback-open]::before {
	content: '';
	position: fixed;
	z-index: -1;
	inset: -100vh -100vw;
	background: var(--irannet-sp-gallery-video-overlay);
}

.irannet-sp-gallery__video-panel {
	box-sizing: border-box;
	inline-size: 100%;
	max-block-size: calc(100dvh - 34px);
	overflow: auto;
	overscroll-behavior: contain;
	-webkit-overflow-scrolling: touch;
}

.irannet-sp-gallery__video-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 14px;
	margin-block-end: 14px;
}

.irannet-sp-gallery__video-title {
	min-inline-size: 0;
	font-weight: 700;
	line-height: 1.7;
	overflow-wrap: anywhere;
}

.irannet-sp-gallery__video-close {
	appearance: none;
	-webkit-appearance: none;
	display: inline-grid;
	place-items: center;
	flex: 0 0 40px;
	inline-size: 40px;
	block-size: 40px;
	padding: 0;
	border: 0;
	border-radius: 999px;
	background: rgba(0,0,0,.06);
	color: inherit;
	cursor: pointer;
	line-height: 1;
}

.irannet-sp-gallery__video-close > span,
.irannet-sp-gallery__video-close svg {
	display: block;
	inline-size: 20px;
	block-size: 20px;
}

.irannet-sp-gallery__video-close:focus-visible {
	outline: 2px solid var(--irannet-sp-gallery-global-primary);
	outline-offset: 3px;
}

.irannet-sp-gallery__video-viewport {
	position: relative;
	inline-size: 100%;
	aspect-ratio: 16 / 9;
	overflow: hidden;
	border-radius: max(8px, .55em);
	background: #000;
}

.irannet-sp-gallery__video-iframe,
.irannet-sp-gallery__video-native {
	display: block;
	inline-size: 100%;
	block-size: 100%;
	margin: 0;
	border: 0;
	background: #000;
	object-fit: contain;
}

.irannet-sp-gallery__video-noscript {
	margin: 10px 0 0;
}

.irannet-sp-gallery__video-noscript a {
	text-decoration: underline;
	text-underline-offset: 3px;
}

html.irannet-sp-gallery-video-open,
body.irannet-sp-gallery-video-open {
	overflow: hidden;
}

@media (max-width: 767px) {
	.irannet-sp-gallery__video-dialog {
		inline-size: min(var(--irannet-sp-gallery-video-width), calc(100vw - 16px));
		max-inline-size: calc(100vw - 16px);
		max-block-size: calc(100dvh - 16px);
	}
	.irannet-sp-gallery__video-panel {
		max-block-size: calc(100dvh - 18px);
	}
	.irannet-sp-gallery__video-header {
		gap: 10px;
		margin-block-end: 10px;
	}
	.irannet-sp-gallery__video-close {
		flex-basis: 38px;
		inline-size: 38px;
		block-size: 38px;
	}
}


/* Runtime device bridge ---------------------------------------------------
 * Elementor's editor preview and sites with custom breakpoints do not
 * necessarily land inside the legacy 768/1024 media-query ranges. JS keeps
 * data-irannet-device in sync with Elementor's actual device mode so the
 * editor and frontend use the same layout/visibility contract. */
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--tablet-thumbs-bottom {
	grid-template-areas: "main" "thumbs" !important;
	grid-template-columns: minmax(0, 1fr) !important;
}
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--tablet-thumbs-top {
	grid-template-areas: "thumbs" "main" !important;
	grid-template-columns: minmax(0, 1fr) !important;
}
/* In an RTL grid the visual column order is reversed, hence these mirrored
 * templates produce literal physical LEFT / RIGHT positions. */
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--tablet-thumbs-left {
	grid-template-areas: "main thumbs" !important;
	grid-template-columns: minmax(0, 1fr) var(--irannet-sp-gallery-thumb-size) !important;
	align-items: start;
}
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--tablet-thumbs-right {
	grid-template-areas: "thumbs main" !important;
	grid-template-columns: var(--irannet-sp-gallery-thumb-size) minmax(0, 1fr) !important;
	align-items: start;
}
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--tablet-thumbs-left .irannet-sp-gallery__thumbs,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--tablet-thumbs-right .irannet-sp-gallery__thumbs {
	flex-direction: column;
	max-height: var(--irannet-sp-gallery-main-height);
	overflow-x: hidden;
	overflow-y: auto;
}

/* Action visibility: class state is the source of truth. This also makes
 * old saved Elementor documents deterministic inside the editor preview. */
.irannet-sp-gallery[data-irannet-device="desktop"].irannet-sp-gallery--actions-visible-desktop-hide .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-visible-tablet-hide .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="mobile"].irannet-sp-gallery--actions-visible-mobile-hide .irannet-sp-gallery__product-actions {
	display: none !important;
}
.irannet-sp-gallery[data-irannet-device="desktop"].irannet-sp-gallery--actions-visible-desktop-show .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-visible-tablet-show .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="mobile"].irannet-sp-gallery--actions-visible-mobile-show .irannet-sp-gallery__product-actions {
	display: flex !important;
}

/* Tablet action positioning also follows the runtime device marker so the
 * Elementor tablet preview cannot fall back to desktop geometry. */
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-right .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-left .irannet-sp-gallery__product-actions { flex-direction: column; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-right .irannet-sp-gallery__product-actions { right: var(--irannet-sp-gallery-action-offset); left: auto; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-left .irannet-sp-gallery__product-actions { left: var(--irannet-sp-gallery-action-offset); right: auto; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-right.irannet-sp-gallery--actions-align-tablet-start .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-left.irannet-sp-gallery--actions-align-tablet-start .irannet-sp-gallery__product-actions { top: var(--irannet-sp-gallery-action-offset); bottom: auto; transform: none; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-right.irannet-sp-gallery--actions-align-tablet-center .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-left.irannet-sp-gallery--actions-align-tablet-center .irannet-sp-gallery__product-actions { top: 50%; bottom: auto; transform: translateY(-50%); }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-right.irannet-sp-gallery--actions-align-tablet-end .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-left.irannet-sp-gallery--actions-align-tablet-end .irannet-sp-gallery__product-actions { top: auto; bottom: var(--irannet-sp-gallery-action-offset); transform: none; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-top .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-bottom .irannet-sp-gallery__product-actions { flex-direction: row; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-top .irannet-sp-gallery__product-actions { top: var(--irannet-sp-gallery-action-offset); bottom: auto; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-bottom .irannet-sp-gallery__product-actions { bottom: var(--irannet-sp-gallery-action-offset); top: auto; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-top.irannet-sp-gallery--actions-align-tablet-start .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-bottom.irannet-sp-gallery--actions-align-tablet-start .irannet-sp-gallery__product-actions { left: var(--irannet-sp-gallery-action-offset); right: auto; transform: none; }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-top.irannet-sp-gallery--actions-align-tablet-center .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-bottom.irannet-sp-gallery--actions-align-tablet-center .irannet-sp-gallery__product-actions { left: 50%; right: auto; transform: translateX(-50%); }
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-top.irannet-sp-gallery--actions-align-tablet-end .irannet-sp-gallery__product-actions,
.irannet-sp-gallery[data-irannet-device="tablet"].irannet-sp-gallery--actions-tablet-bottom.irannet-sp-gallery--actions-align-tablet-end .irannet-sp-gallery__product-actions { left: auto; right: var(--irannet-sp-gallery-action-offset); transform: none; }

@media (prefers-reduced-motion: reduce) {
	.irannet-sp-gallery__product-action--video,
	.irannet-sp-gallery__video-close {
		transition: none !important;
	}
}
