/**
 * Brina Cart (page 12, Bricks shortcode element #brxe-fugmvg rendering
 * [woocommerce_cart] with the child theme's woocommerce/cart/cart.php and
 * cart-totals.php). Loaded on the cart page only (inc/brina-cart.php).
 *
 * Replaces the element's former custom CSS. Section 1 keeps, unchanged, the
 * rules shared with the empty cart and "Previously in your cart"
 * (brina-cart-recovery.css), which are approved as they are. Everything else
 * styles the populated cart only:
 *   LEFT  one open shopping surface: heading + count + divided product rows
 *   RIGHT the order summary card (the only card), sticky on tall desktops.
 * Presentation only: markup hooks used by WooCommerce's cart.js and
 * assets/js/brina-cart.js (input.qty, .quantity .action, .product-subtotal,
 * .cart_totals rows, .product-remove > a) are all kept.
 */

/* ---- 1. Shared with the empty cart (carried over unchanged) ----------- */

#brxe-fugmvg {
	width: 100%;
}

#brxe-fugmvg .woocommerce {
	display: grid;
	grid-template-columns: minmax(0, 1fr) 280px;
	align-items: start;
	gap: 20px;
}

#brxe-fugmvg .woocommerce-notices-wrapper,
#brxe-fugmvg .woocommerce-error,
#brxe-fugmvg .woocommerce-message,
#brxe-fugmvg .woocommerce-info {
	grid-column: 1 / -1;
}

@media (min-width: 992px) {
	/* Two explicit rows, as before (empty cart: notices row + empty state). */
	#brxe-fugmvg > .woocommerce {
		grid-template-rows: auto auto;
	}

	#brxe-fugmvg > .woocommerce > .woocommerce-notices-wrapper,
	#brxe-fugmvg > .woocommerce > .woocommerce-error,
	#brxe-fugmvg > .woocommerce > .woocommerce-message,
	#brxe-fugmvg > .woocommerce > .woocommerce-info {
		grid-row: 1;
		width: 100%;
	}
}

#brxe-fugmvg button.button,
#brxe-fugmvg a.button {
	min-height: 44px;
	padding: 11px 18px;
	color: #ffffff;
	font-size: 14px;
	font-weight: 700;
	background: #0866d5;
	border: 0;
	border-radius: 9px;
	transition: background-color 0.2s ease, transform 0.15s ease;
}

#brxe-fugmvg button.button:hover,
#brxe-fugmvg a.button:hover {
	color: #ffffff;
	background: #064fa8;
	transform: translateY(-2px);
}

#brxe-fugmvg button.button:disabled,
#brxe-fugmvg button.button:disabled[disabled] {
	color: #7b8798;
	background: #e8edf3;
	opacity: 1;
}

/* ---- 2. Page structure (populated cart) -------------------------------- */

/* The Bricks page hero ("YOUR SHOPPING BAG / Your Cart / Review…") stays for
   the empty cart; with items, the heading lives on the left surface. */
body.woocommerce-cart:has(.woocommerce-cart-form) #brxe-ntzhdg {
	display: none;
}

#brxe-fugmvg > .woocommerce:has(> .woocommerce-cart-form) {
	--cart-ink: #172033;
	--cart-ink-2: #3B4556;
	--cart-muted: #6B7688;
	--cart-line: #E6EAF0;
	--cart-navy: #101C3D;
	--cart-accent: #5B4CF0;
	--cart-green: #15803D;
	grid-template-columns: minmax(0, 1fr);
	gap: 28px;
	font-family: Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
	color: var(--cart-ink);
}

@media (min-width: 992px) {
	#brxe-fugmvg > .woocommerce:has(> .woocommerce-cart-form) {
		grid-template-columns: minmax(0, 1fr) 340px;
		column-gap: 40px;
	}

	#brxe-fugmvg > .woocommerce > form.woocommerce-cart-form {
		grid-column: 1;
		grid-row: 2;
	}

	/* Stretches to the items' height so the sticky card stops with them
	   (it never slides over "Previously in your cart" or the footer). */
	#brxe-fugmvg > .woocommerce > .cart-collaterals {
		grid-column: 2;
		grid-row: 2;
		align-self: stretch;
		height: auto; /* Bricks sets fit-content, which would stop the stretch */
	}
}

/* ---- 3. Left shopping surface ------------------------------------------ */

#brxe-fugmvg .woocommerce-cart-form {
	width: 100%;
	min-width: 0;
	margin: 0;
	padding: 0;
	background: none;
	border: 0;
}

#brxe-fugmvg .brina-cart-head {
	display: flex;
	align-items: baseline;
	flex-wrap: wrap;
	gap: 4px 14px;
	padding: 4px 0 14px;
	border-bottom: 1px solid var(--cart-line);
}

#brxe-fugmvg .brina-cart-head__title {
	margin: 0;
	font-size: 28px;
	font-weight: 700;
	line-height: 1.2;
	color: var(--cart-ink);
}

#brxe-fugmvg .brina-cart-head__count {
	margin: 0;
	font-size: 15px;
	font-weight: 500;
	color: var(--cart-muted);
}

#brxe-fugmvg table.shop_table.cart {
	display: block;
	width: 100%;
	margin: 0;
	border: 0;
	border-collapse: collapse;
	background: none;
}

#brxe-fugmvg table.shop_table.cart > tbody { display: block; }

/* One product row: image | details … price, actions under the details.
   Cells are placed on a grid; the remove link stays in its own cell
   (WooCommerce's AJAX remove listens on .product-remove > a). */
#brxe-fugmvg table.shop_table.cart tr.cart_item {
	display: grid;
	grid-template-columns: 116px auto auto minmax(0, 1fr) auto;
	grid-template-areas:
		"img info info info price"
		"img qty  rm   .    price";
	column-gap: 20px;
	row-gap: 10px;
	align-items: start;
	padding: 18px 0;
	border-bottom: 1px solid var(--cart-line);
}

#brxe-fugmvg tr.cart_item > td {
	display: block;
	width: auto;
	min-width: 0;
	padding: 0;
	border: 0;
	background: none;
	text-align: left;
	vertical-align: top;
}

#brxe-fugmvg tr.cart_item > td::before { content: none; } /* WooCommerce responsive labels */

/* The details cell holds image + info; its children join the row grid. */
#brxe-fugmvg tr.cart_item > td.product-info-cell,
#brxe-fugmvg tr.cart_item .brina-cart-product-row { display: contents; }

#brxe-fugmvg tr.cart_item .brina-cart-product-image { grid-area: img; }
#brxe-fugmvg tr.cart_item .brina-cart-product-row > .brina-cart-product-info { grid-area: info; min-width: 0; }
#brxe-fugmvg tr.cart_item > td.product-quantity { grid-area: qty; align-self: center; }
#brxe-fugmvg tr.cart_item > td.product-remove { grid-area: rm; align-self: center; }
#brxe-fugmvg tr.cart_item > td.product-subtotal { grid-area: price; text-align: right; }
/* Unit price stays in the markup (read by the instant-totals script). */
#brxe-fugmvg tr.cart_item > td.product-price { display: none; }

/* Image frame: fixed, white, centred, never cropped or distorted. */
#brxe-fugmvg .brina-cart-product-image a,
#brxe-fugmvg .brina-cart-product-image > img {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 116px;
	height: 116px;
	padding: 6px;
	background: #FFFFFF;
	border: 1px solid #EEF1F5;
	border-radius: 10px;
	box-sizing: border-box;
	overflow: hidden;
}

#brxe-fugmvg .brina-cart-product-image img {
	display: block;
	width: 100%;
	height: 100%;
	max-width: none;
	margin: 0;
	object-fit: contain;
	border: 0;
	border-radius: 0;
	background: none;
}

#brxe-fugmvg .brina-cart-product-image > img { padding: 6px; object-fit: contain; }

/* Details: title > urgency > selected configuration > returns. */
#brxe-fugmvg .brina-cart-product-info .brina-cart-product-info { display: block; }

#brxe-fugmvg .brina-cart-product-title {
	margin: 0;
	padding: 0;
	font-size: 16px;
	font-weight: 600;
	line-height: 1.35;
}

#brxe-fugmvg .brina-cart-product-title a {
	color: var(--cart-ink);
	font-size: inherit;
	font-weight: inherit;
	text-decoration: none;
}

#brxe-fugmvg .brina-cart-product-title a:hover { text-decoration: underline; text-underline-offset: 2px; }

#brxe-fugmvg .brina-cart-stock {
	margin: 4px 0 0;
	font-size: 13px;
	/* Medium, between the earlier 600 (too heavy) and 500 (too thin). Bricks
	   loads Inter as static weights, where 550 would render as 600, so 500 is
	   thickened by a hairline stroke in the text colour instead. */
	font-weight: 500;
	-webkit-text-stroke: 0.2px currentColor;
	line-height: 1.35;
}

#brxe-fugmvg .brina-stock-in { color: var(--cart-green); }
#brxe-fugmvg .brina-stock-low { color: #C42B2B; } /* restrained marketplace red */
#brxe-fugmvg .brina-stock-out { color: #B91C1C; }

/* Selected configuration (variation attributes / identifying attributes). */
#brxe-fugmvg .brina-cart-selection {
	margin: 6px 0 0;
	padding: 0;
	font-size: 13px;
	font-weight: 500;
	line-height: 1.4;
	color: var(--cart-ink-2);
}

#brxe-fugmvg .brina-cart-selection__item { white-space: nowrap; }
#brxe-fugmvg .brina-cart-selection__label { font-weight: 400; color: var(--cart-muted); }
#brxe-fugmvg .brina-cart-selection__sep { color: var(--cart-muted); }

#brxe-fugmvg .brina-cart-refund {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 0 8px;
	margin: 2px 0 0;
	font-size: 12.5px;
	line-height: 1.4;
	color: var(--cart-muted);
}

#brxe-fugmvg .brina-refund-title { font-weight: 600; color: var(--cart-ink-2); white-space: normal; }
#brxe-fugmvg .brina-refund-note { font-size: inherit; color: var(--cart-muted); white-space: normal; }

/* Vendor label: hidden in the cart view only (Dokan item data stays in the
   cart, checkout, orders and REST responses). */
#brxe-fugmvg .woocommerce-cart-form dl.variation dt.variation-Vendor,
#brxe-fugmvg .woocommerce-cart-form dl.variation dd.variation-Vendor { display: none; }

#brxe-fugmvg .woocommerce-cart-form dl.variation {
	display: grid;
	grid-template-columns: auto 1fr;
	gap: 0 6px;
	margin: 4px 0 0;
	font-size: 13px;
	color: var(--cart-ink-2);
}

#brxe-fugmvg .woocommerce-cart-form dl.variation dt,
#brxe-fugmvg .woocommerce-cart-form dl.variation dd { margin: 0; }
#brxe-fugmvg .woocommerce-cart-form dl.variation dd p { margin: 0; }

#brxe-fugmvg .woocommerce-cart-form .backorder_notification { margin: 4px 0 0; font-size: 13px; color: #C2410C; }

/* Item price (line subtotal): same place in every row. */
#brxe-fugmvg tr.cart_item > td.product-subtotal {
	font-size: 17px;
	font-weight: 700;
	line-height: 1.3;
	color: var(--cart-ink);
	white-space: nowrap;
}

/* Quantity: one control [ − qty + ] (Bricks buttons + WooCommerce input). */
#brxe-fugmvg .brina-cart-quantity-inline { display: block; margin: 0; }

#brxe-fugmvg .woocommerce-cart-form .quantity {
	display: inline-flex;
	align-items: stretch;
	width: auto;
	height: 36px;
	margin: 0;
	background: #FFFFFF;
	border: 1px solid #C9D0DC;
	border-radius: 8px;
	overflow: hidden;
}

#brxe-fugmvg .woocommerce-cart-form .quantity:focus-within { border-color: var(--cart-navy); }

#brxe-fugmvg .woocommerce-cart-form .quantity .action {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 34px;
	height: auto;
	padding: 0;
	color: var(--cart-ink);
	background: #FFFFFF;
	border: 0;
	cursor: pointer;
	user-select: none;
}

#brxe-fugmvg .woocommerce-cart-form .quantity .action svg { width: 16px; height: 16px; }
#brxe-fugmvg .woocommerce-cart-form .quantity .action:hover { background: #F2F4F8; }
#brxe-fugmvg .woocommerce-cart-form .quantity .action:focus-visible { outline: 2px solid var(--cart-accent); outline-offset: -2px; }

/* + at WooCommerce's maximum purchasable quantity. */
#brxe-fugmvg .woocommerce-cart-form .quantity .action.is-disabled,
#brxe-fugmvg .woocommerce-cart-form .quantity .action.is-disabled:hover {
	color: #B8BFCC;
	background: #F7F8FA;
	cursor: not-allowed;
}
#brxe-fugmvg .woocommerce-cart-form .quantity .minus { order: 0; border-right: 1px solid #E3E7EE; }
#brxe-fugmvg .woocommerce-cart-form .quantity .plus { order: 2; border-left: 1px solid #E3E7EE; }

#brxe-fugmvg .woocommerce-cart-form .quantity input.qty {
	order: 1;
	width: 44px;
	height: 100%;
	min-height: 0;
	margin: 0;
	padding: 0;
	font-size: 15px;
	font-weight: 600;
	color: var(--cart-ink);
	text-align: center;
	background: #FFFFFF;
	border: 0;
	border-radius: 0;
	-moz-appearance: textfield;
	appearance: textfield;
}

#brxe-fugmvg .woocommerce-cart-form .quantity input.qty::-webkit-outer-spin-button,
#brxe-fugmvg .woocommerce-cart-form .quantity input.qty::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }

#brxe-fugmvg .woocommerce-cart-form .quantity input.qty:focus-visible {
	outline: 2px solid var(--cart-accent);
	outline-offset: -2px;
}

/* Remove: a quiet, secondary action beside the quantity. */
#brxe-fugmvg tr.cart_item > td.product-remove {
	padding-left: 14px;
	border-left: 1px solid var(--cart-line);
}

#brxe-fugmvg tr.cart_item > td.product-remove a.remove {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	width: auto;
	height: 32px;
	padding: 0 8px;
	margin: 0 0 0 -8px;
	font-size: 13px;
	font-weight: 500;
	line-height: 1;
	color: var(--cart-ink) !important; /* WooCommerce core colours a.remove red */
	text-decoration: underline;
	text-decoration-color: rgba(23, 32, 51, 0.35);
	text-decoration-thickness: 1px;
	text-underline-offset: 3px;
	background: none;
	border-radius: 6px;
}

#brxe-fugmvg tr.cart_item > td.product-remove a.remove::before,
#brxe-fugmvg tr.cart_item > td.product-remove a.remove::after { content: none; }

#brxe-fugmvg tr.cart_item > td.product-remove a.remove:hover {
	color: #B91C1C !important;
	text-decoration-color: currentColor;
	background: #FEF2F2;
}

#brxe-fugmvg .woocommerce-cart-form a:focus-visible,
#brxe-fugmvg .cart_totals a:focus-visible,
#brxe-fugmvg .cart_totals button:focus-visible,
#brxe-fugmvg .cart_totals input:focus-visible {
	outline: 2px solid var(--cart-accent);
	outline-offset: 2px;
}

/* ---- 4. Order summary card --------------------------------------------- */

#brxe-fugmvg .cart-collaterals { width: 100%; min-width: 0; margin: 0; }

#brxe-fugmvg .cart-collaterals .cart_totals {
	float: none;
	width: 100%;
	margin: 0;
	padding: 22px 22px 20px;
	background: #FFFFFF;
	border: 1px solid #DDE3EC;
	border-radius: 12px;
	box-shadow: 0 6px 20px rgba(16, 28, 61, 0.06);
}

@media (min-width: 992px) and (min-height: 720px) {
	#brxe-fugmvg .cart-collaterals .cart_totals {
		position: sticky;
		top: 24px;
	}
}

#brxe-fugmvg .cart_totals h2 {
	margin: 0 0 8px;
	font-size: 20px;
	font-weight: 700;
	line-height: 1.3;
	color: var(--cart-ink);
}

#brxe-fugmvg .cart_totals table.shop_table {
	width: 100%;
	margin: 0;
	border: 0;
	border-collapse: collapse;
}

#brxe-fugmvg .cart_totals tr > th,
#brxe-fugmvg .cart_totals tr > td {
	padding: 9px 0;
	font-size: 14px;
	font-weight: 500;
	line-height: 1.4;
	color: var(--cart-ink-2);
	text-transform: none;
	letter-spacing: 0;
	vertical-align: top;
	background: none;
	border: 0;
}

#brxe-fugmvg .cart_totals tr > td { text-align: right; color: var(--cart-ink); }
#brxe-fugmvg .cart_totals tr > td::before { content: none; }

#brxe-fugmvg .cart_totals .woocommerce-shipping-methods {
	margin: 0;
	padding: 0;
	list-style: none;
	font-weight: 600;
	color: var(--cart-green);
}

#brxe-fugmvg .cart_totals .woocommerce-shipping-methods li { margin: 0; padding: 0; }
#brxe-fugmvg .cart_totals .woocommerce-shipping-methods label { font-weight: 600; color: inherit; }

/* Destination: its own quiet line under the shipping method. */
#brxe-fugmvg .cart_totals .woocommerce-shipping-destination {
	margin: 2px 0 0;
	font-size: 13px;
	font-weight: 400;
	line-height: 1.4;
	color: var(--cart-muted);
}

#brxe-fugmvg .cart_totals .woocommerce-shipping-destination strong { font-weight: 600; color: var(--cart-ink-2); white-space: nowrap; }

/* "Shipping to <destination>.  Change" (inc/brina-cart.php) replaces the
   line above; Change opens WooCommerce's shipping calculator. */
#brxe-fugmvg .cart_totals:has(tr.brina-ship-dest) .woocommerce-shipping-destination { display: none; }

#brxe-fugmvg .cart_totals tr.brina-ship-dest > td {
	padding: 0 0 10px !important;
	font-size: 13px;
	font-weight: 400;
	text-align: left;
	color: var(--cart-muted);
}

#brxe-fugmvg .cart_totals .brina-ship-dest__line {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	justify-content: space-between;
	gap: 2px 12px;
}

#brxe-fugmvg .cart_totals .brina-ship-dest__text { flex: 1 1 0; min-width: 0; margin: 0; }
#brxe-fugmvg .cart_totals .brina-ship-dest__text strong { font-weight: 600; color: var(--cart-ink-2); white-space: nowrap; }

#brxe-fugmvg .cart_totals tr.brina-ship-dest .woocommerce-shipping-calculator { display: contents; margin: 0; }

#brxe-fugmvg .cart_totals .brina-ship-dest .shipping-calculator-button,
#brxe-fugmvg .cart_totals .brina-ship-dest__change {
	flex: 0 0 auto;
	font-size: 13px;
	font-weight: 600;
	color: var(--cart-accent);
	text-decoration: none;
}

#brxe-fugmvg .cart_totals .brina-ship-dest .shipping-calculator-button::after { content: none; }
#brxe-fugmvg .cart_totals .brina-ship-dest .shipping-calculator-button:hover,
#brxe-fugmvg .cart_totals .brina-ship-dest__change:hover { text-decoration: underline; text-underline-offset: 2px; }

#brxe-fugmvg .cart_totals .brina-ship-dest .shipping-calculator-form {
	flex: 1 0 100%;
	margin: 8px 0 0;
	padding: 12px;
	background: #F7F8FB;
	border: 1px solid #E6EAF0;
	border-radius: 10px;
}

#brxe-fugmvg .cart_totals .brina-ship-dest .shipping-calculator-form .form-row { margin: 0 0 8px; padding: 0; }
#brxe-fugmvg .cart_totals .brina-ship-dest .shipping-calculator-form label { display: block; margin: 0 0 3px; font-size: 12px; font-weight: 600; color: var(--cart-ink-2); }

#brxe-fugmvg .cart_totals .brina-ship-dest .shipping-calculator-form input.input-text,
#brxe-fugmvg .cart_totals .brina-ship-dest .shipping-calculator-form select,
#brxe-fugmvg .cart_totals .brina-ship-dest .shipping-calculator-form .select2-container .select2-selection--single {
	width: 100%;
	height: 38px;
	min-height: 38px;
	padding: 0 10px;
	font-size: 14px;
	color: var(--cart-ink);
	background: #FFFFFF;
	border: 1px solid #C9D0DC;
	border-radius: 8px;
}

#brxe-fugmvg .cart_totals .brina-ship-dest .shipping-calculator-form .select2-container { width: 100% !important; }
#brxe-fugmvg .cart_totals .brina-ship-dest .shipping-calculator-form .select2-selection__rendered { padding: 0; line-height: 36px; }
#brxe-fugmvg .cart_totals .brina-ship-dest .shipping-calculator-form .select2-selection__arrow { height: 36px; }

#brxe-fugmvg .cart_totals .brina-ship-dest .shipping-calculator-form button[name="calc_shipping"] {
	width: 100%;
	height: 40px;
	margin: 4px 0 0;
	font-size: 14px;
	font-weight: 600;
	color: var(--cart-navy);
	background: #FFFFFF;
	border: 1px solid var(--cart-navy);
	border-radius: 8px;
}

#brxe-fugmvg .cart_totals .brina-ship-dest .shipping-calculator-form button[name="calc_shipping"]:hover { color: #FFFFFF; background: var(--cart-navy); }

/* FREE shipping progress: under Subtotal, before and after it is unlocked. */
#brxe-fugmvg .cart_totals tr.brina-fs-row > td { padding: 4px 0 10px !important; text-align: left; }

/* Shipping / Tax: WooCommerce's amounts; FREE in the summary's green. */
#brxe-fugmvg .cart_totals .brina-ship-free { font-weight: 600; letter-spacing: 0.02em; color: var(--cart-green); }
#brxe-fugmvg .cart_totals .woocommerce-shipping-methods .woocommerce-Price-amount { font-weight: 500; color: var(--cart-ink); }
#brxe-fugmvg .cart_totals tr.brina-tax-row > td { color: var(--cart-ink); }
#brxe-fugmvg .cart_totals .brina-tax-pending { font-size: 13px; font-weight: 400; color: var(--cart-muted); }

#brxe-fugmvg .cart_totals .brina-fs {
	padding: 10px 12px 11px;
	background: #F7F8FB;
	border: 1px solid #E6EAF0;
	border-radius: 10px;
}

#brxe-fugmvg .cart_totals .brina-fs.is-unlocked {
	background: #F0FDF4;
	border-color: #BBF7D0;
}

#brxe-fugmvg .cart_totals .brina-fs__message {
	display: flex;
	align-items: center;
	gap: 8px;
	margin: 0 0 8px;
	font-size: 14px;
	line-height: 1.35;
	color: var(--cart-ink);
}

#brxe-fugmvg .cart_totals .brina-fs.is-unlocked .brina-fs__message { color: #166534; }

#brxe-fugmvg .cart_totals .brina-fs.is-unlocked .brina-fs__message::before {
	content: "";
	flex: 0 0 20px;
	width: 20px;
	height: 20px;
	border-radius: 50%;
	background: #16A34A url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5.5 10.3l2.9 2.9 6-6.2' fill='none' stroke='%23FFFFFF' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 20px 20px no-repeat;
}

#brxe-fugmvg .cart_totals .brina-fs__bar { height: 5px; }

/* Total: the strongest line. */
#brxe-fugmvg .cart_totals tr.order-total > th,
#brxe-fugmvg .cart_totals tr.order-total > td {
	padding-top: 14px;
	font-size: 18px;
	font-weight: 700;
	color: var(--cart-ink);
	border-top: 1px solid var(--cart-line);
}

#brxe-fugmvg .cart_totals tr.order-total > td { font-size: 20px; }
#brxe-fugmvg .cart_totals tr.order-total > td strong { font-weight: inherit; }

/* Coupon: secondary, compact. */
#brxe-fugmvg .cart_totals .brina-total-coupon-gap { display: block; height: 10px; }

#brxe-fugmvg .cart_totals .brina-cart-total-coupon {
	display: grid;
	grid-template-columns: minmax(0, 1fr) auto;
	gap: 8px;
	margin: 0;
}

#brxe-fugmvg .cart_totals .brina-cart-total-coupon input[name="coupon_code"] {
	width: 100%;
	min-width: 0;
	height: 40px;
	min-height: 40px;
	margin: 0;
	padding: 0 12px;
	font-size: 14px;
	color: var(--cart-ink);
	background: #FFFFFF;
	border: 1px solid #C9D0DC;
	border-radius: 8px;
	box-sizing: border-box;
}

#brxe-fugmvg .cart_totals .brina-cart-total-coupon button[name="apply_coupon"] {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 40px;
	height: 40px;
	margin: 0;
	padding: 0 16px;
	font-size: 14px;
	font-weight: 600;
	color: var(--cart-navy);
	background: #FFFFFF;
	border: 1px solid #C9D0DC;
	border-radius: 8px;
	transform: none;
}

#brxe-fugmvg .cart_totals .brina-cart-total-coupon button[name="apply_coupon"]:hover {
	color: var(--cart-navy);
	background: #F2F4F8;
	border-color: var(--cart-navy);
	transform: none;
}

/* Proceed to checkout: the primary action. */
#brxe-fugmvg .cart_totals .wc-proceed-to-checkout { margin: 0; padding: 16px 0 0; }

#brxe-fugmvg .cart_totals .wc-proceed-to-checkout a.checkout-button {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	min-height: 50px;
	margin: 0;
	padding: 0 20px;
	font-size: 16px;
	font-weight: 700;
	color: #FFFFFF;
	background: var(--cart-navy);
	border: 0;
	border-radius: 10px;
	transform: none;
}

#brxe-fugmvg .cart_totals .wc-proceed-to-checkout a.checkout-button:hover {
	color: #FFFFFF;
	background: #1B2A55;
	transform: none;
}

/* ---- 5. Tablet / mobile -------------------------------------------------- */

@media (max-width: 991.98px) {
	#brxe-fugmvg .cart-collaterals .cart_totals { max-width: 560px; margin-left: auto; }
}

@media (max-width: 767.98px) {
	#brxe-fugmvg .cart-collaterals .cart_totals { max-width: none; }
}

@media (max-width: 599.98px) {
	#brxe-fugmvg .brina-cart-head__title { font-size: 24px; }

	#brxe-fugmvg table.shop_table.cart tr.cart_item {
		grid-template-columns: 84px auto auto minmax(0, 1fr);
		grid-template-areas:
			"img info info info"
			"img price price price"
			"qty qty  rm   .";
		column-gap: 14px;
		row-gap: 8px;
		padding: 16px 0;
	}

	#brxe-fugmvg .brina-cart-product-image a,
	#brxe-fugmvg .brina-cart-product-image > img { width: 84px; height: 84px; padding: 4px; }

	#brxe-fugmvg tr.cart_item > td.product-subtotal { text-align: left; font-size: 16px; }
	#brxe-fugmvg .brina-cart-product-title { font-size: 15px; }
	#brxe-fugmvg .woocommerce-cart-form .quantity { height: 40px; }
	#brxe-fugmvg .woocommerce-cart-form .quantity .action { width: 40px; }
	#brxe-fugmvg .cart-collaterals .cart_totals { padding: 18px 16px; }
}

/* ---- 6. Quantity updates and removal: no overlay, spinner or fade ------- */
/* brina-cart.js updates quantities in place; the only pending sign is the
   control itself (aria-busy). A removed row is hidden at once while
   WooCommerce removes it in the background (.is-removing). */
#brxe-fugmvg .woocommerce-cart-form .quantity[aria-busy="true"] input.qty { color: var(--cart-ink-2); }
#brxe-fugmvg tr.cart_item.is-removing { display: none !important; }

/* ---- 7. Cart-only utility footer (inc/brina-cart.php) ------------------- */
/* Short carts: the page is a full-height flex column, so continue the cart
   section's background down to the compact footer (cart page only). */
body.woocommerce-cart { background-color: #F5F7FB; }

#brx-footer.brina-cart-footer {
	margin: 0;
	padding: 18px 16px 22px;
	background: transparent;
	border-top: 1px solid #E3E7EE;
	font-family: Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
	font-size: 13px;
	line-height: 1.5;
	color: #6B7688;
}

#brx-footer.brina-cart-footer .brina-cart-footer__inner {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: center;
	gap: 4px 14px;
	max-width: 1200px;
	margin: 0 auto;
	text-align: center;
}

#brx-footer.brina-cart-footer p { margin: 0; }
#brx-footer.brina-cart-footer nav { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 10px; }
#brx-footer.brina-cart-footer a { color: #3B4556; text-decoration: none; }
#brx-footer.brina-cart-footer a:hover { text-decoration: underline; text-underline-offset: 2px; }
#brx-footer.brina-cart-footer a:focus-visible { outline: 2px solid #5B4CF0; outline-offset: 2px; }

/* ---- 8. Cart item removal toast ---------------------------------------- */
/* WooCommerce's successful "removed from your cart" notice is shown as the
   Brina toast (assets/js/brina-cart.js) instead of the full-width green bar.
   The notice is marked server-side (inc/brina-cart.php) and hidden only while
   JavaScript runs (body.woocommerce-js), so it is never painted or announced;
   without JavaScript WooCommerce's notice is shown as before. Errors and all
   other notices are untouched. */
.woocommerce-js .woocommerce-notices-wrapper .woocommerce-message:has(.brina-removed-title) { display: none !important; }

/* The toast rules below are an exact copy of the Add to Cart toast in
   assets/css/brina-product-page.css (lines 1526-1536 and 1569-1691; the PDP's
   .brina-qty-tip line omitted). That file loads on product pages only; keep
   both in step if the toast design ever changes. */
.brina-sr-only {
	position: absolute !important;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0 0 0 0);
	white-space: nowrap;
	border: 0;
}

/* Add to Cart toast */
.brina-toast {
	position: fixed;
	/* Top-center, just below the header/navigation. The header is not sticky,
	   so the controller sets --brina-toast-top from its rendered bottom (+12px,
	   never above 12px from the viewport top); the value here is the no-JS
	   fallback. Centred with auto margins: transform belongs to the animation. */
	top: var(--brina-toast-top, 170px);
	right: 0;
	left: 0;
	margin: 0 auto;
	z-index: 2147483000; /* above third-party widgets (chat, sign-up forms) */
	display: flex;
	align-items: center;
	gap: 10px;
	width: min(400px, calc(100vw - 32px));
	padding: 12px 8px 12px 14px;
	color: #111827;
	background: #FFFFFF;
	border: 1px solid #E3E7EF;
	border-left: 4px solid #16A34A;
	border-radius: 12px;
	box-shadow: 0 10px 30px rgba(16, 28, 61, .18);
	box-sizing: border-box;
	/* Visible from the first paint (no script needed to show it). Without
	   JavaScript it fades out after 12 s; the inline controller replaces that
	   with the 4 s behaviour (.is-managed). */
	animation: brina-toast-in .2s ease-out both, brina-toast-out .25s ease-in 12s forwards;
}

.brina-toast.is-managed { animation: brina-toast-in .2s ease-out both; }

.brina-toast.is-out {
	animation: brina-toast-out .2s ease-in forwards;
	pointer-events: none;
}

.brina-toast[hidden] { display: none; }

@keyframes brina-toast-in {
	from { opacity: 0; transform: translateY(8px); }
	to { opacity: 1; transform: none; }
}

@keyframes brina-toast-out {
	to { opacity: 0; transform: translateY(8px); visibility: hidden; }
}

.brina-toast__icon { flex: 0 0 20px; color: #16A34A; }

.brina-toast__msg {
	flex: 1 1 auto;
	min-width: 0;
	margin: 0;
	font-size: 14px;
	line-height: 1.35;
}

/* Long names are cut to one line; "added to cart" is always visible. */
.brina-toast__name {
	display: block;
	overflow: hidden;
	font-weight: 700;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.brina-toast__tail { display: block; }

.brina-toast__link {
	flex: 0 0 auto;
	display: inline-flex;
	align-items: center;
	min-height: 44px;
	padding: 0 8px;
	font-size: 14px;
	font-weight: 700;
	white-space: nowrap;
	color: #5B4CF0;
	text-decoration: underline;
	text-underline-offset: 3px;
}

.brina-toast__close {
	flex: 0 0 44px;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	margin: 0;
	padding: 0;
	color: #4B5563;
	background: transparent;
	border: 0;
	border-radius: 10px;
	cursor: pointer;
}

.brina-toast__close:hover { background: #F1F3F8; }

.brina-toast__link:focus-visible,
.brina-toast__close:focus-visible {
	outline: 2px solid #5B4CF0;
	outline-offset: 2px;
	border-radius: 8px;
}

@media (max-width: 767.98px) {
	.brina-toast {
		top: var(--brina-toast-top, 247px);
		right: 16px;
		left: 16px;
		width: auto;
	}
}

@media (prefers-reduced-motion: reduce) {
	.brina-toast { animation: brina-toast-out .01s linear 12s forwards; }
	.brina-toast.is-managed { animation: none; }
	.brina-toast.is-out { animation: brina-toast-out .01s linear forwards; }
}

/* Cart-only: a failed remove/restore uses the same toast with a red accent
   (the action did not happen); success removals keep the green accent. */
.brina-toast--error { border-left-color: #B91C1C; }
.brina-toast--error .brina-toast__icon { color: #B91C1C; }

/* =====================================================================
   6. TABLET CART — PHASE 1 (768–1200.98px only; 2026-10-04, owner)
   ---------------------------------------------------------------------
   Same tablet range as the homepage tablet layer (brina-home-tablet.css);
   desktop (>= 1201) and phone (<= 767) cannot match. Presentation only —
   no template, JS or WooCommerce logic changes; every hook used by
   cart.js / brina-cart.js (input.qty, .quantity .action, .product-price,
   .product-subtotal, .product-remove > a, .cart_totals rows) is kept.

   • Two columns: cart (≈ 69%) | Order summary clamp(240px, 31%, 340px).
     Notices sit at the top of the cart column; the summary starts level
     with them (or with "Your Cart" when there is no notice) and stays
     sticky beside the items, inside the cart area.
   • Product rows: larger image (128 → 148px), title and details across
     the full row, then quantity · Remove · price on one line.
   • WooCommerce notices: a compact alert (same message, same logic);
     the out-of-stock row gets a quiet red accent.
   • Page edges 24px, as on the other tablet pages.
   ===================================================================== */
@media (min-width: 768px) and (max-width: 1200.98px) {

	/* Page frame: 24px tablet edges (Bricks section, cart page only). */
	body.woocommerce-cart #brxe-cxnjrk.brina-cart-page {
		padding: 20px 24px 40px;
	}

	/* ---- Two-column workspace ---- */
	#brxe-fugmvg > .woocommerce:has(> .woocommerce-cart-form) {
		grid-template-columns: minmax(0, 1fr) clamp(240px, 31%, 340px);
		grid-template-rows: auto 1fr;
		column-gap: clamp(20px, 2.6vw, 32px);
		row-gap: 0;
	}

	#brxe-fugmvg > .woocommerce:has(> .woocommerce-cart-form) > .woocommerce-notices-wrapper {
		grid-column: 1;
		grid-row: 1;
		width: 100%;
		min-width: 0;
	}

	#brxe-fugmvg > .woocommerce:has(> .woocommerce-cart-form) > form.woocommerce-cart-form {
		grid-column: 1;
		grid-row: 2;
	}

	#brxe-fugmvg > .woocommerce:has(> .woocommerce-cart-form) > .cart-collaterals {
		grid-column: 2;
		grid-row: 1 / span 2;
		align-self: stretch;
		height: auto;                   /* Bricks: fit-content */
	}

	#brxe-fugmvg .cart-collaterals .cart_totals {
		max-width: none;                /* base below 992px: 560px, right-aligned */
		margin: 0;
		padding: 20px 18px 18px;
	}

	#brxe-fugmvg .cart_totals h2 {
		font-size: 19px;
	}

	/* ---- Cart heading ---- */
	#brxe-fugmvg .brina-cart-head {
		padding: 0 0 14px;
	}

	#brxe-fugmvg .brina-cart-head__title {
		font-size: 26px;
	}

	/* ---- Product rows: image | details, then qty · remove · price ---- */
	#brxe-fugmvg table.shop_table.cart tr.cart_item {
		grid-template-columns: clamp(128px, 2.5vw + 108.8px, 148px) auto auto minmax(0, 1fr) auto;
		grid-template-areas:
			"img info info info  info"
			"img qty  rm   .     price";
		grid-template-rows: auto 1fr;
		column-gap: 18px;
		row-gap: 14px;
		padding: 22px 0;
	}

	#brxe-fugmvg .brina-cart-product-image a,
	#brxe-fugmvg .brina-cart-product-image > img {
		width: clamp(128px, 2.5vw + 108.8px, 148px);
		height: clamp(128px, 2.5vw + 108.8px, 148px);
		padding: 8px;
	}

	#brxe-fugmvg tr.cart_item > td.product-quantity,
	#brxe-fugmvg tr.cart_item > td.product-remove {
		align-self: end;
	}

	/* Price: end of the controls line, aligned with the quantity control. */
	#brxe-fugmvg tr.cart_item > td.product-subtotal {
		align-self: end;
		min-height: 36px;
		display: flex;
		align-items: center;
		justify-content: flex-end;
		font-size: 18px;
	}

	/* Easier touch target for the quantity control. */
	#brxe-fugmvg .woocommerce-cart-form .quantity {
		height: 40px;
	}

	#brxe-fugmvg .woocommerce-cart-form .quantity .action {
		width: 38px;
	}

	/* The out-of-stock row is identifiable at a glance (WooCommerce keeps
	   its own "Out of Stock" label and the checkout validation). */
	#brxe-fugmvg table.shop_table.cart tr.cart_item:has(.brina-stock-out) {
		box-shadow: inset 3px 0 0 #C42B2B;
		padding-left: 14px;
		background: linear-gradient(90deg, #FFF6F6 0%, rgba(255, 246, 246, 0) 70%);
	}

	/* ---- Compact WooCommerce notices (message text and logic unchanged) ---- */
	#brxe-fugmvg .woocommerce-notices-wrapper .woocommerce-error,
	#brxe-fugmvg .woocommerce-notices-wrapper .woocommerce-info,
	#brxe-fugmvg .woocommerce-notices-wrapper .woocommerce-message {
		position: relative;
		margin: 0 0 16px;
		padding: 10px 14px 10px 42px;
		font-size: 14px;
		font-weight: 500;
		line-height: 1.45;
		list-style: none;
		border-radius: 10px;
		box-shadow: none;
	}

	#brxe-fugmvg .woocommerce-notices-wrapper .woocommerce-error {
		color: #8F1D1D;
		background: #FEF4F4;
		border: 1px solid #F3C9CC;
		border-left: 3px solid #C42B2B;
	}

	#brxe-fugmvg .woocommerce-notices-wrapper .woocommerce-info {
		color: #1E3A8A;
		background: #F3F6FE;
		border: 1px solid #CDD8F6;
		border-left: 3px solid #3B5BDB;
	}

	#brxe-fugmvg .woocommerce-notices-wrapper .woocommerce-message {
		color: #14532D;
		background: #F2FBF5;
		border: 1px solid #C6E9D2;
		border-left: 3px solid #15803D;
	}

	#brxe-fugmvg .woocommerce-notices-wrapper .woocommerce-error > li {
		margin: 0;
		padding: 0;
	}

	#brxe-fugmvg .woocommerce-notices-wrapper .woocommerce-error > li + li {
		margin-top: 4px;
	}

	/* WooCommerce focuses the notice on load (tabindex -1) so it is
	   announced; keep a visible but restrained focus indicator. */
	#brxe-fugmvg .woocommerce-notices-wrapper .woocommerce-error:focus,
	#brxe-fugmvg .woocommerce-notices-wrapper .woocommerce-info:focus,
	#brxe-fugmvg .woocommerce-notices-wrapper .woocommerce-message:focus {
		outline: 2px solid rgba(196, 43, 43, 0.28);
		outline-offset: 2px;
	}

	/* Primary checkout action: one line in the narrower summary (Bricks
	   gives buttons a 60px line-height, which doubled a wrapped label). */
	#brxe-fugmvg .cart_totals .wc-proceed-to-checkout a.checkout-button {
		min-height: 52px;
		padding: 0 12px;
		line-height: 1.25;
		white-space: nowrap;
	}

	/* Alert icon (replaces any theme/core notice icon). */
	#brxe-fugmvg .woocommerce-notices-wrapper .woocommerce-error::before,
	#brxe-fugmvg .woocommerce-notices-wrapper .woocommerce-info::before,
	#brxe-fugmvg .woocommerce-notices-wrapper .woocommerce-message::before {
		content: "";
		position: absolute;
		top: 11px;
		left: 14px;
		width: 18px;
		height: 18px;
		margin: 0;
		background: currentColor;
		-webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3Cpath d='M12 7.5v5.5M12 16.5h.01'/%3E%3C/svg%3E") center / contain no-repeat;
		mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3Cpath d='M12 7.5v5.5M12 16.5h.01'/%3E%3C/svg%3E") center / contain no-repeat;
		font-family: inherit;
	}
}

/* Sticky summary on tablets tall enough for it (it never covers the
   header — not sticky — nor the footer: it stops with the cart column). */
@media (min-width: 768px) and (max-width: 1200.98px) and (min-height: 640px) {
	#brxe-fugmvg .cart-collaterals .cart_totals {
		position: sticky;
		top: 20px;
	}
}

/* =====================================================================
   9. PHONE CART (<= 767.98px; 2026-10-04, owner)
   ---------------------------------------------------------------------
   Compact phone composition of the approved tablet structure. Tablet
   (768–1200.98, section 6) and desktop cannot match these rules.
   Presentation only: the template, brina-cart.js, WooCommerce cart.js and
   every hook they use (input.qty, .quantity .action, .product-price,
   .product-subtotal, .product-remove > a, .cart_totals rows, coupon form,
   shipping calculator) are unchanged.

   • Page edges 16px; "Your Cart  N items" compact.
   • Each item is a shallow white card: image | title · stock · details ·
     returns, then one action row across the card: [− qty +]  Remove  price.
   • Details wrap (they were nowrap and clipped "Eau de Parfum (EDP)").
   • Order summary below the items as a compact card; checkout 48px.
   ===================================================================== */
@media (max-width: 767.98px) {

	/* ---- Page frame ---- */
	/* Populated cart only (the empty-cart state keeps its current layout). */
	body.woocommerce-cart:has(.woocommerce-cart-form) #brxe-cxnjrk.brina-cart-page {
		padding: 12px 16px 28px;
	}

	#brxe-fugmvg > .woocommerce:has(> .woocommerce-cart-form) {
		gap: 16px;
	}

	#brxe-fugmvg .woocommerce-cart-form,
	#brxe-fugmvg .cart-collaterals,
	#brxe-fugmvg table.shop_table.cart {
		max-width: 100%;
		min-width: 0;
		box-sizing: border-box;
	}

	/* ---- Heading ---- */
	#brxe-fugmvg .brina-cart-head {
		gap: 2px 10px;
		margin: 0 0 12px;
		padding: 0;
		border-bottom: 0;
	}

	#brxe-fugmvg .brina-cart-head__title {
		font-size: 22px;
		line-height: 1.2;
	}

	#brxe-fugmvg .brina-cart-head__count {
		font-size: 14px;
	}

	/* ---- Item cards ---- */
	#brxe-fugmvg table.shop_table.cart > tbody {
		display: flex;
		flex-direction: column;
		gap: 10px;
	}

	#brxe-fugmvg table.shop_table.cart tr.cart_item {
		--cart-img: clamp(80px, 22vw, 104px);
		grid-template-columns: var(--cart-img) auto minmax(0, 1fr) auto;
		grid-template-areas:
			"img info info info"
			"qty qty  rm   price";
		grid-template-rows: auto auto;
		column-gap: 12px;
		row-gap: 10px;
		padding: 12px;
		background: #FFFFFF;
		border: 1px solid #E3E7EF;
		border-radius: 12px;
		box-shadow: none;
		box-sizing: border-box;
		min-width: 0;
	}

	#brxe-fugmvg table.shop_table.cart tr.cart_item:has(.brina-stock-out) {
		border-color: #F0C9CC;
		box-shadow: inset 3px 0 0 #C42B2B;
	}

	/* Image: compact square frame, contained, centred. */
	#brxe-fugmvg .brina-cart-product-image a,
	#brxe-fugmvg .brina-cart-product-image > img {
		width: var(--cart-img);
		height: var(--cart-img);
		padding: 4px;
		border-radius: 8px;
	}

	/* Details: title > stock > selection > returns, compact. */
	#brxe-fugmvg .brina-cart-product-title {
		display: -webkit-box;
		-webkit-box-orient: vertical;
		-webkit-line-clamp: 2;
		line-clamp: 2;
		overflow: hidden;
		font-size: 14.5px;
		font-weight: 600;
		line-height: 1.3;
		overflow-wrap: anywhere;
	}

	#brxe-fugmvg .brina-cart-stock {
		margin-top: 2px;
		font-size: 12.5px;
		line-height: 1.3;
	}

	#brxe-fugmvg .brina-cart-selection {
		margin-top: 3px;
		font-size: 12.5px;
		line-height: 1.32;
		overflow-wrap: anywhere;
	}

	/* Attributes flow inline and wrap inside the card (no clipping). */
	#brxe-fugmvg .brina-cart-selection__item {
		white-space: normal;
	}

	#brxe-fugmvg .brina-cart-refund {
		display: block;
		margin-top: 3px;
		font-size: 11.5px;
		line-height: 1.35;
	}

	#brxe-fugmvg .brina-refund-title {
		font-size: 12px;
	}

	/* The policy sentence stays in the page for screen readers; visually
	   the card keeps the "Returns & Refunds Accepted" line (the full policy
	   is on the product page and the Returns & Refunds page). */
	#brxe-fugmvg .brina-refund-note {
		position: absolute;
		width: 1px;
		height: 1px;
		margin: -1px;
		padding: 0;
		overflow: hidden;
		clip: rect(0 0 0 0);
		white-space: nowrap;
		border: 0;
	}

	#brxe-fugmvg .woocommerce-cart-form dl.variation,
	#brxe-fugmvg .woocommerce-cart-form .backorder_notification {
		font-size: 12.5px;
	}

	/* ---- Action row: [− qty +]  Remove  ........  price ---- */
	#brxe-fugmvg tr.cart_item > td.product-quantity,
	#brxe-fugmvg tr.cart_item > td.product-remove,
	#brxe-fugmvg tr.cart_item > td.product-subtotal {
		align-self: center;
	}

	#brxe-fugmvg .woocommerce-cart-form .quantity {
		height: 38px;
	}

	#brxe-fugmvg .woocommerce-cart-form .quantity {
		flex: none;
	}

	#brxe-fugmvg .woocommerce-cart-form .quantity .action {
		flex: 0 0 36px;
		width: 36px;
	}

	#brxe-fugmvg .woocommerce-cart-form .quantity input.qty {
		flex: 0 0 40px;
		width: 40px;
		font-size: 15px;
	}

	#brxe-fugmvg tr.cart_item > td.product-remove {
		padding-left: 10px;
	}

	#brxe-fugmvg tr.cart_item > td.product-remove a.remove {
		height: 38px;
		padding: 0 6px;
		margin-left: -6px;
		font-size: 13px;
	}

	#brxe-fugmvg tr.cart_item > td.product-subtotal {
		font-size: 16px;
		text-align: right;
	}

	/* ---- Order summary: compact card under the items ---- */
	#brxe-fugmvg .cart-collaterals .cart_totals {
		max-width: none;
		margin: 0;
		padding: 16px 14px 14px;
		border-radius: 12px;
		box-shadow: none;
		box-sizing: border-box;
	}

	#brxe-fugmvg .cart_totals h2 {
		margin: 0 0 4px;
		font-size: 17px;
	}

	#brxe-fugmvg .cart_totals tr > th,
	#brxe-fugmvg .cart_totals tr > td {
		padding: 7px 0;
		font-size: 14px;
	}

	#brxe-fugmvg .cart_totals tr.brina-fs-row > td {
		padding: 2px 0 8px !important;
	}

	#brxe-fugmvg .cart_totals .brina-fs {
		padding: 8px 10px 9px;
	}

	#brxe-fugmvg .cart_totals .brina-fs__message {
		margin-bottom: 6px;
		font-size: 13.5px;
	}

	#brxe-fugmvg .cart_totals tr.brina-ship-dest > td {
		padding: 0 0 8px !important;
		overflow-wrap: anywhere;
	}

	#brxe-fugmvg .cart_totals .brina-ship-dest__text strong {
		white-space: normal;
	}

	#brxe-fugmvg .cart_totals tr.order-total > th,
	#brxe-fugmvg .cart_totals tr.order-total > td {
		padding-top: 11px;
		font-size: 17px;
	}

	#brxe-fugmvg .cart_totals tr.order-total > td {
		font-size: 19px;
	}

	#brxe-fugmvg .cart_totals .brina-total-coupon-gap {
		height: 8px;
	}

	#brxe-fugmvg .cart_totals .wc-proceed-to-checkout {
		padding-top: 12px;
	}

	#brxe-fugmvg .cart_totals .wc-proceed-to-checkout a.checkout-button {
		min-height: 48px;
		padding: 0 12px;
		font-size: 15.5px;
		line-height: 1.25;
		white-space: nowrap;
	}

	/* ---- Compact WooCommerce notices (text and logic unchanged) ---- */
	#brxe-fugmvg .woocommerce-notices-wrapper .woocommerce-error,
	#brxe-fugmvg .woocommerce-notices-wrapper .woocommerce-info,
	#brxe-fugmvg .woocommerce-notices-wrapper .woocommerce-message {
		margin: 0 0 12px;
		padding: 10px 12px;
		font-size: 13.5px;
		line-height: 1.4;
		list-style: none;
		border-radius: 10px;
		box-shadow: none;
		overflow-wrap: anywhere;
	}

	#brxe-fugmvg .woocommerce-notices-wrapper .woocommerce-error::before,
	#brxe-fugmvg .woocommerce-notices-wrapper .woocommerce-info::before,
	#brxe-fugmvg .woocommerce-notices-wrapper .woocommerce-message::before {
		content: none;
	}

	#brxe-fugmvg .woocommerce-notices-wrapper .woocommerce-error {
		color: #8F1D1D;
		background: #FEF4F4;
		border: 1px solid #F3C9CC;
		border-left: 3px solid #C42B2B;
	}

	#brxe-fugmvg .woocommerce-notices-wrapper .woocommerce-info {
		color: #1E3A8A;
		background: #F3F6FE;
		border: 1px solid #CDD8F6;
		border-left: 3px solid #3B5BDB;
	}

	#brxe-fugmvg .woocommerce-notices-wrapper .woocommerce-message {
		color: #14532D;
		background: #F2FBF5;
		border: 1px solid #C6E9D2;
		border-left: 3px solid #15803D;
	}

	#brxe-fugmvg .woocommerce-notices-wrapper .woocommerce-error > li {
		margin: 0;
		padding: 0;
	}

	/* Message with WooCommerce's action button ("View cart" etc.): text
	   left, button right at its natural width (it was being squeezed). */
	#brxe-fugmvg .woocommerce-notices-wrapper .woocommerce-message:has(> .button) {
		display: flex;
		align-items: center;
		justify-content: space-between;
		gap: 10px;
	}

	#brxe-fugmvg .woocommerce-notices-wrapper .woocommerce-message > .button {
		order: 2;
		flex: none;
		float: none;
		min-height: 36px;
		margin: 0;
		padding: 0 12px;
		font-size: 13px;
		line-height: 36px;
		white-space: nowrap;
	}
}

/* =====================================================================
   10. PHONE STICKY CHECKOUT BAR (<= 767.98px; 2026-10-04, owner)
   ---------------------------------------------------------------------
   The summary's own checkout area (.wc-proceed-to-checkout: WooCommerce's
   real "Proceed to checkout" link + the cart total printed beside it in
   cart-totals.php) is fixed to the bottom of the phone viewport. It lives
   inside .cart_totals, which brina-cart.js replaces with WooCommerce's fresh
   HTML after every quantity change / remove / undo, so the total is always
   current with no extra script. Tablet and desktop: the total is hidden
   and the area stays in the summary as before.
   ===================================================================== */
#brxe-fugmvg .cart_totals .brina-checkout-bar__total {
	display: none;
}

@media (max-width: 767.98px) {
	#brxe-fugmvg .cart_totals .wc-proceed-to-checkout {
		position: fixed;
		right: 0;
		bottom: 0;
		left: 0;
		z-index: 900; /* above the cart content; below the account flyout (1100) and toasts */
		display: flex;
		align-items: center;
		gap: 12px;
		width: 100%;
		margin: 0;
		padding: 10px 16px calc(10px + env(safe-area-inset-bottom, 0px));
		background: #FFFFFF;
		border-top: 1px solid #E3E7EF;
		box-shadow: 0 -6px 18px rgba(16, 28, 61, 0.06);
		box-sizing: border-box;
	}

	#brxe-fugmvg .cart_totals .brina-checkout-bar__total {
		display: flex;
		flex: 1 1 auto;
		flex-direction: column;
		min-width: 0;
		margin: 0;
		line-height: 1.15;
	}

	#brxe-fugmvg .cart_totals .brina-checkout-bar__label {
		font-size: 12px;
		font-weight: 500;
		color: var(--cart-muted);
	}

	#brxe-fugmvg .cart_totals .brina-checkout-bar__amount {
		overflow: hidden;
		font-size: 19px;
		font-weight: 700;
		color: var(--cart-ink);
		text-overflow: ellipsis;
		white-space: nowrap;
	}

	#brxe-fugmvg .cart_totals .wc-proceed-to-checkout a.checkout-button {
		flex: 0 0 auto;
		width: auto;
		min-height: 46px;
		padding: 0 20px;
		font-size: 15.5px;
		line-height: 1.2;
		background: var(--cart-accent);
		border-radius: 10px;
	}

	#brxe-fugmvg .cart_totals .wc-proceed-to-checkout a.checkout-button:hover,
	#brxe-fugmvg .cart_totals .wc-proceed-to-checkout a.checkout-button:focus-visible {
		background: #4A3BD6;
	}

	/* Keep the end of the page reachable above the bar (bar = 10 + 46 + 10
	   + 1px border, plus the device's bottom safe area). Populated cart only. */
	body.woocommerce-cart:has(#brxe-fugmvg .cart_totals .wc-proceed-to-checkout) {
		padding-bottom: calc(67px + env(safe-area-inset-bottom, 0px));
	}
}

/* Narrowest phones: a little more room for four-digit totals. */
@media (max-width: 359.98px) {
	#brxe-fugmvg .cart_totals .wc-proceed-to-checkout {
		gap: 10px;
	}

	#brxe-fugmvg .cart_totals .wc-proceed-to-checkout a.checkout-button {
		padding: 0 14px;
		font-size: 14.5px;
	}
}

/* =====================================================================
   11. PHONE CART: NO ORDER SUMMARY CARD + PRODUCT DISCOVERY
       (<= 767.98px; 2026-10-05, owner)
   ---------------------------------------------------------------------
   The Order summary card is not shown on the phone cart; only its checkout
   area remains, as the sticky bottom bar (section 10). WooCommerce still
   renders and recalculates the whole .cart_totals (brina-cart.js refreshes
   it, the bar total comes from it); totals, shipping, tax and coupons are
   shown in the checkout Order summary (coupon entry there on phone).
   In its place: "You may also like" (+ "Recently viewed") from
   inc/brina-cart-discovery.php. Tablet/desktop: summary card unchanged,
   discovery hidden.
   ===================================================================== */
#brxe-fugmvg .brina-cart-reco {
	display: none;
}

@media (max-width: 767.98px) {
	/* Summary card: invisible container; everything but the checkout bar hidden. */
	#brxe-fugmvg .cart-collaterals .cart_totals {
		padding: 0;
		background: none;
		border: 0;
		box-shadow: none;
	}

	#brxe-fugmvg .cart-collaterals .cart_totals > :not(.wc-proceed-to-checkout) {
		display: none !important;
	}

	/* ---- Product discovery (homepage phone card language) ---- */
	#brxe-fugmvg .brina-cart-reco {
		--reco-line: #E5E7EC;
		--reco-ink: #0F172A;
		--reco-muted: #6B7280;
		display: block;
		margin: 4px 0 0;
	}

	#brxe-fugmvg .brina-cart-reco__group + .brina-cart-reco__group {
		margin-top: 24px;
	}

	#brxe-fugmvg .brina-cart-reco__head {
		display: flex;
		align-items: center;
		justify-content: space-between;
		gap: 12px;
		margin: 0 0 10px;
	}

	#brxe-fugmvg .brina-cart-reco__title {
		margin: 0;
		min-width: 0;
		font-size: 19px;
		font-weight: 800;
		line-height: 1.2;
		letter-spacing: -.01em;
		color: var(--reco-ink);
	}

	#brxe-fugmvg .brina-cart-reco__more {
		flex: none;
		display: inline-flex;
		align-items: center;
		gap: 4px;
		min-height: 44px;
		margin: -10px 0;
		font-size: 14px;
		font-weight: 600;
		color: #3B32C4;
		text-decoration: none;
		white-space: nowrap;
	}

	#brxe-fugmvg .brina-cart-reco__grid {
		display: grid;
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 10px;
	}

	#brxe-fugmvg .brina-cart-reco .brina-card {
		--brina-price: var(--reco-ink);
		--brina-muted: var(--reco-muted);
		--brina-sale: #C92F55;
		min-width: 0;
		gap: 0;
		background: #FFFFFF;
		border: 1px solid var(--reco-line);
		border-radius: 12px;
		box-shadow: none;
		overflow: hidden;
	}

	#brxe-fugmvg .brina-cart-reco .brina-card__media {
		display: flex;
		align-items: center;
		justify-content: center;
		aspect-ratio: 1 / 1;
		height: auto;
		background: #FFFFFF;
		border: 0;
		border-radius: 0;
	}

	#brxe-fugmvg .brina-cart-reco .brina-card__img {
		width: 100%;
		height: 100%;
		max-width: 100%;
		padding: 10px;
		box-sizing: border-box;
		object-fit: contain;
		mix-blend-mode: multiply;
	}

	#brxe-fugmvg .brina-cart-reco .brina-card__body {
		gap: 4px;
		padding: 2px 10px 10px;
	}

	#brxe-fugmvg .brina-cart-reco .brina-card__brand {
		font-size: 11px;
		color: var(--reco-muted);
	}

	#brxe-fugmvg .brina-cart-reco .brina-card__title {
		margin: 0;
		font-size: 13.5px;
		font-weight: 500;
		line-height: 1.35;
		color: var(--reco-ink);
		-webkit-line-clamp: 2;
		line-clamp: 2;
		min-height: calc(2em * 1.35);
		overflow-wrap: break-word;
		word-break: normal;
	}

	#brxe-fugmvg .brina-cart-reco .brina-card__link {
		color: inherit;
		text-decoration: none;
	}

	#brxe-fugmvg .brina-cart-reco .brina-card__price {
		margin-top: auto;
		font-size: 15.5px;
		font-weight: 700;
		color: var(--reco-ink);
	}

	#brxe-fugmvg .brina-cart-reco .brina-card__price del {
		font-size: 12.5px;
		font-weight: 400;
		color: var(--reco-muted);
	}

	#brxe-fugmvg .brina-cart-reco .brina-card__price ins {
		color: #C92F55;
		text-decoration: none;
	}

	#brxe-fugmvg .brina-cart-reco .brina-card__discount {
		font-size: 12px;
		font-weight: 600;
		color: #C92F55;
	}

	#brxe-fugmvg .brina-cart-reco .brina-wishlist {
		--brina-heart-size: 20px;
		--brina-heart-hit: 40px;
		top: 4px;
		right: 4px;
	}

	#brxe-fugmvg .brina-cart-reco .brina-card:focus-within {
		outline: 2px solid var(--cart-accent);
		outline-offset: 2px;
	}

	/* Add to cart (simple) / Select options (other types): WooCommerce's own. */
	#brxe-fugmvg .brina-cart-reco .brina-card__action {
		display: flex;
		align-items: center;
		justify-content: center;
		align-self: stretch;
		min-height: 38px;
		margin-top: 6px;
		padding: 0 8px;
		font-size: 13.5px;
		font-weight: 600;
		line-height: 1.2;
		color: var(--cart-accent);
		text-align: center;
		text-decoration: none;
		white-space: nowrap;
		background: #FFFFFF;
		border: 1px solid var(--cart-accent);
		border-radius: 9px;
	}

	#brxe-fugmvg .brina-cart-reco .brina-card__action:hover,
	#brxe-fugmvg .brina-cart-reco .brina-card__action:focus-visible {
		color: #FFFFFF;
		background: var(--cart-accent);
	}

	#brxe-fugmvg .brina-cart-reco .brina-card__action.loading {
		opacity: .7;
		pointer-events: none;
	}

	#brxe-fugmvg .brina-cart-reco .added_to_cart {
		position: relative;
		z-index: 2;
		align-self: center;
		margin-top: 6px;
		font-size: 12.5px;
		font-weight: 600;
		color: var(--cart-accent);
		text-decoration: none;
	}
}

/* =====================================================================
   12. PHONE CART: SELECT ITEMS FOR CHECKOUT (<= 767.98px; 2026-10-05)
   ---------------------------------------------------------------------
   inc/brina-cart-selection.php + assets/js/brina-cart-selection.js.
   A checkbox on each buyable line (top-left of the card, over the image
   frame's corner — the card does not grow), "Select all" in the heading,
   and "N items selected" in the sticky bar instead of the money total.
   Tablet/desktop: the selection cell and Select all are not displayed.
   ===================================================================== */
#brxe-fugmvg tr.cart_item > td.brina-cart-select,
#brxe-fugmvg .brina-cart-selectall {
	display: none;
}

@media (max-width: 767.98px) {
	#brxe-fugmvg table.shop_table.cart tr.cart_item {
		position: relative;
	}

	/* 44px hit area at the card's top-left; the visible box is 22px. */
	#brxe-fugmvg tr.cart_item > td.brina-cart-select {
		position: absolute;
		top: 0;
		left: 0;
		z-index: 2;
		display: block;
		width: 44px;
		height: 44px;
		padding: 0;
	}

	#brxe-fugmvg tr.cart_item > td.brina-cart-select:empty {
		display: none;
	}

	#brxe-fugmvg .brina-cart-select__hit,
	#brxe-fugmvg .brina-cart-selectall {
		position: relative;
		display: flex;
		align-items: center;
		cursor: pointer;
		-webkit-tap-highlight-color: transparent;
	}

	#brxe-fugmvg .brina-cart-select__hit {
		justify-content: center;
		width: 44px;
		height: 44px;
	}

	#brxe-fugmvg .brina-cart-select__input,
	#brxe-fugmvg .brina-cart-selectall__input {
		position: absolute;
		inset: 0;
		width: 100%;
		height: 100%;
		margin: 0;
		opacity: 0;
		cursor: pointer;
	}

	#brxe-fugmvg .brina-cart-select__box {
		position: relative;
		flex: none;
		width: 22px;
		height: 22px;
		background: #FFFFFF;
		border: 1.5px solid #9AA3B2;
		border-radius: 6px;
		box-shadow: 0 1px 2px rgba(16, 28, 61, 0.08);
		box-sizing: border-box;
		pointer-events: none;
		transition: background-color .12s ease, border-color .12s ease;
	}

	#brxe-fugmvg input:checked + .brina-cart-select__box {
		background: var(--cart-accent);
		border-color: var(--cart-accent);
	}

	#brxe-fugmvg input:checked + .brina-cart-select__box::after {
		content: "";
		position: absolute;
		top: 3px;
		left: 6.5px;
		width: 5px;
		height: 10px;
		border: solid #FFFFFF;
		border-width: 0 2.2px 2.2px 0;
		transform: rotate(45deg);
	}

	/* Select all: some selected (indeterminate). */
	#brxe-fugmvg input:indeterminate + .brina-cart-select__box {
		background: var(--cart-accent);
		border-color: var(--cart-accent);
	}

	#brxe-fugmvg input:indeterminate + .brina-cart-select__box::after {
		content: "";
		position: absolute;
		top: 8.5px;
		left: 4.5px;
		width: 10px;
		height: 2.2px;
		background: #FFFFFF;
		border-radius: 1px;
	}

	#brxe-fugmvg input:focus-visible + .brina-cart-select__box {
		outline: 2px solid var(--cart-accent);
		outline-offset: 2px;
	}

	/* Select all: right side of "Your Cart  N items". */
	#brxe-fugmvg .brina-cart-head {
		align-items: center;
	}

	#brxe-fugmvg .brina-cart-selectall {
		gap: 8px;
		min-height: 44px;
		margin: -8px -4px -8px auto;
		padding: 0 4px;
		font-size: 13.5px;
		font-weight: 600;
		color: var(--cart-ink-2);
		white-space: nowrap;
	}

	/* Sticky bar: selected count instead of the money total. */
	#brxe-fugmvg .cart_totals .brina-checkout-bar__count {
		overflow: hidden;
		font-size: 15px;
		font-weight: 700;
		color: var(--cart-ink);
		text-overflow: ellipsis;
		white-space: nowrap;
	}

	/* 0 selected: inactive, not clickable. */
	#brxe-fugmvg .cart_totals .wc-proceed-to-checkout a.checkout-button.is-disabled,
	#brxe-fugmvg .cart_totals .wc-proceed-to-checkout a.checkout-button.is-disabled:hover {
		color: #FFFFFF;
		background: #B9B3F3;
		cursor: not-allowed;
		pointer-events: none;
	}
}
