/* --- yForm --- */
.yform form { display: block; margin: 0 0 20px 0; padding: 0; }

/* Gruppe mit Label + Eingabefeld */
.yform .form-group { margin-bottom: 20px; }

/* Label-Styling für bessere Barrierefreiheit */
.yform label { display: block; margin-bottom: 6px; font-weight: 500; color: #333; }

/* Hervorhebung von Pflichtfeldern im Label */
.yform label .required { color: #a94442; margin-left: 3px; }

.yform .form-control { box-sizing: border-box; display: block; width: 100%; height: auto; margin: 0 0 20px 0; padding: 8px 10px; font-family: inherit; font-size: 0.8rem; color: #001f40; background-color: #fff; border: solid 1px #dfe6e7; border-radius: 5px; box-shadow: none; outline: none; transition: border-color 0.2s, box-shadow 0.2s; }
.yform .form-control:hover { border-color: #a8aeb5; }
.yform .form-control:focus, .yform .form-control:focus-visible { border-color: #37434f; outline: none; box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.25); }

.yform textarea.form-control { height: 136px; }

.yform .form-check-group { clear: both; margin: 0 0 20px 0; }
.yform .form-check-group .control-label { clear: both; display: block; margin: 0 0 10px 0; }

.yform .radio { position: relative; padding-left: 30px; margin-bottom: 10px; }
.yform .radio label input { position: absolute; left: 0; top: 5px; width: 20px; height: 20px; }
.yform .radio input:focus, .yform .radio input:focus-visible { outline: 2px solid #0078d7; outline-offset: 2px; }

.yform .checkbox { clear: both; margin: 0 0 20px 0; position: relative; }
.yform .checkbox label { padding-left: 0; position: relative; }
.yform .checkbox label input { position: absolute; left: 0; top: 5px; width: 20px; height: 20px; }
.yform .checkbox input:focus, .yform .checkbox input:focus-visible { outline: 2px solid #0078d7; outline-offset: 2px; }

/* Hilfetext-Stil */
.yform .help-text { display: block; font-size: 0.85em; color: #666; margin-top: -15px; margin-bottom: 15px; }

/* Verbesserter Button für Barrierefreiheit */
.yform .btn-primary { clear: both; display: block; width: 140px; height: auto; margin: 0 0 10px 0; padding: 10px; border: none; border-radius: 5px; text-align: center; font-weight: bold; background-color: #58698d; color: #FFF; cursor: pointer; transition: background-color 0.2s, transform 0.1s; }
.yform .btn-primary:hover { background-color: #001f40; color: #FFF; }
.yform .btn-primary:focus, .yform .btn-primary:focus-visible { outline: none; box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.5); background-color: #001f40; }
.yform .btn-primary:active { transform: translateY(1px); }

/* Besser sichtbare Pflichtfeld-Markierung */
.yform .pflichtfelder { font-size: 0.9em; margin-top: 15px; margin-bottom: 20px; color: #555; }

/* Fehlerhinweisbox, überm Formular */
.yform div.alert { padding: 15px 20px 5px 20px; margin-bottom: 20px; border-radius: 4px; }
.yform div.alert span { margin-right: 15px; }
.yform div.alert-danger { border: 2px solid #a94442; background-color: #FBF6F6; color: #a94442; }
.yform .alert ul { list-style-type: none; margin: 0; padding: 0; }
.yform .alert li { list-style-type: none; margin: 0 0 10px 0; padding: 0; color: #a94442; }

/* Grundlegende Fehlermarkierung für alle Formularelemente */
.yform .has-error { margin-bottom: 20px; }
.yform .has-error .control-label { color: #a94442; font-weight: 500; }
.yform .has-error label { color: #a94442; }
.yform .has-error .form-control { border-color: #a94442; box-shadow: 0 0 0 2px rgba(169, 68, 66, 0.25); }

/* Fehlermarkierung für reguläre Eingabefelder */
.yform .has-error .form-control { border-color: #a94442; box-shadow: 0 0 0 1px #EAD0D0; background-color: #FBF6F6; }
/* Spezielle Fehlermarkierung für die Checkbox */
.yform .formcheckbox.has-error label { color: #a94442; }
.yform .formcheckbox.has-error .form-helper { border-color: #a94442; box-shadow: 0 0 0 1px #EAD0D0; }

/* Optionale visuelle Verstärkung für die Checkbox */
.yform .formcheckbox.has-error { padding: 10px; border-radius: 4px; background-color: #FBF6F6; }

/* Fokus-Zustand für fehlerhafte Checkboxen verstärken */
.yform .formcheckbox.has-error input[type="checkbox"]:focus + .form-helper,
.yform .formcheckbox.has-error input[type="checkbox"]:focus-visible + .form-helper { border-color: #a94442; box-shadow: 0 0 0 3px rgba(169, 68, 66, 0.3); }

/* Verbesserte Fokusdarstellung für Tastaturbedienung */
.yform a:focus, .yform a:focus-visible { outline: 2px solid #0078d7; outline-offset: 2px; }

/* High-contrast mode Unterstützung */
@media (forced-colors: active) {
.yform .form-control:focus { outline: 2px solid CanvasText; }
.yform .btn-primary { border: 1px solid CanvasText; }
}


/* Honeypot gegen SPAM */
.yform .honeypot_box div.form-group { display: block; width: 1px; height: 1px; margin: 0; padding: 0; overflow: hidden; opacity: 0.1; }
/* Wird sichtbar, wenn das Feld den Fokus bekommt oder .has-error hat*/
.yform .honeypot_box div.form-group:focus-within,
.yform .honeypot_box div.form-group.has-error { display: block; width: auto; height: auto; margin: 0 0 20px 0; padding: 15px 20px 5px 20px; overflow: visible; opacity: 1; background-color: #f8f8f8; border: 1px solid #ddd; border-radius: 4px; box-shadow: 0 0 5px rgba(0,0,0,0.1); }
.yform .honeypot_box div.form-group.has-error { border-color: #a94442; }


/* Datenschutz Hinweis */
.yform .privacy_box { clear: both; position: relative; margin-bottom: 25px; padding: 5px 0; }
.yform .privacy_box label { display: block; position: relative; cursor: pointer; padding-left: 40px; line-height: 1.5; }
.yform .privacy_box input[type="checkbox"] { position: absolute; opacity: 0; }
.yform .privacy_box .form-helper { position: absolute; left: 0; top: 0; width: 24px; height: 24px; background-color: #fff; border: 2px solid #dfe6e7; border-radius: 4px; transition: all 0.2s; }
.yform .privacy_box input[type="checkbox"]:checked + .form-helper::before { content: ''; position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 12px; height: 12px; background-color: #58698d; border-radius: 2px; }
.yform .privacy_box input[type="checkbox"]:focus + .form-helper, .yform .privacy_box input[type="checkbox"]:focus-visible + .form-helper { border-color: #37434f; box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.25); }
.yform .privacy_box label:hover .form-helper { border-color: #a8aeb5; }
.yform .privacy_box a { color: #58698d; text-decoration: underline; font-weight: 500; }
.yform .privacy_box a:hover { color: #001f40; }
.yform .privacy_box a:focus, .yform .privacy_box a:focus-visible { outline: 2px solid #0078d7; outline-offset: 2px; }
/* Fehlerzustand für die Checkbox */
.yform .privacy_box.has-error label { color: #a94442; }
.yform .privacy_box.has-error .form-helper { border-color: #a94442; box-shadow: 0 0 0 1px rgba(169, 68, 66, 0.25); }
.yform .privacy_box.has-error { background-color: rgba(169, 68, 66, 0.05); padding: 10px; border-radius: 4px; }

/* hier ohne .yForm !!! */
.hinweis_email_erfolgreich_versendet { display: block; margin: 20px 0; padding: 20px; background-color: #5bb585; color: #fff; font-size: 1.5rem; text-align: center; }

/* Formular mit 2 Spalten */
.yform .form_left, .yform .form_right { float: left; width: 48%; min-width: 250px; margin: 0 0 20px 0; }
.yform .form_right { float: right; }
.yform .form_clear { width: 100%; clear: both; }

@media all and (max-width:768px) {
.yform .form_left, .yform .form_right { float: none; width: 100%; }
.yform .btn-primary { width: 100%; }
}
