/* Fix per le immagini full-width */
#project-content {
    max-width: 100%;
    overflow-x: hidden;
    padding: 0;
    margin: 0;
}

.section-image {
    width: 100vw;
    margin: 0;
    padding: 0;
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
}

.section-image img {
    width: 100%;
    height: auto;
    display: block;
    margin: 0;
    padding: 0;
}

/* Fix iOS Safari: 100vw include la scrollbar, causando overflow orizzontale */
@supports (-webkit-touch-callout: none) {
    .section-image {
        width: 100%;
        left: 0;
        right: 0;
        margin-left: 0;
        margin-right: 0;
    }
}

/* Mobile: margini ridotti tra le immagini */
@media (max-width: 768px) {
    .section-image {
        margin-top: 10px !important;
        margin-bottom: 0 !important;
    }

    .section-image:first-child {
        margin-top: 0 !important;
    }

    /* Video: stessi margini delle immagini */
    .section-video {
        margin: 10px 0 0 0 !important;
    }

    .section-video:first-child {
        margin-top: 0 !important;
    }

    .vimeo-container {
        margin: 0 !important;
        border-radius: 0 !important;
    }
}

/* Fix per contenuti About generati da Quill editor */
.column-text p {
    margin: 0;
    padding: 0;
}

.column-text p:empty,
.column-text p br:only-child {
    display: none;
}

/* ==================== ABOUT PAGE LAYOUT ==================== */

/* About hero first section: same as home page */
.about-hero-first {
    padding: var(--spacing-lg) var(--pad);
    padding-bottom: 0;
}

/* About hero first paragraph: no bottom margin (image follows directly) */
.about-hero-first .hero-paragraph {
    margin-bottom: 0;
}

/* About hero sections after image */
.about-hero-rest {
    padding: 0 var(--pad) var(--spacing-lg);
}

/* About image: flush with text on both sides */
.about-page .section-image {
    margin-top: 40px;
    margin-bottom: 40px;
}

/* Hero paragraph spacing (for rest section) */
.about-hero-rest .hero-paragraph {
    margin-bottom: 40px;
}

.about-hero-rest .hero-paragraph.last {
    margin-bottom: 0;
}

/* Remove margins from Quill-generated p tags inside hero-text */
.hero-text p,
.hero-paragraph p {
    margin: 0;
    padding: 0;
}

/* Mobile adjustments for About - match Home page (24px = --spacing-md on mobile) */
@media (max-width: 768px) {
    .about-hero-first {
        padding: var(--spacing-md) var(--pad-m);
        padding-bottom: 0;
    }

    .about-hero-rest {
        padding: 0 var(--pad-m) var(--spacing-md);
    }

    .about-page .section-image {
        margin-top: 20px !important;
        margin-bottom: 20px !important;
    }

    .about-hero-rest .hero-paragraph {
        margin-bottom: 20px;
    }
}