/**
 * Shop-Press Global Enhancements
 * 
 * Global styling for Shop-Press elements across all pages
 * - Enhanced SP quantity controls
 * - Centered checkout buttons
 * - Modern design matching Kata theme
 * 
 * @package Kata
 * @version 1.0.0
 */

/* ==========================================================================
   DANA FONT DEFINITIONS
   ========================================================================== */

/* Primary Dana font from local files */
@font-face {
    font-family: 'Dana';
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url('/wp-content/uploads/kata/fonts/Dana-Regular.ttf') format('truetype');
}

@font-face {
    font-family: 'Dana';
    font-style: normal;
    font-weight: 600;
    font-display: swap;
    src: url('/wp-content/uploads/kata/fonts/Dana-DemiBold.ttf') format('truetype');
}

@font-face {
    font-family: 'Dana';
    font-style: normal;
    font-weight: 700;
    font-display: swap;
    src: url('/wp-content/uploads/kata/fonts/Dana-Bold.ttf') format('truetype');
}

/* Fallback Dana font from CDN (multiple sources for reliability) */
@font-face {
    font-family: 'Dana-Fallback';
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url('https://cdn.fontcdn.ir/Font/Persian/Dana/woff2/Dana-Regular.woff2') format('woff2'),
    url('https://cdn.fontcdn.ir/Font/Persian/Dana/woff/Dana-Regular.woff') format('woff'),
    url('https://cdn.fontcdn.ir/Font/Persian/Dana/ttf/Dana-Regular.ttf') format('truetype');
}

/* ==========================================================================
   ENHANCED SP QUANTITY CONTROLS - GLOBAL
   ========================================================================== */

/* Enhanced SP quantity wrapper styling */
body .sp-quantity-input-modern-wrap,
html .sp-quantity-input-modern-wrap,
.single-product .sp-quantity-input-modern-wrap,
.kata-centered-layout .sp-quantity-input-modern-wrap {
    position: relative !important;
    display: inline-block !important;
    background: #f8f9fe !important;
    border: 2px solid #dee2e6 !important;
    border-radius: 8px !important;
    padding: 2px !important;
    margin: 4px 0 !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08) !important;
    transition: all 0.3s ease !important;
    min-width: 90px !important;
    max-width: 90px !important;
    width: 90px !important;
    overflow: hidden !important;
}

body .sp-quantity-input-modern-wrap:hover,
html .sp-quantity-input-modern-wrap:hover,
.single-product .sp-quantity-input-modern-wrap:hover,
.kata-centered-layout .sp-quantity-input-modern-wrap:hover {
    border-color: #2dce89 !important;
    box-shadow: 0 4px 16px rgba(45, 206, 137, 0.15) !important;
    background: #f0fff4 !important;
}

/* Enhanced SP quantity control buttons - OVERRIDE Shop-Press defaults */
body .sp-quantity-control,
html .sp-quantity-control,
.single-product .sp-quantity-control,
.kata-centered-layout .sp-quantity-control {
    border: none !important;
    background: linear-gradient(135deg, #2dce89, #219150) !important;
    color: white !important;
    width: 24px !important;
    height: 24px !important;
    min-width: 24px !important;
    padding: 0 !important;
    position: absolute !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    cursor: pointer !important;
    border-radius: 6px !important;
    transition: all 0.3s ease !important;
    z-index: 15 !important;
    box-shadow: 0 2px 8px rgba(45, 206, 137, 0.2) !important;
    font-size: 12px !important;
    font-weight: 700 !important;
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
}

/* Plus button positioning - OVERRIDE Shop-Press */
body .sp-quantity-control.plus,
html .sp-quantity-control.plus,
.single-product .sp-quantity-control.plus,
.kata-centered-layout .sp-quantity-control.plus {
    right: 3px !important;
    left: auto !important;
}

/* Minus button positioning - OVERRIDE Shop-Press */
body .sp-quantity-control.minus,
html .sp-quantity-control.minus,
.single-product .sp-quantity-control.minus,
.kata-centered-layout .sp-quantity-control.minus {
    left: 3px !important;
    right: auto !important;
}

/* Enhanced button hover states */
body .sp-quantity-control:hover,
html .sp-quantity-control:hover,
.single-product .sp-quantity-control:hover,
.kata-centered-layout .sp-quantity-control:hover {
    background: linear-gradient(135deg, #219150, #1a7a42) !important;
    transform: translateY(-50%) scale(1.1) !important;
    box-shadow: 0 4px 16px rgba(45, 206, 137, 0.3) !important;
}

/* Enhanced button active states */
body .sp-quantity-control:active,
html .sp-quantity-control:active,
.single-product .sp-quantity-control:active,
.kata-centered-layout .sp-quantity-control:active {
    transform: translateY(-50%) scale(0.9) !important;
    box-shadow: 0 2px 8px rgba(45, 206, 137, 0.4) !important;
}

/* Enhanced SP quantity input styling */
body .sp-quantity-input-modern-wrap .qty,
body .sp-quantity-input-modern-wrap input[type="number"],
html .sp-quantity-input-modern-wrap .qty,
html .sp-quantity-input-modern-wrap input[type="number"],
.single-product .sp-quantity-input-modern-wrap .qty,
.single-product .sp-quantity-input-modern-wrap input[type="number"],
.kata-centered-layout .sp-quantity-input-modern-wrap .qty,
.kata-centered-layout .sp-quantity-input-modern-wrap input[type="number"] {
    font-size: 14px !important;
    font-weight: 700 !important;
    line-height: 18px !important;
    background: transparent !important;
    padding: 0 30px !important;
    text-align: center !important;
    width: 100% !important;
    min-width: 90px !important;
    max-width: 90px !important;
    -moz-appearance: textfield !important;
    border: none !important;
    border-radius: 0 !important;
    min-height: 30px !important;
    height: 30px !important;
    margin: 0 !important;
    position: relative !important;
    z-index: 5 !important;
    outline: none !important;
    box-shadow: none !important;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    pointer-events: auto !important;
    color: #1e2529 !important;
    font-family: 'Dana', 'Dana-Fallback', 'Digikala', 'Vazir', 'IRANSans', Tahoma, sans-serif !important;
}

body .sp-quantity-input-modern-wrap .qty:focus,
body .sp-quantity-input-modern-wrap input[type="number"]:focus,
html .sp-quantity-input-modern-wrap .qty:focus,
html .sp-quantity-input-modern-wrap input[type="number"]:focus,
.single-product .sp-quantity-input-modern-wrap .qty:focus,
.single-product .sp-quantity-input-modern-wrap input[type="number"]:focus,
.kata-centered-layout .sp-quantity-input-modern-wrap .qty:focus,
.kata-centered-layout .sp-quantity-input-modern-wrap input[type="number"]:focus {
    outline: none !important;
    box-shadow: none !important;
    border: none !important;
}

/* Enhanced SP quantity control SVG icons */
body .sp-quantity-control svg,
html .sp-quantity-control svg,
.single-product .sp-quantity-control svg,
.kata-centered-layout .sp-quantity-control svg {
    pointer-events: none !important;
    width: 18px !important;
    height: 18px !important;
    fill: currentColor !important;
    display: block !important;
    filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.1)) !important;
}

/* Remove webkit number input spinners */
body .sp-quantity-input-modern-wrap .qty::-webkit-outer-spin-button,
body .sp-quantity-input-modern-wrap .qty::-webkit-inner-spin-button,
body .sp-quantity-input-modern-wrap input[type="number"]::-webkit-outer-spin-button,
body .sp-quantity-input-modern-wrap input[type="number"]::-webkit-inner-spin-button,
html .sp-quantity-input-modern-wrap .qty::-webkit-outer-spin-button,
html .sp-quantity-input-modern-wrap .qty::-webkit-inner-spin-button,
html .sp-quantity-input-modern-wrap input[type="number"]::-webkit-outer-spin-button,
html .sp-quantity-input-modern-wrap input[type="number"]::-webkit-inner-spin-button,
.single-product .sp-quantity-input-modern-wrap .qty::-webkit-outer-spin-button,
.single-product .sp-quantity-input-modern-wrap .qty::-webkit-inner-spin-button,
.single-product .sp-quantity-input-modern-wrap input[type="number"]::-webkit-outer-spin-button,
.single-product .sp-quantity-input-modern-wrap input[type="number"]::-webkit-inner-spin-button,
.kata-centered-layout .sp-quantity-input-modern-wrap .qty::-webkit-outer-spin-button,
.kata-centered-layout .sp-quantity-input-modern-wrap .qty::-webkit-inner-spin-button,
.kata-centered-layout .sp-quantity-input-modern-wrap input[type="number"]::-webkit-outer-spin-button,
.kata-centered-layout .sp-quantity-input-modern-wrap input[type="number"]::-webkit-inner-spin-button {
    -webkit-appearance: none !important;
    margin: 0 !important;
    width: 0 !important;
    border: none !important;
    display: none !important;
}

/* ==========================================================================
   MINI-CART SPECIFIC ENHANCEMENTS
   ========================================================================== */

/* ENHANCED mini-cart styling with proper dimensions */
.sp-mini-cart .sp-quantity-input-modern-wrap,
.sp-mini-cart-style-1 .sp-quantity-input-modern-wrap {
    background: #f4f5f7 !important;
    border: 2px solid #e1e2e3 !important;
    border-radius: 8px !important;
    min-width: 80px !important;
    max-width: 80px !important;
    width: 80px !important;
    margin: 4px 0 !important;
    padding: 2px !important;
    overflow: hidden !important;
}

.sp-mini-cart .sp-quantity-input-modern-wrap:hover,
.sp-mini-cart-style-1 .sp-quantity-input-modern-wrap:hover {
    border-color: #2dce89 !important;
    background: #f0fff4 !important;
}

.sp-mini-cart .sp-quantity-control,
.sp-mini-cart-style-1 .sp-quantity-control {
    background: linear-gradient(135deg, #2dce89, #219150) !important;
    width: 20px !important;
    height: 20px !important;
    min-width: 20px !important;
    border-radius: 4px !important;
    font-size: 12px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    position: absolute !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    cursor: pointer !important;
    z-index: 15 !important;
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
}

.sp-mini-cart .sp-quantity-control:hover,
.sp-mini-cart-style-1 .sp-quantity-control:hover {
    transform: translateY(-50%) scale(1.1) !important;
    background: linear-gradient(135deg, #219150, #1a7a42) !important;
}

.sp-mini-cart .sp-quantity-control.plus,
.sp-mini-cart-style-1 .sp-quantity-control.plus {
    right: 2px !important;
    left: auto !important;
}

.sp-mini-cart .sp-quantity-control.minus,
.sp-mini-cart-style-1 .sp-quantity-control.minus {
    left: 2px !important;
    right: auto !important;
}

.sp-mini-cart .sp-quantity-input-modern-wrap .qty,
.sp-mini-cart-style-1 .sp-quantity-input-modern-wrap .qty {
    padding: 0 24px !important;
    min-width: 80px !important;
    max-width: 80px !important;
    width: 80px !important;
    height: 24px !important;
    min-height: 24px !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    font-family: 'Dana', 'Dana-Fallback', 'Digikala', 'Vazir', 'IRANSans', Tahoma, sans-serif !important;
    line-height: 14px !important;
    text-align: center !important;
    background: transparent !important;
    border: none !important;
    outline: none !important;
    color: #1e2529 !important;
}

/* ==========================================================================
   CHECKOUT BUTTON CENTER ALIGNMENT - GLOBAL
   ========================================================================== */

/* Center align checkout button in ALL SP mini-cart instances */
.sp-mini-cart .sp-cart-details .woocommerce-mini-cart__buttons.buttons,
.sp-mini-cart-style-1 .sp-cart-details .woocommerce-mini-cart__buttons.buttons {
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    gap: 12px !important;
    margin: 0 !important;
    padding: 16px 0 !important;
    border: none !important;
    flex-direction: column !important;
}

/* Enhanced checkout button styling */
.sp-mini-cart .sp-cart-details .woocommerce-mini-cart__buttons.buttons a,
.sp-mini-cart-style-1 .sp-cart-details .woocommerce-mini-cart__buttons.buttons a {
    width: 100% !important;
    max-width: 280px !important;
    min-width: auto !important;
    text-align: center !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    margin: 0 !important;
    padding: 16px 24px !important;
    border-radius: 12px !important;
    font-size: 16px !important;
    font-weight: 600 !important;
    transition: all 0.3s ease !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1) !important;
}

/* Enhanced checkout button (تسویه حساب) */
.sp-mini-cart .sp-cart-details .woocommerce-mini-cart__buttons.buttons a.checkout,
.sp-mini-cart-style-1 .sp-cart-details .woocommerce-mini-cart__buttons.buttons a.checkout {
    background: linear-gradient(135deg, #2dce89, #219150) !important;
    color: #ffffff !important;
    border: none !important;
    box-shadow: 0 4px 16px rgba(45, 206, 137, 0.3) !important;
    order: 2 !important;
}

.sp-mini-cart .sp-cart-details .woocommerce-mini-cart__buttons.buttons a.checkout:hover {
    background: linear-gradient(135deg, #219150, #1a7a42) !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 20px rgba(45, 206, 137, 0.4) !important;
}

/* Force white text on checkout button across all states (fix purple/visited on single-product) */
.sp-mini-cart .sp-cart-details .woocommerce-mini-cart__buttons.buttons a.checkout,
.sp-mini-cart .sp-cart-details .woocommerce-mini-cart__buttons.buttons a.checkout:visited,
.sp-mini-cart .sp-cart-details .woocommerce-mini-cart__buttons.buttons a.checkout:hover,
.sp-mini-cart .sp-cart-details .woocommerce-mini-cart__buttons.buttons a.checkout:active,
.sp-mini-cart .sp-cart-details .woocommerce-mini-cart__buttons.buttons a.checkout:focus {
    color: #ffffff !important;
}

/* Extra specificity for single product page, if needed */
body.single-product .sp-mini-cart .sp-cart-details .woocommerce-mini-cart__buttons.buttons a.checkout,
body.single-product .sp-mini-cart .sp-cart-details .woocommerce-mini-cart__buttons.buttons a.checkout:visited,
body.single-product .sp-mini-cart .sp-cart-details .woocommerce-mini-cart__buttons.buttons a.checkout:hover,
body.single-product .sp-mini-cart .sp-cart-details .woocommerce-mini-cart__buttons.buttons a.checkout:active,
body.single-product .sp-mini-cart .sp-cart-details .woocommerce-mini-cart__buttons.buttons a.checkout:focus {
    color: #ffffff !important;
}

/* Bold and theme-consistent total price; ensure font uses Dana; */
.sp-mini-cart .woocommerce-mini-cart__total .woocommerce-Price-amount .amount,
.sp-mini-cart .woocommerce-mini-cart__total .woocommerce-Price-amount,
.sp-mini-cart .woocommerce-mini-cart__total .amount bdi {
    font-weight: 700 !important;
    font-family: 'Dana', 'Dana-Fallback', 'Digikala', 'Vazir', 'IRANSans', Tahoma, sans-serif !important;
}

/* Ensure RTL order and place currency before digits using ::before on amount */
.sp-mini-cart .woocommerce-mini-cart__total .woocommerce-Price-amount,
#sp-mini-cart-drawer .woocommerce-mini-cart__total .woocommerce-Price-amount {
    direction: rtl !important;
    unicode-bidi: isolate-override !important;
    display: inline-flex !important;
    align-items: center !important;
}

.sp-mini-cart .woocommerce-mini-cart__total .woocommerce-Price-amount .woocommerce-Price-currencySymbol,
#sp-mini-cart-drawer .woocommerce-mini-cart__total .woocommerce-Price-amount .woocommerce-Price-currencySymbol {
    display: none !important;
}

.sp-mini-cart .woocommerce-mini-cart__total .woocommerce-Price-amount::before,
#sp-mini-cart-drawer .woocommerce-mini-cart__total .woocommerce-Price-amount::before {
    content: 'تومان';
    display: inline-block;
    margin-left: 8px; /* فاصله بین تومان و عدد */
    font-weight: 700;
}

/* Cancel any previous insertion on bdi */
.sp-mini-cart .woocommerce-mini-cart__total .woocommerce-Price-amount bdi::before,
#sp-mini-cart-drawer .woocommerce-mini-cart__total .woocommerce-Price-amount bdi::before {
    content: none !important;
}

/* Enhanced view cart button (مشاهده سبد خرید) */
.sp-mini-cart .sp-cart-details .woocommerce-mini-cart__buttons.buttons a:not(.checkout) {
    background: white !important;
    color: #2dce89 !important;
    border: 2px solid #2dce89 !important;
    order: 1 !important;
}

.sp-mini-cart .sp-cart-details .woocommerce-mini-cart__buttons.buttons a:not(.checkout):hover {
    background: #f0fff4 !important;
    color: #219150 !important;
    border-color: #219150 !important;
    transform: translateY(-1px) !important;
}

/* ==========================================================================
   DANA FONT FOR ENTIRE SP MINI-CART
   ========================================================================== */

/* Apply Dana font to entire SP mini-cart with higher specificity */
.sp-mini-cart,
.sp-mini-cart *,
.sp-mini-cart-style-1,
.sp-mini-cart-style-1 *,
#sp-mini-cart-drawer .sp-mini-cart,
#sp-mini-cart-drawer .sp-mini-cart *,
.sp-drawer .sp-mini-cart,
.sp-drawer .sp-mini-cart * {
    font-family: 'Dana', 'Dana-Fallback', 'Digikala', 'Vazir', 'IRANSans', Tahoma, sans-serif !important;
}

/* Specific SP mini-cart elements with Dana font */
.sp-mini-cart .sp-title,
.sp-mini-cart .sp-cart-item-pr-title,
.sp-mini-cart .sp-cart-item-pr-title-link,
.sp-mini-cart .sp-cart-item-price,
.sp-mini-cart .sp-cart-item-quantity,
.sp-mini-cart .woocommerce-Price-amount,
.sp-mini-cart .woocommerce-mini-cart__total,
.sp-mini-cart .woocommerce-mini-cart__buttons a,
.sp-mini-cart-style-1 .sp-title,
.sp-mini-cart-style-1 .sp-cart-item-pr-title,
.sp-mini-cart-style-1 .sp-cart-item-pr-title-link,
.sp-mini-cart-style-1 .sp-cart-item-price,
.sp-mini-cart-style-1 .sp-cart-item-quantity,
.sp-mini-cart-style-1 .woocommerce-Price-amount,
.sp-mini-cart-style-1 .woocommerce-mini-cart__total,
.sp-mini-cart-style-1 .woocommerce-mini-cart__buttons a {
    font-family: 'Dana', 'Dana-Fallback', 'Digikala', 'Vazir', 'IRANSans', Tahoma, sans-serif !important;
}

/* Ensure Dana font loads for SP drawer elements */
.sp-drawer,
.sp-drawer *,
.sp-mini-cart-drawer,
.sp-mini-cart-drawer *,
#sp-mini-cart-drawer,
#sp-mini-cart-drawer * {
    font-family: 'Dana', 'Dana-Fallback', 'Digikala', 'Vazir', 'IRANSans', Tahoma, sans-serif !important;
}

/* ==========================================================================
   ULTRA HIGH SPECIFICITY - OVERRIDE SINGLE PRODUCT PAGE
   ========================================================================== */

/* ULTRA SPECIFIC - SP quantity wrapper for single product page override */
body.single-product .sp-quantity-input-modern-wrap,
html body.single-product .sp-quantity-input-modern-wrap,
body.single-product .kata-centered-layout .sp-quantity-input-modern-wrap,
body.single-product .kata-add-to-cart-wrapper .sp-quantity-input-modern-wrap {
    position: relative !important;
    display: inline-block !important;
    background: #f8f9fe !important;
    border: 2px solid #dee2e6 !important;
    border-radius: 8px !important;
    padding: 2px !important;
    margin: 4px 0 !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08) !important;
    transition: all 0.3s ease !important;
    min-width: 85px !important;
    max-width: 85px !important;
    width: 85px !important;
    overflow: hidden !important;
}

/* ULTRA SPECIFIC - SP quantity buttons for single product page override */
body.single-product .sp-quantity-control,
html body.single-product .sp-quantity-control,
body.single-product .kata-centered-layout .sp-quantity-control,
body.single-product .kata-add-to-cart-wrapper .sp-quantity-control {
    border: none !important;
    background: linear-gradient(135deg, #2dce89, #219150) !important;
    color: white !important;
    width: 22px !important;
    height: 22px !important;
    min-width: 22px !important;
    padding: 0 !important;
    position: absolute !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    cursor: pointer !important;
    border-radius: 5px !important;
    transition: all 0.3s ease !important;
    z-index: 15 !important;
    box-shadow: 0 2px 8px rgba(45, 206, 137, 0.2) !important;
    font-size: 11px !important;
    font-weight: 700 !important;
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
}

/* ULTRA SPECIFIC - SP quantity input for single product page override */
body.single-product .sp-quantity-input-modern-wrap .qty,
body.single-product .sp-quantity-input-modern-wrap input[type="number"],
html body.single-product .sp-quantity-input-modern-wrap .qty,
html body.single-product .sp-quantity-input-modern-wrap input[type="number"],
body.single-product .kata-centered-layout .sp-quantity-input-modern-wrap .qty,
body.single-product .kata-centered-layout .sp-quantity-input-modern-wrap input[type="number"] {
    font-size: 13px !important;
    font-weight: 700 !important;
    line-height: 16px !important;
    background: transparent !important;
    padding: 0 26px !important;
    text-align: center !important;
    width: 100% !important;
    min-width: 85px !important;
    max-width: 85px !important;
    -moz-appearance: textfield !important;
    border: none !important;
    border-radius: 0 !important;
    min-height: 26px !important;
    height: 26px !important;
    margin: 0 !important;
    position: relative !important;
    z-index: 5 !important;
    outline: none !important;
    box-shadow: none !important;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    pointer-events: auto !important;
    color: #1e2529 !important;
    font-family: 'Dana', 'Dana-Fallback', 'Digikala', 'Vazir', 'IRANSans', Tahoma, sans-serif !important;
}

/* ULTRA SPECIFIC - SP button positioning for single product page */
body.single-product .sp-quantity-control.plus,
html body.single-product .sp-quantity-control.plus,
body.single-product .kata-centered-layout .sp-quantity-control.plus {
    right: 2px !important;
    left: auto !important;
}

body.single-product .sp-quantity-control.minus,
html body.single-product .sp-quantity-control.minus,
body.single-product .kata-centered-layout .sp-quantity-control.minus {
    left: 2px !important;
    right: auto !important;
}

/* ULTRA SPECIFIC - SP button icons for single product page */
body.single-product .sp-quantity-control svg,
html body.single-product .sp-quantity-control svg,
body.single-product .kata-centered-layout .sp-quantity-control svg {
    width: 14px !important;
    height: 14px !important;
    fill: currentColor !important;
    display: block !important;
}

/* ==========================================================================
   RESPONSIVE DESIGN
   ========================================================================== */

@media (max-width: 768px) {
    .sp-quantity-input-modern-wrap {
        min-width: 100px !important;
    }

    .sp-quantity-control {
        width: 28px !important;
        height: 28px !important;
        min-width: 28px !important;
    }

    .sp-quantity-input-modern-wrap .qty {
        padding: 0 32px !important;
        min-width: 100px !important;
        font-size: 14px !important;
    }
}

@media (max-width: 480px) {
    .sp-mini-cart .sp-cart-details .woocommerce-mini-cart__buttons.buttons a {
        font-size: 14px !important;
        padding: 14px 20px !important;
    }
}

/* ==========================================================================
   ULTRA HIGH SPECIFICITY - EXACT SHOP-PRESS SELECTOR OVERRIDE
   ========================================================================== */

/* EXACT OVERRIDE - Match Shop-Press specificity exactly */
.sp-mini-cart.sp-mini-cart-style-1 .sp-cart-items .sp-cart-item-pr .sp-mmceta .sp-cart-item-prices div.quantity .sp-quantity-input-modern-wrap {
    position: relative !important;
    display: inline-block !important;
    background: #f8f9fe !important;
    border: 2px solid #2dce89 !important;
    border-radius: 8px !important;
    padding: 2px !important;
    margin: 4px 0 !important;
    box-shadow: 0 2px 8px rgba(45, 206, 137, 0.15) !important;
    transition: all 0.3s ease !important;
    min-width: 85px !important;
    max-width: 85px !important;
    width: 85px !important;
    overflow: hidden !important;
}

.sp-mini-cart.sp-mini-cart-style-1 .sp-cart-items .sp-cart-item-pr .sp-mmceta .sp-cart-item-prices div.quantity .sp-quantity-input-modern-wrap:hover {
    border-color: #219150 !important;
    background: #f0fff4 !important;
    box-shadow: 0 4px 16px rgba(45, 206, 137, 0.2) !important;
}

.sp-mini-cart.sp-mini-cart-style-1 .sp-cart-items .sp-cart-item-pr .sp-mmceta .sp-cart-item-prices div.quantity .sp-quantity-input-modern-wrap .qty {
    font-size: 13px !important;
    font-weight: 700 !important;
    line-height: 16px !important;
    background: transparent !important;
    padding: 0 26px !important;
    text-align: center !important;
    width: 100% !important;
    min-width: 85px !important;
    max-width: 85px !important;
    -moz-appearance: textfield !important;
    border: none !important;
    border-radius: 0 !important;
    min-height: 26px !important;
    height: 26px !important;
    margin: 0 !important;
    position: relative !important;
    z-index: 5 !important;
    outline: none !important;
    box-shadow: none !important;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    pointer-events: auto !important;
    color: #1e2529 !important;
    font-family: 'Dana', 'Dana-Fallback', 'Digikala', 'Vazir', 'IRANSans', Tahoma, sans-serif !important;
}

.sp-mini-cart.sp-mini-cart-style-1 .sp-cart-items .sp-cart-item-pr .sp-mmceta .sp-cart-item-prices div.quantity .sp-quantity-input-modern-wrap .sp-quantity-control {
    border: none !important;
    background: linear-gradient(135deg, #2dce89, #219150) !important;
    color: white !important;
    width: 22px !important;
    height: 22px !important;
    min-width: 22px !important;
    padding: 0 !important;
    position: absolute !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    cursor: pointer !important;
    border-radius: 5px !important;
    transition: all 0.3s ease !important;
    z-index: 15 !important;
    box-shadow: 0 2px 8px rgba(45, 206, 137, 0.2) !important;
    font-size: 11px !important;
    font-weight: 700 !important;
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
}

.sp-mini-cart.sp-mini-cart-style-1 .sp-cart-items .sp-cart-item-pr .sp-mmceta .sp-cart-item-prices div.quantity .sp-quantity-input-modern-wrap .sp-quantity-control:hover {
    background: linear-gradient(135deg, #219150, #1a7a42) !important;
    transform: translateY(-50%) scale(1.1) !important;
    box-shadow: 0 4px 16px rgba(45, 206, 137, 0.3) !important;
}

.sp-mini-cart.sp-mini-cart-style-1 .sp-cart-items .sp-cart-item-pr .sp-mmceta .sp-cart-item-prices div.quantity .sp-quantity-input-modern-wrap .sp-quantity-control.plus {
    right: 2px !important;
    left: auto !important;
}

.sp-mini-cart.sp-mini-cart-style-1 .sp-cart-items .sp-cart-item-pr .sp-mmceta .sp-cart-item-prices div.quantity .sp-quantity-input-modern-wrap .sp-quantity-control.minus {
    left: 2px !important;
    right: auto !important;
}

.sp-mini-cart.sp-mini-cart-style-1 .sp-cart-items .sp-cart-item-pr .sp-mmceta .sp-cart-item-prices div.quantity .sp-quantity-input-modern-wrap .sp-quantity-control svg {
    width: 14px !important;
    height: 14px !important;
    fill: currentColor !important;
    display: block !important;
    pointer-events: none !important;
}

/* ALSO override the shorter selector path */
.sp-mini-cart.sp-mini-cart-style-1 .sp-cart-items div.quantity .sp-quantity-input-modern-wrap {
    position: relative !important;
    display: inline-block !important;
    background: #f8f9fe !important;
    border: 2px solid #2dce89 !important;
    border-radius: 8px !important;
    padding: 2px !important;
    margin: 4px 0 !important;
    box-shadow: 0 2px 8px rgba(45, 206, 137, 0.15) !important;
    transition: all 0.3s ease !important;
    min-width: 85px !important;
    max-width: 85px !important;
    width: 85px !important;
    overflow: hidden !important;
}

.sp-mini-cart.sp-mini-cart-style-1 .sp-cart-items div.quantity .sp-quantity-input-modern-wrap .qty {
    font-size: 13px !important;
    font-weight: 700 !important;
    line-height: 16px !important;
    background: transparent !important;
    padding: 0 26px !important;
    text-align: center !important;
    width: 100% !important;
    min-width: 85px !important;
    max-width: 85px !important;
    -moz-appearance: textfield !important;
    border: none !important;
    border-radius: 0 !important;
    min-height: 26px !important;
    height: 26px !important;
    margin: 0 !important;
    position: relative !important;
    z-index: 5 !important;
    outline: none !important;
    box-shadow: none !important;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    pointer-events: auto !important;
    color: #1e2529 !important;
    font-family: 'Dana', 'Dana-Fallback', 'Digikala', 'Vazir', 'IRANSans', Tahoma, sans-serif !important;
}

.sp-mini-cart.sp-mini-cart-style-1 .sp-cart-items div.quantity .sp-quantity-input-modern-wrap .sp-quantity-control {
    border: none !important;
    background: linear-gradient(135deg, #2dce89, #219150) !important;
    color: white !important;
    width: 22px !important;
    height: 22px !important;
    min-width: 22px !important;
    padding: 0 !important;
    position: absolute !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    cursor: pointer !important;
    border-radius: 5px !important;
    transition: all 0.3s ease !important;
    z-index: 15 !important;
    box-shadow: 0 2px 8px rgba(45, 206, 137, 0.2) !important;
    font-size: 11px !important;
    font-weight: 700 !important;
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
}

.sp-mini-cart.sp-mini-cart-style-1 .sp-cart-items div.quantity .sp-quantity-input-modern-wrap .sp-quantity-control:hover {
    background: linear-gradient(135deg, #219150, #1a7a42) !important;
    transform: translateY(-50%) scale(1.1) !important;
    box-shadow: 0 4px 16px rgba(45, 206, 137, 0.3) !important;
}

.sp-mini-cart.sp-mini-cart-style-1 .sp-cart-items div.quantity .sp-quantity-input-modern-wrap .sp-quantity-control.plus {
    right: 2px !important;
    left: auto !important;
}

.sp-mini-cart.sp-mini-cart-style-1 .sp-cart-items div.quantity .sp-quantity-input-modern-wrap .sp-quantity-control.minus {
    left: 2px !important;
    right: auto !important;
}

.sp-mini-cart.sp-mini-cart-style-1 .sp-cart-items div.quantity .sp-quantity-input-modern-wrap .sp-quantity-control svg {
    width: 14px !important;
    height: 14px !important;
    fill: currentColor !important;
    display: block !important;
    pointer-events: none !important;
}