/* =====================================================================
   CERVO · SISTEMA DE DISEÑO PERSONALIZADO (VERDE, BLANCO Y NEGRO)
   Arquitectura: Vanilla CSS3 / Variables CSS nativas
   Identidad: Rendimiento Deportivo, Siluetas Vectoriales y Micro-animaciones
   ===================================================================== */

:root {
  /* ---------- 1. Escala de Negros Profundos (Onyx / Stealth) ---------- */
  --black-950: #040705;  /* Negro absoluto de profundidad */
  --black-900: #090e0c;  /* Fondo principal oscuro y cabeceras */
  --black-850: #0f1713;  /* Superficies de alto contraste */
  --black-800: #14201b;  /* Bordes intensos y tarjetas oscuras */
  --black-700: #1d2c26;  /* Separadores */
  --black-600: #2b3d35;  /* Muted darks */

  /* ---------- 2. Escala de Blancos Puros y Neutros Suaves ---------- */
  --white: #ffffff;
  --white-soft: #f8faf9;     /* Fondo claro con micro-tinte menta */
  --white-card: #ffffff;     /* Superficie de tarjetas */
  --gray-100: #f0f4f2;       /* Superficie suave */
  --gray-200: #e1e8e4;       /* Bordes nítidos */
  --gray-300: #cbd5cf;       /* Bordes de formulario */
  --gray-400: #93a39a;       /* Texto desactivado */
  --gray-500: #5c6c63;       /* Subtextos */
  --gray-600: #3b4941;       /* Texto secundario de alta legibilidad (WCAG AAA) */
  --gray-700: #232f28;       /* Texto principal */
  --gray-900: #090e0c;       /* Títulos negro ónix */

  /* ---------- 3. Escala de Verdes Atléticos (Emerald, Cyber Mint & Racing) ---------- */
  --green-50: #ecfdf5;       /* Fondo suave de cupones y éxito */
  --green-100: #d1fae5;      /* Tintes de borde suave */
  --green-200: #a7f3d0;      /* Bordes de badges */
  --green-300: #6ee7b7;      /* Acentos sutiles */
  --green-400: #34d399;      /* Verde menta brillante */
  --green-500: #10b981;      /* Verde esmeralda deportivo */
  --green-600: #059669;      /* Verde acción accesible */
  --green-700: #047857;      /* Verde primario sólido de alta tracción */
  --green-800: #065f46;      /* Hover activo */
  --green-900: #064e3b;      /* Verde bosque oscuro */
  --green-950: #022c22;      /* Negro-verde técnico */
  --green-neon: #00e676;     /* Verde neón deportivo de alto impacto */
  --green-cyber: #00ff87;    /* Resplandor cyber mint */

  /* ---------- 4. Mapeo Semántico (Compatibilidad 100% arquitectura) ---------- */
  --fondo: var(--white);
  --fondo-suave: var(--white-soft);
  --fondo-tarjeta: var(--white-card);
  --texto: var(--black-900);
  --texto-2: var(--gray-600);
  --acento: var(--green-700);
  --acento-hover: var(--green-800);
  --acento-neon: var(--green-neon);
  --borde: var(--gray-200);
  --verde: var(--green-600);
  --rojo: #e11d48;

  /* Radios y Sombras con Luz Direccional */
  --radio: 20px;
  --radio-sm: 12px;
  --radio-pill: 980px;
  --sombra-sm: 0 1px 3px rgba(9, 14, 12, 0.05), 0 1px 2px rgba(9, 14, 12, 0.04);
  --sombra: 0 4px 18px -2px rgba(9, 14, 12, 0.07), 0 2px 6px -1px rgba(9, 14, 12, 0.04);
  --sombra-lg: 0 14px 36px -4px rgba(9, 14, 12, 0.12), 0 4px 14px -2px rgba(9, 14, 12, 0.05);
  --sombra-hover: 0 20px 36px -8px rgba(0, 230, 118, 0.28), 0 6px 18px -2px rgba(9, 14, 12, 0.1);
  --sombra-glow: 0 0 24px rgba(0, 230, 118, 0.4);

  --monitor-ancho: 380px;
  --monitor-alto-movil: 300px;
  --fuente: -apple-system, BlinkMacSystemFont, "SF Pro Text", "SF Pro Display", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --curva-suave: cubic-bezier(0.16, 1, 0.3, 1);
}

/* ---------- Reseteo y Base ---------- */
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--fuente);
  font-size: 17px;
  line-height: 1.48;
  color: var(--texto);
  background: var(--fondo);
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
main { flex: 1; }
img, svg { max-width: 100%; }
a { color: var(--acento); text-decoration: none; transition: color 0.2s ease; }
a:hover { color: var(--green-900); text-decoration: underline; }
h1, h2, h3 { letter-spacing: -0.03em; line-height: 1.15; margin: 0 0 0.5em; color: var(--black-900); }
h1 { font-size: clamp(34px, 5.2vw, 52px); font-weight: 800; }
h2 { font-size: clamp(22px, 3.2vw, 30px); font-weight: 700; }
h3 { font-size: 20px; font-weight: 600; }
p { margin: 0 0 1em; }
[hidden] { display: none !important; }

.contenedor { width: 100%; max-width: 1080px; margin: 0 auto; padding: 0 22px; }
.seccion { padding: 44px 0 72px; }
.texto-2 { color: var(--texto-2); }
.centrado { text-align: center; }

/* ---------- Barra Superior (Header Sticky en Verde / Negro / Blanco) ---------- */
.barra {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1.5px solid var(--borde);
  transition: background-color 0.3s ease, border-color 0.3s ease;
}
.barra-interior { display: flex; align-items: center; justify-content: space-between; height: 58px; }
.logo {
  display: inline-flex; align-items: center; gap: 12px;
  color: var(--black-900); font-weight: 800; font-size: 22px; letter-spacing: -0.04em;
  transition: transform 0.2s var(--curva-suave), opacity 0.2s;
}
.logo:hover { text-decoration: none; transform: translateY(-1px); opacity: 0.95; }
.logo-icono {
  display: inline-flex; align-items: center; justify-content: center;
  width: 38px; height: 38px; border-radius: 10px;
  background: #ffffff;
  border: 1.5px solid var(--green-neon);
  box-shadow: 0 2px 10px rgba(0, 230, 118, 0.25);
  overflow: hidden; padding: 4px;
  transition: all 0.3s var(--curva-suave);
}
.logo:hover .logo-icono {
  background: var(--green-neon);
  transform: scale(1.08) rotate(-4deg);
  box-shadow: 0 4px 16px rgba(0, 230, 118, 0.5);
}
.logo-icono img {
  width: 100%; height: 100%; object-fit: contain;
  display: block;
  transition: transform 0.3s ease;
}
.logo:hover .logo-icono img {
  transform: scale(1.05);
}

.nav { display: flex; gap: 24px; align-items: center; font-size: 15px; font-weight: 600; }
.nav a { color: var(--black-900); opacity: 0.82; transition: opacity 0.2s ease, color 0.2s ease; }
.nav a:hover { opacity: 1; color: var(--green-700); text-decoration: none; }
.nav-carrito { display: inline-flex; align-items: center; gap: 8px; }

/* Contador del carrito con animación pop y fondo verde neón */
.contador {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 22px; height: 22px; padding: 0 7px; border-radius: 999px;
  background: var(--black-900); color: var(--green-neon); font-size: 12px; font-weight: 800;
  border: 1.5px solid var(--green-neon);
  box-shadow: 0 2px 10px rgba(0, 230, 118, 0.35);
  transition: transform 0.25s var(--curva-suave);
}
.contador.pop,
.contador:not([hidden]) {
  animation: bounceBadge 0.45s var(--curva-suave);
}

/* ---------- Botones con Identidad Verde, Blanco y Negro ---------- */
.boton, .boton-secundario {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 46px; padding: 11px 24px; border-radius: var(--radio-pill);
  font: inherit; font-size: 16px; font-weight: 700; cursor: pointer;
  border: 2px solid transparent; position: relative; overflow: hidden;
  transition: all 0.25s var(--curva-suave);
}
.boton {
  background: var(--green-700); color: #fff;
  box-shadow: 0 4px 16px rgba(4, 120, 87, 0.3);
}
.boton:hover {
  background: var(--green-800);
  text-decoration: none;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(4, 120, 87, 0.4);
}
.boton:active {
  transform: translateY(0) scale(0.98);
  box-shadow: 0 2px 8px rgba(4, 120, 87, 0.2);
}
.boton:disabled {
  background: var(--gray-300);
  color: var(--gray-500);
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}
.boton-secundario {
  background: #fff; color: var(--green-700); border-color: var(--green-600);
  box-shadow: var(--sombra-sm);
}
.boton-secundario:hover {
  background: var(--green-50);
  border-color: var(--green-800);
  color: var(--green-800);
  text-decoration: none;
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(4, 120, 87, 0.15);
}
.boton-secundario:active { transform: translateY(0) scale(0.98); }
.boton-texto {
  background: none; border: 0; padding: 4px 0; color: var(--green-700);
  font: inherit; font-size: 14px; font-weight: 600; cursor: pointer;
  transition: color 0.2s ease, transform 0.15s;
}
.boton-texto:hover { color: var(--green-900); text-decoration: underline; transform: translateY(-1px); }
.boton-bloque { width: 100%; }
:focus-visible { outline: 3px solid var(--green-500); outline-offset: 2px; }

/* ---------- Hero y Banner Promocional Animado ---------- */
.hero {
  position: relative;
  background:
    radial-gradient(ellipse 90% 65% at 50% -10%, rgba(0, 230, 118, 0.12) 0%, transparent 75%),
    radial-gradient(circle at 10% 20%, rgba(5, 150, 105, 0.06) 0%, transparent 40%),
    var(--white-soft);
  padding: 68px 0 58px;
  text-align: center;
  border-bottom: 1.5px solid var(--gray-200);
  overflow: hidden;
}
.hero-crest {
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 18px;
}
.hero-logo-img {
  width: 80px; height: 80px; object-fit: contain;
  filter: drop-shadow(0 10px 22px rgba(0, 230, 118, 0.45));
  animation: heroFadeIn 0.5s var(--curva-suave) both, floatFigure 5s ease-in-out infinite alternate;
}
.hero-tag {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--black-900); color: var(--green-neon);
  border: 1px solid rgba(0, 230, 118, 0.4);
  font-size: 13px; font-weight: 800; text-transform: uppercase;
  letter-spacing: 0.12em; padding: 6px 16px; border-radius: var(--radio-pill);
  margin-bottom: 16px; box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  animation: heroFadeIn 0.5s var(--curva-suave) both;
}
.hero-tag::before {
  content: ""; width: 7px; height: 7px; border-radius: 50%;
  background: var(--green-neon); box-shadow: 0 0 8px var(--green-neon);
}
.hero h1 {
  font-size: clamp(44px, 7.5vw, 70px);
  margin-bottom: 8px;
  letter-spacing: -0.04em;
  animation: heroFadeIn 0.6s var(--curva-suave) 0.05s both;
}
.hero .subtitulo {
  font-size: clamp(19px, 2.5vw, 24px);
  color: var(--texto-2);
  margin-bottom: 34px;
  font-weight: 500;
  animation: heroFadeIn 0.6s var(--curva-suave) 0.15s both;
}

/* Banner de promoción dinámico Negro-Verde con degradado animado */
.banner-promo {
  display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap;
  max-width: 800px; margin: 0 auto; padding: 26px 30px; text-align: left;
  border-radius: var(--radio); color: #fff; cursor: pointer; position: relative;
  background: linear-gradient(130deg, #040705 0%, #09150f 35%, #053b21 72%, #00e676 100%);
  background-size: 230% 230%;
  animation: heroFadeIn 0.65s var(--curva-suave) 0.22s both, gradientShift 9s ease infinite alternate;
  box-shadow: 0 14px 34px -4px rgba(0, 230, 118, 0.28), 0 4px 14px rgba(4, 7, 5, 0.2);
  border: 1.5px solid rgba(0, 230, 118, 0.35);
  transition: transform 0.3s var(--curva-suave), box-shadow 0.3s var(--curva-suave);
}
.banner-promo:hover {
  text-decoration: none;
  transform: translateY(-3px) scale(1.01);
  box-shadow: 0 20px 42px -6px rgba(0, 230, 118, 0.45), 0 8px 20px rgba(4, 7, 5, 0.3);
}
.banner-promo .eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 13px; text-transform: uppercase; letter-spacing: 0.12em;
  opacity: 0.95; margin: 0 0 6px; font-weight: 800; color: #a7f3d0;
}
.banner-promo .eyebrow::before {
  content: ""; display: inline-block; width: 9px; height: 9px; border-radius: 50%;
  background: var(--green-neon);
  box-shadow: 0 0 0 0 rgba(0, 230, 118, 0.8);
  animation: pulseDot 2s infinite;
}
.banner-promo strong {
  display: block; font-size: clamp(21px, 3.2vw, 27px);
  letter-spacing: -0.025em; line-height: 1.25; font-weight: 800;
}
.banner-promo .codigo {
  display: inline-block; margin-top: 8px; padding: 5px 14px;
  border: 1.5px dashed var(--green-neon);
  border-radius: 8px; background: rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(6px);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 15px; font-weight: 800; letter-spacing: 0.08em; color: var(--green-neon);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}
.banner-promo .cta {
  background: #ffffff; color: var(--black-950);
  border-radius: var(--radio-pill); padding: 12px 24px;
  font-weight: 800; font-size: 15px; white-space: nowrap;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
  transition: all 0.25s var(--curva-suave);
}
.banner-promo:hover .cta {
  background: var(--green-neon);
  color: var(--black-950);
  transform: scale(1.05);
  box-shadow: 0 6px 22px rgba(0, 230, 118, 0.5);
}

/* ---------- Catálogo y Tarjetas con Siluetas de Ropa Visibles ---------- */
.titulo-seccion {
  display: flex; align-items: baseline; justify-content: space-between;
  gap: 16px; flex-wrap: wrap; margin-bottom: 28px;
}
.titulo-seccion h2 { margin: 0; }
.grilla {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(235px, 1fr));
  gap: 24px;
}
.tarjeta {
  display: flex; flex-direction: column; color: var(--texto);
  background: #ffffff; border: 1.5px solid var(--borde);
  border-radius: var(--radio); overflow: hidden; position: relative;
  box-shadow: var(--sombra-sm);
  transition: transform 0.3s var(--curva-suave), box-shadow 0.3s var(--curva-suave), border-color 0.3s ease;
  animation: cardEnter 0.55s var(--curva-suave) both;
}
/* Entrada en cascada escalonada para catálogo */
.grilla .tarjeta:nth-child(1) { animation-delay: 0.04s; }
.grilla .tarjeta:nth-child(2) { animation-delay: 0.08s; }
.grilla .tarjeta:nth-child(3) { animation-delay: 0.12s; }
.grilla .tarjeta:nth-child(4) { animation-delay: 0.16s; }
.grilla .tarjeta:nth-child(5) { animation-delay: 0.20s; }
.grilla .tarjeta:nth-child(6) { animation-delay: 0.24s; }
.grilla .tarjeta:nth-child(7) { animation-delay: 0.28s; }
.grilla .tarjeta:nth-child(8) { animation-delay: 0.32s; }

.tarjeta:hover {
  text-decoration: none;
  transform: translateY(-7px);
  box-shadow: var(--sombra-hover);
  border-color: var(--green-500);
}
.tarjeta-info { padding: 18px 20px 22px; display: flex; flex-direction: column; gap: 5px; flex: 1; }
.tarjeta-categoria {
  font-size: 12px; font-weight: 800; text-transform: uppercase;
  letter-spacing: 0.08em; color: var(--green-700);
}
.tarjeta-nombre { font-size: 18px; font-weight: 800; color: var(--black-900); }
.tarjeta-ver {
  margin-top: auto; padding-top: 10px; color: var(--green-700);
  font-size: 14px; font-weight: 700; display: inline-flex; align-items: center; gap: 4px;
  transition: gap 0.2s ease, color 0.2s ease;
}
.tarjeta:hover .tarjeta-ver {
  color: var(--green-800);
  gap: 8px;
}

/* =====================================================================
   BLOQUE VISUAL CON FIGURAS VECTORIALES DE LOS OBJETOS
   ===================================================================== */
.visual {
  position: relative; display: flex; align-items: center; justify-content: center;
  aspect-ratio: 4 / 3; color: #fff; overflow: hidden;
  border-bottom: 1px solid rgba(0, 230, 118, 0.2);
}
/* Efecto de luz ambiental especular */
.visual::before {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(circle at 35% 25%, rgba(0, 230, 118, 0.18) 0%, transparent 68%);
  pointer-events: none;
}
/* Destello de brillo animado en hover */
.visual::after {
  content: ""; position: absolute; top: -50%; left: -60%; width: 45%; height: 200%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  transform: rotate(25deg); opacity: 0; pointer-events: none;
}
.tarjeta:hover .visual::after {
  opacity: 1;
  animation: shimmerSweep 0.85s ease forwards;
}

/* Contenedor de la silueta / ilustración del producto */
.visual-figura {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  padding: 16px; z-index: 2; pointer-events: none;
}
.figura-svg {
  width: 76%; height: 76%; max-height: 145px;
  filter: drop-shadow(0 10px 18px rgba(0, 0, 0, 0.55));
  transition: transform 0.4s var(--curva-suave), filter 0.35s ease;
}
.tarjeta:hover .figura-svg {
  transform: scale(1.12) translateY(-4px);
  filter: drop-shadow(0 14px 26px rgba(0, 230, 118, 0.38)) drop-shadow(0 8px 16px rgba(0, 0, 0, 0.7));
}

/* Etiqueta técnica de siglas (esquina superior derecha) */
.visual-siglas {
  position: absolute; top: 12px; right: 14px;
  font-size: 12px; font-weight: 800; letter-spacing: 0.08em;
  background: rgba(4, 7, 5, 0.75); color: #fff;
  border: 1px solid rgba(0, 230, 118, 0.4);
  padding: 3px 8px; border-radius: 6px; z-index: 3;
  backdrop-filter: blur(6px);
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.4);
  transition: border-color 0.2s, color 0.2s;
}
.tarjeta:hover .visual-siglas {
  border-color: var(--green-neon);
  color: var(--green-neon);
}
.visual-marca {
  position: absolute; left: 16px; bottom: 12px; font-size: 11px;
  letter-spacing: 0.14em; text-transform: uppercase; font-weight: 800;
  color: rgba(255, 255, 255, 0.85); z-index: 3;
  text-shadow: 0 2px 6px rgba(0, 0, 0, 0.6);
}

/* En la página de detalle */
.visual-grande {
  border-radius: var(--radio); aspect-ratio: 1 / 1;
  box-shadow: var(--sombra-lg);
  border: 1.5px solid rgba(0, 230, 118, 0.3);
}
.visual-grande .figura-svg {
  width: 82%; height: 82%; max-height: 360px;
  animation: floatFigure 6s ease-in-out infinite alternate;
}
.visual-grande .visual-siglas {
  font-size: 14px; padding: 4px 12px; border-radius: 8px;
}

/* En el carrito de compras */
.visual-mini {
  width: 76px; height: 76px; aspect-ratio: auto;
  border-radius: var(--radio-sm); flex: none; box-shadow: var(--sombra-sm);
  border: 1px solid rgba(0, 230, 118, 0.3);
}
.visual-mini .visual-figura { padding: 6px; }
.visual-mini .figura-svg { width: 85%; height: 85%; }
.visual-mini .visual-siglas { display: none; }
.visual-mini .visual-marca { display: none; }

/* Precios y etiquetas con escala Verde/Negro/Blanco */
.precio { font-weight: 800; color: var(--black-900); font-size: 18px; }
.precio-antes {
  color: var(--gray-400); text-decoration: line-through;
  font-weight: 400; margin-left: 6px; font-size: 0.9em;
}
.etiqueta-descuento {
  display: inline-block; background: var(--green-50); color: var(--green-800);
  border: 1.5px solid var(--green-200); font-size: 12px; font-weight: 800;
  border-radius: 6px; padding: 2px 8px; letter-spacing: 0.04em;
}

/* ---------- Detalle de Producto ---------- */
.detalle {
  display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: start;
  animation: heroFadeIn 0.5s var(--curva-suave) both;
}
.detalle-info .tarjeta-categoria { display: block; margin-bottom: 8px; }
.detalle-precio { font-size: 28px; margin: 8px 0 20px; font-weight: 800; }
.detalle-desc { color: var(--texto-2); font-size: 16px; line-height: 1.6; }

.selector-cantidad {
  display: inline-flex; align-items: center;
  border: 2px solid var(--borde); border-radius: var(--radio-pill);
  overflow: hidden; background: #fff; box-shadow: var(--sombra-sm);
  transition: border-color 0.2s, box-shadow 0.2s;
}
.selector-cantidad:focus-within {
  border-color: var(--green-600);
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.2);
}
.selector-cantidad button {
  width: 44px; height: 44px; border: 0; background: transparent;
  font-size: 20px; font-weight: 700; cursor: pointer; color: var(--texto);
  transition: background-color 0.15s, transform 0.1s;
}
.selector-cantidad button:hover { background: var(--gray-100); color: var(--green-800); }
.selector-cantidad button:active { transform: scale(0.9); }
.selector-cantidad output, .selector-cantidad span {
  min-width: 40px; text-align: center; font-weight: 800; font-size: 16px;
}
.fila-compra { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; margin: 24px 0; }
.lista-beneficios { list-style: none; padding: 0; margin: 26px 0 0; color: var(--texto-2); font-size: 15px; }
.lista-beneficios li { padding: 10px 0; border-top: 1px solid var(--borde); }
.lista-beneficios li::before { content: "✓ "; color: var(--green-600); font-weight: 800; margin-right: 8px; }

/* Mensajes con estilo deportivo */
.mensaje-ok {
  background: var(--green-50); color: var(--green-900);
  border: 1.5px solid var(--green-200); border-radius: var(--radio-sm);
  padding: 14px 18px; font-size: 15px; box-shadow: var(--sombra-sm); font-weight: 500;
}
.mensaje-ok:not([hidden]) {
  animation: alertSlideIn 0.35s var(--curva-suave) both;
}
.mensaje-error {
  background: #fff1f2; color: #9f1239;
  border: 1.5px solid #fecdd3; border-radius: var(--radio-sm);
  padding: 14px 18px; font-size: 15px; box-shadow: var(--sombra-sm);
}
.mensaje-error:not([hidden]) {
  animation: alertSlideIn 0.35s var(--curva-suave) both;
}
.volver {
  display: inline-flex; align-items: center; gap: 6px;
  margin-bottom: 22px; font-size: 15px; font-weight: 700;
  color: var(--green-700);
  transition: transform 0.2s ease, color 0.2s ease;
}
.volver:hover { transform: translateX(-3px); color: var(--green-900); text-decoration: none; }

/* ---------- Paneles, Carrito y Checkout ---------- */
.panel {
  background: #ffffff; border: 1.5px solid var(--borde);
  border-radius: var(--radio); padding: 28px;
  box-shadow: var(--sombra);
}
.dos-columnas { display: grid; grid-template-columns: minmax(0, 1fr) 350px; gap: 32px; align-items: start; }
.linea-carrito {
  display: flex; gap: 16px; align-items: center; padding: 18px 0;
  border-bottom: 1px solid var(--gray-100);
}
.linea-carrito:first-child { padding-top: 0; }
.linea-info { flex: 1; min-width: 0; }
.linea-info a { color: var(--black-900); font-weight: 800; font-size: 17px; }
.linea-info a:hover { color: var(--green-700); }
.linea-acciones { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; }
.linea-subtotal { font-weight: 800; color: var(--black-900); font-size: 17px; }

.resumen h2 { font-size: 22px; }
.resumen-fila { display: flex; justify-content: space-between; gap: 12px; padding: 8px 0; font-size: 15px; }
.resumen-fila.total {
  border-top: 2px solid var(--borde); margin-top: 12px;
  padding-top: 16px; font-size: 21px; font-weight: 800; color: var(--black-900);
}
.resumen-fila .descuento { color: var(--green-600); font-weight: 800; }
.resumen-item { display: flex; justify-content: space-between; gap: 12px; font-size: 14px; color: var(--texto-2); padding: 5px 0; }

.form-cupon { display: flex; gap: 8px; margin: 18px 0 8px; }
.form-cupon input { flex: 1; min-width: 0; }
.cupon-activo {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  background: var(--green-50); border: 1.5px solid var(--green-300);
  color: var(--green-900); border-radius: var(--radio-sm);
  padding: 12px 16px; font-size: 14px; margin: 18px 0 8px;
  font-weight: 600;
  animation: alertSlideIn 0.3s var(--curva-suave) both;
}

label.campo { display: block; font-size: 14px; font-weight: 700; margin-bottom: 18px; color: var(--black-900); }
input[type="text"], select {
  display: block; width: 100%; margin-top: 6px; padding: 12px 16px; min-height: 48px;
  font: inherit; font-size: 16px; color: var(--texto); background: #fff;
  border: 1.5px solid var(--borde); border-radius: var(--radio-sm);
  transition: border-color 0.2s, box-shadow 0.2s;
}
input[type="text"]:focus, select:focus {
  outline: none; border-color: var(--green-600);
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.2);
}
.form-cupon input { margin-top: 0; text-transform: uppercase; font-weight: 700; }
.ayuda { font-size: 13px; color: var(--texto-2); margin: -10px 0 18px; line-height: 1.4; }
fieldset { border: 0; padding: 0; margin: 0 0 20px; }
legend { font-size: 14px; font-weight: 700; margin-bottom: 10px; padding: 0; color: var(--black-900); }
.opciones { display: grid; gap: 10px; }
.opcion {
  display: flex; align-items: center; gap: 14px; padding: 16px 18px; cursor: pointer;
  background: #fff; border: 1.5px solid var(--borde); border-radius: var(--radio-sm); font-size: 15px;
  transition: border-color 0.2s, background-color 0.2s, box-shadow 0.2s, transform 0.15s;
}
.opcion:hover {
  border-color: var(--green-400);
  transform: translateY(-1px);
  box-shadow: var(--sombra-sm);
}
.opcion:has(input:checked) {
  border-color: var(--green-600);
  background: var(--green-50);
  box-shadow: 0 0 0 1px var(--green-600), 0 4px 14px rgba(4, 120, 87, 0.12);
}
.opcion input { accent-color: var(--green-600); width: 18px; height: 18px; margin: 0; }
.opcion .opcion-texto { flex: 1; font-weight: 600; }
.opcion .opcion-detalle { display: block; font-size: 13px; color: var(--texto-2); font-weight: 400; margin-top: 2px; }
.opcion .opcion-precio { font-weight: 800; color: var(--black-900); }

/* Indicador de pasos animado */
.pasos { display: flex; gap: 12px; list-style: none; padding: 0; margin: 0 0 28px; font-size: 14px; }
.pasos li {
  padding: 9px 20px; border-radius: var(--radio-pill);
  background: var(--gray-100); color: var(--gray-500);
  font-weight: 700; transition: all 0.3s var(--curva-suave);
}
.pasos li.activo {
  background: var(--black-950); color: var(--green-neon);
  box-shadow: 0 4px 14px rgba(4, 7, 5, 0.25);
  border: 1px solid var(--green-neon);
  animation: stepPulse 2.5s infinite;
}
.pasos li.hecho {
  background: var(--green-50); color: var(--green-800);
  border: 1.5px solid var(--green-200);
}

.acciones { display: flex; gap: 12px; flex-wrap: wrap; justify-content: space-between; }
.aviso {
  font-size: 13px; color: var(--texto-2); background: var(--white-soft);
  border-radius: var(--radio-sm); padding: 12px 16px; border: 1.5px dashed var(--gray-300);
}
.estado-vacio { text-align: center; padding: 52px 24px; }
.estado-vacio .boton { margin-top: 14px; }

/* ---------- Confirmación (Gracias) ---------- */
.check-grande {
  width: 78px; height: 78px; margin: 0 auto 18px; display: block;
  animation: checkBounce 0.65s var(--curva-suave) both;
}
.check-grande circle {
  fill: var(--green-600) !important;
}
.check-grande path {
  stroke-dasharray: 60; stroke-dashoffset: 60;
  animation: drawCheck 0.6s 0.3s cubic-bezier(0.65, 0, 0.45, 1) forwards;
}
.pedido {
  max-width: 580px; margin: 28px auto 0; text-align: left;
  animation: heroFadeIn 0.5s var(--curva-suave) 0.2s both;
}
.pedido-id {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 14px; font-weight: 800; color: var(--green-700);
}

/* ---------- Pie de Página ---------- */
.pie {
  background: var(--white-soft); color: var(--texto-2);
  font-size: 13px; line-height: 1.6; padding: 36px 0 44px;
  border-top: 1.5px solid var(--borde); margin-top: 48px;
}
.pie-brand {
  display: inline-flex; align-items: center; gap: 10px; margin-bottom: 16px;
  background: #ffffff; padding: 6px 14px; border-radius: var(--radio-pill);
  border: 1px solid var(--gray-200); box-shadow: var(--sombra-sm);
}
.pie-logo-img {
  width: 26px; height: 26px; object-fit: contain;
}
.pie-brand-name {
  font-size: 14px; font-weight: 800; color: var(--black-900); letter-spacing: -0.02em;
}
.pie p { margin: 0 0 8px; }
.pie strong { color: var(--black-900); }

/* =====================================================================
   MONITOR DE EVENTOS GA4 (Estilo DevTools Negro / Verde Neón)
   ===================================================================== */
body.con-monitor { padding-right: var(--monitor-ancho); }
body.con-monitor.monitor-plegado { padding-right: 0; }

.monitor {
  position: fixed; top: 0; right: 0; bottom: 0; z-index: 100;
  width: var(--monitor-ancho);
  display: flex; flex-direction: column;
  background: #040705; color: #f0fdf4;
  font-family: var(--fuente); font-size: 13px; line-height: 1.45;
  border-left: 1.5px solid #14201b;
  box-shadow: -6px 0 28px rgba(0, 0, 0, 0.55);
  transition: transform 0.3s var(--curva-suave), opacity 0.3s;
}
.monitor-cabecera {
  display: flex; align-items: center; justify-content: space-between;
  gap: 10px; padding: 14px 16px; border-bottom: 1.5px solid #14201b;
  background: #090e0c; flex: none;
}
.monitor-titulo { font-size: 14px; font-weight: 800; color: #ffffff; letter-spacing: -0.02em; }
.monitor-toggle {
  background: #14201b; color: var(--green-neon); border: 1px solid #1d2c26;
  border-radius: var(--radio-pill); padding: 6px 14px;
  font: inherit; font-size: 12px; font-weight: 700; cursor: pointer;
  transition: background-color 0.2s, transform 0.15s;
}
.monitor-toggle:hover { background: #1d2c26; }
.monitor-toggle:active { transform: scale(0.96); }
.monitor-cuerpo {
  flex: 1; min-height: 0; overflow-y: auto; padding: 14px 16px 20px;
  display: flex; flex-direction: column; gap: 12px;
}
.monitor-estado {
  margin: 0; padding: 10px 14px; border-radius: 10px; font-weight: 700; font-size: 12px;
}
.monitor-estado.ok {
  background: rgba(0, 230, 118, 0.15); color: #00e676;
  border: 1px solid rgba(0, 230, 118, 0.45);
}
.monitor-estado.error {
  background: rgba(225, 29, 72, 0.15); color: #fb7185;
  border: 1px solid rgba(225, 29, 72, 0.45);
}
.monitor-origen {
  background: #090e0c; border-radius: 10px; border: 1px solid #14201b;
  padding: 10px 14px; display: flex; flex-direction: column; gap: 3px;
}
.monitor-etiqueta {
  margin: 0; font-size: 11px; text-transform: uppercase;
  letter-spacing: 0.08em; color: #86efac; font-weight: 800;
}
.monitor-valor {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 12px; word-break: break-word; color: #00e676; font-weight: 600;
}
.monitor-lista { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.monitor-evento details {
  background: #090e0c; border-radius: 10px; border: 1px solid #14201b;
  border-left: 3.5px solid #00e676;
  transition: background-color 0.2s, transform 0.15s;
}
.monitor-evento details:hover { background: #0f1713; }
.monitor-evento.es-compra details { border-left-color: #34d399; }
.monitor-evento:first-child details {
  animation: eventGlow 1.4s ease-out;
}
.monitor-evento summary {
  list-style: none; cursor: pointer; padding: 9px 12px;
  display: grid; grid-template-columns: auto 1fr; column-gap: 8px; row-gap: 3px;
}
.monitor-evento summary::-webkit-details-marker { display: none; }
.monitor-hora {
  color: #6ee7b7; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 11px;
}
.monitor-nombre {
  color: #ffffff; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 12px; font-weight: 800;
}
.monitor-resumen { grid-column: 1 / -1; color: #cbd5cf; font-size: 12px; word-break: break-word; }
.monitor-json {
  margin: 0; padding: 10px 12px 12px; font-size: 11px; color: #d1fae5;
  background: #020604; white-space: pre-wrap; word-break: break-word;
  border-top: 1px solid #14201b; max-height: 260px; overflow: auto;
}
.monitor-vacio { color: #86efac; padding: 10px 0; text-align: center; }
.monitor-reset {
  margin-top: auto; background: var(--green-700); color: #fff;
  border: 1px solid var(--green-neon); border-radius: var(--radio-pill); padding: 12px 16px;
  font: inherit; font-size: 13px; font-weight: 800; cursor: pointer;
  box-shadow: 0 4px 16px rgba(0, 230, 118, 0.25);
  transition: background-color 0.2s, transform 0.15s;
}
.monitor-reset:hover { background: var(--green-800); transform: translateY(-1px); }
.monitor-reset:active { transform: translateY(0); }

/* Plegado: píldora flotante */
.monitor.plegado {
  top: auto; bottom: 20px; right: 20px; width: auto;
  border: 1.5px solid var(--green-neon); border-radius: var(--radio-pill);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.55);
  background: #040705;
}
.monitor.plegado .monitor-cabecera { border-bottom: 0; padding: 7px 8px 7px 16px; background: transparent; }
.monitor.plegado .monitor-cuerpo { display: none; }

/* =====================================================================
   KEYFRAMES DE ANIMACIONES
   ===================================================================== */
@keyframes heroFadeIn {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes gradientShift {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

@keyframes pulseDot {
  0% { box-shadow: 0 0 0 0 rgba(0, 230, 118, 0.8); }
  70% { box-shadow: 0 0 0 9px rgba(0, 230, 118, 0); }
  100% { box-shadow: 0 0 0 0 rgba(0, 230, 118, 0); }
}

@keyframes shimmerSweep {
  0% { transform: translateX(-150%) rotate(25deg); opacity: 0; }
  40% { opacity: 0.7; }
  100% { transform: translateX(260%) rotate(25deg); opacity: 0; }
}

@keyframes cardEnter {
  from { opacity: 0; transform: translateY(22px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes floatFigure {
  0% { transform: translateY(0px) scale(1); }
  100% { transform: translateY(-8px) scale(1.03); }
}

@keyframes bounceBadge {
  0% { transform: scale(0.6); }
  55% { transform: scale(1.25); }
  100% { transform: scale(1); }
}

@keyframes drawCheck {
  to { stroke-dashoffset: 0; }
}

@keyframes checkBounce {
  0% { opacity: 0; transform: scale(0.35); }
  60% { opacity: 1; transform: scale(1.12); }
  100% { transform: scale(1); }
}

@keyframes stepPulse {
  0% { box-shadow: 0 0 0 0 rgba(0, 230, 118, 0.55); }
  70% { box-shadow: 0 0 0 10px rgba(0, 230, 118, 0); }
  100% { box-shadow: 0 0 0 0 rgba(0, 230, 118, 0); }
}

@keyframes alertSlideIn {
  from { opacity: 0; transform: translateY(-10px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes eventGlow {
  0% { border-left-color: #00ff87; background: #042a19; }
  100% { border-left-color: #00e676; background: #090e0c; }
}

/* Accesibilidad: reducción de movimiento */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ---------- Responsivo ---------- */
@media (max-width: 900px) {
  .detalle { grid-template-columns: 1fr; gap: 32px; }
  .dos-columnas { grid-template-columns: 1fr; }
}

@media (max-width: 819.98px) {
  body.con-monitor { padding-right: 0; padding-bottom: var(--monitor-alto-movil); }
  body.con-monitor.monitor-plegado { padding-right: 0; padding-bottom: 0; }
  .monitor {
    top: auto; left: 0; right: 0; bottom: 0;
    width: auto; height: var(--monitor-alto-movil);
    border-left: 0; border-top: 1.5px solid #14201b;
  }
  .monitor.plegado { left: auto; height: auto; }
  .contenedor { padding: 0 16px; }
  .nav { gap: 16px; }
  .banner-promo { padding: 22px 24px; }
  .grilla { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 16px; }
  .visual-siglas { font-size: 11px; padding: 2px 6px; }
}
