/**
 * Global tokens, reset, and shared utilities.
 *
 * Naming:
 * - Colors: --lbs-color-palette-* (canonical swatches), then semantic aliases and legacy names.
 * - Type: --lbs-type-{role}-{property} (roles match design: display-xl … body-* … action-label).
 *
 * @package Love_Beauty_Skin
 */

:root {
	/* -------------------------------------------------------------------------
	   Palette (canonical — use these in new CSS)
	   ------------------------------------------------------------------------- */
	--lbs-color-palette-pink-lb: #f4e3e2;
	--lbs-color-palette-pink-dark: #d9a9a9;
	--lbs-color-palette-pink-light: #f6dcdc;
	--lbs-color-palette-beige: #f6eeea;
	--lbs-color-palette-neutral: #636363;

	/* Semantic color (preferred for components) */
	--lbs-color-accent: var(--lbs-color-palette-pink-dark);
	--lbs-color-surface-brand: var(--lbs-color-palette-pink-lb);
	--lbs-color-surface-muted: var(--lbs-color-palette-beige);
	--lbs-color-surface-tint: var(--lbs-color-palette-pink-light);
	--lbs-color-text-primary: #1a1a1a;
	--lbs-color-text-secondary: var(--lbs-color-palette-neutral);
	--lbs-color-surface-page: #ffffff;
	--lbs-color-border-subtle: #dab2b2;

	/* Legacy / section-specific aliases (existing components rely on these) */
	--lbs-color-bg-header: var(--lbs-color-surface-page);
	--lbs-color-nav: var(--lbs-color-text-secondary);
	--lbs-color-accent-pink: var(--lbs-color-accent);
	--lbs-color-light-beige: var(--lbs-color-surface-muted);
	--lbs-color-footer-bg: var(--lbs-color-surface-brand);
	--lbs-color-checkout-border: var(--lbs-color-border-subtle);
	--lbs-color-text: var(--lbs-color-text-primary);

	/*
	 * H1 / H2 “lighter” on light backgrounds: Typekit ivymode in this project only serves ~400/700
	 * (see use.typekit.net uai4dpg). font-weight:100–300 all map to the same Regular file, so the
	 * *visual* light look is from softer ink (not body black) + a touch of tracking. Override per
	 * block (e.g. white on hero) with `color: inherit` or a local variable.
	 */
	--lbs-color-text-display-ink: color-mix(
		in srgb,
		var(--lbs-color-text-primary) 52%,
		#ffffff 48%
	);

	/* -------------------------------------------------------------------------
	   Typography — font stacks
	   ------------------------------------------------------------------------- */
	   --lbs-font-body: "Aileron", "Work Sans", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
	/* Ivy Mode: family name from Typekit is "ivymode" (not "ivy-mode") or the web font never matches */
	--lbs-font-display: "ivymode", "Cormorant Garamond", Georgia, "Times New Roman", serif;

	/* -------------------------------------------------------------------------
	   Typography — roles (Figma: H1, H2, H3, H6, Body 1–3, CTA)
	   Properties: -font-family, -font-size, -font-weight, -line-height, -letter-spacing
	   ------------------------------------------------------------------------- */
	/* H1 — Ivy; 400 = regular file actually loaded in kit (n4) — + ink + tracking for “light” look */
	--lbs-type-display-xl-font-family: var(--lbs-font-display);
	--lbs-type-display-xl-font-size: 5.625rem; /* 90px */
	--lbs-type-display-xl-font-weight: 400;
	--lbs-type-display-xl-line-height: 1.1;
	--lbs-type-display-xl-letter-spacing: 0.02em;
	--lbs-type-display-xl-color: var(--lbs-color-text-display-ink);

	/* H2 */
	--lbs-type-display-lg-font-family: var(--lbs-font-display);
	--lbs-type-display-lg-font-size: 3.5rem; /* 56px */
	--lbs-type-display-lg-font-weight: 400;
	--lbs-type-display-lg-line-height: 1.2;
	--lbs-type-display-lg-letter-spacing: 0.012em;
	--lbs-type-display-lg-color: var(--lbs-color-text-display-ink);

	/* H3 — Ivy Mode Regular 40 / 4% / 120% */
	--lbs-type-display-md-font-family: var(--lbs-font-display);
	--lbs-type-display-md-font-size: 2.5rem; /* 40px */
	--lbs-type-display-md-font-weight: 400;
	--lbs-type-display-md-line-height: 1.2;
	--lbs-type-display-md-letter-spacing: 0.04em;

	/* H4 / H5 — not in handoff; bridge between H3 and H6 until Figma confirms */
	--lbs-type-display-sm-font-family: var(--lbs-font-display);
	--lbs-type-display-sm-font-size: 2.125rem; /* 34px */
	--lbs-type-display-sm-font-weight: 400;
	--lbs-type-display-sm-line-height: 1.2;
	--lbs-type-display-sm-letter-spacing: 0.02em;

	--lbs-type-heading-md-font-family: var(--lbs-font-display);
	--lbs-type-heading-md-font-size: 1.9375rem; /* 31px */
	--lbs-type-heading-md-font-weight: 300;
	--lbs-type-heading-md-line-height: 1.2;
	--lbs-type-heading-md-letter-spacing: 0;

	/* H6 — Aileron Light 28 / 0% / 110% */
	--lbs-type-heading-sm-font-family: var(--lbs-font-body);
	--lbs-type-heading-sm-font-size: 1.75rem; /* 28px */
	--lbs-type-heading-sm-font-weight: 300;
	--lbs-type-heading-sm-line-height: 1.1;
	--lbs-type-heading-sm-letter-spacing: 0;

	/* Body 1 — Aileron Light 20 / 0% / 140% */
	--lbs-type-body-lg-font-family: var(--lbs-font-body);
	--lbs-type-body-lg-font-size: 1.25rem; /* 20px */
	--lbs-type-body-lg-font-weight: 300;
	--lbs-type-body-lg-line-height: 1.4;
	--lbs-type-body-lg-letter-spacing: 0;

	/* Body 2 — Aileron Bold 22 / 0% / 140% */
	--lbs-type-body-md-font-family: var(--lbs-font-body);
	--lbs-type-body-md-font-size: 1.375rem; /* 22px */
	--lbs-type-body-md-font-weight: 700;
	--lbs-type-body-md-line-height: 1.4;
	--lbs-type-body-md-letter-spacing: 0;

	/* Body 3 — Aileron Light 16 / 0% / 140% */
	--lbs-type-body-sm-font-family: var(--lbs-font-body);
	--lbs-type-body-sm-font-size: 1rem; /* 16px */
	--lbs-type-body-sm-font-weight: 300;
	--lbs-type-body-sm-line-height: 1.4;
	--lbs-type-body-sm-letter-spacing: 0;

	/* CTA / button label — Aileron Light 14 / 0% / 140% */
	--lbs-type-action-label-font-family: var(--lbs-font-body);
	--lbs-type-action-label-font-size: 1rem; /* 14px */
	--lbs-type-action-label-font-weight: 300;
	--lbs-type-action-label-line-height: 1.4;
	--lbs-type-action-label-letter-spacing: 0;

	/* Legacy body token = Body 1 */
	--lbs-font-size-body: var(--lbs-type-body-lg-font-size);

	--lbs-font-weight-nav: 300;

	--lbs-header-min-height: 7.25rem;
	--lbs-container-max: 90rem;
	--lbs-space-header-x: clamp(1rem, 4vw, 5.75rem);
	--lbs-nav-gap-left: 1.375rem;
	--lbs-nav-gap-right: 1.25rem;
	--lbs-transition: 0.2s ease;

	/* Drawer navigation — matches primary desktop nav typography (Body 3 + nav weight); same tokens at every breakpoint inside the drawer. */
	--lbs-drawer-nav-font-family: var(--lbs-type-body-sm-font-family);
	--lbs-drawer-nav-font-size: var(--lbs-type-body-sm-font-size);
	--lbs-drawer-nav-font-weight: var(--lbs-font-weight-nav);
	--lbs-drawer-nav-line-height: var(--lbs-type-body-sm-line-height);
	--lbs-drawer-nav-letter-spacing: var(--lbs-type-body-sm-letter-spacing);

	/* CTA chrome — size/line-height follow action-label type scale */
	--lbs-cta-btn-min-height: 3.25rem;
	--lbs-cta-btn-padding-y: 1.25rem;
	--lbs-cta-btn-padding-x: 2rem;
	--lbs-cta-btn-gap: 1.25rem;
	--lbs-cta-btn-max-width: 17.625rem;
	--lbs-cta-btn-font-family: var(--lbs-type-action-label-font-family);
	--lbs-cta-btn-font-size: var(--lbs-type-action-label-font-size);
	--lbs-cta-btn-font-weight: var(--lbs-type-action-label-font-weight);
	--lbs-cta-btn-line-height: var(--lbs-type-action-label-line-height);

	/* Shop page layout — Figma 340:2763 */
	--lbs-shop-banner-min-height: 9.25rem; /* 148px */
	--lbs-shop-banner-pad-y: 1.9375rem; /* 31px */
	--lbs-shop-sidebar-col: 18rem; /* 288px — slightly narrower than Figma 324px */
	--lbs-shop-sidebar-pad-top: 5.3125rem; /* 85px */
	--lbs-shop-sidebar-inner-max: 13rem; /* 208px — keeps text block proportional */
	--lbs-shop-sidebar-title-gap: 3.4375rem; /* 55px below “Categories” */
	--lbs-shop-sidebar-section-gap: 1.875rem; /* 30px between accordion rows */
	--lbs-shop-main-pad-top: 5.125rem; /* ~82px — align grid with sidebar block */
	--lbs-shop-grid-col-gap: 2.5rem; /* 40px */
	--lbs-shop-grid-row-gap: 1.9375rem; /* 31px */
	--lbs-shop-card-width: 19.0625rem; /* 305px */
	--lbs-shop-card-image-h: 20rem; /* 320px */
}

@media (max-width: 62rem) {
	:root {
		--lbs-type-display-xl-font-size: clamp(2.75rem, 10vw, 5.625rem);
		--lbs-type-display-lg-font-size: clamp(2rem, 6vw, 3.5rem);
		--lbs-type-display-md-font-size: clamp(1.75rem, 5vw, 2.5rem);
		--lbs-type-display-sm-font-size: clamp(1.5rem, 4vw, 2.125rem);
		--lbs-type-heading-md-font-size: clamp(1.375rem, 3.5vw, 1.9375rem);
		--lbs-type-heading-sm-font-size: clamp(1.25rem, 3vw, 1.75rem);
	}
}

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

html {
	-webkit-text-size-adjust: 100%;
}

body {
	margin: 0;
	/* Figma default body: Aileron (not Work Sans) — was inheriting to nav and unstyled nodes */
	font-family: var(--lbs-type-body-lg-font-family);
	font-size: var(--lbs-type-body-lg-font-size);
	font-weight: var(--lbs-type-body-lg-font-weight);
	line-height: var(--lbs-type-body-lg-line-height);
	letter-spacing: var(--lbs-type-body-lg-letter-spacing);
	color: var(--lbs-color-text-primary);
	background-color: var(--lbs-color-surface-page);
}

h1,
.h1 {
	font-family: var(--lbs-type-display-xl-font-family);
	font-size: var(--lbs-type-display-xl-font-size);
	font-weight: var(--lbs-type-display-xl-font-weight);
	line-height: var(--lbs-type-display-xl-line-height);
	letter-spacing: var(--lbs-type-display-xl-letter-spacing);
	color: var(--lbs-type-display-xl-color);
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
}

h2,
.h2 {
	font-family: var(--lbs-type-display-lg-font-family);
	font-size: var(--lbs-type-display-lg-font-size);
	font-weight: var(--lbs-type-display-lg-font-weight);
	line-height: var(--lbs-type-display-lg-line-height);
	letter-spacing: var(--lbs-type-display-lg-letter-spacing);
	color: var(--lbs-type-display-lg-color);
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
}

h3,
.h3 {
	font-family: var(--lbs-type-display-md-font-family);
	font-size: var(--lbs-type-display-md-font-size);
	font-weight: var(--lbs-type-display-md-font-weight);
	line-height: var(--lbs-type-display-md-line-height);
	letter-spacing: var(--lbs-type-display-md-letter-spacing);
}

h4,
.h4 {
	font-family: var(--lbs-type-display-sm-font-family);
	font-size: var(--lbs-type-display-sm-font-size);
	font-weight: var(--lbs-type-display-sm-font-weight);
	line-height: var(--lbs-type-display-sm-line-height);
	letter-spacing: var(--lbs-type-display-sm-letter-spacing);
}

h5,
.h5 {
	font-family: var(--lbs-type-heading-md-font-family);
	font-size: var(--lbs-type-heading-md-font-size);
	font-weight: var(--lbs-type-heading-md-font-weight);
	line-height: var(--lbs-type-heading-md-line-height);
	letter-spacing: var(--lbs-type-heading-md-letter-spacing);
}

h6,
.h6 {
	font-family: var(--lbs-type-heading-sm-font-family);
	font-size: var(--lbs-type-heading-sm-font-size);
	font-weight: var(--lbs-type-heading-sm-font-weight);
	line-height: var(--lbs-type-heading-sm-line-height);
	letter-spacing: var(--lbs-type-heading-sm-letter-spacing);
}

h1,
h2,
h3,
h4,
h5,
h6 {
	margin: 0;
	text-wrap: balance;
}

p {
	margin: 0;
	/* Inherits body body-lg; explicit rule kept for Gutenberg / mixed markup */
}

.lbs-type-body-lg {
	font-family: var(--lbs-type-body-lg-font-family);
	font-size: var(--lbs-type-body-lg-font-size);
	font-weight: var(--lbs-type-body-lg-font-weight);
	line-height: var(--lbs-type-body-lg-line-height);
	letter-spacing: var(--lbs-type-body-lg-letter-spacing);
}

.lbs-type-body-md {
	font-family: var(--lbs-type-body-md-font-family);
	font-size: var(--lbs-type-body-md-font-size);
	font-weight: var(--lbs-type-body-md-font-weight);
	line-height: var(--lbs-type-body-md-line-height);
	letter-spacing: var(--lbs-type-body-md-letter-spacing);
}

.lbs-type-body-sm {
	font-family: var(--lbs-type-body-sm-font-family);
	font-size: var(--lbs-type-body-sm-font-size);
	font-weight: var(--lbs-type-body-sm-font-weight);
	line-height: var(--lbs-type-body-sm-line-height);
	letter-spacing: var(--lbs-type-body-sm-letter-spacing);
}

.lbs-type-action-label {
	font-family: var(--lbs-type-action-label-font-family);
	font-size: var(--lbs-type-action-label-font-size);
	font-weight: var(--lbs-type-action-label-font-weight);
	line-height: var(--lbs-type-action-label-line-height);
	letter-spacing: var(--lbs-type-action-label-letter-spacing);
}

img,
svg {
	display: block;
	max-width: 100%;
	height: auto;
}

/* Shared PNG arrow on CTA buttons (banner, split-image, etc.) */
.lbs-btn-arrow {
	display: block;
	flex-shrink: 0;
	width: 1.882rem;
	height: auto;
}

a {
	color: inherit;
	text-decoration: none;
}

a:hover,
a:focus-visible {
	text-decoration: underline;
	text-underline-offset: 0.2em;
}

.screen-reader-text {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

.site-main {
	min-height: 50vh;
}

/* Slightly tighter vertical rhythm between consecutive flexible sections */
.site-main .content-area > * + * {
	margin-top: -0.5rem;
}
