:root {
  --bg: #f5f7fb;
  --surface: #ffffff;
  --surface-soft: #f8fafc;
  --border: #e6ebf2;
  --border-strong: #d7e0ec;
  --ink: #0f172a;
  --muted: #607086;
  --coral: #f03350;
  --coral-deep: #da2644;
  --dark: #09111f;
  --dark-soft: #162338;
  --success: #f03350;
  --success-soft: rgba(240, 51, 80, 0.08);
  --danger: #c23737;
  --shadow-sm: 0 10px 24px rgba(15, 23, 42, 0.06);
  --shadow: 0 20px 48px rgba(15, 23, 42, 0.1);
  --shell: 1480px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background:
    radial-gradient(circle at top left, rgba(240, 51, 80, 0.06), transparent 28%),
    radial-gradient(circle at top right, rgba(27, 90, 255, 0.05), transparent 24%),
    var(--bg);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
a, button, input { font: inherit; }
a { color: inherit; text-decoration: none; }
button { border: 0; }
.shell { width: min(var(--shell, 1240px), calc(100% - 16px)); margin: 0 auto; }

/* ==========================================
   MARKETPLACE LAYOUT (Sidebar + Grid)
   ========================================== */
.marketplace-layout {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 28px;
  width: calc(100% - 12px);
  margin: 0 auto;
  padding: 0 0 64px;
}

.products-section > .shell,
.products-section > .marketplace-layout {
  width: calc(100% - 12px);
  padding-left: 18px;
  padding-right: 6px;
}

/* --- Sidebar Desktop --- */
.filters-sidebar {
  grid-column: 1;
  position: sticky;
  top: 120px;
  height: fit-content;
  display: flex;
  flex-direction: column;
  gap: 24px;
  padding-right: 14px;
  border-right: 1px solid var(--premium-border, #e2e8f0);
}

.mobile-filters-trigger,
.filters-backdrop,
.filters-sidebar {
  display: none !important;
}

.product-grid-container {
  grid-column: 1 / -1;
  min-width: 0;
}

.filter-group {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.filter-title {
  margin: 0;
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--premium-text-main, #0f172a);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.filter-group-trigger {
  background: transparent;
  padding: 0;
  border: 0;
  width: 100%;
  text-align: left;
  cursor: default;
}

.filter-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.price-inputs {
  display: flex;
  align-items: center;
  gap: 8px;
}

.price-inputs input {
  width: 100%;
  min-height: 42px;
  padding: 0 12px;
  border-radius: 10px;
  border: 1px solid var(--premium-border, #e2e8f0);
  background: #fff;
  font-size: 0.9rem;
  outline: none;
}

.price-inputs input:focus {
  border-color: var(--premium-brand, #f03350);
}

.price-separator {
  color: var(--premium-text-muted, #64748b);
  font-weight: 700;
}

.filter-apply-btn {
  width: 100%;
  min-height: 42px;
  border-radius: 10px;
  background: var(--premium-text-main, #0f172a);
  color: #fff;
  font-weight: 700;
  font-size: 0.85rem;
  cursor: pointer;
  border: 0;
}

.filter-checkbox,
.filter-radio {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  font-size: 0.88rem;
  color: var(--premium-text-muted, #64748b);
  font-weight: 600;
  line-height: 1.35;
}

.empty-products-state {
  grid-column: 1 / -1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 72px 24px;
  text-align: center;
  border: 1px solid var(--border);
  border-radius: 24px;
  background: linear-gradient(180deg, rgba(255,255,255,0.96), rgba(248,250,252,0.98));
  box-shadow: var(--shadow-sm);
}

.empty-products-state h2 {
  margin: 0;
  font-size: 1.35rem;
}

.empty-products-state p {
  margin: 0;
  max-width: 520px;
  color: var(--muted);
}

.empty-products-state .primary-button {
  margin-top: 8px;
}

.filter-checkbox input,
.filter-radio input {
  width: 18px;
  height: 18px;
  accent-color: var(--premium-brand, #f03350);
}

.clear-filters-btn {
  background: transparent;
  color: var(--premium-text-muted, #64748b);
  font-weight: 700;
  font-size: 0.85rem;
  text-decoration: underline;
  cursor: pointer;
  text-align: left;
  border: 0;
}

/* ==========================================
   MOBILE DRAWER & ACCORDIONS
   ========================================== */
@media (max-width: 1024px) {
  .products-section > .shell,
  .products-section > .marketplace-layout {
    padding-left: 12px;
    padding-right: 4px;
  }

  .marketplace-layout {
    grid-template-columns: 1fr;
    padding-top: 20px;
    gap: 18px;
  }

  .filters-sidebar {
    grid-column: auto;
  }

  .product-grid-container {
    grid-column: auto;
  }

  /* Trigger móvil */
  .mobile-filters-trigger {
    display: flex;
    align-items: center;
    gap: 10px;
    width: fit-content;
    min-height: 46px;
    padding: 0 20px;
    background: #fff;
    border: 1px solid var(--premium-border, #e2e8f0);
    border-radius: 12px;
    font-weight: 800;
    font-size: 0.9rem;
    color: var(--premium-text-main);
    cursor: pointer;
    box-shadow: var(--premium-shadow-sm);
    margin-bottom: 24px;
    position: relative;
  }

  .active-filters-badge {
    background: var(--premium-brand);
    color: #fff;
    font-size: 0.7rem;
    min-width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  /* Backdrop */
  .filters-backdrop {
    display: block; /* Aseguramos que se vea en móvil */
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.4);
    backdrop-filter: blur(4px);
    z-index: 1500;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
  }
  .filters-backdrop.is-active {
    opacity: 1;
    visibility: visible;
  }

  /* Sidebar como Drawer */
  .filters-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: min(340px, 85vw);
    background: #fff;
    z-index: 1600;
    padding: 0;
    margin: 0;
    border-right: 0;
    box-shadow: 20px 0 60px rgba(0,0,0,0.1);
    transform: translateX(-100%);
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    display: flex;
    flex-direction: column;
  }

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

  .sidebar-header-mobile {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 24px;
    border-bottom: 1px solid var(--premium-border, #e2e8f0);
  }

  .sidebar-header-mobile h3 {
    margin: 0;
    font-size: 1.2rem;
    letter-spacing: -0.02em;
  }

  .close-sidebar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--premium-surface);
    font-size: 1.4rem;
    display: grid;
    place-items: center;
    cursor: pointer;
    border: 0;
  }

  /* Acordeones */
  .filter-group.is-collapsible {
    border-bottom: 1px solid var(--premium-border, #e2e8f0);
    gap: 0;
  }

  .filter-group-trigger {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    cursor: pointer;
  }

  .filter-group-trigger .chevron {
    display: block;
    transition: transform 0.3s ease;
    color: var(--premium-text-muted);
  }

  .filter-group.is-active .chevron {
    transform: rotate(180deg);
  }

  .filter-group-content {
    max-height: 0;
    overflow: hidden;
    padding: 0 24px;
    transition: all 0.3s ease;
    opacity: 0;
  }

  .filter-group.is-active .filter-group-content {
    max-height: 500px;
    padding-bottom: 24px;
    opacity: 1;
  }

  /* Footer Drawer */
  .sidebar-footer-mobile {
    margin-top: auto;
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 12px;
    padding: 20px 24px;
    border-top: 1px solid var(--premium-border, #e2e8f0);
    background: #fff;
  }

  .apply-filters-mobile-btn {
    min-height: 50px;
    border-radius: 12px;
    background: var(--premium-brand);
    color: #fff;
    font-weight: 800;
    font-size: 0.95rem;
    border: 0;
    cursor: pointer;
  }
}

/* Header y Footer manejados por componentes header.js/footer.js y header.css/footer.css */

.search-suggestions-panel {
  position: absolute;
  z-index: 120;
  padding: 14px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.98);
  border: 1px solid #e4eaf2;
  box-shadow: 0 28px 60px rgba(15, 23, 42, 0.16);
  backdrop-filter: blur(16px);
}

.search-suggestions-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 4px 4px 12px;
}

.search-suggestions-head strong {
  font-size: .92rem;
  letter-spacing: -.02em;
}

.search-suggestions-head span {
  color: var(--muted);
  font-size: .8rem;
  font-weight: 700;
}

.search-suggestions-list {
  display: grid;
  gap: 8px;
}

.search-suggestion-item {
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 10px;
  border-radius: 16px;
  transition: background .18s ease, transform .18s ease;
}

.search-suggestion-item:hover {
  background: #f8fafc;
  transform: translateY(-1px);
}

.search-suggestion-item img {
  width: 54px;
  height: 54px;
  border-radius: 14px;
  object-fit: cover;
  background: #eef2f7;
}

.search-suggestion-copy {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.search-suggestion-copy strong {
  font-size: .92rem;
  line-height: 1.25;
}

.search-suggestion-copy span {
  color: var(--muted);
  font-size: .78rem;
  line-height: 1.35;
}

.search-suggestion-item em {
  color: var(--ink);
  font-style: normal;
  font-weight: 900;
  font-size: .94rem;
  letter-spacing: -.02em;
}

.search-suggestions-action {
  width: 100%;
  margin-top: 12px;
  min-height: 46px;
  border: 0;
  border-radius: 16px;
  background: #f3f6fb;
  color: var(--ink);
  font-weight: 800;
  cursor: pointer;
}

.search-suggestions-action:hover {
  background: #e9eef6;
}

.header-actions { display: flex; align-items: center; gap: 12px; }
.header-action {
  position: relative;
  min-width: 108px;
  display: grid;
  gap: 2px;
  padding: 10px 14px;
  border-radius: 16px;
  background: rgba(255,255,255,.6);
  cursor: pointer;
  text-align: left;
}
.header-action small { color: var(--muted); font-size: .76rem; }
.header-action strong { font-size: .93rem; }
.cta-cart {
  position: relative;
  min-height: 46px;
  padding: 0 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border-radius: 999px;
  background: linear-gradient(135deg, #101c2f, #24344d);
  color: #fff;
  font-weight: 700;
  box-shadow: 0 16px 30px rgba(16, 28, 47, 0.18);
}

.cta-cart-icon {
  font-size: 1rem;
  line-height: 1;
}

.cta-cart-label {
  line-height: 1;
}

.nav-count-badge {
  position: absolute;
  top: -6px;
  right: -6px;
  min-width: 22px;
  height: 22px;
  padding: 0 6px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--coral), var(--coral-deep));
  color: #fff;
  font-size: .74rem;
  font-weight: 800;
  box-shadow: 0 10px 20px rgba(240, 51, 80, 0.28);
}

.cta-cart.is-highlighted {
  animation: cartPulse .7s ease;
}

.cta-cart.is-highlighted .nav-count-badge {
  animation: badgePop .7s ease;
}

@keyframes cartPulse {
  0% { transform: scale(1); box-shadow: 0 16px 30px rgba(16, 28, 47, 0.18); }
  35% { transform: scale(1.05); box-shadow: 0 22px 38px rgba(240, 51, 80, 0.24); }
  100% { transform: scale(1); box-shadow: 0 16px 30px rgba(16, 28, 47, 0.18); }
}

@keyframes badgePop {
  0% { transform: scale(1); }
  35% { transform: scale(1.22); }
  100% { transform: scale(1); }
}

.header-secondary {
  border-top: 1px solid rgba(215,224,236,.7);
  background: rgba(248,250,252,.85);
  overflow: visible;
}
.header-secondary-row {
  justify-content: space-between;
  gap: 18px;
  min-height: 56px;
  position: relative;
  overflow: visible;
}
.department-nav {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  overflow: visible;
  scrollbar-width: none;
}
.department-nav::-webkit-scrollbar { display: none; }
.department-nav a {
  white-space: nowrap;
  padding: 10px 14px;
  border-radius: 999px;
  color: var(--muted);
  font-weight: 600;
}
.department-nav a:hover,
.department-nav a.is-active { color: var(--ink); background: #fff; box-shadow: inset 0 0 0 1px var(--border); }
.service-notes {
  display: flex;
  align-items: center;
  gap: 18px;
  color: var(--muted);
  font-size: .88rem;
  white-space: nowrap;
}
.service-notes span { position: relative; }
.service-notes span + span::before {
  content: "";
  position: absolute;
  left: -11px;
  top: 50%;
  transform: translateY(-50%);
  width: 4px;
  height: 4px;
  border-radius: 999px;
  background: #c2ccda;
}

.home-layout { padding-bottom: 42px; }

.hero-stage {
  position: relative;
  min-height: clamp(560px, 72vh, 760px);
  background: var(--dark);
  margin-bottom: 42px;
  overflow: hidden;
}

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

.hero-slide {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  opacity: 0;
  transform: scale(1.02);
  pointer-events: none;
  background-position: center;
  background-size: cover;
  transition: opacity .8s cubic-bezier(0.4, 0, 0.2, 1), transform 1.4s ease;
}

.hero-slide.is-active {
  opacity: 1;
  transform: scale(1);
  pointer-events: auto;
}

.hero-slide::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(7, 12, 22, 0.82) 0%, rgba(7, 12, 22, 0.58) 34%, rgba(7, 12, 22, 0.12) 68%, rgba(7, 12, 22, 0.42) 100%),
    linear-gradient(180deg, rgba(7, 12, 22, 0.02) 0%, rgba(7, 12, 22, 0.34) 100%);
  z-index: 1;
}

.hero-slide-copy {
  position: relative;
  z-index: 2;
  width: min(620px, 90%);
  margin-left: max(24px, calc((100vw - var(--shell)) / 2 + 24px));
  color: #fff;
}

.hero-slide-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.7);
}

.hero-slide-kicker::before {
  content: "";
  width: 24px;
  height: 1px;
  background: currentColor;
  opacity: 0.6;
}

.hero-slide-copy h1, .hero-slide-copy h2 { 
  font-size: clamp(2.2rem, 4vw, 3.8rem); 
  margin: 0 0 16px; 
  line-height: 1.05; 
  letter-spacing: -0.04em;
  text-wrap: balance;
}

.hero-slide-copy p { 
  font-size: 1.1rem; 
  line-height: 1.6; 
  color: rgba(255, 255, 255, 0.85); 
  margin-bottom: 24px;
  max-width: 48ch;
}
.hero-slide-link {
  margin-top: 16px;
  min-height: 44px;
  padding: 0 16px;
  background: rgba(255, 255, 255, 0.14);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.16);
}
.hero-slider-controls {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 max(18px, calc((100vw - var(--shell)) / 2 + 18px));
  z-index: 4;
  pointer-events: none;
}
.slider-arrow {
  width: 54px; height: 54px; display: grid; place-items: center; border-radius: 999px; background: rgba(8,16,29,.34); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.14), 0 18px 36px rgba(8, 16, 29, 0.2); backdrop-filter: blur(12px); color: #fff; font-size: 1rem; font-weight: 900; pointer-events: auto;
}
.slider-dots {
  position: absolute;
  left: 50%;
  bottom: 32px;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  padding: 10px 14px;
  border-radius: 999px;
  background: rgba(8, 16, 29, 0.26);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(12px);
  pointer-events: auto;
}
.slider-dot { width: 10px; height: 10px; padding: 0; border-radius: 999px; background: rgba(255,255,255,.4); cursor: pointer; }
.slider-dot.is-active { width: 30px; background: #fff; }

.category-ribbon { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin-bottom: 20px; }
.category-ribbon article { padding: 20px; border-radius: 18px; }
.category-ribbon span { display: block; margin-bottom: 8px; color: var(--muted); font-size: .84rem; text-transform: uppercase; letter-spacing: .08em; }
.category-ribbon strong { font-size: 1.1rem; line-height: 1.2; }

.collection-grid { display: grid; grid-template-columns: 1.35fr 1fr 1fr 1fr; gap: 18px; margin-bottom: 26px; }
.collection-card { min-height: 200px; padding: 24px; border-radius: 22px; }
.collection-card.large { background: linear-gradient(135deg, #fef2f5 0%, #fff 100%); }
.collection-card.coral { background: linear-gradient(135deg, #fff3f6 0%, #ffe3ea 100%); }
.collection-card.sky { background: linear-gradient(135deg, #eef8fd 0%, #dbeef8 100%); }
.collection-card.dark { background: linear-gradient(140deg, var(--dark) 0%, #24334d 100%); color: #fff; }
.collection-card.dark .section-kicker { background: rgba(255,255,255,.14); color: #fff; }

.products-section, .showcase-panel { margin-bottom: 24px; }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 18px; margin-bottom: 18px; }
.section-head h2 { font-size: clamp(1.9rem, 3vw, 3rem); }
.section-tools { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.filter-pill { padding: 12px 16px; border-radius: 999px; background: var(--surface); color: #41506a; font-weight: 700; box-shadow: var(--shadow); }
.filter-pill.is-active { background: var(--dark); color: #fff; }
.view-toggle {
  display: none;
  align-items: center;
  gap: 6px;
  margin-left: auto;
  padding: 6px;
  border-radius: 999px;
  background: rgba(9, 17, 31, 0.06);
  border: 1px solid rgba(215, 224, 236, 0.9);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7);
}
.view-toggle-button {
  min-height: 38px;
  padding: 0 14px;
  border-radius: 999px;
  background: transparent;
  color: #51627a;
  font-size: .86rem;
  font-weight: 800;
  letter-spacing: .01em;
  cursor: pointer;
  transition: background .2s ease, color .2s ease, box-shadow .2s ease, transform .2s ease;
}
.view-toggle-button.is-active {
  background: linear-gradient(135deg, #101c2f, #24344d);
  color: #fff;
  box-shadow: 0 10px 24px rgba(16, 28, 47, 0.18);
}

.product-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 14px; }
/* Tarjetas de producto manejadas por product-card.css */

.product-add-icon {
  width: 42px;
  height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: var(--surface-soft);
  border: 1px solid var(--border);
  color: var(--ink);
  font-size: 1.1rem;
  font-weight: 900;
  cursor: pointer;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.footer-newsletter {
  background: rgba(255, 255, 255, 0.03);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  padding: 60px 0;
}

.newsletter-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
}

.newsletter-copy {
  max-width: 520px;
}

.premium-badge-alt {
  display: inline-block;
  padding: 4px 12px;
  background: var(--coral);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 800;
  text-transform: uppercase;
  border-radius: 999px;
  letter-spacing: 0.1em;
  margin-bottom: 16px;
}

.newsletter-copy h2 {
  font-size: 2.2rem;
  color: #fff;
  margin: 0 0 12px;
}

.newsletter-copy p {
  color: #94a3b8;
  font-size: 1.05rem;
  line-height: 1.6;
}

.newsletter-form-pro {
  flex-grow: 1;
  max-width: 480px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.input-group {
  display: flex;
  gap: 10px;
}

.newsletter-form-pro input {
  flex-grow: 1;
  min-height: 54px;
  padding: 0 20px;
  background: #1e293b;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 14px;
  color: #fff;
  font-size: 1rem;
}

.newsletter-form-pro input:focus {
  outline: none;
  border-color: var(--coral);
}

.newsletter-form-pro button {
  padding: 0 28px;
  background: #fff;
  color: #0f172a;
  border-radius: 14px;
  font-weight: 800;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.2s ease;
  border: none;
}

.newsletter-form-pro button:hover {
  background: var(--coral);
  color: #fff;
  transform: translateY(-2px);
}

.form-note {
  font-size: 0.75rem;
  color: #64748b;
  margin: 0;
}

.dual-showcase.single-column {
  grid-template-columns: 1fr;
}

@media (max-width: 1024px) {
  .newsletter-row {
    flex-direction: column;
    text-align: center;
    align-items: stretch;
  }
  .newsletter-copy {
    max-width: none;
  }
  .newsletter-form-pro {
    max-width: none;
  }
}

.showcase-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 24px;
}

.showcase-title-group h2 {
  font-size: 2.2rem;
  margin: 6px 0;
}

.showcase-title-group p {
  color: var(--muted);
  font-size: 1rem;
}

.premium-badge {
  display: inline-block;
  padding: 4px 10px;
  background: rgba(10, 143, 99, 0.1);
  color: #0a8f63;
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
  border-radius: 999px;
  letter-spacing: 0.05em;
}

.text-button {
  font-weight: 700;
  color: var(--coral-deep);
  font-size: 0.9rem;
  transition: opacity 0.2s;
}

.text-button:hover {
  opacity: 0.7;
}

.mini-reorder-card {
  display: flex;
  gap: 20px;
  padding: 16px;
  background: var(--surface-soft);
  border: 1px solid var(--border);
  border-radius: 20px;
  transition: all 0.3s ease;
}

.mini-reorder-card:hover {
  background: #fff;
  border-color: var(--coral-deep);
  transform: translateX(6px);
  box-shadow: var(--shadow-sm);
}

.mini-reorder-img {
  width: 92px;
  height: 92px;
  border-radius: 14px;
  overflow: hidden;
  background: #fff;
  border: 1px solid var(--border);
  flex-shrink: 0;
}

.mini-reorder-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.mini-reorder-info {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.mini-reorder-tag {
  font-size: 0.68rem;
  font-weight: 800;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  margin-bottom: 4px;
  display: block;
}

.mini-reorder-title {
  font-size: 1.05rem;
  margin: 0 0 2px;
  line-height: 1.2;
}

.mini-reorder-title a {
  color: var(--ink);
  display: -webkit-box;
  -webkit-line-clamp: 1;
  line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.mini-reorder-provider {
  font-size: 0.85rem;
  color: var(--muted);
  margin: 0;
}

.mini-reorder-action-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 8px;
}

.mini-reorder-price {
  font-size: 1.25rem;
  font-weight: 900;
  color: var(--ink);
  letter-spacing: -0.02em;
}

.reorder-button {
  background: var(--dark);
  color: #fff;
  padding: 8px 16px;
  border-radius: 999px;
  font-weight: 800;
  font-size: 0.82rem;
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  border: none;
}

.reorder-button:hover {
  background: var(--coral-deep);
  transform: scale(1.04);
}

.reorder-button small {
  font-size: 1.1rem;
  line-height: 1;
  background: rgba(255,255,255,0.15);
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
}
.mini-product-topline {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
  flex-wrap: wrap;
}
.mini-product-tag {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 10px;
  border-radius: 999px;
  background: rgba(240, 51, 80, 0.08);
  color: var(--coral-deep);
  font-size: .68rem;
  font-weight: 800;
  letter-spacing: .06em;
  text-transform: uppercase;
}
.mini-product-provider {
  color: #475569;
  font-size: .78rem;
  font-weight: 700;
}
.mini-product-side {
  text-align: right;
}
.mini-product-card.is-placeholder {
  pointer-events: none;
}

.newsletter { background: linear-gradient(140deg, var(--dark) 0%, #24334d 100%); color: #fff; }
.newsletter .section-kicker { background: rgba(255,255,255,.14); color: #fff; }
.newsletter p { color: rgba(255,255,255,.8); }
.newsletter-form { display: grid; grid-template-columns: 1fr auto; gap: 10px; margin-top: 22px; }
.newsletter-form input {
  min-height: 52px; padding: 0 16px; border: 1px solid rgba(255,255,255,.2); border-radius: 14px; background: rgba(255,255,255,.08); color: #fff; outline: 0;
}
.newsletter-form button { min-width: 142px; border-radius: 14px; background: #fff; color: var(--ink); font-weight: 800; cursor: pointer; }
.trust-points { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 18px; }
.trust-points span { padding: 10px 14px; border-radius: 999px; background: rgba(255,255,255,.1); font-size: .84rem; }

/* Login Drawer manejado por header.css */

.drawer-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; margin-bottom: 18px; }
.drawer-title-group h2 { font-size: 2rem; line-height: 1; letter-spacing: -0.04em; }
.card-kicker {
  display: inline-flex;
  width: fit-content;
  margin: 0 0 14px;
  padding: 7px 11px;
  font-size: 0.75rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  border-radius: 8px;
  background: rgba(240, 51, 80, 0.1);
  color: var(--coral-deep);
}
.card-copy {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.5;
}
.drawer-close { width: 42px; height: 42px; border-radius: 999px; background: var(--surface-soft); color: var(--ink); font-size: 1.2rem; cursor: pointer; }

#login-form { display: flex; flex-direction: column; gap: 16px; }
.field { display: flex; flex-direction: column; gap: 8px; font-weight: 700; }
.input-shell {
  display: flex; align-items: center; gap: 10px; min-height: 54px; padding: 0 14px; border-radius: 14px; background: var(--surface); border: 1px solid var(--border);
}
.input-shell:focus-within { border-color: rgba(240,51,80,.56); box-shadow: 0 0 0 4px rgba(240,51,80,.1); }
.input-icon { width: 22px; color: var(--muted); font-weight: 900; }
.input-shell input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; }
.toggle-password { background: transparent; color: var(--coral-deep); font-weight: 800; cursor: pointer; }
.form-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; font-size: .9rem; }
.check-field { display: inline-flex; align-items: center; gap: 10px; color: var(--muted); }
.check-field input { accent-color: var(--coral); }
.text-link { color: var(--coral-deep); font-weight: 700; }
.ghost-button { background: var(--surface-soft); color: var(--ink); }
.divider { display: flex; align-items: center; gap: 12px; color: #8791a3; }
.divider span { flex: 1; height: 1px; background: var(--border); }
.divider p { margin: 0; font-size: .84rem; font-weight: 700; }
.google-badge { display: inline-flex; width: 20px; height: 20px; vertical-align: middle; }
.google-badge svg { width: 100%; height: 100%; }
.drawer-actions { display: grid; gap: 10px; }
.status-message { min-height: 24px; margin: 0; font-size: .92rem; font-weight: 700; }
.status-message.is-error { color: var(--danger); }
.status-message.is-success { color: var(--success); }

.store-footer {
  margin-top: 80px;
  background: #0f172a;
  color: #f8fafc;
  padding: 80px 0 40px;
}

.footer-main {
  display: flex;
  flex-direction: column;
  gap: 60px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1.2fr;
  gap: 48px;
}

.footer-brand-column {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.footer-brand-column .brand-mark {
  background: linear-gradient(135deg, var(--coral), #ff6d87);
}

.footer-brand-column .brand-copy strong {
  color: #fff;
}

.footer-description {
  color: #94a3b8;
  line-height: 1.6;
  font-size: 0.95rem;
  max-width: 32ch;
}

.footer-social {
  display: flex;
  gap: 12px;
}

.footer-social a {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 10px;
  font-size: 0.8rem;
  font-weight: 800;
  color: #cbd5e1;
  transition: all 0.3s ease;
}

.footer-social a:hover {
  background: var(--coral);
  color: #fff;
  transform: translateY(-3px);
}

.footer-nav-column h3, 
.footer-trust-column h3 {
  font-size: 1.1rem;
  font-weight: 800;
  margin-bottom: 24px;
  color: #fff;
}

.footer-nav-column nav {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-nav-column a {
  color: #94a3b8;
  font-size: 0.92rem;
  transition: color 0.2s;
}

.footer-nav-column a:hover {
  color: var(--coral);
}

.footer-trust-column p {
  color: #94a3b8;
  font-size: 0.9rem;
  margin-bottom: 24px;
}

.payment-methods {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 24px;
}

.payment-card {
  padding: 12px;
  background: #1e293b;
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.payment-label {
  font-size: 0.8rem;
  font-weight: 900;
  color: #fff;
  line-height: 1;
}

.payment-sub {
  font-size: 0.6rem;
  font-weight: 700;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-top: 4px;
}

.security-badges {
  display: flex;
  gap: 12px;
}

.security-badges span {
  padding: 6px 12px;
  background: rgba(10, 143, 99, 0.1);
  color: #f03350;
  border-radius: 8px;
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
}

.footer-bottom {
  padding-top: 40px;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: #64748b;
  font-size: 0.85rem;
}

.footer-bottom-info {
  display: flex;
  gap: 24px;
}

.footer-bottom-links {
  display: flex;
  gap: 20px;
}

.footer-bottom-links a {
  color: #64748b;
  transition: color 0.2s;
}

.footer-bottom-links a:hover {
  color: #fff;
}

.mobile-menu-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  border-radius: 12px;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  transition: background 0.2s ease;
}

.mobile-menu-toggle:hover {
  background: var(--surface-soft);
}

.store-header.is-menu-open .icon-menu { display: none; }
.store-header.is-menu-open .icon-close { display: block !important; }

.primary-button:hover, .secondary-button:hover, .filter-pill:hover, .slider-arrow:hover, .slider-dot:hover, .product-action:hover, .drawer-close:hover, .ghost-button:hover, .newsletter-form button:hover {
  transform: translateY(-1px);
}

@media (max-width: 1260px) {
  .header-secondary-row,
  .collection-grid,
  .dual-showcase {
    grid-template-columns: 1fr;
    flex-direction: column;
    align-items: stretch;
  }

  .header-primary {
    grid-template-columns: auto 1fr;
  }

  .header-actions {
    grid-column: 1 / -1;
    justify-content: flex-end;
  }

  .product-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

@media (max-width: 1080px) {
  .product-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 860px) {
  .shell { width: calc(100% - 14px); }
  .top-banner-row, .header-secondary-row, .form-row { flex-direction: column; align-items: stretch; text-align: center; }
  .top-banner-links { justify-content: center; margin-top: 4px; }
  .header-primary { grid-template-columns: 1fr; min-height: auto; padding: 14px 0; }
  .store-search { order: 3; grid-template-columns: 1fr auto; min-height: 48px; }
  .search-mode { display: none; }
  .store-search input,
  .store-search button { min-height: 48px; }
  .store-search button { border-top: none; padding: 0 18px; }
  .header-actions { width: 100%; flex-wrap: wrap; justify-content: stretch; }
  .header-action, .cta-cart { flex: 1 1 180px; }
  .department-nav { width: 100%; flex-wrap: nowrap; overflow-x: auto; overflow-y: visible; }
  .service-notes { white-space: normal; flex-wrap: wrap; }
  .newsletter-form { grid-template-columns: 1fr; }
  .hero-slide-copy, .collection-card, .showcase-panel, .login-drawer { padding-left: 18px; padding-right: 18px; }
  .hero-stage { min-height: 560px; }
  .hero-slide-copy { 
    position: absolute;
    left: 20px;
    margin-left: 0;
    width: calc(100% - 40px); 
    top: clamp(42px, 10vw, 64px); 
    padding: 0;
    background: transparent;
    border: none;
    box-shadow: none;
    backdrop-filter: none;
    display: block;
  }
  .hero-slide-copy h1 { max-width: 12ch; font-size: clamp(2rem, 8vw, 2.8rem); line-height: 1; }
  .hero-slide-copy > p:not(.hero-slide-kicker) { font-size: 0.96rem; max-width: none; }
  .hero-actions { flex-direction: column; align-items: stretch; }
  .hero-slider-controls { padding: 0 16px; }
  .slider-dots { bottom: 18px; }
  .hero-metrics { grid-template-columns: 1fr; }
  .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .product-grid.is-mobile-list { grid-template-columns: 1fr; }
  .mini-product-list > a,
  .mini-product-card {
    grid-template-columns: 72px minmax(0, 1fr);
  }
  .mini-product-list > a strong,
  .mini-product-side {
    grid-column: 2;
    text-align: left;
  }
  .mini-product-list > a strong::after,
  .mini-product-side span {
    text-align: left;
  }
  .footer-grid,
  .footer-bottom {
    grid-template-columns: 1fr;
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 640px) {
  .shell { width: calc(100% - 12px); }
  
  /* Se eliminó la lógica de header.is-menu-open duplicada para usar la global de header.css */
}

@media (max-width: 560px) {
  .shell { width: calc(100% - 12px); }
  .section-tools { width: 100%; }
  .view-toggle {
    width: 100%;
    margin-left: 0;
    justify-content: space-between;
  }
  .view-toggle-button {
    flex: 1 1 0;
    justify-content: center;
    text-align: center;
  }
  .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .product-grid.is-mobile-list { grid-template-columns: 1fr; }
  .mini-product-list > a {
    grid-template-columns: 1fr;
  }
  .mini-product-list > a img,
  .mini-product-image-shell {
    width: 100%;
    height: 180px;
  }
  .mini-product-list > a strong,
  .mini-product-side {
    grid-column: auto;
  }
}

/* --- MEGA MENU CATEGORIES --- */
.categories-menu {
  position: relative;
  z-index: 80;
}

.category-trigger {
  min-height: 42px;
  padding: 0 14px;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  border-radius: 999px;
  background: #fff;
  border: 1px solid var(--border);
  color: var(--ink);
  font-weight: 700;
  transition: all .2s ease;
  cursor: pointer;
}

.category-trigger:hover, .category-trigger.is-open {
  color: var(--ink);
  background: #fff;
  box-shadow: inset 0 0 0 1px var(--border);
}

.category-trigger-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  height: 20px;
  border-radius: 999px;
  background: var(--coral);
  color: #fff;
  font-size: .68rem;
  font-weight: 900;
}

.categories-dropdown {
  position: absolute;
  top: calc(100% + 12px);
  left: 0;
  width: 780px;
  padding: 24px;
  border-radius: 24px;
  background: #fff;
  border: 1px solid var(--border);
  box-shadow: 0 32px 80px rgba(15, 23, 42, 0.16);
  z-index: 1000;
  opacity: 1;
  visibility: visible;
  transition: all .3s cubic-bezier(0.4, 0, 0.2, 1);
}

.categories-dropdown[hidden] {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(-10px);
  display: block !important;
}

.categories-dropdown-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.category-menu-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 14px;
  border-radius: 16px;
  background: #f8fafc;
  border: 1px solid #f1f5f9;
  transition: all .2s ease;
  text-decoration: none;
}

.category-menu-item:hover {
  background: #fff;
  border-color: var(--coral);
  transform: translateY(-2px);
  box-shadow: 0 12px 24px rgba(15, 23, 42, 0.06);
}

.category-menu-item-icon {
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--cat-start, #ccc) 0%, var(--cat-end, #999) 100%);
  color: #fff;
  font-size: 1.2rem;
  font-weight: 900;
  flex-shrink: 0;
}

.category-menu-item-content {
  display: flex;
  flex-direction: column;
  gap: 2px;
  overflow: hidden;
}

.category-menu-item-content strong {
  font-size: .94rem;
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.category-menu-item-content small {
  font-size: .74rem;
  color: #64748b;
  font-weight: 600;
}

@media (max-width: 860px) {
  .categories-dropdown {
    width: calc(100vw - 32px);
    position: fixed;
    top: auto;
    bottom: 20px;
    left: 16px;
    max-height: 70vh;
    overflow-y: auto;
  }
  .categories-dropdown-grid {
    grid-template-columns: 1fr;
  }
}

.category-menu-item-icon {
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--cat-start, #ccc) 0%, var(--cat-end, #999) 100%);
  color: #fff;
  font-size: 1.2rem;
  font-weight: 900;
  flex-shrink: 0;
}

.category-menu-item-content {
  display: flex;
  flex-direction: column;
  gap: 2px;
  overflow: hidden;
}

.category-menu-item-content strong {
  font-size: .94rem;
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.category-menu-item-content small {
  font-size: .74rem;
  color: #64748b;
  font-weight: 600;
}

@media (max-width: 860px) {
  .categories-dropdown {
    width: calc(100vw - 32px);
    position: fixed;
    top: auto;
    bottom: 20px;
    left: 16px;
    max-height: 70vh;
    overflow-y: auto;
  }
  .categories-dropdown-grid {
    grid-template-columns: 1fr;
  }
}
