/* =========================================
   Kontaktformular
   ========================================= */

.elementor-contactform {
    display: block;
    max-width: 800px;
    margin: 0 auto;
}

.contactform-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}

.form-field {
    display: flex;
    flex-direction: column;
    flex: 1 1 45%;
}

.form-label {
    font-size: 0.85rem;
    color: #555;
    margin-bottom: 5px;
}

.required {
    color: #e53935;
    font-weight: bold;
}

.form-field input,
.form-field textarea {
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-size: 0.95rem;
}

.form-field input:focus,
.form-field textarea:focus {
    border-color: #0073aa;
    outline: none;
    box-shadow: 0 0 3px rgba(0,115,170,0.3);
}

.form-field textarea {
    min-height: 150px;
    resize: vertical;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9rem;
    color: #444;
}

.checkbox-label a {
    color: #0073aa;
    text-decoration: underline;
}

.btn-submit {
    margin-top: 20px;
    padding: 12px 25px;
    background: #0073aa;
    color: #fff;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 1rem;
    transition: background 0.2s ease;
}

.btn-submit:hover {
    background: #005c8a;
}

/* Formular: unter 768px eine Spalte */
@media (max-width: 768px) {
    .form-field {
        flex: 1 1 100%;
    }
}

/* =========================================
   Grid Accordion
   ========================================= */

/* Grid-Container – Desktop: 3 Spalten */
.ecf-grid-accordion {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
    align-items: flex-start;
}

/* Tablet: 2 Spalten */
@media (max-width: 1024px) {
    .ecf-grid-accordion {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* Handy: 1 Spalte – zur Sicherheit mit !important,
   falls Elementor-eigene CSS reingrätscht */
@media (max-width: 767px) {
    .ecf-grid-accordion {
        grid-template-columns: 1fr !important;
    }
}

/* Grid-Item */
.ecf-grid-item {
    background: #ffffff;
    border-radius: 10px;
    box-shadow: 0 4px 10px rgba(0,0,0,.06);
    overflow: hidden;
}

/* Wenn ein Item offen ist → volle Zeile (alle Spalten) */
.ecf-grid-item.is-open {
    grid-column: 1 / -1;
}

/* Innenlayout: Standard (geschlossen) = untereinander */
.ecf-grid-inner {
    display: block;
}

/* Spalten-Wrapper */
.ecf-grid-col-left,
.ecf-grid-col-right {
    width: 100%;
}

/* Trigger-Button allgemein */
.ecf-grid-trigger {
    border: none;
    background: none;
    padding: 0;
    cursor: pointer;
}

/* Bild-Trigger */
.ecf-grid-trigger-image {
    display: flex;
    align-items: center;
    justify-content: center;
}

.ecf-grid-img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
}

/* LINKE Spalte: Bild + Titel + Button (immer unter dem Bild) */
.ecf-grid-item-top {
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.ecf-grid-item-title {
    font-weight: 600;
    text-align: center;
}

.ecf-grid-trigger-button {
    align-self: center;
    padding: 8px 16px;
    border-radius: 6px;
    background: #0E1628;
    color: #ffffff;
    font-size: 14px;
    font-weight: 600;
}

/* Ausklapp-Bereich (rechte Spalte) */
.ecf-grid-content-wrapper {
    display: none;
    border-top: 1px solid #eee;
}

.ecf-grid-content-text {
    position: relative;
    font-size: 14px;
    line-height: 1.6;
    padding: 16px;
}

.ecf-grid-close {
    position: absolute;
    top: 8px;
    right: 8px;
    border: none;
    background: transparent;
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
}

.ecf-grid-content-text-inner {
    padding-right: 24px;
}

/* Wenn Item geöffnet ist → Inhalt anzeigen */
.ecf-grid-item.is-open .ecf-grid-content-wrapper {
    display: block;
}

/* 30 / 70 Layout NUR wenn offen:
   Links: Bild + Titel + Button
   Rechts: Inhalt */
.ecf-grid-item.is-open .ecf-grid-inner {
    display: grid;
    grid-template-columns: 30% 70%;
    gap: 16px;
    align-items: flex-start;
}

/* Handy: alles untereinander, aber Item bleibt volle Zeile */
@media (max-width: 767px) {
    .ecf-grid-item.is-open .ecf-grid-inner {
        grid-template-columns: 1fr;
    }
}