/*
 Theme Name:   Woodmart Child
 Description:  Woodmart Child Theme
 Author:       XTemos
 Author URI:   http://xtemos.com
 Template:     woodmart
 Version:      1.0.0
 Text Domain:  woodmart
*/

/* Скрываем дополнительную информацию в названиях товаров,
   заключённую в одинарные кавычки и обёрнутую в nl-hidden-title-extra. */
.nl-hidden-title-extra {
	display: none !important;
}

/* Бейдж "Бесплатная укладка" — пара к .product-badge-discounted,
   но в холодной сине-голубой палитре. */
.product-badge-free-installation {
	align-items: center;
	background: linear-gradient(92.16deg, #68d5ee, #2563eb);
	border-radius: 20px;
	color: #fff;
	display: flex;
	flex-direction: row;
	font-size: 12px;
	font-style: normal;
	font-weight: 400;
	gap: 2px;
	justify-content: center;
	line-height: 120%;
	padding: 3px 10px;
}

/* Стили для кнопок фильтров каталога */
.nl-catalog-filter-buttons-widget {
	margin-bottom: 20px;
}

.nl-catalog-filter-buttons {
	display: flex;
	flex-direction: column;
	gap: 8px;
	align-items: stretch;
}

.nl-filter-toggle-wrapper {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	width: 100%;
	padding: 10px 12px;
	margin-bottom: 0;
	border-radius: 8px;
	background: #F1EEEE;
}

.nl-filter-label {
	font-size: 16px;
	font-weight: 500;
	color: #333;
	flex: 1;
}

/* Тумблер */
.nl-filter-toggle {
	position: relative;
	display: inline-block;
	width: 50px;
	height: 26px;
	margin: 0;
	cursor: pointer;
	flex-shrink: 0;
}

.nl-filter-checkbox {
	opacity: 0;
	width: 0;
	height: 0;
}

.nl-filter-slider {
	position: absolute;
	cursor: pointer;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background-color: #ccc;
	transition: 0.3s;
	border-radius: 26px;
	box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1);
}

.nl-filter-slider::before {
	position: absolute;
	content: "";
	height: 20px;
	width: 20px;
	left: 3px;
	bottom: 3px;
	background-color: white;
	transition: 0.3s;
	border-radius: 50%;
	box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.nl-filter-checkbox:checked + .nl-filter-slider {
	background: linear-gradient(135deg, #9C2422 0%, #C73A35 100%);
}

.nl-filter-checkbox:checked + .nl-filter-slider::before {
	transform: translateX(24px);
}

.nl-filter-checkbox:focus + .nl-filter-slider {
	box-shadow: 0 0 0 3px rgba(156, 36, 34, 0.2);
}

/* Адаптивность */
@media (max-width: 768px) {
	.nl-filter-label {
		font-size: 15px;
	}
}

/* --- Фильтры над товарами: только на мобилке, bottom sheet --- */
.nl-mobile-filters-wrap {
	display: none;
	margin-bottom: 16px;
	position: relative;
	overflow: visible;
	width: 100%;
}

@media (max-width: 1024px) {
	.nl-mobile-filters-wrap {
		display: block;
	}
}

.nl-mobile-filters-scroll {
	display: flex;
	align-items: center;
	gap: 10px;
	overflow-x: scroll;
	overflow-y: hidden;
	padding: 4px 0 12px;
	-webkit-overflow-scrolling: touch;
	touch-action: pan-x;
	scrollbar-width: none;
	-ms-overflow-style: none;
	cursor: grab;
	min-width: 0;
	max-width: 100%;
}

.nl-mobile-filters-scroll:active {
	cursor: grabbing;
}

.nl-mobile-filters-scroll::-webkit-scrollbar {
	display: none;
}

/* Тумблеры (Распродажа, Бесплатная укладка) — как пилюли фильтров */
.nl-mobile-filter-toggle.nl-filter-toggle-wrapper {
	flex: 0 0 auto;
	width: auto;
	min-width: 180px;
	margin: 0;
	padding: 8px 14px;
	gap: 10px;
	border-radius: 10px;
	background: #f0eeee;
	transition: background 0.2s ease;
}

.nl-mobile-filter-toggle.nl-filter-toggle-wrapper:hover {
	background: #e8e6e6;
}

.nl-mobile-filter-toggle .nl-filter-label {
	font-size: 14px !important;
	font-weight: 500;
	color: #292323;
	white-space: nowrap;
}

/* Кнопка «Фильтры» — тёмная, как на референсе */
.nl-mobile-filter-dropdown.nl-filter-btn-primary {
	background: #282828;
	min-width: auto;
}

.nl-mobile-filter-dropdown.nl-filter-btn-primary:hover {
	background: #3a3a3a;
}

.nl-mobile-filter-dropdown.nl-filter-btn-primary.is-open {
	border-radius: 10px 10px 0 0;
}

.nl-mobile-filter-dropdown.nl-filter-btn-primary .nl-mobile-filter-summary {
	color: #fff;
	font-weight: 500;
	padding: 8px 14px;
}

.nl-mobile-filter-dropdown.nl-filter-btn-primary .nl-mobile-filter-summary::before {
	content: "\f15c";
	font-family: "woodmart-font";
	margin-right: 8px;
	flex-shrink: 0;
	font-size: 1em;
}


.nl-mobile-filter-dropdown.nl-filter-btn-primary .nl-mobile-filter-summary::after {
	border-top-color: rgba(255, 255, 255, 0.9);
}

/* Кнопки атрибутов (Цвет, Класс) — светлые, pill-shaped */
.nl-mobile-filter-dropdown {
	position: relative;
	flex: 0 0 auto;
	min-width: 100px;
	max-width: 200px;
	border-radius: 10px;
	background: #f0eeee;
	transition: background 0.2s ease, color 0.2s ease;
}

.nl-mobile-filter-dropdown:hover {
	background: #e8e6e6;
}

.nl-mobile-filter-summary {
	display: flex;
	align-items: center;
	justify-content: space-between;
	width: 100%;
	padding: 8px 14px;
	font-size: 14px !important;
	font-weight: 500;
	color: #292323;
	background: transparent;
	border: none;
	border-radius: 10px;
	cursor: pointer;
	user-select: none;
	text-align: left;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.nl-mobile-filter-summary::after {
	content: "";
	width: 0;
	height: 0;
	margin-left: 8px;
	border-left: 5px solid transparent;
	border-right: 5px solid transparent;
	border-top: 6px solid currentColor;
	opacity: 0.8;
	flex-shrink: 0;
}

/* При раскрытии на десктопе — кнопка без нижнего скругления */
.nl-mobile-filter-dropdown.is-open:not(.nl-filter-btn-primary) {
	border-radius: 10px 10px 0 0;
	background: #e8e6e6;
}

.nl-mobile-filter-dropdown.is-open .nl-mobile-filter-summary {
	border-radius: 10px 10px 0 0;
}

.nl-mobile-filter-dropdown.is-open .nl-mobile-filter-summary::after {
	transform: rotate(180deg);
}

/* Заголовки кнопок фильтров */
.nl-mobile-filters-wrap .nl-mobile-filter-summary,
.nl-mobile-filters-scroll .nl-mobile-filter-summary {
	font-size: 14px !important;
}

/* --- Bottom sheet на мобилке и планшете (≤ 1024px) --- */
.nl-mobile-filter-backdrop {
	display: none;
	position: fixed;
	inset: 0;
	background: rgba(0, 0, 0, 0.4);
	z-index: 2147483645;
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.25s ease, visibility 0.25s ease;
}

.nl-mobile-filter-backdrop.is-visible {
	display: block;
	opacity: 1;
	visibility: visible;
}

/* Панель: десктоп — под кнопкой; мобилка — bottom sheet --- */
.nl-mobile-filter-panel {
	display: none;
	position: fixed;
	z-index: 2147483646;
	box-sizing: border-box;
	width: 200px;
	max-height: 70vh;
	overflow-y: auto;
	overflow-x: hidden;
	scrollbar-width: none;
	-ms-overflow-style: none;
	padding: 8px 12px 12px !important;
	background: #fff;
	font-size: 14px !important;
	border-radius: 0 0 12px 12px;
	opacity: 0;
	visibility: hidden;
	pointer-events: none;
	transition: opacity 0.2s ease, visibility 0.2s ease;
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.nl-mobile-filter-panel.is-visible {
	display: block;
	opacity: 1;
	visibility: visible;
	pointer-events: auto;
}

/* Мобилка и планшет: bottom sheet — белый блок, скруглённые верхние углы */
@media (max-width: 1024px) {
	.nl-mobile-filter-panel {
		left: 0 !important;
		right: 0 !important;
		width: 100% !important;
		max-width: 100% !important;
		bottom: 0 !important;
		top: auto !important;
		height: auto;
		max-height: 70vh;
		border-radius: 10px 10px 0 0;
		padding: 0 !important;
		transform: translateY(100%);
		transition: transform 0.3s ease, opacity 0.2s ease, visibility 0.2s ease;
		box-shadow: 0 -8px 32px rgba(0, 0, 0, 0.12);
		display: flex;
		flex-direction: column;
		overflow: hidden;
	}

	.nl-mobile-filter-panel.is-visible {
		transform: translateY(0);
	}

	.nl-mobile-filter-panel .nl-filter-panel-header {
		display: flex;
		align-items: center;
		justify-content: space-between;
		padding: 20px 20px 16px;
		flex-shrink: 0;
		background: #fff;
	}

	.nl-mobile-filter-panel .nl-filter-panel-title {
		font-size: 18px;
		font-weight: 700;
		color: #1a1a1a;
		margin: 0;
	}

	.nl-mobile-filter-panel .nl-filter-panel-close {
		width: 40px;
		height: 40px;
		border-radius: 50%;
		background: #e8e6e6;
		border: none;
		cursor: pointer;
		display: flex;
		align-items: center;
		justify-content: center;
		font-size: 22px;
		line-height: 1;
		padding: 0;
		transition: background 0.2s ease;
		color: #1a1a1a;
		font-weight: 300;
	}

	.nl-mobile-filter-panel .nl-filter-panel-close:hover {
		background: #ddd;
	}

	.nl-mobile-filter-panel .nl-filter-panel-inner {
		padding: 0 20px 20px !important;
		flex: 1 1 0;
		min-height: 0;
		max-height: calc(70vh - 120px);
		overflow-y: auto;
		overflow-x: hidden;
		-webkit-overflow-scrolling: touch;
		overscroll-behavior-y: contain;
		touch-action: pan-y;
		overflow-anchor: none;
	}

	.nl-mobile-filter-panel .nl-filter-apply-btn {
		display: flex;
		width: 100%;
		align-items: center;
		justify-content: center;
		padding: 16px 24px;
		background: #282828;
		color: #fff;
		border: none;
		border-radius: 0;
		font-size: 16px;
		font-weight: 600;
		cursor: pointer;
		transition: background 0.2s ease;
		flex-shrink: 0;
		margin: 0;
	}

	.nl-mobile-filter-panel .nl-filter-apply-btn:hover {
		background: #1a1a1a;
	}

	.nl-mobile-filter-panel .widget li,
	.nl-mobile-filter-panel .wc-layered-nav-term,
	.nl-mobile-filter-panel li {
		margin-bottom: 8px !important;
		font-size: 15px !important;
	}

	.nl-mobile-filter-panel .widget a,
	.nl-mobile-filter-panel .layered-nav-link,
	.nl-mobile-filter-panel a {
		display: flex !important;
		align-items: center !important;
		padding: 8px 0 !important;
		font-size: 15px !important;
		color: #1a1a1a !important;
	}

	.nl-mobile-filter-panel input[type="checkbox"] {
		width: 20px;
		height: 20px;
		border-radius: 4px;
		border: 2px solid #ccc;
		margin-right: 12px;
		flex-shrink: 0;
	}

	.nl-mobile-filter-panel input[type="checkbox"]:checked {
		background: #282828;
		border-color: #282828;
	}
}

@media (min-width: 1025px) {
	.nl-mobile-filter-backdrop {
		display: none !important;
	}

	.nl-mobile-filter-panel .nl-filter-panel-header,
	.nl-mobile-filter-panel .nl-filter-panel-close,
	.nl-mobile-filter-panel .nl-filter-apply-btn {
		display: none !important;
	}
}

.nl-mobile-filter-panel .widget,
.nl-mobile-filter-panel .wd-scroll,
.nl-mobile-filter-panel .wd-scroll-content {
	padding: 0 !important;
	margin: 0 !important;
	border: none !important;
	background: transparent !important;
	font-size: 14px !important;
}

.nl-mobile-filter-panel .widget .widget-title,
.nl-mobile-filter-panel .widget .wd-pf-title,
.nl-mobile-filter-panel .widget .title-text {
	font-size: 14px !important;
	font-weight: 600;
	margin-bottom: 4px !important;
}

.nl-mobile-filter-panel .nl-filter-group {
	margin-bottom: 16px;
}

.nl-mobile-filter-panel .nl-filter-group-title {
	font-size: 14px;
	font-weight: 600;
	margin: 0 0 8px;
	color: #292323;
}

.nl-mobile-filter-panel .widget ul,
.nl-mobile-filter-panel .wd-filter-list,
.nl-mobile-filter-panel .wd-swatches-filter,
.nl-mobile-filter-panel ul {
	margin: 0 !important;
	padding: 0 !important;
	list-style: none !important;
}

.nl-mobile-filter-panel .widget li,
.nl-mobile-filter-panel .wc-layered-nav-term,
.nl-mobile-filter-panel li {
	margin-bottom: 2px !important;
	font-size: 14px !important;
	padding: 0 !important;
}

.nl-mobile-filter-panel .widget a,
.nl-mobile-filter-panel .layered-nav-link,
.nl-mobile-filter-panel a {
	display: block !important;
	padding: 2px 0 !important;
	font-size: 14px !important;
}

.nl-mobile-filter-panel .wd-filter-lable,
.nl-mobile-filter-panel .layer-term-lable,
.nl-mobile-filter-panel .count,
.nl-mobile-filter-panel span {
	font-size: 14px !important;
}

.nl-mobile-filter-panel::-webkit-scrollbar {
	display: none;
}

/* Сайдбар: скрываем фильтры, у которых только один пункт выбора */
.wd-sidebar .widget:has(.wd-filter-list > li:only-child),
.wd-sidebar .widget:has(.wc-layered-nav-term:only-child),
.wd-sidebar .widget:has(.layered-nav-link:only-child) {
	display: none;
}

/* Цена "от" в фильтре производителей */
.widget_layered_nav .wc-layered-nav-term:has(.nl-brand-filter-meta),
.woodmart-woocommerce-layered-nav .wc-layered-nav-term:has(.nl-brand-filter-meta),
.woodmart-woocommerce-layered-nav .wd-swatches-filter li:has(.nl-brand-filter-meta) {
	display: grid;
	grid-template-columns: minmax(0, 1fr) auto;
	grid-template-areas:
		"label count"
		"price count";
	column-gap: 10px;
	row-gap: 2px;
	align-items: center;
	margin-bottom: 10px;
}

.widget_layered_nav .wc-layered-nav-term:has(.nl-brand-filter-meta) > a,
.widget_layered_nav .wc-layered-nav-term:has(.nl-brand-filter-meta) > span:first-child,
.woodmart-woocommerce-layered-nav .wc-layered-nav-term:has(.nl-brand-filter-meta) > a,
.woodmart-woocommerce-layered-nav .wc-layered-nav-term:has(.nl-brand-filter-meta) > span:first-child,
.woodmart-woocommerce-layered-nav .wd-swatches-filter li:has(.nl-brand-filter-meta) > a {
	grid-area: label;
	flex: 1 1 auto;
	min-width: 0;
}

.nl-brand-filter-meta {
	display: contents;
	white-space: nowrap;
}

.nl-brand-filter-price {
	grid-area: price;
	display: block;
	color: #1f1f1f;
	font-size: 12px;
	font-weight: 700;
	line-height: 1.2;
}

.nl-brand-filter-meta .count {
	grid-area: count;
	align-self: center;
	margin-top: 0;
}

.nl-brand-filter-price-prefix {
	color: #7b6664;
	font-weight: 500;
}

.nl-brand-filter-price-unit {
	margin-left: 2px;
	color: #6f6f6f;
	font-size: 11px;
	font-weight: 500;
}

.nl-mobile-filter-panel .nl-brand-filter-meta {
	font-size: 12px !important;
}

.nl-mobile-filter-panel .nl-brand-filter-price,
.nl-mobile-filter-panel .nl-brand-filter-price-prefix,
.nl-mobile-filter-panel .nl-brand-filter-price-unit {
	font-size: 12px !important;
}

/* Кнопки социальных сетей (Telegram и VK) */
.nl-social-buttons {
	position: fixed;
	right: 20px;
	bottom: 80px;
	z-index: 349;
	display: flex;
	flex-direction: column;
	gap: 5px;
}

/* Переопределяем все возможные стили Woodmart для иконок */
.nl-social-buttons .nl-social-btn .wd-icon,
.nl-social-buttons .nl-social-btn .wd-icon:before,
.nl-social-buttons .nl-social-btn.wd-social-icon .wd-icon,
.nl-social-buttons .nl-social-btn.wd-social-icon .wd-icon:before {
	background: transparent !important;
	background-color: transparent !important;
}

.nl-social-btn {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 50px;
	height: 50px;
	border-radius: 50%;
	border: none !important;
	outline: none !important;
	box-shadow: none;
	color: #fff !important;
	text-decoration: none !important;
	transition: box-shadow 0.3s ease;
	backface-visibility: hidden;
	-webkit-backface-visibility: hidden;
	overflow: hidden;
}

.nl-telegram-btn {
	background-color: #0088cc !important;
}

.nl-telegram-btn:hover {
	box-shadow: 0 2px 8px rgba(0, 136, 204, 0.4);
}

.nl-vk-btn {
	background-color: #0077ff !important;
}

.nl-vk-btn:hover {
	box-shadow: 0 2px 8px rgba(0, 119, 255, 0.4);
}

/* Убеждаемся, что классы social-tg и social-vk применяют CSS переменные */
.nl-social-btn.social-tg,
.nl-social-btn.social-tg.wd-social-icon {
	--wd-social-icon: "\f179";
	border: none !important;
	box-shadow: none !important;
	background-color: #0088cc !important;
	background: #0088cc !important;
}

.nl-social-btn.social-tg .wd-icon,
.nl-social-btn.social-tg .wd-icon:before,
.nl-social-btn.social-tg.wd-social-icon .wd-icon,
.nl-social-btn.social-tg.wd-social-icon .wd-icon:before {
	color: #fff !important;
	background: transparent !important;
	background-color: transparent !important;
}

.nl-social-btn.social-vk,
.nl-social-btn.social-vk.wd-social-icon {
	--wd-social-icon: "\f168";
	border: none !important;
	box-shadow: none !important;
	background-color: #0077ff !important;
	background: #0077ff !important;
}

.nl-social-btn.social-vk .wd-icon,
.nl-social-btn.social-vk .wd-icon:before,
.nl-social-btn.social-vk.wd-social-icon .wd-icon,
.nl-social-btn.social-vk.wd-social-icon .wd-icon:before {
	color: #fff !important;
	background: transparent !important;
	background-color: transparent !important;
}

.nl-social-btn .wd-icon {
	font-size: 20px;
	line-height: 50px;
	display: block;
	color: #fff !important;
	width: 100%;
	height: 100%;
	text-align: center;
	background: transparent !important;
	background-color: transparent !important;
}

.nl-social-btn .wd-icon:before {
	content: var(--wd-social-icon) !important;
	font-family: "woodmart-font" !important;
	color: #fff !important;
	font-size: inherit;
	line-height: inherit;
	display: inline-block;
	background: transparent !important;
	background-color: transparent !important;
}

/* Убираем белый фон, который может добавлять Woodmart */
.nl-social-btn.wd-social-icon,
.nl-social-btn.wd-social-icon .wd-icon,
.nl-social-btn.wd-social-icon .wd-icon:before {
	background: transparent !important;
	background-color: transparent !important;
}

/* Адаптивность для кнопок социальных сетей */
@media (max-width: 1024px) {
	.nl-social-buttons {
		right: 12px;
		bottom: 117px; /* 12px (scrollToTop bottom) + 40px (scrollToTop height) + 15px (отступ) + 40px (VK height) + 10px (дополнительный отступ для комфорта) */
	}
	
	.nl-social-btn {
		width: 40px;
		height: 40px;
	}
	
	.nl-social-btn .wd-icon {
		font-size: 18px;
		line-height: 40px;
	}
}

/* Скрываем кнопки при открытом поиске (как scrollToTop) */
.wd-search-opened .nl-social-buttons {
	display: none;
}

/* --- Миниатюры карусели галереи товара (ПК): устраняем «сплюснутость» ---
   Контейнер миниатюр мог получать слишком малую высоту (напр. из JS по offsetHeight),
   из‑за чего слайды сжимались до ~32px. min-height держит размер, img — квадрат 1:1. */
@media (min-width: 1025px) {
	.woocommerce-product-gallery.thumbs-position-left .wd-gallery-thumb {
		min-height: 320px;
	}
	.thumbs-position-left .wd-gallery-thumb .wd-carousel {
		min-height: 290px;
	}
	.thumbs-position-left .wd-gallery-thumb .wd-carousel-item {
		min-height: 90px;
	}
}

/* Миниатюры карусели галереи — квадрат 1:1 (все позиции: слева, снизу).
   Ячейки слайдов не квадратные (высота задаётся Swiper/темой), поэтому
   рисуем img по меньшей стороне и центрируем в ячейке. */
.wd-gallery-thumb .wd-carousel-item {
	display: flex;
	justify-content: center;
	align-items: center;
}

.wd-gallery-thumb .wd-carousel-item img {
	height: calc(100% - var(--wd-gap, 10px));
	width: auto;
	aspect-ratio: 1 / 1;
	object-fit: cover;
	margin-bottom: var(--wd-gap, 10px);
	max-width: 100%;
	display: block;
}

/* --- Квадратные изображения товаров (1:1) ---
   Каталог, карусели товаров, основная галерея на странице товара. */
.woocommerce ul.products li.product a img,
.woocommerce div.product .wd-gallery-images img {
	object-fit: cover;
	aspect-ratio: 1 / 1;
	width: 100%;
	display: block;
}

/* Квадратные изображения в виджетах Elementor (product-card-image) */
.elementor-widget-image.product-card-image {
	position: relative;
	width: 100%;
	overflow: hidden;
	aspect-ratio: 1 / 1;
}

.elementor-widget-image.product-card-image img,
.elementor-widget-image.product-card-image .elementor-image,
.elementor-widget-image.product-card-image .elementor-image-wrapper {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

@supports not (aspect-ratio: 1 / 1) {
	.elementor-widget-image.product-card-image {
		height: 0;
		padding-top: 100%;
	}

	.elementor-widget-image.product-card-image img {
		position: absolute;
		top: 0;
		left: 0;
		height: 100%;
	}
}

/* --- Свотчи «Цвета пороги»: квадратики с картинкой и подписью снизу --- */
.nl-swatches-image-with-label.wd-swatches-product {
	display: grid;
	grid-auto-flow: column;
	grid-auto-columns: minmax(64px, max-content);
	align-items: start;
	gap: 10px;
	overflow-x: auto;
	overflow-y: hidden;
	scroll-snap-type: x mandatory;
	-webkit-overflow-scrolling: touch;
	touch-action: pan-x;
	padding: 2px 2px 8px;
	width: 100%;
	max-width: 100%;
	min-width: 0;
	box-sizing: border-box;
	scrollbar-width: thin;
}

.nl-swatches-product.nl-swatches-image-with-label {
	position: relative !important;
	left: auto !important;
	right: auto !important;
	top: auto !important;
	bottom: auto !important;
	transform: none !important;
	float: none !important;
	display: flex;
	flex-wrap: nowrap;
	align-items: flex-start;
	gap: 10px;
	overflow-x: auto;
	overflow-y: hidden;
	scroll-snap-type: x mandatory;
	-webkit-overflow-scrolling: touch;
	touch-action: pan-x;
	padding: 2px 2px 8px;
	width: 100%;
	max-width: 100%;
	min-width: 0;
	box-sizing: border-box;
	margin: 0 !important;
	scrollbar-width: none;
	-ms-overflow-style: none;
}

.nl-swatches-product.nl-swatches-image-with-label::-webkit-scrollbar {
	display: none;
	width: 0;
	height: 0;
}

.nl-swatches-image-with-label .wd-swatch {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 6px;
	flex: 0 0 auto;
	width: 64px;
	min-width: 64px;
	cursor: pointer;
	scroll-snap-align: start;
	box-sizing: border-box;
	position: relative;
	z-index: 2;
	pointer-events: auto;
}

.nl-swatches-product.nl-swatches-image-with-label .nl-swatch {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 6px;
	flex: 0 0 auto;
	width: 72px;
	min-width: 72px;
	cursor: pointer;
	scroll-snap-align: start;
	box-sizing: border-box;
	position: relative;
	z-index: 2;
	pointer-events: auto;
}

.nl-swatches-image-with-label .wd-swatch-bg {
	width: 52px;
	height: 52px;
	min-width: 52px;
	min-height: 52px;
	border-radius: 4px;
	overflow: hidden;
	display: flex;
	align-items: center;
	justify-content: center;
	border: 1px solid rgba(0, 0, 0, 0.08);
	background: #f5f5f5;
	transition: border-color 0.2s, box-shadow 0.2s;
}

.nl-swatches-product.nl-swatches-image-with-label .nl-swatch-bg {
	width: 56px;
	aspect-ratio: 1 / 1;
	height: auto;
	min-width: 56px;
	border-radius: 4px;
	overflow: hidden;
	display: flex;
	align-items: center;
	justify-content: center;
	border: 1px solid rgba(0, 0, 0, 0.12);
	background: #fff;
	transition: border-color 0.2s, box-shadow 0.2s;
}

.nl-swatches-image-with-label .wd-swatch:hover .wd-swatch-bg,
.nl-swatches-image-with-label .wd-swatch.wd-active .wd-swatch-bg {
	border-color: #9c2422;
	box-shadow: 0 0 0 2px #9c2422;
}

.nl-swatches-product.nl-swatches-image-with-label .nl-swatch:hover .nl-swatch-bg,
.nl-swatches-product.nl-swatches-image-with-label .nl-swatch.is-active .nl-swatch-bg {
	border-color: #9c2422;
	box-shadow: 0 0 0 2px #9c2422;
}

.nl-swatches-product.nl-swatches-image-with-label.nl-swatches-text-rect {
	display: grid !important;
	grid-template-columns: repeat(auto-fit, minmax(80px, 1fr)) !important;
	gap: 8px !important;
	align-items: stretch !important;
	overflow: visible !important;
	scroll-snap-type: none !important;
	padding-right: 2px !important;
}

.nl-swatches-product.nl-swatches-image-with-label.nl-swatches-text-rect .nl-swatch {
	width: 100% !important;
	min-width: 0 !important;
}

.nl-swatches-product.nl-swatches-image-with-label.nl-swatches-text-rect .nl-swatch-bg,
.nl-swatches-product.nl-swatches-image-with-label.nl-swatches-text-rect .nl-swatch-text {
	display: none !important;
}

.nl-swatches-product.nl-swatches-image-with-label.nl-swatches-text-rect .nl-swatch-pill {
	display: flex !important;
	align-items: center !important;
	justify-content: center !important;
	width: 100% !important;
	min-height: 32px !important;
	padding: 3px 8px !important;
	border-radius: 10px !important;
	border: 1px solid #d8c5c1 !important;
	background: linear-gradient(180deg, #fff 0%, #fcf8f7 100%) !important;
	color: #292323 !important;
	font-size: 12px !important;
	line-height: 1.2 !important;
	white-space: nowrap !important;
	font-weight: 600 !important;
	letter-spacing: 0.01em !important;
	box-shadow: none !important;
	transition: border-color 0.2s ease, background-color 0.2s ease, color 0.2s ease !important;
}

.nl-swatches-product.nl-swatches-image-with-label.nl-swatches-text-rect .nl-swatch:hover .nl-swatch-pill {
	border-color: #9c2422 !important;
	background: #fff3f1 !important;
	color: #9c2422 !important;
	box-shadow: none !important;
	transform: none !important;
}

.nl-swatches-product.nl-swatches-image-with-label.nl-swatches-text-rect .nl-swatch.is-active .nl-swatch-pill {
	border-color: #9c2422 !important;
	background: #9c2422 !important;
	box-shadow: none !important;
	color: #fff !important;
	font-weight: 700 !important;
}

.nl-swatches-product.nl-swatches-image-with-label.nl-swatches-text-rect .nl-swatch.is-disabled .nl-swatch-pill {
	border-color: #d7d7d7 !important;
	background: #f3f3f3 !important;
	color: #9b9b9b !important;
	box-shadow: none !important;
	transform: none !important;
}

.nl-swatches-image-with-label .wd-swatch-bg img {
	width: 100%;
	height: 100%;
	object-fit: contain;
	background: #fff;
	display: block;
}

.nl-swatches-product.nl-swatches-image-with-label .nl-swatch-bg img {
	width: 100%;
	height: 100%;
	object-fit: contain;
	background: #fff;
	display: block;
	pointer-events: none;
	-webkit-user-drag: none;
	user-select: none;
}

.nl-swatches-image-with-label .wd-swatch-text {
	display: block;
	font-size: 10px !important;
	line-height: 1.2;
	text-align: center;
	color: #555;
	max-width: 64px;
	white-space: normal;
	word-break: break-word;
	overflow-wrap: anywhere;
}

.nl-swatches-product.nl-swatches-image-with-label .nl-swatch-text {
	display: block !important;
	font-size: 11px !important;
	line-height: 1.2;
	text-align: center;
	color: #555;
	max-width: 72px;
	white-space: normal;
	word-break: break-word;
	overflow-wrap: anywhere;
	opacity: 1 !important;
	visibility: visible !important;
}

.nl-swatches-image-with-label .wd-swatch.wd-active .wd-swatch-text {
	color: #1a1a1a !important;
	font-weight: 700 !important;
}

.nl-swatches-product.nl-swatches-image-with-label .nl-swatch.is-active .nl-swatch-text {
	color: #1a1a1a !important;
	font-weight: 700 !important;
}

.nl-swatches-image-with-label .wd-swatch.wd-disabled {
	opacity: 0.5;
}

.nl-swatches-product.nl-swatches-image-with-label .nl-swatch.is-disabled {
	opacity: 0.5;
}

/* Для этого атрибута делаем заголовок фильтра сверху. */
.variations tr.nl-swatches-carousel-row .label.cell {
	display: none;
}

.variations tr.nl-swatches-carousel-row {
	display: block !important;
	width: 100% !important;
}

.variations tr.nl-swatches-carousel-row .value.cell {
	display: block;
	width: 100%;
	max-width: 100%;
	padding-left: 0;
	overflow: hidden;
	box-sizing: border-box;
	min-width: 0;
	position: relative;
}

.nl-swatches-filter-title {
	display: block;
	margin-bottom: 8px;
	padding: 0;
	border: 0;
	background: transparent;
	font-size: 13px;
	font-weight: 600;
	line-height: 1.25;
	letter-spacing: normal;
	text-transform: none;
	color: #2c2c2c;
}

.variations tr.nl-swatches-carousel-row select {
	display: none !important;
}

/* Страхуемся от стилей темы, которые могут скрывать подпись. */
.nl-swatches-image-with-label .wd-swatch .wd-swatch-text {
	display: block !important;
	opacity: 1 !important;
	visibility: visible !important;
}

/* Цена подкатегории ниже заголовка, но в пределах одной карточки */
.nl-subcat-meta {
	margin-top: 2px;
}

.nl-subcat-price {
	display: block;
	margin-top: 0;
	color: #1f1f1f;
	font-size: 12.5px;
	font-weight: 700;
	line-height: 1.25;
}

.nl-subcat-price-prefix {
	color: #7b6664;
	font-weight: 500;
	text-transform: none;
}

.nl-subcat-price-unit {
	margin-left: 4px;
	color: #6f6f6f;
	font-size: 11px;
	font-weight: 500;
}

/*
 * Плитка категорий (cat-design-alt): одна высота превью для любых пропорций логотипов.
 * Без этого горизонтальные PNG (например Tarkett) дают низкий блок и съезжают заголовки/цены.
 */
.category-grid-item.cat-design-alt .wd-cat-thumb {
	aspect-ratio: 1 / 1;
	width: 100%;
	display: flex;
	align-items: center;
	justify-content: center;
}

.category-grid-item.cat-design-alt .wd-cat-image {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 100%;
	margin: 0;
	min-height: 0;
}

.category-grid-item.cat-design-alt .wd-cat-thumb img {
	max-width: 100%;
	max-height: 100%;
	width: auto;
	height: auto;
	object-fit: contain;
	object-position: center;
}

/* Шапка: контактные «пилюли» (Elementor CMS blocks 2988 / 172) */
.whb-general-header .elementor-2988,
.whb-general-header .elementor-172 {
	width: 100%;
}

.whb-general-header .elementor-2988 > .e-con,
.whb-general-header .elementor-172 > .e-con {
	width: auto;
	max-width: 100%;
}

.whb-general-header .elementor-2988 .wd-text-block p {
	margin: 0;
	color: #727272;
}

.whb-general-header .elementor-172 .wd-text-block p {
	margin: 0;
	white-space: normal;
	line-height: 1.45;
}

@media (max-width: 1024px) {
	.whb-general-header .elementor-2988 > .e-con,
	.whb-general-header .elementor-172 > .e-con {
		padding: 8px 12px !important;
	}

	.whb-general-header .elementor-172 .wd-text-block p {
		font-size: 14px !important;
	}
}

@media (max-width: 1024px) {
	.nl-social-buttons {
		z-index: 348;
	}
}
