/* ============================================================
   VIVERO AGRONOMÍA — Sistema visual compartido
   Branding de viveroagronomia.com.ar · Marcellus + Nunito Sans
   Verde bosque #1A4032 · Verde agua #0C5D57 · Crema #FFFCF3
   Pasteles: salvia · lila · manteca · rosa
   ============================================================ */

:root {
  /* Papel / tinta */
  --paper:        #FFFCF3;
  --paper-2:      #F6F2E6;
  --paper-3:      #EEE9DA;
  --card:         #FFFFFF;
  --ink:          #1A4032;
  --ink-soft:     #3F5A4F;
  --ink-faint:    #5E6E67;

  /* Verde marca */
  --green:        #1A4032;
  --green-deep:   #12302A;
  --green-mid:    #0C5D57;
  --green-soft:   #D6E3DB;
  --green-tint:   #EAF1EC;

  /* Acento (verde agua) — mantiene los nombres "clay" por compatibilidad */
  --clay:         #0C5D57;
  --clay-deep:    #0A4C47;
  --clay-soft:    #FFF7A4;

  /* Pasteles de marca */
  --sage:         #D9E6DE;
  --lilac:        #EFECF3;
  --butter:       #FFF7A4;
  --pink:         #F8C8E1;
  --berry:        #A3245B;

  /* Apoyo */
  --honey:        #C08A12;
  --line:         #E4E1D3;
  --line-strong:  #CFCBB9;
  --shadow:       rgba(26, 64, 50, 0.12);
  --shadow-soft:  rgba(26, 64, 50, 0.06);

  --r-sm: 8px;
  --r-md: 14px;
  --r-lg: 20px;
  --r-xl: 28px;
  --r-pill: 999px;

  --maxw: 1280px;
  --header-h: 116px;

  --serif: 'Marcellus', Georgia, serif;
  --sans: 'Nunito Sans', system-ui, -apple-system, sans-serif;
  --mono: 'SFMono-Regular', ui-monospace, 'Cascadia Code', Menlo, monospace;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--sans);
  background: var(--paper);
  color: var(--ink);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
ul { margin: 0; padding: 0; list-style: none; }

h1, h2, h3, h4 {
  font-family: var(--serif);
  font-weight: 400;
  line-height: 1.08;
  margin: 0;
  letter-spacing: 0;
  color: var(--green);
}

.serif { font-family: var(--serif); }
.mono { font-family: var(--mono); }

.container { max-width: var(--maxw); margin: 0 auto; padding: 0 28px; }
.eyebrow {
  font-size: 0.72rem; font-weight: 600; letter-spacing: 0.18em;
  text-transform: uppercase; color: var(--clay-deep);
}
.muted { color: var(--ink-faint); }

/* ---------- Breadcrumb (compartido) ---------- */
.breadcrumb { display: flex; align-items: center; flex-wrap: wrap; gap: 0.5rem; font-size: 0.82rem; color: var(--ink-faint); }
.breadcrumb a:hover { color: var(--green-deep); }
.breadcrumb svg { width: 13px; height: 13px; opacity: 0.5; flex-shrink: 0; }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 0.55em;
  font-family: var(--sans); font-weight: 600; font-size: 0.94rem;
  padding: 0.85em 1.5em; border-radius: var(--r-pill);
  border: 1px solid transparent; transition: all 0.2s ease;
  white-space: nowrap; line-height: 1;
}
.btn svg { width: 1.05em; height: 1.05em; }
.btn-primary { background: var(--green); color: var(--paper); }
.btn-primary:hover { background: var(--green-deep); transform: translateY(-1px); }
.btn-clay { background: var(--clay); color: #fff; }
.btn-clay:hover { background: var(--clay-deep); transform: translateY(-1px); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line-strong); }
.btn-ghost:hover { background: var(--green-tint); border-color: var(--green); color: var(--green-deep); }
.btn-light { background: var(--card); color: var(--ink); border-color: var(--line); }
.btn-light:hover { background: var(--green-tint); border-color: var(--green-mid); }
.btn-lg { padding: 1.05em 1.9em; font-size: 1rem; }
.btn-block { display: flex; width: 100%; justify-content: center; }

/* ---------- Iconos / chips genéricos ---------- */
.icon-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 44px; height: 44px; border-radius: var(--r-pill);
  background: transparent; border: 1px solid transparent; color: var(--ink);
  position: relative; transition: background 0.18s ease;
}
.icon-btn:hover { background: var(--green-tint); }
.icon-btn svg { width: 21px; height: 21px; }
.icon-btn .count {
  position: absolute; top: 2px; right: 0px; min-width: 18px; height: 18px;
  padding: 0 4px; border-radius: var(--r-pill); background: var(--berry); color: #fff;
  font-size: 0.66rem; font-weight: 700; display: flex; align-items: center; justify-content: center;
  font-family: var(--sans);
}

.badge {
  display: inline-flex; align-items: center; gap: 0.4em;
  font-size: 0.7rem; font-weight: 600; letter-spacing: 0.02em;
  padding: 0.36em 0.7em; border-radius: var(--r-pill);
  background: var(--green-soft); color: var(--green-deep);
}
.badge svg { width: 0.95em; height: 0.95em; }
.badge.clay { background: var(--lilac); color: var(--green); }
.badge.honey { background: var(--butter); color: #5C4A00; }
.badge.sale { background: var(--berry); color: #fff; }

/* ============================================================
   HEADER  (compartido)
   ============================================================ */
.topbar {
  background: var(--green-deep); color: var(--green-soft);
  font-size: 0.8rem; letter-spacing: 0.01em;
}
.topbar .container { display: flex; align-items: center; justify-content: center; gap: 2.4rem; height: 38px; }
.topbar .tb-item { display: inline-flex; align-items: center; gap: 0.5em; white-space: nowrap; }
.topbar svg { width: 15px; height: 15px; opacity: 0.85; }
.topbar .tb-hide { }
@media (max-width: 720px){ .topbar .tb-hide { display: none; } }

.site-header { position: sticky; top: 0; z-index: 60; background: var(--paper); border-bottom: 1px solid var(--line); }
.header-main { display: flex; align-items: center; gap: 1.6rem; height: 78px; }
.logo { display: flex; align-items: center; gap: 0.6rem; flex-shrink: 0; }
.logo-mark {
  width: 38px; height: 38px; border-radius: 50%;
  background: var(--green); color: var(--paper);
  display: flex; align-items: center; justify-content: center;
}
.logo-mark svg { width: 22px; height: 22px; }
.logo-text { line-height: 1; }
.logo-text b { font-family: var(--serif); font-weight: 600; font-size: 1.32rem; display: block; letter-spacing: -0.02em; }
.logo-text span { font-size: 0.64rem; letter-spacing: 0.26em; text-transform: uppercase; color: var(--ink-faint); }

.logo { display: flex; align-items: center; flex-shrink: 0; }
.logo-img { height: 34px; width: auto; display: block; }
.logo-img-light { filter: brightness(0) invert(1); }

.search {
  flex: 1; max-width: 480px; display: flex; align-items: center; gap: 0.6rem;
  background: var(--paper-2); border: 1px solid var(--line); border-radius: var(--r-pill);
  padding: 0.7rem 1.1rem; color: var(--ink-faint); transition: border 0.18s;
}
.search:focus-within { border-color: var(--green-mid); background: var(--card); }
.search svg { width: 18px; height: 18px; flex-shrink: 0; }
.search input { border: none; background: transparent; outline: none; font-family: inherit; font-size: 0.92rem; color: var(--ink); width: 100%; }
.header-actions { display: flex; align-items: center; gap: 0.2rem; margin-left: auto; }

.nav-bar { border-top: 1px solid var(--line); }
.nav-list { display: flex; align-items: center; gap: 0.3rem; height: 52px; }
.nav-list > li > a {
  display: flex; align-items: center; gap: 0.4em; padding: 0.5em 0.9em; border-radius: var(--r-sm);
  font-size: 0.9rem; font-weight: 500; color: var(--ink-soft); transition: all 0.15s;
}
.nav-list > li > a:hover { color: var(--green-deep); background: var(--green-tint); }
.nav-list > li > a svg { width: 14px; height: 14px; opacity: 0.6; }
.nav-spacer { flex: 1; }
.nav-link-clay { color: var(--clay-deep) !important; font-weight: 600 !important; }

/* mega dropdown */
.has-mega { position: relative; }
.mega {
  position: absolute; top: calc(100% + 8px); left: 0; z-index: 70;
  background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg);
  box-shadow: 0 24px 50px -22px var(--shadow); padding: 1.5rem; width: 640px;
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.3rem 2rem;
  opacity: 0; visibility: hidden; transform: translateY(-6px); transition: all 0.18s ease;
}
.has-mega:hover .mega { opacity: 1; visibility: visible; transform: translateY(0); }
.mega h5 { font-family: var(--sans); font-size: 0.72rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--clay-deep); margin: 0 0 0.7rem; }
.mega a { display: block; font-size: 0.88rem; color: var(--ink-soft); padding: 0.28em 0; transition: color 0.12s; }
.mega a:hover { color: var(--green); }

.menu-toggle { display: none; }

/* ============================================================
   PRODUCT CARD  (compartido)
   ============================================================ */
.product-card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg);
  overflow: hidden; display: flex; flex-direction: column; position: relative;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}
.product-card:hover { transform: translateY(-4px); box-shadow: 0 24px 40px -26px var(--shadow); border-color: var(--green-soft); }
.pc-media { position: relative; aspect-ratio: 1 / 1; overflow: hidden; }
.pc-media .ph-img { width: 100%; height: 100%; }
.pc-badges { position: absolute; top: 12px; left: 12px; display: flex; flex-direction: column; gap: 6px; align-items: flex-start; z-index: 2; }
.pc-fav {
  position: absolute; top: 10px; right: 10px; z-index: 3;
  width: 38px; height: 38px; border-radius: 50%; background: oklch(1 0 0 / 0.9);
  border: 1px solid var(--line); display: flex; align-items: center; justify-content: center;
  color: var(--ink-soft); transition: all 0.16s; backdrop-filter: blur(4px);
}
.pc-fav svg { width: 18px; height: 18px; }
.pc-fav:hover { color: var(--berry); transform: scale(1.08); }
.pc-fav.active { color: var(--berry); background: #FDEAF3; border-color: var(--berry); }
.pc-fav.active svg { fill: currentColor; }
.pc-quick {
  position: absolute; left: 12px; right: 12px; bottom: 12px; z-index: 3;
  opacity: 0; transform: translateY(8px); transition: all 0.2s ease;
}
.product-card:hover .pc-quick { opacity: 1; transform: translateY(0); }
.pc-body { padding: 1rem 1.1rem 1.2rem; display: flex; flex-direction: column; gap: 0.35rem; flex: 1; }
.pc-cat { font-size: 0.7rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-faint); }
.pc-name { font-family: var(--serif); font-size: 1.18rem; font-weight: 500; line-height: 1.1; }
.pc-name a:hover { color: var(--green); }
.pc-sci { font-size: 0.78rem; font-style: italic; color: var(--ink-faint); margin-top: -0.1rem; }
.pc-tags { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 0.2rem; }
.pc-tag { font-size: 0.68rem; color: var(--green-deep); background: var(--green-tint); padding: 0.22em 0.6em; border-radius: var(--r-pill); display: inline-flex; align-items: center; gap: 0.3em; }
.pc-tag svg { width: 12px; height: 12px; }
.pc-foot { margin-top: auto; padding-top: 0.6rem; display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; }
.pc-price { font-size: 1.12rem; font-weight: 700; }
.pc-price .from { font-size: 0.72rem; font-weight: 500; color: var(--ink-faint); display: block; line-height: 1; margin-bottom: 1px; }
.pc-price .old { font-size: 0.82rem; font-weight: 500; color: var(--ink-faint); text-decoration: line-through; margin-left: 0.4em; }
.pc-add {
  width: 42px; height: 42px; border-radius: 50%; background: var(--green-tint); color: var(--green-deep);
  border: 1px solid var(--green-soft); display: flex; align-items: center; justify-content: center; flex-shrink: 0;
  transition: all 0.16s;
}
.pc-add svg { width: 19px; height: 19px; }
.pc-add:hover { background: var(--green); color: #fff; border-color: var(--green); }
.pc-out { font-size: 0.8rem; font-weight: 600; color: var(--clay-deep); }

/* ---------- Placeholder de imagen (rayado) ---------- */
.ph-img {
  position: relative; display: flex; align-items: flex-end; justify-content: flex-start;
  background-color: var(--green-tint); overflow: hidden;
}
.ph-img::before {
  content: ''; position: absolute; inset: 0;
  background-image: repeating-linear-gradient(135deg,
    transparent 0, transparent 11px,
    oklch(0.40 0.06 158 / 0.07) 11px, oklch(0.40 0.06 158 / 0.07) 12px);
}
.ph-img > span {
  position: relative; z-index: 1; margin: 10px; font-family: var(--mono);
  font-size: 0.64rem; letter-spacing: 0.04em; color: var(--green-deep);
  background: oklch(1 0 0 / 0.7); padding: 0.25em 0.55em; border-radius: 5px;
}
.ph-clay { background-color: var(--lilac); }
.ph-clay::before { background-image: repeating-linear-gradient(135deg, transparent 0, transparent 11px, rgba(26,64,50,.07) 11px, rgba(26,64,50,.07) 12px); }
.ph-clay > span { color: var(--green); }

/* ============================================================
   FOOTER  (compartido)
   ============================================================ */
.site-footer { background: var(--green-deep); color: oklch(0.88 0.03 150); margin-top: 5rem; }
.footer-cta {
  background: var(--green); padding: 3.2rem 0; text-align: center;
}
.footer-cta h2 { color: var(--paper); font-size: clamp(1.8rem, 4vw, 2.8rem); max-width: 18ch; margin: 0 auto 0.5rem; }
.footer-cta p { color: var(--green-soft); margin: 0 auto 1.6rem; max-width: 42ch; }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1.4fr; gap: 2.5rem; padding: 4rem 0 2.5rem; }
.footer-grid h5 { font-family: var(--sans); font-size: 0.74rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--green-mid); margin: 0 0 1.1rem; }
.footer-grid a { display: block; color: oklch(0.85 0.03 150); font-size: 0.9rem; padding: 0.3em 0; transition: color 0.14s; }
.footer-grid a:hover { color: #fff; }
.footer-brand .logo-text b { color: var(--paper); }
.footer-brand .logo-text span { color: var(--green-mid); }
.footer-brand p { font-size: 0.9rem; line-height: 1.6; margin: 1.1rem 0 1.4rem; max-width: 32ch; color: oklch(0.82 0.03 150); }
.footer-social { display: flex; gap: 0.6rem; }
.footer-social a { width: 40px; height: 40px; border-radius: 50%; border: 1px solid oklch(0.6 0.04 155); display: flex; align-items: center; justify-content: center; }
.footer-social a:hover { background: var(--green); border-color: var(--green); }
.footer-social svg { width: 18px; height: 18px; }
.footer-info { display: flex; align-items: flex-start; gap: 0.6em; font-size: 0.9rem; margin-bottom: 0.9rem; color: oklch(0.85 0.03 150); }
.footer-info svg { width: 17px; height: 17px; margin-top: 2px; flex-shrink: 0; color: var(--green-mid); }
.footer-bottom { border-top: 1px solid oklch(0.45 0.04 155); padding: 1.4rem 0; display: flex; justify-content: space-between; align-items: center; gap: 1rem; font-size: 0.8rem; color: oklch(0.72 0.03 150); flex-wrap: wrap; }
.footer-pay { display: flex; gap: 0.5rem; align-items: center; }
.footer-pay span { font-size: 0.68rem; padding: 0.3em 0.6em; border: 1px solid oklch(0.5 0.04 155); border-radius: 5px; }

/* ============================================================
   UTILIDADES de layout / secciones
   ============================================================ */
.section { padding: 4.5rem 0; }
.section-sm { padding: 3rem 0; }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 1.5rem; margin-bottom: 2.2rem; flex-wrap: wrap; }
.section-head h2 { font-size: clamp(1.7rem, 3.4vw, 2.5rem); }
.section-head p { color: var(--ink-faint); margin: 0.5rem 0 0; max-width: 46ch; }
.link-arrow { display: inline-flex; align-items: center; gap: 0.4em; font-weight: 600; font-size: 0.92rem; color: var(--green-deep); }
.link-arrow svg { width: 16px; height: 16px; transition: transform 0.18s; }
.link-arrow:hover svg { transform: translateX(3px); }

.grid-products { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.4rem; }
@media (max-width: 1080px){ .grid-products { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 760px){ .grid-products { grid-template-columns: repeat(2, 1fr); gap: 1rem; } }

/* Imágenes reales en tarjetas de producto */
.pc-media img, .qv-media img, .gal-main img, .gal-thumb img { width:100%; height:100%; object-fit:cover; display:block; }
.ig-card img { position:absolute; inset:0; width:100%; height:100%; object-fit:cover; display:block; }
.cat-card img { position:absolute; inset:0; width:100%; height:100%; object-fit:cover; display:block; }
.season-media img, .advice-media img { width:100%; height:100%; object-fit:cover; display:block; }
.hero-media img { width:100%; height:100%; min-height:540px; object-fit:cover; display:block; }

/* ---------- Toast ---------- */
.toast-wrap { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%); z-index: 200; display: flex; flex-direction: column; gap: 10px; align-items: center; pointer-events: none; }
.toast {
  background: var(--ink); color: var(--paper); padding: 0.85rem 1.3rem; border-radius: var(--r-pill);
  font-size: 0.88rem; font-weight: 500; box-shadow: 0 16px 30px -12px var(--shadow);
  display: flex; align-items: center; gap: 0.7em; animation: toastIn 0.3s ease;
}
.toast svg { width: 18px; height: 18px; color: var(--green-mid); }
@keyframes toastIn { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }

/* ---------- Reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(20px); transition: opacity 0.7s ease, transform 0.7s ease; }
.reveal.in { opacity: 1; transform: none; }

/* ============================================================
   OVERLAY · MENÚ MOBILE · CARRITO DRAWER
   ============================================================ */
.overlay {
  position: fixed; inset: 0; background: oklch(0.2 0.03 150 / 0.45); z-index: 90;
  opacity: 0; visibility: hidden; transition: opacity 0.25s ease; backdrop-filter: blur(2px);
}
.overlay.show { opacity: 1; visibility: visible; }

.mobile-menu {
  position: fixed; top: 0; left: 0; bottom: 0; width: min(86vw, 360px); z-index: 100;
  background: var(--paper); transform: translateX(-100%); transition: transform 0.3s cubic-bezier(.4,0,.2,1);
  display: flex; flex-direction: column; box-shadow: 0 0 40px -10px var(--shadow);
}
.mobile-menu.open { transform: translateX(0); }
.mm-head { display: flex; align-items: center; justify-content: space-between; padding: 1rem 1.2rem; border-bottom: 1px solid var(--line); }
.mm-nav { padding: 0.8rem 0.6rem; overflow-y: auto; }
.mm-nav a { display: block; padding: 0.85rem 1rem; font-size: 1rem; font-weight: 500; border-radius: var(--r-sm); }
.mm-nav a:hover { background: var(--green-tint); color: var(--green-deep); }

.cart-drawer {
  position: fixed; top: 0; right: 0; bottom: 0; width: min(92vw, 420px); z-index: 100;
  background: var(--paper); transform: translateX(100%); transition: transform 0.3s cubic-bezier(.4,0,.2,1);
  display: flex; flex-direction: column; box-shadow: 0 0 40px -10px var(--shadow);
}
.cart-drawer.open { transform: translateX(0); }
.cart-head { display: flex; align-items: center; justify-content: space-between; padding: 1.3rem 1.4rem; border-bottom: 1px solid var(--line); }
.cart-head h3 { font-size: 1.3rem; }
.cart-head span { color: var(--ink-faint); font-family: var(--sans); font-size: 0.9rem; }
.cart-ship:not(:empty) { padding: 0.9rem 1.4rem; border-bottom: 1px solid var(--line); background: var(--green-tint); }
.ship-bar p { margin: 0 0 0.5rem; font-size: 0.82rem; display: flex; align-items: center; gap: 0.4em; color: var(--green-deep); }
.ship-bar p svg { width: 16px; height: 16px; }
.ship-bar.ok p { margin: 0; font-weight: 600; }
.ship-track { height: 6px; background: oklch(1 0 0 / 0.6); border-radius: var(--r-pill); overflow: hidden; }
.ship-track i { display: block; height: 100%; background: var(--green); border-radius: var(--r-pill); transition: width 0.3s; }
.cart-body { flex: 1; overflow-y: auto; padding: 0.5rem 1.4rem; }
.cart-item { display: flex; gap: 0.9rem; padding: 1rem 0; border-bottom: 1px solid var(--line); }
.ci-media { width: 76px; height: 76px; border-radius: var(--r-md); overflow: hidden; flex-shrink: 0; }
.ci-media .ph-img > span { display: none; }
.ci-info { flex: 1; display: flex; flex-direction: column; gap: 0.25rem; }
.ci-info strong { font-family: var(--serif); font-weight: 500; font-size: 1.05rem; }
.ci-size { font-size: 0.78rem; color: var(--ink-faint); }
.ci-row { margin-top: auto; display: flex; align-items: center; justify-content: space-between; }
.ci-price { font-weight: 700; }
.qty { display: inline-flex; align-items: center; gap: 0.2rem; border: 1px solid var(--line-strong); border-radius: var(--r-pill); padding: 2px; }
.qty button { width: 28px; height: 28px; border-radius: 50%; border: none; background: transparent; color: var(--ink); display: flex; align-items: center; justify-content: center; }
.qty button svg { width: 15px; height: 15px; }
.qty button:hover { background: var(--green-tint); }
.qty span { min-width: 22px; text-align: center; font-weight: 600; font-size: 0.9rem; }
.cart-empty { text-align: center; padding: 3.5rem 1rem; display: flex; flex-direction: column; align-items: center; gap: 1rem; }
.cart-empty svg { width: 48px; height: 48px; color: var(--green-soft); }
.cart-empty p { margin: 0; color: var(--ink-faint); }
.cart-foot { padding: 1.3rem 1.4rem; border-top: 1px solid var(--line); display: flex; flex-direction: column; gap: 0.7rem; }
.cart-foot:empty { display: none; }
.cart-total { display: flex; align-items: center; justify-content: space-between; font-size: 1.05rem; }
.cart-total b { font-size: 1.3rem; }
.cart-continue { background: none; border: none; color: var(--ink-faint); font-size: 0.86rem; font-weight: 500; padding: 0.3rem; }
.cart-continue:hover { color: var(--green-deep); }

@media (prefers-reduced-motion: reduce) {
  * { animation-duration: 0.01ms !important; transition-duration: 0.05ms !important; }
  .reveal { opacity: 1; transform: none; }
}

/* ---------- Responsive header ---------- */
@media (max-width: 940px) {
  :root { --header-h: 70px; }
  .nav-bar { display: none; }
  .search { display: none; }
  .menu-toggle { display: inline-flex; }
  .header-main { height: 64px; }
}

/* ============================================================
   v2 — Componentes nuevos (branding real + funciones)
   ============================================================ */
:focus-visible { outline: 2px solid var(--green-mid); outline-offset: 2px; border-radius: 6px; }
.skip-link { position: absolute; left: -999px; top: 8px; z-index: 300; background: var(--green); color: #fff; padding: .6rem 1rem; border-radius: var(--r-pill); }
.skip-link:focus { left: 12px; }
.eyebrow { color: var(--green-mid); font-weight: 700; }
.btn { font-weight: 700; }
.btn-clay { background: var(--green-mid); }
.btn-clay:hover { background: var(--clay-deep); }
.btn-outline-light { background: transparent; color: #fff; border-color: rgba(255,255,255,.5); }
.btn-outline-light:hover { background: rgba(255,255,255,.12); }
.btn-wsp { background: #1F9D55; color: #fff; }
.btn-wsp:hover { background: #17834A; }
.input, .select-lg {
  width: 100%; border: 1px solid var(--line-strong); background: var(--card); border-radius: var(--r-md);
  padding: .8rem 1rem; font: inherit; font-size: .95rem; color: var(--ink); outline: none;
}
.input:focus, .select-lg:focus { border-color: var(--green-mid); box-shadow: 0 0 0 3px rgba(12,93,87,.12); }
.field { display: flex; flex-direction: column; gap: .35rem; }
.field label { font-size: .82rem; font-weight: 700; color: var(--ink-soft); }

/* topbar rotativa */
.topbar { background: var(--green); color: #E6EFE9; }
.tb-rotator { position: relative; height: 38px; overflow: hidden; flex: 1; text-align: center; }
.tb-rotator .tb-item { position: absolute; inset: 0; justify-content: center; opacity: 0; transform: translateY(10px); transition: all .4s ease; }
.tb-rotator .tb-item.on { opacity: 1; transform: none; }
.tb-rotator b { color: var(--butter); font-weight: 700; }
@media (min-width: 941px) { .tb-rotator { display: none; } }
@media (max-width: 940px) { .tb-static { display: none !important; } }

/* buscador predictivo */
.search { position: relative; }
.ac-panel {
  position: absolute; top: calc(100% + 8px); left: 0; right: 0; z-index: 80; background: var(--card);
  border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: 0 24px 50px -20px var(--shadow);
  padding: .6rem; display: none; color: var(--ink); max-height: 70vh; overflow: auto;
}
.ac-panel.open { display: block; }
.ac-h { font-size: .68rem; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-faint); font-weight: 700; padding: .6rem .7rem .3rem; }
.ac-item { display: flex; align-items: center; gap: .8rem; padding: .5rem .7rem; border-radius: var(--r-md); }
.ac-item:hover, .ac-item.hl { background: var(--green-tint); }
.ac-thumb { width: 44px; height: 44px; border-radius: 10px; overflow: hidden; flex-shrink: 0; background: var(--green-tint); }
.ac-thumb img { width: 100%; height: 100%; object-fit: cover; }
.ac-thumb .ph-img { width: 100%; height: 100%; }
.ac-thumb .ph-img > span { display: none; }
.ac-item b { font-weight: 700; font-size: .92rem; display: block; }
.ac-item small { color: var(--ink-faint); font-size: .78rem; }
.ac-item .ac-price { margin-left: auto; font-weight: 800; font-size: .9rem; }
.ac-chips { display: flex; flex-wrap: wrap; gap: .4rem; padding: .3rem .7rem .7rem; }
.ac-chips a { font-size: .8rem; padding: .35em .8em; border-radius: var(--r-pill); background: var(--paper-2); }
.ac-chips a:hover { background: var(--sage); }
.ac-all { display: block; text-align: center; padding: .7rem; font-weight: 700; font-size: .88rem; color: var(--green-mid); border-top: 1px solid var(--line); margin-top: .4rem; }
mark { background: var(--butter); color: inherit; border-radius: 3px; padding: 0 1px; }
.m-search { display: none; padding: 0 0 .8rem; }
@media (max-width: 940px) { .m-search { display: block; } .m-search .search { display: flex; max-width: none; } }

/* mega menú ampliado */
.mega { width: 860px; grid-template-columns: repeat(4, 1fr); }
.has-mega:focus-within .mega { opacity: 1; visibility: visible; transform: none; }
.mega-promo { grid-column: span 1; background: var(--butter); border-radius: var(--r-md); padding: 1rem; display: flex; flex-direction: column; gap: .4rem; }
.mega-promo b { font-family: var(--serif); font-size: 1.15rem; font-weight: 400; color: var(--green); }
.mega-promo span { font-size: .82rem; color: var(--ink-soft); }
.mega-promo a { color: var(--green-mid) !important; font-weight: 700; }
.nav-list > li > a.nav-hot { color: var(--berry); font-weight: 700; }
.mm-nav .mm-h { font-size: .7rem; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-faint); font-weight: 700; padding: 1rem 1rem .3rem; }

/* carrito v2 */
.ci-media img { width: 100%; height: 100%; object-fit: cover; }
.ci-remove { background: none; border: none; color: var(--ink-faint); font-size: .75rem; text-decoration: underline; padding: 0; align-self: flex-start; }
.cart-upsell { margin: .8rem 0 1rem; padding: .9rem; border-radius: var(--r-md); background: var(--lilac); }
.cart-upsell h6 { margin: 0 0 .6rem; font-size: .78rem; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-soft); }
.cu-item { display: flex; align-items: center; gap: .7rem; }
.cu-item + .cu-item { margin-top: .5rem; }
.cu-item .ac-thumb { width: 40px; height: 40px; }
.cu-item span { flex: 1; font-size: .86rem; font-weight: 600; }
.cu-item button { border: 1px solid var(--green); background: var(--card); color: var(--green); border-radius: var(--r-pill); font-size: .76rem; font-weight: 700; padding: .35em .8em; }
.cu-item button:hover { background: var(--green); color: #fff; }
.cart-pay-note { font-size: .78rem; color: var(--ink-faint); text-align: center; margin: 0; }
.cart-pay-note b { color: var(--green-mid); }

/* precio con transferencia */
.pc-transfer { font-size: .72rem; color: var(--green-mid); font-weight: 700; display: block; margin-top: 2px; }

/* WhatsApp flotante */
.wsp-fab {
  position: fixed; right: 20px; bottom: 20px; z-index: 85; width: 58px; height: 58px; border-radius: 50%;
  background: #1F9D55; color: #fff; border: none; display: flex; align-items: center; justify-content: center;
  box-shadow: 0 14px 30px -10px rgba(0,0,0,.35); transition: transform .2s;
}
.wsp-fab:hover { transform: scale(1.06); }
.wsp-fab svg { width: 28px; height: 28px; }
.wsp-fab .dot { position: absolute; top: 4px; right: 4px; width: 12px; height: 12px; border-radius: 50%; background: var(--butter); border: 2px solid #1F9D55; }
.wsp-panel {
  position: fixed; right: 20px; bottom: 90px; z-index: 86; width: min(340px, calc(100vw - 40px));
  background: var(--card); border-radius: var(--r-lg); box-shadow: 0 30px 60px -20px rgba(0,0,0,.35); overflow: hidden;
  transform: translateY(14px) scale(.98); opacity: 0; visibility: hidden; transition: all .22s ease;
}
.wsp-panel.open { transform: none; opacity: 1; visibility: visible; }
.wsp-top { background: var(--green); color: #fff; padding: 1rem 1.1rem; display: flex; gap: .8rem; align-items: center; }
.wsp-top .av { width: 42px; height: 42px; border-radius: 50%; background: var(--butter); color: var(--green); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.wsp-top .av svg { width: 22px; height: 22px; }
.wsp-top b { display: block; font-size: .98rem; }
.wsp-top small { opacity: .85; display: inline-flex; align-items: center; gap: .35em; }
.wsp-top small i { width: 8px; height: 8px; border-radius: 50%; background: #5BE38E; display: inline-block; }
.wsp-top small i.off { background: #F3B04B; }
.wsp-body { padding: 1rem; background: var(--paper); }
.wsp-bubble { background: var(--card); border: 1px solid var(--line); border-radius: 4px 14px 14px 14px; padding: .7rem .9rem; font-size: .88rem; margin-bottom: .8rem; }
.wsp-opts { display: flex; flex-direction: column; gap: .45rem; }
.wsp-opts a { display: flex; align-items: center; justify-content: space-between; padding: .65rem .9rem; border-radius: var(--r-md); border: 1px solid var(--line); background: var(--card); font-size: .88rem; font-weight: 600; }
.wsp-opts a:hover { border-color: #1F9D55; color: #17834A; }
.wsp-opts svg { width: 16px; height: 16px; }

/* footer v2 */
.footer-grid { grid-template-columns: 1.5fr 1fr 1fr 1fr 1.3fr; }
.footer-legal { display: flex; gap: 1rem; flex-wrap: wrap; align-items: center; }
.footer-legal a { color: oklch(0.85 0.03 150); text-decoration: underline; text-underline-offset: 3px; }
.btn-arrep { background: var(--butter); color: var(--green); border-radius: var(--r-pill); padding: .45em 1em; font-weight: 800; font-size: .78rem; text-decoration: none !important; }
.open-now { display: inline-flex; align-items: center; gap: .45em; font-size: .78rem; font-weight: 700; padding: .25em .7em; border-radius: var(--r-pill); background: rgba(255,255,255,.1); }
.open-now i { width: 8px; height: 8px; border-radius: 50%; background: #5BE38E; }
.open-now.closed i { background: #F3B04B; }
.footer-cta { background: var(--green-mid); }
@media (max-width: 1080px) { .footer-grid { grid-template-columns: 1fr 1fr 1fr; } .footer-brand { grid-column: 1 / -1; } }
@media (max-width: 620px) { .footer-grid { grid-template-columns: 1fr 1fr; } .footer-cta h2 { font-size: 1.7rem; } }
@media (max-width: 760px) { .container { padding: 0 16px; } }

/* ============================================================
   v3 — Card de producto editorial + experiencia mobile tipo app
   ============================================================ */
.product-card { background: transparent; border: none; border-radius: 0; overflow: visible; }
.product-card:hover { transform: none; box-shadow: none; }
.pc-media { aspect-ratio: 4 / 5; border-radius: var(--r-lg); background: var(--paper-2); overflow: hidden; }
.pc-media > a { display: block; width: 100%; height: 100%; }
.pc-media img { object-fit: contain; mix-blend-mode: multiply; padding: 6%; transition: transform .45s cubic-bezier(.2,.7,.2,1); }
.product-card:hover .pc-media img { transform: scale(1.05); }
.product-card:nth-child(4n+2) .pc-media { background: #EEF3EF; }
.product-card:nth-child(4n+3) .pc-media { background: #F4F1F7; }
.product-card:nth-child(4n+4) .pc-media { background: #FBF6E6; }
.pc-quick { left: 10px; right: 64px; bottom: 10px; }
.pc-quick .btn { padding: .7em 1em; font-size: .82rem; background: rgba(255,255,255,.92); border-color: transparent; backdrop-filter: blur(6px); }
.pc-body { padding: .85rem .15rem 0; gap: .25rem; }
.pc-cat { font-size: .68rem; font-weight: 700; color: var(--green-mid); }
.pc-name { font-size: 1.22rem; }
.pc-sci { margin-top: 0; }
.pc-tags { margin-top: .25rem; }
.pc-foot { align-items: flex-end; }
.pc-price { font-size: 1.1rem; font-weight: 800; color: var(--green); }
.pc-add { position: absolute; right: 10px; bottom: 10px; width: 44px; height: 44px; background: var(--green); color: #fff; border: none; box-shadow: 0 10px 20px -10px rgba(18,48,42,.6); }
.pc-add:hover { background: var(--green-mid); transform: scale(1.06); }
.pc-media .pc-add { z-index: 4; }
.pc-out { color: var(--berry); text-decoration: underline; cursor: pointer; }

/* Barra inferior mobile (tipo app) */
.bnav { display: none; }
@media (max-width: 940px) {
  body { padding-bottom: calc(64px + env(safe-area-inset-bottom)); }
  .bnav {
    display: grid; grid-template-columns: repeat(5, 1fr); position: fixed; left: 0; right: 0; bottom: 0; z-index: 88;
    background: rgba(255,252,243,.96); backdrop-filter: blur(12px); border-top: 1px solid var(--line);
    padding: 6px 4px calc(6px + env(safe-area-inset-bottom));
  }
  .bnav a, .bnav button { display: flex; flex-direction: column; align-items: center; gap: 2px; font-size: .66rem; font-weight: 700; color: var(--ink-soft); background: none; border: none; padding: 4px 0; position: relative; min-height: 48px; justify-content: center; }
  .bnav svg { width: 23px; height: 23px; }
  .bnav .on { color: var(--green); }
  .bnav .on::before { content: ''; position: absolute; top: -7px; width: 28px; height: 3px; border-radius: 0 0 4px 4px; background: var(--green); }
  .bnav .count { position: absolute; top: 2px; left: calc(50% + 6px); min-width: 17px; height: 17px; padding: 0 4px; border-radius: 99px; background: var(--berry); color: #fff; font-size: .62rem; display: flex; align-items: center; justify-content: center; }
  .wsp-fab { bottom: calc(76px + env(safe-area-inset-bottom)); right: 14px; width: 52px; height: 52px; }
  .wsp-panel { bottom: calc(138px + env(safe-area-inset-bottom)); right: 14px; }
  .toast-wrap { bottom: calc(80px + env(safe-area-inset-bottom)); }
  .header-actions .icon-btn[href*="visitanos"], .header-actions .icon-btn[href*="fav"] { display: none; }
  .site-header .container { padding-top: 0; }
  .header-main { height: 58px; gap: .6rem; }
  .logo-img { height: 28px; }
  .m-search { padding-bottom: .6rem; }
  .m-search .search { padding: .6rem 1rem; }
  .m-search .ac-panel { position: fixed; left: 12px; right: 12px; top: 120px; max-height: calc(100vh - 220px); }
  .topbar .container { height: 32px; font-size: .76rem; }
  .tb-rotator { height: 32px; }
  .section { padding: 3.2rem 0; }
  .section-sm { padding: 2.2rem 0; }
  .section-head { margin-bottom: 1.4rem; }
  .cart-drawer { width: 100vw; }
  .mobile-menu { width: min(88vw, 380px); }
  .mm-nav a { padding: .8rem 1rem; }
  .site-footer { margin-top: 3rem; }
  .footer-grid { padding: 2.6rem 0 1.6rem; gap: 1.6rem; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
  .footer-pay { flex-wrap: wrap; }
}
@media (max-width: 620px) {
  .grid-products { grid-template-columns: 1fr 1fr; gap: 1.4rem .8rem; }
  .pc-name { font-size: 1.02rem; }
  .pc-sci, .pc-tags, .pc-quick { display: none; }
  .pc-price { font-size: 1rem; }
  .pc-transfer { font-size: .66rem; }
  .pc-add { width: 38px; height: 38px; right: 8px; bottom: 8px; }
  .pc-fav { width: 34px; height: 34px; top: 8px; right: 8px; }
  .pc-badges { top: 8px; left: 8px; }
  .badge { font-size: .64rem; }
  .btn-lg { padding: 1em 1.4em; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-cta { padding: 2.4rem 0; }
}
@media (max-width: 940px) { .search input, .hx-search input, .input, .select-lg, .nl-form input { font-size: 16px; } }

/* v4 — fixes */
[hidden] { display: none !important; }
.pc-media { aspect-ratio: 3 / 4; }
.pc-media img.photo { object-fit: cover; padding: 0; }
.pc-media img.cut { object-fit: contain; padding: 8%; }
.ac-thumb img, .ci-media img { mix-blend-mode: multiply; }
.ac-thumb, .ci-media { background: var(--paper-2); }
.ac-thumb img.cut { object-fit: contain; }
/* chips (compartidos) */
.chip-row { display: flex; flex-wrap: wrap; gap: .5rem; }
.chip-opt { display: inline-flex; align-items: center; gap: .5em; padding: .65em 1.1em; border-radius: var(--r-pill); border: 1px solid var(--line-strong); background: var(--card); font: inherit; font-size: .88rem; font-weight: 700; color: var(--ink-soft); transition: all .15s; min-height: 40px; }
.chip-opt:hover { border-color: var(--green-mid); color: var(--green); }
.chip-opt.sel { background: var(--green); color: #fff; border-color: var(--green); }
.chip-opt svg { width: 16px; height: 16px; }
.footer-legal a.btn-arrep { color: var(--green); }
@media (max-width: 620px) {
  .footer-grid > div:last-child { grid-column: 1 / -1; }
  .footer-grid h5 { margin-bottom: .6rem; }
}
