/* ============================================================
   UIXTRA STORE.CSS — PARTE 1/2
   BASE ORIGINAL + NUEVO SIDEBAR (ESTRUCTURA Y CHECKBOX)
   Todo está documentado para que SEPAS EXACTAMENTE qué es cada cosa.
============================================================ */


/* ============================================================
   1) GRID PRINCIPAL DE PRODUCTOS (TU CSS ORIGINAL)
============================================================ */

#products-grid {
  display: grid;
  gap: 2rem;
  transition: 0.3s all ease;
}

/* Tarjeta de producto */
.product-card {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 20px;
  padding: 1.5rem;
  backdrop-filter: blur(20px);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  cursor: pointer;
}

.product-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(0, 255, 255, 0.15);
}

/* Imagen */
.product-image {
  width: 100%;
  height: 180px;
  border-radius: 16px;
  overflow: hidden;
  position: relative;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.product-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: 0.25s ease;
}

.product-card:hover img {
  opacity: 0.9;
}

/* Badge */
.badge {
  position: absolute;
  top: 12px;
  left: 12px;
  padding: 6px 10px;
  border-radius: 10px;
  font-size: 11px;
  font-weight: 600;
  color: #000;
  background: rgba(52, 225, 193, 0.9);
  box-shadow: 0 0 20px rgba(52, 225, 193, 0.3);
  display: none;
}

/* Título */
.product-title {
  margin-top: 1rem;
  font-size: 1rem;
  font-weight: 600;
  color: #e2e8f0;
  line-height: 1.4;
}

/* Categoría */
.product-category {
  margin-top: 4px;
  font-size: 0.85rem;
  color: #94a3b8;
}

/* Precio */
.product-price {
  margin-top: 0.6rem;
  font-size: 1.1rem;
  font-weight: 700;
  color: #38f5ff;
}

/* Botón “Buy” */
.buy-btn {
  display: inline-block;
  margin-top: 0.9rem;
  padding: 8px 14px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #e2e8f0;
  font-size: 0.85rem;
  font-weight: 500;
  transition: 0.25s ease;
  text-decoration: none;
}

.buy-btn:hover {
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
}

/* SKELETON (cargando) */
.product-skeleton {
  animation: pulse 1.5s infinite ease-in-out;
}

@keyframes pulse {
  0% { opacity: 0.45; }
  50% { opacity: 1; }
  100% { opacity: 0.45; }
}




/* ============================================================
   2) NUEVO SIDEBAR DE FILTROS (BASE)
   SUPER IMPORTANTE → esto reemplaza SOLO el filtro visual,
   NO afecta el JS (eso se ajustará en su archivo).
============================================================ */

/* Contenedor del sidebar */
#uixtra-sidebar-filters {
  /* Ya tiene estilos en el HTML (bg-white/5, blur, etc.) */
  border-radius: 20px;
  padding: 1.5rem;
}

/* Título del bloque */
#uixtra-sidebar-filters h3 {
  font-size: 1.1rem;
  font-weight: 600;
  color: #e2e8f0;
}

/* Botón que abre/cierra cada filtro (flechita) */
#uixtra-sidebar-filters button {
  color: #cbd5e1;
  cursor: pointer;
  transition: 0.2s ease;
}

#uixtra-sidebar-filters button:hover {
  color: #fff;
}

/* ============================================================
   CHECKBOX — DISEÑO PREMIUM UIXTRA
============================================================ */

.uixtra-check {
  appearance: none;
  width: 17px;
  height: 17px;
  border-radius: 5px;
  border: 2px solid rgba(255, 255, 255, 0.25);
  background: rgba(255, 255, 255, 0.02);
  cursor: pointer;
  position: relative;
  transition: all 0.2s ease;
}

/* Hover suave */
.uixtra-check:hover {
  border-color: rgba(0, 255, 255, 0.6);
}

/* Estado activado (check real UIXTRA) */
.uixtra-check:checked {
  border-color: #14f1e1;
  background: #14f1e1;
  box-shadow: 0 0 10px #14f1e1aa;
}

/* Icono de check (usando ::after) */
.uixtra-check:checked::after {
  content: "✔";
  font-size: 11px;
  color: #000;
  position: absolute;
  top: -1px;
  left: 3px;
  font-weight: 700;
}

/* Labels internos del sidebar */
#uixtra-sidebar-filters label {
  color: #d1d5db;
  cursor: pointer;
  transition: 0.2s ease;
}

#uixtra-sidebar-filters label:hover {
  color: #fff;
}


/* ============================================================
   3) PAGINATION (TU CSS ORIGINAL)
============================================================ */

#store-pagination {
  display: flex;
  gap: 0.5rem;
}

.store-page {
  padding: 0.45rem 1rem;
  border-radius: 10px;
  font-size: 0.9rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #cbd5e1;
  transition: 0.25s ease;
}

.store-page:hover {
  background: rgba(255, 255, 255, 0.15);
}

.store-prev,
.store-next {
  padding: 0.45rem 1.1rem;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #cbd5e1;
  transition: 0.25s ease;
}

.store-prev:hover,
.store-next:hover {
  background: rgba(255, 255, 255, 0.15);
}

.store-prev:disabled,
.store-next:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* No products */
#no-products p {
  color: #94a3b8;
  font-size: 1.1rem;
}


/* ============================================================
   4) FIX DEL CANVAS PARA EL SPINNER AZUL (TU FIX REAL)
============================================================ */

#uixtra-hero-stars {
  appearance: none !important;
}

#uixtra-hero-stars::before,
#uixtra-hero-stars::after {
  display: none !important;
  content: none !important;
}


/* ============================================================
   >>> FIN DE STORE.CSS PARTE 1 <<<
   La parte 2 contiene:
   - Estilos avanzados del sidebar (accordion real)
   - Versión responsive (mobile drawer)
   - Animaciones premium
   - Scroll y spacing refinado
   - Ajustes visuales finales
============================================================ */
/* ============================================================
   UIXTRA STORE.CSS — PARTE 2/2
   SIDEBAR PREMIUM + ACCORDIONS + RESPONSIVE + MOBILE DRAWER
   Todo está perfectamente comentado para que entiendas cada
   sección sin confusión.
============================================================ */


/* ============================================================
   5) ACCORDION — ABRIR Y CERRAR BLOQUES
   (Funciona con JS, pero requiere estilos visuales)
============================================================ */

/* Botón del accordion */
#uixtra-sidebar-filters button {
  width: 100%;
  background: transparent;
  border: none;
  padding: 0;
  text-align: left;
  font-size: 14px;
  font-weight: 600;
  color: #cbd5e1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
}

#uixtra-sidebar-filters button:hover {
  color: #fff;
}

/* Flecha girando cuando está abierto */
.uixtra-accordion-open i {
  transform: rotate(180deg);
  transition: 0.25s ease;
}

/* Flecha normal */
#uixtra-sidebar-filters i {
  transition: transform 0.25s ease;
}


/* ============================================================
   6) ANIMACIÓN DE APERTURA DE BLOQUES
============================================================ */

.uixtra-accordion-content {
  overflow: hidden;
  max-height: 0;
  opacity: 0;
  transition: max-height 0.35s ease, opacity 0.35s ease;
}

.uixtra-accordion-content.open {
  max-height: 500px; /* suficiente para cualquier lista */
  opacity: 1;
}

/* Espaciado interno del contenido */
.uixtra-accordion-content-inner {
  padding-left: 0.5rem;
  padding-top: 0.3rem;
  padding-bottom: 0.5rem;
}


/* ============================================================
   7) ESTILO DE LOS LABELS INTERNOS (mejorado)
============================================================ */

#uixtra-sidebar-filters label {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #cbd5e1;
  font-size: 14px;
  cursor: pointer;
  transition: color 0.2s ease;
}

#uixtra-sidebar-filters label:hover {
  color: #fff;
}


/* ============================================================
   8) INPUT SEARCH (sidebar premium)
============================================================ */

#sidebar-search {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #e2e8f0;
  font-size: 14px;
  padding: 9px 12px;
  border-radius: 12px;
  transition: border-color 0.2s;
}

#sidebar-search::placeholder {
  color: #64748b;
}

#sidebar-search:focus {
  outline: none;
  border-color: #14f1e1;
  box-shadow: 0 0 15px #14f1e144;
}


/* ============================================================
   9) SIDEBAR SCROLL (cuando hay muchos filtros)
============================================================ */

#uixtra-sidebar-filters {
  max-height: calc(100vh - 180px);
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: #14f1e1 #0f172a;
}

/* Estilo del scroll (chrome) */
#uixtra-sidebar-filters::-webkit-scrollbar {
  width: 6px;
}

#uixtra-sidebar-filters::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.05);
}

#uixtra-sidebar-filters::-webkit-scrollbar-thumb {
  background: #14f1e1;
  border-radius: 6px;
}


/* ============================================================
   10) EFFECTOS PREMIUM (BRILLO, HOVER GLOBAL)
============================================================ */

#uixtra-sidebar-filters {
  transition: box-shadow 0.25s ease;
}

#uixtra-sidebar-filters:hover {
  box-shadow: 0 0 30px rgba(20, 241, 225, 0.15);
}


/* ============================================================
   11) RESPONSIVE — ADAPTACIÓN DEL GRID
============================================================ */

@media (max-width: 1024px) {
  #products-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  #products-grid {
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
  }

  .product-image {
    height: 160px;
  }

  .product-card {
    padding: 1.2rem;
  }
}

@media (max-width: 480px) {
  #products-grid {
    grid-template-columns: 1fr;
  }

  .product-image {
    height: 150px;
  }

  .product-title {
    font-size: 0.95rem;
  }

  .product-price {
    font-size: 1rem;
  }
}


/* ============================================================
   12) RESPONSIVE — MOBILE FILTER DRAWER (ESTILO GUMROAD)
============================================================ */

/* Botón flotante para abrir filtros en mobile */
#mobile-filters-btn {
  position: fixed;
  bottom: 25px;
  right: 25px;
  z-index: 100;
  background: linear-gradient(to right, #14f1e1, #38bdf8);
  color: #000;
  font-weight: 600;
  padding: 12px 20px;
  border-radius: 14px;
  box-shadow: 0 0 25px #14f1e188;
  cursor: pointer;
  display: none; /* se activa en mobile */
}

/* Drawer */
#mobile-filters-drawer {
  position: fixed;
  bottom: -100%;
  left: 0;
  width: 100%;
  height: 85%;
  background: rgba(2, 7, 18, 0.95);
  backdrop-filter: blur(20px);
  border-top-left-radius: 22px;
  border-top-right-radius: 22px;
  padding: 25px;
  transition: 0.35s ease-in-out;
  z-index: 200;
  overflow-y: auto;
  display: none; /* solo mobile */
}

/* Drawer abierto */
#mobile-filters-drawer.open {
  bottom: 0;
}

/* Botón cerrar */
#mobile-filters-close {
  font-size: 20px;
  color: #fff;
  margin-bottom: 20px;
  cursor: pointer;
}

/* Mostrar solo en pantallas pequeñas */
@media (max-width: 768px) {
  #mobile-filters-btn {
    display: flex;
  }

  #mobile-filters-drawer {
    display: block;
  }

  /* Ocultar sidebar normal en mobile */
  #uixtra-sidebar-filters {
    display: none;
  }
}


/* ============================================================
   >>> FIN DE STORE.CSS PARTE 2 <<<
============================================================ */
#uixtra-hero-stars {
  background: transparent !important;
  appearance: none !important;
}

#uixtra-hero-stars::-webkit-media-controls {
  display: none !important;
}

#uixtra-hero-stars::before,
#uixtra-hero-stars::after {
  content: none !important;
  display: none !important;
}
canvas#uixtra-hero-stars {
  -webkit-appearance: none !important;
  -moz-appearance: none !important;
  appearance: none !important;
  display: block !important;
}

canvas#uixtra-hero-stars::-webkit-media-controls-panel,
canvas#uixtra-hero-stars::-webkit-media-controls-play-button {
  display: none !important;
}

canvas#uixtra-hero-stars:focus {
  outline: none !important;
}
