/**
 * CLUSE — cart drawer + cart page.
 *
 * Reference geometry: cart page .page-width--narrow (1000, 60px/40px) → content 920,
 * 150px image + 30px gap + details grid (1fr / 100px qty / 207px total), uppercase
 * 11.9px labels (letter-spacing 2.38px), footer border-top + 30px padding,
 * 445px checkout button. Drawer: 450px right panel, 90px thumbs.
 */

/* ------------------------------------------------------------------ *
 * 1. Quantity stepper (shared by cart page + drawer)
 * ------------------------------------------------------------------ */
.cluse-cart-page .js-qty__wrapper,
.cluse-cart-drawer .js-qty__wrapper {
	background: #fff;
	border: 1px solid var(--cluse-border);
	box-sizing: border-box;
	display: block;
	height: 28.1px;
	max-width: none;
	position: relative;
	width: 80px;
}

.cluse-cart-page .js-qty__num,
.cluse-cart-drawer .js-qty__num {
	appearance: textfield;
	-moz-appearance: textfield;
	background: none;
	border: 0;
	box-sizing: border-box;
	font-family: var(--cluse-font-body);
	font-size: 14px;
	height: 100%;
	line-height: 1;
	padding: 0 26px;
	text-align: center;
	width: 100%;
}

.cluse-cart-page .js-qty__num::-webkit-outer-spin-button,
.cluse-cart-page .js-qty__num::-webkit-inner-spin-button,
.cluse-cart-drawer .js-qty__num::-webkit-outer-spin-button,
.cluse-cart-drawer .js-qty__num::-webkit-inner-spin-button {
	-webkit-appearance: none;
	margin: 0;
}

.cluse-cart-page .js-qty__adjust,
.cluse-cart-drawer .js-qty__adjust {
	align-items: center;
	background: none;
	border: 0;
	color: var(--cluse-ink);
	cursor: pointer;
	display: flex;
	font-size: 15px;
	height: 100%;
	justify-content: center;
	line-height: 1;
	padding: 0;
	position: absolute;
	top: 0;
	width: 26px;
}

.cluse-cart-page .js-qty__adjust--minus,
.cluse-cart-drawer .js-qty__adjust--minus {
	left: 0;
}

.cluse-cart-page .js-qty__adjust--plus,
.cluse-cart-drawer .js-qty__adjust--plus {
	right: 0;
}

/* ------------------------------------------------------------------ *
 * 2. Free-shipping progress
 * ------------------------------------------------------------------ */
.cart-free-shipping {
	margin: 0 0 20px;
}

.cart-free-shipping--page {
	margin-bottom: 30px;
}

.cart-free-shipping__label {
	font-size: 13px;
	line-height: 1.5;
	margin: 0 0 8px;
}

.cart-free-shipping__bar {
	background: var(--cluse-border);
	height: 3px;
	overflow: hidden;
	width: 100%;
}

.cart-free-shipping__fill {
	background: var(--cluse-green);
	display: block;
	height: 100%;
	transition: width 0.4s ease;
}

/* ------------------------------------------------------------------ *
 * 3. Cart rule notice (mu-plugin cluse-pricing.php markup — style only)
 * ------------------------------------------------------------------ */
.cluse-rule-notice {
	align-items: flex-start;
	background: #f7f7f4;
	border-left: 3px solid var(--cluse-green);
	display: flex;
	font-size: 13px;
	gap: 12px;
	line-height: 1.5;
	margin: 0 0 25px;
	padding: 12px 15px;
}

.cluse-rule-notice[data-rule='regular'] {
	border-left-color: var(--cluse-sale);
}

.cluse-rule-notice__badge {
	background: var(--cluse-green);
	color: #fff;
	flex: 0 0 auto;
	font-family: var(--cluse-font-heading);
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.12em;
	line-height: 1.2;
	padding: 4px 7px;
	text-transform: uppercase;
	white-space: nowrap;
}

.cluse-rule-notice[data-rule='regular'] .cluse-rule-notice__badge {
	background: var(--cluse-sale);
}

.cluse-rule-notice__text {
	display: block;
}

.cluse-rule-notice__shipping {
	color: #6b6c6c;
	display: block;
	margin-top: 3px;
}

/* ------------------------------------------------------------------ *
 * 4. Cart page
 * ------------------------------------------------------------------ */
.cluse-cart-page .section-header {
	margin-bottom: 30px;
}

.cart-page__back {
	font-size: 13px;
	margin-top: 10px;
}

.cart-page__back a {
	text-decoration: underline;
	text-underline-offset: 2px;
}

.cart__item {
	align-items: start;
	display: grid;
	gap: 30px;
	grid-template-columns: 150px 1fr;
	padding: 0 0 30px;
}

.cart__item--headers {
	align-items: end;
	font-family: var(--cluse-font-heading);
	font-size: 11.9px;
	font-weight: 700;
	grid-template-columns: 150px 1fr;
	letter-spacing: 2.38px;
	line-height: 1.2;
	margin-bottom: 30px;
	padding-bottom: 0;
	text-transform: uppercase;
}

.cart__item--headers .cart__item--details {
	border-bottom: 1px solid var(--cluse-border);
	padding-bottom: 15px;
}

.cart__item--image .image-wrap {
	aspect-ratio: 1 / 1;
	background: var(--cluse-image-bg);
	display: block;
	overflow: hidden;
}

.cart__item--image img {
	display: block;
	height: 100%;
	object-fit: cover;
	width: 100%;
}

.cart__item--details {
	align-items: center;
	display: grid;
	gap: 20px;
	grid-template-columns: 1fr 100px 207px;
}

.cart__item--headers .cart__item--details {
	align-items: end;
	grid-template-columns: 1fr 100px 207px;
}

.cart__item--name {
	padding-right: 20px;
}

.cart__product-name {
	color: var(--cluse-ink);
	display: block;
	font-size: 14px;
	line-height: 1.6;
	text-decoration: none;
}

.cart__product-name:hover {
	text-decoration: underline;
	text-underline-offset: 2px;
}

.cart__item--unit-price {
	color: #6b6c6c;
	font-size: 12.6px;
	line-height: 1.5;
	margin: 4px 0 0;
}

.cart__item--remove {
	color: #6b6c6c;
	display: inline-block;
	font-size: 12px;
	margin-top: 6px;
	text-decoration: underline;
	text-underline-offset: 2px;
}

.cart__item--qty {
	display: flex;
	justify-content: center;
}

.cart__item--price {
	font-size: 14px;
	line-height: 1.6;
}

.cart__item--headers .cart__item--qty,
.cart__item--headers .cart__item--price {
	font-size: 11.9px;
	letter-spacing: 2.38px;
	line-height: 1.2;
	text-transform: uppercase;
}

.cart__footer {
	border-top: 1px solid var(--cluse-border);
	margin-top: 10px;
	padding-top: 30px;
}

.cart__footer-inner {
	margin-left: auto;
	max-width: 445px;
}

.cart__item-sub {
	align-items: baseline;
	display: flex;
	font-size: 14px;
	justify-content: space-between;
	line-height: 1.6;
	padding: 10px 0 0;
}

.cart__subtotal {
	font-family: var(--cluse-font-heading);
	font-size: 14px;
	font-weight: 700;
	letter-spacing: 2.8px;
	line-height: 1.2;
	text-transform: uppercase;
}

.cart__item-row--total {
	border-top: 1px solid var(--cluse-border);
	font-size: 16px;
	font-weight: 500;
	margin-top: 12px;
	padding-top: 12px;
}

.cart__savings {
	color: var(--cluse-sale);
	font-size: 13px;
	padding-top: 8px;
	text-align: right;
}

.ajaxcart__note {
	color: #6b6c6c;
	font-size: 12px;
	line-height: 1.5;
	padding: 12px 0 20px;
	text-align: left;
}

.cart__checkout {
	display: block;
	font-size: 16px;
	letter-spacing: 0.05em;
	padding: 11px 20px;
	text-align: center;
	width: 100%;
}

.cart__continue {
	font-size: 13px;
	margin: 15px 0 0;
	text-align: center;
}

.cart__continue a {
	text-decoration: underline;
	text-underline-offset: 2px;
}

.cart-page__empty {
	padding: 20px 0 60px;
	text-align: center;
}

.cart-page__empty-text {
	font-size: 15px;
	margin-bottom: 25px;
}

/* ------------------------------------------------------------------ *
 * 5. Cart drawer (reference: 450px right panel; 90px thumbnails)
 * ------------------------------------------------------------------ */
.drawer--right {
	right: 0;
	transform: translateX(100%);
	width: 350px;
}

.drawer--right.drawer--is-open {
	transform: translateX(0);
	visibility: visible;
}

.cluse-cart-drawer .drawer__contents {
	height: 100%;
}

.cluse-cart-drawer .drawer__title {
	font-family: var(--cluse-font-heading);
	font-size: 21.35px;
	font-weight: 700;
	line-height: 1.2;
}

.cart-drawer__panel,
.cart-drawer__form {
	display: flex;
	flex-direction: column;
	flex: 1 1 auto;
	min-height: 0;
}

.cart-drawer__form {
	height: 100%;
}

.cluse-cart-drawer .drawer__scrollable {
	flex: 1 1 auto;
	overflow-y: auto;
}

.cart-drawer__empty {
	padding: 30px 0;
	text-align: center;
}

.cart-drawer__empty p {
	font-size: 14px;
	margin-bottom: 20px;
}

.cart-drawer__items {
	display: flex;
	flex-direction: column;
	gap: 25px;
	padding: 25px 0;
}

.cart-drawer__item {
	align-items: start;
	display: flex;
	gap: 20px;
}

.cart-drawer__image {
	flex: 0 0 auto;
	width: 90px;
}

.cart-drawer__image img {
	aspect-ratio: 1 / 1;
	background: var(--cluse-image-bg);
	display: block;
	object-fit: cover;
	width: 90px;
}

.cart-drawer__details {
	flex: 1 1 auto;
	min-width: 0;
}

.cart-drawer__name {
	color: var(--cluse-ink);
	display: block;
	font-size: 14px;
	line-height: 1.6;
	text-decoration: none;
}

.cart-drawer__name:hover {
	text-decoration: underline;
	text-underline-offset: 2px;
}

.cart-drawer__row {
	align-items: center;
	display: flex;
	justify-content: space-between;
	margin-top: 10px;
}

.cart-drawer__price {
	font-size: 14px;
	line-height: 1.6;
}

.cart-drawer__footer {
	border-top: 1px solid var(--cluse-border);
	flex: 0 0 auto;
	padding-bottom: 20px;
	padding-top: 20px;
}

.cart-drawer__subtotal {
	align-items: baseline;
	display: flex;
	justify-content: space-between;
	margin-bottom: 10px;
}

.cart-drawer__subtotal-label {
	font-family: var(--cluse-font-heading);
	font-size: 14px;
	font-weight: 700;
	letter-spacing: 2.8px;
	line-height: 1.2;
	text-transform: uppercase;
}

.cart-drawer__subtotal-value {
	font-size: 14px;
	line-height: 1.6;
}

.cart-drawer__note {
	color: #6b6c6c;
	font-size: 12px;
	line-height: 1.5;
	margin: 0 0 15px;
}

.cart-drawer__checkout {
	display: block;
	font-size: 16px;
	letter-spacing: 0.05em;
	padding: 11px 20px;
	text-align: center;
	width: 100%;
}

.cart-drawer__view-cart {
	display: block;
	font-size: 12px;
	margin-top: 12px;
	text-align: center;
	text-decoration: underline;
	text-underline-offset: 2px;
}

/* ------------------------------------------------------------------ *
 * 6. Responsive
 * ------------------------------------------------------------------ */
@media only screen and (min-width: 590px) {
	.drawer--right {
		width: 450px;
	}
}

@media only screen and (max-width: 589px) {
	.cart__item {
		gap: 15px;
		grid-template-columns: 100px 1fr;
		padding-bottom: 20px;
	}

	.cart__item--headers {
		display: none;
	}

	.cart__item--details {
		gap: 10px;
		grid-template-columns: 1fr auto;
	}

	.cart__item--qty {
		justify-content: flex-start;
		order: 2;
	}

	.cart__item--price {
		order: 1;
		text-align: right;
	}

	.cart__footer-inner {
		max-width: 100%;
	}

	.drawer--right {
		max-width: 92%;
		width: 340px;
	}

	.cart-drawer__image,
	.cart-drawer__image img {
		width: 74px;
	}

	.cluse-cart-page .js-qty__wrapper,
	.cluse-cart-drawer .js-qty__wrapper {
		width: 84px;
	}
}

/* ------------------------------------------------------------------ *
 * 7. Informational "-40 %" discount row (cart page + checkout summary)
 * ------------------------------------------------------------------ */
.cart__item-row.cart__discount {
	color: var(--cluse-green);
	font-size: 13px;
}

.cart__subtotal--discount {
	color: var(--cluse-green);
	font-size: 12px;
	letter-spacing: 0.18em;
}

.cart__discount-value {
	color: var(--cluse-green);
	font-weight: 500;
}

.cart__shipping-free {
	color: var(--cluse-green);
}

.cart__shipping-note {
	color: #6b6c6c;
	font-size: 11.5px;
	margin: -6px 0 0;
	text-align: right;
}

/* Checkout summary discount row (mirrors .cluse-review__row) */
.cluse-review__row--discount-total {
	color: var(--cluse-green);
}

.cluse-review__row--discount-total .cluse-review__value {
	font-weight: 500;
}

[data-cluse-discount-row][hidden] {
	display: none !important;
}

/* ------------------------------------------------------------------ *
 * 8. "Nous acceptons :" card icon row (client spec, cart page totals)
 * ------------------------------------------------------------------ */
.cluse-cart-pay {
	margin-top: 22px;
	text-align: right;
}

.cluse-cart-pay__label {
	color: #6b6c6c;
	font-size: 12.5px;
	margin: 0 0 8px;
}

.cluse-cart-pay__icons {
	align-items: center;
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
	justify-content: flex-end;
}

.cluse-cart-pay__icons img {
	display: block;
	height: 28px;
	max-width: 100%;
	width: auto;
}

@media only screen and (max-width: 589px) {
	.cluse-cart-pay {
		text-align: left;
	}

	.cluse-cart-pay__icons {
		justify-content: flex-start;
	}

}
