/* Photo grid for the main catalogue. The existing rarity frames paint above these cards. */
body.storefront-page.cs-cinema-home main #products.product-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  gap: clamp(12px, 1.5vw, 24px) !important;
  padding-top: 4px;
}

body.storefront-page.cs-cinema-home main #products > .product-card.cg-fixed {
  grid-template-columns: minmax(0, 1fr) auto !important;
  grid-template-rows: auto auto auto auto minmax(60px, 1fr) auto !important;
  align-content: stretch !important;
  gap: 6px 10px !important;
  height: auto !important;
  min-height: 0 !important;
  max-height: none !important;
  padding: calc(12px - var(--cg-border, 0px)) !important;
  contain-intrinsic-block-size: auto 430px;
}

.cs-cinema-home #products > .cg-fixed > :is(.cg-photo, .cg-title, .cg-details, .growth-facts, .shortlist-actions) {
  grid-column: 1 / -1;
}

.cs-cinema-home #products > .cg-fixed > .cg-photo {
  height: auto;
  min-width: 0;
  grid-row: 1;
}

body.storefront-page.cs-cinema-home main #products > .cg-fixed .cg-photo .product-image {
  height: auto !important;
  min-height: 0 !important;
  max-height: none !important;
  aspect-ratio: 6 / 5 !important;
  border-radius: 6px;
}

body.storefront-page.cs-cinema-home main #products > .cg-fixed .product-image :is(img, svg) {
  max-height: none !important;
  padding: 0 !important;
}

.cs-cinema-home #products > .cg-fixed > .cg-label {
  position: absolute;
  grid-area: auto;
  z-index: 3;
  inset: 20px auto auto 20px;
  height: auto;
  pointer-events: none;
}

.cs-cinema-home #products > .cg-fixed .rarity-plaque {
  display: none !important;
}

.cs-cinema-home #products > .cg-fixed .cg-rarity {
  background-color: #242015;
}

body.storefront-page.cs-cinema-home main #products > .cg-fixed > .cg-title {
  grid-row: 2;
  height: auto !important;
  min-height: 2.5em !important;
  max-height: none !important;
  font-size: clamp(15px, 1.4vw, 21px) !important;
  line-height: 1.25 !important;
  overflow-wrap: anywhere;
}

body.storefront-page.cs-cinema-home main #products > .cg-fixed > .cg-details {
  grid-row: 3;
  height: auto !important;
  min-height: 0 !important;
  max-height: none !important;
  font-size: 12px !important;
  line-height: 1.4 !important;
  overflow-wrap: anywhere;
}

body.storefront-page.cs-cinema-home main #products > .cg-fixed > .growth-facts {
  grid-row: 4;
  min-height: 0;
  color: #b9c0cb;
  overflow-wrap: anywhere;
}

body.storefront-page.cs-cinema-home main #products > .cg-fixed > :is(.cg-details, .growth-facts):empty {
  display: none !important;
}

.cs-cinema-home #products > .cg-fixed > .cg-price {
  grid-area: 5 / 1;
  align-self: end;
  grid-template-rows: auto auto auto;
  height: auto;
  gap: 0;
}

.cs-cinema-home #products > .cg-fixed .cg-saving:empty {
  display: none;
}

.cs-cinema-home #products > .cg-fixed .cg-amount {
  font-size: clamp(20px, 1.65vw, 25px);
  line-height: 1.22;
  white-space: normal;
  overflow-wrap: anywhere;
}

.cs-cinema-home #products > .cg-fixed .cg-stock {
  white-space: normal;
  overflow-wrap: anywhere;
}

body.storefront-page.cs-cinema-home main #products > .cg-fixed .add-button.cg-button {
  grid-area: 5 / 2;
  align-self: end !important;
  min-height: 44px !important;
  height: auto !important;
  max-height: none !important;
  padding-inline: 9px !important;
}

body.storefront-page.cs-cinema-home main #products > .cg-fixed > .shortlist-actions {
  grid-row: 6;
  margin: 2px 0 0;
  padding-top: 5px;
  border-top: 1px solid #ffffff22;
}

.cs-cinema-home #products > .cg-fixed > .shortlist-actions button {
  min-height: 44px;
  margin: 0 6px 0 0;
  background: #ffffff08;
  border-color: #ffffff30;
  color: #e2e5eb;
  font-size: 12px;
}

.cs-cinema-home #products > .cg-fixed > .shortlist-actions button:is(:hover, [aria-pressed="true"]) {
  background: #ffffff16;
}

.cs-cinema-home #products > .cg-fixed > .shortlist-actions button:focus-visible {
  outline: 2px solid #ffad4d;
  outline-offset: 2px;
}

@media (max-width: 1099px) {
  body.storefront-page.cs-cinema-home main #products.product-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
}

@media (max-width: 599px) {
  body.storefront-page.cs-cinema-home main #products.product-grid {
    grid-template-columns: minmax(0, 1fr) !important;
  }

  body.storefront-page.cs-cinema-home main #products > .cg-fixed > .cg-title {
    min-height: 0 !important;
  }
}

@media (min-width: 1100px) and (not (pointer: coarse)) {
  body.storefront-page.cs-cinema-home main #products.product-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  }

  body.storefront-page.cs-cinema-home main #products > .product-card.cg-fixed {
    grid-template-columns: minmax(0, 1fr) fit-content(48%) !important;
    column-gap: 8px !important;
    padding: calc(10px - var(--cg-border, 0px)) !important;
  }

  .cs-cinema-home #products > .cg-fixed .cg-amount {
    font-size: clamp(18px, 1.45vw, 23px);
  }
}

body.storefront-page.cs-cinema-home main #products > .cg-fixed > .cg-product-link {
  grid-area: 5 / 2;
  align-self: end;
  justify-self: end;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: #ffb351;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.25;
  white-space: nowrap;
  text-decoration: none;
}

.cs-cinema-home #products .cg-product-link:is(:hover, :focus-visible) {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.cs-cinema-home #products .cg-product-link:focus-visible {
  outline: 2px solid #ffb351;
  outline-offset: 2px;
}

#products .product-image .quick-view { display: none !important; }
