:root {
  --violet: #8447FF;
  --violet-fonce: #6F35E5;
  --violet-doux: rgba(132, 71, 255, 0.10);
  --noir: #0A0A0A;
  --texte: #1A1A1A;
  --gris: #52525B;
  --gris-clair: #A1A1AA;
  --ligne: #E4E4E7;
  --fond: #F4F4F5;
  --surface: #FFFFFF;
  --champ: #FAFAFA;
  --rouge: #DC2626;
  --rayon: 10px;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 32px 16px;
  background: var(--fond);
  color: var(--texte);
  font: 15px/1.55 'Geist', -apple-system, BlinkMacSystemFont, 'Helvetica Neue', sans-serif;
  -webkit-font-smoothing: antialiased;
}

[hidden] { display: none !important; }

.carte {
  width: 100%;
  max-width: 1040px;
  background: var(--surface);
  border: 1px solid var(--ligne);
  border-radius: 16px;
  box-shadow: 0 1px 2px rgba(0,0,0,.04), 0 12px 32px rgba(0,0,0,.05);
  overflow: hidden;
}

/* Étapes */
.etapes {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: 16px;
  border-bottom: 1px solid var(--ligne);
  font-size: 13px;
  color: var(--gris-clair);
}
.etape { display: flex; align-items: center; gap: 8px; }
.etape i { width: 16px; height: 16px; border-radius: 50%; background: var(--ligne); }
.etape.active { color: var(--texte); font-weight: 500; }
.etape.active i { background: var(--noir); }
.etape.faite i { background: var(--violet); }
.trait { width: 64px; height: 1px; background: var(--ligne); }

.colonnes { display: grid; grid-template-columns: 1fr 1fr; }
.gauche { padding: 40px; border-right: 1px solid var(--ligne); }
.droite { position: relative; padding: 40px; }

/* Colonne gauche */
.marque { margin: 0 0 6px; font-size: 13px; font-weight: 600; color: var(--violet); letter-spacing: .02em; }
h1 { margin: 0 0 6px; font-size: 26px; line-height: 1.2; font-weight: 600; letter-spacing: -.01em; }
.infos { margin: 0 0 20px; color: var(--gris); font-size: 14px; }
.description p { margin: 0 0 10px; color: var(--gris); }
.description { margin-bottom: 24px; }

label { display: block; margin: 16px 0 6px; font-size: 14px; font-weight: 500; }
label b { color: var(--rouge); font-weight: 500; }
input, select {
  width: 100%;
  height: 44px;
  padding: 0 12px;
  border: 1px solid var(--ligne);
  border-radius: 8px;
  background: var(--champ);
  color: var(--texte);
  font: inherit;
}
input::placeholder { color: var(--gris-clair); }
input:focus, select:focus { outline: none; border-color: var(--violet); box-shadow: 0 0 0 3px var(--violet-doux); background: var(--surface); }
input.invalide { border-color: var(--rouge); }
.tel { display: flex; }
.tel select { width: 108px; flex: none; border-radius: 8px 0 0 8px; border-right: 0; cursor: pointer; }
.tel input { border-radius: 0 8px 8px 0; }
.deux { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.cache { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }

button { font: inherit; cursor: pointer; }
#continuer {
  width: 100%;
  height: 46px;
  margin-top: 24px;
  border: 0;
  border-radius: 8px;
  background: var(--noir);
  color: #FAFAFA;
  font-weight: 600;
  transition: background .15s, opacity .15s;
}
#continuer:hover:not(:disabled) { background: #262626; }
#continuer:disabled { opacity: .35; cursor: not-allowed; }
.mention { margin: 16px 0 0; font-size: 12px; line-height: 1.5; color: var(--gris); text-align: center; }
.mention a, .petit a { color: inherit; }
.erreur { margin: 12px 0 0; min-height: 0; color: var(--rouge); font-size: 13px; }
.erreur:empty { display: none; }

.resume { margin-top: 8px; padding: 16px; border: 1px solid var(--ligne); border-radius: var(--rayon); background: var(--champ); }
.qui { margin: 0 0 6px; font-size: 14px; }
.lien { padding: 0; border: 0; background: none; color: var(--violet); font-size: 13px; text-decoration: underline; }

/* Calendrier */
.mois { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.mois h2 { margin: 0; font-size: 15px; font-weight: 600; }
.fleche { width: 32px; height: 32px; border: 1px solid var(--ligne); border-radius: 8px; background: var(--surface); color: var(--texte); font-size: 18px; line-height: 1; }
.fleche:disabled { opacity: .3; cursor: default; }
.grille { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.entete { margin-bottom: 6px; }
.entete span { text-align: center; font-size: 11px; font-weight: 500; color: var(--gris-clair); }
.jour {
  aspect-ratio: 1;
  max-height: 48px;
  border: 0;
  border-radius: 8px;
  background: none;
  color: var(--gris-clair);
  font-size: 14px;
}
.jour.dispo { background: var(--violet-doux); color: var(--violet-fonce); font-weight: 600; }
.jour.dispo:hover { background: rgba(132, 71, 255, .18); }
.jour.choisi { background: var(--violet); color: #fff; }
.jour:disabled { cursor: default; }
.fuseau { margin: 14px 0 0; font-size: 12px; color: var(--gris-clair); }

.heures { margin-top: 20px; padding-top: 20px; border-top: 1px solid var(--ligne); }
.heures h3 { margin: 0 0 12px; font-size: 14px; font-weight: 600; }
.liste { display: grid; grid-template-columns: repeat(auto-fill, minmax(88px, 1fr)); gap: 8px; }
.heure {
  height: 42px;
  border: 1px solid var(--violet);
  border-radius: 8px;
  background: var(--surface);
  color: var(--violet-fonce);
  font-weight: 600;
}
.heure:hover { background: var(--violet-doux); }
.heure.choisie { background: var(--noir); border-color: var(--noir); color: #fff; }
.confirmer { grid-column: 1 / -1; height: 46px; border: 0; border-radius: 8px; background: var(--violet); color: #fff; font-weight: 600; }
.confirmer:hover { background: var(--violet-fonce); }
.confirmer:disabled { opacity: .6; cursor: wait; }
.vide { color: var(--gris); font-size: 14px; }

.voile {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(255,255,255,.55);
  backdrop-filter: blur(1px);
}
.voile p {
  margin: 0;
  max-width: 280px;
  padding: 16px 20px;
  border: 1px solid var(--ligne);
  border-radius: 12px;
  background: var(--surface);
  box-shadow: 0 8px 24px rgba(0,0,0,.08);
  font-size: 14px;
  text-align: center;
}
.droite:not(.verrouille) .voile { display: none; }
.verrouille .grille, .verrouille .mois { opacity: .45; }

/* Confirmation */
.fin { max-width: 520px; padding: 48px 40px; text-align: center; }
.fin p { color: var(--gris); }
.coche { width: 56px; height: 56px; margin: 0 auto 20px; display: grid; place-items: center; border-radius: 50%; background: var(--violet-doux); color: var(--violet); font-size: 26px; font-weight: 700; }
.quand { font-size: 17px; font-weight: 600; color: var(--texte) !important; }
.petit { font-size: 13px; }

@media (max-width: 820px) {
  body { padding: 0; align-items: stretch; }
  .carte { border-radius: 0; border: 0; box-shadow: none; }
  .colonnes { grid-template-columns: 1fr; }
  .gauche { padding: 28px 16px; border-right: 0; border-bottom: 1px solid var(--ligne); }
  .droite { padding: 28px 16px 40px; }
  .droite.verrouille { display: none; }
  .etapes { gap: 10px; }
  .trait { width: 28px; }
  .fin { padding: 48px 16px; }
}
