:root {
  /* ILUNUR brand palette ("Cielo de amanecer"), from the color & typography manual v1.0.
     Proportion on every screen: crema 60% · noche 30% · celeste ≤5% · coral ≤5%.
     Coral = buy buttons, cart and the flame only. Celeste = badges/details, never text on crema.
     No pure black, no cold grays, no pure white as the brand background. */
  --ilunur-noche: #1F2547;          /* primary: text, logo, dark blocks, footer */
  --ilunur-crema: #FFF8EC;          /* neutral: backgrounds */
  --ilunur-coral: #FF6F59;          /* accent: purchase actions only */
  --ilunur-coral-hover: #FF8A78;
  --ilunur-coral-active: #E85A45;
  --ilunur-celeste: #9FD8F0;        /* secondary: badges, icons, details */
  --ilunur-transicion: #FF9F1C;     /* mandarina: only inside dawn gradients/animations */
  --ilunur-line: #E4DCCB;           /* hairlines and soft shadows */

  /* Semantic aliases used across the site */
  --night: var(--ilunur-noche);
  --cream: var(--ilunur-crema);
  --ink: var(--ilunur-noche);
  --ink-soft: #4E5374;              /* muted noche for secondary text: 7.1:1 on crema */
  --surface: #FFFFFF;               /* product and content cards (manual: "tarjetas blancas o crema") */

  --font-display: "Fraunces", Georgia, "Times New Roman", serif;
  --font-sans: "Instrument Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;

  --gutter: clamp(16px, 4vw, 56px);
  --maxw: 1320px;
  --radius: 28px;
  --ease: cubic-bezier(.16, 1, .3, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 88px; -webkit-text-size-adjust: 100%; } /* clear the fixed header on anchor jumps */
body {
  margin: 0;
  background: var(--night);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; cursor: pointer; }
h1, h2, h3, p { margin: 0; }
ul, ol { list-style: none; margin: 0; padding: 0; }
em { font-style: italic; }

.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 var(--gutter); }
.skip { position: absolute; left: -9999px; top: 8px; z-index: 100; background: var(--cream); color: var(--ink); padding: 8px 14px; border-radius: 8px; }
.skip:focus { left: 8px; }
:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; box-shadow: 0 0 0 3px var(--cream); }
.site-header[data-theme="dark"] :focus-visible, .footer :focus-visible, .tested :focus-visible,
.chapters :focus-visible, .skip-story:focus-visible { outline-color: var(--cream); box-shadow: 0 0 0 3px var(--ink); }

.eyebrow { font-size: 13px; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; color: var(--ink); margin-bottom: 14px; }
.title {
  font-family: var(--font-display);
  font-weight: 600;
  font-variation-settings: "opsz" 144;
  font-size: clamp(40px, 6.4vw, 92px);
  line-height: .98;
  letter-spacing: -.02em;
}
.title em { color: var(--ink); font-weight: 500; }
.title, .line-card h3 { text-wrap: balance; }
.lead { font-size: clamp(17px, 1.4vw, 20px); color: var(--ink-soft); max-width: 46ch; margin-top: 18px; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 52px; padding: 0 26px; border-radius: 999px;
  font-weight: 600; font-size: 16px; border: 2px solid transparent;
  transition: transform .3s var(--ease), background .2s, color .2s;
}
.btn:hover { transform: translateY(-2px); }
/* Press feedback for touch and click */
.btn:active, .add-btn:active, .tab:active, .chip:active, .opt > span:active, .cart-btn:active, .qty button:active, .icon-btn:active { transform: scale(.97); transition-duration: .08s; }
.btn-ink { background: var(--ink); color: var(--cream); }
.btn-ink:hover { background: #2A315C; }
.btn-outline { border-color: var(--ink); color: var(--ink); background: transparent; }
/* The purchase button: the only coral button in a block */
.btn-buy { background: var(--ilunur-coral); color: var(--ilunur-noche); }
.btn-buy:hover { background: var(--ilunur-coral-hover); }
.btn-buy:active { background: var(--ilunur-coral-active); }
.btn-outline:hover { background: var(--ink); color: var(--cream); }
.full { width: 100%; }
.btn:disabled { opacity: .45; cursor: not-allowed; transform: none; }

/* ============ HEADER ============ */
.site-header {
  position: fixed; inset: 0 0 auto; z-index: 40;
  transition: background .4s, color .4s, box-shadow .4s;
}
.site-header[data-theme="dark"] { color: var(--cream); }
.site-header[data-theme="clear"] { color: var(--ink); }
.site-header[data-theme="light"] { color: var(--ink); background: rgba(255,248,236,.92); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); box-shadow: 0 1px 0 var(--ilunur-line); }
.nav { height: 72px; display: flex; align-items: center; gap: 32px; }
.logo { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; font-family: var(--font-display); font-weight: 700; font-size: 24px; letter-spacing: .14em; }
/* The ILUNUR logo (isotipo over lettering). One white PNG used as a stencil and painted with currentColor,
   so it is crema on dark and azul noche on light, the only two colors the manual allows. */
.brand-logo {
  display: block; aspect-ratio: 2899 / 1104; background: currentColor;
  -webkit-mask: url("assets/brand/logo-full.png") center / contain no-repeat;
          mask: url("assets/brand/logo-full.png") center / contain no-repeat;
}
.logo-iso { height: 40px; width: auto; flex: none; }  /* the menu shows only the isotipo; the full logo lives on the opening screen */
/* Compact version for the menu: the lettering alone (the isotipo would be too small to read at menu size) */
.logo-mark {
  height: 26px; aspect-ratio: 2899 / 531;
  -webkit-mask-image: url("assets/brand/logo-lettering.png"); mask-image: url("assets/brand/logo-lettering.png");
}
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.nav-links { display: flex; gap: 28px; margin-left: auto; font-weight: 500; font-size: 15px; }
.nav-links a { display: inline-flex; align-items: center; min-height: 44px; opacity: .85; transition: opacity .2s; }
.nav-links a:hover { opacity: 1; }
.cart-btn {
  display: inline-flex; align-items: center; gap: 10px; min-height: 44px; padding: 0 18px;
  border-radius: 99px; border: 0; background: var(--ilunur-coral); color: var(--ilunur-noche); font-weight: 600;
  transition: background .2s;
}
.cart-btn:hover { background: var(--ilunur-coral-hover); }
.cart-count {
  min-width: 24px; height: 24px; padding: 0 6px; border-radius: 99px;
  display: inline-grid; place-items: center; font-size: 13px;
  background: var(--ilunur-noche); color: var(--ilunur-crema);
}
.cart-count.bump { animation: bump .5s var(--ease); }
@keyframes bump { 40% { transform: scale(1.35); } }
@media (max-width: 760px) {
  .nav-links { display: none; }
  .cart-btn { margin-left: auto; }
}

/* ============ HERO ============ */
.hero { position: relative; height: 260vh; background: var(--night); }
.stage { position: sticky; top: 0; height: 100vh; height: 100svh; overflow: hidden; }
.stage { background: var(--ilunur-noche); }
/* The footage has a pure black background, so it can fill the screen or float on black seamlessly */
.hero-video {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; pointer-events: none;
}
@media (max-aspect-ratio: 1/1) {
  /* Portrait screens: size the clip so the glass spans most of the width; the cropped sides are black */
  .hero-video { inset: auto; left: 50%; top: 50%; width: 200%; height: auto; aspect-ratio: 16 / 9;
    transform: translate(-50%, -50%);
    -webkit-mask-image: linear-gradient(180deg, transparent 0, #000 12%, #000 88%, transparent 100%);
            mask-image: linear-gradient(180deg, transparent 0, #000 12%, #000 88%, transparent 100%); }
}
/* The footage's pure black becomes azul noche ("lighten" keeps whichever is brighter per pixel,
   so the candle itself is untouched). The brand never uses pure black. */
.hero-night {
  position: absolute; inset: 0; pointer-events: none;
  mix-blend-mode: lighten; background: var(--ilunur-noche);
}
/* The sunrise on the sides of the frame: night → celeste → coral → crema, the manual's story.
   Masked away from the center so it never tints the candle. */
.hero-dawn {
  position: absolute; inset: 0; pointer-events: none; opacity: 0; mix-blend-mode: lighten; will-change: opacity;
  background: linear-gradient(180deg, #9FD8F0 0, #BFDDE8 30%, #F4DCCF 58%, #FFEEDF 78%, #FFF8EC 100%);
  /* --gl is the glass's left edge on screen (JS): the sky stops right at the candle's silhouette */
  -webkit-mask-image: linear-gradient(90deg, #000 0, #000 calc(var(--gl, 20%) - 14px), transparent var(--gl, 20%), transparent calc(100% - var(--gl, 20%)), #000 calc(100% - var(--gl, 20%) + 14px));
          mask-image: linear-gradient(90deg, #000 0, #000 calc(var(--gl, 20%) - 14px), transparent var(--gl, 20%), transparent calc(100% - var(--gl, 20%)), #000 calc(100% - var(--gl, 20%) + 14px));
}
@media (max-aspect-ratio: 1/1) {
  /* Portrait: the candle fills the width, so the sky shows above and below the clip instead */
  .hero-dawn {
    -webkit-mask-image: linear-gradient(180deg, #000 0, #000 calc(var(--gt, 20%) + 10px), transparent calc(var(--gt, 20%) + 70px), transparent calc(var(--gb, 80%) - 70px), #000 calc(var(--gb, 80%) - 10px));
            mask-image: linear-gradient(180deg, #000 0, #000 calc(var(--gt, 20%) + 10px), transparent calc(var(--gt, 20%) + 70px), transparent calc(var(--gb, 80%) - 70px), #000 calc(var(--gb, 80%) - 10px));
  }
}
/* Candlelight centered on the real flame (JS moves it with the footage and makes it flicker).
   Mandarina only ever appears inside this light. */
.hero-glow {
  position: absolute; left: -120vmax; top: -120vmax; width: 240vmax; height: 240vmax;
  pointer-events: none; opacity: 0; mix-blend-mode: lighten; will-change: transform, opacity;
  background: radial-gradient(circle closest-side, rgba(255,159,28,.62) 0, rgba(255,111,89,.5) 15%, rgba(255,111,89,.18) 33%, rgba(31,37,71,0) 60%);
}
/* Soft rays turning slowly around the flame */
.hero-rays {
  position: absolute; left: -80vmax; top: -80vmax; width: 160vmax; height: 160vmax;
  pointer-events: none; opacity: 0; mix-blend-mode: screen; will-change: transform, opacity;
}
.hero-rays i {
  position: absolute; inset: 0; border-radius: 50%; filter: blur(14px);
  background: conic-gradient(from 0deg, rgba(255,159,28,0) 0deg, rgba(255,159,28,.16) 9deg, rgba(255,159,28,0) 22deg, rgba(255,111,89,0) 58deg, rgba(255,111,89,.13) 66deg, rgba(255,111,89,0) 81deg, rgba(255,159,28,0) 117deg, rgba(255,159,28,.18) 128deg, rgba(255,159,28,0) 139deg, rgba(255,111,89,0) 176deg, rgba(255,111,89,.12) 186deg, rgba(255,111,89,0) 203deg, rgba(255,159,28,0) 240deg, rgba(255,159,28,.15) 249deg, rgba(255,159,28,0) 262deg, rgba(255,111,89,0) 300deg, rgba(255,111,89,.14) 311deg, rgba(255,111,89,0) 328deg, rgba(255,159,28,0) 360deg);
  -webkit-mask-image: radial-gradient(circle closest-side, #000 0, rgba(0,0,0,.55) 22%, transparent 62%);
          mask-image: radial-gradient(circle closest-side, #000 0, rgba(0,0,0,.55) 22%, transparent 62%);
  animation: rays-turn 90s linear infinite;
}
@keyframes rays-turn { to { transform: rotate(360deg); } }
.hero-fx { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
/* The closing transition: a cream wash rises from the bottom so the milky base of the candle
   dissolves into the page background, which is the same cream */
.hero-fade {
  position: absolute; inset: 0; pointer-events: none; will-change: transform;
  background: linear-gradient(0deg, var(--cream) 0, var(--cream) 22%, rgba(255,248,236,.75) 42%, rgba(255,248,236,0) 72%);
  transform: translateY(100%);
}
/* Dark wash at the bottom keeps the story lines readable over the footage */
.hero-scrim {
  position: absolute; inset: auto 0 0; height: 40%; pointer-events: none;
  background: linear-gradient(0deg, rgba(31,37,71,.85), rgba(31,37,71,0));
}

.wordmark {
  position: absolute; left: 0; right: 0; top: 40%;
  text-align: center; color: var(--cream); will-change: opacity, transform;
}
/* The logo's artwork is untouched: it is simply revealed by light spreading from its own spark */
@property --logo-r { syntax: "<percentage>"; inherits: false; initial-value: 170%; }
.wordmark-logo { box-sizing: content-box; width: clamp(260px, 50vw, 700px); padding: 48px; margin: -48px auto; }
.logo-stack {
  position: relative; display: block; margin: -48px; padding: 48px;
  -webkit-mask-image: radial-gradient(circle at 52.5% 12%, #000 var(--logo-r), transparent calc(var(--logo-r) + 22%));
          mask-image: radial-gradient(circle at 52.5% 12%, #000 var(--logo-r), transparent calc(var(--logo-r) + 22%));
  animation: logo-ignite 2.1s cubic-bezier(.3, .7, .25, 1) .55s both;
}
@keyframes logo-ignite { from { --logo-r: 0%; } to { --logo-r: 170%; } }
.logo-stack .brand-logo { width: 100%; color: var(--ilunur-crema); filter: drop-shadow(0 0 30px rgba(255,111,89,.3)); }
/* Slow breathing light behind the logo */
.logo-aura {
  position: absolute; left: 50%; top: 50%; width: 92%; height: 118%; transform: translate(-50%, -50%);
  background: radial-gradient(ellipse closest-side, rgba(255,111,89,.2), rgba(255,111,89,0));
  animation: aura-breathe 5.5s ease-in-out infinite;
}
@keyframes aura-breathe { 0%, 100% { opacity: .45; } 50% { opacity: 1; } }
/* The spark on the logo catches first, then twinkles now and then */
.logo-flare {
  position: absolute; left: calc(48px + (100% - 96px) * .525); top: calc(48px + (100% - 96px) * .072);
  width: clamp(70px, 11vw, 150px); aspect-ratio: 1; transform: translate(-50%, -50%) scale(0);
  background:
    radial-gradient(circle closest-side, #FFF8EC 0, rgba(255,214,170,.75) 9%, rgba(255,111,89,.28) 28%, rgba(255,111,89,0) 62%),
    linear-gradient(90deg, rgba(255,248,236,0) 2%, #FFF8EC 50%, rgba(255,248,236,0) 98%) center / 100% 2px no-repeat,
    linear-gradient(0deg, rgba(255,248,236,0) 2%, #FFF8EC 50%, rgba(255,248,236,0) 98%) center / 2px 100% no-repeat;
  animation: flare-catch 1.5s ease-out .35s both, flare-twinkle 6.5s ease-in-out 3s infinite;
}
@keyframes flare-catch { 0% { transform: translate(-50%, -50%) scale(0) rotate(-30deg); opacity: 0; } 35% { transform: translate(-50%, -50%) scale(1.25) rotate(0); opacity: 1; } 100% { transform: translate(-50%, -50%) scale(.42) rotate(10deg); opacity: .75; } }
@keyframes flare-twinkle { 0%, 72%, 100% { transform: translate(-50%, -50%) scale(.42) rotate(10deg); opacity: .75; } 80% { transform: translate(-50%, -50%) scale(.82) rotate(34deg); opacity: 1; } 90% { transform: translate(-50%, -50%) scale(.36) rotate(52deg); opacity: .6; } }
.wordmark p { margin-top: 26px; font-size: 13px; letter-spacing: .3em; text-transform: uppercase; color: rgba(255,248,236,.82); }
.wordmark p span { display: inline-block; animation: word-rise 1.1s var(--ease) both; animation-delay: calc(1.5s + var(--i) * .11s); }
@keyframes word-rise { from { opacity: 0; transform: translateY(10px); } }

.flicker { transform-box: fill-box; transform-origin: 50% 100%; animation: flicker 2.6s ease-in-out infinite; }
@keyframes flicker {
  0%, 100% { transform: scale(1, 1) skewX(0deg); }
  20% { transform: scale(.97, 1.04) skewX(1.5deg); }
  45% { transform: scale(1.02, .96) skewX(-1deg); }
  70% { transform: scale(.98, 1.03) skewX(1deg); }
}

/* Story lines light up word by word (JS). Wide screens: large, in the dark beside the candle.
   Narrow screens: centered under the candle. */
.chapters { position: absolute; inset: 0; pointer-events: none; }
.chapter {
  position: absolute; left: var(--gutter); right: var(--gutter); bottom: 7vh; text-align: center;
  font-family: var(--font-display); font-weight: 400; font-style: italic;
  font-size: clamp(25px, 6.6vw, 36px); line-height: 1.16; color: var(--cream);
  opacity: 0; will-change: opacity, translate; text-wrap: balance;
}
.chapter .w { display: inline-block; opacity: 0; will-change: opacity, transform; }
@media (min-aspect-ratio: 5/4) {
  .chapter {
    top: 50%; bottom: auto; transform: translateY(-50%); width: min(25vw, 460px); right: auto; text-align: left;
    font-size: clamp(30px, 3.5vw, 60px); line-height: 1.08; letter-spacing: -.01em; font-variation-settings: "opsz" 144;
  }
  .chapter br { display: none; }
  .chapter:nth-child(1) { top: 44%; }
  /* Line 2 sits up in the dark, above the glass rim */
  .chapter:nth-child(2) { left: auto; right: var(--gutter); top: 15%; transform: none; text-align: right; width: min(27vw, 500px); }
  /* Line 3: the candle fills the frame, so it runs along the bottom on the shade */
  .chapter:nth-child(3) {
    top: auto; bottom: 8vh; right: var(--gutter); transform: none; width: auto; text-align: center;
    font-size: clamp(28px, 3vw, 50px); line-height: 1.12;
  }
  .chapter:nth-child(3) br { display: inline; }
}
.scroll-cue {
  position: absolute; left: 50%; bottom: 28px; transform: translateX(-50%);
  display: flex; flex-direction: column; align-items: center; gap: 10px;
  color: var(--cream); font-size: 11px; letter-spacing: .3em; text-transform: uppercase;
  animation: cue-in 1.2s ease 2.5s both;
}
@keyframes cue-in { from { opacity: 0; } }
.scroll-cue i { position: relative; width: 1px; height: 46px; background: linear-gradient(rgba(255,248,236,.55), rgba(255,248,236,.05)); }
.scroll-cue i::after {
  content: ""; position: absolute; left: 50%; top: 0; width: 5px; height: 5px; margin-left: -2.5px; border-radius: 50%;
  background: #FFF8EC; box-shadow: 0 0 10px 3px rgba(255,111,89,.85);
  animation: cue-spark 2.2s cubic-bezier(.55, 0, .35, 1) infinite;
}
@keyframes cue-spark { 0% { transform: translateY(0); opacity: 0; } 15% { opacity: 1; } 85% { opacity: 1; } 100% { transform: translateY(44px); opacity: 0; } }
/* A soft shade keeps the menu readable when the footage passes behind it */
.site-header::before {
  content: ""; position: absolute; inset: 0 0 -40px; z-index: -1; pointer-events: none; opacity: 0;
  background: linear-gradient(180deg, rgba(31,37,71,.72), rgba(31,37,71,0)); transition: opacity .4s;
}
.site-header[data-theme="dark"]::before { opacity: 1; }
/* The menu arrives after the logo has lit */
.site-header { animation: header-in 1.1s ease 1.7s both; }
@keyframes header-in { from { opacity: 0; } }

.skip-story {
  position: absolute; right: var(--gutter); bottom: 22px; z-index: 2;
  display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 16px;
  border-radius: 99px; color: var(--cream); font-size: 14px; font-weight: 600;
  background: rgba(255,248,236,.08); border: 1px solid rgba(255,248,236,.28);
  transition: background .2s, opacity .3s;
}
.skip-story:hover { background: rgba(255,248,236,.18); }
.story-progress { position: absolute; left: 0; right: 0; top: 0; height: 3px; z-index: 41; }
.story-progress i { display: block; height: 100%; width: 100%; transform-origin: left; transform: scaleX(0);
  background: linear-gradient(90deg, var(--ilunur-coral), var(--ilunur-transicion), var(--ilunur-celeste)); }

@media (max-width: 700px) {
  .hero { height: 230vh; }
  .skip-story { bottom: auto; top: 84px; right: 16px; }
  .scroll-cue { bottom: 20px; }
  .wordmark p { letter-spacing: .18em; font-size: 11px; }
}

/* ============ LINES ============ */
.lines { position: relative; background: var(--cream); padding: clamp(48px, 6vw, 80px) 0 clamp(72px, 9vw, 120px); margin-top: -2px; /* overlap the hero by 2px so no seam shows */ }
.line-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-top: 48px; }
.line-card {
  position: relative; display: flex; flex-direction: column; gap: 14px;
  min-height: 340px; padding: clamp(28px, 3vw, 44px); border-radius: var(--radius);
  overflow: hidden; transition: transform .5s var(--ease);
}
.line-card:hover { transform: translateY(-6px) rotate(-.4deg); }
.line-card.night { background: var(--ilunur-noche); color: var(--ilunur-crema); }
.line-card.light { background: var(--surface); color: var(--ink); box-shadow: inset 0 0 0 1px var(--ilunur-line); }
.line-card h3 { font-family: var(--font-display); font-weight: 600; font-size: clamp(34px, 4vw, 56px); line-height: 1; letter-spacing: -.01em; }
.line-card p { max-width: 38ch; font-size: 17px; }
.line-card .tag { align-self: flex-start; padding: 6px 12px; border-radius: 99px; background: var(--ilunur-celeste); color: var(--ilunur-noche); font-size: 12px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; }
.line-card .arrow { margin-top: auto; font-weight: 700; }
@media (max-width: 760px) { .line-cards { grid-template-columns: 1fr; } .line-card { min-height: 280px; } }

/* ============ SHOP ============ */
.shop { background: var(--cream); padding: clamp(56px, 7vw, 96px) 0 clamp(80px, 10vw, 140px); }
.shop-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 24px; }
.tabs { display: flex; flex-wrap: wrap; gap: 8px; }
.tab {
  min-height: 44px; padding: 0 20px; border-radius: 99px;
  border: 1.5px solid var(--ink); background: transparent; font-weight: 600;
  transition: background .2s, color .2s;
}
.tab:hover { background: rgba(31,37,71,.06); }
.tab.is-active { background: var(--ink); color: var(--cream); }
.hint { margin-top: 18px; color: var(--ink-soft); font-size: 14px; }
.products { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 22px; margin-top: 28px; }
.product { display: flex; flex-direction: column; animation: rise .6s var(--ease) both; animation-delay: var(--d, 0s); }
@keyframes rise { from { opacity: 0; transform: translateY(18px); } }
.product-art {
  position: relative; aspect-ratio: 4 / 5; border-radius: var(--radius);
  background: var(--surface); box-shadow: inset 0 0 0 1px var(--ilunur-line); display: grid; place-items: center; overflow: hidden;
  transition: background .5s, box-shadow .5s;
}
.product-art::before {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(circle at 50% 28%, rgba(255,111,89,.22), rgba(255,111,89,0) 55%);
  opacity: 0; transition: opacity .5s;
}
.product-art svg { position: relative; width: 74%; height: auto; overflow: visible; transition: transform .6s var(--ease); }
.product-art .card-flame { opacity: 0; transform: scale(.2); transform-box: fill-box; transform-origin: 50% 100%; transition: opacity .3s, transform .5s var(--ease); }
.product:hover .product-art::before, .product:focus-within .product-art::before, .product.is-lit .product-art::before { opacity: 1; }
.product:hover .card-flame, .product:focus-within .card-flame, .product.is-lit .card-flame { opacity: 1; transform: scale(1); }
.product:hover .product-art svg { transform: translateY(-4px) scale(1.03); }
.badge {
  position: absolute; top: 16px; left: 16px; z-index: 1;
  padding: 6px 12px; border-radius: 99px; background: var(--ilunur-celeste); color: var(--ilunur-noche);
  font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
}
.product-info { display: grid; grid-template-columns: 1fr auto; gap: 4px 12px; padding: 16px 4px 0; }
.product-info h3 { font-family: var(--font-display); font-weight: 600; font-size: 22px; line-height: 1.15; }
.product-info .price { font-weight: 700; font-size: 17px; }
.product-info .notes { grid-column: 1 / -1; color: var(--ink-soft); font-size: 14px; }
.add-btn {
  margin-top: 14px; min-height: 48px; border-radius: 99px;
  border: 0; background: var(--ilunur-coral); color: var(--ilunur-noche); font-weight: 600;
  transition: background .2s;
}
.add-btn:hover { background: var(--ilunur-coral-hover); }
.add-btn:active { background: var(--ilunur-coral-active); }
.add-btn:disabled { opacity: .45; cursor: not-allowed; }
.add-btn:disabled, .add-btn:disabled:hover { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--ilunur-line); }
.product-art img { position: relative; width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease); }
.product:hover .product-art img { transform: scale(1.03); }
.product.is-out .product-art > svg, .product.is-out .product-art > img { opacity: .5; filter: grayscale(.4); }
.badge-out { background: var(--ink); color: var(--cream); }
.badge-low { background: var(--ilunur-celeste); color: var(--ilunur-noche); }
.sku { font-weight: 600; color: var(--ink-soft); font-size: .85em; letter-spacing: .02em; }

/* ============ MOMENTS: personalization studio ============ */
.moments { position: relative; background: var(--cream); padding: clamp(80px, 10vw, 140px) 0; overflow: hidden; }
.moments-head { max-width: 760px; }
.occasions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 24px; }
.chip {
  min-height: 44px; padding: 0 18px; border-radius: 99px; border: 1.5px solid var(--ink);
  background: transparent; color: var(--ink); font-weight: 600; transition: background .2s, color .2s;
}
.chip:hover { background: rgba(31,37,71,.06); }
.chip.is-active { background: var(--ink); color: var(--cream); }

.studio { display: grid; grid-template-columns: 1.1fr 1fr; gap: clamp(20px, 3vw, 40px); margin-top: 48px; align-items: start; }
.studio-view {
  position: sticky; top: 92px;
  border-radius: var(--radius); overflow: hidden; aspect-ratio: 1 / 1;
  background:
    radial-gradient(ellipse 60% 50% at 50% 30%, rgba(255,111,89,.16), rgba(255,111,89,0) 70%),
    linear-gradient(180deg, #262c52 0%, var(--ilunur-noche) 60%);
  box-shadow: 0 30px 60px rgba(31,37,71,.18);
}
/* The gift box is night blue, so its preview sits on a light, photo-studio backdrop */
.studio-view[data-mode="box"] { background: radial-gradient(ellipse 70% 60% at 50% 40%, #FFFFFF 0, var(--ilunur-crema) 55%, #F1E8D8 100%); }
.studio-view[data-mode="box"] .view-tabs { background: rgba(31,37,71,.08); }
.studio-view[data-mode="box"] .view-tabs button { color: var(--ink); }
.studio-view[data-mode="box"] .view-tabs button[aria-selected="true"] { background: var(--ink); color: var(--cream); }
.studio-view[data-mode="box"] .studio-hint { color: var(--ink-soft); }
.studio-canvas { display: block; width: 100%; height: 100%; touch-action: pan-y; cursor: grab; }
.studio-canvas:active { cursor: grabbing; }
.view-tabs { position: absolute; top: 16px; left: 50%; transform: translateX(-50%); z-index: 1; display: flex; gap: 4px; padding: 4px; border-radius: 99px; background: rgba(255,248,236,.1); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
.view-tabs button { min-height: 40px; padding: 0 16px; white-space: nowrap; border: 0; border-radius: 99px; background: transparent; color: var(--cream); font-weight: 600; font-size: 14px; }
.view-tabs button[aria-selected="true"] { background: var(--cream); color: var(--ink); }
.studio-hint { position: absolute; bottom: 14px; left: 0; right: 0; text-align: center; font-size: 13px; color: rgba(255,248,236,.7); pointer-events: none; transition: opacity .6s; }

.studio-form fieldset { border: 0; margin: 0 0 22px; padding: 22px; border-radius: 20px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--ilunur-line); }
.studio-form legend { float: left; width: 100%; display: flex; align-items: center; gap: 10px; margin-bottom: 14px; font-family: var(--font-display); font-weight: 600; font-size: 20px; }
.studio-form legend + * { clear: both; }
.step { display: inline-grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--ilunur-celeste); color: var(--ink); font-family: var(--font-sans); font-size: 14px; font-weight: 700; }
.studio-form label:not(.opt):not(.check-row), .studio-form .label { display: flex; justify-content: space-between; margin: 14px 0 6px; font-weight: 600; font-size: 14px; }
.studio-form input[type=text], .studio-form input[type=date] {
  width: 100%; min-height: 48px; padding: 0 14px; border: 1.5px solid #C9C2B3; border-radius: 12px;
  background: var(--surface); color: var(--ink); font: inherit; font-size: 16px;
}
.studio-form input:focus-visible { border-color: var(--ink); }
.studio-form input[aria-invalid="true"] { border-color: var(--ilunur-coral-active); }
.count { font-weight: 500; color: var(--ink-soft); font-variant-numeric: tabular-nums; }
.help { margin-top: 6px; font-size: 13px; color: var(--ink-soft); }
.seg { display: flex; flex-wrap: wrap; gap: 8px; }
.opt { position: relative; }
.opt input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.opt > span { display: inline-grid; place-items: center; min-width: 48px; min-height: 48px; padding: 0 14px; border-radius: 12px; box-shadow: inset 0 0 0 1.5px var(--ilunur-line); font-weight: 600; transition: box-shadow .2s, background .2s; }
.opt input:checked + span { background: rgba(159,216,240,.35); box-shadow: inset 0 0 0 2px var(--ink); }
.opt input:focus-visible + span { outline: 3px solid var(--ink); outline-offset: 2px; }
.opt svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.motifs span { font-size: 20px; }
.f-script { font-family: "Caveat", cursive; font-size: 22px; font-weight: 700; }
.f-serif { font-family: var(--font-display); font-style: italic; font-size: 17px; }
.f-sans { font-family: var(--font-sans); letter-spacing: .08em; text-transform: uppercase; font-size: 13px; }
.check-row { display: flex; align-items: center; gap: 10px; min-height: 44px; font-weight: 600; }
.check-row input { width: 22px; height: 22px; accent-color: var(--ink); }

.candle-pick { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.candle-pick .opt > span { display: flex; justify-content: flex-start; gap: 10px; width: 100%; min-height: 64px; padding: 8px 12px; text-align: left; font-weight: 600; }
.candle-pick .opt svg { width: 40px; height: 48px; flex: none; fill: initial; stroke: none; overflow: visible; }
.candle-pick small { display: block; font-weight: 500; color: var(--ink-soft); }

.studio-total { padding: 22px; border-radius: 20px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--ilunur-line); }
.total-line { display: flex; justify-content: space-between; font-size: 15px; color: var(--ink-soft); }
.total-line + .total-line { margin-top: 6px; }
.total-line.total { margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--ilunur-line); color: var(--ink); font-size: 18px; }
.made-to-order { display: flex; align-items: center; gap: 8px; margin: 14px 0 4px; font-weight: 600; font-size: 14px; }
.made-to-order svg { width: 20px; height: 20px; fill: none; stroke: var(--ink); stroke-width: 2; stroke-linecap: round; }
@media (max-width: 900px) {
  .studio { grid-template-columns: 1fr; }
  .studio-view { position: relative; top: 0; aspect-ratio: 4 / 3.4; }
}
@media (max-width: 420px) { .candle-pick { grid-template-columns: 1fr; } .view-tabs button { padding: 0 12px; font-size: 13px; } }

/* Cart: personalized lines */
.custom-tag { display: inline-block; margin: 2px 0 4px; padding: 2px 8px; border-radius: 99px; background: var(--ilunur-celeste); font-size: 11px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }
.custom-sum { font-size: 13px; color: var(--ink-soft); line-height: 1.4; }
.unit .muted { font-size: 12px; }

/* ============ LIFE: floating light motes + scroll reveals ============ */
/* Tiny coral and celeste "sparks" drifting upward in the cream sections, like light leaving the flame.
   Kept sparse and small so the accents stay within the brand's 5% + 5%. */
.motes { position: absolute; inset: 0; pointer-events: none; overflow: hidden; z-index: 0; }
.motes i {
  position: absolute; bottom: -20px; width: var(--s); height: var(--s); border-radius: 50%;
  background: var(--c); opacity: 0; filter: blur(.4px);
  animation: mote var(--d) linear infinite; animation-delay: var(--delay);
}
.motes i.ring { background: transparent; box-shadow: inset 0 0 0 1.5px var(--c); }
@keyframes mote {
  0% { transform: translate3d(0, 0, 0); opacity: 0; }
  12% { opacity: var(--o); }
  85% { opacity: var(--o); }
  100% { transform: translate3d(var(--dx), -110vh, 0); opacity: 0; }
}
.lines > .container, .shop > .container, .moments > .container, .newsletter > .container { position: relative; z-index: 1; }
.shop, .newsletter { position: relative; overflow: hidden; }

.reveal { opacity: 0; transform: translateY(28px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
.reveal.is-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .motes { display: none; }
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* ============ HOW WE TEST ============ */
/* Manual: noche background, crema text, celeste for icons and figures */
.tested { background: var(--ilunur-noche); color: var(--ilunur-crema); padding: clamp(80px, 10vw, 130px) 0; }
.tested .eyebrow { color: var(--ilunur-celeste); }
.tested .title em { color: var(--ilunur-celeste); }
.tested .lead { color: rgba(255,248,236,.85); }
.tested-head { max-width: 720px; }
.tests { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; margin-top: 56px; counter-reset: none; }
.tests li { padding: 28px 24px; border-radius: var(--radius); background: rgba(255,248,236,.05); box-shadow: inset 0 0 0 1px rgba(255,248,236,.12); }
.tests svg { width: 44px; height: 44px; fill: none; stroke: var(--ilunur-celeste); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.tests .figure { display: block; margin-top: 22px; font-family: var(--font-display); font-weight: 600; font-size: clamp(26px, 2.4vw, 34px); line-height: 1.1; color: var(--ilunur-celeste); }
.tests h3 { margin-top: 6px; font-size: 18px; font-weight: 700; }
.tests p { margin-top: 8px; font-size: 15px; color: rgba(255,248,236,.82); }
.tested-note { margin-top: 32px; font-size: 15px; color: rgba(255,248,236,.85); }
@media (max-width: 960px) { .tests { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .tests { grid-template-columns: 1fr; } .tests li { display: grid; grid-template-columns: 44px 1fr; column-gap: 16px; } .tests li > :not(svg) { grid-column: 2; } .tests .figure { margin-top: 0; } }

/* ============ NEWSLETTER ============ */
.newsletter { background: var(--cream); box-shadow: inset 0 1px 0 var(--ilunur-line); padding: clamp(80px, 10vw, 130px) 0; }
.newsletter .lead { color: var(--ink); }
.news-grid { display: grid; grid-template-columns: 1.1fr 1fr; gap: 40px; align-items: end; }
.news-form label { display: block; font-weight: 600; margin-bottom: 10px; }
.news-row { display: flex; gap: 10px; }
.news-row input {
  flex: 1; min-width: 0; min-height: 52px; padding: 0 20px; border-radius: 99px;
  border: 2px solid var(--ink); background: var(--surface); color: var(--ink); font: inherit;
}
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; } /* bot trap */
.form-msg { min-height: 24px; margin-top: 10px; font-weight: 600; }
@media (max-width: 760px) { .news-grid { grid-template-columns: 1fr; } .news-row { flex-direction: column; } }

/* ============ FOOTER ============ */
.footer { background: var(--night); color: var(--cream); padding-top: 80px; text-align: center; overflow: hidden; }
.footer-iso { display: block; height: 92px; width: auto; margin: 36px auto 18px; color: var(--ilunur-crema); filter: drop-shadow(0 0 26px rgba(255,111,89,.3)); }
.footer-line { margin-top: 18px; font-family: var(--font-display); font-style: italic; font-size: clamp(22px, 2.4vw, 32px); }

.footer-row { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px; padding-top: 28px; padding-bottom: 32px; font-size: 14px; }
.footer-row ul { display: flex; flex-wrap: wrap; gap: 4px 20px; }
.footer-row a { display: inline-flex; align-items: center; min-height: 44px; }
.footer-row a { color: var(--ilunur-celeste); }
.footer-row a:hover { text-decoration: underline; }

/* ============ CART ============ */
.scrim { position: fixed; inset: 0; z-index: 60; background: rgba(31,37,71,.55); opacity: 0; transition: opacity .25s; }
.scrim.show { opacity: 1; transition-duration: .45s; }
.cart {
  position: fixed; top: 0; right: 0; bottom: 0; z-index: 70;
  width: min(440px, 100%); background: var(--cream); color: var(--ink);
  display: flex; flex-direction: column;
  transform: translateX(100%); transition: transform .28s cubic-bezier(.4, 0, 1, 1);
}
.cart.open { transform: none; transition: transform .45s var(--ease); }
.cart-head { display: flex; justify-content: space-between; align-items: center; padding: 22px 24px; border-bottom: 1px solid rgba(31,37,71,.1); }
.cart-head h2 { font-family: var(--font-display); font-size: 28px; font-weight: 600; }
.icon-btn { width: 44px; height: 44px; border-radius: 50%; border: 0; background: rgba(31,37,71,.06); font-size: 24px; line-height: 1; }
.icon-btn:hover { background: rgba(31,37,71,.12); }
.ship .bar { height: 6px; margin-top: 8px; border-radius: 99px; background: rgba(31,37,71,.1); overflow: hidden; }
.ship { background: var(--surface); margin: 12px 24px 0; padding: 14px 16px; font-size: 14px; border-radius: 16px; box-shadow: inset 0 0 0 1px var(--ilunur-line); }
.ship p { font-weight: 600; }
.ship .bar { height: 8px; }
.ship .bar i { display: block; height: 100%; width: 0; border-radius: 99px; background: var(--ilunur-celeste); transition: width .6s var(--ease); }
.ship.is-free .bar i { background: linear-gradient(90deg, var(--ilunur-celeste), var(--ilunur-coral)); } /* goal reached: the bar "lights up" */
.cart-items { flex: 1; overflow-y: auto; padding: 4px 24px; }
.cart-empty { padding: 40px 0; text-align: center; color: var(--ink-soft); }
.cart-item { display: grid; grid-template-columns: 76px 1fr auto; gap: 14px; align-items: center; padding: 14px 0; border-bottom: 1px solid rgba(31,37,71,.08); }
.cart-thumb { width: 76px; height: 76px; border-radius: 16px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--ilunur-line); display: grid; place-items: center; }
.cart-thumb svg { width: 70%; height: auto; overflow: visible; }
.cart-thumb { overflow: hidden; }
.cart-thumb img { width: 100%; height: 100%; object-fit: cover; }
.qty button:disabled { opacity: .35; cursor: not-allowed; }
.ship[hidden] { display: none; }
.cart-item h3 { font-family: var(--font-display); font-size: 17px; font-weight: 600; line-height: 1.2; }
.cart-item .unit { font-size: 13px; color: var(--ink-soft); }
.qty { display: inline-flex; align-items: center; margin-top: 8px; border: 1.5px solid rgba(31,37,71,.25); border-radius: 99px; }
.qty button { width: 44px; height: 44px; border: 0; background: none; font-size: 18px; }
.qty output { min-width: 22px; text-align: center; font-weight: 600; }
.cart-item .line { text-align: right; font-weight: 700; }
.remove { display: inline-flex; align-items: center; min-height: 44px; margin-top: 2px; border: 0; background: none; font-size: 13px; text-decoration: underline; color: var(--ink-soft); padding: 0 0 0 8px; }
.cart-foot { padding: 20px 24px calc(24px + env(safe-area-inset-bottom)); border-top: 1px solid rgba(31,37,71,.1); }
.subtotal { display: flex; justify-content: space-between; font-size: 18px; }
.fine { font-size: 13px; color: var(--ink-soft); margin: 6px 0 16px; }

/* ============ TOAST ============ */
.toast {
  position: fixed; left: 50%; bottom: calc(24px + env(safe-area-inset-bottom)); z-index: 80;
  transform: translate(-50%, 30px); opacity: 0; pointer-events: none;
  background: var(--ink); color: var(--cream); padding: 14px 22px; border-radius: 99px;
  font-weight: 600; box-shadow: 0 12px 30px rgba(31,37,71,.25);
  transition: opacity .3s, transform .4s var(--ease);
  max-width: calc(100% - 32px); text-align: center;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero { height: 100vh; height: 100svh; }
  .scroll-cue, .skip-story, .story-progress { display: none; }
  .flicker, .scroll-cue i, .scroll-cue i::after, .product, .logo-stack, .logo-aura, .logo-flare, .wordmark p span, .scroll-cue, .site-header, .hero-rays i { animation: none !important; }
  .logo-flare { transform: translate(-50%, -50%) scale(.42); }
  .hero-fx, .hero-rays { display: none; }
}

/* ============ PRODUCT VIEW ============ */
.product-art { border: 0; padding: 0; width: 100%; font: inherit; color: inherit; cursor: zoom-in; }
.product-name { all: unset; cursor: pointer; display: inline-block; padding: 10px 0; margin: -10px 0; } /* 44px+ tap area, same look */
.product-name:hover { text-decoration: underline; text-underline-offset: 3px; }
.product-name:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; border-radius: 4px; }

.pdp {
  width: min(920px, calc(100% - 32px)); max-height: calc(100vh - 32px); max-height: calc(100dvh - 32px);
  padding: 0; border: 0; border-radius: var(--radius); overflow: auto;
  background: var(--cream); color: var(--ink);
  box-shadow: 0 30px 80px rgba(31,37,71,.35);
}
.pdp::backdrop { background: rgba(31,37,71,.6); }
.pdp[open] { animation: pdp-in .35s var(--ease); }
@keyframes pdp-in { from { opacity: 0; transform: translateY(16px) scale(.98); } }
.pdp-close { position: absolute; top: 14px; right: 14px; z-index: 2; background: var(--surface); box-shadow: inset 0 0 0 1px var(--ilunur-line); }
.pdp-grid { display: grid; grid-template-columns: 1.05fr 1fr; }
.pdp-art {
  position: relative; display: grid; place-items: center; min-height: 420px;
  background: var(--surface); box-shadow: inset -1px 0 0 var(--ilunur-line);
}
.pdp-art::before { content: ""; position: absolute; inset: 0; background: radial-gradient(circle at 50% 30%, rgba(255,111,89,.2), rgba(255,111,89,0) 55%); }
.pdp-art svg { position: relative; width: 62%; height: auto; overflow: visible; }
.pdp-art .card-flame { opacity: 1; transform: scale(1); }  /* the candle is lit in the product view */
.pdp-art img { width: 100%; height: 100%; object-fit: cover; }
.pdp-info { padding: clamp(28px, 4vw, 48px); display: flex; flex-direction: column; gap: 12px; }
.pdp-meta { display: flex; align-items: center; gap: 10px; min-height: 28px; }
.pdp-badge { position: static; }
.pdp-name { font-family: var(--font-display); font-weight: 600; font-size: clamp(32px, 4vw, 44px); line-height: 1.05; padding-right: 40px; }
.pdp-price { font-size: 22px; font-weight: 700; }
.pdp-notes { color: var(--ink-soft); font-size: 17px; }
.pdp-details { display: grid; gap: 8px; padding: 14px 0; border-block: 1px solid var(--ilunur-line); }
.pdp-details li { position: relative; padding-left: 20px; font-size: 15px; }
.pdp-details li::before { content: ""; position: absolute; left: 2px; top: .55em; width: 8px; height: 8px; border-radius: 50%; background: var(--ilunur-celeste); }
.pdp-stock { min-height: 22px; font-weight: 600; font-size: 14px; }
.pdp-buy { display: flex; gap: 12px; align-items: center; margin-top: auto; }
.pdp-buy .qty { margin-top: 0; flex: none; }
.pdp-add { flex: 1; }
.pdp-add:disabled { background: transparent; box-shadow: inset 0 0 0 1.5px var(--ilunur-line); color: var(--ink-soft); cursor: not-allowed; }
@media (max-width: 760px) {
  /* Phones: a bottom sheet */
  .pdp { width: 100%; max-width: none; margin: auto 0 0; border-radius: var(--radius) var(--radius) 0 0; max-height: 92dvh; }
  .pdp[open] { animation-name: pdp-up; }
  @keyframes pdp-up { from { transform: translateY(40px); opacity: 0; } }
  .pdp-grid { grid-template-columns: 1fr; }
  .pdp-art { min-height: 0; aspect-ratio: 5 / 4; box-shadow: inset 0 -1px 0 var(--ilunur-line); }
  .pdp-art svg { width: 44%; }
  .pdp-info { padding: 22px 16px calc(22px + env(safe-area-inset-bottom)); }
}
@media (prefers-reduced-motion: reduce) { .pdp[open] { animation: none; } }
