/* =========================================================================
   Sunshop – parduotuvės filtrai
   1) Sulankstomi (collapse/expand) filtrai su rodykle
   2) Tvarkingas checkbox lygiavimas
   3) Mobile: „Filtrai" off-canvas panelė
   ========================================================================= */

/* ---- Konteineris ------------------------------------------------------- */
.etheme-product-filters { display: block; }
.etheme-product-filters-items { display: block; grid-template-columns: none; }

/* ---- Filtro grupė ------------------------------------------------------ */
.etheme-product-filters-item {
	position: static;
	margin: 0;
	border-bottom: 1px solid #ececec;
}
.etheme-product-filters-item:first-child { border-top: 1px solid #ececec; }

/* Antraštė = perjungiklis (be temos dėžutės/rėmelio) */
.etheme-product-filters-item-title {
	display: flex !important;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	cursor: pointer;
	margin: 0 !important;
	padding: 15px 2px !important;
	border: 0 !important;
	background: transparent !important;
	border-radius: 0 !important;
	box-shadow: none !important;
	-webkit-user-select: none;
	user-select: none;
}
.etheme-product-filters-item-title .title-text {
	white-space: normal !important;
	overflow: visible !important;
	text-overflow: clip !important;
	min-width: 0 !important;
	font-weight: 600;
	font-size: 15px;
	color: #1a1a1a;
	line-height: 1.3;
	padding: 0 !important;
}
/* Paslėpti temos „quick-results" spanus antraštėje (netvarkingi) */
.etheme-product-filters-quick-results { display: none !important; }

/* Sava rodyklė (chevron) */
.etheme-product-filters-item-title:after {
	content: '' !important;
	display: inline-block !important;
	width: 8px;
	height: 8px;
	flex: 0 0 auto;
	border-right: 2px solid #9a9a9a;
	border-bottom: 2px solid #9a9a9a;
	transform: rotate(45deg);
	transition: transform .22s ease;
	position: static !important;
	margin: 0 3px 4px 0 !important;
	top: auto !important;
	right: auto !important;
}
.etheme-product-filters-item.ss-open > .etheme-product-filters-item-title:after {
	transform: rotate(-135deg);
	margin-bottom: -2px !important;
}

/* ---- Turinys – sulankstomas -------------------------------------------- */
.etheme-product-filters-item .etheme-product-filters-item-content {
	display: block !important;
	position: static !important;
	background: transparent !important;
	box-shadow: none !important;
	border: 0 !important;
	margin: 0 !important;
	padding: 0 !important;
	max-height: 0;
	overflow: hidden;
	transition: max-height .28s ease;
}
.etheme-product-filters-item.ss-open > .etheme-product-filters-item-content {
	padding: 0 0 15px !important;
}

/* ---- Reikšmių sąrašas + checkbox lygiavimas ---------------------------- */
.etheme-product-filters-item-content ul { margin: 0 !important; padding: 0 !important; list-style: none !important; }
.etheme-product-filters-item-content li {
	list-style: none !important;
	margin: 0 !important;
	padding: 0 !important;
}
.etheme-product-filters-item-content li > .filter-item {
	display: flex !important;
	align-items: center;
	gap: 10px;
	padding: 6px 2px !important;
	margin: 0 !important;
	color: #4a4a4a;
	text-decoration: none;
	cursor: pointer;
	line-height: 1.35;
	font-size: 14px;
}
.etheme-product-filters-item-content li > .filter-item:hover { color: #643395; }
.etheme-product-filters-item-content li > .filter-item > .st-custom-attribute,
.etheme-product-filters-item-content li > .filter-item > span:not(.count) {
	flex: 1 1 auto;
	min-width: 0;
}

/* Checkbox indikatorius */
.etheme-product-filters-item-content li > .filter-item::before {
	content: '';
	display: inline-block;
	width: 18px;
	height: 18px;
	flex: 0 0 auto;
	border: 1.5px solid #cbcbcb;
	border-radius: 4px;
	background: #fff;
	transition: all .15s ease;
}
.etheme-product-filters-item-content li.selected > .filter-item::before,
.etheme-product-filters-item-content li.chosen > .filter-item::before {
	border-color: #643395;
	background: #643395 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='%23fff' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 8.5l3.2 3.3 6.6-8'/%3E%3C/svg%3E") center / 12px no-repeat;
}

/* ---- Kainos slankiklis -------------------------------------------------- */
.etheme-product-filters-item .price_label {
	font-size: 14px;
	color: #4a4a4a;
	margin-top: 12px;
}
.etheme-product-filters-item .ui-slider,
.etheme-product-filters-item .price_slider { margin-top: 10px; }

/* „Filtruoti" – tik mygtukas, be spalvoto fono (wrapper permatomas) */
.etheme-product-filters .etheme-product-filters-button {
	background: transparent !important;
	padding: 0 !important;
	margin-top: 16px;
	border: 0 !important;
	border-radius: 0 !important;
	box-shadow: none !important;
	text-align: left;
}
/* Desktop – auto-filtras (mygtukas nereikalingas); mobile – lieka */
@media (min-width: 1025px) {
	.etheme-product-filters .etheme-product-filters-button { display: none !important; }
}
.etheme-product-filters .etheme-product-filters-button .elementor-button,
.etheme-product-filters button[type="submit"] {
	display: inline-flex;
	align-items: center;
	width: auto;
	cursor: pointer;
}

/* Kategorijų puslapio erdvė viršuje/apačioje */
.tax-product_cat .elementor-element-77dcb4d0,
.post-type-archive-product .elementor-element-77dcb4d0 {
	padding-top: 50px !important;
	padding-bottom: 80px !important;
}
@media (max-width: 767px) {
	.tax-product_cat .elementor-element-77dcb4d0,
	.post-type-archive-product .elementor-element-77dcb4d0 {
		padding-top: 28px !important;
		padding-bottom: 48px !important;
	}
}

/* ---- Mobile off-canvas („Filtrai") ------------------------------------- */
.sunshop-filters-toggle {
	display: none;
	align-items: center;
	gap: 8px;
	background: #643395;
	color: #fff;
	border: 0;
	border-radius: 4px;
	padding: 11px 20px;
	font-weight: 600;
	font-size: 15px;
	cursor: pointer;
	margin-bottom: 18px;
}
.sunshop-filters-toggle svg { width: 16px; height: 16px; }
.sunshop-filters-overlay {
	display: none;
	position: fixed;
	inset: 0;
	background: rgba(0, 0, 0, .5);
	z-index: 99998;
}
.sunshop-filters-overlay.is-open { display: block; }

@media (max-width: 1024px) {
	.sunshop-filters-toggle { display: inline-flex; }

	.elementor-widget-etheme_product_filters {
		position: fixed !important;
		top: 0;
		left: 0;
		height: 100% !important;
		width: 330px;
		max-width: 86vw;
		background: #fff;
		z-index: 99999;
		transform: translateX(-100%);
		transition: transform .3s ease;
		overflow-y: auto;
		padding: 24px 20px 40px;
		box-shadow: 2px 0 22px rgba(0, 0, 0, .18);
	}
	.elementor-widget-etheme_product_filters.is-open { transform: translateX(0) !important; }

	.sunshop-filters-close {
		position: absolute;
		top: 10px;
		right: 12px;
		width: 32px;
		height: 32px;
		border: 0;
		background: transparent;
		font-size: 28px;
		line-height: 1;
		color: #333;
		cursor: pointer;
		z-index: 1;
	}
}
@media (min-width: 1025px) {
	.sunshop-filters-toggle,
	.sunshop-filters-close { display: none !important; }
}
