
/* Classic WooCommerce cart: local styles, native forms and validation. */
/* Shipping choices remain available at checkout; keep native calculations. */
body.woocommerce-cart .cart_totals .woocommerce-shipping-totals { display:none; }
body.woocommerce-cart .blog-article { max-width:none; border:0; border-radius:0; padding:0; box-shadow:none; }
body.woocommerce-cart .blog-single-main { background:var(--tw-surface); }
body.woocommerce-cart .entry-content > .woocommerce { display:grid; grid-template-columns:minmax(0,2fr) minmax(280px,1fr); gap:24px; align-items:start; }
body.woocommerce-cart .woocommerce-notices-wrapper, body.woocommerce-cart .cart-empty, body.woocommerce-cart .return-to-shop { grid-column:1 / -1; }
body.woocommerce-cart .woocommerce-cart-form, body.woocommerce-cart .cart-collaterals { padding:0; border:0; border-radius:0; background:var(--tw-surface); min-width:0; }
body.woocommerce-cart .cart-collaterals { width:100%; max-width:none; justify-self:stretch; }
body.woocommerce-cart .woocommerce table.shop_table { border:0; border-collapse:collapse; margin:0; }
body.woocommerce-cart .woocommerce table.shop_table th { padding:12px 8px; background:transparent; border:0; border-bottom:1px solid var(--tw-border); font-size:13px; }
body.woocommerce-cart .woocommerce table.shop_table td { padding:14px 8px; border:0; border-bottom:1px solid var(--tw-border); vertical-align:middle; font-size:13px; }
body.woocommerce-cart .woocommerce .product-thumbnail img { width:75px; max-width:75px; height:auto; border-radius:8px; }
body.woocommerce-cart .woocommerce .product-name a { color:var(--tw-text); text-decoration:none; font-weight:700; }
body.woocommerce-cart .woocommerce .quantity input { width:65px; padding:8px; border:1px solid var(--tw-border); border-radius:8px; font:inherit; }
body.woocommerce-cart .woocommerce .cart-collaterals .cart_totals { float:none; width:100%; }
body.woocommerce-cart .cart_totals h2 { font-size:20px; margin:0 0 16px; }
body.woocommerce-cart .woocommerce .coupon { display:flex; gap:8px; flex-wrap:wrap; }
body.woocommerce-cart .woocommerce .coupon input.input-text { width:150px; padding:10px; border:1px solid var(--tw-border); border-radius:8px; font:inherit; }
body.woocommerce-cart .woocommerce button.button { padding:12px 16px; border-radius:8px; font:inherit; background:var(--tw-background); color:var(--tw-text); }
body.woocommerce-cart .woocommerce .wc-proceed-to-checkout a.checkout-button { background:var(--tw-buy-color,var(--tw-primary)); color:var(--tw-primary-ink); border-radius:10px; font:700 15px var(--tw-font); padding:16px; margin:0; text-decoration:none; }
body.woocommerce-cart .woocommerce .wc-proceed-to-checkout a.checkout-button:hover { background:var(--tw-buy-color,var(--tw-primary)); filter:brightness(.96); }
body.woocommerce-cart .woocommerce .cart-collaterals { width:auto; }
body.woocommerce-cart .woocommerce .cart-collaterals::before,body.woocommerce-cart .woocommerce .cart-collaterals::after { display:none; }
@media(max-width:900px) { body.woocommerce-cart .entry-content > .woocommerce { grid-template-columns:minmax(0,1fr); } }
@media(max-width:767px) { body.woocommerce-cart .woocommerce-cart-form,body.woocommerce-cart .cart-collaterals { padding:0; } body.woocommerce-cart .woocommerce .coupon { margin-bottom:12px; } }

@media(max-width:768px) {
 body.woocommerce-cart .woocommerce table.shop_table_responsive tr td.product-name { text-align:right !important; }
 body.woocommerce-cart .woocommerce table.shop_table_responsive tr td.product-name::before { float:none; display:block; margin-bottom:6px; }
 body.woocommerce-cart .woocommerce td.product-name a { display:inline; text-align:right; }
}

/* Keep coupon controls together and the update action visible. */
body.woocommerce-cart .woocommerce table.cart td.actions .coupon { display:flex; flex-wrap:nowrap; align-items:stretch; gap:8px; }
body.woocommerce-cart .woocommerce table.cart td.actions .coupon input.input-text { flex:1 1 140px; min-width:0; width:140px; float:none; margin:0; }
body.woocommerce-cart .woocommerce table.cart td.actions .coupon button.button { flex:0 0 auto; width:auto!important; float:none; margin:0; white-space:nowrap; }
body.woocommerce-cart .woocommerce button[name="update_cart"] { background:var(--tw-buy-color,var(--tw-primary)); color:var(--tw-primary-ink); border:1px solid var(--tw-border); font-weight:700; }
body.woocommerce-cart .woocommerce button[name="update_cart"]:disabled { background:#e4e8ed; color:#59616c; opacity:1; cursor:not-allowed; }
body.woocommerce-cart .tw-cart-quantity { display:inline-flex; flex-direction:column; align-items:stretch; width:64px; border:1px solid var(--tw-border); border-radius:8px; overflow:hidden; background:var(--tw-surface); }
body.woocommerce-cart .tw-cart-quantity button { border:0; background:var(--tw-background); color:var(--tw-text); min-height:30px; padding:0; font:700 20px var(--tw-font); cursor:pointer; }
body.woocommerce-cart .woocommerce .tw-cart-quantity input.qty { box-sizing:border-box; width:100%; border:0; border-radius:0; text-align:center; padding:5px 0; appearance:textfield; -moz-appearance:textfield; }
body.woocommerce-cart .tw-cart-quantity input::-webkit-inner-spin-button,body.woocommerce-cart .tw-cart-quantity input::-webkit-outer-spin-button { -webkit-appearance:none; margin:0; }
body.woocommerce-cart .tw-cart-quantity button:focus-visible { outline:2px solid var(--tw-primary); outline-offset:-2px; }
@media(max-width:768px) { body.woocommerce-cart .woocommerce table.cart td.actions .coupon { width:100%; } }

/* Compact mobile cart: image on the right, details on the left. */
@media(max-width:768px) {
 body.woocommerce-cart .woocommerce table.shop_table_responsive tr.cart_item { display:grid; direction:ltr; grid-template-columns:minmax(0,1fr) 82px; grid-template-areas:"name image" "price remove" "quantity ." "subtotal ."; column-gap:12px; position:relative; padding:14px 0; border-bottom:1px solid var(--tw-border); }
 body.woocommerce-cart .woocommerce table.shop_table_responsive tr.cart_item td { background:transparent!important; border:0; padding:8px 0; min-width:0; direction:rtl; }
 body.woocommerce-cart .woocommerce table.shop_table_responsive tr.cart_item td.product-thumbnail { display:flex!important; grid-area:image; align-self:start; align-items:flex-start; justify-content:center; }
 body.woocommerce-cart .woocommerce table.shop_table_responsive tr.cart_item td.product-thumbnail::before,body.woocommerce-cart .woocommerce table.shop_table_responsive tr.cart_item td.product-name::before,body.woocommerce-cart .woocommerce table.shop_table_responsive tr.cart_item td.product-remove::before { display:none; }
 body.woocommerce-cart .woocommerce table.shop_table_responsive tr.cart_item td.product-name { grid-area:name; padding-left:0; font-size:13px; line-height:1.8; }
 body.woocommerce-cart .woocommerce table.shop_table_responsive tr.cart_item td.product-remove { position:static; grid-area:remove; align-self:start; justify-self:center; padding:0; }
 body.woocommerce-cart .woocommerce table.shop_table_responsive tr.cart_item td.product-price { grid-area:price; }
 body.woocommerce-cart .woocommerce table.shop_table_responsive tr.cart_item td.product-quantity { grid-area:quantity; border-block:1px dashed var(--tw-border); }
 body.woocommerce-cart .woocommerce table.shop_table_responsive tr.cart_item td.product-subtotal { grid-area:subtotal; }
 body.woocommerce-cart .woocommerce table.shop_table_responsive tr.cart_item td:is(.product-price,.product-quantity,.product-subtotal) { display:flex; align-items:center; justify-content:space-between; gap:8px; }
 body.woocommerce-cart .woocommerce table.shop_table_responsive tr.cart_item td::before { float:none; font-weight:400; color:var(--tw-muted); }
 body.woocommerce-cart .woocommerce td.product-subtotal .amount { color:var(--tw-primary); font-weight:700; }
 body.woocommerce-cart .woocommerce .product-thumbnail img { width:82px; max-width:100%; }
 body.woocommerce-cart .tw-cart-quantity { flex-direction:row; direction:ltr; width:110px; flex-shrink:0; border-radius:4px; }
 body.woocommerce-cart .tw-cart-quantity button { flex:0 0 32px; min-height:34px; font-size:18px; }
 body.woocommerce-cart .woocommerce .tw-cart-quantity input.qty { width:44px; min-width:0; border-inline:1px solid var(--tw-border); }
 body.woocommerce-cart .woocommerce-cart-form { padding:0; }
}

/* Cart tables are not editorial tables: avoid nested boxes and word breaking. */
body.woocommerce-cart .woocommerce table.shop_table tbody tr { background:transparent; }
@media(min-width:901px) {
 body.woocommerce-cart .woocommerce .woocommerce-cart-form { padding:18px; border:1px solid var(--tw-border); border-radius:10px; box-sizing:border-box; }
 body.woocommerce-cart .woocommerce .cart-collaterals { padding:18px; border:1px solid var(--tw-border); border-radius:10px; }
}
body.woocommerce-cart .woocommerce .amount, body.woocommerce-cart .woocommerce .amount bdi, body.woocommerce-cart .woocommerce .woocommerce-Price-currencySymbol { white-space:nowrap; overflow-wrap:normal; word-break:normal; }
@media(min-width:769px) {
 body.woocommerce-cart .woocommerce table.cart :is(.product-price,.product-subtotal,.product-quantity) { width:1%; white-space:nowrap; padding-inline:8px; }
 body.woocommerce-cart .woocommerce table.cart .product-name { width:auto; }
}
@media(max-width:768px) {
 body.woocommerce-cart .blog-single-main > .container { width:calc(100% - 24px); }
 body.woocommerce-cart .woocommerce table.shop_table_responsive tr.cart_item { column-gap:10px; grid-template-columns:minmax(0,1fr) 72px; }
 body.woocommerce-cart .woocommerce table.shop_table_responsive tr.cart_item td::before { white-space:nowrap; flex-shrink:0; }
 body.woocommerce-cart .woocommerce .product-thumbnail img { width:72px; }
 body.woocommerce-cart .woocommerce .amount { font-size:12px; }
 body.woocommerce-cart .woocommerce table.shop_table_responsive tbody tr.cart_item:first-child { border-top:1px solid var(--tw-border); }
 body.woocommerce-cart .woocommerce table.shop_table tbody tr.cart_item:nth-child(odd) { background:#fff; }
 body.woocommerce-cart .woocommerce table.shop_table tbody tr.cart_item:nth-child(even) { background:#f7f8fa; }
}

/* Preserve native removal URL and AJAX handling; add a readable label. */
body.woocommerce-cart .woocommerce .product-remove a.remove { display:inline-flex; align-items:center; justify-content:center; gap:4px; width:auto; height:auto; min-height:32px; padding:2px 4px; color:#c62828!important; background:transparent; white-space:nowrap; font-size:20px; text-decoration:none; }
body.woocommerce-cart .woocommerce .product-remove a.remove::after { content:"حذف"; font-size:12px; font-weight:400; }
body.woocommerce-cart .woocommerce .product-remove a.remove:hover { color:#a31d1d!important; background:#fff1f1; }
