/* کانتینر اصلی کارت */
.kima-product-card {
    background: #fff;
    border: 1px solid #f0f0f1;
    border-radius: 0; /* عکس دوم لبه‌های تیزی دارد، اگر گرد می‌خواهید ۸ پیکسل بدهید */
    padding: 15px;
    height: 100%;
    display: flex;
    flex-direction: column;
    transition: all 0.3s ease;
    position: relative;
}

.kima-product-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

/* بخش تصویر */
.product_img_wrap {
    position: relative;
    margin-bottom: 12px;
}

.kima-product-card .product_img {
    height: 200px; /* ارتفاع ثابت تصویر */
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.kima-product-card .product_img img {
    max-height: 100%;
    width: auto;
    object-fit: contain;
}

/* بج تخفیف صورتی مشابه عکس */
.onsale-badge {
    position: absolute;
    top: 0;
    right: 0;
    background-color: #ef4f83; /* رنگ دقیق مشابه عکس */
    color: #fff;
    font-size: 12px;
    font-weight: bold;
    padding: 2px 8px;
    border-radius: 20px;
    z-index: 2;
}

/* عنوان محصول */
.kima-product-card .product_title {
    font-size: 14px;
    line-height: 24px;
    height: 48px; /* دو خطی کردن عنوان */
    overflow: hidden;
    margin-bottom: 12px;
    text-align: right;
}

.kima-product-card .product_title a {
    color: #3f4064;
    text-decoration: none;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

/* قیمت‌ها */
.product_price_wrapper {
    margin-top: auto; /* چسباندن قیمت به پایین */
    text-align: left; /* در عکس دوم قیمت‌ها سمت چپ هستند */
    direction: lcl;
}

.custom-price-display {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

/* اصلاح استایل پیش‌فرض ووکامرس برای قیمت */
.kima-product-card .price {
    display: flex;
    flex-direction: row-reverse;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    font-size: 16px;
    font-weight: 700;
    color: #3f4064;
}

.kima-product-card .price del {
    font-size: 13px;
    color: #c1c2c5;
    font-weight: 400;
    margin-left: 8px;
}

.kima-product-card .price ins {
    text-decoration: none;
}

/* امتیازدهی */
.product_rating {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    margin-top: 8px;
}

.star_rating {
    width: 70px;
    height: 14px;
    background: url('data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0Ij48cGF0aCBmaWxsPSIjZGRkIiBkPSJNMTIgMS43MmwyLjc4IDUuNjMgNi4yMi45LTQuNSA0LjM4IDEuMDYgNi4xOUwxMiAxNi43N2wtNS41NiAyLjkyIDEuMDYtNi4xOS00LjUtNC4zOCA2LjIyLS45TDEyIDEuNzJ6Ii8+PC9zdmc+') repeat-x;
    background-size: 14px;
    position: relative;
}

.product_rate {
    height: 100%;
    background: url('data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0Ij48cGF0aCBmaWxsPSIjZTRkMDAwIiBkPSJNMTIgMS43MmwyLjc4IDUuNjMgNi4yMi45LTQuNSA0LjM4IDEuMDYgNi4xOUwxMiAxNi43N2wtNS41NiAyLjkyIDEuMDYtNi4xOS00LjUtNC4zOCA2LjIyLS45TDEyIDEuNzJ6Ii8+PC9zdmc+') repeat-x;
    background-size: 14px;
    position: absolute;
    top: 0;
    right: 0;
}

.rating_count {
    font-size: 11px;
    color: #999;
    margin-right: 5px;
}

/* حذف دکمه خرید در اسلایدر برای شباهت به نمونه */
.kima-product-card .add_to_cart {
    display: none;
}

/* ریسپانسیو موبایل */
@media (max-width: 768px) {
    .kima-product-card .product_img {
        height: 140px;
    }
    .kima-product-card .product_title {
        font-size: 12px;
        height: 40px;
    }
}
