@import url('../../variables.css');


.browse_products_page {
    margin-top: 8px;
}

.browse_products_page .row>* {
    padding: 0;
}

.browser_page_background_image {
    position: fixed;
    right: max(0px, calc(50% - (var(--container-width, 1200px) / 2) - 170px));
    bottom: 0;
    height: 90vh;
    width: auto;
    max-width: 100%;
    object-fit: contain;
    z-index: -1;
    pointer-events: none;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 8px;
    margin: 0 auto;
}

.product-card {
    display: flex;
    height: 130px;
    box-shadow: rgba(0, 0, 0, 0.1) 0px 10px 15px -3px, rgba(0, 0, 0, 0.05) 0px 4px 6px -2px;
    background-color: white;
    text-decoration: none;
    transition: transform 0.2s, box-shadow 0.2s;
}

.product-card:hover {
    transform: translateY(-0.2px);
    box-shadow: 0px 6px 15px rgba(0, 0, 0, 0.2);
}

.product-image {
    width: 140px;
    border-radius: 5px;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 5px;
    mix-blend-mode: multiply;
}

.product-card-text {
    flex: 1;
    display: flex;
    flex-direction: column;
    opacity: 0.9;
    position: relative;
    color: black;
    padding-right: 15px;
    padding-top: 15px;
    text-align: justify;
}

.product-title {
    font-size: 14px;
    margin-bottom: 2px;
}

.product-title:hover {
    color: var(--xinshengGreen);
}

.product-excerpt {
    font-size: 13px;
    line-height: 1.4;
    font-weight: 400;
    opacity: 0.9;
}

.product-card-text .card-function-buttons {
    display: flex;
    justify-content: flex-end;
    position: absolute;
    bottom: 10px;
    right: 10px;
}

.product-card-text .card-function-buttons .add-to-quote,
.product-card-text .card-function-buttons .remove-from-quote {
    color: white;
    border: none;
    border-radius: 2px;
    padding: 4px 8px;
    display: flex;
    align-items: center;
    cursor: pointer;
    font-size: 12px;
    margin: 0;
    gap: 5px;
}

.related-products .product-grid .card-function-buttons {
    right: 20px;
}

.related-products .product-grid .card-function-buttons .add-to-quote,
.related-products .product-grid .card-function-buttons .remove-from-quote {
    padding: 4px 8px !important;
}

.related-products .product-grid .card-function-buttons span {
    font-size: 12px;
}

.card-function-buttons .add-to-quote {
    background-color: var(--xinshengGreen);
}

.card-function-buttons .add-to-quote:hover {
    background-color: #1a5f9c;
}

.card-function-buttons .remove-from-quote {
    background-color: #e74c3c;
    display: none;
}

.card-function-buttons .remove-from-quote:hover {
    background-color: #c0392b;
}

.product-card-text .card-function-buttons img {
    width: 20px;
    height: 20px;
    display: block;
}

.product-card-text .card-function-buttons span {
    font-size: 12px;
    line-height: 1;
}

.card-function-buttons[data-in-quote="true"] .add-to-quote {
    display: none;
}

.card-function-buttons[data-in-quote="true"] .remove-from-quote {
    display: flex;
}

.no-products,
.search-results-info {
    text-align: center;
    margin-top: 20px;
}

.no-products {
    color: #999;
}

.search-results-info {
    background-color: white;
    box-shadow: rgba(0, 0, 0, 0.24) 0px 3px 8px;
    padding: 10px;
}

.search-results-info h2 {
    color: #333;
    font-size: 22px;
    margin-bottom: 10px;
}

.search-results-info p {
    color: #666;
    margin-bottom: 0;
}

.pagination {
    background-color: white;
    border-radius: 5px;
    width: fit-content;
    padding: 5px 60px;
    display: flex;
    justify-content: center;
    margin: 40px auto;
    box-shadow: rgba(0, 0, 0, 0.1) 0px 4px 6px -1px, rgba(0, 0, 0, 0.06) 0px 2px 4px -1px;
}

.pagination a,
.pagination span {
    padding: 8px 15px;
    color: #333;
    text-decoration: none;
    border-radius: 2px;
    transition: all 0.3s;
    font-size: 14px;
    margin: 0 2px;
}

.pagination .next,
.pagination .prev {
    padding: 5px;
    display: flex;
    align-items: center;
}

.pagination .next span,
.pagination .prev span {
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pagination a.next:hover,
.pagination a.prev:hover {
    color: white;
}

.pagination a.next:hover .dashicons,
.pagination a.prev:hover .dashicons {
    color: white !important;
}

.pagination a:hover {
    background-color: var(--xinshengBlue);
    color: white;
}

.pagination .current {
    background: var(--xinshengBlue);
    color: #fff;
    font-weight: var(--siteBoldSize2);
}

.products_layout_wrapper {
    display: flex;
    align-items: flex-start;
    flex-wrap: wrap;
}

/* Filter Column */

.filters_column {
    flex: 1 1 auto;
    max-width: 350px;
    margin-right: 8px;
}

.filters_column .header {
    background-color: white;
    padding: 8px;

}

.filters_column .header h2 {
    font-size: 18px;
    margin-bottom: 0;
}

.filters_column .header .clear-button {
    color: red;
    font-size: 15px;
    text-decoration: none;
    margin-left: 10px;
    margin-right: 10px;

}

.filters_column .header .clear-button:hover {
    color: darkred;
}

.products_column {
    flex: 3 1 0;
    min-width: 300px;
    width: 100%;
}



@media (max-width: 900px) {
    .filters_column {
        max-width: 250px;
    }
}

@media (max-width: 768px) {
    .products_layout_wrapper {
        flex-direction: column;
    }

    .filters_column {
        display: none;
    }

    .products_column {
        max-width: 100%;
    }
}

@media (max-width: 1400px) {
    .product-grid {
        grid-template-columns: repeat(auto-fill, minmax(400px, 1fr));
    }
}

@media (max-width: 800px) and (min-width: 551px) {
    .product-card {
        height: 120px;
    }

    .product-image {
        width: 140px;
    }
}

@media (max-width: 450px) {
    .product-grid {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        margin: 0;
    }

    .product-card {
        flex-direction: column;
        width: 100% !important;
        max-width: 100% !important;
        height: auto;
        box-sizing: border-box;
    }

    .product-image {
        width: 100% !important;
        height: 180px !important;
        border-radius: 8px 8px 0 0;
    }

    .product-image img {
        width: 100%;
        height: 100%;
        object-fit: contain;
    }

    .product-card-text {
        padding: 15px;
        text-align: left;
    }

    .product-title {
        font-size: 16px;
        margin-bottom: 8px;
    }

    .product-excerpt {
        font-size: 14px;
        margin-bottom: 15px;
        line-height: 1.4;
    }

    .card-function-buttons {
        position: static !important;
        justify-content: flex-start;
    }
}