/* =========================================================
   NOVA X — Componentes
   ========================================================= */

/* ---------- Marquee superior ---------- */
.marquee-bar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--marquee-h);
  z-index: calc(var(--z-header) + 1);
  background: var(--gradient-brand);
  overflow: hidden;
  display: flex;
  align-items: center;
}

.marquee-track {
  display: flex;
  gap: var(--space-8);
  white-space: nowrap;
  animation: marqueeScroll 22s linear infinite;
  will-change: transform;
}

.marquee-track span {
  font-family: var(--font-accent);
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: 0.04em;
  color: #fff;
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
}

.marquee-track span::before {
  content: "✦";
}

/* ---------- Header ---------- */
.site-header {
  position: fixed;
  top: var(--marquee-h);
  left: 0;
  right: 0;
  height: var(--header-h);
  z-index: var(--z-header);
  display: flex;
  align-items: center;
  background: transparent;
  transition: height var(--dur-med) var(--ease-out), background var(--dur-med) var(--ease-out),
    box-shadow var(--dur-med) var(--ease-out), backdrop-filter var(--dur-med) var(--ease-out);
}

.site-header.is-scrolled {
  height: var(--header-h-scrolled);
  background: var(--glass-bg);
  backdrop-filter: blur(var(--glass-blur));
  -webkit-backdrop-filter: blur(var(--glass-blur));
  box-shadow: var(--shadow-sm);
  border-bottom: 1px solid var(--color-border);
}

.header-inner {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--space-5);
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: var(--space-6);
}

.logo {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  display: flex;
  align-items: baseline;
  gap: 2px;
}

.logo .x {
  background: var(--gradient-brand);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  display: inline-block;
  transition: transform var(--dur-med) var(--ease-spring);
}

.logo:hover .x {
  transform: rotate(-8deg) scale(1.15);
}

.main-nav {
  display: flex;
  align-items: center;
  gap: var(--space-6);
  justify-self: center;
}

.main-nav a {
  font-size: var(--fs-small);
  font-weight: 500;
  color: var(--color-text-muted);
  position: relative;
  padding-block: 4px;
  transition: color var(--dur-fast) var(--ease-out);
}

.main-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 0;
  height: 2px;
  background: var(--gradient-brand);
  transition: width var(--dur-med) var(--ease-out);
  border-radius: var(--radius-pill);
}

.main-nav a:hover,
.main-nav a.is-active {
  color: var(--color-text);
}

.main-nav a:hover::after,
.main-nav a.is-active::after {
  width: 100%;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

.icon-btn {
  position: relative;
  width: 42px;
  height: 42px;
  border-radius: var(--radius-pill);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  background: var(--color-surface);
  color: var(--color-text);
  transition: transform var(--dur-fast) var(--ease-spring), background var(--dur-fast) var(--ease-out);
}

.icon-btn:hover {
  transform: translateY(-2px);
  background: var(--color-surface-2);
}

.badge-count {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 18px;
  height: 18px;
  padding-inline: 4px;
  border-radius: var(--radius-pill);
  background: var(--gradient-brand);
  color: #fff;
  font-size: 0.65rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  transform: scale(0);
  transition: transform var(--dur-fast) var(--ease-spring);
}

.badge-count.is-visible {
  transform: scale(1);
}

/* ---------- Buscador ---------- */
.search-wrap {
  position: relative;
}

.search-box {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  background: var(--color-surface);
  border-radius: var(--radius-pill);
  padding: 8px 16px;
  width: 260px;
  transition: width var(--dur-med) var(--ease-out), box-shadow var(--dur-med) var(--ease-out);
}

.search-box:focus-within {
  width: 320px;
  box-shadow: var(--shadow-sm);
}

.search-box input {
  flex: 1;
  background: transparent;
  font-size: var(--fs-small);
}

.search-results {
  position: absolute;
  top: calc(100% + 10px);
  left: 0;
  right: 0;
  background: var(--color-bg-elevated);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--color-border);
  overflow: hidden;
  max-height: 420px;
  overflow-y: auto;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px);
  transition: all var(--dur-med) var(--ease-out);
  z-index: var(--z-header);
}

.search-results.is-open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.search-result-item {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-4);
  transition: background var(--dur-fast);
}

.search-result-item:hover {
  background: var(--color-surface);
}

.search-result-item img {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-sm);
  object-fit: cover;
}

.search-result-item .info strong {
  display: block;
  font-size: var(--fs-small);
}

.search-result-item .info span {
  font-size: var(--fs-xs);
  color: var(--color-text-muted);
}

.search-empty {
  padding: var(--space-5);
  text-align: center;
  color: var(--color-text-muted);
  font-size: var(--fs-small);
}

/* ---------- Botones ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: 13px 28px;
  border-radius: var(--radius-pill);
  font-family: var(--font-accent);
  font-weight: 600;
  font-size: var(--fs-small);
  transition: transform var(--dur-fast) var(--ease-spring), box-shadow var(--dur-med) var(--ease-out),
    background var(--dur-fast) var(--ease-out);
  white-space: nowrap;
}

.btn:active {
  transform: scale(0.97);
}

.btn-primary {
  background: var(--gradient-brand);
  color: #fff;
  box-shadow: var(--shadow-glow-purple);
}

.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 14px 34px rgba(124, 58, 237, 0.4);
}

.btn-ghost {
  background: var(--color-surface);
  color: var(--color-text);
}

.btn-ghost:hover {
  background: var(--color-surface-2);
  transform: translateY(-2px);
}

.btn-outline {
  border: 1.5px solid var(--color-border);
  color: var(--color-text);
}

.btn-outline:hover {
  border-color: var(--color-blue);
  color: var(--color-blue);
}

.btn-block {
  width: 100%;
}

.btn-sm {
  padding: 9px 18px;
  font-size: var(--fs-xs);
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none !important;
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 88vh;
  display: flex;
  align-items: center;
  overflow: hidden;
  perspective: 1200px;
}

.hero-slider {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  overflow: hidden;
  transition: opacity 1.1s var(--ease-out);
}

.hero-slide.is-active {
  opacity: 1;
}

.hero-slide-media {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  will-change: transform;
}

.hero-slide::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(11, 16, 32, 0.55), rgba(11, 16, 32, 0.75));
}

[data-theme="light"] .hero-slide::after,
:root:not([data-theme="dark"]) .hero-slide::after {
  background: linear-gradient(180deg, rgba(11, 16, 32, 0.35), rgba(11, 16, 32, 0.65));
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--space-5);
  width: 100%;
  color: #fff;
  transform-style: preserve-3d;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-family: var(--font-accent);
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 8px 16px;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(10px);
  margin-bottom: var(--space-5);
}

.hero-title {
  font-size: var(--fs-display-xl);
  font-weight: 700;
  max-width: 16ch;
  transform: translateZ(40px);
  text-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
}

.hero-subtitle {
  margin-top: var(--space-4);
  font-size: 1.1rem;
  max-width: 46ch;
  color: rgba(255, 255, 255, 0.85);
  transform: translateZ(20px);
}

.hero-actions {
  margin-top: var(--space-6);
  display: flex;
  gap: var(--space-4);
  transform: translateZ(30px);
}

.hero-dots {
  position: absolute;
  bottom: var(--space-7);
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  display: flex;
  gap: var(--space-2);
}

.hero-dot {
  width: 30px;
  height: 4px;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.35);
  transition: background var(--dur-med) var(--ease-out);
}

.hero-dot.is-active {
  background: #fff;
}

.hero-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  width: 48px;
  height: 48px;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.14);
  backdrop-filter: blur(10px);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  transition: background var(--dur-fast);
}

.hero-arrow:hover {
  background: rgba(255, 255, 255, 0.28);
}

.hero-arrow.prev { left: var(--space-5); }
.hero-arrow.next { right: var(--space-5); }

/* ---------- Categorías ---------- */
.categories-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: var(--space-4);
}

.category-card {
  display: block;
  position: relative;
  padding: var(--space-6) var(--space-4);
  border-radius: var(--radius-lg);
  text-align: center;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  backdrop-filter: blur(var(--glass-blur));
  -webkit-backdrop-filter: blur(var(--glass-blur));
  box-shadow: var(--shadow-sm);
  transition: transform var(--dur-med) var(--ease-spring), box-shadow var(--dur-med) var(--ease-out);
  overflow: hidden;
}

.category-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--gradient-brand-soft);
  opacity: 0;
  transition: opacity var(--dur-med) var(--ease-out);
}

.category-card:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: var(--shadow-glow-blue);
}

.category-card:hover::before {
  opacity: 1;
}

.category-icon {
  font-size: 2.2rem;
  margin-bottom: var(--space-3);
  position: relative;
  z-index: 1;
}

.category-card h3 {
  font-size: var(--fs-title);
  position: relative;
  z-index: 1;
}

.category-card p {
  font-size: var(--fs-xs);
  color: var(--color-text-muted);
  margin-top: var(--space-1);
  position: relative;
  z-index: 1;
}

/* ---------- Grid de productos ---------- */
.products-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-5);
}

.products-grid.cols-3 {
  grid-template-columns: repeat(3, 1fr);
}

/* ---------- Product card ---------- */
.product-card {
  position: relative;
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: transform var(--dur-med) var(--ease-spring), box-shadow var(--dur-med) var(--ease-out);
}

.product-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
}

.product-media {
  display: block;
  position: relative;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: var(--color-surface);
}

.product-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: opacity var(--dur-med) var(--ease-out), transform var(--dur-slow) var(--ease-out);
}

.product-media img.img-alt {
  position: absolute;
  inset: 0;
  opacity: 0;
}

.product-card:hover .product-media img.img-base {
  opacity: 0;
}

.product-card:hover .product-media img.img-alt {
  opacity: 1;
}

.product-card:hover .product-media img {
  transform: scale(1.04);
}

.product-badges {
  position: absolute;
  top: var(--space-3);
  left: var(--space-3);
  display: flex;
  flex-direction: column;
  gap: 6px;
  z-index: 2;
}

.badge {
  font-family: var(--font-accent);
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  padding: 5px 10px;
  border-radius: var(--radius-pill);
  color: #fff;
  text-transform: uppercase;
}

.badge-nuevo { background: var(--color-blue); }
.badge-oferta { background: var(--danger); }
.badge-mas-vendido { background: var(--color-purple); }

.product-fav {
  position: absolute;
  top: var(--space-3);
  right: var(--space-3);
  z-index: 2;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-text);
  transition: transform var(--dur-fast) var(--ease-spring);
}

.product-fav:hover {
  transform: scale(1.12);
}

.product-fav.is-active {
  color: var(--danger);
}

.product-quickview {
  position: absolute;
  left: 50%;
  bottom: var(--space-3);
  transform: translate(-50%, 16px);
  opacity: 0;
  z-index: 2;
  transition: all var(--dur-med) var(--ease-out);
}

.product-card:hover .product-quickview {
  opacity: 1;
  transform: translate(-50%, 0);
}

.product-info {
  padding: var(--space-4);
}

.product-brand {
  font-size: var(--fs-xs);
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.product-name {
  font-size: 0.98rem;
  font-weight: 600;
  margin-top: 2px;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.product-rating {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 6px;
  font-size: var(--fs-xs);
  color: var(--color-text-muted);
}

.product-rating .stars {
  color: var(--warning);
}

.product-price-row {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-top: var(--space-2);
}

.product-price {
  font-family: var(--font-accent);
  font-weight: 700;
  font-size: 1.05rem;
}

.product-price-old {
  font-size: var(--fs-xs);
  color: var(--color-text-soft);
  text-decoration: line-through;
}

.product-add {
  margin-top: var(--space-3);
  width: 100%;
}

/* ---------- Filtros ---------- */
.toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  margin-bottom: var(--space-6);
  flex-wrap: wrap;
}

.filters-bar {
  display: flex;
  gap: var(--space-2);
  flex-wrap: wrap;
}

.chip {
  padding: 8px 16px;
  border-radius: var(--radius-pill);
  background: var(--color-surface);
  font-size: var(--fs-small);
  font-weight: 500;
  transition: all var(--dur-fast) var(--ease-out);
}

.chip.is-active,
.chip:hover {
  background: var(--gradient-brand);
  color: #fff;
}

.select-sort {
  padding: 10px 16px;
  border-radius: var(--radius-md);
  background: var(--color-surface);
  font-size: var(--fs-small);
}

/* ---------- Drawer carrito ---------- */
.overlay {
  position: fixed;
  inset: 0;
  background: rgba(11, 16, 32, 0.5);
  backdrop-filter: blur(4px);
  z-index: var(--z-drawer);
  opacity: 0;
  visibility: hidden;
  transition: all var(--dur-med) var(--ease-out);
}

.overlay.is-open {
  opacity: 1;
  visibility: visible;
}

.drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(420px, 92vw);
  background: var(--color-bg-elevated);
  z-index: calc(var(--z-drawer) + 1);
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform var(--dur-slow) var(--ease-out);
  box-shadow: var(--shadow-lg);
}

.drawer.is-open {
  transform: translateX(0);
}

.drawer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-5);
  border-bottom: 1px solid var(--color-border);
}

.drawer-body {
  flex: 1;
  overflow-y: auto;
  padding: var(--space-5);
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

.drawer-footer {
  padding: var(--space-5);
  border-top: 1px solid var(--color-border);
}

.cart-item {
  display: grid;
  grid-template-columns: 72px 1fr auto;
  gap: var(--space-3);
  align-items: center;
}

.cart-item img {
  width: 72px;
  height: 72px;
  object-fit: cover;
  border-radius: var(--radius-md);
}

.cart-item-name {
  font-size: var(--fs-small);
  font-weight: 600;
}

.cart-item-price {
  font-size: var(--fs-xs);
  color: var(--color-text-muted);
}

.qty-control {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  margin-top: 6px;
  background: var(--color-surface);
  border-radius: var(--radius-pill);
  padding: 4px;
}

.qty-control button {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--color-bg-elevated);
  font-weight: 700;
}

.cart-item-remove {
  justify-self: end;
  color: var(--color-text-soft);
  font-size: 1.1rem;
}

.cart-item-remove:hover {
  color: var(--danger);
}

.cart-empty {
  text-align: center;
  padding: var(--space-8) 0;
  color: var(--color-text-muted);
}

.summary-row {
  display: flex;
  justify-content: space-between;
  font-size: var(--fs-small);
  margin-bottom: var(--space-2);
  color: var(--color-text-muted);
}

.summary-row.total {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--color-text);
  margin-top: var(--space-3);
}

/* ---------- Modal vista rápida ---------- */
.modal {
  position: fixed;
  inset: 0;
  z-index: var(--z-modal);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-5);
  opacity: 0;
  visibility: hidden;
  transition: all var(--dur-med) var(--ease-out);
}

.modal.is-open {
  opacity: 1;
  visibility: visible;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(11, 16, 32, 0.55);
  backdrop-filter: blur(6px);
}

.modal-box {
  position: relative;
  z-index: 1;
  width: min(880px, 100%);
  max-height: 88vh;
  overflow-y: auto;
  background: var(--color-bg-elevated);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  display: grid;
  grid-template-columns: 1fr 1fr;
  transform: scale(0.92) translateY(20px);
  transition: transform var(--dur-med) var(--ease-spring);
}

.modal.is-open .modal-box {
  transform: scale(1) translateY(0);
}

.modal-close {
  position: absolute;
  top: var(--space-4);
  right: var(--space-4);
  z-index: 2;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--color-surface);
  font-size: 1.1rem;
}

.modal-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.modal-info {
  padding: var(--space-6);
  display: flex;
  flex-direction: column;
}

/* ---------- Badges de stock / notas ---------- */
.stock-note {
  font-size: var(--fs-xs);
  color: var(--success);
  margin-top: var(--space-3);
}

/* ---------- Toasts ---------- */
.toast-container {
  position: fixed;
  bottom: var(--space-5);
  left: 50%;
  transform: translateX(-50%);
  z-index: var(--z-toast);
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  align-items: center;
}

.toast {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  background: var(--color-text);
  color: var(--color-bg);
  padding: 12px 22px;
  border-radius: var(--radius-pill);
  font-size: var(--fs-small);
  font-weight: 500;
  box-shadow: var(--shadow-lg);
  animation: toastIn var(--dur-med) var(--ease-spring);
}

.toast.is-leaving {
  animation: toastOut var(--dur-fast) var(--ease-out) forwards;
}

.toast-icon {
  font-size: 1rem;
}

/* ---------- WhatsApp flotante ---------- */
.whatsapp-fab {
  position: fixed;
  bottom: var(--space-6);
  right: var(--space-6);
  z-index: 90;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: #25d366;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-lg);
  transition: transform var(--dur-fast) var(--ease-spring), box-shadow var(--dur-med) var(--ease-out);
}

.whatsapp-fab svg {
  display: block;
}

.whatsapp-fab:hover {
  transform: scale(1.08);
  box-shadow: 0 0 30px rgba(37, 211, 102, 0.55), var(--shadow-lg);
}

/* ---------- Testimonios ---------- */
.testimonials-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-5);
}

.testimonial-card {
  padding: var(--space-6);
  border-radius: var(--radius-lg);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
}

.testimonial-stars {
  color: var(--warning);
  margin-bottom: var(--space-3);
}

.testimonial-author {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin-top: var(--space-5);
}

.testimonial-author img {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  object-fit: cover;
}

.testimonial-author strong {
  font-size: var(--fs-small);
  display: block;
}

.testimonial-author span {
  font-size: var(--fs-xs);
  color: var(--color-text-muted);
}

/* ---------- Marcas ---------- */
.brands-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-6);
  flex-wrap: wrap;
  opacity: 0.7;
}

.brands-row span {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.3rem;
  color: var(--color-text-muted);
}

/* ---------- FAQ ---------- */
.faq-list {
  max-width: 780px;
  margin-inline: auto;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.faq-item {
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--color-bg-elevated);
}

.faq-question {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-5);
  font-weight: 600;
  text-align: left;
}

.faq-icon {
  transition: transform var(--dur-med) var(--ease-out);
}

.faq-item.is-open .faq-icon {
  transform: rotate(45deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height var(--dur-med) var(--ease-out);
  color: var(--color-text-muted);
  font-size: var(--fs-small);
}

.faq-answer-inner {
  padding: 0 var(--space-5) var(--space-5);
}

/* ---------- Newsletter ---------- */
.newsletter {
  background: var(--gradient-brand);
  border-radius: var(--radius-lg);
  padding: var(--space-8);
  text-align: center;
  color: #fff;
  position: relative;
  overflow: hidden;
}

.newsletter h2 {
  font-size: var(--fs-display-md);
}

.newsletter p {
  margin-top: var(--space-2);
  opacity: 0.9;
}

.newsletter-form {
  margin-top: var(--space-5);
  display: flex;
  gap: var(--space-2);
  max-width: 440px;
  margin-inline: auto;
}

.newsletter-form input {
  flex: 1;
  padding: 13px 20px;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
  backdrop-filter: blur(10px);
}

.newsletter-form input::placeholder {
  color: rgba(255, 255, 255, 0.75);
}

.newsletter-form .btn {
  background: #fff;
  color: var(--color-purple);
}

/* ---------- Footer ---------- */
/* El footer siempre usa un esquema oscuro propio, sin importar
   el modo claro/oscuro del sitio, para diferenciarse del body. */
.site-footer {
  --color-bg-elevated: #1a2333;
  --color-surface: #111827;
  --color-surface-2: #1a2333;
  --color-border: rgba(255, 255, 255, 0.1);
  --color-text: #ffffff;
  --color-text-muted: #b7bed1;
  --color-text-soft: #8a92a8;

  background: var(--color-surface);
  color: var(--color-text);
  padding-block: var(--space-8) var(--space-6);
  margin-top: var(--space-8);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: var(--space-6);
}

.footer-brand p {
  color: var(--color-text-muted);
  font-size: var(--fs-small);
  margin-top: var(--space-3);
  max-width: 32ch;
}

.footer-social {
  display: flex;
  gap: var(--space-3);
  margin-top: var(--space-5);
}

.social-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  color: var(--color-text-muted);
  transition: transform var(--dur-fast) var(--ease-spring),
    color var(--dur-med) var(--ease-out),
    background var(--dur-med) var(--ease-out),
    border-color var(--dur-med) var(--ease-out),
    box-shadow var(--dur-med) var(--ease-out);
}

.social-icon svg {
  display: block;
}

.social-icon:hover,
.social-icon:focus-visible {
  color: #fff;
  background: var(--gradient-brand);
  border-color: transparent;
  transform: translateY(-4px) scale(1.06);
  box-shadow: var(--shadow-glow-purple);
}

.footer-col h4 {
  font-size: var(--fs-small);
  margin-bottom: var(--space-4);
}

.footer-col ul {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.footer-col a {
  font-size: var(--fs-small);
  color: var(--color-text-muted);
  transition: color var(--dur-fast);
}

.footer-col a:hover {
  color: var(--color-blue);
}

.payment-icons {
  display: flex;
  gap: var(--space-2);
  margin-top: var(--space-3);
  flex-wrap: wrap;
}

.payment-icons span {
  font-size: var(--fs-xs);
  padding: 6px 10px;
  background: var(--color-bg-elevated);
  border-radius: var(--radius-sm);
  border: 1px solid var(--color-border);
}

.footer-bottom {
  margin-top: var(--space-7);
  padding-top: var(--space-5);
  border-top: 1px solid var(--color-border);
  display: flex;
  justify-content: space-between;
  font-size: var(--fs-xs);
  color: var(--color-text-soft);
  flex-wrap: wrap;
  gap: var(--space-2);
}

/* ---------- Formularios (checkout, contacto, perfil) ---------- */
.form-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-4);
}

.form-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-field.full {
  grid-column: 1 / -1;
}

.form-field label {
  font-size: var(--fs-xs);
  font-weight: 600;
  color: var(--color-text-muted);
}

.form-field input,
.form-field select,
.form-field textarea {
  padding: 12px 16px;
  border-radius: var(--radius-md);
  background: var(--color-surface);
  border: 1.5px solid transparent;
  transition: border-color var(--dur-fast);
}

.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
  border-color: var(--color-blue);
}

.form-field.has-error input,
.form-field.has-error select,
.form-field.has-error textarea {
  border-color: var(--danger);
}

.field-error {
  font-size: var(--fs-xs);
  color: var(--danger);
  display: none;
}

.form-field.has-error .field-error {
  display: block;
}

.payment-methods {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-3);
}

.payment-option {
  border: 1.5px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: var(--space-4);
  text-align: center;
  font-size: var(--fs-small);
  font-weight: 600;
  transition: all var(--dur-fast);
}

.payment-option.is-selected {
  border-color: var(--color-blue);
  background: var(--gradient-brand-soft);
}

/* ---------- Tarjetas genéricas de página ---------- */
.page-hero {
  padding-block: var(--space-8) var(--space-6);
  text-align: center;
}

.page-hero .eyebrow {
  display: block;
  color: var(--color-purple);
  font-family: var(--font-accent);
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-size: var(--fs-xs);
  margin-bottom: var(--space-3);
}

.page-hero h1 {
  font-size: var(--fs-display-lg);
}

.breadcrumb {
  font-size: var(--fs-xs);
  color: var(--color-text-muted);
  margin-top: var(--space-3);
}

.breadcrumb a:hover {
  color: var(--color-blue);
}

.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-8);
}

.detail-gallery-main {
  aspect-ratio: 1/1;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--color-surface);
}

.detail-gallery-main img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.detail-thumbs {
  display: flex;
  gap: var(--space-3);
  margin-top: var(--space-3);
}

.detail-thumbs img {
  width: 76px;
  height: 76px;
  border-radius: var(--radius-md);
  object-fit: cover;
  border: 2px solid transparent;
  cursor: pointer;
  transition: border-color var(--dur-fast);
}

.detail-thumbs img.is-active {
  border-color: var(--color-blue);
}

.qty-selector {
  display: inline-flex;
  align-items: center;
  gap: var(--space-4);
  background: var(--color-surface);
  border-radius: var(--radius-pill);
  padding: 6px 20px;
}

.qty-selector button {
  font-size: 1.2rem;
  font-weight: 700;
}

.tabs {
  display: flex;
  gap: var(--space-6);
  border-bottom: 1px solid var(--color-border);
  margin-top: var(--space-7);
}

.tab-btn {
  padding-bottom: var(--space-3);
  font-weight: 600;
  color: var(--color-text-muted);
  border-bottom: 2px solid transparent;
}

.tab-btn.is-active {
  color: var(--color-text);
  border-color: var(--color-blue);
}

.tab-panel {
  display: none;
  padding-block: var(--space-6);
  color: var(--color-text-muted);
}

.tab-panel.is-active {
  display: block;
}

.empty-state {
  text-align: center;
  padding: var(--space-9) 0;
}

.empty-state .icon {
  font-size: 3rem;
  margin-bottom: var(--space-4);
}

.empty-state p {
  color: var(--color-text-muted);
  margin-bottom: var(--space-5);
}

.profile-tabs {
  display: flex;
  gap: var(--space-2);
  margin-bottom: var(--space-6);
  flex-wrap: wrap;
}

.dark-toggle {
  position: relative;
  width: 46px;
  height: 26px;
  border-radius: var(--radius-pill);
  background: var(--color-surface-2);
}

.dark-toggle .knob {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--gradient-brand);
  transition: transform var(--dur-med) var(--ease-spring);
}

[data-theme="dark"] .dark-toggle .knob {
  transform: translateX(20px);
}

/* ---------- Login / Registro ---------- */
.auth-wrap {
  min-height: 74vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-block: var(--space-8);
}

.auth-card {
  width: min(440px, 100%);
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-7);
  box-shadow: var(--shadow-md);
}

.auth-card .logo {
  display: flex;
  justify-content: center;
  margin-bottom: var(--space-5);
  font-size: 1.7rem;
}

.auth-card h1 {
  font-size: var(--fs-display-md);
  text-align: center;
}

.auth-subtitle {
  text-align: center;
  color: var(--color-text-muted);
  margin-top: var(--space-2);
  font-size: var(--fs-small);
}

.auth-form {
  margin-top: var(--space-6);
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

.auth-footer-link {
  text-align: center;
  margin-top: var(--space-5);
  font-size: var(--fs-small);
  color: var(--color-text-muted);
}

.auth-footer-link a {
  color: var(--color-blue);
  font-weight: 600;
}

.auth-notice {
  margin-top: var(--space-6);
  font-size: var(--fs-xs);
  color: var(--color-text-soft);
  background: var(--color-surface);
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-md);
  text-align: center;
  line-height: 1.5;
}

.auth-error {
  display: none;
  font-size: var(--fs-small);
  color: var(--danger);
  background: rgba(239, 68, 68, 0.1);
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-md);
  margin-top: var(--space-4);
}

.auth-error.is-visible {
  display: block;
}

/* ---------- Modal de autenticación (login / registro) ---------- */
.auth-modal-box {
  grid-template-columns: 1.05fr 0.95fr;
  width: min(960px, 100%);
  max-height: 90vh;
  padding: 0;
}

.auth-modal-form-col {
  padding: var(--space-7) var(--space-6);
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}

.auth-modal-form-col .logo {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 700;
}

.auth-tabs {
  display: flex;
  gap: var(--space-2);
  background: var(--color-surface);
  border-radius: var(--radius-pill);
  padding: 4px;
  margin-block: var(--space-5);
}

.auth-tab-btn {
  flex: 1;
  padding: 10px 16px;
  border-radius: var(--radius-pill);
  font-size: var(--fs-small);
  font-weight: 600;
  color: var(--color-text-muted);
  transition: background var(--dur-med) var(--ease-out), color var(--dur-med) var(--ease-out), box-shadow var(--dur-med) var(--ease-out);
}

.auth-tab-btn.is-active {
  background: var(--color-bg-elevated);
  color: var(--color-text);
  box-shadow: var(--shadow-sm);
}

.auth-panel {
  display: none;
}

.auth-panel.is-active {
  display: block;
  animation: fadeIn var(--dur-med) var(--ease-out);
}

.form-check {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: var(--fs-xs);
  color: var(--color-text-muted);
}

.form-check input {
  margin-top: 3px;
  accent-color: var(--color-blue);
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

.form-check.has-error {
  color: var(--danger);
}

.auth-modal-benefits {
  padding: var(--space-7) var(--space-6);
  background: var(--gradient-brand);
  color: #fff;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.auth-modal-benefits h3 {
  font-family: var(--font-display);
  font-size: 1.4rem;
  margin-bottom: var(--space-4);
  line-height: 1.25;
}

.auth-modal-benefits ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.auth-modal-benefits li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: var(--fs-small);
  color: rgba(255, 255, 255, 0.92);
  line-height: 1.4;
}

.auth-modal-benefits li .check-icon {
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.22);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
}

@media (max-width: 900px) {
  .auth-modal-box {
    max-height: 90vh;
    overflow-y: auto;
  }

  .auth-modal-benefits {
    order: 2;
    padding: var(--space-6) var(--space-6) var(--space-7);
  }

  .auth-modal-form-col {
    order: 1;
    overflow-y: visible;
  }
}

@media (max-width: 480px) {
  .auth-modal-form-col,
  .auth-modal-benefits {
    padding: var(--space-6) var(--space-5);
  }
}

/* Mejoras NOVA X API 2026 */
:root[data-theme="light"],:root{--color-bg:#e8edf4;--color-surface:#fff}.product-card,.category-card,[data-checkout-summary-card]{box-shadow:0 16px 40px rgba(15,23,42,.12)!important;border:1px solid rgba(15,23,42,.09)!important}.hero-slide,.slide{align-items:center!important}.hero-content,.slide-content{top:auto!important;transform:none!important;align-self:center!important}.logo{font-size:clamp(1.55rem,2vw,2.25rem)!important}.main-nav a{font-size:clamp(.95rem,1.05vw,1.12rem)}@media(min-width:1400px){.container{max-width:1440px}.header-inner{max-width:1500px}.hero-title{font-size:clamp(3.3rem,4vw,5.6rem)}body{font-size:17px}}
