/* ------------------------------------------------------------ *\
	Biovancia v3 — Cart page (templates/cart-design.php, gated
	BVA_V3_CHECKOUT). Layout + product rows + recap card over the
	untouched woocommerce/cart/* markup. Shared sections (buttons,
	services, slider, notices) live in wc-shared.css.
\* ------------------------------------------------------------ */

/* Two-rail layout: form left, recap + services right. Row 1 is reserved
   for the full-width notice banners Woo prints before the form (they focus
   on render — misplaced, they drag the scroll to the bottom of the page). */
.v3.woocommerce-cart .woocommerce__inner {
	display: grid;
	grid-template-columns: minmax(0, 1fr) 424px;
	grid-template-rows: auto auto auto 1fr;
	column-gap: 64px;
	align-items: start;
}

.v3.woocommerce-cart .woocommerce__inner > .woocommerce-notices-wrapper,
.v3.woocommerce-cart .woocommerce__inner > .woocommerce-error,
.v3.woocommerce-cart .woocommerce__inner > .woocommerce-message,
.v3.woocommerce-cart .woocommerce__inner > .woocommerce-info {
	grid-column: 1 / -1;
	grid-row: 1;
}

.v3 .woocommerce-cart-form {
	grid-column: 1;
	grid-row: 2 / span 3;
}

.v3.woocommerce-cart .cart-collaterals {
	grid-column: 2;
	grid-row: 2;
}

.v3.woocommerce-cart .section-services {
	grid-column: 2;
	grid-row: 3;
}

/* woocommerce-layout.css floats the totals to 48% — full rail here. */
.v3.woocommerce-cart .cart-collaterals .cart_totals {
	float: none;
	width: 100%;
}

/* Rendered inside the collaterals wrapper, right after the totals card. */
.v3.woocommerce-cart .cart-coupon {
	width: 100%;
	margin-top: 24px;
}

/* Same scale + margin as the "Récapitulatif" heading so both rails' cards
   start at the same height. */
.v3.woocommerce-cart .woocommerce__inner h1 {
	margin: 0 0 24px;
	font-size: 28px;
	font-weight: 500;
	line-height: 1.3;
}

/* --- Product rows -------------------------------------------------- */

.v3 .product-row {
	display: grid;
	grid-template-columns: 128px minmax(0, 1fr) auto;
	gap: 24px 32px;
	padding: 24px;
	margin-bottom: 16px;
}

/* Cap the text column on wide screens so the space-between price lines stay
   visually attached to their labels instead of drifting toward the actions. */
.v3 .product-row .product-name {
	max-width: 560px;
}

.v3 .product-thumbnail img {
	display: block;
	width: 100%;
	height: auto;
	border-radius: 4px;
	background: var(--bva-cream);
}

.v3 .product-name .product__title {
	margin-bottom: 12px;
}

.v3 .product-name .product__title a {
	font-family: var(--bva-font-sans);
	font-size: 20px;
	font-weight: 600;
	line-height: 1.2;
	color: var(--bva-black);
	text-decoration: none;
}

.v3 .product-name .product__title a:hover {
	text-decoration: underline;
}

.v3 .product-name .product__title p {
	margin: 6px 0 0;
	font-family: var(--bva-font-sans);
	font-size: 14px;
	font-weight: 400;
	line-height: 1.45;
	color: var(--bva-text-60);
}

.v3 .product-units .product-unit-meta {
	display: flex;
	justify-content: space-between;
	gap: 16px;
	margin: 0 0 6px;
	font-family: var(--bva-font-sans);
	font-size: 15px;
	font-weight: 400;
	color: var(--bva-black);
}

.v3 .product-units .product-unit-meta b {
	font-weight: 500;
}

.v3 .product-units .product-unit-meta s {
	color: var(--bva-muted);
}

.v3 .product-units .highlight {
	display: flex;
	justify-content: space-between;
	gap: 16px;
	margin: 0;
	font-family: var(--bva-font-sans);
	font-size: 15px;
	font-weight: 500;
	color: var(--bva-canelle-400);
}

.v3 .product-price p {
	display: flex;
	justify-content: space-between;
	gap: 16px;
	margin: 12px 0 0;
	padding-top: 12px;
	border-top: 1px solid var(--bva-line);
	font-family: var(--bva-font-sans);
	font-size: 16px;
	font-weight: 600;
	color: var(--bva-black);
}

.v3 .product-subtotal {
	display: flex;
	flex-direction: column;
	align-items: flex-end;
	gap: 12px;
}

.v3 .product-subtotal h4 {
	margin: 0;
	font-family: var(--bva-font-sans);
	font-size: 20px;
	font-weight: 600;
	color: var(--bva-black);
}

.v3 .product-subtotal .edit {
	margin-top: auto;
}

/* woocommerce.css ships `a.remove { color: red !important; width/height: 1em;
   border-radius: 100% }` (the round × icon) — flatten it back to a text link. */
.v3 .product-subtotal .remove {
	display: inline-block;
	width: auto;
	height: auto;
	background: none !important;
	border-radius: 0;
	text-align: right;
	font-family: var(--bva-font-sans);
	font-size: 13px !important;
	font-weight: 400;
	line-height: 1.4;
	color: #c26a52 !important; /* soft brick red — destructive but quiet */
	text-decoration: underline;
	text-underline-offset: 3px;
}

.v3 .product-subtotal .remove:hover {
	color: #b3401f !important;
	background: none !important;
}

/* --- Recap (cart totals) ------------------------------------------- */

.v3.woocommerce-cart .cart-collaterals > h2 {
	margin: 0 0 24px;
	font: var(--bva-t-header-l);
	font-weight: 500;
	color: var(--bva-black);
}

.v3 .cart_totals {
	padding: 28px 24px;
}

/* "Prix normal" headline row inside the card. */
.v3 .cart_totals > h2 {
	display: flex;
	justify-content: space-between;
	gap: 16px;
	margin: 0 0 8px;
	padding-bottom: 16px;
	border-bottom: 1px solid var(--bva-line);
	font-family: var(--bva-font-sans);
	font-size: 16px;
	font-weight: 400;
	color: var(--bva-black);
}

/* Kill the plugin's boxed table (outer border + per-cell border-top). */
.v3 .cart_totals table.shop_table {
	width: 100%;
	margin: 0 0 8px;
	border: 0;
	border-collapse: collapse;
	background: transparent;
}

.v3 .cart_totals table.shop_table tr th,
.v3 .cart_totals table.shop_table tr td {
	padding: 10px 0;
	border: 0;
	border-bottom: 1px solid var(--bva-hairline);
	background: transparent;
	font-family: var(--bva-font-sans);
	font-size: 15px;
	font-weight: 400;
	text-align: left;
	color: var(--bva-black);
}

.v3 .cart_totals table.shop_table tr:last-child th,
.v3 .cart_totals table.shop_table tr:last-child td {
	border-bottom: 0;
}

.v3 .cart_totals table.shop_table tr td {
	text-align: right;
}

.v3 .cart_totals table.shop_table tr.order-discount th,
.v3 .cart_totals table.shop_table tr.order-discount td {
	color: var(--bva-canelle-400);
	font-weight: 500;
}

.v3 .cart_totals table.shop_table tr.order-total th,
.v3 .cart_totals table.shop_table tr.order-total td {
	padding-top: 16px;
	border-top: 1px solid var(--bva-line);
	font-size: 19px;
	font-weight: 600;
}

.v3 .wc-proceed-to-checkout {
	margin: 0;
	padding: 0;
}

.v3 .wc-proceed-to-checkout .checkout-button {
	width: 100%;
	margin-top: 20px;
}

/* Payment logos strip under the CTA. */
.v3 .wc-proceed-to-checkout ~ img,
.v3 .cart_totals img {
	display: block;
	max-width: 260px;
	margin: 16px auto 0;
}

/* --- Coupon -------------------------------------------------------- */

.v3.woocommerce-cart .cart-collaterals .cart-coupon {
	padding: 24px;
}

.v3 .cart-coupon p {
	margin: 0 0 16px;
	font: var(--bva-t-label);
	font-weight: 400;
	letter-spacing: 0.02em;
	text-transform: uppercase;
	color: rgba(0, 0, 0, 0.6);
}

.v3 .cart-coupon .coupon {
	display: flex;
	align-items: flex-end;
	gap: 12px;
}

.v3 .cart-coupon .coupon input.input-text {
	flex: 1;
	min-width: 0;
	padding: 0 0 12px;
	border: 0;
	border-bottom: 1px solid var(--bva-line);
	border-radius: 0;
	background: transparent;
	font-family: var(--bva-font-sans);
	font-size: 16px;
	font-weight: 400;
	color: var(--bva-black);
	outline: none;
}

.v3 .cart-coupon .coupon input.input-text:focus {
	border-bottom-color: var(--bva-black);
}

.v3 .cart-coupon .coupon button {
	min-height: 44px;
	padding: 0 20px;
}

/* --- Remove confirmation modal (toggled by main.js) ----------------- */

.v3 .remove-overlay {
	position: fixed;
	inset: 0;
	z-index: 101;
	display: none;
	justify-content: center;
	align-items: center;
	padding: 3%;
	background: rgba(21, 20, 18, 0.6);
}

.v3 .remove-overlay.active {
	display: flex;
}

.v3 .remove-overlay__inner {
	max-width: 480px;
	padding: 40px 32px;
	background: var(--bva-white-pure);
	border-radius: 8px;
}

.v3 .remove-overlay__inner p {
	margin: 0 0 28px;
	font-family: var(--bva-font-sans);
	font-size: 20px;
	font-weight: 500;
	line-height: 1.35;
	text-align: center;
	color: var(--bva-black);
}

.v3 .remove-overlay__actions {
	display: flex;
	justify-content: center;
	gap: 16px;
}

.v3 .remove-overlay__actions .remove-real {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 13px 24px;
	background: var(--bva-black);
	color: var(--bva-white);
	border: 1px solid var(--bva-black);
	border-radius: 2px;
	font-family: var(--bva-font-sans);
	font-size: 13px;
	font-weight: 600;
	text-transform: uppercase;
	text-decoration: none;
	transition: background 0.15s ease;
}

.v3 .remove-overlay__actions .remove-real:hover {
	background: var(--bva-espresso);
}

/* --- Empty cart ----------------------------------------------------- */

.v3 .section-about .section__head {
	padding: 96px 0 64px;
	text-align: center;
}

.v3 .section-about .section__head h2 {
	margin: 0 0 32px;
	font: var(--bva-t-header-l);
	font-weight: 500;
	color: var(--bva-black);
}

/* --- Responsive ------------------------------------------------------ */

@media (max-width: 1200px) {
	.v3.woocommerce-cart .woocommerce__inner {
		grid-template-columns: minmax(0, 1fr) 360px;
		column-gap: 40px;
	}
}

@media (max-width: 980px) {
	.v3.woocommerce-cart .woocommerce__inner {
		display: block;
	}

	.v3.woocommerce-cart .cart-collaterals {
		margin-top: 40px;
	}

	.v3.woocommerce-cart .section-services {
		margin-top: 40px;
	}
}

@media (max-width: 560px) {
	.v3 .product-row {
		grid-template-columns: 96px minmax(0, 1fr);
		gap: 16px;
		padding: 16px;
	}

	.v3 .product-subtotal {
		grid-column: 1 / -1;
		flex-direction: row;
		align-items: center;
		justify-content: flex-end;
	}

	.v3 .product-subtotal h4 {
		margin-right: auto;
	}

	.v3 .cart-coupon .coupon {
		flex-direction: column;
		align-items: stretch;
	}
}
