/**
 * WooCommerce Premium Design System (Cultivarte)
 * FORCED HIGH PRIORITY STYLES
 */

/* 1. Global Page Wrapper for Cart/Checkout */
body.woocommerce-cart,
body.woocommerce-checkout {
    background-color: #fcfdfc !important;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif !important;
    color: #2C3E50 !important;
}

/* 2. Page Title Overhaul */
.woocommerce-cart h1.page-title,
.woocommerce-checkout h1.entry-title {
    font-size: 38px !important;
    font-weight: 900 !important;
    color: #2A662E !important;
    text-align: center !important;
    margin: 40px 0 60px !important;
    letter-spacing: -1px !important;
}

/* 3. Shop Table (Cart) Transformation */
.woocommerce-cart table.shop_table {
    border: none !important;
    border-radius: 20px !important;
    background: #ffffff !important;
    box-shadow: 0 10px 40px rgba(42, 102, 46, 0.06) !important;
    overflow: hidden !important;
    margin-bottom: 40px !important;
}

.woocommerce-cart table.shop_table thead th {
    background: #f8faf8 !important;
    color: #2A662E !important;
    text-transform: uppercase !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    padding: 25px !important;
    border-bottom: 2px solid #eaf3ea !important;
}

.woocommerce-cart table.shop_table td {
    padding: 30px 25px !important;
    border-bottom: 1px solid #f0f0f0 !important;
    vertical-align: middle !important;
}

.woocommerce-cart table.shop_table td.product-thumbnail img {
    border-radius: 12px !important;
    width: 90px !important;
    height: auto !important;
}

.woocommerce-cart table.shop_table td.product-name a {
    font-size: 18px !important;
    font-weight: 800 !important;
    color: #1a1a1a !important;
    text-decoration: none !important;
    transition: color 0.3s ease !important;
}

.woocommerce-cart table.shop_table td.product-name a:hover {
    color: #2A662E !important;
}

/* 4. Cart Totals (Sticky Premium Card) */
.cart-collaterals {
    margin-top: 0 !important;
}

.cart_totals {
    background: #ffffff !important;
    border-radius: 24px !important;
    padding: 35px !important;
    border: 2px solid #2A662E !important;
    /* Borde corporativo activo */
    box-shadow: 0 15px 50px rgba(42, 102, 46, 0.12) !important;
}

.cart_totals h2 {
    font-size: 24px !important;
    font-weight: 900 !important;
    color: #2A662E !important;
    margin-bottom: 25px !important;
    border-bottom: 2px solid #f0f0f0 !important;
    padding-bottom: 15px !important;
}

/* High Contrast Finalizar Compra Button */
.wc-proceed-to-checkout a.checkout-button,
#place_order {
    background-color: #2A662E !important;
    /* Verde Cultivarte */
    color: #ffffff !important;
    font-size: 20px !important;
    font-weight: 900 !important;
    text-transform: uppercase !important;
    padding: 22px !important;
    border-radius: 14px !important;
    text-align: center !important;
    display: block !important;
    width: 100% !important;
    border: none !important;
    box-shadow: 0 8px 25px rgba(42, 102, 46, 0.4) !important;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275) !important;
    margin-top: 20px !important;
    cursor: pointer !important;
}

.wc-proceed-to-checkout a.checkout-button:hover,
#place_order:hover {
    background-color: #1e4a21 !important;
    transform: translateY(-5px) scale(1.02) !important;
    box-shadow: 0 12px 35px rgba(42, 102, 46, 0.5) !important;
}

/* 5. Trust Badges in Cart (Phase 9) */
.cultivarte-cart-trust-box {
    background: #f8faf8 !important;
    margin-top: 25px !important;
    padding: 20px !important;
    border-radius: 16px !important;
    text-align: center !important;
}

.cultivarte-checkout-badges {
    display: flex !important;
    justify-content: center !important;
    gap: 12px !important;
    margin-bottom: 10px !important;
}

.trust-badge {
    padding: 8px 14px !important;
    border-radius: 30px !important;
    font-size: 12px !important;
    font-weight: 800 !important;
    letter-spacing: 0.5px !important;
}

.badge-webpay {
    background: #13223f !important;
    color: #fff !important;
}

.badge-transbank {
    background: #e31837 !important;
    color: #fff !important;
}

/* 6. Form Optimization (Checkout) */
.woocommerce-checkout #customer_details {
    padding: 40px !important;
    background: #fff !important;
    border-radius: 24px !important;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.04) !important;
}

.woocommerce-checkout #order_review {
    padding: 40px !important;
    background: rgba(255, 255, 255, 0.8) !important;
    backdrop-filter: blur(15px) !important;
    -webkit-backdrop-filter: blur(15px) !important;
    border-radius: 24px !important;
    border: 1px solid rgba(42, 102, 46, 0.1) !important;
}

.woocommerce form .form-row input.input-text {
    height: 55px !important;
    border-radius: 12px !important;
    border: 2px solid #eee !important;
    padding: 10px 20px !important;
    font-size: 16px !important;
    background: #fafafa !important;
    transition: all 0.3s ease !important;
}

.woocommerce form .form-row input.input-text:focus {
    border-color: #2A662E !important;
    background: #fff !important;
    box-shadow: 0 0 0 4px rgba(42, 102, 46, 0.1) !important;
}

/* 7. Mobile Experience */
@media (max-width: 768px) {
    .woocommerce-cart table.shop_table td {
        padding: 20px !important;
    }

    .woocommerce-cart table.shop_table_responsive tr td::before {
        color: #2A662E !important;
        font-weight: 900 !important;
        text-transform: uppercase !important;
    }

    .cart_totals {
        padding: 25px !important;
    }
}