.home-product-tabs {
  display: flex;
  gap: 10px;
  margin: -18px 0 34px;
  overflow-x: auto;
  scrollbar-width: none;
}

.home-product-tabs::-webkit-scrollbar { display: none; }

.home-product-tabs button {
  flex: 0 0 auto;
  border: 1px solid #d9cbca;
  border-radius: 999px;
  background: #fffdfb;
  color: #735f60;
  cursor: pointer;
  font: 700 13px/1 "DM Sans", sans-serif;
  letter-spacing: .03em;
  padding: 12px 19px;
  transition: background .2s ease, border-color .2s ease, color .2s ease, transform .2s ease;
}

.home-product-tabs button:hover { transform: translateY(-1px); }

.home-product-tabs button.active {
  background: #6f1831;
  border-color: #6f1831;
  color: #fff;
}

#catalogo { scroll-margin-top: 90px; }
.size-quick-filters { display: flex; align-items: center; gap: 9px; margin: 4px 0 14px; overflow-x: auto; scrollbar-width: none; }
.size-quick-filters[hidden] { display: none; }
.size-quick-filters > span { flex: 0 0 auto; font-size: 10px; font-weight: 800; text-transform: uppercase; }
.size-quick-filters > div { display: flex; gap: 6px; }
.size-quick-filters button { flex: 0 0 auto; min-height: 34px; padding: 7px 11px; border: 1px solid #ded7da; border-radius: 18px; color: #4c4549; background: #fff; cursor: pointer; font-size: 9px; font-weight: 700; }
.size-quick-filters [data-quick-size].active { color: #fff; border-color: #a51d58; background: #a51d58; }
.size-quick-filters > button { color: #a51d58; border: 0; text-decoration: underline; }

.discount-pill {
  position: absolute;
  left: 12px;
  top: 48px;
  z-index: 3;
  padding: 6px 9px;
  border-radius: 999px;
  color: #fff;
  background: #a51d58;
  font-size: 9px;
  font-weight: 800;
}

.product-skeleton { pointer-events: none; }
.product-skeleton .product-image,
.product-skeleton .product-info > * {
  background: linear-gradient(100deg, #f2edef 30%, #fff 48%, #f2edef 66%);
  background-size: 250% 100%;
  animation: product-loading 1.25s infinite;
}
.product-skeleton .product-info { display: grid; gap: 10px; }
.product-skeleton .product-info > * { display: block; height: 11px; border-radius: 8px; }
.product-skeleton .product-info b { width: 75%; height: 18px; }
.product-skeleton .product-info span { width: 42%; }
@keyframes product-loading { to { background-position-x: -250%; } }

.clear-catalog-filters {
  min-height: 48px;
  border: 1px dashed #cbbbc1;
  border-radius: 12px;
  color: #8b3153;
  background: #fff;
  cursor: pointer;
  font-weight: 700;
}

#active-filter-count {
  display: inline-grid;
  place-items: center;
  width: 19px;
  height: 19px;
  margin-left: 6px;
  border-radius: 50%;
  color: #fff;
  background: #a51d58;
  font-size: 9px;
}
#active-filter-count[hidden] { display: none; }

.product-image [data-favorite][aria-pressed="true"] {
  color: #fff;
  background: #a51d58;
  box-shadow: 0 7px 20px rgba(165, 29, 88, .3);
}
.product-image [data-favorite][aria-pressed="true"] .favorite-heart {
  fill: currentColor;
  stroke: currentColor;
}

/* La etiqueta AGOTADO y el corazón comparten la clase base `badge`; se
   restablece el botón para que no herede el tratamiento negro del estado. */
.product-card.sold-out-card .product-image > button.badge[data-favorite]:first-of-type {
  padding: 0 !important;
  border: 1px solid rgba(17, 17, 17, .08) !important;
  color: #111 !important;
  background: rgba(255, 255, 255, .96) !important;
  font-size: 0 !important;
  letter-spacing: 0 !important;
  box-shadow: 0 5px 18px rgba(0, 0, 0, .1) !important;
}
.product-card.sold-out-card .product-image > button.badge[data-favorite][aria-pressed="true"]:first-of-type {
  color: #fff !important;
  border-color: #a51d58 !important;
  background: #a51d58 !important;
}
.product-card.sold-out-card .product-image > button[data-favorite] .favorite-heart {
  fill: none;
  stroke: currentColor;
}
.product-card.sold-out-card .product-image > button[data-favorite][aria-pressed="true"] .favorite-heart {
  fill: currentColor;
}

.editorial-break,
.collection-showcase,
.bundles-section,
.promotions-section,
.recently-viewed,
.customer-reviews,
.story,
.request-cta {
  content-visibility: auto;
  contain-intrinsic-size: auto 680px;
}

@media (max-width: 700px) {
  .home-product-tabs { margin: -10px 0 24px; }
  .home-product-tabs button { padding: 11px 16px; }
  .launches { padding-bottom: 52px; }
  .discount-pill {
    top: auto;
    bottom: 58px;
    left: 8px;
    max-width: calc(100% - 16px);
    padding: 5px 8px;
    border: 1px solid rgba(255,255,255,.8);
    font-size: 8px;
    line-height: 1;
    box-shadow: 0 4px 12px rgba(97,20,50,.18);
  }
  .advanced-filters { align-items: stretch; }
  .clear-catalog-filters { grid-column: 1 / -1; }
  .product-card.sold-out-card .product-image > span.badge {
    max-width: calc(100% - 54px);
    padding: 7px 9px;
    border-width: 1px;
    font-size: 7px;
    letter-spacing: .1em;
  }
  .product-card.sold-out-card .quick-add {
    min-height: 42px;
    padding: 7px 9px;
    font-size: 7px;
    line-height: 1.2;
  }
  .product-card.sold-out-card .product-info h3 { min-height: 36px; }
  dialog.mobile-category-sheet { top: auto !important; right: 0 !important; bottom: calc(70px + env(safe-area-inset-bottom)) !important; left: 0 !important; width: 100% !important; max-width: none !important; max-height: 68svh !important; margin: 0 !important; padding: 20px 18px 24px !important; border: 0 !important; border-radius: 22px 22px 0 0 !important; visibility: hidden; overflow-y: auto !important; background: #fff !important; box-shadow: 0 -18px 55px rgba(20,20,24,.2) !important; transform: translateY(110%) !important; pointer-events: none; transition: transform .25s ease,visibility .25s !important; }
  dialog.mobile-category-sheet[open].open { display: block !important; visibility: visible; transform: translateY(0) !important; pointer-events: auto; }
  dialog.mobile-category-sheet::backdrop { background: rgba(25,20,23,.42); backdrop-filter: blur(2px); }
  #mobile-category-images { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 11px; overflow: visible; }
  #mobile-category-images a { min-width: 0; display: grid; grid-template-columns: 54px minmax(0,1fr); align-items: center; gap: 11px; padding: 9px; border: 1px solid #eee5e9; border-radius: 15px; color: #30292d; background: #fff9fb; text-align: left; text-decoration: none; }
  #mobile-category-images img { width: 54px; height: 54px; margin: 0; border-radius: 12px; object-fit: cover; }
  #mobile-category-images span { min-width: 0; display: flex; flex-direction: column; gap: 4px; }
  #mobile-category-images strong { overflow: hidden; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
  #mobile-category-images small { color: #8a7e84; font-size: 9px; font-weight: 500; }
  .mobile-categories-empty { grid-column: 1/-1; margin: 4px 0; padding: 18px; border-radius: 13px; color: #756b70; background: #faf6f8; text-align: center; font-size: 11px; }
  .mobile-dock { z-index: 62; }
  #toast.toast { z-index: 200 !important; right: 12px !important; bottom: calc(84px + env(safe-area-inset-bottom)) !important; left: 12px !important; width: auto !important; max-width: 430px; margin: auto; transform: translateY(18px); }
  #toast.toast.show { transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
  .product-skeleton .product-image,
  .product-skeleton .product-info > * { animation: none; }
}
