/**
 * Cart page (woocommerce/cart/cart.php + cart-totals.php + cart-shipping.php
 * + cart-empty.php) — compact, Shopify-inspired layout. Scoped to
 * body.woocommerce-cart (WooCommerce's own body_class() addition on this
 * page — see wc_body_class() core-side — so nothing here can leak onto any
 * other page) and loaded conditionally (functions.php, is_cart()).
 *
 * Reuses the same warm-neutral palette and card language already
 * established by the header's [wow_mini_cart] drawer (.wow-mini-cart__*,
 * see style.css) — rounded thumbnails, uppercase Josefin Sans titles, grey
 * meta text, accent/black button pair — so the full cart page reads as that
 * drawer's "big sister", not a different product bolted onto the site.
 */

.wow-cart img {
	max-width: 100%;
}

/* Same fix as checkout-page.css: the database-stored "Page: Cart" template's
   ".entry-content.is-layout-constrained" wrapper applies its own width/
   centering to the WooCommerce-injected .woocommerce div, which can fight
   with .wow-cart's own 1280px/auto-margin below and throw the whole page
   off-center. Reset those ancestors to full-width/no-margin so .wow-cart is
   the only thing controlling width + centering here. */
body.woocommerce-cart .entry-content,
body.woocommerce-cart .woocommerce {
	max-width: none;
	width: 100%;
	margin: 0;
	padding: 0;
}

.wow-cart {
	max-width: 1000px;
	margin: 0 auto;
	padding: 48px 32px 110px;
}

.wow-cart-head {
	margin: 0 0 32px;
}

.wow-cart-head__title {
	margin: 0;
	font-family: var(--wp--preset--font-family--josefin);
	font-size: clamp(24px, 3vw, 34px);
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	color: var(--wp--preset--color--black);
}

.wow-cart-layout {
	display: grid;
	grid-template-columns: 1fr 380px;
	gap: 56px;
	align-items: start;
}

form.woocommerce-cart-form {
	min-width: 0;
}

/* ── Item list ─────────────────────────────────────────────────────────── */
.wow-cart-items {
	display: flex;
	flex-direction: column;
}

.wow-cart-item {
	display: flex;
	gap: 20px;
	padding: 24px 0;
	border-bottom: 1px solid #eee;
}

.wow-cart-item:first-child {
	padding-top: 0;
}

.wow-cart-item__image {
	flex-shrink: 0;
	width: 96px;
	height: 96px;
	border-radius: 10px;
	overflow: hidden;
	background-color: #fafafa;
	display: flex;
	align-items: center;
	justify-content: center;
}

.wow-cart-item__image img {
	max-width: 100%;
	max-height: 100%;
	object-fit: contain;
}

.wow-cart-item__body {
	flex: 1;
	min-width: 0;
	display: flex;
	flex-direction: column;
	justify-content: space-between;
	gap: 14px;
}

.wow-cart-item__head {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 12px;
}

.wow-cart-item__name a {
	display: inline-block;
	font-family: var(--wp--preset--font-family--josefin);
	font-size: 14px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.3px;
	color: var(--wp--preset--color--black);
	text-decoration: none;
}

.wow-cart-item__name a:hover {
	color: var(--wp--preset--color--accent);
}

/* Configurator selections (Print type / Frame Color / Artwork size) — see
   wow_nc_display_in_cart() in functions.php, output here via core's own
   wc_get_formatted_cart_item_data() as a <dl class="variation">. */
.wow-cart-item__name dl.variation {
	margin: 8px 0 0;
	display: flex;
	flex-direction: column;
	gap: 2px;
}

.wow-cart-item__name dl.variation dt,
.wow-cart-item__name dl.variation dd {
	display: inline;
	margin: 0;
	font-size: 12px;
	font-weight: 300;
	color: var(--wp--preset--color--grey);
}

.wow-cart-item__name dl.variation dt {
	font-weight: 700;
	color: var(--wp--preset--color--text);
}

.wow-cart-item__name dl.variation dd p {
	display: inline;
	margin: 0;
}

.product-remove.wow-cart-item__remove {
	flex-shrink: 0;
}

.product-remove.wow-cart-item__remove a {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 28px;
	height: 28px;
	border-radius: 50%;
	background-color: #f5f2ee;
	color: #7a756f;
	transition: background-color 0.2s ease, color 0.2s ease;
}

.product-remove.wow-cart-item__remove a:hover,
.product-remove.wow-cart-item__remove a:focus-visible {
	background-color: #000;
	color: #fff;
}

.wow-cart-item__foot {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	margin-top: auto;
}

.wow-cart-item__stepper {
	display: inline-flex;
	align-items: center;
	border: 1px solid #e4e0da;
	border-radius: 999px;
	overflow: hidden;
}

.wow-cart-item__qty-btn {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 30px;
	height: 30px;
	border: none;
	background: none;
	font-size: 15px;
	line-height: 1;
	color: var(--wp--preset--color--text);
	cursor: pointer;
	transition: background-color 0.15s ease;
}

.wow-cart-item__qty-btn:hover,
.wow-cart-item__qty-btn:focus-visible {
	background-color: #faf8f5;
}

.wow-cart-item__stepper .quantity {
	margin: 0;
}

.wow-cart-item__stepper input.qty {
	width: 36px;
	height: 30px;
	padding: 0;
	border: none;
	background: none;
	text-align: center;
	font-family: var(--wp--preset--font-family--josefin);
	font-size: 13px;
	font-weight: 700;
	color: var(--wp--preset--color--text);
	-moz-appearance: textfield;
}

.wow-cart-item__stepper input.qty::-webkit-outer-spin-button,
.wow-cart-item__stepper input.qty::-webkit-inner-spin-button {
	-webkit-appearance: none;
	margin: 0;
}

.wow-cart-item__price {
	font-family: var(--wp--preset--font-family--josefin);
	font-size: 15px;
	font-weight: 700;
	color: var(--wp--preset--color--black);
	white-space: nowrap;
}

/* ── Actions row (continue shopping / coupon / update) ────────────────── */
.wow-cart-actions {
	display: flex;
	align-items: center;
	justify-content: space-between;
	flex-wrap: wrap;
	gap: 16px;
	margin-top: 8px;
	padding-top: 24px;
	border-top: 1px solid #eee;
}

.wow-cart-actions__continue {
	font-family: var(--wp--preset--font-family--josefin);
	font-size: 12px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	color: var(--wp--preset--color--grey);
	text-decoration: none;
}

.wow-cart-actions__continue:hover,
.wow-cart-actions__continue:focus-visible {
	color: var(--wp--preset--color--accent);
}

/* Real submit button, kept in the DOM and fully functional (Enter-key
   fallback, and assets/js/cart-page.js clicks it programmatically after the
   qty stepper changes a value) — just not meant to be seen, since the
   stepper already triggers the same AJAX update on its own. */
.wow-cart-actions__update {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

.wow-cart-coupon {
	flex-basis: 100%;
	order: 3;
}

.wow-cart-coupon__toggle {
	display: inline-block;
	font-size: 12px;
	color: var(--wp--preset--color--grey);
	text-decoration: underline;
	cursor: pointer;
	list-style: none;
}

.wow-cart-coupon__toggle::-webkit-details-marker {
	display: none;
}

.wow-cart-coupon__toggle:hover {
	color: var(--wp--preset--color--text);
}

.wow-cart-coupon__row {
	display: flex;
	gap: 8px;
	margin-top: 12px;
	max-width: 360px;
}

.wow-cart-coupon__row #coupon_code {
	flex: 1;
	min-width: 0;
	padding: 10px 14px;
	border: 1px solid #e4e0da;
	border-radius: 6px;
	font-size: 13px;
	font-family: var(--wp--preset--font-family--josefin);
}

.wow-cart-coupon__apply {
	flex-shrink: 0;
	padding: 10px 18px;
	border: none;
	border-radius: 6px;
	background-color: var(--wp--preset--color--black);
	color: #fff;
	font-family: var(--wp--preset--font-family--josefin);
	font-size: 11px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	cursor: pointer;
	transition: background-color 0.2s ease;
}

.wow-cart-coupon__apply:hover,
.wow-cart-coupon__apply:focus-visible {
	background-color: var(--wp--preset--color--accent);
}

.coupon-error-notice {
	margin: 8px 0 0;
	font-size: 12px;
	color: var(--wp--preset--color--accent);
}

/* ── Order summary card ───────────────────────────────────────────────── */
.wow-cart-summary {
	min-width: 0;
}

.wow-cart-summary__card {
	position: sticky;
	top: 24px;
	background-color: #faf8f5;
	border-radius: 14px;
	padding: 28px;
}

.wow-cart-summary__title {
	margin: 0 0 20px;
	font-family: var(--wp--preset--font-family--josefin);
	font-size: 15px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 1px;
	color: var(--wp--preset--color--black);
}

.wow-cart-summary__rows {
	display: flex;
	flex-direction: column;
	gap: 14px;
}

.wow-cart-summary__row {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 12px;
	font-size: 13px;
	color: var(--wp--preset--color--text);
}

.wow-cart-summary__row > span:first-child {
	color: var(--wp--preset--color--grey);
	flex-shrink: 0;
}

.wow-cart-summary__row > span:last-child {
	text-align: right;
}

.wow-cart-summary__row--total {
	margin-top: 4px;
	padding-top: 14px;
	border-top: 1px solid #e4e0da;
	font-family: var(--wp--preset--font-family--josefin);
	text-transform: uppercase;
	letter-spacing: 0.5px;
}

.wow-cart-summary__row--total > span:first-child {
	color: var(--wp--preset--color--text);
	font-weight: 700;
}

.wow-cart-summary__row--total strong {
	font-size: 17px;
	font-weight: 700;
}

.wow-cart-summary__row--total .includes_tax {
	display: block;
	margin-top: 2px;
	font-size: 11px;
	font-weight: 400;
	text-transform: none;
	letter-spacing: normal;
	color: var(--wp--preset--color--grey);
}

.woocommerce-remove-coupon {
	margin-left: 8px;
	font-size: 11px;
	color: var(--wp--preset--color--grey);
	text-decoration: underline;
}

.woocommerce-remove-coupon:hover {
	color: var(--wp--preset--color--accent);
}

/* Shipping — method list + calculator toggle/form (core-rendered, see
   woocommerce/cart/cart-shipping.php override; the calculator's country/
   state <select> markup is left completely untouched since selectWoo/
   WooCommerce's own country_to_state.js target those exact IDs/classes). */
.wow-cart-summary__row--shipping {
	flex-direction: column;
}

.wow-cart-summary__row--shipping > span:last-child {
	width: 100%;
	text-align: left;
}

#shipping_method {
	list-style: none;
	margin: 6px 0 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	gap: 8px;
}

#shipping_method li {
	font-size: 13px;
}

#shipping_method label {
	margin-left: 6px;
}

.woocommerce-shipping-destination {
	margin: 8px 0 0;
	font-size: 12px;
	color: var(--wp--preset--color--grey);
}

.shipping-calculator-button {
	display: inline-block;
	margin-top: 8px;
	font-size: 11px;
	color: var(--wp--preset--color--grey);
	text-decoration: underline;
	cursor: pointer;
}

.shipping-calculator-button:hover {
	color: var(--wp--preset--color--text);
}

.shipping-calculator-form {
	margin-top: 14px;
	padding-top: 14px;
	border-top: 1px dashed #e4e0da;
}

.shipping-calculator-form .form-row {
	margin: 0 0 10px;
}

.shipping-calculator-form label {
	display: block;
	margin: 0 0 4px;
	font-size: 11px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.4px;
	color: var(--wp--preset--color--grey);
}

.shipping-calculator-form select,
.shipping-calculator-form input.input-text {
	width: 100%;
	box-sizing: border-box;
	padding: 9px 10px;
	border: 1px solid #e4e0da;
	border-radius: 6px;
	background-color: #fff;
	font-size: 13px;
	font-family: var(--wp--preset--font-family--josefin);
}

.shipping-calculator-form button[name="calc_shipping"] {
	padding: 10px 18px;
	border: none;
	border-radius: 6px;
	background-color: var(--wp--preset--color--black);
	color: #fff;
	font-family: var(--wp--preset--font-family--josefin);
	font-size: 11px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	cursor: pointer;
}

.shipping-calculator-form button[name="calc_shipping"]:hover {
	background-color: var(--wp--preset--color--accent);
}

/* ── Proceed to checkout ──────────────────────────────────────────────── */
.wow-cart-summary__checkout {
	margin-top: 24px;
}

.wow-cart-summary__checkout .checkout-button {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	box-sizing: border-box;
	padding: 16px;
	border-radius: 8px;
	background-color: var(--wp--preset--color--accent);
	color: #fff;
	font-family: var(--wp--preset--font-family--josefin);
	font-size: 13px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 1px;
	text-decoration: none;
	transition: background-color 0.2s ease, transform 0.2s ease;
}

.wow-cart-summary__checkout .checkout-button:hover,
.wow-cart-summary__checkout .checkout-button:focus-visible {
	background-color: var(--wp--preset--color--black);
	color: #fff;
	transform: translateY(-1px);
}

.wow-cart-summary__note {
	margin: 16px 0 0;
	font-size: 11px;
	color: var(--wp--preset--color--grey);
	text-align: center;
}

/* ── Empty cart ────────────────────────────────────────────────────────── */
.wow-cart--empty-page {
	min-height: 46vh;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	text-align: center;
}

.wow-cart-empty__text {
	margin: 0 0 20px;
	font-size: 15px;
	color: var(--wp--preset--color--grey);
}

.return-to-shop {
	margin: 0;
}

.wow-cart-empty__btn {
	display: inline-flex;
	align-items: center;
	border: 1px solid #e2e2e2;
	border-radius: 999px;
	padding: 12px 30px;
	font-family: var(--wp--preset--font-family--josefin);
	font-size: 12px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	color: var(--wp--preset--color--text);
	text-decoration: none;
	transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.wow-cart-empty__btn:hover,
.wow-cart-empty__btn:focus-visible {
	background-color: #000;
	border-color: #000;
	color: #fff;
}

/* ── Notices (WooCommerce's own .woocommerce-error / -message / -info,
   still core-rendered — see do_action('woocommerce_before_cart') in
   cart.php) — unstyled by default with core CSS dequeued sitewide. ── */
.wow-cart .woocommerce-error,
.wow-cart .woocommerce-message,
.wow-cart .woocommerce-info {
	list-style: none;
	margin: 0 0 24px;
	padding: 14px 18px;
	border-radius: 8px;
	background-color: #f5f2ee;
	color: var(--wp--preset--color--text);
	font-size: 13px;
}

.wow-cart .woocommerce-error {
	background-color: #fbeaea;
	color: var(--wp--preset--color--accent);
}

.wow-cart .woocommerce-message .button {
	margin-left: 12px;
	font-weight: 700;
	color: var(--wp--preset--color--black);
	text-decoration: underline;
}

/* ── Responsive ────────────────────────────────────────────────────────── */
@media (max-width: 900px) {
	.wow-cart {
		padding: 32px 20px 80px;
	}

	.wow-cart-layout {
		grid-template-columns: 1fr;
		gap: 40px;
	}

	.wow-cart-summary__card {
		position: static;
	}
}

@media (max-width: 560px) {
	.wow-cart-item {
		gap: 14px;
	}

	.wow-cart-item__image {
		width: 76px;
		height: 76px;
	}

	.wow-cart-item__foot {
		flex-wrap: wrap;
	}

	.wow-cart-actions {
		justify-content: flex-start;
	}
}
