.shop-page {
    margin-bottom: 9.375rem;
}

.shop-page .page-header {
    margin-bottom: 4.375rem;
}

/*
|--------------------------------------------------------------------------
| Header
|--------------------------------------------------------------------------
*/


.shop-title {
    margin: 0 0 1rem;

    font-size: 3.4375rem;
    font-weight: 400;
    line-height: 1.1;

    color: var(--dark);
}

.shop-description {
    max-width: 45rem;

    color: var(--gray);
}


/*
|--------------------------------------------------------------------------
| Layout
|--------------------------------------------------------------------------
*/

.shop-layout {
    display: grid;

    grid-template-columns: minmax(0, 1fr) 15rem;

    gap: 3.75rem;
}


/*
|--------------------------------------------------------------------------
| Sidebar
|--------------------------------------------------------------------------
*/

.shop-sidebar {
    display: flex;
    flex-direction: column;

    gap: 2.5rem;
}

.shop-filter {
    padding-bottom: 2rem;
    border-bottom: 0.0625rem solid var(--light-gray-4);
}

.shop-filter:last-of-type {
    padding: 0;
    border-bottom: 0;
}

.shop-filter-title {
    margin: 0 0 1.25rem;
    font-size: 1.875rem;
    font-weight: 400;
    line-height: 1.1;
    letter-spacing: 1%;
    text-transform: capitalize;
    color: var(--dark);
}


/*
|--------------------------------------------------------------------------
| Categories
|--------------------------------------------------------------------------
*/

.shop-categories {
    display: flex;
    flex-direction: column;

    gap: 0.75rem;
}

.shop-category {
    display: flex;
    align-items: center;
    justify-content: space-between;

    color: var(--gray);

    text-decoration: none;

    transition: color 0.3s ease;
}

.shop-category:hover,
.shop-category.active {
    color: var(--dark);
}

.shop-category-count {
    font-size: 0.75rem;
    color: var(--gray);
}


/*
|--------------------------------------------------------------------------
| Price
|--------------------------------------------------------------------------
*/

.price-filter {
    display: flex;
    flex-direction: column;

    gap: 1rem;
}

.price-filter-fields {
    display: grid;

    grid-template-columns: 1fr 1fr;

    gap: 0.625rem;
}

.price-field {
    display: flex;
    flex-direction: column;

    gap: 0.375rem;
}

.price-field label {
    font-size: 0.75rem;
    color: var(--gray);
}

.price-field input {
    width: 100%;
    box-sizing: border-box;

    padding: 0.625rem;

    border: 0.0625rem solid var(--light-gray-4);
    border-radius: 0.25rem;

    outline: none;
}

.shop-filter-button {
    font-family: var(--font-family);
    align-self: flex-start;

    padding: 0.75rem 1.25rem;

    border: 0.0625rem solid var(--dark);
    border-radius: 0.25rem;

    background: var(--dark);

    color: var(--white);

    cursor: pointer;
}


/*
|--------------------------------------------------------------------------
| Products top
|--------------------------------------------------------------------------
*/

.shop-products-top {
    display: flex;
    align-items: center;
    justify-content: space-between;

    margin-bottom: 1.875rem;
}

.shop-products-count {
    color: var(--gray);
}

.shop-ordering select {
    font-family: var(--font-family);
    font-weight: 400;
    font-size: 1rem;
    letter-spacing: 1%;
    text-transform: capitalize;
    padding: 0.75rem 1rem;

    border-bottom: 0.0625rem solid var(--light-gray-4);
    border-radius: 0.25rem;

    background: var(--white);

    color: var(--dark);

    cursor: pointer;
}

.filter-toggle {
    display: none;
}

.filter-toggle-icon {
    position: relative;
    top: -0.125rem;
    height: 1.5rem;
    width: 1.5rem;
    fill: var(--dark);
    transition: fill 0.3s ease;
}

.filter-toggle-label {
    font-family: var(--font-family);
    font-weight: 400;
    font-size: 1rem;
    letter-spacing: 1%;
    text-transform: uppercase;
    color: var(--dark);
    transition: color 0.3s ease;
}

.filter-toggle:hover {
    border: 0.0625rem solid var(--dark);
    background: var(--dark);
    color: var(--white);
}

.filter-toggle:hover .filter-toggle-icon {
    fill: var(--white);
}

.filter-toggle:hover .filter-toggle-label {
    color: var(--white);
}


/*
|--------------------------------------------------------------------------
| Products grid
|--------------------------------------------------------------------------
*/

.shop-products .products-grid {
    display: grid;

    grid-template-columns: repeat(3, minmax(0, 1fr));

    column-gap: 1.25rem;
    row-gap: 2.8125rem;
}

.shop-products .products-grid .product-card {
    opacity: 1;
    transform: translateY(0);
}


/*
|--------------------------------------------------------------------------
| Pagination
|--------------------------------------------------------------------------
*/

.shop-pagination {
    margin-top: 4rem;
}

.shop-pagination .page-numbers {
    display: flex;

    align-items: center;
    justify-content: center;

    gap: 0.5rem;

    padding: 0;

    margin: 0;

    list-style: none;
}

.shop-pagination .page-numbers a,
.shop-pagination .page-numbers span {
    display: flex;

    align-items: center;
    justify-content: center;

    width: 2.5rem;
    height: 2.5rem;

    border: 0.0625rem solid var(--light-gray-4);
    border-radius: 0.25rem;

    color: var(--dark);

    text-decoration: none;
    transition: border 0.3s ease, color 0.3s ease, background 0.3s ease;
}

.shop-pagination .page-numbers a:hover,
.shop-pagination .page-numbers span {
    background: var(--dark);
    color: var(--white);
    border-color: var(--dark);
}

.shop-pagination .page-numbers .current {
    background: var(--dark);

    color: var(--white);

    border-color: var(--dark);
}


/*
|--------------------------------------------------------------------------
| Empty
|--------------------------------------------------------------------------
*/

.shop-no-products {
    padding: 5rem 2rem;

    text-align: center;
}

.shop-no-products h3 {
    margin-bottom: 1rem;

    font-size: 2rem;
    font-weight: 400;
}

.shop-no-products p {
    margin-bottom: 2rem;

    color: var(--gray);
}

.shop-filter-button,
.shop-no-products .main-btn {
    align-self: flex-start;
}

.filter-toggle-close {
    display: none;
}

.filter-toggle-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, .5);
    opacity: 0;
    visibility: hidden;
    transition: .3s;
    z-index: 11;
}

@media (max-width: 62.5rem) {
    .shop-layout {
        grid-template-columns: 1fr;
    }

    .shop-sidebar {
        position: fixed;
        top: 0;
        right: -100%;
        width: 25rem;
        height: 100%;
        background-color: var(--white);
        padding: 3.625rem 1.25rem 0rem 1.25rem;
        transition: all 0.3s ease;
        overflow: auto;
        z-index: 3;
    }

    .shop-sidebar.active {
        right: 0;
        z-index: 12;
    }

    .filter-toggle-overlay.active {
        opacity: 1;
        visibility: visible;
    }

    .shop-products-count {
        display: none;
    }

    .filter-toggle {
        display: flex;
        align-items: center;
        gap: 0.25rem;
        padding: 0.5rem 0.75rem;
        border: 0.0625rem solid rgba(65, 64, 62, 0.2);
        border-radius: 0.25rem;
        color: var(--white);
        background: transparent;
        cursor: pointer;
        transition: color 0.3s ease, background 0.3s ease, border 0.3s ease;
    }

    .filter-toggle-close {
        display: block;
        margin-left: auto;
        position: relative;
        width: 1.875rem;
        height: 1.25rem;
        z-index: 14;
    }

    .filter-toggle-close::before, .filter-toggle-close::after {
        content: '';
        background-color: var(--dark);
        position: absolute;
        width: 100%;
        height: 0.125rem;
        left: 0;
        transition: all 0.3s ease 0s;
    }

    .filter-toggle-close span {
        position: absolute;
        background-color: var(--dark);
        left: 0;
        width: 100%;
        height: 0.125rem;
        top: 0.5625rem;
        transition: all 0.3s ease 0s;
    }

    .filter-toggle-close.active::before {
        transform: rotate(45deg);
    }

    .filter-toggle-close.active::after {
        transform: rotate(-45deg);
    }

    .filter-toggle-close.active span {
        transform: scale(0);
    }

    
}


@media (max-width: 48rem) {
    .shop-page {
        margin-bottom: 6.25rem;
    }

    .shop-products .products-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}


@media (max-width: 30rem) {
    .shop-title {
        font-size: 2.5rem;
    }

    .shop-sidebar {
        grid-template-columns: 1fr;
    }

    .shop-products-top {
        align-items: flex-start;

        flex-direction: column;

        gap: 1rem;
    }

    .shop-products .products-grid {
        grid-template-columns: repeat(1, minmax(0, 1fr));
    }
}

@media (max-width: 25rem) {
    .shop-sidebar {
        width: 100%;
    }
}