.list_box {
    display: flex;
    align-items: flex-start;
    width: 100%;
    max-width: 1600px;
    gap: 30px
}

.list_box .filters {
    display: none;
    width: 300px;
    gap: var(--padding)
}

.list_box .filters h3 {
    font-size: 16px;
    font-weight: 500;
    line-height: 20px;
}

.list_box .filters h4 {
    font-size: unset;
    font-weight: unset
}

.list_box .filters .filters_box {
    display: grid;
    gap: 15px;
    position: sticky;
    top: 0;
}

.list_box .filters .filters_box .item {
    background: #fff
}

.list_box .filters .filters_box .item h3 {
    display: flex;
    padding: 15px 25px;
    width: 100%;
    background: var(--black-800);
    color: #fff;
}

.list_box .filters label {
    display: flex;
    gap: 10px;
    padding: 15px 25px;
}

.list_box .filter-categories, .list_box .filter-brands {
    overflow-y: auto
}

.list_box .filter-categories button {
    width: 100%;
    word-break: keep-all;
    background: 0;
    color: #000;
    border-radius: 0;
    text-align: start;
    position: relative;
    padding: 15px 25px
}

.list_box .filter-categories button.active {
    color: var(--primary-color-1)
}

.list_box .filter-categories button.active:before {
    content: "";
    background: var(--primary-color-1);
    position: absolute;
    left: 0;
    top: 0;
    width: 4px;
    height: 100%
}

.list_box .result > .filter-button {
    /*display: grid;*/
    display: none;
    gap: 3px;
    place-items: center;
    position: fixed;
    top: 50vh;
    left: 0;
    color: #fff;
    width: 27px;
    padding: 6px 3px;
    border-radius: 0 4px 4px 0;
    transform: translateY(-50%);
    background: var(--primary-color-1);
    z-index: 2;
    text-align: center
}

.list_box .tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px
}

.list_box .tags label {
    background: var(--tag-bg);
    color: #fff;
    font-size: 12px;
    height: 21px;
    display: grid;
    place-items: center;
    border-radius: 4px;
    padding: 0 5px;
    cursor: pointer
}

.list_box .tags label:hover {
    background: var(--button-background-hover)
}

.list_box .tags input {
    display: none
}

.list_box .tags input:checked + label {
    background: var(--button-background-hover)
}

.list_box .result {
    display: grid;
    gap: 15px;
    width: 100%
}

.list_box .result .box {
    background: #fff;
    padding: 15px var(--padding)
}

.list_box .result-filter {
    display: none;
    flex-wrap: wrap;
    align-items: center;
    width: 100%
}

.list_box .result-filter > div:first-of-type {
    margin-bottom: 1rem
}

.list_box .result-filter > div:first-of-type label {
    position: absolute;
    top: 20px;
    right: 20px
}

.list_box .price-range {
    display: flex;
    gap: 10px;
    align-items: center;
    width: 100%
}

.list_box .price-range .irs {
    width: 100%;
    max-width: 231px
}

.list_box .price-range input {
    padding: 5px 8px;
    width: 5rem
}

.list_box .price-range input:first-of-type {
    margin-left: auto
}

.list_box .result-products .products {
    margin-top: 15px
}

.list_box .result-products .pagination {
    margin-top: 15px
}

.list_box .sort {
    display: flex
}

.list_box .sort .filter{
    display: flex;
    align-items: center;
    margin-right: 20px;
}
.list_box .sort .filter svg{
    width: 20px;
    height: 20px;
    margin-right: 5px;
}

.list_box .sort .count {
    margin-left: 8px;
}

.list_box .sort .order {
    margin-left: auto;
    margin-right: auto;
    display: flex;
    align-items: center;
}

.list_box select {
    padding: 5px 8px
}

.list_box select:hover:not(:focus) {
    background: var(--black-100)
}

.list_box .products {
    --gap: 10px;
    --column-width: max(calc((100% - (var(--gap) * 3)) / 4), 170px);
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(var(--column-width), auto));
    gap: var(--gap)
}

.list_box #mobile-filter {
    display: none
}

@media (max-width: 768px) {
    .list_box #mobile-filter:checked ~ .mobile-filter {
        top: 10vw;
        padding: 0;
        display: grid;
        overflow-y: auto;
        z-index: 11;
    }
    .list_box #mobile-filter:checked ~ .background {
        z-index: 10;
    }

    .list_box #mobile-filter:checked ~ .mobile-filter .smallContainer {
        padding: 0
    }

    .list_box #mobile-filter:checked ~ .mobile-filter .smallContainer .searchFunction {
        padding: 0 1rem
    }

    .list_box.search #mobile-filter:checked ~ .mobile-filter .smallContainer .searchFunction {
        width: 100%;
    }

    .list_box #mobile-filter:checked ~ .mobile-filter .result-filter {
        display: contents
    }

    .list_box #mobile-filter:checked ~ .mobile-filter .result-filter > div:not(.tags-title) {
        padding: 10px
    }

    .list_box #mobile-filter:checked ~ .mobile-filter .result-filter > div:first-of-type {
        width: 100%;
        padding-block: 20px 10px;
        border-bottom: 1px solid #000;
        position: sticky;
        top: 0;
        background: #fff;
        z-index: 3
    }

    .list_box #mobile-filter:checked ~ .mobile-filter .result-filter > div:nth-of-type(2) {
        display: flex;
        flex-direction: column;
        align-items: flex-start
    }

    .list_box #mobile-filter:checked ~ .mobile-filter .result-filter > div:nth-of-type(2) > div {
        flex: 1
    }

    .list_box #mobile-filter:checked ~ .mobile-filter .result-filter > div:nth-of-type(2) > div > label {
        background: 0;
        border: 1px solid #000;
        border-radius: 0
    }

    .list_box #mobile-filter:checked ~ .mobile-filter .result-filter > div:nth-of-type(2) > div > label button {
        background: 0;
        color: #000
    }

    .list_box #mobile-filter:checked ~ .mobile-filter .filters {
        display: grid;
        width: 100%;
    }

    #mobile-filter:checked~.mobile-filter .filters .filter-categories {
        height: 85%
    }

    #mobile-filter:checked~.mobile-filter .filters .filter-categories button:nth-of-type(2n) {
        background: var(--black-50)
    }

    .list_box #mobile-filter:checked ~ .mobile-filter .filters .filter-brands {
        height: 86%
    }

    .list_box #mobile-filter:checked ~ .mobile-filter .filters .filter-brands label:nth-of-type(2n) {
        background: var(--black-50)
    }

    .list_box #mobile-filter:checked ~ .mobile-filter .filters h3 {
        background: var(--black-100);
        color: #000
    }

    .list_box #mobile-filter:checked ~ .mobile-filter .filters > div {
        display: grid;
    }

    .list_box #mobile-filter:checked ~ .mobile-filter .filters > div > div {
        height: 100%;
        overflow: hidden
    }

    .list_box #mobile-filter:checked ~ .mobile-filter .filters > div > div h3 {
        position: sticky;
        top: 0;
        z-index: 2
    }

    .list_box #mobile-filter:checked ~ .mobile-filter .tags-title {
        width: 100%;
        background: var(--black-100);
        padding: 15px 25px;
        grid-row: 5/6;
        font-weight: 500
    }

    .list_box #mobile-filter:checked ~ .mobile-filter .tags {
        grid-row: 6/7
    }

    .list_box #mobile-filter:checked ~ .background {
        opacity: .4;
        pointer-events: all
    }

    .list_box .sorting {
        background: var(--black-100)
    }

    .list_box .sorting .asc:before {
        background: var(--black-400)
    }

    .list_box .sorting .asc:after {
        background: unset
    }

    .list_box .sorting .desc:before {
        background: unset
    }

    .list_box .sorting .desc:after {
        background: var(--black-400)
    }
}

.list_box .mobile-filter, .background {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 2
}

.list_box .background {
    opacity: 0;
    background: #000;
    transition: .3s opacity ease;
    pointer-events: none
}

.list_box .mobile-filter {
    position: fixed;
    align-content: flex-start;
    gap: 10px;
    top: 100%;
    background: #fff;
    border-radius: 12px 12px 0 0;
    transition: .3s top ease
}

@media (min-width: 768px) {
    .list_box .filters {
        display: grid;
        align-content: flex-start;
        grid-row: 1/4
    }

    .list_box .filter-categories, .list_box .filter-brands {
        max-height: 400px;
    }

    .list_box .result > label.filter-button {
        display: none
    }

    .list_box .result {
        display: grid;
        grid-template-columns: auto 1fr;
        grid-template-rows: auto auto 1fr;
        gap: var(--padding)
    }

    .list_box .mobile-filter {
        display: contents
    }

    .list_box .result-filter {
        display: flex;
        justify-content: space-between;
        background: #fff;
        padding: 15px var(--padding)
    }

    .list_box .result-filter > div:first-of-type {
        width: 100%;
        display: flex;
        flex-wrap: wrap;
        gap: 10px
    }

    .list_box .result-filter > div:first-of-type label {
        display: none
    }

    .list_box .result-filter .tags-title {
        display: none
    }

    .list_box .result-filter .tags {
        grid-column: 1/3
    }

    .list_box .result-products {
        gap: 30px
    }

    .list_box .tags {
        display: flex
    }

    .list_box .sort .filter{
        display: none;
    }

    .list_box .sort .order{
        margin-left: 0;
    }

    .list_box .sorting {
        background: var(--black-800)
    }

    .list_box .sorting .asc:before {
        background: var(--black-400)
    }

    .list_box .sorting .asc:after {
        background: unset
    }

    .list_box .sorting .desc:before {
        background: unset
    }

    .list_box .sorting .desc:after {
        background: var(--black-400)
    }
}

.list_box .searchBox {
    display: flex;
    align-items: center
}

.list_box .searchBox > p {
    min-width: 7rem
}

.list_box .smallContainer {
    padding-right: var(--padding);
    background-color: #fff;
    display: flex;
    flex-direction: row
}

.list_box .smallContainer .result-filter {
    width: 65%
}

.list_box .smallContainer .searchFunction {
    display: flex;
    justify-items: center;
    align-items: center;
    flex-direction: column;
    margin: auto 0;
    gap: 1rem;
}

.list_box.search .smallContainer .searchFunction{
    flex: 1;
}

@media (max-width: 1200px) {
    .list_box .smallContainer {
        flex-direction: column;
        align-items: center
    }

    .list_box .smallContainer .result-filter {
        width: 100%
    }

    .list_box .smallContainer .searchFunction {
        width: fit-content
    }
}

.list_box .sorting {
    padding: 0 25px 0 0
}

.list_box .connectLink {
    display: flex;
    justify-content: center;
    margin-top: 15px;
}

@media (min-width: 768px) {
    .list_box .smallContainer .searchFunction{
        padding: 15px 0;
    }
}


