/* ==========================================================================
 * Mini-cart (header side-drawer) — uniform thumbnail box
 *
 * The mini-cart renders standard WooCommerce markup
 * (ul.woocommerce-mini-cart > li.mini_cart_item > a > img). The product images
 * have wildly different native ratios (tall bullets 460x1842, near-square
 * 460x464, etc.), and the default sizing is width x each image's own ratio, so
 * the cart rows come out uneven and the products sit at different scales.
 *
 * Fix: a fixed 72px SQUARE box with object-fit:contain — every thumbnail keeps
 * its original ratio (no distortion), letterboxed inside the same footprint, so
 * rows are consistent. !important beats the theme/WooCommerce widget defaults.
 * ========================================================================== */
ul.woocommerce-mini-cart li.mini_cart_item a img,
ul.woocommerce-mini-cart li.mini_cart_item img.attachment-woocommerce_thumbnail {
	width: 72px !important;
	height: 72px !important;
	max-width: 72px !important;
	object-fit: contain !important;
	/* Same encapsulation as the cart-page / checkout thumbnails: gray backdrop +
	 * padding so the product sits in a uniform box. */
	background: var(--image-bg, #F7F7F7) !important;
	padding: 8px !important;
	box-sizing: border-box !important;
}

/* Mini-cart buttons: the sidebar goes straight to checkout (fewer clicks), so hide
 * the redundant "view cart" button and let תשלום fill the row. The parent theme
 * hardcodes both buttons in its mini-cart template (no hook to unhook), so this is
 * done in CSS; the hidden <a> stays in the markup but is never painted. */
p.woocommerce-mini-cart__buttons .button.wc-forward:not(.checkout) {
	display: none !important;
}
p.woocommerce-mini-cart__buttons .button.checkout {
	width: 100% !important;
	margin: 0 !important;
}

/* Cart page (WooCommerce cart table) — same treatment, larger box + the shared
 * #F7F7F7 backdrop, so line-item thumbnails match the PDP/PLP/mini-cart look. */
.woocommerce-cart-form td.product-thumbnail img,
.woocommerce-cart-form td.product-thumbnail a img {
	width: 96px !important;
	height: 96px !important;
	max-width: 96px !important;
	object-fit: contain !important;
	background: var(--image-bg, #F7F7F7) !important;
	padding: 8px !important;
	box-sizing: border-box !important;
}

/* Checkout page (order-review table thumbnails) — same encapsulated box. */
.woocommerce-checkout .product-item-thumbnail img {
	width: 96px !important;
	height: 96px !important;
	max-width: 96px !important;
	object-fit: contain !important;
	background: var(--image-bg, #F7F7F7) !important;
	padding: 8px !important;
	box-sizing: border-box !important;
}

/* Thank-you page: the order-overview <ul> inherits the theme's generic
 * `ul { margin: 0 20px 0 0 }`, whose 20px right margin knocks it off-centre.
 * Reset it so the box sits full-width/centred in its container. */
ul.woocommerce-order-overview {
	margin-right: 0 !important;
}

/* Order-details table (thank-you / view-order): keep the "× N" quantity right
 * after the product name (adjacent), and isolate its bidi so it renders the
 * same way next to both Hebrew and English names instead of jumping sides. */
.woocommerce-order-details td.product-name .product-quantity {
	unicode-bidi: isolate;
	font-weight: 700;
}
