/* Customer content only. No viewport-height or scroll-driven sizing is used here. */
.customer-page-content {
    padding-top: 32px;
    padding-bottom: 56px;
    color: #344e60;
}

.customer-page-content #ContentPlaceHolderMain_PanelContenuti,
.customer-page-content #ContentPlaceHolderMain_PanelImportato,
.customer-page-content #recapitiPanel {
    min-width: 0;
}

.customer-page-content h1.yi-section-title {
    margin-top: 0;
    margin-bottom: 22px;
    color: #173c56;
    font-size: 25px;
    font-weight: 650;
    line-height: 1.45;
    text-transform: none;
}

.customer-page-content .yi-section-title > .yi-section-icon {
    background: #edf4f8;
    color: #225d84;
}

.customer-page-content .customer-contacts,
.customer-page-content .customer-description-section,
.customer-page-content .customer-gallery-section,
.customer-page-content .customer-video-section {
    margin-bottom: 32px;
    padding: 24px;
    border: 1px solid #e1e9ef;
    border-radius: 20px;
    background: #fff;
    box-shadow: 0 5px 22px rgba(25, 55, 77, .035);
}

.customer-page-content .customer-description-section .customer-page-description {
    color: #435b6b;
    font-size: 16px;
    line-height: 1.85;
}

.customer-page-content .customer-page-description > :first-child {
    margin-top: 0;
}

.customer-page-content .customer-page-description > :last-child {
    margin-bottom: 0;
}

.customer-page-content #ContentPlaceHolderMain_PanelContenuti .customer-page-description p {
    margin-bottom: 18px;
    padding: 0;
    font-size: inherit;
    line-height: 1.85;
}

.customer-page-content .customer-page-description img,
.customer-page-content .customer-page-description video {
    max-width: 100%;
    height: auto;
}

.customer-page-content .customer-page-description a {
    color: #003c70;
    text-decoration: underline;
    text-underline-offset: 3px;
}

/* The thumbnail geometry depends on width alone, including during mobile scrolling. */
.customer-page-content .Collage {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    width: 100%;
    height: auto !important;
    margin: 0;
    padding: 0;
}

.customer-page-content .Collage::before,
.customer-page-content .Collage::after {
    display: none;
}

.customer-page-content .Collage > .Image_Wrapper {
    position: relative;
    display: block !important;
    float: none;
    width: auto !important;
    height: auto !important;
    min-width: 0;
    margin: 0 !important;
    padding: 0 !important;
    border: 0;
    aspect-ratio: 4 / 3;
    opacity: 1 !important;
    transform: none !important;
    animation: none !important;
}

.customer-page-content .Collage .Image_Wrapper > a[data-lightbox] {
    display: block;
    width: 100%;
    height: 100%;
    overflow: hidden;
    border: 1px solid #e0e8ee;
    border-radius: 14px;
    background: #edf3f6;
}

.customer-page-content .Collage .Image_Wrapper img {
    display: block;
    width: 100% !important;
    height: 100% !important;
    max-width: 100%;
    margin: 0;
    border-radius: 0 !important;
    object-fit: cover;
    object-position: center;
    transform: none !important;
    transition: none;
}

.customer-page-content .Collage .btn-delete-gallery {
    position: absolute;
    z-index: 2;
    top: 8px;
    right: 8px;
    left: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    margin: 0;
    padding: 0;
    border-radius: 10px;
}

.customer-page-content .customer-gallery-section > .widget {
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
    box-shadow: none;
}

.customer-page-content .customer-gallery-section > .widget > .row {
    margin: 0;
}

.customer-page-content .customer-gallery-section > .widget > .row > .col-xs-12 {
    padding: 0;
}

.customer-page-content .customer-video-section .video-wrapper-customer {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 16px;
    margin: 0;
}

.customer-page-content .customer-video-section .video-wrapper-customer > [class*="col-"] {
    float: none;
    width: 100%;
    min-width: 0;
    padding: 0;
}

.customer-page-content .customer-video-section .video-wrapper-customer iframe {
    width: 100%;
    height: auto !important;
    min-height: 0;
    aspect-ratio: 16 / 9;
    border-radius: 14px;
}

.customer-page-content #ContentPlaceHolderMain_PanelMap,
.customer-page-content #ContentPlaceHolderMain_PanelVirtualTour {
    margin-bottom: 16px;
    overflow: hidden;
    border: 1px solid #dce7ee;
    border-radius: 18px;
    background: #edf4f8;
    box-shadow: 0 5px 22px rgba(25, 55, 77, .035);
}

.customer-page-content #ContentPlaceHolderMain_PanelMap iframe,
.customer-page-content #ContentPlaceHolderMain_PanelVirtualTour iframe {
    display: block;
    width: 100% !important;
    height: auto !important;
    min-height: 260px;
    aspect-ratio: 4 / 3;
    border: 0;
}

.customer-page-content #ContentPlaceHolderMain_PanelMap > .row,
.customer-page-content #ContentPlaceHolderMain_PanelVirtualTour > .row {
    margin: 0;
}

.customer-page-content #ContentPlaceHolderMain_PanelMap > .row > .col-xs-12,
.customer-page-content #ContentPlaceHolderMain_PanelVirtualTour > .row > .col-xs-12 {
    padding: 0;
}

.customer-page-content #ContentPlaceHolderMain_CalcolaPercorso {
    box-sizing: border-box;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-width: 0;
    max-width: 100%;
    height: auto;
    min-height: 48px;
    padding: 12px 16px;
    border: 1px solid #cbdde9;
    border-radius: 12px;
    background: #edf4f8;
    color: #003c70;
    font-size: 14px;
    line-height: 1.6;
    white-space: normal;
    text-transform: none !important;
    transition: background-color .18s ease, border-color .18s ease, box-shadow .18s ease;
}

.customer-page-content #ContentPlaceHolderMain_CalcolaPercorso > .fa {
    flex: 0 0 auto;
}

.customer-page-content #ContentPlaceHolderMain_CalcolaPercorso > .customer-directions-label {
    min-width: 0;
    max-width: 100%;
    white-space: normal;
}

/* Match the portal's light buttons while preserving the resting appearance. */
@media (hover: hover) {
    .customer-page-content #ContentPlaceHolderMain_CalcolaPercorso:hover {
        border-color: #9fbdd3;
        background: #dfedf7;
        color: #003c70;
        box-shadow: 0 3px 8px rgba(0, 60, 112, .12);
    }
}

.customer-page-content #ContentPlaceHolderMain_CalcolaPercorso:focus-visible,
.customer-page-content #ContentPlaceHolderMain_CalcolaPercorso:active {
    border-color: #9fbdd3;
    background: #dfedf7;
    color: #003c70;
    box-shadow: 0 3px 8px rgba(0, 60, 112, .12);
}

@media (prefers-reduced-motion: reduce) {
    .customer-page-content #ContentPlaceHolderMain_CalcolaPercorso {
        transition: none;
    }
}

.customer-page-content #ContentPlaceHolderMain_ServiziWidget {
    margin-bottom: 24px;
    padding: 18px;
    border: 1px solid #e1e9ef;
    border-radius: 18px;
    background: #fff;
}

.customer-page-content #ContentPlaceHolderMain_ServiziWidget .customer-services-list > .label {
    flex: 1 1 auto;
    display: inline-flex;
    align-items: center;
    min-height: 36px;
    padding: 8px 10px;
    border-radius: 10px;
}

.customer-page-content #ContentPlaceHolderMain_ServiziWidget .customer-services-legend {
    gap: 10px 14px;
    margin-top: 20px;
    padding-top: 16px;
}

.customer-page-content .customer-related-links,
.customer-page-content [id$="_WidgetGuide"] {
    margin-bottom: 20px;
    padding: 18px;
    border: 1px solid #e1e9ef;
    border-radius: 18px;
    background: #fff;
}

.customer-page-content .customer-related-links p,
.customer-page-content [id$="_GuidaClienteBox"] {
    margin: 0;
    padding: 0 !important;
    font-size: 14px;
    line-height: 1.7;
}

.customer-page-content .customer-related-links p > a,
.customer-page-content [id$="_GuidaClienteBox"] > a {
    display: inline-block;
    max-width: 100%;
    padding: 6px 0;
    color: #315e7d;
    text-decoration: underline;
    text-decoration-color: #c2d5e2;
    text-underline-offset: 3px;
}

.customer-page-content .widget.offerta {
    border-color: #dce7ee;
    border-radius: 18px;
    box-shadow: 0 5px 22px rgba(25, 55, 77, .055);
    transform: none;
}

.customer-page-content .widget.offerta h1 {
    color: #173c56;
    line-height: 1.5;
}

.customer-page-content .widget.offerta a.btn {
    border-radius: 12px;
    background: #003c70;
}

.customer-page-content .widget.offerta a.btn:hover,
.customer-page-content .widget.offerta a.btn:focus {
    background: #002d54;
}

.customer-page-content a:focus-visible,
.customer-page-content button:focus-visible {
    outline: 3px solid #003c70;
    outline-offset: 3px;
}

@media (min-width: 768px) {
    .customer-page-content .customer-video-section .video-wrapper-customer.two-video {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 767px) {
    .customer-page-content {
        padding-top: 22px;
        padding-bottom: 36px;
    }

    .customer-page-content .customer-contacts,
    .customer-page-content .customer-description-section,
    .customer-page-content .customer-gallery-section,
    .customer-page-content .customer-video-section {
        margin-bottom: 24px;
        padding: 18px;
        border-radius: 16px;
    }

    .customer-page-content h1.yi-section-title {
        font-size: 23px;
        margin-bottom: 18px;
    }

    .customer-page-content .Collage {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 10px;
    }
}

@media (max-width: 374px) {
    .customer-page-content .customer-contacts,
    .customer-page-content .customer-description-section,
    .customer-page-content .customer-gallery-section,
    .customer-page-content .customer-video-section {
        padding-inline: 12px;
    }

    .customer-page-content h1.yi-section-title {
        gap: 8px;
        font-size: 20px;
    }

    .customer-page-content .yi-section-title > .yi-section-icon {
        flex-basis: 32px;
        width: 32px;
        height: 32px;
        inline-size: 32px;
        block-size: 32px;
        font-size: 21px;
    }

    .customer-page-content .Collage {
        gap: 8px;
    }
}

@media (max-width: 319px) {
    .customer-page-content .customer-description-section {
        padding-inline: 10px;
    }

    .customer-page-content .customer-description-section .customer-page-description {
        font-size: 14px;
    }
}
