:root {
  --bg: #0b0d12;
  --card: #121622;
  --muted: #9aa3b2;
  --text: #e8ecf3;
  --brand: #6c9ef8;
  --accent: #22d3ee;
  --ok: #22c55e;
  --warn: #f59e0b;
  --shadow: 0 10px 25px rgba(0,0,0,.25);
}

/* --- RESET Y BASE --- */
* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Inter', sans-serif;
  background: linear-gradient(180deg, #0a0c10, #0f1220 40%, #0b0d12);
  color: var(--text);
  line-height: 1.5;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; height: auto; }
.container { max-width: 1100px; margin: 0 auto; padding: 24px; }
.with-safe { padding-left: calc(24px + env(safe-area-inset-left)); padding-right: calc(24px + env(safe-area-inset-right)); }

/* --- NAVEGACIÓN --- */
.nav { position: sticky; top: 0; z-index: 50; background: rgba(11,13,18,.75); backdrop-filter: blur(10px); border-bottom: 1px solid rgba(255,255,255,.05); }
.nav-wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; height: 70px; }
.brand { display: flex; align-items: center; gap: 12px; font-weight: 800; font-size: 1.2rem; flex-shrink: 0; }
.brand-logo-img { width: 35px !important; height: 35px !important; min-width: 35px; min-height: 35px; object-fit: contain; border-radius: 6px; }

.nav-actions { display: flex; align-items: center; gap: 12px; }
.nav-links-group { display: flex; gap: 8px; align-items: center; }

.nav-pill {
  text-decoration: none;
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 700;
  padding: 6px 12px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  transition: all 0.2s ease;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  white-space: nowrap;
}

.nav-pill:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--brand);
  color: var(--text);
  transform: translateY(-1px);
}

.lang-picker select {
  background: rgba(255, 255, 255, 0.05); 
  color: var(--text); 
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 6px 10px; 
  border-radius: 10px; 
  cursor: pointer; 
  outline: none; 
  transition: 0.2s;
  font-size: 0.75rem;
  font-weight: 600;
}
.lang-picker select:hover { background: rgba(255,255,255,0.1); border-color: var(--brand); }

/* --- FILTROS (CHIPS) --- */
.filters { display: flex; gap: 10px; margin-bottom: 30px; flex-wrap: wrap; }
.chip {
  padding: 8px 18px; border-radius: 20px; background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1); color: white; cursor: pointer;
  font-size: 14px; transition: all 0.3s ease;
}
.chip.active, .chip:hover { background: var(--brand); color: #0b0d12; border-color: var(--brand); font-weight: 600; }

/* --- BOTONES --- */
.btn {
  padding: 12px 20px; border-radius: 14px; border: 1px solid rgba(255,255,255,.08); 
  background: var(--brand); color: #0b0d12; font-weight: 800; cursor: pointer; 
  display: inline-flex; align-items: center; transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  justify-content: center;
  border: none;
}
.btn:hover { transform: translateY(-3px); box-shadow: 0 8px 20px rgba(108, 158, 248, 0.3); filter: brightness(1.1); }
.btn:active { transform: scale(0.95); }
.btn.secondary { background: transparent; color: var(--text); border: 1px solid rgba(255,255,255,0.1); }
.btn.secondary:hover { background: rgba(255,255,255,0.05); border-color: var(--brand); }

/* --- HERO --- */
.hero { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: center; padding: 60px 0; }
.hero h1 { font-size: clamp(32px, 5vw, 52px); line-height: 1.1; margin: 0 0 20px; }
.hero p { color: var(--muted); font-size: 1.1rem; margin: 0 0 30px; }
.badge {
  display: inline-flex; background: rgba(108,158,248,.15); border: 1px solid rgba(108,158,248,.3); 
  padding: 8px 16px; border-radius: 999px; color: #cfe0ff; font-size: 13px; margin-bottom: 16px;
  transition: 0.3s; cursor: default;
}
.badge:hover { background: rgba(108,158,248,0.25); transform: scale(1.05); }

/* --- GRID Y CARDS --- */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 24px; margin-top: 20px; }
.card { background: var(--card); border: 1px solid rgba(255,255,255,.06); border-radius: 20px; overflow: hidden; display: flex; flex-direction: column; transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275); }
.card:hover { transform: translateY(-10px); box-shadow: 0 20px 40px rgba(0,0,0,0.4); border-color: rgba(108,158,248,0.3); }
.thumb { aspect-ratio: 16/10; background: #0c1220; overflow: hidden; cursor: zoom-in; }
.thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s ease; }
.card:hover .thumb img { transform: scale(1.1); }
.card-body { padding: 20px; display: flex; flex-direction: column; flex-grow: 1; }
.card-title { display: flex; justify-content: space-between; align-items: center; margin-bottom: 5px; }
.price { font-weight: 800; color: var(--accent); font-size: 1.2rem; transition: 0.3s; }
.card:hover .price { color: var(--brand); }

/* --- PORTAL CLIENTES (INPUTS) --- */
#customer-email {
  width: 100%; 
  background: rgba(255,255,255,0.05); 
  border: 1px solid rgba(255,255,255,0.1); 
  padding: 14px; 
  border-radius: 12px; 
  color: white; 
  outline: none; 
  transition: 0.3s;
  margin-bottom: 15px;
}
#customer-email::placeholder { color: rgba(255,255,255,0.3); }
#customer-email:focus {
  border-color: var(--brand);
  background: rgba(255,255,255,0.08);
  box-shadow: 0 0 0 3px rgba(108, 158, 248, 0.1);
}

/* --- ANIMACIONES Y LOADER --- */
.loader { border: 4px solid rgba(255, 255, 255, 0.1); border-left-color: var(--brand); border-radius: 50%; width: 40px; height: 40px; animation: spin 1s linear infinite; position: absolute; }
@keyframes spin { to { transform: rotate(360deg); } }

.fade-anim { animation: fadeIn 0.5s ease-out forwards; }
@keyframes fadeIn { 
  from { opacity: 0; transform: translateY(10px) scale(0.98); } 
  to { opacity: 1; transform: translateY(0) scale(1); } 
}

.drawer { position: fixed; inset: 0; display: none; z-index: 100; }
.drawer.active { display: flex; }
.drawer-overlay { position: absolute; inset: 0; background: rgba(0,0,0,0.9); backdrop-filter: blur(8px); cursor: pointer; }
#modalImg { max-width: 92%; max-height: 85vh; border-radius: 12px; object-fit: contain; display: none; }

/* --- SKELETONS --- */
@keyframes skeleton-loading { 0%, 100% { background-color: rgba(255,255,255,0.05); } 50% { background-color: rgba(255,255,255,0.12); } }
.skeleton-card { background: var(--card); border-radius: 20px; height: 400px; overflow: hidden; border: 1px solid rgba(255,255,255,0.05); }
.skeleton-img { width: 100%; aspect-ratio: 16/10; animation: skeleton-loading 1.5s infinite; }
.skeleton-line { height: 18px; margin: 15px 20px; border-radius: 6px; animation: skeleton-loading 1.5s infinite; background: rgba(255, 255, 255, 0.05); }
.skeleton-line.title { width: 70%; height: 24px; }

/* --- RESPONSIVE --- */
@media (max-width: 850px) { 
  .hero { grid-template-columns: 1fr; text-align: center; } 
  .hero-img { order: -1; }
}

@media (max-width: 600px) {
  .nav-wrap { padding: 0 12px; gap: 8px; }
  .brand span { display: none; } 
  .nav-actions { gap: 6px; }
  .nav-links-group { gap: 4px; }
  .nav-pill { padding: 5px 8px; font-size: 0.65rem; border-radius: 8px; }
  .lang-picker select { padding: 5px 4px; font-size: 0.65rem; border-radius: 8px; }
}