/* Dezen — Catalog Gallery Slider (Savoy)  v1.0.9
   Minimal styling that inherits Savoy's look. Accent: #DC9814 (brand gold).
   v1.0.6: mobile (<=991px) shows Slick dots as non-interactive position
   indicators; arrows are no longer built on mobile (see JS). */

.dezen-cgs {
	position: relative;
}

.nm-shop-loop-thumbnail .dezen-cgs__slide {
	/* ratio is set inline from the featured image; falls back to square.
	   !important + height:auto defend against lazyload plugins that set explicit
	   heights on image wrappers, which would silently break the ratio lock. */
	aspect-ratio: var(--cgs-ratio, 1 / 1) !important;
	height: auto !important;
	overflow: hidden;
}
.nm-shop-loop-thumbnail .dezen-cgs__slide img,
.nm-shop-loop-thumbnail .dezen-cgs__img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

/* Savoy hides non-hover loop images until lazysizes marks them loaded; our slides
   use Slick's own lazy-load, so force them visible. */
.nm-shop-loop-thumbnail .dezen-cgs__img,
.images-lazyload .nm-shop-loop-thumbnail .dezen-cgs__slide img {
	opacity: 1 !important;
}

/* ---- Arrows (subtle, edge-hugging) ---- */
.dezen-cgs__arrow {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	z-index: 3;
	width: 30px;
	height: 30px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.85);
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12);
	cursor: pointer;
	opacity: 0;
	transition: opacity 0.2s ease, background 0.2s ease;
}
.dezen-cgs__arrow:hover {
	background: #fff;
}
.dezen-cgs__arrow::before {
	content: "";
	position: absolute;
	top: 50%;
	left: 50%;
	width: 7px;
	height: 7px;
	border-top: 2px solid #282828;
	border-right: 2px solid #282828;
}
.dezen-cgs__arrow--prev {
	left: 6px;
}
.dezen-cgs__arrow--prev::before {
	transform: translate(-40%, -50%) rotate(-135deg);
}
.dezen-cgs__arrow--next {
	right: 6px;
}
.dezen-cgs__arrow--next::before {
	transform: translate(-60%, -50%) rotate(45deg);
}

/* Desktop: reveal on hover. */
.nm-shop-loop-thumbnail:hover .dezen-cgs__arrow {
	opacity: 1;
}

/* Touch devices (no hover): always visible, but smaller & lighter so they don't crowd the card. */
@media (hover: none) {
	.dezen-cgs__arrow {
		opacity: 1;
		width: 24px;
		height: 24px;
		background: rgba(255, 255, 255, 0.78);
		box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
	}
	.dezen-cgs__arrow::before {
		width: 6px;
		height: 6px;
		border-top-width: 1.5px;
		border-right-width: 1.5px;
	}
	.dezen-cgs__arrow--prev {
		left: 4px;
	}
	.dezen-cgs__arrow--next {
		right: 4px;
	}
}

/* ---- Dots (exist only when the page initialized at <=991px — see JS MOBILE flag) ----
   NOT wrapped in a media query on purpose: the dots' existence is decided once by JS
   at load, so styling must follow existence, not live viewport width. Otherwise a
   page loaded narrow and viewed wider drops the dots <ul> into normal flow, adding a
   white band below the image. position/bottom are !important for the same reason:
   if any theme rule wins the position fight, the same white band appears. */
.dezen-cgs .slick-dots {
	position: absolute !important;
	left: 0 !important;
	right: 0 !important;
	top: auto !important;
	bottom: 8px !important;
	width: auto;
	height: auto;
	margin: 0 !important;
	padding: 0 !important;
	list-style: none;
	display: flex !important;
	justify-content: center;
	align-items: center;
	gap: 6px;
	z-index: 3;
	line-height: 0;
	/* Indicators only: the dots live inside the product <a>, so letting taps
	   pass through means a tap there opens the product, same as the image. */
	pointer-events: none;
}
.dezen-cgs .slick-dots li,
.dezen-cgs .slick-dots li.slick-active {
	width: 6px !important;
	height: 6px !important;
	margin: 0 !important;
	padding: 0 !important;
	transform: none !important;
}
.dezen-cgs .slick-dots li button,
.dezen-cgs .slick-dots li.slick-active button {
	display: block;
	width: 6px !important;
	height: 6px !important;
	padding: 0 !important;
	margin: 0 !important;
	border: 0;
	border-radius: 50%;
	box-shadow: none;
	transform: none !important;
	text-indent: -9999px;
	transition: background 0.2s ease;
}
.dezen-cgs .slick-dots li button {
	background: #dddddd;
}
.dezen-cgs .slick-dots li button::before,
.dezen-cgs .slick-dots li button::after {
	content: none !important; /* Savoy/slick themes often draw the dot via ::before */
}
.dezen-cgs .slick-dots li.slick-active button {
	background: #DC9814;
}

/* Keep Savoy's wishlist / quick-view / add-to-cart overlay above the slider. */
.nm-shop-loop-thumbnail .nm-shop-loop-icons,
.nm-shop-loop-thumbnail .nm-shop-loop-buttons,
.nm-shop-loop-thumbnail .nm-loop-product-buttons,
.nm-shop-loop-product-wrap .nm-shop-loop-add-to-cart {
	z-index: 4;
}
