/* =========================
   Scope dédié au(x) formulaire(s)
   ========================= */
.immocfg-form{
  /* Variables locales au formulaire (autonomes) */
  --icf-container-max: 1900px;
  --icf-pad-inline: clamp(12px, 3.2vw, 60px);
  --icf-pad-block: clamp(16px, 3vw, 40px);

  --icf-color-primary: #005866;
  --icf-color-accent: #00525d;
  --icf-color-accent-rgb: 0, 82, 93;
  --icf-color-gold: rgba(224,196,11);

  --icf-color-text: #333;
  --icf-color-muted: #666;
  --icf-color-light: #f9fafb;
  --icf-color-border: #e5e7eb;

  --icf-radius: 12px;
  --icf-shadow: 0 2px 10px rgba(0,0,0,.04);
  --icf-shadow-lg: 0 6px 18px rgba(0,0,0,.10);

  --icf-gap: 22px;
  --icf-card-padding: 16px;
  --icf-btn-radius: 10px;

  --icf-primary-soft: rgba(var(--icf-color-accent-rgb), .3);
}

.immocfg-form .cf7-estimation br {
  display: none;
}

/* Ancrage visuel au reste de la page (barre or) */
.immocfg-form .ic-contact-annonce{
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;
  font-size: 16px;
  line-height: 1.5;
  color: var(---icf-color-text);
}

.ic-contact-annonce {
  max-width: var(--icf-container-max);
  margin: 0 auto;
  padding: var(--icf-pad-block) var(--icf-pad-inline);
  box-sizing: border-box;
  background: var(--icf-color-light);
  border-top: 4px solid var(--icf-color-gold);
  border-bottom: 4px solid var(--icf-color-gold);
  box-shadow: var(--icf-shadow-lg);
}

/* Carte & titres */
.immocfg-form .cf7-estimation{
  --gap: 20px;
  --radius: var(--icf-radius);
  --border: 1px solid var(--icf-color-border);
  --shadow: var(--icf-shadow-lg);

  padding: 24px;
  border: var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  background: #fff;
  color: var(--icf-color-text);
}
.immocfg-form .cf7-estimation .cf7-title{
  margin: 8px 0 14px;
  font-size: 1.15rem;
  line-height: 1.3;
  font-weight: 700;
  color: var(--icf-color-primary);
}

/* Grille responsive */
.immocfg-form .cf7-estimation .cf7-grid{
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: var(--icf-gap);
  margin-bottom: 18px;
}
.immocfg-form .cf7-estimation .cf7-field{ margin: 0; }
.immocfg-form .cf7-estimation .cf7-col-2{ grid-column: span 2; }

/* Labels & champs */
.immocfg-form .cf7-estimation label{
  display: block;
  font-size: .95rem;
  margin-bottom: 6px;
  color: var(--icf-color-text);
}
.immocfg-form .cf7-estimation .req{
  color: var(--icf-color-gold);
  font-weight: 700;
}

.immocfg-form .cf7-estimation input[type="text"],
.immocfg-form .cf7-estimation input[type="email"],
.immocfg-form .cf7-estimation input[type="tel"],
.immocfg-form .cf7-estimation select{
  width: 100%;
  box-sizing: border-box;
  appearance: none;
  border: 1px solid var(--icf-color-border);
  border-radius: 10px;
  padding: 12px 14px;
  font-size: 16px;
  line-height: 1.4;
  background: #fff;
  transition: border-color .2s, box-shadow .2s, background-color .2s;
}

.immocfg-form .cf7-estimation textarea {
  width: 100%;
  box-sizing: border-box;
  appearance: none;
  border: 1px solid var(--icf-color-border);
  border-radius: 10px;
  padding: 12px 14px;
  font-size: 16px;
  line-height: 1.4;
  background: #fff;
  transition: border-color .2s, box-shadow .2s, background-color .2s;
}

.immocfg-form .cf7-estimation select{ padding-right: 34px; }
.immocfg-form .cf7-estimation textarea{ min-height: 60px; resize: vertical; }

.immocfg-form .cf7-estimation input::placeholder,
.immocfg-form .cf7-estimation textarea::placeholder{
  color: var(--icf-color-muted);
}

/* Focus & accessibilité */
.immocfg-form .cf7-estimation input:focus-visible,
.immocfg-form .cf7-estimation select:focus-visible,
.immocfg-form .cf7-estimation textarea:focus-visible{
  outline: none;
  border-color: var(--icf-color-primary);
  box-shadow: 0 0 0 4px var(--icf-primary-soft);
}

/* Bouton */
.immocfg-form .cf7-estimation .cf7-actions{ margin-top: 10px; }
.immocfg-form .cf7-estimation .cf7-btn{
  display: inline-block;
  border: 0;
  border-radius: var(--icf-btn-radius);
  padding: 12px 20px;
  font-weight: 700;
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
  background: var(--icf-color-primary);
  color: #fff;
  transition: transform .06s ease, box-shadow .2s, background-color .2s;
  box-shadow: 0 8px 20px rgba(var(--icf-color-accent-rgb), .25);
}
.immocfg-form .cf7-estimation .cf7-btn:hover{
  background: var(--icf-color-accent);
  transform: translateY(-1px);
}
.immocfg-form .cf7-estimation .cf7-btn:active{
  transform: translateY(0);
  box-shadow: none;
}

/* États d’erreur CF7 (ne touche pas au scope global) */
.immocfg-form .wpcf7 form .wpcf7-not-valid{
  border-color: #e74c3c !important;
  background: #fff6f6;
}
.immocfg-form .wpcf7 form .wpcf7-not-valid-tip{
  font-size: .85rem;
  margin-top: 6px;
  color: #c0392b;
}
.immocfg-form .wpcf7 form .wpcf7-response-output{
  border-radius: 10px;
  margin: 14px 0 0;
}

/* Responsive */
@media (max-width: 768px){
  .immocfg-form .cf7-estimation{ padding: 18px; }
  .immocfg-form .cf7-estimation .cf7-grid{ grid-template-columns: 1fr; }
  .immocfg-form .cf7-estimation .cf7-col-2{ grid-column: auto; }
  .immocfg-form .cf7-estimation input,
  .immocfg-form .cf7-estimation select,
  .immocfg-form .cf7-estimation textarea{ width: 100%; } /* full largeur mobile */
}
