/* ===========================================================================
   GALLERY — Image gallery, thumbnails, lightbox
   Petz.gr

   !important kept on: gallery-nav, swiper-button (Swiper library),
   .container, .section, .row, col-*, .product-title (Bootstrap/Modesy),
   gallery-thumb sizing (Swiper inline styles)
   !important removed from: petz-gallery-row (petz-exclusive)
   =========================================================================== */

/* ── Layout row ──────────────────────────────────────────── */

.petz-gallery-row {
	display: flex;
	flex-wrap: wrap;
	align-items: stretch;
}

/* ── Gallery container ───────────────────────────────────── */

.petz-gallery {
	border-radius: 16px;
	overflow: hidden;
	background: #1a1a1a;
	position: relative;
}

.gallery-main {
	position: relative;
	aspect-ratio: 4/3;
	overflow: hidden;
	display: flex;
	align-items: center;
	justify-content: center;
}

.gallery-blur-bg {
	position: absolute;
	inset: -30px;
	background-size: cover;
	background-position: center;
	filter: blur(25px);
	transform: scale(1.2);
	opacity: 0.6;
	z-index: 0;
	transition: background-image 0.3s ease;
}

.gallery-main-img {
	position: relative;
	z-index: 1;
	max-width: 100%;
	max-height: 100%;
	width: auto;
	height: auto;
	object-fit: contain;
	display: block;
	margin: auto;
}

.petz-gallery .gallery-swiper {
	width: 100%;
	height: 100%;
}

.petz-gallery .swiper-slide {
	display: flex;
	align-items: center;
	justify-content: center;
}

.petz-gallery .swiper-slide a {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 100%;
}

.petz-gallery .gallery-main img,
.petz-gallery .gallery-swiper a {
	cursor: zoom-in;
}

/* ── Gallery navigation — !important needed (overrides Swiper defaults) ── */

.petz-gallery .gallery-nav {
	background: rgba(0, 0, 0, 0.3) !important;
	width: 44px !important;
	height: 44px !important;
	border-radius: 50% !important;
	box-shadow: 0 2px 8px rgba(0,0,0,0.2);
	transition: all 0.25s ease;
	backdrop-filter: blur(4px);
	-webkit-backdrop-filter: blur(4px);
}

.petz-gallery .gallery-nav::after {
	font-size: 16px !important;
	font-weight: bold !important;
	color: #fff !important;
}

.petz-gallery .gallery-nav:hover {
	background: rgba(0, 0, 0, 0.5) !important;
	transform: scale(1.08);
}

/* Hide thumbnail navigation arrows — !important needed (Swiper) */
.petz-gallery .gallery-thumbs-container .swiper-button-prev,
.petz-gallery .gallery-thumbs-container .swiper-button-next,
.petz-gallery-container .gallery-thumbs-swiper .swiper-button-prev,
.petz-gallery-container .gallery-thumbs-swiper .swiper-button-next,
#product_slider_container .gallery-thumbs-container .swiper-button-prev,
#product_slider_container .gallery-thumbs-container .swiper-button-next {
	display: none !important;
}

/* ── Thumbnails ──────────────────────────────────────────── */

.gallery-thumbs-container {
	padding: 16px;
	background: #fff;
}

.gallery-thumbs-swiper {
	width: 100%;
}

.gallery-thumbs-swiper .swiper-wrapper {
	display: flex;
	gap: 8px;
}

/* !important on sizing — overrides Swiper inline width/height */
.gallery-thumb {
	width: 100px !important;
	height: 75px !important;
	border-radius: 6px;
	overflow: hidden;
	cursor: pointer;
	border: 2px solid transparent;
	transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
	flex-shrink: 0;
	position: relative;
	background: none;
}

.gallery-thumb::before {
	content: "";
	position: absolute;
	inset: 0;
	background-image: var(--thumb-bg);
	background-size: cover;
	background-position: center;
	filter: blur(25px);
	opacity: 0.6;
	z-index: 1;
	transform: scale(1.4);
}

.gallery-thumb img {
	width: 100%;
	height: 100%;
	object-fit: contain;
	border-radius: 6px;
	position: relative;
	z-index: 2;
	box-shadow: 0 0 10px rgba(0,0,0,0.1);
}

.gallery-thumb:hover {
	border-color: var(--petz-primary);
	transform: scale(1.05);
	box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}

.gallery-thumb.swiper-slide-thumb-active {
	border-color: #8B5CF6;
	transform: scale(1.08);
	border: 2px solid #555 !important;
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15) !important;
}

/* Thumbnail nav arrows — !important needed (Swiper) */
.thumb-nav {
	width: 32px !important;
	height: 32px !important;
	background: rgba(255,255,255,0.9) !important;
	border-radius: 50% !important;
	box-shadow: 0 1px 4px rgba(0,0,0,0.1);
}

.thumb-nav::after {
	font-size: 12px !important;
	color: #333 !important;
}
