/* =============================================================================
   WooCommerce Cart Page
   ============================================================================= */

.woocommerce-cart {
    margin: 0 auto;
}

.woocommerce-cart .woocommerce {
    max-width: 1240px;
    margin: 0 auto;
}

/* -----------------------------------------------------------------------------
   Cart Table
   ----------------------------------------------------------------------------- */
.woocommerce-cart table.shop_table {
    border: 1px solid #d4eeff;
    border-radius: 8px;
    overflow: hidden;
}

.woocommerce-cart table.shop_table thead {
    background: #eef6ff;
}

.woocommerce-cart table.shop_table thead th {
    padding: 1rem;
    font-weight: 600;
    color: #00274c;
    border-bottom: 2px solid #d4eeff;
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.woocommerce-cart table.shop_table tbody tr {
    border-bottom: 1px solid #d4eeff;
}

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

.woocommerce-cart table.shop_table td {
    padding: 1.5rem 1rem;
    vertical-align: middle;
}

.woocommerce-cart table.shop_table .product-thumbnail img {
    border-radius: 8px;
    max-width: 80px;
    height: auto;
}

.woocommerce-cart table.shop_table .product-name a {
    color: #00274c;
    font-weight: 600;
    text-decoration: none;
    transition: color 0.2s;
}

.woocommerce-cart table.shop_table .product-name a:hover {
    color: #0064cf;
}

.woocommerce-cart table.shop_table .product-price,
.woocommerce-cart table.shop_table .product-subtotal {
    font-weight: 600;
    color: #00274c;
}

.woocommerce-cart table.shop_table .product-remove a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    color: #6c4659;
    font-size: 1.5rem;
    text-decoration: none;
    transition: color 0.2s;
}

.woocommerce-cart table.shop_table .product-remove a:hover {
    color: #0064cf;
}

/* -----------------------------------------------------------------------------
   Quantity Input
   ----------------------------------------------------------------------------- */
.woocommerce-cart .quantity input.qty {
    width: 80px;
    padding: 0.5rem;
    border: 2px solid #0064cf;
    border-radius: 8px;
    text-align: center;
    font-weight: 600;
    transition: border-color 0.2s;
}

.woocommerce-cart .quantity input.qty:focus {
    outline: none;
    border-color: #0064cf;
    box-shadow: 0 0 0 3px rgba(0, 100, 207, 0.1);
}

/* -----------------------------------------------------------------------------
   Cart Actions Wrapper
   ----------------------------------------------------------------------------- */
.woocommerce-cart .cart-actions-wrapper {
    display: flex;
    justify-content: flex-end;
}

/* Show button when loading or disabled states */
.woocommerce-cart button[name="update_cart"].loading {
    display: inline-flex;
    padding: 0.875rem 2.5rem;
    border-radius: 100px;
    font-weight: 600;
    font-size: 1rem;
    border: none;
    background-color: #0064cf;
    color: #fff;
    min-width: 220px;
    opacity: 0.7;
    cursor: wait;
}

/* -----------------------------------------------------------------------------
   Cart Collaterals (Cart Totals)
   ----------------------------------------------------------------------------- */
.woocommerce-cart .cart-collaterals {
    display: flex;
    justify-content: flex-end;
    margin-top: 2rem;
}

.woocommerce-cart .cart_totals {
    width: 100%;
    max-width: 500px;
}

.woocommerce-cart .cart_totals h2 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #00274c;
    margin-bottom: 1.5rem;
}

.woocommerce-cart .cart_totals table {
    width: 100%;
    border: 1px solid #d4eeff;
    border-radius: 8px;
    overflow: hidden;
}

.woocommerce-cart .cart_totals table th,
.woocommerce-cart .cart_totals table td {
    padding: 1rem;
    border-bottom: 1px solid #d4eeff;
}

.woocommerce-cart .cart_totals table th {
    text-align: left;
    font-weight: 600;
    color: #00274c;
    width: 50%;
}

.woocommerce-cart .cart_totals table td {
    text-align: right;
    font-weight: 600;
}

.woocommerce-cart .cart_totals .order-total th,
.woocommerce-cart .cart_totals .order-total td {
    font-size: 1.25rem;
    color: #0064cf;
    border-bottom: none;
}

.woocommerce-cart .wc-proceed-to-checkout {
    padding: 1.5rem 0 0;
}

.woocommerce-cart .wc-proceed-to-checkout a.checkout-button {
    display: block;
    width: 100%;
    text-align: center;
    padding: 1rem 2rem;
    background-color: #0064cf;
    color: #fff;
    text-decoration: none;
    border-radius: 100px;
    font-weight: 600;
    transition: background-color 0.2s;
}

.woocommerce-cart .wc-proceed-to-checkout a.checkout-button:hover {
    background-color: #005bb5;
}

/* -----------------------------------------------------------------------------
   Empty Cart
   ----------------------------------------------------------------------------- */
.woocommerce-cart .cart-empty {
    text-align: center;
    padding: 3rem 1rem;
    color: #6c4659;
}

.woocommerce-cart .return-to-shop {
    text-align: center;
    margin-top: 2rem;
}

.woocommerce-cart .return-to-shop a {
    display: inline-block;
    padding: 0.75rem 2rem;
    background-color: #0064cf;
    color: #fff;
    text-decoration: none;
    border-radius: 100px;
    font-weight: 600;
    transition: background-color 0.2s;
}

.woocommerce-cart .return-to-shop a:hover {
    background-color: #005bb5;
}

/* -----------------------------------------------------------------------------
   Mobile Responsiveness
   ----------------------------------------------------------------------------- */
@media (max-width: 768px) {
    .woocommerce-cart .woocommerce {
        padding-left: 1rem;
        padding-right: 1rem;
    }

    .woocommerce-cart table.shop_table {
        border: none;
    }

    .woocommerce-cart table.shop_table thead {
        display: none;
    }

    .woocommerce-cart table.shop_table tbody tr {
        display: block;
        margin-bottom: 1.5rem;
        border: 1px solid #d4eeff;
        border-radius: 8px;
        padding: 1rem;
    }

    .woocommerce-cart table.shop_table tbody td {
        display: block;
        padding: 0.5rem 0;
        border: none;
    }

    .woocommerce-cart table.shop_table tbody td::before {
        content: attr(data-title) ": ";
        font-weight: 600;
        display: inline-block;
        margin-right: 0.5rem;
    }

    .woocommerce-cart table.shop_table .product-thumbnail {
        text-align: center;
        margin-bottom: 1rem;
    }

    .woocommerce-cart table.shop_table .product-thumbnail::before {
        display: none;
    }

    .woocommerce-cart .cart-collaterals {
        margin-top: 1.5rem;
    }

    .woocommerce-cart .cart_totals {
        max-width: 100%;
    }
}
