.view-filter-wrap {
    padding: 12px 12px 48px 12px;
    margin: 0 16px 16px 16px;
    background: #fff;
    border-radius: 24px;
    border: 1px solid #E9E9ED;
    display: flex;
    flex-direction: column;
    gap: 16px;
    position: relative;
    z-index: 0;
}

.view-filter-wrap:before {
    content: '';
    display: block;
    width: 1px;
    height: 90%;
    background: var(--view-primary-100);
    position: absolute;
    top: 0;
    right: 12%;
    z-index: -1;
}

span.content-filter-label-en {
    font-size: 12px;
    font-weight: 500;
    color: #A7A5B5;
    pointer-events: none;
    direction: ltr;
    max-width: 40%;
    text-wrap: nowrap;
    text-overflow: ellipsis;
}

.view-filter-wrap:after {
    content: '';
    display: block;
    width: 9px;
    height: 9px;
    background: var(--view-primary-100);
    position: absolute;
    top: 90%;
    right: 10.5%;
    z-index: -1;
    border-radius: 50%;
}

.view-filter-wrap .filters-header {
    gap: 12px;
    position: relative;
}

.remove-filters {
    background: #FDF5F8;
    display: flex;
    gap: 5px;
    align-items: center;
    justify-content: center;
    padding: 3px 8px 3px 4px;
    border-radius: 24px;
    font-size: 14px;
    font-weight: 400;
    line-height: 22px;
    position: absolute;
    left: 0;
    top: 8px;
    color: var(--view-accent);
    text-decoration: none;
}

.view-filter-wrap .filters-header h3 {
    padding: 0;
    margin: 0;
    font-size: 18px;
    font-weight: 700;
    line-height: 26px;
}

.view-filter-wrap .filters-header span {
    color: var(--view-accent-400);
    font-family: inherit;
    font-size: 12px;
    line-height: 20px;
    font-weight: 500;
}


/* ظرف اصلی */
.content-filter {
    background: #fff;
    border-radius: 22px;
    overflow: hidden;
}

/* Toggle بدون JS */
.content-filter-toggle {
    display: none;
}

/* هدر */
.content-filter-header {
    position: relative;
    height: 32px;
    padding: 8px 16px 8px 8px;
    background: var(--view-primary);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    border-radius: 32px;
    flex-direction: row;
    z-index: 0;
    overflow: hidden;
}

.content-filter-header:before {
    content: '';
    position: absolute;
    right: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: url("../image/horizontal-pattern.png");
    display: block;
    mix-blend-mode: overlay;
    z-index: -1;
}


.content-filter-title {
    position: relative;
    z-index: 1;
    font-size: 16px;
    font-weight: 500;
    line-height: 22px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.content-filter-title::after {
    content: "";
    width: 8px;
    height: 8px;
    border-radius: 2px;
    transform: rotate(45deg);
    background: #fff;
    display: inline-block;
}

.content-filter-chevron {
    left: 10px;
    top: 9px;
    width: fit-content;
    height: fit-content;
    border-radius: 10px;
    display: flex;
    place-items: center;
    color: #fff;
    transition: transform .28s ease;
    z-index: 1;
    align-items: center;
    justify-content: center;
    flex-direction: column;
}


/* لیست (Collapsible) */
.content-filter-list {
    padding: 12px;
    display: flex;
    gap: 10px;
    max-height: 0;
    overflow: hidden;
    transition: max-height .42s ease;
    position: relative;
    background: #fff;
    flex-direction: column;
    border: 1px solid #DEDCF7;
    border-radius: 24px;
    margin-top: 4px;
}

.content-filter-toggle:checked~.content-filter-list {
    max-height: 560px;
    visibility: visible;
    opacity: 1;
}

.content-filter-toggle:not(:checked)~.content-filter-list {
    display: none;
    visibility: hidden;
    opacity: 0;
}

.content-filter-toggle:not(:checked)~.content-filter-header {
    background: #F7F6FD;
    border: 1px solid #EFEEFB;
    color: var(--view-accent);
}

.content-filter-toggle:not(:checked)~.content-filter-header:before {
    background: transparent;
}

.content-filter-toggle:not(:checked)~.content-filter-header svg circle {
    fill: #DEDCF7;
    opacity: 1;
}

.content-filter-toggle:not(:checked)~.content-filter-header svg path {
    stroke: var(--view-primary);
}

.content-filter-header svg {
    transition: ease-in-out 300ms;
}

.content-filter-toggle:not(:checked)~.content-filter-header svg {
    transform: rotate(-90deg);
}

.content-filter-toggle:not(:checked)~.content-filter-header .content-filter-title::after {
    background: var(--view-primary);
}

.content-filter-marker {
    display: none;
}

.content-filter-option:has(.content-filter-input:checked) .content-filter-marker {
    display: inline-block;
}


/* آیتم‌ها */
.content-filter-option {
    position: relative;
    display: flex;
    align-items: center;
    gap: 10px;
    height: 48px;
    padding: 0 14px;
    background: #fff;
    border-radius: 40px;
    transition: background .2s ease, border-color .2s ease, box-shadow .2s ease;
    border: 1px solid #E9E9ED;
    text-decoration: none;
    z-index: 0;
}


/* ورودی رادیو مخفی */
.content-filter-input {
    display: none;
}

/* عنوان فارسی */
.content-filter-label {
    flex: 1;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    color: var(--view-accent);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-decoration: none;
    line-height: 20px;
}

/* متن انگلیسی کم‌رنگ (فقط در انتخاب‌شده) */
.content-filter-subtext {
    font-size: 12px;
    font-weight: 500;
    color: #A7A5B5;
    pointer-events: none;
    direction: ltr;
}


.content-filter-option:has(.content-filter-input:checked),
.content-filter-option:hover {
    background: #EFEEFB;
    position: relative;
    overflow: hidden;
}


.content-filter-option:has(.content-filter-input:checked):before,
.content-filter-option:hover:before {
    content: '';
    position: absolute;
    inset: 4px;
    border: 1px solid #BDB9EF;
    border-radius: 32px;
    z-index: -1;
}


/*DATE FILTER*/


/* ظرف اصلی */
.date-filter {
    background: #fff;
    border-radius: 22px;
    overflow: hidden;
}

/* Toggle بدون JS */
.date-filter-toggle {
    display: none;
}

/* هدر */
.date-filter-header {
    position: relative;
    height: 32px;
    padding: 8px 16px 8px 8px;
    background: var(--view-secondary);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    border-radius: 32px;
    flex-direction: row;
    z-index: 0;
    overflow: hidden;
}

.date-filter-header:before {
    content: '';
    position: absolute;
    right: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: url("../image/horizontal-pattern.png");
    display: block;
    mix-blend-mode: overlay;
    z-index: -1;
}

.date-filter-title {
    position: relative;
    z-index: 1;
    font-size: 16px;
    font-weight: 500;
    line-height: 22px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.date-filter-title::after {
    content: "";
    width: 8px;
    height: 8px;
    border-radius: 2px;
    transform: rotate(45deg);
    background: #fff;
    display: inline-block;
}

.date-filter-chevron {
    left: 10px;
    top: 9px;
    width: fit-content;
    height: fit-content;
    border-radius: 10px;
    display: flex;
    place-items: center;
    color: #fff;
    transition: transform .28s ease;
    z-index: 1;
    align-items: center;
    justify-content: center;
    flex-direction: column;
}


/* لیست (Collapsible) */
.date-filter-list {
    padding: 12px;
    display: flex;
    gap: 10px;
    max-height: 0;
    overflow: hidden;
    transition: max-height .42s ease;
    position: relative;
    background: #fff;
    flex-direction: column;
    border: 1px solid #DEDCF7;
    border-radius: 24px;
    margin-top: 4px;
}

.date-filter-toggle:checked~.date-filter-list {
    max-height: 560px;
    visibility: visible;
    opacity: 1;
}

.date-filter-toggle:not(:checked)~.date-filter-list {
    display: none;
    visibility: hidden;
    opacity: 0;
}

.date-filter-toggle:not(:checked)~.date-filter-header {
    background: #FDF5F8;
    border: 1px solid #FCEAF0;
    color: var(--view-accent);
}

.date-filter-toggle:not(:checked)~.date-filter-header:before {
    background: transparent;
}

.date-filter-toggle:not(:checked)~.date-filter-header svg circle {
    fill: #F9D6E2;
    opacity: 1;
}

.date-filter-header svg {
    transition: ease-in-out 300ms;
}

.date-filter-toggle:not(:checked)~.date-filter-header svg {
    transform: rotate(-90deg);
}

.date-filter-toggle:not(:checked)~.date-filter-header svg path {
    stroke: var(--view-secondary);
}

.date-filter-toggle:not(:checked)~.date-filter-header .date-filter-title::after {
    background: var(--view-secondary);
}

.date-filter-marker {
    display: none;
}

.date-filter-option:has(.date-filter-input:checked) .date-filter-marker {
    display: inline-block;
}


/* آیتم‌ها */
.date-filter-option {
    position: relative;
    display: flex;
    align-items: center;
    gap: 10px;
    height: 48px;
    padding: 0 14px;
    background: #fff;
    border-radius: 40px;
    transition: background .2s ease, border-color .2s ease, box-shadow .2s ease;
    border: 1px solid #E9E9ED;
    text-decoration: none;
    z-index: 0;
}


/* ورودی رادیو مخفی */
.date-filter-input {
    display: none;
}

/* عنوان */
.date-filter-label {
    flex: 1;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    color: var(--view-accent);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-decoration: none;
    line-height: 20px;
}

/* زیرنویس */
.date-filter-subtext {
    font-size: 12px;
    font-weight: 500;
    color: #A7A5B5;
    pointer-events: none;
    direction: ltr;
}

.date-filter-option:has(.date-filter-input:checked),
.date-filter-option:hover {
    background: #FCEAF0;
    position: relative;
    overflow: hidden;
}

.date-filter-option:has(.date-filter-input:checked):before,
.date-filter-option:hover:before {
    content: '';
    position: absolute;
    inset: 4px;
    border: 1px solid #F3ACC4;
    border-radius: 32px;
    z-index: -1;
}


/* ظرف اصلی */
.popularity-filter {
    background: #fff;
    border-radius: 22px;
    overflow: hidden;
}

/* Toggle بدون JS */
.popularity-filter-toggle {
    display: none;
}

/* هدر */
.popularity-filter-header {
    position: relative;
    height: 32px;
    padding: 8px 16px 8px 8px;
    background: var(--view-primary);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    border-radius: 32px;
    flex-direction: row;
    z-index: 0;
    overflow: hidden;
}

.popularity-filter-header:before {
    content: '';
    position: absolute;
    right: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: url("../image/horizontal-pattern.png");
    display: block;
    mix-blend-mode: overlay;
    z-index: -1;
}

.popularity-filter-title {
    position: relative;
    z-index: 1;
    font-size: 16px;
    font-weight: 500;
    line-height: 22px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.popularity-filter-title::after {
    content: "";
    width: 8px;
    height: 8px;
    border-radius: 2px;
    transform: rotate(45deg);
    background: #fff;
    display: inline-block;
}

.popularity-filter-chevron {
    left: 10px;
    top: 9px;
    width: fit-content;
    height: fit-content;
    border-radius: 10px;
    display: flex;
    place-items: center;
    color: #fff;
    transition: transform .28s ease;
    z-index: 1;
    align-items: center;
    justify-content: center;
    flex-direction: column;
}

/* لیست (Collapsible) */
.popularity-filter-list {
    padding: 12px;
    display: flex;
    gap: 10px;
    max-height: 0;
    overflow: hidden;
    transition: max-height .42s ease;
    position: relative;
    background: #fff;
    flex-direction: column;
    border: 1px solid #DEDCF7;
    border-radius: 24px;
    margin-top: 4px;
}

.popularity-filter-toggle:checked~.popularity-filter-list {
    max-height: 560px;
    visibility: visible;
    opacity: 1;
}

.popularity-filter-toggle:not(:checked)~.popularity-filter-list {
    display: none;
    visibility: hidden;
    opacity: 0;
}

.popularity-filter-toggle:not(:checked)~.popularity-filter-header {
    background: #F7F6FD;
    border: 1px solid #EFEEFB;
    color: var(--view-accent);
}

.popularity-filter-toggle:not(:checked)~.popularity-filter-header:before {
    background: transparent;
}

.popularity-filter-toggle:not(:checked)~.popularity-filter-header svg circle {
    fill: #DEDCF7;
    opacity: 1;
}


.popularity-filter-header svg {
    transition: ease-in-out 300ms;
}

.popularity-filter-toggle:not(:checked)~.popularity-filter-header svg {
    transform: rotate(-90deg);
}


.popularity-filter-toggle:not(:checked)~.popularity-filter-header svg path {
    stroke: var(--view-primary);
}

.popularity-filter-toggle:not(:checked)~.popularity-filter-header .popularity-filter-title::after {
    background: var(--view-primary);
}

.popularity-filter-marker {
    display: none;
}

.popularity-filter-option:has(.popularity-filter-input:checked) .popularity-filter-marker {
    display: inline-block;
}

/* آیتم‌ها */
.popularity-filter-option {
    position: relative;
    display: flex;
    align-items: center;
    gap: 10px;
    height: 48px;
    padding: 0 14px;
    background: #fff;
    border-radius: 40px;
    transition: background .2s ease, border-color .2s ease, box-shadow .2s ease;
    border: 1px solid #E9E9ED;
    text-decoration: none;
    z-index: 0;
}

/* ورودی رادیو مخفی */
.popularity-filter-input {
    display: none;
}

/* عنوان */
.popularity-filter-label {
    flex: 1;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    color: var(--view-accent);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-decoration: none;
    line-height: 20px;
}

/* زیرنویس */
.popularity-filter-subtext {
    font-size: 12px;
    font-weight: 500;
    color: #A7A5B5;
    pointer-events: none;
    direction: ltr;
}

.popularity-filter-option:has(.popularity-filter-input:checked),
.popularity-filter-option:hover {
    background: #EFEEFB;
    position: relative;
    overflow: hidden;
}

.popularity-filter-option:has(.popularity-filter-input:checked):before,
.popularity-filter-option:hover:before {
    content: '';
    position: absolute;
    inset: 4px;
    border: 1px solid #BDB9EF;
    border-radius: 32px;
}

/* Container */
.brand-filter {
    background: #fff;
    border-radius: 22px;
    overflow: hidden;
}

/* Toggle (no JS) */
.brand-filter-toggle {
    display: none;
}

/* Header */
.brand-filter-header {
    position: relative;
    height: 32px;
    padding: 8px 16px 8px 8px;
    background: var(--view-secondary);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    border-radius: 32px;
    flex-direction: row;
    z-index: 0;
    overflow: hidden;
}

.brand-filter-header:before {
    content: '';
    position: absolute;
    right: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: url("../image/horizontal-pattern.png");
    display: block;
    mix-blend-mode: overlay;
    z-index: -1;
}

.brand-filter-title {
    position: relative;
    z-index: 1;
    font-size: 16px;
    font-weight: 500;
    line-height: 22px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.brand-filter-title::after {
    content: "";
    width: 8px;
    height: 8px;
    border-radius: 2px;
    transform: rotate(45deg);
    background: #fff;
    display: inline-block;
}

.brand-filter-toggle:not(:checked)~.brand-filter-header .brand-filter-title::after {
    background: var(--view-secondary);
}

.brand-filter-chevron {
    left: 10px;
    top: 9px;
    width: fit-content;
    height: fit-content;
    border-radius: 10px;
    display: flex;
    place-items: center;
    color: #fff;
    transition: transform .28s ease;
    z-index: 1;
    align-items: center;
    justify-content: center;
    flex-direction: column;
}

.brand-filter-header svg {
    transition: ease-in-out 300ms;
}

/* Panel (search + list collapse together) */
.brand-filter-panel {
    max-height: 0;
    overflow: hidden;
    transition: max-height .42s ease, opacity .42s ease;
    opacity: 0;
    margin-top: 4px;
}

.brand-filter-toggle:checked~.brand-filter-panel {
    max-height: 600px;
    /* adjust if needed */
    opacity: 1;
}

/* Header visual when closed */
.brand-filter-toggle:not(:checked)~.brand-filter-header {
    background: #FDF5F8;
    border: 1px solid #FCEAF0;
    color: var(--view-accent);
}

.brand-filter-toggle:not(:checked)~.brand-filter-header:before {
    background: transparent;
}

.brand-filter-toggle:not(:checked)~.brand-filter-header svg {
    transform: rotate(-90deg);
}

.brand-filter-toggle:not(:checked)~.brand-filter-header svg path {
    stroke: var(--view-secondary);
}

.brand-filter-toggle:not(:checked)~.brand-filter-header svg circle {
    fill: #F9D6E2;
    opacity: 1;
}

/* Search */
.brand-filter-search {
    position: relative;
    margin: 8px 0 0 0;
}

.brand-filter-search-input {
    width: 100%;
    height: 48px;
    padding: 14px;
    /* LTR icon space */
    border: 1px solid #E9E9ED;
    border-radius: 999px;
    background: #fff;
    font-size: 14px;
    line-height: 20px;
    outline: none;
}


.brand-filter-search-input::placeholder {
    color: #A7A5B5;
}

/* پنل نتایج */
/* حذف دکمه clear (x) در کروم / اج */
.brand-filter-search-input[type="search"]::-webkit-search-cancel-button {
    -webkit-appearance: none;
    appearance: none;
    display: none;
}

/* فایرفاکس */
.brand-filter-search-input[type="search"]::-moz-search-clear {
    display: none;
}

/* سافاری (وب‌کیت) */
.brand-filter-search-input[type="search"]::-webkit-search-decoration,
.brand-filter-search-input[type="search"]::-webkit-search-results-button,
.brand-filter-search-input[type="search"]::-webkit-search-results-decoration {
    display: none;
}


.brand-filter-search-icon {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    left: 12px;
    color: #A7A5B5;
    pointer-events: none;
}

/* List */
.brand-filter-list {
    padding: 12px;
    display: flex;
    gap: 10px;
    flex-direction: column;
    background: #fff;
    border: 1px solid #F9D6E2;
    border-radius: 24px;
    max-height: 291px;
    /* bounded by inline style too */
    overflow: auto;
}




/* Items */
.brand-filter-option {
    position: relative;
    display: flex;
    align-items: center;
    gap: 5px;
    height: 48px;
    min-height: 48px;
    max-height: 48px;
    padding: 0 14px;
    background: #fff;
    border-radius: 40px;
    transition: background .2s ease, border-color .2s ease, box-shadow .2s ease;
    border: 1px solid #E9E9ED;
    text-decoration: none;
    z-index: 0;
}

.brand-filter-input {
    display: none;
}

.brand-filter-marker {
    display: none;
}

.brand-filter-option:has(.brand-filter-input:checked) .brand-filter-marker {
    display: inline-block;
}

/* Labels */
.brand-filter-label {
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    color: var(--view-accent);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-decoration: none;
    line-height: 20px;
    width: fit-content;
}

.brand-filter-subtext {
    font-size: 12px;
    font-weight: 500;
    color: #A7A5B5;
    pointer-events: none;
    direction: ltr;
}

.brand-filter-count {
    margin-inline-start: 8px;
    font-size: 12px;
    color: #A7A5B5;
}

/* Hover/Active */
.brand-filter-option:hover,
.brand-filter-option.is-active,
.brand-filter-option:has(.brand-filter-input:checked) {
    background: #FCEAF0;
    position: relative;
}

.brand-filter-option:hover::before,
.brand-filter-option.is-active::before,
.brand-filter-option:has(.brand-filter-input:checked)::before {
    content: '';
    position: absolute;
    inset: 4px;
    border: 1px solid #F3ACC4;
    border-radius: 32px;
    z-index: -1;
}




.brand-filter-list {
    scrollbar-width: none;
}