/* ==========================================================================
PET ROYALE - HOME & PRODUCT GRID STYLES (home.css)
اختصاصی صفحه اصلی، آرشیو دسته‌ها و گرید محصولات
========================================================================== */

/* ==========================================================================
۳. کارت‌های محصول و چیدمان فروشگاه (PRODUCT CARDS & SHOP GRID)
شامل: ثبات رنگ در هاور، اصلاح کامل چیدمان قیمت و تخفیف و مخفی‌سازی دکمه خرید گرید
========================================================================== */

/* ۱. بدنه اصلی کارت: سفید خالص حتی در زمان هاور بدون تغییر رنگ کرمی */

/* ۱. بدنه اصلی کارت: سفید خالص بدون پدینگ تا کادر طوسی کاملاً تمام‌عرض و لبه‌به‌لبه قرار گیرد */
.product-grid-item,
.wd-product,
.product-grid-item:hover,
.wd-product:hover {
    background: #FFFFFF !important;
    border-radius: 18px !important;
    border: 1px solid rgba(56, 43, 32, 0.08) !important;
    box-shadow: 0 4px 16px rgba(56, 43, 32, 0.03) !important;
    transition: transform 0.28s ease, box-shadow 0.28s ease !important;
    padding: 0 !important;
    position: relative !important;
    direction: rtl !important;
    text-align: right !important;
    overflow: hidden !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: space-between !important;
    box-sizing: border-box !important;
}

/* هاور فقط شناوری با سایه در دسکتاپ و سیستم‌های دارای نشانگر موس (غیرفعال در تاچ موبایل و تبلت) */
@media (min-width: 1025px) {
.product-grid-item:hover,
.wd-product:hover {
    transform: translateY(-4px) !important;
    box-shadow: 0 10px 24px rgba(56, 43, 32, 0.08) !important;
}

}

.product-grid-item .product-wrapper,
.wd-product .product-wrapper,
.product-grid-item:hover .product-wrapper,
.wd-product:hover .product-wrapper {
    background: transparent !important;
    padding: 0 !important;
    margin: 0 !important;
    border: none !important;
    box-shadow: none !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: space-between !important;
    height: 100% !important;
    width: 100% !important;
    border-radius: inherit !important;
    overflow: hidden !important;
}

/* ۲. قاب تصویر محصول (با فاصله ۸ پیکسلی تمیز از لبه‌ها) */
.wd-product .product-element-top,
.product-grid-item .product-element-top {
    border-radius: 14px !important;
    overflow: hidden !important;
    background: #FAF6EE !important;
    margin: 8px 8px 0 8px !important;
    padding: 0 !important;
    border: 1px solid rgba(243, 233, 215, 0.7) !important;
    position: relative !important;
}

.wd-product .product-element-top img,
.product-grid-item .product-element-top img {
    transition: transform 0.4s ease !important;
}

@media (min-width: 1025px) {
.wd-product:hover .product-element-top img,
.product-grid-item:hover .product-element-top img {
    transform: scale(1.04) !important;
}

}

/* ۳. کادر طوسی عنوان، قیمت و سبد خرید: کاملاً تمام‌عرض (Flush) در پایین کادر محصول و بدون سفیدی در گوشه‌ها */
.product-grid-item .product-element-bottom,
.wd-product .product-element-bottom,
.product-grid-item .product-information,
.wd-product .product-information,
.product-grid-item:hover .product-element-bottom,
.product-grid-item:hover .product-information,
.wd-product:hover .product-information {
    background: #F6F6F8 !important;
    border: none !important;
    border-top: 1px solid rgba(56, 43, 32, 0.04) !important;
    outline: none !important;
    box-shadow: none !important;
    border-radius: 0 !important;
    padding: 10px 12px 12px 12px !important;
    margin: 8px 0 0 0 !important;
    width: 100% !important;
    box-sizing: border-box !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: space-between !important;
    flex-grow: 1 !important;
    overflow: visible !important;
}

/* حذف کامل نشان تخفیف گرد/مستطیلی از بالای عکس در کارت‌های محصول (اسلایدرها و فروشگاه) بدون آسیب به صفحه تکی محصول */
.product-grid-item .product-labels,
.wd-product:not(.single-product) .product-labels,
.product-grid-item .product-element-top .product-labels,
.wd-product:not(.single-product) .product-element-top .product-labels,
.product-grid-item .onsale,
.wd-product:not(.single-product) .onsale,
.product-grid-item .product-label.onsale,
.wd-product:not(.single-product) .product-label.onsale,
.product-grid-item .labels-rectangular,
.wd-product:not(.single-product) .labels-rectangular,
.product-grid-item .labels-rounded,
.wd-product:not(.single-product) .labels-rounded {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
    pointer-events: none !important;
    height: 0 !important;
    width: 0 !important;
    min-height: 0 !important;
    min-width: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
    border: none !important;
}

/* حفظ کامل نشان تخفیف در صفحه اختصاصی محصول */
.single-product .woocommerce-product-gallery .product-labels,
.single-product .woocommerce-product-gallery .onsale,
.single-product-page .woocommerce-product-gallery .product-labels,
.single-product-page .woocommerce-product-gallery .onsale {
    display: flex !important;
    visibility: visible !important;
    opacity: 1 !important;
    pointer-events: auto !important;
}

/* ۴. عنوان محصول (رفع کامل نصفه شدن و پنهان شدن متن پشت قیمت) */
.product-grid-item .wd-product-header,
.wd-product .wd-product-header {
    display: block !important;
    width: 100% !important;
    position: static !important;
}

.product-grid-item .wd-entities-title,
.wd-product:not(.single-product) .wd-entities-title,
.product-grid-item h3.wd-entities-title,
.wd-product:not(.single-product) h3.wd-entities-title {
    font-family: 'dana', 'Dana', sans-serif !important;
    color: #382B20 !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    line-height: 1.35 !important;
    text-align: right !important;
    direction: rtl !important;
    height: 35px !important;
    min-height: 35px !important;
    max-height: 35px !important;
    display: -webkit-box !important;
    -webkit-line-clamp: 2 !important;
    -webkit-box-orient: vertical !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    word-break: break-word !important;
    margin: 0 0 6px 0 !important;
    clip-path: inset(0) !important;
}

.product-grid-item .wd-entities-title a,
.wd-product .wd-entities-title a,
.product-grid-item .product-title a,
.wd-product .product-title a {
    font-family: inherit !important;
    color: #382B20 !important;
    font-size: inherit !important;
    font-weight: inherit !important;
    line-height: inherit !important;
    display: -webkit-box !important;
    -webkit-line-clamp: 2 !important;
    -webkit-box-orient: vertical !important;
    overflow: hidden !important;
    max-height: 100% !important;
    text-decoration: none !important;
}

.product-grid-item .wd-entities-title a:hover,
.product-grid-item .product-title a:hover,
.wd-product .wd-entities-title a:hover {
    color: #0E3A2F !important;
}

/* ۵. موقعیت و استایل کپسولی ستاره امتیاز در تمام سایزها: گوشه پایین سمت چپ عکس محصول بدون تغییر جزئیات */
.product-grid-item .product-element-top,
.wd-product .product-element-top,
.product-grid-item .wd-product-thumb,
.wd-product .wd-product-thumb {
    position: relative !important;
}

/* نمایش قطعی ستاره امتیاز در تمام اندازه‌ها (دسکتاپ، تبلت و موبایل) */
html body .product-grid-item .star-rating,
html body .wd-product .star-rating,
.product-grid-item .star-rating,
.wd-product .star-rating,
.product-grid-item:hover .star-rating,
.wd-product:hover .star-rating,
.product-grid-item.wd-hovered .star-rating,
.wd-product.wd-hovered .star-rating {
    display: inline-flex !important;
    visibility: visible !important;
    opacity: 1 !important;
}

/* حالت ۱: قرارگیری درون قاب عکس در تمام سایزها (دسکتاپ، تبلت و موبایل) - کاملاً فلت، هماهنگ و بدون پس‌زمینه */
html body .product-grid-item .product-element-top .star-rating,
html body .wd-product .product-element-top .star-rating,
html body .product-grid-item .wd-product-thumb .star-rating,
html body .wd-product .wd-product-thumb .star-rating,
.product-grid-item .product-element-top .star-rating,
.wd-product .product-element-top .star-rating,
.product-grid-item .wd-product-thumb .star-rating,
.wd-product .wd-product-thumb .star-rating {
    position: absolute !important;
    bottom: 8px !important;
    left: 8px !important;
    right: auto !important;
    top: auto !important;
    z-index: 25 !important;
    margin: 0 !important;
    display: inline-flex !important;
    visibility: visible !important;
    opacity: 1 !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 3px !important;
    background: transparent !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    border: none !important;
    box-shadow: none !important;
    border-radius: 0 !important;
    padding: 0 !important;
    direction: ltr !important;
    pointer-events: none !important;
    line-height: 1 !important;
    font-size: 11.5px !important;
    font-weight: 700 !important;
    color: #382B20 !important;
}

/* حالت ۲: پشتیبان CSS اختصاصی فقط زمانی که ستاره درون بخش پایینی باشد (بدون تداخل با قاب عکس) */
.product-grid-item .product-element-bottom,
.wd-product .product-element-bottom,
.product-grid-item .product-information,
.wd-product .product-information,
.product-grid-item:hover .product-element-bottom,
.product-grid-item:hover .product-information,
.wd-product:hover .product-information {
    position: relative !important;
    overflow: visible !important;
    z-index: 10 !important;
}

.product-grid-item .wd-product-header,
.wd-product .wd-product-header {
    position: static !important;
    overflow: visible !important;
}

html body .product-grid-item .product-element-bottom .star-rating,
html body .wd-product .product-element-bottom .star-rating,
html body .product-grid-item .product-element-bottom .wd-product-header .star-rating,
html body .wd-product .product-element-bottom .wd-product-header .star-rating,
.product-grid-item .product-element-bottom .star-rating,
.wd-product .product-element-bottom .star-rating,
.product-grid-item .product-element-bottom .wd-product-header .star-rating,
.wd-product .product-element-bottom .wd-product-header .star-rating {
    position: absolute !important;
    bottom: calc(100% + 14px) !important;
    left: 14px !important;
    right: auto !important;
    top: auto !important;
    z-index: 25 !important;
    margin: 0 !important;
    display: inline-flex !important;
    visibility: visible !important;
    opacity: 1 !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 3px !important;
    background: transparent !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    border: none !important;
    box-shadow: none !important;
    border-radius: 0 !important;
    padding: 0 !important;
    direction: ltr !important;
    pointer-events: none !important;
    line-height: 1 !important;
    font-size: 11.5px !important;
    font-weight: 700 !important;
    color: #382B20 !important;
}

.product-grid-item .star-rating,
.wd-product .star-rating {
    font-size: 11.5px !important;
    font-weight: 700 !important;
    color: #382B20 !important;
    direction: ltr !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    line-height: 1 !important;
    vertical-align: middle !important;
}

/* رفع کامل پایین بودن ستاره و هم‌تراز کردن دقیق افقی با عدد ۴.۵ در کارت‌های محصول (اسلایدرها و فروشگاه) */
.product-grid-item .star-rating.wd-style-simple:after,
.wd-product:not(.single-product) .star-rating.wd-style-simple:after,
.product-grid-item .star-rating.wd-style-simple::before,
.wd-product:not(.single-product) .star-rating.wd-style-simple::before,
.product-grid-item .star-rating.wd-style-simple .wd-star,
.wd-product:not(.single-product) .star-rating.wd-style-simple .wd-star {
    color: #FAB515 !important;
    font-size: 13px !important;
    line-height: 1 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    position: relative !important;
    top: -2.5px !important;

/* جبران شیفت عمودی پیش‌فرض قالب وودمارت و تراز دقیق با مرکز رقم */
    margin: 0 !important;
    padding: 0 !important;
    vertical-align: middle !important;
}

/* هم‌راستایی کامل ظرف عدد در کارت‌های محصول */
.product-grid-item .star-rating.wd-style-simple>div,
.wd-product:not(.single-product) .star-rating.wd-style-simple>div,
.product-grid-item .star-rating.wd-style-simple>span,
.wd-product:not(.single-product) .star-rating.wd-style-simple>span {
    display: inline-flex !important;
    align-items: center !important;
    line-height: 1 !important;
    vertical-align: middle !important;
    font-size: 11.5px !important;
    font-weight: 700 !important;
    color: #382B20 !important;
}

/* ۵. متغیرها و سوئیچها (راستچین و کپسولی) */
.wd-swatches-grid,
.wd-swatches-product,
.product-grid-item .wd-swatches-grid {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 5px !important;
    justify-content: flex-start !important;
    direction: rtl !important;
    margin: 3px 0 5px 0 !important;
    padding: 0 !important;
}

.wd-swatches-grid .wd-swatch,
.wd-swatches-product .wd-swatch,
.woodmart-swatch {
    font-family: 'dana', 'Dana', sans-serif !important;
    background: #FFFFFF !important;
    color: #4A3324 !important;
    border: 1px solid rgba(217, 164, 65, 0.4) !important;
    border-radius: 6px !important;
    font-size: 10.5px !important;
    font-weight: 600 !important;
    padding: 2px 7px !important;
    min-width: unset !important;
    height: auto !important;
    line-height: 1.5 !important;
    transition: all 0.2s ease !important;
}

.wd-swatches-grid .wd-swatch:hover,
.wd-swatches-grid .wd-swatch.wd-active,
.woodmart-swatch:hover,
.woodmart-swatch.active-swatch {
    background: #0E3A2F !important;
    color: #F3E9D7 !important;
    border-color: #0E3A2F !important;
}

/* ۶. ردیف قیمت، درصد تخفیف و دکمه سبد خرید (ثابت و بدون پرش عمودی در زمان هاور و لمس) */
.product-grid-item .wrap-price,
.wd-product .wrap-price,
.product-grid-item .swap-wrapp,
.wd-product .swap-wrapp,
.wd-product.wd-hover-alt .swap-wrapp,
.wd-product.wd-hover-alt:hover .swap-wrapp,
.wd-product.wd-hover-alt:not(.wd-variation-active) .swap-wrapp,
.wd-product.wd-hover-alt:not(.wd-variation-active):hover .swap-wrapp,
.product-grid-item:hover .swap-wrapp,
.wd-product:hover .swap-wrapp,
.product-grid-item:active .swap-wrapp,
.wd-product:active .swap-wrapp,
.product-grid-item.wd-hovered .swap-wrapp,
.wd-product.wd-hovered .swap-wrapp {
    width: 100% !important;
    height: auto !important;
    min-height: unset !important;
    max-height: none !important;
    overflow: visible !important;
    transform: none !important;
    transition: none !important;
    margin-block: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    display: flex !important;
    flex-wrap: nowrap !important;
    align-items: center !important;
}

/* خنثی‌سازی کامل جابه‌جایی و جهش عمودی قیمت و دکمه سبد خرید در هاور و لمس قالب وودمارت */
.product-grid-item .swap-elements,
.wd-product .swap-elements,
.wd-product.wd-hover-alt .swap-elements,
.wd-product.wd-hover-alt:hover .swap-elements,
.wd-product.wd-hover-alt:not(.wd-variation-active) .swap-elements,
.wd-product.wd-hover-alt:not(.wd-variation-active):hover .swap-elements,
.wd-product.wd-hover-alt:not(.wd-variation-active):is(.purchasable, .product-type-grouped):hover .swap-elements,
.product-grid-item:hover .swap-elements,
.wd-product:hover .swap-elements,
.product-grid-item:active .swap-elements,
.wd-product:active .swap-elements,
.product-grid-item.wd-hovered .swap-elements,
.wd-product.wd-hovered .swap-elements {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    align-items: center !important;
    justify-content: space-between !important;
    direction: rtl !important;
    width: 100% !important;
    margin-top: auto !important;
    margin-bottom: 0 !important;
    padding: 0 !important;
    gap: 6px !important;
    box-sizing: border-box !important;
    overflow: visible !important;
    transform: none !important;
    transition: none !important;
}

/* پایداری کامل و جلوگیری از هرگونه جابه‌جایی یا پرش قیمت و دکمه سبد خرید در هاور */
.product-grid-item .price,
.wd-product .price,
.product-grid-item:hover .price,
.wd-product:hover .price,
.wd-product.wd-hover-alt:not(.wd-variation-active) .price,
.wd-product.wd-hover-alt:not(.wd-variation-active):is(.purchasable, .product-type-grouped):hover .price,
.product-grid-item .wd-add-btn,
.wd-product .wd-add-btn,
.product-grid-item:hover .wd-add-btn,
.wd-product:hover .wd-add-btn,
.wd-product.wd-hover-alt:not(.wd-variation-active) .wd-add-btn,
.wd-product.wd-hover-alt:not(.wd-variation-active):is(.purchasable, .product-type-grouped):hover .wd-add-btn,
.product-grid-item.wd-hovered .price,
.wd-product.wd-hovered .price,
.product-grid-item.wd-hovered .wd-add-btn,
.wd-product.wd-hovered .wd-add-btn,
.product-grid-item:hover .product-element-bottom,
.wd-product:hover .product-element-bottom,
.product-grid-item.wd-hovered .product-element-bottom,
.wd-product.wd-hovered .product-element-bottom {
    transform: none !important;
    -webkit-transform: none !important;
    transition: none !important;
}

/* ۷. دکمه آیکون سبد خرید: مربع با گوشه‌های گرد، پایین سمت راست، همیشه ثابت در دسکتاپ و موبایل */
.product-grid-item .wd-add-btn,
.wd-product .wd-add-btn,
.product-grid-item .woodmart-add-btn,
.wd-product .woodmart-add-btn {
    order: 1 !important;

/* در جهت راست‌به‌چپ در سمت راست قرار می‌گیرد */
    position: relative !important;
    z-index: 25 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: auto !important;
    height: auto !important;
    margin: 0 !important;
    padding: 0 !important;
    opacity: 1 !important;
    visibility: visible !important;
    max-height: none !important;
    pointer-events: auto !important;
    transform: none !important;
    flex-shrink: 0 !important;
    box-sizing: border-box !important;
}

.product-grid-item .wd-add-btn a.button,
.wd-product .wd-add-btn a.button,
.product-grid-item .wd-add-btn a,
.wd-product .wd-add-btn a {
    position: relative !important;
    z-index: 30 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 38px !important;
    height: 38px !important;
    min-width: 38px !important;
    max-width: 38px !important;
    padding: 0 !important;
    margin: 0 !important;
    background: #0E3A2F !important;
    color: #FFFFFF !important;
    border-radius: 10px !important;
    border: 1px solid rgba(217, 164, 65, 0.45) !important;
    box-shadow: 0 3px 8px rgba(14, 58, 47, 0.2) !important;
    text-decoration: none !important;
    cursor: pointer !important;
    outline: none !important;
    box-sizing: border-box !important;
    transition: all 0.22s cubic-bezier(0.4, 0, 0.2, 1) !important;
    direction: rtl !important;
    touch-action: manipulation !important;
    -webkit-tap-highlight-color: transparent !important;
    pointer-events: auto !important;
}

/* هاور دکمه سبد خرید: طلایی با آیکون سبز تیره بدون بالا رفتن و کاملا ثابت */
.product-grid-item .wd-add-btn a.button:hover,
.wd-product .wd-add-btn a.button:hover,
.product-grid-item .wd-add-btn a:hover,
.wd-product .wd-add-btn a:hover {
    background: #D9A441 !important;
    color: #0E3A2F !important;
    border-color: #D9A441 !important;
    box-shadow: 0 4px 12px rgba(217, 164, 65, 0.4) !important;
    transform: none !important;
}

.product-grid-item .wd-add-btn a.button:active,
.wd-product .wd-add-btn a.button:active {
    transform: scale(0.93) !important;
}

/* مخفی‌سازی کامل دکمه اضافی «مشاهده سبد خرید» ووکامرس که بعد از کلیک افزوده می‌شود */
.product-grid-item .added_to_cart,
.wd-product .added_to_cart,
.product-grid-item .wd-add-btn .added_to_cart,
.wd-product .wd-add-btn .added_to_cart,
.product-grid-item .swap-elements .added_to_cart,
.wd-product .swap-elements .added_to_cart,
a.added_to_cart.wc-forward {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
    width: 0 !important;
    height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    pointer-events: none !important;
}

/* مخفی‌سازی کامل متن دکمه سبد خرید و صفربندی فونت */
.product-grid-item .wd-add-btn a,
.wd-product .wd-add-btn a,
.product-grid-item .wd-add-btn a.button,
.wd-product .wd-add-btn a.button {
    font-size: 0 !important;
    color: #FFFFFF !important;
}

/* جلوگیری قطعی از تولید آیکون دوم اضافی روی تگ a */
.product-grid-item .wd-add-btn a::before,
.wd-product .wd-add-btn a::before,
.product-grid-item .wd-add-btn a.button::before,
.wd-product .wd-add-btn a.button::before {
    content: none !important;
    display: none !important;
}

.product-grid-item .wd-add-btn a > span:not(.wd-action-icon),
.wd-product .wd-add-btn a > span:not(.wd-action-icon),
.product-grid-item .wd-add-btn .wd-action-text,
.wd-product .wd-add-btn .wd-action-text {
    display: none !important;
    font-size: 0 !important;
}

/* آیکون سبد خرید اصلی وودمارت با رنگ سفید براق و کاملاً تک */
.product-grid-item .wd-add-btn .wd-action-icon,
.wd-product .wd-add-btn .wd-action-icon {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 18px !important;
    height: 18px !important;
    margin: 0 !important;
    padding: 0 !important;
    color: #FFFFFF !important;
    flex-shrink: 0 !important;
}

.product-grid-item .wd-add-btn .wd-action-icon::before,
.wd-product .wd-add-btn .wd-action-icon::before {
    content: '' !important;
    display: inline-block !important;
    width: 17px !important;
    height: 17px !important;
    background-color: #FFFFFF !important;
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='9' cy='21' r='1'/%3E%3Ccircle cx='20' cy='21' r='1'/%3E%3Cpath d='M1 1h4l2.68 13.39a2 2 0 0 0 2 1.61h9.72a2 2 0 0 0 2-1.61L23 6H6'/%3E%3C/svg%3E") no-repeat center / contain !important;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='9' cy='21' r='1'/%3E%3Ccircle cx='20' cy='21' r='1'/%3E%3Cpath d='M1 1h4l2.68 13.39a2 2 0 0 0 2 1.61h9.72a2 2 0 0 0 2-1.61L23 6H6'/%3E%3C/svg%3E") no-repeat center / contain !important;
    transition: background-color 0.22s ease !important;
}

/* هاور دکمه سبد خرید: رنگ آیکون به سبز تیره برند تغییر کند */
.product-grid-item .wd-add-btn a:hover .wd-action-icon::before,
.wd-product .wd-add-btn a:hover .wd-action-icon::before,
.product-grid-item .wd-add-btn a.button:hover .wd-action-icon::before,
.wd-product .wd-add-btn a.button:hover .wd-action-icon::before {
    background-color: #0E3A2F !important;
}

/* انیمیشن چرخش روان آیکون لودینگ */
@keyframes pr-spin {
0% { transform: rotate(0deg); }
100% { transform: rotate(360deg); }
}

/* ۱. وضعیت در حال افزودن (لودینگ) با نمایش اسپینر سفید در مرکز دکمه */
.product-grid-item .wd-add-btn a.loading,
.wd-product .wd-add-btn a.loading,
.product-grid-item .wd-add-btn a.button.loading,
.wd-product .wd-add-btn a.button.loading {
    opacity: 1 !important;
    pointer-events: none !important;
    position: relative !important;
}

.product-grid-item .wd-add-btn a.loading .wd-action-icon,
.wd-product .wd-add-btn a.loading .wd-action-icon,
.product-grid-item .wd-add-btn a.button.loading .wd-action-icon,
.wd-product .wd-add-btn a.button.loading .wd-action-icon {
    opacity: 0 !important;
    visibility: hidden !important;
}

.product-grid-item .wd-add-btn a.loading::after,
.wd-product .wd-add-btn a.loading::after,
.product-grid-item .wd-add-btn a.button.loading::after,
.wd-product .wd-add-btn a.button.loading::after {
    content: '' !important;
    display: block !important;
    position: absolute !important;
    top: 50% !important;
    left: 50% !important;
    width: 17px !important;
    height: 17px !important;
    margin-top: -8.5px !important;
    margin-left: -8.5px !important;
    border: 2px solid rgba(255, 255, 255, 0.25) !important;
    border-top-color: #FFFFFF !important;
    border-radius: 50% !important;
    animation: pr-spin 0.65s linear infinite !important;
    z-index: 50 !important;
    box-sizing: border-box !important;
}

/* ۲. حالت افزوده شده: حفظ پس‌زمینه سبز یشمی لوکس برند (#0E3A2F) و نمایش تیک سفید تایید */
.product-grid-item .wd-add-btn a.added,
.wd-product .wd-add-btn a.added,
.product-grid-item .wd-add-btn a.button.added,
.wd-product .wd-add-btn a.button.added {
    background: #0E3A2F !important;
    border: 1px solid #D9A441 !important;
    border-color: #D9A441 !important;
    color: #FFFFFF !important;
    box-shadow: 0 3px 8px rgba(14, 58, 47, 0.2) !important;
    position: relative !important;
}

.product-grid-item .wd-add-btn a.added:hover,
.wd-product .wd-add-btn a.added:hover,
.product-grid-item .wd-add-btn a.button.added:hover,
.wd-product .wd-add-btn a.button.added:hover {
    background: #D9A441 !important;
    border-color: #D9A441 !important;
    color: #0E3A2F !important;
    box-shadow: 0 4px 12px rgba(217, 164, 65, 0.4) !important;
}

.product-grid-item .wd-add-btn a.added .wd-action-icon,
.wd-product .wd-add-btn a.added .wd-action-icon,
.product-grid-item .wd-add-btn a.button.added .wd-action-icon,
.wd-product .wd-add-btn a.button.added .wd-action-icon {
    opacity: 0 !important;
    visibility: hidden !important;
}

.product-grid-item .wd-add-btn a.added::after,
.wd-product .wd-add-btn a.added::after,
.product-grid-item .wd-add-btn a.button.added::after,
.wd-product .wd-add-btn a.button.added::after {
    content: '' !important;
    display: block !important;
    position: absolute !important;
    top: 50% !important;
    left: 50% !important;
    width: 17px !important;
    height: 17px !important;
    margin-top: -8.5px !important;
    margin-left: -8.5px !important;
    background-color: #FFFFFF !important;
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'%3E%3C/polyline%3E%3C/svg%3E") no-repeat center / contain !important;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'%3E%3C/polyline%3E%3C/svg%3E") no-repeat center / contain !important;
    z-index: 50 !important;
    transition: background-color 0.22s ease !important;
}

.product-grid-item .wd-add-btn a.added:hover::after,
.wd-product .wd-add-btn a.added:hover::after,
.product-grid-item .wd-add-btn a.button.added:hover::after,
.wd-product .wd-add-btn a.button.added:hover::after {
    background-color: #0E3A2F !important;
}

.product-grid-item .wd-add-btn .wd-check-icon,
.wd-product .wd-add-btn .wd-check-icon,
.product-grid-item .wd-add-btn a.button.added .wd-check-icon,
.wd-product .wd-add-btn a.button.added .wd-check-icon {
    display: none !important;
}

/* حذف کامل بخش «سفارش داده شده»، «آیتم‌های موجود» و نوار پیشرفت از کارت‌های محصول */
.product-grid-item .wd-stock-progress-bar,
.wd-product .wd-stock-progress-bar,
.product-grid-item .woodmart-stock-progress-bar,
.wd-product .woodmart-stock-progress-bar,
.product-grid-item .stock-info,
.wd-product .stock-info,
.product-grid-item .total-sold,
.wd-product .total-sold,
.product-grid-item .current-stock,
.wd-product .current-stock,
.product-grid-item .progress-area,
.wd-product .progress-area,
.product-grid-item .wd-product-stock,
.wd-product .wd-product-stock,
.product-grid-item [class*="stock-progress"],
.wd-product [class*="stock-progress"],
.product-grid-item [class*="total-sold"],
.wd-product [class*="total-sold"],
.product-grid-item [class*="current-stock"],
.wd-product [class*="current-stock"] {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
    height: 0 !important;
    max-height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    border: none !important;
    pointer-events: none !important;
    overflow: hidden !important;
}

/* ۸. بخش قیمت و درصد تخفیف: سمت چپ ردیف */
.product-grid-item .price,
.wd-product .price,
.product-grid-item:hover .price,
.wd-product:hover .price {
    order: 2 !important;

/* در جهت راست‌به‌چپ در سمت چپ قرار می‌گیرد */
    font-family: 'dana', 'Dana', sans-serif !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: flex-end !important;

/* چسبیدن به لبه چپ کادر */
    justify-content: center !important;
    text-align: left !important;
    direction: rtl !important;
    line-height: 1.25 !important;
    margin: 0 !important;
    padding: 0 !important;
    flex-grow: 1 !important;
    opacity: 1 !important;
    visibility: visible !important;
}

/* محفظه قیمت خط‌خورده قبلی و بج درصد تخفیف */
.pr-price-old-wrap {
    display: inline-flex !important;
    align-items: center !important;
    gap: 6px !important;
    direction: rtl !important;
    margin: 0 0 3px 0 !important;
    order: 1 !important;
}

/* سطر قیمت خط‌خورده قبلی - رنگ خاکستری استاندارد و یکدست */
.product-grid-item .price del,
.wd-product .price del,
.pr-price-old-wrap del,
.product .price del {
    color: #718096 !important; /* رنگ خاکستری شکیل و استاندارد */
    font-size: 11.5px !important;
    font-weight: 500 !important;
    text-decoration: line-through !important;
    -webkit-text-decoration-line: line-through !important;
    text-decoration-line: line-through !important;
    text-decoration-color: #718096 !important;
    -webkit-text-decoration-color: #718096 !important;
    text-decoration-thickness: 1.5px !important;
    opacity: 1 !important;
    display: inline-flex !important;
    align-items: center !important;
    margin: 0 !important;
    order: 2 !important;
}

.product-grid-item .price del .amount,
.wd-product .price del .amount,
.pr-price-old-wrap del .amount,
.product .price del .amount,
.product-grid-item .price del bdi,
.wd-product .price del bdi,
.pr-price-old-wrap del bdi,
.product .price del bdi {
    font-family: 'dana', 'Dana', sans-serif !important;
    color: #718096 !important;
    font-size: 11.5px !important;
    font-weight: 500 !important;
    text-decoration: line-through !important;
    -webkit-text-decoration-line: line-through !important;
    text-decoration-line: line-through !important;
    text-decoration-color: #718096 !important;
    -webkit-text-decoration-color: #718096 !important;
    text-decoration-thickness: 1.5px !important;
}

/* حذف کامل تکرار کلمه تومان از قیمت خط‌خورده کارت‌های محصول */
.product-grid-item .price del .woocommerce-Price-currencySymbol,
.wd-product .price del .woocommerce-Price-currencySymbol,
.pr-price-old-wrap del .woocommerce-Price-currencySymbol,
.price del .woocommerce-Price-currencySymbol {
    display: none !important;
}

/* نشان درصد تخفیف اختصاصی پپت رویال (طرح دیجی‌کالایی پیل‌شکل لوکس و بولد) */
.pr-discount-badge {
    order: -1 !important;
    margin-left: 6px !important;
    margin-right: 0 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    background: #EF4444 !important;
    background-color: #EF4444 !important;
    color: #FFFFFF !important;
    -webkit-text-fill-color: #FFFFFF !important;
    font-family: 'dana', 'Dana', sans-serif !important;
    font-size: 11px !important;
    font-weight: 800 !important;
    padding: 1.5px 7px !important;
    border-radius: 12px !important;
    line-height: 1.3 !important;
    letter-spacing: -0.2px !important;
    direction: ltr !important;
    text-decoration: none !important;
    box-shadow: 0 2px 6px rgba(239, 68, 68, 0.28) !important;
    flex-shrink: 0 !important;
    margin: 0 !important;
}

/* قیمت اصلی محصول یا قیمت با تخفیف جدید (سبز تیره برند، بولد و درشت) */
.product-grid-item .price>.amount,
.wd-product .price>.amount,
.product-grid-item .price ins,
.wd-product .price ins {
    color: #0E3A2F !important;
    font-size: 14.5px !important;
    font-weight: 800 !important;
    text-decoration: none !important;
    display: inline-flex !important;
    align-items: baseline !important;
    margin: 0 !important;
    line-height: 1.2 !important;
    order: 2 !important;
}

.product-grid-item .price ins .amount,
.wd-product .price ins .amount,
.product-grid-item .price>.amount,
.wd-product .price>.amount {
    font-family: 'dana', 'Dana', sans-serif !important;
    color: #0E3A2F !important;
    font-size: 14.5px !important;
    font-weight: 800 !important;
    text-decoration: none !important;
    display: inline-block !important;
}

.product-grid-item .price .woocommerce-Price-currencySymbol,
.wd-product .price .woocommerce-Price-currencySymbol,
.price .woocommerce-Price-currencySymbol,
.woocommerce-Price-currencySymbol {
    font-family: 'dana', 'Dana', Tahoma, sans-serif !important;
    font-size: 11px !important;
    font-weight: 600 !important;
    opacity: 0.85 !important;
    margin-right: 3px !important;
    display: inline-block !important;
    vertical-align: baseline !important;
    letter-spacing: 0 !important;
}

/* یکسان‌سازی قیمت محصولات متغیر: مخفی‌سازی قیمت دوم و خط تیره و نمایش فقط یک قیمت واحد */
.product-grid-item .price > .amount ~ .amount,
.wd-product .price > .amount ~ .amount,
.product-grid-item .price > .woocommerce-Price-amount ~ .woocommerce-Price-amount,
.wd-product .price > .woocommerce-Price-amount ~ .woocommerce-Price-amount,
.product-grid-item .price > span.amount:nth-of-type(2),
.wd-product .price > span.amount:nth-of-type(2) {
    display: none !important;
}

/* حذف خط تیره متنی بین دو قیمت در محصولات متغیر */
.product-grid-item .price:has(> .amount ~ .amount),
.wd-product .price:has(> .amount ~ .amount),
.product-grid-item .price:has(> .woocommerce-Price-amount ~ .woocommerce-Price-amount),
.wd-product .price:has(> .woocommerce-Price-amount ~ .woocommerce-Price-amount) {
    font-size: 0 !important;
}

/* بهینه‌سازی ریسپانسیو دکمه سبد خرید و قیمت در موبایل */
@media (max-width: 768px) {
.product-grid-item .wd-entities-title,
.wd-product:not(.single-product) .wd-entities-title,
.product-grid-item h3.wd-entities-title,
.wd-product:not(.single-product) h3.wd-entities-title {
    font-size: 12px !important;
    line-height: 1.35 !important;
    height: 32.5px !important;
    min-height: 32.5px !important;
    max-height: 32.5px !important;
    margin-bottom: 6px !important;
    clip-path: inset(0) !important;
}

.product-grid-item .wd-add-btn,
.wd-product .wd-add-btn {
    position: relative !important;
    z-index: 25 !important;
}

.product-grid-item .wd-add-btn a.button,
.wd-product .wd-add-btn a.button,
.product-grid-item .wd-add-btn a,
.wd-product .wd-add-btn a {
    width: 33px !important;
    height: 33px !important;
    min-width: 33px !important;
    max-width: 33px !important;
    border-radius: 8px !important;
    position: relative !important;
    z-index: 30 !important;
    touch-action: manipulation !important;
    -webkit-tap-highlight-color: transparent !important;
}

.product-grid-item .wd-add-btn .wd-action-icon,
.wd-product .wd-add-btn .wd-action-icon {
    width: 15px !important;
    height: 15px !important;
}

.product-grid-item .wd-add-btn .wd-action-icon::before,
.wd-product .wd-add-btn .wd-action-icon::before {
    width: 14px !important;
    height: 14px !important;
}

.product-grid-item .price ins,
.wd-product .price ins,
.product-grid-item .price>.amount,
.wd-product .price>.amount,
.product-grid-item .price ins .amount,
.wd-product .price ins .amount {
    font-size: 13px !important;
}

.product-grid-item .price del,
.wd-product .price del,
.product-grid-item .price del .amount,
.wd-product .price del .amount {
    font-size: 10px !important;
}

.pr-discount-badge {
    font-size: 9.5px !important;
    padding: 1px 4px !important;
    border-radius: 4px !important;
}

}

/* ۸. آیکونهای شناور دسکتاپ */
.wd-product .wd-buttons,
.wd-product .woodmart-buttons {
    background: #F3E9D7 !important;
    border: 1px solid rgba(255, 255, 255, 0.8) !important;
    border-radius: 10px !important;
    box-shadow: 0 4px 12px rgba(56, 43, 32, 0.1) !important;
    padding: 2px !important;
}

.wd-product .wd-buttons a:hover,
.wd-product .woodmart-buttons a:hover {
    background-color: #D9A441 !important;
    color: #FFFFFF !important;
}

/* ۱. مخفی کردن کامل آیکون ذرهبین (نمایش سریع) */
.quick-view-btn,
.wd-quick-view-btn,
.wd-action-btn.wd-quick-view-btn {
    display: none !important;
}

/* ۲. بالا آمدن آیکون پسندیدهها (علاقهمندی) در بالاترین نقطه */
.wd-buttons {
    top: 10px !important;
}

.wd-wishlist-btn,
.wishlist-btn,
.wd-action-btn.wd-wishlist-btn {
    display: flex !important;
    margin: 0 !important;
}

/* ۱. رنگ آیکون قلب در حالت عادی (سبز رویال) */
.wd-wishlist-btn>a,
.wd-wishlist-btn>a:before,
.wd-wishlist-btn>a svg,
.wd-wishlist-btn>a svg path {
    color: rgb(106, 127, 95) !important;
    fill: rgb(106, 127, 95) !important;
    stroke: rgb(106, 127, 95) !important;
}

/* ۲. رنگ آیکون قلب در حالت هاور (کاملاً سفید و شفاف) */
.wd-wishlist-btn>a:hover,
.wd-wishlist-btn>a:hover:before,
.wd-wishlist-btn>a:hover svg,
.wd-wishlist-btn>a:hover svg path,
.wd-action-btn.wd-wishlist-btn>a:hover * {
    color: #ffffff !important;
    fill: #ffffff !important;
    stroke: #ffffff !important;
    opacity: 1 !important;
    visibility: visible !important;
}

/* تنظیم ابعاد ثابت و گوشههای گرد دکمه علاقهمندی */
.wd-wishlist-btn>a,
.wishlist-btn>a,
.wd-action-btn.wd-wishlist-btn>a {
    width: 36px !important;
    height: 36px !important;
    min-width: 36px !important;
    min-height: 36px !important;
    border-radius: 12px !important;

/* گوشههای گرد شکیل */
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 0 !important;
    overflow: hidden !important;
    box-sizing: border-box !important;
}

/* حفظ کامل گوشههای گرد و ابعاد در زمان هاور */
.wd-wishlist-btn>a:hover,
.wishlist-btn>a:hover,
.wd-action-btn.wd-wishlist-btn>a:hover {
    border-radius: 12px !important;

/* ثابت ماندن گوشههای گرد */
}

/* اندازه آیکون قلب داخل دکمه */
.wd-wishlist-btn>a svg,
.wd-wishlist-btn>a:before {
    font-size: 16px !important;
    width: 16px !important;
    height: 16px !important;
    margin: 0 !important;
}

/* بهینه‌سازی CLS بدون استفاده از content-visibility جهت جلوگیری از پرش هدر و لگ اسکرول */

/* --- PRODUCT CARDS IN MOBILE / TABLET --- */

/* ==========================================================================
۷.۹ ثبات کامل کارت‌های محصول و اسلایدرها در موبایل و تبلت (@media (max-width: 1024px))
جلوگیری قطعی از رشد ارتفاع به سمت پایین، پرش کادرها و لگ هنگام کشیدن با دست
========================================================================== */
@media (max-width: 1024px) {

/* ۱. ثبات کامل کارت محصول در لمس، هاور و کلیک (بدون تغییر ارتفاع یا پرش عمودی) */
.product-grid-item,
.wd-product,
.product-grid-item:hover,
.wd-product:hover,
.product-grid-item:active,
.wd-product:active,
.product-grid-item:focus,
.wd-product:focus,
.product-grid-item.wd-hovered,
.wd-product.wd-hovered {
    transform: none !important;
    -webkit-transform: none !important;
    box-shadow: 0 4px 16px rgba(56, 43, 32, 0.03) !important;
    transition: none !important;
    box-sizing: border-box !important;
}

/* ۲. بدنه محفظه داخلی کارت محصول: ارتفاع ۱۰۰٪ بدون کوچکترین بیرون‌زدگی */
.product-grid-item .product-wrapper,
.wd-product .product-wrapper,
.product-grid-item:hover .product-wrapper,
.wd-product:hover .product-wrapper,
.product-grid-item:active .product-wrapper,
.wd-product:active .product-wrapper,
.product-grid-item.wd-hovered .product-wrapper,
.wd-product.wd-hovered .product-wrapper {
    height: 100% !important;
    max-height: 100% !important;
    overflow: hidden !important;
    transform: none !important;
    transition: none !important;
}

/* ۳. قاب تصویر محصول و جلوگیری از زوم شدن عکس هنگام لمس دست */
.wd-product .product-element-top,
.product-grid-item .product-element-top,
.wd-product:hover .product-element-top,
.product-grid-item:hover .product-element-top,
.wd-product:active .product-element-top,
.product-grid-item:active .product-element-top,
.wd-product.wd-hovered .product-element-top,
.product-grid-item.wd-hovered .product-element-top {
    transform: none !important;
    transition: none !important;
}

.wd-product .product-element-top img,
.product-grid-item .product-element-top img,
.wd-product:hover .product-element-top img,
.product-grid-item:hover .product-element-top img,
.wd-product:active .product-element-top img,
.product-grid-item:active .product-element-top img,
.wd-product.wd-hovered .product-element-top img,
.product-grid-item.wd-hovered .product-element-top img {
    transform: none !important;
    -webkit-transform: none !important;
    transition: none !important;
    user-select: none !important;
    -webkit-user-select: none !important;
    -webkit-user-drag: none !important;
}

/* ۴. عنوان محصول: دقیقاً دو خط با ارتفاع قفل شده در لمس و هاور */
.product-grid-item .wd-entities-title,
.wd-product .wd-entities-title,
.product-grid-item h3.wd-entities-title,
.wd-product h3.wd-entities-title,
.product-grid-item .product-title,
.product-grid-item:hover .wd-entities-title,
.wd-product:hover .wd-entities-title,
.product-grid-item:active .wd-entities-title,
.wd-product:active .wd-entities-title,
.product-grid-item.wd-hovered .wd-entities-title,
.wd-product.wd-hovered .wd-entities-title {
    height: 35px !important;
    min-height: 35px !important;
    max-height: 35px !important;
    display: -webkit-box !important;
    -webkit-line-clamp: 2 !important;
    -webkit-box-orient: vertical !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
}

/* ۵. ردیف قیمت و دکمه سبد خرید: در یک خط افقی بدون شکستن به دو خط یا ستونی شدن */
.product-grid-item .wrap-price,
.wd-product .wrap-price,
.product-grid-item .swap-wrapp,
.wd-product .swap-wrapp,
.product-grid-item:hover .swap-wrapp,
.wd-product:hover .swap-wrapp,
.product-grid-item:active .swap-wrapp,
.wd-product:active .swap-wrapp,
.product-grid-item.wd-hovered .swap-wrapp,
.wd-product.wd-hovered .swap-wrapp,
.product-grid-item .swap-elements,
.wd-product .swap-elements,
.product-grid-item:hover .swap-elements,
.wd-product:hover .swap-elements,
.product-grid-item:active .swap-elements,
.wd-product:active .swap-elements,
.product-grid-item.wd-hovered .swap-elements,
.wd-product.wd-hovered .swap-elements {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    align-items: center !important;
    justify-content: space-between !important;
    min-height: 38px !important;
    height: 38px !important;
    max-height: 38px !important;
    transform: none !important;
    transition: none !important;
}

/* ۶. مخفی‌سازی کامل هرگونه المان اضافه که با هاور یا لمس فعال می‌شود و باعث رشد ارتفاع می‌شود */
.product-grid-item .hover-content,
.wd-product .hover-content,
.product-grid-item .wd-more-desc,
.wd-product .wd-more-desc,
.product-grid-item .fade-in-block,
.wd-product .fade-in-block,
.product-grid-item .hover-mask,
.wd-product .hover-mask,
.product-grid-item .content-product-imagin,
.wd-product .content-product-imagin,
.product-grid-item .wd-quick-shop-2,
.wd-product .wd-quick-shop-2,
.product-grid-item .product-labels,
.wd-product:not(.single-product) .product-labels,
.product-grid-item .onsale,
.wd-product:not(.single-product) .onsale {
    display: none !important;
    height: 0 !important;
    max-height: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
    overflow: hidden !important;
    opacity: 0 !important;
    visibility: hidden !important;
}

/* حذف انحنای اضافی کادر پایینی در تبلت و موبایل تا هیچ پس‌زمینه سفیدی در گوشه‌ها نمایان نشود */
.product-grid-item .product-element-bottom,
.wd-product .product-element-bottom,
.product-grid-item:hover .product-element-bottom,
.wd-product:hover .product-element-bottom,
.product-grid-item:active .product-element-bottom,
.wd-product:active .product-element-bottom,
.product-grid-item.wd-hovered .product-element-bottom,
.wd-product.wd-hovered .product-element-bottom,
.product-grid-item .product-information,
.wd-product .product-information {
    border-radius: 0 !important;
    margin-bottom: 0 !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
}

/* ۷. ثبات اسلایدها و کروسل‌های وودمارت در هنگام درگ دست و جلوگیری از لگ */
.wd-carousel-container .wd-carousel-item,
.wd-products-element .wd-carousel-item,
.products .wd-carousel-item {
    height: auto !important;
    align-self: stretch !important;
}

.wd-carousel-container .wd-carousel-item .wd-product,
.wd-carousel-container .wd-carousel-item .product-grid-item,
.wd-products-element .wd-carousel-item .wd-product,
.wd-products-element .wd-carousel-item .product-grid-item {
    height: 100% !important;
}

.wd-carousel,
.wd-carousel-wrap,
.wd-carousel-container {
    touch-action: pan-y pinch-zoom !important;
    -webkit-overflow-scrolling: touch !important;
}

}

/* --- CATEGORY ARCHIVE DESCRIPTION --- */

/* ==========================================================
۱۹. استایل لوکس توضیحات دسته‌بندی محصولات (مشابه توضیحات محصول)
(Woodmart / WooCommerce Category Archive Description Card)
========================================================== */
.tax-product_cat .term-description,
.tax-product_cat .woocommerce-products-header__title + .term-description,
.archive.woocommerce .term-description,
.woocommerce-products-header .term-description,
.woodmart-shop-head .term-description,
.woodmart-archive-shop .term-description,
.woodmart-category-description,
.shop-loop-head .term-description {
    background: #FFFFFF !important;
    border: 1px solid #ECE7DE !important;
    border-radius: 18px !important;
    padding: 24px 28px !important;
    margin: 18px auto 26px auto !important;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.03) !important;
    line-height: 1.9 !important;
    color: #4A4A4A !important;
    font-size: 13.5px !important;
    font-family: 'Dana', sans-serif !important;
    box-sizing: border-box !important;
    width: 100% !important;
    max-width: 1200px !important;
    position: relative !important;
    direction: rtl !important;
    text-align: right !important;
}

/* عنوان‌های داخل توضیحات دسته‌بندی */
.tax-product_cat .term-description h1,
.tax-product_cat .term-description h2,
.tax-product_cat .term-description h3,
.tax-product_cat .term-description h4,
.archive.woocommerce .term-description h2,
.archive.woocommerce .term-description h3,
.woodmart-category-description h2,
.woodmart-category-description h3 {
    font-family: 'Dana', sans-serif !important;
    font-size: 17px !important;
    font-weight: 800 !important;
    color: #1A202C !important;
    margin-top: 6px !important;
    margin-bottom: 14px !important;
    display: flex !important;
    align-items: center !important;
    gap: 10px !important;
    direction: rtl !important;
    text-align: right !important;
}

/* شاخص رنگی طلایی-سبز کنار عنوان مشابه تب توضیحات محصول */
.tax-product_cat .term-description h1::before,
.tax-product_cat .term-description h2::before,
.tax-product_cat .term-description h3::before,
.tax-product_cat .term-description h4::before,
.archive.woocommerce .term-description h2::before,
.archive.woocommerce .term-description h3::before,
.woodmart-category-description h2::before,
.woodmart-category-description h3::before {
    content: '' !important;
    display: inline-block !important;
    width: 4px !important;
    height: 18px !important;
    background: #6A7F5F !important;
    border-radius: 4px !important;
    flex-shrink: 0 !important;
}

/* پاراگراف‌های داخل توضیحات دسته‌بندی */
.tax-product_cat .term-description p,
.archive.woocommerce .term-description p,
.woodmart-category-description p {
    margin-bottom: 14px !important;
    line-height: 1.95 !important;
    color: #4A4A4A !important;
    font-size: 13.5px !important;
}

.tax-product_cat .term-description p:last-child,
.archive.woocommerce .term-description p:last-child,
.woodmart-category-description p:last-child {
    margin-bottom: 0 !important;
}

/* متن‌های بولد */
.tax-product_cat .term-description strong,
.archive.woocommerce .term-description strong,
.woodmart-category-description strong {
    color: #1A202C !important;
    font-weight: 700 !important;
}

/* لیست‌های بالت‌دار داخل توضیحات دسته‌بندی */
.tax-product_cat .term-description ul,
.archive.woocommerce .term-description ul,
.woodmart-category-description ul {
    list-style: none !important;
    padding-right: 0 !important;
    padding-left: 0 !important;
    margin: 12px 0 16px 0 !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 10px !important;
}

.tax-product_cat .term-description ul li,
.archive.woocommerce .term-description ul li,
.woodmart-category-description ul li {
    position: relative !important;
    padding-right: 22px !important;
    line-height: 1.85 !important;
    color: #4A4A4A !important;
    font-size: 13.5px !important;
}

/* آیکون نقطه یا تیک سبز لوکس برای بالت‌ها */
.tax-product_cat .term-description ul li::before,
.archive.woocommerce .term-description ul li::before,
.woodmart-category-description ul li::before {
    content: '' !important;
    position: absolute !important;
    right: 4px !important;
    top: 9px !important;
    width: 7px !important;
    height: 7px !important;
    background: #6A7F5F !important;
    border-radius: 50% !important;
    box-shadow: 0 0 0 3px rgba(106, 127, 95, 0.15) !important;
}

/* لینک‌های داخل توضیحات دسته‌بندی */
.tax-product_cat .term-description a,
.archive.woocommerce .term-description a,
.woodmart-category-description a {
    color: #6A7F5F !important;
    text-decoration: underline !important;
    font-weight: 600 !important;
    transition: color 0.2s ease !important;
}

.tax-product_cat .term-description a:hover,
.archive.woocommerce .term-description a:hover,
.woodmart-category-description a:hover {
    color: #56684D !important;
}

/* انتقال دقیق ستاره امتیاز به گوشه پایین کادر عکس در کارت‌ها */
.product-grid-item .wd-product-header .star-rating,
.wd-product .wd-product-header .star-rating {
    position: absolute !important;
    top: -30px !important;
    left: 10px !important;
    right: auto !important;
    bottom: auto !important;
    z-index: 20 !important;
}


/* ==========================================================================
بهینه‌سازی و اصلاح نهایی استایل تخفیف و ستاره در کارت‌های محصول (طرح دو سطری استاندارد)
========================================================================== */

/* کادر اصلی قیمت در کارت‌ها: دو سطر عمودی منظم */
.product-grid-item .price,
.wd-product .price {
    display: flex !important;
    flex-direction: column !important;
    align-items: flex-end !important;
    justify-content: center !important;
    direction: rtl !important;
    text-align: right !important;
    line-height: 1.25 !important;
    margin: 0 !important;
}

/* سطر ۱ (بالا): محفظه قیمت قدیمی و بج درصد تخفیف */
.product-grid-item .price .pr-price-old-wrap,
.wd-product .price .pr-price-old-wrap,
.pr-price-old-wrap {
    display: inline-flex !important;
    flex-direction: row !important;
    direction: rtl !important;
    align-items: center !important;
    justify-content: flex-end !important;
    gap: 6px !important;
    margin: 0 0 2px 0 !important;
    order: 1 !important;
}

/* قرارگیری قطعی نشان درصد تخفیف در سمت راست عدد قیمت قدیمی */
.product-grid-item .pr-discount-badge,
.wd-product .pr-discount-badge,
.pr-discount-badge {
    order: 1 !important;
    background: #EF4444 !important;
    background-color: #EF4444 !important;
    color: #FFFFFF !important;
    -webkit-text-fill-color: #FFFFFF !important;
    font-family: 'dana', 'Dana', sans-serif !important;
    font-size: 11px !important;
    font-weight: 800 !important;
    padding: 1.5px 7px !important;
    border-radius: 12px !important;
    line-height: 1.3 !important;
    direction: ltr !important;
    box-shadow: 0 2px 6px rgba(239, 68, 68, 0.28) !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    margin: 0 !important;
    text-decoration: none !important;
}

/* اعمال خط‌خوردگی خاکستری استاندارد و قطعی روی قیمت قبلی در سمت چپ نشان تخفیف */
.product-grid-item .price del,
.wd-product .price del,
.pr-price-old-wrap del,
.product .price del,
.product-grid-item .price del .amount,
.wd-product .price del .amount,
.pr-price-old-wrap del .amount,
.product .price del .amount,
.product-grid-item .price del bdi,
.wd-product .price del bdi,
.pr-price-old-wrap del bdi,
.product .price del bdi {
    order: 2 !important;
    font-family: 'dana', 'Dana', sans-serif !important;
    color: #718096 !important; /* رنگ خاکستری شکیل */
    font-size: 12px !important;
    font-weight: 500 !important;
    text-decoration: line-through !important;
    -webkit-text-decoration-line: line-through !important;
    text-decoration-line: line-through !important;
    text-decoration-color: #718096 !important;
    -webkit-text-decoration-color: #718096 !important;
    text-decoration-thickness: 1.5px !important;
    opacity: 1 !important;
    display: inline-flex !important;
    align-items: center !important;
    margin: 0 !important;
}

/* حذف کلمه تومان از قیمت خط‌خورده در کارت‌ها */
.product-grid-item .price del .woocommerce-Price-currencySymbol,
.wd-product .price del .woocommerce-Price-currencySymbol,
.pr-price-old-wrap del .woocommerce-Price-currencySymbol {
    display: none !important;
}

/* سطر ۲ (پایین): قیمت نهایی فروش */
.product-grid-item .price ins,
.wd-product .price ins {
    order: 2 !important;
    font-family: 'dana', 'Dana', sans-serif !important;
    color: #0E3A2F !important;
    font-size: 14.5px !important;
    font-weight: 800 !important;
    text-decoration: none !important;
    margin: 0 !important;
}

/* مخفی‌سازی هرگونه نشان تخفیف تکراری سرگردان مستقیم زیر قیمت */
.product-grid-item .price > .pr-discount-badge,
.wd-product .price > .pr-discount-badge {
    display: none !important;
}

/* ۴. بالا بردن قطعی ستاره امتیاز به داخل قاب عکس در کارت‌های محصول */
.product-grid-item .wd-product-header .star-rating,
.wd-product .wd-product-header .star-rating,
.product-grid-item .product-element-bottom .star-rating,
.wd-product .product-element-bottom .star-rating {
    position: absolute !important;
    top: -55px !important;
    left: 10px !important;
    right: auto !important;
    bottom: auto !important;
    z-index: 25 !important;
    margin: 0 !important;
}
