/* ============================================================
   CLANDESTUDIO — page Contact
   ============================================================ */

.ct { padding: clamp(90px, 11vw, 140px) 0 clamp(70px, 9vw, 120px); overflow-x: clip; }  /* les entrées latérales animées ne créent pas de défilement horizontal */
.ct__grid { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: clamp(32px, 5vw, 80px); align-items: start; }
.ct__side { min-width: 0; }
.ct__intro .h-xl { margin-top: 16px; font-size: clamp(44px, 6.2vw, 96px); }

/* ---------- Moyens de contact directs ---------- */
/* Entrée jouée au chargement (et non liée au scroll) : ces liens sont visibles dès l'ouverture */
.ct-ways { list-style: none; margin: 36px 0 0; padding: 0; display: grid; gap: 10px; }
.ct-ways li, .ct__social { animation: ct-rise .8s var(--ease) both; }
.ct-ways li:nth-child(1) { animation-delay: .35s; }
.ct-ways li:nth-child(2) { animation-delay: .45s; }
.ct-ways li:nth-child(3) { animation-delay: .55s; }
.ct__social { animation-delay: .65s; }
@keyframes ct-rise { from { opacity: 0; transform: translateY(24px); } }
.ct-way {
  display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 16px;
  padding: 16px 18px; border-radius: var(--r-md); background: var(--paper); border: 1px solid var(--line);
  transition: transform .3s var(--ease), box-shadow .3s var(--ease), border-color .3s;
}
.ct-way:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: rgba(63, 217, 192, .6); }
.ct-way > .icon:first-child { width: 26px; height: 26px; color: var(--neon-ink); }
.ct-way > .icon:last-child { color: var(--ink-soft); transition: transform .25s var(--ease); }
.ct-way:hover > .icon:last-child { transform: translate(2px, -2px); color: var(--ink); }
.ct-way span { min-width: 0; }
.ct-way small { display: block; font-size: 13px; color: var(--ink-soft); }
.ct-way b { display: block; font-family: var(--display); font-size: 17px; font-weight: 700; overflow-wrap: anywhere; }
.ct-way--wa { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.ct-way--wa small { color: rgba(255, 250, 242, .65); }
.ct-way--wa > .icon:first-child { color: var(--neon); }
.ct-way--wa > .icon:last-child { color: rgba(255, 250, 242, .7); }
.ct-way--wa:hover { box-shadow: 0 14px 34px -10px var(--neon-glow); }
.ct-way--wa:hover > .icon:last-child { color: var(--neon); }
.ct__social { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }

/* ---------- Carte du formulaire ---------- */
.ct__panel { position: relative; min-width: 0; padding: clamp(22px, 3.4vw, 44px); border-radius: var(--r-lg); background: var(--glass-strong); box-shadow: var(--shadow-lg); }

.ct-progress { margin-bottom: 30px; }
.ct-progress__steps { list-style: none; display: flex; justify-content: space-between; gap: 10px; margin: 0 0 14px; padding: 0; }
.ct-progress__steps li { display: flex; align-items: center; gap: 8px; min-width: 0; font-size: 13px; font-weight: 500; color: var(--ink-soft); }
.ct-progress__steps b {
  display: grid; place-items: center; flex: none; width: 26px; height: 26px; border-radius: 50%;
  border: 1px solid var(--line-strong); font-family: var(--display); font-size: 12px; transition: background .3s, color .3s, border-color .3s;
}
.ct-progress__steps span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ct-progress__steps li.is-done b { background: var(--neon); border-color: var(--neon); color: var(--ink); }
.ct-progress__steps li.is-current { color: var(--ink); font-weight: 600; }
.ct-progress__steps li.is-current b { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.ct-progress__bar { height: 4px; border-radius: 4px; background: var(--line); overflow: hidden; }
.ct-progress__bar span { display: block; height: 100%; width: 25%; border-radius: inherit; background: linear-gradient(90deg, var(--neon-ink), var(--neon)); box-shadow: 0 0 12px var(--neon-glow); transition: width .5s var(--ease); }

/* ---------- Étapes ---------- */
.ct-form fieldset { margin: 0; padding: 0; border: 0; min-width: 0; }
.ct-step.is-current { animation: ct-in .45s var(--ease) both; }
@keyframes ct-in { from { opacity: 0; transform: translateX(18px); } }
.ct-step__title { display: block; padding: 0; margin: 0 0 8px; font-family: var(--display); font-weight: 700; font-size: clamp(24px, 2.4vw, 32px); line-height: 1.1; letter-spacing: -.02em; }
.ct-step__title span { display: block; margin-bottom: 8px; font-size: 12px; letter-spacing: .16em; text-transform: uppercase; color: var(--copper); }
.ct-step__title:focus { outline: none; }
.ct-step__hint { margin: 0 0 22px; color: var(--ink-soft); font-size: 15px; }
.ct-step > .ct-fields, .ct-step > .ct-field { margin-top: 22px; }

.ct-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.ct-field { display: grid; gap: 7px; align-content: start; }
.ct-field label, .ct-group legend { font-weight: 600; font-size: 15px; }
.ct-req { color: var(--copper); }
.ct-opt { margin-left: 6px; font-weight: 400; font-size: 13px; color: var(--ink-soft); }
.ct-field input, .ct-field textarea {
  width: 100%; min-height: 50px; padding: 13px 16px; border-radius: var(--r-sm);
  border: 1px solid var(--line-strong); background: var(--paper); color: var(--ink);
  font: inherit; font-size: 16px; line-height: 1.4;
  transition: border-color .2s, box-shadow .2s, background .2s;
}
.ct-field textarea { resize: vertical; min-height: 150px; }
.ct-field input::placeholder, .ct-field textarea::placeholder { color: #8f806f; }
.ct-field input:hover, .ct-field textarea:hover { border-color: rgba(30, 24, 18, .4); }
.ct-field input:focus, .ct-field textarea:focus { outline: none; border-color: var(--neon-ink); box-shadow: 0 0 0 4px rgba(63, 217, 192, .28); }
.ct-field [aria-invalid="true"] { border-color: #b3261e; background: #fff6f4; }
.ct-field [aria-invalid="true"]:focus { border-color: #b3261e; box-shadow: 0 0 0 4px rgba(179, 38, 30, .18); }
.ct-help { margin: 0; font-size: 13px; color: var(--ink-soft); }
.ct-error { display: flex; align-items: center; gap: 6px; margin: 0; font-size: 14px; font-weight: 500; color: #b3261e; }
.ct-error::before { content: "!"; display: grid; place-items: center; flex: none; width: 18px; height: 18px; border-radius: 50%; background: #b3261e; color: #fff; font-size: 12px; font-weight: 700; }
.ct-error[hidden] { display: none; }

/* ---------- Tuiles des pôles ---------- */
.ct-poles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.ct-pole { position: relative; display: block; cursor: pointer; }
.ct-pole input, .ct-chip input { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.ct-pole__box {
  position: relative; display: flex; flex-direction: column; gap: 6px; height: 100%; padding: 16px;
  border-radius: var(--r-md); background: var(--paper); border: 1px solid var(--line);
  transition: transform .3s var(--ease), border-color .25s, box-shadow .25s, background .25s;
}
.ct-pole:hover .ct-pole__box { transform: translateY(-3px); border-color: rgba(63, 217, 192, .6); box-shadow: var(--shadow); }
.ct-pole__icon { display: grid; place-items: center; width: 44px; height: 44px; margin-bottom: 8px; border-radius: 14px; background: rgba(63, 217, 192, .14); color: var(--neon-ink); }
.ct-pole__icon .icon { width: 24px; height: 24px; }
.ct-pole__check {
  position: absolute; top: 12px; right: 12px; display: grid; place-items: center; width: 24px; height: 24px;
  border-radius: 50%; border: 1px solid var(--line-strong); color: transparent; transition: background .2s, color .2s, border-color .2s;
}
.ct-pole__check .icon { width: 15px; height: 15px; stroke-width: 2.6; }
.ct-pole b { font-family: var(--display); font-size: 16px; line-height: 1.15; }
.ct-pole small { font-size: 13px; line-height: 1.4; color: var(--ink-soft); }
.ct-pole input:checked + .ct-pole__box { border-color: var(--neon-ink); background: #f1fbf8; box-shadow: 0 0 0 1px var(--neon-ink), 0 12px 30px -14px var(--neon-glow); }
.ct-pole input:checked + .ct-pole__box .ct-pole__check { background: var(--neon); border-color: var(--neon); color: var(--ink); }
.ct-pole input:checked + .ct-pole__box .ct-pole__icon { background: var(--ink); color: var(--neon); }
.ct-pole input:focus-visible + .ct-pole__box { outline: 2px solid var(--neon-ink); outline-offset: 3px; }
.ct-step.has-error .ct-pole__box { border-color: rgba(179, 38, 30, .5); }
.ct-step > .ct-error { margin-top: 14px; }

/* ---------- Puces (prestations, délai) ---------- */
.ct-prestas { display: grid; gap: 22px; }
.ct-presta legend { display: flex; align-items: center; gap: 8px; padding: 0; margin-bottom: 10px; font-family: var(--display); font-weight: 700; font-size: 16px; }
.ct-presta legend .icon { color: var(--neon-ink); }
.ct-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.ct-chip { position: relative; cursor: pointer; }
.ct-chip span {
  display: inline-flex; align-items: center; gap: 6px; min-height: 42px; padding: 9px 16px;
  border-radius: 999px; border: 1px solid var(--line-strong); background: var(--paper);
  font-size: 14px; font-weight: 500; line-height: 1.2; transition: background .2s, border-color .2s, color .2s, transform .2s var(--ease);
}
.ct-chip span .icon { width: 0; margin-left: -6px; opacity: 0; stroke-width: 2.6; transition: width .2s var(--ease), opacity .2s, margin .2s; }
.ct-chip:hover span { border-color: var(--neon-ink); transform: translateY(-1px); }
.ct-chip input:checked + span { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.ct-chip input:checked + span .icon { width: 1em; margin-left: 0; opacity: 1; color: var(--neon); }
.ct-chip input:focus-visible + span { outline: 2px solid var(--neon-ink); outline-offset: 3px; }
.ct-chip--radio input:checked + span { background: var(--neon); border-color: var(--neon); color: var(--ink); }
.ct-group { margin-top: 24px !important; }
.ct-group legend { padding: 0; margin-bottom: 10px; }
.ct-empty { margin: 0; padding: 18px; border-radius: var(--r-sm); border: 1px dashed var(--line-strong); color: var(--ink-soft); }

.ct-privacy { display: flex; gap: 10px; align-items: flex-start; margin: 24px 0 0; font-size: 14px; color: var(--ink-soft); }
.ct-privacy .icon { margin-top: 2px; color: var(--neon-ink); }

/* Champ piège : invisible pour les humains, présent pour les robots */
.ct-hp { position: absolute !important; left: -10000px; top: auto; width: 1px; height: 1px; overflow: hidden; }

/* ---------- Boutons de navigation ---------- */
.ct-actions { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: 32px; padding-top: 22px; border-top: 1px solid var(--line); }
.ct-actions .btn--glass .icon { transition: transform .25s var(--ease); }
.ct-actions .btn--glass:hover .icon { transform: translateX(-3px); }
.ct-actions .btn[aria-busy="true"] { opacity: .75; cursor: progress; }
.ct-actions .btn[aria-busy="true"] .icon { animation: ct-pulse 1s ease-in-out infinite; }
@keyframes ct-pulse { 50% { opacity: .3; } }

/* ---------- Échec / succès ---------- */
.ct-fail { margin-top: 22px; padding: 18px 20px; border-radius: var(--r-md); background: #fff4ef; border: 1px solid rgba(179, 38, 30, .3); }
.ct-fail p { margin: 0 0 14px; font-size: 15px; }
.ct-fail strong { color: #8c1d16; }
.ct-fail[hidden] { display: none; }

.ct-done { text-align: center; padding: clamp(20px, 4vw, 50px) 0; animation: ct-in .5s var(--ease) both; }
.ct-done:focus { outline: none; }
.ct-done__icon { display: grid; place-items: center; width: 76px; height: 76px; margin: 0 auto 22px; border-radius: 50%; background: var(--neon); color: var(--ink); box-shadow: 0 0 0 10px rgba(63, 217, 192, .18), 0 18px 40px -12px var(--neon-glow); }
.ct-done__icon .icon { width: 36px; height: 36px; stroke-width: 2.4; }
.ct-done .h-md { margin-top: 12px; }
.ct-done > p:not(.eyebrow) { max-width: 460px; margin: 16px auto 0; color: var(--ink-soft); }
.ct-done__actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 28px; }
[hidden] { display: none !important; }

/* ---------- Responsive ---------- */
@media (max-width: 1280px) {
  .ct-progress__steps span { display: none; }
  .ct-progress__steps li.is-current span { display: block; }
  .ct-progress__steps { justify-content: flex-start; gap: 14px; }
}
@media (max-width: 960px) {
  .ct__grid { grid-template-columns: 1fr; }
  .ct__side { position: static; }
  .ct-ways { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
}
@media (max-width: 640px) {
  .ct-fields { grid-template-columns: 1fr; }
  .ct-poles { grid-template-columns: 1fr 1fr; gap: 10px; }
  .ct-pole__box { padding: 14px; }
  .ct-pole small { font-size: 12px; }
}
@media (max-width: 560px) {
  .ct { padding-top: 70px; }
  .ct-ways { grid-template-columns: 1fr; }
  .ct__panel { padding: 22px 18px; border-radius: 24px; }
  .ct-actions .btn { flex: 1; padding-inline: 16px; }
  .ct-actions > span:empty { display: none; }
}
