/* ========================================================
   MyWage Lead Form – iframe-friendly styles
   ======================================================== */

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 15px;
  line-height: 1.5;
  color: #1a1a2e;
  background: #ffffff;
  padding: 16px;
}

/* --- Container --- */
.form-container {
  max-width: 640px;
  margin: 0 auto;
}

.form-container h1 {
  font-size: 1.6rem;
  font-weight: 700;
  margin-bottom: 6px;
  color: #1a1a2e;
}

/* --- Header --- */
.form-header {
  margin-bottom: 20px;
}

.form-header .subtitle {
  font-size: 0.95rem;
  color: #6b7280;
  line-height: 1.4;
}

/* --- Perks section --- */
.perks {
  background: #f0f9ff;
  border: 1px solid #bae6fd;
  border-radius: 10px;
  padding: 16px 20px;
  margin-bottom: 8px;
}

.perks h2 {
  font-size: 1rem;
  font-weight: 600;
  color: #0c4a6e;
  margin-bottom: 10px;
}

.perks-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.perks-list li {
  font-size: 0.95rem;
  color: #1e3a5f;
  padding: 4px 0;
  display: flex;
  align-items: center;
}

.perk-check {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  background: #16a34a;
  color: #fff;
  border-radius: 50%;
  font-size: 0.75rem;
  font-weight: bold;
  margin-right: 10px;
  flex-shrink: 0;
}

/* --- Nudges (below submit button) --- */
.nudges {
  display: flex;
  justify-content: center;
  gap: 24px;
  margin-top: 14px;
  flex-wrap: wrap;
}

.nudge {
  font-size: 0.8rem;
  color: #6b7280;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.nudge-icon {
  color: #16a34a;
}

/* --- Mandatory info (inside Einwilligung fieldset, below checkbox) --- */
.mandatory-info {
  font-size: 0.75rem;
  color: #6b7280;
  line-height: 1.5;
  text-align: center;
  margin: 16px 0 0 0;
  padding: 14px 8px 2px;
  border-top: 1px solid #e5e7eb;
}

/* --- Flash messages --- */
.flash {
  padding: 10px 14px;
  border-radius: 6px;
  margin-bottom: 16px;
  font-size: 0.9rem;
}
.flash-error {
  background: #fef2f2;
  color: #b91c1c;
  border: 1px solid #fecaca;
}

/* --- Fieldset & legend --- */
fieldset {
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  padding: 16px 20px;
  margin-bottom: 20px;
}

legend {
  font-weight: 600;
  font-size: 0.95rem;
  color: #374151;
  padding: 0 6px;
}

/* --- Form rows (2-column grid) --- */
.form-row {
  display: flex;
  gap: 14px;
  margin-top: 12px;
}

.form-group {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.form-group-wide {
  flex: 2;
}
.form-group-narrow {
  flex: 1;
}

/* --- Labels --- */
label {
  font-size: 0.85rem;
  font-weight: 500;
  color: #4b5563;
  margin-bottom: 4px;
}

/* --- Inputs & selects --- */
input[type="text"],
input[type="email"],
input[type="tel"],
input[type="date"],
input[type="number"],
select {
  width: 100%;
  padding: 9px 12px;
  border: 1px solid #d1d5db;
  border-radius: 6px;
  font-size: 0.95rem;
  color: #1a1a2e;
  background: #fff;
  transition: border-color 0.15s;
}

input:focus, select:focus {
  outline: none;
  border-color: #2563eb;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

/* --- Terms checkbox --- */
.terms-wrapper {
  margin-top: 10px;
}

.checkbox-label {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 0.85rem;
  color: #4b5563;
  cursor: pointer;
}

.checkbox-label input[type="checkbox"] {
  margin-top: 3px;
  flex-shrink: 0;
}

.checkbox-label a {
  color: #2563eb;
  text-decoration: underline;
}

/* --- Submit button --- */
.btn-submit {
  display: block;
  width: 100%;
  padding: 12px;
  font-size: 1rem;
  font-weight: 600;
  color: #fff;
  background: #2563eb;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.15s;
}

.btn-submit:hover {
  background: #1d4ed8;
}

.btn-submit:active {
  background: #1e40af;
}

.btn-submit:disabled {
  background: #9ca3af;
  cursor: not-allowed;
}

/* --- Success / Error pages --- */
.message-page {
  text-align: center;
  padding-top: 60px;
}

.success-icon {
  font-size: 3rem;
  color: #16a34a;
  background: #f0fdf4;
  width: 72px;
  height: 72px;
  line-height: 72px;
  border-radius: 50%;
  margin: 0 auto 16px;
}

.error-icon {
  font-size: 3rem;
  color: #dc2626;
  background: #fef2f2;
  width: 72px;
  height: 72px;
  line-height: 72px;
  border-radius: 50%;
  margin: 0 auto 16px;
}

.message-page p {
  color: #6b7280;
  max-width: 400px;
  margin: 10px auto 0;
}

.btn-fallback {
  display: inline-block;
  margin-top: 24px;
  padding: 12px 24px;
  background: #2563eb;
  color: #fff;
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 600;
  border-radius: 8px;
  transition: background 0.15s;
}

.btn-fallback:hover {
  background: #1d4ed8;
}

/* --- Responsive (stack on mobile) --- */
@media (max-width: 520px) {
  .form-row {
    flex-direction: column;
    gap: 0;
  }
  .form-group {
    margin-top: 10px;
  }
  body {
    padding: 10px;
  }
}
