/* CANOPY MARKETPLACE-REFERENCE RUNTIME COMPOSITION FIX V25.2.3 */

body.canopy-desktop {
    background-image:
        linear-gradient(
            color-mix(in srgb, var(--canopy-site-background) 93%, transparent),
            color-mix(in srgb, var(--canopy-site-background) 93%, transparent)
        ),
        url("/images/canopy-leafy-watermark-v25.2.0.svg") !important;
    background-size: auto, 1050px 790px !important;
}

body.canopy-desktop > main.shell.page-content {
    padding-top: 24px;
}

body.canopy-desktop .canopy-marketplace-product-page {
    width: calc(100% - 28px) !important;
    max-width: 1540px !important;
    margin-right: auto !important;
    margin-left: auto !important;
    padding: 12px 16px 28px !important;
    background: rgba(255, 255, 255, .985) !important;
}

body.canopy-desktop .canopy-marketplace-product-grid {
    display: grid !important;
    grid-template-columns:
        58px
        minmax(300px, 1.08fr)
        minmax(330px, .94fr)
        minmax(265px, 292px) !important;
    gap: 14px !important;
    align-items: start !important;
}

body.canopy-desktop .canopy-marketplace-thumbnail-rail {
    width: 58px !important;
    min-width: 58px !important;
}

body.canopy-desktop .canopy-marketplace-thumb {
    width: 54px !important;
    height: 54px !important;
}

body.canopy-desktop .canopy-marketplace-main-media {
    width: auto !important;
    min-width: 0 !important;
    margin: 0 !important;
    padding: 0 4px 0 0 !important;
}

body.canopy-desktop .canopy-marketplace-main-media-frame {
    min-height: 470px !important;
    max-height: 560px !important;
}

body.canopy-desktop .canopy-marketplace-main-media-frame img,
body.canopy-desktop .canopy-marketplace-main-media-frame video {
    width: 100% !important;
    max-height: 560px !important;
    object-fit: contain !important;
}

body.canopy-desktop section.canopy-marketplace-product-information {
    display: block !important;
    width: auto !important;
    min-width: 0 !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 0 4px !important;
}

body.canopy-desktop section.canopy-marketplace-product-information > * {
    min-width: 0 !important;
    max-width: 100% !important;
}

body.canopy-desktop section.canopy-marketplace-product-information > * + * {
    margin-top: 8px !important;
}

body.canopy-desktop section.canopy-marketplace-product-information > h1 {
    width: auto !important;
    max-width: none !important;
    margin: 0 0 4px !important;
    font-size: clamp(1.38rem, 1.55vw, 1.72rem) !important;
    font-weight: 600 !important;
    line-height: 1.18 !important;
    letter-spacing: -.012em !important;
    overflow-wrap: normal !important;
    word-break: normal !important;
}

body.canopy-desktop .canopy-marketplace-seller-link {
    display: inline-block !important;
    margin: 0 !important;
    font-size: .8rem !important;
}

body.canopy-desktop .canopy-marketplace-activity-line {
    display: flex !important;
    width: 100% !important;
    margin: 6px 0 0 !important;
    gap: 5px 9px !important;
    align-items: center !important;
}

body.canopy-desktop .canopy-marketplace-marketplace-badge {
    max-width: 100% !important;
    white-space: nowrap !important;
}

body.canopy-desktop .canopy-marketplace-product-information hr {
    width: 100% !important;
    margin: 10px 0 !important;
}

body.canopy-desktop .canopy-marketplace-center-price {
    display: flex !important;
    width: 100% !important;
    margin: 8px 0 0 !important;
    gap: 6px !important;
    align-items: baseline !important;
}

body.canopy-desktop .canopy-marketplace-center-price strong {
    font-size: 1.7rem !important;
    line-height: 1 !important;
}

body.canopy-desktop .canopy-marketplace-center-stock {
    display: block !important;
    width: 100% !important;
    max-width: none !important;
    margin: 7px 0 12px !important;
    clear: both !important;
    color: #365846 !important;
    font-size: .8rem !important;
    line-height: 1.35 !important;
    white-space: normal !important;
}

body.canopy-desktop .canopy-marketplace-center-stock strong {
    display: inline !important;
    width: auto !important;
    max-width: none !important;
    white-space: normal !important;
}

body.canopy-desktop .canopy-marketplace-detail-row {
    display: block !important;
    width: 100% !important;
    min-width: 0 !important;
    margin: 0 !important;
    border-top: 1px solid #d7ddd8 !important;
}

body.canopy-desktop .canopy-marketplace-detail-row:last-of-type {
    border-bottom: 1px solid #d7ddd8 !important;
}

body.canopy-desktop .canopy-marketplace-detail-row > summary {
    display: list-item !important;
    width: 100% !important;
    padding: 12px 0 !important;
    margin: 0 !important;
    color: #172018 !important;
    cursor: pointer !important;
    font-size: .96rem !important;
    font-weight: 760 !important;
    line-height: 1.2 !important;
}

body.canopy-desktop .canopy-marketplace-highlight-list {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 7px 18px !important;
    width: 100% !important;
    margin: 0 0 12px !important;
}

body.canopy-desktop .canopy-marketplace-highlight-list > div {
    display: grid !important;
    grid-template-columns: 88px minmax(0, 1fr) !important;
    gap: 8px !important;
    min-width: 0 !important;
    padding: 2px 0 !important;
    font-size: .76rem !important;
    line-height: 1.3 !important;
}

body.canopy-desktop .canopy-marketplace-highlight-list dt {
    color: #34443a !important;
    font-weight: 760 !important;
}

body.canopy-desktop .canopy-marketplace-highlight-list dd {
    min-width: 0 !important;
    margin: 0 !important;
    color: #4f5c54 !important;
    overflow-wrap: anywhere !important;
}

body.canopy-desktop .canopy-marketplace-detail-row > p {
    width: 100% !important;
    margin: 0 0 12px !important;
    font-size: .8rem !important;
    line-height: 1.5 !important;
}

body.canopy-desktop .canopy-marketplace-detail-row .pc-inline {
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 0 12px !important;
    padding: 0 !important;
}

body.canopy-desktop .canopy-marketplace-detail-row
.pc-inline-expanded .pc-disclosure-card {
    padding: 0 !important;
    background: transparent !important;
}

body.canopy-desktop .canopy-marketplace-purchase-column {
    position: sticky !important;
    top: 88px !important;
    grid-column: auto !important;
    align-self: start !important;
    width: auto !important;
    min-width: 0 !important;
    margin: 0 !important;
}

body.canopy-desktop .canopy-marketplace-purchase-box {
    width: 100% !important;
    min-width: 0 !important;
    padding: 14px !important;
}

body.canopy-desktop .canopy-marketplace-buybox-price strong,
body.canopy-desktop .canopy-marketplace-auction-opening {
    font-size: 1.6rem !important;
}

body.canopy-desktop .canopy-marketplace-buybox-quantity {
    grid-template-columns: auto minmax(0, 1fr) !important;
}

body.canopy-desktop .canopy-marketplace-buybox-quantity input {
    width: 100% !important;
    max-width: 98px !important;
}

body.canopy-desktop .canopy-marketplace-related-section {
    margin-top: 160px !important;
}

/* Separate recommendations from the product details while keeping the two
   recommendation rails visually grouped together. */
body.canopy-desktop .canopy-marketplace-seller-related-section {
    margin-top: 160px !important;
}

body.canopy-desktop .canopy-marketplace-seller-related-section +
    .canopy-marketplace-related-section {
    margin-top: 32px !important;
}
/* Give every related Buy Now product the same image footprint regardless of
   the source image's aspect ratio. */
body.canopy-desktop .canopy-marketplace-related-section .canopy-commerce-product-rail {
    grid-auto-columns: 180px;
}

body.canopy-desktop .canopy-marketplace-related-section .canopy-commerce-card-media {
    width: 180px;
    height: 180px;
    aspect-ratio: auto;
}

body.canopy-desktop .canopy-marketplace-related-section .canopy-commerce-card-media img {
    display: block;
    width: 100% !important;
    height: 100% !important;
    object-fit: cover;
    object-position: center;
}

/* Keep the Marketplace-style four-column layout on ordinary desktop widths.
   Collapse only when four useful columns can no longer fit. */
@media (max-width: 1080px) {
    body.canopy-desktop .canopy-marketplace-product-page {
        width: calc(100% - 16px) !important;
    }

    body.canopy-desktop .canopy-marketplace-product-grid {
        grid-template-columns:
            56px
            minmax(285px, 1fr)
            minmax(310px, 1fr) !important;
    }

    body.canopy-desktop .canopy-marketplace-purchase-column {
        position: static !important;
        grid-column: 2 / -1 !important;
    }
}

@media (max-width: 760px) {
    body.canopy-desktop .canopy-marketplace-product-grid {
        grid-template-columns: 52px minmax(0, 1fr) !important;
    }

    body.canopy-desktop section.canopy-marketplace-product-information,
    body.canopy-desktop .canopy-marketplace-purchase-column {
        grid-column: 1 / -1 !important;
    }

    body.canopy-desktop .canopy-marketplace-highlight-list {
        grid-template-columns: 1fr !important;
    }
}
