/*
Theme Name: Routine For You
Theme URI: https://routine4u.com
Author: Gizmo Media Production
Description: Bilingual (English / Arabic) theme for routine4u.com. Design direction "Thin to thick". Needs the Routine For You Core plugin.
Version: 1.5.4
Requires PHP: 7.4
License: Proprietary
Text Domain: routine4u
*/

/* Fonts (self-hosted, OFL) ------------------------------------------------ */
@font-face {
	font-family: "Alexandria";
	src: url("assets/fonts/alexandria-var.woff2") format("woff2");
	font-weight: 100 900;
	font-display: swap;
}
@font-face {
	font-family: "Readex Pro";
	src: url("assets/fonts/readexpro-var.woff2") format("woff2");
	font-weight: 160 700;
	font-display: swap;
}

/* Tokens ------------------------------------------------------------------- */
:root {
	/* Roles (see DESIGN.md): ink = action, teal = information, deal = money, sun = decoration only */
	--ink: #22313B; --ink-2: #3D5566; --ink-3: #4F6676;
	--paper: #F7F9F9; --surface: #FFFFFF; --water: #E9EFF1; --line: #D5DEE2;
	--teal: #28706A; --on-teal: #FFFFFF;
	--gel-light: #CFE7E4; --gel: #A8D5D1; --gel-deep: #7DBDB8; --cream: #EDD8C4; --sun: #E0B348;
	--success: #1F6B47; --success-bg: #E2F1EA;
	--deal: var(--success); --deal-bg: var(--success-bg);
	--caution: #8A5A0E; --caution-bg: #FBEFD9;
	--danger: #B3402E; --danger-bg: #F8E1DC;
	--sponsored: #4F6676; --sponsored-bg: #EEF1F3;
	--on-ink: #F7F9F9;
	/* "Night" blocks (evening card, final call to action) stay deep in both modes */
	--night: #22313B; --on-night: #F7F9F9; --night-glow: none;
	--btn: var(--ink); --on-btn: var(--on-ink); --btn-hover: var(--ink-2);
	--gloss: .55;

	--font-display: "Alexandria", system-ui, sans-serif;
	--font-body: "Readex Pro", system-ui, sans-serif;

	--t-display: clamp(2.75rem, 1.6rem + 4.2vw, 4.75rem);
	--t-h1: clamp(2.25rem, 1.6rem + 2.4vw, 3.5rem);
	--t-h2: clamp(1.75rem, 1.4rem + 1.3vw, 2.5rem);
	--t-h3: clamp(1.375rem, 1.25rem + 0.4vw, 1.75rem);
	--t-h4: 1.1875rem;
	--t-lead: clamp(1.125rem, 1.08rem + 0.2vw, 1.25rem);
	--t-body: clamp(1rem, 0.98rem + 0.1vw, 1.0625rem);
	--t-small: 0.9375rem;
	--t-micro: 0.8125rem;
	--t-h1-product: clamp(1.5rem, 1.2rem + 1.2vw, 2.25rem);
	--t-price-lg: 1.75rem;
	--t-price: 1.25rem;

	--s-1: 4px; --s-2: 8px; --s-3: 12px; --s-4: 16px; --s-5: 24px; --s-6: 32px; --s-7: 48px; --s-8: 64px;

	--r-pill: 999px; --r-card: 20px; --r-row: 16px; --r-img: 12px; --r-input: 14px;
	--shadow-float: 0 8px 24px rgba(34, 49, 59, .08);
	--container: 1200px; --reading: 720px; --gutter: clamp(20px, 5vw, 72px);
	--section: clamp(64px, 8vw, 96px);
}

:root[data-theme="dark"] {
	/* Moonlight: deep blue night, warm cream text, glowing gel colours */
	--ink: #F4EEE6; --ink-2: #CFC7BC; --ink-3: #A39B91;
	--paper: #0E131A; --surface: #19212B; --water: #141B24; --line: #2A3441;
	--teal: #8FD6CC; --on-teal: #0E131A;
	--gel-light: #4E9890; --gel: #63B3AA; --gel-deep: #86CDC3; --cream: #E2BE97; --sun: #F3C661;
	--success: #8EDBB5; --success-bg: #15302A;
	--caution: #F3C661; --caution-bg: #352A14;
	--danger: #F4A497; --danger-bg: #3A1D1A;
	--sponsored: #A39B91; --sponsored-bg: #1D2530;
	--on-ink: #0E131A;
	--night: #172539; --on-night: #F4EEE6;
	--night-glow: radial-gradient(120% 90% at 85% 0%, rgba(143, 214, 204, .16), transparent 55%), radial-gradient(90% 80% at 0% 100%, rgba(243, 198, 97, .09), transparent 60%);
	--btn: #8FD6CC; --on-btn: #0E131A; --btn-hover: #B3E5DE;
	--gloss: .3;
	--shadow-float: 0 10px 30px rgba(0, 0, 0, .45);
	color-scheme: dark;
}

/* Base --------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
	margin: 0;
	background: var(--paper);
	color: var(--ink);
	font-family: var(--font-body);
	font-size: var(--t-body);
	line-height: 1.65;
	font-weight: 400;
	-webkit-font-smoothing: antialiased;
}
:lang(ar) body, body.lang-ar { line-height: 1.8; }
img, svg { max-width: 100%; height: auto; display: block; }
a { color: var(--teal); text-underline-offset: 3px; }
a:hover { color: var(--ink); }
:focus-visible { outline: 3px solid var(--teal); outline-offset: 2px; border-radius: 6px; }
p { margin: 0 0 1em; }
:where(ul[role="list"], ol[role="list"]) { list-style: none; margin: 0; padding: 0; }
h1, h2, h3, h4 { margin: 0 0 .5em; font-family: var(--font-display); font-weight: 600; color: var(--ink); }
.screen-reader-text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(1px, 1px, 1px, 1px); }

.display { font-size: var(--t-display); line-height: 1.02; letter-spacing: -0.04em; }
.h1 { font-size: var(--t-h1); line-height: 1.05; letter-spacing: -0.035em; }
.h2 { font-size: var(--t-h2); line-height: 1.1; letter-spacing: -0.03em; }
.h3 { font-size: var(--t-h3); line-height: 1.2; letter-spacing: -0.02em; }
.h4 { font-size: var(--t-h4); line-height: 1.3; }
.lead { font-size: var(--t-lead); line-height: 1.6; color: var(--ink-2); max-width: 36em; }
.small { font-size: var(--t-small); }
.muted { color: var(--ink-3); }

/* Arabic: no negative tracking, a little more line height, one step smaller headlines */
.lang-ar .display, .lang-ar .h1, .lang-ar .h2, .lang-ar .h3, .lang-ar h1, .lang-ar h2, .lang-ar h3 { letter-spacing: 0; }
.lang-ar .display { font-size: calc(var(--t-display) * .86); line-height: 1.25; }
.lang-ar .h1 { font-size: calc(var(--t-h1) * .9); line-height: 1.3; }
.lang-ar .h2 { line-height: 1.3; }
.lang-ar .h3 { line-height: 1.4; }
.lang-ar .lead { line-height: 1.8; max-width: 32em; }

.container { width: 100%; max-width: calc(var(--container) + var(--gutter) * 2); margin-inline: auto; padding-inline: var(--gutter); }
.reading { max-width: calc(var(--reading) + var(--gutter) * 2); }

.skip-link { position: absolute; inset-inline-start: 16px; top: -60px; background: var(--ink); color: var(--on-ink); padding: 10px 16px; border-radius: var(--r-pill); z-index: 100; text-decoration: none; }
.skip-link:focus { top: 12px; }

/* Buttons ------------------------------------------------------------------ */
.btn {
	display: inline-flex; align-items: center; justify-content: center; gap: 8px;
	min-height: 52px; padding: 14px 28px; border-radius: var(--r-pill);
	font-family: var(--font-body); font-size: 1.0625rem; font-weight: 500; line-height: 1.2;
	text-decoration: none; border: 1.5px solid transparent; cursor: pointer;
	transition: background-color .15s ease, color .15s ease, border-color .15s ease;
}
.btn-primary { background: var(--btn); color: var(--on-btn); }
.btn-primary:hover { background: var(--btn-hover); color: var(--on-btn); }
.btn-secondary { background: transparent; color: var(--ink); border-color: var(--ink); }
.btn-secondary:hover { background: var(--ink); color: var(--on-ink); }
.btn-quiet { background: transparent; color: var(--ink); padding-inline: 8px; }
.btn-quiet:hover { color: var(--ink); text-decoration: underline; }
.btn-sm { min-height: 44px; padding: 10px 20px; font-size: 1rem; }
.btn[disabled], .btn[aria-disabled="true"] { background: var(--line); color: var(--ink-3); border-color: transparent; cursor: not-allowed; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin-block: 28px 0; }
.link { font-weight: 500; }

/* Header ------------------------------------------------------------------- */
.site-header { position: sticky; top: 0; z-index: 50; background: color-mix(in srgb, var(--paper) 92%, transparent); backdrop-filter: saturate(1.4) blur(8px); border-bottom: 1px solid transparent; }
.site-header.is-scrolled { border-bottom-color: var(--line); }
.header-inner { display: flex; align-items: center; gap: 24px; min-height: 76px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; }
.brand-mark { width: 32px; height: 32px; fill: currentColor; }
.lang-ar .brand-mark { transform: scaleX(-1); }
.brand-word { font-family: var(--font-display); font-weight: 600; font-size: 1.625rem; letter-spacing: -0.04em; line-height: 1; }
.lang-ar .brand-word { letter-spacing: 0; font-size: 1.5rem; }
.site-nav { margin-inline-start: auto; }
.site-nav ul { display: flex; align-items: center; gap: 28px; }
.site-nav a { color: var(--ink); text-decoration: none; font-weight: 400; white-space: nowrap; }
.site-nav a:hover { text-decoration: underline; }
.site-nav .btn-primary { color: var(--on-btn); }
.site-nav .btn-primary:hover { text-decoration: none; }
.lang-switch { color: var(--ink); text-decoration: none; font-weight: 500; padding: 8px 4px; }
.lang-switch:lang(ar) { font-family: var(--font-display); }
.menu-toggle { display: none; }
.theme-toggle { display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; padding: 0; border: 1.5px solid var(--line); border-radius: var(--r-pill); background: transparent; color: var(--ink); cursor: pointer; flex: none; transition: border-color .15s ease, background-color .15s ease; }
.theme-toggle:hover { border-color: var(--ink); }
.theme-toggle .icon { width: 20px; height: 20px; }
.theme-toggle .icon-sun { display: none; }
:root[data-theme="dark"] .theme-toggle .icon-sun { display: block; }
:root[data-theme="dark"] .theme-toggle .icon-moon { display: none; }

@media (max-width: 1120px) {
	.header-inner { min-height: 64px; gap: 12px; }
	.menu-toggle {
		display: inline-flex; margin-inline-start: auto; align-items: center; min-height: 44px; padding: 8px 16px;
		border: 1.5px solid var(--ink); border-radius: var(--r-pill); background: transparent; color: var(--ink);
		font: 500 1rem var(--font-body); cursor: pointer;
	}
	.site-nav { display: none; position: absolute; inset-inline: 0; top: 100%; background: var(--paper); border-bottom: 1px solid var(--line); padding: 8px var(--gutter) 24px; margin: 0; }
	.site-nav.is-open { display: block; }
	.site-nav ul { flex-direction: column; align-items: stretch; gap: 0; }
	.site-nav li a { display: block; padding: 14px 0; font-size: 1.125rem; border-bottom: 1px solid var(--line); }
	.site-nav .nav-cta { margin-top: 16px; }
	.site-nav .nav-cta a { border-bottom: 0; display: flex; }
}

/* Sections ----------------------------------------------------------------- */
.section { padding-block: var(--section); }
.section-tight { padding-block: clamp(32px, 5vw, 56px) var(--section); }
.section-water { background: var(--water); }
.section-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 12px 24px; margin-bottom: 32px; }
.section-head .h2 { margin: 0; }
.page-head { padding-block: clamp(40px, 6vw, 72px) 8px; }
.page-head .lead { margin-bottom: 0; }
.crumbs { display: flex; gap: 8px; font-size: var(--t-small); color: var(--ink-3); margin-bottom: 16px; }
.crumbs a { color: var(--ink-3); }
.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(32px, 6vw, 80px); align-items: center; }
.cta-band { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px; }
.cta-band .lead { margin: 0; }
@media (max-width: 760px) { .split { grid-template-columns: 1fr; } }

/* Hero (home) -------------------------------------------------------------- */
.hero { background: var(--water); padding-block: clamp(48px, 8vw, 104px); }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.12fr) minmax(0, 1fr); gap: clamp(32px, 6vw, 80px); align-items: center; }
.hero .display { margin-bottom: 24px; }
.hero .lead { margin-bottom: 0; }
.promise { margin: 20px 0 0; font-size: var(--t-small); color: var(--ink-3); }
.hero-layers { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 14px; }
.hero-layer { display: flex; align-items: center; gap: 18px; }
.hero-layer .layer-bar { flex: 1; height: var(--h); border-radius: var(--r-pill); }
.hero-layer-label { width: 9.5em; font-size: var(--t-small); color: var(--ink-2); }
@media (max-width: 860px) {
	.hero-grid { grid-template-columns: 1fr; }
}

/* Texture colors (one mapping everywhere) ---------------------------------- */
.tex-water { --tex: var(--gel-light); }
.tex-gel { --tex: var(--gel); }
.tex-treatment { --tex: var(--gel-deep); }
.tex-cream { --tex: var(--cream); }
.tex-sun { --tex: var(--sun); }
.layer-bar, .mini-layer { background: var(--tex, var(--gel)); }
.swatch path { fill: var(--tex, var(--gel)); }
.swatch-gloss { fill: #fff; opacity: var(--gloss); }

/* Layer reveal: the one orchestrated motion */
@media (prefers-reduced-motion: no-preference) {
	.js .hero-layer .layer-bar, .js .stack .layer-bar { transform-origin: left center; animation: r4u-grow .5s cubic-bezier(.2, .7, .2, 1) both; }
	.js .lang-ar .hero-layer .layer-bar, .js .lang-ar .stack .layer-bar { transform-origin: right center; }
	.hero-layer:nth-child(2) .layer-bar, .layer:nth-child(2) .layer-bar { animation-delay: .08s; }
	.hero-layer:nth-child(3) .layer-bar, .layer:nth-child(3) .layer-bar { animation-delay: .16s; }
	.hero-layer:nth-child(4) .layer-bar, .layer:nth-child(4) .layer-bar { animation-delay: .24s; }
	.hero-layer:nth-child(5) .layer-bar, .layer:nth-child(5) .layer-bar { animation-delay: .32s; }
	.layer:nth-child(6) .layer-bar { animation-delay: .40s; }
	.layer:nth-child(7) .layer-bar { animation-delay: .48s; }
}
@keyframes r4u-grow { from { transform: scaleX(0); } to { transform: scaleX(1); } }

/* How it works ------------------------------------------------------------- */
.how { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; margin-top: 32px; }
.how-step { background: var(--surface); border-radius: var(--r-card); padding: 28px; }
.how-num { display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; border-radius: 50%; background: var(--water); font-family: var(--font-display); font-weight: 600; font-size: 1.125rem; margin-bottom: 20px; }
.how-step p { color: var(--ink-2); margin: 0; }
@media (max-width: 860px) { .how { grid-template-columns: 1fr; } }

/* Preset cards ------------------------------------------------------------- */
.preset-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.preset-card { display: flex; flex-direction: column; gap: 10px; background: var(--surface); border-radius: var(--r-card); padding: 24px; color: var(--ink); text-decoration: none; border: 1.5px solid transparent; transition: border-color .15s ease; }
.preset-card:hover { border-color: var(--ink); color: var(--ink); }
.mini-stack { display: flex; flex-direction: column; gap: 5px; width: 120px; margin-bottom: 8px; }
.mini-layer { display: block; height: var(--h); border-radius: var(--r-pill); }
.preset-title { font-family: var(--font-display); font-weight: 600; font-size: 1.25rem; line-height: 1.25; letter-spacing: -0.02em; }
.lang-ar .preset-title { letter-spacing: 0; line-height: 1.5; }
.preset-meta { font-size: var(--t-small); color: var(--ink-3); }
@media (max-width: 960px) { .preset-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .preset-grid { grid-template-columns: 1fr; } }

/* Chips -------------------------------------------------------------------- */
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0 20px; }
.chip { display: inline-flex; align-items: center; min-height: 32px; padding: 5px 14px; border-radius: var(--r-pill); background: var(--water); color: var(--ink); font-size: var(--t-small); line-height: 1.3; text-decoration: none; }
.chip-ok { background: var(--success-bg); color: var(--success); }
.chip-caution { background: var(--caution-bg); color: var(--caution); }
.chip-danger { background: var(--danger-bg); color: var(--danger); }
.chip-plain { background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }
.chip-link { min-height: 40px; padding-inline: 16px; }
.chip-link:hover { background: var(--ink); color: var(--on-ink); }
.section-water .chip, .builder .chip { background: var(--surface); }
.ing-cloud { display: flex; flex-wrap: wrap; gap: 10px; }

/* Routine page: layer stacks ---------------------------------------------- */
.routine { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 40px; align-items: start; }
.routine-stacks { display: flex; flex-direction: column; gap: 32px; }
.routine-side { position: sticky; top: 100px; display: flex; flex-direction: column; gap: 16px; }
@media (max-width: 960px) { .routine { grid-template-columns: 1fr; } .routine-side { position: static; } }
.stack { background: var(--surface); border-radius: var(--r-card); padding: clamp(20px, 3vw, 32px); }
.stack-title { font-size: var(--t-h3); letter-spacing: -0.02em; margin-bottom: 20px; }
.stack-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 18px; }
.layer { display: grid; grid-template-columns: 112px minmax(0, 1fr); gap: 20px; align-items: center; }
.layer-bar { display: block; width: 100%; height: var(--h); border-radius: var(--r-pill); }
.layer-body p { margin: 0; }
.layer-step { font-size: var(--t-small); color: var(--ink-3); display: flex; align-items: center; gap: 8px; }
.layer-num { font-family: var(--font-display); font-weight: 600; color: var(--ink); }
.layer-product { font-weight: 500; font-size: 1.0625rem; }
.layer-product a { color: var(--ink); text-decoration: none; }
.layer-product a:hover { text-decoration: underline; }
.layer-brand { color: var(--ink-3); font-weight: 400; }
.layer-why { color: var(--ink-2); font-size: var(--t-small); margin-top: 4px !important; }
.layer-alts { margin-top: 6px; font-size: var(--t-small); }
.layer-alts summary { cursor: pointer; color: var(--teal); min-height: 32px; display: inline-flex; align-items: center; }
.layer-alts ul { margin: 6px 0 0; padding-inline-start: 18px; }
@media (max-width: 560px) { .layer { grid-template-columns: 64px minmax(0, 1fr); gap: 14px; } }

/* Panels ------------------------------------------------------------------- */
.panel { border-radius: var(--r-card); padding: 24px; }
.panel :last-child { margin-bottom: 0; }
.panel ul { margin: 0; padding-inline-start: 18px; }
.panel li + li { margin-top: 8px; }
.panel-caution { background: var(--caution-bg); }
.panel-caution .h3, .panel-caution li { color: var(--ink); }
.panel-danger { background: var(--danger-bg); margin-block: 24px; }
.panel-danger .chips { margin-bottom: 0; }
.panel-water { background: var(--water); margin-block: 24px; }
.routine-side .panel-water { margin: 0; }
.routine-side .panel-water .btn { margin-top: 8px; }

/* Products ----------------------------------------------------------------- */
.product-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }
.product-card { background: var(--surface); border-radius: var(--r-card); padding: 22px; display: flex; flex-direction: column; gap: 6px; position: relative; }
.product-card .swatch { width: 96px; margin-bottom: 10px; }
.product-card .product-brand { margin: 0; }
.product-card .product-name { font-family: var(--font-body); font-weight: 500; font-size: 1.0625rem; line-height: 1.35; letter-spacing: 0; margin: 0; }
.product-card .product-name a { color: var(--ink); text-decoration: none; }
.product-card .product-name a::after { content: ""; position: absolute; inset: 0; border-radius: var(--r-card); }
.product-card:hover { box-shadow: inset 0 0 0 1.5px var(--ink); }
.product-why { margin: 0; font-size: var(--t-small); color: var(--ink-3); }
.product-brand { font-size: var(--t-small); color: var(--ink-3); margin: 0 0 6px; }
@media (max-width: 1080px) { .product-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 760px) { .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 460px) { .product-grid { grid-template-columns: 1fr; } }

.product-head { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 40px; align-items: center; }
.product-swatch-lg { background: var(--water); border-radius: var(--r-card); aspect-ratio: 1; display: flex; align-items: center; justify-content: center; padding: 28px; }
.swatch-lg { width: 100%; }
.product-head .h1 { font-size: clamp(1.875rem, 1.4rem + 1.8vw, 2.75rem); }
@media (max-width: 700px) { .product-head { grid-template-columns: 1fr; gap: 24px; } .product-swatch-lg { max-width: 180px; } }
.detail-grid { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 48px; }
@media (max-width: 860px) { .detail-grid { grid-template-columns: 1fr; gap: 24px; } }
.ing-list { display: flex; flex-direction: column; gap: 14px; margin-block: 8px 28px; }
.ing-list li { background: var(--surface); border-radius: var(--r-card); padding: 18px 22px; }
.ing-list-name { font-weight: 500; color: var(--ink); }
.ing-list p { margin: 4px 0 0; color: var(--ink-2); font-size: var(--t-small); }
.inci { background: var(--surface); border-radius: var(--r-card); padding: 18px 22px; }
.inci summary { cursor: pointer; font-weight: 500; min-height: 32px; display: flex; align-items: center; }
.inci p { font-size: var(--t-small); color: var(--ink-2); margin: 12px 0 0; word-break: break-word; }
.detail-side .h4 { margin-top: 8px; }

/* Ingredients -------------------------------------------------------------- */
.ing-index { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.ing-index a { display: flex; flex-direction: column; gap: 6px; background: var(--surface); border-radius: var(--r-card); padding: 22px 24px; text-decoration: none; color: var(--ink); height: 100%; border: 1.5px solid transparent; }
.ing-index a:hover { border-color: var(--ink); color: var(--ink); }
.ing-index-name { font-family: var(--font-display); font-weight: 600; font-size: 1.25rem; letter-spacing: -0.02em; }
.lang-ar .ing-index-name { letter-spacing: 0; }
.ing-index-what { color: var(--ink-2); font-size: var(--t-small); }
@media (max-width: 760px) { .ing-index { grid-template-columns: 1fr; } }
.facts { display: grid; gap: 0; margin: 0 0 24px; }
.facts > div { display: grid; grid-template-columns: 160px minmax(0, 1fr); gap: 16px; padding-block: 16px; border-bottom: 1px solid var(--line); align-items: center; }
.facts dt { color: var(--ink-3); font-size: var(--t-small); }
.facts dd { margin: 0; }
.facts .chips { margin: 0; }
@media (max-width: 560px) { .facts > div { grid-template-columns: 1fr; gap: 6px; } }

/* Journal ------------------------------------------------------------------ */
.post-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.post-card { display: flex; flex-direction: column; }
.post-card-img { display: block; border-radius: var(--r-card); overflow: hidden; aspect-ratio: 16 / 10; background: var(--water); margin-bottom: 14px; }
.post-card-img img { width: 100%; height: 100%; object-fit: cover; }
.post-card-swatch { display: flex; align-items: center; justify-content: center; padding: 15%; }
.post-card-swatch .swatch { width: 70%; }
.post-date { font-size: var(--t-small); color: var(--ink-3); margin: 0 0 6px; }
.post-card .h3 a { color: var(--ink); text-decoration: none; }
.post-card .h3 a:hover { text-decoration: underline; }
.post-card p:last-child { color: var(--ink-2); }
@media (max-width: 960px) { .post-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .post-grid { grid-template-columns: 1fr; } }
.pager { display: flex; justify-content: space-between; gap: 12px; margin-top: 40px; }
.empty { background: var(--surface); border-radius: var(--r-card); padding: clamp(28px, 5vw, 56px); text-align: center; }
.empty .lead { margin-inline: auto; }
.article-image img { border-radius: var(--r-card); width: 100%; }

/* Prose (articles and info pages) ----------------------------------------- */
.prose { font-size: var(--t-body); }
.prose h2 { font-size: var(--t-h3); margin-top: 1.8em; letter-spacing: -0.02em; }
.prose h3 { font-size: var(--t-h4); margin-top: 1.6em; }
.prose ul, .prose ol { padding-inline-start: 1.3em; margin: 0 0 1em; }
.prose li + li { margin-top: .4em; }
.prose img { border-radius: 12px; }
.prose blockquote { margin: 1.5em 0; padding: 4px 0; padding-inline-start: 20px; border-inline-start: 3px solid var(--gel); color: var(--ink-2); }
.lang-ar .prose h2, .lang-ar .prose h3 { letter-spacing: 0; }

/* Builder ------------------------------------------------------------------ */
.builder { background: var(--water); min-height: calc(100vh - 76px); padding-block: clamp(24px, 5vw, 56px) 96px; }
.builder-root { max-width: 760px; margin-inline: auto; }
.q-progress { display: flex; align-items: center; gap: 14px; margin-bottom: clamp(28px, 5vw, 48px); }
.q-bar { flex: 1; height: 8px; border-radius: var(--r-pill); background: var(--line); overflow: hidden; }
.q-bar span { display: block; height: 100%; background: var(--btn); border-radius: inherit; transition: width .25s ease; }
.q-count { font-size: var(--t-small); color: var(--ink-3); white-space: nowrap; }
.q-back { background: none; border: 0; color: var(--ink); font: 500 1rem var(--font-body); cursor: pointer; min-height: 44px; padding: 8px 4px; }
.q-back[hidden] { display: none; }
.q-title { font-size: var(--t-h2); text-align: center; letter-spacing: -0.03em; line-height: 1.15; margin-bottom: 10px; }
.lang-ar .q-title { letter-spacing: 0; line-height: 1.4; }
.q-hint { text-align: center; color: var(--ink-3); margin-bottom: 28px; }
.q-options { display: grid; gap: 12px; margin: 0; padding: 0; border: 0; }
.q-options.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 560px) { .q-options.two { grid-template-columns: 1fr; } }
.q-opt { position: relative; }
.q-opt input { position: absolute; opacity: 0; pointer-events: none; }
.q-opt label {
	display: flex; align-items: center; justify-content: space-between; gap: 14px;
	min-height: 64px; padding: 16px 20px; border-radius: var(--r-input);
	background: var(--surface); border: 1.5px solid var(--line); cursor: pointer;
	font-size: 1.0625rem; line-height: 1.4; transition: border-color .12s ease, box-shadow .12s ease;
}
.q-opt label:hover { border-color: var(--ink-3); }
.q-opt input:focus-visible + label { outline: 3px solid var(--teal); outline-offset: 2px; }
.q-opt input:checked + label { border-color: var(--teal); box-shadow: inset 0 0 0 1px var(--teal); }
.q-check { width: 24px; height: 24px; border-radius: 50%; border: 1.5px solid var(--line); flex-shrink: 0; display: flex; align-items: center; justify-content: center; }
.q-opt input[type="checkbox"] + label .q-check { border-radius: 7px; }
.q-opt input:checked + label .q-check { background: var(--teal); border-color: var(--teal); }
.q-check svg { width: 14px; height: 14px; stroke: var(--surface); opacity: 0; }
.q-opt input:checked + label .q-check svg { opacity: 1; }
.q-actions { display: flex; gap: 12px; justify-content: center; margin-top: 32px; }
.q-actions .btn { min-width: 220px; }
@media (max-width: 560px) {
	.q-actions { position: sticky; bottom: 0; margin-inline: calc(var(--gutter) * -1); padding: 14px var(--gutter); background: var(--water); box-shadow: var(--shadow-float); }
	.q-actions .btn { flex: 1; min-width: 0; }
}
.q-skip { background: none; border: 0; color: var(--ink-2); font: 400 1rem var(--font-body); text-decoration: underline; cursor: pointer; min-height: 44px; }

.result-head { margin-bottom: 28px; }
.result-head .h1 { margin-bottom: 12px; }
.result-summary { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 8px; }
.result-tabs { display: inline-grid; grid-auto-flow: column; background: var(--surface); border-radius: var(--r-pill); padding: 4px; margin-bottom: 20px; }
.result-tabs button { min-height: 44px; padding: 8px 22px; border: 0; border-radius: var(--r-pill); background: transparent; color: var(--ink-2); font: 500 1rem var(--font-body); cursor: pointer; }
.result-tabs button[aria-selected="true"] { background: var(--btn); color: var(--on-btn); }
.result-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
.result-note { margin-top: 20px; }
.builder .stack { box-shadow: none; }
.copied { color: var(--success); font-size: var(--t-small); align-self: center; }

/* Footer ------------------------------------------------------------------- */
.site-footer { background: var(--water); margin-top: 0; padding-block: 64px 32px; }
.footer-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) minmax(0, 1fr); gap: 40px; }
.footer-brand p { color: var(--ink-2); max-width: 30em; margin-top: 16px; }
.footer-promise { font-size: var(--t-small); }
.footer-title { font-family: var(--font-body); font-size: var(--t-small); font-weight: 500; color: var(--ink-3); margin-bottom: 12px; }
.site-footer ul a { display: inline-block; padding-block: 6px; color: var(--ink); text-decoration: none; }
.site-footer ul a:hover { text-decoration: underline; }
.footer-base { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; margin-top: 48px; padding-top: 24px; border-top: 1px solid var(--line); font-size: var(--t-micro); color: var(--ink-3); }
.footer-base p { margin: 0; }
@media (max-width: 760px) { .footer-grid { grid-template-columns: 1fr; gap: 28px; } }

/* 404 ---------------------------------------------------------------------- */
.notfound { padding-block: clamp(64px, 10vw, 120px); }
.notfound-mark { width: 72px; height: 72px; fill: var(--ink); margin-bottom: 28px; opacity: .9; }

/* Print -------------------------------------------------------------------- */
@media print {
	.site-header, .site-footer, .routine-side, .result-actions, .result-tabs { display: none !important; }
	body { background: #fff; color: #000; }
	.stack { padding: 0; }
}

/* =========================================================================
   v1.1 — icons, product illustrations, motion
   ========================================================================= */

.icon { width: 1.25em; height: 1.25em; flex-shrink: 0; }
.with-icon { display: flex; align-items: center; gap: 10px; }
.with-icon .icon { color: var(--teal); }
.promise.with-icon .icon { width: 1.1em; height: 1.1em; }

/* Product illustrations */
.art { display: block; overflow: visible; }
.art .art-body { fill: var(--tex, var(--gel)); }
.art .art-cap, .art .art-neck { fill: var(--ink); }
.art .art-label { fill: var(--surface); }
.art .art-ink-line { stroke: var(--ink-3); stroke-width: 2.5; stroke-linecap: round; fill: none; opacity: .7; }
.art .art-shine { fill: #fff; opacity: calc(var(--gloss) - .1); }
.art .art-shine-line { stroke: #fff; stroke-width: 4; stroke-linecap: round; fill: none; opacity: .5; }
.art-sm { width: 30px; height: 40px; }
.product-art { height: 112px; display: flex; align-items: flex-end; margin-bottom: 12px; }
.product-art .art { width: 66px; height: auto; transition: transform .25s ease; }
.product-card:hover .product-art .art { transform: translateY(-3px) rotate(-2deg); }
.product-swatch-lg { position: relative; overflow: hidden; }
.swatch-bg { position: absolute; width: 120%; inset-inline-start: -10%; bottom: 6%; opacity: .55; }
.art-lg { position: relative; width: 46%; height: auto; filter: drop-shadow(0 10px 18px rgba(34, 49, 59, .12)); }

/* Icons inside routine stacks */
.stack-title { display: flex; align-items: center; gap: 10px; }
.icon-title { color: var(--teal); width: 1em; height: 1em; }
.layer-product { display: flex; align-items: center; gap: 12px; }
.layer-product .art-sm { width: 22px; height: 30px; }
.preset-meta { display: flex; flex-wrap: wrap; gap: 6px 16px; }
.preset-meta-item { display: inline-flex; align-items: center; gap: 6px; }
.preset-meta-item .icon { width: 1.05em; height: 1.05em; color: var(--ink-3); }

/* Lift on hover for the main card types */
.preset-card, .ing-tile, .product-card, .ing-index a { transition: transform .2s ease, box-shadow .2s ease, border-color .15s ease; }
.preset-card:hover, .ing-tile:hover, .product-card:hover, .ing-index a:hover { transform: translateY(-3px); box-shadow: var(--shadow-float); }
@media (prefers-reduced-motion: reduce) {
	.preset-card:hover, .ing-tile:hover, .product-card:hover, .ing-index a:hover { transform: none; }
}

/* Hero: drifting texture swatches + product shelf */
.hero { position: relative; overflow: hidden; }
.hero-grid { position: relative; z-index: 1; }
.hero-deco .deco { position: absolute; opacity: .35; }
.deco-1 { width: 380px; top: -60px; inset-inline-end: -80px; }
.deco-2 { width: 300px; bottom: -70px; inset-inline-start: 38%; opacity: .3; }
.deco-3 { width: 160px; top: 42%; inset-inline-start: -40px; opacity: .22; }
@media (prefers-reduced-motion: no-preference) {
	.deco-1 { animation: r4u-drift 18s ease-in-out infinite alternate; }
	.deco-2 { animation: r4u-drift 22s ease-in-out -6s infinite alternate-reverse; }
	.deco-3 { animation: r4u-drift 16s ease-in-out -3s infinite alternate; }
}
@keyframes r4u-drift { from { transform: translate(0, 0) rotate(0deg); } to { transform: translate(-24px, 18px) rotate(6deg); } }

.hero-visual { display: flex; flex-direction: column; gap: 28px; min-width: 0; }
.hero-copy { min-width: 0; }
.hero-shelf { display: flex; align-items: flex-end; justify-content: space-between; gap: 4px; padding-inline-end: 9.5em; padding-bottom: 6px; border-bottom: 2px solid var(--line); }
.shelf-item { flex: 0 0 auto; display: flex; justify-content: center; }
.shelf-item .art { width: calc(78px + var(--i) * 6px); max-width: 19vw; height: auto; filter: drop-shadow(0 8px 14px rgba(34, 49, 59, .10)); }
@media (prefers-reduced-motion: no-preference) {
	.js .shelf-item { animation: r4u-rise .6s cubic-bezier(.2, .7, .2, 1) both; animation-delay: calc(var(--i) * 90ms + 150ms); }
	.js .shelf-item .art { animation: r4u-bob 5s ease-in-out infinite; animation-delay: calc(var(--i) * -900ms); }
}
@keyframes r4u-rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
@keyframes r4u-bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-5px); } }
@media (max-width: 860px) {
	.hero-visual { order: -1; max-width: 460px; width: 100%; }
	.hero-shelf { padding-inline-end: 0; }
	.shelf-item .art { width: calc(13vw + var(--i) * 1vw); max-width: 80px; }
	.hero-layer-label { width: 7.5em; }
	.deco-1 { width: 240px; }
}

/* Trust strip */
.trust { background: var(--surface); border-block: 1px solid var(--line); }
.trust-list { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; padding-block: 28px; }
.trust-list li { display: flex; align-items: flex-start; gap: 14px; }
.trust-list .icon { width: 44px; height: 44px; padding: 11px; border-radius: 50%; background: var(--water); color: var(--teal); }
.trust-list strong { display: block; font-family: var(--font-display); font-weight: 600; font-size: 1.125rem; letter-spacing: -0.01em; }
.trust-list span { display: block; font-size: var(--t-small); color: var(--ink-3); line-height: 1.45; margin-top: 2px; }
.lang-ar .trust-list strong { letter-spacing: 0; }
@media (max-width: 960px) { .trust-list { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 520px) { .trust-list { grid-template-columns: 1fr; gap: 16px; } }

/* The layering rule: scroll-driven */
.rule-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(32px, 6vw, 88px); align-items: start; }
.rule-steps { margin-top: 36px; display: flex; flex-direction: column; gap: 4px; }
.rule-step { display: flex; gap: 18px; padding: 20px; border-radius: var(--r-card); transition: background-color .3s ease, opacity .3s ease; opacity: .55; }
.rule-step.is-active { background: var(--surface); opacity: 1; box-shadow: var(--shadow-float); }
.rule-step .h4 { margin-bottom: 4px; }
.rule-step p { margin: 0; color: var(--ink-2); }
.rule-num { font-family: var(--font-display); color: var(--teal); }
.rule-art { flex-shrink: 0; width: 34px; padding-top: 2px; }
.rule-art .art-sm { width: 30px; height: 40px; }
.rule-visual { position: sticky; top: 120px; }
.skin { position: relative; aspect-ratio: 5 / 4; border-radius: 32px; background: var(--water); overflow: hidden; }
.skin-surface { position: absolute; inset: auto 0 0 0; height: 30%; background: color-mix(in srgb, var(--cream) 75%, var(--surface)); border-top: 2px solid color-mix(in srgb, var(--cream) 80%, var(--ink) 8%); }
.skin-layer {
	position: absolute; inset-inline: 8%; border-radius: 999px; background: var(--tex);
	bottom: var(--b); height: var(--hh);
	opacity: 0; transform: translateY(-24px) scaleX(.6); transition: opacity .45s ease, transform .55s cubic-bezier(.2, .7, .2, 1);
	box-shadow: 0 6px 16px rgba(34, 49, 59, .08);
}
.skin-layer.is-on { opacity: .95; transform: none; }
.skin-label { position: absolute; top: 22px; inset-inline-start: 24px; padding: 6px 14px; border-radius: var(--r-pill); background: var(--surface); font-size: var(--t-small); font-weight: 500; }
.no-js .skin-layer, .rule:not([data-ready]) .skin-layer { opacity: .95; transform: none; }
@media (max-width: 860px) {
	.rule-grid { grid-template-columns: 1fr; }
	.rule-visual { display: none; }
	.rule-step { opacity: 1; background: var(--surface); }
}

/* How it works */
.how-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; }
.how-icon .icon { width: 46px; height: 46px; padding: 11px; border-radius: 14px; background: var(--water); color: var(--teal); }
.how-num { margin: 0; background: transparent; font-size: 2.25rem; color: var(--line); width: auto; height: auto; }
.section-water .how-step { background: var(--surface); }
.section-water .how-icon .icon { background: var(--water); }

/* Morning vs evening */
.ampm { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; margin-top: 28px; }
.ampm-card { border-radius: var(--r-card); padding: clamp(24px, 4vw, 40px); position: relative; overflow: hidden; }
.ampm-card p { color: inherit; opacity: .85; max-width: 30em; }
.ampm-am { background: var(--water); }
.ampm-pm { background: var(--night-glow), var(--night); color: var(--on-night); }
.ampm-pm .h3 { color: var(--on-night); }
.ampm-icon .icon { width: 52px; height: 52px; padding: 12px; border-radius: 50%; margin-bottom: 18px; }
.ampm-am .ampm-icon .icon { background: var(--sun); color: #22313B; }
.skip-link { background: var(--btn); color: var(--on-btn); }
.ampm-pm .ampm-icon .icon { background: rgba(255, 255, 255, .12); color: var(--on-night); }
.ampm-arts { display: flex; align-items: flex-end; gap: 10px; margin-top: 20px; }
.ampm-arts .art-sm { width: 36px; height: 48px; }
.ampm-pm .art .art-cap, .ampm-pm .art .art-neck { fill: var(--on-night); }
.ampm-pm .art .art-label { fill: var(--night); }
@media (max-width: 760px) { .ampm { grid-template-columns: 1fr; } }

/* Ingredient tiles (home) and icons */
.ing-icon { display: inline-flex; }
.ing-icon .icon { width: 42px; height: 42px; padding: 10px; border-radius: 12px; background: var(--water); color: var(--teal); }
.ing-icon-lg .icon { width: 56px; height: 56px; padding: 13px; border-radius: 16px; margin-bottom: 14px; }
.ing-index .ing-icon { margin-bottom: 6px; }
.ing-tiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.ing-tile { display: flex; flex-direction: column; gap: 8px; height: 100%; background: var(--surface); border-radius: var(--r-card); padding: 20px; text-decoration: none; color: var(--ink); border: 1.5px solid transparent; }
.ing-tile:hover { border-color: var(--ink); color: var(--ink); }
.ing-tile-name { font-family: var(--font-display); font-weight: 600; font-size: 1.125rem; }
.ing-tile-for { font-size: var(--t-small); color: var(--ink-3); }

/* Final call to action */
.final-cta { background: var(--night-glow), var(--night); color: var(--on-night); padding-block: clamp(64px, 9vw, 112px); text-align: center; overflow: hidden; }
.final-inner { display: flex; flex-direction: column; align-items: center; }
.final-cta .h1 { color: var(--on-night); max-width: 16em; }
.final-cta .lead { color: var(--on-night); opacity: .8; margin-inline: auto; }
.final-arts { display: flex; align-items: flex-end; gap: 14px; margin-bottom: 32px; }
.final-arts .art { width: 54px; height: auto; }
.final-arts .art .art-cap, .final-arts .art .art-neck { fill: var(--on-night); }
.final-arts .art .art-label { fill: var(--night); }
@media (prefers-reduced-motion: no-preference) {
	.final-arts span { animation: r4u-bob 4.5s ease-in-out infinite; animation-delay: calc(var(--i) * -700ms); }
}
.btn-light { background: var(--on-night); color: var(--night); margin-top: 12px; }
.btn-light:hover { background: var(--gel-light); color: var(--night); }

/* Reveal on scroll (once) */
@media (prefers-reduced-motion: no-preference) {
	.js .reveal { opacity: 0; transform: translateY(16px); transition: opacity .6s ease, transform .6s cubic-bezier(.2, .7, .2, 1); transition-delay: calc(var(--d, 0) * 80ms); }
	.js .reveal.is-in { opacity: 1; transform: none; }
}

/* Builder: option icons and screen transitions */
.q-opt label { justify-content: flex-start; }
.q-opt label > span:first-of-type:not(.q-ico) { flex: 1; }
.q-label { flex: 1; }
.q-ico { width: 42px; height: 42px; border-radius: 12px; background: var(--water); color: var(--teal); display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; transition: background-color .15s ease, color .15s ease; }
.q-ico .icon { width: 22px; height: 22px; }
.q-opt input:checked + label .q-ico { background: var(--teal); color: var(--surface); }
@media (prefers-reduced-motion: no-preference) {
	.q-screen { animation: q-in .35s cubic-bezier(.2, .7, .2, 1) both; }
	.q-screen.is-back { animation-name: q-in-back; }
	.lang-ar .q-screen { animation-name: q-in-back; }
	.lang-ar .q-screen.is-back { animation-name: q-in; }
	.result-screen .stack, .result-screen .result-head { animation: r4u-rise .5s cubic-bezier(.2, .7, .2, 1) both; }
}
@keyframes q-in { from { opacity: 0; transform: translateX(28px); } to { opacity: 1; transform: none; } }
@keyframes q-in-back { from { opacity: 0; transform: translateX(-28px); } to { opacity: 1; transform: none; } }
.result-tabs button { display: inline-flex; align-items: center; gap: 8px; }
.result-tabs .icon { width: 1.1em; height: 1.1em; }
.builder-intro { display: flex; justify-content: center; gap: 10px; margin-bottom: 24px; }
.builder-intro .art { width: 34px; height: auto; }

/* =========================================================================
   v1.2: photography, story section, moonlight dark mode
   ========================================================================= */

/* Hero photo with a floating "your order" card */
.hero-visual { position: relative; padding-bottom: 28px; }
.hero-photo {
	margin: 0; margin-inline-start: auto; width: min(100%, 440px); aspect-ratio: 4 / 5;
	border-radius: 220px 220px 28px 28px; overflow: hidden; background: var(--cream);
	box-shadow: 0 30px 60px -30px rgba(34, 49, 59, .35);
}
.photo { display: block; width: 100%; height: 100%; object-fit: cover; }
.hero-card {
	position: absolute; inset-inline-start: 0; bottom: 0; width: min(300px, 72%);
	padding: 18px 20px 20px; border-radius: 22px;
	background: color-mix(in srgb, var(--surface) 86%, transparent);
	-webkit-backdrop-filter: blur(14px) saturate(1.2); backdrop-filter: blur(14px) saturate(1.2);
	border: 1px solid color-mix(in srgb, var(--line) 70%, transparent);
	box-shadow: var(--shadow-float);
}
.hero-card-title { display: flex; align-items: center; gap: 8px; margin: 0 0 12px; font-family: var(--font-display); font-weight: 600; font-size: var(--t-small); color: var(--ink); }
.hero-card-title .icon { color: var(--teal); width: 1.1em; height: 1.1em; }
.hero-card .hero-layers { gap: 9px; }
.hero-card .hero-layer { gap: 12px; }
.hero-card .hero-layer-label { width: 6.6em; font-size: var(--t-micro); }
@media (prefers-reduced-motion: no-preference) {
	.js .hero-photo { animation: r4u-rise .8s cubic-bezier(.2, .7, .2, 1) both; }
	.js .hero-card { animation: r4u-rise .7s cubic-bezier(.2, .7, .2, 1) .25s both; }
}
@media (max-width: 860px) {
	.hero-visual { order: 0; margin-inline: auto; padding-bottom: 0; display: block; }
	.hero-photo { width: min(82%, 340px); margin-inline: auto; }
	.hero-card { position: relative; inset: auto; margin: -64px auto 0; width: min(300px, 92%); }
}

/* Story: the problem the builder solves */
.kicker { margin: 0 0 10px; font-size: var(--t-small); font-weight: 500; color: var(--teal); letter-spacing: .02em; }
.story-photo { position: relative; margin: 0; width: min(100%, 460px); aspect-ratio: 4 / 5; border-radius: 28px; overflow: visible; }
.story-photo .photo { border-radius: 28px; box-shadow: 0 30px 60px -30px rgba(34, 49, 59, .35); }
.story-bubble {
	position: absolute; top: 9%; inset-inline-end: -18px; width: 64px; height: 64px; border-radius: 50%;
	display: flex; align-items: center; justify-content: center;
	background: var(--sun); color: #22313B; font: 600 1.9rem/1 var(--font-display);
	box-shadow: var(--shadow-float);
}
@media (prefers-reduced-motion: no-preference) {
	.story-bubble { animation: r4u-bob 4s ease-in-out infinite; }
}
.story-points { list-style: none; margin: 8px 0 28px; padding: 0; display: grid; gap: 12px; }
.story-points li { display: flex; align-items: center; gap: 12px; color: var(--ink-2); }
.story-points .icon { width: 34px; height: 34px; padding: 8px; border-radius: 50%; background: var(--surface); color: var(--teal); }
@media (max-width: 760px) {
	.story-photo { width: min(100%, 360px); margin-inline: auto; }
	.story-bubble { inset-inline-end: 8px; }
}

/* Moonlight dark mode details (only when the visitor chooses it) */
:root[data-theme="dark"] .hero { background: radial-gradient(80% 70% at 90% 10%, rgba(143, 214, 204, .10), transparent 60%), var(--water); }
:root[data-theme="dark"] .hero-photo,
:root[data-theme="dark"] .story-photo .photo { box-shadow: 0 30px 70px -28px rgba(0, 0, 0, .7), 0 0 0 1px rgba(255, 255, 255, .04); }
:root[data-theme="dark"] .skin { background: linear-gradient(180deg, #1C2633, #161E28); }
:root[data-theme="dark"] .skin-surface { background: linear-gradient(180deg, #D4A889, #9C7258); border-top-color: #E8C2A4; }
:root[data-theme="dark"] .hero-deco .deco { opacity: .16; }
:root[data-theme="dark"] .deco-2 { opacity: .08; }
:root[data-theme="dark"] .skin-layer { box-shadow: 0 0 18px -4px var(--tex); }
:root[data-theme="dark"] .layer-bar { box-shadow: 0 0 14px -6px var(--tex); }
:root[data-theme="dark"] .art,
:root[data-theme="dark"] .shelf-item .art { filter: drop-shadow(0 8px 16px rgba(0, 0, 0, .45)); }
:root[data-theme="dark"] .how-num { color: #2E3A48; }
:root[data-theme="dark"] .preset-card,
:root[data-theme="dark"] .ing-tile,
:root[data-theme="dark"] .how-step,
:root[data-theme="dark"] .ing-index a { border-color: rgba(255, 255, 255, .05); }
:root[data-theme="dark"] .preset-card:hover,
:root[data-theme="dark"] .ing-tile:hover,
:root[data-theme="dark"] .ing-index a:hover { border-color: var(--teal); }
:root[data-theme="dark"] .btn-secondary { border-color: var(--teal); color: var(--teal); }
:root[data-theme="dark"] .btn-secondary:hover { background: var(--teal); color: var(--on-btn); }
:root[data-theme="dark"] a { text-decoration-color: color-mix(in srgb, var(--teal) 60%, transparent); }
:root[data-theme="dark"] .site-header { background: color-mix(in srgb, var(--paper) 88%, transparent); }

/* Headings that receive focus from script (quiz steps) need no ring */
[tabindex="-1"]:focus { outline: none; }

/* v1.3: product photos (only when a licensed photo has been added) */
.product-photo { display: block; width: auto; max-width: 100%; height: 100%; max-height: 112px; object-fit: contain; border-radius: 12px; }
.product-photo-sm { width: 30px; height: 40px; max-height: none; object-fit: contain; border-radius: 6px; background: var(--surface); flex-shrink: 0; }
.layer-product .product-photo-sm { width: 28px; height: 36px; }
.product-swatch-lg { margin: 0; }
.product-swatch-lg.has-photo { background: #fff; flex-direction: column; gap: 6px; padding: 14px; }
.product-photo-lg { display: block; width: 100%; min-height: 0; flex: 1; object-fit: contain; border-radius: 12px; }
.photo-credit { font-size: var(--t-micro); color: var(--ink-3); }
.pv { display: contents; }
.pv .pv-art { display: none; }
.pv.pv-failed img { display: none; }
.pv.pv-failed .pv-art { display: contents; }
.product-swatch-lg .pv-art { display: none; }
.product-swatch-lg.pv-failed { background: var(--water); padding: 28px; }
.product-swatch-lg.pv-failed .product-photo-lg, .product-swatch-lg.pv-failed .photo-credit { display: none; }
.product-swatch-lg.pv-failed .pv-art { display: contents; }
/* Product photos sit on one white tile so every brand's photo looks the same */
.product-art:has(.product-photo) { height: 168px; align-items: center; justify-content: center; background: #fff; border-radius: 14px; padding: 12px; margin-bottom: 14px; }
.product-art .product-photo { height: 100%; max-height: 144px; width: 100%; object-fit: contain; border-radius: 0; }
.product-art:has(.pv-failed) { background: transparent; height: 112px; align-items: flex-end; justify-content: flex-start; padding: 0; }
.product-card:hover .product-art .product-photo { transform: translateY(-3px); transition: transform .25s ease; }
.product-photo-sm { background: #fff; padding: 2px; border-radius: 6px; }
.product-head:has(.has-photo) { grid-template-columns: 300px minmax(0, 1fr); }
.layer-product .product-photo-sm { width: 44px; height: 52px; padding: 3px; border-radius: 8px; }
@media (max-width: 700px) { .product-head:has(.has-photo) { grid-template-columns: 1fr; } .product-swatch-lg.has-photo { max-width: 240px; } }

/* === R4U routine photos (theme 1.4.0) — photo on each routine card and routine page head === */
.preset-card{overflow:hidden}
.preset-card::before{content:"";display:block;aspect-ratio:3/2;margin:-24px -24px 6px;background:var(--water,#e9f0f2) center/cover no-repeat}
html:has(link[rel="canonical"][href*="/routines/"][href$="-routine/"]) .page-head .container{display:grid;grid-template-columns:minmax(0,1fr) minmax(240px,40%);column-gap:clamp(24px,4vw,56px);align-items:center}
html:has(link[rel="canonical"][href*="/routines/"][href$="-routine/"]) .page-head .container>*{grid-column:1}
html:has(link[rel="canonical"][href*="/routines/"][href$="-routine/"]) .page-head .container::after{content:"";grid-column:2;grid-row:1/span 3;aspect-ratio:3/2;border-radius:var(--r-card,20px);background-color:var(--water,#e9f0f2);background-position:center;background-size:cover;background-repeat:no-repeat}
@media (max-width:760px){html:has(link[rel="canonical"][href*="/routines/"][href$="-routine/"]) .page-head .container{grid-template-columns:1fr}html:has(link[rel="canonical"][href*="/routines/"][href$="-routine/"]) .page-head .container::after{grid-column:1;grid-row:auto;margin-top:20px}}
.preset-card[href$="/routines/acne-prone-skin-routine/"]::before,html:has(link[rel="canonical"][href$="/routines/acne-prone-skin-routine/"]) .page-head .container::after{background-image:url(https://routine4u.com/wp-content/uploads/2026/10/routine-acne-prone-skin-routine.webp)}
.preset-card[href$="/routines/anti-aging-routine/"]::before,html:has(link[rel="canonical"][href$="/routines/anti-aging-routine/"]) .page-head .container::after{background-image:url(https://routine4u.com/wp-content/uploads/2026/10/routine-anti-aging-routine.webp)}
.preset-card[href$="/routines/budget-skincare-routine/"]::before,html:has(link[rel="canonical"][href$="/routines/budget-skincare-routine/"]) .page-head .container::after{background-image:url(https://routine4u.com/wp-content/uploads/2026/10/routine-budget-skincare-routine.webp)}
.preset-card[href$="/routines/combination-skin-routine/"]::before,html:has(link[rel="canonical"][href$="/routines/combination-skin-routine/"]) .page-head .container::after{background-image:url(https://routine4u.com/wp-content/uploads/2026/10/routine-combination-skin-routine.webp)}
.preset-card[href$="/routines/dark-spots-routine/"]::before,html:has(link[rel="canonical"][href$="/routines/dark-spots-routine/"]) .page-head .container::after{background-image:url(https://routine4u.com/wp-content/uploads/2026/10/routine-dark-spots-routine.webp)}
.preset-card[href$="/routines/dry-skin-routine/"]::before,html:has(link[rel="canonical"][href$="/routines/dry-skin-routine/"]) .page-head .container::after{background-image:url(https://routine4u.com/wp-content/uploads/2026/10/routine-dry-skin-routine.webp)}
.preset-card[href$="/routines/humid-climate-skincare-routine/"]::before,html:has(link[rel="canonical"][href$="/routines/humid-climate-skincare-routine/"]) .page-head .container::after{background-image:url(https://routine4u.com/wp-content/uploads/2026/10/routine-humid-climate-skincare-routine.webp)}
.preset-card[href$="/routines/korean-skincare-routine/"]::before,html:has(link[rel="canonical"][href$="/routines/korean-skincare-routine/"]) .page-head .container::after{background-image:url(https://routine4u.com/wp-content/uploads/2026/10/routine-korean-skincare-routine.webp)}
.preset-card[href$="/routines/mens-skincare-routine/"]::before,html:has(link[rel="canonical"][href$="/routines/mens-skincare-routine/"]) .page-head .container::after{background-image:url(https://routine4u.com/wp-content/uploads/2026/10/routine-mens-skincare-routine.webp)}
.preset-card[href$="/routines/oily-skin-routine/"]::before,html:has(link[rel="canonical"][href$="/routines/oily-skin-routine/"]) .page-head .container::after{background-image:url(https://routine4u.com/wp-content/uploads/2026/10/routine-oily-skin-routine.webp)}
.preset-card[href$="/routines/pregnancy-safe-skincare-routine/"]::before,html:has(link[rel="canonical"][href$="/routines/pregnancy-safe-skincare-routine/"]) .page-head .container::after{background-image:url(https://routine4u.com/wp-content/uploads/2026/10/routine-pregnancy-safe-skincare-routine.webp)}
.preset-card[href$="/routines/sensitive-skin-routine/"]::before,html:has(link[rel="canonical"][href$="/routines/sensitive-skin-routine/"]) .page-head .container::after{background-image:url(https://routine4u.com/wp-content/uploads/2026/10/routine-sensitive-skin-routine.webp)}
/* === end R4U routine photos === */

/* Price pages (routine4u-prices): long product names use the product title size (DESIGN.md) */
.h1.r4up-item-h1 { font-size: var(--t-h1-product); line-height: 1.2; letter-spacing: -0.02em; }
.lang-ar .h1.r4up-item-h1 { font-size: var(--t-h1-product); line-height: 1.35; letter-spacing: 0; }
