/* Keep the price and the stock/SKU block side by side, including the VAT note. */
body.catalog-product-view .product-info-main .product-info-price {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    column-gap: 16px;
    row-gap: 3px;
    align-items: center;
    width: 100%;
}
body.catalog-product-view .product-info-main .product-info-price > .price-box {
    grid-column: 1;
    grid-row: 1;
    display: block;
    width: auto;
    margin: 0;
    padding: 0;
}
body.catalog-product-view .product-info-main .product-info-price > .retailer-price-notice {
    grid-column: 1;
    grid-row: 2;
    margin: 0 !important;
}
body.catalog-product-view .product-info-main .product-info-price > .product-info-stock-sku {
    grid-column: 2;
    grid-row: 1 / span 2;
    align-self: center;
    display: block;
    width: auto;
    margin: 0;
    padding: 0;
    text-align: right;
}
body.catalog-product-view .product-info-price .product.attribute.sku {
    white-space: nowrap;
}

body.catalog-product-view .bundle-options-container {
    margin: 24px 0 0;
    padding: 20px 22px 24px;
    border: 1px solid #eadfdb;
    border-radius: 14px;
    background: #fffdfc;
    box-shadow: 0 2px 12px rgba(111, 21, 23, .06);
}
body.catalog-product-view.page-product-bundle .bundle-options-container .fieldset,
body.catalog-product-view.page-product-bundle .bundle-options-container .fieldset-bundle-options {
    margin-bottom: 0;
}
body.catalog-product-view.page-product-bundle .bundle-options-container .field.qty {
    margin-bottom: 0;
}
body.catalog-product-view.page-product-bundle .bundle-options-container #validation-message-box-radio {
    min-height: 0;
}
body.catalog-product-view.page-product-bundle .bundle-options-wrapper,
body.catalog-product-view.page-product-bundle .product-options-wrapper,
body.catalog-product-view.page-product-bundle .fieldset-bundle-options {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
}
body.catalog-product-view.page-product-bundle #product-options-wrapper,
body.catalog-product-view.page-product-bundle .bundle-options-wrapper .product-options-wrapper {
    display: block !important;
    height: auto !important;
    max-height: none !important;
}
body.catalog-product-view.page-product-bundle .bundle-options-container .product-add-form {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
}
body.page-product-bundle .bundle-options-container {
    display: none !important;
}
body.page-product-bundle.ls-bundle-ready .bundle-options-container {
    display: block !important;
}
body.page-product-bundle.ls-bundle-guest .bundle-options-container .price-notice,
body.page-product-bundle.ls-bundle-guest .bundle-options-container .bundle-option-price {
    display: none !important;
}
body.page-product-bundle:has(.b2b-cta-pdp) .bundle-options-container .price-notice,
body.page-product-bundle:has(.b2b-cta-pdp) .bundle-options-container .bundle-option-price {
    display: none !important;
}
body.catalog-product-view.page-product-bundle .product-top-main {
    display: grid !important;
    grid-template-columns: minmax(0, 55%) minmax(0, 40%);
    column-gap: 5%;
    align-items: start;
    /* Title, options box and reviews keep their natural height; the extra
     * height of the tall gallery goes into the last row, below the content. */
    grid-template-rows: auto auto 1fr;
}
body.page-product-bundle .product-top-main {
    visibility: hidden;
}
/* Pearl's v2 sticky script writes an inline pixel height on the gallery while
 * scrolling. Inside this grid that height inflates the last row and leaves a
 * large blank area under the gallery (seen after choosing a bundle option). */
@media (min-width: 768px) {
    body.catalog-product-view.page-product-bundle .product-top-main > .product.media {
        height: auto !important;
    }
}
body.page-product-bundle.ls-bundle-ready .product-top-main {
    visibility: visible;
}
body.catalog-product-view.page-product-bundle .product-top-main > .product.media {
    grid-column: 1;
    grid-row: 1 / span 3;
    width: 100% !important;
    float: none !important;
}
body.catalog-product-view.page-product-bundle .product-top-main > .product-info-main {
    grid-column: 2;
    grid-row: 1;
    width: 100% !important;
    float: none !important;
}
body.catalog-product-view.page-product-bundle .product-top-main > .bundle-options-container {
    grid-column: 2;
    grid-row: 2;
    display: block !important;
    width: 100% !important;
    float: none !important;
    clear: both;
    margin-top: 22px;
    align-self: start;
    height: fit-content !important;
    min-height: 0 !important;
}
body.catalog-product-view.page-product-bundle .product-top-main > .product-info-main-extend {
    grid-column: 2;
    grid-row: 3;
    width: 100% !important;
    max-width: none !important;
    clear: none;
    margin-top: 18px;
    display: block !important;
    align-self: start;
}
/* Empty price/summary area between the options and the CTA buttons. */
body.catalog-product-view.page-product-bundle .bundle-options-container .product-options-wrapper {
    margin-bottom: 0 !important;
}
body.catalog-product-view.page-product-bundle .bundle-options-container .product-options-bottom {
    margin: 0 !important;
    padding: 0 !important;
}
body.catalog-product-view.page-product-bundle .bundle-options-container p.required {
    margin-bottom: 0;
}
body.catalog-product-view.page-product-bundle .product-top-main > .product-info-main-extend .accordion-1,
body.catalog-product-view.page-product-bundle .product-top-main > .product-info-main-extend .product.data.items {
    width: 100% !important;
    max-width: none !important;
}
body.catalog-product-view.page-product-bundle .product-info-main {
    position: static !important;
    top: auto !important;
    left: auto !important;
}
body.catalog-product-view.page-product-bundle .product-info-main.pp-fixed,
body.catalog-product-view.page-product-bundle .product-info-main.product_v2.pp-fixed {
    position: static !important;
    top: auto !important;
    left: auto !important;
    width: 100% !important;
    transform: none !important;
}
body.catalog-product-view.page-product-bundle .product-info-main .product-info-price > .price-box,
body.catalog-product-view.page-product-bundle .product-info-main .product-info-price > .retailer-price-notice {
    display: none !important;
}
body.catalog-product-view.page-product-bundle .bundle-options-container .box-tocart,
body.catalog-product-view.page-product-bundle .bundle-options-container .product-options-bottom,
body.catalog-product-view.page-product-bundle .bundle-options-container hr {
    border-top: 0 !important;
    box-shadow: none !important;
}
body.catalog-product-view.page-product-bundle .block-bundle-summary > .title,
body.catalog-product-view.page-product-bundle .block-bundle-summary .bundle-summary {
    display: none !important;
}
body.catalog-product-view.page-product-bundle .product-info-main-extend {
    width: 100% !important;
    max-width: none !important;
    clear: both;
}
body.catalog-product-view.page-product-bundle .product-info-main-extend .product.info.detailed,
body.catalog-product-view.page-product-bundle .product-info-main-extend .product.data.items {
    width: 100% !important;
}
body.catalog-product-view.page-product-bundle #reviews {
    display: block;
}
body.catalog-product-view.page-product-bundle .action.customization.back,
body.catalog-product-view.page-product-bundle #bundle-slide {
    display: none !important;
}
body.catalog-product-view .bundle-options-container .legend.title {
    color: #8a171b;
    font-size: 22px;
    font-weight: 700;
    line-height: 1.25;
    margin-bottom: 12px;
}
body.catalog-product-view .bundle-options-container .bundle-option,
body.catalog-product-view .bundle-options-container .field.option {
    margin: 0;
    padding: 10px 12px;
    border-radius: 8px;
    transition: background-color .15s ease;
}
body.catalog-product-view .bundle-options-container .bundle-option:hover,
body.catalog-product-view .bundle-options-container .field.option:hover {
    background: #fff0ed;
}
body.catalog-product-view .bundle-options-container .bundle-option input[type="radio"] {
    accent-color: #8a171b;
    margin-right: 10px;
}
body.catalog-product-view .bundle-options-container .bundle-option label,
body.catalog-product-view .bundle-options-container .bundle-option .product-name {
    color: #2d2927;
    font-size: 16px;
    font-weight: 600;
}
body.catalog-product-view .bundle-options-container .bundle-option-price,
body.catalog-product-view .bundle-options-container .price-notice {
    color: #8a171b;
    font-weight: 700;
}
body.catalog-product-view .bundle-options-container .field.qty {
    margin-top: 14px;
    padding-top: 14px;
    border: 0 !important;
    border-top: 0 !important;
    border-bottom: 0 !important;
}
@media (max-width: 767px) {
    body.catalog-product-view.page-product-bundle .product-top-main {
        display: block !important;
    }
    body.catalog-product-view.page-product-bundle .product-top-main > .product.media,
    body.catalog-product-view.page-product-bundle .product-top-main > .product-info-main,
    body.catalog-product-view.page-product-bundle .product-top-main > .bundle-options-container,
    body.catalog-product-view.page-product-bundle .product-top-main > .product-info-main-extend {
        width: 100% !important;
    }
    body.catalog-product-view .bundle-options-container {
        padding: 16px 14px;
    }
}

/* Keep the product detail tabs in one predictable row.  The Pearl theme
 * floats the titles and lets their widths be affected by inherited layout
 * rules, which can leave uneven gaps and broken borders on the PDP. */
body.catalog-product-view .tabs-1.product.info.detailed .product.data.items > .item.title,
body.catalog-product-view .tabs-v3.product.info.detailed .product.data.items > .item.title {
    float: none;
    display: inline-block;
    vertical-align: bottom;
    width: auto;
    margin: 0 -1px 0 0;
}
body.catalog-product-view .tabs-1.product.info.detailed .product.data.items > .item.title > .switch,
body.catalog-product-view .tabs-v3.product.info.detailed .product.data.items > .item.title > .switch {
    display: block;
    width: auto;
    min-width: 0;
    white-space: nowrap;
}
body.catalog-product-view .tabs-1.product.info.detailed .product.data.items > .item.content,
body.catalog-product-view .tabs-v3.product.info.detailed .product.data.items > .item.content {
    clear: both;
    float: none;
    width: 100%;
}
/* Accordion sections (including Reviews) must occupy the full content column. */
body.catalog-product-view .accordion-1.product.info.detailed .product.data.items > .item.title,
body.catalog-product-view .accordion-1.product.info.detailed .product.data.items > .item.title > .switch {
    display: block;
    float: none;
    width: 100%;
    margin-right: 0;
}
body.catalog-product-view .accordion-1.product.info.detailed .product.data.items > .item.content {
    clear: both;
    float: none;
    width: 100%;
}
@media (max-width: 767px) {
    body.catalog-product-view .product.info.detailed .product.data.items > .item.title {
        display: block;
        width: 100%;
        margin: 0;
    }
    body.catalog-product-view .product.info.detailed .product.data.items > .item.title > .switch {
        white-space: normal;
    }
}
/* Override only the theme's fixed state; retain its normal and footer positioning. */
body.catalog-product-view .product.media.ls-gallery-fixed {
    top: var(--ls-product-header-offset, 96px) !important;
}


@media (max-width: 767px) {
    body.catalog-product-view.page-product-bundle .bundle-options-container,
    body.catalog-product-view.page-product-bundle .bundle-options-container .block-bundle-summary,
    body.catalog-product-view.page-product-bundle .bundle-options-container .fieldset-bundle-options {
        height: auto !important;
        min-height: 0 !important;
        max-height: none !important;
        overflow: visible !important;
    }
    body.catalog-product-view.page-product-bundle .bundle-options-container {
        box-sizing: border-box;
        margin-bottom: 16px !important;
    }
    body.catalog-product-view.page-product-bundle .b2b-cta-pdp,
    body.catalog-product-view.page-product-bundle .b2b-cta-pdp-links {
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box;
    }
    body.catalog-product-view.page-product-bundle .b2b-cta-pdp a,
    body.catalog-product-view.page-product-bundle .b2b-cta-pdp button {
        max-width: 100%;
        box-sizing: border-box;
    }
}

/* The quantity field must not add vertical space inside the bundle card. */
body.catalog-product-view.page-product-bundle .bundle-options-container .field.qty {
    margin: 0 !important;
    padding: 0 !important;
}

/* Use the full available column for the bundle selector. Pearl's default
 * 57% width leaves the options panel unnecessarily narrow and can push the
 * purchase controls outside the visible card. */
body.catalog-product-view.page-product-bundle .bundle-options-container .bundle-options-wrapper,
body.catalog-product-view.page-product-bundle .bundle-options-container .product-options-wrapper,
body.catalog-product-view.page-product-bundle .bundle-options-container #product-options-wrapper {
    display: block !important;
    float: none !important;
    width: 100% !important;
    max-width: none !important;
    box-sizing: border-box;
}
body.catalog-product-view.page-product-bundle .bundle-options-container .fieldset-bundle-options {
    width: 100% !important;
    max-width: none !important;
    box-sizing: border-box;
}
@media (min-width: 768px) {
    body.catalog-product-view.page-product-bundle .bundle-options-container {
        width: 100% !important;
        max-width: none !important;
    }
}

@media (max-width: 767px) {
    body.catalog-product-view.page-product-bundle .product-info-main,
    body.catalog-product-view.page-product-bundle .bundle-options-container,
    body.catalog-product-view.page-product-bundle .b2b-cta-pdp,
    body.catalog-product-view.page-product-bundle .b2b-cta-pdp-links {
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
        overflow: visible !important;
    }
    body.catalog-product-view.page-product-bundle .b2b-cta-pdp {
        display: flex !important;
        flex-direction: column !important;
        gap: 10px;
        margin: 12px 0 18px !important;
        padding: 0 !important;
    }
    body.catalog-product-view.page-product-bundle .b2b-cta-pdp-links {
        display: flex !important;
        flex-direction: column !important;
        gap: 10px;
        margin: 0 !important;
        padding: 0 !important;
    }
    body.catalog-product-view.page-product-bundle .b2b-cta-pdp a,
    body.catalog-product-view.page-product-bundle .b2b-cta-pdp button {
        display: block !important;
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        margin: 0 !important;
        box-sizing: border-box !important;
        white-space: normal !important;
    }
}

/* Remove the theme's reserved vertical space between required fields and CTAs. */
body.catalog-product-view.page-product-bundle .bundle-options-container .content,
body.catalog-product-view.page-product-bundle .bundle-options-container .bundle-info,
body.catalog-product-view.page-product-bundle .bundle-options-container .bundle-options-wrapper,
body.catalog-product-view.page-product-bundle .bundle-options-container .product-options-wrapper,
body.catalog-product-view.page-product-bundle .bundle-options-container .product-options-bottom {
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
}
body.catalog-product-view.page-product-bundle .bundle-options-container .b2b-cta-pdp {
    margin-top: 12px !important;
}

/* Bundle scontato (prezzo speciale): prezzo pieno barrato + prezzo scontato */
.bundle-options-container .ls-old-price,
.ls-price-range .ls-old-price {
    text-decoration: line-through;
    color: #8a8a8a;
    font-weight: 400;
    margin-left: 6px;
    font-size: .85em;
}
body.catalog-product-view .price-box .price-as-configured.ls-discounted {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    margin: 0;
}
.price-as-configured.ls-discounted .ls-disc-top {
    display: flex;
    align-items: center;
    gap: 10px;
}
.price-as-configured.ls-discounted .ls-disc-badge {
    display: inline-block;
    padding: 3px 8px;
    border-radius: 4px;
    background: #8a171b;
    color: #fff;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: .02em;
}
body.catalog-product-view .price-as-configured.ls-discounted .old-price,
body.catalog-product-view .price-as-configured.ls-discounted .old-price .price {
    color: #8a8a8a !important;
    font-size: 16px !important;
    font-weight: 400 !important;
    line-height: 1.2 !important;
    text-decoration: line-through;
}
body.catalog-product-view .price-as-configured.ls-discounted .special-price .price {
    color: #8a171b !important;
    font-size: 32px !important;
    font-weight: 700 !important;
    line-height: 1.1 !important;
}
.price-as-configured.ls-discounted .ls-disc-saving {
    color: #2e7d32;
    font-size: 14px;
    line-height: 1.3;
}
.price-as-configured.ls-discounted .ls-disc-saving strong { font-weight: 700; }
/* Prezzo scontato e prezzo pieno dell'opzione restano insieme */
.bundle-options-container .price-notice:has(.ls-old-price) {
    display: inline-block;
    white-space: nowrap;
}
