/*
Theme Name: Sfera Tepla — каталог (Astra child)
Template: astra
Description: Каталог с высокой плотностью информации: плитки подкатегорий, плотные карточки товаров, хлебные крошки, адаптив.
Version: 1.0.0
*/

/* ---------- Дизайн-токены ---------- */
:root {
  --st-bg: #ffffff;
  --st-bg-alt: #f5f7f9;
  --st-text: #16181b;
  --st-muted: #5b6470;
  --st-border: #e2e6ea;
  --st-accent: #0b6bcb;
  --st-accent-hover: #0957a6;
  --st-accent-soft: #e8f1fb;
  --st-success: #1d7a3c;
  --st-warning: #b26a00;
  --st-danger: #b3261e;
  --st-radius: 6px;
  --st-radius-lg: 10px;
  --st-container: 1440px;
  --st-gap: 16px;
  --st-font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --st-fs-xs: 12px;
  --st-fs-sm: 13px;
  --st-fs-base: 15px;
  --st-fs-lg: 17px;
  --st-fs-xl: 22px;
  --st-fs-2xl: 28px;
  --st-line: 1.45;
}

body { font-family: var(--st-font); color: var(--st-text); background: var(--st-bg); line-height: var(--st-line); }
.ast-container, .site-content .ast-container { max-width: var(--st-container); }

/* Табличные цифры для цен и параметров */
.woocommerce-Price-amount, .price, .st-num, .st-spec-value, .st-count { font-variant-numeric: tabular-nums; }

/* ---------- Хлебные крошки ---------- */
.st-breadcrumbs { font-size: var(--st-fs-sm); color: var(--st-muted); margin: 12px 0 18px; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.st-breadcrumbs a { color: var(--st-muted); text-decoration: none; }
.st-breadcrumbs a:hover, .st-breadcrumbs a:focus { color: var(--st-accent); text-decoration: underline; }
.st-breadcrumbs .st-sep { opacity: .5; }
.st-breadcrumbs .st-current { color: var(--st-text); }
@media (max-width: 767px) { .st-breadcrumbs { font-size: var(--st-fs-xs); } }

/* ---------- Плитки подкатегорий ---------- */
.st-cats { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: var(--st-gap); margin: 0 0 28px; }
.st-cat { display: flex; flex-direction: column; border: 1px solid var(--st-border); border-radius: var(--st-radius-lg); overflow: hidden; background: var(--st-bg); text-decoration: none; color: var(--st-text); transition: border-color .15s, box-shadow .15s, transform .15s; }
.st-cat:hover, .st-cat:focus-within { border-color: var(--st-accent); box-shadow: 0 4px 16px rgba(11,107,203,.10); transform: translateY(-1px); }
.st-cat:focus { outline: 2px solid var(--st-accent); outline-offset: 2px; }
.st-cat-img { aspect-ratio: 4 / 3; background: var(--st-bg-alt); display: flex; align-items: center; justify-content: center; }
.st-cat-img img { width: 100%; height: 100%; object-fit: contain; padding: 12px; }
.st-cat-body { padding: 10px 12px 12px; display: flex; flex-direction: column; gap: 4px; }
.st-cat-name { font-size: var(--st-fs-base); font-weight: 600; line-height: 1.25; }
.st-cat-count { font-size: var(--st-fs-xs); color: var(--st-muted); }
@media (max-width: 767px) { .st-cats { grid-template-columns: repeat(2, 1fr); gap: 10px; } }

/* ---------- Заголовки разделов ---------- */
.st-section-title { font-size: var(--st-fs-xl); font-weight: 700; margin: 8px 0 14px; letter-spacing: -.01em; }
@media (max-width: 767px) { .st-section-title { font-size: var(--st-fs-lg); } }

/* ---------- Карточки товаров: плотность ---------- */
ul.products { display: grid; gap: var(--st-gap); grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); margin: 0; }
ul.products li.product { width: 100% !important; margin: 0 !important; float: none !important; border: 1px solid var(--st-border); border-radius: var(--st-radius-lg); padding: 0; overflow: hidden; background: var(--st-bg); display: flex; flex-direction: column; transition: border-color .15s, box-shadow .15s; }
ul.products li.product:hover { border-color: #c9d2dc; box-shadow: 0 4px 14px rgba(16,24,40,.06); }
ul.products li.product a img { margin: 0; aspect-ratio: 1 / 1; object-fit: contain; padding: 12px; background: #fff; }
ul.products li.product .woocommerce-loop-product__title { font-size: var(--st-fs-base); font-weight: 600; line-height: 1.3; padding: 10px 12px 4px !important; min-height: 40px; }
ul.products li.product .price { padding: 0 12px; font-size: var(--st-fs-lg); font-weight: 700; color: var(--st-text); }
ul.products li.product .price del { color: var(--st-muted); font-weight: 400; font-size: var(--st-fs-sm); }
ul.products li.product .price ins { color: var(--st-danger); text-decoration: none; }
ul.products li.product .button { margin: 10px 12px 12px !important; }
ul.products li.product .st-specs { padding: 6px 12px 0; font-size: var(--st-fs-xs); color: var(--st-muted); display: flex; flex-direction: column; gap: 2px; }
ul.products li.product .st-specs .st-spec { display: flex; justify-content: space-between; gap: 8px; }
.st-spec-value { color: var(--st-text); font-weight: 600; }
.st-spec-unit { color: var(--st-muted); font-weight: 400; font-size: .92em; margin-left: 2px; }

/* Наличие */
.st-stock { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px 0; font-size: var(--st-xs, 12px); }
.st-stock::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--st-success); }
.st-stock.st-out::before { background: var(--st-danger); }
.st-stock.st-out { color: var(--st-danger); }

/* ---------- Кнопки ---------- */
.woocommerce a.button, .woocommerce button.button, .woocommerce input.button, .wp-block-button__link {
  background: var(--st-accent); color: #fff; border-radius: var(--st-radius); font-weight: 600; font-size: var(--st-fs-sm);
  padding: 10px 16px; line-height: 1.2; border: none; transition: background .15s, box-shadow .15s; text-decoration: none;
}
.woocommerce a.button:hover, .woocommerce button.button:hover, .woocommerce input.button:hover { background: var(--st-accent-hover); color: #fff; }
.woocommerce a.button:focus-visible, .woocommerce button.button:focus-visible, .st-cat:focus-visible { outline: 2px solid var(--st-accent); outline-offset: 2px; }
.woocommerce a.button.alt, .woocommerce button.button.alt { background: var(--st-accent); }

/* ---------- Меню каталога (2 уровня) ---------- */
.st-menu-2lvl { display: none; }
@media (min-width: 1024px) {
  .st-menu-2lvl { display: block; }
}

/* Мобильная шторка каталога */
.st-sheet { position: fixed; inset: 0; z-index: 9999; background: #fff; transform: translateX(100%); transition: transform .2s ease; overflow-y: auto; }
.st-sheet.is-open { transform: translateX(0); }
.st-sheet-head { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-bottom: 1px solid var(--st-border); position: sticky; top: 0; background: #fff; }
.st-sheet-back { border: none; background: none; font-size: var(--st-fs-base); color: var(--st-accent); padding: 8px; cursor: pointer; }
.st-sheet-list { list-style: none; margin: 0; padding: 8px 0; }
.st-sheet-list li a { display: flex; justify-content: space-between; align-items: center; padding: 14px 16px; color: var(--st-text); text-decoration: none; border-bottom: 1px solid var(--st-border); font-size: var(--st-fs-base); }
.st-sheet-list li a:hover { background: var(--st-bg-alt); }

/* ---------- Адаптив ---------- */
@media (max-width: 1280px) { :root { --st-gap: 14px; } }
@media (max-width: 1024px) { ul.products { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 767px) {
  :root { --st-gap: 10px; --st-fs-xl: 19px; }
  ul.products { grid-template-columns: repeat(2, 1fr); }
  ul.products li.product .price { font-size: var(--st-fs-base); }
  ul.products li.product .woocommerce-loop-product__title { font-size: var(--st-fs-sm); min-height: 36px; }
}
@media (max-width: 380px) { ul.products { grid-template-columns: 1fr 1fr; } }

/* ---------- Меню каталога: десктоп 2 уровня ---------- */
.st-menu-wrap { position: relative; margin: 0 0 20px; }
.st-menu-toggle { display: inline-flex; align-items: center; gap: 8px; padding: 11px 18px; border: 1px solid var(--st-border); background: #fff; border-radius: var(--st-radius); font-size: var(--st-fs-base); font-weight: 600; color: var(--st-text); cursor: pointer; }
.st-menu-toggle:hover { border-color: var(--st-accent); color: var(--st-accent); }
.st-menu-toggle::before { content: ""; width: 14px; height: 10px; background: currentColor; clip-path: polygon(0 0, 100% 0, 100% 20%, 0 20%, 0 40%, 100% 40%, 100% 60%, 0 60%, 0 80%, 100% 80%, 100% 100%, 0 100%); }
.st-menu-desktop { display: none; }
@media (min-width: 1024px) {
  .st-menu-toggle { display: none; }
  .st-menu-desktop { display: block; }
  .st-menu-root { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 4px; border-bottom: 1px solid var(--st-border); }
  .st-menu-item { position: relative; }
  .st-menu-link { display: block; padding: 12px 14px; font-size: var(--st-fs-base); font-weight: 600; color: var(--st-text); text-decoration: none; border-bottom: 2px solid transparent; }
  .st-menu-item:hover > .st-menu-link, .st-menu-item:focus-within > .st-menu-link { color: var(--st-accent); border-bottom-color: var(--st-accent); }
  .st-menu-panel { position: absolute; top: 100%; left: 0; z-index: 500; min-width: 640px; max-width: 1100px; background: #fff; border: 1px solid var(--st-border); border-radius: 0 0 var(--st-radius-lg) var(--st-radius-lg); box-shadow: 0 18px 40px rgba(16,24,40,.12); padding: 20px; opacity: 0; visibility: hidden; transform: translateY(6px); transition: opacity .15s ease .18s, transform .15s ease .18s, visibility 0s linear .33s; }
  .st-menu-item:hover > .st-menu-panel, .st-menu-item:focus-within > .st-menu-panel { opacity: 1; visibility: visible; transform: translateY(0); transition-delay: .18s, .18s, 0s; }
  .st-menu-cols { column-width: 240px; column-gap: 24px; }
  .st-menu-col { break-inside: avoid; margin: 0 0 16px; }
  .st-menu-col-title { display: block; font-size: var(--st-fs-base); font-weight: 600; color: var(--st-text); text-decoration: none; margin-bottom: 6px; }
  .st-menu-col-title:hover { color: var(--st-accent); }
  .st-menu-sub { list-style: none; margin: 0; padding: 0; }
  .st-menu-sub li { margin: 0 0 4px; }
  .st-menu-sub a { font-size: var(--st-fs-sm); color: var(--st-muted); text-decoration: none; }
  .st-menu-sub a:hover { color: var(--st-accent); text-decoration: underline; }
}

/* ---------- Мобильная шторка ---------- */
.st-sheet { position: fixed; inset: 0; z-index: 99999; background: #fff; display: flex; flex-direction: column; transform: translateX(100%); transition: transform .2s ease; }
.st-sheet.is-open { transform: translateX(0); }
.st-sheet-head { display: flex; align-items: center; gap: 10px; padding: 14px 16px; border-bottom: 1px solid var(--st-border); background: #fff; }
.st-sheet-title { font-size: var(--st-fs-lg); font-weight: 700; flex: 1; }
.st-sheet-back, .st-sheet-close { border: none; background: none; font-size: var(--st-fs-lg); color: var(--st-accent); cursor: pointer; padding: 6px 8px; }
.st-sheet-body { overflow-y: auto; -webkit-overflow-scrolling: touch; }
.st-sheet-list { list-style: none; margin: 0; padding: 0; }
.st-sheet-list li a { display: flex; justify-content: space-between; align-items: center; padding: 14px 16px; border-bottom: 1px solid var(--st-border); color: var(--st-text); text-decoration: none; font-size: var(--st-fs-base); }
.st-sheet-list li a:hover { background: var(--st-bg-alt); }
.st-sheet-arrow { color: var(--st-muted); font-size: var(--st-fs-lg); }
.st-sheet-sub { padding-left: 12px; }
@media (min-width: 1024px) { .st-sheet { display: none; } }

/* Скрыть значок WhatsApp в шапке (элемент конструктора Astra) */
.ast-builder-social-element[aria-label="WhatsApp"],
.header-social-item[aria-label="WhatsApp"] { display: none !important; }

/* Наличие показывает наша разметка (.st-stock), штатную метку Astra скрываем */
.ast-shop-product-out-of-stock { display: none !important; }

/* Убрать «Читать далее» на плитках: иконку Astra и штатную кнопку WC для товаров без наличия */
ul.products li.product .ast-on-card-button,
ul.products li.product .ast-card-action-tooltip,
ul.products li.product.outofstock .button.product_type_simple,
ul.products li.product.outofstock .added_to_cart { display: none !important; }

/* Фото товара целиком в плитке (без обрезки) */
ul.products li.product .astra-shop-thumbnail-wrap { aspect-ratio: 1 / 1; display: flex; align-items: center; justify-content: center; background: #fff; overflow: hidden; }
ul.products li.product .astra-shop-thumbnail-wrap img,
ul.products li.product a img { width: 100%; height: 100%; object-fit: contain !important; margin: 0 !important; padding: 10px; background: #fff; }

/* ---------- Наличие на складах поставщика ---------- */
.st-supplier { position: relative; margin: 14px 0 18px; }
.st-supplier summary { cursor: pointer; list-style: none; display: flex; flex-wrap: nowrap; align-items: center; gap: 6px; font-size: var(--st-fs-sm); color: var(--st-text); user-select: none; white-space: nowrap; }
.st-supplier summary > span { white-space: nowrap; }
.st-supplier summary::-webkit-details-marker { display: none; }
.st-supplier summary::marker { content: ''; }
.st-supplier-ok { color: #1d7a3c; font-weight: 700; font-size: var(--st-fs-lg); line-height: 1; }
.st-supplier-label { color: var(--st-muted); font-size: var(--st-fs-sm); white-space: nowrap; }
.st-supplier-total { font-weight: 700; color: #1d7a3c; font-variant-numeric: tabular-nums; font-size: var(--st-fs-base); white-space: nowrap; }
.st-supplier-link { color: var(--st-accent); font-size: var(--st-fs-xs); border-bottom: 1px dotted currentColor; white-space: nowrap; }
.st-supplier summary:hover .st-supplier-link { color: var(--st-accent-hover); }
.st-warehouses { position: absolute; top: calc(100% + 10px); left: 0; z-index: 60; min-width: 300px; max-width: 380px; background: #fff; border: 1px solid var(--st-border); border-radius: 12px; box-shadow: 0 16px 40px rgba(16,24,40,.18); padding: 16px 18px; }
.st-warehouses-title { font-weight: 700; font-size: var(--st-fs-lg); margin: 0 0 6px; padding-bottom: 10px; border-bottom: 1px solid #eef1f4; }
.st-warehouses ul { list-style: none; margin: 0; padding: 0; }
.st-warehouses li { padding: 9px 0; }
.st-warehouse-name { display: block; font-weight: 700; font-size: var(--st-fs-base); margin-bottom: 3px; color: var(--st-text); }
.st-warehouse-qty { color: #1d7a3c; font-size: var(--st-fs-sm); }
.st-warehouse-qty::before { content: '✓'; font-weight: 700; margin-right: 6px; }
.st-warehouses-date { margin-top: 10px; padding-top: 10px; border-top: 1px solid #eef1f4; font-size: 11px; color: var(--st-muted); }


/* ---------- Фильтр по характеристикам ---------- */
.st-filters { border: 1px solid var(--st-border); border-radius: var(--st-radius-lg); margin: 0 0 18px; background: #fff; }
.st-filters-head { display: flex; align-items: center; gap: 12px; padding: 10px 14px; border-bottom: 1px solid var(--st-border); flex-wrap: wrap; }
.st-filters-title { font-weight: 700; font-size: var(--st-fs-base); }
.st-filters-count { color: var(--st-muted); font-size: var(--st-fs-sm); }
.st-filters-reset { margin-left: auto; font-size: var(--st-fs-sm); color: var(--st-accent); text-decoration: none; }
.st-filters-reset:hover { text-decoration: underline; }
.st-filters-apply { padding: 8px 18px !important; }
.st-filters-body { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 0 20px; padding: 6px 14px 12px; }
.st-filter { border-bottom: 1px solid #eef1f4; padding: 6px 0; }
.st-filter:last-child { border-bottom: none; }
.st-filter summary { cursor: pointer; font-weight: 600; font-size: var(--st-fs-sm); padding: 4px 0; color: var(--st-text); }
.st-filter summary:hover { color: var(--st-accent); }
.st-filter-terms { max-height: 230px; overflow-y: auto; padding: 4px 0 6px; display: flex; flex-direction: column; gap: 3px; }
.st-filter-terms label { display: flex; align-items: center; gap: 7px; font-size: var(--st-fs-sm); color: var(--st-text); cursor: pointer; }
.st-filter-terms input[type="checkbox"] { accent-color: var(--st-accent); }
.st-filter-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.st-filter-count { margin-left: auto; color: var(--st-muted); font-size: var(--st-fs-xs); font-variant-numeric: tabular-nums; }
.st-filters-empty { padding: 0 14px 14px; color: var(--st-muted); font-size: var(--st-fs-sm); }
@media (max-width: 767px) { .st-filters-body { grid-template-columns: 1fr 1fr; } }

/* ---------- Жёсткая сетка плиток: 6 в ряд на десктопе ---------- */
ul.products {
	display: grid !important;
	grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)) !important;
	gap: var(--st-gap) !important;
	margin: 0 0 24px !important;
	padding: 0 !important;
	list-style: none !important;
}
ul.products li.product,
ul.products li.ast-grid-common-col {
	width: auto !important;
	max-width: none !important;
	margin: 0 !important;
	padding-left: 0 !important;
	padding-right: 0 !important;
	float: none !important;
	clear: none !important;
}
ul.products li.product .woocommerce-loop-product__title { font-size: var(--st-fs-base) !important; line-height: 1.3 !important; }
ul.products li.product .price { font-size: var(--st-fs-lg) !important; font-weight: 700 !important; color: var(--st-text) !important; }
ul.products li.product .ast-woo-product-category { font-size: var(--st-fs-xs); color: var(--st-muted); }
@media (max-width: 1100px) { ul.products { grid-template-columns: repeat(4, 1fr) !important; } }
@media (max-width: 860px) { ul.products { grid-template-columns: repeat(3, 1fr) !important; } }
@media (max-width: 640px) { ul.products { grid-template-columns: repeat(2, 1fr) !important; } }

/* ---------- Карточка товара: порядок и отступы ---------- */
ul.products li.product .ast-woo-product-category { display: none !important; }
ul.products li.product .st-stock { padding: 8px 12px 0; }
ul.products li.product .st-specs { padding: 6px 12px 12px; }
ul.products li.product .woocommerce-loop-product__title { padding: 10px 12px 2px !important; }
ul.products li.product .price { padding: 0 12px 4px; }
ul.products li.product .astra-shop-thumbnail-wrap { aspect-ratio: 4 / 3; }

/* Наличие: только для товаров в наличии, зелёным */
ul.products li.product .st-stock { color: var(--st-success) !important; font-weight: 600; }
ul.products li.product .st-stock::before { background: var(--st-success) !important; }
p.st-single-stock { color: var(--st-success) !important; font-weight: 600; }

/* Наличие в карточке товара: «Нет в наличии» не показываем, «В наличии» — зелёным */
p.stock.out-of-stock, .woocommerce div.product p.stock.out-of-stock { display: none !important; }
p.stock.in-stock, .woocommerce div.product p.stock.in-stock { color: #1d7a3c !important; font-weight: 600; background: #eef8f1; border-radius: 6px; padding: 4px 10px; display: inline-block; }

@media (max-width: 480px) {
	.st-supplier summary { white-space: normal; flex-wrap: wrap; row-gap: 2px; }
	.st-supplier summary > span { white-space: normal; }
}

/* ---------- Карточка товара: двухколоночная раскладка ---------- */
@media (min-width: 922px) {
	.woocommerce div.product {
		display: grid;
		grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
		column-gap: 44px;
		row-gap: 28px;
		align-items: start;
	}
	.woocommerce div.product .woocommerce-product-gallery { grid-column: 1; width: 100% !important; float: none !important; margin: 0 !important; }
	.woocommerce div.product .summary.entry-summary { grid-column: 2; width: 100% !important; float: none !important; margin: 0 !important; }
	.woocommerce div.product .woocommerce-tabs,
	.woocommerce div.product .related,
	.woocommerce div.product .upsells { grid-column: 1 / -1; }
}

.woocommerce div.product .product_title { font-size: var(--st-fs-2xl); line-height: 1.2; letter-spacing: -.01em; margin: 0 0 12px; }
.woocommerce div.product .summary .price { font-size: 32px; font-weight: 700; color: var(--st-text); margin: 6px 0 14px; }
.woocommerce div.product .summary .price del { font-size: 18px; color: var(--st-muted); font-weight: 400; }
.woocommerce div.product .summary .price ins { color: var(--st-danger); text-decoration: none; }
.woocommerce div.product .product_meta { font-size: var(--st-fs-sm); color: var(--st-muted); border-top: 1px solid var(--st-border); padding-top: 12px; margin-top: 8px; }
.woocommerce div.product .product_meta a { color: var(--st-accent); text-decoration: none; }
.woocommerce div.product .product_meta a:hover { text-decoration: underline; }
.woocommerce div.product p.stock.in-stock { margin: 10px 0 4px; }
.woocommerce div.product form.cart { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin: 16px 0 8px; }
.woocommerce div.product form.cart .quantity { display: flex; }
.woocommerce div.product form.cart .quantity input { width: 70px; height: 42px; text-align: center; }
.woocommerce div.product form.cart .single_add_to_cart_button { flex: 1 1 200px; height: 42px; font-size: var(--st-fs-base); }
.woocommerce div.product .woocommerce-tabs ul.tabs { margin: 0 0 18px; padding: 0; border-bottom: 1px solid var(--st-border); }
.woocommerce div.product .woocommerce-tabs ul.tabs li { background: none; border: none; margin: 0 24px 0 0; padding: 0; }
.woocommerce div.product .woocommerce-tabs ul.tabs li a { padding: 10px 0; font-weight: 600; font-size: var(--st-fs-base); color: var(--st-muted); border: none; }
.woocommerce div.product .woocommerce-tabs ul.tabs li.active a { color: var(--st-text); box-shadow: inset 0 -2px 0 var(--st-accent); }
.woocommerce div.product .woocommerce-tabs .panel { padding: 0; margin: 0 0 24px; }
.woocommerce div.product .woocommerce-tabs .panel h2 { font-size: var(--st-fs-xl); margin: 0 0 12px; }
.woocommerce div.product table.shop_attributes { width: 100%; border-collapse: collapse; font-size: var(--st-fs-sm); }
.woocommerce div.product table.shop_attributes th { width: 38%; text-align: left; padding: 10px 12px; color: var(--st-muted); font-weight: 500; border-bottom: 1px solid var(--st-border); background: transparent; }
.woocommerce div.product table.shop_attributes td { padding: 10px 12px; border-bottom: 1px solid var(--st-border); font-weight: 600; }
.woocommerce div.product table.shop_attributes tr:nth-child(even) th,
.woocommerce div.product table.shop_attributes tr:nth-child(even) td { background: #fafbfc; }
@media (max-width: 921px) {
	.woocommerce div.product .product_title { font-size: var(--st-fs-xl); }
	.woocommerce div.product .summary .price { font-size: 26px; }
}

/* Хлебные крошки: только сверху слева, без дубля в блоке товара */
.woocommerce div.product .summary .woocommerce-breadcrumb,
.woocommerce div.product .woocommerce-breadcrumb { display: none !important; }
.st-breadcrumbs { margin: 0 0 18px; padding: 0; }

/* Социальные иконки в подвале */
.footer-soc { display: flex; align-items: center; gap: 12px; }
.footer-soc a { display: inline-flex; align-items: center; justify-content: center; line-height: 0; }
.footer-soc img { width: 40px; height: 40px; object-fit: contain; display: block; }
@media (max-width: 767px) {
	.footer-soc { justify-content: center; }
}

/* ---------- Мобильная адаптация ---------- */
/* Таблицы из 1С в описании: прокрутка внутри блока, а не всей страницы */
.woocommerce-Tabs-panel--description table,
.woocommerce-Tabs-panel--additional_information table,
.woocommerce-product-details__short-description table,
.woocommerce-Tabs-panel--description .colored_table {
	display: block;
	width: 100% !important;
	max-width: 100%;
	overflow-x: auto;
	-webkit-overflow-scrolling: touch;
}
.woocommerce-Tabs-panel--description td,
.woocommerce-Tabs-panel--description th { white-space: normal; }

/* Картинки из описания не должны вылезать */
.woocommerce-Tabs-panel--description img,
.woocommerce-product-details__short-description img {
	max-width: 100% !important;
	height: auto !important;
}

/* Длинные слова и артикулы */
.woocommerce-Tabs-panel--description,
.woocommerce div.product .product_title,
ul.products li.product .woocommerce-loop-product__title { overflow-wrap: anywhere; }

@media (max-width: 1023px) {
	/* Панель каталога для десктопного ховера на мобильных не нужна */
	.st-menu-panel { display: none !important; }
}

@media (max-width: 767px) {
	/* Попап «Остатки на складах» не шире экрана */
	.st-warehouses { min-width: 0; width: calc(100vw - 32px); max-width: 360px; left: 0; }
	/* Кнопки в фильтре — крупнее для пальца */
	.st-filters-apply { min-height: 40px; }
	.st-filter summary { padding: 8px 0; }
	/* Заголовок товара и цена */
	.woocommerce div.product .product_title { font-size: var(--st-fs-xl); line-height: 1.25; }
	.woocommerce div.product .summary .price { font-size: 26px; }
	/* Кнопка «В корзину» на всю ширину */
	.woocommerce div.product form.cart .single_add_to_cart_button { flex: 1 1 100%; }
	/* Вкладки не переносятся криво */
	.woocommerce div.product .woocommerce-tabs ul.tabs { display: flex; gap: 16px; overflow-x: auto; margin: 0 0 14px; }
	.woocommerce div.product .woocommerce-tabs ul.tabs li { margin: 0; white-space: nowrap; }
	/* Наличие и склады */
	.st-supplier summary { row-gap: 2px; }
}

/* ---------- Фильтр: свёрнутый вид ---------- */
.st-filters { border: 1px solid var(--st-border); border-radius: var(--st-radius-lg); background: #fff; margin: 0 0 16px; }
.st-filters-bar { display: flex; align-items: center; gap: 12px; padding: 10px 14px; flex-wrap: wrap; }
.st-filters-toggle { display: inline-flex; align-items: center; gap: 8px; border: 1px solid var(--st-border); background: #fff; border-radius: var(--st-radius); padding: 9px 16px; font-size: var(--st-fs-base); font-weight: 600; color: var(--st-text); cursor: pointer; }
.st-filters-toggle:hover { border-color: var(--st-accent); color: var(--st-accent); }
.st-filters-toggle-icon { width: 14px; height: 11px; background: currentColor; flex: 0 0 auto;
	clip-path: polygon(0 0,100% 0,100% 18%,0 18%,0 41%,100% 41%,100% 59%,0 59%,0 82%,100% 82%,100% 100%,0 100%); }
.st-filters-badge { background: var(--st-accent); color: #fff; border-radius: 999px; padding: 1px 8px; font-size: 12px; line-height: 18px; }
.st-filters-reset { margin-left: auto; font-size: var(--st-fs-sm); color: var(--st-accent); text-decoration: none; }
.st-filters-reset:hover { text-decoration: underline; }
.st-filters-body { display: none; padding: 4px 14px 14px; border-top: 1px solid var(--st-border); }
.st-filters.is-open .st-filters-body { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 0 20px; }
.st-filters-actions { grid-column: 1 / -1; display: flex; gap: 10px; align-items: center; padding-top: 12px; }
.st-filters-actions .button { padding: 9px 18px; min-height: 40px; }
.st-filters-close { background: #fff !important; color: var(--st-text) !important; border: 1px solid var(--st-border) !important; }
@media (max-width: 767px) {
	.st-filters-actions { flex-direction: column; align-items: stretch; }
	.st-filters-actions .button { width: 100%; }
	.st-filters-reset { margin-left: 0; }
}

/* ---------- Фильтр на <details>: свёрнут, кнопка справа ---------- */
.st-filters > summary { list-style: none; cursor: pointer; }
.st-filters > summary::-webkit-details-marker { display: none; }
.st-filters > summary::marker { content: ""; }
.st-filters-bar { display: flex; align-items: center; justify-content: flex-end; gap: 12px; padding: 10px 14px; flex-wrap: wrap; }
.st-filters-toggle { margin-left: auto; }
.st-filters[open] .st-filters-body {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
	gap: 0 20px;
	padding: 4px 14px 14px;
	border-top: 1px solid var(--st-border);
}
.st-filters-actions { grid-column: 1 / -1; display: flex; gap: 10px; align-items: center; padding-top: 12px; }
.st-filters-reset { margin-left: 0 !important; }
@media (max-width: 767px) {
	.st-filters[open] .st-filters-body { grid-template-columns: 1fr 1fr; }
	.st-filters-toggle { margin-left: auto; }
}

/* ---------- Статическая карта на главной ---------- */
.st-map { display: block; position: relative; overflow: hidden; border-radius: var(--st-radius-lg); line-height: 0; }
.st-map img { display: block; width: 100%; height: auto; }
.st-map-hint {
	position: absolute; left: 16px; bottom: 16px; background: #fff; color: var(--st-text);
	padding: 8px 14px; border-radius: 8px; font-size: 14px; font-weight: 600; line-height: 1.2;
	box-shadow: 0 2px 10px rgba(16,24,40,.18); transition: background .15s, color .15s;
}
.st-map:hover .st-map-hint, .st-map:focus .st-map-hint { background: var(--st-accent); color: #fff; }
@media (max-width: 767px) {
	.st-map { border-radius: var(--st-radius); }
	.st-map-hint { left: 10px; bottom: 10px; padding: 6px 10px; font-size: 12px; }
}

/* Карта на главной: Elementor задаёт виджету ширину 107.7% — убираем, чтобы не было горизонтального скролла */
.elementor-635 .elementor-element-cfc7566,
.elementor-element-cfc7566 { width: 100% !important; max-width: 100% !important; }

/* ---------- Мобильная панель «Позвонить» ---------- */
.st-callbar {
	position: fixed;
	left: 0;
	right: 0;
	bottom: 0;
	z-index: 9990;
	display: none;
	padding: 8px 12px calc(8px + env(safe-area-inset-bottom, 0px));
	background: rgba(255, 255, 255, .97);
	border-top: 1px solid var(--st-border);
	box-shadow: 0 -6px 20px rgba(16, 24, 40, .12);
	transform: translateY(110%);
	transition: transform .22s ease;
}
.st-callbar.is-visible { transform: translateY(0); }
.st-callbar-btn {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	min-height: 48px;
	padding: 12px 16px;
	background: var(--st-accent);
	color: #fff;
	text-decoration: none;
	border-radius: 12px;
	font-size: 15px;
	font-weight: 600;
	line-height: 1.1;
}
.st-callbar-btn:hover,
.st-callbar-btn:focus { color: #fff; text-decoration: none; filter: brightness(1.05); }
.st-callbar-icon { display: inline-flex; }
.st-callbar-text { display: inline-flex; align-items: baseline; gap: 8px; flex-wrap: wrap; justify-content: center; }
.st-callbar-phone { font-weight: 700; white-space: nowrap; }
@media (max-width: 767px) {
	.st-callbar { display: block; }
	body { padding-bottom: 78px; }
}

/* Прозрачный фон панели «Позвонить»: остаётся только сама кнопка */
.st-callbar {
	background: transparent !important;
	border-top: 0 !important;
	box-shadow: none !important;
	pointer-events: none;
}
.st-callbar-btn {
	pointer-events: auto;
	border-radius: 999px;
	box-shadow: 0 8px 24px rgba(16, 24, 40, .28);
}

/* Карта на странице «Контакты»: снимаем ширину 107.7% (горизонтальный скролл) */
.elementor-17 .elementor-element-12b9095,
.elementor-element-12b9095 { width: 100% !important; max-width: 100% !important; }
