/**
 * Products catalogue — product stage redesign (TASK-020)
 * Square soft stage + category chip in body so live photos fit.
 */

.catalog-hero {
  padding: 72px 0 56px;
  background:
    radial-gradient(circle at 90% 20%, rgba(44, 145, 219, 0.14), transparent 28%),
    linear-gradient(120deg, #f7fbff, #edf7fc);
  border-bottom: 1px solid var(--line);
}

.catalog-hero h1 {
  margin-top: 12px;
  font-size: clamp(36px, 4.6vw, 58px);
}

.catalog-hero p {
  margin-top: 16px;
  max-width: 52ch;
  font-size: 17px;
}

.catalog-wrap {
  padding-top: 48px;
  padding-bottom: 90px;
}

.filter-panel {
  box-shadow: var(--shadow2);
}

.filter-panel .filter-option {
  padding: 9px 0;
}

.filter-panel .filter-option label {
  font-size: 13px;
  line-height: 1.35;
  gap: 10px;
}

.catalog-grid {
  align-items: stretch;
}

.catalog-grid .product-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  background: #fff;
}

.catalog-grid .product-media {
  aspect-ratio: 4 / 3;
  min-height: 0;
  height: auto;
  background: #fff;
  padding: 0;
}

.catalog-grid .product-body {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.catalog-grid .product-body p {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 0;
}

.catalog-grid .product-actions {
  margin-top: auto;
}

.catalog-toolbar {
  gap: 14px;
}

.catalog-toolbar .search-box {
  flex: 1;
}

.catalog-toolbar select {
  min-width: 160px;
}

.no-results {
  border: 1px dashed #bfcfdd;
  border-radius: 20px;
  padding: 55px 28px;
  text-align: center;
  color: var(--muted);
  background: #fbfcfe;
}

.no-results[hidden],
.no-results:not(.is-visible) {
  display: none;
}

.no-results.is-visible,
.no-results:not([hidden]) {
  display: block;
}

@media (max-width: 900px) {
  .catalog-wrap {
    padding-top: 28px;
  }

  .catalog-toolbar {
    display: grid;
  }

  .catalog-toolbar select {
    width: 100%;
  }

  .catalog-grid .product-media {
    min-height: 0;
  }
}

@media (max-width: 640px) {
  .catalog-grid .product-media {
    min-height: 0;
  }

  .product-media img {
    inset: 8px 10px;
    width: calc(100% - 20px);
    height: calc(100% - 16px);
  }
}
