/**
 * Celine Claire Wishlist
 * A premium personal product shelf: warm canvas, black editorial type, brand yellow
 * reserved for the saved state and the primary action, thin rules instead of shadows.
 */

.cc-wl {
	--wl-ink: #1B1A17;
	--wl-ink-2: #4A3F38;
	--wl-canvas: #FBF7EF;
	--wl-panel: #FFFFFF;
	--wl-line: rgba(27, 26, 23, 0.10);
	--wl-line-soft: rgba(27, 26, 23, 0.06);
	--wl-yellow: #F5C518;
	--wl-yellow-ink: #1B1A17;
	--wl-oos: #8B4A3A;
	--wl-r: 2px;
	--wl-s1: 6px;
	--wl-s2: 12px;
	--wl-s3: 20px;
	--wl-s4: 32px;
	--wl-s5: 56px;
	--wl-s6: 84px;
	--wl-gap: 56px;

	box-sizing: border-box;
	width: min(1180px, 92vw);
	margin-inline: auto;
	padding-block: var(--wl-s5) var(--wl-s6);
	color: var(--wl-ink);
	display: flex;
	flex-direction: column;
	gap: var(--wl-gap);
}

.cc-wl *,
.cc-wl *::before,
.cc-wl *::after { box-sizing: border-box; }

.cc-wl h1, .cc-wl h2, .cc-wl h3 { color: var(--wl-ink); margin: 0; text-wrap: balance; }
.cc-wl p { margin: 0; color: var(--wl-ink-2); }

/* ------------------------------------------------------------------- hero */

.cc-wl__crumbs {
	font-size: 12px;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--wl-ink-2);
	display: flex;
	gap: var(--wl-s1);
	/* Sits directly above the hero, so cancel the column gap and re-add a small one. */
	margin-bottom: calc(var(--wl-gap) * -1 + var(--wl-s3));
}
.cc-wl__crumbs a { color: inherit; text-decoration: none; }
.cc-wl__crumbs a:hover { text-decoration: underline; }

.cc-wl__hero { display: flex; flex-direction: column; gap: var(--wl-s2); max-width: 60ch; }
.cc-wl__eyebrow {
	font-size: 11px;
	letter-spacing: 0.18em;
	text-transform: uppercase;
	color: var(--wl-ink-2);
}
.cc-wl__title { font-size: clamp(30px, 4.4vw, 52px); line-height: 1.06; font-weight: 400; letter-spacing: -0.01em; }
.cc-wl__lede { font-size: 16px; line-height: 1.65; max-width: 62ch; }
.cc-wl__statelines {
	font-size: 13px;
	line-height: 1.6;
	padding-top: var(--wl-s2);
	border-top: 1px solid var(--wl-line-soft);
	color: var(--wl-ink-2);
}

/* --------------------------------------------------------------- controls */

.cc-wl__controls {
	display: flex;
	flex-wrap: wrap;
	gap: var(--wl-s3);
	align-items: end;
	justify-content: space-between;
	padding-bottom: var(--wl-s2);
	border-bottom: 1px solid var(--wl-line);
}
.cc-wl__count { font-size: 13px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--wl-ink); }
.cc-wl__tools { display: flex; flex-wrap: wrap; gap: var(--wl-s2); align-items: center; }
.cc-wl__sortlabel { font-size: 12px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--wl-ink-2); }
.cc-wl__sort {
	min-height: 44px;
	padding: 0 var(--wl-s3) 0 var(--wl-s2);
	border: 1px solid var(--wl-line);
	border-radius: var(--wl-r);
	background: var(--wl-panel);
	color: var(--wl-ink);
	font: inherit;
	font-size: 14px;
}

/* --------------------------------------------------------------- buttons */

/* The active theme styles bare `button` hard enough to beat a single class here, so
   every control is scoped to the component and the visual properties are marked. */
.cc-wl .cc-wl__btn {
	display: inline-flex !important;
	align-items: center;
	justify-content: center;
	min-height: 44px;
	padding: 0 var(--wl-s3) !important;
	border: 1px solid transparent !important;
	border-radius: var(--wl-r) !important;
	font: inherit;
	font-size: 14px !important;
	line-height: 1.2 !important;
	letter-spacing: 0.02em;
	text-transform: none !important;
	text-decoration: none !important;
	cursor: pointer;
	width: auto;
	transition: background-color 160ms ease-out, color 160ms ease-out, border-color 160ms ease-out, transform 140ms ease-out;
}
.cc-wl .cc-wl__btn--primary {
	background: var(--wl-yellow) !important;
	color: var(--wl-yellow-ink) !important;
	border-color: var(--wl-yellow) !important;
	font-weight: 600 !important;
}
.cc-wl .cc-wl__btn--primary:hover { background: #E7B70C !important; border-color: #E7B70C !important; }
.cc-wl .cc-wl__btn--quiet {
	background: transparent !important;
	color: var(--wl-ink-2) !important;
	border-color: var(--wl-line) !important;
}
.cc-wl .cc-wl__btn--quiet:hover { border-color: var(--wl-ink) !important; color: var(--wl-ink) !important; }
.cc-wl .cc-wl__btn--ghost {
	background: transparent !important;
	color: var(--wl-ink) !important;
	border-color: var(--wl-ink) !important;
}
.cc-wl .cc-wl__btn:active { transform: scale(0.985); }
.cc-wl .cc-wl__btn[disabled], .cc-wl .cc-wl__btn.is-busy { opacity: 0.45; cursor: default; transform: none; }

.cc-wl .cc-wl__link {
	background: none !important;
	border: 0 !important;
	padding: 0 !important;
	font: inherit;
	font-size: 13px !important;
	color: var(--wl-ink) !important;
	text-transform: none !important;
	text-decoration: underline !important;
	text-underline-offset: 3px;
	cursor: pointer;
}

/* The master asks for brand yellow on the focus state, but #F5C518 on this warm
   canvas is about 1.7:1 - below the 3:1 a focus indicator has to meet. So the ring
   itself is ink, and the yellow sits outside it as a halo: brand-correct and legible
   on both the cream page and a product photograph. */
.cc-wl :focus-visible,
button.cc-wl-heart:focus-visible,
.cc-wl-heart:focus-visible,
a.cc-wl-headerlink:focus-visible {
	outline: 2px solid var(--wl-ink, #1B1A17) !important;
	outline-offset: 2px !important;
	box-shadow: 0 0 0 5px rgba(245, 197, 24, 0.55) !important;
	border-radius: 2px;
}

/* ------------------------------------------------------------------ grid */

/* auto-fill, not auto-fit: with one saved item the card keeps its own width and the
   row does not stretch a single product across the whole viewport. */
.cc-wl__grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
	gap: var(--wl-s4) var(--wl-s3);
}
.cc-wl[data-state="empty"] .cc-wl__grid,
.cc-wl[data-state="boot"] .cc-wl__grid,
.cc-wl[data-state="empty"] .cc-wl__controls { display: none; }
.cc-wl[data-state="boot"] .cc-wl__controls { visibility: hidden; }

/* ------------------------------------------------------------------ card */

.cc-wl-card {
	display: flex;
	flex-direction: column;
	gap: var(--wl-s2);
	padding-bottom: var(--wl-s3);
	border-bottom: 1px solid var(--wl-line);
	background: transparent;
}
/* Reserves the real card height before the data arrives, so nothing jumps. */
.cc-wl-card--skeleton { min-height: 430px; border-bottom-color: var(--wl-line-soft); }

.cc-wl-card__media {
	position: relative;
	aspect-ratio: 1 / 1;
	background: var(--wl-canvas);
	border-radius: var(--wl-r);
	overflow: hidden;
}
.cc-wl-card__media a { display: block; width: 100%; height: 100%; }
.cc-wl-card__media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}
.cc-wl-card__alt {
	position: absolute;
	inset: 0;
	opacity: 0;
	transition: opacity 200ms ease-out;
}
.cc-wl-card__media:hover .cc-wl-card__alt,
.cc-wl-card__media:focus-within .cc-wl-card__alt { opacity: 1; }
.cc-wl-card__noimg { display: block; width: 100%; height: 100%; background: var(--wl-canvas); }

.cc-wl-card__body { display: flex; flex-direction: column; gap: var(--wl-s1); }
.cc-wl-card__name { font-size: 17px; line-height: 1.3; font-weight: 500; }
.cc-wl-card__name a { color: inherit; text-decoration: none; }
.cc-wl-card__name a:hover { text-decoration: underline; text-underline-offset: 3px; }
.cc-wl-card__role { font-size: 13px; line-height: 1.55; color: var(--wl-ink-2); }
.cc-wl-card__price { font-size: 15px; color: var(--wl-ink); font-variant-numeric: tabular-nums; }
.cc-wl-card__price del { opacity: 0.5; margin-right: 6px; }
.cc-wl-card__stock { font-size: 12px; letter-spacing: 0.06em; text-transform: uppercase; }
.cc-wl-card__stock[data-stock="out"] { color: var(--wl-oos); }
.cc-wl-card__rating { font-size: 12px; color: var(--wl-ink-2); }
.cc-wl-card__flag { font-size: 12px; line-height: 1.5; color: var(--wl-oos); }
.cc-wl-card__actions { display: flex; flex-wrap: wrap; gap: var(--wl-s2); align-items: center; margin-top: var(--wl-s1); }
.cc-wl .cc-wl-card__remove {
	align-self: start;
	min-height: 44px;
	background: none !important;
	border: 0 !important;
	background: none;
	border: 0;
	padding: 0;
	font: inherit;
	font-size: 12px;
	letter-spacing: 0.04em;
	color: var(--wl-ink-2);
	text-decoration: underline;
	text-underline-offset: 3px;
	cursor: pointer;
}
.cc-wl-card__remove:hover { color: var(--wl-ink); }

.cc-wl-card[data-state="unavailable"] { grid-column: span 1; }
.cc-wl-card__gone {
	display: flex;
	flex-direction: column;
	gap: var(--wl-s2);
	padding: var(--wl-s3);
	border: 1px solid var(--wl-line);
	border-radius: var(--wl-r);
	background: var(--wl-canvas);
}
.cc-wl-card__gone h3 { font-size: 15px; font-weight: 500; line-height: 1.35; }
.cc-wl-card__gone p { font-size: 13px; line-height: 1.55; }
.cc-wl-card__gone .cc-wl__btn { align-self: start; }

/* ----------------------------------------------------------- empty state */

.cc-wl__empty { display: flex; flex-direction: column; gap: var(--wl-s3); }
.cc-wl__empty h2 { font-size: clamp(22px, 2.6vw, 30px); font-weight: 400; }
.cc-wl__empty p { max-width: 58ch; line-height: 1.6; }
.cc-wl__emptyactions { display: flex; flex-wrap: wrap; gap: var(--wl-s3); align-items: center; }
.cc-wl__starters {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
	gap: var(--wl-s3);
	margin-top: var(--wl-s2);
	padding-top: var(--wl-s4);
	border-top: 1px solid var(--wl-line);
}
.cc-wl-start { display: flex; flex-direction: column; gap: var(--wl-s1); position: relative; }
.cc-wl-start__media { aspect-ratio: 1 / 1; background: var(--wl-canvas); border-radius: var(--wl-r); overflow: hidden; display: block; }
.cc-wl-start__media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.cc-wl-start__name { font-size: 15px; font-weight: 500; line-height: 1.3; margin-top: var(--wl-s1); }
.cc-wl-start__name a { color: inherit; text-decoration: none; }
.cc-wl-start__role { font-size: 12px; line-height: 1.5; }
.cc-wl-start__price { font-size: 14px; font-variant-numeric: tabular-nums; }

/* --------------------------------------------------- notice / bridge / cta */

.cc-wl__notice,
.cc-wl__bridge,
.cc-wl__final {
	display: flex;
	flex-direction: column;
	gap: var(--wl-s2);
	padding: var(--wl-s4);
	border: 1px solid var(--wl-line);
	border-radius: var(--wl-r);
	background: var(--wl-canvas);
}
.cc-wl__notice h2, .cc-wl__bridge h2, .cc-wl__final h2 { font-size: 20px; font-weight: 500; }
.cc-wl__notice p, .cc-wl__bridge p, .cc-wl__final p { font-size: 14px; line-height: 1.65; max-width: 62ch; }
.cc-wl__bridgeactions, .cc-wl__finalactions {
	display: flex;
	flex-wrap: wrap;
	gap: var(--wl-s2) var(--wl-s3);
	align-items: center;
	margin-top: var(--wl-s1);
}
.cc-wl__fine { font-size: 12px; color: var(--wl-ink-2); }
.cc-wl__bridge.is-required { border-color: var(--wl-oos); }

/* ---------------------------------------------------------- compare / faq */

.cc-wl__compare, .cc-wl__faq { display: flex; flex-direction: column; gap: var(--wl-s3); }
.cc-wl__compare h2, .cc-wl__faq h2 { font-size: clamp(21px, 2.4vw, 28px); font-weight: 400; }
.cc-wl__comparegrid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 1px; background: var(--wl-line); border: 1px solid var(--wl-line); }
.cc-wl-cmp { background: var(--wl-panel); padding: var(--wl-s3); display: flex; flex-direction: column; gap: var(--wl-s1); }
.cc-wl-cmp h3 { font-size: 15px; font-weight: 600; line-height: 1.35; }
.cc-wl-cmp p { font-size: 13px; line-height: 1.6; }
.cc-wl-cmp__links { display: flex; flex-wrap: wrap; gap: var(--wl-s1) var(--wl-s2); align-items: baseline; margin-top: auto; padding-top: var(--wl-s2); }
.cc-wl-cmp__label { font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--wl-ink-2); }
.cc-wl-cmp__links a { font-size: 13px; color: var(--wl-ink); text-underline-offset: 3px; }

.cc-wl__faqlist { border-top: 1px solid var(--wl-line); }
.cc-wl-q { border-bottom: 1px solid var(--wl-line); }
.cc-wl-q summary {
	list-style: none;
	cursor: pointer;
	padding: var(--wl-s3) var(--wl-s4) var(--wl-s3) 0;
	font-size: 15px;
	font-weight: 500;
	position: relative;
	min-height: 44px;
	display: flex;
	align-items: center;
}
.cc-wl-q summary::-webkit-details-marker { display: none; }
.cc-wl-q summary::after {
	content: "+";
	position: absolute;
	right: var(--wl-s1);
	font-size: 18px;
	color: var(--wl-ink-2);
}
.cc-wl-q[open] summary::after { content: "\2212"; }
.cc-wl-q p { padding: 0 var(--wl-s4) var(--wl-s3) 0; font-size: 14px; line-height: 1.7; max-width: 68ch; }

/* ------------------------------------------------------- toast and sticky */

.cc-wl__live {
	position: absolute;
	width: 1px;
	height: 1px;
	overflow: hidden;
	clip-path: inset(50%);
	white-space: nowrap;
}
.cc-wl__toast {
	position: fixed;
	left: 50%;
	bottom: 24px;
	transform: translateX(-50%);
	z-index: 9998;
	max-width: min(420px, 92vw);
}
.cc-wl-toast__inner {
	position: relative;
	background: var(--wl-ink);
	color: #FBF7EF;
	padding: var(--wl-s3) var(--wl-s5) var(--wl-s3) var(--wl-s3);
	border-radius: var(--wl-r);
	display: flex;
	flex-direction: column;
	gap: var(--wl-s1);
}
.cc-wl-toast__t { color: #FBF7EF; font-size: 14px; font-weight: 600; }
.cc-wl-toast__b { color: rgba(251, 247, 239, 0.82); font-size: 13px; line-height: 1.5; }
.cc-wl-toast__a { display: flex; gap: var(--wl-s3); flex-wrap: wrap; align-items: center; }
/* Undo has to be reachable with a thumb, not just a mouse. */
.cc-wl .cc-wl-toast__a .cc-wl__link { min-height: 44px; display: inline-flex; align-items: center; }
.cc-wl .cc-wl-toast__a .cc-wl__link { color: var(--wl-yellow) !important; }
.cc-wl-toast__x {
	position: absolute;
	top: 6px;
	right: 6px;
	min-width: 44px;
	min-height: 44px;
	background: none;
	border: 0;
	color: rgba(251, 247, 239, 0.7);
	font-size: 20px;
	cursor: pointer;
}

.cc-wl__sticky { display: none; }

/* --------------------------------------------------------- heart control */

button.cc-wl-heart,
.cc-wl-heart {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	min-width: 44px;
	min-height: 44px;
	padding: 0 10px;
	background: rgba(255, 255, 255, 0.94);
	border: 1px solid rgba(27, 26, 23, 0.20);
	border-radius: 999px;
	color: #1B1A17;
	font: inherit;
	font-size: 12px;
	letter-spacing: 0.04em;
	text-transform: none;
	cursor: pointer;
	transition: color 160ms ease-out, border-color 160ms ease-out, transform 160ms ease-out;
}
.cc-wl-heart__icon { transition: transform 160ms ease-out, fill 160ms ease-out; }
.cc-wl-heart[aria-pressed="true"] { border-color: #F5C518; color: #1B1A17; }
.cc-wl-heart[aria-pressed="true"] .cc-wl-heart__icon { fill: #F5C518; stroke: #C9A00E; }
.cc-wl-heart:active { transform: scale(0.96); }
.cc-wl-heart.is-pulsing .cc-wl-heart__icon { transform: scale(1.18); }

/* On a product card the heart floats over the image corner; on the product page and
   the empty-state shelf it sits inline with the other controls. */
.cc-wl-heart--card {
	position: absolute;
	top: 10px;
	right: 10px;
	z-index: 3;
}
.cc-wl-heart--card .cc-wl-heart__text,
.cc-wl-heart--start .cc-wl-heart__text {
	position: absolute;
	width: 1px;
	height: 1px;
	overflow: hidden;
	clip-path: inset(50%);
	white-space: nowrap;
}
.cc-wl-heart--start { position: absolute; top: 8px; right: 8px; z-index: 3; }
.cc-wl-heart--single { margin-top: 12px; }

.woocommerce ul.products li.product { position: relative; }

/* --------------------------------------------------------- header utility */

.cc-wl-headerlink { position: relative; }
.cc-wl-headerlink__count {
	position: absolute;
	top: -2px;
	right: -4px;
	min-width: 16px;
	height: 16px;
	padding: 0 4px;
	border-radius: 999px;
	background: #F5C518;
	color: #1B1A17;
	font-size: 10px;
	line-height: 16px;
	text-align: center;
	font-variant-numeric: tabular-nums;
}

/* -------------------------------------------------------------- responsive */

@media (max-width: 900px) {
	.cc-wl { --wl-gap: 32px; padding-block: var(--wl-s4) var(--wl-s5); }
	.cc-wl__controls { align-items: start; flex-direction: column; gap: var(--wl-s2); }
	.cc-wl__notice, .cc-wl__bridge, .cc-wl__final { padding: var(--wl-s3); }
}

@media (max-width: 640px) {
	/* One product per row, and the image, name, price, stock and primary action stay
	   together in the same block. */
	.cc-wl__grid { grid-template-columns: 1fr; gap: var(--wl-s4); }
	.cc-wl-card--skeleton { min-height: 380px; }
	.cc-wl__starters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.cc-wl__comparegrid { grid-template-columns: 1fr; }
	.cc-wl-card__actions .cc-wl__btn { flex: 1 1 auto; }

	/* Compact sticky bar, only rendered when two or more items are eligible. It sits
	   above the safe-area inset so it never covers system navigation. */
	.cc-wl__sticky:not([hidden]) {
		display: block;
		position: sticky;
		bottom: calc(env(safe-area-inset-bottom, 0px) + 8px);
		z-index: 40;
		padding: 8px;
		background: rgba(251, 247, 239, 0.94);
		backdrop-filter: blur(6px);
		border: 1px solid var(--wl-line);
		border-radius: var(--wl-r);
	}
	.cc-wl__sticky .cc-wl__btn { width: 100%; }
	.cc-wl__toast { bottom: calc(env(safe-area-inset-bottom, 0px) + 76px); }
}

@media (prefers-reduced-motion: reduce) {
	.cc-wl *,
	.cc-wl-heart,
	.cc-wl-heart__icon { transition-duration: 1ms !important; animation-duration: 1ms !important; }
	.cc-wl-heart.is-pulsing .cc-wl-heart__icon { transform: none; }
	.cc-wl-card__alt { transition: none; }
}
