/**
 * Shahin | WooCommerce UI
 */

:root {
    --shahin-qty-border: #e3e6ec;
    --shahin-qty-bg: #ffffff;
    --shahin-qty-btn-bg: #f5f6fa;
    --shahin-qty-btn-hover: #e67e22;
    --shahin-qty-text: #2c3e50;
    --shahin-qty-radius: 10px;
    --shahin-qty-size: 38px;
    --shahin-sale-bg: #e74c3c;
    --shahin-sale-text: #ffffff;
}

/* ------------------------------------------------------------------
 * فیلد تعداد
 * --------------------------------------------------------------- */

.woocommerce .quantity.shahin-qty,
.woocommerce-page .quantity.shahin-qty,
.quantity.shahin-qty,
.quantity:has(> .shahin-qty-btn) {
    display: inline-flex;
    align-items: stretch;
    direction: ltr;
    background: var(--shahin-qty-bg);
    border: 1px solid var(--shahin-qty-border);
    border-radius: var(--shahin-qty-radius);
    overflow: hidden;
    width: auto;
    max-width: 100%;
    vertical-align: middle;
}

.quantity .shahin-qty-btn {
    flex: 0 0 var(--shahin-qty-size);
    width: var(--shahin-qty-size);
    min-width: var(--shahin-qty-size);
    min-height: var(--shahin-qty-size);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    margin: 0;
    border: 0;
    background: var(--shahin-qty-btn-bg);
    color: var(--shahin-qty-text);
    font-size: 18px;
    font-weight: 700;
    line-height: 1;
    cursor: pointer;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
    transition: background-color 0.18s ease, color 0.18s ease;
}

.quantity .shahin-qty-btn:hover:not(:disabled),
.quantity .shahin-qty-btn:focus-visible:not(:disabled) {
    background: var(--shahin-qty-btn-hover);
    color: #fff;
    outline: none;
}

.quantity .shahin-qty-btn:active:not(:disabled) {
    transform: scale(0.94);
}

.quantity .shahin-qty-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

/* اگر یک صفحه‌ساز کنترل تعداد را دوباره تزریق کرد، دومی نمایش داده نشود. */
.quantity .shahin-qty-minus ~ .shahin-qty-minus,
.quantity .shahin-qty-plus ~ .shahin-qty-plus {
    display: none !important;
}

.quantity.shahin-qty input.qty,
.quantity:has(> .shahin-qty-btn) input.qty {
    flex: 1 1 auto;
    width: 52px;
    min-width: 44px;
    min-height: var(--shahin-qty-size);
    padding: 0 4px;
    margin: 0;
    border: 0;
    border-left: 1px solid var(--shahin-qty-border);
    border-right: 1px solid var(--shahin-qty-border);
    border-radius: 0;
    background: transparent;
    color: var(--shahin-qty-text);
    font-family: inherit;
    font-size: 15px;
    font-weight: 700;
    text-align: center;
    box-shadow: none;
    -moz-appearance: textfield;
    appearance: textfield;
}

.quantity.shahin-qty input.qty:focus,
.quantity:has(> .shahin-qty-btn) input.qty:focus {
    outline: none;
    box-shadow: none;
}

.quantity input.qty::-webkit-outer-spin-button,
.quantity input.qty::-webkit-inner-spin-button {
    -webkit-appearance: none;
    appearance: none;
    margin: 0;
}

.quantity.hidden,
.quantity.hidden .shahin-qty-btn {
    display: none !important;
}

/* هم‌ترازییی با دکمه افزودن به سبد در صفحه محصول */
.woocommerce div.product form.cart .quantity.shahin-qty {
    margin-right: 0;
    margin-left: 8px;
}

.woocommerce table.cart td.product-quantity .quantity.shahin-qty,
.woocommerce-cart table.cart td.product-quantity .quantity.shahin-qty {
    margin: 0 auto;
}

/* ------------------------------------------------------------------
 *  تعداد + افزودن به سبد در آرشیو محصولات 
 * --------------------------------------------------------------- */

.shahin-loop-cart {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 8px;
}

.shahin-loop-cart .quantity.shahin-qty--loop {
    --shahin-qty-size: 34px;
    flex: 0 0 auto;
}

.shahin-loop-cart .quantity.shahin-qty--loop input.qty {
    width: 44px;
    font-size: 14px;
}

.shahin-loop-cart > .button,
.shahin-loop-cart > a.button {
    margin: 0 !important;
    flex: 1 1 auto;
    text-align: center;
    white-space: nowrap;
}

.shahin-loop-cart > a.added_to_cart {
    flex: 1 1 100%;
    margin: 0;
    font-size: 13px;
    text-align: center;
}

.woocommerce ul.products li.product .shahin-loop-cart a.button {
    margin-top: 0;
}

/* ------------------------------------------------------------------
 * برچسب درصد تخفیف
 * --------------------------------------------------------------- */

.woocommerce ul.products li.product,
.woocommerce div.product .woocommerce-product-gallery,
.woocommerce .product_thumbnail {
    position: relative;
}

.woocommerce span.onsale.shahin-onsale,
.woocommerce-page span.onsale.shahin-onsale,
span.onsale.shahin-onsale {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: absolute;
    top: 12px;
    left: 12px;
    right: auto;
    bottom: auto;
    min-width: 56px;
    min-height: 56px;
    width: auto;
    height: auto;
    padding: 8px 12px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--shahin-sale-bg, #e74c3c) 0%, var(--shahin-sale-bg2, #b03a2e) 100%);
    color: var(--shahin-sale-text, #fff);
    font-family: inherit;
    line-height: 1.1;
    direction: rtl;
    z-index: 9;
    margin: 0;
    box-shadow:
        0 6px 16px rgba(0,0,0,0.28),
        0 0 0 3px rgba(255,255,255,0.35),
        inset 0 2px 4px rgba(255,255,255,0.35),
        inset 0 -8px 14px rgba(0,0,0,0.18);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

span.onsale.shahin-onsale:hover {
    transform: scale(1.07) rotate(-4deg);
}

/* موقعیت برچسب حراج (قابل تنظیم از پنل ابزارها) */
span.onsale.shahin-onsale.shahin-onsale--pos-top-left {
    top: 12px !important;
    left: 12px !important;
    right: auto !important;
    bottom: auto !important;
}

span.onsale.shahin-onsale.shahin-onsale--pos-top-right {
    top: 12px !important;
    right: 12px !important;
    left: auto !important;
    bottom: auto !important;
}

span.onsale.shahin-onsale.shahin-onsale--pos-bottom-left {
    bottom: 12px !important;
    left: 12px !important;
    top: auto !important;
    right: auto !important;
}

span.onsale.shahin-onsale.shahin-onsale--pos-bottom-right {
    bottom: 12px !important;
    right: 12px !important;
    top: auto !important;
    left: auto !important;
}

/* افکت حلقه ضربان‌دار */
.shahin-onsale--fx-pulse::after {
    content: "";
    position: absolute;
    inset: -3px;
    border-radius: inherit;
    border: 2px solid var(--shahin-sale-bg, #e74c3c);
    animation: shahinOnsaleRing 1.6s ease-out infinite;
    pointer-events: none;
}

@keyframes shahinOnsaleRing {
    0%   { opacity: 0.8; transform: scale(1); }
    100% { opacity: 0;   transform: scale(1.45); }
}

/* افکت برق لامع */
.shahin-onsale--fx-shine {
    overflow: hidden;
}

.shahin-onsale--fx-shine::before {
    content: "";
    position: absolute;
    top: -10%;
    bottom: -10%;
    width: 55%;
    left: -80%;
    background: linear-gradient(100deg, transparent, rgba(255,255,255,0.55), transparent);
    transform: skewX(-20deg);
    animation: shahinOnsaleShine 2.2s ease-in-out infinite;
    pointer-events: none;
}

@keyframes shahinOnsaleShine {
    0%        { left: -80%; }
    60%, 100% { left: 130%; }
}

/* افکت شناور */
.shahin-onsale--fx-float {
    animation: shahinOnsaleFloat 2.4s ease-in-out infinite;
}

@keyframes shahinOnsaleFloat {
    0%, 100% { transform: translateY(0); }
    50%      { transform: translateY(-4px); }
}

@media (prefers-reduced-motion: reduce) {
    .shahin-onsale--fx-pulse::after,
    .shahin-onsale--fx-shine::before,
    .shahin-onsale--fx-float {
        animation: none;
    }
}

.woocommerce div.product .woocommerce-product-gallery span.onsale.shahin-onsale {
    min-width: 62px;
    min-height: 62px;
}

.shahin-onsale__value {
    font-size: 16px;
    font-weight: 900;
    white-space: nowrap;
    text-shadow: 0 1px 2px rgba(0,0,0,0.25);
}

.shahin-onsale__value bdi {
    direction: ltr;
    unicode-bidi: isolate;
}

.shahin-onsale__text {
    font-size: 10px;
    font-weight: 700;
    opacity: 0.9;
    letter-spacing: 0.5px;
}

.shahin-onsale--variable {
    border-radius: 24px !important;
}

.shahin-onsale--variable .shahin-onsale__value {
    font-size: 13px;
}

/* ------------------------------------------------------------------
 * موبایل
 * --------------------------------------------------------------- */

@media screen and (max-width: 480px) {
    .quantity.shahin-qty {
        --shahin-qty-size: 40px;
    }

    .shahin-loop-cart {
        gap: 6px;
    }

    .shahin-loop-cart .quantity.shahin-qty--loop {
        --shahin-qty-size: 36px;
    }

    .shahin-loop-cart > .button,
    .shahin-loop-cart > a.button {
        flex: 1 1 100%;
    }

    span.onsale.shahin-onsale {
        min-width: 44px;
        min-height: 44px;
    }
}

/* ------------------------------------------------------------------
 * شکل‌های مختلف برچسب تخفیف
 * --------------------------------------------------------------- */

span.onsale.shahin-onsale.shahin-onsale--rounded {
    border-radius: 12px !important;
}

span.onsale.shahin-onsale.shahin-onsale--square {
    border-radius: 6px !important;
}

.shahin-onsale__amount {
    font-size: 10px;
    opacity: 0.85;
    margin-top: 2px;
}

.shahin-onsale__amount .woocommerce-Price-amount {
    font-size: inherit;
    color: inherit;
}

/* ------------------------------------------------------------------
 * ویژگی‌های سفارشی محصول (فرانت)
 * --------------------------------------------------------------- */

.shahin-product-attrs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 16px;
    margin: 12px 0;
    padding: 14px 16px;
    background: #f9f9f9;
    border-radius: 10px;
    border: 1px solid #eef0f5;
}

.shahin-attr-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
}

.shahin-attr-label {
    font-weight: 700;
    color: #555;
}

.shahin-attr-value {
    color: #2c3e50;
}

.shahin-color-swatch {
    display: inline-block;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    border: 2px solid rgba(0,0,0,0.12);
    vertical-align: middle;
    flex-shrink: 0;
}

.shahin-color-swatch--md {
    width: 18px;
    height: 18px;
}

.shahin-color-code {
    font-size: 13px;
    color: #7f8c8d;
    direction: ltr;
}

.shahin-attrs-table {
    width: 100%;
    border-collapse: collapse;
}

.shahin-attrs-table th,
.shahin-attrs-table td {
    padding: 8px 12px;
    text-align: right;
    border-bottom: 1px solid #eef0f5;
    font-size: 14px;
}

.shahin-attrs-table th {
    width: 35%;
    font-weight: 700;
    color: #555;
    background: #f9f9f9;
}

/* ------------------------------------------------------------------
 * سلکتور تنوع محصول (Shahin Swatches)
 * دراپ‌داون‌های پیش‌فرض به دکمه/سواچ رنگی تبدیل می‌شوند؛
 * خود سلکت در DOM می‌ماند تا موتور ووکامرس کار کند.
 * --------------------------------------------------------------- */

:root {
    --shahin-swatch-accent: var(--dg-secondary, #e67e22);
    --shahin-swatch-border: #e3e6ec;
    --shahin-swatch-text: #2c3e50;
    --shahin-swatch-radius: 12px;
    --shahin-swatch-danger: #dc2626;
    --shahin-swatch-success: #15803d;
}

/* پنهان‌سازی کامل سلکت اصلی (موتور ووکامرس فقط مقدارش را می‌خواند؛
   تکنیک clip در بعضی مرورگرها فلش نیتیو سلکت را رسم می‌کند، پس display:none) */
select.shahin-has-swatches {
    display: none !important;
}

/* اگر افزونه‌ای سلکت را با select2/selectWoo تزئین کرده، نسخه تزئینی هم پنهان شود */
select.shahin-has-swatches ~ .select2-container,
select.shahin-has-swatches ~ .select2,
select.shahin-has-swatches ~ .selectwoo-container {
    display: none !important;
}

.shahin-swatches {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 8px;
}

.shahin-swatch {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 42px;
    padding: 8px 16px;
    margin: 0;
    border: 2px solid var(--shahin-swatch-border);
    border-radius: var(--shahin-swatch-radius);
    background: #fff;
    color: var(--shahin-swatch-text);
    font-family: inherit;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.4;
    cursor: pointer;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
    transition:
        border-color 0.18s ease,
        background-color 0.18s ease,
        color 0.18s ease,
        box-shadow 0.18s ease,
        transform 0.18s ease,
        opacity 0.18s ease;
}

.shahin-swatch:hover:not(.is-disabled) {
    border-color: #c3cbd6;
    transform: translateY(-1px);
    box-shadow: 0 4px 10px rgba(44, 62, 80, 0.08);
}

.shahin-swatch:focus-visible {
    outline: 2px solid var(--shahin-swatch-accent);
    outline-offset: 2px;
}

.shahin-swatch:active:not(.is-disabled) {
    transform: translateY(0) scale(0.97);
}

/* حالت انتخاب‌شده */
.shahin-swatch.is-selected {
    border-color: var(--shahin-swatch-accent);
    background: rgba(230, 126, 34, 0.08);
    color: var(--shahin-swatch-text);
    box-shadow: 0 6px 14px rgba(230, 126, 34, 0.16);
}

.shahin-swatch.is-selected::after {
    content: "";
    position: absolute;
    top: -7px;
    inset-inline-start: -7px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background-color: var(--shahin-swatch-accent);
    background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='3.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 12.5l5.2 5.2L20 6.5'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: center;
    background-size: 10px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.28);
}

/* نقطه رنگ برای ویژگی‌های رنگی */
.shahin-swatch--color {
    padding-inline-start: 10px;
}

.shahin-swatch__dot {
    flex: 0 0 auto;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--swatch-color, #cbd5e1);
    border: 1px solid rgba(0, 0, 0, 0.14);
    box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.55);
    position: relative;
}

/* حالت ناموجود / نامعتبر */
.shahin-swatch.is-disabled {
    opacity: 0.42;
    cursor: not-allowed;
}

.shahin-swatch.is-disabled .shahin-swatch__text {
    text-decoration: line-through;
}

.shahin-swatch.is-disabled .shahin-swatch__dot::after {
    content: "";
    position: absolute;
    left: 50%;
    top: -3px;
    bottom: -3px;
    width: 2px;
    background: var(--shahin-swatch-danger);
    transform: translateX(-50%) rotate(45deg);
    border-radius: 2px;
}

/* گروه ناقص (کاربر بدون انتخاب روی خرید زده) */
.shahin-swatches.is-missing .shahin-swatch {
    border-color: #fca5a5;
}

.shahin-swatches.shahin-shake {
    animation: shahinSwatchShake 0.45s ease;
}

@keyframes shahinSwatchShake {
    0%, 100% { transform: translateX(0); }
    20%      { transform: translateX(5px); }
    40%      { transform: translateX(-5px); }
    60%      { transform: translateX(4px); }
    80%      { transform: translateX(-4px); }
}

/* پیام خطای انتخاب تنوع */
.shahin-variation-error {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0 0 14px;
    padding: 12px 16px;
    background: #fef2f2;
    border: 1px solid #fecaca;
    border-inline-start: 4px solid var(--shahin-swatch-danger);
    border-radius: 10px;
    color: #b91c1c;
    font-size: 14px;
    font-weight: 600;
}

.shahin-variation-error__icon {
    flex: 0 0 22px;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: var(--shahin-swatch-danger);
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 13px;
}

/* نوار خلاصه انتخاب کاربر */
.shahin-variation-summary {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px 16px;
    margin: 0 0 14px;
    padding: 10px 16px;
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-radius: 10px;
    color: var(--shahin-swatch-success);
    font-size: 13.5px;
}

.shahin-variation-summary__label {
    font-weight: 800;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.shahin-variation-summary__label::before {
    content: "";
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background-color: var(--shahin-swatch-success);
    background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='3.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 12.5l5.2 5.2L20 6.5'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: center;
    background-size: 9px;
}

.shahin-variation-summary__item b {
    font-weight: 700;
}

/* باکس قیمت/موجودی تنوع انتخاب‌شده */
.woocommerce div.product form.variations_form .single_variation,
.woocommerce-page div.product form.variations_form .single_variation {
    padding: 14px 18px;
    margin: 0 0 16px;
    background: #fff;
    border: 1px solid #eef0f5;
    border-radius: 14px;
    box-shadow: 0 2px 10px rgba(44, 62, 80, 0.05);
}

.woocommerce div.product .single_variation .price {
    font-size: 1.35em;
    font-weight: 900;
    color: var(--dg-primary, #2c3e50);
    margin: 0 0 4px;
}

.woocommerce div.product .woocommerce-variation-availability .stock.in-stock {
    color: var(--shahin-swatch-success);
    font-weight: 700;
}

.woocommerce div.product .woocommerce-variation-availability .stock.out-of-stock {
    color: var(--shahin-swatch-danger);
    font-weight: 700;
}

.woocommerce div.product .woocommerce-variation-description {
    font-size: 14px;
    color: #475569;
    margin-top: 6px;
}

/* جدول ویژگی‌ها و لینک پاک‌سازی */
.woocommerce div.product form.cart table.variations th.label,
.woocommerce div.product form.cart table.variations .label,
form.variations_form .variations .label {
    font-weight: 700;
    color: var(--dg-primary, #2c3e50);
}

.woocommerce div.product form.cart a.reset_variations,
form.variations_form a.reset_variations {
    display: inline-flex !important;
    align-items: center;
    gap: 4px;
    margin-top: 10px;
    font-size: 13px;
    font-weight: 600;
    color: #64748b;
    text-decoration: none;
    border-bottom: 1px dashed #cbd5e1;
    transition: color 0.18s ease, border-color 0.18s ease;
}

.woocommerce div.product form.cart a.reset_variations:hover,
form.variations_form a.reset_variations:hover {
    color: var(--shahin-swatch-danger);
    border-bottom-color: var(--shahin-swatch-danger);
}

/* وقتی لینک پاک‌سازی توسط ووکامرس مخفی است */
form.variations_form a.reset_variations[style*="visibility: hidden"] {
    display: inline-flex !important;
    visibility: hidden !important;
}

/* درخشش ملایم دکمه خرید وقتی تنوع کامل انتخاب شده */
form.variations_form.shahin-variation-complete .single_add_to_cart_button {
    animation: shahinCtaGlow 2.2s ease-in-out infinite;
}

@keyframes shahinCtaGlow {
    0%, 100% { box-shadow: 0 0 0 0 rgba(21, 128, 61, 0); }
    50%      { box-shadow: 0 0 0 7px rgba(21, 128, 61, 0.14); }
}

@media screen and (max-width: 480px) {
    .shahin-swatch {
        min-height: 40px;
        padding: 7px 13px;
        font-size: 13px;
    }

    .shahin-swatch__dot {
        width: 18px;
        height: 18px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .shahin-swatch,
    .shahin-variation-error,
    .shahin-variation-summary {
        transition: none;
    }

    .shahin-swatches.shahin-shake,
    form.variations_form.shahin-variation-complete .single_add_to_cart_button {
        animation: none;
    }
}

/* ------------------------------------------------------------------
 * باکس خرید جایگزین (وقتی قالب صفحه‌ساز فرم خرید ندارد)
 * --------------------------------------------------------------- */

.shahin-purchase-fallback {
    margin: 20px 0;
    padding: 22px 24px;
    background: #fff;
    border: 1px solid #eef0f5;
    border-radius: 16px;
    box-shadow: 0 6px 24px rgba(44, 62, 80, 0.07);
}

.shahin-purchase-fallback form.cart {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
    margin: 0;
}

.shahin-purchase-fallback form.cart table.variations {
    width: 100%;
    margin: 0 0 6px;
    border: 0;
}

.shahin-purchase-fallback form.cart table.variations th,
.shahin-purchase-fallback form.cart table.variations td {
    display: block;
    width: 100%;
    padding: 4px 0;
    border: 0;
    text-align: right;
}

.shahin-purchase-fallback form.cart table.variations th.label {
    font-size: 14px;
    font-weight: 800;
    color: var(--dg-primary, #2c3e50);
}

.shahin-purchase-fallback form.cart table.variations select {
    width: 100%;
    min-height: 44px;
    padding: 8px 14px;
    border: 2px solid #e3e6ec;
    border-radius: 10px;
    font-family: inherit;
    font-size: 14px;
    background: #fff;
    color: var(--dg-primary, #2c3e50);
}

/* ردیف تعداد + دکمه خرید */
.shahin-purchase-fallback .woocommerce-variation-add-to-cart,
.shahin-purchase-fallback form.cart .quantity {
    display: inline-flex;
    align-items: center;
    gap: 12px;
}

.shahin-purchase-fallback .woocommerce-variation-add-to-cart {
    flex-wrap: wrap;
    margin-top: 6px;
}

.shahin-purchase-fallback .single_add_to_cart_button {
    flex: 0 1 auto;
    width: auto;
    min-width: 230px;
    max-width: 340px;
    min-height: 50px;
    padding: 12px 28px;
    border: 0;
    border-radius: 12px;
    background: linear-gradient(135deg, #4f46e5 0%, #6d28d9 100%);
    color: #fff;
    font-family: inherit;
    font-size: 15px;
    font-weight: 800;
    cursor: pointer;
    box-shadow: 0 6px 16px rgba(79, 70, 229, 0.3);
    transition: transform 0.18s ease, box-shadow 0.18s ease, opacity 0.18s ease;
}

.shahin-purchase-fallback .single_add_to_cart_button:hover:not(.disabled) {
    transform: translateY(-2px);
    box-shadow: 0 12px 26px rgba(79, 70, 229, 0.42);
}

.shahin-purchase-fallback .single_add_to_cart_button.disabled,
.shahin-purchase-fallback .single_add_to_cart_button:disabled {
    opacity: 0.55;
    cursor: not-allowed;
    box-shadow: none;
}

/* محصول ساده: قیمت داخل باکس */
.shahin-purchase-fallback form.cart > .price,
.shahin-purchase-fallback form.cart p.price {
    font-size: 1.3em;
    font-weight: 900;
    color: var(--dg-primary, #2c3e50);
    margin: 0 0 10px;
}

/* گروپ‌شده‌ها */
.shahin-purchase-fallback form.cart table.group_table {
    width: 100%;
    margin-bottom: 12px;
}

.shahin-purchase-fallback form.cart table.group_table td {
    padding: 8px;
    vertical-align: middle;
}

@media screen and (max-width: 480px) {
    .shahin-purchase-fallback {
        padding: 16px;
    }

    .shahin-purchase-fallback .single_add_to_cart_button {
        flex-basis: 100%;
        max-width: none;
    }
}
