/* Grundlegendes Reset & Schriftart */
* {
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    -webkit-text-size-adjust: 100%; /* Verhindert automatisches Vergrößern auf iOS */
}

html, body {
    margin: 0;
    padding: 0;
    width: 100%;
    background-color: transparent;
}

body {
    display: flex !important;
    justify-content: center !important;
    align-items: flex-start !important;
    padding: 15px 10px !important;
}

/* Formular-Karte (Desktop / PC) */
.form-card {
    background: #ffffff;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    width: 100% !important;
    max-width: 750px !important;
    margin: 0 auto !important;
}

h2 {
    color: #333333;
    margin-top: 0;
    margin-bottom: 8px;
    font-size: 24px;
}

.subtitle {
    color: #666666;
    font-size: 14px;
    margin-bottom: 25px;
    line-height: 1.5;
}

/* Formulargruppen & Input-Felder */
.form-group {
    margin-bottom: 20px;
    text-align: left;
}

label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #444444;
    font-size: 14px;
}

/* Container für Kontaktaufnahme-Optionen */
.contact-options {
    display: flex;
    flex-wrap: wrap;
    gap: 15px 20px;
    margin-top: 8px;
}

/* 16px verhindert den automatischen Zoom auf Mobilgeräten */
input[type="text"],
input[type="tel"],
input[type="email"],
select,
textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #cccccc;
    border-radius: 6px;
    font-size: 16px !important;
    color: #333333;
    background-color: #fdfdfd;
    transition: border-color 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

/* Custom Pfeil für das Pulldown-Menü */
select {
    cursor: pointer;
    background-image: url('data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22%23333333%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.4-12.8z%22%2F%3E%3C%2Fsvg%3E');
    background-repeat: no-repeat;
    background-position: right 15px top 50%;
    background-size: 12px auto;
    padding-right: 35px;
    text-overflow: ellipsis;
    white-space: nowrap;
    overflow: hidden;
}

input:focus,
select:focus,
textarea:focus {
    border-color: #4a7c59;
    outline: none;
    box-shadow: 0 0 5px rgba(74, 124, 89, 0.3);
    background-color: #ffffff;
}

/* Datenschutz & Checkbox Styling */
.checkbox-group {
    margin-top: 25px;
    margin-bottom: 25px;
}

.checkbox-label {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-weight: normal;
    font-size: 13px;
    color: #555555;
    line-height: 1.4;
    cursor: pointer;
}

.checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    margin-top: 2px;
    cursor: pointer;
    flex-shrink: 0;
}

.checkbox-label a {
    color: #4a7c59;
    text-decoration: underline;
}

.checkbox-label a:hover {
    color: #3b6346;
}

/* Button Styling */
.submit-btn {
    width: 100%;
    background-color: #4a7c59;
    color: #ffffff;
    border: none;
    padding: 14px 20px;
    font-size: 16px;
    font-weight: bold;
    border-radius: 6px;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.submit-btn:hover {
    background-color: #3b6346;
}

.text-center {
    text-align: center;
}

/* Styling für die Zusammenfassung nach dem Versand (versand.php) */
.summary-box {
    background-color: #f9f9f9;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 20px;
    margin: 20px 0;
    text-align: left;
}

.summary-box h3 {
    margin-top: 0;
    margin-bottom: 15px;
    font-size: 16px;
    color: #333333;
    border-bottom: 2px solid #4a7c59;
    padding-bottom: 8px;
}

.summary-table {
    width: 100%;
    border-collapse: collapse;
}

.summary-table th,
.summary-table td {
    padding: 8px 5px;
    vertical-align: top;
    font-size: 14px;
}

.summary-table th {
    width: 35%;
    color: #555555;
    font-weight: 600;
}

.summary-table td {
    color: #222222;
}

/* Mobil-Optimierung (Smartphone bis 768px) */
@media screen and (max-width: 768px) {
    body {
        padding: 5px !important;
    }

    .form-card {
        max-width: 100% !important;
        padding: 15px 10px !important;
        box-shadow: none !important;
        border-radius: 0 !important;
    }

    .contact-options {
        flex-direction: column;
        gap: 10px;
    }

    input[type="text"],
    input[type="tel"],
    input[type="email"],
    select,
    textarea {
        padding: 10px 12px !important;
        font-size: 16px !important; /* Exakte 16px verhindern automatisches Heranzoomen */
    }

    .summary-table th,
    .summary-table td {
        display: block;
        width: 100%;
    }
    
    .summary-table th {
        padding-bottom: 2px;
        color: #777777;
    }
    
    .summary-table td {
        padding-bottom: 12px;
    }
}