﻿.products-page {
    direction: rtl;
    font-family: 'Vazirmatn', Tahoma, sans-serif;
    min-height: 80vh;
    padding: 50px 0 80px;
    background: radial-gradient(circle at 5% 5%, rgba(116,39,201,.10), transparent 28%), radial-gradient(circle at 95% 90%, rgba(0,184,117,.10), transparent 28%), #f8f7fa;
}

.products-container {
    width: 92%;
    max-width: 1250px;
    margin: auto;
}

.products-heading {
    text-align: center;
    margin-bottom: 40px;
}

.products-icon {
    width: 68px;
    height: 68px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 15px;
    border-radius: 21px;
    color: #fff;
    font-size: 28px;
    background: linear-gradient(135deg,#7b2bd0,#4f198d);
    box-shadow: 0 12px 30px rgba(116,39,201,.25);
}

.products-heading h1 {
    margin: 0;
    color: #29153c;
    font-size: 32px;
    font-weight: 900;
}

.products-heading p {
    margin: 9px 0 0;
    color: #777;
    font-size: 14px;
}

.heading-line {
    width: 75px;
    height: 4px;
    margin: 16px auto 0;
    border-radius: 20px;
    background: linear-gradient(90deg,#7427c9,#00b875);
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(4,1fr);
    gap: 22px;
}

.product-card {
    overflow: hidden;
    background: #fff;
    border-radius: 22px;
    border: 1px solid rgba(116,39,201,.08);
    box-shadow: 0 10px 30px rgba(40,20,60,.07);
    transition: .25s;
}

    .product-card:hover {
        transform: translateY(-8px);
        box-shadow: 0 20px 45px rgba(40,20,60,.14);
    }

.product-image-link {
    display: block;
    text-decoration: none;
}

.product-image-box {
    position: relative;
    height: 225px;
    padding: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(145deg,#faf9fc,#f4f1f7);
}

.product-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: .35s;
}

.product-card:hover .product-image {
    transform: scale(1.07);
}

.product-badge {
    position: absolute;
    top: 13px;
    right: 13px;
    padding: 6px 11px;
    border-radius: 30px;
    color: #fff;
    background: linear-gradient(135deg,#7427c9,#552095);
    font-size: 10px;
    font-weight: 800;
    z-index: 2;
}

.product-body {
    padding: 18px;
}

.product-title {
    min-height: 52px;
    color: #2b1a36;
    font-size: 15px;
    font-weight: 800;
    line-height: 1.8;
}

.product-price {
    margin: 12px 0 16px;
    color: #00a56a;
    font-size: 19px;
    font-weight: 900;
}

.product-price-unit {
    color: #888;
    font-size: 11px;
    font-weight: 500;
}

.product-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 9px;
}

.product-button {
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    border-radius: 12px;
    text-decoration: none;
    font-family: inherit;
    font-size: 12px;
    font-weight: 800;
    transition: .2s;
}

/* مشاهده محصول */

.details-button {
    color: #fff;
    background: linear-gradient(135deg,#7427c9,#542094);
    box-shadow: 0 7px 18px rgba(116,39,201,.18);
}

    .details-button:hover {
        color: #fff;
        transform: translateY(-2px);
        box-shadow: 0 10px 23px rgba(116,39,201,.28);
    }

/* افزودن به سبد */

.cart-button {
    border: 0;
    color: #fff;
    background: linear-gradient(135deg,#00b875,#008d5a);
    box-shadow: 0 7px 18px rgba(0,184,117,.16);
    cursor: pointer;
}

    .cart-button:hover {
        color: #fff;
        transform: translateY(-2px);
        box-shadow: 0 10px 23px rgba(0,184,117,.28);
    }

@media(max-width:1050px) {

    .products-grid {
        grid-template-columns: repeat(3,1fr);
    }
}

@media(max-width:760px) {

    .products-grid {
        grid-template-columns: repeat(2,1fr);
        gap: 14px;
    }

    .products-heading h1 {
        font-size: 26px;
    }

    .product-image-box {
        height: 175px;
    }

    .product-body {
        padding: 13px;
    }

    .product-title {
        font-size: 13px;
    }

    .product-price {
        font-size: 16px;
    }
}

@media(max-width:450px) {

    .products-container {
        width: 94%;
    }

    .product-image-box {
        height: 150px;
    }

    .product-buttons {
        grid-template-columns: 1fr;
    }
}
