/* Passwortgeschützte Event-Seiten: rechte Spalte / Trenner komplett entfernen */
body.tb-protected-event #sidebar,
body.tb-protected-event .widget-area,
body.tb-protected-event .et_pb_widget_area,
body.tb-protected-event .et_pb_sidebar,
body.tb-protected-event .et_right_sidebar #sidebar {
    display: none !important;
}

body.tb-protected-event #main-content .container,
body.tb-protected-event #content-area,
body.tb-protected-event #left-area {
    width: 100% !important;
    max-width: 100% !important;
    margin-right: 0 !important;
    padding-right: 0 !important;
    float: none !important;
    border-right: none !important;
}

body.tb-protected-event #main-content .container:before,
body.tb-protected-event #main-content .container:after,
body.tb-protected-event #content-area:before,
body.tb-protected-event #content-area:after,
body.tb-protected-event #left-area:before,
body.tb-protected-event #left-area:after {
    display: none !important;
    content: none !important;
    border: 0 !important;
    background: none !important;
}

body.tb-protected-event .et_right_sidebar #left-area {
    width: 100% !important;
    padding-right: 0 !important;
}

body.tb-protected-event .et_pb_section,
body.tb-protected-event .et_pb_row,
body.tb-protected-event .et_pb_column,
body.tb-protected-event .et_pb_post {
    border-right: none !important;
}

body.tb-protected-event .et_pb_column.et-last-child,
body.tb-protected-event .et_pb_column:last-child {
    border-right: none !important;
}

/* Passwortgeschützte Event-Seiten: wieder angenehme Inhaltsbreite */
body.tb-protected-event #main-content .container {
    width: 80% !important;
    max-width: 1080px !important;
    margin: 0 auto !important;
    padding-bottom: 40px !important;
}

body.tb-protected-event #content-area,
body.tb-protected-event #left-area {
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
    padding-right: 0 !important;
    float: none !important;
}

@media (max-width: 980px) {
    body.tb-protected-event #main-content .container {
        width: 90% !important;
    }
}

/* Geschützte Event-Seiten – Hinweistext schön formatieren */
body.tb-protected-event .tb-event-protected-note {
    position: relative;
    background: #f8f1e4;
    border-left: 4px solid #c89a5b;
    padding: 22px 26px 22px 82px;
    margin: 24px 0 32px 0;
    border-radius: 8px;
    color: #4f5f73;
    max-width: 900px;
}

body.tb-protected-event .tb-event-protected-note p {
    margin: 0 0 14px 0;
    line-height: 1.7;
    font-size: 22px;
}

body.tb-protected-event .tb-event-protected-note p:last-child {
    margin-bottom: 0;
}

body.tb-protected-event .tb-event-protected-note::before {
    content: "🔒";
    position: absolute;
    top: 24px;
    left: 24px;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    line-height: 1;
    background: #fff;
    border: 1px solid #c89a5b;
    border-radius: 999px;
}

/* Divi-Passwortformular auf geschützten Event-Seiten */
body.tb-protected-event form.et_password_protected_form,
body.tb-protected-event .post-password-form {
    margin: 24px 0 40px !important;
    clear: both !important;
    overflow: visible !important;
    background: transparent !important;
}

body.tb-protected-event form.et_password_protected_form::after,
body.tb-protected-event .post-password-form::after {
    content: "" !important;
    display: block !important;
    clear: both !important;
}

body.tb-protected-event form.et_password_protected_form p,
body.tb-protected-event .post-password-form p {
    margin: 0 0 16px 0 !important;
    padding: 0 !important;
    background: transparent !important;
}

body.tb-protected-event form.et_password_protected_form p:last-child,
body.tb-protected-event .post-password-form p:last-child,
body.tb-protected-event .post-password-form p:last-of-type {
    display: flex !important;
    align-items: flex-end !important;
    gap: 16px !important;
    margin: 0 !important;
    padding: 0 !important;
    min-height: 0 !important;
    background: transparent !important;
    overflow: visible !important;
}

body.tb-protected-event form.et_password_protected_form label,
body.tb-protected-event .post-password-form label {
    display: block !important;
    flex: 1 1 auto !important;
    width: auto !important;
    margin: 0 !important;
}

body.tb-protected-event form.et_password_protected_form input[type="password"],
body.tb-protected-event .post-password-form input[type="password"] {
    float: none !important;
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    margin: 0 !important;
}

body.tb-protected-event form.et_password_protected_form .et_submit_button,
body.tb-protected-event form.et_password_protected_form input[type="submit"],
body.tb-protected-event .post-password-form input[type="submit"] {
    float: none !important;
    clear: none !important;
    position: static !important;
    right: auto !important;
    bottom: auto !important;
    display: inline-block !important;
    margin: 0 !important;
    flex: 0 0 auto !important;
    align-self: flex-end !important;
    z-index: 2 !important;
}

body.tb-protected-event #main-content,
body.tb-protected-event #content-area,
body.tb-protected-event #left-area,
body.tb-protected-event .et_pb_post,
body.tb-protected-event #main-footer {
    clear: both !important;
    overflow: visible !important;
}

@media (max-width: 767px) {
    body.tb-protected-event .tb-event-protected-note {
        padding: 18px 18px 18px 64px;
    }

    body.tb-protected-event .tb-event-protected-note p {
        font-size: 18px;
    }

    body.tb-protected-event .tb-event-protected-note::before {
        top: 18px;
        left: 16px;
        width: 34px;
        height: 34px;
        font-size: 18px;
    }

    body.tb-protected-event form.et_password_protected_form p:last-child,
    body.tb-protected-event .post-password-form p:last-child,
    body.tb-protected-event .post-password-form p:last-of-type {
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 12px !important;
    }

    body.tb-protected-event form.et_password_protected_form .et_submit_button,
    body.tb-protected-event form.et_password_protected_form input[type="submit"],
    body.tb-protected-event .post-password-form input[type="submit"] {
        align-self: flex-start !important;
    }
}
@media (max-width: 980px) {
    body.tb-protected-event form.et_password_protected_form p:last-child,
    body.tb-protected-event .post-password-form p:last-child,
    body.tb-protected-event .post-password-form p:last-of-type {
        display: block !important;
        margin: 0 !important;
        padding: 0 !important;
        min-height: 0 !important;
        background: transparent !important;
        overflow: visible !important;
    }

    body.tb-protected-event form.et_password_protected_form label,
    body.tb-protected-event .post-password-form label {
        display: block !important;
        width: 100% !important;
        margin: 0 0 12px 0 !important;
        flex: none !important;
    }

    body.tb-protected-event form.et_password_protected_form input[type="password"],
    body.tb-protected-event .post-password-form input[type="password"] {
        display: block !important;
        width: 100% !important;
        max-width: 100% !important;
        margin: 0 0 12px 0 !important;
        float: none !important;
    }

    body.tb-protected-event form.et_password_protected_form .et_submit_button,
    body.tb-protected-event form.et_password_protected_form input[type="submit"],
    body.tb-protected-event .post-password-form input[type="submit"] {
        display: inline-block !important;
        float: none !important;
        margin: 0 !important;
        align-self: auto !important;
    }
}

@media (max-width: 980px) {
    body.tb-protected-event #main-content .container {
        padding-bottom: 90px !important;
    }

    body.tb-protected-event form.et_password_protected_form,
    body.tb-protected-event .post-password-form {
        margin-bottom: 0 !important;
        padding-bottom: 36px !important;
    }

    body.tb-protected-event form.et_password_protected_form .et_submit_button,
    body.tb-protected-event form.et_password_protected_form input[type="submit"],
    body.tb-protected-event .post-password-form input[type="submit"] {
        margin-bottom: 24px !important;
    }
}