/* ==========================================================================
   JPA PLP — HEADER-SAFE FINAL BUILD — 2026-08-25
   - PLP visuals/behavior preserved.
   - Legacy/global selectors are isolated to #plp_container with :where() so
     specificity and the internal cascade remain unchanged.
   - Document-level html/body leakage was removed.
   - Generic PLP keyframes/font-face names were namespaced to avoid collisions.
   ========================================================================== */

#plp_container{
    --bg: #0f1115;
    --panel: #f3f0f0;
    --surface: #0c1017;
    --text: #e6e9ef;
    --muted: #9aa3b6;
    --brand: #4f8cff;
    --border: #212733;
    --radius: 14px;
    --shadow: 0 10px 30px rgba(233, 233, 233, 0.35);
    --speed: 320ms;
    --fade: 160ms;
    --easing: cubic-bezier(.2, .75, .25, 1);
    --content-max: 1340px;
    --gutter: 16px;
    --site-header-h: 60px;
    --panelPx: 360px;
    --d2-col-max: 320px;
    --liner-skel-color: #dbdde3;
    --skel-color: #e6e9ef;

    /* Right offset so fixed filters align to the container’s right edge */
    --wrap-right: 10px;
    --siteHeaderH: 60px;
}
#plp_container,
#plp_container *,
#plp_container *::before,
#plp_container *::after{
    box-sizing: border-box;
}

#plp_container{
    --panelPx: 360px;
    position: relative;
}


#plp_container .plp-searchbar{
    position: sticky;
    top: var(--siteHeaderH);
    z-index: 600;
    background: #fff;
    box-shadow: 0 6px 18px rgba(0,0,0,.06);
    border-bottom: 1px solid #eee;
}


#plp_container .plp-searchbar,
#plp_container .search-header-spacer{
    transition: height .18s ease, top .18s ease;
}


#plp_container .search-header-spacer{
    height: 0;
}


#plp_container .wrap{
    max-width: 1400px;
    margin: 0 auto;
    padding: 0;
}



@font-face {
    font-family: jpa-plp-plp;
    src: url("../fonts/ttf/IRANSansWebFaNum.ttf");
}

@media (prefers-reduced-motion:reduce) {
    #plp_container{
        --speed: 0ms;
        --fade: 0ms;
    }
}
:where(#plp_container) #searchHeader{ position:static !important; }

#plp_container{ overflow:visible; }


#plp_container{
    color: #000;
    font: 500 15px/1.55 ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Arial;
    font-family: jpa-plp !important;
}

#plp_container a{
    color: inherit;
    text-decoration: none;
}

#plp_container .wrap{
    direction: rtl;
    margin-inline: auto;
    padding: 0 var(--gutter);
    width: 100%;
    box-sizing: border-box;
}

#plp_container{
    width: 100%;
    height: 100%;
    margin: 0;
    background: #fff;
    font: 500 15px/1.55 ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Arial;
    font-family: jpa-plp !important;
    overflow-x: hidden;
    /* keep content below fixed site header */
}

/* === Fixed Site Header (60px) === */
/*.site-header {*/
/*    position: fixed;*/
/*    inset: 0 0 auto 0;*/
/*    height: var(--site-header-h);*/
/*    z-index: 130;*/
/*    background: #0e121a;*/
/*    border-bottom: 1px solid var(--border);*/
/*    display: flex;*/
/*    align-items: center;*/
/*}*/

/*.site-header .bar {*/
/*    display: flex;*/
/*    align-items: center;*/
/*    justify-content: space-between;*/
/*    gap: 12px*/
/*}*/

:where(#plp_container) .btn{
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border: 0px;
    background: #f6f6f6;
    color: #000000;
    font-family: jpa-plp;
    padding: 9px 14px;
    border-radius: 12px;
    cursor: pointer;
    transition: background var(--speed) var(--easing), transform 120ms ease
}

:where(#plp_container) .btn:hover{
    background: #dddde4;
}

:where(#plp_container) .btn:active{
    transform: translateY(1px)
}

/* === Search Header (FIXED under site header, with spacer) === */
:where(#plp_container) .search-header{
    direction: ltr;
    position: fixed;
    left: 0;
    right: 0;
    top: var(--site-header-h);
    z-index: 120;
    background: rgb(255, 255, 255);
    backdrop-filter: blur(10px);
    /* border-bottom:1px solid var(--border); */
    box-shadow: 0px 4px 10px rgba(124, 124, 124, 0.5);
    transform: translateY(0);
    transition: transform var(--speed) var(--easing);
    will-change: transform;
}

:where(#plp_container) .search-header.is-hidden{
    transform: translateY(calc(-100% - 1px));
}

/* slide out of view */
:where(#plp_container) .search-header .row{
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 0
}

/* Spacer reserves layout under fixed search header when visible */
:where(#plp_container) .search-header-spacer{
    direction: ltr;
    height: 0;
    transition: height var(--speed) var(--easing)
}

/* Category bar (Swiper) */
:where(#plp_container) .catbar{
    padding: 10px 0 12px;
    border-top: 1px solid rgba(255, 255, 255, .04)
}

:where(#plp_container) .catbar-inner{
    display: flex;
    align-items: center;
    gap: 8px
}
/* test */
:where(#plp_container) .catbtn{
    flex: 0 0 auto;
    border: 0px;
    background: #f6f6f6;
    color: crimson;
    border-radius: 999px;
    padding: 7px 9px;
    font-weight: 700;
    cursor: pointer
}

:where(#plp_container) .catbtn[disabled]{
    color: #000000;
    opacity: .5;
    cursor: not-allowed
}

:where(#plp_container) .swiper{
    flex: 1 1 auto;
    margin-left: auto;
    margin-right: auto;
    width: 100%;
    overflow: hidden;
}

:where(#plp_container) .swiper-free-mode>.swiper-wrapper{
    width: 100%;
    display: flex;
    
}
:where(#plp_container) .swiper-wrapper{
    align-items: center
}

:where(#plp_container) .swiper-slide{
    width: auto
}

:where(#plp_container) .pill{
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    background: #f6f6f6;
    border-radius: 12px;
    color: #000000;
    white-space: nowrap;
    cursor: pointer;
    transition: background var(--speed) var(--easing), transform 120ms ease, color var(--speed);
    font-family: jpa-plp !important;
    border: 2px solid transparent;
}

:where(#plp_container) .pill:hover{
    background: #dddde4
}

:where(#plp_container) .pill.active{
    color: #0b0e14;
    border-color: #c5c5cb;
    background: #eaeaf1;
    font-weight: 600;
}

:where(#plp_container) .pill .dot{
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: currentColor;
    opacity: .85
}

:where(#plp_container) .pill-skel{
    height: 30px;
    width: 84px;
    border-radius: 999px;
    background: var(--skel-color);
    position: relative;
    overflow: hidden;
    margin-right: 8px;
    display: inline-block
}

:where(#plp_container) .pill-skel::after{
    content: "";
    position: absolute;
    inset: 0;
    transform: translateX(-100%);
    background: linear-gradient(90deg, transparent, var(--liner-skel-color), transparent);
    animation: plpLegacyShimmer 1.1s infinite
}

/* === Filter facet skeletons === */
:where(#plp_container) .facet-skel{
    display: grid;
    gap: 10px;
    margin: 6px 0;
}

:where(#plp_container) .facet-skel .row{
    height: 14px;
    border-radius: 8px;
    background: var(--skel-color);
    position: relative;
    overflow: hidden;
}

:where(#plp_container) .facet-skel .row::after{
    content: "";
    position: absolute;
    inset: 0;
    transform: translateX(-100%);
    background: linear-gradient(90deg, transparent, var(--liner-skel-color), transparent);
    animation: plpLegacyShimmer 1.1s infinite;
}

:where(#plp_container) .facet-group-title{
    height: 12px;
    width: 38%;
    border-radius: 6px;
    background: var(--skel-color);
    margin: 10px 0 6px;
    position: relative;
    overflow: hidden;
}

:where(#plp_container) .facet-group-title::after{
    content: "";
    position: absolute;
    inset: 0;
    transform: translateX(-100%);
    background: linear-gradient(90deg, transparent, var(--liner-skel-color), transparent);
    animation: plpLegacyShimmer 1.1s infinite;
}

@keyframes plpLegacyShimmer {
    100% {
        transform: translateX(100%)
    }
}

/* Shell / Products */
:where(#plp_container) .shell{
    position: relative;
    display: block;
    min-height: calc(100vh - var(--site-header-h));
    padding: 16px 0;
    overflow: hidden
}

:where(#plp_container) .products{
    width: 100%;
    transition: width var(--speed) var(--easing)
}

:where(#plp_container) .results-head{
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 8px 0 12px
}

:where(#plp_container) .muted{
    color: var(--muted)
}

:where(#plp_container) .cards{
    display: grid;
    margin: 0;
    padding: 0;
    list-style: none;
    gap: 12px;
    transition: gap var(--speed) var(--easing), opacity var(--fade) ease;
    justify-content: center;
    width: 100%;
    max-width: 100%;
    grid-template-columns: repeat(2, minmax(0, 1fr)); 
    box-sizing: border-box;
}

:where(#plp_container) .cards.is-crossfading{
    opacity: 0.01
}

/* GRID PRESETS */
@media (min-width:901px) {
    #plp_container.grid-2 .cards{
        grid-template-columns: repeat(2, minmax(220px, min(100%, var(--d2-col-max))))
    }

    #plp_container.grid-4 .cards{
        grid-template-columns: repeat(4, minmax(0, 1fr))
    }

    #plp_container.grid-8 .cards{
        grid-template-columns: repeat(8, minmax(140px, 1fr))
    }

    #plp_container.filters-open.grid-8 .cards{
        grid-template-columns: repeat(8, minmax(120px, 1fr));
        /* optional: tighten gaps a bit if you still see a squeeze */
        /* gap: 10px; */
    }
}




/* اصلاح wrap برای زبان فارسی */
:where(#plp_container) .wrap{
    direction: rtl !important; /* حتما RTL باشد */
    padding: 0 var(--gutter);
    width: 100%;
    box-sizing: border-box;
}


@media (max-width:900px) {
    #plp_container.grid-2 .cards{
        grid-template-columns: repeat(2, minmax(0, 1fr))
    }

    #plp_container.grid-4 .cards{
        grid-template-columns: repeat(4, minmax(0, 1fr))
    }

    #plp_container.grid-4 .card .body{
        display: none
    }

    /* image-only on mobile at 4 cols */
}

:where(#plp_container) .card{
    background-color: rgb(56, 56, 56);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: transform var(--speed) var(--easing), opacity var(--speed) var(--easing);
     min-width: 0; /* مانع از بیرون‌زدگی محتوای داخلی کارت می‌شود */
    width: 100%;
}

:where(#plp_container) .products.animating .card{
    transform: scale(.985);
    opacity: .98
}

:where(#plp_container) .thumb{
    aspect-ratio: 173/258;
    background: #0c111a;
    display: flex;
    align-items: center;
    justify-content: center
}

:where(#plp_container) .thumb img{
    max-width: 100%;
    max-height: 100%;
    display: block
}

:where(#plp_container) .body{
    padding: 10px;
    display: flex;
    flex-direction: column;
    justify-content: start;
    align-items: end;
}

:where(#plp_container) .title{
    font-size: 10px !important;
    font-weight: 700;
    line-height: 1.35;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100%;
}

:where(#plp_container) .meta{
    margin-top: 6px;
    color: #9aa3b6;
    font-size: 13px
}

/* Card skeletons */
:where(#plp_container) .card.skel .thumb{
    position: relative;
    background: var(--skel-color);
    overflow: hidden
}

:where(#plp_container) .card.skel .thumb::after{
    content: "";
    position: absolute;
    inset: 0;
    transform: translateX(-100%);
    background: linear-gradient(90deg, transparent, var(--liner-skel-color), transparent);
    animation: plpLegacyShimmer 1.1s infinite
}

:where(#plp_container) .card.skel .body>div{
    height: 12px;
    border-radius: 6px;
    background-color: var(--liner-skel-color);
    margin-top: 8px
}

:where(#plp_container) .card.skel .body>div:first-child{
    height: 18px;
    margin-top: 0;
    width: 75%
}

/* Tiny spinner */
:where(#plp_container) .spinner{
    width: 16px;
    height: 16px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, .2);
    border-top-color: rgba(255, 255, 255, .85);
    animation: plpLegacySpin .7s linear infinite;
    display: inline-block;
    vertical-align: middle
}

@keyframes plpLegacySpin {
    to {
        transform: rotate(360deg)
    }
}

/* Backdrop — above everything except panel */
:where(#plp_container) .backdrop{
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, .45);
    opacity: 0;
    pointer-events: none;
    transition: opacity var(--speed);
    z-index: 900;
}

#plp_container.filters-open .backdrop{
    opacity: 1;
    pointer-events: auto
}

/* ===== FILTERS ===== */
:where(#plp_container) .filters{
    background: var(--panel);
    border-left: 1px solid var(--border);
    box-shadow: var(--shadow);
    overflow-y: scroll;
    scrollbar-gutter: stable;
}

:where(#plp_container) .filters-inner{
    padding: 14px;
    direction: rtl;
}

:where(#plp_container) .filters h3{
    margin: 0 0 10px;
    font-size: 14px;
    color: #cbd3e2;
    text-transform: uppercase;
    letter-spacing: .14em
}

:where(#plp_container) .filter_group_container{
    border-bottom: 1px solid gainsboro;
}

:where(#plp_container) .filter_group_item{
    color: black;
}


/* Desktop: FIXED, full height, aligned to container’s right, internal scroll */
@media (min-width:901px) {
    :where(#plp_container) .filters{
        position: fixed;
        top: 0;
        /* start below site header */
        right: var(--wrap-right);
        /* align with container right edge */
        height: 100vh;
        /* full viewport height under site header */
        width: var(--panelPx);
        max-width: 420px;
        min-width: 280px;
        border-radius: 12px;
        overflow: auto;
        /* internal scroll */
        transform: translateX(100%);
        opacity: 0;
        visibility: hidden;
        pointer-events: none;
        transition: transform var(--speed) var(--easing), opacity var(--speed), visibility 0s linear var(--speed);
        z-index: 1000;
        /* above headers */

    }

    #plp_container.filters-open .filters{
        transform: translateX(0);
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
        transition-delay: 0s;
        z-index: 99999;

    }

    /* Keep products from running under the fixed panel */
    #plp_container.filters-open .products{
        width: calc(100% - var(--panelPx))
    }
}

/* Mobile: overlay full screen */
@media (max-width:900px) {
    :where(#plp_container) .filters{
        position: fixed;
        inset: 0;
        width: 100%;
        height: 100%;
        border-radius: 0;
        border-left: 0;
        transform: translateX(100%);
        opacity: 0;
        visibility: hidden;
        pointer-events: none;
        transition: transform var(--speed) var(--easing), opacity var(--speed);
        z-index: 1000;
        max-width: 100% !important;
    }

    :where(#plp_container) .filter-controls{
        align-items: start !important;
    }
    :where(#plp_container) .toggle-btn{
        width: 48% !important;
    }


    #plp_container.filters-open{
        overflow: hidden
    }

    #plp_container.filters-open .filters{
        transform: translateX(0);
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
        z-index: 99999;
    }
    #plp_container .filters{width: 100% !important;}
}

:where(#plp_container) .filters .close{
    display: flex !important;
    justify-content: start !important;
    align-items: center !important;
    position: sticky;
    top: 0;
    z-index: 1;
    display: flex;
    justify-content: flex-end;
    background: linear-gradient(180deg, rgb(227, 227, 227), rgba(244, 244, 244, 0.7) 60%, transparent);
    padding: 10px
}

:where(#plp_container) .filters .close .btn{
    background-color: crimson !important;
    color: white;
}

:where(#plp_container) :where(button, a, input):focus-visible{
    outline: 2px solid var(--brand);
    outline-offset: 2px;
    border-radius: 10px
}



/* main filters item style */

/* -------- FILTER ITEM (Square Pill Style) -------- */
/* -------- FILTER GROUP -------- */
:where(#plp_container) .filter-group{
    border-bottom: 2px solid gainsboro;
    margin-bottom: 10px;
    background: transparent !important;
    overflow: hidden;
    transition: box-shadow .25s ease;
}

:where(#plp_container) .filter-group.open{
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    background: rgba(255, 255, 255, 0.8) !important;
}

/* -------- HEADER -------- */
:where(#plp_container) .group-header{
    width: 100%;
    border: none;
    padding: 10px 14px;
    font-weight: 600;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 15px;
    cursor: pointer;
    transition: background .25s, color .25s;
}

:where(#plp_container) .group-header:hover{
    background: #f0f0f0;
    color: #111;
}

:where(#plp_container) .group-header i{
    transition: transform .25s ease;
    opacity: 0.6;
}

:where(#plp_container) .filter-group.open .group-header i{
    transform: rotate(180deg);
    opacity: 1;
}

/* -------- BODY -------- */
:where(#plp_container) .group-body{
    display: none;
    padding: 10px 12px 14px;
    overflow: hidden;
}

/* -------- FILTER CONTROLS -------- */
:where(#plp_container) .filter-controls{
    display: flex;
    flex-direction: column;
    justify-content: start;
    align-items: start;
    gap: 8px;
    margin-bottom: 8px;
    padding: 10px;
}

:where(#plp_container) .filter-controls button{
    width: 100%;
    background: transparent;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 0px;
    padding: 5px 10px;
    font-size: 13px;
    cursor: pointer;
    transition: background .2s, color .2s, transform .1s;
}

:where(#plp_container) .filter-controls button:hover{
    background: #fd0d0d10;
    color: crimson;
    transform: scale(1.05);
}

/* -------- GRID LAYOUT -------- */
:where(#plp_container) .filter-grid{
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 2fr));
    gap: 6px;
    justify-items: stretch;
}

/* -------- FILTER ITEM (Pill Style) -------- */
:where(#plp_container) .filter-item{
    padding: 8px 10px;
    border: 1px solid #ddd;
    border-radius: 20px;
    text-align: center;
    cursor: pointer;
    color: #333;
    font-size: 14px;
    transition: background .2s, color .2s, transform .1s, border-color .2s;
    user-select: none;
}

:where(#plp_container) .filter-item:hover{
    background: #f9f9f9;
}

:where(#plp_container) .filter-item.selected{
    background: #fd0d0d10;
    color: crimson;
    border-color: crimson;
    font-weight: 600;
    transform: scale(1.05);
}

:where(#plp_container) .filter-item .count{
    display: block;
    font-size: 11px;
    color: #999;
    margin-top: 2px;
}

/* ==========================================================
 🎚️ Toggle Switch Controls (Select All / Clear All)
 — Smooth, clean, mobile-friendly
========================================================== */

:where(#plp_container) .filter-controls{
    display: flex;
    justify-content: flex-end;
    gap: 16px;
    margin-bottom: 10px;
    align-items: center;
}

:where(#plp_container) .toggle-btn{
    width: 100%;
    display: flex;
    justify-content: space-between;
    gap: 8px;
    cursor: pointer;
    font-size: 10px;
    color: #333;
    user-select: none;
}

/* Hide native checkbox */
:where(#plp_container) .toggle-btn input[type="checkbox"]{
    appearance: none;
    -webkit-appearance: none;
    width: 0;
    height: 0;
    position: absolute;
}

/* Switch track */
:where(#plp_container) .toggle-btn .switch{
    position: relative;
    width: 38px;
    height: 20px;
    background: #ccc;
    border-radius: 20px;
    transition: background 0.3s ease;
    flex-shrink: 0;
}

/* Switch handle */
:where(#plp_container) .toggle-btn .switch::before{
    content: "";
    position: absolute;
    top: 2px;
    left: 2px;
    width: 16px;
    height: 16px;
    background: #fff;
    border-radius: 50%;
    transition: transform 0.3s ease;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

/* Checked (ON) state */
:where(#plp_container) .toggle-btn input[type="checkbox"]:checked+.switch{
    background: crimson;
}

:where(#plp_container) .toggle-btn input[type="checkbox"]:checked+.switch::before{
    transform: translateX(18px);
}

/* Label text */
:where(#plp_container) .toggle-btn .label-text{
    pointer-events: none;
    transition: color 0.2s ease;
}

:where(#plp_container) .toggle-btn:hover .label-text{
    color: crimson;
}
:where(#plp_container) label{margin: 0 !important;}
/* Optional pressed feedback */
:where(#plp_container) .toggle-btn:active .switch::before{
    transform: scale(0.9) translateX(2px);
}

:where(#plp_container) .plp-card .price{font: 700 14px / 1.8 jpa-plp !important;}

:where(#plp_container) .plp-card .btn-add-mobile{border-radius: 100%}

:where(#plp_container) .products_slider_section .owl-stage{
    padding-right: 20px !important;
    align-items: baseline;
}

:where(#plp_container) .carousel_title_img_font{
    font-size: 18px !important;
}

@media screen and (max-width: 768px){
    :where(#plp_container) .modern_see_all_carousel{
        bottom: 30px;
    }
    :where(#plp_container) .modern_see_all_carousel{
        width: 40%;
        margin: auto;
        border-radius: 10px;
        left: 50% !important;
        transform: translate(-50%) !important;
        right: unset !important;
        font-family: "jpack" !important;
        background-color: #626262 !important;
    }
}

:where(#plp_container) .card-aekm{
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.3);
    width: 90%;
    max-width: 420px;
    padding: 20px;
    z-index: 9999;
    display: none;
    flex-direction: column;
    gap: 15px;
    animation: plpLegacyFadeInScale .25s ease;
}

:where(#plp_container) .card-aekm .image svg{
    width: 50px;
    height: 50px;
    stroke: #e74c3c;
    margin: 0 auto;
    display: block;
}

:where(#plp_container) .card-aekm .title{
    font-weight: bold;
    font-size: 18px;
    color: #333;
    display: block;
    margin-bottom: 5px;
    text-align: center;
}

:where(#plp_container) .card-aekm .message{
    color: #666;
    font-size: 14px;
    line-height: 1.6;
    text-align: center;
}

:where(#plp_container) .card-aekm .actions{
    display: flex;
    justify-content: space-between;
    gap: 10px;
}

:where(#plp_container) .card-aekm .desactivate,
:where(#plp_container) .card-aekm .cancel{
    flex: 1;
    padding: 10px 0;
    border-radius: 6px;
    text-align: center;
    cursor: pointer;
    font-weight: bold;
    transition: 0.2s;
    min-width: 79px;
    line-height: 30px;
    height: 30px;
    justify-content: center;
    align-items: center;
    font-size: 13px;
    margin: 0;
}

:where(#plp_container) .card-aekm .desactivate{
    background: #e74c3c;
    color: #fff;
}

:where(#plp_container) .card-aekm .desactivate:hover{
    background: #c0392b;
}

:where(#plp_container) .card-aekm .cancel{
    background: #eee;
    color: #444;
}

:where(#plp_container) .card-aekm .cancel:hover{
    background: #ddd;
}

@keyframes plpLegacyFadeInScale {
    from { opacity: 0; transform: translate(-50%, -40%) scale(0.95); }
    to   { opacity: 1; transform: translate(-50%, -50%) scale(1); }
}


:where(#plp_container) .basket-info .meta{
    font-size: 13px;
    color: #555;
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    align-items: center;
}

:where(#plp_container) .basket-info .meta-item i{
    margin-left: 4px;
    color: #999;
    font-size: 12px;
}

:where(#plp_container) .basket-info .separator{
    color: #bbb;
}


:where(#plp_container) .basket-item{
    display: flex;
    gap: 16px;
    background: #fff;
    border-radius: 14px;
    padding: 14px;
    box-shadow: 0 2px 8px rgba(0,0,0,.06);
    transition: box-shadow .2s;
}
:where(#plp_container) .basket-item:hover{
    box-shadow: 0 4px 14px rgba(0,0,0,.12);
}

:where(#plp_container) .thumb{
    position: relative;
    flex: 0 0 90px;
}
:where(#plp_container) .thumb img{
    width: 90px;
    height: auto;
    border-radius: 10px;
    object-fit: cover;
}
:where(#plp_container) .thumb .promotion_badge_basket{
    position: absolute;
    top: 6px;
    left: 6px;
    background: #ff4757;
    color: #fff;
    font-size: 11px;
    padding: 2px 6px;
    border-radius: 6px;
}

/* متن‌ها */
:where(#plp_container) .basket-info{
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
}
:where(#plp_container) .title{
    font-size: 15px;
    font-weight: 600;
    margin: 0;
}
:where(#plp_container) .meta{
    font-size: 13px;
    color: #666;
    margin: 0;
}

:where(#plp_container) .price-row{
    margin: 0;
}
:where(#plp_container) .price-row .price{
    font-size: 16px;
    font-weight: 700;
    width: 100%;
    display: inline-flex;
    align-items: center;
    color: #000
}
:where(#plp_container) .discount-info .old-price{
    text-decoration: line-through;
    color: #999;
    font-size: 13px;
}

:where(#plp_container) .main-basket-panel{
    display: flex;
    flex-direction: column;
    padding: 20px 20px 10px;
    overflow-y: scroll;
}

:where(#plp_container) .cashback-txt{
    text-align: right;
}
:where(#plp_container) .controls{
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
}
:where(#plp_container) .quantity-control{
    display: flex;
    align-items: center;
    gap: 8px;
    background: #f1f1f1;
    border-radius: 8px;
    padding: 4px 10px;
}
:where(#plp_container) .qty-btn{
    border: none;
    background: #ddd;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 16px;
    font-weight: bold;
    transition: background .2s;
    justify-content: center;
}
:where(#plp_container) .qty-btn:hover{ background: #bbb; }
:where(#plp_container) .qty{
    font-size: 14px;
    font-weight: 600;
    min-width: 20px;
    text-align: center;
    justify-content: center;
}

:where(#plp_container) .remove-btn{
    border: none;
    background: transparent;
    color: #ff4757;
    font-size: 10px;
    cursor: pointer;
    transition: opacity .2s;
}
:where(#plp_container) .remove-btn:hover{ opacity: .7; }

/* بج تخفیف */
:where(#plp_container) .discount-badge{
    position: absolute;
    top: 6px;
    right: 6px;
    background: #ff4757;
    color: #fff;
    font-size: 12px;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: 6px;
    box-shadow: 0 1px 4px rgba(0,0,0,.2);
}


:where(#plp_container) .thumb{
    position: relative;
}
:where(#plp_container) .thumb .promotion_badge_basket{
    position: absolute;
    top: 6px;
    left: 6px;
    background: #1e90ff;
    color: #fff;
    font-size: 11px;
    padding: 2px 6px;
    border-radius: 6px;
}

:where(#plp_container) .price-row .currency{
    font-size: 10px;
    margin-right: 3px;
    opacity: 0.8;
}

:where(#plp_container) .filters{
    font-family: "Inter", sans-serif;
    font-size: 14px;
    line-height: 1.5;
    color: #111;
}

:where(#plp_container) .filters{
    position: fixed;
    top: 0;
    right: -420px;
    width: 420px;
    height: 100vh;
    background: #fff;
    box-shadow: -8px 0 24px rgba(0,0,0,0.1);
    transition: right 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    overflow: hidden;
    direction: rtl;
}

:where(#plp_container) .filters[aria-hidden="false"]{
    right: 0;
}

:where(#plp_container) .filters-inner{
    height: calc(100vh - 150px);
    overflow-y: auto;
    padding: 0;
    scrollbar-width: none;
}

:where(#plp_container) .filters-inner::-webkit-scrollbar{
    display: none;
}

:where(#plp_container) .hstrip .swiper-wrapper{
    direction: rtl;
    justify-content: flex-start;
}

:where(#plp_container) .flt-head{
    padding: 20px 24px;
    border-bottom: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    background: #fff;
    z-index: 10;
}

:where(#plp_container) .flt-head .title{
    font-size: 20px;
    font-weight: 700;
}

:where(#plp_container) .icon-btn{
    background: none;
    border: none;
    cursor: pointer;
    transition: transform 0.2s;
}

:where(#plp_container) .icon-btn:hover{
    transform: scale(1.1);
}

:where(#plp_container) .flt-tags{
    padding: 16px 24px;
    position: sticky;
    top: 61px;
    background: #fff;
    z-index: 9;
    border-bottom: 1px solid #eee;
}

:where(#plp_container) #fltActiveTags.chips{
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 12px;
}

:where(#plp_container) #fltActiveTags .chip{
    background: #f8f8f8;
    border-radius: 20px;
    padding: 6px 14px;
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 6px;
    color: #333;
}

:where(#plp_container) #fltActiveTags .chip::after{
    content: "×";
    font-weight: bold;
    color: #aaa;
    cursor: pointer;
}

:where(#plp_container) .flt-tags .muted.small{
    font-size: 12px;
    color: #888;
    text-align: center;
}

:where(#plp_container) .fsec{
    border-bottom: 1px solid #f2f2f2;
}

:where(#plp_container) .fsec-h{
    padding: 10px 24px 10px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #fff;
    cursor: pointer;
    transition: background 0.2s;
    width: 100%;
}

:where(#plp_container) .fsec-h:hover{
    background: #f9f9f9;
}

:where(#plp_container) .fsec-h span:first-child{
    font-size: 16px;
    font-weight: 600;
    font-family: "jpack";
    color: #000000;
}

:where(#plp_container) .rhs{
    display: flex;
    align-items: center;
    gap: 16px;
}

:where(#plp_container) .exp-toggle{
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #f0f0f0;
    border: none;
    font-size: 16px;
    color: #666;
    cursor: pointer;
    transition: all 0.2s;
}

:where(#plp_container) .exp-toggle[aria-pressed="true"]{
    background: #111;
    color: #fff;
}

:where(#plp_container) .exp-toggle:hover{
    background: #ddd;
}

:where(#plp_container) .chev{
    transition: transform 0.3s ease;
    color: #aaa;
}



:where(#plp_container) .fsec .chev{
    transform: rotate(90deg);
}

:where(#plp_container) .fsec.is-open .chev{
    transform: rotate(180deg);
}

:where(#plp_container) .fsec-b{
    padding: 0 24px 50px 0;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease, padding 0.4s ease;
}

:where(#plp_container) .fsec.is-open .fsec-b{
    max-height: none;
    padding: 0 24px 20px 0;
}

:where(#plp_container) .hstrip{
    position: relative;
    overflow: hidden;
    padding: 0 0 0 0;}

:where(#plp_container) .hstrip .swiper-wrapper{
    transition-timing-function: linear;
}

:where(#plp_container) .fsec.is-expanded .hstrip{
    padding: 0;
}

:where(#plp_container) .hstrip-inner{
    display: flex;
    gap: 8px;
}

:where(#plp_container) .fsec.is-expanded .hstrip-inner{
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 8px 8px;
}

:where(#plp_container) .swiper-slide{
    flex-shrink: 0;
    width: auto;
}

:where(#plp_container) .f-chips .chip,
:where(#plp_container) .f-colors .dot{
    border-radius: 999px;
    padding: 8px 20px;
    font-size: 14px;
    color: #333;
    background: #f8f8f8;
    border: 1px solid #ddd;
    transition: all 0.2s;
    cursor: pointer;
    white-space: nowrap;
}

:where(#plp_container) .f-chips .chip:hover,
:where(#plp_container) .f-colors .dot:hover{
    background: #eee;
    border-color: #ccc;
}

:where(#plp_container) .f-chips .chip.is-active,
:where(#plp_container) .f-colors .dot.is-active{
    background: #d3060c;
    color: #fff;
    border-color: #d3060c;
}

:where(#plp_container) .f-colors .dot{
    width: 36px;
    height: 36px;
    padding: 0;
    border-radius: 50%;
    background: var(--dot);
    border: 2px solid #fff;
    box-shadow: 0 0 0 1px #ddd;
}

:where(#plp_container) .f-colors .dot.is-active{
    box-shadow: 0 0 0 3px #111;
}

:where(#plp_container) .f-groups{
    display: flex;
    flex-direction: column;
    gap: 12px;
}

:where(#plp_container) .cat-group{
    border-bottom: none;
}

:where(#plp_container) .cg-h{
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
}

:where(#plp_container) .cg-h .lbl{
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
}

:where(#plp_container) .cg-h input[type="checkbox"]{
    width: 18px;
    height: 18px;
    accent-color: #111;
    border-radius: 4px;
}

:where(#plp_container) .cg-toggle{
    background: #f8f8f8;
    border: none;
    color: #666;
    font-size: 13px;
    padding: 4px 8px;
    cursor: pointer;
    transition: color 0.2s;
}

:where(#plp_container) .cg-toggle:hover{
    color: #111;
}

:where(#plp_container) .cg-b{
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    gap: 8px;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease, padding 0.3s;
}

:where(#plp_container) .cg-b:not([style*="display: none"]){
    max-height: none;
    padding: 8px 16px;
}

:where(#plp_container) .f-item{
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 14px;
    color: #444;
    cursor: pointer;
    transition: color 0.2s;
}

:where(#plp_container) .f-item:hover{
    color: #111;
}

:where(#plp_container) .f-item input[type="checkbox"]{
    width: 18px;
    height: 18px;
    accent-color: #111;
    border-radius: 4px;
}

:where(#plp_container) .price-row{
    display: flex;
    align-items: center;
    gap: 12px;
    direction: ltr;
    padding: 12px 0;
}

:where(#plp_container) .price-row input{
    flex: 1;
    padding: 12px 16px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
    text-align: center;
    transition: border-color 0.2s;
}

:where(#plp_container) .price-row input:focus{
    border-color: #111;
    outline: none;
}

:where(#plp_container) .price-row .dash{
    color: #888;
    font-size: 20px;
}

:where(#plp_container) #priceApply{
    padding: 12px 20px;
    background: #111;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    cursor: pointer;
    transition: background 0.2s;
}

:where(#plp_container) #priceApply:hover{
    background: #333;
}

:where(#plp_container) .flt-foot{
    display: flex;
    gap: 12px;
    padding: 20px 24px;
    background: #fff;
    border-top: 1px solid #eee;
    position: sticky;
    bottom: 0;
    z-index: 10;
}

:where(#plp_container) .btn.primary,
:where(#plp_container) .btn.ghost{
    flex: 1;
    padding: 14px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

:where(#plp_container) .btn.primary{
    background: #111;
    color: #fff;
    border: none;
}

:where(#plp_container) .btn.primary:hover{
    background: #333;
}

:where(#plp_container) .btn.ghost{
    background: transparent;
    color: #111;
    border: 1px solid #ddd;
}

:where(#plp_container) .btn.ghost:hover{
    border-color: #111;
}

:where(#plp_container) .sizes-row--mobile{display: none}

@media (max-width: 768px) {
    :where(#plp_container) .filters{
        width: 100vw;
        right: -100vw;
    }

    :where(#plp_container) .sizes-row--mobile{
        display: flex;
    }

    :where(#plp_container) .filters[aria-hidden="false"]{
        right: 0;
    }

    :where(#plp_container) .filters-inner{
        height: calc(100dvh - 150px);
    }
}

:where(#plp_container) .f-item input[type="checkbox"]{
    appearance: none;
    width: 20px;
    height: 20px;
    border: 2px solid #ccc;
    border-radius: 4px;
    position: relative;
    transition: all 0.2s;
}

:where(#plp_container) .f-item input[type="checkbox"]:checked{
    border-color: #111;
    background: #111;
}

:where(#plp_container) .f-item input[type="checkbox"]:checked::after{
    content: "✔";
    position: absolute;
    top: -2px;
    left: 2px;
    color: #fff;
    font-size: 14px;
}

:where(#plp_container) .cg-h input[type="checkbox"]{
    appearance: none;
    width: 20px;
    height: 20px;
    border: 2px solid #ccc;
    border-radius: 4px;
    position: relative;
    transition: all 0.2s;
}

:where(#plp_container) .cg-h input[type="checkbox"]:checked{
    border-color: #111;
    background: #111;
}

:where(#plp_container) .cg-h input[type="checkbox"]:checked::after{
    content: "✔";
    position: absolute;
    top: -2px;
    left: 2px;
    color: #fff;
    font-size: 14px;
}
/* چیپ رنگ مینیمال */
:where(#plp_container) .f-colors .chip-color{
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    background: #f7f7f7;
    border: 1px solid #e6e6e6;
    border-radius: 999px;
    cursor: pointer;
    white-space: nowrap;
    transition: background .2s, border-color .2s, color .2s, transform .12s;
    width: auto;
}

:where(#plp_container) .f-colors .chip-color .swatch{
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: var(--dot);
    box-shadow: 0 0 0 1px rgba(0, 0, 0, .08) inset;
    position: relative;
    flex: 0 0 9px;
    transition: transform .12s, box-shadow .2s;
    border: 1px solid #fff;
}

:where(#plp_container) .f-colors .chip-color .lbl{
    font-size: 13px;
    color: #fff;
    line-height: 1;
    opacity: .9;
    transition: color .2s, opacity .2s;
}

:where(#plp_container) .f-colors .chip-color .tick{
    width: 14px;
    height: 14px;
    position: relative;
    background: #fff;
    -webkit-mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath fill='%23000' d='M9.0 16.2 4.8 12l-1.4 1.4L9 19 21 7l-1.4-1.4z'/%3E%3C/svg%3E") center/contain no-repeat;
    mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath fill='%23000' d='M9.0 16.2 4.8 12l-1.4 1.4L9 19 21 7l-1.4-1.4z'/%3E%3C/svg%3E") center/contain no-repeat;
    opacity: 0; /* فقط در اکتیو نمایش */
    pointer-events: none;
    transition: opacity .15s ease;
}

/* Hover حالت لطیف */
:where(#plp_container) .f-colors .chip-color:hover{
    background: #f1f1f1;
    border-color: #d9d9d9;
    transform: translateZ(0) scale(1.01);
}


:where(#plp_container) .f-colors .chip-color.is-active{
    background: #111;
    color: #fff;
    border-color: #111;
    box-shadow: 0 6px 16px rgba(17,17,17,.12);
    align-items: center;
}

:where(#plp_container) .f-colors .chip-color.is-active .lbl{
    color: #fff;
    opacity: 1;
}

/* رینگ دوتایی روی سواچ */
:where(#plp_container) .f-colors .chip-color.is-active .swatch{
    transform: scale(1.06);
    box-shadow:
            0 0 0 2px #fff,   /* رینگ داخلی */
            0 0 0 4px #111,   /* رینگ بیرونی */
            0 2px 8px rgba(0,0,0,.18);
}

/* تیک روشن می‌شود */
:where(#plp_container) .f-colors .chip-color.is-active .tick{
    opacity: .95;
}

:where(#plp_container) .plp-card .row-top-mobile{min-height: 35px}

/* حالت فشرده‌تر روی موبایل */
@media (max-width: 480px) {
    :where(#plp_container) .f-colors .chip-color{ padding: 8px 10px; gap: 8px; }
    :where(#plp_container) .f-colors .chip-color .swatch{        width: 9px;
        height: 9px; }
    :where(#plp_container) .f-colors .chip-color .lbl{ font-size: 12px; }
}

:where(#plp_container).plp_container.jpa-plp.grid-4{

}

@media screen and (max-width: 768px){
    :where(#plp_container).plp_container.jpa-plp.grid-4 .cards{
        gap: 0 !important;
    }
    :where(#plp_container).plp_container.jpa-plp.grid-4 .swiper-pagination,
:where(#plp_container).plp_container.jpa-plp.grid-4 .plp-card .top-actions,
:where(#plp_container).plp_container.jpa-plp.grid-4 .plp-card .sizes-row,
:where(#plp_container).plp_container.jpa-plp.grid-4 .plp-card .color-badges{
        display: none;
    }

    :where(#plp_container).plp_container.jpa-plp.grid-4 .price-row .price{
        font: 700 11px / 1.8 jpa-plp !important;
        direction: rtl;
        justify-content: center;
        text-align: center;
    }
    :where(#plp_container).plp_container.jpa-plp.grid-4 .price-row .prices{
        width: 100%;
    }

    :where(#plp_container).plp_container.jpa-plp.grid-4 .plp-card .price-row{
        margin: 0;
        padding: 0;
    }
    :where(#plp_container).plp_container.jpa-plp.grid-4 .plp-card{
        border-radius: 0;
    }

    :where(#plp_container).plp_container.jpa-plp.grid-4 .plp-card .row-top-mobile{
        align-items: baseline;
        min-height: 35px;
    }

    :where(#plp_container).plp_container.jpa-plp.grid-4 .price-off{
        position: absolute;
        top: 0;
        z-index: 1;
        left: 0;
    }
    :where(#plp_container).plp_container.jpa-plp.grid-4 .price-off{
        border-radius: 2px;
        font-size: 8px;
        padding: 3px 5px;
    }
    :where(#plp_container).plp_container.jpa-plp.grid-4 .price-row.has-off .prices{
        flex-direction: column;
        align-items: center;
        direction: rtl;
        gap: 0;
    }
}


:where(#plp_container) .f-chips .chip,
:where(#plp_container) .f-colors .dot{
    width: 90px;
    top: 0;
    right: 0;
}

:where(#plp_container) .plp-card .btn-add-mobile{border-radius: 100% !important;}

/* ===== JPA PLP — Pager UI (RTL-first, Mobile/Desktop) ===== */
:where(#plp_container) #plpPager{
    --pg-bg:#fff; --pg-br:#e5e7eb; --pg-shadow:0 8px 24px rgba(16,24,40,.06);
    --pg-size:40px; --pg-gap:8px; --pg-radius:12px;
    --pg-fg:#111827; --pg-fg-muted:#667085; --pg-active:#111827; --pg-active-fg:#fff;
    --pg-hover:#f2f4f7; --pg-disabled:.45;

    background:var(--pg-bg); border:1px solid var(--pg-br); border-radius:16px;
    box-shadow:var(--pg-shadow); padding:10px 12px; margin:16px 0;
}

/* Wrapper: در دسکتاپ بالا، در موبایل استیکی پایین */
@media (min-width: 641px){
    :where(#plp_container) #plpPager{ position:sticky; top:0; z-index:7; }
}
@media (max-width: 640px){
    :where(#plp_container) #plpPager{ position:sticky; bottom:0; top:auto; border-radius:18px 18px 0 0; }
}

/* Grid layout: دکمه‌های قبلی/بعدی دو طرف، اعداد وسط */
:where(#plp_container) #plpPager{ display:grid; grid-template-columns: auto 1fr auto; align-items:center; gap:12px; }
:where(#plp_container) #plpPager .meta{ grid-column: 1 / -1; display:flex; align-items:center; gap:8px;
    color:var(--pg-fg-muted); font-size:12px; line-height:1; }
:where(#plp_container) #plpPager .meta .sep{ opacity:.6; }
:where(#plp_container) #plpPager .meta b{ color:var(--pg-fg); }

:where(#plp_container) #plpPager .controls{ grid-column: 1 / -1; display:grid; grid-template-columns:auto 1fr auto; align-items:center; gap:8px; }
:where(#plp_container) #plpPager .controls .nums{ grid-column:2; justify-self:center; display:flex; align-items:center; gap:var(--pg-gap); }

/* RTL: شماره‌ها از راست به چپ دیده شوند */
html[dir="rtl"] :where(#plp_container) #plpPager .controls .nums{ flex-direction: row-reverse; }

/* دکمه‌های اول/قبلی در راست، بعدی/آخر در چپ (با RTL سازگار) */
:where(#plp_container) #plpPager .controls .first,
:where(#plp_container) #plpPager .controls .prev{ grid-column:1; }
:where(#plp_container) #plpPager .controls .next,
:where(#plp_container) #plpPager .controls .last{ grid-column:3; }

/* دکمه‌ها */
:where(#plp_container) #plpPager .pg,
:where(#plp_container) #plpPager .num,
:where(#plp_container) #plpPager .gap{
    min-width:var(--pg-size); height:var(--pg-size);
    padding:0 10px; border:1px solid var(--pg-br); background:#fff;
    color:var(--pg-fg); border-radius:var(--pg-radius);
    display:inline-flex; align-items:center; justify-content:center;
    font:600 13px/1 system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
    cursor:pointer; transition:transform .08s ease, background-color .12s ease, border-color .12s ease;
}
:where(#plp_container) #plpPager .pg:hover,
:where(#plp_container) #plpPager .num:hover,
:where(#plp_container) #plpPager .gap:hover{ background:var(--pg-hover); }
:where(#plp_container) #plpPager .pg:active,
:where(#plp_container) #plpPager .num:active,
:where(#plp_container) #plpPager .gap:active{ transform: translateY(1px); }

/* شماره فعال */
:where(#plp_container) #plpPager .num.active{
    background:var(--pg-active); color:var(--pg-active-fg); border-color:var(--pg-active);
}

/* غیر فعال */
:where(#plp_container) #plpPager .pg:disabled{ opacity:var(--pg-disabled); cursor:not-allowed; }

/* کلیدهای پرش (… ±5) */
:where(#plp_container) #plpPager .gap{
    font-weight:700; border-style:dashed; letter-spacing:1px;
}

/* اعداد قابل اسکرول در موبایل، اما تمیز و بدون اسکرول‌بار */
@media (max-width: 640px){
    :where(#plp_container) #plpPager{ --pg-size:36px; --pg-gap:6px; padding:10px; }
    :where(#plp_container) #plpPager .meta{ font-size:11px; }
    :where(#plp_container) #plpPager .controls .nums{ overflow-x:auto; -ms-overflow-style:none; scrollbar-width:none; }
    :where(#plp_container) #plpPager .controls .nums::-webkit-scrollbar{ display:none; }
}

/* اندازه‌های لمسی مناسب */
@media (pointer:coarse){
    :where(#plp_container) #plpPager .pg,
:where(#plp_container) #plpPager .num,
:where(#plp_container) #plpPager .gap{ min-width:44px; height:44px; }
}

/* JPA Pager — Minimal Clean UI (RTL, Mobile/Desktop) */
:where(#plp_container) #plpPager{
    --bg:#fff; --br:#eceff3; --fg:#1f2937; --muted:#6b7280;
    --primary:#0f172a; --primary-fg:#fff; --hover:#f3f4f6;
    --radius:12px; --size:38px; --gap:8px;
    background:var(--bg); border:1px solid var(--br); border-radius:16px;
    padding:10px 12px; margin:16px 0; box-shadow:0 8px 24px rgba(16,24,40,.06);
    display:grid; grid-template-columns:1fr; gap:10px;
}

/* Meta line */
:where(#plp_container) #plpPager .meta{ display:flex; align-items:center; gap:8px; color:var(--muted); font-size:12px; }
:where(#plp_container) #plpPager .meta .dot{ width:4px; height:4px; border-radius:50%; background:#d1d5db; display:inline-block; }
:where(#plp_container) #plpPager .meta b{ color:var(--fg); }

/* Controls */
:where(#plp_container) #plpPager .controls{ display:flex;  align-items:center; gap:10px; }
:where(#plp_container) #plpPager .nums{ display:flex; align-items:center; gap:var(--gap); justify-content:center; }

/* RTL: اعداد از راست به چپ */
html[dir="rtl"] :where(#plp_container) #plpPager .nums{ flex-direction:row-reverse; }

/* Buttons */
:where(#plp_container) #plpPager .num,
:where(#plp_container) #plpPager .gap,
:where(#plp_container) #plpPager .nav{
    min-width:var(--size); height:var(--size);
    background:#fff; border:1px solid var(--br); color:var(--fg);
    border-radius:12px; display:inline-flex; align-items:center; justify-content:center;
    font:600 13px/1 system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
    cursor:pointer; transition:background-color .12s ease, border-color .12s ease, transform .08s ease;
}
:where(#plp_container) #plpPager .num:hover,
:where(#plp_container) #plpPager .gap:hover,
:where(#plp_container) #plpPager .nav:hover{ background:var(--hover); }
:where(#plp_container) #plpPager .num:active,
:where(#plp_container) #plpPager .gap:active,
:where(#plp_container) #plpPager .nav:active{ transform:translateY(1px); }
:where(#plp_container) #plpPager .num.active{ background:var(--primary); color:var(--primary-fg); border-color:var(--primary); }
:where(#plp_container) #plpPager .nav:disabled{ opacity:.5; cursor:not-allowed; }

/* Gap (… ±5) */


:where(#plp_container) #plpPager .gap{ border-style:dashed; font-weight:700; letter-spacing:1px; }


:where(#plp_container) #gridToggle{background: transparent;border: unset}
/* Mobile tweaks */
@media (max-width:640px){
    :where(#plp_container) #plpPager{ --size:36px; padding:10px; border-radius:18px 18px 12px 12px; position:sticky; bottom:0; z-index:7; }
    :where(#plp_container) #plpPager .meta{ font-size:11px; }
    :where(#plp_container) #plpPager .nums{ overflow-x:auto; -ms-overflow-style:none; scrollbar-width:none; }
    :where(#plp_container) #plpPager .nums::-webkit-scrollbar{ display:none; }

    :where(#plp_container) .plp-searchbar #filterToggle{
        width: 70%;
    }

    :where(#plp_container) .plp-searchbar #gridToggleMobile{
        width: 30%;
    }

    :where(#plp_container) #resultCount{
        width: 50%;
        text-align: right;
        direction: rtl;
    }
    :where(#plp_container) .plp-searchbar .sort-select{
        width: 50%;
    }
    :where(#plp_container) #sortSelect{
        width: 100%;
    }
    :where(#plp_container) .plp-searchbar .wrap .right{padding: 0 20px !important;}
    :where(#plp_container) .plp-searchbar .wrap .right,
:where(#plp_container) .plp-searchbar .wrap .left{gap: 0 !important;width: 100% !important;margin: 0 0 0 23px;}
}

@media (min-width:641px){
    :where(#plp_container) #plpPager{ position:sticky; top:0; }
}

:where(#plp_container) .switcher{ display:flex; align-items:center; gap:.6rem; }
:where(#plp_container) .switcher .sui{ position:relative; width:40px; height:22px; border-radius:999px; background:#e5e7eb; transition:.2s; }
:where(#plp_container) .switcher input{ display:none; }
:where(#plp_container) .switcher .sui::after{ content:""; position:absolute; top:3px; left:3px; width:16px; height:16px; background:#fff; border-radius:50%; box-shadow:0 1px 3px rgba(0,0,0,.2); transition:.2s; }
:where(#plp_container) .switcher input:checked + .sui{ background:#10b981; }
:where(#plp_container) .switcher input:checked + .sui::after{ transform:translateX(18px); }
:where(#plp_container) .active-tags{ display:flex; flex-wrap:wrap; gap:8px; margin:8px 0 0 }
:where(#plp_container) .chip{ display:inline-flex; align-items:center; gap:.35rem; padding:.35rem .6rem; border:1px solid #e5e7eb; border-radius:999px; background:#fff; font-size:.9rem }
:where(#plp_container) .chip--rem span{ opacity:.6; font-weight:700 }
:where(#plp_container) .active-tags-sw{ margin: 6px 0 10px;}
:where(#plp_container) #activeTagsSwiper{ padding: 2px 0; }
:where(#plp_container) #activeTagsSwiper .swiper-slide{ width: auto; }

:where(#plp_container) .chip-min{
    display:inline-flex; align-items:center; gap:.4rem;
    padding:.28rem .6rem; border:1px solid #e5e7eb;
    border-radius:999px; background:#fff; font-size:11px; line-height:1.2;
    box-shadow:0 1px 2px rgba(16,24,40,.04);
    white-space:nowrap; user-select:none; cursor:pointer;
}
:where(#plp_container) .chip-min .x{ font-weight:700; opacity:.45; }
:where(#plp_container) .chip-min:hover{ background:#f9fafb; border-color:#e5e7eb; }
:where(#plp_container) .chip-min[data-k="discount_only"],
:where(#plp_container) .chip-min[data-k="bigSize"]{ border-style:dashed; }

@media (prefers-color-scheme: dark) {
    :where(#plp_container) .chip-min{ background:#0b0f13; border-color:#1e293b; color: #fff}
    :where(#plp_container) .chip-min:hover{ background:#0e1218;}
}
/* جا بده در CSS صفحه‌ات */
:where(#plp_container) .chip-min--color .chip-dot{display:inline-block;width:10px;height:10px;border-radius:50%;margin-inline-end:6px;vertical-align:-1px;background:var(--dot,#ccc);box-shadow:inset 0 0 0 1px rgba(0,0,0,.08);}

/* ===== Offers (chips slider) ===== */
:where(#plp_container) .plp-offers-bar{ min-width: 0; }
:where(#plp_container) #offersSwiper{ width: min(64vw, 700px); }
:where(#plp_container) #offersSwiper .swiper-wrapper{ align-items: stretch; }
:where(#plp_container) .offer-chip{
    --bg: #f7f7f8;
    --ring: rgba(0,0,0,.06);
    --txt: #111;
    --shadow: 0 6px 18px rgba(16,24,40,.06);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 12px;
    border-radius: 999px;
    background: var(--bg);
    color: var(--txt);
    border: 1px solid var(--ring);
    box-shadow: var(--shadow);
    cursor: pointer;
    user-select: none;
    white-space: nowrap;
    font: 600 12px/1 system-ui;
    max-width: 150px;
    transition: transform .15s ease, box-shadow .2s ease, background .2s ease, color .2s ease, border-color .2s ease;
}
:where(#plp_container) .offer-chip .ico{
    width: 18px; height: 18px; display: inline-grid; place-items:center;
}
:where(#plp_container) .offer-chip .lbl{ letter-spacing: -.2px }
:where(#plp_container) .offer-chip:hover{ transform: translateY(-1px); box-shadow: 0 10px 24px rgba(16,24,40,.10); }
:where(#plp_container) .offer-chip.is-active{
    border-color: transparent;
    box-shadow: 0 10px 26px rgba(16,24,40,.12);
}


:where(#plp_container) .offer-chip[data-theme="stock"]{ --bg: #f7f7f8; --txt:#222; }
:where(#plp_container) .offer-chip .badge{
    font: 700 10px/1 system-ui; padding: 4px 6px; border-radius: 999px;
    background: rgba(255,255,255,.7); color: inherit; border:1px solid rgba(0,0,0,.06);
}

@media (max-width: 768px){
    :where(#plp_container) #offersSwiper{ width: 58vw; }
}
:where(#plp_container) .plp-searchbar .row-top{ gap:12px; }
:where(#plp_container) .plp-searchbar .row-offers{ display:flex; align-items:center; }

:where(#plp_container) .muted-small{
    font-size:12px;
    opacity:.8;
}


:where(#plp_container) #offersSwiper{ width:100%; }
:where(#plp_container) #offersSwiper .swiper-wrapper{ align-items:stretch;    justify-content: right; }
:where(#plp_container) #offersSwiper,
:where(#plp_container) #activeTagsSwiper{ direction: rtl;    display: inline-flex;
    padding: 0 19px 0 0; }
/* ============ Grid switch ============ */
:where(#plp_container) .grid-toggle{ padding: 6px; border-radius: 12px; }
:where(#plp_container) .grid-toggle .grid-switch{ display:block; }

:where(#plp_container) .grid-switch .sw-body{
    fill: none;
    stroke: currentColor;
    opacity: .28;
    stroke-width: 2;
}

:where(#plp_container) .grid-switch .sw-grid rect{
    fill: currentColor;
    opacity: .38;
    transform-origin: center;
    transition: transform .25s ease, opacity .2s ease, filter .2s ease;
}

/* پیکان */
:where(#plp_container) .grid-switch .sw-arrow path{
    stroke: currentColor;
    stroke-width: 2;
    opacity: .7;
    transition: transform .25s ease, opacity .2s ease;
}

/* نُب */
:where(#plp_container) .grid-switch .sw-knob{
    fill: currentColor;
    opacity: .12;
    transition: transform .28s ease, opacity .2s ease, fill .2s ease;
}




/* ===== Unique Grid Switch ===== */
:where(#plp_container) .grid-toggle-uni{ padding: 4px; border-radius: 12px; line-height: 0; }
:where(#plp_container) .grid-toggle-uni .uni{ display:block; color: currentColor; }

:where(#plp_container) .grid-toggle-uni .uni-bg{
    fill: none;
    stroke: currentColor;
    stroke-opacity: .18;
    stroke-width: 2;
}

/* کپسول‌ها */
:where(#plp_container) .grid-toggle-uni .cap{
    fill: currentColor;
    opacity: .06;
    transition: opacity .25s ease, transform .25s ease, filter .25s ease;
}

/* نقاط (گرید) */
:where(#plp_container) .grid-toggle-uni .dots rect{
    fill: currentColor;
    opacity: .42;
    transition: transform .25s ease, opacity .25s ease, filter .25s ease;
    transform-origin: center;
}

/* فلش مرکزی */
:where(#plp_container) .grid-toggle-uni .arrow .shaft,
:where(#plp_container) .grid-toggle-uni .arrow .head{
    stroke: currentColor;
    stroke-width: 2.2;
    stroke-linecap: square;
    fill: none;
    opacity: .7;
    transition: transform .25s ease, opacity .25s ease;
}

/* حلقه‌ی های‌لایت */
:where(#plp_container) .grid-toggle-uni .glow{
    fill: none;
    stroke: currentColor;
    stroke-opacity: .16;
    stroke-width: 6;
    filter: drop-shadow(0 0 6px rgba(0,0,0,.06));
    transition: transform .28s ease, opacity .28s ease, cx .28s ease;
}

/* حالت فعال: ۴ستون (RTL: سمت چپ) */
:root[dir="rtl"] :where(#plp_container) .grid-toggle-uni[data-view="4"] .side-left .cap{ opacity: .12; filter: drop-shadow(0 6px 16px rgba(0,0,0,.08)); }
:root[dir="rtl"] :where(#plp_container) .grid-toggle-uni[data-view="4"] .side-left .dots rect{ opacity: 1; transform: scale(1.08); }
:root[dir="rtl"] :where(#plp_container) .grid-toggle-uni[data-view="4"] .glow{ cx: 32px; opacity: .9; }

/* حالت غیرفعال: ۲ستون (RTL: سمت راست) */
:root[dir="rtl"] :where(#plp_container) .grid-toggle-uni[data-view="4"] .side-right .cap{ opacity: .04; }
:root[dir="rtl"] :where(#plp_container) .grid-toggle-uni[data-view="4"] .side-right .dots rect{ opacity: .28; transform: scale(.9); }

/* حالت فعال: ۲ستون (RTL: سمت راست) */
:root[dir="rtl"] :where(#plp_container) .grid-toggle-uni[data-view="2"] .side-right .cap{ opacity: .12; filter: drop-shadow(0 6px 16px rgba(0,0,0,.08)); }
:root[dir="rtl"] :where(#plp_container) .grid-toggle-uni[data-view="2"] .side-right .dots rect{ opacity: 1; transform: scale(1.1); }
:root[dir="rtl"] :where(#plp_container) .grid-toggle-uni[data-view="2"] .glow{ cx: 108px; opacity: .9; }

/* حالت غیرفعال: ۴ستون (RTL) */
:root[dir="rtl"] :where(#plp_container) .grid-toggle-uni[data-view="2"] .side-left .cap{ opacity: .04; }
:root[dir="rtl"] :where(#plp_container) .grid-toggle-uni[data-view="2"] .side-left .dots rect{ opacity: .28; transform: scale(.9); }

/* اگر LTR بودی، فقط جای cx و کلاس‌ها برعکس می‌شود: */
:root[dir="ltr"] :where(#plp_container) .grid-toggle-uni[data-view="4"] .glow{ cx: 108px; }
:root[dir="ltr"] :where(#plp_container) .grid-toggle-uni[data-view="2"] .glow{ cx: 32px; }
:root[dir="ltr"] :where(#plp_container) .grid-toggle-uni[data-view="4"] .side-right .cap,
:root[dir="ltr"] :where(#plp_container) .grid-toggle-uni[data-view="2"] .side-left  .cap{ opacity: .12; filter: drop-shadow(0 6px 16px rgba(0,0,0,.08)); }
:root[dir="ltr"] :where(#plp_container) .grid-toggle-uni[data-view="4"] .side-right .dots rect,
:root[dir="ltr"] :where(#plp_container) .grid-toggle-uni[data-view="2"] .side-left  .dots rect{ opacity:1; transform:scale(1.1); }
:root[dir="ltr"] :where(#plp_container) .grid-toggle-uni[data-view="4"] .side-left  .cap,
:root[dir="ltr"] :where(#plp_container) .grid-toggle-uni[data-view="2"] .side-right .cap{ opacity:.04; }
:root[dir="ltr"] :where(#plp_container) .grid-toggle-uni[data-view="4"] .side-left  .dots rect,
:root[dir="ltr"] :where(#plp_container) .grid-toggle-uni[data-view="2"] .side-right .dots rect{ opacity:.28; transform:scale(.9); }

/* انیمیشن فلش هنگام سوئیچ */
@keyframes plpUniWiggleRtl { 0%{transform:translateX(0)} 50%{transform:translateX(-2.2px)} 100%{transform:translateX(0)} }
@keyframes plpUniWiggleLtr { 0%{transform:translateX(0)} 50%{transform:translateX( 2.2px)} 100%{transform:translateX(0)} }
:root[dir="rtl"] :where(#plp_container) .grid-toggle-uni.wiggle .arrow{ animation: plpUniWiggleRtl .28s ease; }
:root[dir="ltr"] :where(#plp_container) .grid-toggle-uni.wiggle .arrow{ animation: plpUniWiggleLtr .28s ease; }

/* کاهش حرکت */
@media (prefers-reduced-motion: reduce){
    :where(#plp_container) .grid-toggle-uni .cap,
:where(#plp_container) .grid-toggle-uni .dots rect,
:where(#plp_container) .grid-toggle-uni .arrow .shaft,
:where(#plp_container) .grid-toggle-uni .arrow .head,
:where(#plp_container) .grid-toggle-uni .glow{ transition:none; animation:none !important; }
}

:where(#plp_container) .offer-chip{
    min-width: 60px !important;
    max-width: 150px !important;
    width: 80px !important;
}
/* هدر گروه */
:where(#plp_container) .cat-group{ border:1px solid #eee; border-radius:12px; background:#fff; margin-bottom:12px; }
:where(#plp_container) .cat-group .cg-h{
    display:flex; align-items:center; justify-content:space-between;
    padding:10px 12px; gap:12px;
}
:where(#plp_container) .cat-group .lbl{ display:flex; align-items:center; gap:8px; font:700 14px/1.6 system-ui; }

/* تاگل آیکونی (بدون متن) */
:where(#plp_container) .cg-toggle{
    display:inline-grid; place-items:center;
    width:auto; height:32px; border:1px solid #e5e7eb; border-radius:8px;
    background:#f8f8f8; color:#111; cursor:pointer;
    transition: border-color .2s ease, background .2s ease, color .2s ease;
}
:where(#plp_container) .cg-toggle:hover{ background:#f9fafb; border-color:#d1d5db; }
:where(#plp_container) .cg-toggle .chev{ transition: transform .22s ease; }

/* حالت باز: چرخش آیکون */
:where(#plp_container) .cat-group.is-open .cg-toggle .chev{ transform: rotate(180deg); }

/* بدنهٔ آیتم‌ها: سه‌ستونه روی دسکتاپ، RTL-فیکس */
:where(#plp_container) .cg-b{
    list-style:none; margin:0; padding:8px 12px 12px;
    display:grid; gap:10px;
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

/* آیتم چک‌باکس */
:where(#plp_container) .cg-b li{ min-width:0; }
:where(#plp_container) .f-item{ display:flex; align-items:center; gap:4px; }
:where(#plp_container) .f-item input[type="checkbox"]{
    width:18px; height:18px; accent-color:#111; /* اگر نخواستی، استایل سفارشی بذار */
}
:where(#plp_container) .f-item .t{ font:500 13px/1.8 system-ui; color:#111; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }

/* رسپانسیو */
@media (max-width: 900px){
    :where(#plp_container) .cg-b{ grid-template-columns: repeat(2, minmax(0, 1fr)); }

    :where(#plp_container) .f-item .t{
        font: 500 11px / 1.8 system-ui;
    }

}
@media (max-width: 520px){
    :where(#plp_container) .cg-b{ grid-template-columns: 1fr 1fr 1fr; }
}

/* انیمیشن باز/بسته با hidden */
:where(#plp_container) .cg-b[hidden]{ display:none !important; }



/* Theme tokens */
:where(#plp_container) .flt-head{
    --flt-bg: color-mix(in oklab, #0b1220 10%, #ffffff 90%);
    --flt-bg-2: color-mix(in oklab, #0b1220 2%, #ffffff 98%);
    --flt-border: color-mix(in oklab, #000 12%, transparent);
    --flt-shadow: 0 8px 24px rgba(16,24,40,.06), 0 2px 6px rgba(16,24,40,.04);
    --flt-accent: #d01d33;            /* می‌تونی با رنگ برندت عوض کنی */
    --txt: #0e1525;
}


@media (prefers-color-scheme: dark){
    :where(#plp_container) .flt-head{
        --flt-bg: rgba(17, 22, 34, .72);
        --flt-bg-2: rgba(17, 22, 34, .55);
        --flt-border: rgba(255,255,255,.08);
        --flt-shadow: 0 10px 30px rgba(0,0,0,.35);
        --txt: #e8ebf3;
    }
}

/* Container */
:where(#plp_container) .flt-head{
    position: sticky;
    top: 0;
    z-index: 5;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 16px;
    isolation: isolate;
}

/* Title */
:where(#plp_container) .flt-head .title{
    font-weight: 800;
    font-size: 16px;
    letter-spacing: .2px;
    display: inline-flex;
    align-items: center;
    gap: .6rem;
    position: relative;
    font-family: jpa-plpck;
}

/* Accent bar (animated) */
:where(#plp_container) .flt-head .title::after{
    content: "";
    height: 3px;
    width: 56px;
    border-radius: 999px;
    background:
            linear-gradient(90deg, var(--flt-accent), color-mix(in oklab, var(--flt-accent), #ffcf33 35%), var(--flt-accent));
    position: absolute;
    inset-inline-start: 0;
    bottom: -8px;

    animation: plpFilterTitleSweep 2.4s cubic-bezier(.22,1,.36,1) infinite;
    opacity: .9;
}

@keyframes plpFilterTitleSweep{
    0%   { transform: scaleX(.25); filter: brightness(1); }
    40%  { transform: scaleX(1);   filter: brightness(1.2); }
    60%  { transform: scaleX(.6);  filter: brightness(1); }
    100% { transform: scaleX(.25); filter: brightness(1); }
}

/* Close button */
:where(#plp_container) .flt-head .icon-btn{
    --size: 40px;
    inline-size: var(--size);
    block-size: var(--size);
    border-radius: 12px;
    border: 1px solid var(--flt-border);
    background: linear-gradient(180deg, rgba(255,255,255,.6), rgba(255,255,255,.4));
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    display: grid;
    place-items: center;
    cursor: pointer;
    transition: transform .18s ease, box-shadow .25s ease, background .25s ease;
    box-shadow: 0 2px 8px rgba(0,0,0,.06) inset;
    position: relative;
    outline: none;
}


@media (prefers-color-scheme: dark){
    :where(#plp_container) .flt-head .icon-btn{
        background: linear-gradient(180deg, rgba(255,255,255,.06), rgba(255,255,255,.03));
        box-shadow: 0 0 0 0 rgba(208,29,51,0); /* صاف در دارک */
    }
}

/* Icon sizing & animation */
:where(#plp_container) .flt-head .icon-btn svg{
    width: 18px;
    height: 18px;
    transition: transform .45s cubic-bezier(.22,1,.36,1), opacity .2s ease;
    opacity: .92;
    /* اگر سمبل #ico-close استروک دارد، این رنگ‌ها اعمال می‌شوند: */
    stroke: currentColor;
}

/* Hover/active states */
:where(#plp_container) .flt-head .icon-btn:hover{
    transform: translateY(-1px);
    box-shadow: 0 10px 20px rgba(16,24,40,.12);
    background: linear-gradient(180deg, rgba(255,255,255,.85), rgba(255,255,255,.6));
}
:where(#plp_container) .flt-head .icon-btn:active{
    transform: translateY(0);
}

/* Rotate the close icon on hover */
:where(#plp_container) .flt-head .icon-btn:hover svg{
    transform: rotate(90deg) scale(1.02);
}

/* Ripple feedback (pure CSS) */
:where(#plp_container) .flt-head .icon-btn::after{
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: radial-gradient(100% 100% at 50% 50%, color-mix(in oklab, var(--flt-accent) 35%, transparent), transparent 60%);
    opacity: 0;
    transform: scale(.6);
    transition: opacity .25s ease, transform .25s ease;
    pointer-events: none;
}
:where(#plp_container) .flt-head .icon-btn:hover::after{
    opacity: .22;
    transform: scale(1);
}

/* Keyboard focus (accessibility) */
:where(#plp_container) .flt-head .icon-btn:focus-visible{
    box-shadow: 0 0 0 3px color-mix(in oklab, var(--flt-accent) 40%, transparent);
}

/* Compact on small screens */
@media (max-width: 480px){
    :where(#plp_container) .flt-head{
        border-radius: 12px;
        padding: 12px 12px;
    }
    :where(#plp_container) .flt-head .title{ font-size: 15px !important; }
    :where(#plp_container) .flt-head .title::after{ bottom: -6px; width: 48px; }
    :where(#plp_container) .flt-head .icon-btn{ --size: 36px; }
}

/* Respect reduced motion */
@media (prefers-reduced-motion: reduce){
    :where(#plp_container) .flt-head .title::after,
:where(#plp_container) .flt-head .icon-btn svg{
        animation: none !important;
        transition: none !important;
    }
}
:where(#plp_container) .size-chip-side{
    width: 31px !important;
    border-radius: 4px !important;
    padding: 5px 0 !important;
    text-align: center;
    justify-content: center;
}

:where(#plp_container) #plpPager{
  width: 100%;
  max-width: 100%;
  overflow: hidden;
}

:where(#plp_container) #plpPager ul,
:where(#plp_container) #plpPager .pagination{
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
}

/* ========================================================================== 
   FINAL PLP FILTER VIEW — v2
   --------------------------------------------------------------------------
   Every rule is scoped to `.plp-filter-v2`.  The legacy filter/card rules
   above stay available for other pages, but cannot style this filter view.
   ========================================================================== */
.plp-filter-v2{
    --nf-ink: #1f2025;
    --nf-muted: #72767f;
    --nf-line: #e4e5e8;
    --nf-surface: #fbfbfc;
    --nf-primary: #1e3a99;
    --nf-danger: #ed1c24;
    --nf-panel-width: 318px;
    color: var(--nf-ink);
}

.plp-filter-v2,
.plp-filter-v2 *,
.plp-filter-v2 *::before,
.plp-filter-v2 *::after{
    box-sizing: border-box;
}

.plp-filter-v2 button,
.plp-filter-v2 input{
    font: inherit;
}

.plp-filter-v2 [hidden]{
    display: none !important;
}

/* The pager host must remain inside the product column. */
.plp-filter-v2 #shell{
    position: relative;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) var(--nf-panel-width) !important;
    align-items: start;
    gap: 20px;
    min-height: calc(100vh - var(--site-header-h));
    padding: 16px 0 40px;
    overflow: visible !important;
    direction: ltr;
}

.plp-filter-v2 #products{
    grid-column: 1;
    min-width: 0;
    width: 100% !important;
    direction: rtl;
}

.plp-filter-v2 .plp-pager-host{
    display: block;
    width: 100%;
    min-width: 0;
    margin-top: 20px;
    clear: both;
}

.plp-filter-v2 #plpPager{
    position: static !important;
    inset: auto !important;
    z-index: auto !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
    border-radius: 10px;
}

/* ------------------------------ desktop toolbar ------------------------- */
.plp-filter-v2 .plp-product-toolbar{
    min-height: 48px;
    display: flex;
    align-items: stretch;
    gap: 16px;
    margin-bottom: 12px;
    padding: 0 10px 0 12px;
    direction: rtl;
    border-radius: 2px;
    background: #fafafa;
}

.plp-filter-v2 .plp-sort-tabs{
    min-width: 0;
    flex: 1 1 auto;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    align-items: stretch;
}

.plp-filter-v2 .plp-sort-tab{
    position: relative;
    min-width: 0;
    width: 100%;
    height: 48px;
    padding: 0 6px;
    border: 0;
    border-radius: 0;
    color: #74777e;
    background: transparent;
    cursor: pointer;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 11px;
    font-weight: 600;
    line-height: 48px;
    text-align: center;
    font-family: 'iransans';

}

.plp-filter-v2 .plp-sort-tab::after{
    content: "";
    position: absolute;
    inset-inline: 6px;
    bottom: 0;
    height: 2px;
    border-radius: 2px 2px 0 0;
    background: transparent;
}

.plp-filter-v2 .plp-sort-tab.is-active{
    color: #17181c;
    /* Same metrics in both states: activating a tab never moves its siblings. */
    font-weight: 600;
}

.plp-filter-v2 .plp-sort-tab.is-active::after{
    background: var(--nf-danger);
}

.plp-filter-v2 .plp-sort-tab:disabled{
    color: #b4b6bb;
    cursor: default;
}

.plp-filter-v2 .plp-quick-filters{
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    gap: 20px;
    direction: rtl;
}

.plp-filter-v2 .plp-quick-filter{
    min-height: 36px;
    display: inline-flex;
    align-items: center;
    gap: 9px;
    padding: 0;
    border: 0;
    border-radius: 0;
    color: #6f737b;
    background: transparent;
    cursor: pointer;
    direction: ltr;
    white-space: nowrap;
    font-size: 11px;
}

.plp-filter-v2 .plp-switch{
    position: relative;
    width: 44px;
    height: 24px;
    flex: 0 0 44px;
    border-radius: 999px;
    background: #b9bcc2;
    direction: ltr;
    transition: background-color .18s ease;
}

.plp-filter-v2 .plp-switch i{
    position: absolute;
    top: 2px;
    left: 2px;
    width: 20px;
    height: 20px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 1px 2px rgba(0,0,0,.12);
    transition: transform .18s ease;
}

.plp-filter-v2 .plp-quick-filter.is-active .plp-switch{
    background: #27c83f;
}

.plp-filter-v2 .plp-quick-filter.is-active .plp-switch i{
    transform: translateX(20px);
}

.plp-filter-v2 .plp-quick-filter.is-active .plp-switch i::after{
    content: "";
    width: 5px;
    height: 9px;
    border-right: 1.6px solid #27b83a;
    border-bottom: 1.6px solid #27b83a;
    transform: translateY(-1px) rotate(45deg);
}

/* ------------------------------ final filter panel ---------------------- */
.plp-filter-v2 .nf-filter-panel{
    grid-column: 2;
    position: sticky;
    top: calc(var(--site-header-h, 72px) + 12px);
    width: var(--nf-panel-width) !important;
    min-width: 0;
    max-width: var(--nf-panel-width) !important;
    max-height: calc(100vh - var(--site-header-h, 72px) - 24px);
    display: grid;
    grid-template-rows: minmax(0, 1fr);
    overflow: hidden;
    direction: rtl;
    color: var(--nf-ink);
    border: 1px solid #e5e6e8;
    border-radius: 4px;
    background: var(--nf-surface);
    box-shadow: none;
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: none;
    z-index: 5;
}

.plp-filter-v2 .nf-filter-head,
.plp-filter-v2 .nf-filter-footer{
    display: none;
}

.plp-filter-v2 .nf-filter-scroll{
    min-height: 0;
    overflow-y: auto;
    overscroll-behavior: contain;
    direction: rtl;
    scrollbar-width: thin;
    scrollbar-color: #d7d9dd transparent;
}

.plp-filter-v2 .nf-filter-scroll::-webkit-scrollbar{
    width: 5px;
}

.plp-filter-v2 .nf-filter-scroll::-webkit-scrollbar-thumb{
    border-radius: 999px;
    background: #d7d9dd;
}

.plp-filter-v2 .nf-applied{
    padding: 18px 17px 16px;
    background: var(--nf-surface);
}

.plp-filter-v2 .nf-applied::after{
    content: "";
    display: block;
    height: 1px;
    margin: 16px 0 -16px;
    background: #e3e4e7;
}

.plp-filter-v2 .nf-applied__head{
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 16px;
}

.plp-filter-v2 .nf-applied__head strong{
    font-size: 14px;
    font-weight: 600;
}

.plp-filter-v2 .nf-clear-all{
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 0;
    border: 0;
    color: var(--nf-danger);
    background: transparent;
    cursor: pointer;
    font-size: 12px;
}

.plp-filter-v2 .nf-clear-all svg{
    fill: none;
    stroke: currentColor;
    stroke-width: 1.6;
    stroke-linecap: round;
}

.plp-filter-v2 .nf-active-chips{
    min-height: 31px;
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 7px;
}

.plp-filter-v2 .nf-active-chips:empty{
    min-height: 0;
}

.plp-filter-v2 .nf-active-chip{
    min-height: 31px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 9px;
    border: 1px solid #e1e2e5;
    border-radius: 999px;
    color: #52555c;
    background: #fff;
    cursor: pointer;
    font-size: 11px;
    line-height: 1.25;
}

.plp-filter-v2 .nf-active-chip i{
    color: #858990;
    font-style: normal;
    font-size: 15px;
    line-height: 1;
}

.plp-filter-v2 .nf-chip-swatch{
    width: 19px;
    height: 19px;
    flex: 0 0 19px;
    border-radius: 5px;
    background: linear-gradient(180deg, rgba(255,255,255,.28), rgba(255,255,255,.02) 45%, rgba(0,0,0,.18)), var(--nf-chip-swatch);
    box-shadow: inset 0 0 0 1px rgba(0,0,0,.05);
}

.plp-filter-v2 .nf-section{
    position: relative;
    background: var(--nf-surface);
}

.plp-filter-v2 .nf-section::after{
    content: "";
    position: absolute;
    inset-inline: 17px;
    bottom: 0;
    height: 1px;
    background: #e3e4e7;
}

.plp-filter-v2 .nf-section:last-child::after{
    display: none;
}

.plp-filter-v2 .nf-section__head{
    width: 100%;
    min-height: 58px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 0 18px;
    border: 0;
    border-radius: 0;
    color: var(--nf-ink);
    background: transparent;
    cursor: pointer;
    direction: rtl;
    text-align: right;
}

.plp-filter-v2 .nf-section__head > span{
    font-size: 15.5px;
    font-weight: 600;
}

.plp-filter-v2 .nf-section__head svg{
    width: 15px;
    height: 15px;
    flex: 0 0 15px;
    fill: none;
    stroke: #8c9199;
    stroke-width: 1.6;
    stroke-linecap: round;
    stroke-linejoin: round;
    transform: rotate(90deg);
    transition: transform .18s ease;
}

.plp-filter-v2 .nf-section.is-open .nf-section__head svg{
    transform: rotate(-90deg);
}

.plp-filter-v2 .nf-section:not(.is-open) .nf-section__body{
    display: none;
}

.plp-filter-v2 .nf-section__body{
    padding: 0 18px 22px;
}

.plp-filter-v2 .nf-check-list,
.plp-filter-v2 .nf-price-list{
    display: grid;
    gap: 11px;
}

/* First the title in RTL reading order, then its control immediately beside it. */
.plp-filter-v2 .nf-option{
    width: 100%;
    min-height: 22px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 9px;
    color: #6e727a;
    direction: rtl;
    cursor: pointer;
    text-align: right;
}

.plp-filter-v2 .nf-option > span{
    min-width: 0;
    font-size: 13px;
    line-height: 1.55;
}

.plp-filter-v2 .nf-option input{
    -webkit-appearance: none;
    appearance: none;
    position: relative;
    width: 21px !important;
    height: 21px !important;
    min-width: 21px;
    flex: 0 0 21px;
    margin: 0;
    border: 1px solid #ccd0d6;
    border-radius: 4px;
    background: #fff;
    direction: ltr;
    cursor: pointer;
}

.plp-filter-v2 .nf-option input[type="checkbox"]:checked{
    border-color: var(--nf-primary);
    background: var(--nf-primary);
}

.plp-filter-v2 .nf-option input[type="checkbox"]:checked::after{
    content: "";
    position: absolute;
    left: 7px;
    top: 3px;
    width: 5px;
    height: 10px;
    border-right: 1.8px solid #fff;
    border-bottom: 1.8px solid #fff;
    transform: rotate(45deg);
}

.plp-filter-v2 .nf-option input[type="checkbox"]:indeterminate{
    border-color: var(--nf-primary);
    background: var(--nf-primary);
}

.plp-filter-v2 .nf-option input[type="checkbox"]:indeterminate::after{
    content: "";
    position: absolute;
    left: 5px;
    right: 5px;
    top: 9px;
    height: 2px;
    background: #fff;
}

/* Price controls are always circular; their label order matches other rows. */
.plp-filter-v2 .nf-price-option input[type="radio"]{
    border-radius: 50%;
}

.plp-filter-v2 .nf-price-option input[type="radio"]:checked{
    border: 2px solid var(--nf-primary);
    background: var(--nf-primary);
    box-shadow: inset 0 0 0 4px #fff;
}

.plp-filter-v2 .nf-size-grid{
    display: grid;
    grid-template-columns: repeat(6, 34px);
    grid-auto-rows: 34px;
    justify-content: space-between;
    gap: 11px 0;
    direction: rtl;
}

.plp-filter-v2 .nf-size{
    width: 34px !important;
    height: 34px !important;
    min-width: 34px;
    min-height: 34px;
    padding: 0 !important;
    border: 1px solid #e0e2e6;
    border-radius: 5px;
    color: #5c6068;
    background: #fff;
    cursor: pointer;
    font-size: 10px;
    line-height: 32px;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
}

.plp-filter-v2 .nf-size.is-active{
    color: #fff;
    border-color: var(--nf-primary);
    background: var(--nf-primary);
    box-shadow: 0 0 0 2px #fff, 0 0 0 4px var(--nf-primary);
}

.plp-filter-v2 .nf-color-grid{
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: 12px 10px;
    direction: rtl;
}

.plp-filter-v2 .nf-color{
    position: relative;
    width: 100% !important;
    min-width: 0;
    aspect-ratio: 1 / 1;
    padding: 0 !important;
    border: 0;
    border-radius: 5px;
    background: linear-gradient(180deg, rgba(255,255,255,.30) 0%, rgba(255,255,255,.03) 48%, rgba(0,0,0,.22) 100%), var(--nf-swatch);
    box-shadow: inset 0 0 0 1px rgba(0,0,0,.05);
    cursor: pointer;
}

.plp-filter-v2 .nf-color.is-active{
    box-shadow: 0 0 0 2px #fff, 0 0 0 3px var(--nf-swatch), inset 0 0 0 1px rgba(0,0,0,.05);
}

.plp-filter-v2 .nf-color.is-active::after{
    content: "";
    position: absolute;
    left: 50%;
    top: 50%;
    width: 7px;
    height: 11px;
    border-right: 1.8px solid #fff;
    border-bottom: 1.8px solid #fff;
    transform: translate(-40%, -62%) rotate(45deg);
    filter: drop-shadow(0 1px 1px rgba(0,0,0,.25));
}

/* ------------------------------ mobile header controls ------------------ */
.plp-filter-v2 #filterToggle,
.plp-filter-v2 #sortToggle{
    display: none;
}

.plp-filter-v2 .plp-sort-layer{
    display: none;
}

.plp-filter-v2 .nf-icon-button{
    width: 28px;
    height: 28px;
    display: grid;
    place-items: center;
    flex: 0 0 28px;
    padding: 0;
    border: 0;
    border-radius: 5px;
    color: #44474d;
    background: transparent;
    cursor: pointer;
}

.plp-filter-v2 .nf-icon-button svg{
    fill: none;
    stroke: currentColor;
    stroke-width: 1.6;
    stroke-linecap: round;
}

/* ------------------------------ mobile view ----------------------------- */
@media (max-width: 900px) {
    .plp-filter-v2 #shell{
        display: block !important;
        min-height: 0;
        padding: 10px 0 24px;
        overflow: visible !important;
    }

    .plp-filter-v2 #products{
        width: 100% !important;
    }

    .plp-filter-v2 .plp-product-toolbar{
        display: none !important;
    }

    .plp-filter-v2 .plp-searchbar .row-top{
        min-height: 50px;
        padding: 6px 0 !important;
    }

    .plp-filter-v2 .plp-searchbar .left.tools{
        width: auto !important;
        max-width: none !important;
        display: flex !important;
        align-items: center !important;
        gap: 8px !important;
        margin: 0 !important;
        direction: ltr;
    }

    .plp-filter-v2 .plp-searchbar .right.mini-stats{
        width: auto !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    .plp-filter-v2 #gridToggleMobile,
.plp-filter-v2 #filterToggle,
.plp-filter-v2 #sortToggle{
        position: relative;
        width: 38px !important;
        min-width: 38px;
        height: 38px;
        display: grid;
        place-items: center;
        padding: 0;
        color: #42454b;
        background: #fff !important;
        
    }
    
     #filterToggle{
         margin-right: 10px;
     }
    
    #sortToggle{
        margin-left: 10px;
    }

    .plp-filter-v2 #gridToggleMobile .grid-split{
        width: 29px;
        height: 20px;
    }

    .plp-filter-v2 #filterToggle .btn-label,
.plp-filter-v2 #sortToggle .btn-label{
        position: absolute;
        width: 1px;
        height: 1px;
        overflow: hidden;
        clip: rect(0,0,0,0);
        white-space: nowrap;
    }

    .plp-filter-v2 #filterCount{
        position: absolute;
        top: -6px;
        right: -6px;
        min-width: 16px;
        height: 16px;
        display: grid;
        place-items: center;
        padding: 0 3px;
        border: 2px solid #fff;
        border-radius: 999px;
        color: #fff;
        background: var(--nf-danger);
        font-size: 8px;
        line-height: 12px;
    }

    .plp-filter-v2 .nf-filter-panel{
        position: fixed;
        inset: 0;
        width: 100% !important;
        min-width: 320px;
        max-width: 100% !important;
        height: 100vh;
        height: 100dvh;
        max-height: none;
        display: grid;
        grid-template-rows: auto minmax(0, 1fr) auto;
        border: 0;
        border-radius: 0;
        background: var(--nf-surface);
        box-shadow: none;
        transform: translateX(100%);
        opacity: 0;
        visibility: hidden;
        pointer-events: none;
        transition: transform .22s ease, opacity .18s ease, visibility 0s linear .22s;
        z-index: 100000;
    }

    .plp-filter-v2.filters-open .nf-filter-panel{
        transform: translateX(0);
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
        transition-delay: 0s;
    }

    .plp-filter-v2 .nf-filter-head{
        min-height: 58px;
        display: flex;
        align-items: center;
        justify-content: flex-start;
        gap: 7px;
        padding: max(11px, env(safe-area-inset-top)) 15px 9px;
        border-bottom: 1px solid #ececef;
        background: var(--nf-surface);
    }

    .plp-filter-v2 .nf-filter-head__title{
        font-size: 14px;
        font-weight: 600;
    }

    .plp-filter-v2 .nf-filter-scroll{
        background: var(--nf-surface);
    }

    .plp-filter-v2 .nf-applied{
        padding-top: 12px;
    }

    .plp-filter-v2 .nf-applied__head{
        display: none;
    }

    .plp-filter-v2 .nf-section__head{
        min-height: 57px;
    }

    .plp-filter-v2 .nf-section__body{
        padding-bottom: 21px;
    }

    .plp-filter-v2 .nf-filter-footer{
        display: flex;
        gap: 9px;
        padding: 13px 15px max(13px, env(safe-area-inset-bottom));
        border-top: 1px solid #e6e7ea;
        background: rgba(255,255,255,.98);
    }

    .plp-filter-v2 .nf-footer-button{
        flex: 1 1 0;
        min-width: 0;
        height: 42px;
        border-radius: 5px;
        cursor: pointer;
        font-size: 12px;
    }

    .plp-filter-v2 .nf-footer-button--reset{
        border: 1px solid #cfd1d5;
        color: #555960;
        background: #fff;
    }

    .plp-filter-v2 .nf-footer-button--apply{
        border: 1px solid var(--nf-danger);
        color: #fff;
        background: var(--nf-danger);
    }

    .plp-filter-v2 .plp-sort-layer{
        position: fixed;
        inset: 0;
        z-index: 100010;
        display: grid;
        align-items: end;
    }

    .plp-filter-v2 .plp-sort-backdrop{
        position: absolute;
        inset: 0;
        width: 100%;
        height: 100%;
        padding: 0;
        border: 0;
        border-radius: 0;
        background: rgba(0,0,0,.52);
        cursor: pointer;
    }

    .plp-filter-v2 .plp-sort-sheet{
        position: relative;
        z-index: 1;
        width: 100%;
        max-height: calc(100dvh - 112px);
        overflow: hidden;
        border-radius: 15px 15px 0 0;
        background: #fff;
        direction: rtl;
        transform: translateY(16px);
        opacity: .75;
        transition: transform .2s ease, opacity .2s ease;
    }

    .plp-filter-v2 .plp-sort-layer.is-open .plp-sort-sheet{
        transform: translateY(0);
        opacity: 1;
    }

    .plp-filter-v2 .plp-sort-sheet-head{
        min-height: 58px;
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 0 15px;
        border-bottom: 1px solid #ececef;
    }

    .plp-filter-v2 .plp-sort-sheet-head h2{
        margin: 0;
        font-size: 14px;
        font-weight: 500;
    }

    .plp-filter-v2 .plp-sort-sheet-options{
        padding: 8px 15px 20px;
    }

    .plp-filter-v2 .plp-sort-sheet-option{
        width: 100%;
        min-height: 40px;
        display: block;
        padding: 0 10px;
        border: 0;
        border-radius: 0;
        color: #53565e;
        background: #fff;
        cursor: pointer;
        text-align: right;
        font-size: 11px;
    }

    .plp-filter-v2 .plp-sort-sheet-option.is-active{
        color: #292b30;
        background: #f6f6f7;
    }

    .plp-filter-v2 .plp-sort-sheet-option:disabled{
        color: #b7b9be;
        cursor: default;
    }

    .plp-filter-v2 #backdrop{
        display: none !important;
    }

    .plp-filter-v2 #plpPager{
        position: static !important;
        bottom: auto !important;
        border-radius: 10px !important;
    }
}

@media (max-width: 380px) {
    .plp-filter-v2 .nf-section__body{
        padding-inline: 14px;
    }

    .plp-filter-v2 .nf-size-grid{
        grid-template-columns: repeat(6, 32px);
        grid-auto-rows: 32px;
    }

    .plp-filter-v2 .nf-size{
        width: 32px !important;
        height: 32px !important;
        min-width: 32px;
        min-height: 32px;
        line-height: 30px;
    }

    .plp-filter-v2 .nf-color-grid{
        gap-inline: 8px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .plp-filter-v2 .nf-filter-panel,
.plp-filter-v2 .plp-sort-sheet,
.plp-filter-v2 .plp-switch,
.plp-filter-v2 .plp-switch i,
.plp-filter-v2 .nf-section__head svg{
        transition: none !important;
    }
}


/* ========================================================================== 
   PLP FINAL RUNTIME POLISH — 2026-08-22
   Small rules previously embedded in the PHP view. Keeping them here makes
   the final PLP styling single-source without changing the approved view.
   ========================================================================== */
.plp-filter-v2{ position: relative; }

.plp-filter-v2 [data-plp-grid-toggle] .arrow{
    transform-box: fill-box;
    transform-origin: 48px 16px;
    transition: transform .28s ease;
}
.plp-filter-v2 [data-plp-grid-toggle][data-view="2"] .arrow{ transform: rotate(0deg); }
.plp-filter-v2 [data-plp-grid-toggle][data-view="4"] .arrow{
    transform: rotate(180deg);
    transform-origin: 6px;
}

.plp-filter-v2 #filtersApply .ft-count{
    font-size: 12px;
    font-weight: 600;
}

@media (prefers-reduced-motion: reduce) {
    .plp-filter-v2 #gridToggle .arrow{ transition: none; }
}


/* ========================================================================== 
   PLP PRODUCTION PATCH — 2026-08-23
   Sticky filter hand-off, hierarchical categories, integrated grid control,
   RTL pager and hybrid infinite-scroll/pagination presentation.
   ========================================================================== */

/* Desktop: the approved top product toolbar is the single toolbar. */
@media (min-width: 901px) {
    /* `overflow-x:hidden` on a sticky ancestor turns it into a scroll container
       in some browsers. `clip` prevents horizontal bleed without breaking sticky. */
    .plp-filter-v2{
        overflow-x: clip !important;
        overflow-y: visible !important;
    }

    .plp-filter-v2 #searchHeader{
        display: none !important;
    }

    .plp-filter-v2 .plp-product-toolbar{
        align-items: center;
    }

    .plp-filter-v2 .plp-grid-control{
        flex: 0 0 auto;
        display: flex;
        align-items: center;
        align-self: stretch;
        padding-inline: 8px;
        border-inline-start: 1px solid #ececef;
    }

    .plp-filter-v2 .plp-grid-toggle-desktop{
        width: 76px;
        min-width: 76px;
        height: 36px;
        padding: 0;
        display: grid;
        place-items: center;
        border: 0;
        border-radius: 6px;
        color: #555960;
        background: transparent;
        cursor: pointer;
    }

    .plp-filter-v2 .plp-grid-toggle-desktop:hover{
        background: #f1f2f4;
    }

    /* Eight columns must fit the actual products column next to the filter. */
    .plp-filter-v2.grid-8 .cards{
        grid-template-columns: repeat(8, minmax(0, 1fr)) !important;
    }

    /* Sticky panel with its own scroll. When the inner scroll reaches either
       boundary, browser scroll chaining continues on the document naturally. */
    .plp-filter-v2 .nf-filter-panel{
        align-self: start;
        top: calc(var(--site-header-h, 60px) + 12px);
        max-height: calc(100vh - var(--site-header-h, 60px) - 24px);
        max-height: calc(100dvh - var(--site-header-h, 60px) - 24px);
    }

    .plp-filter-v2 .nf-filter-scroll{
        overscroll-behavior-y: auto !important;
        scrollbar-gutter: stable;
        -webkit-overflow-scrolling: touch;
    }
}

/* Mobile keeps the compact toolbar and its original grid action. */
@media (max-width: 900px) {
    .plp-filter-v2 #gridToggleMobile .grid-split{
        width: 29px;
        height: 20px;
    }
}

/* Hybrid infinite scroll UI. It never changes card/image lazy-load rules. */
.plp-filter-v2 .plp-infinite-sentinel{
    width: 100%;
    height: 1px;
    pointer-events: none;
}

.plp-filter-v2 .plp-infinite-status{
    min-height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    margin-top: 12px;
    color: #777b82;
    font-size: 11px;
}

.plp-filter-v2 .plp-infinite-spinner{
    width: 17px;
    height: 17px;
    flex: 0 0 17px;
    border: 2px solid #e1e3e7;
    border-top-color: #5f636a;
    border-radius: 50%;
    animation: plpInfiniteSpin .7s linear infinite;
}

@keyframes plpInfiniteSpin {
    to { transform: rotate(360deg); }
}

.plp-filter-v2 .plp-pager-host.is-auto-hidden{
    display: none !important;
}

/* Pagination order is explicitly RTL: page 1 is the right-most number,
   previous sits on the right and next sits on the left. */
.plp-filter-v2 #plpPager{
    direction: rtl !important;
}

.plp-filter-v2 #plpPager .controls{
    direction: rtl !important;
    flex-direction: row !important;
}

.plp-filter-v2 #plpPager .nums,
html[dir="rtl"] .plp-filter-v2 #plpPager .nums{
    direction: rtl !important;
    flex-direction: row !important;
}

@media (prefers-reduced-motion: reduce) {
    .plp-filter-v2 .plp-infinite-spinner{ animation: none; }
}

/* ========================================================================== 
   PLP PRODUCTION PATCH 3 — 2026-08-23
   Remove legacy-card conflicts, true desktop sticky filter, mobile grid parity,
   square option tokens and softer card/image/grid transitions.
   ========================================================================== */

/* The PLP root must grow with appended pages. A fixed 100% height truncates the
   sticky containing block and makes the sidebar disappear after the first screen. */
#plp_container.plp-filter-v2{
    height:auto !important;
    min-height:100vh;
}

/* Current card is information-only: there is no hover purchase layer on PLP. */
#plp_container.plp-filter-v2 .plp-card .hover-cta,
#plp_container.plp-filter-v2 .plp-card .add-to-basket,
#plp_container.plp-filter-v2 .plp-card .btn-add-mobile,
#plp_container.plp-filter-v2 .plp-card .mb-add{
    display:none !important;
    pointer-events:none !important;
}

/* Stable 1:1 visual tokens in every density. */
#plp_container.plp-filter-v2 .plp-card.plp-card--v2 .sz-chip,
#plp_container.plp-filter-v2 .plp-card.plp-card--v2 .sz-more,
#plp_container.plp-filter-v2 .plp-card.plp-card--v2 .color-dot,
#plp_container.plp-filter-v2 .plp-card.plp-card--v2 .color-plus{
    box-sizing:border-box !important;
    width:var(--plp-option-token,22px) !important;
    min-width:var(--plp-option-token,22px) !important;
    max-width:var(--plp-option-token,22px) !important;
    height:var(--plp-option-token,22px) !important;
    min-height:var(--plp-option-token,22px) !important;
    max-height:var(--plp-option-token,22px) !important;
    padding:0 !important;
    flex:0 0 var(--plp-option-token,22px) !important;
    aspect-ratio:1 / 1 !important;
}

/* Separate direct Gender and Clothing Type facets. */
.plp-filter-v2 .nf-gender-list,
.plp-filter-v2 .nf-clothing-list{
    display:grid;
    gap:2px;
}
.plp-filter-v2 .nf-option--gender{
    min-height:39px;
    font-weight:600;
}
.plp-filter-v2 .nf-option--clothing{
    min-height:36px;
}

@media (min-width:901px){
    /* Keep the whole sidebar inside the viewport while its content scrolls. */
    #plp_container.plp-filter-v2 .nf-filter-panel{
        position:sticky !important;
        position:-webkit-sticky !important;
        top:12px !important;
        align-self:start !important;
        max-height:calc(100vh - 24px) !important;
        max-height:calc(100dvh - 24px) !important;
        overflow:hidden !important;
    }
    #plp_container.plp-filter-v2 .nf-filter-scroll{
        min-height:0 !important;
        max-height:calc(100vh - 26px) !important;
        max-height:calc(100dvh - 26px) !important;
        overflow-y:auto !important;
        overflow-x:hidden !important;
        overscroll-behavior-y:auto !important;
        scrollbar-gutter:stable;
    }
}

/* Mobile grid modes are real 2/4-column states. Legacy plp-ux-fix used to force
   all three classes to two columns, which made the mobile button appear broken. */
@media (max-width:900px){
    #plp_container.plp-filter-v2.grid-2 .cards{
        grid-template-columns:repeat(2,minmax(0,1fr)) !important;
    }
    #plp_container.plp-filter-v2.grid-4 .cards{
        grid-template-columns:repeat(4,minmax(0,1fr)) !important;
        gap:6px !important;
    }
    #plp_container.plp-filter-v2.grid-4 .plp-card.plp-card--v2 .meta{
        padding-inline:4px !important;
    }
}

/* Softer card arrival for pages appended by the hybrid infinite loader. */
#plp_container.plp-filter-v2 .cards > .plp-card.plp-card--v2:not(.skel){
    animation:plpCardEnter .34s cubic-bezier(.22,.61,.36,1) both;
}
@keyframes plpCardEnter{
    from{opacity:0; transform:translateY(8px)}
    to{opacity:1; transform:translateY(0)}
}

/* Preserve the skeleton until decode, then reveal the bitmap more gradually. */
#plp_container.plp-filter-v2 .plp-card.plp-card--v2 .slide-link .product-image{
    opacity:0;
    transform:scale(1.012);
    transition:opacity .38s ease, transform .52s cubic-bezier(.22,.61,.36,1) !important;
}
#plp_container.plp-filter-v2 .plp-card.plp-card--v2 .slide-link.is-image-ready .product-image{
    opacity:1;
    transform:scale(1);
}

@media (prefers-reduced-motion:reduce){
    #plp_container.plp-filter-v2 .cards > .plp-card.plp-card--v2:not(.skel){animation:none !important}
    #plp_container.plp-filter-v2 .plp-card.plp-card--v2 .slide-link .product-image{transition:none !important;transform:none !important}
}

/* ========================================================================== 
   PLP PRODUCTION PATCH 4 — 2026-08-23
   Direct Gender/Clothing facets + robust desktop filter pinning.
   ========================================================================== */

/* Zero-size grid anchor stays in the natural sidebar cell even while the actual
   panel is switched to fixed positioning by the runtime fallback. */
#plp_container.plp-filter-v2 .nf-filter-anchor{
    grid-column:2;
    grid-row:1;
    align-self:start;
    width:1px;
    height:1px;
    margin:0;
    padding:0;
    visibility:hidden;
    pointer-events:none;
}

@media (min-width:901px){
    #plp_container.plp-filter-v2 #products,
#plp_container.plp-filter-v2 .nf-filter-panel,
#plp_container.plp-filter-v2 .nf-filter-anchor{
        grid-row:1;
    }

    /* Keep every PLP-owned ancestor non-scrolling so CSS sticky works whenever
       the outer site template allows it. JS below is only the production fallback. */
    #plp_container.plp-filter-v2,
#plp_container.plp-filter-v2 #shell,
#plp_container.plp-filter-v2 .wrap{
        overflow-y:visible !important;
    }
    #plp_container.plp-filter-v2 #shell{
        overflow-x:visible !important;
        contain:none !important;
    }

    #plp_container.plp-filter-v2 .nf-filter-panel{
        top:12px !important;
        max-height:calc(100vh - 24px) !important;
        max-height:calc(100dvh - 24px) !important;
    }

    /* If an outer legacy wrapper breaks sticky, the runtime pins the same panel
       to the viewport. Its grid column remains reserved by #nfFilterAnchor. */
    #plp_container.plp-filter-v2 .nf-filter-panel.is-v4-fixed{
        position:fixed !important;
        top:12px !important;
        right:auto !important;
        bottom:auto !important;
        margin:0 !important;
        z-index:650 !important;
    }

    /* At the physical end of the PLP shell, settle the panel inside the shell
       instead of allowing it to overlap content that follows the product list. */
    #plp_container.plp-filter-v2 .nf-filter-panel.is-v4-bottomed{
        position:absolute !important;
        top:auto !important;
        right:0 !important;
        bottom:40px !important;
        left:auto !important;
        margin:0 !important;
        z-index:5 !important;
    }

    #plp_container.plp-filter-v2 .nf-filter-scroll{
        min-height:0 !important;
        max-height:calc(100vh - 26px) !important;
        max-height:calc(100dvh - 26px) !important;
        overflow-y:auto !important;
        overflow-x:hidden !important;
        overscroll-behavior-y:auto !important;
        -webkit-overflow-scrolling:touch;
        scrollbar-gutter:stable;
    }
}


/* ========================================================================== 
   PLP PRODUCTION PATCH 5 — 2026-08-24
   Header-safe desktop sidebar pinning, gender fallback visibility,
   accurate color swatches, mobile 4-col cleanup, and global max-width polish.
   ========================================================================== */

/* Respect a comfortable site-wide gutter so content never sticks to the edges. */
#plp_container .wrap{
    max-width:min(100%, 1440px) !important;
    margin-inline:auto !important;
    padding-inline:clamp(12px, 1.9vw, 28px) !important;
}
#plp_container .plp-searchbar .wrap,
#plp_container .plp-toolbar .wrap{
    padding-inline:clamp(12px, 1.9vw, 28px) !important;
}

@media (min-width:901px){
    /* The desktop filter panel should pin below the live header/search-toolbar,
       never overlap it, and keep a calm hand-off between panel scroll and page scroll. */
    #plp_container.plp-filter-v2 .nf-filter-panel{
        top:var(--nf-pin-top, 12px) !important;
        max-height:calc(100dvh - var(--nf-pin-top, 12px) - 12px) !important;
        overscroll-behavior:contain;
    }
    #plp_container.plp-filter-v2 .nf-filter-panel.is-v4-fixed{
        top:var(--nf-pin-top, 12px) !important;
    }
    #plp_container.plp-filter-v2 .nf-filter-scroll{
        max-height:calc(100dvh - var(--nf-pin-top, 12px) - 14px) !important;
        overscroll-behavior-y:contain;
    }
}

/* Direct Gender filter rows */
.plp-filter-v2 .nf-gender-list{
    gap:8px;
}
.plp-filter-v2 .nf-option--gender{
    min-height:44px;
}
.plp-filter-v2 .nf-option--gender > span{
    font-weight:600;
}

/* Color swatches: use the exact backend gradient/color token without adding another overlay. */
.plp-filter-v2 .nf-color{
    background:var(--nf-swatch, #ccc) !important;
    box-shadow:inset 0 0 0 1px rgba(0,0,0,.08), 0 1px 2px rgba(0,0,0,.04);
}
.plp-filter-v2 .nf-color.is-active{
    box-shadow:0 0 0 2px #fff, 0 0 0 3px #1e2433, inset 0 0 0 1px rgba(0,0,0,.08) !important;
}

/* Product-card color dots can render backend gradients too. */
#plp_container .plp-card.plp-card--v2 .color-dot,
#plp_container .mb-row.colors .color-dot{
    background:var(--dot, #ccc) !important;
}

@media (max-width:900px){
    /* In mobile 4-column density, remove image overlays that clutter the tiny cards. */
    #plp_container.plp-filter-v2.grid-4 .plp-card.plp-card--v2 .product-badges,
#plp_container.plp-filter-v2.grid-4 .plp-card.plp-card--v2 .bm-btn,
#plp_container.plp-filter-v2.grid-4 .plp-card.plp-card--v2 .pc-topbar,
#plp_container.plp-filter-v2.grid-4 .plp-card.plp-card--v2 .price-off,
#plp_container.plp-filter-v2.grid-4 .plp-card.plp-card--v2 .lowq-badge{
        display:none !important;
    }

    #plp_container.plp-filter-v2.grid-4 .cards{
        gap:8px !important;
    }
}

/* ========================================================================== 
   PLP PRODUCTION PATCH 5.3 — focused sidebar motion polish
   ========================================================================== */
@media (min-width:901px){
    #plp_container.plp-filter-v2 .nf-filter-panel{
        transition:
            top .22s cubic-bezier(.22,.61,.36,1),
            box-shadow .22s ease,
            opacity .18s ease !important;
        will-change:top;
        backface-visibility:hidden;
        -webkit-font-smoothing:antialiased;
    }
    #plp_container.plp-filter-v2 .nf-filter-panel.is-v4-fixed{
        box-shadow:0 10px 28px rgba(15,23,42,.055);
    }
    #plp_container.plp-filter-v2 .nf-filter-panel:not(.is-v4-fixed){
        box-shadow:0 3px 12px rgba(15,23,42,.025);
    }
}
@media (prefers-reduced-motion:reduce){
    #plp_container.plp-filter-v2 .nf-filter-panel{transition:none !important}
}


/* ========================================================================== 
   PLP PRODUCTION PATCH 5.4 — responsive card option tokens only
   ========================================================================== */
#plp_container.plp-filter-v2 .plp-card.plp-card--v2{
    --plp-option-token:22px;
    --plp-option-gap:4px;
    --plp-option-font:8px;
}
#plp_container.plp-filter-v2 .plp-card.plp-card--v2 .sizes-row,
#plp_container.plp-filter-v2 .plp-card.plp-card--v2 .color-badges{
    gap:var(--plp-option-gap,4px) !important;
    min-width:0;
}
#plp_container.plp-filter-v2 .plp-card.plp-card--v2 .sz-chip,
#plp_container.plp-filter-v2 .plp-card.plp-card--v2 .sz-more,
#plp_container.plp-filter-v2 .plp-card.plp-card--v2 .color-dot,
#plp_container.plp-filter-v2 .plp-card.plp-card--v2 .color-plus{
    width:var(--plp-option-token,22px) !important;
    min-width:var(--plp-option-token,22px) !important;
    max-width:var(--plp-option-token,22px) !important;
    height:var(--plp-option-token,22px) !important;
    min-height:var(--plp-option-token,22px) !important;
    max-height:var(--plp-option-token,22px) !important;
    flex:0 0 var(--plp-option-token,22px) !important;
    aspect-ratio:1 / 1 !important;
    padding:0 !important;
}
#plp_container.plp-filter-v2 .plp-card.plp-card--v2 .sz-chip,
#plp_container.plp-filter-v2 .plp-card.plp-card--v2 .sz-more,
#plp_container.plp-filter-v2 .plp-card.plp-card--v2 .color-plus{
    font-size:var(--plp-option-font,8px) !important;
}
#plp_container.plp-filter-v2 .plp-card.plp-card--v2 .sz-more[hidden],
#plp_container.plp-filter-v2 .plp-card.plp-card--v2 .color-plus[hidden],
#plp_container.plp-filter-v2 .plp-card.plp-card--v2 .sz-chip[hidden],
#plp_container.plp-filter-v2 .plp-card.plp-card--v2 .color-dot[hidden]{
    display:none !important;
}

/* ========================================================================== 
   PLP PRODUCTION PATCH 5.5 — deterministic grid/card density + tiny 4-col tokens
   ========================================================================== */
@media (max-width:900px){
    /* JS writes the exact value from real card width; these are safe fallbacks for
       first paint before ResizeObserver runs. */
    #plp_container.plp-filter-v2.grid-4 .plp-card.plp-card--v2{
        --plp-option-token:10px;
        --plp-option-gap:2px;
        --plp-option-font:5.5px;
    }

    #plp_container.plp-filter-v2.grid-4 .plp-card.plp-card--v2 .sz-chip,
#plp_container.plp-filter-v2.grid-4 .plp-card.plp-card--v2 .sz-more,
#plp_container.plp-filter-v2.grid-4 .plp-card.plp-card--v2 .color-dot,
#plp_container.plp-filter-v2.grid-4 .plp-card.plp-card--v2 .color-plus{
        border-radius:2px !important;
    }

    #plp_container.plp-filter-v2.grid-4 .plp-card.plp-card--v2 .option-row{
        gap:2px !important;
    }

    #plp_container.plp-filter-v2.grid-4 .plp-card.plp-card--v2 .option-label{
        font-size:7px !important;
    }
}


/* =========================================================
   PLP Breadcrumb
   ========================================================= */
#plp_container .plp-breadcrumb{
    width: 100%;
    margin: 14px 0 10px;
    direction: rtl;
    font-size: 11px;
    line-height: 1.8;
    color: #8a8d93;
}

#plp_container .plp-breadcrumb__list{
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 7px;
    margin: 0;
    padding: 0;
    list-style: none;
}

#plp_container .plp-breadcrumb__item{
    display: inline-flex;
    align-items: center;
    gap: 7px;
    min-width: 0;
}

#plp_container .plp-breadcrumb__item:not(:last-child)::after{
    content: "/";
    color: #c4c6ca;
    font-size: 10px;
}

#plp_container .plp-breadcrumb a{
    color: #696c72;
    text-decoration: none;
    transition: color .15s ease;
}

#plp_container .plp-breadcrumb a:hover{
    color: #111;
}

#plp_container .plp-breadcrumb [aria-current="page"]{
    color: #202226;
    font-weight: 500;
}

@media (max-width: 900px) {
    #plp_container .plp-breadcrumb{
        margin: 10px 0 8px;
        padding-inline: 2px;
        font-size: 10px;
        overflow: hidden;
    }

    #plp_container .plp-breadcrumb__list{
        flex-wrap: nowrap;
        overflow-x: auto;
        scrollbar-width: none;
        white-space: nowrap;
    }

    #plp_container .plp-breadcrumb__list::-webkit-scrollbar{
        display: none;
    }
}


/* ==========================================================================
   JPA PLP — PRODUCT SWIPE DISCOVERY HINT
   --------------------------------------------------------------------------
   - Visual-only onboarding hint
   - Does NOT affect card layout
   - Does NOT block swipe / drag / click
   - Responsive for desktop / mobile 2-col / mobile 4-col
   ========================================================================== */


/* --------------------------------------------------------------------------
   Media positioning context
   -------------------------------------------------------------------------- */

#plp_container
.plp-card.plp-card--v2
.media{
    position: relative;
}


/* --------------------------------------------------------------------------
   Main hint capsule
   -------------------------------------------------------------------------- */

#plp_container
.plp-card.plp-card--v2
.plp-swipe-hint{
    position: absolute;

    left: 50%;
    bottom: 34px;

    z-index: 5;

    width: 46px;
    height: 26px;

    display: flex;
    align-items: center;
    justify-content: center;

    padding: 0;

    transform:
        translate3d(-50%, 0, 0);

    border:
        1px solid rgba(20, 20, 20, .07);

    border-radius: 999px;

    background:
        rgba(255, 255, 255, .82);

    -webkit-backdrop-filter:
        blur(6px);

    backdrop-filter:
        blur(6px);

    box-shadow:
        0 2px 8px rgba(0, 0, 0, .07);

    /*
     * بسیار مهم:
     * Hint نباید هیچ Interaction از Swiper را بگیرد.
     */
    pointer-events: none;

    user-select: none;
    -webkit-user-select: none;

    touch-action: none;

    opacity: 1;

    will-change:
        opacity,
        transform;

    transition:
        opacity .26s ease,
        transform .26s cubic-bezier(.22, 1, .36, 1);
}


/* --------------------------------------------------------------------------
   Gesture icon wrapper
   -------------------------------------------------------------------------- */

#plp_container
.plp-card.plp-card--v2
.plp-swipe-hint__gesture{
    width: 34px;
    height: 18px;

    display: flex;
    align-items: center;
    justify-content: center;

    transform:
        translate3d(0, 0, 0);

    transform-origin: center;

    will-change:
        transform,
        opacity;

    animation:
        plpSwipeHintGesture
        1.6s
        cubic-bezier(.45, 0, .55, 1)
        infinite;
}


/* --------------------------------------------------------------------------
   SVG
   -------------------------------------------------------------------------- */

#plp_container
.plp-card.plp-card--v2
.plp-swipe-hint__gesture svg{
    display: block;

    width: 100%;
    height: 100%;

    overflow: visible;

    pointer-events: none;
}


/* --------------------------------------------------------------------------
   Left / Right arrows
   -------------------------------------------------------------------------- */

#plp_container
.plp-card.plp-card--v2
.plp-swipe-hint__arrow{
    fill: none;

    stroke: #35363a;

    stroke-width: 1.55;

    stroke-linecap: round;
    stroke-linejoin: round;

    opacity: .82;

    vector-effect:
        non-scaling-stroke;
}


/* --------------------------------------------------------------------------
   Center touch point
   -------------------------------------------------------------------------- */

#plp_container
.plp-card.plp-card--v2
.plp-swipe-hint__touch{
    fill: #35363a;

    opacity: .92;
}


/* --------------------------------------------------------------------------
   Touch ring
   -------------------------------------------------------------------------- */

#plp_container
.plp-card.plp-card--v2
.plp-swipe-hint__touch-ring{
    fill: none;

    stroke: #35363a;

    stroke-width: 1;

    opacity: .22;

    transform-box: fill-box;
    transform-origin: center;

    animation:
        plpSwipeHintPulse
        1.6s
        ease-out
        infinite;

    vector-effect:
        non-scaling-stroke;
}


/* --------------------------------------------------------------------------
   Leaving state
   Added by JS after user's first real product drag
   -------------------------------------------------------------------------- */

#plp_container
.plp-card.plp-card--v2
.plp-swipe-hint.is-leaving{
    opacity: 0;

    transform:
        translate3d(-50%, 4px, 0)
        scale(.92);
}


/* ==========================================================================
   Animations
   ========================================================================== */


/*
 * کل gesture کمی به چپ و راست حرکت می‌کند.
 * حرکت عمداً کوتاه است تا حس Swipe بدهد ولی حواس‌پرت‌کن نباشد.
 */
@keyframes plpSwipeHintGesture{

    0%{
        transform:
            translate3d(-3px, 0, 0);

        opacity: .62;
    }

    25%{
        opacity: .82;
    }

    50%{
        transform:
            translate3d(3px, 0, 0);

        opacity: 1;
    }

    75%{
        opacity: .82;
    }

    100%{
        transform:
            translate3d(-3px, 0, 0);

        opacity: .62;
    }
}


/*
 * Pulse بسیار ظریف اطراف نقطه لمس
 */
@keyframes plpSwipeHintPulse{

    0%{
        transform:
            scale(.72);

        opacity: .08;
    }

    45%{
        transform:
            scale(1.18);

        opacity: .28;
    }

    75%{
        transform:
            scale(1.05);

        opacity: .18;
    }

    100%{
        transform:
            scale(.72);

        opacity: .08;
    }
}


/* ==========================================================================
   Tablet / Mobile
   ========================================================================== */

@media (max-width: 900px){

    #plp_container
    .plp-card.plp-card--v2
    .plp-swipe-hint{
        width: 40px;
        height: 23px;

        bottom: 28px;

        border-radius: 999px;

        box-shadow:
            0 2px 6px rgba(0, 0, 0, .065);
    }


    #plp_container
    .plp-card.plp-card--v2
    .plp-swipe-hint__gesture{
        width: 29px;
        height: 15px;
    }
}


/* ==========================================================================
   Mobile — 4 column compact grid
   ========================================================================== */

@media (max-width: 900px){

    #plp_container.grid-4
    .plp-card.plp-card--v2
    .plp-swipe-hint{
        width: 28px;
        height: 17px;

        bottom: 10px;

        border-width: 0;

        background:
            rgba(255, 255, 255, .82);

        -webkit-backdrop-filter:
            blur(4px);

        backdrop-filter:
            blur(4px);

        box-shadow:
            0 1px 4px rgba(0, 0, 0, .06);
    }


    #plp_container.grid-4
    .plp-card.plp-card--v2
    .plp-swipe-hint__gesture{
        width: 20px;
        height: 11px;
    }


    #plp_container.grid-4
    .plp-card.plp-card--v2
    .plp-swipe-hint__arrow{
        stroke-width: 1.35;
    }


    #plp_container.grid-4
    .plp-card.plp-card--v2
    .plp-swipe-hint__touch-ring{
        stroke-width: .85;
    }
}


/* ==========================================================================
   Very small mobile screens
   ========================================================================== */

@media (max-width: 380px){

    #plp_container.grid-4
    .plp-card.plp-card--v2
    .plp-swipe-hint{
        width: 26px;
        height: 16px;

        bottom: 8px;
    }


    #plp_container.grid-4
    .plp-card.plp-card--v2
    .plp-swipe-hint__gesture{
        width: 18px;
        height: 10px;
    }
}


/* ==========================================================================
   Browser fallback — no backdrop-filter
   ========================================================================== */

@supports not (
    (backdrop-filter: blur(1px)) or
    (-webkit-backdrop-filter: blur(1px))
){

    #plp_container
    .plp-card.plp-card--v2
    .plp-swipe-hint{
        background:
            rgba(255, 255, 255, .94);
    }
}


/* ==========================================================================
   Accessibility — Reduced Motion
   ========================================================================== */

@media (prefers-reduced-motion: reduce){

    #plp_container
    .plp-card.plp-card--v2
    .plp-swipe-hint__gesture,

    #plp_container
    .plp-card.plp-card--v2
    .plp-swipe-hint__touch-ring{
        animation: none !important;
    }


    #plp_container
    .plp-card.plp-card--v2
    .plp-swipe-hint__gesture{
        opacity: .88;
        transform: none;
    }


    #plp_container
    .plp-card.plp-card--v2
    .plp-swipe-hint__touch-ring{
        opacity: .20;
        transform: none;
    }
}





/* ==========================================================================
   JPA PLP — CLOTHING TYPE SUB ACCORDIONS
   ========================================================================== */


/* Main list */

#plp_container.plp-filter-v2
.nf-clothing-list{
    display: flex;
    flex-direction: column;
    gap: 0;
}


/* --------------------------------------------------------------------------
   Group
   -------------------------------------------------------------------------- */

#plp_container.plp-filter-v2
.nf-clothing-group{
    position: relative;

    width: 100%;

    border-bottom:
        1px solid #e9eaed;
}


#plp_container.plp-filter-v2
.nf-clothing-group:last-child{
    border-bottom: 0;
}


/* --------------------------------------------------------------------------
   Header
   -------------------------------------------------------------------------- */

#plp_container.plp-filter-v2
.nf-clothing-group__head{
    width: 100%;
    min-height: 44px;

    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 12px;

    padding: 0 2px;

    border: 0;
    border-radius: 0;

    background: transparent;

    color: #42454c;

    direction: rtl;

    cursor: pointer;

    text-align: right;

    transition:
        color .18s ease,
        background-color .18s ease;
}


#plp_container.plp-filter-v2
.nf-clothing-group__head:hover{
    color: #17181c;
}


/* title */

#plp_container.plp-filter-v2
.nf-clothing-group__title{
    min-width: 0;

    font-size: 13px;
    font-weight: 600;

    line-height: 1.5;
}


/* right-side meta */

#plp_container.plp-filter-v2
.nf-clothing-group__meta{
    display: inline-flex;
    align-items: center;

    gap: 8px;

    flex: 0 0 auto;
}


/* selected count */

#plp_container.plp-filter-v2
.nf-clothing-group__selected{
    min-width: 19px;
    height: 19px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    padding: 0 5px;

    border-radius: 999px;

    background: #f0f1f3;

    color: #555960;

    font-size: 10px;
    font-weight: 600;

    line-height: 19px;
}


#plp_container.plp-filter-v2
.nf-clothing-group__selected[hidden]{
    display: none !important;
}


/* chevron */

#plp_container.plp-filter-v2
.nf-clothing-group__head svg{
    flex: 0 0 14px;

    fill: none;

    stroke: #8b8f96;

    stroke-width: 1.6;

    stroke-linecap: round;
    stroke-linejoin: round;

    transform:
        rotate(90deg);

    transition:
        transform .22s
        cubic-bezier(.22, 1, .36, 1);
}


#plp_container.plp-filter-v2
.nf-clothing-group.is-open
.nf-clothing-group__head svg{
    transform:
        rotate(-90deg);
}


/* ==========================================================================
   Smooth collapse
   ========================================================================== */

#plp_container.plp-filter-v2
.nf-clothing-group__collapse{
    display: grid;

    grid-template-rows: 0fr;

    opacity: 0;

    transition:
        grid-template-rows .25s
        cubic-bezier(.22, 1, .36, 1),
        opacity .18s ease;
}


#plp_container.plp-filter-v2
.nf-clothing-group.is-open
.nf-clothing-group__collapse{
    grid-template-rows: 1fr;

    opacity: 1;
}


/* Actual items container */

#plp_container.plp-filter-v2
.nf-clothing-group__body{
    min-height: 0;

    overflow: hidden;

    display: grid;

    gap: 10px;

    padding-inline:
        8px 2px;

    padding-block:
        0;

    transition:
        padding .22s ease;
}


#plp_container.plp-filter-v2
.nf-clothing-group.is-open
.nf-clothing-group__body{
    padding-top: 4px;
    padding-bottom: 14px;
}


/* --------------------------------------------------------------------------
   Clothing item
   -------------------------------------------------------------------------- */

#plp_container.plp-filter-v2
.nf-clothing-group
.nf-option--clothing{
    min-height: 22px;

    transition:
        opacity .16s ease;
}


/*
 * Gender filtering hides actual item completely.
 */
#plp_container.plp-filter-v2
.nf-clothing-group
.nf-option--clothing[hidden]{
    display: none !important;
}


/*
 * Empty category groups are removed after gender selection.
 */
#plp_container.plp-filter-v2
.nf-clothing-group[hidden]{
    display: none !important;
}


/* ==========================================================================
   Mobile
   ========================================================================== */

@media (max-width: 900px){

    #plp_container.plp-filter-v2
    .nf-clothing-group__head{
        min-height: 48px;
    }


    #plp_container.plp-filter-v2
    .nf-clothing-group__title{
        font-size: 13px;
    }


    #plp_container.plp-filter-v2
    .nf-clothing-group.is-open
    .nf-clothing-group__body{
        padding-bottom: 16px;
    }
}


/* ==========================================================================
   Reduced motion
   ========================================================================== */

@media (prefers-reduced-motion: reduce){

    #plp_container.plp-filter-v2
    .nf-clothing-group__collapse,

    #plp_container.plp-filter-v2
    .nf-clothing-group__body,

    #plp_container.plp-filter-v2
    .nf-clothing-group__head svg{
        transition: none !important;
    }
}

/* ==========================================================================
   JPA PLP — MOBILE SORT SHEET POLISH
   Minimal visual refinement only
   ========================================================================== */

@media (max-width: 900px){

    /* ------------------------------------------------------------------
       Backdrop
       ------------------------------------------------------------------ */

    #plp_container.plp-filter-v2
    .plp-sort-backdrop{
        background: rgba(15, 16, 18, .46);

        -webkit-backdrop-filter: blur(1.5px);
        backdrop-filter: blur(1.5px);
    }


    /* ------------------------------------------------------------------
       Sheet
       ------------------------------------------------------------------ */

    #plp_container.plp-filter-v2
    .plp-sort-sheet{
        position: relative;

        width: 100%;

        max-height: calc(100dvh - 90px);

        padding-top: 9px;

        border-radius: 20px 20px 0 0;

        background: #fff;

        box-shadow:
            0 -10px 38px rgba(20, 22, 28, .10);

        direction: rtl;

        font-family: inherit !important;

        -webkit-font-smoothing: antialiased;
        -moz-osx-font-smoothing: grayscale;

        transform: translateY(18px);

        opacity: .88;

        transition:
            transform .24s cubic-bezier(.22, 1, .36, 1),
            opacity .18s ease;
    }


    #plp_container.plp-filter-v2
    .plp-sort-layer.is-open
    .plp-sort-sheet{
        transform: translateY(0);
        opacity: 1;
    }


    /* handle کوچک بالای bottom-sheet */

    #plp_container.plp-filter-v2
    .plp-sort-sheet::before{
        content: "";

        display: block;

        width: 34px;
        height: 4px;

        margin: 0 auto 5px;

        border-radius: 999px;

        background: #dedfe2;
    }


    /* ------------------------------------------------------------------
       Header
       ------------------------------------------------------------------ */

    #plp_container.plp-filter-v2
    .plp-sort-sheet-head{
        min-height: 54px;

        padding:
            0 16px;

        border-bottom:
            1px solid rgba(25, 27, 31, .065);

        background: transparent;
    }


    #plp_container.plp-filter-v2
    .plp-sort-sheet-head h2{
        margin: 0;

        color: #24262a;

        font-family: iransans, Poppins !important;

        font-size: 14px;

        font-weight: 600;

        line-height: 1.7;

        letter-spacing: 0;
    }


    /* close button */

    #plp_container.plp-filter-v2
    #sortClose{
        width: 32px;
        height: 32px;

        display: inline-flex;
        align-items: center;
        justify-content: center;

        padding: 0;

        border: 0;
        border-radius: 50%;

        color: #656970;

        background: #f6f6f7;

        font-family: inherit !important;

        transition:
            background-color .16s ease,
            transform .12s ease;
    }


    #plp_container.plp-filter-v2
    #sortClose:active{
        background: #ededee;

        transform: scale(.96);
    }


    #plp_container.plp-filter-v2
    #sortClose svg{
        width: 16px;
        height: 16px;
    }


    /* ------------------------------------------------------------------
       Options container
       ------------------------------------------------------------------ */

    #plp_container.plp-filter-v2
    .plp-sort-sheet-options{
        display: grid;

        gap: 4px;

        padding:
            9px
            12px
            calc(16px + env(safe-area-inset-bottom, 0px));
    }


    /* ------------------------------------------------------------------
       Option
       ------------------------------------------------------------------ */

    #plp_container.plp-filter-v2
    .plp-sort-sheet-option{
        position: relative;

        width: 100%;
        min-height: 46px;

        display: flex;
        align-items: center;

        padding:
            0 13px;

        border: 0;

        border-radius: 10px;

        color: #555961;

        background: transparent;

        font-family: iransans, Poppins !important;

        font-size: 13px;

        font-weight: 500;

        line-height: 1.6;

        text-align: right;

        direction: rtl;

        cursor: pointer;

        -webkit-appearance: none;
        appearance: none;

        -webkit-tap-highlight-color: transparent;

        transition:
            background-color .16s ease,
            color .16s ease,
            transform .10s ease;
    }


    #plp_container.plp-filter-v2
    .plp-sort-sheet-option:active:not(:disabled){
        transform: scale(.992);

        background: #f7f7f8;
    }


    /* ------------------------------------------------------------------
       Active
       ------------------------------------------------------------------ */

    #plp_container.plp-filter-v2
    .plp-sort-sheet-option.is-active{
        color: crimson;

        background: #f4f4f5;

        font-weight: 600;
    }


    /*
     * نشانگر خیلی مینیمال انتخاب
     * بدون radio بزرگ و بدون شلوغ کردن UI
     */
    #plp_container.plp-filter-v2
    .plp-sort-sheet-option.is-active::after{
        content: "";

        width: 6px;
        height: 6px;

        margin-right: auto;
        margin-left: 2px;

        flex: 0 0 6px;

        border-radius: 50%;

        background: crimson;

        box-shadow:
            0 0 0 4px rgba(36, 38, 42, .07);
    }


    /* ------------------------------------------------------------------
       Disabled
       ------------------------------------------------------------------ */

    #plp_container.plp-filter-v2
    .plp-sort-sheet-option:disabled{
        color: #b7b9bd;

        background: transparent;

        font-weight: 400;

        cursor: default;

        opacity: .72;
    }


    #plp_container.plp-filter-v2
    .plp-sort-sheet-option:disabled::after{
        display: none;
    }
}


/* Small phones */

@media (max-width: 380px){

    #plp_container.plp-filter-v2
    .plp-sort-sheet-option{
        min-height: 44px;

        padding-inline: 12px;

        font-size: 12.5px;
    }

}

/* ==========================================================================
   JPA PLP — PRODUCT CARD OPTION TOKEN REFINEMENT
   Size + Color remain strict 1:1 squares
   ========================================================================== */

#plp_container.plp-filter-v2
.plp-card.plp-card--v2
.sz-chip,

#plp_container.plp-filter-v2
.plp-card.plp-card--v2
.sz-more,

#plp_container.plp-filter-v2
.plp-card.plp-card--v2
.color-dot,

#plp_container.plp-filter-v2
.plp-card.plp-card--v2
.color-plus{

    box-sizing: border-box !important;

    width:
        var(--plp-option-token, 22px) !important;

    min-width:
        var(--plp-option-token, 22px) !important;

    max-width:
        var(--plp-option-token, 22px) !important;

    height:
        var(--plp-option-token, 22px) !important;

    min-height:
        var(--plp-option-token, 22px) !important;

    max-height:
        var(--plp-option-token, 22px) !important;

    flex:
        0 0 var(--plp-option-token, 22px) !important;

    aspect-ratio:
        1 / 1 !important;

    padding:
        0 !important;
}


/* Size */

#plp_container.plp-filter-v2
.plp-card.plp-card--v2
.sz-chip,

#plp_container.plp-filter-v2
.plp-card.plp-card--v2
.sz-more{

    display: inline-flex;

    align-items: center;
    justify-content: center;

    border:
        1px solid #dfe1e5;

    border-radius:
        4px !important;

    background:
        #fff;

    color:
        #60646b;

    font-family:
        inherit !important;

    font-size:
        var(--plp-option-font, 8px) !important;

    font-weight:
        500;

    line-height:
        1;

    text-align:
        center;

    white-space:
        nowrap;
}


/* +N سایز */

#plp_container.plp-filter-v2
.plp-card.plp-card--v2
.sz-more{
    border-style:
        dashed;

    color:
        #74777d;

    font-weight:
        600;
}


/* Color */

#plp_container.plp-filter-v2
.plp-card.plp-card--v2
.color-dot{

    position:
        relative;

    border:
        0;

    border-radius:
        4px !important;

    background:
        var(--dot, #ccc) !important;

    box-shadow:
        inset 0 0 0 1px rgba(0,0,0,.055);

    outline:
        none;

    overflow:
        hidden;
}


/*
 * سفید و رنگ‌های خیلی روشن هم روی بک سفید گم نشوند.
 */
#plp_container.plp-filter-v2
.plp-card.plp-card--v2
.color-dot::after{
    content: "";

    position: absolute;

    inset: 0;

    border-radius:
        inherit;

    box-shadow:
        inset 0 0 0 1px rgba(0,0,0,.025);

    pointer-events:
        none;
}


/* Active color */

#plp_container.plp-filter-v2
.plp-card.plp-card--v2
.color-dot.is-active{

    outline:
        1px solid rgba(25, 27, 31, .35);

    outline-offset:
        1px;

    box-shadow:
        inset 0 0 0 1px rgba(255,255,255,.18);
}


/* +N colors */

#plp_container.plp-filter-v2
.plp-card.plp-card--v2
.color-plus{

    display:
        inline-flex;

    align-items:
        center;
    justify-content:
        center;

    border:
        1px dashed #d9dbe0;

    border-radius:
        4px !important;

    background:
        #fafafa;

    color:
        #666a71;

    font-family:
        inherit !important;

    font-size:
        var(--plp-option-font, 8px) !important;

    font-weight:
        600;

    line-height:
        1;
}


/* Rows */

#plp_container.plp-filter-v2
.plp-card.plp-card--v2
.sizes-row,

#plp_container.plp-filter-v2
.plp-card.plp-card--v2
.color-badges{

    gap:
        var(--plp-option-gap, 4px) !important;

    align-items:
        center;

    min-width:
        0;
}


/* --------------------------------------------------------------------------
   Mobile
   -------------------------------------------------------------------------- */

@media (max-width: 900px){

    #plp_container.plp-filter-v2
    .plp-card.plp-card--v2
    .sz-chip,

    #plp_container.plp-filter-v2
    .plp-card.plp-card--v2
    .sz-more,

    #plp_container.plp-filter-v2
    .plp-card.plp-card--v2
    .color-dot,

    #plp_container.plp-filter-v2
    .plp-card.plp-card--v2
    .color-plus{

        border-radius:
            4px !important;
    }

}


/* --------------------------------------------------------------------------
   Mobile 4-column remains intentionally compact
   -------------------------------------------------------------------------- */

@media (max-width: 900px){

    #plp_container.plp-filter-v2.grid-4
    .plp-card.plp-card--v2
    .sz-chip,

    #plp_container.plp-filter-v2.grid-4
    .plp-card.plp-card--v2
    .sz-more,

    #plp_container.plp-filter-v2.grid-4
    .plp-card.plp-card--v2
    .color-dot,

    #plp_container.plp-filter-v2.grid-4
    .plp-card.plp-card--v2
    .color-plus{

        border-radius:
            2px !important;
    }

}

/* ========================================================================== 
   PLP SIDEBAR — shared page scroll / direction-aware desktop pinning
   --------------------------------------------------------------------------
   Desktop only:
   - Sidebar and products use the SAME document scroll.
   - No inner scrollbar/max-height on the sidebar.
   - The site header is intentionally ignored; it may overlay the sidebar.
   - Tall sidebars move naturally until their bottom reaches the viewport,
     then pin there. On upward scroll the motion reverses until the top pins.
   - The panel is always constrained by #shell and cannot overlap the footer.
   Mobile drawer behaviour remains untouched.
   ========================================================================== */
@media (min-width:901px){
    #plp_container.plp-filter-v2 #shell{
        position:relative;
        align-items:start;
        overflow:visible !important;
    }

    #plp_container.plp-filter-v2 .nf-filter-anchor{
        display:block !important;
        grid-column:2;
        grid-row:1;
        align-self:start;
        width:1px;
        height:1px;
        margin:0;
        padding:0;
        visibility:hidden;
        pointer-events:none;
    }

    /* Natural/grid state. JS only leaves this state after the sidebar reaches
       the appropriate viewport edge. Keeping this non-sticky avoids fighting
       the direction-aware runtime logic. */
    #plp_container.plp-filter-v2 .nf-filter-panel{
        position:relative !important;
        top:auto !important;
        right:auto !important;
        bottom:auto !important;
        left:auto !important;
        grid-column:2;
        grid-row:1;
        align-self:start !important;
        width:var(--nf-panel-width) !important;
        min-width:0 !important;
        max-width:var(--nf-panel-width) !important;
        height:auto !important;
        max-height:none !important;
        margin:0 !important;
        overflow:visible !important;
        grid-template-rows:auto !important;
        z-index:5 !important;
        transition:none !important;
        will-change:auto !important;
    }

    /* Viewport-pinned state. `--nf-runtime-top` is driven only by document
       scroll direction; header height/visibility is deliberately not used. */
    #plp_container.plp-filter-v2 .nf-filter-panel.is-v4-fixed{
        position:fixed !important;
        top:var(--nf-runtime-top, 12px) !important;
        right:auto !important;
        bottom:auto !important;
        margin:0 !important;
        z-index:5 !important;
    }

    /* Physical end of the shared shell. This prevents overlap with anything
       after the PLP (pager/footer/etc.) while keeping both columns synchronized. */
    #plp_container.plp-filter-v2 .nf-filter-panel.is-v4-bottomed{
        position:absolute !important;
        top:auto !important;
        right:0 !important;
        bottom:0 !important;
        left:auto !important;
        width:var(--nf-panel-width) !important;
        margin:0 !important;
        z-index:5 !important;
    }

    #plp_container.plp-filter-v2 .nf-filter-scroll{
        min-height:0 !important;
        max-height:none !important;
        height:auto !important;
        overflow:visible !important;
        overscroll-behavior:auto !important;
        scrollbar-gutter:auto !important;
        scrollbar-width:none !important;
    }

    #plp_container.plp-filter-v2 .nf-filter-scroll::-webkit-scrollbar{
        display:none !important;
        width:0 !important;
        height:0 !important;
    }
}
