.catalog,
.catalog button,
.catalog input {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
}

.section-kicker { display: none; }
.section-heading { margin-bottom: 20px; }
.section-heading h2 { margin: 0; font-size: 19px; font-weight: 700; letter-spacing: 0; }
.search { height: 36px; border-radius: 4px; background: #f5f6f8; }
.search input { font-size: 12px; }

.categories {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
  overflow: visible;
}

.category {
  min-width: 0;
  display: flex;
  align-items: flex-start;
  flex-direction: column;
  gap: 5px;
  padding: 12px 15px;
  text-align: left;
  font-weight: 400;
}

.category b {
  max-width: 100%;
  overflow: hidden;
  font-size: 12px;
  font-weight: 400;
  text-overflow: ellipsis;
}

.category small { color: #9aa3ad; font-size: 10px; font-weight: 400; opacity: 1; }
.category.active b { font-weight: 600; }
.category.active small { color: rgba(255, 255, 255, .82); }
.result-meta { font-size: 11px; }

.product-grid {
  grid-template-columns: repeat(4, minmax(0, 218px));
  gap: 14px;
  justify-content: start;
}

.product,
.product.has-image {
  min-width: 0;
  min-height: 0;
  content-visibility: auto;
  contain-intrinsic-size: auto 286px;
  padding: 0 13px 13px;
  overflow: hidden;
  border-color: #dfe8f3;
  border-radius: 13px;
  box-shadow: 0 2px 8px rgba(30, 73, 118, .04);
}

.product:hover {
  transform: translateY(-2px);
  border-color: #b9d9fb;
  box-shadow: 0 10px 24px rgba(31, 90, 145, .11);
}

.product .product-top,
.product.has-image .product-top {
  position: relative;
  margin: 0 -13px;
}

.product-cover {
  width: 100%;
  aspect-ratio: 1 / 1;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: #fff;
  border-bottom: 1px solid #edf2f7;
}

.product-cover img {
  width: 100%;
  height: 100%;
  display: block;
  opacity: 0;
  object-fit: contain;
  object-position: center;
  transition: opacity .16s ease;
}

.product-cover img.is-loaded { opacity: 1; }
.product-cover img[hidden],
.product-image-fallback[hidden] { display: none; }

@media (prefers-reduced-motion: reduce) {
  .product-cover img { transition: none; }
}

.product-placeholder {
  width: 72%;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 10px;
  color: var(--accent, #168df2);
  border: 1px dashed color-mix(in srgb, var(--accent, #168df2) 35%, #dce7f2);
  border-radius: 24%;
  background: color-mix(in srgb, var(--accent, #168df2) 6%, #fff);
}

.product-placeholder b { font-size: clamp(25px, 3vw, 42px); }
.product-placeholder small { color: #8a98aa; font-size: 10px; }

.product h3,
.product.has-image h3 {
  min-height: 20px;
  display: block;
  overflow: hidden;
  margin: 11px 1px 5px;
  font-size: 12px;
  font-weight: 400;
  line-height: 20px;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.product > p { display: none; }
.product-bottom { align-items: center; margin-top: 7px; }
.price small { margin-bottom: 1px; font-size: 9px; font-weight: 400; }
.price b { font-size: 17px; font-weight: 700; }
.inventory-status {
  padding: 4px 7px;
  font-size: 9px;
  font-weight: 600;
  border-radius: 4px;
}
.inventory-status.in-stock { color: #1685ee; background: #edf6ff; }
.inventory-status.low-stock { color: #e89513; background: #fff7df; }
.inventory-status.sold-out { color: #ff6743; background: #fff0e9; }

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

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

@media (max-width: 720px) {
  .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
}

@media (max-width: 600px) {
  .categories { display: flex; overflow-x: auto; }
  .category { min-width: 135px; }
  .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .product, .product.has-image { padding: 0 10px 11px; border-radius: 11px; }
  .product .product-top, .product.has-image .product-top { margin: 0 -10px; }
  .product h3, .product.has-image h3 { min-height: 19px; margin-top: 8px; font-size: 11px; line-height: 19px; }
  .inventory-status { padding: 4px 6px; font-size: 9px; }
  .price b { font-size: 17px; }
}
