.hx-elementx-all-images {
	--hx-thumb-size: 96px;
	--hx-thumb-gap: 12px;
	--hx-nav-height: 30px;
	--hx-nav-gap: 8px;
	display: block;
	width: var(--hx-thumb-size);
	max-width: var(--hx-thumb-size);
}

.hx-elementx-all-images-thumbs-wrap {
	display: flex;
	flex-direction: column;
	height: 100%;
}

.hx-elementx-all-images-thumbs {
	display: flex;
	flex-direction: column;
	gap: var(--hx-thumb-gap);
	height: calc((var(--hx-thumb-size) * 4) + (var(--hx-thumb-gap) * 3));
	max-height: calc((var(--hx-thumb-size) * 4) + (var(--hx-thumb-gap) * 3));
	overflow-y: auto;
	overflow-x: hidden;
	padding-right: 2px;
	-ms-overflow-style: none;
	scrollbar-width: none;
}

.hx-elementx-all-images-thumbs::-webkit-scrollbar {
	width: 0;
	height: 0;
	display: none;
}

.hx-elementx-all-images-thumb {
	display: block;
	width: var(--hx-thumb-size);
	height: var(--hx-thumb-size);
	min-width: var(--hx-thumb-size);
	min-height: var(--hx-thumb-size);
	border: 1px solid #d6dbe4;
	background: #fff;
	padding: 0;
	cursor: pointer;
	line-height: 0;
	opacity: 0.4;
	filter: saturate(0.85);
	transition: border-color 0.18s ease, opacity 0.18s ease, filter 0.18s ease;
	overflow: hidden;
	box-sizing: border-box;
	flex: 0 0 auto;
}

.hx-elementx-all-images-thumb img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.hx-elementx-all-images-thumb.is-active {
	border-color: #111827;
	opacity: 1;
	filter: none;
}

.hx-elementx-all-images-thumb:hover {
	opacity: 0.7;
}

.hx-elementx-all-images-nav {
	display: flex;
	align-items: center;
	justify-content: stretch;
	gap: 0;
	margin-top: var(--hx-nav-gap);
	border: 1px solid var(--hx-all-nav-border, #d8dde6);
}

.hx-elementx-all-images-nav-btn {
	flex: 1 1 50%;
	height: var(--hx-nav-height);
	border: 0;
	border-right: 1px solid var(--hx-all-nav-border, #d8dde6);
	background: var(--hx-all-nav-bg, #f3f4f6);
	color: var(--hx-all-nav-icon, #7f5e58);
	display: inline-flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	line-height: 1;
}

.hx-elementx-all-images-nav-btn:last-child {
	border-right: 0;
}

.hx-elementx-all-images-nav-btn:hover:not(:disabled),
.hx-elementx-all-images-nav-btn:focus-visible:not(:disabled),
.hx-elementx-all-images-nav-btn:active:not(:disabled) {
	background: var(--hx-all-nav-bg-hover, #ebeef3);
	color: var(--hx-all-nav-icon-hover, #6d4f49);
	box-shadow: inset 0 0 0 1px var(--hx-all-nav-border-hover, #cfd6e1);
}

.hx-elementx-all-images-nav-btn i,
.hx-elementx-all-images-nav-btn svg {
	display: block;
	width: 12px;
	height: 12px;
	color: currentColor;
	fill: currentColor;
}

.hx-elementx-all-images-nav-btn:disabled {
	opacity: 0.45;
	cursor: default;
}

@media (max-width: 767px) {
	/* Place All Images immediately after Product Image on mobile/tablet stacks */
	.elementor-column:has(.elementor-widget-hx-elementx-all-images),
	.e-con:has(.elementor-widget-hx-elementx-all-images),
	.e-con-inner:has(.elementor-widget-hx-elementx-all-images) {
		order: -1 !important;
	}

	.hx-elementx-all-images {
		width: 100%;
		max-width: 100%;
		height: auto !important;
	}

	.hx-elementx-all-images-thumbs-wrap {
		height: auto;
	}

	.hx-elementx-all-images-thumbs {
		flex-direction: row;
		width: 100%;
		height: auto !important;
		max-height: none !important;
		overflow-x: auto;
		overflow-y: hidden;
		padding-right: 0;
		padding-bottom: 2px;
	}

	.hx-elementx-all-images-nav {
		display: none !important;
	}
}
