/* =========================================================
   DTKV Vereinsmeldung
   Mehrstufiger Formularprozess
   ========================================================= */


/* ---------------------------------------------------------
   1. Grundstruktur
   --------------------------------------------------------- */

.dtkv-vm {
  width: 100%;
  scroll-margin-top: 120px;
}

.dtkv-vm__form {
  display: grid;
  gap: 24px;
}

.dtkv-vm__panels {
  min-width: 0;
}


/* ---------------------------------------------------------
   2. Schritt-Navigation
   --------------------------------------------------------- */

.dtkv-vm__steps {
  display: flex;
  align-items: flex-start;
  justify-content: center;

  max-width: 760px;
  margin: 0 auto 4px;
  padding: 0 8px;
}

.dtkv-vm__step {
  display: flex;
  flex: 0 0 auto;
  flex-direction: column;
  align-items: center;
  gap: 8px;

  min-width: 92px;
  padding: 0;

  color: #8b8b8b;
  background: transparent !important;
  border: 0;
  box-shadow: none !important;

  font: inherit;
  cursor: pointer;
}

.dtkv-vm__step:hover,
.dtkv-vm__step:focus,
.dtkv-vm__step:focus-visible {
  background: transparent !important;
  border: 0;
  box-shadow: none !important;
  outline: none;
}

.dtkv-vm__step:disabled {
  cursor: default;
  opacity: .8;
}


/* Sechseck */

.dtkv-vm__step-shape {
  display: inline-flex;
  align-items: center;
  justify-content: center;

  width: 42px;
  height: 42px;

  color: #777;
  background: var(--dtkv-primary-soft, #f3efe8);

  font-size: 15px;
  font-weight: 700;

  clip-path: polygon(
    25% 6.7%,
    75% 6.7%,
    100% 50%,
    75% 93.3%,
    25% 93.3%,
    0% 50%
  );

  transition:
    color 0.2s ease,
    background-color 0.2s ease,
    transform 0.2s ease;
}


/* Nummer und Häkchen */

.dtkv-vm__step-check {
  display: none;
  font-size: 18px;
}

.dtkv-vm__step-label {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.25;
  text-align: center;

  transition:
    color 0.2s ease,
    transform 0.2s ease;
}


/* Verbindungslinien */

.dtkv-vm__step-line {
  flex: 1 1 80px;

  height: 2px;
  margin: 20px 4px 0;

  background: var(--dtkv-line, #e8e4de);
}


/* Hover nur auf Icon und Text */

.dtkv-vm__step:not(:disabled):hover .dtkv-vm__step-shape,
.dtkv-vm__step:not(:disabled):focus-visible .dtkv-vm__step-shape {
  color: #fff;
  background: var(--dtkv-primary, #a9936f);
  transform: translateY(-2px);
}

.dtkv-vm__step:not(:disabled):hover .dtkv-vm__step-label,
.dtkv-vm__step:not(:disabled):focus-visible .dtkv-vm__step-label {
  color: var(--dtkv-primary, #a9936f);
}

/* Noch nicht erreichbare Schritte:
   Text bleibt auch bei Hover unverändert grau */
.dtkv-vm__step:disabled .dtkv-vm__step-label,
.dtkv-vm__step:disabled:hover .dtkv-vm__step-label,
.dtkv-vm__step:disabled:focus .dtkv-vm__step-label,
.dtkv-vm__step:disabled:focus-visible .dtkv-vm__step-label {
  color: #8b8b8b;
  transform: none;
}

/* Auch das Sechseck reagiert bei deaktivierten Schritten nicht */
.dtkv-vm__step:disabled .dtkv-vm__step-shape,
.dtkv-vm__step:disabled:hover .dtkv-vm__step-shape,
.dtkv-vm__step:disabled:focus .dtkv-vm__step-shape,
.dtkv-vm__step:disabled:focus-visible .dtkv-vm__step-shape {
  color: #777;
  background: var(--dtkv-primary-soft, #f3efe8);
  transform: none;
}

/* Beim Hover etwas deutlicher, aber weiterhin nicht aktiv */
.dtkv-vm__step:disabled:hover,
.dtkv-vm__step:disabled:focus,
.dtkv-vm__step:disabled:focus-visible {
  color: #8b8b8b;
  background: transparent !important;
  opacity: 1;
  box-shadow: none !important;
  outline: none;
}

/* Icon und Text gemeinsam weich einblenden */
.dtkv-vm__step:disabled .dtkv-vm__step-shape,
.dtkv-vm__step:disabled .dtkv-vm__step-label {
  opacity: 1;
  transform: none;
}

/* Kein Farbwechsel und keine Bewegung am Icon */
.dtkv-vm__step:disabled:hover .dtkv-vm__step-shape,
.dtkv-vm__step:disabled:focus-visible .dtkv-vm__step-shape {
  color: #777;
  background: var(--dtkv-primary-soft, #f3efe8);
  transform: none;
}


/* Aktiver Schritt */

.dtkv-vm__step.is-active {
  color: var(--dtkv-text, #1f1f1f);
  background: transparent !important;
}

.dtkv-vm__step.is-active .dtkv-vm__step-shape {
  color: #fff;
  background: var(--dtkv-text, #1f1f1f);
}

.dtkv-vm__step.is-active:hover .dtkv-vm__step-shape,
.dtkv-vm__step.is-active:focus-visible .dtkv-vm__step-shape {
  color: #fff;
  background: var(--dtkv-text, #1f1f1f);
}

.dtkv-vm__step.is-active:hover .dtkv-vm__step-label,
.dtkv-vm__step.is-active:focus-visible .dtkv-vm__step-label {
  color: var(--dtkv-text, #1f1f1f);
}


/* Abgeschlossener Schritt */

.dtkv-vm__step.is-complete {
  color: var(--dtkv-secondary, #4a4a4a);
  background: transparent !important;
}

.dtkv-vm__step.is-complete .dtkv-vm__step-shape {
  color: #fff;
  background: var(--dtkv-primary, #a9936f);
}

.dtkv-vm__step.is-complete .dtkv-vm__step-number {
  display: none;
}

.dtkv-vm__step.is-complete .dtkv-vm__step-check {
  display: inline;
}

.dtkv-vm__step.is-complete:hover .dtkv-vm__step-shape,
.dtkv-vm__step.is-complete:focus-visible .dtkv-vm__step-shape {
  color: #fff;
  background: var(--dtkv-accent, #8a7554);
}

.dtkv-vm__step.is-complete:hover .dtkv-vm__step-label,
.dtkv-vm__step.is-complete:focus-visible .dtkv-vm__step-label {
  color: var(--dtkv-accent, #8a7554);
}


/* ---------------------------------------------------------
   3. Formularabschnitte
   --------------------------------------------------------- */

.dtkv-vm__section {
  min-width: 0;
  margin: 0;
  padding: 36px 40px;

  background: var(--dtkv-surface, #fff);
  border: 1px solid var(--dtkv-line, #e8e4de);
  border-radius: 12px;

  box-shadow: 0 4px 14px rgba(31, 31, 31, 0.03);
}

.dtkv-vm__form.is-enhanced
  .dtkv-vm__section:not(.is-active) {
  display: none;
}


/* Abschnittsüberschrift */

.dtkv-vm__section-head {
  margin: 0 0 24px;
}

.dtkv-vm__section-head h3 {
  margin: 0;

  color: var(--dtkv-text, #1f1f1f);

  font-size: 30px;
  font-weight: 700;
  line-height: 1.2;
}

.dtkv-vm__section-head p {
  margin: 8px 0 0;

  color: var(--dtkv-secondary, #4a4a4a);

  font-size: 16px;
  line-height: 1.5;
}


/* ---------------------------------------------------------
   4. Formularraster
   --------------------------------------------------------- */

.dtkv-vm__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px 24px;
}

.dtkv-vm__field {
  min-width: 0;
}

.dtkv-vm__field--full {
  grid-column: 1 / -1;
}


/* ---------------------------------------------------------
   5. Feldbeschriftungen
   --------------------------------------------------------- */

.dtkv-vm label,
.dtkv-vm__label {
  display: block;

  margin: 0 0 7px;

  color: var(--dtkv-text, #1f1f1f);

  font-size: 16px;
  font-weight: 600;
  line-height: 1.35;
}


/* ---------------------------------------------------------
   6. Eingabefelder
   --------------------------------------------------------- */

.dtkv-vm input[type="text"],
.dtkv-vm input[type="email"],
.dtkv-vm input[type="tel"],
.dtkv-vm input[type="url"],
.dtkv-vm input[type="number"],
.dtkv-vm select,
.dtkv-vm textarea {
  width: 100%;
  min-height: 52px;

  padding: 12px 16px;

  color: var(--dtkv-text, #1f1f1f);
  background: #fff;

  border: 1px solid var(--dtkv-secondary, #4a4a4a);
  border-radius: 8px;

  box-sizing: border-box;

  font: inherit;
  font-size: 16px;
  line-height: 1.4;
}

.dtkv-vm textarea {
  min-height: 104px;
  resize: vertical;
}

.dtkv-vm input::placeholder,
.dtkv-vm textarea::placeholder {
  color: #858585;
  opacity: 1;
}

/* Dropdown-Pfeil */

.dtkv-vm select {
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;

  padding-right: 54px !important;

  background-color: #fff;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='10' viewBox='0 0 16 10'%3E%3Cpath d='M2 2l6 6 6-6' fill='none' stroke='%231f1f1f' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 20px center;
  background-size: 16px 10px;

  cursor: pointer;
}

/* Alten Pfeil im Internet Explorer ausblenden */
.dtkv-vm select::-ms-expand {
  display: none;
}

/* Fokus */

.dtkv-vm input:focus,
.dtkv-vm select:focus,
.dtkv-vm textarea:focus {
  border-color: var(--dtkv-primary, #a9936f);

  outline: 2px solid rgba(169, 147, 111, 0.28);
  outline-offset: 1px;
}


/* Fehlerzustand */

.dtkv-vm input.is-invalid,
.dtkv-vm select.is-invalid,
.dtkv-vm textarea.is-invalid {
  border-color: #a33;
  box-shadow: 0 0 0 1px #a33;
}


/* ---------------------------------------------------------
   7. Checkboxen
   --------------------------------------------------------- */

.dtkv-vm__checks {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 24px;
}

.dtkv-vm__checks--stacked {
  grid-template-columns: 1fr;
  gap: 11px;
}

.dtkv-vm__checks label {
  display: flex;
  align-items: flex-start;
  gap: 10px;

  margin: 0;

  font-size: 15px;
  font-weight: 400;

  cursor: pointer;
}



.dtkv-vm__checks a {
  color: var(--dtkv-secondary, #4a4a4a);

  font-weight: 600;

  text-decoration-color: var(--dtkv-primary, #a9936f);
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}

.dtkv-vm__checks input[type="checkbox"] {
  appearance: none;
  -webkit-appearance: none;

  display: inline-grid;
  place-content: center;

  width: 18px;
  height: 18px;
  flex: 0 0 18px;

  margin: 2px 0 0;

  background: #fff;
  border: 1px solid var(--dtkv-secondary, #4a4a4a);
  border-radius: 3px;

  cursor: pointer;
}

.dtkv-vm__checks input[type="checkbox"]::before {
  content: "";

  width: 9px;
  height: 5px;

  border-left: 2px solid #fff;
  border-bottom: 2px solid #fff;

  transform: rotate(-45deg) scale(0);
  transform-origin: center;

  transition: transform 0.15s ease;
}

.dtkv-vm__checks input[type="checkbox"]:checked {
  background: var(--dtkv-primary, #a9936f);
  border-color: var(--dtkv-primary, #a9936f);
}

.dtkv-vm__checks input[type="checkbox"]:checked::before {
  transform: rotate(-45deg) scale(1);
}

.dtkv-vm__checks input[type="checkbox"]:focus-visible {
  outline: 2px solid rgba(169, 147, 111, 0.28);
  outline-offset: 2px;
}

/* ---------------------------------------------------------
   8. Formularnavigation und Buttons
   --------------------------------------------------------- */

.dtkv-vm__actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;

  margin-top: 28px;
  padding-top: 22px;

  border-top: 1px solid var(--dtkv-line, #e8e4de);
}

.dtkv-vm__next,
.dtkv-vm__back,
.dtkv-vm__submit {
  min-height: 48px;
  padding: 12px 22px;

  border-radius: 8px;

  font: inherit;
  font-size: 16px;
  font-weight: 700;

  cursor: pointer;
}


/* Primäre Buttons */

.dtkv-vm__next,
.dtkv-vm__submit {
  color: #fff;
  background: var(--dtkv-primary, #a9936f);

  border: 1px solid var(--dtkv-primary, #a9936f);
}

.dtkv-vm__next:hover,
.dtkv-vm__next:focus-visible,
.dtkv-vm__submit:hover,
.dtkv-vm__submit:focus-visible {
  background: var(--dtkv-accent, #8a7554);
  border-color: var(--dtkv-accent, #8a7554);
}


/* Zurück-Button */

.dtkv-vm__back {
  color: var(--dtkv-text, #1f1f1f);
  background: #fff;

  border: 1px solid var(--dtkv-secondary, #4a4a4a);
}

.dtkv-vm__back:hover,
.dtkv-vm__back:focus-visible {
  background: var(--dtkv-primary-soft, #f3efe8);
}


/* ---------------------------------------------------------
   9. Statusmeldungen
   --------------------------------------------------------- */

.dtkv-vm__notice {
  margin: 0 0 20px;
  padding: 20px 22px;

  border-radius: 12px;
}

.dtkv-vm__notice h3 {
  margin: 0 0 8px;
}

.dtkv-vm__notice p {
  margin: 0;
}

.dtkv-vm__notice--success {
  background: #f1f6ef;
  border: 1px solid #cddfc7;
}

.dtkv-vm__notice--error {
  background: #fbf1f1;
  border: 1px solid #e5caca;
}


/* ---------------------------------------------------------
   10. Spam-Schutz
   --------------------------------------------------------- */

.dtkv-vm__honeypot {
  position: absolute !important;
  left: -9999px !important;

  width: 1px !important;
  height: 1px !important;

  overflow: hidden !important;
}


/* =========================================================
   Tablet und Mobil
   ========================================================= */

@media (max-width: 767px) {

  .dtkv-vm {
    scroll-margin-top: 88px;
  }

  .dtkv-vm__form {
    gap: 18px;
  }


  /* Schritt-Navigation */

  .dtkv-vm__steps {
    justify-content: space-between;
    padding: 0;
  }

  .dtkv-vm__step {
    min-width: 58px;
    gap: 6px;
  }

  .dtkv-vm__step-shape {
    width: 36px;
    height: 36px;
  }

  .dtkv-vm__step-label {
    font-size: 12px;
  }

  .dtkv-vm__step-line {
    margin: 17px 2px 0;
  }


  /* Formularabschnitt */

  .dtkv-vm__section {
    padding: 26px 18px;
  }

  .dtkv-vm__section-head {
    margin-bottom: 20px;
  }

  .dtkv-vm__section-head h3 {
    font-size: 24px;
  }


  /* Raster */

  .dtkv-vm__grid,
  .dtkv-vm__checks {
    grid-template-columns: 1fr;
  }

  .dtkv-vm__field--full {
    grid-column: auto;
  }


  /* Buttons */

  .dtkv-vm__actions {
    margin-top: 24px;
  }

  .dtkv-vm__next,
  .dtkv-vm__back,
  .dtkv-vm__submit {
    min-width: 0;
    padding: 11px 17px;
  }

  .dtkv-vm__submit {
    flex: 1;
  }
}


/* =========================================================
   Kleine Smartphones
   ========================================================= */

@media (max-width: 430px) {

  .dtkv-vm__step-label {
    max-width: 66px;
  }

  .dtkv-vm__step-line {
    min-width: 8px;
  }

  .dtkv-vm__actions {
    gap: 10px;
  }
}