@font-face {
    font-family: 'YekanBakh';
    src: url('fonts/yekanbakhfa/woff2/YekanBakhFaNum-Bold.woff2') format('woff2');
    font-weight: normal;
    font-style: normal;
}

.minaro-product-list .minaro-single-product-card {
    width: 100%;
}

.minaro-single-product-card {
    border: 2px solid #0000000D;
    padding: 14px;
    border-radius: 16px;
    text-align: center;
    transition: 0.3s;
    height: 100%;
    margin: 6px;
}

#min-val {
    width: 60px;
    text-align: center;
}

#max-val {
    width: 60px;
    text-align: center;
}

.courses-4-columns .minaro-single-product-card {
    width: 24%;
}

.minaro-link-cate {
    width: 10px;
    height: 10px;
    background-color: #8c8c8e;
    margin: 0 10px 0 0;
}

.minaro-container-head a {
    display: flex;
    align-items: center;
}

.minaro-container-tag-rate {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
}

.minaro-single-product-card .swiper-container {
    padding: 0 !important;
}

.minaro-single-product-card:hover {
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.minaro-single-product-card img {
    border-radius: 5px;
}

.product-thumbnail img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
}

.product-title {
    font-size: 16px;
    font-weight: 600;
    margin: 10px 0;
    height: 60px;
}

.added_to_cart.wc-forward {
    display: none;
}

.minaro-container-products {
    display: flex;
    justify-content: space-around;
}

.wc-cat-accordion {
    border: 1px solid #ccc;
    border-radius: 8px;
    padding: 0;
    background: #fafafa;
    max-width: 100%;
    margin: 1rem 0;
    overflow: hidden;
}

/*.minaro-filter {*/
/*    margin-left: 20px;*/
/*    width: 26%;*/
/*}*/

.minaro-item-filtered {
    color: #a5a2a2;
}

/* سرتیتر */
.wc-cat-title {
    display: flex;
    flex-direction: column;
    font-weight: bold;
    font-size: 14px;
    padding: 8px;
    cursor: pointer;
    position: relative;
    user-select: none;
    background-color: #fff;
}

/* فلش قبل از متن */
.wc-cat-title .arrow {
    display: inline-block;
    margin-left: 0.5rem;
    transition: transform 0.3s ease;
    width: 0;
    height: 0;
    border-top: 6px solid transparent;
    border-bottom: 6px solid transparent;
    border-right: 6px solid #555;
}

/* وقتی باز شد فلش بچرخه */
.wc-cat-accordion[open] .wc-cat-title .arrow {
    transform: rotate(90deg);
}

/* لیست اصلی */
.wc-cat-list {
    list-style: none;
    padding: 0.5rem 1rem 1rem;
    margin: 0;
}

/* آیتم دسته‌بندی */
.wc-cat-item {
    margin-bottom: 0.7rem;
}

/* زیردسته‌ها */
.wc-cat-children {
    margin-top: 0.3rem;
    list-style: none;
}

.minaro-child-link {
    margin-right: 20px;
}

/* چک‌باکس و برچسب */
.wc-cat-item label,
.wc-cat-children label {
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    cursor: pointer;
}

.range-container {
    background: #f9f9f9;
    padding: 20px;
    border-radius: 16px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
    direction: rtl;
    max-width: 400px;
    margin: auto;
    color: #333;
}

.range-container label {
    font-weight: bold;
    margin-bottom: 10px;
    display: block;
    font-size: 16px;
}

.slider {
    position: relative;
    height: 40px;
    margin: 20px 0;
}

.slider input[type="range"] {
    position: absolute;
    width: 100%;
    pointer-events: none;
    -webkit-appearance: none;
    height: 6px;
    border-radius: 4px;
    background: #007bff;
}

.slider input[type="range"]::-webkit-slider-thumb {
    pointer-events: all;
    width: 20px;
    height: 20px;
    background: #007bff;
    border-radius: 50%;
    cursor: pointer;
    -webkit-appearance: none;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.slider input[type="range"]::-moz-range-thumb {
    pointer-events: all;
    width: 20px;
    height: 20px;
    background: #007bff;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.price-values {
    display: flex;
    justify-content: space-between;
    font-size: 14px;
    background: #fff;
    padding: 8px 14px;
    border-radius: 12px;
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.05);
}

/* فونت دلخواهت را اضافه کن */
*, *:before, *:after {
    box-sizing: border-box
}

.colors-filter {
    direction: rtl;
}

.filter-title {
    margin-bottom: 8px;
    font-weight: 700;
    color: #444
}

.color-grid {
    display: flex;
    flex-wrap: wrap;
    margin: 0;
    padding: 0;
    list-style: none;
}

/* چک‌باکس مخفی */
.color-grid input[type=checkbox] {
    display: none
}

.color-grid li {
    display: flex;
    align-items: center;
    flex-direction: column;
}

.minaro-sub-title {
    display: flex;
    align-items: center;
}

.minaro-selected-filter {
    width: 5px;
    height: 5px;
    background-color: blue;
    border-radius: 30px;
    margin-right: 10px;
}

.swatch {
    position: relative;
    display: block;
    width: 50px;
    height: 50px;
    border: 2px solid #e6e6e6;
    border-radius: 12px;
    cursor: pointer;
    transition: border-color .25s;
}

/* نوارهای رنگی داخل هر سوَچ */
.swatch:before {
    content: "";
    position: absolute;
    inset: 6px;
    border-radius: 8px;
    background: #ccc; /* پیش‌فرض تا اگر کلاس gradient نبود خاکستری بماند */
}

/* نام رنگ روی سوَچ (مانند تصویر) */
.swatch:after {
    /*content: attr(data-name);*/
    position: absolute;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding-bottom: 6px;
    font-size: 12px;
    color: #555;
    font-weight: 500;
    pointer-events: none;
    width: 100%;
}

/* هنگام انتخاب → بوردر آبی */
.color-grid input:checked + .swatch {
    border-color: #00a3ff
}

/* ــــــــــ رنگ‌ها ــــــــــ */
.swatch-white:before {
    background: #ffffff
}

.swatch-black:before {
    background: #000000
}

.swatch-gray:before {
    background: #8f8f8f
}

.swatch-silver:before {
    background: #d9d9d9
}

/* طیف‌های چند‑نوار (مثل تصویر) با gradient تکراری */
.swatch-green:before {
    background: repeating-linear-gradient(90deg, #1e7d34 0 25%, #60c46b 25% 50%, #b2e6b5 50% 75%, #dfeee0 75% 100%)
}

.swatch-blue:before {
    background: repeating-linear-gradient(90deg, #0759c5 0 25%, #1483e9 25% 50%, #60b0ff 50% 75%, #cbe4ff 75% 100%)
}

.swatch-purple:before {
    background: repeating-linear-gradient(90deg, #5a0aa5 0 25%, #8946ce 25% 50%, #b98ef2 50% 75%, #eadcfb 75% 100%)
}

.swatch-yellow:before {
    background: repeating-linear-gradient(90deg, #ffc107 0 25%, #ffe073 25% 50%, #fff0b9 50% 75%, #fff9e5 75% 100%)
}

.swatch-brown:before {
    background: repeating-linear-gradient(90deg, #5d3a27 0 25%, #8a5a40 25% 50%, #c49a7a 50% 75%, #e8d7cc 75% 100%)
}

.swatch-orange:before {
    background: repeating-linear-gradient(90deg, #ff7a00 0 25%, #ffa445 25% 50%, #ffc88a 50% 75%, #ffe7cd 75% 100%)
}

.swatch-red:before {
    background: repeating-linear-gradient(90deg, #b60000 0 25%, #d93a3a 25% 50%, #f48484 50% 75%, #fedddd 75% 100%)
}

.swatch-pink:before {
    background: repeating-linear-gradient(90deg, #d9006c 0 25%, #e9519e 25% 50%, #f8a8c9 50% 75%, #fde6ef 75% 100%)
}

.product-price {
    font-weight: bold;
    color: #1a8917;
    margin-bottom: 10px;
}

.product-tags {
    display: flex;
    justify-content: space-around;
    height: 22px;
    line-height: 16px;
}

.product-tags div {
    border-radius: 5px;
    padding: 4px 7px;
    margin-left: 10px;
}

.product-description {
    display: flex;
    justify-content: space-between;
    border-bottom: 2px solid #cac9c9;
    padding-bottom: 10px;
    align-items: center;
    height: 48px;
}

.minaro-container-product {
    height: auto;
}

.minaro-container-price {
    display: flex;
}

.minaro-regular-price {
    color: #b0a4a4;
}

.minaro-regular-price-wrapper {
    position: relative;
    display: inline-block;
    margin-left: 10px;
}

.minaro-regular-price-wrapper::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    width: 100%;
    height: 1px;
    background-color: #b0a4a4;
    transform: rotate(-20deg);
    transform-origin: center;
}

.percent-number {
    background-color: #e81a40;
    color: white;
    border-radius: 10px;
    width: fit-content;
    padding: 0 4px;
    height: fit-content;
    line-height: 25px;
}

.minaro-price-container {
    display: flex;
    justify-content: space-between;
    margin-top: 10px;
    flex-direction: row-reverse;
    align-items: center;
}

.minaro-sale-price {
    color: #e81a40;
}

.product-details {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 57%;
}

.product-cart a.button {
    width: 100%;
    background-color: #37c976;
    color: white;
    padding: 8px 12px;
    border-radius: 5px;
    text-decoration: none;
    margin-bottom: 10px;
}

.product-cart a.button:hover {
    background-color: #1d7e45;
}

.minaro-product-list {

    align-items: center;
    justify-content: center;
    /*font-size: 23px;*/
    /*font-weight: 800;*/

    width: 76%;
    display: flex;
    flex-wrap: wrap;
    gap: 0px;

}

.minaro-container-products .minaro-single-product-card {

    box-sizing: border-box;
    height: auto;
}

.swiper-pagination-bullet {
    width: 5px !important;
    height: 5px !important;
    background: #1F75EC38 !important;
    opacity: 1 !important;
    margin: 0 4px !important;
    transition: all 0.3s ease !important;
}

.swiper-pagination-bullet-active {
    width: 18px !important;
    height: 5px !important;
    background: #2563eb !important;
    border-radius: 38px !important;
}

.minaro-head-category {
    cursor: pointer;
}

.wc-cat-children {
    margin-left: 20px;
    list-style: none;
}

.details-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.7s ease;
}

.wc-cat-content {
    max-width: 275px;
}

.wc-cat-title {
    cursor: pointer;
}

.arrow {
    display: inline-block;
    transition: transform 0.3s ease;
}

.wc-cat-accordion.open .arrow {
    transform: rotate(90deg);
}

.wc-cat-accordion[open] .details-content {
    max-height: 1000px; /* کافی است بزرگتر از بیشترین ارتفاع محتوای داخلی باشد */
}

.minaro-container-head .arrow {
    display: inline-block;
    margin-right: 5px;
    cursor: pointer;
    width: 10px;
    height: 10px;
    border-right: 2px solid #333;
    border-bottom: 2px solid #333;

    transition: transform 0.2s;
    transform: rotate(135deg);
}

.minaro-container-head .arrow.open {
    transform: rotate(45deg);
}

.wc-cat-item > a,
.wc-cat-item > .arrow {
    vertical-align: middle;
}

.minaro-container-head {
    display: flex;
    white-space: nowrap;;
    justify-content: space-between;
    align-items: center;
}

#open-filters {
    display: none;
}

@media only screen and (min-width: 767px) {

    .minaro-product-list .minaro-single-product-card {
        width: calc(33% - 10px) !important;
    }

    .minaro-product-list {
        width: 76%;
    }

}

.minaro-mobile-filter-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.minaro-mobile-filter-header #svg-close {
    cursor: pointer;
    display: none;
}

#main .vc_row {
    overflow: visible;
}

/* رپر دو ستونه */
.shop-layout {
    display: flex;
    gap: 24px;
    align-items: flex-start; /* مهم: به‌جای stretch */
}

/* ستون محصول‌ها */
.shop-content {
    flex: 1 1 auto;
    min-width: 0; /* برای شکستن درست خطوط */
}

/* خود سایدبار */
.minaro-filter {
    position: sticky; /* حالت چسبان */
    top: 80px; /* به‌اندازه هدر ثابت سایتت تغییر بده */
    flex: 0 0 280px; /* عرض ثابت ستون سایدبار */
    /*max-height: calc(100vh - 80px); !* تا لبه پایین ویوپورت *!*/
    overflow: auto; /* داخل سایدبار اسکرول بخوره */
    align-self: flex-start; /* اگر جایی override شد */
    box-sizing: border-box;
}

/* خیلی مهم: روی هیچ‌کدوم از اجداد مستقیم سایدبار overflow نذار */
.container, .shop-layout, .shop-content {
    overflow: visible !important;
}

@media only screen and (max-width: 767px) {
    .shop-layout {
        display: none !important;
    }

    .shop-layout.active {
        display: block !important;
    }


    .minaro-product-list {
        width: 100%;
    }

    .minaro-mobile-filter-header #svg-close {
        display: block;
    }

    #open-filters {
        display: block;
    }

    .minaro-single-product-card {
        width: 100% !important;
    }

    .minaro-container-products {
        flex-direction: column;
    }

    /* پنل اصلی فیلتر */
    .shop-layout {
        position: fixed;
        bottom: -100%;
        left: 0;
        width: 100%;
        background: #fff;
        z-index: 999999;
        transition: bottom 0.3s ease-in-out;
        box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.15);
        height: 100vh;
        overflow: hidden; /* مهم: جلوگیری از اسکرول کل پنل */
        border-radius: 10px 10px 0 0;
    }

    /* وقتی فیلتر فعاله */
    .shop-layout.active {
        bottom: 0;
    }

    /* این بخش داخلی اسکرول‌پذیر باشه */
    .minaro-filter-wrapper {
        height: 100%;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch; /* روان‌تر برای موبایل */
        padding: 32px;
    }

    /* وقتی فعال شد */
    .shop-layout.active {
        height: 84%;
        margin-bottom: 175px;
    }

    .minaro-filter {
        height: 100%;
        overflow-y: auto;
        padding: 20px;
    }
}