/* Nascondi titolo pagina su anteprima legacy */
body.page-id-2073 .entry-hero,
body.page-id-2073 .entry-hero-container,
body.ibb-home-legacy .entry-hero,
body.ibb-home-legacy .entry-hero-container,
body.ibb-home-preview .entry-hero,
body.ibb-home-preview .entry-hero-container {
    display: none !important;
}

body.page-id-2073 .content-wrap,
body.ibb-home-legacy .content-wrap,
body.ibb-home-preview .content-wrap {
    padding-top: 0 !important;
}

/* ===== Layout home a due colonne ===== */
.ibb-home-main {
    align-items: stretch !important;
    gap: 20px !important;
    margin-bottom: 0 !important;
}

.ibb-home-left,
.ibb-home-right {
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.ibb-home-hero {
    border-radius: 14px !important;
    overflow: hidden;
    margin: 0 !important;
}

.ibb-home-hero .wp-block-cover__background {
    opacity: 0 !important;
}

.ibb-home-hero .wp-block-cover__image-background {
    object-fit: cover;
    object-position: center center;
}

.ibb-home-hero .wp-block-cover__inner-container {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 220px;
    padding: 16px;
}

.ibb-home-hero .ibb-hero-overlay-text {
    margin: 0 !important;
    color: #ffffff !important;
    text-align: center !important;
    font-size: clamp(1.55rem, 2.8vw, 2.1rem) !important;
    line-height: 1.25;
    text-shadow: 0 2px 14px rgba(0, 0, 0, 0.7), 0 0 36px rgba(0, 0, 0, 0.4);
    letter-spacing: 0.02em;
}

.ibb-home-left .ibb-zoom-meeting {
    margin-top: 14px !important;
}

.ibb-home-left .ibb-contatti-box {
    margin-top: 14px !important;
}

.ibb-home-right {
    display: flex;
    flex-direction: column;
    min-height: 0;
    align-self: stretch !important;
}

.ibb-home-right .ibb-home-reflection {
    flex: 1 1 auto;
    display: flex !important;
    flex-direction: column;
    width: 100%;
    height: 100%;
    min-height: 100%;
    margin-top: 0 !important;
    box-sizing: border-box;
}

.ibb-home-right .ibb-home-reflection > .wp-block-group__inner-container {
    display: flex !important;
    flex-direction: column;
    flex: 1 1 auto;
    width: 100%;
    height: 100%;
    min-height: 0;
}

.ibb-home-right .ibb-home-reflection .ibb-riflessione-wrapper {
    flex: 1 1 auto;
    width: 100%;
    height: 100%;
    min-height: 0;
}

.ibb-home-reflection .ibb-riflessione-body {
    flex: 1 1 auto;
    min-height: 0;
    max-height: none;
    overflow-y: auto;
}

.ibb-btn-zoom .wp-block-button__link {
    background: linear-gradient(180deg, #3ca14d 0%, #2f8a3e 100%) !important;
    color: #fff !important;
    border-radius: 10px !important;
    font-weight: 700;
    border: 1px solid #2f7d3a !important;
}

@media (max-width: 767px) {
    .ibb-home-main {
        flex-wrap: wrap !important;
    }

    .ibb-home-main > .wp-block-column {
        flex-basis: 100% !important;
    }

    .ibb-home-hero .ibb-hero-overlay-text {
        font-size: 1.45rem !important;
    }

    .ibb-home-right .ibb-home-reflection,
    .ibb-home-right .ibb-home-reflection .ibb-riflessione-wrapper {
        height: auto !important;
        min-height: 320px !important;
        max-height: none !important;
    }
}

/* Titolo sito più compatto */
.site-branding .site-title {
    font-size: clamp(1.25rem, 2.2vw, 2rem) !important;
    line-height: 1.15 !important;
    letter-spacing: 0.04em !important;
}

.ibb-home-actions {
    align-items: stretch !important;
    gap: 16px !important;
}

.ibb-home-actions > .wp-block-column {
    display: flex;
    flex-direction: column;
}

.ibb-home-actions .ibb-zoom-meeting,
.ibb-home-actions .ibb-contatti-box {
    height: 100%;
    margin-top: 0 !important;
    box-sizing: border-box;
}

.ibb-contatti-box {
    padding: 14px 16px !important;
    border: 1px solid #d5dde7 !important;
    border-radius: 14px !important;
    background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%) !important;
    box-shadow: 0 8px 20px rgba(26, 58, 92, 0.06) !important;
}

.ibb-contatti-box h4 {
    margin: 0 0 8px !important;
    color: #1a3a5c !important;
    font-size: 1rem !important;
}

.ibb-contatti-box p {
    margin: 0 0 12px !important;
    color: #5b6775 !important;
    line-height: 1.45 !important;
}

.ibb-contatti-box .wp-block-buttons {
    gap: 8px;
}

.ibb-btn-whatsapp .wp-block-button__link {
    background: #25d366 !important;
    color: #fff !important;
    border-radius: 10px !important;
    font-weight: 700;
    border: none !important;
}

.ibb-btn-phone .wp-block-button__link {
    border-radius: 10px !important;
    color: #1a3a5c !important;
    border-color: #c5d0dc !important;
    font-weight: 600;
}

.ibb-home-reflection {
    margin-top: 0;
}

/* Colonne home allineate in altezza */
.ibb-home-main,
.home .ibb-home-main,
.page-id-9 .ibb-home-main,
.page-id-70 .ibb-home-main,
.page-id-71 .ibb-home-main {
    align-items: stretch !important;
}

.ibb-home-main > .wp-block-column,
.page-id-9 .ibb-home-main > .wp-block-column,
.page-id-70 .ibb-home-main > .wp-block-column,
.page-id-71 .ibb-home-main > .wp-block-column {
    display: flex;
    flex-direction: column;
}

/* Riflessione giornaliera */
.ibb-riflessione-wrapper {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-sizing: border-box;
    width: 100%;
    height: 100%;
    min-height: 0;
    padding: 16px 18px 14px;
    border-radius: 16px;
    border: 1px solid #e3e8ef;
    background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
    box-shadow: 0 10px 28px rgba(26, 58, 92, 0.08);
}

.ibb-riflessione-header {
    flex: 0 0 auto;
    margin-bottom: 10px;
}

.ibb-riflessione-topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 10px;
}

.ibb-riflessione-form {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
    margin: 0;
    padding: 0;
    background: transparent;
    border: none;
}

.ibb-riflessione-form label {
    margin: 0;
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    color: #5b6775;
    text-transform: uppercase;
}

.ibb-riflessione-form select {
    padding: 4px 8px;
    border: 1px solid #d5dde7;
    border-radius: 8px;
    background: #fff;
    font-size: 0.85rem;
    color: #1f2a37;
}

.ibb-riflessione-form button {
    padding: 5px 12px;
    border: none;
    border-radius: 8px;
    background: #1a3a5c;
    color: #fff;
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
}

.ibb-riflessione-actions {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
    margin: 0;
}

.ibb-copy-wa,
.ibb-edit-rif {
    font-size: 0.78rem;
    padding: 6px 11px;
    border-radius: 999px;
    cursor: pointer;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: none;
    font-weight: 600;
    white-space: nowrap;
}

.ibb-copy-wa {
    background: #25d366;
    color: #fff;
    box-shadow: 0 4px 12px rgba(37, 211, 102, 0.25);
}

.ibb-copy-wa.is-copied {
    background: #128c7e;
}

.ibb-edit-rif {
    background: #eef2f7;
    color: #1a3a5c;
    border: 1px solid #d5dde7;
}

.ibb-riflessione-date {
    margin: 0;
    padding: 0 0 8px;
    border-bottom: 1px solid #e8edf3;
    color: #6b7a8a;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.ibb-riflessione-body {
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
    padding-right: 4px;
    line-height: 1.52;
    color: #334155;
    font-size: 0.98rem;
    text-align: justify;
}

.ibb-riflessione-body--compact {
    font-size: 0.84em !important;
    line-height: 1.42 !important;
}

.ibb-riflessione-body--compact .ibb-riflessione-title {
    font-size: 1.1em !important;
    margin-bottom: 8px !important;
}

.ibb-riflessione-title {
    margin: 0 0 10px;
    font-size: 1.28rem;
    line-height: 1.25;
    color: #1a3a5c;
    text-align: left;
    font-weight: 700;
}

.ibb-riflessione-text p {
    margin: 0 0 0.75em;
}

.ibb-riflessione-text p.ibb-riflessione-ref {
    margin: 0.15em 0 0.85em;
    font-size: 0.88em;
    font-weight: 700;
    font-style: italic;
    color: #5b6775;
    letter-spacing: 0.02em;
    text-align: left;
}

.ibb-riflessione-text p:last-child {
    margin-bottom: 0;
}

.ibb-riflessione-body::-webkit-scrollbar {
    width: 6px;
}

.ibb-riflessione-body::-webkit-scrollbar-thumb {
    background: #c9d3df;
    border-radius: 999px;
}

.ibb-riflessione-body::-webkit-scrollbar-track {
    background: transparent;
}

/* Riquadro ZOOM elegante */
.ibb-zoom-meeting {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box;
    margin-top: 0 !important;
    padding: 14px 16px !important;
    border: 1px solid #d9e6d2 !important;
    border-radius: 14px !important;
    background: linear-gradient(180deg, #f7faf5 0%, #f1f6ee 100%) !important;
    box-shadow: 0 8px 20px rgba(46, 91, 52, 0.07) !important;
}

.ibb-zoom-meeting .wp-block-group {
    width: 100%;
    max-width: 100%;
    flex-wrap: wrap !important;
}

.ibb-zoom-meeting p {
    width: 100%;
    max-width: 100% !important;
    margin: 0 auto 12px !important;
    font-size: clamp(0.88rem, 2.2vw, 1rem) !important;
    line-height: 1.45 !important;
    word-break: break-word;
    overflow-wrap: anywhere;
    color: #2f3f4f !important;
}

.ibb-zoom-meeting .wp-block-buttons {
    width: 100%;
    justify-content: center;
}

.ibb-zoom-meeting .wp-block-button {
    width: 100%;
}

.ibb-zoom-meeting .wp-block-button__link {
    width: 100%;
    max-width: 100%;
    white-space: normal !important;
    text-align: center;
    line-height: 1.3 !important;
    padding: 0.8rem 1rem !important;
    border-radius: 10px !important;
    border: 1px solid #2f7d3a !important;
    background: linear-gradient(180deg, #3ca14d 0%, #2f8a3e 100%) !important;
    color: #fff !important;
    box-shadow: 0 6px 16px rgba(47, 138, 62, 0.22);
    font-weight: 700;
}

/* Banner confronto versioni home */
.ibb-compare-banner {
    background: #fff8e6;
    border-bottom: 1px solid #e8c96a;
    padding: 10px 16px;
    text-align: center;
    font-size: 0.9rem;
    line-height: 1.45;
    color: #3d3428;
    position: relative;
    z-index: 100;
}

.ibb-compare-banner p {
    margin: 0;
}

.ibb-compare-banner a {
    color: #1a3a5c;
    font-weight: 700;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.ibb-compare-banner a:hover {
    color: #0f2438;
}
