/* =====================================================
   MOVAWAY — PAGE CONTACT
   (header/footer/components/base sont chargés en amont)
   ===================================================== */

/* ============ HERO ============ */
.contact-hero {
  padding: 30px 0 60px;
}

/* 3 petites citations (5 étoiles + phrase) — pattern repris d'avis */
.contact-hero-quotes {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 30px;
  align-items: start;
  text-align: center;
  margin-bottom: 36px;
}
.contact-hero-quote img {
  display: inline-block;
  height: 26px;
  width: auto;
  margin: 0 auto 10px;
}
.contact-hero-quote p {
  margin: 0;
  font-size: 1rem;
  font-weight: 500;
  color: var(--ink);
  line-height: 1.4;
}

.contact-hero-title {
  text-align: center;
  font-size: clamp(2.4rem, 1.6rem + 3vw, 4.6rem);
  font-weight: 800;
  letter-spacing: -1.5px;
  line-height: 1.05;
  margin: 0 0 22px;
  color: var(--ink);
}
.contact-hero-lead {
  text-align: center;
  font-size: clamp(1rem, 0.9rem + 0.4vw, 1.25rem);
  line-height: 1.55;
  color: var(--ink);
  max-width: 760px;
  margin: 0 auto 50px;
}

/* 3 photos d'illustration en grille */
.contact-hero-photos {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}
.contact-hero-photo img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: var(--border-radius);
  object-fit: cover;
  aspect-ratio: 555 / 424;
}

/* ============ SECTION FORMULAIRE + ENCART COP1 ============ */
.contact-form-section {
  padding: 60px 0 100px;
  background-color: #fff;
  background-image: url("https://movaway.fr/wp-content/uploads/2025/11/bg-contact-2.svg");
  background-repeat: no-repeat;
  background-position: center top;
  background-size: contain;
}
.contact-form-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 60px;
  align-items: start;
}

/* ----- Formulaire SANS cadre carte : fond direct, inputs en fond gris doux ----- */
.contact-form-legend {
  font-size: 13px;
  color: var(--ink-soft);
  margin: 0 0 20px;
}
/* ❊ orange brand — repris du style WP Gravity Forms */
.contact-form-req {
  color: #F97316;
  font-weight: 700;
  font-size: 0.8em;
  vertical-align: top;
  margin-left: 2px;
}

.contact-form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-bottom: 22px;
}
.contact-form-field {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.contact-form-field-full {
  margin-bottom: 22px;
}
.contact-form-field label {
  font-size: 15px;
  font-weight: 800;
  color: var(--ink);
  letter-spacing: -0.2px;
  transition: color .2s ease;
}
/* Label bleu au hover/focus du champ → feedback visuel global sur tout le bloc */
.contact-form-field:hover label,
.contact-form-field:focus-within label {
  color: var(--primary);
}
/* Inputs : fond gris très doux, pas de bordure visible, rounded large */
.contact-form-field input,
.contact-form-field textarea,
.contact-form-field select {
  font-family: inherit;
  font-size: 15px;
  color: var(--ink);
  background: #EFF1F4;
  border: 2px solid transparent;     /* invisible au repos, bleu au focus */
  border-radius: 14px;
  padding: 16px 20px;
  transition: background .2s ease, border-color .2s ease, box-shadow .2s ease;
  width: 100%;
  box-shadow: none;
}
.contact-form-field input:hover,
.contact-form-field textarea:hover,
.contact-form-field select:hover {
  background: #E5E9F0;
}
.contact-form-field input:focus,
.contact-form-field textarea:focus,
.contact-form-field select:focus {
  outline: none;
  background: #fff;
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(41, 124, 255, 0.15);
}
.contact-form-field textarea {
  resize: vertical;
  min-height: 160px;
  line-height: 1.55;
}

/* Select : chevron custom (pas le chevron natif laid) */
.contact-form-select {
  position: relative;
}
.contact-form-select::after {
  content: "";
  position: absolute;
  right: 22px;
  top: 50%;
  width: 9px;
  height: 9px;
  border-right: 2px solid var(--ink);
  border-bottom: 2px solid var(--ink);
  transform: translateY(-70%) rotate(45deg);
  pointer-events: none;
  transition: transform .2s ease, border-color .2s ease;
}
.contact-form-select:hover::after { border-color: var(--primary); }
.contact-form-select select {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  padding-right: 44px;
  cursor: pointer;
}

.contact-form-submit {
  margin-top: 32px;
  display: flex;
  justify-content: flex-start;
}
.contact-form-submit .btn {
  padding: 18px 36px;
  font-size: 15px;
}

/* ----- Colonne droite : conteneur relative pour la flèche absolute ----- */
.contact-cop1-col {
  position: relative;
}

/* ----- Encart Cop1 (carte gris-bleu arrondie) ----- */
.contact-cop1-card {
  background: #EFF1F4;
  border-radius: 28px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  position: relative;
  z-index: 2;
}

/* Bloc haut : vignette logo carrée + texte */
.contact-cop1-head {
  display: grid;
  grid-template-columns: 90px 1fr;
  gap: 16px;
  align-items: start;
}
/* Logo encadré dans une mini-carte blanche (look brand cohérent) */
.contact-cop1-logo-frame {
  background: #fff;
  border-radius: 16px;
  padding: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 1 / 1;
}
.contact-cop1-logo {
  width: 100%;
  height: auto;
  display: block;
}
.contact-cop1-text {
  margin: 0;
  font-size: 14px;
  line-height: 1.55;
  color: var(--ink);
}
.contact-cop1-text strong { font-weight: 800; }

/* Stat blanche : montant collecté */
.contact-cop1-stat {
  background: #fff;
  border-radius: 16px;
  padding: 18px 20px;
  text-align: center;
  box-shadow: 0 2px 8px rgba(0, 8, 56, 0.04);
}
.contact-cop1-stat-amount {
  font-size: clamp(1.6rem, 1.3rem + 1vw, 2.1rem);
  font-weight: 800;
  letter-spacing: -0.5px;
  color: var(--primary);
}
.contact-cop1-stat-label {
  font-size: 14px;
  color: var(--ink);
  margin-top: 4px;
}

/* ----- "On vous rappelle" : widget Join Stories (page-contact) ----- */
.contact-cop1-callback {
  position: relative;
  padding-top: 4px;
  min-height: 132px;            /* réserve l'espace pour le widget */
  align-self: flex-start;
}
/* Le mount-point du widget : largeur libre, le widget gère son propre layout */
#join-widget-page-contact {
  position: relative;
  z-index: 2;
  display: block;
  width: 100%;
  margin: 5px 2px;
  min-height: 114px;            /* min-height officiel du source WP */
}
@media (min-aspect-ratio: 3/4) {
  #join-widget-page-contact { min-height: 132px; }
}

/* ----- Skeleton "On vous rappelle" : anneau brand + label barre
   (même esthétique que le skeleton stories d'avis pour cohérence) ----- */
.contact-callback-skeleton {
  position: absolute;
  top: 4px;
  left: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  pointer-events: none;
  z-index: 1;
  transition: opacity .35s ease;
}
.contact-callback-skeleton.is-hidden { opacity: 0; }
.contact-callback-skel-circle {
  position: relative;
  width: 84px;
  height: 84px;
  border-radius: 50%;
  background: conic-gradient(
    from 0deg,
    var(--primary) 0deg,
    #6ba7ff 90deg,
    var(--primary-soft) 180deg,
    #6ba7ff 270deg,
    var(--primary) 360deg
  );
  animation: contact-skel-rotate 3s linear infinite;
}
.contact-callback-skel-circle::after {
  content: '';
  position: absolute;
  inset: 3px;
  border-radius: 50%;
  background: linear-gradient(110deg, #f3f5f9 30%, #fafbfd 50%, #f3f5f9 70%);
  background-size: 200% 100%;
  animation: contact-skel-shimmer 1.6s linear infinite;
}
.contact-callback-skel-label {
  width: 56px;
  height: 8px;
  border-radius: 4px;
  background: linear-gradient(110deg, #eef2f7 30%, #f7f9fc 50%, #eef2f7 70%);
  background-size: 200% 100%;
  animation: contact-skel-shimmer 1.6s linear infinite;
}
@keyframes contact-skel-rotate {
  0%   { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}
@keyframes contact-skel-shimmer {
  0%   { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}
@media (prefers-reduced-motion: reduce) {
  .contact-callback-skel-circle,
  .contact-callback-skel-circle::after,
  .contact-callback-skel-label { animation: none; }
  .contact-callback-skel-circle { background: var(--primary-soft); }
}

/* ----- Grande flèche bleue décorative qui descend de l'encart ----- */
.contact-arrow {
  position: absolute;
  bottom: -160px;
  right: -40px;
  width: 220px;
  height: auto;
  pointer-events: none;
  z-index: 1;
}

/* ============ FAQ ============
   .faq + .faq-item sont déjà stylés dans components.css → on réutilise tel quel.
   Seul le bouton sous la FAQ est spécifique à la page contact. */
.faq-cta {
  text-align: center;
  margin-top: 40px;
}

/* ============ RESPONSIVE ============ */
@media (max-width: 999px) {
  .contact-form-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .contact-cop1-head {
    grid-template-columns: 80px 1fr;
  }
  /* Flèche : positionnée à droite, ne descend plus en dessous mais reste à côté */
  .contact-arrow {
    bottom: -120px;
    right: 0;
    width: 180px;
  }
}

@media (max-width: 700px) {
  .contact-hero { padding: 20px 0 40px; }
  .contact-hero-quotes {
    grid-template-columns: 1fr;
    gap: 14px;
    margin-bottom: 24px;
  }
  /* Sur mobile, on n'affiche que la 1re citation (comme le source) */
  .contact-hero-quotes .contact-hero-quote:nth-child(n+2) {
    display: none;
  }
  .contact-hero-lead { margin-bottom: 30px; }

  /* Photos : 1 grande au-dessus + 2 petites en dessous */
  .contact-hero-photos {
    grid-template-columns: 1fr 1fr;
    gap: 12px;
  }
  .contact-hero-photos .contact-hero-photo:first-child {
    grid-column: span 2;
  }

  .contact-form-section { padding: 40px 0 60px; }
  .contact-form-row {
    grid-template-columns: 1fr;
    gap: 18px;
  }
  .contact-cop1-card { padding: 20px; }

  /* Flèche : cachée en mobile (la mise en page change trop, elle deviendrait
     décorative non pertinente sous la carte) */
  .contact-arrow { display: none; }
}

@media (max-width: 480px) {
  .contact-hero-photos {
    grid-template-columns: 1fr;
  }
  .contact-hero-photos .contact-hero-photo:first-child {
    grid-column: auto;
  }
}
