/**
 * Après mon DPE — Styles formulaire CF7
 * Layout 2 colonnes sur desktop, 1 colonne sur mobile, harmonisé avec Salient.
 */

/* ----- Conteneur ----- */
.wpcf7 form {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9em 1em;
}

/* ----- Lignes ----- */
.wpcf7 .amd-form-row {
  flex: 1 1 100%;
  margin: 0;
}

@media (min-width: 720px) {
  .wpcf7 .amd-form-row-half {
    flex: 1 1 calc(50% - 0.5em);
    max-width: calc(50% - 0.5em);
  }
}

/* ----- Labels ----- */
.wpcf7 .amd-form-row > label {
  display: block;
  font-weight: 600;
  font-size: 0.95em;
  margin-bottom: 0.35em;
  line-height: 1.35;
}

.wpcf7 .amd-required {
  color: #c0392b;
  font-weight: 700;
  margin-left: 0.15em;
}

/* ----- Inputs ----- */
.wpcf7 .amd-form-row input[type="text"],
.wpcf7 .amd-form-row input[type="email"],
.wpcf7 .amd-form-row input[type="tel"],
.wpcf7 .amd-form-row input[type="number"],
.wpcf7 .amd-form-row select,
.wpcf7 .amd-form-row textarea {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

.wpcf7 .amd-form-row textarea {
  min-height: 110px;
  resize: vertical;
}

/* ----- Bloc consentement RGPD ----- */
.wpcf7 .amd-form-row-consent {
  flex: 1 1 100%;
  background: #f6f7f9;
  border: 1px solid #e3e6eb;
  border-radius: 6px;
  padding: 1em 1.1em;
  font-size: 0.86em;
  line-height: 1.55;
  color: #3a3f47;
  margin-top: 0.4em;
}

.wpcf7 .amd-form-row-consent .wpcf7-acceptance,
.wpcf7 .amd-form-row-consent .wpcf7-form-control-wrap {
  display: block;
}

.wpcf7 .amd-form-row-consent .wpcf7-list-item {
  display: flex !important;
  align-items: flex-start;
  gap: 0.7em;
  margin: 0 !important;
  padding: 0;
}

.wpcf7 .amd-form-row-consent input[type="checkbox"] {
  appearance: auto !important;
  -webkit-appearance: checkbox !important;
  -moz-appearance: checkbox !important;
  width: 18px !important;
  height: 18px !important;
  min-width: 18px !important;
  margin: 0.2em 0 0 0 !important;
  padding: 0 !important;
  flex-shrink: 0;
  cursor: pointer;
  opacity: 1 !important;
  visibility: visible !important;
  position: static !important;
  transform: none !important;
  background: #fff !important;
  border: 1px solid #888 !important;
  border-radius: 3px !important;
  box-shadow: none !important;
  accent-color: #1a6fbf;
}

.wpcf7 .amd-form-row-consent input[type="checkbox"]:checked {
  background: #1a6fbf !important;
  border-color: #1a6fbf !important;
}

.wpcf7 .amd-form-row-consent .wpcf7-list-item-label {
  display: block;
  margin: 0;
  flex: 1;
}

.wpcf7 .amd-form-row-consent a {
  color: #1a6fbf;
  text-decoration: underline;
}

/* ----- Soumission ----- */
.wpcf7 .amd-submit-row {
  flex: 1 1 100%;
  margin-top: 0.5em;
}

.wpcf7 .amd-submit-row input[type="submit"] {
  width: 100%;
}

@media (min-width: 720px) {
  .wpcf7 .amd-submit-row input[type="submit"] {
    width: auto;
    min-width: 280px;
  }
}

/* ----- Messages d'erreur CF7 ----- */
.wpcf7 .wpcf7-not-valid-tip {
  font-size: 0.85em;
  margin-top: 0.25em;
}
