/* Hyva preview only: cohesive category width and readable, compact listing cards. */
body.catalog-category-view main.page-main > .category-view.container,
body.catalog-category-view main.page-main > .columns {
  width:100%;
  max-width:980px;
  margin-inline:auto;
  box-sizing:border-box;
  padding-inline:24px;
}
body.catalog-category-view .column.main {min-width:0;}
body.catalog-category-view .products-grid > ul {
  grid-template-columns:minmax(0,1fr);
  align-items:stretch;
  gap:16px;
}
body.catalog-category-view .products-grid li,
body.catalog-category-view .products-grid .product-item {
  min-width:0;
}
body.catalog-category-view .products-grid .product-item {
  height:100%;
}
body.catalog-category-view .products-grid .product-item-photo {
  display:flex;
  justify-content:center;
  align-items:center;
  width:100%;
  height:220px;
  min-height:0;
  overflow:hidden;
  margin-bottom:12px;
}
body.catalog-category-view .products-grid img.product-image-photo {
  display:block;
  width:100%;
  height:100%;
  max-height:220px;
  object-fit:contain;
}
body.catalog-category-view .products-grid .product-info {min-width:0;}
body.catalog-category-view .products-grid .product-item-link {
  overflow-wrap:anywhere;
}
@media(min-width:640px) {
  body.catalog-category-view .products-grid > ul {
    grid-template-columns:repeat(2,minmax(0,1fr));
  }
}
@media(max-width:639px) {
  body.catalog-category-view main.page-main > .category-view.container,
  body.catalog-category-view main.page-main > .columns {padding-inline:16px;}
  body.catalog-category-view .products-grid .product-item-photo {height:190px;}
  body.catalog-category-view .products-grid img.product-image-photo {max-height:190px;}
}

/* Keep category title aligned with the category description and product list. */
body.catalog-category-view main.page-main > .container:has(.page-title) {
  width: 100%;
  max-width: 980px;
  margin-inline: auto;
  padding-inline: 24px;
  box-sizing: border-box;
}
body.catalog-category-view .category-view.container {
  padding-top: 0;
  padding-bottom: 2px;
}
/* Give the cards more room by reducing the oversized desktop filter column. */
@media (min-width: 1024px) {
  body.catalog-category-view main.page-main > .columns {
    display: grid;
    grid-template-columns: 205px minmax(0, 1fr);
    align-items: start;
    gap: 22px;
  }
  body.catalog-category-view main.page-main > .columns > .sidebar-main {
    min-width: 0;
    width: 100%;
    grid-column: 1;
  }
  body.catalog-category-view main.page-main > .columns > .column.main {
    min-width: 0;
    width: 100%;
    grid-column: 2;
  }
}
@media (min-width: 640px) and (max-width: 1023px) {
  body.catalog-category-view main.page-main > .columns {
    display: flex;
    flex-direction: column;
    gap: 14px;
  }
  body.catalog-category-view main.page-main > .columns > .sidebar-main,
  body.catalog-category-view main.page-main > .columns > .column.main {width:100%}
}
body.catalog-category-view .products-grid > ul {
  gap: 18px;
}
body.catalog-category-view .products-grid .product-item-photo {
  height: 205px;
  margin-bottom: 10px;
}
body.catalog-category-view .products-grid img.product-image-photo {
  max-height: 205px;
}
body.catalog-category-view .products-grid .product-item-link {
  line-height: 1.35;
}
@media (max-width: 639px) {
  body.catalog-category-view main.page-main > .container:has(.page-title) {padding-inline: 16px;}
  body.catalog-category-view .products-grid .product-item-photo {height:190px}
  body.catalog-category-view .products-grid img.product-image-photo {max-height:190px}
}
