/* ============================================================
   CONTACT — formulaire, trois cartes et réseaux à côté, questions fréquentes et plan dessiné dessous
   Chargée à l'arrivée sur /contact (core/lazy-assets.js) ; liens des réseaux
   sociaux (.socials, .social) dans modules/header/header.css, servis aussi par le
   pied de page ; teintes .tone-* de core/css/layout.css
   ============================================================ */
/* Photo du bandeau (voile : .page-head--photo, core/css/layout.css), limitée à la rubrique. */
[data-route="contact"] .page-head--photo { --ph-photo: url('/assets/heroes/contact-accueil.webp'); --ph-photo-sm: url('/assets/heroes/contact-accueil-1000.webp'); --ph-pos: center 40%; --ph-pos-sm: 72% center; }
:where(.call, .faq-item) { --c: var(--c-orange); --s: var(--c-orange-soft); --i: var(--c-orange-ink); }

/* ---------- Mise en page : formulaire | cartes + réseaux ; dessous : questions | plan ---------- */
.contact-grid { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(0, 1fr); grid-template-areas: "form ways" "form follow"; grid-template-rows: auto 1fr; gap: 24px 32px; align-items: start; }
.contact-form-block { grid-area: form; }
.contact-ways { grid-area: ways; }
.contact-grid .follow { grid-area: follow; margin: 0; }
.contact-more > .block, .contact-grid > .block { margin-top: 0; }
.contact-more { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 32px; align-items: start; margin-top: 44px; }

/* ---------- Formulaire ---------- */
.contact-form-block { background: #fff; border-radius: 26px 26px 26px 8px; box-shadow: var(--shadow); padding: 28px 30px; border-top: 6px solid var(--c-orange); }
.contact-form-block h2 { margin-top: 0; }
.contact-form textarea { height: 177px; }
.contact-form .form-actions { margin-top: 6px; }
.contact-sent { text-align: center; padding: 28px 10px 10px; animation: fun-hop .5s both; }
.contact-sent:focus { outline: none; }
.contact-sent p { margin: 0 0 8px; }
.contact-sent-title { font-family: var(--f-display); font-size: 24px; }
.contact-sent-sticker { display: grid; place-items: center; width: 84px; height: 84px; margin: 0 auto 14px; border-radius: 50%; background: var(--c-green-soft); border: 3px solid var(--c-green); }
.contact-sent-sticker svg { width: 48px; height: 48px; }

/* ---------- Appeler, Écrire, Venir : l'une sous l'autre ---------- */
.calls { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.call { display: grid; grid-template-columns: auto minmax(0, 1fr); column-gap: 16px; row-gap: 4px; align-items: start; background: var(--s); border-radius: 22px 22px 22px 8px; padding: 18px 20px; animation: fun-hop .55s cubic-bezier(.3, 1.5, .5, 1) both; animation-delay: calc(var(--n, 0) * .12s); }
.call > :not(.call-sticker) { grid-column: 2; justify-self: start; }
.call:nth-child(2) { border-radius: 22px 22px 8px 22px; }
.call:nth-child(3) { border-radius: 22px 8px 22px 22px; }
.call-sticker { grid-row: 1 / span 4; width: 56px; height: 56px; border-radius: 50%; background: #fff; border: 3px solid var(--c); display: grid; place-items: center; }
.call-sticker svg { width: 32px; height: 32px; }
.call:hover .call-sticker { animation: fun-jump .5s ease-out; }
.call h3 { font-size: 20px; color: var(--i); margin: 0; }
.call-big { font-family: var(--f-display); font-weight: 800; font-size: 22px; line-height: 1.2; color: var(--c-ink); text-decoration: none; }
/* Même taille que le téléphone et l'adresse ; la ligne se coupe après « @ » si la carte est étroite. */
.call-mail { display: inline-block; overflow-wrap: anywhere; }
.call-mail-domain { white-space: nowrap; }
@media (max-width: 360px) { .call-mail-domain { white-space: normal; } }
a.call-big:hover { text-decoration: underline; }
.call small { color: var(--c-mute); font-weight: 700; font-size: 14px; }
.call-link { font-weight: 800; color: var(--i); }
.call-open { display: inline-flex; align-items: center; gap: 8px; font-weight: 800; font-size: 13.5px; border-radius: var(--r-pill); padding: 3px 12px 3px 10px; background: #fff; }
.call-open i { position: relative; width: 10px; height: 10px; border-radius: 50%; background: var(--c-green); }
.call-open i::after { content: ""; position: absolute; inset: 0; border-radius: 50%; background: var(--c-green); animation: contact-ping 1.6s ease-out infinite; }
.call-open.is-closed i, .call-open.is-closed i::after { background: var(--c-mute); animation: none; }
@keyframes contact-ping { from { transform: scale(.6); opacity: .7; } to { transform: scale(2.4); opacity: 0; } }

/* ---------- Suivez-nous ---------- */
.follow h2 { font-size: 22px; margin: 0 0 12px; }
.follow-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; }
.follow-card { display: flex; align-items: center; gap: 14px; padding: 14px 16px; border-radius: 22px; background: var(--s); border: 3px solid transparent; color: var(--c-ink); text-decoration: none; transition: transform .25s, border-color .25s; }
.follow-card:hover, .follow-card:focus-visible { transform: translateY(-4px) rotate(-1deg); border-color: var(--c); }
.follow-icon { flex: 0 0 auto; width: 48px; height: 48px; border-radius: 50%; background: #fff; border: 3px solid var(--c); color: var(--i); display: grid; place-items: center; }
.follow-icon svg { width: 22px; height: 22px; }
.follow-card b { display: block; font-family: var(--f-display); font-size: 19px; color: var(--i); line-height: 1.1; }
.follow-card small { display: block; color: var(--c-mute); font-weight: 700; font-size: 13px; }
@media (prefers-reduced-motion: reduce) { .follow-card { transition: none; } .follow-card:hover { transform: none; } }

/* ---------- Avant d'écrire ---------- */
.faq { display: grid; gap: 10px; }
.faq-item { background: var(--s); border-radius: 18px; overflow: hidden; }
.faq-item summary { list-style: none; cursor: pointer; display: flex; gap: 12px; align-items: center; padding: 12px 16px; font-family: var(--f-display); font-weight: 700; font-size: 18px; line-height: 1.2; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: "+"; margin-left: auto; font-size: 22px; font-weight: 800; color: var(--i); transition: transform .25s; }
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-item summary:hover .faq-sticker { animation: fun-jump .5s ease-out; }
.faq-sticker { flex: 0 0 auto; width: 42px; height: 42px; border-radius: 50%; background: #fff; border: 2px solid var(--c); display: grid; place-items: center; }
.faq-sticker svg { width: 24px; height: 24px; }
.faq-answer { padding: 0 18px 14px 70px; font-size: 15px; animation: fun-hop .3s both; }
.faq-answer p { margin: 0 0 6px; }
.faq-answer ul { margin: 0 0 8px; padding-left: 18px; }
.faq-answer a { font-weight: 800; color: var(--i); }

/* ---------- Plan d'accès dessiné ---------- */
.map-card { position: relative; height: 320px; border-radius: 22px; overflow: hidden; background: #F3F7EF; }
.map-streets { position: absolute; inset: 0; width: 100%; height: 100%; }
.map-street { position: absolute; left: 12%; top: calc(62% - 2px); font-weight: 800; font-size: 13px; color: var(--c-mute); transform: rotate(-2deg); }
.map-pin { position: absolute; left: 51%; top: 34%; width: 46px; height: 46px; border-radius: 50% 50% 50% 0; background: var(--c-orange); transform: rotate(-45deg); box-shadow: 0 8px 18px rgba(240, 122, 0, .35); animation: contact-bounce 1.6s ease-in-out infinite; }
.map-pin::after { content: ""; position: absolute; inset: 13px; border-radius: 50%; background: #fff; }
.map-shadow { position: absolute; left: calc(51% + 2px); top: calc(34% + 56px); width: 34px; height: 10px; border-radius: 50%; background: rgba(14, 12, 12, .15); }
.map-label { position: absolute; left: calc(51% + 56px); top: calc(34% - 4px); background: var(--c-black); color: #fff; border-radius: 12px; padding: 6px 12px; font-weight: 800; font-size: 14px; }
.map-label small { display: block; font-weight: 600; opacity: .8; }
@keyframes contact-bounce { 0%, 100% { transform: translateY(0) rotate(-45deg); } 50% { transform: translateY(-12px) rotate(-45deg); } }
.map-actions { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; margin: 14px 0 0; }
.map-actions span { color: var(--c-mute); font-size: 14px; }

@media (max-width: 860px) {
  /* Téléphone : les cartes d'abord (appeler en un geste), puis le formulaire, puis les réseaux. */
  .contact-grid { grid-template-columns: minmax(0, 1fr); grid-template-areas: "ways" "form" "follow"; grid-template-rows: auto; }
  .contact-more { grid-template-columns: minmax(0, 1fr); }
  .contact-form-block { padding: 22px 18px; }
  .map-label { left: auto; right: 10px; top: 12px; }
  .map-card { height: 260px; }
}
}
@media (prefers-reduced-motion: reduce) {
  .map-pin, .call-open i::after { animation: none; }
}
