/* ============================================================
   LA MERCA DIGITAL — CSS v6
   Colores: Azul #003399 + Dorado #FFD700
   Estilo: MercadoLibre / Claro — moderno e intuitivo
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800;900&family=Nunito:wght@700;800;900&display=swap');

/* ── Variables ──────────────────────────────────────────── */
:root {
  --azul:        #003399;
  --azul-dark:   #001f66;
  --azul-mid:    #0044cc;
  --azul-light:  #e8eeff;
  --dorado:      #FFD700;
  --dorado-dark: #e6c000;
  --dorado-soft: #fff8cc;
  --rojo:        #e53935;
  --verde:       #00a650;
  --blanco:      #ffffff;
  --fondo:       #f5f6fa;
  --gris-borde:  #e4e6eb;
  --gris-texto:  #666;
  --texto:       #1a1a2e;

  --shadow-sm: 0 1px 4px rgba(0,51,153,.08);
  --shadow-md: 0 4px 16px rgba(0,51,153,.12);
  --shadow-lg: 0 8px 32px rgba(0,51,153,.16);
  --radius:    12px;
  --radius-sm: 8px;
  --radius-lg: 20px;
}

/* ── Reset ──────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { font-family: 'Inter', sans-serif; background: var(--fondo); color: var(--texto); font-size: 15px; line-height: 1.5; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button, input, select, textarea { font-family: inherit; }

/* ── Utilidades ─────────────────────────────────────────── */
.container { max-width: 1280px; margin: 0 auto; padding: 0 16px; }
.flex { display: flex; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.gap-2 { gap: 8px; }
.gap-3 { gap: 12px; }
.gap-4 { gap: 16px; }
.gap-6 { gap: 24px; }
.text-center { text-align: center; }
.hidden { display: none !important; }
.w-full { width: 100%; }
.mt-2 { margin-top: 8px; }
.mt-4 { margin-top: 16px; }
.mt-6 { margin-top: 24px; }
.mb-2 { margin-bottom: 8px; }
.mb-4 { margin-bottom: 16px; }
.font-bold { font-weight: 700; }
.text-sm { font-size: .875rem; }
.text-xs { font-size: .75rem; }
.truncate { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }

/* ── HEADER / NAVBAR ────────────────────────────────────── */
.header-top {
  background: var(--azul);
  position: sticky; top: 0; z-index: 1000;
  box-shadow: 0 2px 12px rgba(0,0,0,.2);
}
.header-inner {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 12px 0;
}
.header-logo {
  flex-shrink: 0;
  height: 52px;
}
.header-logo img { height: 52px; width: auto; filter: drop-shadow(0 2px 6px rgba(0,0,0,.45)); }

.header-search {
  flex: 1;
  max-width: 600px;
  display: flex;
  background: #fff;
  border-radius: 8px;
  overflow: hidden;
  border: 2px solid var(--dorado);
}
.header-search input {
  flex: 1;
  border: none;
  outline: none;
  padding: 10px 16px;
  font-size: .95rem;
  color: var(--texto);
}
.header-search button {
  background: var(--dorado);
  border: none;
  padding: 0 18px;
  cursor: pointer;
  font-size: 1.1rem;
  color: var(--azul);
  font-weight: 700;
  transition: background .2s;
}
.header-search button:hover { background: var(--dorado-dark); }

.header-actions {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
}
.header-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding: 6px 12px;
  color: #fff;
  border-radius: 8px;
  transition: background .2s;
  cursor: pointer;
  font-size: .75rem;
  font-weight: 600;
  border: none;
  background: transparent;
  white-space: nowrap;
}
.header-btn:hover { background: rgba(255,255,255,.15); }
.header-btn i { font-size: 1.3rem; }
.header-btn .cart-badge {
  position: relative;
}
.cart-count {
  position: absolute;
  top: -6px; right: -6px;
  background: var(--dorado);
  color: var(--azul);
  font-size: .65rem;
  font-weight: 900;
  width: 18px; height: 18px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
}
/* Catálogo — ícono especial en el header */
.header-btn-catalog i { color: var(--dorado, #f59e0b); }
.header-btn-catalog:hover { background: rgba(245,158,11,.2); }

/* ── NAV CATEGORÍAS ─────────────────────────────────────── */
.header-nav {
  background: var(--azul-dark);
  border-top: 1px solid rgba(255,255,255,.1);
}
.header-nav-inner {
  display: flex;
  gap: 0;
  overflow-x: auto;
  scrollbar-width: none;
}
.header-nav-inner::-webkit-scrollbar { display: none; }
.nav-link {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 16px;
  color: rgba(255,255,255,.85);
  font-size: .85rem;
  font-weight: 600;
  white-space: nowrap;
  transition: color .2s, background .2s;
}
.nav-link:hover { color: var(--dorado); background: rgba(255,255,255,.05); }
.nav-link i { font-size: .9rem; }

/* ── Nav categorías en móvil: grid 2 columnas, sin scroll ── */
@media (max-width: 768px) {
  .header-nav-inner {
    display: grid;
    grid-template-columns: 1fr 1fr;
    overflow-x: visible;
    overflow: visible;
  }
  .nav-link {
    white-space: normal;
    padding: 9px 12px;
    font-size: .8rem;
    border-bottom: 1px solid rgba(255,255,255,.07);
    justify-content: flex-start;
  }
  .nav-link:nth-child(odd)  { border-right: 1px solid rgba(255,255,255,.07); }
}

/* ── BREADCRUMB ─────────────────────────────────────────── */
.breadcrumb {
  padding: 10px 0;
  font-size: .82rem;
  color: var(--gris-texto);
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}
.breadcrumb a { color: var(--azul-mid); }
.breadcrumb a:hover { text-decoration: underline; }
.breadcrumb i { font-size: .65rem; }

/* ── HERO BANNER ────────────────────────────────────────── */
.hero-banner {
  background: linear-gradient(135deg, var(--azul-dark) 0%, var(--azul) 50%, #0055cc 100%);
  padding: 48px 0;
  position: relative;
  overflow: hidden;
}
.hero-banner::before {
  content: '';
  position: absolute;
  top: -50%; right: -10%;
  width: 500px; height: 500px;
  background: radial-gradient(circle, rgba(255,215,0,.15) 0%, transparent 70%);
  border-radius: 50%;
}
.hero-content {
  position: relative;
  display: flex;
  align-items: center;
  gap: 40px;
}
.hero-text { flex: 1; }
.hero-tag {
  display: inline-block;
  background: var(--dorado);
  color: var(--azul-dark);
  font-size: .75rem;
  font-weight: 800;
  padding: 4px 12px;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: .08em;
  margin-bottom: 16px;
}
.hero-title {
  font-size: 2.6rem;
  font-weight: 900;
  color: #fff;
  line-height: 1.15;
  margin-bottom: 16px;
  font-family: 'Nunito', sans-serif;
}
.hero-title span { color: var(--dorado); }
.hero-desc {
  color: rgba(255,255,255,.75);
  font-size: 1rem;
  margin-bottom: 28px;
  max-width: 440px;
}
.hero-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--dorado);
  color: var(--azul-dark);
  padding: 14px 28px;
  border-radius: 10px;
  font-weight: 800;
  font-size: 1rem;
  transition: all .2s;
  box-shadow: 0 4px 16px rgba(255,215,0,.4);
}
.hero-cta:hover { background: var(--dorado-dark); transform: translateY(-2px); }
.hero-img {
  filter: drop-shadow(0 4px 16px rgba(0,0,0,.5));
  width: 280px;
  flex-shrink: 0;
  opacity: .9;
}

/* ── SECCIÓN GENÉRICA ───────────────────────────────────── */
.section { padding: 32px 0; }
.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}
.section-title {
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--texto);
  display: flex;
  align-items: center;
  gap: 10px;
}
.section-title::before {
  content: '';
  display: block;
  width: 4px; height: 24px;
  background: var(--azul);
  border-radius: 2px;
}
.section-link {
  color: var(--azul-mid);
  font-size: .875rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 4px;
}
.section-link:hover { text-decoration: underline; }

/* ── GRID CATEGORÍAS ────────────────────────────────────── */
.cat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 12px;
}
.cat-card {
  background: #fff;
  border-radius: var(--radius);
  padding: 20px 12px 16px;
  text-align: center;
  border: 2px solid transparent;
  cursor: pointer;
  transition: all .2s;
  box-shadow: var(--shadow-sm);
}
.cat-card:hover {
  border-color: var(--azul);
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}
.cat-icon {
  width: 52px; height: 52px;
  background: var(--azul-light);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 10px;
  font-size: 1.4rem;
  color: var(--azul);
  transition: background .2s;
}
.cat-card:hover .cat-icon { background: var(--azul); color: #fff; }
.cat-name {
  font-size: .8rem;
  font-weight: 700;
  color: var(--texto);
  line-height: 1.3;
}

/* ── PRODUCTO CARD ──────────────────────────────────────── */
.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 16px;
}
.product-card {
  background: #fff;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--gris-borde);
  transition: all .25s;
  display: flex;
  flex-direction: column;
}
.product-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
  border-color: var(--azul);
}
.product-img-wrap {
  position: relative;
  padding-top: 70%;
  background: var(--fondo);
  overflow: hidden;
}
.product-img-wrap img {
  position: absolute;
  inset: 0;
  width: 100%; height: 100%;
  object-fit: contain;
  padding: 12px;
  transition: transform .3s;
}
.product-card:hover .product-img-wrap img { transform: scale(1.05); }
.product-badge {
  position: absolute;
  top: 8px; left: 8px;
  background: var(--rojo);
  color: #fff;
  font-size: .7rem;
  font-weight: 800;
  padding: 3px 8px;
  border-radius: 6px;
  text-transform: uppercase;
}
.product-badge.nuevo { background: var(--verde); }
.product-badge.destac { background: var(--azul); }
.product-body {
  padding: 14px;
  flex: 1;
  display: flex;
  flex-direction: column;
}
.product-cat {
  font-size: .7rem;
  color: var(--gris-texto);
  text-transform: uppercase;
  letter-spacing: .05em;
  font-weight: 600;
  margin-bottom: 4px;
}
.product-name {
  font-size: .9rem;
  font-weight: 600;
  color: var(--texto);
  line-height: 1.4;
  margin-bottom: 10px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  flex: 1;
}
.product-price-wrap { margin-bottom: 10px; }
.product-price-old {
  font-size: .8rem;
  color: var(--gris-texto);
  text-decoration: line-through;
}
.product-price {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--azul);
  line-height: 1.2;
}
.product-price-cuotas {
  font-size: .75rem;
  color: var(--verde);
  font-weight: 600;
}
.product-stock {
  font-size: .72rem;
  color: var(--gris-texto);
  margin-bottom: 10px;
}
.product-stock.low { color: var(--rojo); }
.product-stock.out { color: var(--rojo); font-weight: 700; }
.btn-add-cart {
  width: 100%;
  padding: 10px;
  background: var(--azul);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-weight: 700;
  font-size: .875rem;
  cursor: pointer;
  transition: background .2s, transform .1s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}
.btn-add-cart:hover { background: var(--azul-mid); }
.btn-add-cart:active { transform: scale(.97); }

/* ── BANNERS PROMO ──────────────────────────────────────── */
.promo-banners {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.promo-card {
  border-radius: var(--radius);
  padding: 28px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  overflow: hidden;
  position: relative;
}
.promo-card.azul {
  background: linear-gradient(135deg, var(--azul) 0%, #0055cc 100%);
  color: #fff;
}
.promo-card.dorado {
  background: linear-gradient(135deg, #b8860b 0%, var(--dorado) 100%);
  color: var(--azul-dark);
}
.promo-text h3 { font-size: 1.3rem; font-weight: 800; margin-bottom: 6px; }
.promo-text p { font-size: .85rem; opacity: .85; margin-bottom: 14px; }
.promo-btn {
  display: inline-block;
  padding: 8px 20px;
  border-radius: 8px;
  font-weight: 700;
  font-size: .85rem;
  transition: all .2s;
}
.promo-card.azul .promo-btn { background: var(--dorado); color: var(--azul-dark); }
.promo-card.dorado .promo-btn { background: var(--azul); color: #fff; }
.promo-icon { font-size: 4rem; opacity: .25; position: absolute; right: 20px; }

/* ── TRUST BADGES ───────────────────────────────────────── */
.trust-bar {
  background: #fff;
  border-top: 3px solid var(--dorado);
  border-bottom: 1px solid var(--gris-borde);
  padding: 20px 0;
}
.trust-items {
  display: flex;
  justify-content: space-around;
  flex-wrap: wrap;
  gap: 16px;
}
.trust-item {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: .85rem;
  color: var(--texto);
}
.trust-item i {
  font-size: 1.6rem;
  color: var(--azul);
}
.trust-item strong { display: block; font-size: .95rem; }

/* ── BOTONES GENERALES ──────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 24px;
  border-radius: 10px;
  font-weight: 700;
  font-size: .9rem;
  cursor: pointer;
  border: 2px solid transparent;
  transition: all .2s;
  white-space: nowrap;
}
.btn-primary { background: var(--azul); color: #fff; }
.btn-primary:hover { background: var(--azul-dark); }
.btn-secondary { background: transparent; color: var(--azul); border-color: var(--azul); }
.btn-secondary:hover { background: var(--azul-light); }
.btn-dorado { background: var(--dorado); color: var(--azul-dark); border-color: var(--dorado); }
.btn-dorado:hover { background: var(--dorado-dark); }
.btn-danger { background: var(--rojo); color: #fff; }
.btn-sm { padding: 7px 16px; font-size: .8rem; border-radius: 8px; }
.btn-lg { padding: 14px 32px; font-size: 1rem; }
.btn-block { width: 100%; }

/* ── FORMS ──────────────────────────────────────────────── */
.form-group { margin-bottom: 18px; }
.form-label {
  display: block;
  font-size: .8rem;
  font-weight: 700;
  color: var(--gris-texto);
  text-transform: uppercase;
  letter-spacing: .05em;
  margin-bottom: 6px;
}
.form-input, .form-select, .form-textarea {
  width: 100%;
  padding: 12px 16px;
  border: 2px solid var(--gris-borde);
  border-radius: 10px;
  font-size: .95rem;
  color: var(--texto);
  background: #fff;
  outline: none;
  transition: border-color .2s, box-shadow .2s;
}
.form-input:focus, .form-select:focus, .form-textarea:focus {
  border-color: var(--azul);
  box-shadow: 0 0 0 3px rgba(0,51,153,.1);
}
.form-input.error { border-color: var(--rojo); }
.form-error { font-size: .8rem; color: var(--rojo); margin-top: 4px; font-weight: 600; }
.form-textarea { resize: vertical; min-height: 100px; }
.input-icon { position: relative; }
.input-icon input { padding-left: 44px; }
.input-icon i {
  position: absolute;
  left: 14px; top: 50%;
  transform: translateY(-50%);
  color: var(--gris-texto);
  font-size: 1rem;
}

/* ── CARD GENÉRICA ──────────────────────────────────────── */
.card {
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--gris-borde);
  overflow: hidden;
}
.card-header {
  padding: 18px 24px;
  border-bottom: 1px solid var(--gris-borde);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.card-header h2, .card-header h3 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--texto);
  display: flex;
  align-items: center;
  gap: 8px;
}
.card-header i { color: var(--azul); }
.card-body { padding: 24px; }

/* ── FILTRO CATEGORÍAS (sidebar productos) ──────────────────── */
.cat-filter-link {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  color: var(--texto);
  text-decoration: none;
  font-size: .875rem;
  border-left: 3px solid transparent;
  border-radius: 0 6px 6px 0;
  transition: background .15s, color .15s, border-color .15s;
}
.cat-filter-link:hover {
  background: rgba(0,51,153,.07);
  color: var(--azul);
  border-left-color: var(--azul);
}
.cat-filter-link.active {
  background: rgba(0,51,153,.12);
  color: var(--azul);
  border-left-color: var(--azul);
  font-weight: 600;
}
.cat-filter-link i { width: 16px; text-align: center; font-size: .8rem; opacity: .75; }

/* ── WHATSAPP FLOTANTE ──────────────────────────────────── */
.wa-float {
  position: fixed;
  bottom: 28px;
  right: 24px;
  z-index: 9999;
  width: 58px;
  height: 58px;
  background: #25d366;
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.75rem;
  box-shadow: 0 4px 16px rgba(37,211,102,.45);
  text-decoration: none;
  transition: transform .2s, box-shadow .2s;
}
.wa-float:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 24px rgba(37,211,102,.6);
  color: #fff;
}
.wa-float-tooltip {
  position: absolute;
  right: 68px;
  background: #1a1a1a;
  color: #fff;
  font-size: .78rem;
  white-space: nowrap;
  padding: 5px 10px;
  border-radius: 6px;
  opacity: 0;
  pointer-events: none;
  transition: opacity .2s;
}
.wa-float-tooltip::after {
  content: '';
  position: absolute;
  right: -6px;
  top: 50%;
  transform: translateY(-50%);
  border: 6px solid transparent;
  border-right: none;
  border-left-color: #1a1a1a;
}
.wa-float:hover .wa-float-tooltip { opacity: 1; }

/* ── ALERTAS ────────────────────────────────────────────── */
.alert {
  padding: 12px 16px;
  border-radius: 10px;
  font-size: .875rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
}
.alert-error { background: #fef2f2; color: #c0392b; border: 1px solid #fecaca; }
.alert-success { background: #f0fdf4; color: #15803d; border: 1px solid #bbf7d0; }
.alert-info { background: var(--azul-light); color: var(--azul); border: 1px solid rgba(0,51,153,.2); }
.alert-warning { background: var(--dorado-soft); color: #92400e; border: 1px solid var(--dorado); }

/* ── BADGES / CHIPS ─────────────────────────────────────── */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: .72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .04em;
}
.badge-azul { background: var(--azul-light); color: var(--azul); }
.badge-dorado { background: var(--dorado-soft); color: #92400e; }
.badge-verde { background: #d1fae5; color: #065f46; }
.badge-rojo { background: #fef2f2; color: #b91c1c; }
.badge-gris { background: #f3f4f6; color: #4b5563; }

/* ── TABLA ADMIN ────────────────────────────────────────── */
.table-wrap { overflow-x: auto; }
.table {
  width: 100%;
  border-collapse: collapse;
  font-size: .875rem;
}
.table th {
  background: var(--fondo);
  padding: 12px 16px;
  text-align: left;
  font-size: .75rem;
  text-transform: uppercase;
  letter-spacing: .05em;
  color: var(--gris-texto);
  font-weight: 700;
  border-bottom: 2px solid var(--gris-borde);
  white-space: nowrap;
}
.table td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--gris-borde);
  vertical-align: middle;
}
.table tr:hover td { background: #fafbff; }
.table tr:last-child td { border-bottom: none; }

/* ── SIDEBAR ADMIN ──────────────────────────────────────── */
.admin-layout {
  display: flex;
  min-height: 100vh;
}
.admin-sidebar {
  width: 240px;
  background: var(--azul-dark);
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
}
.sidebar-logo {
  padding: 20px;
  border-bottom: 1px solid rgba(255,255,255,.1);
}
.sidebar-logo img { height: 44px; }
.sidebar-nav { flex: 1; padding: 16px 0; }
.sidebar-section {
  font-size: .7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: rgba(255,255,255,.35);
  padding: 16px 20px 6px;
}
.sidebar-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 20px;
  color: rgba(255,255,255,.75);
  font-size: .875rem;
  font-weight: 600;
  transition: all .2s;
  border-left: 3px solid transparent;
}
.sidebar-link:hover, .sidebar-link.active {
  background: rgba(255,255,255,.08);
  color: #fff;
  border-left-color: var(--dorado);
}
.sidebar-link i { width: 18px; font-size: .95rem; }
.admin-main { flex: 1; overflow: hidden; }
.admin-topbar {
  background: #fff;
  border-bottom: 1px solid var(--gris-borde);
  padding: 16px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.admin-topbar h1 {
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--texto);
  display: flex;
  align-items: center;
  gap: 10px;
}
.admin-topbar h1 i { color: var(--azul); }
.admin-content { padding: 24px 28px; }

/* ── STATS CARDS ────────────────────────────────────────── */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 16px;
  margin-bottom: 28px;
}
.stat-card {
  background: #fff;
  border-radius: var(--radius);
  padding: 20px 24px;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--gris-borde);
  display: flex;
  align-items: center;
  gap: 16px;
}
.stat-icon {
  width: 52px; height: 52px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  flex-shrink: 0;
}
.stat-icon.azul  { background: var(--azul-light); color: var(--azul); }
.stat-icon.verde { background: #d1fae5; color: var(--verde); }
.stat-icon.dor   { background: var(--dorado-soft); color: #92400e; }
.stat-icon.rojo  { background: #fef2f2; color: var(--rojo); }
.stat-num { font-size: 1.7rem; font-weight: 800; color: var(--texto); line-height: 1; }
.stat-label { font-size: .8rem; color: var(--gris-texto); font-weight: 600; margin-top: 4px; }

/* ── PAGE AUTH ──────────────────────────────────────────── */
.auth-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--azul-dark) 0%, var(--azul) 60%, #0055cc 100%);
  padding: 24px;
}
.auth-card {
  background: #fff;
  border-radius: 20px;
  box-shadow: 0 24px 64px rgba(0,0,0,.25);
  padding: 40px 36px;
  width: 100%;
  max-width: 440px;
}
.auth-logo {
  text-align: center;
  margin-bottom: 28px;
}
.auth-logo img { height: 64px; margin: 0 auto 12px; }
.auth-logo h2 {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--azul);
  font-family: 'Nunito', sans-serif;
}
.auth-logo p { font-size: .85rem; color: var(--gris-texto); }
.auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 20px 0;
  color: var(--gris-texto);
  font-size: .8rem;
  font-weight: 600;
  text-transform: uppercase;
}
.auth-divider::before, .auth-divider::after {
  content: ''; flex: 1;
  height: 1px;
  background: var(--gris-borde);
}
.btn-google {
  width: 100%;
  padding: 12px;
  border: 2px solid var(--gris-borde);
  border-radius: 10px;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-weight: 700;
  font-size: .9rem;
  color: var(--texto);
  cursor: pointer;
  transition: all .2s;
}
.btn-google:hover { border-color: var(--azul); background: var(--azul-light); }
.btn-google img { width: 20px; }

/* ── CUENTA / PERFIL ────────────────────────────────────── */
.cuenta-layout {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 24px;
  padding: 28px 0;
}
.cuenta-sidebar {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.cuenta-user-card {
  background: #fff;
  border-radius: var(--radius);
  padding: 24px;
  text-align: center;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--gris-borde);
  margin-bottom: 8px;
}
.cuenta-avatar {
  width: 72px; height: 72px;
  border-radius: 50%;
  background: var(--azul-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  color: var(--azul);
  margin: 0 auto 12px;
  font-weight: 800;
  overflow: hidden;
}
.cuenta-avatar img { width: 100%; height: 100%; object-fit: cover; }
.cuenta-nombre { font-weight: 800; font-size: 1rem; color: var(--texto); }
.cuenta-email { font-size: .8rem; color: var(--gris-texto); }
.cuenta-nav-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 16px;
  background: #fff;
  border-radius: var(--radius-sm);
  color: var(--texto);
  font-size: .875rem;
  font-weight: 600;
  border: 1px solid var(--gris-borde);
  transition: all .2s;
}
.cuenta-nav-link:hover, .cuenta-nav-link.active {
  background: var(--azul-light);
  color: var(--azul);
  border-color: var(--azul);
}
.cuenta-nav-link i { width: 18px; color: var(--azul); }

/* ── STREAMING CARDS ────────────────────────────────────── */
.streaming-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 20px;
}
.streaming-card {
  background: #fff;
  border-radius: var(--radius-lg);
  border: 2px solid var(--gris-borde);
  overflow: hidden;
  transition: all .25s;
  display: flex;
  flex-direction: column;
}
.streaming-card:hover {
  border-color: var(--azul);
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
}
.streaming-card-top {
  background: linear-gradient(135deg, var(--azul) 0%, #0055cc 100%);
  padding: 28px 24px;
  text-align: center;
  color: #fff;
}
.streaming-icon { font-size: 2.5rem; margin-bottom: 8px; }
.streaming-name { font-size: 1.1rem; font-weight: 800; }
.streaming-screens {
  font-size: .8rem;
  background: rgba(255,255,255,.15);
  padding: 4px 10px;
  border-radius: 20px;
  margin-top: 6px;
  display: inline-block;
}
.streaming-card-body { padding: 20px 24px; flex: 1; }
.streaming-price { font-size: 1.6rem; font-weight: 800; color: var(--azul); }
.streaming-duracion { font-size: .8rem; color: var(--gris-texto); }
.streaming-features { list-style: none; margin: 14px 0; }
.streaming-features li {
  font-size: .85rem;
  padding: 4px 0;
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--texto);
}
.streaming-features li i { color: var(--verde); font-size: .75rem; }

/* ── FOOTER ─────────────────────────────────────────────── */
.footer {
  background: var(--azul-dark);
  color: rgba(255,255,255,.75);
  padding: 48px 0 24px;
  margin-top: 48px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 36px;
}
.footer-brand img { height: 52px; margin-bottom: 12px; }
.footer-brand p {
  font-size: .875rem;
  line-height: 1.6;
  margin-bottom: 16px;
}
.footer-social { display: flex; gap: 10px; }
.social-btn {
  width: 36px; height: 36px;
  background: rgba(255,255,255,.1);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: .9rem;
  transition: background .2s;
}
.social-btn:hover { background: var(--dorado); color: var(--azul-dark); }
.footer-col h4 {
  color: #fff;
  font-size: .875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  margin-bottom: 14px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--dorado);
  display: inline-block;
}
.footer-links { list-style: none; }
.footer-links li { margin-bottom: 8px; }
.footer-links a {
  color: rgba(255,255,255,.65);
  font-size: .85rem;
  transition: color .2s;
}
.footer-links a:hover { color: var(--dorado); }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.1);
  padding-top: 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: .8rem;
  flex-wrap: wrap;
  gap: 12px;
}
.footer-bottom a { color: rgba(255,255,255,.6); }
.footer-bottom a:hover { color: var(--dorado); }
.pay-methods { display: flex; gap: 8px; align-items: center; }
.pay-badge {
  background: rgba(255,255,255,.1);
  border-radius: 6px;
  padding: 4px 10px;
  font-size: .75rem;
  font-weight: 700;
  color: #fff;
}

/* ── PAGINACIÓN ─────────────────────────────────────────── */
.pagination {
  display: flex;
  gap: 6px;
  justify-content: center;
  margin-top: 32px;
}
.page-btn {
  width: 38px; height: 38px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  font-size: .875rem;
  font-weight: 600;
  border: 2px solid var(--gris-borde);
  color: var(--texto);
  background: #fff;
  cursor: pointer;
  transition: all .2s;
}
.page-btn:hover, .page-btn.active { background: var(--azul); color: #fff; border-color: var(--azul); }

/* ── RESPONSIVE ─────────────────────────────────────────── */
@media (max-width: 1024px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .admin-sidebar { width: 200px; }
}
@media (max-width: 768px) {
  .hero-content { flex-direction: column; text-align: center; }
  .hero-img { width: 180px; }
  .hero-title { font-size: 1.8rem; }
  .promo-banners { grid-template-columns: 1fr; }
  .cat-grid { grid-template-columns: repeat(3, 1fr); }
  .products-grid { grid-template-columns: repeat(2, 1fr); }
  .cuenta-layout { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .admin-layout { flex-direction: column; }
  .admin-sidebar { width: 100%; }

  /* ── Header móvil ── */
  .header-inner {
    flex-wrap: wrap;
    gap: 8px;
    padding: 8px 0;
  }
  /* Logo: fila 1 izquierda */
  .header-logo { order: 1; }
  .header-logo img { height: 42px; }
  /* Acciones: fila 1 derecha */
  .header-actions { order: 2; margin-left: auto; gap: 0; }
  /* Buscador: fila 2 ancho completo */
  .header-search { order: 3; max-width: 100%; flex-basis: 100%; }

  /* Texto de los botones: ocultar en móvil, solo ícono */
  .header-btn span:not(.cart-badge):not(.cart-count) { display: none; }
  .header-btn { padding: 6px 9px; }
  .header-btn i { font-size: 1.4rem; }

  /* Sidebar de categorías en productos: colapsable */
  .prod-sidebar-mobile { display: block !important; }
}

@media (max-width: 480px) {
  .cat-grid { grid-template-columns: repeat(2, 1fr); }
  .products-grid { grid-template-columns: repeat(2, 1fr); }
  .auth-card { padding: 28px 20px; }
  .header-logo img { height: 38px; }
}

/* ── SERVICIO TÉCNICO ───────────────────────────────────── */
.st-hero {
  background: linear-gradient(135deg,#1a1a2e 0%,#16213e 60%,#0f3460 100%);
  border-radius: var(--radius-lg);
  padding: 32px 40px;
  margin-bottom: 32px;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.st-hero-icon { font-size: 5rem; opacity: .2; flex-shrink: 0; }
.st-layout {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 24px;
  align-items: start;
}
.form-row-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
@media (max-width: 768px) {
  .st-hero { padding: 24px 20px; }
  .st-hero-icon { display: none; }
  .st-layout { grid-template-columns: 1fr; }
  .form-row-2 { grid-template-columns: 1fr; }
}

/* ── HELPERS EXTRA ──────────────────────────────────────── */
.price-cop::before { content: '$'; }
.line-through { text-decoration: line-through; }
.text-azul { color: var(--azul); }
.text-dorado { color: var(--dorado-dark); }
.text-verde { color: var(--verde); }
.text-rojo { color: var(--rojo); }
.text-gris { color: var(--gris-texto); }
.bg-azul { background: var(--azul); }
.bg-dorado { background: var(--dorado); }
.rounded { border-radius: var(--radius); }
.shadow { box-shadow: var(--shadow-md); }
.spinner {
  display: inline-block;
  width: 20px; height: 20px;
  border: 3px solid rgba(0,51,153,.2);
  border-top-color: var(--azul);
  border-radius: 50%;
  animation: spin .7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.fade-in {
  animation: fadeIn .4s ease;
}
@keyframes fadeIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

/* ============================================================
   DETALLE DE PRODUCTO
============================================================ */
.producto-detail {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 32px;
  align-items: start;
  margin-top: 24px;
}
.producto-img-col {
  position: sticky;
  top: 88px;
}
.producto-info-col { min-width: 0; }

/* ---- Slider de imágenes ---- */
.img-slider {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--gris-borde);
  background: #fff;
}
.img-slider-track {
  display: flex;
  width: 100%;
  height: 100%;
  transition: transform .35s cubic-bezier(.4,0,.2,1);
}
.img-slider-slide {
  flex: 0 0 100%;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fff;
}
.img-slider-slide img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  user-select: none;
}
.img-slider-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255,255,255,.9);
  border: 1px solid var(--gris-borde);
  border-radius: 50%;
  width: 34px; height: 34px;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  font-size: .8rem;
  color: var(--texto);
  z-index: 2;
  transition: background .15s, box-shadow .15s;
  box-shadow: 0 2px 6px rgba(0,0,0,.12);
}
.img-slider-btn:hover { background: #fff; box-shadow: 0 3px 10px rgba(0,0,0,.18); }
.img-slider-btn.prev { left: 8px; }
.img-slider-btn.next { right: 8px; }
.img-slider-dots {
  display: flex;
  justify-content: center;
  gap: 6px;
  margin-top: 10px;
}
.img-slider-dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--gris-borde);
  cursor: pointer;
  transition: background .2s, transform .2s;
  border: none;
  padding: 0;
}
.img-slider-dot.active {
  background: var(--azul);
  transform: scale(1.3);
}
.img-slider-badge {
  position: absolute;
  top: 10px; left: 10px;
  z-index: 3;
}

@media (max-width: 860px) {
  .producto-detail {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  .producto-img-col {
    position: static;
    max-width: 340px;
    margin: 0 auto;
    width: 100%;
  }
}
