/* ============================================================
   PISADAS VIP — Estilos principales
   Fuentes: Rubik (headings) + Nunito Sans (body)
   Paleta: Azul #2563EB · Naranja CTA #F97316 · Fondo #F8FAFC
   ============================================================ */

/* Fuentes cargadas via <link> en head.php con preconnect para mejor rendimiento */

:root {
  --primary:   #2563EB;
  --primary-d: #1D4ED8;
  --cta:       #F97316;
  --cta-d:     #EA6C00;
  --bg:        #F8FAFC;
  --surface:   #FFFFFF;
  --text:      #1E293B;
  --muted:     #475569;
  --border:    #E2E8F0;
  --success:   #10B981;
  --danger:    #EF4444;
  --radius:    12px;
  --shadow:    0 4px 24px rgba(0,0,0,.08);
  --shadow-lg: 0 8px 40px rgba(0,0,0,.12);
  --transition: 200ms ease;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  font-family: 'Nunito Sans', sans-serif;
  background: var(--bg);
  color: var(--text);
  font-size: 16px;
  line-height: 1.65;
  min-height: 100vh;
}

h1,h2,h3,h4,h5,h6 {
  font-family: 'Rubik', sans-serif;
  line-height: 1.25;
  font-weight: 700;
}

a { color: var(--primary); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--primary-d); }
img { max-width: 100%; display: block; }

/* ── Accesibilidad ───────────────────────────────────────── */
.skip-link {
  position: absolute; top: -100%; left: 1rem;
  background: var(--primary); color: #fff; padding: .5rem 1rem;
  border-radius: 0 0 8px 8px; font-weight: 700; z-index: 9999;
  text-decoration: none; transition: top .15s;
}
.skip-link:focus { top: 0; }

/* Foco visible para teclado */
:focus-visible {
  outline: 3px solid var(--primary);
  outline-offset: 3px;
  border-radius: 4px;
}
:focus:not(:focus-visible) { outline: none; }

/* ── Utilidades ──────────────────────────────────────────── */
.container { max-width: 1200px; margin: 0 auto; padding: 0 1.25rem; }
.sr-only { position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0,0,0,0) }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  padding: .875rem 2rem; border-radius: 50px; font-family: 'Rubik', sans-serif;
  font-weight: 600; font-size: 1rem; cursor: pointer; border: none;
  transition: all var(--transition); text-decoration: none; white-space: nowrap;
}
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-d); color: #fff; transform: translateY(-1px); box-shadow: 0 4px 16px rgba(37,99,235,.35); }
.btn-cta { background: var(--cta); color: #fff; font-size: 1.1rem; padding: 1rem 2.5rem; }
.btn-cta:hover { background: var(--cta-d); color: #fff; transform: translateY(-2px); box-shadow: 0 6px 20px rgba(249,115,22,.4); }
.btn-cod { background: #16A34A; color: #fff; }
.btn-cod:hover { background: #15803D; color: #fff; transform: translateY(-1px); box-shadow: 0 4px 16px rgba(22,163,74,.35); }
.btn-outline { background: transparent; color: var(--primary); border: 2px solid var(--primary); }
.btn-outline:hover { background: var(--primary); color: #fff; }
.btn-ghost { background: rgba(255,255,255,.15); color: #fff; backdrop-filter: blur(8px); }
.btn-ghost:hover { background: rgba(255,255,255,.25); color: #fff; }
.btn:disabled { opacity: .6; cursor: not-allowed; transform: none !important; }

.badge { display: inline-block; padding: .2rem .6rem; border-radius: 50px; font-size: .75rem; font-weight: 700; }
.badge-sale { background: var(--danger); color: #fff; }
.badge-new  { background: var(--success); color: #fff; }
.badge-hot  { background: var(--cta); color: #fff; }

/* ── Navbar ──────────────────────────────────────────────── */
.navbar {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255,255,255,.95); backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  padding: .875rem 0;
}
.nav-inner { display: flex; align-items: center; position: relative; }
.nav-logo { display: flex; align-items: center; position: absolute; left: 50%; transform: translateX(-50%); }
.nav-logo img { height: 48px; width: auto; display: block; }
.nav-logo span { color: var(--primary); }
/* Desktop nav links — izquierda */
.nav-links { display: flex; flex-direction: row; gap: 1.75rem; list-style: none; margin: 0; }
.nav-links li a { color: var(--muted); font-weight: 600; font-size: .95rem; transition: color var(--transition); }
.nav-links li a:hover { color: var(--primary); }
/* Drawer móvil (oculto en desktop) */
.nav-drawer { display: none; }
.nav-drawer-header { display: none; }
.nav-overlay { display: none; }
.hamburger { display: none; }
.nav-actions { display: flex; align-items: center; gap: .75rem; margin-left: auto; }
.nav-cart { position: relative; cursor: pointer; color: var(--text); }
.cart-count {
  position: absolute; top: -8px; right: -8px;
  background: var(--cta); color: #fff; font-size: .65rem; font-weight: 700;
  width: 18px; height: 18px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
}
.hamburger { display: none; flex-direction: column; gap: 5px; cursor: pointer; background: none; border: none; padding: .25rem; }
.hamburger span { display: block; width: 24px; height: 2px; background: var(--text); border-radius: 2px; transition: transform .25s ease, opacity .25s ease; }
.hamburger.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.is-open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.hamburger.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ── Hero ────────────────────────────────────────────────── */
.hero {
  background: linear-gradient(135deg, #0F172A 0%, #1E293B 60%, #0F172A 100%);
  color: #fff; overflow: hidden; position: relative; min-height: 560px;
  display: flex; align-items: center;
}
.hero::before {
  content: ''; position: absolute; inset: 0;
  background: url("data:image/svg+xml,%3Csvg width='80' height='80' viewBox='0 0 80 80' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.03'%3E%3Ccircle cx='40' cy='40' r='2'/%3E%3Ccircle cx='0' cy='0' r='2'/%3E%3Ccircle cx='80' cy='0' r='2'/%3E%3Ccircle cx='0' cy='80' r='2'/%3E%3Ccircle cx='80' cy='80' r='2'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}
.hero::after {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(ellipse 80% 60% at 70% 50%, rgba(234,179,8,.07) 0%, transparent 70%);
  pointer-events: none;
}
.hero-content { position: relative; z-index: 1; padding: 4rem 0; }
.hero-badge { display: inline-block; background: rgba(234,179,8,.15); border: 1px solid rgba(234,179,8,.35); color: #FCD34D; padding: .4rem 1rem; border-radius: 50px; font-size: .85rem; font-weight: 600; margin-bottom: 1.25rem; letter-spacing: .03em; }
.hero h1 { font-size: clamp(2rem, 5vw, 3.5rem); margin-bottom: 1rem; line-height: 1.15; }
.hero h1 span { color: #FCD34D; }
.hero p { font-size: 1.15rem; opacity: .75; max-width: 520px; margin-bottom: 2rem; }
.hero-ctas { display: flex; gap: 1rem; flex-wrap: wrap; }
.hero-features { display: flex; gap: 2rem; margin-top: 2.5rem; flex-wrap: wrap; }
.hero-feature { display: flex; align-items: center; gap: .5rem; font-size: .9rem; opacity: .7; }
.hero-img { position: absolute; right: 0; bottom: 0; max-height: 90%; opacity: .15; }

/* ── Trust bar ───────────────────────────────────────────── */
.trust-bar { background: var(--primary); padding: .875rem 0; }
.trust-items { display: flex; gap: 2rem; justify-content: center; flex-wrap: wrap; }
.trust-item { display: flex; align-items: center; gap: .5rem; color: #fff; font-size: .9rem; font-weight: 600; }

/* ── Sección ─────────────────────────────────────────────── */
.section { padding: 5rem 0; }
.section-alt { background: #F1F5F9; }
.section-header { text-align: center; margin-bottom: 3rem; }
.section-header h2 { font-size: clamp(1.6rem, 3vw, 2.25rem); margin-bottom: .75rem; }
.section-header p { color: var(--muted); max-width: 540px; margin: 0 auto; }
.section-label { display: inline-block; color: var(--primary); font-weight: 700; font-size: .8rem; text-transform: uppercase; letter-spacing: .1em; margin-bottom: .5rem; }

/* ── Grid de productos ───────────────────────────────────── */
.products-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); gap: 1.5rem; }

.product-card {
  background: var(--surface); border-radius: var(--radius); overflow: hidden;
  box-shadow: var(--shadow); transition: all var(--transition); cursor: pointer;
}
.product-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.product-img-wrap { position: relative; aspect-ratio: 1; background: #F8FAFC; overflow: hidden; }
.product-img-wrap img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.product-card:hover .product-img-wrap img { transform: scale(1.05); }
.product-badges { position: absolute; top: .75rem; left: .75rem; display: flex; flex-direction: column; gap: .35rem; }
.product-wishlist { position: absolute; top: .75rem; right: .75rem; background: #fff; border: none; border-radius: 50%; width: 36px; height: 36px; display: flex; align-items: center; justify-content: center; cursor: pointer; box-shadow: 0 2px 8px rgba(0,0,0,.12); transition: var(--transition); }
.product-wishlist:hover { background: #FEE2E2; }
.product-info { padding: 1.25rem; }
.product-name { font-family: 'Rubik', sans-serif; font-weight: 600; font-size: 1rem; margin-bottom: .35rem; color: var(--text); }
.product-price { display: flex; align-items: center; gap: .75rem; margin-bottom: .75rem; }
.price-current { font-size: 1.2rem; font-weight: 700; color: var(--primary); }
.price-old { font-size: .9rem; color: var(--muted); text-decoration: line-through; }
.product-stars { display: flex; align-items: center; gap: .25rem; font-size: .85rem; color: var(--muted); margin-bottom: .75rem; }
.stars { color: #F59E0B; }
.product-btn { width: 100%; }

/* ── Product detail ──────────────────────────────────────── */
.product-detail { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: start; }
.product-gallery { position: sticky; top: 80px; }
.gallery-main { aspect-ratio: 1; border-radius: var(--radius); overflow: hidden; background: #F1F5F9; margin-bottom: 1rem; }
.gallery-main img { width: 100%; height: 100%; object-fit: cover; }
.gallery-thumbs { display: flex; gap: .5rem; }
.gallery-thumb { width: 70px; height: 70px; border-radius: 8px; overflow: hidden; cursor: pointer; border: 2px solid transparent; transition: var(--transition); }
.gallery-thumb.active, .gallery-thumb:hover { border-color: var(--primary); }
.gallery-thumb img { width: 100%; height: 100%; object-fit: cover; }

.product-detail-info h1 { font-size: clamp(1.6rem, 3vw, 2.2rem); margin-bottom: .5rem; }
.product-rating-bar { display: flex; align-items: center; gap: 1rem; margin-bottom: 1.25rem; padding-bottom: 1.25rem; border-bottom: 1px solid var(--border); }
.rating-score { font-size: 2rem; font-weight: 800; color: var(--text); }
.rating-details small { color: var(--muted); }
.product-price-section { margin-bottom: 1.5rem; }
.product-price-section .price-current { font-size: 2rem; }
.discount-tag { display: inline-block; background: #FEE2E2; color: var(--danger); font-size: .8rem; font-weight: 700; padding: .2rem .6rem; border-radius: 6px; margin-left: .5rem; }
.savings { color: var(--success); font-size: .9rem; margin-top: .25rem; }

.size-label { font-weight: 700; margin-bottom: .75rem; }
.sizes-grid { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 1.5rem; }
.size-btn { width: 50px; height: 50px; border: 2px solid var(--border); border-radius: 8px; background: #fff; font-family: 'Rubik', sans-serif; font-weight: 600; cursor: pointer; transition: var(--transition); }
.size-btn:hover { border-color: var(--primary); color: var(--primary); }
.size-btn.selected { border-color: var(--primary); background: var(--primary); color: #fff; }
.size-btn.out { opacity: .4; cursor: not-allowed; text-decoration: line-through; }

.qty-row { display: flex; align-items: center; gap: 1rem; margin-bottom: 1.5rem; }
.qty-control { display: flex; align-items: center; border: 2px solid var(--border); border-radius: 50px; overflow: hidden; }
.qty-btn { width: 40px; height: 40px; border: none; background: none; font-size: 1.2rem; cursor: pointer; transition: var(--transition); }
.qty-btn:hover { background: var(--primary); color: #fff; }
.qty-val { width: 48px; text-align: center; font-weight: 700; }

.add-to-cart-wrap { display: flex; gap: 1rem; margin-bottom: 1.5rem; }
.add-to-cart-wrap .btn-cta { flex: 1; }

.product-perks { display: grid; grid-template-columns: 1fr 1fr; gap: .75rem; margin-bottom: 1.5rem; }
.perk { display: flex; align-items: center; gap: .5rem; font-size: .875rem; color: var(--muted); }

.product-description { font-size: .95rem; line-height: 1.75; color: var(--muted); }

/* ── Reseñas ─────────────────────────────────────────────── */
.reviews-section { margin-top: 4rem; }
.reviews-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 2rem; flex-wrap: wrap; gap: 1rem; }
.reviews-summary { display: flex; align-items: center; gap: 2rem; }
.big-score { font-size: 4rem; font-weight: 800; line-height: 1; }
.score-bars { flex: 1; min-width: 180px; }
.score-bar-row { display: flex; align-items: center; gap: .5rem; font-size: .8rem; margin-bottom: .35rem; }
.score-bar-track { flex: 1; height: 6px; background: var(--border); border-radius: 3px; overflow: hidden; }
.score-bar-fill { height: 100%; background: #F59E0B; border-radius: 3px; }

.reviews-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 1.25rem; }
.review-card { background: var(--surface); border-radius: var(--radius); padding: 1.5rem; box-shadow: var(--shadow); }
.review-top { display: flex; align-items: center; gap: .75rem; margin-bottom: .75rem; }
.review-avatar { width: 44px; height: 44px; border-radius: 50%; background: linear-gradient(135deg,var(--primary),#60A5FA); display: flex; align-items: center; justify-content: center; color: #fff; font-weight: 700; font-size: 1.1rem; flex-shrink: 0; }
.review-name { font-weight: 700; font-size: .95rem; }
.review-date { font-size: .8rem; color: var(--muted); }
.review-verified { font-size: .75rem; color: var(--success); font-weight: 600; }
.review-text { font-size: .9rem; color: var(--muted); line-height: 1.65; }

.review-form { background: var(--surface); border-radius: var(--radius); padding: 2rem; box-shadow: var(--shadow); margin-top: 2rem; }
.review-form h3 { margin-bottom: 1.25rem; }
.form-group { margin-bottom: 1rem; }
.form-group label { display: block; font-weight: 600; font-size: .9rem; margin-bottom: .4rem; }
.form-group input, .form-group textarea, .form-group select {
  width: 100%; padding: .75rem 1rem; border: 2px solid var(--border); border-radius: var(--radius);
  font-family: 'Nunito Sans', sans-serif; font-size: .95rem; color: var(--text);
  transition: border-color var(--transition); background: var(--surface);
}
.form-group input:focus, .form-group textarea:focus, .form-group select:focus {
  outline: none; border-color: var(--primary);
}
.star-select { display: flex; gap: .25rem; margin-bottom: 1rem; }
.star-select label { font-size: 2rem; cursor: pointer; color: #CBD5E1; transition: color var(--transition); }
.star-select input { display: none; }
.star-select label:hover, .star-select label.active { color: #F59E0B; }

/* ── Checkout ────────────────────────────────────────────── */
.checkout-grid { display: grid; grid-template-columns: 1fr 380px; gap: 2rem; align-items: start; }
.checkout-box { background: var(--surface); border-radius: var(--radius); padding: 1.75rem; box-shadow: var(--shadow); margin-bottom: 1.5rem; }
.checkout-box h3 { font-size: 1.1rem; margin-bottom: 1.25rem; padding-bottom: .75rem; border-bottom: 1px solid var(--border); }
.payment-methods { display: grid; gap: .75rem; }
.payment-method { display: flex; align-items: center; gap: 1rem; padding: 1rem 1.25rem; border: 2px solid var(--border); border-radius: var(--radius); cursor: pointer; transition: var(--transition); }
.payment-method:hover { border-color: var(--primary); }
.payment-method.selected { border-color: var(--primary); background: #EFF6FF; }
.payment-icon { width: 44px; height: 44px; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 1.4rem; flex-shrink: 0; }
.payment-icon.cod { background: #FEF3C7; }
.payment-icon.stripe { background: #EDE9FE; }
.payment-icon.bank { background: #D1FAE5; }
.payment-icon.paypal { background: #DBEAFE; }
.payment-info { flex: 1; }
.payment-info strong { display: block; font-weight: 700; }
.payment-info small { color: var(--muted); font-size: .82rem; }
.payment-radio { width: 20px; height: 20px; accent-color: var(--primary); }

.order-summary-item { display: flex; align-items: center; gap: .75rem; padding: .75rem 0; border-bottom: 1px solid var(--border); }
.order-summary-item:last-child { border: none; }
.order-item-img { width: 56px; height: 56px; border-radius: 8px; object-fit: cover; background: var(--bg); flex-shrink: 0; }
.order-item-name { flex: 1; font-size: .9rem; font-weight: 600; }
.order-item-price { font-weight: 700; color: var(--primary); }
.order-total-row { display: flex; justify-content: space-between; padding: .5rem 0; font-size: .95rem; }
.order-total-row.grand { font-size: 1.1rem; font-weight: 800; border-top: 2px solid var(--border); margin-top: .5rem; padding-top: 1rem; }

/* ── Cart sidebar ────────────────────────────────────────── */
.cart-overlay { position: fixed; inset: 0; background: rgba(0,0,0,.5); z-index: 200; opacity: 0; pointer-events: none; transition: opacity var(--transition); }
.cart-overlay.open { opacity: 1; pointer-events: all; }
.cart-sidebar { position: fixed; top: 0; right: -420px; width: 420px; max-width: 100vw; height: 100vh; height: 100dvh; background: #fff; z-index: 201; box-shadow: var(--shadow-lg); display: flex; flex-direction: column; transition: right .3s ease; }
.cart-sidebar.open { right: 0; }
.cart-head { padding: 1.25rem 1.5rem; border-bottom: 1px solid var(--border); display: flex; align-items: center; justify-content: space-between; flex-shrink: 0; }
.cart-head h2 { font-size: 1.15rem; }
.cart-close { background: none; border: none; cursor: pointer; font-size: 1.5rem; color: var(--muted); line-height: 1; }
.cart-close:hover { color: var(--text); }
.cart-items { flex: 1; overflow-y: auto; padding: 1rem 1.5rem; min-height: 0; }
.cart-item { display: flex; gap: 1rem; padding: 1rem 0; border-bottom: 1px solid var(--border); }
.cart-item-img { width: 72px; height: 72px; border-radius: 8px; object-fit: cover; background: var(--bg); flex-shrink: 0; }
.cart-item-details { flex: 1; }
.cart-item-name { font-weight: 700; font-size: .9rem; margin-bottom: .25rem; }
.cart-item-meta { font-size: .82rem; color: var(--muted); }
.cart-item-price { font-weight: 700; color: var(--primary); }
.cart-item-remove { background: none; border: none; color: var(--danger); cursor: pointer; font-size: .85rem; margin-top: .35rem; }
.cart-footer { padding: 1.25rem 1.5rem; border-top: 1px solid var(--border); flex-shrink: 0; }
.cart-subtotal { display: flex; justify-content: space-between; font-size: 1rem; margin-bottom: 1rem; }
.cart-subtotal strong { font-size: 1.2rem; }
.cart-empty { text-align: center; padding: 3rem 1rem; color: var(--muted); }
.cart-empty svg { opacity: .3; margin: 0 auto 1rem; }

/* ── Toast ───────────────────────────────────────────────── */
.toast-wrap { position: fixed; bottom: 1.5rem; right: 1.5rem; z-index: 500; display: flex; flex-direction: column; gap: .5rem; }
.toast { background: #1E293B; color: #fff; padding: .875rem 1.25rem; border-radius: var(--radius); font-size: .9rem; font-weight: 600; display: flex; align-items: center; gap: .5rem; box-shadow: var(--shadow-lg); animation: slideUp .25s ease; max-width: 320px; }
.toast.success { background: var(--success); }
.toast.error   { background: var(--danger); }
@keyframes slideUp { from { opacity:0; transform: translateY(12px); } to { opacity:1; transform: translateY(0); } }

/* ── FAQ ─────────────────────────────────────────────────── */
.faq-item { border-bottom: 1px solid var(--border); }
.faq-q { display: flex; justify-content: space-between; align-items: center; padding: 1.25rem 0; cursor: pointer; font-weight: 600; gap: 1rem; }
.faq-q svg { flex-shrink: 0; transition: transform .25s; }
.faq-item.open .faq-q svg { transform: rotate(45deg); }
.faq-a { max-height: 0; overflow: hidden; transition: max-height .3s ease; color: var(--muted); font-size: .95rem; }
.faq-item.open .faq-a { max-height: 300px; padding-bottom: 1.25rem; }

/* ── Footer ──────────────────────────────────────────────── */
footer { background: #0F172A; color: rgba(255,255,255,.75); padding: 4rem 0 2rem; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 3rem; margin-bottom: 3rem; }
.footer-brand h3 { color: #fff; font-size: 1.5rem; margin-bottom: .75rem; }
.footer-brand p { font-size: .9rem; line-height: 1.7; }
footer h4 { color: #fff; font-size: .95rem; margin-bottom: 1rem; }
footer ul { list-style: none; }
footer ul li { margin-bottom: .5rem; }
footer ul a { color: rgba(255,255,255,.65); font-size: .9rem; transition: color var(--transition); }
footer ul a:hover { color: #fff; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.1); padding-top: 1.5rem; display: flex; justify-content: space-between; align-items: center; flex-wrap: gap-1rem; font-size: .85rem; }
.social-links { display: flex; gap: .75rem; }
.social-link { width: 36px; height: 36px; background: rgba(255,255,255,.1); border-radius: 8px; display: flex; align-items: center; justify-content: center; color: #fff; transition: background var(--transition); }
.social-link:hover { background: var(--primary); color: #fff; }

/* ── Admin ───────────────────────────────────────────────── */
:root {
  --gl-bg:        rgba(255,255,255,.08);
  --gl-bg-strong: rgba(255,255,255,.13);
  --gl-bg-soft:   rgba(255,255,255,.05);
  --gl-border:    rgba(255,255,255,.14);
  --gl-blur:      18px;
  --gl-text:      #F1F5F9;
  --gl-muted:     #A8B3C7;
  --gl-primary:   #60A5FA;
  --gl-accent:    #22C55E;
}

.admin-layout {
  display: flex; min-height: 100vh; position: relative; isolation: isolate;
  background: #0B1120; color: var(--gl-text);
  /* Sobreescribe variables globales para que todo el admin herede el tema oscuro */
  --muted:   #A8B3C7;
  --text:    #F1F5F9;
  --border:  rgba(255,255,255,.14);
  --surface: rgba(255,255,255,.08);
  --shadow:  0 8px 32px rgba(0,0,0,.25);
  --shadow-lg: 0 20px 60px rgba(0,0,0,.4);
}
.admin-layout::before {
  content: ''; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(circle at 12% 8%,  rgba(37,99,235,.35)  0%, transparent 45%),
    radial-gradient(circle at 88% 18%, rgba(168,85,247,.28) 0%, transparent 45%),
    radial-gradient(circle at 25% 90%, rgba(34,197,94,.20)  0%, transparent 45%),
    radial-gradient(circle at 80% 85%, rgba(249,115,22,.18) 0%, transparent 45%),
    linear-gradient(135deg, #0B1120 0%, #0F172A 50%, #0B1120 100%);
  filter: blur(60px);
}
.admin-sidebar {
  width: 260px; flex-shrink: 0; display: flex; flex-direction: column;
  background: var(--gl-bg-soft);
  backdrop-filter: blur(var(--gl-blur)); -webkit-backdrop-filter: blur(var(--gl-blur));
  border-right: 1px solid var(--gl-border);
  color: var(--gl-text);
}
.admin-logo { padding: 1.5rem; font-family: 'Rubik', sans-serif; font-size: 1.2rem; font-weight: 700; border-bottom: 1px solid var(--gl-border); }
.admin-logo span { color: #60A5FA; }
.admin-nav { flex: 1; padding: 1rem .75rem; }
.admin-nav a {
  display: flex; align-items: center; gap: .75rem; padding: .7rem 1rem; margin-bottom: .25rem;
  color: var(--gl-muted); font-size: .9rem; font-weight: 600; border-radius: 10px;
  border: 1px solid transparent; transition: background var(--transition), color var(--transition), border-color var(--transition);
}
.admin-nav a:hover { color: var(--gl-text); background: var(--gl-bg); border-color: var(--gl-border); }
.admin-nav a.active {
  color: #fff; background: rgba(37,99,235,.28); border: 1px solid rgba(96,165,250,.4);
  box-shadow: 0 4px 18px rgba(37,99,235,.25);
}
.admin-main { flex: 1; display: flex; flex-direction: column; overflow: hidden; }
.admin-topbar {
  background: var(--gl-bg-soft);
  backdrop-filter: blur(var(--gl-blur)); -webkit-backdrop-filter: blur(var(--gl-blur));
  border-bottom: 1px solid var(--gl-border);
  padding: 1rem 1.5rem; display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: .75rem;
  color: var(--gl-text);
}
.admin-topbar h1 { font-size: 1.2rem; color: var(--gl-text); }
.admin-content { flex: 1; overflow-y: auto; padding: 1.5rem; color: var(--gl-text); }
.stat-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 1.25rem; margin-bottom: 2rem; }
.stat-card {
  background: var(--gl-bg);
  backdrop-filter: blur(var(--gl-blur)); -webkit-backdrop-filter: blur(var(--gl-blur));
  border: 1px solid var(--gl-border);
  border-radius: var(--radius); padding: 1.5rem;
  box-shadow: 0 8px 32px rgba(0,0,0,.25);
  transition: transform var(--transition), border-color var(--transition), background var(--transition);
}
.stat-card:hover { background: var(--gl-bg-strong); border-color: rgba(255,255,255,.22); transform: translateY(-2px); }
.stat-card .stat-label { font-size: .85rem; color: var(--gl-muted); font-weight: 600; text-transform: uppercase; letter-spacing: .05em; margin-bottom: .5rem; }
.stat-card .stat-value { font-size: 2rem; font-weight: 800; color: var(--gl-text); font-family: 'Rubik', sans-serif; }
.stat-card .stat-change { font-size: .82rem; margin-top: .25rem; }
.stat-card .stat-icon {
  width: 48px; height: 48px; border-radius: 12px; display: flex; align-items: center; justify-content: center; margin-bottom: 1rem;
  background: rgba(255,255,255,.10) !important;
  border: 1px solid var(--gl-border);
  backdrop-filter: blur(6px);
}

.table-wrap {
  background: var(--gl-bg);
  backdrop-filter: blur(var(--gl-blur)); -webkit-backdrop-filter: blur(var(--gl-blur));
  border: 1px solid var(--gl-border);
  border-radius: var(--radius); overflow: hidden;
  box-shadow: 0 8px 32px rgba(0,0,0,.25);
}
table { width: 100%; border-collapse: collapse; }
th {
  padding: .875rem 1rem; text-align: left; font-size: .8rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em;
  color: var(--gl-muted); background: rgba(255,255,255,.04); border-bottom: 1px solid var(--gl-border);
}
td { padding: .875rem 1rem; border-bottom: 1px solid var(--gl-border); font-size: .9rem; vertical-align: middle; color: var(--gl-text); }
tr:last-child td { border: none; }
tr:hover td { background: rgba(255,255,255,.05); }

.status-pill { padding: .25rem .75rem; border-radius: 50px; font-size: .78rem; font-weight: 700; border: 1px solid transparent; backdrop-filter: blur(4px); }
.status-new        { background: rgba(59,130,246,.18);  color: #93C5FD; border-color: rgba(147,197,253,.3); }
.status-processing { background: rgba(217,119,6,.18);   color: #FCD34D; border-color: rgba(252,211,77,.3); }
.status-shipped    { background: rgba(6,182,212,.18);   color: #67E8F9; border-color: rgba(103,232,249,.3); }
.status-delivered  { background: rgba(34,197,94,.18);   color: #86EFAC; border-color: rgba(134,239,172,.3); }
.status-cancelled  { background: rgba(239,68,68,.18);   color: #FCA5A5; border-color: rgba(252,165,165,.3); }
.status-paid       { background: rgba(34,197,94,.18);   color: #86EFAC; border-color: rgba(134,239,172,.3); }
.status-pending    { background: rgba(217,119,6,.18);   color: #FCD34D; border-color: rgba(252,211,77,.3); }

/* Botones e inputs dentro del admin (glass) */
.admin-content .btn-outline,
.admin-topbar .btn-outline {
  background: var(--gl-bg); color: var(--gl-text); border: 1px solid var(--gl-border);
  backdrop-filter: blur(8px);
}
.admin-content .btn-outline:hover,
.admin-topbar .btn-outline:hover { background: var(--gl-bg-strong); color: #fff; }
.admin-content input[type="text"],
.admin-content input[type="email"],
.admin-content input[type="date"],
.admin-content input[type="password"],
.admin-content select,
.admin-content textarea {
  background: var(--gl-bg); border: 1px solid var(--gl-border); color: var(--gl-text);
  backdrop-filter: blur(6px);
}
.admin-content input::placeholder, .admin-content textarea::placeholder { color: var(--gl-muted); }
.admin-content label { color: var(--gl-text); }
.admin-content a:not(.btn) { color: var(--gl-primary); }
.admin-content h2, .admin-content h3 { color: var(--gl-text); }

/* ── Responsive ──────────────────────────────────────────── */

/* Tablet grande */
@media (max-width: 1024px) {
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 2rem; }
  .checkout-grid { grid-template-columns: 1fr; }
  .product-detail { grid-template-columns: 1fr; gap: 2rem; }
  .product-gallery { position: static; }
  .admin-sidebar { width: 220px; }
  .reviews-summary { flex-direction: column; align-items: flex-start; gap: 1rem; }
}

/* Tablet / móvil grande */
@media (max-width: 768px) {
  /* Navbar móvil */
  .nav-links { display: none !important; }
  .hamburger { display: flex; z-index: 200; position: relative; }
  .nav-logo { position: absolute; left: 50%; transform: translateX(-50%); margin: 0; }
  .nav-inner { position: relative; justify-content: space-between; }
  .nav-actions { margin-left: 0; }
  /* Drawer */
  .nav-drawer { display: flex; flex-direction: column; list-style: none; margin: 0; padding: 0; position: fixed; top: 0; left: 0; bottom: 0; width: 78vw; max-width: 290px; background: #fff; z-index: 9999; box-shadow: 8px 0 32px rgba(0,0,0,.2); transform: translateX(-110%); transition: transform .28s cubic-bezier(.4,0,.2,1); pointer-events: none; overflow-y: auto; }
  .nav-drawer.mobile-open { transform: translateX(0); pointer-events: auto; }
  .nav-drawer-header { display: block; padding: 1.25rem 1.5rem 1rem; border-bottom: 2px solid var(--border); margin-bottom: .5rem; }
  .nav-drawer li { width: 100%; }
  .nav-drawer li a { display: block; font-size: 1.05rem; font-weight: 700; color: #1E293B; padding: 1rem 1.5rem; border-bottom: 1px solid #f1f5f9; text-decoration: none; }
  .nav-drawer li a:active { background: #EFF6FF; color: var(--primary); }
  .nav-overlay { display: none; position: fixed; inset: 0; background: rgba(0,0,0,.5); z-index: 9998; }
  .nav-overlay.active { display: block; }

  /* Hero */
  .hero { min-height: auto; }
  .hero-content { padding: 3rem 0 2rem; }
  .hero h1 { font-size: 2rem; }
  .hero p { font-size: 1rem; }
  .hero-ctas { flex-direction: column; }
  .hero-ctas .btn { width: 100%; justify-content: center; }
  .hero-features { flex-direction: column; gap: .75rem; }
  .hero-img { display: none; }

  /* Trust bar */
  .trust-items { flex-direction: column; gap: .75rem; text-align: center; }

  /* Sección */
  .section { padding: 3rem 0; }
  .section-header { margin-bottom: 2rem; }

  /* Productos grid */
  .products-grid { grid-template-columns: repeat(2, 1fr); gap: 1rem; }
  .product-info { padding: .875rem; }
  .product-name { font-size: .9rem; }
  .price-current { font-size: 1.05rem; }

  /* Producto detalle */
  .product-detail { grid-template-columns: 1fr; gap: 1.5rem; }
  .gallery-main { max-height: 320px; }
  .gallery-thumbs { gap: .35rem; }
  .gallery-thumb { width: 56px; height: 56px; }
  .product-detail-info h1 { font-size: 1.5rem; }
  .product-price-section .price-current { font-size: 1.6rem; }
  .add-to-cart-wrap { flex-direction: column; }
  .add-to-cart-wrap .btn { width: 100%; justify-content: center; }
  .product-perks { grid-template-columns: 1fr 1fr; }
  .sizes-grid { gap: .35rem; }
  .size-btn { width: 44px; height: 44px; font-size: .85rem; }

  /* Reseñas */
  .reviews-grid { grid-template-columns: 1fr; }
  .reviews-header { flex-direction: column; }
  .reviews-summary { flex-direction: row; flex-wrap: wrap; gap: 1rem; }
  .big-score { font-size: 3rem; }

  /* Checkout */
  .checkout-grid { grid-template-columns: 1fr; }
  .checkout-box { padding: 1.25rem; }

  /* Footer */
  .footer-grid { grid-template-columns: 1fr; gap: 1.75rem; }
  .footer-bottom { flex-direction: column; gap: .75rem; text-align: center; }

  /* Admin */
  .admin-layout { flex-direction: column; }
  .admin-sidebar { width: 100%; }
  .admin-nav { display: flex; overflow-x: auto; padding: 0; flex-direction: row; }
  .admin-nav a { white-space: nowrap; border-right: none; border-bottom: 3px solid transparent; }
  .admin-nav a.active { border-bottom-color: #2563EB; border-right: none; }
  .stat-cards { grid-template-columns: repeat(2, 1fr); }

  /* Cart sidebar */
  .cart-sidebar { width: 100%; right: -100%; }

  /* COD Modal */
  .cod-modal-box { margin: .5rem; max-height: 95vh; border-radius: 12px; }
  .pack-cards { gap: .5rem; }
  .pack-card { padding: .75rem .5rem; min-width: 0; flex: 1; }

  /* Toast */
  .toast-wrap { left: 1rem; right: 1rem; bottom: 1rem; }
  .toast { max-width: 100%; }
}

/* Móvil pequeño */
@media (max-width: 480px) {
  /* Container */
  .container { padding: 0 1rem; }

  /* Navbar */
  .nav-logo img { height: 38px; }

  /* Hero */
  .hero-content { padding: 2.5rem 0 1.5rem; }
  .hero h1 { font-size: 1.7rem; }
  .hero-badge { font-size: .75rem; }

  /* Productos */
  .products-grid { grid-template-columns: repeat(2, 1fr); gap: .75rem; }
  .product-info { padding: .75rem; }
  .product-btn { font-size: .85rem; padding: .6rem 1rem; }

  /* Producto detalle */
  .gallery-main { max-height: 280px; }
  .product-detail-info h1 { font-size: 1.3rem; }
  .product-price-section .price-current { font-size: 1.4rem; }
  .product-perks { grid-template-columns: 1fr; }
  .size-btn { width: 42px; height: 42px; font-size: .8rem; }
  .qty-val { width: 36px; }

  /* Rating bar en detalle */
  .product-rating-bar { flex-wrap: wrap; gap: .5rem; }

  /* Reseñas */
  .review-card { padding: 1rem; }
  .big-score { font-size: 2.5rem; }

  /* Sección */
  .section { padding: 2.5rem 0; }
  .section-header h2 { font-size: 1.4rem; }

  /* Botones globales */
  .btn { font-size: .9rem; padding: .75rem 1.25rem; }
  .btn-cta { font-size: 1rem; padding: .875rem 1.5rem; }

  /* Checkout */
  .checkout-box { padding: 1rem; }

  /* Admin */
  .stat-cards { grid-template-columns: 1fr; }
  .admin-content { padding: 1rem; }
  .table-wrap { overflow-x: auto; }

  /* COD Modal */
  .pack-cards { flex-direction: column; }
  .pack-card { flex-direction: row; align-items: center; gap: 1rem; padding: .75rem 1rem; }
  .pack-img { font-size: 1.5rem; }
  .pack-label { font-size: .8rem; }
  .pack-price { font-size: 1rem; }
  .cod-form-group { margin-bottom: .75rem; }
}

/* Muy pequeño */
@media (max-width: 360px) {
  .products-grid { grid-template-columns: 1fr; }
  .hero h1 { font-size: 1.5rem; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
