/*
 * Cart page (includes/cart.php, templates/cart/*): items list beside an order summary that stays in view.
 * RTL with logical properties: the items column is first (right), the summary second (left); in each item the image
 * sits at the start (right) and the remove link at the end of the name row; the stepper reads − value + from the
 * right, like the product page and the side cart.
 * Every rule starts with body.woocommerce-cart: the page template's content widget styles all h2 (40px) and links
 * (underlined) inside page content with three classes, and these must win (as checkout.css does).
 */

/* ---------- Layout ---------- */
body.woocommerce-cart .woocommerce:has(> .woocommerce-cart-form) {
	display: grid;
	grid-template-columns: minmax(0, 1fr) 380px;
	column-gap: 48px;
	align-items: start;
}
body.woocommerce-cart .woocommerce:has(> .woocommerce-cart-form) > * { grid-column: 1 / -1; }
body.woocommerce-cart .woocommerce:has(> .woocommerce-cart-form) > .woocommerce-cart-form { grid-column: 1; }
body.woocommerce-cart .woocommerce:has(> .woocommerce-cart-form) > .cart-collaterals {
	grid-column: 2;
	grid-row: span 2;
	position: sticky;
	top: 110px; /* Below the sticky header. */
	width: auto;
	margin: 0;
}
body.woocommerce-cart .woocommerce::before,
body.woocommerce-cart .woocommerce::after { display: none; }

/* ---------- Items ---------- */
body.woocommerce-cart .nr-cart__head {
	display: flex;
	align-items: baseline;
	gap: 10px;
	padding-bottom: 16px;
	border-bottom: 1px solid #171717;
}
body.woocommerce-cart .woocommerce h2.nr-cart__heading { margin: 0; font-size: 20px; font-weight: 600; line-height: 28px; }
body.woocommerce-cart .nr-cart__count { font-size: 14px; color: #6d6a65; }

body.woocommerce-cart .nr-cart__items { margin: 0; padding: 0; list-style: none; }
body.woocommerce-cart .nr-cart__item {
	display: grid;
	grid-template-columns: 120px minmax(0, 1fr);
	gap: 24px;
	padding: 24px 0;
	border-bottom: 1px solid #ececec;
}
body.woocommerce-cart .nr-cart__item::before,
body.woocommerce-cart .nr-cart__item::after { content: none; display: none; }

body.woocommerce-cart .nr-cart__thumb a { display: block; }
body.woocommerce-cart .woocommerce .nr-cart__thumb img {
	display: block;
	width: 120px;
	height: 150px;
	object-fit: cover;
	background: #f1f1f1;
	box-shadow: none;
}

body.woocommerce-cart .nr-cart__info { display: flex; flex-direction: column; min-width: 0; }
body.woocommerce-cart .nr-cart__top {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 16px;
}
body.woocommerce-cart .woocommerce .nr-cart__name { font-size: 16px; font-weight: 500; line-height: 24px; }
body.woocommerce-cart .woocommerce .nr-cart__name a { color: #171717; text-decoration: none; }
body.woocommerce-cart .woocommerce .nr-cart__name a:hover,
body.woocommerce-cart .woocommerce .nr-cart__name a:focus-visible { color: #EE2C1F; }

body.woocommerce-cart .woocommerce .nr-cart__remove-link {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	flex: none;
	color: #6d6a65;
	font-size: 13px;
	text-decoration: none;
	transition: color .2s;
}
body.woocommerce-cart .woocommerce .nr-cart__remove-link:hover,
body.woocommerce-cart .woocommerce .nr-cart__remove-link:focus-visible { color: #EE2C1F; }

body.woocommerce-cart .nr-cart__options,
body.woocommerce-cart .nr-cart__unit {
	margin: 6px 0 0;
	font-size: 14px;
	line-height: 20px;
	color: #6d6a65;
}
body.woocommerce-cart .nr-cart__info .backorder_notification { margin: 6px 0 0; font-size: 13px; color: #c92318; }

body.woocommerce-cart .nr-cart__bottom {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	margin-top: auto;
	padding-top: 16px;
}

/* Stepper: − (start, right) · field · + (end, left). */
body.woocommerce-cart .nr-cart__qty {
	display: inline-flex;
	align-items: center;
	height: 42px;
	border: 1px solid #d9d9d9;
}
body.woocommerce-cart .nr-cart__qty.is-fixed { height: auto; border: 0; }
body.woocommerce-cart .woocommerce .nr-cart__qty .quantity { display: block; margin: 0; }
body.woocommerce-cart .woocommerce .nr-cart__qty .qty {
	width: 44px;
	height: 40px;
	padding: 0;
	border: 0;
	background: none;
	color: #171717;
	font-size: 15px;
	text-align: center;
	-moz-appearance: textfield;
	appearance: textfield;
}
body.woocommerce-cart .woocommerce .nr-cart__qty .qty::-webkit-outer-spin-button,
body.woocommerce-cart .woocommerce .nr-cart__qty .qty::-webkit-inner-spin-button { margin: 0; -webkit-appearance: none; }
body.woocommerce-cart .woocommerce .nr-cart__step {
	display: grid;
	place-items: center;
	width: 40px;
	height: 40px;
	padding: 0;
	border: 0;
	border-radius: 0;
	background: none;
	color: #171717;
	cursor: pointer;
	transition: color .2s;
}
body.woocommerce-cart .woocommerce .nr-cart__step:hover:not(:disabled),
body.woocommerce-cart .woocommerce .nr-cart__step:focus-visible { background: none; color: #EE2C1F; }
body.woocommerce-cart .woocommerce .nr-cart__step:disabled { color: #c4c4c4; cursor: default; }
body.woocommerce-cart .nr-cart__qty-fixed { font-size: 14px; color: #6d6a65; }

body.woocommerce-cart .nr-cart__line { font-size: 17px; font-weight: 600; white-space: nowrap; }

/* ---------- Coupon and update ---------- */
body.woocommerce-cart .nr-cart__actions { padding: 24px 0 8px; }
body.woocommerce-cart .nr-cart__coupon { max-width: 440px; }
body.woocommerce-cart .nr-cart__coupon-label { display: block; margin-bottom: 8px; font-size: 14px; font-weight: 500; }
body.woocommerce-cart .nr-cart__coupon-row { display: flex; }
body.woocommerce-cart .woocommerce .nr-cart__coupon #coupon_code {
	flex: 1 1 auto;
	min-width: 0;
	height: 46px;
	padding: 0 14px;
	border: 1px solid #d9d9d9;
	border-inline-end: 0;
	border-radius: 0;
	font-size: 14px;
}
body.woocommerce-cart .woocommerce .nr-cart__coupon #coupon_code:focus { border-color: #171717; outline: none; }
body.woocommerce-cart .woocommerce .nr-cart__coupon .nr-cart__coupon-button {
	flex: none;
	height: 46px;
	padding: 0 22px;
	border: 1px solid #171717;
	border-radius: 0;
	background: #171717;
	color: #fff;
	font-weight: 600;
}
body.woocommerce-cart .woocommerce .nr-cart__coupon .nr-cart__coupon-button:hover { background: #000; border-color: #000; color: #fff; }
body.woocommerce-cart .nr-cart__coupon .coupon-error-notice { margin: 8px 0 0; font-size: 13px; color: #c92318; }
/* Quantities save by themselves; the button is for browsers without JavaScript. */
body.woocommerce-cart.woocommerce-js .woocommerce .nr-cart__update { display: none; }

/* ---------- Summary ---------- */
body.woocommerce-cart .woocommerce .cart-collaterals .nr-summary {
	float: none;
	width: auto;
	padding: 28px;
	background: #f8f8f8;
}
body.woocommerce-cart .woocommerce h2.nr-summary__title { margin: 0 0 18px; font-size: 20px; font-weight: 600; line-height: 28px; }

body.woocommerce-cart .woocommerce .nr-summary table.nr-summary__table { margin: 0; border: 0; border-radius: 0; border-collapse: collapse; }
body.woocommerce-cart .woocommerce .nr-summary table.nr-summary__table tr { display: flex; justify-content: space-between; gap: 16px; padding: 10px 0; }
body.woocommerce-cart .woocommerce .nr-summary table.nr-summary__table :is(th,
body.woocommerce-cart td) {
	padding: 0;
	border: 0;
	background: none;
	font-size: 15px;
	font-weight: 400;
	line-height: 22px;
	text-align: start;
}
body.woocommerce-cart .woocommerce .nr-summary table.nr-summary__table td { text-align: end; }
body.woocommerce-cart .woocommerce .nr-summary table.nr-summary__table .cart-discount td { color: #1f7a4d; }
body.woocommerce-cart .woocommerce .nr-summary .woocommerce-remove-coupon { color: #6d6a65; font-size: 13px; }

/* Shipping (templates/cart/cart-shipping.php): its title above the options, across the row. */
body.woocommerce-cart .woocommerce .nr-summary table.nr-summary__table tr.shipping { display: block; padding: 14px 0; border-block: 1px solid #e6e6e6; margin-block: 6px; }
body.woocommerce-cart .woocommerce .nr-summary table.nr-summary__table tr.shipping td { display: block; text-align: start; }
body.woocommerce-cart .woocommerce .nr-summary h3.shipping-title { margin: 0 0 10px; font-size: 15px; font-weight: 600; line-height: 22px; }
body.woocommerce-cart .woocommerce .nr-summary ul#shipping_method { margin: 0; padding: 0; list-style: none; }
body.woocommerce-cart .woocommerce .nr-summary ul#shipping_method li {
	display: flex;
	align-items: flex-start;
	gap: 10px;
	margin: 0 0 10px;
	padding: 0;
	font-size: 14px;
	line-height: 21px;
	text-indent: 0;
}
body.woocommerce-cart .woocommerce .nr-summary ul#shipping_method li:last-child { margin-bottom: 0; }
body.woocommerce-cart .woocommerce .nr-summary ul#shipping_method input[type="radio"] { flex: none; margin: 3px 0 0; accent-color: #EE2C1F; }
body.woocommerce-cart .woocommerce .nr-summary ul#shipping_method label { display: block; margin: 0; line-height: 21px; cursor: pointer; }
body.woocommerce-cart .woocommerce .nr-summary ul#shipping_method .amount { font-weight: 600; }
body.woocommerce-cart .nr-summary .woocommerce-shipping-destination { margin: 10px 0 0; font-size: 13px; color: #6d6a65; }
body.woocommerce-cart .nr-summary .woocommerce-shipping-calculator { margin: 6px 0 0; }
body.woocommerce-cart .woocommerce .nr-summary .shipping-calculator-button { color: #171717; font-size: 13px; text-decoration: underline; }
body.woocommerce-cart .nr-summary .shipping-calculator-button::after { display: none; }

body.woocommerce-cart .woocommerce .nr-summary table.nr-summary__table tr.order-total { margin-top: 6px; padding-top: 16px; border-top: 1px solid #171717; }
body.woocommerce-cart .woocommerce .nr-summary table.nr-summary__table tr.order-total :is(th,
body.woocommerce-cart td) { font-size: 18px; font-weight: 600; }
body.woocommerce-cart .nr-summary .order-total small { display: block; font-size: 12px; font-weight: 400; color: #6d6a65; }

body.woocommerce-cart .woocommerce .nr-summary .wc-proceed-to-checkout { padding: 20px 0 0; }
body.woocommerce-cart .woocommerce .nr-summary .wc-proceed-to-checkout a.checkout-button {
	display: block;
	margin: 0;
	padding: 15px 20px;
	border-radius: 0;
	background: #EE2C1F;
	color: #fff;
	font-size: 16px;
	font-weight: 600;
	line-height: 22px;
	text-align: center;
	text-decoration: none;
}
body.woocommerce-cart .woocommerce .nr-summary .wc-proceed-to-checkout a.checkout-button:hover,
body.woocommerce-cart .woocommerce .nr-summary .wc-proceed-to-checkout a.checkout-button:focus-visible { background: #c92318; }
body.woocommerce-cart .nr-summary .wc-proceed-to-checkout > * + * { margin-top: 10px; }

body.woocommerce-cart .nr-summary__trust { margin: 20px 0 0; padding: 18px 0 0; border-top: 1px solid #e6e6e6; list-style: none; }
body.woocommerce-cart .nr-summary__trust li {
	display: flex;
	align-items: flex-start;
	gap: 10px;
	margin: 0 0 10px;
	font-size: 13px;
	line-height: 20px;
	color: #4a4845;
}
body.woocommerce-cart .nr-summary__trust li:last-child { margin-bottom: 0; }
body.woocommerce-cart .nr-summary__trust svg { flex: none; margin-top: 1px; color: #171717; }
body.woocommerce-cart .woocommerce .nr-summary__trust a { color: inherit; text-decoration: underline; }
body.woocommerce-cart .woocommerce .nr-summary__trust a:hover { color: #EE2C1F; }

/* ---------- Cross-sells (below, across the page) ---------- */
body.woocommerce-cart .cross-sells { margin-top: 56px; }

/* ---------- Empty cart ---------- */
body.woocommerce-cart .nr-cart-empty {
	display: flex;
	flex-direction: column;
	align-items: center;
	max-width: 420px;
	margin: 24px auto 0;
	text-align: center;
}
body.woocommerce-cart .nr-cart-empty__icon { color: #171717; }
body.woocommerce-cart .woocommerce .nr-cart-empty .nr-cart-empty__title {
	margin: 18px 0 0;
	padding: 0;
	border: 0;
	background: none;
	font-size: 22px;
	font-weight: 600;
	color: #171717;
}
body.woocommerce-cart .woocommerce .nr-cart-empty .nr-cart-empty__title::before { display: none; }
body.woocommerce-cart .nr-cart-empty__text { margin: 8px 0 0; font-size: 15px; color: #6d6a65; }
body.woocommerce-cart .nr-cart-empty .return-to-shop { width: 100%; margin: 28px 0 0; }
body.woocommerce-cart .nr-cart-empty .woocommerce-notices-wrapper { margin-top: 20px; } /* "… הוסר. לבטל?" after removing the last item. */
body.woocommerce-cart .woocommerce .nr-cart-empty .nr-cart-empty__button {
	display: block;
	padding: 14px 24px;
	background: #EE2C1F;
	color: #fff;
	font-size: 16px;
	font-weight: 600;
	text-decoration: none;
	transition: background .2s;
}
body.woocommerce-cart .woocommerce .nr-cart-empty .nr-cart-empty__button:hover,
body.woocommerce-cart .woocommerce .nr-cart-empty .nr-cart-empty__button:focus-visible { background: #c92318; color: #fff; }

/* ---------- Tablet and phone: stacked, summary after the items ---------- */
@media (max-width: 1024px) {
	body.woocommerce-cart .woocommerce:has(> .woocommerce-cart-form) { display: block; }
	body.woocommerce-cart .woocommerce:has(> .woocommerce-cart-form) > .cart-collaterals { position: static; margin-top: 32px; }
}
@media (max-width: 767px) {
	body.woocommerce-cart .nr-cart__item { grid-template-columns: 88px minmax(0, 1fr); gap: 16px; padding: 18px 0; }
	body.woocommerce-cart .woocommerce .nr-cart__thumb img { width: 88px; height: 110px; }
	body.woocommerce-cart .woocommerce .nr-cart__name { font-size: 15px; line-height: 22px; }
	body.woocommerce-cart .woocommerce .nr-cart__remove-link span { display: none; } /* Icon only; the link keeps its aria-label. */
	body.woocommerce-cart .nr-cart__bottom { padding-top: 12px; }
	body.woocommerce-cart .nr-cart__qty { height: 38px; }
	body.woocommerce-cart .woocommerce .nr-cart__step { width: 36px; height: 36px; }
	body.woocommerce-cart .woocommerce .nr-cart__qty .qty { width: 36px; height: 36px; }
	body.woocommerce-cart .nr-cart__line { font-size: 16px; }
	body.woocommerce-cart .woocommerce .cart-collaterals .nr-summary { margin-inline: -16px; padding: 24px 16px; }
}
