/*
 * Heikaya v6.19.1
 * Single-product page only.
 * Related Products styled to visually match the Homepage Featured Selection.
 * The homepage itself is not touched.
 */

/* Stock quantity control state. */
body.single-product form.cart .lumiere-qty-step:disabled,
body.single-product form.cart .lumiere-qty-step[aria-disabled="true"] {
    opacity: .32 !important;
    cursor: not-allowed !important;
    pointer-events: none !important;
}

/* ============================================================
   RELATED PRODUCTS
   ============================================================ */

body.single-product .related.products {
    clear: both !important;
    width: 100% !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 72px 0 10px !important;
    background: #fffdf9 !important;
}

body.single-product .related.products > h2 {
    margin: 0 0 32px !important;
    padding: 0 !important;
    color: #15120f !important;
    font-family: "Cormorant Garamond", Georgia, serif !important;
    font-size: clamp(40px, 4vw, 58px) !important;
    font-weight: 500 !important;
    line-height: 1 !important;
    letter-spacing: -.015em !important;
    text-align: center !important;
    text-transform: none !important;
}

/* Force exactly four cards on desktop. */
body.single-product .related.products ul.products,
body.single-product .related.products ul.products.columns-3,
body.single-product .related.products ul.products.columns-4 {
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: clamp(16px, 1.8vw, 28px) !important;
    width: 100% !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 0 !important;
    list-style: none !important;
}

body.single-product .related.products ul.products::before,
body.single-product .related.products ul.products::after {
    display: none !important;
    content: none !important;
}

body.single-product .related.products ul.products li.product {
    float: none !important;
    clear: none !important;
    display: flex !important;
    flex-direction: column !important;
    width: 100% !important;
    max-width: none !important;
    min-width: 0 !important;
    height: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    text-align: center !important;
}

/* Image stage = Featured Selection card language. */
body.single-product .related.products li.product > a.woocommerce-LoopProduct-link,
body.single-product .related.products li.product .astra-shop-thumbnail-wrap > a {
    display: block !important;
    color: #15120f !important;
    text-decoration: none !important;
}

body.single-product .related.products li.product .astra-shop-thumbnail-wrap,
body.single-product .related.products li.product > a.woocommerce-LoopProduct-link > img,
body.single-product .related.products li.product .woocommerce-loop-product__link > img {
    position: relative !important;
}

body.single-product .related.products li.product .astra-shop-thumbnail-wrap {
    display: block !important;
    width: 100% !important;
    aspect-ratio: 1 / 1 !important;
    overflow: hidden !important;
    border: 1px solid rgba(21,18,15,.15) !important;
    border-radius: 18px !important;
    background: #fffdf9 !important;
    box-shadow: 0 14px 34px rgba(29,22,16,.055) !important;
}

body.single-product .related.products li.product .astra-shop-thumbnail-wrap img,
body.single-product .related.products li.product > a.woocommerce-LoopProduct-link > img,
body.single-product .related.products li.product .woocommerce-loop-product__link > img {
    display: block !important;
    width: 100% !important;
    height: 100% !important;
    margin: 0 !important;
    padding: 10px !important;
    object-fit: contain !important;
    object-position: center !important;
    transition: transform .35s ease !important;
}

body.single-product .related.products li.product:hover .astra-shop-thumbnail-wrap img,
body.single-product .related.products li.product:hover > a.woocommerce-LoopProduct-link > img {
    transform: scale(1.025) !important;
}

/* Product copy aligned like Featured Selection. */
body.single-product .related.products li.product .astra-shop-summary-wrap,
body.single-product .related.products li.product .woocommerce-loop-product__link {
    text-align: center !important;
}

body.single-product .related.products li.product .astra-shop-summary-wrap {
    display: flex !important;
    flex: 1 1 auto !important;
    flex-direction: column !important;
    align-items: center !important;
    width: 100% !important;
    padding: 13px 4px 0 !important;
}

body.single-product .related.products li.product .woocommerce-loop-product__title {
    display: -webkit-box !important;
    min-height: 2.25em !important;
    margin: 0 !important;
    overflow: hidden !important;
    color: #15120f !important;
    font-family: "Cormorant Garamond", Georgia, serif !important;
    font-size: clamp(20px, 1.45vw, 25px) !important;
    font-weight: 500 !important;
    line-height: 1.08 !important;
    text-align: center !important;
    text-transform: none !important;
    -webkit-box-orient: vertical !important;
    -webkit-line-clamp: 2 !important;
}

body.single-product .related.products li.product .price {
    margin: 8px 0 0 !important;
    color: #15120f !important;
    font-family: Montserrat, Arial, sans-serif !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    text-align: center !important;
}

/* Keep product-card actions aligned underneath. */
body.single-product .related.products li.product .button,
body.single-product .related.products li.product .added_to_cart {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    min-height: 42px !important;
    margin: 14px auto 0 !important;
    padding: 0 18px !important;
    border: 1px solid #15120f !important;
    border-radius: 999px !important;
    background: #15120f !important;
    color: #fffdf9 !important;
    -webkit-text-fill-color: #fffdf9 !important;
    font-family: Montserrat, Arial, sans-serif !important;
    font-size: 9px !important;
    font-weight: 700 !important;
    letter-spacing: .11em !important;
    text-decoration: none !important;
    text-transform: uppercase !important;
}

body.single-product .related.products li.product .button:hover,
body.single-product .related.products li.product .added_to_cart:hover {
    background: #fffdf9 !important;
    color: #15120f !important;
    -webkit-text-fill-color: #15120f !important;
}

/* Hide default star rating to keep the same clean editorial card rhythm. */
body.single-product .related.products li.product .star-rating {
    display: none !important;
}

@media (max-width: 980px) {
    body.single-product .related.products ul.products,
    body.single-product .related.products ul.products.columns-3,
    body.single-product .related.products ul.products.columns-4 {
        grid-template-columns: repeat(2, minmax(0,1fr)) !important;
        gap: 22px 12px !important;
    }
}

@media (max-width: 767px) {
    body.single-product .related.products {
        padding-top: 42px !important;
    }

    body.single-product .related.products > h2 {
        margin-bottom: 20px !important;
        font-size: 34px !important;
    }

    body.single-product .related.products ul.products,
    body.single-product .related.products ul.products.columns-3,
    body.single-product .related.products ul.products.columns-4 {
        grid-template-columns: repeat(2, minmax(0,1fr)) !important;
        gap: 18px 9px !important;
    }

    body.single-product .related.products li.product .astra-shop-thumbnail-wrap {
        border-radius: 12px !important;
    }

    body.single-product .related.products li.product .astra-shop-thumbnail-wrap img,
    body.single-product .related.products li.product > a.woocommerce-LoopProduct-link > img,
    body.single-product .related.products li.product .woocommerce-loop-product__link > img {
        padding: 6px !important;
    }

    body.single-product .related.products li.product .astra-shop-summary-wrap {
        padding: 9px 2px 0 !important;
    }

    body.single-product .related.products li.product .woocommerce-loop-product__title {
        min-height: 2.2em !important;
        font-size: 15px !important;
    }

    body.single-product .related.products li.product .price {
        margin-top: 5px !important;
        font-size: 11px !important;
    }

    body.single-product .related.products li.product .button,
    body.single-product .related.products li.product .added_to_cart {
        min-height: 38px !important;
        margin-top: 10px !important;
        padding: 0 12px !important;
        font-size: 8px !important;
    }
}
