/* ==========================================================================
   CALVITO COFFEE — styles.css
   Paleta: crema + rojo ladrillo. Estilo grabado / vintage paisa.
   ========================================================================== */

/* ── Tokens ─────────────────────────────────────────────────────────────── */
:root {
  --cream:        #FAF1DE;
  --cream-2:      #F5E9D2;
  --cream-3:      #EEDFC2;
  --red:          #C4202B;
  --red-deep:     #97141F;
  --red-soft:     #E04A44;
  --ink:          #3A322B;
  --ink-2:        #6E6255;
  --ink-3:        #9C8E7E;
  --white:        #FFFCF5;

  --wa:           #25D366;
  --wa-deep:      #128C4A;

  --f-display: 'Lilita One', 'Arial Black', system-ui, sans-serif;
  --f-body:    'Nunito Sans', system-ui, -apple-system, sans-serif;

  --shadow-sm: 0 2px 8px rgba(58,50,43,.08);
  --shadow:    0 10px 30px rgba(58,50,43,.12);
  --shadow-lg: 0 28px 70px rgba(58,50,43,.20);
  --shadow-red:0 14px 34px rgba(196,32,43,.30);

  --nav-h: 72px;
  --promo-h: 0px;                 /* JS lo sube a 40px si la promo está viva */
  --ease:  cubic-bezier(.22,1,.36,1);
  --ease-back: cubic-bezier(.34,1.56,.64,1);

  --pad: clamp(1.25rem, 5vw, 5rem);
  --maxw: 1240px;
}

/* ── Reset ──────────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-h) + var(--promo-h));
  -webkit-text-size-adjust: 100%;
}
html.has-promo { --promo-h: 40px; }

body {
  font-family: var(--f-body);
  font-weight: 400;
  color: var(--ink);
  background: var(--cream);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img, svg, canvas { display: block; max-width: 100%; }
button, input, select { font: inherit; color: inherit; }
button { background: none; border: 0; cursor: pointer; }
a { color: inherit; text-decoration: none; }
fieldset { border: 0; }
ul, ol { list-style: none; }

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

.skip-link {
  position: fixed; top: -100px; left: 1rem; z-index: 999;
  background: var(--red); color: var(--white);
  padding: .75rem 1.25rem; border-radius: 0 0 12px 12px;
  transition: top .2s;
}
.skip-link:focus { top: 0; }

:focus-visible {
  outline: 3px solid var(--red);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ── Textura de papel ───────────────────────────────────────────────────── */
.grain {
  position: fixed; inset: 0; z-index: 9998;
  pointer-events: none; opacity: .35; mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='200' height='200' filter='url(%23n)' opacity='.45'/%3E%3C/svg%3E");
}

/* ── Barra de promo (inauguración) ──────────────────────────────────────── */
.promo-bar {
  position: fixed; top: 0; left: 0; right: 0;
  z-index: 1002; height: var(--promo-h);
  background: var(--red);
  color: var(--white);
  display: grid; place-items: center;
  overflow: hidden;
}
/* Brillito que cruza la barra cada tanto */
.promo-bar::before {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(100deg, transparent 30%, rgba(255,255,255,.22) 50%, transparent 70%);
  transform: translateX(-100%);
  animation: sweep 5s var(--ease) infinite;
}
@keyframes sweep { 0%, 65% { transform: translateX(-100%); } 100% { transform: translateX(100%); } }

.promo-bar__inner {
  position: relative;
  display: flex; align-items: center; gap: .75rem;
  padding: 0 1rem;
  font-size: .82rem; font-weight: 800;
  text-align: center;
}
.promo-bar__count {
  display: inline-flex; align-items: center;
  padding: .18rem .6rem;
  background: rgba(255,255,255,.2);
  border-radius: 999px;
  font-size: .72rem; font-weight: 900;
  letter-spacing: .04em;
  white-space: nowrap;
}

/* ── Barra de progreso ──────────────────────────────────────────────────── */
.progress {
  position: fixed; top: var(--promo-h); left: 0; right: 0; height: 3px;
  z-index: 1001; background: rgba(196,32,43,.10);
}
.progress__bar {
  display: block; height: 100%; width: 0%;
  background: linear-gradient(90deg, var(--red-deep), var(--red), var(--red-soft));
  transition: width .1s linear;
}

/* ── Wordmark (CALVITO con el grano en la O) ────────────────────────────── */
.wordmark {
  font-family: var(--f-display);
  font-weight: 400;
  color: var(--red);
  letter-spacing: .01em;
  line-height: .82;
  display: inline-flex;
  align-items: baseline;
  white-space: nowrap;
}

/* La "O" con el grano de café atravesado */
.bean-o {
  --o: 1em;
  position: relative;
  display: inline-block;
  width: .78em; height: .78em;
  border: .19em solid currentColor;
  border-radius: 50%;
  transform: translateY(.02em);
  margin-left: .02em;
}
.bean-o::after {
  content: '';
  position: absolute; top: 50%; left: 50%;
  width: .13em; height: 1.02em;
  background: currentColor;
  border-radius: .08em;
  transform: translate(-50%, -50%) rotate(24deg);
  box-shadow: 0 0 0 .07em var(--cream);
}

.wordmark--hero { font-size: clamp(3.6rem, 13vw, 10rem); }
.wordmark--h2   { font-size: clamp(2.8rem, 9vw, 6rem); }
.wordmark--sm   { font-size: 1.6rem; }

/* ── Tipografía compartida ──────────────────────────────────────────────── */
.eyebrow {
  font-size: .78rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .22em;
  color: var(--red); margin-bottom: .75rem;
}

.h-display {
  font-family: var(--f-display);
  font-weight: 400;
  font-size: clamp(2.4rem, 6vw, 4.4rem);
  line-height: .95;
  color: var(--red);
  letter-spacing: .01em;
}
.h-display--xl { font-size: clamp(3rem, 9vw, 6.5rem); }

.lead {
  font-size: clamp(1.1rem, 2.2vw, 1.45rem);
  color: var(--ink-2);
  max-width: 40ch;
  margin-bottom: 1.25rem;
}

.dot {
  display: inline-block;
  width: .5em; height: .7em;
  background: currentColor;
  border-radius: 50% / 45%;
  transform: rotate(20deg) translateY(.06em);
  position: relative;
}
.dot::after {
  content: ''; position: absolute; inset: 0;
  border-left: 1.5px solid var(--cream);
  left: 50%; transform: rotate(-20deg);
}

/* ── Botones ────────────────────────────────────────────────────────────── */
.btn {
  --bg: var(--red);
  position: relative;
  display: inline-flex; align-items: center; justify-content: center;
  gap: .6rem;
  padding: .95rem 1.9rem;
  border-radius: 999px;
  font-weight: 800; font-size: 1rem;
  letter-spacing: .01em;
  cursor: pointer;
  transition: transform .35s var(--ease-back), box-shadow .35s var(--ease), background .25s;
  will-change: transform;
  overflow: hidden;
}
.btn svg { width: 1.15em; height: 1.15em; flex: none; }

.btn--primary {
  background: var(--bg);
  color: var(--white);
  box-shadow: var(--shadow-red);
}
.btn--primary::before {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(100deg, transparent 20%, rgba(255,255,255,.30) 50%, transparent 80%);
  transform: translateX(-120%);
  transition: transform .7s var(--ease);
}
.btn--primary:hover { transform: translateY(-3px); box-shadow: 0 20px 44px rgba(196,32,43,.42); }
.btn--primary:hover::before { transform: translateX(120%); }
.btn--primary:active { transform: translateY(-1px) scale(.98); }

.btn--ghost {
  color: var(--red);
  border: 2.5px solid var(--red);
  background: transparent;
}
.btn--ghost:hover { background: var(--red); color: var(--white); transform: translateY(-3px); }

.btn--wa { background: var(--wa-deep); color: #fff; box-shadow: 0 14px 34px rgba(18,140,74,.32); }
.btn--wa:hover { transform: translateY(-3px); background: #0f7a40; }

.btn--big { padding: 1.15rem 2.4rem; font-size: 1.08rem; width: 100%; }

.btn:disabled,
.btn.is-disabled { opacity: .4; filter: grayscale(.5); cursor: not-allowed; }
.btn.is-disabled:hover { transform: none; }

/* ── NAV ────────────────────────────────────────────────────────────────── */
.nav {
  position: fixed; top: var(--promo-h); left: 0; right: 0;
  z-index: 1000; height: var(--nav-h);
  transition: background .4s var(--ease), box-shadow .4s var(--ease), backdrop-filter .4s;
}
.nav.is-stuck {
  background: rgba(250,241,222,.86);
  backdrop-filter: blur(14px) saturate(1.2);
  -webkit-backdrop-filter: blur(14px) saturate(1.2);
  box-shadow: 0 1px 0 rgba(196,32,43,.14), var(--shadow-sm);
}

.nav__inner {
  max-width: var(--maxw); height: 100%; margin: 0 auto;
  padding: 0 var(--pad);
  display: flex; align-items: center; justify-content: space-between; gap: 1.5rem;
}

/* El logo del nav aparece solo cuando el hero ya pasó */
.nav__logo {
  opacity: 0; transform: translateY(-6px) scale(.9);
  transition: opacity .4s var(--ease), transform .4s var(--ease-back);
  pointer-events: none;
}
.nav.is-stuck .nav__logo { opacity: 1; transform: none; pointer-events: auto; }

.nav__links { display: flex; gap: 2rem; margin-left: auto; }
.nav__links a {
  position: relative;
  font-weight: 700; font-size: .95rem;
  color: var(--ink); padding: .35rem 0;
}
.nav__links a::after {
  content: ''; position: absolute; left: 0; bottom: 0;
  width: 100%; height: 2.5px; background: var(--red);
  transform: scaleX(0); transform-origin: right;
  transition: transform .35s var(--ease);
  border-radius: 2px;
}
.nav__links a:hover::after, .nav__links a.is-active::after { transform: scaleX(1); transform-origin: left; }
.nav__links a.is-active { color: var(--red); }

/* Carrito */
.cart-btn {
  position: relative;
  width: 46px; height: 46px;
  display: grid; place-items: center;
  border-radius: 50%;
  color: var(--red);
  background: rgba(196,32,43,.08);
  transition: transform .3s var(--ease-back), background .25s;
}
.cart-btn:hover { background: rgba(196,32,43,.16); transform: scale(1.08); }
.cart-btn svg { width: 22px; height: 22px; }
.cart-btn.is-bump { animation: bump .45s var(--ease-back); }
@keyframes bump { 0%,100% { transform: scale(1); } 40% { transform: scale(1.28); } }

.cart-btn__count {
  position: absolute; top: -2px; right: -2px;
  min-width: 20px; height: 20px; padding: 0 5px;
  display: grid; place-items: center;
  background: var(--red); color: var(--white);
  font-size: .7rem; font-weight: 900;
  border-radius: 999px;
  border: 2px solid var(--cream);
  transition: transform .3s var(--ease-back);
}
.cart-btn__count[data-empty="true"] { transform: scale(0); }

/* ── HERO ───────────────────────────────────────────────────────────────── */
.hero {
  position: relative;
  min-height: 100svh;
  display: grid; place-items: center;
  padding: calc(var(--nav-h) + var(--promo-h) + 2rem) var(--pad) 6rem;
  overflow: hidden;
  background:
    radial-gradient(120% 90% at 50% 0%,   var(--white)  0%, transparent 55%),
    radial-gradient(100% 70% at 50% 100%, var(--cream-3) 0%, transparent 60%),
    var(--cream);
}

.hero__layers { position: absolute; inset: 0; color: var(--red); pointer-events: none; }

.hero__mountains {
  position: absolute; left: 0; right: 0; bottom: 0;
  width: 100%; height: 42vh;
  will-change: transform;
}
.hero__clouds {
  position: absolute; left: 0; right: 0; top: 8%;
  width: 100%; height: 22vh;
  will-change: transform;
}

.hero__branch {
  position: absolute; bottom: -4%;
  width: clamp(170px, 22vw, 320px); height: auto;
  opacity: .3;
  will-change: transform;
}
.hero__branch--l { left: -3%; }
.hero__branch--r { right: -3%; }

.hero__beans { position: absolute; inset: 0; width: 100%; height: 100%; }

.hero__content {
  position: relative; z-index: 2;
  text-align: center;
  display: flex; flex-direction: column; align-items: center;
  will-change: transform, opacity;
}

.hero__eyebrow {
  font-size: .74rem; font-weight: 800;
  text-transform: uppercase; letter-spacing: .3em;
  color: var(--ink-2); margin-bottom: 1.25rem;
}

.hero__title { display: flex; flex-direction: column; align-items: center; gap: .3rem; }

.hero__sub {
  font-family: var(--f-display);
  font-size: clamp(1.1rem, 3.2vw, 2.2rem);
  color: var(--red);
  letter-spacing: .42em;
  text-indent: .42em;
  position: relative;
  padding: 0 1.6em;
}
.hero__sub::before, .hero__sub::after {
  content: ''; position: absolute; top: 50%;
  width: 1.1em; height: 3px; background: var(--red); border-radius: 2px;
}
.hero__sub::before { left: 0; }
.hero__sub::after  { right: 0; }

.hero__kicker {
  font-size: clamp(.68rem, 1.5vw, .84rem);
  font-weight: 800; letter-spacing: .3em;
  text-transform: uppercase; color: var(--ink-2);
  margin-top: .5rem;
}

.hero__tagline {
  font-family: var(--f-display);
  font-size: clamp(1.4rem, 3.4vw, 2.3rem);
  line-height: 1.1;
  color: var(--ink);
  margin: 2rem 0 2.25rem;
}
.hero__tagline em { color: var(--red); font-style: normal; }

.hero__cta { display: flex; gap: 1rem; flex-wrap: wrap; justify-content: center; }

.hero__badge {
  margin-top: 2.5rem;
  display: inline-flex; align-items: center; gap: .75rem;
  padding: .6rem 1.4rem .6rem 1.1rem;
  border: 2.5px solid var(--red);
  border-radius: 14px;
  color: var(--red);
  background: rgba(255,252,245,.6);
  box-shadow: inset 0 0 0 3px var(--cream), var(--shadow-sm);
}
.hero__badge strong { font-family: var(--f-display); font-size: 2.2rem; line-height: 1; }
.hero__badge span {
  font-size: .68rem; font-weight: 800; line-height: 1.25;
  text-transform: uppercase; letter-spacing: .12em; text-align: left;
}

/* Scroll cue */
.scroll-cue {
  position: absolute; bottom: 1.75rem; left: 50%;
  transform: translateX(-50%);
  z-index: 3;
  display: flex; flex-direction: column; align-items: center; gap: .6rem;
  color: var(--ink-2);
}
.scroll-cue__line {
  width: 2px; height: 46px; border-radius: 2px;
  background: linear-gradient(var(--red), transparent);
  position: relative; overflow: hidden;
}
.scroll-cue__line::after {
  content: ''; position: absolute; top: -50%; left: 0;
  width: 100%; height: 50%; background: var(--red);
  animation: cue 1.9s var(--ease) infinite;
}
@keyframes cue { 0% { top: -50%; } 100% { top: 110%; } }
.scroll-cue__txt {
  font-size: .68rem; font-weight: 800;
  text-transform: uppercase; letter-spacing: .2em;
}

/* ── BANDA (banner parallax) ────────────────────────────────────────────── */
/* El banner es 1600x640 (2.5:1) y trae el logo a la izquierda y las matas en
   los bordes: si recortamos a los lados, se pierde la marca. Por eso la altura
   se ata a la proporción de la imagen en vez de ser fija.
   La cuenta: alto = ancho / (2.5 x 1.36), donde 1.36 es el alto extra que le
   damos a la imagen (inset -18%) para que tenga recorrido de parallax.
   Resultado: cero recorte lateral en cualquier ancho de pantalla. */
.banda {
  position: relative;
  aspect-ratio: 3.4;          /* = 2.5 (imagen) x 1.36 (extra de parallax) */
  min-height: 108px;
  overflow: hidden;
  background: var(--cream);
}
.banda__img {
  position: absolute; inset: -18% 0;
  background-image: url('../assets/img/banner.jpg');
  background-size: cover;
  background-position: center;
  will-change: transform;
}
.banda__veil {
  position: absolute; inset: 0;
  background:
    linear-gradient(var(--cream) 0%, transparent 18%, transparent 82%, var(--cream) 100%);
}

/* ── INTRO ──────────────────────────────────────────────────────────────── */
.intro {
  padding: clamp(3.5rem, 8vw, 6rem) var(--pad) 0;
  background: var(--cream);
  text-align: center;
}
.intro__inner { max-width: 760px; margin: 0 auto; }
.intro__kicker {
  font-family: var(--f-display);
  font-size: clamp(1.3rem, 3.2vw, 2.1rem);
  line-height: 1.2;
  color: var(--red);
  margin-bottom: 1.25rem;
}
.intro__text {
  font-size: clamp(1rem, 2vw, 1.2rem);
  color: var(--ink-2);
}
.intro__text strong { color: var(--ink); font-weight: 900; }

/* ── HISTORIA ───────────────────────────────────────────────────────────── */
.historia {
  padding: clamp(5rem, 11vw, 9rem) var(--pad);
  background: var(--cream);
}
.historia__grid {
  max-width: var(--maxw); margin: 0 auto;
  display: grid; grid-template-columns: 1.05fr .95fr;
  gap: clamp(2rem, 6vw, 5rem);
  align-items: center;
}

.historia__text .h-display { margin-bottom: 1.75rem; }

.pills { display: flex; flex-wrap: wrap; gap: .6rem; margin: 1.75rem 0; }
.pills li {
  padding: .45rem 1rem;
  border: 2px solid rgba(196,32,43,.28);
  border-radius: 999px;
  font-size: .82rem; font-weight: 700;
  color: var(--red);
  transition: background .25s, transform .25s var(--ease-back);
}
.pills li:hover { background: rgba(196,32,43,.08); transform: translateY(-2px); }

.historia__sign {
  font-size: .72rem; font-weight: 800;
  letter-spacing: .2em; text-transform: uppercase;
  color: var(--red);
  display: flex; align-items: center; gap: .5rem;
}

.historia__figure {
  position: relative;
  will-change: transform;
  display: grid; place-items: center;
}
.historia__halo {
  position: absolute; inset: 6%;
  border-radius: 50%;
  background: radial-gradient(circle, var(--cream-3) 0%, transparent 68%);
  animation: breathe 7s ease-in-out infinite;
}
@keyframes breathe { 0%,100% { transform: scale(1); } 50% { transform: scale(1.07); } }

.historia__img {
  position: relative;
  width: 100%; height: auto;
  border-radius: 20px;
  filter: drop-shadow(0 24px 40px rgba(58,50,43,.14));
}
.historia__fallback { display: none; }
.historia__figure.is-missing .historia__img { display: none; }
.historia__figure.is-missing .historia__fallback {
  display: grid; place-items: center; gap: .75rem;
  aspect-ratio: 4/5; width: 100%;
  border: 3px dashed rgba(196,32,43,.35);
  border-radius: 20px;
  background: var(--cream-2);
  font-size: 2.5rem;
}
.historia__fallback small {
  font-family: var(--f-body); font-size: .8rem;
  font-weight: 700; color: var(--ink-3);
}
.historia__fallback code {
  background: rgba(196,32,43,.1); color: var(--red);
  padding: .15em .45em; border-radius: 5px; font-size: .95em;
}

/* ── LOTE ───────────────────────────────────────────────────────────────── */
.lote {
  position: relative;
  display: grid; grid-template-columns: 1fr 1fr;
  background: var(--cream-2);
  min-height: 100vh;
}

/* La foto va a la derecha y el texto a la izquierda, como en la pieza de IG */
.lote__media { position: relative; overflow: hidden; order: 2; }
.lote__photo {
  position: absolute; inset: -18% 0;
  background-image: url('../assets/img/cerezas.jpg');
  background-size: cover;
  background-position: center;
  background-color: var(--red-deep);
  will-change: transform;
}
/* Borde rasgado, como la pieza de Instagram */
.lote__tear {
  position: absolute; top: 0; bottom: 0; left: -1px;
  width: 46px;
  background: var(--cream-2);
  clip-path: polygon(
    0 0, 100% 0, 62% 4%, 88% 9%, 55% 14%, 92% 19%, 60% 25%,
    85% 31%, 52% 37%, 90% 43%, 58% 49%, 86% 55%, 54% 61%,
    93% 67%, 60% 73%, 84% 79%, 52% 85%, 90% 91%, 62% 96%, 100% 100%, 0 100%
  );
}

.lote__panel {
  padding: clamp(3.5rem, 8vw, 7rem) var(--pad);
  display: flex; flex-direction: column; justify-content: center;
  align-items: flex-start;
  order: 1;
}
.lote__panel .h-display--xl { margin-bottom: 2rem; }

/* Sello 85 puntos */
.score {
  display: inline-flex; align-items: center; gap: 1rem;
  padding: .85rem 1.5rem;
  border: 3px solid var(--red);
  border-radius: 16px;
  box-shadow: inset 0 0 0 4px var(--cream-2), var(--shadow-sm);
  background: rgba(255,252,245,.55);
  color: var(--red);
  margin-bottom: 2.5rem;
}
.score__num { font-family: var(--f-display); font-size: 3.4rem; line-height: .9; }
.score__txt { display: flex; flex-direction: column; line-height: 1.25; }
.score__txt strong { font-size: .82rem; font-weight: 900; text-transform: uppercase; letter-spacing: .1em; }
.score__txt span   { font-size: .72rem; font-weight: 700; color: var(--ink-2); }
.score__stars svg  { width: 26px; height: 26px; animation: twinkle 2.4s ease-in-out infinite; }
@keyframes twinkle { 0%,100% { transform: scale(1) rotate(0); opacity: 1; } 50% { transform: scale(1.18) rotate(12deg); opacity: .75; } }

/* Ficha técnica */
.ficha { width: 100%; margin-bottom: 2.5rem; }
.ficha__row {
  display: grid; grid-template-columns: minmax(140px, auto) 1fr;
  gap: 1rem; align-items: baseline;
  padding: .85rem 0;
  border-bottom: 1.5px dashed rgba(196,32,43,.22);
}
.ficha__row dt {
  display: flex; align-items: center; gap: .55rem;
  font-weight: 900; color: var(--red);
  font-size: .95rem;
}
.ficha__row dt svg { width: 20px; height: 20px; flex: none; }
.ficha__row dd { color: var(--ink-2); font-weight: 600; }

/* Notas de taza */
.notas { margin-bottom: 2.5rem; }
.notas__title {
  font-size: .72rem; font-weight: 900;
  text-transform: uppercase; letter-spacing: .2em;
  color: var(--red); margin-bottom: 1rem;
}
.notas__list { display: flex; flex-wrap: wrap; gap: .6rem; }
.notas__list li {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: .5rem 1rem .5rem .65rem;
  background: var(--white);
  border-radius: 999px;
  font-size: .85rem; font-weight: 800;
  box-shadow: var(--shadow-sm);
  transition: transform .3s var(--ease-back);
}
.notas__list li:hover { transform: translateY(-3px) rotate(-2deg); }
.notas__ic {
  width: 22px; height: 22px; border-radius: 50%;
  display: inline-block; flex: none;
  background-size: 62%; background-repeat: no-repeat; background-position: center;
}
.notas__ic[data-ic="manzanilla"] { background: #F5D96B; }
.notas__ic[data-ic="dulce"]      { background: #C98A4B; }
.notas__ic[data-ic="chocolate"]  { background: #6B4226; }
.notas__ic[data-ic="caramelo"]   { background: #E0A458; }

/* ── RITUAL ─────────────────────────────────────────────────────────────── */
.ritual {
  padding: clamp(5rem, 11vw, 9rem) var(--pad);
  background: var(--cream);
}
.ritual__head { max-width: var(--maxw); margin: 0 auto clamp(3rem, 6vw, 4.5rem); text-align: center; }
.ritual__head .eyebrow { text-align: center; }
.ritual__intro { color: var(--ink-2); font-size: 1.1rem; margin-top: 1rem; }

.steps {
  max-width: var(--maxw); margin: 0 auto;
  display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.25rem;
}
.step {
  position: relative;
  padding: 2.25rem 1.6rem 1.6rem;
  background: var(--white);
  border-radius: 18px;
  box-shadow: var(--shadow-sm);
  transition: transform .4s var(--ease), box-shadow .4s var(--ease);
}
.step:hover { transform: translateY(-8px); box-shadow: var(--shadow); }
.step__n {
  position: absolute; top: -18px; left: 1.4rem;
  width: 42px; height: 42px;
  display: grid; place-items: center;
  background: var(--red); color: var(--white);
  font-family: var(--f-display); font-size: 1.3rem;
  border-radius: 50%;
  border: 4px solid var(--cream);
  box-shadow: 0 5px 12px rgba(196,32,43,.28);
}
.step h3 { font-family: var(--f-display); font-weight: 400; font-size: 1.25rem; color: var(--red); margin-bottom: .5rem; }
.step p  { font-size: .95rem; color: var(--ink-2); }

.step--cup { display: flex; flex-direction: column; align-items: center; text-align: center; padding-top: 1.6rem; background: var(--cream-3); }
.cup { position: relative; color: var(--red); width: 110px; margin-bottom: .5rem; }
.cup svg { width: 100%; }
.cup__steam {
  position: absolute; top: 6px; width: 4px; height: 22px;
  background: var(--red); border-radius: 3px; opacity: 0;
  animation: steam 2.6s ease-in-out infinite;
}
.cup__steam:nth-child(1) { left: 32%; animation-delay: 0s; }
.cup__steam:nth-child(2) { left: 46%; animation-delay: .5s; }
.cup__steam:nth-child(3) { left: 60%; animation-delay: 1s; }
@keyframes steam {
  0%   { opacity: 0; transform: translateY(6px) scaleY(.5); }
  35%  { opacity: .55; }
  100% { opacity: 0; transform: translateY(-26px) scaleY(1.4) translateX(5px); }
}

/* ── COMPRAR ────────────────────────────────────────────────────────────── */
.comprar {
  padding: clamp(5rem, 11vw, 9rem) var(--pad);
  background: linear-gradient(var(--cream-2), var(--cream));
}
.comprar__grid {
  max-width: var(--maxw); margin: 0 auto;
  display: grid; grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 6vw, 5rem);
  align-items: center;
}

.comprar__figure { position: relative; display: grid; place-items: center; }
.comprar__glow {
  position: absolute; inset: 4%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(196,32,43,.14) 0%, transparent 68%);
  filter: blur(18px);
}
.comprar__img {
  position: relative;
  width: 100%; border-radius: 22px;
  box-shadow: var(--shadow-lg);
  transition: transform .5s var(--ease);
  will-change: transform;
}
.comprar__fallback { display: none; }
.comprar__figure.is-missing .comprar__img { display: none; }
.comprar__figure.is-missing .comprar__fallback {
  display: grid; place-items: center; gap: .75rem;
  aspect-ratio: 4/3; width: 100%;
  border: 3px dashed rgba(196,32,43,.35);
  border-radius: 22px; background: var(--cream-2);
  font-size: 2.5rem;
}
.comprar__fallback small { font-family: var(--f-body); font-size: .8rem; font-weight: 700; color: var(--ink-3); }
.comprar__fallback code { background: rgba(196,32,43,.1); color: var(--red); padding: .15em .45em; border-radius: 5px; font-size: .95em; }

.comprar__desc { color: var(--ink-2); font-weight: 700; margin-bottom: 2.25rem; }
.comprar__desc-soft { font-weight: 400; color: var(--ink-3); }

/* Opciones */
.opt { margin-bottom: 1.75rem; }
.opt__legend {
  font-size: .72rem; font-weight: 900;
  text-transform: uppercase; letter-spacing: .18em;
  color: var(--red); margin-bottom: .75rem;
}
.opt__row { display: flex; flex-wrap: wrap; gap: .75rem; }

.chip {
  position: relative;
  flex: 1 1 160px;
  padding: .9rem 1.1rem;
  background: var(--white);
  border: 2.5px solid rgba(196,32,43,.18);
  border-radius: 14px;
  text-align: left;
  transition: border-color .25s, transform .3s var(--ease-back), box-shadow .3s;
}
.chip:hover { border-color: rgba(196,32,43,.45); transform: translateY(-2px); }
.chip[aria-checked="true"] {
  border-color: var(--red);
  box-shadow: inset 0 0 0 1px var(--red), var(--shadow-sm);
  background: rgba(196,32,43,.05);
}
.chip__top { display: flex; align-items: baseline; justify-content: space-between; gap: .5rem; }
.chip__label { font-family: var(--f-display); font-size: 1.15rem; color: var(--red); }
.chip__price { font-weight: 900; font-size: 1rem; color: var(--ink); }
.chip__note  { display: block; font-size: .76rem; color: var(--ink-3); font-weight: 600; margin-top: .2rem; }

.chip__flag {
  position: absolute; top: -11px; right: .8rem;
  background: var(--red); color: var(--white);
  font-size: .58rem; font-weight: 900;
  letter-spacing: .1em; text-transform: uppercase;
  padding: .25rem .6rem; border-radius: 999px;
  box-shadow: var(--shadow-red);
}

/* Selector de método (aparece solo si es molido) */
.metodo {
  display: grid; grid-template-rows: 0fr;
  opacity: 0;
  transition: grid-template-rows .4s var(--ease), opacity .3s, margin .4s var(--ease);
  margin-top: 0;
}
.metodo.is-open { grid-template-rows: 1fr; opacity: 1; margin-top: .85rem; }
.metodo__inner { overflow: hidden; }
.metodo__label {
  display: block;
  font-size: .76rem; font-weight: 800; color: var(--ink-2);
  margin-bottom: .5rem;
}
.metodo__select {
  width: 100%; padding: .8rem 1rem;
  background: var(--white);
  border: 2.5px solid rgba(196,32,43,.18);
  border-radius: 12px;
  font-weight: 700; color: var(--ink);
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23C4202B' stroke-width='2.5' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  background-size: 18px;
  padding-right: 2.75rem;
}
.metodo__select:focus { border-color: var(--red); }

/* Cantidad */
.qty {
  display: inline-flex; align-items: center; gap: .25rem;
  background: var(--white);
  border: 2.5px solid rgba(196,32,43,.18);
  border-radius: 999px; padding: .3rem;
}
.qty__btn {
  width: 40px; height: 40px; border-radius: 50%;
  display: grid; place-items: center;
  font-size: 1.35rem; font-weight: 700; color: var(--red);
  transition: background .2s, transform .2s var(--ease-back);
}
.qty__btn:hover { background: rgba(196,32,43,.1); transform: scale(1.12); }
.qty__btn:disabled { opacity: .3; pointer-events: none; }
.qty__val { min-width: 42px; text-align: center; font-weight: 900; font-size: 1.15rem; }

/* Bloque de compra */
.buy {
  margin-top: 2.25rem; padding-top: 2rem;
  border-top: 2px dashed rgba(196,32,43,.22);
}
.buy__price { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 1.1rem; }
.buy__label  { font-size: .78rem; font-weight: 900; text-transform: uppercase; letter-spacing: .18em; color: var(--ink-3); }
.buy__amount { font-family: var(--f-display); font-size: 2.4rem; color: var(--red); line-height: 1; }
.buy__was {
  font-size: .48em; color: var(--ink-3);
  text-decoration-thickness: 2px;
  margin-right: .15em;
}
.buy__note   { margin-top: .85rem; font-size: .82rem; color: var(--ink-3); text-align: center; }

/* Regalo + envío */
.perks { display: grid; gap: .6rem; margin-top: 1.5rem; }
.perk {
  display: flex; align-items: flex-start; gap: .65rem;
  font-size: .85rem; font-weight: 600; color: var(--ink-2);
}
.perk__ic { font-size: 1rem; line-height: 1.35; flex: none; }
.perk strong { color: var(--ink); font-weight: 900; }

/* Barra de envío gratis */
.freeship {
  margin-top: 1.5rem; padding: 1rem 1.15rem;
  background: var(--white); border-radius: 14px;
  box-shadow: var(--shadow-sm);
}
.freeship__txt { font-size: .82rem; font-weight: 700; color: var(--ink-2); margin-bottom: .6rem; }
.freeship__txt b { color: var(--red); }
.freeship.is-done .freeship__txt { color: var(--wa-deep); }
.freeship.is-done .freeship__txt b { color: var(--wa-deep); }
.freeship__track { height: 8px; background: var(--cream-3); border-radius: 999px; overflow: hidden; }
.freeship__fill {
  display: block; height: 100%; width: 0%;
  background: linear-gradient(90deg, var(--red-soft), var(--red));
  border-radius: 999px;
  transition: width .6s var(--ease), background .3s;
}
.freeship.is-done .freeship__fill { background: linear-gradient(90deg, var(--wa), var(--wa-deep)); }

/* ── CIERRE ─────────────────────────────────────────────────────────────── */
.cierre {
  padding: clamp(5rem, 11vw, 8rem) var(--pad);
  background: var(--red);
  color: var(--white);
  text-align: center;
  position: relative; overflow: hidden;
}
.cierre::before {
  content: ''; position: absolute; inset: 0;
  background-image: radial-gradient(circle at 1px 1px, rgba(255,255,255,.16) 1px, transparent 0);
  background-size: 26px 26px;
  opacity: .5;
}
.cierre__inner { position: relative; max-width: 620px; margin: 0 auto; display: grid; gap: 2.5rem; justify-items: center; }
.cierre__quote {
  font-family: var(--f-display);
  font-size: clamp(1.8rem, 5vw, 3.2rem);
  line-height: 1.15;
}
.cierre__quote em { font-style: normal; color: var(--cream-3); }
.cierre__text { font-size: 1.02rem; color: rgba(250,241,222,.9); max-width: 46ch; }
.cierre__text strong { color: var(--white); font-weight: 900; }
.cierre .btn--primary { background: var(--white); color: var(--red); box-shadow: 0 14px 34px rgba(0,0,0,.22); max-width: 340px; }
.cierre .btn--primary:hover { background: var(--cream); }

/* ── FOOTER ─────────────────────────────────────────────────────────────── */
.footer { background: var(--ink); color: var(--cream); padding: clamp(3rem, 7vw, 5rem) var(--pad) 2rem; }
.footer__inner {
  max-width: var(--maxw); margin: 0 auto;
  display: grid; grid-template-columns: 1fr auto auto;
  gap: 2.5rem; align-items: start;
}
.footer .wordmark { color: var(--cream); }
.footer .bean-o::after { box-shadow: 0 0 0 .07em var(--ink); }
.footer__tag   { font-size: .72rem; font-weight: 800; letter-spacing: .18em; text-transform: uppercase; margin-top: .75rem; color: var(--ink-3); }
.footer__since { font-size: .72rem; font-weight: 800; letter-spacing: .18em; text-transform: uppercase; margin-top: .3rem; color: var(--ink-3); display: flex; align-items: center; gap: .4rem; }
.footer__since .dot::after { border-left-color: var(--ink); }

.footer__nav { display: grid; gap: .6rem; }
.footer__nav a { font-weight: 700; font-size: .92rem; color: var(--cream-3); transition: color .2s, transform .2s; }
.footer__nav a:hover { color: var(--white); transform: translateX(3px); }

.footer__contact { display: grid; gap: 1.25rem; justify-items: start; }
.footer__wa {
  display: inline-flex; align-items: center; gap: .6rem;
  padding: .7rem 1.2rem;
  background: rgba(37,211,102,.14);
  border: 1.5px solid rgba(37,211,102,.4);
  border-radius: 999px;
  font-weight: 800; font-size: .9rem; color: var(--wa);
  transition: background .25s, transform .25s var(--ease-back);
}
.footer__wa:hover { background: rgba(37,211,102,.24); transform: translateY(-2px); }
.footer__wa svg { width: 18px; height: 18px; }

.footer__social { display: flex; gap: .6rem; }
.footer__social a {
  width: 40px; height: 40px; display: grid; place-items: center;
  border-radius: 50%; background: rgba(250,241,222,.1);
  color: var(--cream-3);
  transition: background .25s, color .25s, transform .3s var(--ease-back);
}
.footer__social a:hover { background: var(--red); color: var(--white); transform: translateY(-3px) scale(1.08); }
.footer__social svg { width: 19px; height: 19px; }

.footer__legal {
  max-width: var(--maxw); margin: 3rem auto 0;
  padding-top: 1.75rem;
  border-top: 1px solid rgba(250,241,222,.14);
  font-size: .76rem; color: var(--ink-3); text-align: center;
}

/* ── WhatsApp flotante ──────────────────────────────────────────────────── */
.wa-float {
  position: fixed; right: 1.25rem; bottom: 1.25rem;
  z-index: 900;
  width: 56px; height: 56px;
  display: grid; place-items: center;
  background: var(--wa); color: #fff;
  border-radius: 50%;
  box-shadow: 0 10px 28px rgba(37,211,102,.45);
  transform: scale(0);
  transition: transform .45s var(--ease-back), box-shadow .3s;
}
.wa-float.is-in { transform: scale(1); }
.wa-float:hover { transform: scale(1.1) rotate(-6deg); }
.wa-float svg { width: 27px; height: 27px; }
.wa-float::after {
  content: ''; position: absolute; inset: 0;
  border-radius: 50%; border: 2px solid var(--wa);
  animation: ping 2.4s var(--ease) infinite;
}
@keyframes ping { 0% { transform: scale(1); opacity: .7; } 100% { transform: scale(1.7); opacity: 0; } }

/* ── DRAWER / CARRITO ───────────────────────────────────────────────────── */
.drawer-scrim {
  position: fixed; inset: 0; z-index: 1100;
  background: rgba(58,50,43,.5);
  backdrop-filter: blur(4px);
  opacity: 0; transition: opacity .4s var(--ease);
}
.drawer-scrim.is-open { opacity: 1; }

.drawer {
  position: fixed; top: 0; right: 0; bottom: 0;
  z-index: 1101;
  width: min(420px, 100vw);
  background: var(--cream);
  display: flex; flex-direction: column;
  box-shadow: -20px 0 60px rgba(58,50,43,.25);
  transform: translateX(100%);
  transition: transform .5s var(--ease);
  visibility: hidden;
}
.drawer.is-open { transform: none; visibility: visible; }

.drawer__head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 1.5rem; border-bottom: 2px dashed rgba(196,32,43,.2);
  flex: none;
}
.drawer__title { font-family: var(--f-display); font-weight: 400; font-size: 1.6rem; color: var(--red); }
.drawer__close {
  width: 40px; height: 40px; display: grid; place-items: center;
  border-radius: 50%; color: var(--red);
  transition: background .2s, transform .3s var(--ease-back);
}
.drawer__close:hover { background: rgba(196,32,43,.1); transform: rotate(90deg); }
.drawer__close svg { width: 20px; height: 20px; }

.drawer__body { flex: 1; overflow-y: auto; padding: 1.25rem 1.5rem; }

.drawer__empty { text-align: center; padding: 3rem 1rem; color: var(--ink-3); display: grid; gap: 1rem; justify-items: center; }
.drawer__empty .wordmark { font-size: 2.2rem; opacity: .25; }
.drawer__empty p { font-weight: 700; }

.line {
  display: grid; grid-template-columns: 1fr auto;
  gap: .5rem 1rem; align-items: center;
  padding: 1rem 0;
  border-bottom: 1.5px dashed rgba(196,32,43,.18);
  animation: lineIn .4s var(--ease-back);
}
@keyframes lineIn { from { opacity: 0; transform: translateX(20px); } }
.line__name { font-family: var(--f-display); font-size: 1.15rem; color: var(--red); }
.line__meta { font-size: .78rem; font-weight: 700; color: var(--ink-3); }
.line__price { font-weight: 900; }
.line__ctrl { display: flex; align-items: center; gap: .3rem; }
.line__btn {
  width: 28px; height: 28px; border-radius: 50%;
  display: grid; place-items: center;
  color: var(--red); font-weight: 800;
  background: rgba(196,32,43,.08);
  transition: background .2s;
}
.line__btn:hover { background: rgba(196,32,43,.2); }
.line__qty { min-width: 28px; text-align: center; font-weight: 900; font-size: .9rem; }
.line__del { font-size: .74rem; font-weight: 800; color: var(--ink-3); text-decoration: underline; }
.line__del:hover { color: var(--red); }

.drawer__foot {
  flex: none; padding: 1.25rem 1.5rem 1.5rem;
  border-top: 2px dashed rgba(196,32,43,.2);
  background: var(--cream-2);
  display: grid; gap: .85rem;
  max-height: 70vh; overflow-y: auto;
}
.drawer__total {
  display: flex; align-items: baseline; justify-content: space-between; gap: .75rem;
  padding-top: .75rem;
  border-top: 2px solid rgba(196,32,43,.18);
}
.drawer__total > span {
  font-size: .78rem; font-weight: 900; text-transform: uppercase;
  letter-spacing: .18em; color: var(--ink-3);
  display: flex; flex-direction: column; gap: .2rem;
}
.drawer__total-tag {
  font-size: .58rem; font-weight: 900; letter-spacing: .1em;
  color: var(--wa-deep); text-transform: uppercase;
}
.drawer__total strong { font-family: var(--f-display); font-size: 2rem; color: var(--red); }
.drawer__note { font-size: .74rem; color: var(--ink-3); text-align: center; }

/* Selector de zona de envío */
.zona__legend {
  font-size: .7rem; font-weight: 900;
  text-transform: uppercase; letter-spacing: .16em;
  color: var(--red); margin-bottom: .6rem;
}
.zona__row { display: flex; gap: .5rem; }
.zona__chip {
  flex: 1;
  padding: .6rem .7rem;
  background: var(--white);
  border: 2px solid rgba(196,32,43,.18);
  border-radius: 11px;
  text-align: left;
  transition: border-color .2s, background .2s;
}
.zona__chip:hover { border-color: rgba(196,32,43,.45); }
.zona__chip[aria-checked="true"] {
  border-color: var(--red);
  background: rgba(196,32,43,.06);
  box-shadow: inset 0 0 0 1px var(--red);
}
.zona__chip b { display: block; font-size: .8rem; font-weight: 900; color: var(--ink); }
.zona__chip small { display: block; font-size: .66rem; color: var(--ink-3); font-weight: 700; margin-top: .1rem; }

/* Desglose de totales */
.totals { display: grid; gap: .4rem; }
.totals__row {
  display: flex; align-items: baseline; justify-content: space-between; gap: .75rem;
  font-size: .84rem; font-weight: 700; color: var(--ink-2);
}
.totals__row dt { display: flex; align-items: center; gap: .35rem; }
.totals__row dd { font-weight: 800; color: var(--ink); white-space: nowrap; }
.totals__row--promo dt,
.totals__row--promo dd { color: var(--red); font-weight: 900; }
.totals__row--free dt,
.totals__row--free dd { color: var(--wa-deep); font-weight: 900; }
.totals__row--soft dd { color: var(--ink-3); font-weight: 700; font-style: italic; }
.totals__hint {
  font-size: .7rem; font-weight: 600; color: var(--ink-3);
  line-height: 1.35; margin-top: .1rem;
}

/* ── TOAST ──────────────────────────────────────────────────────────────── */
.toast {
  position: fixed; left: 50%; bottom: 2rem;
  z-index: 1200;
  transform: translate(-50%, 140%);
  background: var(--ink); color: var(--cream);
  padding: .9rem 1.5rem; border-radius: 999px;
  font-weight: 800; font-size: .9rem;
  box-shadow: var(--shadow);
  transition: transform .5s var(--ease-back);
  pointer-events: none;
  max-width: calc(100vw - 2rem);
  text-align: center;
}
.toast.is-in { transform: translate(-50%, 0); }

/* ── Reveal on scroll ───────────────────────────────────────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .8s var(--ease), transform .8s var(--ease);
}
.reveal.is-in { opacity: 1; transform: none; }
.reveal[data-delay="1"] { transition-delay: .08s; }
.reveal[data-delay="2"] { transition-delay: .16s; }
.reveal[data-delay="3"] { transition-delay: .24s; }
.reveal[data-delay="4"] { transition-delay: .32s; }
.reveal[data-delay="5"] { transition-delay: .40s; }
.reveal[data-delay="6"] { transition-delay: .48s; }
.reveal[data-delay="7"] { transition-delay: .56s; }
.reveal[data-delay="8"] { transition-delay: .64s; }

/* ══ Responsive ═════════════════════════════════════════════════════════ */
@media (max-width: 980px) {
  .historia__grid { grid-template-columns: 1fr; }
  .historia__figure { order: -1; max-width: 380px; margin: 0 auto; }

  .lote { grid-template-columns: 1fr; }
  .lote__media { height: 52vh; order: -1; }
  .lote__tear { top: auto; bottom: -1px; left: 0; right: 0; width: auto; height: 40px;
    clip-path: polygon(
      0 100%, 0 0, 4% 62%, 9% 88%, 14% 55%, 19% 92%, 25% 60%, 31% 85%, 37% 52%,
      43% 90%, 49% 58%, 55% 86%, 61% 54%, 67% 93%, 73% 60%, 79% 84%, 85% 52%,
      91% 90%, 96% 62%, 100% 0, 100% 100%
    );
  }

  .comprar__grid { grid-template-columns: 1fr; }
  .comprar__figure { max-width: 460px; margin: 0 auto; }

  .footer__inner { grid-template-columns: 1fr; gap: 2rem; }
}

@media (max-width: 720px) {
  :root { --nav-h: 62px; }
  html.has-promo { --promo-h: 52px; }

  .promo-bar__inner { flex-direction: column; gap: .15rem; font-size: .7rem; line-height: 1.2; }
  .promo-bar__count { font-size: .62rem; padding: .1rem .5rem; }

  .zona__row { flex-direction: column; }
  .drawer__foot { max-height: 62vh; }

  .nav__links { display: none; }
  .nav__logo { opacity: 1; transform: none; pointer-events: auto; }

  .hero { padding-bottom: 5rem; }
  .hero__badge { margin-top: 1.75rem; }
  .hero__cta { width: 100%; flex-direction: column; }
  .hero__cta .btn { width: 100%; }
  .hero__branch { opacity: .3; width: 130px; bottom: -2%; }

  .score { gap: .75rem; padding: .7rem 1.1rem; }
  .score__num { font-size: 2.6rem; }

  .ficha__row { grid-template-columns: 1fr; gap: .3rem; }

  .steps { grid-template-columns: 1fr; gap: 1.75rem; }

  .chip { flex: 1 1 100%; }

  .drawer { width: 100vw; }

  .wa-float { right: 1rem; bottom: 1rem; width: 52px; height: 52px; }

  .toast { bottom: 5.5rem; }
}

/* ══ Accesibilidad: movimiento reducido ═════════════════════════════════ */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
  .reveal { opacity: 1 !important; transform: none !important; }
  .hero__beans { display: none; }
  .wa-float { transform: scale(1); }
  .wa-float::after { display: none; }
}

/* ══ Impresión ══════════════════════════════════════════════════════════ */
@media print {
  .nav, .wa-float, .drawer, .drawer-scrim, .grain, .progress, .scroll-cue { display: none !important; }
  .reveal { opacity: 1 !important; transform: none !important; }
}
