/* ============================================================
   WAEG - Estilos Base / Desktop
   Los bloques @media max-width se movieron a shop-mobile.css
   ============================================================ */

/* ======================================
   ESTRUCTURA PRINCIPAL CON SIDEBAR LATERAL
   ====================================== */

.waeg-shop-wrapper {
  display: flex;
  flex-direction: row !important; /* FILA: Filtros izquierda, contenido derecha */
  gap: 32px !important; /* Espacio entre filtros y contenido */
  width: 100%;
  max-width: 1610px !important; /* Ancho máximo del contenedor (+15% para mostrar más categorías) */
  align-items: flex-start;
  padding: 0 20px !important; /* Padding lateral normal (sticky no necesita offset) */
  margin: 0 auto !important; /* CENTRAR TODO EL CONTENEDOR */
}

/* Panel lateral izquierdo: oculto — los filtros se abren como offcanvas */
/* Scope al wrapper del shop para no tapar el clon dentro del modal */
.waeg-shop-wrapper .waeg-filters-sidebar {
  display: none !important;
}

.waeg-filters-sidebar {
  position: sticky !important;
  left: auto !important;
  transform: none !important;
  top: 0 !important;
  height: 100% !important;
  min-height: auto !important;
  width:  242px;
  max-width: 242px;
  flex: 0 0 242px;
  background: #f8f9fa;
  border-radius: 33px !important; /* BORDES CIRCULARES (reducido 33%) */
  padding: 30px 20px !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  max-height: calc(100vh - 40px) !important; /* Altura máxima con margen */
  overflow-y: auto;
  margin: 0 !important;
  z-index: 1 !important;
  scrollbar-width: thin; /* Firefox */
  scrollbar-color: #bbb #f1f1f1; /* Firefox */
  align-self: flex-start; /* Alineación al inicio, no stretch */
  order: 1; /* Filtros PRIMERO (izquierda) */
}

/* Scrollbar personalizado para filtros en Chrome, Safari, Edge */
.waeg-filters-sidebar::-webkit-scrollbar {
  width: 8px;
}

.waeg-filters-sidebar::-webkit-scrollbar-track {
  background: #f1f1f1;
  border-radius: 10px;
}

.waeg-filters-sidebar::-webkit-scrollbar-thumb {
  background: #bbb;
  border-radius: 10px;
}

.waeg-filters-sidebar::-webkit-scrollbar-thumb:hover {
  background: #999;
}

/* Contenedor principal: categorías + grid */
.waeg-content-wrapper {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column !important; /* COLUMNA: Categorías arriba, productos abajo */
  gap: 0 !important; /* Sin gap, el padding de sidebar lo maneja */
  padding: 0 0 0 8px !important; /* Padding izquierdo adicional para separación */
  margin: 0 !important; /* Sin margin */
  align-items: stretch;
  order: 2; /* Contenido SEGUNDO (derecha) */
  position: relative;
  z-index: 2;
}

/* Panel superior de categorías (contenido oculto en desktop, visible en móvil) */
.waeg-sidebar {
  flex: 0 0 auto;
  width: 100%;
  background: transparent;
  border-radius: 0;
  padding: 0 !important; /* Sin padding en desktop — el contenido está oculto */
  margin: 0 !important;
  box-shadow: none;
  order: 1 !important;
}

.waeg-main-content {
  flex: 1;
  min-width: 0;
  overflow: visible; /* Permitir que el contenido se extienda */
  padding: 0 !important; /* Sin padding */
  margin: 0 !important; /* Sin margin */
  order: 2 !important; /* SEGUNDO: Productos abajo */
}

.waeg-sidebar-section {
  margin-bottom: 32px;
  transition: all 0.3s ease;
}

.waeg-sidebar-section:last-child {
  margin-bottom: 0;
}

/* ======================================
   ESTRUCTURA ANTIGUA DE CATEGORÍAS (DESHABILITADA)
   ====================================== */

/* Ocultar la estructura antigua de categorías horizontales */
.waeg-categories-container {
  display: none !important;
}

.waeg-categories-list,
#waeg-categories-list,
#waeg-subcategories-section {
  display: none !important;
}

/* ======================================
   FILTRO DE CATEGORÍAS TIPO PILLS (NUEVO SISTEMA)
   ====================================== */

.waeg-categories-filter-section {
  margin-bottom: 28px;
  padding-bottom: 28px;
  border-bottom: 1px solid #e0e0e0;
}

.waeg-categories-filter-section .waeg-sidebar-title {
  color: #333 !important;
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 12px;
  display: block;
}

/* Estilos para los selects de categorías */
.waeg-filter-select {
  width: 100%;
  padding: 10px 12px;
  font-size: 14px;
  color: var(--waeg-gray-700);
  background: var(--waeg-white);
  border: 2px solid var(--waeg-gray-200);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23333' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 36px;
}

.waeg-filter-select:hover {
  border-color: #999;
  background-color: #f9f9f9;
}

.waeg-filter-select:focus {
  outline: none;
  border-color: var(--waeg-dark);
  box-shadow: 0 0 0 3px rgba(44, 62, 80, 0.1);
}

.waeg-filter-select:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  background-color: #f0f0f0;
}

.waeg-subcategories-container {
  margin-top: 12px;
}

.waeg-subcategories-label {
  display: block;
  font-size: 13px;
  font-weight: 500;
  color: #666;
  margin-bottom: 6px;
}

/* Toggle icon para atributos */
.waeg-sidebar-title.waeg-collapsible {
  cursor: pointer;
  user-select: none;
  position: relative;
  padding-right: 25px;
  transition: color 0.2s ease;
}

.waeg-sidebar-title.waeg-collapsible:hover {
  color: #2c3e50 !important;
}

.waeg-toggle-icon {
  position: absolute;
  right: 0;
  font-size: 12px;
  transition: transform 0.3s ease;
}

.waeg-attributes-section.collapsed .waeg-toggle-icon {
  transform: rotate(-90deg);
}

.waeg-attributes-section.collapsed .waeg-attribute-filter {
  display: none;
}

/* Mantener estilos antiguos para pills si se necesitan */
.waeg-categories-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
  max-height: 1000px;
  overflow: hidden;
  transition: max-height 0.3s ease, opacity 0.3s ease;
  opacity: 1;
}

.waeg-categories-filter-section.collapsed .waeg-categories-pills {
  max-height: 0;
  opacity: 0;
  margin-top: 0;
}

.waeg-category-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 16px;
  font-size: 11px; /* Reducido 3px de 14px */
  font-weight: 500;
  color: #555;
  background: #fff;
  border: 2px solid #e0e0e0;
  border-radius: 20px;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.waeg-category-pill:hover {
  background: #f5f5f5;
  border-color: #999;
  color: #333;
}

.waeg-category-pill.active {
  background: #2c3e50;
  border-color: #2c3e50;
  color: #fff;
  font-weight: 600;
}

/* Subcategorías pills */
.waeg-subcategories-pills {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid #f0f0f0;
  max-height: 1000px;
  overflow: hidden;
  transition: max-height 0.3s ease, opacity 0.3s ease;
  opacity: 1;
}

.waeg-categories-filter-section.collapsed .waeg-subcategories-pills {
  max-height: 0;
  opacity: 0;
  margin-top: 0;
  padding-top: 0;
}

.waeg-subcategories-pills-title {
  font-size: 12px; /* Reducido de 14px */
  font-weight: 600;
  color: #555;
  margin-bottom: 10px;
}

.waeg-subcategories-pills .waeg-pills-container {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.waeg-subcategory-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 14px;
  font-size: 10px; /* Reducido 3px de 13px */
  font-weight: 500;
  color: #666;
  background: #f8f8f8;
  border: 1.5px solid #ddd;
  border-radius: 16px;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.waeg-subcategory-pill:hover {
  background: #fff;
  border-color: #999;
  color: #333;
}

.waeg-subcategory-pill.active {
  background: #3498db;
  border-color: #3498db;
  color: #fff;
  font-weight: 600;
}

/* ========================================
   FILTRO DE RANGO DE PRECIOS
   ======================================== */

.waeg-price-filter-section {
  margin-bottom: 28px;
  padding-bottom: 28px;
  border-bottom: 1px solid #e8ecef;
}

.waeg-price-filter-section .waeg-sidebar-title {
  color: #2d3748 !important;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  margin-bottom: 18px;
  display: flex;
  align-items: center;
  gap: 7px;
}

.waeg-price-icon {
  color: #6c757d;
  flex-shrink: 0;
  opacity: 0.8;
}

.waeg-price-filter {
  padding: 0;
}

/* --- Badges de precio min/max --- */
.waeg-price-display {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 22px;
}

.waeg-price-badge {
  flex: 1;
  background: #f7f8fa;
  border: 1.5px solid #e2e8f0;
  border-radius: 10px;
  padding: 8px 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  transition: border-color 0.2s ease, background 0.2s ease;
  min-width: 0;
}

.waeg-price-badge--min {
  border-left: 3px solid #42a5f5;
}

.waeg-price-badge--max {
  border-right: 3px solid #26a69a;
}

.waeg-price-badge-label {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: #8a9ab0;
  line-height: 1;
}

.waeg-price-badge-value {
  font-size: 13px;
  font-weight: 700;
  color: #2d3748;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

.waeg-price-separator {
  display: flex;
  align-items: center;
  flex-shrink: 0;
  padding: 0 2px;
}

/* --- Slider --- */
.waeg-price-slider-wrapper {
  position: relative;
  height: 44px;
  padding: 0 2px;
  margin-top: 4px;
}

.waeg-price-slider {
  position: absolute;
  width: 100%;
  height: 5px;
  -webkit-appearance: none;
  appearance: none;
  background: transparent;
  pointer-events: none;
  outline: none;
  z-index: 3;
  top: 20px;
  left: 0;
  margin: 0 !important;
}

/* Thumb min (azul) */
#waeg-price-min::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 18px;
  height: 18px;
  background: #fff;
  cursor: pointer;
  pointer-events: all;
  border-radius: 50%;
  border: 2.5px solid #42a5f5;
  box-shadow: 0 2px 8px rgba(66, 165, 245, 0.35);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  position: relative;
  z-index: 5;
}

#waeg-price-min::-webkit-slider-thumb:hover {
  transform: scale(1.18);
  box-shadow: 0 3px 12px rgba(66, 165, 245, 0.5);
}

#waeg-price-min::-webkit-slider-thumb:active {
  transform: scale(1.25);
  box-shadow: 0 4px 14px rgba(66, 165, 245, 0.6);
}

#waeg-price-min::-moz-range-thumb {
  width: 18px;
  height: 18px;
  background: #fff;
  cursor: pointer;
  pointer-events: all;
  border-radius: 50%;
  border: 2.5px solid #42a5f5;
  box-shadow: 0 2px 8px rgba(66, 165, 245, 0.35);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  z-index: 5;
}

#waeg-price-min::-moz-range-thumb:hover {
  transform: scale(1.18);
  box-shadow: 0 3px 12px rgba(66, 165, 245, 0.5);
}

/* Thumb max (verde azulado) */
#waeg-price-max::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 18px;
  height: 18px;
  background: #fff;
  cursor: pointer;
  pointer-events: all;
  border-radius: 50%;
  border: 2.5px solid #26a69a;
  box-shadow: 0 2px 8px rgba(38, 166, 154, 0.35);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  position: relative;
  z-index: 5;
}

#waeg-price-max::-webkit-slider-thumb:hover {
  transform: scale(1.18);
  box-shadow: 0 3px 12px rgba(38, 166, 154, 0.5);
}

#waeg-price-max::-webkit-slider-thumb:active {
  transform: scale(1.25);
  box-shadow: 0 4px 14px rgba(38, 166, 154, 0.6);
}

#waeg-price-max::-moz-range-thumb {
  width: 18px;
  height: 18px;
  background: #fff;
  cursor: pointer;
  pointer-events: all;
  border-radius: 50%;
  border: 2.5px solid #26a69a;
  box-shadow: 0 2px 8px rgba(38, 166, 154, 0.35);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  z-index: 5;
}

#waeg-price-max::-moz-range-thumb:hover {
  transform: scale(1.18);
  box-shadow: 0 3px 12px rgba(38, 166, 154, 0.5);
}

/* Track base */
.waeg-price-track {
  position: absolute;
  top: 20px;
  left: 2px;
  right: 2px;
  height: 5px;
  background: #e8ecef;
  border-radius: 99px;
  pointer-events: none;
  z-index: 1;
}

/* Track fill con gradiente azul → verde */
.waeg-price-track-fill {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 100%;
  background: linear-gradient(90deg, #42a5f5 0%, #26c6da 50%, #26a69a 100%);
  border-radius: 99px;
  transition: left 0.12s ease, width 0.12s ease;
  z-index: 2;
}

/* ========================================
   OCULTAR ELEMENTOS DUPLICADOS EN CATEGORÍAS
   (Ordenar por, Buscador, Limpiar filtros)
   ======================================== */

/* Ocultar sección de ordenar por en las categorías (ya está en filtros) */
.waeg-sidebar .waeg-sort-section {
  display: none !important;
}

/* Ocultar sección de controles (buscador + limpiar) en las categorías */
.waeg-sidebar .waeg-controls-section {
  display: none !important;
}

/* Sección de controles (buscador + ordenamiento + limpiar) AL FINAL */
.waeg-controls-section {
  margin-top: 24px !important;
  margin-bottom: 0 !important;
  padding-top: 24px;
  border-top: 2px solid #e0e0e0;
}

.waeg-controls-top {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  margin-bottom: 0; /* Cambiado de 12px a 0 */
  flex-wrap: wrap; /* Permitir que los elementos se envuelvan en móviles */
}

.waeg-search-wrapper {
  position: relative;
  flex: 1;
  min-width: 200px; /* Mínimo para el buscador */
}

/* Nuevo: Selector de items por página */
.waeg-perpage-wrapper {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
  white-space: nowrap;
}

.waeg-perpage-wrapper label {
  font-size: 13px;
  font-weight: 600;
  color: #ffffff; /* Blanco para consistencia */
  white-space: nowrap;
}

.waeg-items-select {
  padding: 10px 32px 10px 12px;
  font-size: 14px;
  border: 2px solid #ddd;
  border-radius: 8px;
  background: white;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23333' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 12px;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  transition: all 0.3s ease;
  min-width: 140px;
}

.waeg-items-select:hover {
  border-color: #333;
}

.waeg-items-select:focus {
  outline: none;
  border-color: #333;
  box-shadow: 0 0 0 3px rgba(0,0,0,0.1);
}

#waeg-search {
  padding: 12px 16px;
  font-size: 14px;
  width: 100%;
  border: 2px solid #ddd;
  border-radius: 10px;
  background: white;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

#waeg-search:hover {
  border-color: #999;
}

#waeg-search:focus {
  outline: none;
  border-color: #0073aa;
  box-shadow: 0 0 0 4px rgba(0, 115, 170, 0.1), 0 4px 12px rgba(0, 0, 0, 0.1);
  transform: translateY(-1px);
}

#waeg-search::placeholder {
  color: #999;
  transition: color 0.3s ease;
}

#waeg-search:focus::placeholder {
  color: #ccc;
}

#waeg-search-suggestions {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  margin-top: 8px;
  background: white;
  border: 1px solid #ddd;
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.15);
  max-height: 400px;
  overflow-y: auto;
  z-index: 1000;
}

.waeg-sort-wrapper {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
  white-space: nowrap;
}

.waeg-sort-wrapper label {
  font-size: 13px;
  font-weight: 600;
  color: #ffffff; /* Cambiado a blanco */
  white-space: nowrap;
}

.waeg-sort-select {
  padding: 10px 32px 10px 12px;
  font-size: 14px;
  border: 2px solid #ddd;
  border-radius: 8px;
  background: white;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23333' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 12px;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  transition: all 0.3s ease;
  min-width: 160px;
}

.waeg-sort-select:hover {
  border-color: #333;
}

.waeg-sort-select:focus {
  outline: none;
  border-color: #333;
  box-shadow: 0 0 0 3px rgba(0,0,0,0.1);
}

/* Botón de limpiar filtros dentro del sidebar */
.waeg-filters {
  display: contents; /* Cambiado de flex a contents para que el botón se integre en la línea superior */
}

.waeg-clear-btn {
  background: #dc3545 !important;
  color: white !important;
  font-weight: 600;
  padding: 10px 20px !important;
  border-radius: 8px !important;
  transition: all 0.3s ease;
  border: 2px solid #dc3545 !important;
  width: auto; /* Cambiado de 100% a auto */
  font-size: 14px;
  flex-shrink: 0;
  white-space: nowrap;
}

.waeg-clear-btn:hover {
  background: #c82333 !important;
  border-color: #c82333 !important;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(220, 53, 69, 0.3);
}

.waeg-clear-btn:active {
  transform: translateY(0);
}

/* Responsive para controles dentro del sidebar */
/* ⇒ MOBILE [1]: @media (max-width: 991px) { — ver shop-mobile.css */

/* ⇒ MOBILE [2]: @media (max-width: 767px) { — ver shop-mobile.css */

/* Animación para subcategorías */
#waeg-subcategories-section {
  opacity: 0;
  max-height: 0;
  overflow: hidden;
  transition: opacity 0.3s ease, max-height 0.3s ease;
}

#waeg-subcategories-section.show {
  opacity: 1;
  max-height: 1000px;
}

.waeg-sidebar-title {
  font-size: 18px;
  font-weight: 700;
  margin: 0 0 16px 0;
  color: #ffffff; /* Cambiado de #333 a blanco */
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-bottom: 2px solid #ffffff; /* Cambiado de #333 a blanco */
  padding-bottom: 8px;
}

/* Listas de categorías y subcategorías */
.waeg-categories-list,
.waeg-subcategories-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

/* Grid para categorías principales - solo texto */
.waeg-categories-list {
  display: flex;
  flex-wrap: wrap;
  gap: 12px; /* Espacio entre botones */
  margin-top: 10px;
  justify-content: start; /* Alinear desde la izquierda */
}

.waeg-categories-list li {
  margin-bottom: 0;
  display: flex;
  justify-content: center;
}

/* Subcategorías en scroll horizontal */
.waeg-subcategories-list {
  display: flex;
  overflow-x: auto;
  overflow-y: hidden;
  gap: 12px;
  padding: 8px 0;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
}

.waeg-subcategories-list li {
  margin-bottom: 0;
  flex: 0 0 auto;
}

/* Categorías principales - estilo pill ajustable (como subcategorías) */
.waeg-category-item {
  background: rgba(255, 255, 255, 0.9); /* Fondo blanco semi-transparente */
  border: 2px solid rgba(0, 0, 0, 0.2); /* Borde gris sutil */
  border-radius: 8px; /* Esquinas redondeadas sutiles */
  padding: 10px 20px; /* Padding ajustado para pill */
  font-size: 15px; /* Texto aumentado +2px */
  font-weight: 600;
  color: #000000; /* Texto NEGRO por defecto */
  cursor: pointer;
  transition: all 0.3s ease;
  display: inline-flex; /* Flex para mejor alineación */
  align-items: center;
  justify-content: center;
  text-align: center;
  white-space: nowrap; /* Evitar saltos de línea */
  text-transform: uppercase;
  letter-spacing: 0.5px;
  min-height: 42px; /* Altura mínima para uniformidad */
  width: auto; /* ANCHO AUTOMÁTICO - se ajusta al contenido */
}

.waeg-category-item:hover {
  background: rgba(255, 255, 255, 0.95); /* Fondo blanco más sólido en hover */
  border-color: #e74c3c; /* Borde rojo sólido */
  color: #e74c3c; /* Texto ROJO en hover */
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(231, 76, 60, 0.3); /* Sombra roja */
}

.waeg-category-item.active {
  background: #e74c3c; /* Fondo rojo sólido cuando está activo */
  color: #ffffff; /* Texto blanco cuando está activo */
  border-color: #e74c3c; /* Borde rojo */
  font-weight: 700;
  box-shadow: 0 4px 12px rgba(231, 76, 60, 0.4); /* Sombra más fuerte */
}

/* Icono OCULTO en categorías principales (ahora son solo pills de texto) */
.waeg-category-item .waeg-category-icon {
  display: none !important; /* OCULTAR completamente los iconos */
  width: 60px; /* Reducido de 80px */
  height: 60px; /* Reducido de 80px */
  background: transparent; /* Sin fondo */
  border: none; /* Sin borde */
  border-radius: 0; /* Sin border-radius */
  align-items: center;
  justify-content: center;
  font-size: 32px; /* Reducido de 36px */
  margin-right: 0;
  margin-bottom: 0;
  transition: all 0.3s ease;
  overflow: visible; /* Cambiado de hidden a visible */
  position: relative;
}

.waeg-category-item:hover .waeg-category-icon {
  border-color: transparent; /* Sin borde */
  box-shadow: none; /* Sin sombra */
  transform: scale(1.1); /* Aumentado de 1.05 */
}

.waeg-category-item.active .waeg-category-icon {
  border-color: transparent; /* Sin borde */
  background: transparent; /* Sin fondo */
  box-shadow: none; /* Sin sombra */
  transform: scale(1.15); /* Icono más grande cuando está activo */
}

/* Imágenes en categorías principales */
.waeg-category-item .waeg-category-icon img.waeg-category-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 0;
  padding: 0; /* Sin padding */
  box-sizing: border-box;
  transition: all 0.3s ease;
  filter: none; /* Sin filtros por defecto */
}

/* Efecto hover en la imagen */
.waeg-category-item:hover .waeg-category-icon img.waeg-category-image {
  filter: brightness(1.1) contrast(1.1);
}

/* Imagen cuando está activo */
.waeg-category-item.active .waeg-category-icon img.waeg-category-image {
  filter: brightness(1.2) contrast(1.15);
}

/* Nombre de categoría - ajustado para pills */
.waeg-category-item span:not(.waeg-category-icon):not(.waeg-category-count) {
  font-size: 13px; /* Texto más grande para pills */
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  line-height: 1.2;
  word-wrap: normal; /* Sin saltos de línea */
  text-align: center;
  display: inline; /* Inline para que fluya naturalmente */
  color: #000000; /* Texto NEGRO por defecto */
  transition: all 0.3s ease;
  white-space: nowrap; /* Mantener en una sola línea */
}

.waeg-category-item:hover span:not(.waeg-category-icon):not(.waeg-category-count) {
  color: #e74c3c; /* Texto ROJO en hover */
}

.waeg-category-item.active span:not(.waeg-category-icon):not(.waeg-category-count) {
  color: #ffffff; /* Texto BLANCO cuando está activo */
  font-weight: 700;
}

/* Ocultar contador en todas las categorías */
.waeg-category-count,
.waeg-tab-count {
  display: none !important;
}

/* Subcategorías - mantener diseño circular existente */
.waeg-subcategory-item {
  padding: 16px 12px;
  font-size: 13px;
  background: #fcfcfc;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  min-width: 80px;
  max-width: 140px; /* Aumentado para textos largos */
  border-radius: 12px;
  gap: 8px;
  white-space: normal; /* Permite saltos de línea */
  overflow: visible; /* Evita que se corte el texto */
}

.waeg-subcategory-item.active {
  background: #555;
}

/* Iconos en subcategorías - layout circular */
.waeg-subcategory-item .waeg-category-icon {
  margin-right: 0;
  margin-bottom: 4px;
  font-size: 32px;
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f0f0f0;
  border-radius: 50%;
  transition: all 0.3s ease;
}

.waeg-subcategory-item:hover .waeg-category-icon {
  background: #e0e0e0;
  transform: scale(1.1);
}

.waeg-subcategory-item.active .waeg-category-icon {
  background: #666;
}

/* Imágenes en subcategorías */
.waeg-subcategory-item .waeg-category-icon img.waeg-category-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 0;
  padding: 1%;
  box-sizing: border-box;
}

/* Texto del nombre en subcategorías */
.waeg-subcategory-item {
  line-height: 1.3;
  word-wrap: break-word;
  overflow-wrap: break-word; /* Rompe palabras largas si es necesario */
  hyphens: auto; /* Agrega guiones automáticos */
}

.waeg-subcategory-item .waeg-category-name {
  display: block;
  width: 100%;
  line-height: 1.2;
  word-break: break-word; /* Rompe palabras muy largas */
}

/* Contador en subcategorías */
.waeg-subcategory-item .waeg-category-count {
  display: block;
  font-size: 11px;
  opacity: 0.6;
  margin-top: 2px;
}

/* Iconos de categorías y subcategorías */
.waeg-category-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-right: 8px;
  font-size: 16px;
  vertical-align: middle;
  min-width: 20px;
}

/* Imágenes en iconos de categorías */
.waeg-category-icon img.waeg-category-image {
  width: 24px;
  height: 24px;
  object-fit: cover;
  border-radius: 50%;
  vertical-align: middle;
}

/* Si el icono es Dashicon */
.waeg-category-icon .dashicons,
.waeg-category-icon .dashicons-before {
  font-size: 18px;
  width: 18px;
  height: 18px;
  line-height: 1;
}

/* Si el icono es Font Awesome */
.waeg-category-icon .fa,
.waeg-category-icon .fas,
.waeg-category-icon .far,
.waeg-category-icon .fab {
  font-size: 16px;
  width: 16px;
}

/* Si el icono es SVG */
.waeg-category-icon svg {
  width: 18px;
  height: 18px;
  vertical-align: middle;
}

/* ======================================
   TABS DE SUB-SUBCATEGORÍAS (n2)
   ====================================== */

/* Sección de tabs */
.waeg-tabs-section {
  margin-top: 20px;
}

#waeg-subsubcategories-section {
  opacity: 0;
  max-height: 0;
  overflow: hidden;
  transition: opacity 0.3s ease, max-height 0.3s ease;
}

#waeg-subsubcategories-section.show {
  opacity: 1;
  max-height: 1000px;
}

/* Contenedor de tabs */
.waeg-tabs-container {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 12px;
}

/* Tab individual - diseño circular */
.waeg-tab-item {
  background: white;
  border: 2px solid #ddd;
  border-radius: 12px;
  padding: 16px 12px;
  font-size: 12px;
  font-weight: 600;
  color: #555;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 8px;
  white-space: normal;
  min-width: 70px;
  max-width: 90px;
  line-height: 1.3;
}

.waeg-tab-item:hover {
  background: #f0f0f0;
  border-color: #333;
  color: #333;
  transform: translateY(-2px);
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.waeg-tab-item.active {
  background: #333;
  color: white;
  border-color: #333;
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

.waeg-tab-item .waeg-tab-count {
  background: rgba(0,0,0,0.1);
  padding: 2px 6px;
  border-radius: 8px;
  font-size: 10px;
  font-weight: 700;
  display: block;
  margin-top: 2px;
}

.waeg-tab-item.active .waeg-tab-count {
  background: rgba(255,255,255,0.2);
}

/* Iconos en tabs - layout circular */
.waeg-tab-item .waeg-category-icon {
  margin-right: 0;
  margin-bottom: 4px;
  font-size: 28px;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f5f5f5;
  border-radius: 50%;
  transition: all 0.3s ease;
}

.waeg-tab-item:hover .waeg-category-icon {
  background: #e8e8e8;
  transform: scale(1.1);
}

.waeg-tab-item.active .waeg-category-icon {
  background: #555;
}

/* Imágenes en tabs */
.waeg-tab-item .waeg-category-icon img.waeg-category-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 0;
  padding: 1%;
  box-sizing: border-box;
}

/* ======================================
   DISEÑO UNIFICADO - PILLS HORIZONTALES
   ====================================== */

/* Todas las vistas usan pills horizontales con scroll */
.waeg-categories-list,
.waeg-subcategories-list {
  display: flex !important;
  overflow-x: auto;
  overflow-y: hidden;
  gap: 12px;
  padding: 8px 0;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
  scrollbar-color: #888 #f1f1f1;
  flex-wrap: nowrap !important;
  list-style: none;
  margin: 0;
}

.waeg-categories-list::-webkit-scrollbar,
.waeg-subcategories-list::-webkit-scrollbar {
  height: 6px;
}

.waeg-categories-list::-webkit-scrollbar-track,
.waeg-subcategories-list::-webkit-scrollbar-track {
  background: #f1f1f1;
  border-radius: 10px;
}

.waeg-categories-list::-webkit-scrollbar-thumb,
.waeg-subcategories-list::-webkit-scrollbar-thumb {
  background: #888;
  border-radius: 10px;
}

.waeg-categories-list li,
.waeg-subcategories-list li {
  margin-bottom: 0;
  flex-shrink: 0;
}

/* Botones de categorías - estilo pills */
.waeg-category-item {
  white-space: nowrap;
  background: white !important;
  border: 2px solid #ddd !important;
  border-radius: 20px !important;
  padding: 10px 20px !important;
  font-size: 14px !important;
  font-weight: 600 !important;
  color: #555 !important;
  min-width: auto !important;
  width: auto !important;
  display: inline-flex !important;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
  overflow: visible;
}

/* Primeras dos categorías con borde rojo animado */
.waeg-category-item:nth-child(1),
.waeg-category-item:nth-child(2) {
  border: 3px solid #ff0000 !important;
  animation: pulseRedBorder 2s ease-in-out infinite;
  box-shadow: 0 0 15px rgba(255, 0, 0, 0.3);
}

.waeg-category-item:nth-child(1)::before,
.waeg-category-item:nth-child(2)::before {
  content: '⭐';
  position: absolute;
  top: -8px;
  right: -8px;
  font-size: 18px;
  animation: rotateStar 3s linear infinite;
  filter: drop-shadow(0 2px 4px rgba(255, 0, 0, 0.4));
  display: none; /* Estrella oculta */
}

@keyframes pulseRedBorder {
  0%, 100% {
    border-color: #ff0000;
    box-shadow: 0 0 15px rgba(255, 0, 0, 0.3), 0 0 30px rgba(255, 0, 0, 0.1);
  }
  50% {
    border-color: #cc0000;
    box-shadow: 0 0 25px rgba(255, 0, 0, 0.5), 0 0 50px rgba(255, 0, 0, 0.2);
  }
}

@keyframes rotateStar {
  0% {
    transform: rotate(0deg) scale(1);
  }
  50% {
    transform: rotate(180deg) scale(1.2);
  }
  100% {
    transform: rotate(360deg) scale(1);
  }
}

.waeg-category-item:hover {
  background: #f0f0f0 !important;
  border-color: #333 !important;
  color: #333 !important;
  transform: translateY(-2px);
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

/* Las primeras dos mantienen el rojo incluso en hover */
.waeg-category-item:nth-child(1):hover,
.waeg-category-item:nth-child(2):hover {
  border-color: #cc0000 !important;
  box-shadow: 0 4px 12px rgba(255, 0, 0, 0.4);
}

.waeg-category-item.active {
  background: #333 !important;
  color: white !important;
  border-color: #333 !important;
}

/* Cuando las primeras dos están activas */
.waeg-category-item:nth-child(1).active,
.waeg-category-item:nth-child(2).active {
  background: #cc0000 !important;
  border-color: #ff0000 !important;
  animation: none;
}

/* Botones de subcategorías - estilo pills */
.waeg-subcategory-item {
  white-space: nowrap;
  background: white !important;
  border: 2px solid #ddd !important;
  border-radius: 8px !important;
  padding: 10px 20px !important;
  font-size: 13px !important;
  font-weight: 600 !important;
  color: #555 !important;
  min-width: auto !important;
  width: auto !important;
  display: inline-flex !important;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.waeg-subcategory-item:hover {
  background: #f0f0f0 !important;
  border-color: #333 !important;
  color: #333 !important;
  transform: translateY(-2px);
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.waeg-subcategory-item.active {
  background: #333 !important;
  color: white !important;
  border-color: #333 !important;
}

/* Contador de productos */
.waeg-category-count,
.waeg-subcategory-count {
  background: rgba(0,0,0,0.1);
  padding: 2px 8px;
  border-radius: 10px;
  font-size: 11px;
  font-weight: 700;
}

.waeg-category-item.active .waeg-category-count,
.waeg-subcategory-item.active .waeg-subcategory-count {
  background: rgba(255,255,255,0.2);
}

/* ======================================
   RESPONSIVE - AJUSTES POR DISPOSITIVO
   ====================================== */

/* ======================================
   BUSCADOR GLOBAL INDEPENDIENTE
   ====================================== */

.waeg-global-search-wrapper {
  position: relative;
  max-width: 100%;
}

.waeg-global-search-form {
  width: 100%;
}

.waeg-search-input-wrapper {
  position: relative;
  display: flex;
  align-items: stretch;
  gap: 8px;
  width: 100%;
}

.waeg-global-search-input {
  flex: 1;
  padding: 12px 20px 12px 48px;
  font-size: 16px;
  border: 2px solid #ddd;
  border-radius: 50px;
  outline: none;
  transition: all 0.3s ease;
  background: white;
  width: 100%;
  min-width: 0;
}

.waeg-global-search-input:focus {
  border-color: #333;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.waeg-global-search-button {
  padding: 12px 28px;
  background: #333;
  color: white;
  border: none;
  border-radius: 50px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  white-space: nowrap;
}

.waeg-global-search-button:hover {
  background: #555;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

.waeg-global-search-button:active {
  transform: translateY(0);
}

/* Resultados de búsqueda en vivo */
.waeg-search-live-results {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  margin-top: 8px;
  background: white;
  border: 1px solid #ddd;
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.15);
  max-height: 400px;
  overflow-y: auto;
  z-index: 1000;
}

/* Lista de sugerencias */
.waeg-suggestions-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.waeg-suggestion-item {
  display: flex;
  align-items: center;
  padding: 12px 16px;
  cursor: pointer;
  transition: background 0.2s ease;
  border-bottom: 1px solid #f0f0f0;
  position: relative;
}

.waeg-suggestion-item:last-child {
  border-bottom: none;
}

.waeg-suggestion-item:hover,
.waeg-suggestion-item.active {
  background: #f9f9f9;
}

.waeg-suggestion-image {
  width: 50px;
  height: 50px;
  object-fit: cover;
  border-radius: 6px;
  margin-right: 12px;
  flex-shrink: 0;
  border: 1px solid #e0e0e0;
}

.waeg-suggestion-image.waeg-no-image {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f5f5f5;
  font-size: 24px;
}

.waeg-suggestion-content {
  flex: 1;
  min-width: 0;
}

.waeg-suggestion-title {
  font-size: 14px;
  font-weight: 600;
  color: #333;
  margin-bottom: 4px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.waeg-suggestion-price {
  font-size: 13px;
  color: #666;
}

.waeg-suggestion-price .amount {
  font-weight: 700;
  color: #333;
}

.waeg-suggestion-badge {
  position: absolute;
  top: 12px;
  right: 16px;
  background: #e74c3c;
  color: white;
  font-size: 11px;
  font-weight: 700;
  padding: 4px 8px;
  border-radius: 4px;
  text-transform: uppercase;
}

.waeg-suggestion-item.on-sale .waeg-suggestion-price {
  color: #e74c3c;
}

/* Loading y mensajes */
.waeg-suggestions-loading,
.waeg-no-suggestions {
  padding: 16px;
  text-align: center;
  color: #666;
  font-size: 14px;
}

.waeg-suggestions-loading {
  animation: waeg-pulse 1.5s ease-in-out infinite;
}

@keyframes waeg-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

/* Botón Ver todos los resultados */
.waeg-view-all-results {
  padding: 12px 16px;
  border-top: 1px solid #f0f0f0;
}

.waeg-view-all-btn {
  width: 100%;
  padding: 12px 20px;
  background: #333;
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  text-align: center;
  /* Mejorar interacción táctil en móvil */
  -webkit-tap-highlight-color: rgba(0,0,0,0.2);
  touch-action: manipulation;
  user-select: none;
  -webkit-user-select: none;
}

.waeg-view-all-btn:hover {
  background: #555;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

.waeg-view-all-btn:active {
  transform: translateY(0);
  background: #222;
}

/* Sugerencia de corrección ortográfica */
.waeg-spelling-suggestion {
  padding: 12px 16px;
  background: #fff8e5;
  border-bottom: 1px solid #f0b849;
  display: flex;
  align-items: center;
  gap: 6px;
}

.waeg-spelling-text {
  color: #666;
  font-size: 13px;
}

.waeg-spelling-link {
  background: none;
  border: none;
  color: #2271b1;
  cursor: pointer;
  font-size: 13px;
  padding: 0;
  text-decoration: none;
  transition: color 0.2s ease;
}

.waeg-spelling-link:hover {
  color: #135e96;
  text-decoration: underline;
}

/* ============================================
   SECCIONES DE SUGERENCIAS (CATEGORÍAS + PRODUCTOS)
   ============================================ */

.waeg-suggestions-section {
  margin: 0;
  padding: 0;
}

.waeg-suggestions-section:not(:last-of-type) {
  border-bottom: 2px solid #e0e0e0;
}

.waeg-suggestions-section-title {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #555;
  border-bottom: 1px solid #e0e0e0;
}

.waeg-suggestions-section-title svg {
  color: #8B0000;
  flex-shrink: 0;
}

/* Estilos específicos para categorías */
.waeg-categories-section .waeg-category-item {
  background: #fafafa;
}

.waeg-categories-section .waeg-category-item:hover,
.waeg-categories-section .waeg-category-item.active {
  background: #f0f4f8;
}

.waeg-category-icon {
  background: linear-gradient(135deg, #e8f0fe 0%, #d2e3fc 100%) !important;
  color: #1a73e8 !important;
}

.waeg-category-name {
  color: #1a73e8 !important;
}

.waeg-category-parent {
  font-size: 11px;
  color: #888;
  margin-bottom: 2px;
  font-style: italic;
}

.waeg-category-count {
  font-size: 12px;
  color: #666;
  font-weight: 500;
}

.waeg-category-badge {
  position: absolute;
  top: 12px;
  right: 16px;
  background: linear-gradient(135deg, #1a73e8 0%, #1557b0 100%);
  color: white;
  font-size: 10px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 12px;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.waeg-category-image {
  border-radius: 8px;
  border: 2px solid #d2e3fc !important;
}

/* Estilos específicos para productos */
.waeg-product-category {
  font-size: 11px;
  color: #888;
  margin-bottom: 2px;
  font-style: italic;
}

.waeg-products-section .waeg-product-item {
  background: #fff;
}

.waeg-products-section .waeg-product-item:hover,
.waeg-products-section .waeg-product-item.active {
  background: #fffaf0;
}

/* Animación de entrada para secciones */
.waeg-suggestions-section {
  animation: waeg-fade-in 0.2s ease-out;
}

@keyframes waeg-fade-in {
  from {
    opacity: 0;
    transform: translateY(-5px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Responsive para sugerencias con secciones */
/* ⇒ MOBILE [3]: @media (max-width: 480px) { — ver shop-mobile.css */

.waeg-spelling-link strong {
  font-weight: 600;
}

/* Estilo Minimal */
.waeg-style-minimal .waeg-global-search-input {
  border: none;
  border-bottom: 2px solid #ddd;
  border-radius: 0;
  padding: 12px;
  background: transparent;
}

.waeg-style-minimal .waeg-global-search-input:focus {
  border-bottom-color: #333;
  box-shadow: none;
}

.waeg-style-minimal .waeg-global-search-button {
  border-radius: 4px;
  padding: 12px 24px;
}

/* Estilo Modern */
.waeg-style-modern .waeg-global-search-input {
  border-radius: 12px;
  border: 1px solid #e0e0e0;
  padding: 14px 20px;
  background: #f9f9f9;
  font-size: 15px;
}

.waeg-style-modern .waeg-global-search-input:focus {
  background: white;
  border-color: #333;
}

.waeg-style-modern .waeg-global-search-button {
  border-radius: 12px;
  background: linear-gradient(135deg, #333 0%, #555 100%);
  padding: 14px 32px;
}

.waeg-style-modern .waeg-global-search-button:hover {
  background: linear-gradient(135deg, #555 0%, #777 100%);
}

/* Responsive para buscador global */
/* ⇒ MOBILE [4]: @media (max-width: 768px) { — ver shop-mobile.css */

/* ⇒ MOBILE [5]: @media (max-width: 720px) { — ver shop-mobile.css */

/* Ocultar calificaciones por estrellas en el grid */
.waeg-grid .star-rating,
.waeg-grid .woocommerce-product-rating {
  display: none !important;
}

/* Grid responsivo con cards de 357x492 */
#waeg-grid.waeg-grid,
#waeg-grid.waeg-grid .products,
#waeg-grid.waeg-grid ul.products {
  display: grid !important;
  grid-template-columns: repeat(3, 321px) !important;
  gap: 8px !important;
  align-items: stretch !important;
  justify-content: center !important;
  position: relative;
  z-index: 3;
  min-height: 200px;
  transition: opacity 0.3s ease;
  list-style: none !important;
  padding: 0 !important;
  margin: 0 !important;
}

/* Eliminar pseudo-elementos de clearfix del tema (legado float) que
   se convierten en celdas fantasma en CSS Grid y desplazan las cards */
#waeg-grid.waeg-grid::before,
#waeg-grid.waeg-grid::after {
  display: none !important;
  content: none !important;
}

/* Indicador de carga para el grid - MEJORADO */
.waeg-grid {
  position: relative;
  transition: opacity 0.3s ease;
}

.waeg-grid.loading {
  opacity: 0.6;
  pointer-events: none;
}

.waeg-grid.loading::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(2px);
  z-index: 999;
  animation: waeg-fadeIn 0.2s ease;
}

.waeg-grid.loading::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 60px;
  height: 60px;
  border: 5px solid #f3f3f3;
  border-top: 5px solid #2c3e50;
  border-radius: 50%;
  animation: waeg-spin 0.8s linear infinite;
  z-index: 1000;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

@keyframes waeg-spin {
  0% { transform: translate(-50%, -50%) rotate(0deg); }
  100% { transform: translate(-50%, -50%) rotate(360deg); }
}

@keyframes waeg-fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* Animación de entrada para productos */
.waeg-grid .product {
  animation: productFadeIn 0.4s ease-out;
  transform-origin: center;
}

@keyframes productFadeIn {
  from {
    opacity: 0;
    transform: scale(0.95) translateY(10px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

/* Efecto hover mejorado para productos */
.waeg-grid .product {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.waeg-grid .product:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
}

/* Lazy loading para imágenes */
.waeg-grid img[data-src] {
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

/* Spinner de scroll infinito (al final del grid) */
.waeg-infinite-loader {
  display: none;
  width: 100%;
  padding: 40px 0;
  text-align: center;
  position: relative;
}

.waeg-infinite-loader.active {
  display: block;
}

.waeg-infinite-loader::before {
  content: '';
  display: inline-block;
  width: 40px;
  height: 40px;
  border: 4px solid #f3f3f3;
  border-top: 4px solid #333;
  border-radius: 50%;
  animation: waeg-spin-infinite 1s linear infinite;
}

@keyframes waeg-spin-infinite {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* ======================================
   RESOLUCIÓN 1280x800 - 3 COLUMNAS COMPRIMIDAS
   ====================================== */
@media (max-width: 1280px) and (min-width: 1200px) {
  /* Grid con 3 columnas más compactas */
  .waeg-grid {
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 16px !important;
    justify-content: center !important;
  }
  
  /* Ajustar tamaño de productos */
  .waeg-grid .product,
  .waeg-grid li.product,
  .waeg-grid .type-product {
    width: 100% !important;
    max-width: 320px !important;
    min-width: auto !important;
  }
  
  /* OCULTAR BUSCADOR COMPLETAMENTE */
  .waeg-search-wrapper,
  #waeg-search,
  .waeg-search-input-wrapper,
  .waeg-controls-section {
    display: none !important;
  }
  
  /* Ocultar sugerencias de búsqueda también */
  #waeg-search-suggestions,
  .waeg-search-live-results {
    display: none !important;
  }
  
  /* MOVER ORDENAR POR DENTRO DE LOS FILTROS */
  .waeg-sort-section {
    display: none !important; /* Ocultar del sidebar de categorías */
  }
  
  /* Reducir el sidebar de filtros para dar más espacio al grid */
  .waeg-filters-sidebar {
    width: 230px !important;
    max-width: 230px !important;
    flex: 0 0 230px !important;
    padding: 24px 16px !important;
  }
  
  .waeg-columns-4 .waeg-grid {
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 16px !important;
  }
  
  .waeg-columns-4 .waeg-grid .product,
  .waeg-columns-4 .waeg-grid li.product,
  .waeg-columns-4 .waeg-grid .type-product {
    width: 100% !important;
    max-width: 320px !important;
    min-width: auto !important;
    height: auto !important;
    min-height: 420px !important;
    max-height: none !important;
  }

  /* 5 columnas en esta resolución — forzar 3 columnas */
  .waeg-columns-5 .waeg-grid {
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 16px !important;
  }

  .waeg-columns-5 .waeg-grid .product,
  .waeg-columns-5 .waeg-grid li.product,
  .waeg-columns-5 .waeg-grid .type-product {
    width: 100% !important;
    max-width: 300px !important;
    min-width: auto !important;
    height: auto !important;
    min-height: 360px !important;
    max-height: none !important;
  }
}

/* Desktop grande - 3 columnas (por defecto) */
@media (min-width: 1200px) {
  .waeg-grid {
    grid-template-columns: repeat(3, 321px);
    justify-content: space-between;
  }
  
  /* Opción de 4 columnas cuando se usa columns="4" en el shortcode */
  .waeg-columns-4 .waeg-grid {
    grid-template-columns: repeat(4, 267px) !important;
    gap: 20px !important;
    justify-content: start !important;
    margin: 0;
    width: 100% !important;
  }
  
  /* Ajustar tamaño de productos en 4 columnas */
  .waeg-columns-4 .waeg-grid .product,
  .waeg-columns-4 .waeg-grid li.product,
  .waeg-columns-4 .waeg-grid .type-product {
    display: flex !important;
    flex-direction: column !important;
    width: 267px !important;
    max-width: 267px !important;
    min-width: 267px !important;
    height: 390px !important;
    min-height: 390px !important;
    max-height: 390px !important;
    box-sizing: border-box !important;
    flex-shrink: 0 !important;
    flex-grow: 0 !important;
    background: #fff !important;
    border: 1px solid #e0e0e0 !important;
    border-radius: 8px !important;
    overflow: hidden !important;
    box-shadow: none !important;
    transition: all 0.3s ease !important;
    position: relative !important;
    margin: 0 !important;
    padding: 0 !important;
  }
  
  /* Ajustar imagen proporcional */
  .waeg-columns-4 .waeg-grid .product a img,
  .waeg-columns-4 .waeg-grid .product img,
  .waeg-columns-4 .waeg-grid .product .attachment-woocommerce_thumbnail {
    height: 231px !important;
    max-height: 231px !important;
    padding: 7px !important;
  }
  
  /* Ajustar contenido interno de las cards */
  .waeg-columns-4 .waeg-grid .product h2,
  .waeg-columns-4 .waeg-grid .product .woocommerce-loop-product__title {
    font-size: 14px !important;
    line-height: 1.2 !important;
  }
  
  .waeg-columns-4 .waeg-grid .product .price {
    font-size: 18px !important;
    font-weight: 700 !important;
    margin: 8px 0 !important;
    padding: 8px 4px !important;
    min-height: 36px !important;
    line-height: 1.3 !important;
    text-align: center !important;
  }
  
  .waeg-columns-4 .waeg-grid .product .button,
  .waeg-columns-4 .waeg-grid .product .add_to_cart_button {
    font-size: 13px !important;
    padding: 9px 13px !important;
    position: relative !important;
    padding-left: 30px !important;
  }
  
  /* Icono de carrito en desktop para 4 columnas */
  .waeg-columns-4 .waeg-grid .product .button::before,
  .waeg-columns-4 .waeg-grid .product .add_to_cart_button::before,
  .waeg-columns-4 .waeg-grid .product a.button::before {
    content: "🛒" !important;
    position: absolute !important;
    left: 8px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    font-size: 16px !important;
    line-height: 1 !important;
  }

  /* Opción de 5 columnas — 15% más pequeño que 4 col: 227×332px */
  .waeg-columns-5 .waeg-grid {
    grid-template-columns: repeat(5, 227px) !important;
    gap: 16px !important;
    justify-content: start !important;
    margin: 0;
    width: 100% !important;
  }

  .waeg-columns-5 .waeg-grid .product,
  .waeg-columns-5 .waeg-grid li.product,
  .waeg-columns-5 .waeg-grid .type-product {
    display: flex !important;
    flex-direction: column !important;
    width: 227px !important;
    max-width: 227px !important;
    min-width: 227px !important;
    height: 332px !important;
    min-height: 332px !important;
    max-height: 332px !important;
    box-sizing: border-box !important;
    flex-shrink: 0 !important;
    flex-grow: 0 !important;
    background: #fff !important;
    border: 1px solid #e0e0e0 !important;
    border-radius: 8px !important;
    overflow: hidden !important;
    box-shadow: none !important;
    transition: all 0.3s ease !important;
    position: relative !important;
    margin: 0 !important;
    padding: 0 !important;
  }

  .waeg-columns-5 .waeg-grid .product a img,
  .waeg-columns-5 .waeg-grid .product img,
  .waeg-columns-5 .waeg-grid .product .attachment-woocommerce_thumbnail {
    height: 196px !important;
    max-height: 196px !important;
    padding: 6px !important;
  }

  .waeg-columns-5 .waeg-grid .product h2,
  .waeg-columns-5 .waeg-grid .product .woocommerce-loop-product__title {
    font-size: 12px !important;
    line-height: 1.2 !important;
  }

  .waeg-columns-5 .waeg-grid .product .price {
    font-size: 15px !important;
    font-weight: 700 !important;
    margin: 4px 0 !important;
    padding: 4px 4px !important;
    text-align: center !important;
  }

  .waeg-columns-5 .waeg-grid .product .button,
  .waeg-columns-5 .waeg-grid .product .add_to_cart_button {
    font-size: 11px !important;
    padding: 7px 10px !important;
    position: relative !important;
    padding-left: 26px !important;
  }

  .waeg-columns-5 .waeg-grid .product .button::before,
  .waeg-columns-5 .waeg-grid .product .add_to_cart_button::before,
  .waeg-columns-5 .waeg-grid .product a.button::before {
    content: "🛒" !important;
    position: absolute !important;
    left: 6px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    font-size: 13px !important;
    line-height: 1 !important;
  }
}

/* Tablet - 2 columnas (igual que móvil) */
@media (max-width: 1199px) and (min-width: 481px) {
  .waeg-grid {
    grid-template-columns: repeat(2, 321px);
    justify-content: space-around;
    gap: 20px;
  }
  
  .waeg-grid .product,
  .waeg-grid li.product {
    width: 321px !important;
    max-width: 321px !important;
  }
  /* Sobrescribir para 4 columnas en tablet también */
  .waeg-columns-4 .waeg-grid {
    grid-template-columns: repeat(2, 267px) !important;
    gap: 20px !important;
  }
  
  .waeg-columns-4 .waeg-grid .product,
  .waeg-columns-4 .waeg-grid li.product,
  .waeg-columns-4 .waeg-grid .type-product {
    width: 267px !important;
    max-width: 267px !important;
    min-width: 267px !important;
    height: 390px !important;
    min-height: 390px !important;
    max-height: 390px !important;
  }
  
  /* Icono de carrito en tablet para 4 columnas */
  .waeg-columns-4 .waeg-grid .product .button,
  .waeg-columns-4 .waeg-grid .product .add_to_cart_button {
    position: relative !important;
    padding-left: 30px !important;
  }
  
  .waeg-columns-4 .waeg-grid .product .button::before,
  .waeg-columns-4 .waeg-grid .product .add_to_cart_button::before,
  .waeg-columns-4 .waeg-grid .product a.button::before {
    content: "🛒" !important;
    position: absolute !important;
    left: 8px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    font-size: 16px !important;
    line-height: 1 !important;
  }

  /* 5 columnas en tablet — 2 columnas */
  .waeg-columns-5 .waeg-grid {
    grid-template-columns: repeat(2, 227px) !important;
    gap: 16px !important;
  }

  .waeg-columns-5 .waeg-grid .product,
  .waeg-columns-5 .waeg-grid li.product,
  .waeg-columns-5 .waeg-grid .type-product {
    width: 227px !important;
    max-width: 227px !important;
    min-width: 227px !important;
    height: 332px !important;
    min-height: 332px !important;
    max-height: 332px !important;
  }

  .waeg-columns-5 .waeg-grid .product .button,
  .waeg-columns-5 .waeg-grid .product .add_to_cart_button {
    position: relative !important;
    padding-left: 26px !important;
  }

  .waeg-columns-5 .waeg-grid .product .button::before,
  .waeg-columns-5 .waeg-grid .product .add_to_cart_button::before,
  .waeg-columns-5 .waeg-grid .product a.button::before {
    content: "🛒" !important;
    position: absolute !important;
    left: 6px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    font-size: 13px !important;
    line-height: 1 !important;
  }
}

/* Mobile - 2 columnas */
/* ⇒ MOBILE [6]: @media (max-width: 720px) { — ver shop-mobile.css */

/* ======================================
   ESTILOS DESKTOP - OCULTAR SOLO WHATSAPP (min-width: 721px)
   ====================================== */

@media (min-width: 721px) {
  /* Botón de WhatsApp - verde WhatsApp, mismo diseño que Agregar */
  .waeg-grid .product .waeg-mobile-button-row .waeg-btn-whatsapp {
    display: flex !important;
    flex: 1 !important;
    background: #25D366 !important;
    color: white !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    justify-content: center !important;
    align-items: center !important;
    gap: 8px !important;
    min-width: 0 !important;
    -webkit-font-smoothing: antialiased !important;
    -moz-osx-font-smoothing: grayscale !important;
  }

  .waeg-grid .product .waeg-mobile-button-row .waeg-btn-whatsapp .waeg-btn-text {
    font-size: 14px !important;
    font-weight: 600 !important;
  }
  
  /* Contenedor con ambos botones en fila */
  .waeg-grid .product .waeg-mobile-button-row {
    display: flex !important;
    flex-direction: row !important;
    gap: 6px !important;
  }
  
  /* Botón de carrito — mismas dimensiones exactas que el botón de WhatsApp */
  .waeg-grid .product .waeg-mobile-button-row .waeg-btn-cart {
    display: flex !important;
    flex: 1 !important;
    min-width: 0 !important;
    width: auto !important;
    max-width: none !important;
    height: auto !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    justify-content: center !important;
    align-items: center !important;
    gap: 8px !important;
    -webkit-font-smoothing: antialiased !important;
    -moz-osx-font-smoothing: grayscale !important;
  }
  
  .waeg-grid .product .waeg-mobile-button-row .waeg-btn-cart .waeg-btn-text {
    font-size: 14px !important;
    font-weight: 600 !important;
  }

  /* Contenedor del botón de carrito — mismo ancho que botón WhatsApp directo */
  .waeg-grid .product .waeg-mobile-button-row .waeg-add-to-cart-container {
    display: flex !important;
    flex: 1 !important;
    min-width: 0 !important;
    align-items: stretch !important;
  }
}

/* ======================================
   PRODUCTOS DE WOOCOMMERCE - DISEÑO UNIFICADO
   ====================================== */

/* Resetear estilos de WooCommerce que puedan interferir */
.waeg-grid ul.products,
.waeg-grid .products {
  list-style: none !important;
  padding: 0 !important;
  margin: 0 !important;
}

.waeg-grid ul.products li,
.waeg-grid .products .product {
  margin: 0 !important;
  padding: 0 !important;
  list-style: none !important;
}

/* Estructura de la card - TAMAÑO EXACTO 357x492 (ESTILO CAROUSEL) */
#waeg-grid.waeg-grid .product,
#waeg-grid.waeg-grid li.product,
#waeg-grid.waeg-grid .type-product {
  display: flex !important;
  flex-direction: column !important;
  width: 321px !important;
  max-width: 321px !important;
  min-width: 321px !important;
  height: 492px !important;
  min-height: 492px !important;
  max-height: 492px !important;
  background: #fff !important;
  border: 1px solid #e0e0e0 !important;
  border-radius: 8px !important;
  overflow: hidden !important;
  box-shadow: none !important;
  transition: all 0.3s ease !important;
  position: relative !important;
  z-index: 4;
  margin: 0 !important;
  padding: 0 !important;
  box-sizing: border-box !important;
}

/* ======================================================
   OVERRIDES DE COLUMNAS — solo en desktop (>= 1025px)
   Estos selectores con ID ganan especificidad sobre la
   regla base #waeg-grid.waeg-grid .product de arriba.
   ====================================================== */
@media (min-width: 1025px) {
  /* Ocultar botón "Ver" WC para 4/5-col — el waeg-mobile-button-row lo reemplaza */
  .waeg-columns-4 #waeg-grid.waeg-grid .product .button,
  .waeg-columns-4 #waeg-grid.waeg-grid .product .add_to_cart_button,
  .waeg-columns-4 #waeg-grid.waeg-grid .product .ver-producto-btn,
  .waeg-columns-5 #waeg-grid.waeg-grid .product .button,
  .waeg-columns-5 #waeg-grid.waeg-grid .product .add_to_cart_button,
  .waeg-columns-5 #waeg-grid.waeg-grid .product .ver-producto-btn {
    display: none !important;
  }
  /* 5 columnas — grid container */
  .waeg-columns-5 #waeg-grid.waeg-grid,
  .waeg-columns-5 #waeg-grid.waeg-grid .products,
  .waeg-columns-5 #waeg-grid.waeg-grid ul.products {
    grid-template-columns: repeat(5, 227px) !important;
    gap: 16px !important;
    justify-content: start !important;
  }

  /* 5 columnas — cards: 227×332px (flex igual que la base) */
  .waeg-columns-5 #waeg-grid.waeg-grid .product,
  .waeg-columns-5 #waeg-grid.waeg-grid li.product,
  .waeg-columns-5 #waeg-grid.waeg-grid .type-product {
    display: flex !important;
    flex-direction: column !important;
    width: 227px !important;
    max-width: 227px !important;
    min-width: 227px !important;
    height: 332px !important;
    min-height: 332px !important;
    max-height: 332px !important;
  }

  /* 5 columnas — imagen proporcional (47% de 332px) */
  .waeg-columns-5 #waeg-grid.waeg-grid .product a img,
  .waeg-columns-5 #waeg-grid.waeg-grid .product img,
  .waeg-columns-5 #waeg-grid.waeg-grid .product .attachment-woocommerce_thumbnail {
    height: 155px !important;
    max-height: 155px !important;
    min-height: 155px !important;
  }

  /* 5 columnas — título más compacto */
  .waeg-columns-5 #waeg-grid.waeg-grid .product .woocommerce-loop-product__title,
  .waeg-columns-5 #waeg-grid.waeg-grid .product h2 {
    font-size: 11px !important;
    height: 30px !important;
    max-height: 30px !important;
    min-height: 30px !important;
    margin: 4px 10px 6px 10px !important;
    -webkit-line-clamp: 2 !important;
  }

  /* 5 columnas — precio más compacto */
  .waeg-columns-5 #waeg-grid.waeg-grid .product .price,
  .waeg-columns-5 #waeg-grid.waeg-grid .product span.price {
    font-size: 14px !important;
    margin: 0 10px 4px 10px !important;
    min-height: 20px !important;
  }

  /* 4 columnas — grid container */
  .waeg-columns-4 #waeg-grid.waeg-grid,
  .waeg-columns-4 #waeg-grid.waeg-grid .products,
  .waeg-columns-4 #waeg-grid.waeg-grid ul.products {
    grid-template-columns: repeat(4, 267px) !important;
    gap: 20px !important;
    justify-content: start !important;
  }

  /* 4 columnas — cards: 267×390px (flex igual que la base) */
  .waeg-columns-4 #waeg-grid.waeg-grid .product,
  .waeg-columns-4 #waeg-grid.waeg-grid li.product,
  .waeg-columns-4 #waeg-grid.waeg-grid .type-product {
    display: flex !important;
    flex-direction: column !important;
    width: 267px !important;
    max-width: 267px !important;
    min-width: 267px !important;
    height: 390px !important;
    min-height: 390px !important;
    max-height: 390px !important;
  }

  /* 4 columnas — imagen proporcional (47% de 390px) */
  .waeg-columns-4 #waeg-grid.waeg-grid .product a img,
  .waeg-columns-4 #waeg-grid.waeg-grid .product img,
  .waeg-columns-4 #waeg-grid.waeg-grid .product .attachment-woocommerce_thumbnail {
    height: 183px !important;
    max-height: 183px !important;
    min-height: 183px !important;
  }

  /* 4 columnas — título más compacto */
  .waeg-columns-4 #waeg-grid.waeg-grid .product .woocommerce-loop-product__title,
  .waeg-columns-4 #waeg-grid.waeg-grid .product h2 {
    font-size: 12px !important;
    height: 34px !important;
    max-height: 34px !important;
    min-height: 34px !important;
    margin: 4px 12px 8px 12px !important;
  }

  /* 4 columnas — precio */
  .waeg-columns-4 #waeg-grid.waeg-grid .product .price,
  .waeg-columns-4 #waeg-grid.waeg-grid .product span.price {
    font-size: 15px !important;
    margin: 0 12px 6px 12px !important;
  }

  /* 5 columnas — botones en desktop (mostrar mobile-button-row) */
  .waeg-columns-5 #waeg-grid.waeg-grid .product .waeg-mobile-button-row {
    display: flex !important;
    flex-direction: row !important;
    padding: 0 6px 8px !important;
    gap: 5px !important;
    height: 38px !important;
    flex-shrink: 0 !important;
  }

  .waeg-columns-5 #waeg-grid.waeg-grid .product .waeg-mobile-button-row .waeg-btn-whatsapp,
  .waeg-columns-5 #waeg-grid.waeg-grid .product .waeg-mobile-button-row .waeg-btn-cart {
    font-size: 10px !important;
    padding: 6px 3px !important;
    border-radius: 7px !important;
    height: 30px !important;
    flex: 1 !important;
  }

  /* 4 columnas — botones en desktop (mostrar mobile-button-row) */
  .waeg-columns-4 #waeg-grid.waeg-grid .product .waeg-mobile-button-row {
    display: flex !important;
    flex-direction: row !important;
    padding: 0 8px 10px !important;
    gap: 6px !important;
    height: 44px !important;
    flex-shrink: 0 !important;
  }

  .waeg-columns-4 #waeg-grid.waeg-grid .product .waeg-mobile-button-row .waeg-btn-whatsapp,
  .waeg-columns-4 #waeg-grid.waeg-grid .product .waeg-mobile-button-row .waeg-btn-cart {
    font-size: 11px !important;
    padding: 8px 4px !important;
    border-radius: 8px !important;
    height: 34px !important;
    flex: 1 !important;
  }
}

/* 5 columnas en tablet: 2 columnas fluidas */
@media (min-width: 481px) and (max-width: 1024px) {
  .waeg-columns-5 #waeg-grid.waeg-grid,
  .waeg-columns-5 #waeg-grid.waeg-grid .products,
  .waeg-columns-5 #waeg-grid.waeg-grid ul.products {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 12px !important;
    justify-content: center !important;
  }

  .waeg-columns-5 #waeg-grid.waeg-grid .product,
  .waeg-columns-5 #waeg-grid.waeg-grid li.product,
  .waeg-columns-5 #waeg-grid.waeg-grid .type-product {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    height: auto !important;
    min-height: 340px !important;
    max-height: none !important;
  }
}

/* 5 columnas en mobile: 2 columnas fluidas */
@media (max-width: 480px) {
  .waeg-columns-5 #waeg-grid.waeg-grid,
  .waeg-columns-5 #waeg-grid.waeg-grid .products,
  .waeg-columns-5 #waeg-grid.waeg-grid ul.products {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 8px !important;
  }

  .waeg-columns-5 #waeg-grid.waeg-grid .product,
  .waeg-columns-5 #waeg-grid.waeg-grid li.product,
  .waeg-columns-5 #waeg-grid.waeg-grid .type-product {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    height: auto !important;
    min-height: 280px !important;
    max-height: none !important;
  }
}

/* Botón de carrito visible en desktop — flujo normal al final de la card */
@media (min-width: 721px) {
  #waeg-grid.waeg-grid .product .waeg-mobile-button-row {
    display: flex !important;
    flex-direction: row !important;
    position: static !important;
    flex-shrink: 0 !important;
    padding: 0 8px 10px !important;
    box-sizing: border-box !important;
    align-items: stretch !important;
    justify-content: center !important;
    gap: 6px !important;
    background: transparent !important;
    margin-top: auto !important;
  }

  #waeg-grid.waeg-grid .product .waeg-mobile-button-row .waeg-add-to-cart-container {
    display: flex !important;
    flex: 1 !important;
    min-width: 0 !important;
  }

  #waeg-grid.waeg-grid .product .waeg-mobile-button-row .waeg-btn-whatsapp {
    display: flex !important;
    flex: 1 !important;
    min-width: 0 !important;
    justify-content: center !important;
    align-items: center !important;
    gap: 8px !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    background: #25D366 !important;
    color: white !important;
    border-radius: 8px !important;
    text-decoration: none !important;
  }

  #waeg-grid.waeg-grid .product .waeg-mobile-button-row .waeg-btn-cart {
    display: flex !important;
    width: 100% !important;
    max-width: none !important;
    justify-content: center !important;
    align-items: center !important;
    gap: 8px !important;
    font-size: 14px !important;
    font-weight: 600 !important;
  }

  /* Ajustar la altura de la card para acomodar el botón */
  #waeg-grid.waeg-grid .product a.woocommerce-loop-product__link,
  #waeg-grid.waeg-grid .product a.woocommerce-LoopProduct-link {
    height: auto !important;
    flex: 1 1 0 !important;
  }
}

#waeg-grid.waeg-grid .product:hover,
#waeg-grid.waeg-grid li.product:hover {
  z-index: 5;
  border-color: #333 !important;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1) !important;
  transform: translateY(-4px) !important;
}

/* Contenedor del link principal - FLEX PARA DISTRIBUCIÓN */
#waeg-grid.waeg-grid .product a.woocommerce-loop-product__link,
#waeg-grid.waeg-grid .product a.woocommerce-LoopProduct-link,
#waeg-grid.waeg-grid .product > a:first-child {
  display: flex !important;
  flex-direction: column !important;
  flex: 1 !important;
  text-decoration: none !important;
  color: inherit !important;
  min-height: 0 !important;
  height: 100% !important;
  justify-content: space-between !important;
}

/* IMAGEN - AJUSTADA PARA 492px DE ALTURA TOTAL */
#waeg-grid.waeg-grid .product a img,
#waeg-grid.waeg-grid .product img,
#waeg-grid.waeg-grid .product .attachment-woocommerce_thumbnail {
  width: 100% !important;
  height: 235px !important;
  max-height: 235px !important;
  min-height: 235px !important;
  object-fit: contain !important;
  object-position: center !important;
  padding: 8px !important;
  background: #ffffff !important;
  display: block !important;
  margin: 0 !important;
  flex-shrink: 0 !important;
  box-sizing: border-box !important;
  border-radius: 8px 8px 0 0 !important;
}

/* Área de contenido - FLEX PARA EMPUJAR BOTÓN AL FONDO */
#waeg-grid.waeg-grid .product .woocommerce-loop-product__link {
  display: flex !important;
  flex-direction: column !important;
  flex: 1 !important;
  min-height: 0 !important;
}

/* Wrapper para contenido del medio (título + precio) */
#waeg-grid.waeg-grid .product .woocommerce-loop-product__link > div,
#waeg-grid.waeg-grid .product .product-content {
  flex: 0 0 auto !important;
}

/* TÍTULO - AJUSTADO PARA CARD DE 492px */
#waeg-grid.waeg-grid .product .woocommerce-loop-product__title,
#waeg-grid.waeg-grid .product h2.woocommerce-loop-product__title,
#waeg-grid.waeg-grid .product h3.woocommerce-loop-product__title,
#waeg-grid.waeg-grid .product h2,
#waeg-grid.waeg-grid .product h3 {
  font-size: 14px !important;
  line-height: 1.4 !important;
  margin: 4px 16px 12px 16px !important;
  padding: 0 !important;
  font-weight: 500 !important;
  color: #333 !important;
  height: 40px !important;
  max-height: 40px !important;
  min-height: 40px !important;
  display: -webkit-box !important;
  -webkit-line-clamp: 2 !important;
  -webkit-box-orient: vertical !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  flex-shrink: 0 !important;
  box-sizing: border-box !important;
}

/* PRECIO - AJUSTADO PARA CARD DE 492px */
#waeg-grid.waeg-grid .product .price,
#waeg-grid.waeg-grid .product span.price {
  font-size: 18px !important;
  font-weight: 600 !important;
  color: #333 !important;
  margin: 0 16px 8px 16px !important;
  padding: 4px 0 !important;
  height: auto !important;
  min-height: 24px !important;
  max-height: none !important;
  display: block !important;
  flex-shrink: 0 !important;
  text-align: center !important;
  box-sizing: border-box !important;
  line-height: 1.3 !important;
}

#waeg-grid.waeg-grid .product .price del {
  opacity: 0.5 !important;
  font-weight: 400 !important;
  margin-right: 8px !important;
  font-size: 16px !important;
}

#waeg-grid.waeg-grid .product .price ins {
  text-decoration: none !important;
  color: #0073aa !important;
  font-weight: 600 !important;
}

/* BOTÓN - AJUSTADO PARA CARD DE 492px */
#waeg-grid.waeg-grid .product .button,
#waeg-grid.waeg-grid .product .add_to_cart_button,
#waeg-grid.waeg-grid .product a.button {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: calc(100% - 32px) !important;
  margin: 0 16px 16px 16px !important;
  padding: 10px 16px !important;
  text-align: center !important;
  background: #7B0303 !important;
  color: #ffffff !important;
  border: none !important;
  border-radius: 8px !important;
  font-size: 14px !important;
  font-weight: 600 !important;
  text-decoration: none !important;
  transition: all 0.3s ease !important;
  cursor: pointer !important;
  flex-shrink: 0 !important;
  box-sizing: border-box !important;
  height: 44px !important;
  min-height: 44px !important;
  max-height: 44px !important;
  line-height: 1.2 !important;
}

#waeg-grid.waeg-grid .product .button:hover,
#waeg-grid.waeg-grid .product .add_to_cart_button:hover,
#waeg-grid.waeg-grid .product a.button:hover {
  background: #5A0202 !important;
  transform: translateY(-2px) !important;
  box-shadow: 0 4px 8px rgba(123, 3, 3, 0.3) !important;
}

.waeg-grid .product .button,
.waeg-grid .product .add_to_cart_button {
  color: white !important;
  border: none !important;
  border-radius: 8px !important;
  font-weight: 600 !important;
  font-size: 15px !important;
  cursor: pointer !important;
  transition: all 0.3s ease !important;
  text-decoration: none !important;
  margin-top: auto !important;
  flex-shrink: 0 !important;
  height: 48px !important;
  line-height: 24px !important;
}

.waeg-grid .product .button:hover,
.waeg-grid .product .add_to_cart_button:hover {
  background: #5A0202 !important; /* Versión más oscura del rojo */
  transform: translateY(-2px) !important;
  box-shadow: 0 4px 8px rgba(123, 3, 3, 0.3) !important;
}

.waeg-grid .product .button:disabled,
.waeg-grid .product .button.loading {
  background: #ccc !important;
  cursor: not-allowed !important;
  transform: none !important;
  opacity: 0.7 !important;
}

/* Estado de producto agregado exitosamente */
.waeg-grid .product .button.added {
  background: #28a745 !important;
  color: white !important;
  animation: buttonAddedPulse 0.4s ease;
}

@keyframes buttonAddedPulse {
  0% { 
    transform: scale(1);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  }
  50% { 
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(40, 167, 69, 0.4);
  }
  100% { 
    transform: scale(1);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  }
}

/* Badge de "En oferta" — oculto en shop grid */
.waeg-grid .product .onsale {
  display: none !important;
}

/* Ocultar elementos innecesarios que puedan descuadrar */
.waeg-grid .product .woocommerce-loop-category__title,
.waeg-grid .product .product-category {
  display: none !important;
}

/* Remover márgenes/paddings de listas */
.waeg-grid .product * {
  box-sizing: border-box !important;
}

/* Asegurar que elementos adicionales no rompan el layout */
.waeg-grid .product .woocommerce-placeholder,
.waeg-grid .product .placeholder {
  height: 220px !important;
  background: #f5f5f5 !important;
}

/* Si hay productos sin imagen */
.waeg-grid .product:not(:has(img)) a:first-child::before {
  content: '' !important;
  display: block !important;
  height: 220px !important;
  background: #f5f5f5 !important;
  flex-shrink: 0 !important;
}

/* Forzar estructura incluso si faltan elementos */
.waeg-grid .product {
  grid-template-rows: none !important;
}

/* ======================================
   SOBRESCRITURA PARA 4 COLUMNAS
   ====================================== */

/* Estas reglas DEBEN ir después de las reglas base para tener prioridad */
.waeg-columns-4 .waeg-grid .product,
.waeg-columns-4 .waeg-grid li.product,
.waeg-columns-4 .waeg-grid .type-product {
  width: 267px !important;
  max-width: 267px !important;
  min-width: 267px !important;
  height: 390px !important;
  min-height: 390px !important;
  max-height: 390px !important;
}

.waeg-columns-4 .waeg-grid .product a img,
.waeg-columns-4 .waeg-grid .product img,
.waeg-columns-4 .waeg-grid .product .attachment-woocommerce_thumbnail {
  height: 231px !important;
  max-height: 231px !important;
  padding: 7px !important;
}

.waeg-columns-4 .waeg-grid .product h2,
.waeg-columns-4 .waeg-grid .product h3,
.waeg-columns-4 .waeg-grid .product .woocommerce-loop-product__title {
  font-size: 14px !important;
  line-height: 1.2 !important;
  padding: 4px !important;
}

.waeg-columns-4 .waeg-grid .product .price,
.waeg-columns-4 .waeg-grid .product span.price {
  font-size: 18px !important;
  font-weight: 700 !important;
  padding: 8px 4px !important;
  margin: 8px 0 !important;
  display: block !important;
  min-height: 36px !important;
  line-height: 1.3 !important;
  text-align: center !important;
}

.waeg-columns-4 .waeg-grid .product .button,
.waeg-columns-4 .waeg-grid .product .add_to_cart_button,
.waeg-columns-4 .waeg-grid .product a.button {
  font-size: 13px !important;
  padding: 9px 13px !important;
}

/* Card (mantener para compatibilidad con custom templates) */
.waeg-product {
  background: #fff;
  border: 1px solid #eee;
  border-radius: 8px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  height: 100%;
  box-shadow: 0 1px 3px rgba(0,0,0,0.02);
}

.waeg-product .waeg-product-link {
  color: inherit;
  text-decoration: none;
  display: block;
  flex: 1 1 auto;
}

.waeg-thumb {
  padding: 12px;
  display:flex;
  align-items:center;
  justify-content:center;
  height: 220px;
  background: #fafafa;
}

.waeg-thumb img {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  display:block;
}

/* Info */
.waeg-info {
  padding: 12px;
}

.waeg-title {
  font-size: 16px;
  margin: 0 0 8px 0;
  line-height: 1.2;
}

.waeg-price {
  font-weight: 600;
}

/* Acciones */
.waeg-actions {
  padding: 10px;
  border-top: 1px solid #f1f1f1;
  display:flex;
  gap:8px;
  justify-content: center;
  align-items:center;
}

.waeg-add-to-cart,
.waeg-view {
  display:inline-block;
  padding:8px 12px;
  border-radius:6px;
  text-decoration:none;
  border:1px solid #ddd;
  background:#fff;
  font-size:14px;
}

/* No results */
.waeg-no-results {
  grid-column: 1 / -1;
  padding: 30px;
  text-align: center;
  color:#666;
}

/* Botones de añadir al carrito */
.waeg-add-to-cart {
  background: #0073aa;
  color: white;
  border: none;
  padding: 8px 12px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 14px;
  transition: background-color 0.3s ease;
}

.waeg-add-to-cart:hover {
  background: #005177;
}

.waeg-add-to-cart:disabled {
  background: #ccc;
  cursor: not-allowed;
}

/* Notificaciones */
.waeg-notification {
  position: fixed;
  top: 20px;
  right: 20px;
  padding: 16px 24px;
  border-radius: 8px;
  color: white;
  font-size: 15px;
  font-weight: 600;
  z-index: 10000;
  box-shadow: 0 8px 24px rgba(0,0,0,0.25);
  animation: slideInFromRight 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  min-width: 280px;
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Icono de checkmark para éxito */
.waeg-notification-success::before {
  content: "✓";
  width: 24px;
  height: 24px;
  background: rgba(255,255,255,0.3);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 16px;
  font-weight: bold;
}

.waeg-notification-success {
  background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
}

/* Icono de X para error */
.waeg-notification-error::before {
  content: "✕";
  width: 24px;
  height: 24px;
  background: rgba(255,255,255,0.3);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 18px;
  font-weight: bold;
}

.waeg-notification-error {
  background: linear-gradient(135deg, #dc3545 0%, #c82333 100%);
}

@keyframes slideInFromRight {
  0% {
    transform: translateX(120%);
    opacity: 0;
  }
  60% {
    transform: translateX(-10px);
  }
  100% {
    transform: translateX(0);
    opacity: 1;
  }
}

/* ======================================
   BOTÓN FLOTANTE DEL CARRITO
   ====================================== */
.waeg-cart-float {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 60px;
  height: 60px;
  background: #0073aa;
  color: white;
  border: none;
  border-radius: 50%;
  font-size: 24px;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0, 115, 170, 0.4);
  z-index: 9998;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  padding: 0;
}

.waeg-cart-float:hover {
  background: #005177;
  transform: scale(1.1);
  box-shadow: 0 6px 20px rgba(0, 115, 170, 0.5);
}

.waeg-cart-float:active {
  transform: scale(0.95);
}

/* Animación cuando se agrega un producto al carrito */
.waeg-cart-float.cart-updated,
.waeg-cart-float.pulse {
  animation: cartFloatPulse 0.6s ease;
}

@keyframes cartFloatPulse {
  0% { 
    transform: scale(1); 
    box-shadow: 0 4px 12px rgba(0, 115, 170, 0.4);
  }
  25% { 
    transform: scale(1.15); 
    box-shadow: 0 8px 24px rgba(0, 115, 170, 0.6);
    background: #28a745;
  }
  50% { 
    transform: scale(1.2); 
    box-shadow: 0 12px 32px rgba(40, 167, 69, 0.7);
    background: #28a745;
  }
  75% { 
    transform: scale(1.1); 
    box-shadow: 0 8px 24px rgba(0, 115, 170, 0.6);
  }
  100% { 
    transform: scale(1); 
    box-shadow: 0 4px 12px rgba(0, 115, 170, 0.4);
  }
}

#waeg-cart-count {
  position: absolute;
  top: -4px;
  right: -4px;
  background: #dc3545;
  color: white;
  border-radius: 50%;
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 600;
  border: 2px solid white;
  box-shadow: 0 2px 6px rgba(0,0,0,0.2);
  transition: transform 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

/* Animación de actualización del contador */
#waeg-cart-count.updating {
  animation: cartBadgePop 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

@keyframes cartBadgePop {
  0% { 
    transform: scale(1); 
    background: #dc3545;
  }
  30% { 
    transform: scale(1.5) rotate(10deg); 
    background: #28a745;
  }
  60% { 
    transform: scale(1.3) rotate(-10deg); 
    background: #28a745;
  }
  100% { 
    transform: scale(1) rotate(0deg); 
    background: #dc3545;
  }
}

/* ======================================
   OFFCANVAS DEL CARRITO
   ====================================== */
.waeg-cart-offcanvas {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 9999;
  pointer-events: none;
  transition: opacity 0.3s ease;
  opacity: 0;
}

.waeg-cart-offcanvas.active {
  pointer-events: auto;
  opacity: 1;
}

.waeg-cart-offcanvas-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.6);
  cursor: pointer;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.waeg-cart-offcanvas.active .waeg-cart-offcanvas-overlay {
  opacity: 1;
}

.waeg-cart-offcanvas-panel {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  max-width: 450px;
  height: 100vh;
  max-height: 100vh;
  background: white;
  box-shadow: -8px 0 32px rgba(0, 0, 0, 0.2);
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  overflow-y: auto;
  padding: 24px;
  border-radius: 12px 0 0 12px;
  z-index: 10001;
}

.waeg-cart-offcanvas.active .waeg-cart-offcanvas-panel {
  transform: translateX(0);
  animation: slideInRight 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

@keyframes slideInRight {
  from {
    transform: translateX(100%);
    opacity: 0.8;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

.waeg-cart-offcanvas-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 32px;
  height: 32px;
  background: transparent;
  border: none;
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
  color: #666;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  transition: all 0.2s ease;
}

.waeg-cart-offcanvas-close:hover {
  background: #f5f5f5;
  color: #333;
}

.waeg-cart-offcanvas h2 {
  margin: 0 0 20px 0;
  font-size: 26px;
  font-weight: 700;
  color: #2c3e50;
  padding-right: 40px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.waeg-cart-offcanvas h2::before {
  content: '🛒';
  font-size: 28px;
}

.waeg-cart-offcanvas h3 {
  margin: 20px 0 12px 0;
  font-size: 18px;
  font-weight: 600;
  color: #333;
}

.waeg-cart-offcanvas hr {
  border: none;
  border-top: 1px solid #e5e5e5;
  margin: 20px 0;
}

/* ======================================
   NOTIFICACIÓN TOAST PARA CARRITO
   ====================================== */
.waeg-toast-notification {
  position: fixed;
  top: 20px;
  right: 20px;
  background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
  color: white;
  padding: 16px 24px;
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
  display: flex;
  align-items: center;
  gap: 12px;
  z-index: 10002;
  opacity: 0;
  transform: translateX(400px);
  transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  pointer-events: none;
  max-width: 350px;
}

.waeg-toast-notification.show {
  opacity: 1;
  transform: translateX(0);
  pointer-events: auto;
}

.waeg-toast-notification.hide {
  opacity: 0;
  transform: translateX(400px);
}

.waeg-toast-icon {
  font-size: 28px;
  line-height: 1;
  animation: toastIconBounce 0.6s ease;
}

@keyframes toastIconBounce {
  0%, 100% { transform: scale(1); }
  25% { transform: scale(1.2) rotate(10deg); }
  50% { transform: scale(0.9) rotate(-10deg); }
  75% { transform: scale(1.1) rotate(5deg); }
}

.waeg-toast-content {
  flex: 1;
}

.waeg-toast-title {
  font-weight: 700;
  font-size: 15px;
  margin-bottom: 4px;
}

.waeg-toast-message {
  font-size: 13px;
  opacity: 0.95;
}

.waeg-toast-close {
  background: rgba(255, 255, 255, 0.2);
  border: none;
  color: white;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  transition: background 0.2s ease;
}

.waeg-toast-close:hover {
  background: rgba(255, 255, 255, 0.3);
}

.waeg-toast-actions {
  margin-top: 8px;
  display: flex;
  gap: 8px;
}

.waeg-toast-btn {
  background: rgba(255, 255, 255, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.4);
  color: white;
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.waeg-toast-btn:hover {
  background: rgba(255, 255, 255, 0.3);
  border-color: rgba(255, 255, 255, 0.6);
}

.waeg-toast-btn.primary {
  background: white;
  color: #28a745;
  border-color: white;
}

.waeg-toast-btn.primary:hover {
  background: rgba(255, 255, 255, 0.9);
}

/* ⇒ MOBILE [7]: @media (max-width: 640px) { — ver shop-mobile.css */

/* ======================================
   CONTENIDO DEL CARRITO
   ====================================== */
.waeg-cart-items {
  flex: 1;
  overflow-y: auto;
  overflow-x: visible !important; /* Permitir que los botones de eliminar no se corten */
  margin-bottom: 16px;
  padding: 4px; /* Padding pequeño para que el botón no se corte en los bordes */
}

.waeg-cart-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.waeg-cart-item {
  display: flex;
  gap: 12px;
  padding: 16px;
  background: #ffffff;
  border: 1px solid #e0e0e0;
  border-radius: 12px;
  margin-bottom: 12px;
  align-items: flex-start;
  position: relative;
  transition: all 0.3s ease;
  box-shadow: 0 1px 3px rgba(0,0,0,0.08);
  overflow: visible !important; /* IMPORTANTE: permite que el botón de eliminar no se corte */
}

.waeg-cart-item:hover {
  background: #fafafa;
  box-shadow: 0 2px 8px rgba(0,0,0,0.12);
  border-color: #d0d0d0;
}

/* Botón de eliminar producto - ESQUINA SUPERIOR DERECHA */
.waeg-cart-remove {
  position: absolute;
  top: -8px;
  right: -8px;
  width: 28px;
  height: 28px;
  border: 2px solid #fff;
  background: #ff4444;
  color: white;
  border-radius: 50%;
  cursor: pointer;
  font-size: 20px;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  padding: 0;
  font-weight: 400;
  box-shadow: 0 2px 8px rgba(255, 68, 68, 0.4);
  z-index: 10;
  overflow: visible !important; /* Asegurar que el icono no se corte */
}

.waeg-cart-remove:hover {
  background: #dd0000;
  transform: scale(1.15) rotate(90deg);
  box-shadow: 0 4px 12px rgba(255, 68, 68, 0.6);
}

.waeg-cart-remove:active {
  transform: scale(1.05) rotate(90deg);
}

.waeg-cart-item .waeg-cart-thumb {
  width: 80px;
  height: 80px;
  object-fit: cover;
  border-radius: 8px;
  background: white;
  padding: 4px;
  flex-shrink: 0;
  border: 1px solid #e0e0e0;
}

.waeg-cart-item-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-width: 0;
  padding-right: 20px;
}

.waeg-cart-item-name {
  font-size: 14px;
  font-weight: 600;
  color: #1a1a1a;
  line-height: 1.4;
  word-wrap: break-word;
}

/* Controles de cantidad */
.waeg-cart-item-quantity {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 6px 0;
}

.waeg-qty-minus,
.waeg-qty-plus {
  width: 32px;
  height: 32px;
  border: 2px solid #333;
  background: #ffffff;
  color: #333;
  border-radius: 6px;
  cursor: pointer;
  font-size: 18px;
  font-weight: 700;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  padding: 0;
  user-select: none;
}

.waeg-qty-minus:hover,
.waeg-qty-plus:hover {
  background: #333;
  color: #fff;
  transform: scale(1.1);
}

.waeg-qty-minus:active,
.waeg-qty-plus:active {
  transform: scale(0.95);
}

/* Input de cantidad - SIN FLECHAS */
.waeg-qty-input {
  width: 50px;
  height: 32px;
  text-align: center;
  border: 2px solid #333;
  border-radius: 6px;
  font-size: 15px;
  font-weight: 700;
  color: #1a1a1a;
  background: #ffffff;
  padding: 0;
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: textfield;
}

/* Remover flechas del input number en Chrome, Safari, Edge, Opera */
.waeg-qty-input::-webkit-outer-spin-button,
.waeg-qty-input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

/* Remover flechas del input number en Firefox */
.waeg-qty-input[type=number] {
  -moz-appearance: textfield;
}

.waeg-qty-input:focus {
  outline: none;
  border-color: #0073aa;
  box-shadow: 0 0 0 3px rgba(0, 115, 170, 0.1);
}

/* Precios del producto */
.waeg-cart-item-prices {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.waeg-cart-item-price-unit {
  font-size: 12px;
  color: #666;
  font-weight: 500;
}

.waeg-cart-item-price-subtotal {
  font-size: 16px;
  font-weight: 700;
  color: #0073aa;
}

/* Sección de totales del carrito */
.waeg-cart-totals {
  background: #f8f9fa;
  border: 1px solid #e0e0e0;
  border-radius: 12px;
  padding: 20px;
  margin: 20px 0;
}

.waeg-cart-total-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid #e0e0e0;
}

.waeg-cart-total-row:last-child {
  border-bottom: none;
}

.waeg-cart-total-row.waeg-cart-total-final {
  margin-top: 12px;
  padding-top: 16px;
  border-top: 2px solid #1a1a1a;
  font-size: 18px;
}

.waeg-cart-total-label {
  font-size: 14px;
  color: #333;
  font-weight: 500;
}

.waeg-cart-total-value {
  font-size: 14px;
  color: #1a1a1a;
  font-weight: 600;
}

.waeg-cart-total-final .waeg-cart-total-label,
.waeg-cart-total-final .waeg-cart-total-value {
  font-size: 20px;
  color: #000;
  font-weight: 700;
}

/* Botones de acción del carrito */
.waeg-cart-actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 20px;
}

.waeg-cart-btn {
  display: block;
  width: 100%;
  padding: 16px 20px;
  text-align: center;
  color: white;
  text-decoration: none;
  border-radius: 10px;
  font-weight: 700;
  font-size: 16px;
  transition: all 0.3s ease;
  border: none;
  cursor: pointer;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.waeg-cart-goto {
  background: #0073aa;
}

.waeg-cart-goto:hover {
  background: #005a87;
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 115, 170, 0.4);
}

.waeg-cart-checkout {
  background: #28a745;
}

.waeg-cart-checkout:hover {
  background: #1e7e34;
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(40, 167, 69, 0.4);
}

.waeg-cart-empty,
.waeg-cart-error {
  padding: 60px 20px;
  text-align: center;
  color: #666;
  font-size: 16px;
  background: #f8f9fa;
  border: 1px solid #e0e0e0;
  border-radius: 12px;
  line-height: 1.8;
}

/* ======================================
   RESPONSIVE - BOTÓN FLOTANTE Y OFFCANVAS
   ====================================== */

/* Tablet */
/* ⇒ MOBILE [8]: @media (max-width: 991px) { — ver shop-mobile.css */

/* Tablet y Mobile - Offcanvas lateral con altura completa */
/* ⇒ MOBILE [9]: @media (max-width: 991px) { — ver shop-mobile.css */

/* Móvil */
/* ⇒ MOBILE [10]: @media (max-width: 767px) { — ver shop-mobile.css */

/* Móvil pequeño */
/* ⇒ MOBILE [11]: @media (max-width: 720px) { — ver shop-mobile.css */

/* ======================================
   FEATURED GRID - Grid con productos ancla en diagonal
   ====================================== */

.waeg-featured-grid-wrapper {
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
  padding: 40px 20px;
}

.waeg-featured-slice {
  margin-bottom: 80px;
}

.waeg-featured-slice:last-child {
  margin-bottom: 0;
}

.waeg-featured-slice-title {
  font-size: 32px;
  font-weight: 700;
  margin-bottom: 32px;
  text-align: center;
  color: #333;
}

/* Grid principal: 4 columnas × 2 filas 
   Cada row: 2 cols para ancla + 2 cols para productos normales (1 col cada uno)
*/
.waeg-featured-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-template-rows: repeat(2, auto);
  gap: 24px;
  width: 100%;
}

/* Productos ancla ocupan 2 columnas */
.waeg-featured-anchor {
  position: relative;
  overflow: hidden;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 4px 16px rgba(0,0,0,0.1);
  transition: all 0.3s ease;
}

/* Pattern 1: Ancla top-left y bottom-right 
   Grid de 4 columnas: Ancla ocupa 2 cols + 2 productos normales (1 col cada uno)
   Orden HTML: [Ancla1][Fill1][Fill2][Fill3][Fill4][Ancla2]
   
   Layout:
   ROW 1: [Ancla1 (cols 1-2)] [Fill1 (col 3)] [Fill2 (col 4)]
   ROW 2: [Fill3 (col 1)] [Fill4 (col 2)] [Ancla2 (cols 3-4)]
*/
.waeg-featured-pattern-1 .waeg-featured-product:nth-child(1) {
  grid-column: 1 / 3; /* Ancla 1: Columnas 1-2, row 1 */
  grid-row: 1;
}

.waeg-featured-pattern-1 .waeg-featured-product:nth-child(2) {
  grid-column: 3; /* Fill 1: Columna 3, row 1 */
  grid-row: 1;
}

.waeg-featured-pattern-1 .waeg-featured-product:nth-child(3) {
  grid-column: 4; /* Fill 2: Columna 4, row 1 */
  grid-row: 1;
}

.waeg-featured-pattern-1 .waeg-featured-product:nth-child(4) {
  grid-column: 1; /* Fill 3: Columna 1, row 2 */
  grid-row: 2;
}

.waeg-featured-pattern-1 .waeg-featured-product:nth-child(5) {
  grid-column: 2; /* Fill 4: Columna 2, row 2 */
  grid-row: 2;
}

.waeg-featured-pattern-1 .waeg-featured-product:nth-child(6) {
  grid-column: 3 / 5; /* Ancla 2: Columnas 3-4, row 2 */
  grid-row: 2;
}

/* Pattern 2: Ancla top-right y bottom-left 
   Grid de 4 columnas: Ancla ocupa 2 cols + 2 productos normales (1 col cada uno)
   Orden HTML: [Fill1][Fill2][Ancla1][Ancla2][Fill3][Fill4]
   
   Layout:
   ROW 1: [Fill1 (col 1)] [Fill2 (col 2)] [Ancla1 (cols 3-4)]
   ROW 2: [Ancla2 (cols 1-2)] [Fill3 (col 3)] [Fill4 (col 4)]
*/
.waeg-featured-pattern-2 .waeg-featured-product:nth-child(1) {
  grid-column: 1; /* Fill 1: Columna 1, row 1 */
  grid-row: 1;
}

.waeg-featured-pattern-2 .waeg-featured-product:nth-child(2) {
  grid-column: 2; /* Fill 2: Columna 2, row 1 */
  grid-row: 1;
}

.waeg-featured-pattern-2 .waeg-featured-product:nth-child(3) {
  grid-column: 3 / 5; /* Ancla 1: Columnas 3-4, row 1 */
  grid-row: 1;
}

.waeg-featured-pattern-2 .waeg-featured-product:nth-child(4) {
  grid-column: 1 / 3; /* Ancla 2: Columnas 1-2, row 2 */
  grid-row: 2;
}

.waeg-featured-pattern-2 .waeg-featured-product:nth-child(5) {
  grid-column: 3; /* Fill 3: Columna 3, row 2 */
  grid-row: 2;
}

.waeg-featured-pattern-2 .waeg-featured-product:nth-child(6) {
  grid-column: 4; /* Fill 4: Columna 4, row 2 */
  grid-row: 2;
}

/* Productos fill ocupan 1 columna */
.waeg-featured-fill {
  position: relative;
  overflow: hidden;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  transition: all 0.3s ease;
}

.waeg-featured-product:hover {
  transform: translateY(-8px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.15);
}

/* Link del producto */
.waeg-featured-product-link {
  display: block;
  text-decoration: none;
  color: inherit;
}

/* Imagen del producto */
.waeg-featured-product-image {
  position: relative;
  width: 100%;
  padding-bottom: 100%; /* Ratio 1:1 */
  overflow: hidden;
  background: #ffffff; /* ✅ Fondo blanco */
}

.waeg-featured-product-image img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.waeg-featured-product:hover .waeg-featured-product-image img {
  transform: scale(1.05);
}

/* Badges (oferta/destacado) */
.waeg-featured-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  z-index: 2;
}

.waeg-badge-sale {
  background: #ff4444;
  color: #fff;
}

.waeg-badge-featured {
  background: #ffd700;
  color: #333;
  top: 48px;
}

/* Info del producto */
.waeg-featured-product-info {
  padding: 20px;
}

.waeg-featured-anchor .waeg-featured-product-info {
  padding: 24px;
}

.waeg-featured-product-title {
  font-size: 18px;
  font-weight: 600;
  margin: 0 0 12px 0;
  color: #333;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.waeg-featured-anchor .waeg-featured-product-title {
  font-size: 22px;
  -webkit-line-clamp: 3;
}

.waeg-featured-product-price {
  font-size: 20px;
  font-weight: 700;
  color: #2c3e50;
}

.waeg-featured-anchor .waeg-featured-product-price {
  font-size: 24px;
}

.waeg-featured-product-price del {
  font-size: 16px;
  font-weight: 400;
  color: #999;
  margin-right: 8px;
}

.waeg-featured-product-price ins {
  text-decoration: none;
  color: #e74c3c;
}

/* Acciones (botón añadir al carrito) */
.waeg-featured-product-actions {
  padding: 0 20px 20px 20px;
}

.waeg-featured-anchor .waeg-featured-product-actions {
  padding: 0 24px 24px 24px;
}

.waeg-featured-add-to-cart,
.waeg-featured-view-product {
  display: block;
  width: 100%;
  padding: 14px 24px;
  background: #0073aa;
  color: #fff;
  border: none;
  border-radius: 6px;
  font-size: 16px;
  font-weight: 600;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.3s ease;
}

.waeg-featured-anchor .waeg-featured-add-to-cart,
.waeg-featured-anchor .waeg-featured-view-product {
  padding: 16px 28px;
  font-size: 18px;
}

.waeg-featured-add-to-cart:hover,
.waeg-featured-view-product:hover {
  background: #005177;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,115,170,0.3);
}

.waeg-featured-view-product {
  background: #7f8c8d;
}

.waeg-featured-view-product:hover {
  background: #5d6d6e;
  box-shadow: 0 4px 12px rgba(127,140,141,0.3);
}

/* RESPONSIVE: Tablet */
/* ⇒ MOBILE [12]: @media (max-width: 991px) { — ver shop-mobile.css */

/* RESPONSIVE: Mobile */
/* ⇒ MOBILE [13]: @media (max-width: 767px) { — ver shop-mobile.css */

/* ======================================
   TAB NAVIGATION
   Navegación estilo tabs para páginas
   ====================================== */

.waeg-tab-navigation {
  width: 100%;
  margin: 32px 0;
  padding: 0;
  border-bottom: 2px solid #e0e0e0;
}

.waeg-tab-list {
  display: flex;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 8px;
  flex-wrap: wrap;
}

/* Alineación */
.waeg-tab-navigation[data-align="center"] .waeg-tab-list {
  justify-content: center;
}

.waeg-tab-navigation[data-align="right"] .waeg-tab-list {
  justify-content: flex-end;
}

.waeg-tab-item {
  position: relative;
  margin: 0;
  padding: 0;
}

.waeg-tab-link {
  display: block;
  padding: 14px 24px;
  text-decoration: none;
  color: #333333;
  font-weight: 600;
  font-size: 15px;
  transition: all 0.3s ease;
  white-space: nowrap;
  border-bottom: 3px solid transparent;
  margin-bottom: -2px;
}

/* ESTILO: Default */
.waeg-tab-nav-default .waeg-tab-item:hover .waeg-tab-link {
  color: #ff0000;
  border-bottom-color: #ff0000;
}

.waeg-tab-nav-default .waeg-tab-item.active .waeg-tab-link {
  color: #cc0000;
  border-bottom-color: #cc0000;
}

/* ESTILO: Modern */
.waeg-tab-nav-modern .waeg-tab-link {
  background: #f5f5f5;
  border-radius: 8px 8px 0 0;
  border: 1px solid #e0e0e0;
  border-bottom: none;
}

.waeg-tab-nav-modern .waeg-tab-item:hover .waeg-tab-link {
  background: #ffffff;
  color: #ff0000;
  border-color: #ff0000;
  transform: translateY(-2px);
}

.waeg-tab-nav-modern .waeg-tab-item.active .waeg-tab-link {
  background: #ffffff;
  color: #cc0000;
  border-color: #cc0000;
  border-bottom: 3px solid #ffffff;
}

/* ESTILO: Minimal */
.waeg-tab-nav-minimal .waeg-tab-link {
  padding: 12px 20px;
  font-weight: 500;
  border-bottom: none;
}

.waeg-tab-nav-minimal .waeg-tab-item {
  position: relative;
}

.waeg-tab-nav-minimal .waeg-tab-item::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%) scaleX(0);
  width: 80%;
  height: 2px;
  background: #cc0000;
  transition: transform 0.3s ease;
}

.waeg-tab-nav-minimal .waeg-tab-item:hover::after {
  transform: translateX(-50%) scaleX(1);
}

.waeg-tab-nav-minimal .waeg-tab-item.active::after {
  transform: translateX(-50%) scaleX(1);
}

.waeg-tab-nav-minimal .waeg-tab-item:hover .waeg-tab-link {
  color: #ff0000;
}

.waeg-tab-nav-minimal .waeg-tab-item.active .waeg-tab-link {
  color: #cc0000;
}

/* ESTILO: Pills */
.waeg-tab-nav-pills {
  border-bottom: none;
}

.waeg-tab-nav-pills .waeg-tab-link {
  border-radius: 50px;
  padding: 12px 28px;
  border: 2px solid #e0e0e0;
  background: #ffffff;
  margin-bottom: 0;
}

.waeg-tab-nav-pills .waeg-tab-item:hover .waeg-tab-link {
  border-color: #ff0000;
  background: #fff5f5;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(255, 0, 0, 0.1);
}

.waeg-tab-nav-pills .waeg-tab-item.active .waeg-tab-link {
  background: #cc0000;
  border-color: #cc0000;
  color: #ffffff !important;
  box-shadow: 0 4px 12px rgba(204, 0, 0, 0.3);
}

/* RESPONSIVE: Tablet */
/* ⇒ MOBILE [14]: @media (max-width: 991px) { — ver shop-mobile.css */

/* RESPONSIVE: Mobile */
/* ⇒ MOBILE [15]: @media (max-width: 767px) { — ver shop-mobile.css */

/* Mobile pequeño */
/* ⇒ MOBILE [16]: @media (max-width: 720px) { — ver shop-mobile.css */

/* ========================================
   WOLF THEME STYLES
   Estilos para integración con Wolf Theme
   Uso: Agregar clase 'wolf-theme' al body o wrapper
   ======================================== */

body.wolf-theme .waeg-sidebar,
.wolf-theme .waeg-sidebar {
  background: transparent; /* Sin fondo */
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  border: none; /* Sin borde */
  border-radius: 0;
  padding: 0; /* Sin padding */
  box-shadow: none; /* Sin sombra */
}

body.wolf-theme .waeg-sidebar-title,
.wolf-theme .waeg-sidebar-title {
  font-size: 16px;
  font-weight: 700;
  color: #ffffff; /* Cambiado de #2d3748 a blanco */
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-bottom: 1px solid #e5e5e5;
  padding-bottom: 12px;
  margin-bottom: 20px;
}

/* Categorías sin cajones - solo iconos y texto */
body.wolf-theme .waeg-category-item,
body.wolf-theme .waeg-subcategory-item,
.wolf-theme .waeg-category-item,
.wolf-theme .waeg-subcategory-item {
  background: transparent; /* Sin fondo */
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  border: none; /* Sin borde */
  border-radius: 0;
  padding: 8px 4px; /* Reducido */
  font-size: 13px; /* Reducido de 14px */
  font-weight: 600;
  color: #ffffff; /* Cambiado de #2d3748 a blanco */
  cursor: pointer;
  transition: all 0.3s ease;
  display: inline-flex;
  flex-direction: column; /* Vertical como el diseño principal */
  justify-content: center;
  align-items: center;
  margin-bottom: 0; /* Sin margen */
  gap: 6px;
}

body.wolf-theme .waeg-category-item:hover,
body.wolf-theme .waeg-subcategory-item:hover,
.wolf-theme .waeg-category-item:hover,
.wolf-theme .waeg-subcategory-item:hover {
  background: transparent; /* Sin fondo */
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  border-color: transparent;
  color: #e74c3c;
  transform: translateY(-3px);
  box-shadow: none; /* Sin sombra */
}

body.wolf-theme .waeg-category-item.active,
body.wolf-theme .waeg-subcategory-item.active,
.wolf-theme .waeg-category-item.active,
.wolf-theme .waeg-subcategory-item.active {
  background: transparent; /* Sin fondo */
  color: #e74c3c; /* Color rojo solo para el texto */
  border-color: transparent; /* Sin borde */
  font-weight: 700;
}

body.wolf-theme .waeg-category-item.active:hover,
body.wolf-theme .waeg-subcategory-item.active:hover,
.wolf-theme .waeg-category-item.active:hover,
.wolf-theme .waeg-subcategory-item.active:hover {
  background: transparent; /* Sin fondo */
  border-color: transparent; /* Sin borde */
  transform: translateY(-3px); /* Reducido de -2px */
}

/* Contador de productos en Wolf Theme */
body.wolf-theme .waeg-category-count,
body.wolf-theme .waeg-subcategory-count,
.wolf-theme .waeg-category-count,
.wolf-theme .waeg-subcategory-count {
  background: #f1f1f1;
  color: #666;
  border-radius: 12px;
  padding: 2px 8px;
  font-size: 12px;
  font-weight: 600;
  margin-left: 8px;
}

body.wolf-theme .waeg-category-item.active .waeg-category-count,
body.wolf-theme .waeg-subcategory-item.active .waeg-subcategory-count,
.wolf-theme .waeg-category-item.active .waeg-category-count,
.wolf-theme .waeg-subcategory-item.active .waeg-subcategory-count {
  background: rgba(255, 255, 255, 0.25);
  color: #ffffff;
}

/* Subcategorías en Wolf Theme */
body.wolf-theme .waeg-subcategory-item,
.wolf-theme .waeg-subcategory-item {
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  border: 1px solid rgba(209, 213, 219, 0.6);
  border-radius: 20px;
  padding: 8px 16px;
  font-size: 13px;
}

body.wolf-theme .waeg-subcategory-item:hover,
.wolf-theme .waeg-subcategory-item:hover {
  border-color: #e74c3c;
  background: rgba(255, 245, 245, 0.9);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

body.wolf-theme .waeg-subcategory-item.active,
.wolf-theme .waeg-subcategory-item.active {
  background: #4a5568;
  color: #ffffff;
  border-color: #4a5568;
}

/* Tabs de sub-subcategorías en Wolf Theme */
body.wolf-theme .waeg-tab-item,
.wolf-theme .waeg-tab-item {
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  border: 1px solid rgba(209, 213, 219, 0.6);
  border-radius: 18px;
  padding: 6px 14px;
  font-size: 13px;
  font-weight: 600;
  color: #4a5568;
  transition: all 0.3s ease;
}

body.wolf-theme .waeg-tab-item:hover,
.wolf-theme .waeg-tab-item:hover {
  background: rgba(247, 250, 252, 0.95);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-color: #718096;
  color: #2d3748;
}

body.wolf-theme .waeg-tab-item.active,
.wolf-theme .waeg-tab-item.active {
  background: #2d3748;
  color: #ffffff;
  border-color: #2d3748;
}

/* Remover bordes animados en Wolf Theme */
body.wolf-theme .waeg-category-item:nth-child(1),
body.wolf-theme .waeg-category-item:nth-child(2),
.wolf-theme .waeg-category-item:nth-child(1),
.wolf-theme .waeg-category-item:nth-child(2) {
  border: 2px solid #e74c3c;
  animation: none;
  box-shadow: none;
}

body.wolf-theme .waeg-category-item:nth-child(1)::before,
body.wolf-theme .waeg-category-item:nth-child(2)::before,
.wolf-theme .waeg-category-item:nth-child(1)::before,
.wolf-theme .waeg-category-item:nth-child(2)::before {
  display: none;
}

body.wolf-theme .waeg-category-item:nth-child(1).active,
body.wolf-theme .waeg-category-item:nth-child(2).active,
.wolf-theme .waeg-category-item:nth-child(1).active,
.wolf-theme .waeg-category-item:nth-child(2).active {
  background: #e74c3c;
  border-color: #e74c3c;
  animation: none;
}

/* Buscador en Wolf Theme */
body.wolf-theme #waeg-search,
.wolf-theme #waeg-search {
  border: 2px solid rgba(229, 231, 235, 0.6);
  border-radius: 25px;
  padding: 12px 20px;
  font-size: 14px;
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  color: #2d3748;
}

body.wolf-theme #waeg-search:focus,
.wolf-theme #waeg-search:focus {
  border-color: #e74c3c;
  outline: none;
  background: rgba(255, 255, 255, 0.95);
  box-shadow: 0 0 0 3px rgba(231, 76, 60, 0.1);
}

/* Selector de ordenamiento en Wolf Theme */
body.wolf-theme #waeg-sort,
.wolf-theme #waeg-sort {
  border: 2px solid rgba(229, 231, 235, 0.6);
  border-radius: 20px;
  padding: 10px 16px;
  font-size: 14px;
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  color: #2d3748;
}

body.wolf-theme #waeg-sort:focus,
.wolf-theme #waeg-sort:focus {
  border-color: #e74c3c;
  outline: none;
}

/* Grid en Wolf Theme - mantener fondo claro */
body.wolf-theme .waeg-main-content,
.wolf-theme .waeg-main-content {
  background: transparent;
}

body.wolf-theme #waeg-grid .product,
.wolf-theme #waeg-grid .product {
  background: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  transition: all 0.3s ease;
}

body.wolf-theme #waeg-grid .product:hover,
.wolf-theme #waeg-grid .product:hover {
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  transform: translateY(-4px);
}

/* Responsive Wolf Theme */
/* ⇒ MOBILE [17]: @media (max-width: 767px) { — ver shop-mobile.css */

/* ==========================================================================
   BOTÓN DE COMPARTIR WHATSAPP - OCULTO (USAMOS EL DEL BUTTON ROW)
   ========================================================================== */

.waeg-shop-share-whatsapp {
  display: none !important; /* OCULTO - usamos el botón del mobile-button-row */
}

/* Mostrar solo en móvil (<767px) - DESHABILITADO */
/* ⇒ MOBILE [18]: @media (max-width: 767px) { — ver shop-mobile.css */

/* ======================================
   SOBRESCRITURA FINAL - MÁXIMA PRIORIDAD
   ====================================== */

/* Forzar centrado de precio en MÓVIL para 4 columnas */
/* ⇒ MOBILE [19]: @media (max-width: 720px) { — ver shop-mobile.css */

/* ======================================
   BOTÓN DE LUPA MÓVIL CON BUSCADOR DESPLEGABLE
   ====================================== */

.waeg-mobile-search-container {
  position: relative;
  display: inline-block;
  z-index: 9998;
}

/* Botón de lupa - ESTÁTICO para navbar */
.waeg-mobile-search-toggle {
  position: relative;
  background: transparent;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  box-shadow: none;
  transition: all 0.3s ease;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.waeg-mobile-search-toggle:hover {
  background: transparent;
  box-shadow: none;
  transform: scale(1.1);
}

.waeg-mobile-search-toggle:active {
  transform: scale(0.95);
}

.waeg-lupa-icon {
  width: 60%;
  height: 60%;
  object-fit: contain;
}

/* Panel desplegable - OCULTO por defecto */
.waeg-mobile-search-panel {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background: white;
  padding: 16px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  transform: translateY(-100%);
  transition: transform 0.3s ease;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* Panel ACTIVO - visible */
.waeg-mobile-search-panel.active {
  transform: translateY(0);
}

/* Botón cerrar */
.waeg-mobile-search-close {
  position: absolute;
  top: 12px;
  right: 12px;
  background: transparent;
  border: none;
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
  color: #666;
  padding: 0;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.waeg-mobile-search-close:hover {
  color: #333;
}

/* Formulario de búsqueda */
.waeg-mobile-search-form {
  display: flex;
  gap: 8px;
  margin-top: 32px;
}

.waeg-mobile-search-input {
  flex: 1;
  padding: 12px 16px;
  font-size: 16px;
  border: 2px solid #e0e0e0;
  border-radius: 8px;
  outline: none;
}

.waeg-mobile-search-input:focus {
  border-color: #0073aa;
}

.waeg-mobile-search-submit {
  background: #0073aa;
  border: none;
  border-radius: 8px;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: white;
  flex-shrink: 0;
}

.waeg-mobile-search-submit:hover {
  background: #005177;
}

/* Resultados de búsqueda */
.waeg-mobile-search-results {
  max-height: 400px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.waeg-suggestion-item {
  display: flex;
  gap: 12px;
  padding: 10px;
  background: #f9f9f9;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.2s ease;
}

.waeg-suggestion-item:hover {
  background: #e8f4f8;
}

.waeg-suggestion-item img {
  width: 50px;
  height: 50px;
  object-fit: cover;
  border-radius: 6px;
  flex-shrink: 0;
}

.waeg-suggestion-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
  justify-content: center;
}

.waeg-suggestion-title {
  font-size: 14px;
  font-weight: 500;
  color: #333;
  line-height: 1.3;
}

.waeg-suggestion-price {
  font-size: 14px;
  font-weight: 600;
  color: #0073aa;
}

.waeg-no-results {
  text-align: center;
  padding: 20px;
  color: #999;
  font-size: 14px;
}

/* Ocultar en desktop por defecto */
@media (min-width: 768px) {
  .waeg-mobile-search-container:not(.waeg-show-desktop) {
    display: none;
  }
}

/* Ajustes móviles */
/* ⇒ MOBILE [20]: @media (max-width: 720px) { — ver shop-mobile.css */

/* ======================================
   SEPARACIÓN VISUAL DE SECCIONES
   ====================================== */

/* Contenedor de categorías - Sin caja visible */
.waeg-categories-container {
  background: transparent; /* Sin fondo blanco */
  border-radius: 0; /* Sin bordes redondeados */
  padding: 0; /* Sin padding */
  margin-bottom: 12px; /* Reducido */
  box-shadow: none; /* Sin sombra */
  border: none; /* Sin borde */
}

/* Título especial para categorías */
.waeg-categories-title {
  display: none !important; /* OCULTAR EL TÍTULO */
  font-size: 16px !important; /* Reducido de 20px a 16px */
  font-weight: 700 !important; /* Reducido de 800 a 700 */
  color: #ffffff !important; /* Cambiado de #1a1a1a a blanco */
  margin-bottom: 12px !important; /* Aumentado ligeramente para separar del grid */
  padding-bottom: 8px !important; /* Aumentado para el borde inferior */
  border-bottom: 2px solid #0073aa !important; /* Mantener línea separadora */
  text-transform: uppercase;
  letter-spacing: 0.5px; /* Reducido de 1px a 0.5px */
}

/* ======================================
   FILTROS POR ATRIBUTOS - SIDEBAR LATERAL
   ====================================== */

/* Contenedor de atributos en sidebar lateral */
.waeg-filters-sidebar .waeg-attributes-container {
  background: transparent;
  border-radius: 0;
  padding: 0;
  margin-bottom: 0;
  box-shadow: none;
  border: none;
}

/* Título de la sección de atributos */
.waeg-attributes-title {
  font-size: 16px !important;
  font-weight: 700 !important;
  color: #2c3e50 !important;
  margin-bottom: 16px !important;
  padding-bottom: 8px !important;
  border-bottom: 2px solid #6c757d !important;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Cada filtro de atributo individual */
.waeg-attribute-filter {
  margin-bottom: 8px; /* Reducido de 16px a 8px (50%) */
  padding-bottom: 6px; /* Reducido de 12px a 6px (50%) */
  border-bottom: 1px solid #e0e0e0;
}

.waeg-attribute-filter:last-child {
  margin-bottom: 6px; /* Reducido de 12px a 6px (50%) */
  border-bottom: none;
}

/* Nombre del atributo (ej: "Color", "Talle", "Marca") */
.waeg-attribute-name {
  font-size: 14px;
  font-weight: 600;
  color: #495057;
  margin: 0 0 5px 0; /* Reducido de 10px a 5px (50%) */
  padding: 6px 10px;
  background: #ffffff;
  border-radius: 6px;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: all 0.2s ease;
  user-select: none;
}

.waeg-attribute-name:hover {
  background: #e9ecef;
}

/* Toggle icon para colapsar/expandir */
.waeg-attribute-toggle {
  font-size: 11px;
  transition: transform 0.3s ease;
  display: inline-block;
}

.waeg-attribute-filter.collapsed .waeg-attribute-toggle {
  transform: rotate(-90deg);
}

/* Contenedor de términos (opciones) */
.waeg-attribute-terms {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 6px 0;
  max-height: 250px;
  overflow-y: auto;
  transition: all 0.3s ease;
}

.waeg-attribute-filter.collapsed .waeg-attribute-terms {
  max-height: 0;
  overflow: hidden;
  padding: 0;
  opacity: 0;
}

/* Cada opción (checkbox + label) */
.waeg-attribute-term-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 12px;
  background: #ffffff;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
  border: 1px solid transparent;
  margin: 0;
}

.waeg-attribute-term-item:hover {
  background: #f1f3f5;
  border-color: #0073aa;
}

/* Checkbox personalizado - MEJORADO */
.waeg-attribute-checkbox {
  width: 20px;
  height: 20px;
  cursor: pointer;
  accent-color: #0073aa;
  flex-shrink: 0;
  transition: all 0.2s ease;
  position: relative;
}

.waeg-attribute-checkbox:hover {
  transform: scale(1.1);
}

.waeg-attribute-checkbox:checked {
  animation: checkboxPulse 0.3s ease;
}

@keyframes checkboxPulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.15); }
}

/* Label del término - MEJORADO */
.waeg-attribute-term-label {
  font-size: 14px;
  color: #495057;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  cursor: pointer;
  user-select: none;
  transition: color 0.2s ease;
}

/* Contador de productos */
.waeg-attribute-count {
  font-size: 12px;
  color: #6c757d;
  font-weight: 500;
  margin-left: 8px;
  padding: 2px 8px;
  background: #f0f0f0;
  border-radius: 10px;
  transition: all 0.2s ease;
}

/* Estado activo cuando checkbox está marcado - MEJORADO */
.waeg-attribute-term-item:has(.waeg-attribute-checkbox:checked) {
  background: linear-gradient(135deg, #e7f3ff 0%, #d0e8ff 100%);
  border-color: #0073aa;
  box-shadow: 0 2px 8px rgba(0, 115, 170, 0.15);
  transform: translateX(2px);
}

.waeg-attribute-term-item:has(.waeg-attribute-checkbox:checked) .waeg-attribute-term-label {
  font-weight: 600;
  color: #0073aa;
}

.waeg-attribute-term-item:has(.waeg-attribute-checkbox:checked) .waeg-attribute-count {
  background: #0073aa;
  color: #fff;
}

/* Botón para limpiar atributos */
.waeg-clear-attributes-btn {
  width: 100%;
  padding: 10px 16px;
  background: #dc3545;
  color: #ffffff;
  border: none;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-top: 16px;
}

.waeg-clear-attributes-btn:hover {
  background: #c82333;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(220, 53, 69, 0.3);
}

.waeg-clear-attributes-btn:active {
  transform: translateY(0);
}

/* ================================
   SELECTOR DE ORDENAMIENTO EN SIDEBAR DE FILTROS
   ================================ */
.waeg-sort-filter-section {
  margin-top: 0;
  margin-bottom: 20px;
  padding-top: 0;
  padding-bottom: 20px;
  border-top: none;
  border-bottom: 2px solid #e0e0e0;
}

.waeg-sort-filter-section .waeg-sidebar-title {
  font-size: 14px;
  font-weight: 700;
  color: #333;
  margin-bottom: 12px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.waeg-sort-wrapper-filter {
  width: 100%;
}

.waeg-sort-select-filter {
  width: 100%;
  padding: 12px 36px 12px 14px;
  font-size: 14px;
  font-weight: 500;
  color: #333;
  background: #fff;
  border: 2px solid #ddd;
  border-radius: 8px;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23333' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 12px;
  transition: all 0.3s ease;
}

.waeg-sort-select-filter:hover {
  border-color: #999;
}

.waeg-sort-select-filter:focus {
  outline: none;
  border-color: #333;
  box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.1);
}

/* ================================
   INDICADOR DE FILTROS ACTIVOS
   ================================ */
.waeg-active-filters {
  background: linear-gradient(135deg, #fff8e5 0%, #fff3cd 100%) !important;
  border: 2px solid #ffc107 !important;
  border-radius: 10px !important;
  padding: 12px !important;
  margin-bottom: 16px !important;
  animation: waeg-filter-appear 0.3s ease-out;
}

@keyframes waeg-filter-appear {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.waeg-active-filters-header {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 8px !important;
  margin-bottom: 10px !important;
  padding-bottom: 8px !important;
  border-bottom: 1px solid rgba(255, 193, 7, 0.4) !important;
}

.waeg-active-filters-title {
  display: flex !important;
  align-items: center !important;
  gap: 6px !important;
  font-size: 12px !important;
  font-weight: 700 !important;
  color: #856404 !important;
  text-transform: uppercase !important;
  letter-spacing: 0.5px !important;
}

.waeg-active-filters-title svg {
  color: #d39e00 !important;
}

.waeg-clear-all-filters-btn {
  display: flex !important;
  align-items: center !important;
  gap: 4px !important;
  padding: 4px 10px !important;
  background: #dc3545 !important;
  color: white !important;
  border: none !important;
  border-radius: 6px !important;
  font-size: 11px !important;
  font-weight: 600 !important;
  cursor: pointer !important;
  transition: all 0.2s ease;
}

.waeg-clear-all-filters-btn:hover {
  background: #c82333 !important;
  transform: translateY(-1px);
}

.waeg-clear-all-filters-btn svg {
  flex-shrink: 0;
}

.waeg-active-filters-list {
  display: flex !important;
  flex-wrap: wrap !important;
  gap: 6px !important;
}

/* Cada filtro activo (badge/chip) */
.waeg-active-filter-item {
  display: inline-flex !important;
  align-items: center !important;
  gap: 6px !important;
  padding: 6px 10px !important;
  background: #fff !important;
  border: 1px solid #ddd !important;
  border-radius: 20px !important;
  font-size: 12px !important;
  color: #333 !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1) !important;
  animation: waeg-chip-appear 0.2s ease-out;
}

@keyframes waeg-chip-appear {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.waeg-active-filter-item .waeg-filter-type {
  font-weight: 600 !important;
  color: #666 !important;
  text-transform: capitalize !important;
}

.waeg-active-filter-item .waeg-filter-value {
  font-weight: 700 !important;
  color: #333 !important;
  max-width: 120px !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
}

/* Botón de eliminar filtro individual */
.waeg-remove-filter-btn {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 18px !important;
  height: 18px !important;
  padding: 0 !important;
  background: #f0f0f0 !important;
  border: none !important;
  border-radius: 50% !important;
  color: #666 !important;
  cursor: pointer !important;
  transition: all 0.2s ease;
  flex-shrink: 0 !important;
}

.waeg-remove-filter-btn:hover {
  background: #dc3545 !important;
  color: white !important;
  transform: scale(1.1);
}

.waeg-remove-filter-btn svg {
  width: 10px !important;
  height: 10px !important;
}

/* Estilos específicos por tipo de filtro */
.waeg-active-filter-item[data-filter-type="search"] {
  background: linear-gradient(135deg, #e3f2fd 0%, #bbdefb 100%) !important;
  border-color: #2196f3 !important;
}

.waeg-active-filter-item[data-filter-type="search"] .waeg-filter-type {
  color: #1565c0 !important;
}

.waeg-active-filter-item[data-filter-type="search"] .waeg-filter-value {
  color: #0d47a1 !important;
}

.waeg-active-filter-item[data-filter-type="category"] {
  background: linear-gradient(135deg, #f3e5f5 0%, #e1bee7 100%) !important;
  border-color: #9c27b0 !important;
}

.waeg-active-filter-item[data-filter-type="category"] .waeg-filter-type {
  color: #7b1fa2 !important;
}

.waeg-active-filter-item[data-filter-type="attribute"] {
  background: linear-gradient(135deg, #e8f5e9 0%, #c8e6c9 100%) !important;
  border-color: #4caf50 !important;
}

.waeg-active-filter-item[data-filter-type="attribute"] .waeg-filter-type {
  color: #2e7d32 !important;
}

/* Responsive para filtros activos */
/* ⇒ MOBILE [21]: @media (max-width: 720px) { — ver shop-mobile.css */

/* ================================
   FILTROS TIPO RANGO (SLIDER)
   ================================ */
.waeg-attribute-range {
  padding: 12px;
  transition: all 0.3s ease;
}

.waeg-attribute-filter.collapsed .waeg-attribute-range {
  max-height: 0;
  overflow: hidden;
  padding: 0;
  opacity: 0;
}

.waeg-range-values {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  font-size: 14px;
  font-weight: 600;
  color: #0073aa;
}

.waeg-range-separator {
  color: #6c757d;
  font-weight: 400;
}

.waeg-range-slider-container {
  position: relative;
  height: 6px;
  background: #e0e0e0;
  border-radius: 3px;
  margin: 8px 0;
}

.waeg-range-slider {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 100%;
  -webkit-appearance: none;
  appearance: none;
  height: 6px;
  background: transparent;
  outline: none;
  pointer-events: none;
  z-index: 2;
  left: 0;
  margin: 0 !important;
}

.waeg-range-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 18px;
  height: 18px;
  background: #0073aa;
  border: 2px solid #ffffff;
  border-radius: 50%;
  cursor: pointer;
  pointer-events: all;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
  transition: all 0.2s ease;
}

.waeg-range-slider::-webkit-slider-thumb:hover {
  background: #005a87;
  transform: scale(1.2);
}

.waeg-range-slider::-moz-range-thumb {
  width: 18px;
  height: 18px;
  background: #0073aa;
  border: 2px solid #ffffff;
  border-radius: 50%;
  cursor: pointer;
  pointer-events: all;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
  transition: all 0.2s ease;
}

.waeg-range-slider::-moz-range-thumb:hover {
  background: #005a87;
  transform: scale(1.2);
}

/* Track fill effect */
.waeg-range-slider::-webkit-slider-runnable-track {
  height: 6px;
  background: linear-gradient(to right, 
    #e0e0e0 0%, 
    #e0e0e0 var(--range-min, 0%), 
    #0073aa var(--range-min, 0%), 
    #0073aa var(--range-max, 100%), 
    #e0e0e0 var(--range-max, 100%), 
    #e0e0e0 100%
  );
  border-radius: 3px;
}

.waeg-range-slider::-moz-range-track {
  height: 6px;
  background: #e0e0e0;
  border-radius: 3px;
}

/* Scroll personalizado para términos */
.waeg-attribute-terms::-webkit-scrollbar {
  width: 6px;
}

.waeg-attribute-terms::-webkit-scrollbar-track {
  background: #f1f1f1;
  border-radius: 3px;
}

.waeg-attribute-terms::-webkit-scrollbar-thumb {
  background: #888;
  border-radius: 3px;
}

.waeg-attribute-terms::-webkit-scrollbar-thumb:hover {
  background: #555;
}

/* ======================================
   RESPONSIVE - LAYOUT Y FILTROS
   ====================================== */

/* Tablet y Mobile: Sidebar arriba en lugar de a la izquierda */
/* ⇒ MOBILE [22]: @media (max-width: 1024px) { — ver shop-mobile.css */

/* Mobile */
/* ⇒ MOBILE [23]: @media (max-width: 768px) { — ver shop-mobile.css */

/* ============================================
   BOTÓN Y MODAL DE FILTROS MÓVIL
   ============================================ */

/* Header de categorías con botón de filtros */
.waeg-categories-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

/* Botón de filtros móvil - oculto por defecto */
.waeg-mobile-filters-btn {
  display: none;
  align-items: center;
  gap: 6px;
  background: #e74c3c;
  color: #ffffff;
  border: none;
  border-radius: 20px;
  padding: 8px 16px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(231, 76, 60, 0.3);
}

.waeg-mobile-filters-btn:hover {
  background: #c0392b;
  box-shadow: 0 4px 12px rgba(231, 76, 60, 0.4);
  transform: translateY(-2px);
}

.waeg-mobile-filters-btn svg {
  width: 18px;
  height: 18px;
}

/* Botón de limpiar filtros móvil - oculto por defecto */
.waeg-mobile-clear-filters-btn {
  display: none;
  align-items: center;
  gap: 6px;
  background: #dc3545;
  color: #ffffff;
  border: none;
  border-radius: 20px;
  padding: 8px 16px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(220, 53, 69, 0.3);
}

.waeg-mobile-clear-filters-btn:hover {
  background: #c82333;
  box-shadow: 0 4px 12px rgba(220, 53, 69, 0.4);
  transform: translateY(-2px);
}

.waeg-mobile-clear-filters-btn svg {
  width: 18px;
  height: 18px;
}

/* Modal de filtros móvil */
.waeg-mobile-filters-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 99999;
  display: none;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.waeg-mobile-filters-modal[aria-hidden="false"] {
  display: block;
  opacity: 1;
}

.waeg-mobile-filters-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6);
  cursor: pointer;
}

.waeg-mobile-filters-panel {
  position: absolute;
  right: 0;
  top: 0;
  width: 85%;
  max-width: 400px;
  height: 100%;
  background: #ffffff;
  box-shadow: -4px 0 24px rgba(0, 0, 0, 0.2);
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.3s ease;
  overflow-x: hidden; /* evita desbordamiento horizontal */
}

.waeg-mobile-filters-modal[aria-hidden="false"] .waeg-mobile-filters-panel {
  transform: translateX(0);
}

/* ── Desktop: panel desliza desde la IZQUIERDA (≥ 1024px) ── */
@media (min-width: 1024px) {
  .waeg-mobile-filters-panel {
    left: 0;
    right: auto;
    width: 320px;
    max-width: 320px;
    transform: translateX(-100%);
    box-shadow: 4px 0 24px rgba(0, 0, 0, 0.2);
  }

  .waeg-mobile-filters-modal[aria-hidden="false"] .waeg-mobile-filters-panel {
    transform: translateX(0);
  }

  /* Sidebar clonado dentro del modal: reset de todos los estilos de layout sticky */
  .waeg-mobile-filters-content .waeg-filters-sidebar {
    display: block !important;
    position: static !important;
    left: auto !important;
    top: auto !important;
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    max-height: none !important;
    min-height: 0 !important;
    flex: none !important;
    overflow: visible !important;
    box-shadow: none !important;
    background: transparent !important;
    padding: 0 !important;
    border-radius: 0 !important;
    box-sizing: border-box !important;
  }
}

.waeg-mobile-filters-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px;
  border-bottom: 2px solid #e74c3c;
  background: #f8f8f8;
}

.waeg-mobile-filters-header h2 {
  margin: 0;
  font-size: 20px;
  font-weight: 700;
  color: #333;
  text-transform: uppercase;
}

.waeg-mobile-filters-close {
  background: transparent;
  border: none;
  font-size: 32px;
  color: #333;
  cursor: pointer;
  line-height: 1;
  padding: 0;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.3s ease;
}

.waeg-mobile-filters-close:hover {
  color: #e74c3c;
}

.waeg-mobile-filters-content {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden; /* evita desbordamiento horizontal de filtros */
  padding: 20px;
}

.waeg-mobile-filters-footer {
  padding: 16px 20px;
  border-top: 1px solid #e0e0e0;
  background: #f8f8f8;
  display: flex;
  gap: 12px;
  position: sticky; /* ✅ Sticky footer para que siempre esté visible */
  bottom: 0;
  z-index: 10;
}

.waeg-mobile-filters-footer .waeg-filter-btn {
  flex: 1;
  padding: 14px 20px; /* ✅ Aumentado para mejor tap target */
  font-size: 14px;
  font-weight: 600;
  border: none;
  border-radius: 8px; /* ✅ Bordes más redondeados */
  cursor: pointer;
  transition: all 0.3s ease;
  text-transform: uppercase;
  min-height: 48px; /* ✅ Altura mínima para touch */
}

.waeg-mobile-filters-footer .waeg-clear-btn {
  background: #f0f0f0;
  color: #333;
}

.waeg-mobile-filters-footer .waeg-clear-btn:hover {
  background: #e0e0e0;
}

.waeg-mobile-filters-footer .waeg-apply-btn {
  background: #e74c3c;
  color: #ffffff;
}

.waeg-mobile-filters-footer .waeg-apply-btn:hover {
  background: #c0392b;
}

/* Mostrar botón solo en móvil */
/* ⇒ MOBILE [24]: @media (max-width: 768px) { — ver shop-mobile.css */

/* ======================================
   BOTÓN FLOTANTE DE FILTROS (MÓVIL)
   ====================================== */

.waeg-float-filters-btn {
  position: fixed;
  bottom: 20px;
  left: 20px;
  z-index: 9997; /* Debajo del carrito flotante (9998) */
  display: flex; /* Visible en todas las pantallas (offcanvas universal) */
  align-items: center;
  gap: 8px;
  padding: 14px 20px;
  background: #e74c3c;
  color: #ffffff;
  border: none;
  border-radius: 50px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 4px 16px rgba(231, 76, 60, 0.4);
  transition: all 0.3s ease;
}

.waeg-float-filters-btn:hover {
  background: #c0392b;
  box-shadow: 0 6px 20px rgba(231, 76, 60, 0.5);
  transform: translateY(-2px);
}

.waeg-float-filters-btn:active {
  transform: translateY(0);
}

.waeg-float-filters-btn svg {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
}

.waeg-float-filters-text {
  font-size: 15px;
  line-height: 1;
}

/* Mostrar botón flotante solo en móvil */
/* ⇒ MOBILE [25]: @media (max-width: 768px) { — ver shop-mobile.css */

/* Ajustes para móvil pequeño */
/* ⇒ MOBILE [26]: @media (max-width: 480px) { — ver shop-mobile.css */

/* ======================================
   DIÁLOGO DE COMPARACIÓN DE PRODUCTOS
   ====================================== */

.waeg-compare-dialog {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 99999;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.waeg-compare-dialog.active {
  opacity: 1;
  visibility: visible;
}

.waeg-compare-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  cursor: pointer;
}

.waeg-compare-content {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: white;
  border-radius: 12px;
  padding: 24px;
  max-width: 90%;
  width: 500px;
  max-height: 80vh;
  overflow-y: auto;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

.waeg-compare-content h3 {
  margin: 0 0 20px;
  font-size: 20px;
  font-weight: 600;
  color: #333;
  text-align: center;
}

.waeg-compare-close {
  position: absolute;
  top: 12px;
  right: 12px;
  background: transparent;
  border: none;
  font-size: 24px;
  color: #666;
  cursor: pointer;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: background 0.2s;
}

.waeg-compare-close:hover {
  background: #f0f0f0;
  color: #333;
}

.waeg-compare-products {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  margin-bottom: 20px;
}

.waeg-compare-product {
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  padding: 12px;
  text-align: center;
  background: #f9f9f9;
}

.waeg-compare-product img {
  width: 100%;
  height: 120px;
  object-fit: cover;
  border-radius: 6px;
  margin-bottom: 8px;
}

.waeg-compare-product h4 {
  font-size: 13px;
  margin: 0 0 8px;
  color: #333;
  font-weight: 600;
  line-height: 1.3;
}

.waeg-compare-view {
  display: inline-block;
  padding: 6px 12px;
  background: #8B0000;
  color: white;
  text-decoration: none;
  border-radius: 4px;
  font-size: 12px;
  transition: opacity 0.2s;
}

.waeg-compare-view:hover {
  opacity: 0.9;
}

.waeg-compare-clear {
  width: 100%;
  padding: 12px;
  background: #666;
  color: white;
  border: none;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s;
}

.waeg-compare-clear:hover {
  background: #555;
}

/* ⇒ MOBILE [27]: @media (max-width: 720px) { — ver shop-mobile.css */

/* ========================================
   MODAL DE DETALLES DE PRODUCTO
   ======================================== */

.waeg-product-modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 99999;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.waeg-product-modal.active {
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 1;
}

.waeg-product-modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(4px);
}

.waeg-product-modal-content {
  position: relative;
  background: white;
  border-radius: 16px;
  max-width: 1125px;
  width: 90%;
  max-height: 85vh;
  overflow-y: auto;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  animation: modalSlideIn 0.3s ease-out;
  z-index: 1;
}

@keyframes modalSlideIn {
  from {
    transform: translateY(-50px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.waeg-product-modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 44px;
  height: 44px;
  border: none;
  background: #dc3545;
  color: white;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
  transition: all 0.2s ease;
  font-size: 28px;
  font-weight: bold;
  line-height: 1;
}

.waeg-product-modal-close:hover {
  background: #c82333;
  transform: scale(1.1);
}

.waeg-product-modal-close svg {
  width: 24px;
  height: 24px;
}

.waeg-product-modal-prev,
.waeg-product-modal-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 60px;
  height: 60px;
  border: none;
  background: rgba(0, 0, 0, 0.7);
  color: white;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
  transition: all 0.3s ease;
  backdrop-filter: blur(4px);
}

.waeg-product-modal-prev {
  left: 16px;
}

.waeg-product-modal-next {
  right: 16px;
}

.waeg-product-modal-prev:hover,
.waeg-product-modal-next:hover {
  background: rgba(0, 0, 0, 0.9);
  transform: translateY(-50%) scale(1.1);
}

.waeg-product-modal-prev svg,
.waeg-product-modal-next svg {
  width: 32px;
  height: 32px;
}

.waeg-product-modal-body {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 30px;
  padding: 30px;
}

/* Estado loading del modal */
.waeg-product-modal.loading .waeg-product-modal-body {
  position: relative;
  min-height: 400px;
}

.waeg-product-modal.loading .waeg-product-modal-body::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 50px;
  height: 50px;
  border: 4px solid #f3f3f3;
  border-top: 4px solid #333;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  z-index: 10;
}

.waeg-product-modal.loading .waeg-product-modal-body::after {
  content: 'Cargando...';
  position: absolute;
  top: calc(50% + 40px);
  left: 50%;
  transform: translateX(-50%);
  font-size: 14px;
  color: #666;
  z-index: 10;
}

.waeg-product-modal.loading .waeg-product-modal-image,
.waeg-product-modal.loading .waeg-product-modal-info {
  opacity: 0.3;
}

@keyframes spin {
  0% { transform: translate(-50%, -50%) rotate(0deg); }
  100% { transform: translate(-50%, -50%) rotate(360deg); }
}

.waeg-product-modal-image {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  background: #f8f9fa;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 300px;
}

.waeg-product-modal-image img {
  width: 100%;
  height: auto;
  object-fit: contain;
  max-height: 500px;
}

.waeg-product-modal-info {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.waeg-product-modal-info h2 {
  margin: 0;
  font-size: 28px;
  color: #333;
  font-weight: 700;
  line-height: 1.3;
}

.waeg-modal-category,
.waeg-modal-sku {
  font-size: 14px;
  color: #666;
  margin: -8px 0 0 0;
}

.waeg-modal-price {
  font-size: 32px;
  font-weight: 700;
  color: #27ae60;
  margin: 8px 0;
}

.waeg-modal-price del {
  font-size: 22px;
  color: #999;
  margin-right: 8px;
}

.waeg-modal-stock {
  padding: 8px 16px;
  border-radius: 6px;
  font-weight: 600;
  font-size: 14px;
  display: inline-block;
  width: fit-content;
}

.waeg-modal-stock .in-stock {
  background: #d4edda;
  color: #155724;
}

.waeg-modal-stock .out-of-stock {
  background: #f8d7da;
  color: #721c24;
}

.waeg-modal-stock .on-backorder {
  background: #fff3cd;
  color: #856404;
}

.waeg-modal-description {
  font-size: 15px;
  line-height: 1.6;
  color: #555;
  padding: 12px 0;
  border-top: 1px solid #e0e0e0;
  border-bottom: 1px solid #e0e0e0;
}

.waeg-modal-attributes {
  margin-top: 8px;
}

.waeg-modal-attributes h4 {
  font-size: 16px;
  font-weight: 700;
  color: #333;
  margin: 0 0 12px 0;
}

.waeg-modal-attributes ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.waeg-modal-attributes li {
  padding: 8px 0;
  font-size: 14px;
  color: #555;
  border-bottom: 1px solid #f0f0f0;
}

.waeg-modal-attributes li:last-child {
  border-bottom: none;
}

.waeg-modal-attributes li strong {
  color: #333;
  font-weight: 600;
}

.waeg-modal-actions {
  margin-top: auto;
  padding-top: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.waeg-modal-cart-button,
.waeg-modal-whatsapp-button,
.waeg-modal-view-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 16px;
  transition: all 0.3s ease;
  text-align: center;
  text-decoration: none;
  border: none;
  cursor: pointer;
}

.waeg-modal-cart-button {
  background: #333;
  color: white;
}

.waeg-modal-cart-button:hover {
  background: #000;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.waeg-modal-cart-button.loading {
  opacity: 0.7;
  cursor: wait;
}

.waeg-modal-cart-button.added {
  background: #28a745;
}

.waeg-modal-whatsapp-button {
  background: #25D366;
  color: white;
}

.waeg-modal-whatsapp-button:hover {
  background: #1fa855;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(37, 211, 102, 0.3);
}

.waeg-modal-view-button {
  background: transparent;
  color: #333;
  border: 2px solid #333;
}

.waeg-modal-view-button:hover {
  background: #333;
  color: white;
  transform: translateY(-2px);
}

.waeg-modal-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 300px;
  gap: 16px;
  grid-column: 1 / -1;
}

.waeg-spinner {
  width: 50px;
  height: 50px;
  border: 4px solid #f3f3f3;
  border-top: 4px solid #333;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.waeg-modal-loading p {
  font-size: 16px;
  color: #666;
  margin: 0;
}

.waeg-modal-error {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 300px;
  grid-column: 1 / -1;
}

.waeg-modal-error p {
  font-size: 16px;
  color: #e74c3c;
  font-weight: 600;
}

/* Responsive para modal */
/* ⇒ MOBILE [28]: @media (max-width: 768px) { — ver shop-mobile.css */

/* ======================================
   PAGINACIÓN NUMÉRICA
   ====================================== */

.waeg-pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 16px 0 20px;
  padding: 12px 0;
  width: 100%;
}

.waeg-pagination-wrapper {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: center;
}

/* Botones de anterior/siguiente */
.waeg-pagination-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 16px;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 8px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 500;
  color: #333;
  transition: all 0.25s ease;
  white-space: nowrap;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.waeg-pagination-btn:hover:not([disabled]) {
  background: #f8f9fa;
  border-color: #cc0000;
  color: #cc0000;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(204, 0, 0, 0.15);
}

.waeg-pagination-btn:active:not([disabled]) {
  transform: translateY(0);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.waeg-pagination-btn[disabled] {
  opacity: 0.5;
  cursor: not-allowed;
  background: #f5f5f5;
}

.waeg-pagination-arrow {
  font-size: 16px;
  font-weight: 700;
  transition: transform 0.25s ease;
}

.waeg-pagination-btn:hover:not([disabled]) .waeg-pagination-arrow {
  transform: scale(1.2);
}

/* Contenedor de números */
.waeg-pagination-numbers {
  display: flex;
  align-items: center;
  gap: 4px;
}

/* Botones de número de página */
.waeg-pagination-number {
  min-width: 40px;
  height: 40px;
  padding: 8px 12px;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 8px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 500;
  color: #333;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
  position: relative;
  overflow: hidden;
}

.waeg-pagination-number::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(204, 0, 0, 0.1) 0%, rgba(204, 0, 0, 0.05) 100%);
  opacity: 0;
  transition: opacity 0.25s ease;
}

.waeg-pagination-number:hover {
  background: #f8f9fa;
  border-color: #cc0000;
  color: #cc0000;
  transform: translateY(-2px) scale(1.05);
  box-shadow: 0 4px 8px rgba(204, 0, 0, 0.2);
}

.waeg-pagination-number:hover::before {
  opacity: 1;
}

/* Página activa */
.waeg-pagination-number.waeg-pagination-active {
  background: linear-gradient(135deg, #cc0000 0%, #990000 100%);
  border-color: #cc0000;
  color: #fff;
  font-weight: 700;
  cursor: default;
  box-shadow: 0 4px 12px rgba(204, 0, 0, 0.3);
  transform: translateY(-2px) scale(1.08);
}

.waeg-pagination-number.waeg-pagination-active::before {
  opacity: 0;
}

.waeg-pagination-number.waeg-pagination-active:hover {
  background: linear-gradient(135deg, #cc0000 0%, #990000 100%);
  border-color: #cc0000;
  color: #fff;
  transform: translateY(-2px) scale(1.08);
}

/* Puntos suspensivos */
.waeg-pagination-ellipsis {
  padding: 8px 4px;
  color: #999;
  font-size: 14px;
  user-select: none;
}

/* Responsive móvil */
/* ⇒ MOBILE [29]: @media (max-width: 768px) { — ver shop-mobile.css */

/* ⇒ MOBILE [30]: @media (max-width: 480px) { — ver shop-mobile.css */

/* ========================================
   SISTEMA RESPONSIVE OPTIMIZADO
   ======================================== */

/* DESKTOP GRANDE (1400px+) - Pantallas grandes y monitores */
@media (min-width: 1400px) {
  .waeg-shop-wrapper {
    max-width: 1680px !important;
    padding: 0 30px !important;
  }
  
  .waeg-shop-wrapper .waeg-filters-sidebar {
    width: 340px;
    max-width: 340px;
    flex: 0 0 340px;
  }
  
  #waeg-grid.waeg-grid,
  #waeg-grid.waeg-grid .products,
  #waeg-grid.waeg-grid ul.products {
    display: grid !important;
    grid-template-columns: repeat(4, 321px) !important;
    gap: 8px !important;
    justify-content: center !important;
    align-items: stretch !important;
  }
  
  /* Asegurar que todas las cards tengan el mismo tamaño */
  #waeg-grid.waeg-grid .product,
  #waeg-grid.waeg-grid li.product,
  #waeg-grid.waeg-grid .type-product {
    width: 321px !important;
    max-width: 321px !important;
    min-width: 321px !important;
    height: 492px !important;
    min-height: 492px !important;
    max-height: 492px !important;
  }
  
  .waeg-shop-wrapper .waeg-category-pill {
    font-size: 15px !important;
    padding: 10px 20px !important;
  }
}

/* DESKTOP (1024px - 1399px) - Laptops y pantallas medianas */
/* Nota: el rango 1281-1399px (1368x768) se refina en el bloque siguiente */
@media (min-width: 1024px) and (max-width: 1280px) {
  .waeg-shop-wrapper {
    max-width: 1400px !important;
    padding: 0 24px !important;
  }
  
  .waeg-shop-wrapper .waeg-filters-sidebar {
    width: 300px;
    max-width: 300px;
    flex: 0 0 300px;
  }
  
  #waeg-grid.waeg-grid,
  #waeg-grid.waeg-grid .products,
  #waeg-grid.waeg-grid ul.products {
    display: grid !important;
    grid-template-columns: repeat(3, 321px) !important;
    gap: 8px !important;
    justify-content: center !important;
    align-items: stretch !important;
  }
  
  /* Asegurar que todas las cards tengan el mismo tamaño */
  #waeg-grid.waeg-grid .product,
  #waeg-grid.waeg-grid li.product,
  #waeg-grid.waeg-grid .type-product {
    width: 321px !important;
    max-width: 321px !important;
    min-width: 321px !important;
    height: 492px !important;
    min-height: 492px !important;
    max-height: 492px !important;
  }
}

/* ======================================
   RESOLUCIÓN 1368x768 - LAPTOPS HD
   Ajuste específico para pantallas 1281-1399px de ancho
   ====================================== */
@media (min-width: 1281px) and (max-width: 1399px) {
  /* Sidebar más compacto para liberar espacio horizontal */
  .waeg-shop-wrapper .waeg-filters-sidebar {
    width: 210px !important;
    max-width: 210px !important;
    flex: 0 0 210px !important;
    padding: 20px 14px !important;
  }

  /* Wrapper con padding reducido */
  .waeg-shop-wrapper {
    padding: 0 16px !important;
    gap: 20px !important;
  }

  /* Grid fluido: 3 columnas que se adaptan al espacio disponible */
  #waeg-grid.waeg-grid,
  #waeg-grid.waeg-grid .products,
  #waeg-grid.waeg-grid ul.products {
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 10px !important;
    justify-content: stretch !important;
  }

  /* Cards: ancho fluido, altura reducida para 768px de alto */
  #waeg-grid.waeg-grid .product,
  #waeg-grid.waeg-grid li.product,
  #waeg-grid.waeg-grid .type-product {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    height: 450px !important;
    min-height: 450px !important;
    max-height: 450px !important;
  }

  /* Imagen proporcional a la nueva altura de card */
  #waeg-grid.waeg-grid .product a img,
  #waeg-grid.waeg-grid .product img,
  #waeg-grid.waeg-grid .product .attachment-woocommerce_thumbnail {
    height: 260px !important;
    max-height: 260px !important;
  }

  /* Título más compacto */
  #waeg-grid.waeg-grid .product h2,
  #waeg-grid.waeg-grid .product .woocommerce-loop-product__title {
    font-size: 13px !important;
    line-height: 1.3 !important;
    -webkit-line-clamp: 2 !important;
  }

  /* Precio más compacto */
  #waeg-grid.waeg-grid .product .price {
    font-size: 16px !important;
    margin: 4px 0 !important;
    padding: 4px !important;
    min-height: 30px !important;
  }

  /* Sidebar: reducir fuentes para que quepa más contenido */
  .waeg-filters-sidebar .waeg-sidebar-title {
    font-size: 12px !important;
  }

  .waeg-filters-sidebar .waeg-filter-attribute-item label,
  .waeg-filters-sidebar .waeg-category-pill,
  .waeg-filters-sidebar .waeg-subcategory-pill {
    font-size: 11px !important;
    padding: 5px 10px !important;
  }

  /* Sidebar sticky: altura exacta para 768px de viewport */
  .waeg-filters-sidebar {
    max-height: calc(100vh - 80px) !important;
  }

  /* 4 columnas en 1368px: usar 3 columnas en su lugar */
  .waeg-columns-4 #waeg-grid.waeg-grid,
  .waeg-columns-4 #waeg-grid.waeg-grid .products,
  .waeg-columns-4 #waeg-grid.waeg-grid ul.products {
    grid-template-columns: repeat(3, 1fr) !important;
  }

  .waeg-columns-4 #waeg-grid.waeg-grid .product,
  .waeg-columns-4 #waeg-grid.waeg-grid li.product,
  .waeg-columns-4 #waeg-grid.waeg-grid .type-product {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
  }
}

/* TABLET HORIZONTAL (768px - 1023px) */
@media (min-width: 768px) and (max-width: 1023px) {
  .waeg-shop-wrapper {
    flex-direction: column !important;
    padding: 0 20px !important;
    gap: 20px !important;
  }
  
  /* Filtros arriba en tablet */
  .waeg-shop-wrapper .waeg-filters-sidebar {
    position: relative !important;
    width: 100% !important;
    max-width: 100% !important;
    flex: 1 1 auto !important;
    max-height: none !important;
    padding: 20px !important;
    order: 1 !important;
  }
  
  .waeg-shop-wrapper .waeg-content-wrapper {
    order: 2 !important;
  }
  
  /* Grid 2 columnas en tablet */
  #waeg-grid.waeg-grid,
  #waeg-grid.waeg-grid .products,
  #waeg-grid.waeg-grid ul.products {
    display: grid !important;
    grid-template-columns: repeat(2, 321px) !important;
    gap: 8px !important;
    justify-content: center !important;
    align-items: stretch !important;
  }
  
  /* Asegurar que todas las cards tengan el mismo tamaño */
  #waeg-grid.waeg-grid .product,
  #waeg-grid.waeg-grid li.product,
  #waeg-grid.waeg-grid .type-product {
    width: 321px !important;
    max-width: 321px !important;
    min-width: 321px !important;
    height: 492px !important;
    min-height: 492px !important;
    max-height: 492px !important;
  }

  /* 5 columnas en tablet: 2 columnas de 227px */
  .waeg-columns-5 #waeg-grid.waeg-grid,
  .waeg-columns-5 #waeg-grid.waeg-grid .products,
  .waeg-columns-5 #waeg-grid.waeg-grid ul.products {
    grid-template-columns: repeat(2, 227px) !important;
    justify-content: center !important;
  }

  .waeg-columns-5 #waeg-grid.waeg-grid .product,
  .waeg-columns-5 #waeg-grid.waeg-grid li.product,
  .waeg-columns-5 #waeg-grid.waeg-grid .type-product {
    width: 227px !important;
    max-width: 227px !important;
    min-width: 227px !important;
    height: 332px !important;
    min-height: 332px !important;
    max-height: 332px !important;
  }
  
  /* Categorías más compactas */
  .waeg-shop-wrapper .waeg-category-pill {
    font-size: 13px !important;
    padding: 8px 16px !important;
  }
  
  .waeg-controls-top {
    flex-wrap: wrap;
  }
  
  .waeg-search-wrapper {
    width: 100%;
    order: 1;
  }
  
  .waeg-sort-wrapper,
  .waeg-perpage-wrapper {
    flex: 1;
    min-width: 200px;
  }
}

/* MOBILE (menos de 768px) */
/* ⇒ MOBILE [31]: @media (max-width: 767px) { — ver shop-mobile.css */

/* MOBILE PEQUEÑO (menos de 480px) */
/* ⇒ MOBILE [32]: @media (max-width: 479px) { — ver shop-mobile.css */

/* ORIENTACIÓN LANDSCAPE EN MOBILE */
/* ⇒ MOBILE [33]: @media (max-width: 767px) and (orientation: landscape) { — ver shop-mobile.css */

/* PRINT (para imprimir) */
@media print {
  .waeg-filters-sidebar,
  .waeg-pagination,
  .waeg-mobile-filters-btn,
  .waeg-mobile-clear-filters-btn,
  .waeg-controls-top {
    display: none !important;
  }
  
  #waeg-grid {
    grid-template-columns: repeat(2, 1fr) !important;
  }
}

/* =====================================================
   CARRITO FLOTANTE
   ===================================================== */
.waeg-cart-float {
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 60px;
  height: 60px;
  background: #0071dc;
  color: white;
  border: none;
  border-radius: 50%;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  cursor: pointer;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  transition: all 0.3s ease;
}

/* ⇒ MOBILE [34]: @media (max-width: 768px) { — ver shop-mobile.css */

.waeg-cart-float:hover {
  transform: scale(1.1);
  background: #005bb5;
}

#waeg-cart-count {
  position: absolute;
  top: -5px;
  right: -5px;
  background: #dc3545;
  color: white;
  border-radius: 50%;
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: bold;
}

/* Offcanvas del carrito */
.waeg-cart-offcanvas {
  position: fixed;
  top: 0;
  right: -100%;
  width: 400px;
  max-width: 90%;
  height: 100%;
  z-index: 10000;
  transition: right 0.3s ease;
}

.waeg-cart-offcanvas.active {
  right: 0;
}

.waeg-cart-offcanvas-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease;
  z-index: -1;
}

.waeg-cart-offcanvas.active .waeg-cart-offcanvas-overlay {
  opacity: 1;
  visibility: visible;
}

.waeg-cart-offcanvas-panel {
  position: absolute;
  top: 0;
  right: 0;
  width: 100%;
  height: 100%;
  background: white;
  box-shadow: -4px 0 12px rgba(0, 0, 0, 0.2);
  display: flex;
  flex-direction: column;
}

.waeg-cart-offcanvas-close {
  position: absolute;
  top: 15px;
  right: 15px;
  background: transparent;
  border: none;
  font-size: 32px;
  cursor: pointer;
  color: #333;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.2s ease;
}

.waeg-cart-offcanvas-close:hover {
  color: #dc3545;
}

.waeg-cart-offcanvas h2 {
  margin: 0;
  padding: 20px;
  border-bottom: 1px solid #eee;
  font-size: 20px;
}

#waeg-cart-items {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
}

/* Estilos para los items del carrito */
.waeg-cart-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.waeg-cart-item {
  display: flex;
  gap: 12px;
  padding: 15px 0;
  border-bottom: 1px solid #eee;
  position: relative;
}

.waeg-cart-remove {
  position: absolute;
  top: 10px;
  right: 0;
  background: #dc3545;
  color: white;
  border: none;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 18px;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease;
}

.waeg-cart-remove:hover {
  background: #c82333;
}

.waeg-cart-thumb {
  width: 60px;
  height: 60px;
  object-fit: cover;
  border-radius: 4px;
}

.waeg-cart-item-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.waeg-cart-item-name {
  font-weight: 500;
  font-size: 14px;
  line-height: 1.3;
}

.waeg-cart-item-quantity {
  display: flex;
  align-items: center;
  gap: 8px;
}

.waeg-qty-minus,
.waeg-qty-plus {
  width: 28px;
  height: 28px;
  border: 1px solid #ddd;
  background: white;
  cursor: pointer;
  font-size: 16px;
  border-radius: 4px;
  transition: all 0.2s ease;
}

.waeg-qty-minus:hover,
.waeg-qty-plus:hover {
  background: #f5f5f5;
  border-color: #999;
}

.waeg-qty-input {
  width: 50px;
  height: 28px;
  border: 1px solid #ddd;
  text-align: center;
  font-size: 14px;
  border-radius: 4px;
}

.waeg-cart-item-prices {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 14px;
}

.waeg-cart-item-price-unit {
  color: #666;
  font-size: 12px;
}

.waeg-cart-item-price-subtotal {
  font-weight: bold;
  color: #0071dc;
}

.waeg-cart-totals {
  padding: 20px;
  border-top: 2px solid #eee;
  background: #f9f9f9;
}

.waeg-cart-total-row {
  display: flex;
  justify-content: space-between;
  padding: 8px 0;
}

.waeg-cart-total-final {
  border-top: 1px solid #ddd;
  margin-top: 8px;
  padding-top: 12px;
  font-size: 18px;
}

.waeg-cart-actions {
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.waeg-cart-btn {
  display: block;
  padding: 12px 20px;
  text-align: center;
  text-decoration: none;
  border-radius: 4px;
  font-weight: 500;
  transition: all 0.2s ease;
}

.waeg-cart-goto {
  background: white;
  color: #0071dc;
  border: 2px solid #0071dc;
}

.waeg-cart-goto:hover {
  background: #f0f8ff;
}

.waeg-cart-checkout {
  background: #0071dc;
  color: white;
  border: 2px solid #0071dc;
}

.waeg-cart-checkout:hover {
  background: #005bb5;
  border-color: #005bb5;
}

.waeg-cart-empty {
  text-align: center;
  padding: 60px 20px;
  color: #999;
  font-size: 16px;
  line-height: 1.6;
}

.waeg-cart-empty::first-line {
  font-size: 48px;
}

/* Fin de estilos del carrito flotante */
/* ======================================
   MODAL DE RECORDATORIO DE INACTIVIDAD
   ====================================== */
.waeg-inactivity-modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 100000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.waeg-inactivity-modal.active {
  opacity: 1;
  visibility: visible;
}

.waeg-inactivity-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(4px);
  animation: waeg-fadeIn 0.3s ease;
}

.waeg-inactivity-content {
  position: relative;
  background: white;
  max-width: 500px;
  width: 90%;
  border-radius: 24px;
  padding: 48px 40px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  text-align: center;
  animation: slideUp 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 1;
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(40px) scale(0.95);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.waeg-inactivity-icon {
  color: #0071dc;
  margin-bottom: 24px;
  animation: iconPulse 2s ease-in-out infinite;
}

@keyframes iconPulse {
  0%, 100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.05);
  }
}

.waeg-inactivity-icon svg {
  width: 64px;
  height: 64px;
  display: inline-block;
}

.waeg-inactivity-title {
  font-size: 28px;
  font-weight: 700;
  color: #2c3e50;
  margin: 0 0 16px 0;
  line-height: 1.3;
}

.waeg-inactivity-message {
  font-size: 16px;
  color: #666;
  margin: 0 0 32px 0;
  line-height: 1.6;
}

.waeg-inactivity-actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 0;
}

.waeg-inactivity-btn {
  padding: 16px 32px;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
}

.waeg-inactivity-btn svg {
  width: 20px;
  height: 20px;
}

.waeg-inactivity-btn.primary {
  background: linear-gradient(135deg, #0071dc 0%, #005bb5 100%);
  color: white;
  box-shadow: 0 4px 16px rgba(0, 113, 220, 0.3);
}

.waeg-inactivity-btn.primary:hover {
  background: linear-gradient(135deg, #005bb5 0%, #004a94 100%);
  box-shadow: 0 6px 20px rgba(0, 113, 220, 0.4);
  transform: translateY(-2px);
}

.waeg-inactivity-btn.primary:active {
  transform: translateY(0);
}

.waeg-inactivity-btn.secondary {
  background: #f8f9fa;
  color: #666;
  border: 2px solid #e0e0e0;
}

.waeg-inactivity-btn.secondary:hover {
  background: #fff;
  border-color: #999;
  color: #333;
}

.waeg-inactivity-close {
  position: absolute;
  top: 16px;
  right: 16px;
  background: rgba(0, 0, 0, 0.1);
  border: none;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 24px;
  line-height: 1;
  color: #666;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.waeg-inactivity-close:hover {
  background: rgba(0, 0, 0, 0.15);
  color: #333;
  transform: rotate(90deg);
}

/* Responsive para móviles */
/* ⇒ MOBILE [35]: @media (max-width: 640px) { — ver shop-mobile.css */
/* Agrega el boton de agregar al carrito a las cards de producto color del boton burdeo, en movil se tienen que ver de a dos productos y los filtros tienen que desplegarse */
.waeg-btn-cart {
    background-color: #800020 !important;
}

/* ⇒ MOBILE [36]: @media (max-width: 767px) { — ver shop-mobile.css */

.waeg-filters-sidebar .waeg-sidebar-section .waeg-sidebar-title {
    cursor: pointer;
}

/* Modal: colapsable por defecto — el toggle JS maneja .collapsed */
.waeg-mobile-filters-content .waeg-attribute-filter {
    max-height: none !important;
    overflow: visible !important;
}
.waeg-mobile-filters-content .waeg-attribute-filter .waeg-attribute-name {
    cursor: pointer;
}
.waeg-mobile-filters-content .waeg-attribute-filter .waeg-attribute-toggle {
    display: inline-block !important;
}
/* Cuando el filtro NO está colapsado, términos visibles */
.waeg-mobile-filters-content .waeg-attribute-filter:not(.collapsed) .waeg-attribute-terms {
    display: flex !important;
    flex-wrap: wrap !important;
    max-height: none !important;
    overflow: visible !important;
    opacity: 1 !important;
    padding: 6px 0 !important;
}
/* Cuando el filtro SÍ está colapsado, términos ocultos */
.waeg-mobile-filters-content .waeg-attribute-filter.collapsed .waeg-attribute-terms {
    max-height: 0 !important;
    overflow: hidden !important;
    opacity: 0 !important;
    padding: 0 !important;
}
.waeg-mobile-filters-content .waeg-attribute-filter .waeg-attribute-term-item {
    display: flex !important;
}

