/* ========================================
   ШАПКА СТРАНИЦЫ КАТЕГОРИИ (.catalog-header)
   ======================================== */

.catalog-header {
    margin-bottom: 10px;
}

/* строка "показано X из Y" + сортировка — просто clearfix-обёртка,
   сама позиция уже задана в style.css для .woocommerce-result-count / .woocommerce-ordering */
.catalog-header-row {
    display: block;
    width: 100%;
     
}
.woocommerce-ordering {
    border: none !important;
    text-decoration: none !important;
}

.woocommerce-ordering::after {
    border: none !important;
}
.catalog-header-row::after {
    content: '';
    display: table;
    clear: both;
}
.catalog-toolbar{

    display:flex;
    justify-content:space-between;
    align-items:center;
    padding: 0;
 

}

.catalog-breadcrumbs{

    font-size:14px;

    color:#777;

}

.catalog-breadcrumbs a{

    color:#777;

    text-decoration:none;

}

.catalog-breadcrumbs a:hover{

    color:var(--primary-yellow);

}
.catalog-breadcrumbs .woocommerce-breadcrumb{
    margin: 0;
    padding: 0;
    border: none;
    background: transparent;
    box-shadow: none;
}
.catalog-result-count{

    margin-bottom:20px;

    color:#777;

    font-size:14px;

}
.catalog-toolbar .woocommerce-ordering{

    margin:0;

}

.catalog-result-count .woocommerce-result-count{

    float:none;

    margin:0;

}
.catalog-toolbar{
    display:flex;
    justify-content:space-between;
    align-items:center;

    background:#fff;
    border:1px solid #ececec;
    border-radius:12px;

    padding: 0px 24px;
 
}

.catalog-breadcrumbs .woocommerce-breadcrumb{
    margin:0;
    padding:0;
    background:none;
    border:none;
}

.catalog-ordering{
    margin:0;
}

.catalog-ordering .woocommerce-ordering{
    margin:0;
}
/* ========================================
   ДВУХКОЛОНОЧНАЯ РАСКЛАДКА (.catalog-layout)
   ======================================== */

.catalog-layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 28px;
    align-items: start;
    margin-top: 20px;
}

.catalog-sidebar {
    position: sticky;
    top: 20px;
}

.catalog-content {
    min-width: 0; /* чтобы сетка карточек не распирала колонку */
}

@media (max-width: 992px) {
    .catalog-layout {
        grid-template-columns: 1fr;
    }

    .catalog-sidebar {
        position: static;
    }
}

/* ========================================
   БЛОК ФИЛЬТРОВ (.filters-widget)
   ======================================== */

.filters-widget {
    background: #fff;
    border: 1px solid #ececec;
    border-radius: 16px;
    padding: 20px;
}

.filters-widget-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 18px;
    font-weight: 700;
    color: var(--dark-gray, #212121);
    margin-bottom: 18px;
}

.filters-icon {
    width: 18px;
    height: 18px;
    border-radius: 4px;
    background: var(--primary-yellow, #FFC107);
    display: inline-block;
}

.filter-block {
    padding: 16px 0;
    border-top: 1px solid #ececec;
}

.filter-block:first-of-type {
    border-top: none;
    padding-top: 0;
}

.filter-block-title {
    font-size: 15px;
    font-weight: 700;
    color: var(--dark-gray, #212121);
    margin-bottom: 12px;
}

.filter-checkbox-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.filter-checkbox-list li {
    margin-bottom: 10px;
}

.filter-checkbox-list label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: #424242;
    cursor: pointer;
}

.filter-checkbox-list input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: var(--primary-yellow, #FFC107);
    flex-shrink: 0;
}

.filter-count {
    color: #9e9e9e;
    font-size: 13px;
}

.filter-toggle-more {
    background: none;
    border: none;
    padding: 0;
    color: var(--primary-yellow, #FFC107);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
}

.filter-search {
    width: 100%;
    height: 38px;
    border: 1px solid var(--border-gray, #e0e0e0);
    border-radius: 10px;
    padding: 0 14px;
    font-size: 14px;
    margin-bottom: 14px;
    box-sizing: border-box;
}

.filter-price-slider {
    height: 4px;
    border-radius: 2px;
    background: linear-gradient(to right, var(--primary-yellow, #FFC107) 0%, var(--primary-yellow, #FFC107) 40%, #e0e0e0 40%, #e0e0e0 100%);
    margin: 10px 0 18px;
    position: relative;
}

.filter-price-slider::before,
.filter-price-slider::after {
    content: '';
    position: absolute;
    top: 50%;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #fff;
    border: 2px solid var(--primary-yellow, #FFC107);
    transform: translateY(-50%);
}

.filter-price-slider::before {
    left: 0;
}

.filter-price-slider::after {
    left: 40%;
}

.filter-price-inputs {
    display: flex;
    align-items: center;
    gap: 10px;
}

.filter-price-field {
    display: flex;
    align-items: center;
    gap: 8px;
    border: 1px solid var(--border-gray, #e0e0e0);
    border-radius: 10px;
    padding: 8px 12px;
    flex: 1;
}

.filter-price-field span {
    color: #9e9e9e;
    font-size: 13px;
}

.filter-price-field input {
    width: 100%;
    border: none;
    outline: none;
    font-size: 14px;
    color: var(--dark-gray, #212121);
}

.filter-actions {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-top: 18px;
}

.filter-actions .filter-apply {
    background: var(--primary-yellow, #FFC107) ;
    color: #fff;
    border: none;
    border-radius: 10px;
    height: 42px;
    padding: 0 22px;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: 0.25s;
}

.filter-actions .filter-apply:hover {
    background: #FFC107 !important;
}

.filter-reset {
    background: none;
    border: none;
    padding: 0;
    color: #616161;
    font-size: 14px;
    text-decoration: underline;
    cursor: pointer;
}

/* ========================================
   ПОЛНОЕ ОПИСАНИЕ КАТЕГОРИИ (.catalog-description-block)
   Выводится под товарами, см. template-parts/catalog/description.php
   ======================================== */

.catalog-description-block {
    margin-top: 40px;
    padding-top: 30px;
    border-top: 1px solid #ececec;
}

.catalog-description-title {
    font-size: 20px;
    font-weight: 700;
    color: var(--dark-gray, #212121);
    margin: 0 0 14px;
}

.catalog-description-text {
    color: var(--text-gray, #616161);
    font-size: 15px;
    line-height: 1.7;
}

.catalog-description-text p {
    margin: 0 0 14px;
}

.catalog-description-text ul,
.catalog-description-text ol {
    margin: 0 0 14px;
    padding-left: 20px;
}

/* ========================================
   БЛОК "ПОПУЛЯРНЫЕ БРЕНДЫ" (.popular-brands)
   ======================================== */

.popular-brands {
    margin-top: 50px;
}

/* Заголовок ставим в среднюю колонку грида, чтобы он был по центру
   независимо от ширины ссылки "Все бренды" справа */
.popular-brands-header {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    margin-bottom: 20px;
}

.popular-brands-header .section-title {
    grid-column: 2;
    margin: 0;
    text-align: center;
}

.popular-brands-link {
    grid-column: 3;
    justify-self: end;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
}

@media (max-width: 560px) {
    .popular-brands-header {
        grid-template-columns: 1fr;
        justify-items: center;
        gap: 10px;
        text-align: center;
    }

    .popular-brands-header .section-title,
    .popular-brands-link {
        grid-column: 1;
        justify-self: center;
    }
}

.popular-brands-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 16px;
}

.brand-logo-card {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 80px;
    background: #fff;
    border: 1px solid #ececec;
    border-radius: 14px;
    font-weight: 700;
    font-size: 16px;
    color: #424242;
    transition: 0.25s;
}

.brand-logo-card:hover {
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.06);
    transform: translateY(-3px);
}

@media (max-width: 992px) {
    .popular-brands-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 560px) {
    .popular-brands-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}


/* ==========================================================
   ПОИСК КАТАЛОГА — ДОБАВЛЕН БЕЗ ИЗМЕНЕНИЯ СТИЛЕЙ ФИЛЬТРОВ
========================================================== */
.steklobit-search {
    width: 100%;
    box-sizing: border-box;
    margin: 0 0 24px;
}

.steklobit-search-card {
    width: 100%;
    box-sizing: border-box;
    background: #fff;
    border: 1px solid #ececec;
    border-radius: 16px;
    padding: 20px;
}

.steklobit-search-home {
    margin-bottom: 40px;
}

.steklobit-search-home .steklobit-search-card {
    width: 40%;
    min-width: 420px;
    margin: 0 auto;
}

.steklobit-search .section-title {
    margin: 0 0 18px;
}

.steklobit-search-category .section-title {
    text-align: left;
    font-size: 20px;
    margin-bottom: 16px;
}

.steklobit-search-category .section-title::after {
    width: 45px;
    height: 3px;
    margin: 10px 0 0;
}

.steklobit-search-form { margin: 0; }

.steklobit-search-field {
    display: flex;
    width: 100%;
    min-height: 48px;
    box-sizing: border-box;
    border: 1px solid #e3e3e3;
    border-radius: 12px;
    overflow: hidden;
    background: #fff;
}

.steklobit-search-field:focus-within {
    border-color: var(--primary-yellow, #FFC107);
    box-shadow: 0 0 0 3px rgba(255,193,7,.12);
}

.steklobit-search-input {
    flex: 1;
    min-width: 0;
    height: 48px;
    border: 0 !important;
    outline: 0 !important;
    box-shadow: none !important;
    padding: 0 14px;
    background: transparent;
    font-size: 15px;
}

.steklobit-search-button {
    width: 56px;
    min-width: 56px;
    border: 0;
    background: var(--primary-yellow, #FFC107);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.steklobit-search-button svg {
    width: 21px;
    height: 21px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
}

.steklobit-search-results-wrap,
.category-search-results {
    margin-bottom: 28px;
}

.steklobit-search-results-title {
    margin: 0 0 18px;
    font-size: 20px;
    font-weight: 700;
    color: var(--dark-gray, #212121);
}

.steklobit-search-results-count {
    color: #888;
    font-size: 14px;
    font-weight: 500;
}

.steklobit-search-results {
    min-width: 0;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 20px;
}

.steklobit-search-results .steklobit-search-product {
    min-width: 0;
}

.category-search-results .catalog-grid {
    min-width: 0;
}

.steklobit-search-results.is-loading,
.steklobit-search.is-loading {
    opacity: .6;
    pointer-events: none;
}

@media (max-width: 992px) {
    .steklobit-search-home .steklobit-search-card {
        width: 100%;
        min-width: 0;
    }
}

@media (max-width: 576px) {
    .steklobit-search-home { margin-bottom: 30px; }
    .steklobit-search-card { padding: 16px; }
    .steklobit-search-button { width: 52px; min-width: 52px; }
}


/* ==========================================================
   ЖИВОЙ ПОИСК — РЕЗУЛЬТАТЫ И ПАГИНАЦИЯ
========================================================== */

.steklobit-search-results-wrap,
.category-search-results {
    transition: opacity .2s ease;
}

.steklobit-search.is-loading {
    opacity: .65;
    pointer-events: none;
}

.steklobit-search-results,
.steklobit-category-search-grid {
    width: 100%;
}

.steklobit-search-pagination-wrap {
    width: 100%;
    margin-top: 24px;
}

.steklobit-search-pagination {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.steklobit-search-page {
    min-width: 38px;
    height: 38px;
    padding: 0 12px;
    border: 1px solid #e5e5e5;
    border-radius: 8px;
    background: #fff;
    color: #333;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: .2s ease;
}

.steklobit-search-page:hover,
.steklobit-search-page.is-current {
    background: var(--primary-yellow, #FFC107);
    border-color: var(--primary-yellow, #FFC107);
    color: #212121;
}

.steklobit-search-results .no-data,
.steklobit-category-search-grid .no-data {
    grid-column: 1 / -1;
    margin: 0;
    padding: 24px 0;
}

@media (max-width: 576px) {
    .steklobit-search-pagination {
        gap: 6px;
    }

    .steklobit-search-page {
        min-width: 34px;
        height: 34px;
        padding: 0 10px;
    }
}


/* Поиск на главной: результаты остаются внутри общего контейнера */
.steklobit-home-search-container {
    width: 100%;
    box-sizing: border-box;
}

.steklobit-home-search-container .steklobit-search-results-wrap {
    width: 100%;
    box-sizing: border-box;
}

.steklobit-home-search-container .steklobit-search-results {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    box-sizing: border-box;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 20px;
}

@media (max-width: 1100px) {
    .steklobit-home-search-container .steklobit-search-results {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 760px) {
    .steklobit-home-search-container .steklobit-search-results {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 480px) {
    .steklobit-home-search-container .steklobit-search-results {
        grid-template-columns: 1fr;
    }
}
.filter-apply:hover {
   background: var(--primary-yellow, #FFC107) !important;
    border-color: #FFC107 !important;
    color: #212121 !important;
}
.filter-actions .filter-apply:disabled,
.filter-actions .filter-apply:disabled:hover {
    background: #FFC107 !important;
    border-color: #FFC107 !important;
    color: #212121 !important;
    opacity: 1 !important;
}