/* =========================================================
   BIORGANIK — Tokens y base
   Concepto: tienda editorial de bienestar. Crema cálido + verde bosque,
   composición asimétrica, envases originales como protagonistas.
   Diseño deliberadamente de un solo tema (claro), con colores explícitos.
   ========================================================= */
:root {
  /* Color */
  --forest: #144B2B;
  --forest-d: #0D3A20;
  --forest-l: #2E7D32;
  --cream: #F8F5DF;
  --cream-2: #F0EBCB;
  --sage: #E1EBDD;
  --sage-2: #D2E1CB;
  --white: #FFFFFF;
  --ink: #27392D;
  --muted: #5E6352;  /* oliva grisáceo del kit, oscurecido para contraste AA */
  --line: #D6E0D0;
  --blush: #F3E6E6;
  --peach: #F6E8D4;
  --lilac: #ECE8F1;
  --warn: #8A5A12;
  --warn-bg: #FBF1DC;
  --danger: #A23B2A;

  /* Tipografía */
  --font: 'Inter', 'Segoe UI', system-ui, -apple-system, sans-serif;
  --font-head: 'Manrope', 'Segoe UI', system-ui, sans-serif;
  --fs-display: clamp(2.6rem, 1.4rem + 4.4vw, 4.6rem);
  --fs-h1: clamp(2.1rem, 1.5rem + 2.4vw, 3.4rem);
  --fs-h2: clamp(1.85rem, 1.3rem + 2vw, 2.9rem);
  --fs-h3: clamp(1.4rem, 1.15rem + 0.9vw, 1.85rem);
  --fs-h4: 1.2rem;
  --fs-lead: clamp(1.02rem, 0.98rem + 0.25vw, 1.15rem);
  --fs-body: 0.98rem;
  --fs-sm: 0.86rem;
  --fs-xs: 0.74rem;

  /* Forma */
  --r-xl: 32px;
  --r-lg: 24px;
  --r-md: 16px;
  --r-sm: 10px;
  --shadow: 0 1px 2px rgba(20, 62, 38, .04), 0 8px 24px -12px rgba(20, 62, 38, .12);
  --shadow-lg: 0 24px 60px -24px rgba(20, 62, 38, .28);
  --wrap: 1240px;
  --gutter: max(20px, env(safe-area-inset-left, 0px));
  --ease: cubic-bezier(.22, .7, .2, 1);
  --header-h: 76px;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--header-h) + 20px); }
body {
  margin: 0;
  font-family: var(--font);
  font-size: var(--fs-body);
  line-height: 1.6;
  color: var(--ink);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
body.no-scroll { overflow: hidden; }
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 60; background: var(--cream); }
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4 { margin: 0; font-family: var(--font-head); color: var(--forest); font-weight: 800; letter-spacing: -0.035em; line-height: 1.08; text-wrap: balance; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
figure { margin: 0; }
code { font-size: .9em; background: var(--sage); padding: 1px 6px; border-radius: 6px; }
:focus-visible { outline: 2px solid var(--forest); outline-offset: 3px; border-radius: 6px; }
::selection { background: var(--sage-2); }
#app { outline: none; min-height: 60vh; }

.wrap {
  width: 100%;
  max-width: calc(var(--wrap) + 2 * 24px);
  margin-inline: auto;
  padding-left: max(20px, env(safe-area-inset-left, 0px));
  padding-right: max(20px, env(safe-area-inset-right, 0px));
}
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--forest); color: var(--white); padding: 10px 16px; border-radius: 10px; }
.skip:focus { top: 12px; }

/* Tipografía */
.display { font-size: var(--fs-display); letter-spacing: -0.045em; line-height: 1.02; font-weight: 800; }
.display--md { font-size: clamp(2.3rem, 1.4rem + 3.4vw, 3.9rem); }
.h1 { font-size: var(--fs-h1); letter-spacing: -0.04em; }
.h2 { font-size: var(--fs-h2); letter-spacing: -0.04em; }
.h3 { font-size: var(--fs-h3); }
.h4 { font-size: var(--fs-h4); letter-spacing: -0.02em; }
.lead { font-size: var(--fs-lead); color: var(--ink); opacity: .86; max-width: 46ch; line-height: 1.6; }
.sub { color: var(--muted); max-width: 52ch; margin-top: 12px; }
.eyebrow { font-size: var(--fs-xs); font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--forest-l); margin-bottom: 14px; }
.fine { font-size: var(--fs-xs); color: var(--muted); line-height: 1.5; }
.muted { color: var(--muted); }
.br-lg { display: none; }
@media (min-width: 900px) { .br-lg { display: inline; } }

/* Botones */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  min-height: 48px; padding: 0 22px; border-radius: 999px;
  font-family: var(--font-head); font-weight: 700; font-size: .95rem; letter-spacing: -0.01em; white-space: nowrap;
  transition: background .25s var(--ease), color .25s var(--ease), border-color .25s var(--ease), transform .25s var(--ease);
}
.btn:active { transform: translateY(1px); }
.btn--primary { background: var(--forest); color: var(--white); }
.btn--primary:hover { background: var(--forest-d); }
.btn--line { border: 1.5px solid var(--forest); color: var(--forest); }
.btn--line:hover { background: var(--forest); color: var(--white); }
.btn--ghost { color: var(--forest); background: var(--sage); }
.btn--ghost:hover { background: var(--sage-2); }
.btn--cream { background: var(--cream); color: var(--forest-d); }
.btn--cream:hover { background: var(--white); }
.btn--text { padding: 0 4px; min-height: 40px; color: var(--forest); }
.btn--text .ico { transition: transform .25s var(--ease); }
.btn--text:hover .ico { transform: translateX(4px); }
.btn--block { width: 100%; }
.btn--grow { flex: 1; }
.btn--lg { min-height: 56px; font-size: 1rem; }
.btnrow { display: flex; flex-wrap: wrap; gap: 12px 18px; align-items: center; }
.btnrow--center { justify-content: center; }
.linkbtn { color: var(--forest); font-weight: 600; font-size: var(--fs-sm); text-decoration: underline; text-underline-offset: 3px; display: inline-flex; align-items: center; gap: 6px; }
.linkbtn:hover { color: var(--forest-d); }

.iconbtn {
  display: inline-grid; place-items: center; width: 42px; height: 42px; border-radius: 50%;
  color: var(--forest); transition: background .2s var(--ease), transform .2s var(--ease);
  flex: none;
}
.iconbtn:hover { background: var(--sage); }
.iconbtn--solid { background: var(--forest); color: var(--white); width: 40px; height: 40px; }
.iconbtn--solid:hover { background: var(--forest-d); transform: scale(1.06); }
.iconbtn--lg { width: 52px; height: 52px; }
.iconbtn--line { border: 1.5px solid var(--line); background: var(--white); }
.iconbtn--line:hover { border-color: var(--forest); background: var(--white); }

/* Chips y etiquetas */
.chip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 7px 14px; border-radius: 999px; font-size: var(--fs-sm); font-weight: 500;
  background: var(--sage); color: var(--forest); transition: background .2s, color .2s;
}
a.chip:hover, button.chip:hover { background: var(--sage-2); }
.chip--line { background: transparent; border: 1px solid var(--line); background: var(--white); }
.chip--sm { padding: 4px 10px; font-size: var(--fs-xs); }
.chip--tab.is-on { background: var(--forest); color: var(--white); }
.tag { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 999px; font-size: var(--fs-xs); font-weight: 600; }
.tag--save { background: var(--sage); color: var(--forest); }
.pending {
  display: inline-flex; align-items: center; gap: 4px; margin-left: 6px; vertical-align: middle;
  padding: 2px 8px; border-radius: 999px; border: 1px dashed currentColor;
  font-size: .68rem; font-weight: 600; letter-spacing: .02em; color: var(--warn); background: var(--warn-bg);
  white-space: nowrap;
}
.price { font-family: var(--font-head); font-weight: 800; color: var(--forest); font-size: 1.5rem; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.price--sm { font-size: 1.05rem; }
.price--lg { font-size: 2rem; }
.price--ask { font-weight: 600; color: var(--forest-l); font-size: 1.05rem; letter-spacing: -0.01em; }
.price--sm.price--ask { font-size: .9rem; }

.note { display: flex; gap: 8px; align-items: flex-start; font-size: var(--fs-sm); color: var(--muted); line-height: 1.5; }
.note .ico { flex: none; margin-top: 2px; color: var(--forest-l); }
.note--warn { color: var(--warn); background: var(--warn-bg); padding: 10px 14px; border-radius: var(--r-sm); }
.note--warn .ico { color: var(--warn); }

/* Revelado suave: siempre visible en reposo, solo desplazamiento */
.reveal { transform: translateY(14px); transition: transform .9s var(--ease); }
.reveal.in { transform: none; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
  .reveal { transform: none; }
}
