/* HG Store offer grid: WooCommerce archives, related offers / up-sells under an offer page, cart cross-sells.
   Scoped by the grid class (added by HG_Store_Presentation::catalog_grid), not by the page type. */

body ul.products.hg-shop-catalog {
  display: grid;
  grid-template-columns: repeat(3,minmax(0,1fr));
  gap: 20px;
  max-width: none;
  width: 100%;
  margin: 0 0 28px;
  padding: 0;
  list-style: none;
}

body ul.products.hg-shop-catalog::before,
body ul.products.hg-shop-catalog::after {
  display: none;
}

body ul.products.hg-shop-catalog>li.product {
  float: none;
  width: 100%;
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  overflow: visible;
}

body .hg-shop-product .hg-public-card {
  height: 100%;
}

body ul.hg-shop-catalog .hg-shop-product .hg-public-image img {
  margin: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

@media(max-width:900px) {
  body ul.products.hg-shop-catalog {
    grid-template-columns: repeat(2,minmax(0,1fr));
    gap: 12px;
  }
}

@media(max-width:340px) {
  body ul.products.hg-shop-catalog {
    grid-template-columns: minmax(0,1fr);
  }
}

/* PATCH032: shop cards show the actual image instead of cropping portraits. */
body ul.hg-shop-catalog .hg-shop-product .hg-public-image img { object-fit: contain; }

/* PATCH040: related offers section spacing on the offer page. */
body .related.products > h2, body .up-sells > h2, body .cross-sells > h2 { margin: 28px 0 14px; }
