/* ==========================================================================
   La Esquinita — Hoja de estilos
   Sistema de diseño: tokens primitivos -> semánticos -> componentes
   Tipografía: Rubik (títulos) / Nunito Sans (texto)
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. TOKENS
   -------------------------------------------------------------------------- */
:root {
  /* Primitivos — verde fresco */
  --green-50:  #F0FDF4;
  --green-100: #DCFCE7;
  --green-200: #BBF7D0;
  --green-500: #22C55E;
  --green-600: #16A34A;
  --green-700: #15803D;
  --green-900: #14532D;

  /* Primitivos — naranja (urgencia / promos) */
  --orange-50:  #FFF7ED;
  --orange-100: #FFEDD5;
  --orange-500: #F97316;
  --orange-600: #EA580C;
  --orange-700: #C2410C;

  /* Primitivos — neutros */
  --white:     #FFFFFF;
  --slate-50:  #F8FAFC;
  --slate-100: #F1F5F9;
  --slate-200: #E2E8F0;
  --slate-300: #CBD5E1;
  --slate-500: #64748B;
  --slate-700: #334155;
  --slate-900: #0F172A;

  /* Semánticos */
  --color-primary:            var(--green-600);
  --color-primary-hover:      var(--green-700);
  --color-on-primary:         var(--white);
  --color-primary-soft:       var(--green-50);
  --color-primary-soft-fg:    var(--green-900);

  --color-accent:             var(--orange-600);
  --color-accent-hover:       var(--orange-700);
  --color-on-accent:          var(--white);
  --color-accent-soft:        var(--orange-50);

  --color-background:         var(--white);
  --color-surface:            var(--slate-50);
  --color-card:               var(--white);
  --color-foreground:         var(--slate-900);
  --color-muted-foreground:   var(--slate-500);
  --color-border:             var(--slate-200);
  --color-ring:               var(--green-600);

  /* Tipografía */
  --font-display: 'Rubik', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-body: 'Nunito Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;

  --text-xs:   0.8125rem; /* 13px */
  --text-sm:   0.9375rem; /* 15px */
  --text-base: 1rem;      /* 16px */
  --text-lg:   1.125rem;
  --text-xl:   1.375rem;
  --text-2xl:  1.75rem;
  --text-3xl:  2.25rem;
  --text-4xl:  3rem;

  /* Espaciado (escala 4px) */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.25rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-20: 5rem;

  /* Radios y sombras */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --radius-xl: 26px;
  --radius-full: 999px;

  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.06), 0 1px 3px rgba(15, 23, 42, 0.04);
  --shadow-md: 0 4px 12px rgba(15, 23, 42, 0.07), 0 2px 4px rgba(15, 23, 42, 0.04);
  --shadow-lg: 0 18px 40px rgba(15, 23, 42, 0.12), 0 4px 10px rgba(15, 23, 42, 0.05);

  /* Movimiento */
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --t-fast: 150ms;
  --t-base: 220ms;
  --t-slow: 320ms;

  /* Layout */
  --container: 1200px;
  --header-h: 68px;
}

/* --------------------------------------------------------------------------
   2. BASE
   -------------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + var(--space-4));
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: 1.6;
  color: var(--color-foreground);
  background: var(--color-background);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0 0 var(--space-3);
  font-weight: 600;
}

h1 { font-size: clamp(2rem, 5.5vw, var(--text-4xl)); font-weight: 700; }
h2 { font-size: clamp(1.5rem, 3.6vw, var(--text-3xl)); }
h3 { font-size: var(--text-lg); }

p { margin: 0 0 var(--space-4); }
p:last-child { margin-bottom: 0; }

a { color: var(--color-primary-hover); text-decoration: none; }
a:hover { text-decoration: underline; }

img, svg { display: block; max-width: 100%; }
ul { margin: 0; padding: 0; list-style: none; }

:focus-visible {
  outline: 3px solid var(--color-ring);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}

/* Enlace de salto para teclado / lectores de pantalla */
.skip-link {
  position: absolute;
  left: var(--space-4);
  top: -100px;
  z-index: 200;
  padding: var(--space-3) var(--space-5);
  background: var(--color-foreground);
  color: var(--white);
  border-radius: var(--radius-md);
  font-weight: 700;
  transition: top var(--t-fast) var(--ease);
}
.skip-link:focus { top: var(--space-4); text-decoration: 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;
}

/* --------------------------------------------------------------------------
   3. UTILIDADES DE LAYOUT
   -------------------------------------------------------------------------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--space-5);
}

.section { padding-block: clamp(var(--space-12), 7vw, var(--space-20)); }
.section--surface { background: var(--color-surface); }

.section-head {
  max-width: 44rem;
  margin-bottom: var(--space-10);
}
.section-head--center { margin-inline: auto; text-align: center; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-family: var(--font-display);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-primary-hover);
  background: var(--color-primary-soft);
  border: 1px solid var(--green-200);
  padding: var(--space-2) var(--space-4);
  border-radius: var(--radius-full);
  margin-bottom: var(--space-4);
}

.lead {
  font-size: var(--text-lg);
  color: var(--color-muted-foreground);
}

.icon { width: 24px; height: 24px; flex: none; }
.icon--sm { width: 18px; height: 18px; }
.icon--lg { width: 30px; height: 30px; }

/* --------------------------------------------------------------------------
   4. BOTONES
   -------------------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  min-height: 48px;
  padding: var(--space-3) var(--space-6);
  border: 1px solid transparent;
  border-radius: var(--radius-full);
  font-family: var(--font-display);
  font-size: var(--text-base);
  font-weight: 600;
  line-height: 1.2;
  cursor: pointer;
  text-decoration: none;
  transition: background-color var(--t-base) var(--ease),
              border-color var(--t-base) var(--ease),
              color var(--t-base) var(--ease),
              transform var(--t-fast) var(--ease),
              box-shadow var(--t-base) var(--ease);
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn:active { transform: translateY(0); }

.btn--primary {
  background: var(--color-primary);
  color: var(--color-on-primary);
  box-shadow: var(--shadow-sm);
}
.btn--primary:hover { background: var(--color-primary-hover); box-shadow: var(--shadow-md); }

.btn--accent {
  background: var(--color-accent);
  color: var(--color-on-accent);
  box-shadow: var(--shadow-sm);
}
.btn--accent:hover { background: var(--color-accent-hover); box-shadow: var(--shadow-md); }

.btn--ghost {
  background: var(--white);
  color: var(--color-foreground);
  border-color: var(--color-border);
}
.btn--ghost:hover { background: var(--color-surface); border-color: var(--slate-300); }

.btn--block { width: 100%; }
.btn--sm { min-height: 42px; padding: var(--space-2) var(--space-4); font-size: var(--text-sm); }

.btn:disabled,
.btn[aria-disabled="true"] {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

/* --------------------------------------------------------------------------
   5. BARRA SUPERIOR + HEADER
   -------------------------------------------------------------------------- */
.topbar {
  background: var(--color-foreground);
  color: var(--slate-200);
  font-size: var(--text-xs);
}
.topbar__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: var(--space-2) var(--space-6);
  padding-block: var(--space-2);
  text-align: center;
}
.topbar__item { display: inline-flex; align-items: center; gap: var(--space-2); }
.topbar__item .icon--sm { color: var(--green-500); }

.header {
  position: sticky;
  top: 0;
  z-index: 60;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--color-border);
}
.header__inner {
  display: flex;
  align-items: center;
  gap: var(--space-4);
  min-height: var(--header-h);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: var(--space-3);
  font-family: var(--font-display);
  color: var(--color-foreground);
  margin-right: auto;
}
.brand:hover { text-decoration: none; }
.brand__mark {
  width: 42px; height: 42px;
  display: grid; place-items: center;
  background: var(--color-primary);
  color: var(--white);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
}
.brand__name { display: block; font-weight: 700; font-size: var(--text-lg); line-height: 1.1; white-space: nowrap; }
.brand__tag {
  display: block;
  font-family: var(--font-body);
  font-size: var(--text-xs);
  color: var(--color-muted-foreground);
}

.nav { display: none; }
@media (min-width: 900px) {
  .nav { display: flex; align-items: center; gap: var(--space-1); }
}
.nav__link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 var(--space-4);
  border-radius: var(--radius-full);
  font-family: var(--font-display);
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--slate-700);
  transition: background-color var(--t-fast) var(--ease), color var(--t-fast) var(--ease);
}
.nav__link:hover { background: var(--color-primary-soft); color: var(--color-primary-hover); text-decoration: none; }

.header__actions { display: flex; align-items: center; gap: var(--space-2); }

/* En pantallas chicas el botón flotante ya ofrece WhatsApp: liberamos el header */
.header__cta { display: none; }
@media (min-width: 740px) { .header__cta { display: inline-flex; } }
@media (max-width: 479px) { .brand__tag { display: none; } }

.cart-btn { position: relative; }
.cart-btn__count {
  position: absolute;
  top: -4px; right: -4px;
  min-width: 22px; height: 22px;
  display: grid; place-items: center;
  padding: 0 5px;
  background: var(--color-accent);
  color: var(--white);
  border: 2px solid var(--white);
  border-radius: var(--radius-full);
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 700;
  transform: scale(0);
  transition: transform var(--t-base) var(--ease);
}
.cart-btn__count.is-visible { transform: scale(1); }

.menu-toggle { display: inline-flex; }
@media (min-width: 900px) { .menu-toggle { display: none; } }

.btn--icon {
  min-height: 48px;
  width: 48px;
  padding: 0;
  border-radius: var(--radius-md);
}

/* Menú móvil */
.mobile-nav {
  display: none;
  border-top: 1px solid var(--color-border);
  background: var(--white);
  padding: var(--space-3) 0 var(--space-5);
}
.mobile-nav.is-open { display: block; }
@media (min-width: 900px) { .mobile-nav.is-open { display: none; } }
.mobile-nav__link {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  min-height: 52px;
  padding: 0 var(--space-3);
  border-radius: var(--radius-md);
  font-family: var(--font-display);
  font-weight: 500;
  color: var(--slate-700);
}
.mobile-nav__link:hover { background: var(--color-surface); text-decoration: none; }
.mobile-nav__link .icon--sm { color: var(--color-primary); }

/* --------------------------------------------------------------------------
   6. HERO
   -------------------------------------------------------------------------- */
.hero {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(1000px 420px at 88% -10%, var(--green-100), transparent 70%),
    linear-gradient(180deg, var(--green-50) 0%, var(--white) 100%);
  padding-block: clamp(var(--space-12), 8vw, var(--space-20));
}
.hero__grid {
  display: grid;
  gap: var(--space-10);
  align-items: center;
}
@media (min-width: 980px) {
  .hero__grid { grid-template-columns: 1.08fr 0.92fr; gap: var(--space-12); }
}
.hero__title strong { color: var(--color-primary-hover); }
.hero__text { max-width: 36rem; }
.hero__cta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  margin-top: var(--space-8);
}

.trust {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-5) var(--space-4);
  margin-top: var(--space-10);
  padding-top: var(--space-8);
  border-top: 1px solid var(--green-200);
}
.trust__item { display: flex; align-items: flex-start; gap: var(--space-3); }
.trust__item .icon--sm { color: var(--color-primary); margin-top: 3px; }
.trust__label {
  font-family: var(--font-display);
  font-size: var(--text-sm);
  font-weight: 600;
  display: block;
  line-height: 1.25;
}
.trust__meta { font-size: var(--text-xs); color: var(--color-muted-foreground); }

/* Tarjeta visual del hero (construida en CSS, sin fotos) */
.hero__card {
  background: var(--white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg);
  padding: var(--space-6);
}
.hero__card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  padding-bottom: var(--space-4);
  margin-bottom: var(--space-4);
  border-bottom: 1px solid var(--color-border);
}
.hero__card-title { font-family: var(--font-display); font-weight: 700; }
.chip-live {
  display: inline-flex; align-items: center; gap: var(--space-2);
  font-size: var(--text-xs); font-weight: 700;
  color: var(--color-primary-hover);
  background: var(--color-primary-soft);
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-full);
}
.chip-live__dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--green-500);
  box-shadow: 0 0 0 4px rgba(34, 197, 94, 0.18);
}
.mini-list { display: grid; gap: var(--space-2); }
.mini-row {
  display: flex; align-items: center; gap: var(--space-3);
  padding: var(--space-3);
  border-radius: var(--radius-md);
  background: var(--color-surface);
}
.mini-row__icon {
  width: 38px; height: 38px;
  display: grid; place-items: center;
  border-radius: var(--radius-sm);
  background: var(--white);
  border: 1px solid var(--color-border);
  color: var(--color-primary-hover);
}
.mini-row__name { font-size: var(--text-sm); font-weight: 600; flex: 1; }
.mini-row__price { font-family: var(--font-display); font-weight: 700; font-size: var(--text-sm); }
.hero__card-total {
  display: flex; align-items: baseline; justify-content: space-between;
  margin-top: var(--space-5);
  padding-top: var(--space-4);
  border-top: 1px dashed var(--color-border);
}
.hero__card-total span { color: var(--color-muted-foreground); font-size: var(--text-sm); }
.hero__card-total strong { font-family: var(--font-display); font-size: var(--text-xl); }
.hero__card-note {
  margin-top: var(--space-4);
  font-size: var(--text-xs);
  color: var(--color-muted-foreground);
  display: flex; align-items: center; gap: var(--space-2);
}

/* --------------------------------------------------------------------------
   7. CATEGORÍAS
   -------------------------------------------------------------------------- */
.cat-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-4);
}
@media (min-width: 640px) { .cat-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 980px) { .cat-grid { grid-template-columns: repeat(6, minmax(0, 1fr)); } }

.cat-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-5) var(--space-3);
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  text-align: center;
  cursor: pointer;
  transition: border-color var(--t-base) var(--ease),
              box-shadow var(--t-base) var(--ease),
              transform var(--t-base) var(--ease);
}
.cat-card:hover {
  border-color: var(--green-200);
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
  text-decoration: none;
}
.cat-card__icon {
  width: 56px; height: 56px;
  display: grid; place-items: center;
  border-radius: var(--radius-md);
  background: var(--color-primary-soft);
  color: var(--color-primary-hover);
}
.cat-card__name {
  font-family: var(--font-display);
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-foreground);
}

/* --------------------------------------------------------------------------
   8. PROMOS
   -------------------------------------------------------------------------- */
.promo-grid {
  display: grid;
  gap: var(--space-5);
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}
.promo-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  padding: var(--space-5);
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  transition: box-shadow var(--t-base) var(--ease), transform var(--t-base) var(--ease);
}
.promo-card:hover { box-shadow: var(--shadow-md); transform: translateY(-3px); }
.promo-card__tag {
  position: absolute;
  top: var(--space-4); right: var(--space-4);
  background: var(--color-accent);
  color: var(--white);
  font-family: var(--font-display);
  font-size: var(--text-xs);
  font-weight: 700;
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-full);
}
.promo-card__icon {
  width: 64px; height: 64px;
  display: grid; place-items: center;
  border-radius: var(--radius-md);
  background: var(--color-accent-soft);
  color: var(--color-accent-hover);
}
.promo-card__name { font-family: var(--font-display); font-weight: 600; font-size: var(--text-base); }
.promo-card__unit { font-size: var(--text-xs); color: var(--color-muted-foreground); }
.promo-card__prices { display: flex; align-items: baseline; gap: var(--space-3); margin-top: auto; }
.promo-card__now { font-family: var(--font-display); font-size: var(--text-2xl); font-weight: 700; color: var(--color-accent-hover); }
.promo-card__was { font-size: var(--text-sm); color: var(--color-muted-foreground); text-decoration: line-through; }

/* --------------------------------------------------------------------------
   9. CATÁLOGO
   -------------------------------------------------------------------------- */
.catalog__toolbar {
  display: grid;
  gap: var(--space-5);
  margin-bottom: var(--space-8);
}
.catalog__toolbar > .field:first-child { max-width: 420px; }

.field { display: grid; gap: var(--space-2); }
.field__label {
  font-family: var(--font-display);
  font-size: var(--text-sm);
  font-weight: 600;
}
.field__hint { font-size: var(--text-xs); color: var(--color-muted-foreground); }

.input-wrap { position: relative; display: flex; align-items: center; }
.input-wrap .icon--sm {
  position: absolute;
  left: var(--space-4);
  color: var(--color-muted-foreground);
  pointer-events: none;
}
.input,
.textarea,
.select {
  width: 100%;
  min-height: 48px;
  padding: var(--space-3) var(--space-4);
  font-family: var(--font-body);
  font-size: var(--text-base);
  color: var(--color-foreground);
  background: var(--white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  transition: border-color var(--t-fast) var(--ease), box-shadow var(--t-fast) var(--ease);
}
.input-wrap .input { padding-left: calc(var(--space-4) + 26px); }
.input:focus, .textarea:focus, .select:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 4px rgba(22, 163, 74, 0.16);
}
.textarea { min-height: 84px; resize: vertical; }

.filters {
  display: flex;
  gap: var(--space-2);
  overflow-x: auto;
  padding-bottom: var(--space-2);
  scrollbar-width: thin;
}
/* En pantallas anchas los filtros caben: que acomoden en vez de desplazarse */
@media (min-width: 720px) {
  .filters { flex-wrap: wrap; overflow-x: visible; padding-bottom: 0; }
}
.filter-chip {
  flex: none;
  min-height: 44px;
  padding: 0 var(--space-4);
  background: var(--white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-full);
  font-family: var(--font-display);
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--slate-700);
  cursor: pointer;
  white-space: nowrap;
  transition: background-color var(--t-fast) var(--ease),
              border-color var(--t-fast) var(--ease),
              color var(--t-fast) var(--ease);
}
.filter-chip:hover { background: var(--color-surface); }
.filter-chip[aria-pressed="true"] {
  background: var(--color-primary);
  border-color: var(--color-primary);
  color: var(--white);
}

.product-grid {
  display: grid;
  gap: var(--space-5);
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 230px), 1fr));
}

.product {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  padding: var(--space-4);
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  transition: border-color var(--t-base) var(--ease), box-shadow var(--t-base) var(--ease);
}
.product:hover { border-color: var(--green-200); box-shadow: var(--shadow-md); }

.product__thumb {
  position: relative;
  aspect-ratio: 16 / 10;
  display: grid;
  place-items: center;
  border-radius: var(--radius-md);
  background:
    radial-gradient(circle at 50% 45%, var(--green-50), var(--color-surface) 72%);
  border: 1px solid var(--slate-100);
  color: var(--color-primary-hover);
}
.product__thumb .icon--lg { width: 60px; height: 60px; }
.product__badge {
  position: absolute;
  top: var(--space-2); left: var(--space-2);
  background: var(--color-accent);
  color: var(--white);
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 3px var(--space-2);
  border-radius: var(--radius-full);
}
.product__name {
  font-family: var(--font-display);
  font-size: var(--text-sm);
  font-weight: 600;
  margin: 0;
  line-height: 1.3;
}
.product__unit { font-size: var(--text-xs); color: var(--color-muted-foreground); }
.product__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  margin-top: auto;
  padding-top: var(--space-2);
}
.product__price { font-family: var(--font-display); font-size: var(--text-lg); font-weight: 700; }
.product__price-was {
  display: block;
  font-family: var(--font-body);
  font-size: var(--text-xs);
  font-weight: 400;
  color: var(--color-muted-foreground);
  text-decoration: line-through;
}
.product__add {
  min-height: 44px; width: 44px;
  padding: 0;
  display: grid; place-items: center;
  background: var(--color-primary-soft);
  color: var(--color-primary-hover);
  border: 1px solid var(--green-200);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: background-color var(--t-fast) var(--ease), color var(--t-fast) var(--ease);
}
.product__add:hover { background: var(--color-primary); color: var(--white); }

.empty-state {
  grid-column: 1 / -1;
  display: grid;
  gap: var(--space-3);
  justify-items: center;
  padding: var(--space-12) var(--space-5);
  text-align: center;
  background: var(--color-surface);
  border: 1px dashed var(--color-border);
  border-radius: var(--radius-lg);
  color: var(--color-muted-foreground);
}
.empty-state .icon--lg { color: var(--slate-300); }

.catalog__note {
  margin-top: var(--space-8);
  padding: var(--space-4) var(--space-5);
  background: var(--color-primary-soft);
  border: 1px solid var(--green-200);
  border-radius: var(--radius-md);
  font-size: var(--text-sm);
  color: var(--color-primary-soft-fg);
  display: flex;
  gap: var(--space-3);
}
.catalog__note .icon--sm { color: var(--color-primary-hover); margin-top: 3px; }

/* --------------------------------------------------------------------------
   10. SERVICIOS
   -------------------------------------------------------------------------- */
.service-grid {
  display: grid;
  gap: var(--space-5);
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
}
.service {
  display: flex;
  gap: var(--space-4);
  padding: var(--space-5);
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  transition: box-shadow var(--t-base) var(--ease), transform var(--t-base) var(--ease);
}
.service:hover { box-shadow: var(--shadow-md); transform: translateY(-3px); }
.service__icon {
  width: 48px; height: 48px; flex: none;
  display: grid; place-items: center;
  border-radius: var(--radius-md);
  background: var(--color-primary-soft);
  color: var(--color-primary-hover);
}
.service__title { font-size: var(--text-base); margin-bottom: var(--space-1); }
.service__text { font-size: var(--text-sm); color: var(--color-muted-foreground); margin: 0; }

/* --------------------------------------------------------------------------
   11. PASOS + TESTIMONIOS
   -------------------------------------------------------------------------- */
.steps {
  display: grid;
  gap: var(--space-6);
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr));
  counter-reset: paso;
}
.step { position: relative; padding-top: var(--space-10); }
.step::before {
  counter-increment: paso;
  content: counter(paso);
  position: absolute;
  top: 0; left: 0;
  width: 44px; height: 44px;
  display: grid; place-items: center;
  background: var(--color-primary);
  color: var(--white);
  border-radius: var(--radius-full);
  font-family: var(--font-display);
  font-size: var(--text-lg);
  font-weight: 700;
}
.step__title { font-size: var(--text-lg); }
.step__text { color: var(--color-muted-foreground); font-size: var(--text-sm); margin: 0; }

.quote-grid {
  display: grid;
  gap: var(--space-5);
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
}
.quote {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  padding: var(--space-6);
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
}
.quote__stars { display: flex; gap: 2px; color: var(--orange-500); }
.quote__stars .icon--sm { width: 16px; height: 16px; }
.quote__text { font-size: var(--text-sm); margin: 0; }
.quote__person { display: flex; align-items: center; gap: var(--space-3); margin-top: auto; }
.quote__avatar {
  width: 40px; height: 40px;
  display: grid; place-items: center;
  border-radius: var(--radius-full);
  background: var(--color-primary-soft);
  color: var(--color-primary-hover);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--text-sm);
}
.quote__name { font-family: var(--font-display); font-size: var(--text-sm); font-weight: 600; display: block; line-height: 1.2; }
.quote__meta { font-size: var(--text-xs); color: var(--color-muted-foreground); }

/* --------------------------------------------------------------------------
   12. CTA FINAL
   -------------------------------------------------------------------------- */
.cta-band {
  background: linear-gradient(135deg, var(--green-700), var(--green-600) 60%, var(--green-500));
  color: var(--white);
}
.cta-band__inner {
  display: grid;
  gap: var(--space-8);
  align-items: center;
  padding-block: clamp(var(--space-12), 7vw, var(--space-16));
}
@media (min-width: 900px) {
  .cta-band__inner { grid-template-columns: 1.3fr auto; }
}
.cta-band h2 { color: var(--white); }
.cta-band p { color: rgba(255, 255, 255, 0.88); margin: 0; max-width: 40rem; }
.cta-band__actions { display: flex; flex-wrap: wrap; gap: var(--space-3); }
.cta-band .btn--ghost { background: transparent; color: var(--white); border-color: rgba(255,255,255,0.55); }
.cta-band .btn--ghost:hover { background: rgba(255,255,255,0.14); border-color: var(--white); }
.cta-band .btn--primary { background: var(--white); color: var(--green-700); }
.cta-band .btn--primary:hover { background: var(--green-50); }

/* --------------------------------------------------------------------------
   13. FOOTER
   -------------------------------------------------------------------------- */
.footer {
  background: var(--color-foreground);
  color: var(--slate-300);
  font-size: var(--text-sm);
  padding-block: var(--space-12) var(--space-6);
}
.footer__grid {
  display: grid;
  gap: var(--space-8);
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
}
.footer h3 {
  color: var(--white);
  font-size: var(--text-sm);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: var(--space-4);
}
.footer a { color: var(--slate-300); }
.footer a:hover { color: var(--white); }
.footer__brand { display: inline-flex; align-items: center; gap: var(--space-3); margin-bottom: var(--space-4); }
.footer__brand .brand__mark { background: var(--green-600); }
.footer__brand .brand__name { color: var(--white); }
.footer__list { display: grid; gap: var(--space-3); }
.footer__list li { display: flex; gap: var(--space-3); }
.footer__list .icon--sm { color: var(--green-500); flex: none; margin-top: 3px; }
.footer__bottom {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3) var(--space-6);
  justify-content: space-between;
  align-items: center;
  margin-top: var(--space-10);
  padding-top: var(--space-6);
  border-top: 1px solid rgba(255,255,255,0.12);
  font-size: var(--text-xs);
  color: var(--slate-500);
}
.social { display: flex; gap: var(--space-2); }
.social__link {
  width: 44px; height: 44px;
  display: grid; place-items: center;
  border-radius: var(--radius-md);
  background: rgba(255,255,255,0.08);
  color: var(--slate-200);
  transition: background-color var(--t-fast) var(--ease), color var(--t-fast) var(--ease);
}
.social__link:hover { background: var(--green-600); color: var(--white); }

/* --------------------------------------------------------------------------
   14. CARRITO (panel lateral)
   -------------------------------------------------------------------------- */
.overlay {
  position: fixed;
  inset: 0;
  z-index: 90;
  background: rgba(15, 23, 42, 0.5);
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--t-base) var(--ease), visibility var(--t-base) var(--ease);
}
.overlay.is-open { opacity: 1; visibility: visible; }

.cart {
  position: fixed;
  top: 0; right: 0;
  z-index: 100;
  width: min(430px, 100%);
  height: 100%;
  display: flex;
  flex-direction: column;
  background: var(--white);
  box-shadow: var(--shadow-lg);
  transform: translateX(104%);
  visibility: hidden;
  transition: transform var(--t-slow) var(--ease), visibility var(--t-slow) var(--ease);
}
.cart.is-open { transform: translateX(0); visibility: visible; }

.cart__head {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-5);
  border-bottom: 1px solid var(--color-border);
}
.cart__title { margin: 0; font-size: var(--text-lg); flex: 1; }
.cart__close {
  width: 44px; height: 44px;
  display: grid; place-items: center;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  color: var(--slate-700);
  cursor: pointer;
  transition: background-color var(--t-fast) var(--ease);
}
.cart__close:hover { background: var(--slate-100); }

.cart__body { flex: 1; overflow-y: auto; padding: var(--space-5); }

.cart__empty {
  display: grid;
  gap: var(--space-3);
  justify-items: center;
  text-align: center;
  padding: var(--space-12) var(--space-4);
  color: var(--color-muted-foreground);
}
.cart__empty .icon--lg { width: 48px; height: 48px; color: var(--slate-300); }

.cart-lines { display: grid; gap: var(--space-3); margin-bottom: var(--space-6); }
.cart-line {
  display: grid;
  grid-template-columns: 44px 1fr auto;
  gap: var(--space-3);
  align-items: center;
  padding: var(--space-3);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
}
.cart-line__icon {
  width: 44px; height: 44px;
  display: grid; place-items: center;
  background: var(--color-surface);
  border-radius: var(--radius-sm);
  color: var(--color-primary-hover);
}
.cart-line__name { font-family: var(--font-display); font-size: var(--text-sm); font-weight: 600; line-height: 1.25; }
.cart-line__price { font-size: var(--text-xs); color: var(--color-muted-foreground); }
.cart-line__side { display: grid; gap: var(--space-2); justify-items: end; }
.cart-line__total { font-family: var(--font-display); font-weight: 700; font-size: var(--text-sm); }

.stepper {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-full);
  overflow: hidden;
  background: var(--white);
}
.stepper__btn {
  width: 36px; height: 36px;
  display: grid; place-items: center;
  background: var(--white);
  border: 0;
  color: var(--slate-700);
  cursor: pointer;
  transition: background-color var(--t-fast) var(--ease), color var(--t-fast) var(--ease);
}
.stepper__btn:hover { background: var(--color-primary-soft); color: var(--color-primary-hover); }
.stepper__value {
  min-width: 34px;
  text-align: center;
  font-family: var(--font-display);
  font-size: var(--text-sm);
  font-weight: 600;
}

.cart__form { display: grid; gap: var(--space-4); }
.cart__form-title {
  font-family: var(--font-display);
  font-size: var(--text-base);
  font-weight: 600;
  padding-top: var(--space-5);
  border-top: 1px solid var(--color-border);
  margin: 0;
}
.radio-row { display: flex; gap: var(--space-3); flex-wrap: wrap; }
.radio-card {
  flex: 1 1 130px;
  display: flex;
  align-items: center;
  gap: var(--space-2);
  min-height: 48px;
  padding: var(--space-2) var(--space-4);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  font-size: var(--text-sm);
  font-weight: 600;
  cursor: pointer;
  transition: border-color var(--t-fast) var(--ease), background-color var(--t-fast) var(--ease);
}
.radio-card:hover { background: var(--color-surface); }
.radio-card input { accent-color: var(--color-primary); width: 18px; height: 18px; }
.radio-card:has(input:checked) {
  border-color: var(--color-primary);
  background: var(--color-primary-soft);
  color: var(--color-primary-soft-fg);
}
.radio-card:has(input:focus-visible) { outline: 3px solid var(--color-ring); outline-offset: 2px; }

.cart__foot {
  border-top: 1px solid var(--color-border);
  padding: var(--space-5);
  background: var(--color-surface);
  display: grid;
  gap: var(--space-3);
}
.sum-row {
  display: flex;
  justify-content: space-between;
  gap: var(--space-4);
  font-size: var(--text-sm);
  color: var(--color-muted-foreground);
}
.sum-row--total {
  font-family: var(--font-display);
  font-size: var(--text-lg);
  font-weight: 700;
  color: var(--color-foreground);
  padding-top: var(--space-3);
  border-top: 1px dashed var(--color-border);
}
.sum-row__free { color: var(--color-primary-hover); font-weight: 700; }
.cart__hint { font-size: var(--text-xs); color: var(--color-muted-foreground); text-align: center; margin: 0; }

/* Botón flotante de WhatsApp */
.fab {
  position: fixed;
  right: var(--space-5);
  bottom: var(--space-5);
  z-index: 70;
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  min-height: 56px;
  padding: 0 var(--space-5);
  background: var(--color-primary);
  color: var(--white);
  border-radius: var(--radius-full);
  box-shadow: var(--shadow-lg);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: var(--text-sm);
  transition: background-color var(--t-base) var(--ease), transform var(--t-base) var(--ease);
}
.fab:hover { background: var(--color-primary-hover); transform: translateY(-2px); text-decoration: none; }
.fab__label { display: none; }
@media (min-width: 620px) { .fab__label { display: inline; } }

/* Aviso tipo "toast" al agregar productos */
.toast {
  position: fixed;
  left: 50%;
  bottom: calc(var(--space-5) + 72px);
  z-index: 110;
  transform: translate(-50%, 16px);
  display: flex;
  align-items: center;
  gap: var(--space-3);
  max-width: calc(100vw - var(--space-8));
  padding: var(--space-3) var(--space-5);
  background: var(--color-foreground);
  color: var(--white);
  border-radius: var(--radius-full);
  box-shadow: var(--shadow-lg);
  font-size: var(--text-sm);
  font-weight: 600;
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--t-base) var(--ease),
              transform var(--t-base) var(--ease),
              visibility var(--t-base) var(--ease);
}
.toast.is-visible { opacity: 1; visibility: visible; transform: translate(-50%, 0); }
.toast .icon--sm { color: var(--green-500); }

body.is-locked { overflow: hidden; }

/* --------------------------------------------------------------------------
   15. MOVIMIENTO REDUCIDO
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .btn:hover, .cat-card:hover, .promo-card:hover, .service:hover, .fab:hover { transform: none; }
}

/* --------------------------------------------------------------------------
   16. IMPRESIÓN
   -------------------------------------------------------------------------- */
@media print {
  .header, .topbar, .fab, .cart, .overlay, .cta-band, .catalog__toolbar { display: none !important; }
  body { color: #000; }
}
