/* SILVGLO Clean Final v4.1.4 — prevent WooCommerce floated cards from
   collapsing inside the related-products mobile grid. Only single product
   recommendations are affected; desktop, Shop and payments remain unchanged. */
@media (max-width: 767px) {
  body.single-product .related.products,
  body.single-product .woocommerce .related.products,
  body.single-product .sv-woocommerce-shell .related.products {
    clear: both;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    grid-column: 1 / -1 !important;
  }
  body.single-product .related.products ul.products,
  body.single-product .woocommerce .related.products ul.products,
  body.single-product .sv-woocommerce-shell .related.products ul.products {
    display: grid !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    grid-template-columns: repeat(var(--sv414-related-columns, 2), minmax(0, 1fr)) !important;
    gap: var(--sv414-related-row-gap, 24px) var(--sv414-related-gap, 14px) !important;
    padding: 0 !important;
    margin: 0 !important;
    list-style: none;
  }
  /* WooCommerce clearfix pseudo-elements can otherwise consume grid cells. */
  body.single-product .related.products ul.products::before,
  body.single-product .related.products ul.products::after {
    content: none !important;
    display: none !important;
  }
  body.single-product .related.products ul.products li.product,
  body.single-product .woocommerce .related.products ul.products li.product,
  body.single-product .sv-woocommerce-shell .related.products ul.products li.product {
    width: 100% !important;
    max-width: none !important;
    min-width: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    float: none !important;
    clear: none !important;
    display: flex !important;
    flex-direction: column;
    align-items: stretch;
    text-align: center;
    box-sizing: border-box;
  }
  body.single-product .related.products ul.products li.product a.woocommerce-LoopProduct-link,
  body.single-product .related.products ul.products li.product a.woocommerce-loop-product__link {
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    box-sizing: border-box;
  }
  body.single-product .related.products ul.products li.product a img,
  body.single-product .related.products ul.products li.product img.attachment-woocommerce_thumbnail {
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    aspect-ratio: 1 / 1 !important;
    object-fit: contain !important;
    object-position: center !important;
    margin: 0 0 11px !important;
    border-radius: 6px;
    background-color: #f8f8f8;
  }
  body.single-product .related.products ul.products li.product :is(.woocommerce-loop-product__title, h2.woocommerce-loop-product__title) {
    font-size: var(--sv414-related-title, 16px) !important;
    font-weight: 400 !important;
    line-height: 1.4 !important;
    word-break: normal !important;
    overflow-wrap: break-word !important;
    hyphens: none !important;
    margin: 8px 0 7px !important;
    padding: 0 3px !important;
  }
  body.single-product .related.products ul.products li.product .price,
  body.single-product .related.products ul.products li.product .price :is(.amount, bdi) {
    font-size: var(--sv414-related-price, 17px) !important;
    font-weight: 700 !important;
    line-height: 1.35 !important;
    color: #103c30 !important;
  }
  body.single-product .related.products ul.products li.product .price {
    display: block !important;
    margin: 3px 0 12px !important;
  }
  body.single-product .related.products ul.products li.product > :is(a.button, a.add_to_cart_button, a.product_type_variable) {
    box-sizing: border-box !important;
    max-width: 100% !important;
    align-self: center;
    margin-top: auto !important;
    white-space: normal !important;
    word-break: normal !important;
    overflow-wrap: break-word !important;
    padding: 12px 10px !important;
    line-height: 1.3 !important;
  }
  /* WooCommerce block-based product recommendations. */
  body.single-product .wp-block-woocommerce-related-products .wc-block-grid__products,
  body.single-product .wp-block-woocommerce-related-products .wc-block-product-template {
    display: grid !important;
    grid-template-columns: repeat(var(--sv414-related-columns, 2), minmax(0,1fr)) !important;
    gap: var(--sv414-related-row-gap, 24px) var(--sv414-related-gap, 14px) !important;
  }
  body.single-product .wp-block-woocommerce-related-products :is(.wc-block-grid__product, .wc-block-product) {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    margin: 0 !important;
    flex: none !important;
  }
  body.single-product .wp-block-woocommerce-related-products .wc-block-grid__product-image img {
    width: 100% !important;
    height: auto !important;
    aspect-ratio: 1 / 1;
    object-fit: contain;
  }
  body.single-product .wp-block-woocommerce-related-products .wc-block-grid__product-title {
    font-size: var(--sv414-related-title, 16px) !important;
    word-break: normal !important;
    overflow-wrap: break-word !important;
    hyphens: none !important;
  }
}
