/* Fichier css/contact.css · chargé par : contact */
/* =====================================================================
   IAI v8 — PAGE CONTACT (une seule scène)
   Ouverture (titre + sphère) → la ville se construit → 4 arrêts = 4 étapes du formulaire → envoi (montée de la tour)
   → plus bas, « Réserver un appel » monte par-dessus la ville (la sphère devient un combiné) → le pied de page passe devant.
   Cartes : une carte pour les champs, des cartes séparées pour les boutons (comme les Réalisations de l'accueil).
   Formats : .f-stack (portrait), .f-side (côte à côte), .f-short (téléphone couché), .f-wide — voir responsive.css
   ===================================================================== */

/* ---------- la scène ---------- */
.ct-city { position: relative; height: 1000vh; background: var(--bg); }
@media (max-width: 900px) { .ct-city { height: 900vh; } }
html.f-short .ct-city { height: 860vh; }
.ct-city__stick { position: sticky; top: 0; height: 100vh; height: 100svh; overflow: hidden; }
.ct-city__gl { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.ct-city__veil { position: absolute; inset: 0; pointer-events: none; opacity: var(--veil, 0);
  background: linear-gradient(0deg, rgb(var(--bg-rgb) / .78) 0, rgb(var(--bg-rgb) / .35) 38%, transparent 60%); }
html.f-stack .ct-city__veil { background: linear-gradient(0deg, rgb(var(--bg-rgb) / .94) 0, rgb(var(--bg-rgb) / .65) 40%, transparent 64%); }

/* ouverture : le titre centré en haut ; la sphère (calque commun) se place dessous, au centre */
.ct-intro { position: absolute; z-index: 3; left: 50%; top: calc(var(--hd-h) + clamp(28px, 7svh, 90px)); transform: translate(-50%, calc(var(--io, 0) * -40px)); width: min(calc(1000px * var(--fs, 1)), calc(100% - 2 * var(--gutter))); text-align: center; opacity: calc(1 - var(--io, 0)); pointer-events: none; }
.ct-intro .eyebrow { margin-bottom: 16px; color: var(--action); }
.ct-intro__t { font-size: clamp(2.6rem, 1rem + 4.6vw, calc(6.2rem * var(--fs, 1))); font-weight: 650; line-height: .92; letter-spacing: -.05em; text-transform: uppercase; }
.ct-tl { display: block; }
.ct-intro__p { margin: 20px auto 0; max-width: 40ch; font-size: max(1rem, 15px); line-height: 1.45; color: rgb(var(--text-rgb) / .78); }
/* incitation au défilement : une simple ligne animée au centre */
.ct-scroll { position: absolute; z-index: 3; left: 50%; bottom: max(22px, calc(var(--sab, 0px) + 18px)); width: 1px; height: clamp(48px, 8svh, 80px); margin-left: -.5px; overflow: hidden; background: rgb(var(--text-rgb) / .16); opacity: calc(1 - var(--io, 0)); pointer-events: none; }
.ct-scroll i { position: absolute; left: 0; top: 0; width: 1px; height: 45%; background: linear-gradient(180deg, transparent, var(--action)); animation: ctLine 1.9s cubic-bezier(.65, 0, .35, 1) infinite; }
@keyframes ctLine { 0% { transform: translateY(-100%); } 100% { transform: translateY(240%); } }
html.f-stack .ct-scroll { bottom: calc(var(--dock-h) + 4px); }

/* ---------- cartes : champs d'un côté, boutons séparés de l'autre ---------- */
.ct-card { position: relative; border-radius: 26px; border: 1px solid rgb(var(--text-rgb) / .16);
  background: linear-gradient(160deg, rgb(var(--bg-rgb) / .9), rgb(var(--bg-rgb) / .76)); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  box-shadow: 0 40px 90px -30px rgb(0 0 0 / .65); padding: clamp(22px, 2.6vw, 38px); display: grid; gap: 16px; }

/* ---------- les étapes : centrées, larges, dans le bas de l'écran ---------- */
.ct-f { position: absolute; inset: 0; z-index: 4; pointer-events: none; }
.ct-q { position: absolute; left: 50%; bottom: max(7svh, calc(var(--ui-b, 30px) + 64px)); width: min(calc(1040px * var(--fs, 1)), calc(100% - 2 * var(--gutter)), 78vw);
  opacity: var(--a, 0); transform: translate(-50%, calc((1 - var(--a, 0)) * 30px)); visibility: hidden; }
.ct-q.is-on { visibility: visible; pointer-events: auto; }
.ct-q:not(.is-on) { transition: visibility 0s .2s; }
.ct-q__k { margin: 0; color: rgb(var(--text-rgb) / .62); }
.ct-q__k b { color: var(--action); font-weight: 800; margin-right: 2px; }
.ct-fld { display: grid; gap: 10px; }
.ct-fld > span, .ct-chips legend { font-size: clamp(1.25rem, .9rem + .9vw, calc(1.9rem * var(--fs, 1))); font-weight: 650; letter-spacing: -.025em; line-height: 1.1; color: var(--text); }
.ct-fld b { color: var(--action); }
.ct-in { width: 100%; min-height: 58px; padding: 14px 18px; border-radius: 14px; border: 1px solid rgb(var(--text-rgb) / .22); background: rgb(var(--text-rgb) / .05); color: var(--text); font: inherit; font-size: 17px; transition: border-color .25s, box-shadow .25s; }
textarea.ct-in { min-height: 130px; resize: vertical; line-height: 1.5; }
.ct-in::placeholder { color: rgb(var(--text-rgb) / .4); }
.ct-in:focus { outline: none; border-color: var(--action); box-shadow: 0 0 0 3px rgb(var(--acc-rgb) / .25); }
.ct-q.is-bad .ct-in { border-color: #ff6b5a; }
.ct-q__hint { margin: 0; color: rgb(var(--text-rgb) / .64); font-size: .9375rem; }
.ct-q__err { margin: 0; color: #ff8a7a; font-size: .9375rem; font-weight: 600; }
.ct-q__err:empty { display: none; }
.ct-q__need { margin: 0; color: rgb(var(--text-rgb) / .7); }
.ct-q__need:empty { display: none; }
.ct-jump { color: var(--action); text-decoration: underline; text-underline-offset: 3px; font: inherit; min-height: 32px; }
.ct-chips { border: 0; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.ct-chips legend { margin-bottom: 12px; padding: 0; float: left; width: 100%; }
.ct-chips label { position: relative; cursor: pointer; }
.ct-chips input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.ct-chips span { display: inline-flex; align-items: center; min-height: 44px; padding: 0 18px; border-radius: 999px; border: 1px solid rgb(var(--text-rgb) / .24); font-weight: 600; font-size: .9375rem; transition: background .25s, border-color .25s, color .25s; }
.ct-chips input:checked + span { background: var(--action); border-color: var(--action); color: var(--on-action); }
.ct-chips input:focus-visible + span { box-shadow: 0 0 0 3px rgb(var(--acc-rgb) / .35); }

/* repères sur la ville */
.ct-pins { position: absolute; inset: 0; z-index: 2; pointer-events: none; }
.ct-pin { position: absolute; left: 0; top: 0; padding: 6px 11px; border-radius: 999px; background: rgb(var(--bg-rgb) / .74); border: 1px solid rgb(var(--mint-rgb) / .45); color: rgb(var(--mint-rgb)); font-size: .75rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; white-space: nowrap; opacity: 0; transition: opacity .5s, border-color .4s, color .4s, background .4s; backdrop-filter: blur(6px); }
.ct-pin.is-on { border-color: #fff; color: #fff; }
.ct-pin.is-done { border-color: var(--action); color: var(--text); background: rgb(var(--acc-rgb) / .24); }
.ct-pin.is-done::after { content: " ✓"; color: var(--action); }

/* progression */
.ct-rail { position: absolute; z-index: 3; left: 50%; bottom: max(14px, calc(var(--ui-b, 30px) - 6px)); transform: translateX(-50%); width: min(240px, 40vw); height: 32px; display: flex; align-items: center; justify-content: space-between; opacity: var(--ro, 0); pointer-events: none; }
.ct-rail::before { content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 1px; background: rgb(var(--text-rgb) / .22); }
.ct-rail__fill { position: absolute; left: 0; top: 50%; height: 2px; margin-top: -.5px; width: 100%; background: var(--action); box-shadow: 0 0 10px var(--action); transform-origin: left; transform: scaleX(var(--rp, 0)); }
.ct-rail b { position: relative; width: 9px; height: 9px; border-radius: 50%; background: color-mix(in srgb, var(--text) 30%, var(--bg)); transition: background .3s, transform .3s, box-shadow .3s; }
.ct-rail b.is-cur { box-shadow: 0 0 0 4px rgb(var(--text-rgb) / .2); }
.ct-rail b.is-on { background: var(--action); transform: scale(1.3); }

/* confirmation */
.ct-done { position: absolute; z-index: 5; left: 50%; bottom: max(8svh, calc(var(--ui-b, 30px) + 40px)); width: min(640px, calc(100% - 2 * var(--gutter))); text-align: center; transform: translate(-50%, 24px); opacity: 0; transition: opacity .7s var(--ease), transform .7s var(--ease); }
.ct-done.is-on { opacity: 1; transform: translate(-50%, 0); }
.ct-done .ct-card { border-color: rgb(var(--acc-rgb) / .45); }
.ct-done .eyebrow { color: var(--action); margin: 0; }
.ct-done__t { font-size: clamp(2rem, 1rem + 2.4vw, calc(3.4rem * var(--fs, 1))); font-weight: 650; letter-spacing: -.04em; line-height: 1; margin: 0; }
.ct-done__p { color: rgb(var(--text-rgb) / .82); line-height: 1.55; margin: 0 auto; max-width: 46ch; }
.ct-done__p a { color: var(--action); font-weight: 700; }

/* ---------- réserver un appel : la section monte par-dessus la ville ---------- */
.ct-res { position: relative; z-index: 5; margin-top: -100svh; padding-bottom: 100svh;
  background: linear-gradient(180deg, rgb(var(--bg-rgb) / 0) 0, rgb(var(--bg-rgb) / .7) 55svh, var(--bg) 100svh); }
.ct-res__phone { width: clamp(150px, 30svh, 300px); aspect-ratio: 1; flex: none; }
.ct-res__head { text-align: center; margin: 0 0 clamp(18px, 3svh, 30px); }
.ct-res__head .eyebrow { color: var(--action); margin-bottom: 10px; }
.ct-res__t { font-size: clamp(2rem, 1rem + 2.6vw, calc(3.8rem * var(--fs, 1))); font-weight: 650; letter-spacing: -.045em; line-height: 1; text-transform: uppercase; }
.ct-res__grid { width: min(calc(1040px * var(--fs, 1)), 100%); display: grid; grid-template-columns: 1.4fr 1fr; gap: clamp(12px, 1.6vw, 22px); align-items: start; }
.ct-res__acts { grid-column: 1 / -1; }
.ct-res__ok { grid-column: 1 / -1; text-align: center; line-height: 1.55; color: rgb(var(--text-rgb) / .85); }
.ct-res__okt { font-size: clamp(1.6rem, 1rem + 1.4vw, 2.4rem); font-weight: 650; color: var(--text); margin: 0 0 6px; }
.ct-days { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 6px; scroll-snap-type: x mandatory; scrollbar-width: thin; }
.ct-day { flex: none; scroll-snap-align: start; display: grid; justify-items: center; gap: 2px; min-width: 76px; padding: 10px 8px; border-radius: 14px; border: 1px solid rgb(var(--text-rgb) / .2); color: var(--text); transition: background .2s, border-color .2s; }
.ct-day span { color: rgb(var(--text-rgb) / .6); }
.ct-day b { font-size: .9375rem; }
.ct-day.is-on { background: var(--action); border-color: var(--action); color: var(--on-action); }
.ct-day.is-on span { color: inherit; }
.ct-slots { display: grid; grid-template-columns: repeat(auto-fill, minmax(84px, 1fr)); gap: 8px; }
.ct-slots__hint { grid-column: 1 / -1; margin: 4px 0; color: rgb(var(--text-rgb) / .55); }
.ct-slot { min-height: 44px; border-radius: 12px; border: 1px solid rgb(var(--text-rgb) / .2); color: var(--text); font-weight: 700; font-variant-numeric: tabular-nums; transition: background .2s, border-color .2s; }
.ct-slot:hover, .ct-day:hover { border-color: rgb(var(--acc-rgb) / .7); }
.ct-slot.is-on { background: var(--action); border-color: var(--action); color: var(--on-action); }
.ct-res__who .ct-fld > span { font-size: 1.05rem; }

/* ---------- portrait (téléphone, tablette debout) ---------- */
html.f-stack .ct-intro__t { font-size: clamp(2.4rem, 11vw, 5.6rem); }
html.f-stack .ct-q { width: auto; left: var(--gutter); right: var(--gutter); transform: translateY(calc((1 - var(--a, 0)) * 24px)); bottom: calc(max(var(--dock-h) + 30px, var(--kb, 0px) + 10px)); }
html.f-stack:not(.f-phone) .ct-q { left: 50%; right: auto; width: min(680px, calc(100% - 2 * var(--gutter))); transform: translate(-50%, calc((1 - var(--a, 0)) * 24px)); }
html.f-stack .ct-card { padding: 20px 18px; border-radius: 22px; gap: 14px; }
html.f-stack .ct-fld > span, html.f-stack .ct-chips legend { font-size: 1.15rem; }
html.f-stack textarea.ct-in { min-height: 100px; }
html.f-stack .ct-rail { left: var(--gutter); transform: none; width: min(200px, calc(100% - 2 * var(--gutter) - 80px)); bottom: calc(var(--dock-b) + var(--chat) / 2 - 16px); }
html.f-stack .ct-done { bottom: calc(var(--dock-h) + 16px); }
html.f-stack .ct-res__grid { grid-template-columns: 1fr; }
html.f-stack .ct-res__phone { width: clamp(120px, 22svh, 220px); }
@media (max-height: 720px) { html.f-stack .ct-q__hint { display: none; } html.f-stack .ct-chips span { min-height: 38px; padding: 0 13px; font-size: .875rem; } }
/* téléphone couché */
html.f-short .ct-intro { top: 54px; }
html.f-short .ct-intro__t { font-size: clamp(1.5rem, 9vh, 2.4rem); }
html.f-short .ct-intro__p { margin-top: 8px; font-size: .875rem; }
html.f-short .ct-q { bottom: 10px; width: min(760px, calc(100% - 2 * var(--gutter) - 70px)); }
html.f-short .ct-card { padding: 12px 16px; gap: 8px; border-radius: 18px; }
html.f-short .ct-fld > span, html.f-short .ct-chips legend { font-size: 1rem; }
html.f-short .ct-in { min-height: 44px; padding: 10px 14px; }
html.f-short textarea.ct-in { min-height: 56px; }
html.f-short .ct-q__hint { display: none; }
html.f-short .ct-chips span { min-height: 34px; padding: 0 11px; font-size: .8125rem; }
html.f-short .ct-chips legend { margin-bottom: 6px; }
html.f-short .ct-rail { display: none; }
html.f-short .ct-done { bottom: 12px; }
html.f-short .ct-res__phone { width: 90px; }
html.f-short .ct-res__t { font-size: 1.6rem; }

/* ---------- pied de page : il passe par-dessus la réservation ---------- */
.ct-page .ft { margin-top: -100svh; z-index: 6; padding-top: 70px; border-radius: clamp(22px, 3vw, 40px) clamp(22px, 3vw, 40px) 0 0; box-shadow: 0 -40px 90px -20px rgb(0 0 0 / .5); min-height: 100svh; display: flex; flex-direction: column; justify-content: flex-end; }
.ct-page .ft[data-tone], html.f-stack .ct-page .ft[data-tone], html.f-short .ct-page .ft[data-tone] { padding-top: 70px; }
.ct-page .ft::before { content: ""; position: absolute; left: 50%; top: 14px; width: 54px; height: 4px; margin-left: -27px; border-radius: 4px; background: rgb(var(--text-rgb) / .22); z-index: 1; }
