/*
Theme Name: Arcade Tech (Hello Biz Child)
Theme URI: https://arcadetech.local
Description: پوسته فرزند تفکیک‌شده و ماژولار آرکید تک
Author: Dima Agency (Mehran)
Template: hello-biz
Version: 2.0.0
Text Domain: hello-biz-child
*/

/* ==========================================================================
   Arcade Tech — Global WooCommerce & Cart Dark Styling
   ========================================================================== */

.woocommerce-cart .woocommerce,
.woocommerce-checkout .woocommerce {
    color: var(--arc-text);
}

.woocommerce-cart table.shop_table {
    width: 100% !important;
    border-collapse: separate !important;
    border-spacing: 0 !important;
    border: 1px solid var(--arc-border) !important;
    border-radius: 16px !important;
    overflow: hidden !important;
    background: var(--arc-surface) !important;
    margin-bottom: 2rem !important;
}

.woocommerce-cart table.shop_table th {
    background: #090618 !important;
    color: #ffffff !important;
    font-weight: 800 !important;
    padding: 1rem 1.25rem !important;
    text-align: right !important;
    border-bottom: 1px solid var(--arc-border) !important;
    font-size: 0.9rem !important;
}

.woocommerce-cart table.shop_table td {
    padding: 1.25rem !important;
    text-align: right !important;
    border-bottom: 1px solid var(--arc-border) !important;
    color: #ffffff !important;
}

.woocommerce-cart table.shop_table tr:last-child td {
    border-bottom: none !important;
}

.woocommerce-cart .cart-collaterals {
    background: var(--arc-surface) !important;
    border: 1px solid var(--arc-border) !important;
    border-radius: 16px !important;
    padding: 2rem !important;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3) !important;
    margin-top: 2rem !important;
}

.woocommerce-cart .cart_totals table {
    width: 100% !important;
    border-collapse: collapse !important;
    color: #ffffff !important;
}

.woocommerce-cart .cart_totals th, 
.woocommerce-cart .cart_totals td {
    padding: 0.85rem 0 !important;
    border-bottom: 1px dashed var(--arc-border) !important;
}

.woocommerce-cart .checkout-button {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
    height: 52px !important;
    border-radius: 10px !important;
    background: var(--arc-lime) !important;
    color: #000000 !important;
    font-weight: 900 !important;
    font-size: 1rem !important;
    text-decoration: none !important;
    box-shadow: 0 0 20px rgba(212, 255, 0, 0.3) !important;
    transition: all 0.25s !important;
    border: none !important;
    margin-top: 1.5rem !important;
    cursor: pointer !important;
}

.woocommerce-cart .checkout-button:hover {
    background: var(--arc-lime-hover) !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 0 30px rgba(212, 255, 0, 0.5) !important;
}

.woocommerce-cart input.input-text,
.woocommerce-checkout input.input-text,
.woocommerce-checkout select,
.woocommerce-checkout textarea {
    background: #090618 !important;
    border: 1px solid var(--arc-border) !important;
    color: #ffffff !important;
    border-radius: 8px !important;
    padding: 8px 14px !important;
    outline: none !important;
}

.woocommerce-cart .button,
.woocommerce-checkout .button {
    background: rgba(255, 255, 255, 0.08) !important;
    border: 1px solid var(--arc-border) !important;
    color: #ffffff !important;
    border-radius: 8px !important;
    padding: 10px 20px !important;
    cursor: pointer !important;
    font-weight: 700 !important;
    transition: all 0.2s !important;
}

.woocommerce-cart .button:hover,
.woocommerce-checkout .button:hover {
    border-color: var(--arc-lime) !important;
    color: var(--arc-lime) !important;
}

/* ==========================================================================
   Arcade Tech — My Account & Gamer Dashboard
   ========================================================================== */

.arc-account-grid {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 2rem;
    align-items: start;
}
@media (max-width: 900px) {
    .arc-account-grid { grid-template-columns: 1fr; }
}
.arc-account-nav-link {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    padding: 0.85rem 1.25rem;
    font-size: 0.92rem;
    font-weight: 700;
    color: #cbd5e1;
    text-decoration: none !important;
    border-radius: 10px;
    transition: all 0.2s ease;
}
.arc-account-nav-link:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--arc-lime);
    transform: translateX(-4px);
}
.arc-account-nav-link.is-active {
    background: var(--arc-purple) !important;
    color: #ffffff !important;
    box-shadow: 0 0 15px var(--arc-purple-glow);
}
.woocommerce-MyAccount-content {
    color: #ffffff !important;
}
.woocommerce-MyAccount-content a {
    color: var(--arc-lime) !important;
    text-decoration: none !important;
    font-weight: 700 !important;
}
.woocommerce-MyAccount-content a:hover {
    text-decoration: underline !important;
}
.woocommerce-MyAccount-content table.shop_table {
    width: 100% !important;
    border-collapse: separate !important;
    border-spacing: 0 !important;
    border: 1px solid var(--arc-border) !important;
    border-radius: 12px !important;
    overflow: hidden !important;
    background: #090618 !important;
}
.woocommerce-MyAccount-content table.shop_table th {
    background: #141029 !important;
    color: #ffffff !important;
    padding: 12px 16px !important;
    text-align: right !important;
    border-bottom: 1px solid var(--arc-border) !important;
}
.woocommerce-MyAccount-content table.shop_table td {
    padding: 14px 16px !important;
    border-bottom: 1px solid var(--arc-border) !important;
    color: #cbd5e1 !important;
}
.woocommerce-MyAccount-content input[type="text"],
.woocommerce-MyAccount-content input[type="email"],
.woocommerce-MyAccount-content input[type="password"] {
    width: 100% !important;
    height: 48px !important;
    border-radius: 8px !important;
    background: #090618 !important;
    border: 1px solid var(--arc-border) !important;
    color: #ffffff !important;
    padding: 0 1rem !important;
    outline: none !important;
}
.woocommerce-MyAccount-content input:focus {
    border-color: var(--arc-lime) !important;
    box-shadow: 0 0 0 3px rgba(212, 255, 0, 0.15) !important;
}
.woocommerce-MyAccount-content button[type="submit"] {
    background: var(--arc-lime) !important;
    color: #000000 !important;
    font-weight: 900 !important;
    border-radius: 8px !important;
    padding: 12px 28px !important;
    border: none !important;
    cursor: pointer !important;
    box-shadow: 0 0 15px rgba(212, 255, 0, 0.3) !important;
    margin-top: 1rem !important;
}

/* ==========================================================================
   Atomic CRO Components: Sticky Mobile Buy Bar
   ========================================================================== */
/* Sticky Mobile Buy Bar */
.arc-sticky-mobile-bar {
    display: none !important;
}
@media (max-width: 767px) {
    .arc-sticky-mobile-bar {
        display: block !important;
        position: fixed !important;
        bottom: 0 !important;
        left: 0 !important;
        right: 0 !important;
        width: 100% !important;
        background: rgba(14, 10, 34, 0.96) !important;
        backdrop-filter: blur(12px) !important;
        -webkit-backdrop-filter: blur(12px) !important;
        border-top: 1px solid rgba(137, 92, 255, 0.3) !important;
        padding: 10px 14px calc(10px + env(safe-area-inset-bottom, 0px)) 14px !important;
        z-index: 99999 !important;
        box-shadow: 0 -8px 24px rgba(0, 0, 0, 0.6) !important;
        direction: rtl !important;
    }
    .arc-sticky-inner {
        display: flex !important;
        align-items: center !important;
        justify-content: space-between !important;
        gap: 12px !important;
        max-width: 600px !important;
        margin: 0 auto !important;
    }
    .arc-sticky-prod {
        display: flex !important;
        align-items: center !important;
        gap: 10px !important;
        overflow: hidden !important;
        flex: 1 !important;
    }
    .arc-sticky-thumb {
        width: 42px !important;
        height: 42px !important;
        border-radius: 8px !important;
        background: #191238 !important;
        border: 1px solid rgba(137, 92, 255, 0.25) !important;
        object-fit: contain !important;
        flex-shrink: 0 !important;
    }
    .arc-sticky-meta {
        display: flex !important;
        flex-direction: column !important;
        overflow: hidden !important;
    }
    .arc-sticky-name {
        color: #ffffff !important;
        font-size: 12px !important;
        font-weight: 700 !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
    }
    .arc-sticky-price {
        color: #d4ff00 !important;
        font-size: 15px !important;
        font-weight: 900 !important;
    }
    .arc-sticky-price small {
        font-size: 10.5px !important;
        color: #94a3b8 !important;
    }
    .arc-sticky-cta {
        background: #d4ff00 !important;
        color: #0b071c !important;
        border: none !important;
        border-radius: 10px !important;
        padding: 10px 18px !important;
        font-size: 13.5px !important;
        font-weight: 900 !important;
        display: inline-flex !important;
        align-items: center !important;
        gap: 6px !important;
        cursor: pointer !important;
        box-shadow: 0 4px 14px rgba(212, 255, 0, 0.35) !important;
        flex-shrink: 0 !important;
        transition: transform 0.15s ease !important;
    }
    .arc-sticky-cta:active {
        transform: scale(0.96) !important;
    }
    body.single-product {
        padding-bottom: 74px !important;
    }
}

/* ==========================================================
   ARCADE TECH: WOOCOMMERCE SHOP & ARCHIVE GRID CRO POLISH
   ========================================================== */
ul.products {
    display: grid !important;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)) !important;
    gap: 20px !important;
    padding: 0 !important;
    margin: 24px 0 !important;
    list-style: none !important;
}

ul.products li.product {
    background: #141029 !important;
    border: 1px solid rgba(137, 92, 255, 0.22) !important;
    border-radius: 16px !important;
    padding: 16px !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: space-between !important;
    transition: all 0.25s ease !important;
    position: relative !important;
    overflow: hidden !important;
    width: 100% !important;
    margin: 0 !important;
    box-sizing: border-box !important;
}

ul.products li.product:hover {
    transform: translateY(-4px) !important;
    border-color: #d4ff00 !important;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.5) !important;
}

ul.products li.product .woocommerce-loop-product__title {
    font-size: 14px !important;
    line-height: 1.55 !important;
    font-weight: 700 !important;
    color: #f8fafc !important;
    margin: 12px 0 8px 0 !important;
    height: 44px !important;
    overflow: hidden !important;
    display: -webkit-box !important;
    -webkit-line-clamp: 2 !important;
    -webkit-box-orient: vertical !important;
    direction: rtl !important;
}

ul.products li.product .price {
    display: flex !important;
    flex-direction: column !important;
    margin-bottom: 12px !important;
    margin-top: auto !important;
}

ul.products li.product .price del {
    color: #64748b !important;
    font-size: 11.5px !important;
    opacity: 0.75 !important;
}

ul.products li.product .price ins,
ul.products li.product .price > .amount {
    color: #d4ff00 !important;
    font-size: 16px !important;
    font-weight: 900 !important;
    text-decoration: none !important;
}

ul.products li.product:not(:has(.arc-prod-card)) .button.add_to_cart_button {
    background: #d4ff00 !important;
    color: #0b071c !important;
    font-size: 13.5px !important;
    font-weight: 800 !important;
    border: none !important;
    border-radius: 10px !important;
    padding: 10px 14px !important;
    width: 100% !important;
    text-align: center !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
    cursor: pointer !important;
    box-shadow: 0 4px 14px rgba(212, 255, 0, 0.3) !important;
    transition: all 0.2s ease !important;
    margin-top: 6px !important;
}

ul.products li.product:not(:has(.arc-prod-card)) .button.add_to_cart_button:hover {
    transform: scale(1.02) !important;
    box-shadow: 0 6px 18px rgba(212, 255, 0, 0.45) !important;
    background: #e2ff33 !important;
}

/* Unified Card Protection in Root style.css */
.arc-prod-card .arc-prod-pricing .arc-add-cart-btn,
.arc-prod-card .arc-add-cart-btn {
    width: auto !important;
    max-width: none !important;
    flex: 0 0 auto !important;
    white-space: nowrap !important;
    margin: 0 !important;
}

ul.products li.product span.onsale {
    background: #ef4444 !important;
    color: #ffffff !important;
    font-size: 11px !important;
    font-weight: 800 !important;
    padding: 4px 8px !important;
    border-radius: 6px !important;
    top: 14px !important;
    right: 14px !important;
    left: auto !important;
    min-height: auto !important;
    line-height: 1 !important;
    box-shadow: 0 2px 8px rgba(239, 68, 68, 0.4) !important;
}
.woocommerce-ordering { display: none !important; }

/* Grid 3-column perfect balance */
.elementor-element-col_products_left ul.products,
.elementor-widget-woocommerce-products ul.products {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 22px !important;
    width: 100% !important;
}

.elementor-element-col_products_left ul.products li.product,
.elementor-widget-woocommerce-products ul.products li.product {
    width: 100% !important;
    margin: 0 !important;
    float: none !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: space-between !important;
    background: #120c28 !important;
    border: 1px solid rgba(137, 92, 255, 0.25) !important;
    border-radius: 14px !important;
    padding: 18px !important;
    transition: all 0.3s ease !important;
}

.elementor-element-col_products_left ul.products li.product:hover,
.elementor-widget-woocommerce-products ul.products li.product:hover {
    border-color: #d4ff00 !important;
    box-shadow: 0 10px 25px rgba(212, 255, 0, 0.15) !important;
    transform: translateY(-4px) !important;
}

/* Badge harmonization */
.woocommerce span.onsale {
    background: #d4ff00 !important;
    color: #0b071c !important;
    font-weight: 900 !important;
    font-size: 11px !important;
    padding: 4px 10px !important;
    border-radius: 6px !important;
    min-height: auto !important;
    line-height: 1.4 !important;
    top: 14px !important;
    right: 14px !important;
    left: auto !important;
}

/* Image container */
.elementor-element-col_products_left ul.products li.product img {
    border-radius: 10px !important;
    background: #1a1438 !important;
    padding: 10px !important;
    object-fit: contain !important;
    height: 180px !important;
    width: 100% !important;
    margin-bottom: 14px !important;
}

/* Product title */
.elementor-element-col_products_left ul.products li.product .woocommerce-loop-product__title {
    font-size: 14px !important;
    font-weight: 800 !important;
    line-height: 1.6 !important;
    height: 44px !important;
    overflow: hidden !important;
    display: -webkit-box !important;
    -webkit-line-clamp: 2 !important;
    -webkit-box-orient: vertical !important;
    margin-bottom: 12px !important;
    color: #f8fafc !important;
}


/* Force 3 columns override only on desktop */
@media (min-width: 1025px) {
    .elementor-widget-woocommerce-archive-products .woocommerce ul.products,
    .elementor-widget-woocommerce-products .woocommerce ul.products,
    .elementor-element-col_products_left .woocommerce ul.products,
    .elementor-element-col_products_left ul.products,
    .elementor-widget-woocommerce-archive-products ul.products.elementor-grid {
        grid-template-columns: repeat(3, 1fr) !important;
        gap: 20px !important;
    }
}

