/* Cart page. WooCommerce's legacy stylesheets are not loaded here; everything is styled below. */

.bb-page--woo {
	padding-block: clamp(28px, 4vw, 64px);
}

/* ---------- Layout: items left, totals right ---------- */
.bb-page--woo .woocommerce {
	display: grid;
	gap: 24px 40px;
	grid-template-columns: minmax(0, 1fr);
	align-items: start;
}

.bb-page--woo .woocommerce > * {
	grid-column: 1 / -1;
}

@media (min-width: 1000px) {
	.woocommerce-cart .woocommerce {
		grid-template-columns: minmax(0, 1fr) 400px;
	}

	.woocommerce-cart .woocommerce-cart-form {
		grid-column: 1;
		grid-row: 2;
	}

	.woocommerce-cart .cart-collaterals {
		grid-column: 2;
		grid-row: 2;
		position: sticky;
		top: 130px;
	}

	.woocommerce-cart .woocommerce-notices-wrapper {
		grid-row: 1;
	}
}

/* ---------- Cart table ---------- */
.shop_table.cart {
	width: 100%;
	border-collapse: collapse;
	background: #fff;
}

.shop_table.cart thead th {
	padding: 16px 18px;
	border-bottom: 1px solid #e6e6e6;
	color: #777;
	font-family: var(--bb-font-head);
	font-size: 15px;
	font-weight: 700;
	letter-spacing: 0.04em;
	text-align: left;
	text-transform: uppercase;
}

.shop_table.cart td {
	padding: 18px;
	border-bottom: 1px solid #eee;
	vertical-align: middle;
}

.shop_table.cart .product-remove {
	width: 44px;
	padding-right: 0;
}

a.remove {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 32px;
	height: 32px;
	border-radius: 50%;
	color: #888;
	font-size: 24px;
	line-height: 1;
	transition: background-color 0.15s, color 0.15s;
}

a.remove:hover {
	background: var(--bb-sale);
	color: #fff;
}

.shop_table.cart .product-thumbnail {
	width: 110px;
}

.shop_table.cart .product-thumbnail img {
	display: block;
	width: 92px;
	height: 92px;
	object-fit: contain;
}

.shop_table.cart .product-name {
	font-family: var(--bb-font-head);
	font-size: 20px;
	font-weight: 700;
	line-height: 1.2;
}

.shop_table.cart .product-name a:hover {
	color: var(--bb-orange);
}

.shop_table.cart .product-name dl.variation {
	margin: 6px 0 0;
	font-family: var(--bb-font-body);
	font-size: 14px;
	font-weight: 400;
	color: #666;
}

.shop_table.cart .product-name dl.variation dt,
.shop_table.cart .product-name dl.variation dd {
	display: inline;
	margin: 0;
}

.shop_table.cart .product-price,
.shop_table.cart .product-subtotal {
	font-family: var(--bb-font-head);
	font-size: 20px;
	white-space: nowrap;
}

.shop_table.cart .product-subtotal {
	color: var(--bb-orange);
	font-weight: 700;
}

/* Coupon + update. The cell spans the whole table, so it must stay a table-cell (not flex);
   the layout is done by the coupon box inside it. */
.shop_table.cart td.actions {
	padding: 20px 18px;
	border-bottom: 0;
	background: #fafafa;
}

.coupon {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	float: left;
}

.shop_table.cart td.actions > .button {
	float: right;
}

.shop_table.cart td.actions::after {
	content: "";
	display: table;
	clear: both;
}

.coupon .input-text,
.woocommerce-cart input[type="text"],
.woocommerce-cart input[type="number"],
.woocommerce-cart select {
	height: 54px;
	padding: 0 16px;
	border: 1px solid #cfcfcf;
	background: #fff;
	font-family: var(--bb-font-head);
	font-size: 18px;
}

.coupon .input-text {
	width: 280px;
	max-width: 100%;
}

.coupon .button {
	min-height: 54px;
	padding: 0 32px;
	font-size: 19px;
}

.woocommerce-cart .button,
.woocommerce-cart button.button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 46px;
	padding: 0 24px;
	border: 0;
	background: #333;
	color: #fff;
	font-family: var(--bb-font-head);
	font-size: 17px;
	font-weight: 700;
	letter-spacing: 0.02em;
	text-transform: uppercase;
	cursor: pointer;
	transition: background-color 0.15s;
}

.woocommerce-cart .button:hover {
	background: var(--bb-orange);
}

/* With JS the cart updates by itself, so the Update button is only for no-JS visitors. */
.js .woocommerce-cart-form [name="update_cart"] {
	display: none;
}

.woocommerce-cart-form.processing {
	opacity: 0.5;
	pointer-events: none;
}

/* ---------- Totals card ---------- */
.cart_totals {
	padding: 26px 26px 28px;
	background: #fff;
	border-top: 3px solid var(--bb-orange);
}

.cart_totals h2 {
	margin-bottom: 16px;
	font-size: 26px;
}

.cart_totals table {
	width: 100%;
	border-collapse: collapse;
}

.cart_totals th,
.cart_totals td {
	padding: 14px 0;
	border-bottom: 1px solid #eee;
	text-align: left;
	vertical-align: top;
}

.cart_totals th {
	width: 36%;
	padding-right: 12px;
	font-family: var(--bb-font-head);
	font-size: 17px;
	font-weight: 700;
	text-transform: uppercase;
}

.cart_totals td {
	font-family: var(--bb-font-head);
	font-size: 19px;
	text-align: right;
}

.cart_totals .order-total th,
.cart_totals .order-total td {
	border-bottom: 0;
	padding-top: 18px;
}

.cart_totals .order-total td {
	color: var(--bb-orange);
	font-size: 30px;
	font-weight: 700;
}

/* Shipping methods (DPD, Venipak, …) */
.woocommerce-shipping-methods {
	display: grid;
	gap: 10px;
	text-align: left;
}

.woocommerce-shipping-methods li {
	display: flex;
	align-items: center;
	gap: 10px;
}

.woocommerce-shipping-methods input[type="radio"] {
	flex: none;
	width: 18px;
	height: 18px;
	margin: 0;
	accent-color: var(--bb-orange);
}

.woocommerce-shipping-methods label {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 4px 10px;
	font-size: 17px;
	line-height: 1.2;
	cursor: pointer;
}

.woocommerce-shipping-methods img {
	width: auto;
	max-height: 24px;
}

.woocommerce-shipping-destination {
	margin: 12px 0 0;
	color: #666;
	font-family: var(--bb-font-body);
	font-size: 14px;
	text-align: left;
}

.shipping-calculator-button {
	display: inline-block;
	margin-top: 10px;
	color: var(--bb-orange);
	font-family: var(--bb-font-body);
	font-size: 14px;
	text-decoration: underline;
}

.shipping-calculator-form {
	display: grid;
	gap: 10px;
	margin-top: 12px;
	text-align: left;
}

.shipping-calculator-form select,
.shipping-calculator-form input {
	width: 100%;
}

.shipping-calculator-form label {
	font-family: var(--bb-font-body);
	font-size: 14px;
}

.wc-proceed-to-checkout {
	margin-top: 22px;
}

.wc-proceed-to-checkout .checkout-button {
	display: flex;
	width: 100%;
	min-height: 58px;
	background: var(--bb-orange);
	font-size: 21px;
}

.wc-proceed-to-checkout .checkout-button:hover {
	background: var(--bb-orange-dark);
}

/* ---------- Empty cart: one centred card (message + button) ---------- */
.woocommerce-cart .cart-empty {
	display: block;
	margin: 0;
	padding: 72px 24px 20px;
	border-left: 0;
	background: #fff;
	font-family: var(--bb-font-head);
	font-size: clamp(24px, 3vw, 32px);
	text-align: center;
}

/* Joins the message card above it (cancels the grid gap), so message + button read as one card. */
.woocommerce-cart .return-to-shop {
	display: flex;
	justify-content: center;
	margin: -24px 0 0;
	padding: 0 24px 72px;
	background: #fff;
}

.return-to-shop .button {
	min-width: 220px;
	background: var(--bb-orange);
}

.return-to-shop .button:hover {
	background: var(--bb-orange-dark);
}

/* ---------- Cross-sells ---------- */
.bb-crosssells {
	margin-top: 24px;
}

.bb-crosssells__title {
	margin-bottom: 20px;
	font-size: clamp(26px, 3vw, 38px);
}

/* ---------- Phones: each cart row becomes a card ---------- */
@media (max-width: 999px) {
	.cart_totals {
		position: static;
	}
}

@media (max-width: 720px) {
	.shop_table.cart thead {
		display: none;
	}

	.shop_table.cart,
	.shop_table.cart tbody {
		display: block;
	}

	.shop_table.cart tr.cart_item {
		position: relative;
		display: grid;
		grid-template-columns: 92px minmax(0, 1fr);
		gap: 6px 16px;
		padding: 16px;
		border-bottom: 1px solid #eee;
	}

	.shop_table.cart tr.cart_item td {
		padding: 0;
		border: 0;
	}

	.shop_table.cart tr.cart_item .product-thumbnail {
		grid-row: 1 / span 4;
		width: auto;
	}

	.shop_table.cart tr.cart_item .product-name,
	.shop_table.cart tr.cart_item .product-price,
	.shop_table.cart tr.cart_item .product-quantity,
	.shop_table.cart tr.cart_item .product-subtotal {
		grid-column: 2;
	}

	.shop_table.cart tr.cart_item .product-name {
		padding-right: 36px;
		font-size: 18px;
	}

	.shop_table.cart tr.cart_item .product-remove {
		position: absolute;
		top: 8px;
		right: 8px;
		width: auto;
	}

	.shop_table.cart tr.cart_item .product-price::before,
	.shop_table.cart tr.cart_item .product-subtotal::before {
		content: attr(data-title) ": ";
		color: #888;
		font-size: 15px;
	}

	.shop_table.cart tr.cart_item .product-price,
	.shop_table.cart tr.cart_item .product-subtotal {
		font-size: 18px;
	}

	.shop_table.cart tr:not(.cart_item) {
		display: block;
	}

	.shop_table.cart td.actions {
		display: block;
		padding: 16px;
	}

	.coupon {
		display: grid;
		float: none;
		grid-template-columns: minmax(0, 1fr);
	}

	.shop_table.cart td.actions > .button {
		float: none;
		width: 100%;
		margin-top: 10px;
	}

	.coupon .input-text {
		width: 100%;
	}
}
