/**
 * HQ Saga design tokens — single source of truth.
 * Do not hardcode these values elsewhere; reference var(--hq-*).
 */
:root {
	/* Color */
	--hq-warm-white: #fbf8f3;
	--hq-beige: #f2eadd;
	--hq-sand: #e7d8c3;
	--hq-terracotta: #b66d51;
	--hq-sage: #7c8a6b;
	--hq-ink: #332a22;
	--hq-body: #6b5f50;
	--hq-hairline: #e4d9c8;

	/* Semantic aliases (footer + dark surfaces) — reference existing palette,
	   no new hex values. */
	--hq-espresso: var(--hq-ink);
	--hq-cream: var(--hq-warm-white);
	--hq-cream-strong: color-mix(in srgb, var(--hq-warm-white) 88%, transparent);
	--hq-cream-muted: color-mix(in srgb, var(--hq-warm-white) 72%, transparent);
	--hq-cream-faint: color-mix(in srgb, var(--hq-warm-white) 12%, transparent);
	--hq-terracotta-dark: color-mix(in srgb, var(--hq-terracotta) 92%, #000);
	/* Very light pastel orange — brand colour ~15 shades lighter (for soft banners). */
	--hq-terracotta-tint: color-mix(in srgb, var(--hq-terracotta) 14%, #fff);
	--hq-terracotta-tint-border: color-mix(in srgb, var(--hq-terracotta) 28%, #fff);
	--hq-sage-dark: color-mix(in srgb, var(--hq-sage) 88%, #000);
	/* Soft pastel green — sage family (buttons, success surfaces). */
	--hq-sage-tint: color-mix(in srgb, var(--hq-sage) 38%, #fff);
	--hq-sage-tint-border: color-mix(in srgb, var(--hq-sage) 52%, #fff);
	--hq-btn-primary-bg: var(--hq-terracotta);
	--hq-btn-primary-bg-hover: var(--hq-terracotta-dark);
	--hq-btn-primary-shadow: rgba(182, 109, 81, 0.22);

	/* Typography scale — single consistent ramp */
	--fs-eyebrow: 0.75rem;
	--fs-meta: 0.8125rem;
	--fs-price: 0.875rem;
	--fs-card: 0.9375rem;
	--fs-body: 1rem;
	--fs-lead: 1.0625rem;
	--fs-h4: 1.125rem;
	--fs-h3: clamp(1.4rem, 2.5vw, 1.75rem);
	--fs-h2: clamp(2rem, 3.5vw, 2.75rem);
	--fs-h1: clamp(2.5rem, 4.5vw, 3.5rem);
	--fs-hero: clamp(2.75rem, 5vw, 4.25rem);

	/* Line-heights */
	--lh-tight: 1.15;
	--lh-snug: 1.35;
	--lh-body: 1.65;

	/* Font weights — keep usage consistent */
	--fw-regular: 400;
	--fw-medium: 500;
	--fw-semibold: 600;
	--fw-bold: 700;

	/* Unified site fonts — Nunito Sans for headings, Baloo 2 for UI/body, Caveat for accents */
	--hq-font-display: "Nunito Sans", "Quicksand", sans-serif;
	--hq-font-display-alt: "Nunito Sans", "Quicksand", sans-serif;
	--hq-font-ui: "Baloo 2", "Quicksand", sans-serif;
	--hq-font-accent: "Caveat", cursive;

	/* Photographic image pop — subtle brightness + saturation lift */
	--hq-img-pop: brightness(1.013) saturate(1.08);

	/* Spacing (4px base) */
	--space-1: 4px;
	--space-2: 8px;
	--space-3: 12px;
	--space-4: 16px;
	--space-5: 24px;
	--space-6: 32px;
	--space-7: 48px;
	--space-8: 64px;
	--space-9: 96px;

	/* Radius / elevation / motion */
	--radius-card: 14px;
	--radius-btn: 999px;
	--radius-chip: 6px;
	--shadow-card: 0 1px 2px rgba(51, 42, 34, 0.04), 0 8px 24px rgba(51, 42, 34, 0.06);
	--ease: cubic-bezier(0.2, 0.6, 0.2, 1);
	--duration: 250ms;
}

@media (prefers-reduced-motion: reduce) {
	:root {
		--duration: 0ms;
	}
}

.hq-saga-theme,
.hq-saga-theme body {
	background: var(--hq-warm-white);
	color: var(--hq-body);
	font-family: var(--hq-font-ui);
	font-size: var(--fs-body);
	font-weight: var(--fw-regular);
	line-height: var(--lh-body);
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
	text-rendering: optimizeLegibility;
}

/* Bzotech typography.css styles every checkbox via ::before — strip on WC block inputs */
.hq-saga-theme input.wc-block-components-checkbox__input[type="checkbox"]::before,
.hq-saga-theme input.wc-block-components-checkbox__input[type="checkbox"]::after {
	content: none !important;
	display: none !important;
	width: 0 !important;
	height: 0 !important;
	border: 0 !important;
	background: transparent !important;
}

.hq-saga-theme input.wc-block-components-checkbox__input[type="checkbox"] {
	width: 20px !important;
	height: 20px !important;
	line-height: normal !important;
	vertical-align: middle !important;
	position: relative !important;
}

/* Remap legacy Bzotech theme option colors to HQ tokens */
.hq-saga-theme {
	--bzo-main-color: var(--hq-terracotta);
	--bzo-main-color-mix: #965033;
	--bzo-main-color-mix2: var(--hq-sage);
	--bzo-title_typo-color: var(--hq-ink);
	--bzo-body_typo-color: var(--hq-body);
	--bzo-border-color: var(--hq-hairline);
	--bzo-body-background: var(--hq-warm-white);
}

/* Breadcrumb / page-title banner — match header orange */
.hq-saga-theme .content-append-before .bg-color2-lighten,
.hq-saga-theme .content-append-before [data-id="e21b60e"],
.hq-saga-theme .content-append-before .elementor-7748 > .e-con {
	background: color-mix(in srgb, var(--hq-terracotta) 30%, #fff) !important;
}

/* Pink content blocks site-wide — match the same soft pastel-orange */
.hq-saga-theme .bg-color-lighten,
.hq-saga-theme .bg-color2-lighten {
	background: color-mix(in srgb, var(--hq-terracotta) 30%, #fff) !important;
}

/* Override parent-theme (:root) and Elementor kit typography vars.
   body.hq-saga-theme (0,1,1) wins over :root / .elementor-kit-* (0,1,0). */
body.hq-saga-theme,
html body.hq-saga-theme {
	/* Parent theme (bzotech) typography → Nunito Sans / Baloo 2 */
	--bzo-body_typo-font-family: "Baloo 2", "Quicksand", sans-serif;
	--bzo-title_typo-font-family: "Nunito Sans", "Quicksand", sans-serif;
	--bzo-menu_typo-font-family: "Nunito Sans", "Quicksand", sans-serif;

	/* Elementor global kit typography → Nunito Sans / Baloo 2 */
	--e-global-typography-primary-font-family: "Nunito Sans", "Quicksand", sans-serif;
	--e-global-typography-secondary-font-family: "Nunito Sans", "Quicksand", sans-serif;
	--e-global-typography-text-font-family: "Baloo 2", "Quicksand", sans-serif;
	--e-global-typography-accent-font-family: "Caveat", cursive;
}

/* ──────────────────────────────────────────────
   Site-wide font normalization
   Nunito Sans (headings) + Baloo 2 (body/UI) + Caveat (accents).
   Icon fonts are explicitly preserved below.
   ────────────────────────────────────────────── */
.hq-saga-theme,
.hq-saga-theme body,
.hq-saga-theme p,
.hq-saga-theme a,
.hq-saga-theme li,
.hq-saga-theme span,
.hq-saga-theme div,
.hq-saga-theme label,
.hq-saga-theme input,
.hq-saga-theme select,
.hq-saga-theme textarea,
.hq-saga-theme button,
.hq-saga-theme blockquote,
.hq-saga-theme table,
.hq-saga-theme .elementor-widget-text-editor,
.hq-saga-theme .elementor-widget-heading,
.hq-saga-theme .elementor-button,
.hq-saga-theme .elementor-widget-container,
.hq-saga-theme .menu-item a,
.hq-saga-theme .hfe-menu-item,
.hq-saga-theme .woocommerce,
.hq-saga-theme .woocommerce-page {
	font-family: var(--hq-font-ui);
}

.hq-saga-theme h1,
.hq-saga-theme h2,
.hq-saga-theme h3,
.hq-saga-theme h4,
.hq-saga-theme h5,
.hq-saga-theme h6,
.hq-saga-theme .hq-display,
.hq-saga-theme .font-title,
.hq-saga-theme .elementor-heading-title,
.hq-saga-theme .product_title,
.hq-saga-theme .woocommerce-loop-product__title,
.hq-saga-theme .entry-title,
.hq-saga-theme .widget-title {
	font-family: var(--hq-font-display);
	font-weight: 400;
	color: var(--hq-ink);
	letter-spacing: 0.01em;
	line-height: var(--lh-snug);
}

/* Consistent heading sizes (no !important — Elementor per-widget settings still win) */
.hq-saga-theme h1 { font-size: var(--fs-h1); line-height: 1.2; }
.hq-saga-theme h2 { font-size: var(--fs-h2); line-height: 1.2; }
.hq-saga-theme h3 { font-size: var(--fs-h3); line-height: var(--lh-snug); }
.hq-saga-theme h4 { font-size: var(--fs-h4); line-height: var(--lh-snug); }

.hq-saga-theme p {
	line-height: var(--lh-body);
}

/* ──────────────────────────────────────────────
   Photographic image pop — subtle brightness + saturation.
   Scoped to content photos only (never logos/icons/UI).
   ────────────────────────────────────────────── */
.hq-saga-theme .hq-card__image,
.hq-saga-theme .hq-brand-story__image,
.hq-saga-theme .wc-block-cart-item__image img,
.hq-saga-cart .hq-cart-thumb,
.hq-saga-product .woocommerce-product-gallery__image img,
.hq-saga-theme .hq-instagram-tile img {
	filter: var(--hq-img-pop);
}

/* Preserve icon fonts — re-assert correct families (never Albert Sans) */
.hq-saga-theme .fa,
.hq-saga-theme .fas,
.hq-saga-theme .far,
.hq-saga-theme .fal,
.hq-saga-theme [class^="fa-"],
.hq-saga-theme [class*=" fa-"] { font-family: "Font Awesome 5 Free", FontAwesome !important; }

.hq-saga-theme .fab { font-family: "Font Awesome 5 Brands" !important; }

.hq-saga-theme .la,
.hq-saga-theme .las,
.hq-saga-theme .lar,
.hq-saga-theme .lab,
.hq-saga-theme [class^="la-"],
.hq-saga-theme [class*=" la-"] { font-family: "Line Awesome Free", "Line Awesome Brands" !important; }

.hq-saga-theme [class^="bzoicon"],
.hq-saga-theme [class*=" bzoicon"] { font-family: "bzoicon" !important; }

.hq-saga-theme [class^="eicon"],
.hq-saga-theme [class*=" eicon"] { font-family: "eicons" !important; }

.hq-saga-theme [class^="elementskit"],
.hq-saga-theme [class*=" elementskit"] { font-family: "elementskit" !important; }

.hq-saga-theme a:focus-visible,
.hq-saga-theme button:focus-visible {
	outline: 2px solid var(--hq-terracotta);
	outline-offset: 3px;
}

/* ── Kill parent-theme add-to-cart popup ── */
.hq-saga-theme .bzo-ajaxcart-report {
	display: none !important;
}

/* ── Hide price filter widget site-wide ── */
.hq-saga-theme .widget_price_filter,
.hq-saga-theme .woocommerce.widget_price_filter,
.hq-saga-theme .attr-price-filter {
	display: none !important;
}

/* ── Side toast notification ── */
.hq-toast {
	position: fixed;
	top: var(--space-5);
	right: var(--space-5);
	z-index: 10000;
	display: flex;
	align-items: center;
	gap: var(--space-3);
	max-width: 360px;
	padding: var(--space-4) var(--space-5);
	background: var(--hq-warm-white);
	border: 1px solid var(--hq-terracotta);
	color: var(--hq-ink);
	border-radius: var(--radius-card);
	box-shadow: 0 10px 30px rgba(182, 109, 81, 0.12);
	font-family: var(--hq-font-ui);
	font-size: var(--fs-meta);
	font-weight: var(--fw-medium);
	line-height: 1.4;
	transform: translateX(calc(100% + var(--space-5)));
	opacity: 0;
	transition: transform 400ms var(--ease), opacity 300ms var(--ease);
	pointer-events: none;
}

.hq-toast.is-visible {
	transform: translateX(0);
	opacity: 1;
	pointer-events: auto;
}

.hq-toast__icon {
	flex-shrink: 0;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 28px;
	height: 28px;
	border-radius: 50%;
	background: var(--hq-sage);
	color: #fff;
	font-size: 0.85rem;
}

.hq-toast__body {
	flex: 1;
	min-width: 0;
}

.hq-toast__title {
	display: block;
	font-weight: var(--fw-semibold);
	color: var(--hq-terracotta);
	margin-bottom: 2px;
}

.hq-toast__link {
	display: inline-block;
	margin-top: var(--space-2);
	color: var(--hq-ink);
	font-weight: var(--fw-bold);
	text-decoration: underline;
	text-underline-offset: 2px;
}

.hq-toast__link:hover {
	color: var(--hq-terracotta);
}

.hq-toast__close {
	flex-shrink: 0;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 24px;
	height: 24px;
	border: 0;
	background: transparent;
	color: var(--hq-body);
	font-size: 1.1rem;
	cursor: pointer;
	transition: color 200ms;
}

.hq-toast__close:hover {
	color: var(--hq-ink);
}

@media (max-width: 575px) {
	.hq-toast {
		right: var(--space-3);
		left: var(--space-3);
		max-width: none;
	}
}
