/* ==========================================================================
   Laurenza — cart.css
   Cart drawer (frames 16–19), shared product lines / coupon / recap blocks,
   cart page (/panier/).
   ========================================================================== */

:root {
	--lz-line: #e0e0e1;          /* separators in drawer / summary */
	--lz-cd-w: 454px;            /* drawer width at 1440 (986 → 1440) */
	--lz-cd-pl: 22px;            /* drawer content x = 1008 */
	--lz-cd-pr: 48px;            /* drawer content right = 1392 */
}

/* ---------- Drawer shell ---------- */
.lz-cd { position: fixed; inset: 0; z-index: 1000; pointer-events: none; visibility: hidden; transition: visibility 0s linear .35s; }
.lz-cd.is-open { pointer-events: auto; visibility: visible; transition: none; }
.lz-cd__overlay { position: absolute; inset: 0; background: rgba(0, 0, 0, .3); opacity: 0; transition: opacity .3s var(--lz-ease); }
.lz-cd.is-open .lz-cd__overlay { opacity: 1; }
.lz-cd__panel {
	position: absolute; top: 0; right: 0; bottom: 0;
	width: var(--lz-cd-w); max-width: 100%;
	background: #fff; color: var(--lz-black);
	transform: translateX(100%); transition: transform .35s var(--lz-ease);
	outline: none;
	display: flex; flex-direction: column;
}
.lz-cd.is-open .lz-cd__panel { transform: none; }
.lz-cd.no-anim .lz-cd__panel, .lz-cd.no-anim .lz-cd__overlay { transition: none; }

.lz-cd__inner { position: relative; flex: 1; min-height: 0; display: flex; flex-direction: column; }
.lz-cd.is-busy .lz-cd__inner { cursor: progress; }
.lz-cd.is-busy .lz-cd__body, .lz-cd.is-busy .lz-recap, .lz-cd.is-busy .lz-cd__buy { opacity: .55; transition: opacity .15s; }

/* Banner "Livraison OFFERTE dans X TND !" / "Votre livraison est 100% gratuite" */
.lz-cd__banner {
	flex: none; height: 40px; display: flex; align-items: center; justify-content: center; gap: 7px;
	padding: 0 16px; background: var(--lz-coral); color: #fff;
	font-size: 16px; line-height: 24px; font-weight: 400; white-space: nowrap;
}
.lz-cd__banner.is-free { background: var(--lz-cyan); }
.lz-cd__banner .lz-icon { flex: none; }
.lz-cd__banner > span { position: relative; top: 1px; letter-spacing: .012em; }
.lz-cd.is-samples .lz-cd__banner { visibility: hidden; }

/* Views */
.lz-cd__view { flex: 1; min-height: 0; display: flex; flex-direction: column; }
.lz-cd__view--samples { display: none; }
.lz-cd.is-samples .lz-cd__view--cart { display: none; }
.lz-cd.is-samples .lz-cd__view--samples { display: flex; }

/* Head "‹ Mon panier ……… 3 [bag]" */
.lz-cd__head {
	flex: none; height: 76px; display: flex; align-items: center; gap: 11px;
	padding: 12px var(--lz-cd-pr) 0 var(--lz-cd-pl);
	border-bottom: 1px solid var(--lz-black);
}
.lz-cd__back, .lz-cd__close { flex: none; width: 24px; height: 24px; display: inline-flex; align-items: center; justify-content: center; color: var(--lz-black); }
.lz-cd__back { margin-top: 1px; }
.lz-cd__title { flex: 1; min-width: 0; margin: 0; font-size: 24px; line-height: 36px; font-weight: 500; letter-spacing: -0.02em; padding-top: 2px; }
.lz-cd__count { display: inline-flex; align-items: center; gap: 11px; font-size: 14px; line-height: 21px; padding-top: 4px; }
.lz-cd__bag { position: relative; display: block; width: 24px; height: 24px; margin-top: -4px; }
.lz-cd__bag .lz-icon { display: block; }
.lz-cd__dot { position: absolute; top: -3px; right: -3px; width: 8px; height: 8px; border-radius: 50%; background: var(--lz-coral); }

/* Body (scroll area) */
.lz-cd__body {
	flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain;
	padding: 32px var(--lz-cd-pr) 16px var(--lz-cd-pl);
	transition: opacity .15s;
}
.lz-cd__foot { flex: none; padding: 0 var(--lz-cd-pr) 50px var(--lz-cd-pl); background: #fff; }

/* Empty state */
.lz-cd__body--empty { display: flex; align-items: center; justify-content: center; }
.lz-cd__empty { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 12px; padding: 40px 0; }
.lz-cd__empty-icon { display: inline-flex; width: 72px; height: 72px; border-radius: 50%; align-items: center; justify-content: center; background: var(--lz-grey-bg); }
.lz-cd__empty-title { margin: 8px 0 0; font-size: 20px; line-height: 30px; font-weight: 500; }
.lz-cd__empty-text { color: var(--lz-grey); font-size: 14px; line-height: 21px; margin-bottom: 12px; }

/* ---------- Product lines (drawer, checkout summary, thank-you, cart page) ---------- */
.lz-lines { list-style: none; margin: 0; padding: 0; }
.lz-line { position: relative; padding: 20px 0 22px; border-bottom: 1px solid var(--lz-line); transition: opacity .2s; }
.lz-lines > .lz-line:first-child { padding-top: 20px; }
.lz-line.is-removing { opacity: .35; pointer-events: none; }
.lz-line__top { display: grid; grid-template-columns: 80px 1fr; column-gap: 14px; align-items: start; }
.lz-line__img { display: block; width: 80px; height: 80px; border-radius: var(--lz-r-sm); background: var(--lz-product-bg); overflow: hidden; }
.lz-line__img img { width: 100%; height: 100%; object-fit: cover; }
.lz-line__text { padding: 5px 40px 0 0; min-width: 0; }
.lz-line__title { margin: 0; font-size: 14px; line-height: 21px; font-weight: 500; }
.lz-line__desc { max-width: 196px; margin: 10px 0 0; font-size: 14px; line-height: 20px; font-weight: 300; color: #000; }
.lz-line__remove {
	position: absolute; top: 20px; right: 0; width: 24px; height: 24px;
	display: inline-flex; align-items: center; justify-content: center; color: var(--lz-grey);
	border-radius: var(--lz-r-xs);
}
.lz-line__remove:hover { color: var(--lz-black); }
.lz-line__bottom { display: grid; grid-template-columns: 94px auto 1fr; align-items: center; min-height: 34px; margin-top: 16px; }
.lz-line__vol { font-size: 14px; line-height: 21px; font-weight: 300; padding-left: 1px; }
.lz-line__price { justify-self: end; font-size: 14px; line-height: 21px; font-weight: 500; white-space: nowrap; }
.lz-line__price--free { font-weight: 500; letter-spacing: .01em; }
.lz-line__qtytext { font-size: 16px; line-height: 24px; font-weight: 500; }

/* Quantity stepper */
.lz-stepper {
	display: inline-flex; align-items: center; height: 34px; padding: 0 11px;
	border: 1px solid var(--lz-border); border-radius: var(--lz-r-sm);
	box-shadow: 0 1px 2px rgba(0, 0, 0, .06); background: #fff;
}
.lz-stepper__btn { width: 24px; height: 24px; display: inline-flex; align-items: center; justify-content: center; color: #67676d; }
.lz-stepper__btn:hover { color: var(--lz-black); }
.lz-stepper__btn[disabled] { opacity: .35; cursor: default; }
.lz-stepper__btn .lz-icon { width: 24px; height: 24px; stroke-width: 2; }
.lz-stepper__val { min-width: 27px; text-align: center; font-size: 16px; line-height: 24px; font-weight: 500; }

/* ---------- Coupon ---------- */
.lz-coupon { display: flex; flex-wrap: wrap; gap: 0 15px; margin: 0; }
.lz-coupon__field {
	flex: 1 1 0; min-width: 0; height: 48px;
	display: flex; align-items: center; justify-content: center; gap: 10px;
	padding: 0 12px; border: 1px solid var(--lz-border); border-radius: var(--lz-r-sm);
	box-shadow: 0 1px 2px rgba(0, 0, 0, .05); background: #fff; color: var(--lz-black); cursor: text;
}
.lz-coupon__field .lz-icon { flex: none; stroke-width: 2; }
.lz .lz-coupon .lz-coupon__input, .lz-coupon__input {
	min-width: 0; width: 7.2em; max-width: 100%; min-height: 0; height: 24px;
	border: 0; border-radius: 0; outline: 0; padding: 0; background: transparent; box-shadow: none;
	font-size: 16px; line-height: 24px; color: var(--lz-black); text-transform: uppercase;
}
/* Size the input to its text so icon + code sit centred in the field (frames 16, 17, 20). */
@supports (field-sizing: content) {
	.lz .lz-coupon .lz-coupon__input, .lz-coupon__input { field-sizing: content; width: auto; min-width: 2ch; }
}
.lz-coupon__input::placeholder { color: var(--lz-grey); opacity: 1; }
.lz-coupon__field:focus-within { border-color: #cfcfcf; }
.lz .lz-coupon.is-applied .lz-coupon__field, .lz .lz-coupon.is-applied .lz-coupon__input { color: var(--lz-green); cursor: default; }
.lz-coupon__btn { flex: none; width: 139px; min-height: 48px; padding: 0 12px; font-weight: 400; }
.lz-coupon.is-loading .lz-coupon__btn { opacity: .6; pointer-events: none; }
.lz-coupon__msg { flex-basis: 100%; margin: 0; font-size: 12px; line-height: 18px; color: var(--lz-grey); }
.lz-coupon__msg:empty { display: none; }
.lz-coupon__msg.is-error { margin-top: 8px; color: var(--lz-coral); }
.lz-coupon--readonly .lz-coupon__field { flex-basis: 100%; }
.lz-coupon__code { font-size: 16px; line-height: 24px; }

/* ---------- Recap toggle + rows ---------- */
.lz-cd__recap-toggle {
	display: flex; width: 100%; align-items: center; justify-content: space-between;
	padding: 23px 0 17px; border-bottom: 1px solid var(--lz-line);
	font-size: 16px; line-height: 24px; font-weight: 300; text-align: left; color: var(--lz-black);
}
.lz-cd__recap-toggle .lz-icon { color: var(--lz-grey); transition: transform .2s; margin-right: 4px; }
.lz-cd.is-recap-open .lz-cd__recap-toggle .lz-icon { transform: rotate(180deg); }
.lz-cd__recap { display: none; padding: 18px 0 3px; }
.lz-cd .lz-coupon.is-applied { margin-bottom: 4px; }
.lz-cd.is-recap-open .lz-cd__recap { display: block; }
.lz-cd__buy { margin-top: 22px; font-weight: 400; }
.lz-cd__buy .lz-sep, .lz-cartpage .lz-sep { margin: 0; font-weight: 400; }

.lz-recap { margin: 0; font-size: 14px; line-height: 21px; font-weight: 300; }
.lz-recap__row { display: flex; align-items: center; justify-content: space-between; gap: 12px; height: 36px; }
.lz-recap dt, .lz-recap dd { margin: 0; }
.lz-recap dd { text-align: right; white-space: nowrap; }
.lz-recap__row--total { font-weight: 600; text-transform: uppercase; }
.lz-recap--drawer .lz-recap__row--discount { color: var(--lz-green); }
.lz-recap--drawer .lz-recap__row--discount dd { font-weight: 600; }

/* ---------- Samples view (frames 18–19) ---------- */
.lz-cd__view--samples .lz-cd__body { padding-top: 25px; }
.lz-samples__intro { margin: 0; padding-bottom: 22px; border-bottom: 1px solid var(--lz-line); font-size: 14px; line-height: 21px; font-weight: 300; color: #000; }
.lz-samples__intro strong { font-weight: 600; }
.lz-samples__intro[data-error]::after { content: attr(data-error); display: block; margin-top: 6px; color: var(--lz-coral); font-size: 12px; }
.lz-samples { display: grid; grid-template-columns: repeat(2, minmax(0, 176px)); justify-content: space-between; gap: 32px; margin: 35px 0 0; padding: 0; list-style: none; }
.lz-sample { text-align: center; transition: opacity .2s; }
.lz-sample.is-disabled { opacity: .3; }
.lz-sample__title { margin: -1px 0 0; font-size: 14px; line-height: 21px; font-weight: 500; }
.lz-sample__name, .lz-sample__vol { margin: 0; font-size: 14px; line-height: 20px; font-weight: 300; }
.lz-sample__name { margin-top: 3px; }
.lz-sample__vol { line-height: 21px; }
.lz-sample__img { margin-top: 2px; aspect-ratio: 1; border-radius: var(--lz-r-sm); background: var(--lz-product-bg); overflow: hidden; }
.lz-sample__img img { width: 100%; height: 100%; object-fit: cover; }
.lz-sample__btn { width: 100%; margin-top: 15px; gap: 10px; font-weight: 400; padding-top: 2px; }
.lz-sample__btn .lz-icon { stroke-width: 2; }
.lz-sample__btn--remove { background: #fff; color: var(--lz-grey); border-color: var(--lz-grey); font-weight: 400; }
.lz-sample__btn--remove:hover { color: var(--lz-black); border-color: var(--lz-black); }
.lz-sample.is-disabled .lz-sample__btn[disabled] { opacity: 1; }
/* Mockup draws drawer button edges at x=1009 (content edge 1008.5): shave 1px off the left. */
.lz-cd .lz-cd__buy, .lz-cd .lz-sample__btn { margin-left: 1px; width: calc(100% - 1px); }

/* ---------- Cart page (/panier/) ---------- */
.lz-cartpage { padding: 24px 0 80px; }
.lz-cartpage__title { margin: 0 0 24px; font-size: 40px; line-height: 60px; font-weight: 500; letter-spacing: -0.02em; }
.lz-cartpage__title span { color: var(--lz-grey); font-weight: 400; }
.lz-cartpage__grid { display: grid; grid-template-columns: minmax(0, 1fr) 384px; gap: 64px; align-items: start; }
.lz-cartpage__lines { border-top: 1px solid var(--lz-line); }
.lz-cartpage__side { position: sticky; top: 24px; }
.lz-cartpage__side .lz-recap { margin: 20px 0 22px; }
.lz-cartpage.is-busy { opacity: .6; pointer-events: none; }
.lz-cartpage__empty { padding: 60px 0 100px; }

/* ---------- Responsive ---------- */
@media (max-width: 1023px) {
	.lz-cartpage__grid { grid-template-columns: 1fr; gap: 32px; }
	.lz-cartpage__side { position: static; }
}
@media (max-width: 600px) {
	:root { --lz-cd-pl: 16px; --lz-cd-pr: 16px; }
	.lz-cd__panel { width: 100%; }
	.lz-cd__banner { font-size: 14px; }
	.lz-cd__title { font-size: 22px; }
	.lz-cd__foot { padding-bottom: 24px; }
	.lz-coupon__btn { width: 116px; }
	.lz-samples { gap: 16px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.lz-cartpage__title { font-size: 28px; line-height: 40px; }
}
@media (prefers-reduced-motion: reduce) {
	.lz-cd__panel, .lz-cd__overlay { transition: none; }
}
@media print {
	.lz-cd { display: none !important; }
}
