/*
Theme Name: mb-elementor
...
*/

/* MBC Widerruf shared card appearance */
#widerruf-form-card,
.mbc-widerruf-form-card,
#widerruf-preview-card,
.widerruf-preview-card {
    background: #ffffff;
    border: 1px solid #dcdcdc;
    border-radius: 8px;
    color: #5b5b5b;
    font-size: 15px;
    line-height: 1.6;
}

/* MBC Widerruf: improve Elementor form spacing */
#widerruf-form-card .elementor-field-group {
    margin-bottom: 16px;
}

/* Left form card spacing */
#widerruf-form-card,
.mbc-widerruf-form-card {
    padding: 28px;
}

/* Right preview outer card: border/height only */
#widerruf-preview-card,
.widerruf-preview-card {
    padding: 0;
}

/* Right preview inner spacing */
.widerruf-preview-inner {
    padding: 28px;
}

/* Preview card should visually match the left form height on desktop */
#widerruf-preview-card,
.widerruf-preview-card {
    min-height: 0;
}

/* Sticky preview on desktop */
@media (min-width: 1025px) {
    #widerruf-preview-card,
    .widerruf-preview-card {
        position: sticky;
        top: 30px;
    }
}

/* Headings */
#widerruf-form-card h2,
#widerruf-form-card h3,
#widerruf-form-card .elementor-heading-title,
.mbc-widerruf-section-title,
#widerruf-preview-card h3,
.widerruf-preview-card h3 {
    color: #026633;
    font-weight: 700;
    font-size: 28px;
    line-height: 1.25;
    margin-bottom: 26px;
}

/* Preview subheadings */
#widerruf-preview-card h4,
.widerruf-preview-card h4 {
    color: #026633;
    font-weight: 700;
    margin-top: 26px;
    margin-bottom: 10px;
}

/* Dividers */
#widerruf-form-card hr,
.mbc-widerruf-divider,
#widerruf-preview-card hr,
.widerruf-preview-card hr {
    border: none;
    border-top: 1px solid #e5e5e5;
    margin: 24px 0;
}

/* Form labels */
#widerruf-form-card label {
    display: block;
    margin-bottom: 6px;
    color: #5b5b5b;
    font-weight: 500;
    font-size: 13px;
}

/* Form fields */
#widerruf-form-card input,
#widerruf-form-card select,
#widerruf-form-card textarea,
.mbc-widerruf-form-card input,
.mbc-widerruf-form-card select,
.mbc-widerruf-form-card textarea {
    border: 1px solid #9aa5b1;
    padding: 9px 12px;
    font-size: 14px;
    border-radius: 3px;
    min-height: 42px;
    background-color: #ffffff;
}

/* Focus state */
#widerruf-form-card input:focus,
#widerruf-form-card select:focus,
#widerruf-form-card textarea:focus,
.mbc-widerruf-form-card input:focus,
.mbc-widerruf-form-card select:focus,
.mbc-widerruf-form-card textarea:focus {
    border-color: #026633;
    box-shadow: 0 0 0 2px rgba(2, 102, 51, 0.12);
    outline: none;
}

#widerruf-form-card .mbc-widerruf-divider {
    margin: 28px 0 22px 0;
}

#widerruf-form-card .mbc-widerruf-section-title {
    font-size: 28px;
    line-height: 1.25;
    margin: 0 0 24px 0;
}

#widerruf-form-card .elementor-button {
    margin-top: 6px;
    min-height: 44px;
}

#widerruf-form-card .elementor-button-text {
    font-size: 14px;
}

/* MBC shared primary button style */
.mbc-primary-button .elementor-button,
#widerruf-form-card .elementor-button {
    background-color: #026633;
    color: #ffffff;
    border-radius: 4px;
    font-weight: 700;
    padding: 14px 24px;
    min-height: 44px;
    border: none;
    text-decoration: none;
    transition:
        background-color 0.2s ease,
        color 0.2s ease;
}

.mbc-primary-button .elementor-button:hover,
#widerruf-form-card .elementor-button:hover {
    background-color: #fbbf07;
    color: #026633;
}

/* Preview mirrored values */
#widerruf-preview-card span[id^='preview-'],
.widerruf-preview-card span[id^='preview-'] {
    color: #333333;
}

/* Bottom note in preview */
.widerruf-preview-note {
    margin-top: 28px;
    padding: 16px;
    border-radius: 6px;
    background: #dae6db;
    border: 1px solid #d8eadf;
}

/* MBC Widerruf: equal-height classic Elementor section */
@media (min-width: 768px) {
    #widerruf-section > .elementor-container {
        display: flex !important;
        align-items: stretch !important;
    }

    #widerruf-section > .elementor-container > .elementor-column {
        display: flex !important;
    }

    #widerruf-section > .elementor-container > .elementor-column > .elementor-widget-wrap {
        display: flex !important;
        flex-direction: column !important;
        width: 100%;
    }

    #widerruf-form-card {
        height: auto;
        min-height: 100%;
        box-sizing: border-box;
    }

    #widerruf-section .elementor-widget-html,
    #widerruf-section .elementor-widget-html > .elementor-widget-container {
        display: flex !important;
        flex: 1 1 auto !important;
        width: 100%;
    }

    #widerruf-preview-card {
        flex: 1 1 auto !important;
        width: 100%;
        height: 100%;
        box-sizing: border-box;
    }
}

@media (max-width: 767px) {
    #widerruf-section > .elementor-container {
        display: block !important;
    }

    #widerruf-form-card,
    .mbc-widerruf-form-card {
        padding: 20px;
    }

    #widerruf-preview-card,
    .widerruf-preview-card {
        padding: 0;
        min-height: auto;
        position: static;
        height: auto;
    }

    .widerruf-preview-inner {
        padding: 20px;
    }
}
