.cocos-floating-cart {
    position: fixed !important;
    right: max(18px, env(safe-area-inset-right));
    bottom: max(20px, calc(env(safe-area-inset-bottom) + 12px));
    z-index: 9990;
    display: flex !important;
    align-items: center;
    justify-content: center;
    width: 62px;
    height: 62px;
    box-sizing: border-box;
    border: 2px solid #f0c894;
    border-radius: 50%;
    background: #332b26 !important;
    color: #f0c894 !important;
    box-shadow: 0 10px 26px rgba(48, 39, 33, .22);
    text-decoration: none !important;
    -webkit-tap-highlight-color: transparent;
    transition: transform .18s ease, box-shadow .18s ease, background-color .18s ease;
}
.cocos-floating-cart:hover {
    background: #413731 !important;
    box-shadow: 0 12px 28px rgba(48, 39, 33, .28);
    transform: translateY(-1px);
}
.cocos-floating-cart:focus-visible { outline: 3px solid #a65f36; outline-offset: 4px; }
.cocos-floating-cart svg { flex: none; width: 26px; height: 26px; }
.cocos-floating-count {
    position: absolute;
    top: -6px;
    right: -2px;
    min-width: 24px;
    height: 24px;
    padding: 0 6px;
    box-sizing: border-box;
    display: grid;
    place-items: center;
    border: 2px solid #fff;
    border-radius: 999px;
    background: #f0c894;
    color: #2f2824;
    font: 700 12px/1 system-ui, sans-serif;
    box-shadow: 0 4px 10px rgba(48, 39, 33, .15);
}
.cocos-cart-announcement {
    position: absolute; width: 1px; height: 1px; padding: 0;
    margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}
body:has(.cocos-floating-cart) { padding-bottom: max(88px, calc(env(safe-area-inset-bottom) + 80px)); }
html.cocos-order-open .cocos-floating-cart { visibility: hidden; }
@media (max-width: 600px) {
    .cocos-floating-cart {
        width: 58px;
        height: 58px;
        right: max(14px, env(safe-area-inset-right));
        bottom: max(16px, calc(env(safe-area-inset-bottom) + 10px));
    }
}

/* Cart-page visual improvements */
.woocommerce-cart table.shop_table_responsive td.product-remove,
.woocommerce-cart table.shop_table td.product-remove {
    width: auto;
    text-align: left !important;
    padding-bottom: 10px;
}
.woocommerce-cart a.remove {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    margin: 0;
    border-radius: 50%;
    border: 1px solid #e4d6c5;
    background: #fff;
    color: #b23333 !important;
    font-size: 26px;
    font-weight: 500;
    line-height: 1;
    text-decoration: none !important;
    box-shadow: 0 4px 12px rgba(48, 39, 33, .08);
    transition: transform .18s ease, box-shadow .18s ease, background-color .18s ease;
}
.woocommerce-cart a.remove:hover,
.woocommerce-cart a.remove:focus {
    background: #fff5f5;
    color: #962525 !important;
    box-shadow: 0 6px 14px rgba(48, 39, 33, .12);
    transform: scale(1.04);
}
.woocommerce-cart a.remove:focus-visible {
    outline: 2px solid #a65f36;
    outline-offset: 3px;
}

/* Hide the manual update only when the auto-update script is initialized. */
.woocommerce-cart-form.cocos-cart-auto [name="update_cart"] { display: none !important; }
.woocommerce-cart-form.cocos-cart-auto tr:has(> td.actions > [name="update_cart"]):not(:has(> td.actions > :not([name="update_cart"]):not(input[type="hidden"]))) { display: none !important; }
.cocos-cart-update-status { font-size: .9em; margin: .5em 0; }
.cocos-cart-update-status[hidden] { display: none !important; }

/* Bilingual free-shipping offer, within the AJAX-replaced cart totals. */
.cocos-shipping-offer { display: flex; align-items: flex-start; gap: 12px; margin: 0 0 16px; padding: 14px; border: 1px solid #d7ba91; border-radius: 10px; background: #faf2e6; color: #382e27; box-sizing: border-box; }
.cocos-shipping-icon { flex: 0 0 26px; margin-top: 2px; color: #77552e; }
.cocos-shipping-copy { flex: 1; min-width: 0; font-size: .95rem; line-height: 1.5; }
.cocos-shipping-copy > strong, .cocos-shipping-copy > span { display: block; }
.cocos-shipping-copy > span[lang="ar"] { text-align: start; margin-top: 5px; }
.cocos-shipping-shop { display: inline-block; margin-top: 9px; padding: 8px 12px; background: #382e27; color: #fff !important; border-radius: 6px; text-decoration: none !important; font-size: .85rem; font-weight: 600; }
.cocos-shipping-shop:focus-visible { outline: 2px solid #77552e; outline-offset: 3px; }
.cocos-shipping-earned { background: #f1f7ef; border-color: #a9c3a2; color: #254c2c; }
.cocos-shipping-earned .cocos-shipping-icon { color: #32673a; }

/* Keep the offer immediately above the checkout button, even with themed alignment. */
.wc-proceed-to-checkout .cocos-shipping-offer { width: 100%; text-align: start; }
