/* ============================================================
    1. GLOBALER BEREICH (INDEX & BASIS)
   ============================================================ */
* { box-sizing: border-box; margin: 0; padding: 0; }

html { 
    font-size: 81%; 
}

body {
    /* Die Reihenfolge ist entscheidend: */
    /* 1. Windows sucht Segoe | 2. Mac sucht seine Systemschrift | 3. Fallback auf serifenlos */
    font-family: "Segoe UI", -apple-system, BlinkMacSystemFont, Roboto, Helvetica, Arial, sans-serif;
    
    /* Der Mac-Fix: Das nimmt die typische Apple-Fettschrift raus */
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    
    /* Windows-Feeling auf dem Mac: Buchstaben etwas enger zusammen */
    letter-spacing: -0.02px;
}

/* ============================================================
    2. ANMELDUNG (INDEX)
   ============================================================ */
.form-container-body { 
    background-color: #f9f9f9 !important;
}

.form-container {
    background: #ffffff !important;
    width: 100% !important;
    max-width: 850px !important;
    margin: 40px auto !important;
    padding: 40px !important;
    border: 1px solid #e0e0e0 !important;
    border-radius: 12px !important;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05) !important;
    text-align: left !important;
}

.anmeldung-header-row {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    width: 100% !important;
    margin-bottom: 25px !important;
}

.anmeldung-header-row h2 {
    color: #0b4d82;
    margin: 0 !important;
    font-size: 1.6rem !important; 
    line-height: 1.2;
    white-space: nowrap !important;
}

.form-container h3 {
    color: #0b4d82;
    font-size: 1.3rem !important;
    margin: 30px 0 10px 0;
}

.form-container p, .form-container label, .checkbox-item {
    font-size: 1.0rem !important; 
    line-height: 1.2;
    color: #444444 !important;
}

/* 1. Standard für Links im Container (z.B. Datenschutz im Text) */
.form-container a {
    color: #444444 !important; 
    text-decoration: underline !important;
}

/* 2. Sonderregel für den Zurück-Link oben (Blau erzwingen) */
.anmeldung-header-row a {
    color: #0b4d82 !important; 
    font-weight: bold !important;
    text-decoration: underline !important;
}

/* 3. Sonderregel für E-Mails im Impressum (Dunkelgrau/Normal) */
.impressum-content a {
    color: #333333 !important;
    font-weight: normal !important;
    text-decoration: none !important;
}

.logo-inline {
    max-width: 300px !important;
    height: auto !important;
    margin-left: 20px !important;
    flex-shrink: 0 !important;
}

.form-row { display: flex !important; gap: 20px !important; margin-bottom: 15px !important; }
.form-group { flex: 1 !important; display: flex !important; flex-direction: column !important; }

/* ============================================================
    3. DANKE-SEITE (MAIN-FRAME LOOK)
   ============================================================ */
.main-frame {
    width: 95%;
    max-width: 900px;
    margin: 40px auto 0 auto;
    background: white;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    border-radius: 8px;
    text-align: center;
    overflow: hidden;
}

.logo-area { line-height: 0; }
.logo-area img { 
    width: 100%; 
    max-width: 550px; 
    height: auto; 
    display: block; 
    margin: 0 auto; 
}

.content-padding { padding: 40px; }

.main-frame h1 { 
    font-size: 1.6rem; 
    color: #0b4d82; 
    margin-bottom: 15px; 
}

.text-large {
    font-size: 1.0rem;
    color: #555;
    margin-bottom: 35px;
}

/* ============================================================
    4. BUTTONS (WEISSE SCHRIFT FIX)
   ============================================================ */
.form-submit-btn, .button-main, a.button-main {
    display: inline-block !important;
    width: 100% !important;
    background-color: #0b4d82 !important;
    color: white !important;
    padding: 16px !important;
    border: none !important;
    border-radius: 6px !important;
    font-size: 1.2rem !important; 
    font-weight: bold !important;
    text-decoration: none !important;
    text-align: center;
    cursor: pointer !important;
}

/* ============================================================
    5. MOBIL EINSTELLUNGEN (HANDY)
   ============================================================ */
@media (max-width: 600px) {
    html { font-size: 90%; } 

    /* Anmeldung Mobil */
    .form-container {
        padding: 20px !important;
        margin: 10px !important;
        width: calc(100% - 20px) !important;
    }

    .form-row { flex-direction: column !important; gap: 10px !important; }

    /* Danke-Seite Mobil (Mehr Luft & Größeres Logo) */
    .main-frame { width: 92% !important; margin-top: 20px !important; }
    
    .logo-area img { 
        max-width: 95% !important; 
        width: 95% !important; 
        margin-top: 25px !important;
    }

    .content-padding { 
        padding: 50px 20px !important; 
    }
    
    .main-frame h1 { font-size: 1.4rem !important; }
    .text-large { font-size: 1.0rem !important; line-height: 1.6 !important; margin-bottom: 45px !important; }
}

/* ============================================================
    6. FOOTER
   ============================================================ */
footer { margin-top: auto; padding: 20px; width: 100%; }
footer p, footer a { font-size: 0.9rem; color: #666666 !important; text-decoration: none !important; }
footer a.footer-link-muted { color: #999999 !important; cursor: default; }
footer a:not(.footer-link-muted):hover { text-decoration: underline !important; }

/* Formular-Elemente */
.form-container input, .form-container select { width: 100%; padding: 10px; border: 1px solid #ccc; border-radius: 6px; }
.radio-item, .checkbox-item { display: flex; align-items: center; margin-bottom: 8px; text-align: left; }
.radio-item input, .checkbox-item input { margin-right: 12px; width: 20px; height: 20px; }