/* =============================================================
   CART + CHECKOUT — brand polish on top of WooCommerce defaults
   Scoped to body.woocommerce-cart, body.woocommerce-checkout
   ============================================================= */

:root {
    --lp-cyan: #00ADEE;
    --lp-magenta: #EB008B;
    --lp-yellow: #FFF100;
    --lp-navy: #000082;
    --lp-dark: #0a0a2e;
    --lp-gray-50: #f7f8fa;
    --lp-gray-100: #eef0f4;
    --lp-gray-200: #dde1e8;
    --lp-gray-700: #4a4a5a;
    --lp-radius: 16px;
    --lp-radius-sm: 10px;
}

body.woocommerce-cart, body.woocommerce-checkout {
    background: var(--lp-gray-50);
}

/* Kill the stray dashed border around the Elementor cart wrapper column */
body.woocommerce-cart .elementor-top-column.elementor-col-100,
body.woocommerce-checkout .elementor-top-column.elementor-col-100 {
    border: 0 !important;
}
/* Cart page only — reduce the heavy 102px top padding the Elementor container adds */
body.woocommerce-cart .elementor-container { padding-top: 24px !important; }
body.woocommerce-cart .elementor-top-column.elementor-col-100 { padding-top: 0 !important; }

/* Page header — tone down the loud magenta */
body.woocommerce-cart .page-header,
body.woocommerce-checkout .page-header,
body.woocommerce-cart .elementor-location-header + .elementor-section,
body.woocommerce-cart .entry-title,
body.woocommerce-checkout .entry-title {
    /* leave the existing header alone, but cap height if it's gigantic */
}

/* Main container — white card replacing dashed-border block */
/* Cart-only white card; checkout uses Elementor's e-checkout layout untouched */
body.woocommerce-cart .woocommerce {
    background: #fff;
    border: 1px solid var(--lp-gray-100);
    border-radius: var(--lp-radius);
    padding: 28px 32px;
    box-shadow: 0 8px 30px rgba(0,0,0,0.06);
    margin: 16px auto 48px;
    max-width: 1100px;
}

/* "Added to cart" notice — WC renders a checkmark pseudo-icon at left:24px, so reserve that room */
body.woocommerce-cart .woocommerce-message {
    background: linear-gradient(135deg, rgba(34, 197, 94, 0.08), rgba(0, 173, 238, 0.04));
    border: 1px solid rgba(34, 197, 94, 0.25);
    border-left: 4px solid #22c55e;
    border-radius: var(--lp-radius-sm);
    padding: 14px 18px 14px 54px;
    color: #166534;
    font-family: 'Barlow', sans-serif;
    margin-bottom: 24px;
}
body.woocommerce-cart .woocommerce-message::before {
    color: #22c55e !important;
    left: 22px !important;
    top: 14px !important;
}
body.woocommerce-cart .woocommerce-message .button {
    background: #fff !important;
    border: 2px solid var(--lp-navy) !important;
    color: var(--lp-navy) !important;
    font-family: 'Khand', sans-serif !important;
    font-weight: 600 !important;
    padding: 8px 18px !important;
    border-radius: 8px !important;
    font-size: 0.9rem !important;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    transition: all 0.2s;
}
body.woocommerce-cart .woocommerce-message .button:hover {
    background: var(--lp-navy) !important;
    color: #fff !important;
}

/* Cart table */
body.woocommerce-cart table.cart,
body.woocommerce-cart table.shop_table {
    border: 0;
    border-collapse: collapse;
    width: 100%;
}
body.woocommerce-cart table.cart thead {
    background: transparent;
}
body.woocommerce-cart table.cart thead th,
body.woocommerce-cart table.cart thead th.product-price,
body.woocommerce-cart table.cart thead th.product-subtotal,
body.woocommerce-cart table.cart thead th.product-name,
body.woocommerce-cart table.cart thead th.product-quantity,
body.woocommerce-cart table.cart thead th.product-thumbnail,
body.woocommerce-cart table.cart thead th.product-remove {
    font-family: 'Khand', sans-serif !important;
    font-weight: 600 !important;
    font-size: 0.78rem !important;
    text-transform: uppercase !important;
    letter-spacing: 0.12em !important;
    color: #8b8b9b !important;
    padding: 12px 16px !important;
    border-bottom: 2px solid var(--lp-gray-100) !important;
    background: transparent !important;
    text-align: left !important;
}
/* Hide the screen-reader-only TH content visually (kept for accessibility) */
body.woocommerce-cart table.cart thead th.product-remove,
body.woocommerce-cart table.cart thead th.product-thumbnail {
    font-size: 0 !important;
}
body.woocommerce-cart table.cart tbody td {
    padding: 18px 16px;
    border-top: 1px solid var(--lp-gray-100);
    background: transparent !important;
    vertical-align: middle;
}
body.woocommerce-cart table.cart .product-thumbnail img,
body.woocommerce-cart table.cart .product-thumbnail a img {
    width: 80px !important;
    height: 80px !important;
    object-fit: cover;
    border-radius: var(--lp-radius-sm);
    border: 1px solid var(--lp-gray-100);
}
body.woocommerce-cart table.cart .product-name a {
    font-family: 'Khand', sans-serif;
    font-weight: 700;
    font-size: 1.05rem;
    color: var(--lp-navy) !important;
    text-transform: uppercase;
    letter-spacing: 0.01em;
    text-decoration: none;
    transition: color 0.2s;
}
body.woocommerce-cart table.cart .product-name a:hover {
    color: var(--lp-magenta) !important;
}
body.woocommerce-cart table.cart .product-price,
body.woocommerce-cart table.cart .product-subtotal {
    font-family: 'Barlow', sans-serif;
    font-weight: 600;
    color: var(--lp-dark);
    font-size: 1rem;
}
body.woocommerce-cart table.cart .product-subtotal {
    color: var(--lp-magenta);
    font-weight: 700;
}

/* Remove "x" button */
body.woocommerce-cart table.cart .product-remove a.remove {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--lp-gray-100) !important;
    color: #8b8b9b !important;
    font-size: 1.2rem !important;
    line-height: 26px !important;
    text-align: center;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
body.woocommerce-cart table.cart .product-remove a.remove:hover {
    background: var(--lp-magenta) !important;
    color: #fff !important;
    transform: rotate(90deg);
}

/* Quantity input */
body.woocommerce-cart table.cart .quantity .qty,
body.woocommerce-checkout .quantity .qty {
    width: 70px !important;
    height: 44px !important;
    padding: 8px 10px !important;
    border: 2px solid var(--lp-gray-200) !important;
    border-radius: var(--lp-radius-sm) !important;
    font-family: 'Barlow', sans-serif !important;
    font-weight: 600 !important;
    text-align: center !important;
    transition: border-color 0.2s;
}
body.woocommerce-cart table.cart .quantity .qty:focus,
body.woocommerce-checkout .quantity .qty:focus {
    border-color: var(--lp-cyan) !important;
    outline: none !important;
}

/* Coupon row + Update button — restyle to brand-secondary */
body.woocommerce-cart .actions { padding: 20px 16px !important; border-top: 1px solid var(--lp-gray-100); }
body.woocommerce-cart .coupon { display: flex; gap: 8px; }
body.woocommerce-cart .coupon .input-text {
    padding: 10px 14px !important;
    border: 2px solid var(--lp-gray-200) !important;
    border-radius: var(--lp-radius-sm) !important;
    font-family: 'Barlow', sans-serif !important;
    width: 200px !important;
    transition: border-color 0.2s;
}
body.woocommerce-cart .coupon .input-text:focus {
    border-color: var(--lp-cyan) !important;
    outline: none !important;
}
body.woocommerce-cart .button:not(.checkout-button):not(.single_add_to_cart_button),
body.woocommerce-cart [name="apply_coupon"],
body.woocommerce-cart [name="update_cart"] {
    background: #fff !important;
    border: 2px solid var(--lp-navy) !important;
    color: var(--lp-navy) !important;
    font-family: 'Khand', sans-serif !important;
    font-weight: 600 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.04em !important;
    padding: 10px 22px !important;
    border-radius: var(--lp-radius-sm) !important;
    font-size: 0.95rem !important;
    cursor: pointer;
    transition: all 0.2s;
    box-shadow: none !important;
    text-shadow: none !important;
}
body.woocommerce-cart .button:not(.checkout-button):not(.single_add_to_cart_button):hover,
body.woocommerce-cart [name="apply_coupon"]:hover,
body.woocommerce-cart [name="update_cart"]:hover {
    background: var(--lp-navy) !important;
    color: #fff !important;
}

/* Cart totals card — horizontal layout so the Finalizar button sits right next to the totals (less scrolling) */
body.woocommerce-cart .cart-collaterals {
    max-width: 100% !important;
    width: 100% !important;
    float: none !important;
}
body.woocommerce-cart .cart_totals {
    background: linear-gradient(135deg, rgba(0, 173, 238, 0.04), rgba(235, 0, 139, 0.04));
    border: 1px solid var(--lp-gray-100);
    border-radius: var(--lp-radius);
    padding: 24px 32px 28px;
    margin-top: 32px;
    position: relative;
    overflow: hidden;
    width: 100% !important;
    max-width: 100% !important;
    float: none !important;
    display: grid;
    grid-template-columns: minmax(260px, auto) 1fr;
    gap: 16px 48px;
    align-items: center;
}
body.woocommerce-cart .cart_totals h2 {
    grid-column: 1 / -1;
    font-family: 'Khand', sans-serif !important;
    font-weight: 600 !important;
    font-size: 0.78rem !important;
    letter-spacing: 0.12em !important;
    text-transform: uppercase !important;
    color: #8b8b9b !important;
    margin: 0 !important;
    padding: 0 !important;
}
body.woocommerce-cart .cart_totals table {
    grid-column: 1;
    border: 0;
    margin: 0;
    width: 100%;
    display: block;
}
body.woocommerce-cart .cart_totals table tbody {
    display: block;
}
body.woocommerce-cart .cart_totals table tr {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 40px;
    padding: 6px 0 !important;
    border: 0 !important;
}
body.woocommerce-cart .cart_totals table th {
    background: transparent !important;
    border: 0 !important;
    padding: 0 !important;
    width: auto !important;
    font-family: 'Khand', sans-serif !important;
    font-weight: 600;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #6b6b7b;
}
body.woocommerce-cart .cart_totals table td {
    background: transparent !important;
    border: 0 !important;
    padding: 0 !important;
    text-align: right;
    font-family: 'Barlow', sans-serif;
    font-weight: 600;
    font-size: 1rem;
    color: var(--lp-dark);
}
body.woocommerce-cart .cart_totals table .order-total {
    border-top: 1px dashed var(--lp-gray-200) !important;
    padding-top: 14px !important;
    margin-top: 6px;
}
body.woocommerce-cart .cart_totals table .order-total th {
    color: var(--lp-navy);
    font-size: 1rem;
}
body.woocommerce-cart .cart_totals table .order-total td {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 2px;
}
body.woocommerce-cart .cart_totals .wc-proceed-to-checkout {
    grid-column: 2;
    grid-row: 2;
    justify-self: end;
    min-width: 280px;
    padding: 0 !important;
    margin: 0 !important;
}
@media (max-width: 760px) {
    body.woocommerce-cart .cart_totals {
        grid-template-columns: 1fr;
        padding: 22px;
    }
    body.woocommerce-cart .cart_totals .wc-proceed-to-checkout {
        grid-column: 1;
        grid-row: auto;
        justify-self: stretch;
        min-width: 0;
    }
}
body.woocommerce-cart .cart_totals::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--lp-cyan), var(--lp-magenta), var(--lp-yellow));
}
/* (Old cart_totals h2 rule superseded by the horizontal-layout definitions below) */
body.woocommerce-cart .cart_totals table {
    border: 0;
    width: 100%;
    margin-bottom: 18px;
}
body.woocommerce-cart .cart_totals table th,
body.woocommerce-cart .cart_totals table td {
    background: transparent !important;
    border: 0 !important;
    padding: 10px 0 !important;
    font-family: 'Barlow', sans-serif;
}
body.woocommerce-cart .cart_totals table th {
    font-family: 'Khand', sans-serif;
    font-weight: 600;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #6b6b7b;
    text-align: left;
    width: 50%;
}
body.woocommerce-cart .cart_totals .order-total {
    border-top: 1px dashed var(--lp-gray-200) !important;
    padding-top: 14px !important;
}
body.woocommerce-cart .cart_totals .order-total th {
    color: var(--lp-navy);
    font-size: 1rem;
}
body.woocommerce-cart .cart_totals .order-total td > .amount,
body.woocommerce-cart .cart_totals .order-total td > strong > .amount {
    font-family: 'Khand', sans-serif;
    font-weight: 800;
    font-size: 1.6rem;
    background: linear-gradient(135deg, var(--lp-magenta), #ff1493);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1;
    display: inline-block;
}
body.woocommerce-cart .cart_totals .tax_label,
body.woocommerce-cart .cart_totals .order-total small,
body.woocommerce-cart .cart_totals .includes_tax,
body.woocommerce-cart .cart_totals small {
    display: block !important;
    font-family: 'Barlow', sans-serif !important;
    font-size: 0.78rem !important;
    color: #999 !important;
    font-weight: 500 !important;
    margin-top: 4px !important;
}
body.woocommerce-cart .cart_totals small .amount {
    font-family: 'Barlow', sans-serif !important;
    font-size: 0.78rem !important;
    color: #999 !important;
    font-weight: 500 !important;
    background: none !important;
    -webkit-text-fill-color: #999 !important;
}
body.woocommerce-cart .cart_totals .checkout-button {
    width: 100%;
    background: var(--lp-navy) !important;
    color: #fff !important;
    font-family: 'Khand', sans-serif !important;
    font-weight: 700 !important;
    font-size: 1.25rem !important;
    text-transform: uppercase !important;
    letter-spacing: 0.04em !important;
    padding: 18px 24px !important;
    border-radius: var(--lp-radius-sm) !important;
    border: none !important;
    box-shadow: -4px 4px 0 var(--lp-magenta), 4px -4px 0 var(--lp-yellow) !important;
    cursor: pointer;
    transition: all 0.25s;
    text-align: center;
    display: block;
    margin-top: 12px;
}
body.woocommerce-cart .cart_totals .checkout-button:hover {
    background: var(--lp-yellow) !important;
    color: var(--lp-navy) !important;
    box-shadow: 4px 4px 0 var(--lp-magenta), -4px -4px 0 var(--lp-navy) !important;
}

/* Two-column cart layout (table left, totals right) on desktop */
@media (min-width: 900px) {
    body.woocommerce-cart .woocommerce-cart-form {
        float: none;
        width: 100%;
    }
    body.woocommerce-cart .cart-collaterals {
        width: 100% !important;
        max-width: 480px;
        margin-left: auto !important;
    }
    body.woocommerce-cart .cart-collaterals .cart_totals { width: 100% !important; float: none !important; }
}

/* =============================================================
   COMPACT MICROTRUST — sits *below* the Finalizar Compra button only
   (no front-loaded doubt triggers; just a quick "you're safe" signal at the click moment)
   ============================================================= */
.lp-checkout-microtrust {
    display: flex;
    flex-wrap: wrap;
    gap: 14px 18px;
    align-items: center;
    justify-content: center;
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px dashed var(--lp-gray-200);
    font-size: 0.78rem;
    color: #6b6b7b;
}
.lp-checkout-microtrust span {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-weight: 600;
}
.lp-checkout-microtrust span svg {
    color: #22c55e;
    flex-shrink: 0;
}
.lp-checkout-microtrust__wa {
    color: var(--lp-cyan);
    font-weight: 600;
    text-decoration: none;
    margin-left: auto;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}
.lp-checkout-microtrust__wa::before {
    content: '›';
    font-weight: 700;
}
.lp-checkout-microtrust__wa:hover { color: var(--lp-magenta); }

/* =============================================================
   CHECKOUT — keep Elementor's own e-checkout layout, just polish the place-order button
   ============================================================= */
body.woocommerce-checkout #place_order {
    width: 100%;
    background: var(--lp-navy) !important;
    color: #fff !important;
    font-family: 'Khand', sans-serif !important;
    font-weight: 700 !important;
    font-size: 1.2rem !important;
    text-transform: uppercase !important;
    letter-spacing: 0.04em !important;
    padding: 16px 24px !important;
    border-radius: var(--lp-radius-sm) !important;
    border: none !important;
    box-shadow: -4px 4px 0 var(--lp-magenta), 4px -4px 0 var(--lp-yellow) !important;
    cursor: pointer;
    transition: all 0.25s;
    margin-top: 12px;
}
body.woocommerce-checkout #place_order:hover {
    background: var(--lp-yellow) !important;
    color: var(--lp-navy) !important;
    box-shadow: 4px 4px 0 var(--lp-magenta), -4px -4px 0 var(--lp-navy) !important;
}

/* (Sticky "ir para pagamento" bar removed — keeps the checkout quiet and action-focused) */

@media (max-width: 768px) {
    body.woocommerce-cart .woocommerce,
    body.woocommerce-checkout .woocommerce {
        padding: 18px;
        margin: 16px;
    }
    .lp-cart-reassure { grid-template-columns: 1fr; gap: 20px; padding: 20px; margin: 0 16px 20px; }
    .lp-cart-trust-badges { padding: 0 16px; gap: 10px; }
    body.woocommerce-cart .coupon { flex-direction: column; }
    body.woocommerce-cart .coupon .input-text { width: 100% !important; }
    body.woocommerce-cart table.cart thead { display: none; }
    body.woocommerce-cart table.cart tbody td { display: block; padding: 8px 0 !important; border: 0 !important; }
    body.woocommerce-cart table.cart tbody td.product-thumbnail { padding-top: 16px !important; }
    body.woocommerce-cart table.cart tbody tr.cart_item { border-bottom: 2px solid var(--lp-gray-100); padding-bottom: 16px; display: block; }
    body.woocommerce-cart .cart-collaterals { max-width: 100%; }
    body.woocommerce-cart .cart_totals { padding: 22px; }
}
