.mes-afm-card { max-width: 920px; margin: 0 auto 2rem; }
.mes-afm-card .mes-form-section { padding: 1.4rem 1.5rem; border-bottom: 1px solid #e3e8e5; }
.mes-afm-card .mes-form-section h2 { margin: 0 0 .8rem; }
.mes-afm-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; margin: 1rem 0; }
.mes-afm-wide { grid-column: 1 / -1; }
.mes-afm-field { display:flex; flex-direction:column; gap:.35rem; margin:.65rem 0; min-width: 0; }
.mes-afm-field label { font-weight: 650; }
.mes-afm-field input, .mes-afm-field textarea, .mes-afm-field select { width:100%; box-sizing:border-box; min-height:2.65rem; padding:.55rem .7rem; border:1px solid #b9c7c2; border-radius:.45rem; background:#fff; color:#192c25; font:inherit; }
.mes-afm-field input:focus-visible, .mes-afm-field textarea:focus-visible, .mes-afm-field select:focus-visible { outline:2px solid #39795e; outline-offset:2px; }
.mes-afm-field small, .mes-afm-small { font-size:.954rem; opacity:.78; }
.mes-afm-card .mes-afm-details { border-bottom:1px solid #e3e8e5; padding:1rem 1.5rem; }
.mes-afm-details summary { font-size:1.2508rem; font-weight:700; cursor:pointer; padding:.5rem 0; }
.mes-afm-details[open] summary { margin-bottom:.6rem; }
.mes-afm-checkbox { display:flex; gap:.7rem; align-items:flex-start; margin:1rem 0; line-height:1.5; }
.mes-afm-checkbox input { margin:.32rem 0 0; flex:none; width:1.1rem; height:1.1rem; }
.mes-afm-checkbox a { display:inline; }
.mes-afm-sepa-text { border:1px solid #d9e3dd; background:#f5f8f6; padding:1rem; border-radius:.55rem; line-height:1.6; }
.mes-afm-signature { border:2px dashed #9eada5; border-radius:.6rem; overflow:hidden; background:#fff; margin:1rem 0 .6rem; }
.mes-afm-signature canvas { width:100%; height:auto; display:block; cursor:crosshair; touch-action:none; }
.mes-afm-challenge { max-width:260px; }
.mes-afm-submit { width:100%; margin:1rem 0; font-size:1.113rem; }
.mes-afm-honeypot { position:absolute!important; left:-10000px!important; top:-10000px!important; height:1px!important; width:1px!important; opacity:0!important; pointer-events:none!important; }
[data-afm-signature-message] { color:#a72f40; font-weight:700; }
/* Alle Zahlungsarten nutzen dieselbe MES-CI und lassen sich per Tastatur bedienen. */
.mes-afm-payment-choices { border:0; padding:0; margin:1rem 0; min-width:0; }
.mes-afm-payment-choices legend { font-weight:700; margin-bottom:.6rem; }
.mes-afm-payment-choice { display:flex; align-items:flex-start; gap:.8rem; cursor:pointer; border:1px solid #bccdc3; border-radius:.65rem; padding:.95rem; margin-bottom:.65rem; }
.mes-afm-payment-choice:has(input:checked) { background:#f0f8f3; border-color:#40886a; }
.mes-afm-payment-choice input { margin:.25rem 0 0; width:1.2rem; height:1.2rem; flex-shrink:0; }
.mes-afm-payment-choice span { display:grid; gap:.2rem; }
.mes-afm-payment-choice small { color:#4e6156; }
.mes-afm-self-payer { padding:1rem; border:1px solid #d9e3dd; border-radius:.55rem; background:#f5f8f6; }
.mes-afm-self-payer p { margin:.5rem 0; }
.mes-afm-input-error { color:#a72f40; font-weight:650; }
.mes-afm-card .mes-afm-field [aria-invalid="true"] { border-color:#b72e4b; box-shadow:0 0 0 2px #fce2e7; }
/* Versteckte Bereiche müssen auch bei globalen CSS-Regeln unsichtbar bleiben. */
.mes-afm-card [hidden] { display:none !important; }
@media (max-width: 650px) { .mes-afm-grid { grid-template-columns:1fr; } .mes-afm-card .mes-form-section { padding:1rem; } .mes-afm-card .mes-afm-details { padding:1rem; } }

/* Rückweg nach erfolgreicher Antragstellung; nur auf der Bestätigungsansicht. */
.mes-afm-success-actions { margin-top: .1rem; }
.mes-afm-success-actions .mes-button { text-decoration: none; }

/* AFM: kompakter Sticky-Kopf mit festem Rückweg zur Mitgliedschaftsseite. */
.mes-afm-page .mes-public-exhibitor-brand {
    position: sticky;
    top: 0;
    z-index: 40;
    box-shadow: 0 4px 15px rgba(25, 35, 25, .07);
}
.mes-afm-page .mes-afm-brand-name {
    flex: 1 1 auto;
    min-width: 0;
}
.mes-afm-page .mes-afm-top-return {
    flex: 0 0 auto;
    margin-left: auto;
    gap: .35rem;
    white-space: nowrap;
    text-decoration: none;
}
.mes-afm-page .mes-afm-top-return:hover { text-decoration: none; }
.mes-afm-page .mes-afm-top-return:focus-visible {
    outline: 2px solid #39795e;
    outline-offset: 2px;
}
@media (max-width: 540px) {
    .mes-afm-page .mes-public-exhibitor-brand { flex-wrap: wrap; }
    .mes-afm-page .mes-afm-top-return { margin-left: auto; }
}

/* AFM UX: interne Namensfelder kompakt, ohne Feld-/Speicherlogik zu ändern. */
.mes-afm-identity-row {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
    min-width: 0;
}
.mes-afm-identity-row > .mes-afm-field { min-width: 0; }
.mes-afm-copy-contact { width: auto; max-width: 100%; white-space: normal; text-align: left; }
.mes-afm-public-contact-intro { margin: .35rem 0 .8rem; }
.mes-afm-copy-hint { margin: .45rem 0 .85rem; font-size: .9116rem; color: #54685a; }
@media (max-width: 900px) and (min-width: 561px) {
    .mes-afm-identity-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .mes-afm-identity-row > .mes-afm-salutation { grid-column: 1 / -1; }
}
@media (max-width: 560px) {
    .mes-afm-identity-row { grid-template-columns: 1fr; }
}
