*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html, body { overflow-x: hidden; }

/* ── Utilities ──────────────────────────────────────────────────────────── */
.mt-0 { margin-top: 0; }
.text-center { text-align: center; }
.radio-gold { margin-top: 0.15rem; accent-color: #ffd700; flex-shrink: 0; }
.chk-gold { margin-top: 0.15rem; accent-color: #ffd700; flex-shrink: 0; width: 1rem; height: 1rem; }

body {
  font-family: 'Segoe UI', system-ui, sans-serif;
  background: #f4f6f9;
  color: #1a1a2e;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

header {
  background: #000000;
  color: #ffd700;
  padding: 1.2rem 2rem;
  display: flex;
  align-items: center;
  gap: 1rem;
}

header .logo { height: 40px; width: auto; object-fit: contain; }

header h1 {
  font-size: 1.4rem;
  letter-spacing: 0.02em;
}

header .subtitle {
  font-size: 0.85rem;
  color: #ccc;
  margin-top: 0.15rem;
}

main {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding: 2.5rem 1rem;
}

.card {
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 4px 24px rgba(0,0,0,0.08);
  padding: 2.5rem;
  width: 100%;
  max-width: 640px;
}

.card h2 {
  font-size: 1.5rem;
  margin-bottom: 0.4rem;
  color: #000;
}

.card .lead {
  color: #555;
  margin-bottom: 1.8rem;
  font-size: 0.95rem;
  line-height: 1.6;
}

label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: #444;
  margin-bottom: 0.3rem;
  margin-top: 1rem;
}

.required { color: #c0392b; margin-left: 2px; }

input[type="text"],
input[type="email"],
input[type="tel"],
select {
  width: 100%;
  padding: 0.72rem 0.9rem;
  border: 1.5px solid #d1d5db;
  border-radius: 7px;
  font-size: 1rem;
  transition: border-color 0.2s;
  background: #fafafa;
  font-family: inherit;
}
select {
  appearance: none; -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%236b7280' stroke-width='1.5' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 0.85rem center;
  padding-right: 2.5rem; cursor: pointer;
}
input:focus { outline: none; border-color: #ffd700; background: #fff; }
select:focus { outline: none; border-color: #ffd700; background-color: #fff; }

.row-2 {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 0.8rem;
}

.btn {
  display: inline-block;
  margin-top: 1.8rem;
  padding: 0.85rem 2rem;
  background: #ffd700;
  color: #000;
  font-weight: 700;
  font-size: 1rem;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.2s, transform 0.1s;
  text-decoration: none;
}

.btn:hover { background: #f0c800; }
.btn:active { transform: scale(0.98); }

.flash-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.45);
  z-index: 9999;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}
.flash-backdrop.visible { display: flex; }
.flash-modal {
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 8px 40px rgba(0,0,0,0.22);
  padding: 2rem 2rem 1.5rem;
  max-width: 480px;
  width: 100%;
  text-align: center;
}
.flash-modal .fm-icon { font-size: 2.2rem; margin-bottom: 0.75rem; }
.flash-modal .fm-title { font-size: 1.05rem; font-weight: 700; color: #1a1a2e; margin-bottom: 0.6rem; }
.flash-modal .fm-body { font-size: 0.92rem; color: #555; line-height: 1.6; margin-bottom: 1.5rem; }
.flash-modal .fm-btn { background: #ffd700; color: #000; font-weight: 700; font-size: 0.95rem; border: none; border-radius: 8px; padding: 0.7rem 2rem; cursor: pointer; }
.flash-modal .fm-btn:hover { background: #f0c800; }

.info-box {
  background: #fffde7;
  border: 1px solid #ffe082;
  border-radius: 8px;
  padding: 1rem 1.2rem;
  margin-top: 1.5rem;
  font-size: 0.88rem;
  line-height: 1.6;
}

.info-box a { color: #000; font-weight: 600; }

.phone-row {
  display: grid;
  grid-template-columns: 130px 1fr;
  gap: 0.6rem;
}

.field-error {
  display: block;
  color: #c0392b;
  font-size: 0.82rem;
  margin-top: 0.3rem;
  min-height: 0;
}

footer {
  text-align: center;
  padding: 1.2rem;
  font-size: 0.8rem;
  color: #999;
}

/* ── Formular (Mitglieder-Blöcke, Ladeoverlay) ─────────────────────────── */
.bd-masked { font-family: monospace; letter-spacing: 0.05em; }
.proof-input { display: block; width: 100%; font-size: 0.88rem; padding: 0.45rem 0; cursor: pointer; }
.member-block .proof-input { font-size: 0.82rem; }
.sub-proof-wrap { margin-top: 0.75rem; }
.sub-proof-wrap label { margin-top: 0 !important; }
#loadingOverlay { display: none; position: fixed; inset: 0; background: rgba(255,255,255,0.92); z-index: 9999; flex-direction: column; align-items: center; justify-content: center; gap: 1.25rem; }
.spinner { width: 52px; height: 52px; border: 4px solid #e5e7eb; border-top-color: #ffd700; border-radius: 50%; animation: spin 0.75s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.mt-radio-label {
  display: flex; align-items: flex-start; gap: 0.6rem; cursor: pointer;
  padding: 0.7rem 0.9rem; border: 1.5px solid #d1d5db; border-radius: 8px;
  background: #fafafa; transition: border-color 0.15s;
}
.mt-radio-label:has(input:checked) { border-color: #ffd700; background: #fffbea; }
.member-block { border: 1.5px solid #e5e7eb; border-radius: 10px; padding: 1.1rem 1.2rem; background: #f9fafb; position: relative; }
.member-block-title { font-weight: 700; font-size: 0.9rem; color: #333; margin-bottom: 0.9rem; padding-right: 2rem; }
.member-block .remove-btn { position: absolute; top: 0.8rem; right: 0.9rem; background: none; border: none; color: #9ca3af; cursor: pointer; font-size: 1.2rem; line-height: 1; padding: 0.15rem 0.35rem; border-radius: 4px; }
.member-block .remove-btn:hover { color: #dc2626; background: #fef2f2; }
.member-block label { display: block; font-size: 0.82rem; font-weight: 600; color: #555; margin-top: 0.75rem; margin-bottom: 0.25rem; }
.member-block label.first { margin-top: 0; }
.member-block input[type="text"], .member-block input[type="email"], .member-block select { width: 100%; padding: 0.6rem 0.8rem; border: 1.5px solid #d1d5db; border-radius: 7px; font-size: 0.9rem; background: #fff; font-family: inherit; }
.member-block select { appearance: none; -webkit-appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%236b7280' stroke-width='1.5' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 0.75rem center; padding-right: 2.2rem; cursor: pointer; }
.member-block input:focus, .member-block select:focus { outline: none; border-color: #ffd700; background: #fff; }
.member-block .row-2 { display: grid; grid-template-columns: 1fr 2fr; gap: 0.6rem; }
.member-block .row-half { display: grid; grid-template-columns: 1fr 1fr; gap: 0.6rem; }
.member-block .phone-row { display: grid; grid-template-columns: 110px 1fr; gap: 0.5rem; }
.member-block .same-addr-toggle { display: flex; align-items: center; gap: 0.5rem; margin-top: 0.75rem; padding: 0.6rem 0.75rem; background: #f0f9ff; border: 1px solid #bae6fd; border-radius: 7px; cursor: pointer; }
.member-block .same-addr-toggle input { accent-color: #0284c7; width: 1rem; height: 1rem; flex-shrink: 0; }
.member-block .same-addr-toggle span { font-size: 0.88rem; font-weight: 600; color: #0369a1; }

@media (max-width: 480px) {
  header { padding: 1rem; }
  header h1 { font-size: 1.1rem; }
  main { padding: 1rem 0.75rem; }
  .card { padding: 1.5rem 1.2rem; }
  .row-2 { grid-template-columns: 1fr; }
  .phone-row { grid-template-columns: 1fr; }
  .member-block .row-2, .member-block .row-half { grid-template-columns: 1fr; }
  .member-block .phone-row { grid-template-columns: 1fr; }
}
