/* =========================================================
   404 / PRODUCTO NO ENCONTRADO
   ========================================================= */

.nx-404 {
  width: 100%;
  background-color: var(--nx-surface-2);
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* --- Mensaje y Hero --- */
.nx-404__hero {
  max-width: 1200px;
  width: 100%;
  /* Reduje el padding inferior de 20px a 0px para optimizar el espacio (Whitespace) */
  padding: 60px 20px 0px 20px;
  text-align: center;
  box-sizing: border-box;
}

/* Contenedor flex para alinear el ícono y el título */
.nx-404__header-title {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  margin-bottom: var(--nx-space-sm);
}

.nx-404__icon {
  color: var(--nx-color-text-darks2);
}

/* Jerarquía visual: Fuente más grande y negrita (800) */
.nx-404__hero h1 {
  font-size: calc(var(--nx-font-g) + 4px); 
  color: var(--nx-text-dark);
  margin: 0; 
  font-weight: 800;
}

.nx-404__hero p {
  font-size: var(--nx-font-m);
  color: var(--nx-color-text-darks2);
  margin-bottom: var(--nx-space-md);
  margin-top: 8px;
}

/* --- Buscador adaptado al 404 --- */
.nx-404__search {
  /* Reduje el margin bottom de 30px a 15px para acercarlo a las categorías */
  margin: 30px auto 15px auto;
  max-width: 500px; 
  width: 100%;
}

.nx-404__search .nx-header-desktop-search {
  display: flex;
  align-items: center;
  background-color: var(--nx-surface-1);
  border: 2px solid var(--nx-color-muted);
  border-radius: var(--nx-radius-md);
  overflow: hidden;
  transition: all 0.3s ease;
}

.nx-404__search .nx-header-desktop-search:focus-within {
  border-color: var(--nx-color-button-bd);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.nx-404__search input[type="search"] {
  flex: 1;
  width: 100%;
  padding: 14px 20px;
  font-size: var(--nx-font-m);
  color: var(--nx-text-dark);
  background-color: transparent;
  border: none;
  outline: none;
}

.nx-404__search input[type="search"]::placeholder {
  color: var(--nx-color-text-textcomment);
}

.nx-404__search .nx-search-btn {
  background: transparent;
  border: none;
  padding: 0 16px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.nx-404__search .nx-search-btn:hover svg {
  stroke: var(--nx-color-button-bd);
  transition: stroke 0.2s ease;
}

/* --- Contenedor de Componentes --- */
.nx-404__components {
  width: 100%;
}

/* --- Estilo y Hover para las Categorías --- */
.nx-category-card {
  transition: all 0.2s ease-in-out;
  border-radius: 8px; /* Ajusta a tu variable de border-radius si la tienes */
  text-decoration: none;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: #ffffff;
}

.nx-category-card:hover {
  transform: translateY(-3px); /* Levanta sutilmente el botón */
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.08); /* Añade una sombra suave */
  border-color: var(--nx-color-button-bd); /* Opcional: ilumina el borde */
}

/* =========================================================
   ESTILOS PARA EL SLIDER DENTRO DEL 404 (SIN TOCAR HTML)
   ========================================================= */

/* 1. Evitar que el slider colapse por el align-items: center del padre */
.nx-404 .nx-product-slider {
  width: 100%;
  padding: 0 20px;
  box-sizing: border-box;
  margin-top: 40px; /* Separación del hero/buscador */
  margin-bottom: 40px;
}

/* 2. Alinear correctamente el título y el enlace "Ver todo" */
.nx-404 .nx-product-slider__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: var(--nx-space-md, 24px);
  width: 100%;
}

/* 3. Estilizar el título de los resultados */
.nx-404 .nx-product-slider__title {
  font-size: var(--nx-font-l, 20px); /* Usa tu variable o un fallback de 20px */
  color: var(--nx-text-dark);
  font-weight: 700;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 12px;
}

/* 4. Estilizar el enlace "Ver todo ->" */
.nx-404 .nx-product-slider__view-all {
  font-size: var(--nx-font-m, 16px);
  color: var(--nx-color-button-bd, #0066cc); /* Ajusta al color primario de tu tema */
  text-decoration: none;
  font-weight: 600;
  transition: color 0.2s ease, transform 0.2s ease;
}

.nx-404 .nx-product-slider__view-all:hover {
  text-decoration: underline;
  transform: translateX(4px); /* Pequeño efecto de movimiento hacia la flecha */
}

/* 5. Asegurar que los puntos del slider (si están activos) se ubiquen bien */
.nx-404 .nx-product-slider__dots {
  display: flex;
  gap: 8px;
  justify-content: center;
  margin-top: 16px;
  width: 100%;
}