/* =========================================================
   Café Corazón del Molino — Design tokens (Brandbook)
   Verde #0D4137 · Dorado #DBC89E · Vino #6F0303
   ========================================================= */
:root {
  --green: #0D4137;
  --green-900: #082C25;
  --green-700: #145446;
  --gold: #DBC89E;
  --gold-300: #EADCBB;
  --gold-600: #B89A5E;
  --wine: #6F0303;
  --wine-700: #4E0606;
  --espresso: #21130C;
  --espresso-800: #2D1A10;
  --cream: #F6F0E3;
  --paper: #FBF8F1;
  --ink: #1D2B27;
  --muted: #55645F;
  --line: rgba(13, 65, 55, .14);

  --f-display: "Cormorant", "Cormorant Garamond", Georgia, serif;
  --f-script: "Allura", "Brush Script MT", cursive;
  --f-body: "Poppins", system-ui, -apple-system, "Segoe UI", sans-serif;

  --radius: 18px;
  --radius-lg: 28px;
  --shadow-sm: 0 2px 10px rgba(33, 19, 12, .08);
  --shadow: 0 18px 50px -18px rgba(33, 19, 12, .35);
  --shadow-lg: 0 40px 90px -30px rgba(8, 44, 37, .55);

  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --ease-io: cubic-bezier(.65, 0, .35, 1);
  --header-h: 84px;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 8px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--f-body);
  font-size: 16px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
body.is-locked { overflow: hidden; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
button { font: inherit; color: inherit; cursor: pointer; }
:focus-visible { outline: 2px solid var(--gold-600); outline-offset: 3px; border-radius: 6px; }
.icon { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
.container { width: min(1200px, 100% - 48px); margin-inline: auto; }
.section { padding: clamp(80px, 11vw, 140px) 0; position: relative; }
.skip-link { position: absolute; left: 12px; top: -60px; z-index: 999; background: var(--gold); color: var(--green); padding: 10px 16px; border-radius: 10px; font-weight: 600; text-decoration: none; transition: top .2s; }
.skip-link:focus { top: 12px; }

/* ---------- Type ---------- */
.h2 {
  font-family: var(--f-display);
  font-weight: 600;
  font-size: clamp(2.3rem, 4.6vw, 3.6rem);
  line-height: 1.05;
  letter-spacing: -.01em;
  color: var(--green);
  margin: 0 0 20px;
}
.h2 em { font-style: italic; font-weight: 500; color: var(--wine); }
.h2--light { color: var(--cream); }
.h2--light em { color: var(--gold); }
.lead { font-size: 1.12rem; color: var(--ink); }
p { margin: 0 0 16px; color: var(--muted); }
.script { font-family: var(--f-script); font-size: clamp(1.9rem, 3.2vw, 2.6rem); line-height: 1; color: var(--gold); margin: 0 0 6px; }
.script--light { color: var(--gold); }
.script--sm { font-size: 1.7rem; color: var(--wine); margin: 0; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 12px;
  font-size: .74rem; font-weight: 500; letter-spacing: .22em; text-transform: uppercase;
  color: var(--gold); margin: 0 0 18px;
}
.eyebrow--dark { color: var(--wine); }
.eyebrow--center { justify-content: center; }
.eyebrow__line { width: 34px; height: 1px; background: currentColor; opacity: .7; }

.section-head { max-width: 680px; margin-bottom: clamp(40px, 6vw, 64px); }
.section-head--center { text-align: center; margin-inline: auto; }
.section-head__sub { font-size: 1.02rem; }
.section-head__sub strong { color: var(--green); font-weight: 600; }

/* ---------- Buttons ---------- */
.btn {
  --bg: var(--green); --fg: var(--cream);
  position: relative; isolation: isolate; overflow: hidden;
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 52px; padding: 0 28px;
  border-radius: 999px; border: 1px solid transparent;
  background: var(--bg); color: var(--fg);
  font-family: var(--f-body); font-size: .95rem; font-weight: 500; letter-spacing: .02em;
  text-decoration: none; cursor: pointer;
  transition: transform .35s var(--ease-out), box-shadow .35s var(--ease-out), color .3s, border-color .3s;
}
.btn::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: var(--hover, var(--green-700));
  transform: translateY(101%); border-radius: inherit;
  transition: transform .45s var(--ease-out);
}
.btn:hover::before { transform: translateY(0); }
.btn:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.btn:active { transform: translateY(0) scale(.98); }
.btn .icon { transition: transform .35s var(--ease-out); }
.btn:hover .icon { transform: translateX(3px); }
.btn--gold { --bg: var(--gold); --fg: var(--green-900); --hover: var(--gold-300); }
.btn--ghost { --bg: transparent; --fg: var(--cream); --hover: rgba(219, 200, 158, .14); border-color: rgba(219, 200, 158, .45); }
.btn--green { --bg: var(--green); --fg: var(--cream); --hover: var(--green-700); }
.btn--cream { --bg: var(--cream); --fg: var(--wine); --hover: #fff; }
.btn--sm { min-height: 44px; padding: 0 20px; font-size: .88rem; }
.btn--block { width: 100%; }
.icon-btn {
  width: 44px; height: 44px; display: grid; place-items: center;
  border-radius: 50%; border: 1px solid var(--line); background: transparent;
  transition: background .25s, transform .25s, border-color .25s;
}
.icon-btn:hover { background: rgba(13, 65, 55, .06); transform: rotate(90deg); }

/* ---------- Loader ---------- */
.loader {
  position: fixed; inset: 0; z-index: 1000;
  display: grid; place-items: center; align-content: center; gap: 22px;
  background: var(--green-900);
  transition: clip-path 1s var(--ease-io), visibility 0s 1s;
  clip-path: inset(0 0 0 0);
}
.loader__iso { width: 74px; opacity: 0; transform: scale(.85); animation: isoIn 1s var(--ease-out) .1s forwards; }
.loader__line { width: 120px; height: 1px; background: rgba(219, 200, 158, .25); position: relative; overflow: hidden; }
.loader__line::after { content: ""; position: absolute; inset: 0; background: var(--gold); transform: scaleX(0); transform-origin: left; animation: line 1s var(--ease-io) .2s forwards; }
.is-loaded .loader { clip-path: inset(0 0 100% 0); visibility: hidden; }
@keyframes isoIn { to { opacity: 1; transform: scale(1); } }
@keyframes line { to { transform: scaleX(1); } }

/* ---------- Header ---------- */
.header {
  position: fixed; inset: 0 0 auto; z-index: 50; height: var(--header-h);
  display: flex; align-items: center;
  transition: background .4s, box-shadow .4s, height .4s, transform .5s var(--ease-out);
}
.header.is-scrolled {
  --header-h: 70px;
  background: rgba(8, 44, 37, .88);
  backdrop-filter: blur(14px) saturate(140%);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  box-shadow: 0 10px 30px -15px rgba(0, 0, 0, .5);
}
.header.is-hidden { transform: translateY(-100%); }
.header__inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.header__logo img { width: clamp(132px, 14vw, 168px); transition: width .4s; }
.is-scrolled .header__logo img { width: 128px; }
.nav { display: flex; gap: clamp(18px, 2.6vw, 36px); }
.nav a {
  position: relative; text-decoration: none; color: var(--cream);
  font-size: .86rem; font-weight: 400; letter-spacing: .06em; padding: 8px 0;
}
.nav a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 2px; height: 1px;
  background: var(--gold); transform: scaleX(0); transform-origin: right;
  transition: transform .45s var(--ease-out);
}
.nav a:hover::after, .nav a.is-active::after { transform: scaleX(1); transform-origin: left; }
.nav a.is-active { color: var(--gold); }
.header__actions { display: flex; align-items: center; gap: 8px; }
.cart-btn, .menu-btn {
  position: relative; width: 48px; height: 48px; display: grid; place-items: center;
  border-radius: 50%; border: 1px solid rgba(219, 200, 158, .35);
  background: rgba(219, 200, 158, .06); color: var(--gold);
  transition: background .3s, transform .3s var(--ease-out);
}
.cart-btn:hover, .menu-btn:hover { background: rgba(219, 200, 158, .16); }
.cart-btn .icon { width: 22px; height: 22px; }
.cart-btn__count {
  position: absolute; top: -4px; right: -4px; min-width: 22px; height: 22px; padding: 0 6px;
  display: grid; place-items: center; border-radius: 999px;
  background: var(--wine); color: #fff; font-size: .72rem; font-weight: 600;
  transform: scale(0); transition: transform .4s var(--ease-out);
}
.cart-btn__count.has-items { transform: scale(1); }
.cart-btn.is-bump { animation: bump .6s var(--ease-out); }
@keyframes bump { 0%{transform:scale(1)} 30%{transform:scale(1.22) rotate(-8deg)} 60%{transform:scale(.95) rotate(4deg)} 100%{transform:scale(1)} }
.menu-btn { display: none; }

/* ---------- Hero ---------- */
.hero {
  position: relative; min-height: 100svh; overflow: hidden;
  display: flex; align-items: center;
  padding: calc(var(--header-h) + 40px) 0 90px;
  background: radial-gradient(120% 90% at 80% 30%, #3A2213 0%, var(--espresso) 55%, #150B06 100%);
  color: var(--cream);
}
.hero__bg { position: absolute; inset: 0; pointer-events: none; }
.hero__glow {
  position: absolute; width: 60vw; height: 60vw; right: -10vw; top: -10vw; border-radius: 50%;
  background: radial-gradient(circle, rgba(219, 200, 158, .16), transparent 60%);
  animation: glow 9s ease-in-out infinite alternate;
}
.hero__pattern {
  position: absolute; inset: 0; opacity: .05;
  background-image: url("../assets/brand/isotipo-gold.png");
  background-size: 60px auto; background-repeat: space;
  mask-image: linear-gradient(100deg, #000 0%, transparent 45%);
  -webkit-mask-image: linear-gradient(100deg, #000 0%, transparent 45%);
}
@keyframes glow { to { transform: translate(-6vw, 6vw) scale(1.1); } }
.hero__grid { position: relative; display: grid; grid-template-columns: 1.08fr .92fr; gap: clamp(30px, 5vw, 80px); align-items: center; }
.hero__title {
  font-family: var(--f-display); font-weight: 500;
  font-size: clamp(3.2rem, 8vw, 6.6rem); line-height: .95; letter-spacing: -.02em;
  margin: 0 0 28px; color: var(--cream);
}
.hero__title .split { display: block; }
.hero__script {
  display: block; font-family: var(--f-script); font-weight: 400;
  font-size: 1.12em; line-height: 1.1; color: var(--gold); letter-spacing: 0;
  margin-top: .02em; padding-left: .2em;
}
.hero__lead { font-size: clamp(1rem, 1.3vw, 1.12rem); max-width: 500px; color: rgba(246, 240, 227, .78); margin-bottom: 34px; }
.hero__ctas { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 48px; }
.hero__facts { list-style: none; margin: 0; padding: 26px 0 0; display: flex; gap: clamp(24px, 4vw, 52px); border-top: 1px solid rgba(219, 200, 158, .2); max-width: 520px; }
.hero__facts strong { display: block; font-family: var(--f-display); font-size: 1.9rem; font-weight: 600; color: var(--gold); line-height: 1.1; }
.hero__facts span { font-size: .78rem; letter-spacing: .12em; text-transform: uppercase; color: rgba(246, 240, 227, .6); }

.hero__visual { position: relative; justify-self: center; width: min(100%, 470px); }
.arch {
  position: relative; aspect-ratio: 919 / 1250; border-radius: 999px 999px 26px 26px; overflow: hidden;
  box-shadow: var(--shadow-lg), 0 0 0 1px rgba(219, 200, 158, .25);
  will-change: transform;
}
.arch::after { content: ""; position: absolute; inset: 10px; border-radius: inherit; border: 1px solid rgba(219, 200, 158, .45); pointer-events: none; }
.arch img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 70%; transform: scale(1.08); animation: kenburns 18s ease-in-out infinite alternate; }
@keyframes kenburns { to { transform: scale(1.16) translate(-2%, -2%); } }
.steam { position: absolute; left: 50%; top: 4%; width: 90px; transform: translateX(-30%); pointer-events: none; }
.steam path { fill: none; stroke: rgba(246, 240, 227, .55); stroke-width: 3; stroke-linecap: round; stroke-dasharray: 60 260; animation: steam 4.5s ease-in-out infinite; filter: blur(2px); }
.steam path:nth-child(2) { animation-delay: 1.3s; }
.steam path:nth-child(3) { animation-delay: 2.6s; }
@keyframes steam { 0% { stroke-dashoffset: 320; opacity: 0; } 25% { opacity: 1; } 100% { stroke-dashoffset: 0; opacity: 0; } }
.hero__iso-float { position: absolute; width: 64px; left: -38px; bottom: 16%; opacity: .9; filter: drop-shadow(0 8px 20px rgba(0,0,0,.4)); }
.hero__badge { position: absolute; right: -26px; top: 14%; width: 124px; height: 124px; border-radius: 50%; background: var(--green); box-shadow: var(--shadow); display: grid; place-items: center; }
.hero__badge svg:first-child { position: absolute; inset: 0; width: 100%; height: 100%; animation: spin 22s linear infinite; }
.hero__badge text { font-family: var(--f-body); font-size: 9.4px; letter-spacing: .24em; fill: var(--gold); }
.hero__badge-bean { width: 34px; height: 34px; fill: none; stroke: var(--gold); stroke-width: 1.4; }
@keyframes spin { to { transform: rotate(360deg); } }
.scroll-cue { position: absolute; left: 50%; bottom: 28px; width: 26px; height: 42px; border: 1px solid rgba(219, 200, 158, .5); border-radius: 20px; transform: translateX(-50%); }
.scroll-cue span { position: absolute; left: 50%; top: 8px; width: 3px; height: 8px; margin-left: -1.5px; border-radius: 3px; background: var(--gold); animation: cue 1.8s ease-in-out infinite; }
@keyframes cue { 0% { opacity: 0; transform: translateY(0); } 40% { opacity: 1; } 100% { opacity: 0; transform: translateY(14px); } }

/* split words */
.split .w { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: .08em; }
.split .w > span { display: inline-block; transform: translateY(110%); transition: transform 1.1s var(--ease-out); transition-delay: var(--d, 0s); }
.is-loaded .split .w > span { transform: translateY(0); }

/* ---------- Marquee ---------- */
.marquee { background: var(--green); color: var(--gold); overflow: hidden; padding: 20px 0; border-block: 1px solid rgba(219, 200, 158, .2); }
.marquee__track { display: flex; align-items: center; gap: 38px; width: max-content; animation: marquee 38s linear infinite; }
.marquee span { font-family: var(--f-display); font-size: clamp(1.3rem, 2.2vw, 1.75rem); font-style: italic; white-space: nowrap; }
.marquee i { width: 8px; height: 8px; transform: rotate(45deg); background: var(--gold); opacity: .6; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ---------- Origin ---------- */
.origin { background: var(--paper); }
.origin::before {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .5;
  background: radial-gradient(60% 50% at 0% 100%, rgba(219, 200, 158, .35), transparent 70%);
}
.origin__grid { position: relative; display: grid; grid-template-columns: .9fr 1.1fr; gap: clamp(40px, 7vw, 100px); align-items: center; }
.map-frame { position: relative; border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow); transform: rotate(-1.5deg); transition: transform .8s var(--ease-out); }
.map-frame:hover { transform: rotate(0) scale(1.01); }
.map-pin { position: absolute; left: var(--x); top: var(--y); width: 18px; height: 18px; margin: -9px 0 0 -9px; border-radius: 50%; background: var(--wine); box-shadow: 0 0 0 4px rgba(255,255,255,.8); }
.map-pin span, .map-pin::after { content: ""; position: absolute; inset: 0; border-radius: 50%; border: 2px solid var(--wine); animation: ping 2.2s var(--ease-out) infinite; }
.map-pin::after { animation-delay: 1.1s; }
@keyframes ping { from { transform: scale(1); opacity: .9; } to { transform: scale(4.2); opacity: 0; } }
.spec { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0; margin: 34px 0 0; border-top: 1px solid var(--line); }
.spec div { padding: 18px 0; border-bottom: 1px solid var(--line); }
.spec div:nth-child(odd) { padding-right: 20px; }
.spec dt { font-size: .72rem; letter-spacing: .18em; text-transform: uppercase; color: var(--wine); margin-bottom: 4px; }
.spec dd { margin: 0; font-family: var(--f-display); font-size: 1.35rem; font-weight: 600; color: var(--green); line-height: 1.2; }

/* ---------- Values ---------- */
.section--dark { background: var(--green); color: var(--cream); overflow: hidden; }
.values__pattern {
  position: absolute; inset: 0; opacity: .045; pointer-events: none;
  background-image: url("../assets/brand/isotipo-gold.png"); background-size: 54px auto;
}
.values .container { position: relative; }
.emblems { display: flex; justify-content: center; gap: clamp(30px, 8vw, 110px); flex-wrap: wrap; margin: 10px 0 clamp(56px, 8vw, 90px); }
.emblem { margin: 0; text-align: center; }
.emblem__svg { width: clamp(96px, 12vw, 130px); fill: none; stroke: var(--gold); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; transition: transform .8s var(--ease-out); }
.emblem__svg .fill { fill: var(--gold); stroke: none; }
.emblem:hover .emblem__svg { transform: rotate(-8deg) scale(1.06); }
.emblem__svg path, .emblem__svg circle:not(.fill) { stroke-dasharray: 400; stroke-dashoffset: 400; transition: stroke-dashoffset 2.2s var(--ease-out); transition-delay: calc(var(--d, 0s) + .2s); }
.emblem.is-in .emblem__svg path, .emblem.is-in .emblem__svg circle { stroke-dashoffset: 0; }
.emblem figcaption { font-family: var(--f-script); font-size: clamp(2rem, 3.4vw, 2.7rem); color: var(--cream); line-height: 1; margin-top: 14px; }
.values__list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 2px; background: rgba(219, 200, 158, .16); border-radius: var(--radius); overflow: hidden; }
.values__list li { background: var(--green); padding: 34px 28px; transition: background .4s; }
.values__list li:hover { background: var(--green-700); }
.values__num { font-family: var(--f-display); font-size: .95rem; color: var(--gold); letter-spacing: .1em; }
.values__list h3 { font-family: var(--f-display); font-size: 1.7rem; font-weight: 600; margin: 8px 0 10px; color: var(--cream); }
.values__list p { color: rgba(246, 240, 227, .72); font-size: .93rem; margin: 0; }

/* ---------- Shop ---------- */
.shop { background: var(--cream); }
.products { display: grid; grid-template-columns: repeat(6, 1fr); gap: clamp(20px, 2.4vw, 32px); }
.product { grid-column: span 2; }
.product:nth-child(4) { grid-column: 2 / span 2; }
.product:nth-child(5) { grid-column: 4 / span 2; }
.product {
  position: relative; display: flex; flex-direction: column;
  background: var(--paper); border-radius: var(--radius-lg); overflow: hidden;
  box-shadow: var(--shadow-sm); border: 1px solid rgba(13, 65, 55, .08);
  transition: box-shadow .5s var(--ease-out), transform .5s var(--ease-out);
  transform-style: preserve-3d;
}
.product:hover { box-shadow: var(--shadow); }
.product__media { position: relative; aspect-ratio: 4 / 4.4; overflow: hidden; background: var(--espresso); cursor: zoom-in; border: 0; padding: 0; width: 100%; }
.product__media img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 62%; transition: transform 1.2s var(--ease-out), filter .6s; }
.product:hover .product__media img { transform: scale(1.07); }
.product__media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 55%, rgba(33, 19, 12, .55)); }
.product__tag {
  position: absolute; top: 16px; left: 16px; z-index: 2;
  padding: 6px 14px; border-radius: 999px; font-size: .72rem; font-weight: 500; letter-spacing: .06em;
  background: var(--gold); color: var(--green-900);
}
.product__tag--wine { background: var(--wine); color: #fff; }
.product__peek {
  position: absolute; z-index: 2; right: 16px; bottom: 16px;
  display: inline-flex; align-items: center; gap: 6px; padding: 8px 14px; border-radius: 999px;
  background: rgba(251, 248, 241, .92); color: var(--green); font-size: .78rem; font-weight: 500;
  transform: translateY(10px); opacity: 0; transition: .45s var(--ease-out);
}
.product:hover .product__peek, .product__media:focus-visible .product__peek { transform: none; opacity: 1; }
.product__body { display: flex; flex-direction: column; flex: 1; padding: 24px 24px 26px; }
.product__name { font-family: var(--f-display); font-size: 1.85rem; font-weight: 600; color: var(--green); margin: 0 0 6px; line-height: 1.05; }
.product__desc { font-size: .9rem; margin-bottom: 14px; }
.product__includes { list-style: none; padding: 0; margin: 0 0 20px; display: flex; flex-wrap: wrap; gap: 6px; }
.product__includes li { font-size: .74rem; padding: 4px 10px; border-radius: 999px; background: rgba(13, 65, 55, .07); color: var(--green); }
.product__price { display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px 12px; margin-top: auto; margin-bottom: 16px; }
.product__price strong { font-family: var(--f-display); font-size: 2rem; font-weight: 700; color: var(--wine); line-height: 1; }
.product__price span { font-size: .78rem; color: var(--muted); }
.product__price span b { color: var(--green); font-weight: 600; }
.product__row { display: flex; gap: 10px; align-items: stretch; }
.grind { display: inline-flex; padding: 4px; border-radius: 999px; background: rgba(13, 65, 55, .07); position: relative; flex-shrink: 0; }
.grind label { position: relative; z-index: 1; cursor: pointer; }
.grind input { position: absolute; opacity: 0; pointer-events: none; }
.grind span { display: grid; place-items: center; min-height: 40px; padding: 0 14px; border-radius: 999px; font-size: .8rem; color: var(--muted); transition: color .3s, background .3s; }
.grind input:checked + span { background: var(--green); color: var(--cream); }
.grind input:focus-visible + span { outline: 2px solid var(--gold-600); outline-offset: 2px; }
.add-btn { flex: 1; min-height: 48px; padding: 0 16px; font-size: .88rem; }
.add-btn.is-added { --bg: var(--wine); }

.perks { list-style: none; margin: clamp(48px, 6vw, 70px) 0 0; padding: 26px; display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; border-radius: var(--radius); border: 1px dashed rgba(13, 65, 55, .25); }
.perks li { display: flex; align-items: center; gap: 12px; font-size: .88rem; color: var(--green); }
.perks .icon { width: 26px; height: 26px; color: var(--wine); }

/* ---------- Box quote ---------- */
.box-quote { position: relative; overflow: hidden; padding: clamp(110px, 16vw, 200px) 0; color: var(--cream); text-align: center; background: var(--espresso); }
.box-quote__media { position: absolute; inset: -15% 0; }
.box-quote__media img { width: 100%; height: 100%; object-fit: cover; }
.box-quote__media::after { content: ""; position: absolute; inset: 0; background: radial-gradient(70% 70% at 50% 50%, rgba(33, 19, 12, .72), rgba(33, 19, 12, .92)); }
.box-quote__inner { position: relative; }
.box-quote__iso { width: 52px; margin: 0 auto 28px; }
.box-quote__text { margin: 0; }
.box-quote .lines { margin: 0; font-family: var(--f-display); font-size: clamp(1.7rem, 3.6vw, 2.9rem); font-weight: 500; line-height: 1.25; color: var(--cream); }
.box-quote .lines span { display: block; }
.box-quote .script-line { font-family: var(--f-script); font-size: 1.35em; color: var(--gold); margin-top: 8px; }

/* ---------- Rituals ---------- */
.rituals { background: var(--paper); }
.rituals__wrap { background: #fff; border-radius: var(--radius-lg); box-shadow: var(--shadow-sm); border: 1px solid rgba(13, 65, 55, .08); padding: clamp(18px, 3vw, 34px); }
.tabs { position: relative; display: inline-flex; gap: 4px; padding: 5px; border-radius: 999px; background: var(--cream); margin-bottom: clamp(26px, 4vw, 40px); max-width: 100%; overflow-x: auto; }
.tabs button { position: relative; z-index: 1; border: 0; background: none; min-height: 46px; padding: 0 22px; border-radius: 999px; font-size: .9rem; color: var(--muted); white-space: nowrap; transition: color .35s; }
.tabs button[aria-selected="true"] { color: var(--cream); }
.tabs__ink { position: absolute; z-index: 0; top: 5px; bottom: 5px; left: 0; width: 0; border-radius: 999px; background: var(--green); transition: transform .55s var(--ease-out), width .55s var(--ease-out); }
.ritual { display: grid; grid-template-columns: .7fr 1.3fr; gap: clamp(24px, 5vw, 70px); align-items: center; }
.ritual:not([hidden]) { animation: fadeUp .7s var(--ease-out); }
.ritual__art { aspect-ratio: 1; border-radius: var(--radius-lg); background: radial-gradient(circle at 50% 40%, #FFF9EC, var(--cream)); display: grid; place-items: center; }
.ritual__art svg { width: 62%; }
.ritual__art .draw { fill: none; stroke: var(--green); stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 1200; stroke-dashoffset: 1200; animation: draw 2.2s var(--ease-out) forwards; }
.ritual__art .liquid { fill: var(--wine); opacity: 0; transform-origin: 50% 100%; transform-box: fill-box; animation: fill 1.6s var(--ease-out) 1s forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes fill { from { opacity: .9; transform: scaleY(0); } to { opacity: .9; transform: scaleY(1); } }
@keyframes fadeUp { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }
.ritual__body h3 { font-family: var(--f-display); font-size: clamp(1.7rem, 2.8vw, 2.2rem); font-weight: 600; color: var(--green); margin: 0 0 20px; line-height: 1.1; }
.ritual__meta { list-style: none; padding: 0; margin: 0 0 24px; display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.ritual__meta li { padding: 14px; border-radius: 14px; background: var(--cream); }
.ritual__meta span { display: block; font-size: .7rem; letter-spacing: .14em; text-transform: uppercase; color: var(--wine); }
.ritual__meta strong { font-family: var(--f-display); font-size: 1.25rem; color: var(--green); font-weight: 700; }
.ritual__steps { margin: 0; padding: 0; list-style: none; counter-reset: s; display: grid; gap: 10px; }
.ritual__steps li { counter-increment: s; position: relative; padding-left: 46px; color: var(--ink); min-height: 32px; display: flex; align-items: center; }
.ritual__steps li::before { content: counter(s); position: absolute; left: 0; top: 50%; transform: translateY(-50%); width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; font-family: var(--f-display); font-weight: 700; color: var(--gold-600); border: 1px solid var(--gold); }

/* ---------- Wholesale ---------- */
.wholesale { background: linear-gradient(120deg, var(--wine-700), var(--wine)); padding: clamp(70px, 9vw, 110px) 0; position: relative; overflow: hidden; }
.wholesale::after { content: ""; position: absolute; right: -60px; top: 50%; width: 360px; height: 560px; transform: translateY(-50%) rotate(12deg); background: url("../assets/brand/isotipo-gold.png") center / contain no-repeat; opacity: .08; }
.wholesale__inner { position: relative; z-index: 1; display: flex; align-items: center; justify-content: space-between; gap: 40px; flex-wrap: wrap; }
.wholesale__inner > div { max-width: 640px; }
.wholesale .h2 { margin-bottom: 14px; }
.wholesale__text { color: rgba(246, 240, 227, .82); margin: 0; font-size: 1.05rem; }

/* ---------- Footer ---------- */
.footer { position: relative; background: var(--espresso); color: rgba(246, 240, 227, .75); padding: clamp(70px, 9vw, 100px) 0 30px; overflow: hidden; }
.footer__pattern { position: absolute; inset: 0; opacity: .05; background-image: url("../assets/brand/isotipo-gold.png"); background-size: 64px auto; pointer-events: none; }
.footer__grid { position: relative; display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 50px; padding-bottom: 50px; border-bottom: 1px solid rgba(219, 200, 158, .18); }
.footer__brand img { width: 220px; margin-bottom: 22px; }
.footer__quote { font-family: var(--f-display); font-style: italic; font-size: 1.25rem; color: var(--gold-300); max-width: 380px; line-height: 1.4; }
.footer__title { font-family: var(--f-display); font-size: 1.4rem; color: var(--gold); margin: 0 0 18px; font-weight: 600; }
.footer__list { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.footer__list a, .footer__list span { display: inline-flex; align-items: flex-start; gap: 10px; text-decoration: none; font-size: .92rem; transition: color .25s; }
.footer__list a:hover { color: var(--gold); }
.footer__list .icon { margin-top: 2px; color: var(--gold); }
.footer__bottom { position: relative; display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; padding-top: 26px; font-size: .82rem; }
.footer__bottom p { margin: 0; color: rgba(246, 240, 227, .55); }
.footer__top { text-decoration: none; color: var(--gold); }

/* ---------- Cart drawer ---------- */
.overlay { position: fixed; inset: 0; z-index: 80; background: rgba(21, 11, 6, .55); backdrop-filter: blur(3px); opacity: 0; transition: opacity .45s; }
.overlay.is-open { opacity: 1; }
.cart {
  position: fixed; z-index: 90; top: 0; right: 0; height: 100dvh; width: min(440px, 100%);
  display: flex; flex-direction: column; background: var(--paper);
  overflow-y: auto; overscroll-behavior: contain;
  box-shadow: -30px 0 80px -20px rgba(0, 0, 0, .35);
  transform: translateX(105%); visibility: hidden;
  transition: transform .6s var(--ease-out), visibility 0s .6s;
}
.cart.is-open { transform: none; visibility: visible; transition: transform .6s var(--ease-out), visibility 0s; }
.cart__head { display: flex; align-items: flex-end; justify-content: space-between; padding: 26px 26px 18px; border-bottom: 1px solid var(--line); }
.cart__title { font-family: var(--f-display); font-size: 2rem; margin: 0; color: var(--green); line-height: 1; }
.cart__head { position: sticky; top: 0; z-index: 2; background: var(--paper); }
.cart__body { flex: 1 0 auto; padding: 10px 26px; }
.cart__empty { display: grid; justify-items: center; gap: 14px; text-align: center; padding: 60px 0; }
.cart__empty img { width: 46px; opacity: .5; }
.cart__empty p { margin: 0; }
.cart__items { list-style: none; margin: 0; padding: 0; }
.citem { display: grid; grid-template-columns: 76px 1fr auto; gap: 14px; padding: 16px 0; border-bottom: 1px solid var(--line); animation: fadeUp .5s var(--ease-out); }
.citem.is-removing { animation: out .35s var(--ease-io) forwards; }
@keyframes out { to { opacity: 0; transform: translateX(30px); } }
.citem img { width: 76px; height: 90px; object-fit: cover; border-radius: 12px; }
.citem__name { font-family: var(--f-display); font-size: 1.25rem; font-weight: 600; color: var(--green); line-height: 1.1; margin: 0 0 2px; }
.citem__meta { font-size: .78rem; color: var(--muted); margin: 0 0 10px; }
.citem__meta b { color: var(--wine); font-weight: 600; }
.qty { display: inline-flex; align-items: center; border: 1px solid var(--line); border-radius: 999px; }
.qty button { width: 36px; height: 36px; display: grid; place-items: center; border: 0; background: none; border-radius: 50%; transition: background .2s; }
.qty button:hover { background: rgba(13, 65, 55, .07); }
.qty .icon { width: 16px; height: 16px; }
.qty output { min-width: 26px; text-align: center; font-weight: 600; font-size: .9rem; }
.citem__side { display: flex; flex-direction: column; align-items: flex-end; justify-content: space-between; }
.citem__price { font-family: var(--f-display); font-weight: 700; font-size: 1.2rem; color: var(--wine); }
.citem__remove { border: 0; background: none; color: var(--muted); width: 40px; height: 40px; display: grid; place-items: center; border-radius: 50%; transition: color .2s, background .2s; }
.citem__remove:hover { color: var(--wine); background: rgba(111, 3, 3, .07); }
.cart__foot { padding: 18px 26px 24px; border-top: 1px solid var(--line); background: #fff; }
.cart__row { display: flex; justify-content: space-between; align-items: baseline; font-size: .95rem; }
.cart__row strong { font-family: var(--f-display); font-size: 1.7rem; color: var(--green); }
.cart__row--save { color: var(--wine); }
.cart__row--save strong { font-size: 1.2rem; color: var(--wine); }
.cart__note { font-size: .78rem; margin: 6px 0 14px; }
.checkout { display: grid; gap: 10px; }
.field { display: grid; gap: 4px; }
.field label { font-size: .78rem; font-weight: 500; color: var(--green); }
.field__opt { font-weight: 400; color: var(--muted); }
.field input { min-height: 46px; padding: 0 14px; border-radius: 12px; border: 1px solid rgba(13, 65, 55, .22); background: var(--paper); font: inherit; font-size: 16px; color: var(--ink); transition: border-color .2s, box-shadow .2s; }
.field input:focus { outline: none; border-color: var(--green); box-shadow: 0 0 0 3px rgba(13, 65, 55, .12); }
.field input[aria-invalid="true"] { border-color: var(--wine); }
.field__error { font-size: .75rem; color: var(--wine); min-height: 0; }
.field__error:empty { display: none; }
.checkout .btn { margin-top: 6px; }

/* ---------- Product dialog ---------- */
.pdialog { width: min(960px, 100% - 32px); max-height: min(90dvh, 760px); padding: 0; border: 0; border-radius: var(--radius-lg); background: var(--paper); box-shadow: var(--shadow-lg); overflow: hidden; }
.pdialog::backdrop { background: rgba(21, 11, 6, .6); backdrop-filter: blur(4px); }
.pdialog[open] { animation: pop .55s var(--ease-out); }
@keyframes pop { from { opacity: 0; transform: translateY(24px) scale(.97); } to { opacity: 1; transform: none; } }
.pdialog__close { position: absolute; top: 14px; right: 14px; z-index: 2; background: var(--paper); }
.pdialog__grid { display: grid; grid-template-columns: 1fr 1fr; max-height: inherit; }
.pdialog__media { background: var(--espresso); }
.pdialog__media img { width: 100%; height: 100%; max-height: min(90dvh, 760px); object-fit: cover; }
.pdialog__body { padding: clamp(26px, 4vw, 44px); overflow-y: auto; }
.pdialog__title { font-family: var(--f-display); font-size: clamp(2rem, 3.5vw, 2.6rem); color: var(--green); margin: 4px 0 12px; line-height: 1.05; }
.pdialog__sub { font-size: .72rem; letter-spacing: .18em; text-transform: uppercase; color: var(--wine); margin: 22px 0 10px; }
.pdialog__includes { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.pdialog__includes li { display: flex; gap: 10px; align-items: center; color: var(--ink); font-size: .95rem; }
.pdialog__includes .icon { color: var(--gold-600); width: 18px; height: 18px; }
.pdialog__price { display: grid; gap: 2px; margin: 26px 0 18px; }
.pdialog__price strong { font-family: var(--f-display); font-size: 2.4rem; color: var(--wine); line-height: 1; }
.pdialog__price span { font-size: .85rem; color: var(--muted); }
.pdialog__actions .product__row { flex-wrap: wrap; }

/* ---------- Toast & flying item ---------- */
.toast {
  position: fixed; left: 50%; bottom: 26px; z-index: 120;
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 22px; border-radius: 999px; background: var(--green); color: var(--cream);
  font-size: .9rem; box-shadow: var(--shadow);
  transform: translate(-50%, 140%); opacity: 0; transition: transform .5s var(--ease-out), opacity .4s;
  pointer-events: none;
}
.toast.is-show { transform: translate(-50%, 0); opacity: 1; }
.toast .icon { color: var(--gold); }
.fly { position: fixed; z-index: 130; width: 70px; height: 70px; border-radius: 50%; object-fit: cover; pointer-events: none; box-shadow: 0 10px 30px rgba(0, 0, 0, .35); border: 2px solid var(--gold); }

/* ---------- Reveal on scroll ---------- */
[data-reveal] { opacity: 0; transform: translateY(34px); transition: opacity 1s var(--ease-out), transform 1.1s var(--ease-out); transition-delay: var(--d, 0s); }
[data-reveal="left"] { transform: translateX(-50px); }
[data-reveal="right"] { transform: translateX(50px); }
[data-reveal="zoom"] { transform: scale(.92); }
[data-reveal].is-in { opacity: 1; transform: none; }
.product[data-reveal] { transform: translateY(50px); }

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .values__list { grid-template-columns: repeat(2, 1fr); }
  .perks { grid-template-columns: repeat(2, 1fr); }
  .products { grid-template-columns: repeat(2, 1fr); }
  .product, .product:nth-child(4), .product:nth-child(5) { grid-column: auto; }
  .product:nth-child(5) { grid-column: 1 / -1; max-width: calc(50% - 14px); justify-self: center; width: 100%; }
}
@media (max-width: 880px) {
  :root { --header-h: 72px; }
  .menu-btn { display: grid; }
  .nav {
    position: fixed; inset: 0 0 auto; top: 0; padding: 100px 28px 40px; z-index: -1;
    flex-direction: column; gap: 4px; background: var(--green-900);
    transform: translateY(-100%); transition: transform .6s var(--ease-out);
  }
  .nav.is-open { transform: none; box-shadow: var(--shadow-lg); }
  .nav a { font-family: var(--f-display); font-size: 1.9rem; padding: 10px 0; border-bottom: 1px solid rgba(219, 200, 158, .14); }
  .hero { padding-top: calc(var(--header-h) + 30px); }
  .hero__grid { grid-template-columns: 1fr; }
  .hero__visual { width: min(84%, 380px); order: -1; margin-top: 10px; }
  .hero__badge { width: 96px; height: 96px; right: -14px; }
  .hero__badge text { font-size: 9px; }
  .hero__iso-float { left: -20px; width: 48px; }
  .scroll-cue { display: none; }
  .origin__grid { grid-template-columns: 1fr; }
  .origin__map { max-width: 440px; }
  .ritual { grid-template-columns: 1fr; }
  .ritual__art { max-width: 260px; }
  .ritual__meta { grid-template-columns: repeat(2, 1fr); }
  .footer__grid { grid-template-columns: 1fr 1fr; }
  .footer__brand { grid-column: 1 / -1; }
  .pdialog__grid { grid-template-columns: 1fr; overflow-y: auto; }
  .pdialog__media img { max-height: 320px; }
}
@media (max-width: 640px) {
  .container { width: min(100% - 32px, 1200px); }
  .products { grid-template-columns: 1fr; }
  .product:nth-child(5) { max-width: none; }
  .values__list { grid-template-columns: 1fr; }
  .perks { grid-template-columns: 1fr; padding: 20px; }
  .spec { grid-template-columns: 1fr; }
  .spec div:nth-child(odd) { padding-right: 0; }
  .hero__facts { gap: 20px; }
  .hero__facts strong { font-size: 1.5rem; }
  .footer__grid { grid-template-columns: 1fr; gap: 36px; }
  .product__row { flex-direction: column; }
  .grind { align-self: flex-start; }
  .wholesale__inner .btn { width: 100%; }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
  [data-reveal], .split .w > span { opacity: 1 !important; transform: none !important; }
  .marquee__track { animation: none; }
  .steam { display: none; }
}
