/* =============================================
   Product Filter Bar — compact horizontal dropdowns
   ============================================= */

.product-filter-bar {
    margin-bottom: 20px;
    position: relative;
    z-index: 20;
}

/* ---- Page layout alignment (breadcrumb, title, filter, grid) ---- */
.product-list > .container > .row {
    margin-left: 0;
    margin-right: 0;
}

.product-list > .container > .row > #breadcrumb,
.product-list > .container > .row > [class*="col-"] {
    padding-left: 0;
    padding-right: 0;
    max-width: 100%;
    flex: 0 0 100%;
}

.product-list .row.categoryinfo {
    padding: 4px 0;
    margin-left: 0;
    margin-right: 0;
}

.product-list .row.categoryinfo > [class*="col-"] {
    padding-left: 0;
    padding-right: 0;
}

/* ---- Category / subcategory page header ---- */
.category-page-header {
    margin: 0 0 18px;
}

.category-page-header__banner {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    min-height: 0;
    padding: 10px 20px;
    text-align: center;
    background: #eee6e3;
    border: none;
    box-sizing: border-box;
}

.category-page-header__eyebrow {
    margin: 0;
    font-family: "Mulish", sans-serif;
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: #453326;
    opacity: 0.55;
    line-height: 1.3;
}

.category-page-header__title {
    margin: 0;
    font-family: "Mulish", sans-serif;
    font-size: 15px;
    font-weight: 700;
    line-height: 1.3;
    letter-spacing: 0.04em;
    color: #453326;
    text-align: center;
}

.category-page-header__title::after {
    content: none;
}

.category-page-header__desc {
    margin: 0;
    max-width: 720px;
    width: 100%;
    font-family: "Mulish", sans-serif;
    font-size: 12px;
    font-weight: 500;
    line-height: 1.6;
    letter-spacing: 0.01em;
    color: #453326;
    text-align: center;
    opacity: 0.78;
}

/* TinyMCE içeriği: ekstra kutu/arka plan olmasın, title ile uyumlu kalsın */
.category-page-header__desc > *:first-child {
    margin-top: 0 !important;
}

.category-page-header__desc > *:last-child {
    margin-bottom: 0 !important;
}

.category-page-header__desc p,
.category-page-header__desc div,
.category-page-header__desc span {
    margin: 0;
    padding: 0;
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    border-radius: 0 !important;
    color: inherit !important;
    font-family: inherit !important;
    font-size: inherit !important;
    line-height: inherit !important;
    text-align: center !important;
}

.category-page-header__breadcrumb {
    margin-top: 12px;
}

.category-page-header__subs {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
    margin-top: 12px;
}

.category-page-header__sub-link {
    display: inline-flex;
    align-items: center;
    padding: 6px 12px;
    font-family: "Mulish", sans-serif;
    font-size: 12px;
    font-weight: 600;
    line-height: 1.3;
    letter-spacing: 0.02em;
    color: #453326;
    text-decoration: none;
    background: #eee6e3;
    border: 1px solid rgba(69, 51, 38, 0.12);
    transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.category-page-header__sub-link:hover,
.category-page-header__sub-link:focus {
    color: #eee6e3;
    background: #453326;
    border-color: #453326;
    text-decoration: none;
}

.product-list .product-list__breadcrumb #breadcrumb,
.product-list .category-page-header__breadcrumb #breadcrumb {
    padding-left: 0;
    padding-right: 0;
    max-width: 100%;
    flex: none;
}

.product-list .product-list__breadcrumb #breadcrumb p,
.product-list .category-page-header__breadcrumb #breadcrumb p {
    margin-top: 0;
    margin-bottom: 0;
}

@media (max-width: 767px) {
    .category-page-header {
        margin-bottom: 14px;
    }

    .category-page-header__banner {
        padding: 8px 14px;
        gap: 5px;
    }

    .category-page-header__title {
        font-size: 14px;
    }

    .category-page-header__desc {
        font-size: 11px;
    }

    .category-page-header__subs {
        gap: 6px;
        margin-top: 10px;
    }

    .category-page-header__sub-link {
        padding: 5px 10px;
        font-size: 11px;
    }
}

.product-list #product-list {
    margin-left: -8px;
    margin-right: -8px;
}

.product-filter-bar__header {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 10px;
}

.product-filter-bar__header-actions {
    display: flex;
    align-items: center;
    gap: 20px;
}

.product-filter-bar__compare {
    display: flex;
    align-items: center;
    gap: 6px;
}

.product-filter-bar__compare-link {
    font-family: "Mulish", sans-serif;
    font-size: 13px;
    font-weight: 500;
    color: #333;
    text-decoration: none;
    white-space: nowrap;
    transition: color 0.15s ease;
}

.product-filter-bar__compare-link:hover {
    color: #111;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.product-filter-bar__compare-clear {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    padding: 0;
    border: none;
    background: transparent;
    color: #c0392b;
    font-size: 18px;
    line-height: 1;
    cursor: pointer;
    opacity: 0.75;
    transition: opacity 0.15s ease;
}

.product-filter-bar__compare-clear:hover {
    opacity: 1;
}

.product-grid-toggle {
    display: flex;
    align-items: center;
    gap: 14px;
}

.product-grid-toggle__item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    text-decoration: none;
    color: #b0b0b0;
    transition: color 0.15s ease;
}

.product-grid-toggle__item:hover,
.product-grid-toggle__item.active {
    color: #333;
}

.product-grid-toggle__label {
    font-family: "Mulish", sans-serif;
    font-size: 13px;
    font-weight: 500;
    line-height: 1;
}

.product-grid-toggle__bars {
    display: inline-flex;
    align-items: stretch;
    gap: 3px;
    height: 14px;
}

.product-grid-toggle__bars i {
    display: block;
    width: 5px;
    border: 1.5px solid currentColor;
    border-radius: 1px;
    box-sizing: border-box;
}

/* Geniş ekranda (>=1800px) liste 3'lü, ızgara 6'lı gösterildiği için
   etiket ve ikonlar da ona göre değişir */
.product-grid-toggle__bars i.wide-only,
.product-grid-toggle__label--wide {
    display: none;
}

@media (min-width: 1800px) {
    .product-grid-toggle__bars i.wide-only {
        display: block;
    }

    .product-grid-toggle__label--wide {
        display: inline;
    }

    .product-grid-toggle__label--default {
        display: none;
    }
}

@media (max-width: 767px) {
    .product-grid-toggle {
        display: none;
    }
}

.product-filter-bar__top {
    width: 100%;
}

.product-filter-bar__dropdowns {
    position: relative;
    width: 100%;
    overflow: visible;
}

.product-filter-bar__dropdowns-scroll {
    display: flex;
    flex-wrap: nowrap;
    align-items: stretch;
    width: 100%;
    min-width: 0;
    border: 1px solid #e0e4e8;
    background: #fff;
}

/* ---- Dropdown trigger ---- */
.filter-dropdown {
    position: relative;
    flex: 0 0 auto;
    min-width: 130px;
    max-width: 200px;
}

.filter-dropdown__trigger {
    display: flex;
    align-items: center;
    width: 100%;
    gap: 6px;
    padding: 12px 14px;
    border: none;
    border-right: 1px solid #e0e4e8;
    background: #fff;
    cursor: pointer;
    font-family: "Mulish", sans-serif;
    font-size: 13px;
    font-weight: 500;
    color: #333;
    text-align: left;
    transition: background 0.15s, color 0.15s;
    white-space: nowrap;
    overflow: hidden;
}

.filter-dropdown:last-child .filter-dropdown__trigger {
    border-right: 1px solid #e0e4e8;
}

/* ---- Sort (end of filter bar) ---- */
.filter-bar__sort-end.filter-dropdown--sort {
    margin-left: auto;
    flex: 0 0 auto;
    min-width: 130px;
    max-width: 150px;
    width: 150px;
    border-left: 1px solid #e0e4e8;
    position: relative;
}

.filter-dropdown--sort .filter-dropdown__trigger {
    border-right: none;
    width: 100%;
    justify-content: space-between;
    padding-left: 14px;
    padding-right: 12px;
}

.filter-dropdown--sort .filter-dropdown__menu--sort {
    left: auto;
    right: 0;
    min-width: 180px;
    width: max-content;
    max-width: min(220px, calc(100vw - 24px));
    padding: 6px 0;
    border-radius: 0 0 10px 10px;
    border: 1px solid #e0e4e8;
    border-top: 1px solid #eee;
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.08);
}

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

.filter-sort-option {
    display: block;
    width: 100%;
    border: none;
    background: transparent;
    text-align: left;
    padding: 10px 16px;
    font-family: "Mulish", sans-serif;
    font-size: 13px;
    font-weight: 500;
    color: #333;
    cursor: pointer;
    transition: background 0.12s ease, color 0.12s ease;
}

.filter-sort-option:hover {
    background: #fff6f2;
    color: #111;
}

.filter-sort-option.is-active {
    background: #fff6f2;
    color: #111;
    font-weight: 600;
}

.filter-dropdown--sort.has-active .filter-dropdown__trigger {
    font-weight: 600;
}

.filter-dropdown__label {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
}

.filter-dropdown__label-short {
    display: none;
}

.filter-dropdown__count {
    display: none;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    background: #222;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    border-radius: 9px;
    line-height: 18px;
    text-align: center;
    flex-shrink: 0;
}

.filter-dropdown__count:not(:empty),
.filter-dropdown__count[data-count]:not([data-count="0"]) {
    display: inline-block;
}

.filter-dropdown__icon {
    font-size: 10px;
    color: #999;
    flex-shrink: 0;
    transition: transform 0.2s ease;
}

.filter-dropdown__trigger:hover {
    background: #fafbfc;
}

.filter-dropdown.is-open .filter-dropdown__trigger {
    background: #fff;
    color: #222;
    z-index: 22;
    position: relative;
}

.filter-dropdown.is-open .filter-dropdown__icon {
    transform: rotate(180deg);
}

.filter-dropdown.has-active .filter-dropdown__trigger {
    font-weight: 600;
}

/* ---- Dropdown menu ---- */
.filter-dropdown__menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 100%;
    width: max-content;
    max-width: 280px;
    background: #fff;
    border: 1px solid #e0e4e8;
    border-top: none;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
    z-index: 21;
    padding: 10px 0;
    max-height: 320px;
    overflow-y: auto;
}

.filter-dropdown.is-open .filter-dropdown__menu {
    display: block;
    animation: filterMenuIn 0.15s ease;
}

@keyframes filterMenuIn {
    from { opacity: 0; transform: translateY(-4px); }
    to { opacity: 1; transform: translateY(0); }
}

.filter-dropdown__menu--price {
    min-width: 0;
    width: max-content;
    max-width: calc(100vw - 32px);
    padding: 6px 8px;
    max-height: none;
    overflow: visible;
    box-sizing: border-box;
}

.filter-dropdown--price .filter-dropdown__menu {
    min-width: 0;
    left: 0;
    right: auto;
}

/* ---- Product count (below filter) ---- */
.product-list-count {
    margin: 14px 0 18px;
    text-align: center;
    font-size: 13px;
    color: #666;
    font-family: "Mulish", sans-serif;
    line-height: 1.4;
}

.product-list-count.is-hidden {
    display: none;
}

.product-list-count strong {
    color: #222;
    font-weight: 600;
}

/* ---- Pagination ---- */
.product-list-pagination {
    margin-top: 12px;
    margin-bottom: 8px;
}

.product-list-pagination .pagination,
.search-page-pagination .pagination,
.brand-page-pagination .pagination {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 6px;
    margin: 0;
    padding: 0;
    list-style: none;
    border-radius: 0;
}

.product-list-pagination .page-item,
.search-page-pagination .page-item,
.brand-page-pagination .page-item {
    margin: 0;
}

.product-list-pagination .page-link,
.search-page-pagination .page-link,
.brand-page-pagination .page-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 38px;
    height: 38px;
    padding: 0 12px;
    margin: 0;
    border: 1px solid rgba(0, 0, 0, 0.12);
    border-radius: 8px !important;
    background: #fff;
    color: #111 !important;
    font-family: "Mulish", sans-serif;
    font-size: 13px;
    font-weight: 600;
    line-height: 1;
    text-decoration: none !important;
    box-shadow: none !important;
    transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.product-list-pagination .page-link:hover,
.search-page-pagination .page-link:hover,
.brand-page-pagination .page-link:hover {
    background: #fff6f2;
    border-color: rgba(0, 0, 0, 0.16);
    color: #111 !important;
}

.product-list-pagination .page-item.active .page-link,
.search-page-pagination .page-item.active .page-link,
.brand-page-pagination .page-item.active .page-link {
    background: #111;
    border-color: #111;
    color: #fff !important;
}

.product-list-pagination .page-item.active .page-link:hover,
.search-page-pagination .page-item.active .page-link:hover,
.brand-page-pagination .page-item.active .page-link:hover {
    background: #111;
    border-color: #111;
    color: #fff !important;
}

.product-list-pagination .page-item.disabled .page-link,
.search-page-pagination .page-item.disabled .page-link,
.brand-page-pagination .page-item.disabled .page-link {
    background: #fff6f2;
    border-color: transparent;
    color: rgba(17, 17, 17, 0.35) !important;
    pointer-events: none;
}

.product-list-empty {
    background: #fff6f2;
    border: 1px solid rgba(0, 0, 0, 0.06);
    border-radius: 12px;
    padding: 32px 24px;
    text-align: center;
    margin: 0 8px 24px;
    max-width: 100%;
    flex: 0 0 calc(100% - 16px);
}

.product-list-empty__text {
    margin: 0;
    font-size: 15px;
    font-weight: 700;
    color: #111;
    letter-spacing: 0.02em;
}

.product-list-empty__subs {
    margin-top: 22px;
}

.product-list-empty__subs-title {
    margin: 0 0 12px;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: rgba(17, 17, 17, 0.55);
}

.product-list-empty__links {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
}

.product-list-empty__links a {
    display: inline-block;
    padding: 8px 14px;
    font-size: 13px;
    font-weight: 500;
    color: #111;
    text-decoration: none;
    background: #fff;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.product-list-empty__links a:hover {
    background: #111;
    border-color: #111;
    color: #fff;
    text-decoration: none;
}

.product-filter-panel .category {
    list-style: none;
    margin: 0;
    padding: 0;
}

.product-filter-panel .category li {
    padding: 0;
    margin: 0;
}

.product-filter-panel .filter-option-item {
    display: block;
    padding: 7px 14px;
    transition: background 0.12s;
}

.product-filter-panel .filter-option-item:hover {
    background: #f5f5f5;
}

.product-filter-panel .filter-option-item.is-selected {
    background: #f0f0f0;
}

.product-filter-panel .checkbox + label,
.product-filter-panel .radio-button + label {
    font-size: 13px;
    line-height: 1.4;
    padding-left: 26px;
    color: #333;
    display: block;
    width: 100%;
    cursor: pointer;
}

.product-filter-panel .checkbox + label::before,
.product-filter-panel .radio-button + label::before {
    width: 15px;
    height: 15px;
    border-radius: 3px;
    border-color: #ccc;
    top: 1px;
}

.product-filter-panel .checkbox:checked + label::before,
.product-filter-panel .radio-button:checked + label::before {
    background: #222;
    border-color: #222;
}

.product-filter-panel .category::-webkit-scrollbar {
    width: 4px;
}

.product-filter-panel .category::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 4px;
}

/* ---- Price pills (inside dropdown) ---- */
.filter-price-pills {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-bottom: 6px;
    width: 100%;
}

.filter-price-pill {
    position: relative;
    width: 100%;
}

.filter-price-pill input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.filter-price-pill label {
    display: block;
    width: 100%;
    box-sizing: border-box;
    padding: 5px 8px;
    font-size: 11px;
    font-family: "Mulish", sans-serif;
    color: #333;
    background: #fff;
    border: 1px solid #e8e8e8;
    cursor: pointer;
    transition: all 0.15s;
    margin: 0;
    padding-left: 8px !important;
    line-height: 1.2;
    text-align: left;
    white-space: nowrap;
}

.filter-price-pill label::before,
.filter-price-pill label::after {
    display: none !important;
}

.filter-price-pill input[type="radio"]:checked + label {
    background: #f5f5f5;
    border-color: #222;
    font-weight: 600;
}

.filter-price-pill label:hover {
    border-color: #999;
}

/* ---- Custom price inputs ---- */
.filter-price-custom {
    border-top: 1px solid #eee;
    padding-top: 6px;
    margin-top: 2px;
    width: 100%;
}

.filter-price-custom__fields {
    display: flex;
    flex-direction: column;
    gap: 4px;
    width: 100%;
}

.filter-price-custom__field {
    display: flex;
    align-items: center;
    border: 1px solid #e0e4e8;
    background: #fff;
    min-height: 0;
}

.filter-price-custom__input {
    flex: 1;
    border: none;
    outline: none;
    padding: 6px 8px;
    font-size: 12px;
    font-family: "Mulish", sans-serif;
    color: #222;
    background: transparent;
    min-width: 0;
    height: 30px;
    -moz-appearance: textfield;
}

.filter-price-custom__input::-webkit-outer-spin-button,
.filter-price-custom__input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.filter-price-custom__input::placeholder {
    color: #bbb;
    font-size: 11px;
}

.filter-price-custom__currency {
    padding: 0 8px;
    font-size: 12px;
    color: #666;
    border-left: 1px solid #e0e4e8;
    align-self: stretch;
    display: flex;
    align-items: center;
    line-height: 1;
}

.filter-price-custom__apply {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 30px;
    padding: 0;
    border: none;
    background: #222;
    color: #fff;
    font-size: 13px;
    cursor: pointer;
    transition: background 0.15s;
}

.filter-price-custom__apply:hover {
    background: #000;
}

.filter-price-custom.is-active .filter-price-custom__field {
    border-color: #999;
}

/* ---- Active filter chips ---- */
.product-active-filters {
    margin-top: 12px;
}

.product-active-filters.is-empty {
    display: none !important;
}

.product-active-filters__chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

.filter-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 10px;
    background: #f0f0f0;
    border: 1px solid #e0e0e0;
    font-size: 12px;
    font-family: "Mulish", sans-serif;
    color: #333;
    line-height: 1.3;
}

.filter-chip__remove {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    height: 16px;
    padding: 0;
    border: none;
    background: transparent;
    color: #666;
    font-size: 16px;
    line-height: 1;
    cursor: pointer;
    transition: color 0.15s;
}

.filter-chip__remove:hover {
    color: #222;
}

.filter-chip-clear-all {
    padding: 6px 10px;
    border: 1px solid #e0e0e0;
    background: #f0f0f0;
    color: #333;
    font-size: 12px;
    font-family: "Mulish", sans-serif;
    cursor: pointer;
    transition: background 0.15s;
}

.filter-chip-clear-all:hover {
    background: #e8e8e8;
}

/* ---- Filter options ---- */
@media (max-width: 991px) {
    .filter-dropdown {
        min-width: 120px;
        max-width: none;
        flex: 1 1 calc(33.33% - 0px);
    }
}

@media (max-width: 767px) {
    .product-filter-bar__header {
        margin-bottom: 8px;
    }

    .product-filter-bar__header-actions {
        gap: 12px;
        flex-wrap: wrap;
    }

    .product-filter-bar__compare-link {
        font-size: 12px;
    }

    .product-grid-toggle__label {
        font-size: 12px;
    }

    .product-filter-bar__top {
        width: 100%;
    }

    .product-filter-bar__dropdowns-scroll {
        display: flex;
        flex-wrap: wrap;
        overflow-x: hidden;
        width: 100%;
        padding-bottom: 0;
    }

    .filter-dropdown {
        flex: 1 1 33.333%;
        min-width: 33.333%;
        max-width: none;
        width: auto;
    }

    .filter-dropdown__trigger {
        justify-content: center;
        gap: 4px;
        padding: 10px 6px;
        font-size: 12px;
    }

    .filter-dropdown__label {
        flex: 0 1 auto;
        text-align: center;
    }

    .filter-dropdown__label-full {
        display: none;
    }

    .filter-dropdown__label-short {
        display: inline;
    }

    .filter-dropdown__icon {
        font-size: 10px;
        flex-shrink: 0;
    }

    .filter-dropdown.is-open {
        z-index: 50;
    }

    .filter-dropdown.is-open .filter-dropdown__menu {
        position: fixed !important;
        z-index: 9999 !important;
    }

    .filter-bar__sort-end.filter-dropdown--sort {
        flex: 1 1 33.333%;
        min-width: 33.333%;
        max-width: none;
        width: auto;
        margin-left: 0;
        position: static;
        border-left: none;
    }

    .filter-dropdown--sort .filter-dropdown__trigger {
        justify-content: center;
        padding-left: 6px;
        padding-right: 6px;
    }
}

/* Hide legacy panel elements */
.product-filter-panel.fadingbar {
    background: transparent;
    border: none;
    padding: 0;
    display: block !important;
}

.product-filter-panel .filterheading,
.product-filter-panel .filter-buttons,
.product-filter-panel .product-filter-header,
.product-filter-panel .product-filter-footer {
    display: none !important;
}

.product-filter-panel .cat-title {
    display: none;
}

.product-filter-panel .category-content.filter-by {
    width: auto;
    float: none;
    margin: 0;
}
