/**
 * Configurateur — styles des composants pilotés par JS (états active/done/error).
 * Le reste de la page utilise les utilitaires Tailwind. Palette alignée sur @theme (head.php).
 */

:root {
  --cfg-cream: #fffdf8;
  --cfg-ink: #010206;
  --cfg-ink-soft: #333332;
  --cfg-body: #474747;
  --cfg-amber: #ffc247;
  --cfg-amber-dark: #f0ad2a;
  --cfg-line: #bfbeba;
  --cfg-ok: #1b5e20;
  --cfg-warn: #8a4b00;
  --cfg-err: #b91c1c;
}

/* ── Fil d'étapes ────────────────────────────────────────────── */
.stepper { display: flex; gap: 0; }
.step-item { display: flex; align-items: center; gap: 10px; flex: 1; }
.step-item:last-child { flex: 0 0 auto; }
.step-circle {
  width: 32px; height: 32px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 500;
  color: rgba(255, 255, 255, .6);
  border: 1px solid rgba(255, 255, 255, .28);
  transition: all .25s ease;
}
.step-circle.active { background: var(--cfg-amber); border-color: var(--cfg-amber); color: #000; }
.step-circle.done { background: rgba(255, 255, 255, .9); border-color: transparent; color: #000; }
.step-lbl {
  font-size: 12px; font-weight: 500; letter-spacing: .14em; text-transform: uppercase;
  white-space: nowrap; color: rgba(255, 255, 255, .6); transition: color .25s ease;
}
.step-item.active .step-lbl { color: #fff; }
.step-item.done .step-lbl { color: rgba(255, 255, 255, .65); }
.step-line { flex: 1; height: 1px; background: rgba(255, 255, 255, .15); margin: 0 12px; }
.step-item.done .step-line { background: rgba(255, 255, 255, .4); }
@media (max-width: 640px) {
  .step-lbl { display: none; }
  .step-item { flex: 1; }
}

/* ── Panneaux d'étape ────────────────────────────────────────── */
.panel { display: none; }
.panel.active { display: block; }

/* ── Groupe de configuration ─────────────────────────────────── */
/* Même traitement que les groupes du simulateur monte-charges : pas de cadre ni
   de bandeau, un simple intitulé discret qui sépare les blocs de champs. */
.config-card { background: none; box-shadow: none; }
/* Intitulé + filet qui court jusqu'au bord : la colonne est longue, les groupes ont
   besoin d'une césure plus lisible que le simple libellé du monte-charges. */
.config-head {
  display: flex; align-items: center; gap: 12px;
  margin-bottom: 18px;
  font-size: 12px; font-weight: 500; letter-spacing: .16em; text-transform: uppercase;
  color: var(--cfg-ink);
}
.config-head::after {
  content: ''; flex: 1; height: 1px; min-width: 20px;
  background: rgba(0, 0, 0, .13);
}
.c-num {
  flex-shrink: 0; padding: 3px 8px; letter-spacing: .1em;
  background: var(--cfg-amber); color: #000;
}
.config-body { padding: 0; }

.field-label {
  font-size: 12px; font-weight: 500; letter-spacing: .16em; text-transform: uppercase;
  color: rgba(0, 0, 0, .62); margin-bottom: 10px;
}
.hint { font-size: 13px; line-height: 1.5; color: rgba(0, 0, 0, .62); }

/* ── Dimensions de gaine ─────────────────────────────────────── */
.gaine-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
@media (max-width: 640px) { .gaine-grid { grid-template-columns: 1fr; } }
.dim-wrap {
  display: flex; align-items: stretch;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .15);
  background: var(--cfg-cream);
  transition: box-shadow .2s ease;
}
.dim-wrap:focus-within { box-shadow: inset 0 0 0 2px var(--cfg-ink); }
.dim-wrap input {
  flex: 1; min-width: 0; width: 100%;
  border: none; background: transparent; outline: none;
  font: inherit; font-size: 17px; font-weight: 500; letter-spacing: -.01em;
  color: var(--cfg-ink); padding: 9px 14px;
  -moz-appearance: textfield;
}
.dim-wrap input::-webkit-outer-spin-button, .dim-wrap input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.dim-wrap .unit {
  display: flex; align-items: center; flex-shrink: 0;
  background: var(--cfg-amber); color: #000; padding: 0 12px;
  font-size: 11px; font-weight: 500; letter-spacing: .1em; text-transform: uppercase;
}
.dim-slider { width: 100%; accent-color: var(--cfg-amber); margin-top: 8px; }

/* Bascule à 2 ou 3 options : même liseré que les boutons de charge, en plein
   largeur pour que les libellés longs ne soient pas coupés. */
.toggle-group { display: flex; flex-wrap: wrap; gap: 8px; }
.toggle-opt {
  flex: 1 1 0; min-width: 0; padding: 10px 12px; cursor: pointer;
  background: #fff; color: var(--cfg-body); font: inherit; font-size: 14px;
  font-weight: 500; line-height: 1.35; text-align: center; border: 0;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .15);
  transition: box-shadow .15s ease, color .15s ease;
}
.toggle-opt:hover { box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .5); }
.toggle-opt.active { color: var(--cfg-ink); box-shadow: inset 0 0 0 2px var(--cfg-amber); }
/* Options portant une icône : contenu aligné à gauche plutôt que centré. */
.toggle-opt:has(> svg) {
  display: flex; align-items: center; gap: 12px; text-align: left;
  padding: 15px 20px;
}
/* Seconde ligne : la motorisation associée à l'option. */
.toggle-opt small {
  display: block; margin-top: 3px;
  font-size: 11.5px; font-weight: 400; color: rgba(0, 0, 0, .62);
}
.toggle-opt.active small { color: rgba(0, 0, 0, .6); }

/* Emplacement machine : le schéma isométrique se lit plus vite que le libellé,
   il passe donc devant, texte aligné à gauche à côté. */
.mode-opt {
  display: flex; align-items: center; gap: 16px;
  padding: 14px 18px; text-align: left;
}
.mode-opt img { height: 112px; width: auto; flex-shrink: 0; }
.mode-opt strong { display: block; font-weight: 500; }
.mode-opt small { margin-top: 4px; }

/* Accès : trois options à schéma carré. Empilé plutôt qu'en ligne, sinon le
   libellé se coupe sur deux lignes à côté du dessin. */
.acces-opt {
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  padding: 14px 12px 12px;
}
.acces-opt img { height: 104px; width: auto; }
.acces-opt strong { font-weight: 500; }

/* Niveaux, hauteur entre niveaux et course sur une seule ligne. */
.niveaux-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
@media (max-width: 860px) { .niveaux-grid { grid-template-columns: 1fr; } }

/* Champ calculé : lisible mais visiblement non saisissable. */
.dim-wrap.is-auto { background: rgba(0, 0, 0, .025); box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .1); }
.dim-wrap.is-auto input { color: rgba(0, 0, 0, .55); cursor: default; }
.dim-wrap.is-auto .unit { background: rgba(0, 0, 0, .08); color: rgba(0, 0, 0, .62); }
.field-auto {
  margin-left: 6px; padding: 2px 6px;
  background: rgba(0, 0, 0, .06); color: rgba(0, 0, 0, .62);
  font-size: 10px; letter-spacing: .08em;
}

.gaine-result { margin-top: 20px; padding: 14px 16px; font-size: 14px; line-height: 1.55; }
.gaine-result:empty { display: none; }
.gaine-ok { background: rgba(255, 194, 71, .12); box-shadow: inset 0 0 0 1px rgba(255, 194, 71, .55); color: var(--cfg-ink-soft); }
.gaine-warn { background: rgba(185, 28, 28, .06); box-shadow: inset 0 0 0 1px rgba(185, 28, 28, .3); color: var(--cfg-err); }
.gaine-charge-badge {
  display: inline-block; margin-left: 6px; padding: 3px 12px;
  background: #fff; color: var(--cfg-ink);
  box-shadow: inset 0 0 0 1px rgba(255, 194, 71, .8);
  font-size: 13px; font-weight: 500;
}

/* ── Charge nominale ─────────────────────────────────────────── */
/* Les charges occupent toute la largeur, à parts égales. `auto-fit` plutôt
   qu'un nombre figé de colonnes : les cinq tiennent sur une ligne tant que la
   place le permet, et la grille se replie d'elle-même quand la colonne de
   configuration se resserre — sans jamais écraser les libellés. */
.charge-grid {
  display: grid; gap: 10px;
  grid-template-columns: repeat(auto-fit, minmax(104px, 1fr));
}
.charge-btn {
  padding: 15px 12px; cursor: pointer; background: #fff; color: var(--cfg-body);
  border: 0; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .15);
  font: inherit; font-size: 14px; font-weight: 500; line-height: 1.35; text-align: center;
  white-space: nowrap;   /* « 1 000 kg » ne doit pas se couper */
  transition: all .15s ease;
}
.toggle-opt > svg { color: rgba(0, 0, 0, .3); transition: color .15s ease; }
.toggle-opt.active > svg { color: var(--cfg-amber-dark); }
.charge-btn small { display: block; font-size: 11px; font-weight: 400; color: rgba(0, 0, 0, .62); }
.charge-btn:hover { box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .5); }
.charge-btn.active { color: var(--cfg-ink); box-shadow: inset 0 0 0 2px var(--cfg-amber); }

/* ── Fournisseur de la signalisation ─────────────────────────── */
/* Deux cartes larges : le choix ouvre la configuration, il doit primer
   visuellement sur les grilles de finitions qui suivent. */
.brand-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
@media (max-width: 560px) { .brand-grid { grid-template-columns: 1fr; } }
/* Le logo tient lieu de libellé : la carte se réduit à lui et au drapeau du
   pays de fabrication, posé dans l'angle. */
.brand-card {
  position: relative; cursor: pointer; background: #fff;
  display: flex; flex-direction: column; align-items: center; gap: 18px;
  padding: 24px 22px 20px;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .12);
  transition: box-shadow .2s ease;
}
.brand-card:hover { box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .45); }
.brand-card.active { box-shadow: inset 0 0 0 2px var(--cfg-amber); }
/* Logos de hauteurs et de ratios très différents : on borne les deux axes pour
   qu'aucun ne domine l'autre dans la rangée. */
.brand-logo {
  height: 34px; width: auto; max-width: 170px; object-fit: contain;
  filter: grayscale(1); opacity: .55; transition: filter .2s ease, opacity .2s ease;
}
.brand-card:hover .brand-logo, .brand-card.active .brand-logo { filter: none; opacity: 1; }
/* L'armoire livrée avec le fournisseur : seconde différence entre les deux
   gammes, montrée dès le choix plutôt que découverte dans le PDF. */
.brand-armoire {
  display: flex; align-items: center; gap: 12px; width: 100%;
  margin-top: auto; padding-top: 16px; text-align: left;
  border-top: 1px solid rgba(0, 0, 0, .1);
}
.brand-armoire img {
  height: 46px; width: 46px; flex-shrink: 0; object-fit: contain;
  background: var(--cfg-cream);
}
.brand-armoire-nm {
  font-size: 13px; font-weight: 500; color: var(--cfg-ink); margin-bottom: 2px;
}
.brand-armoire-sub { font-size: 12px; line-height: 1.4; color: rgba(0, 0, 0, .62); }

/* ── Finitions cabine ────────────────────────────────────────── */
/* 4 colonnes fixes — les cases vides de la dernière ligne sont assumées. */
.cabin-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
@media (max-width: 640px) { .cabin-grid { grid-template-columns: repeat(2, 1fr); } }
.cabin-card { position: relative; cursor: pointer; overflow: hidden; background: #fff; }
/* Le liseré est porté par un calque au-dessus : posé sur la carte, la photo opaque
   le recouvrirait et il ne resterait visible que le long du libellé. */
.cabin-card::after {
  content: ''; position: absolute; inset: 0; z-index: 1; pointer-events: none;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .12);
  transition: box-shadow .2s ease;
}
.cabin-card:hover::after { box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .45); }
.cabin-card.active::after { box-shadow: inset 0 0 0 2px var(--cfg-amber); }
/* Nom sous la photo, sans bandeau : c'est le liseré ambre de la carte qui porte
   l'état sélectionné, comme sur les cartes du simulateur monte-charges. */
.cabin-head {
  padding: 10px 10px 2px; text-align: center; color: var(--cfg-ink);
  font-size: 12px; font-weight: 500; letter-spacing: .12em; text-transform: uppercase;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
/* Visuels natifs en 901 × 1746 : trop hauts pour une grille de 4 colonnes, on les
   recadre au centre sur un format plus compact — parois, plafond et sol restent visibles. */
.cabin-img { aspect-ratio: 901 / 1450; overflow: hidden; background: #fbfaf8; }
.cabin-img img {
  display: block; width: 100%; height: 100%;
  object-fit: cover; object-position: center;
  transition: transform .5s ease;
}
.cabin-card:hover .cabin-img img { transform: scale(1.04); }
.cabin-specs {
  padding: 0 10px 12px; text-align: center;
  font-size: 11.5px; line-height: 1.35; color: rgba(0, 0, 0, .62);
  min-height: 2.7em; /* colonnes étroites : le libellé passe sur 2 lignes */
}

/* ── Portes & signalisation ──────────────────────────────────── */
.opt-photo-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
@media (max-width: 640px) { .opt-photo-grid { grid-template-columns: repeat(2, 1fr); } }
.opt-photo-btn { position: relative; cursor: pointer; overflow: hidden; background: #fff; }
/* Idem cartes cabine : liseré au-dessus de la photo. */
.opt-photo-btn::after {
  content: ''; position: absolute; inset: 0; z-index: 1; pointer-events: none;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .12);
  transition: box-shadow .2s ease;
}
.opt-photo-btn:hover::after { box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .45); }
.opt-photo-btn.active::after { box-shadow: inset 0 0 0 2px var(--cfg-amber); }
.op-img-door { aspect-ratio: 320 / 495; overflow: hidden; background: #fbfaf8; }
.op-img-sig { aspect-ratio: 443 / 1028; overflow: hidden; background: #fff; padding: 14px 18px 8px; }
.op-img-door img, .op-img-sig img { width: 100%; height: 100%; object-fit: contain; transition: transform .5s ease; }
/* Pas de zoom sur les boîtes à boutons : ce sont des fiches gamme, l'agrandissement
   rogne les bulles de légende contre le bord du cadre. */
.opt-photo-btn:hover .op-img-door img { transform: scale(1.04); }
.op-label { padding: 12px 12px 2px; text-align: center; font-size: 15px; font-weight: 500; color: var(--cfg-ink); }
.op-sub { padding: 0 12px 12px; text-align: center; font-size: 13px; color: rgba(0, 0, 0, .62); }

/* ── Étape 1 : configuration + aperçu ────────────────────────── */
.cfg-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 500px;
  gap: 28px;
  align-items: start;
}
.cfg-main { display: flex; flex-direction: column; gap: 32px; min-width: 0; }
.viz-col { position: sticky; top: 20px; }
@media (max-width: 1023px) {
  .cfg-layout { grid-template-columns: 1fr; }
  .viz-col { position: static; order: -1; }
}

/* ── Aperçu en direct ────────────────────────────────────────── */
.viz { background: #fff; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .1); }
.viz-head {
  display: flex; align-items: center; gap: 10px;
  background: var(--cfg-ink); color: #fff; padding: 9px 16px;
  font-size: 11px; font-weight: 500; letter-spacing: .16em; text-transform: uppercase;
}
/* Deux colonnes : photo + vignettes à gauche, récapitulatif chiffré à droite.
   Le panneau est sticky, la hauteur prime sur la taille de la photo. */
.viz-body {
  padding: 14px 16px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 138px;
  gap: 12px 14px;
  align-items: start;
}

/* Scène : photo cabine + cotes. */
.viz-stage { grid-column: 1; grid-row: 1; display: flex; flex-direction: column; gap: 6px; }
/* Colonne de droite : récapitulatif puis vignettes, empilés. */
.viz-side { grid-column: 2; grid-row: 1; display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.viz-meas-top { display: flex; align-items: center; gap: 8px; padding-right: 30px; }
.viz-meas-top .ml { flex: 1; height: 1px; background: rgba(0, 0, 0, .28); position: relative; }
.viz-meas-top .ml::before {
  content: ''; position: absolute; top: -3px; width: 7px; height: 7px;
  border-left: 1px solid rgba(0, 0, 0, .28); border-bottom: 1px solid rgba(0, 0, 0, .28);
  transform: rotate(45deg);
}
.viz-meas-top .ml:first-child::before { left: 0; }
.viz-meas-top .ml:last-child::before { right: 0; transform: rotate(-135deg); }
.viz-meas-lbl {
  font-size: 11px; font-weight: 500; letter-spacing: .1em; text-transform: uppercase;
  color: rgba(0, 0, 0, .62); white-space: nowrap;
}
.viz-row { display: flex; align-items: stretch; gap: 8px; }
.viz-meas-right {
  width: 22px; flex-shrink: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: flex-end;
  gap: 8px; padding: 4px 0;
}
/* Cote PG : sur la moitié basse de la photo, pas sur toute la hauteur. */
.viz-meas-right .ml { flex: 0 0 auto; height: 11%; width: 1px; background: rgba(0, 0, 0, .28); position: relative; }
.viz-meas-right .ml::before {
  content: ''; position: absolute; left: -3px; width: 7px; height: 7px;
  border-left: 1px solid rgba(0, 0, 0, .28); border-bottom: 1px solid rgba(0, 0, 0, .28);
  transform: rotate(135deg);
}
.viz-meas-right .ml:first-child::before { top: 0; }
.viz-meas-right .ml:last-child::before { bottom: 0; transform: rotate(-45deg); }
.viz-meas-right .viz-meas-lbl { writing-mode: vertical-rl; }

/* Cadre plus court que les visuels natifs (901 × 1746) : plafond et sol sont rognés
   pour contenir la hauteur du panneau. Le recadrage 901 × 1500 laisse la colonne
   Sensy — le plus haut des calques boutons — entièrement visible. */
.viz-frame { position: relative; flex: 1; min-width: 0; aspect-ratio: 901 / 1500; overflow: hidden; background: #fbfaf8; }
/* Cabine et boîte à boutons partagent le cadrage source : même recadrage, donc
   superposition alignée. */
.viz-cabin, .viz-cop { display: block; width: 100%; height: 100%; object-fit: cover; object-position: center; }
.viz-cop { position: absolute; inset: 0; transition: opacity .2s ease; }
.viz-tag {
  position: absolute; left: 0; bottom: 0;
  background: var(--cfg-ink); color: #fff; padding: 6px 12px;
  font-size: 11px; font-weight: 500; letter-spacing: .14em; text-transform: uppercase;
}
.viz-tag em { font-style: normal; color: var(--cfg-amber); }

/* Vignettes porte + signalisation — colonne de droite, sous le récapitulatif.
   Colonne étroite : elles s'empilent au lieu de se mettre côte à côte. */
.viz-thumbs { display: grid; grid-template-columns: 1fr; gap: 8px; }
.viz-thumb { display: flex; align-items: center; gap: 7px; background: var(--cfg-cream); padding: 6px 7px; }
.viz-thumb img {
  width: 26px; height: 32px; flex-shrink: 0; object-fit: contain; background: #fff;
}
.viz-thumb div { min-width: 0; }
.viz-tl { font-size: 10px; letter-spacing: .12em; text-transform: uppercase; color: rgba(0, 0, 0, .62); }
.viz-tv {
  font-size: 13px; font-weight: 500; color: var(--cfg-ink);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}

/* Récapitulatif chiffré — colonne de droite, au-dessus des vignettes */
.viz-specs { display: grid; grid-template-columns: 1fr; }
.viz-spec { padding: 6px 0; border-bottom: 1px solid rgba(0, 0, 0, .07); }
.viz-spec:first-child { padding-top: 0; }
/* Course et vitesse tiennent sur une ligne à deux colonnes : deux valeurs
   courtes, une ligne gagnée dans une colonne déjà longue. */
.viz-spec-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 0 12px; }

.viz-sl { display: block; font-size: 11px; line-height: 1.3; color: rgba(0, 0, 0, .62); }
.viz-sv { display: block; font-size: 13px; line-height: 1.35; font-weight: 500; color: var(--cfg-ink); }
/* Bandeau horizontal sous la photo : une colonne par information, sur toute
   la largeur du panneau. Le nombre de colonnes suit le nombre d'entrées. */
.viz-specs-wide {
  grid-column: 1 / -1;
  display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 0 16px;
  padding-top: 10px; border-top: 1px solid rgba(0, 0, 0, .1);
}
.viz-specs-wide .viz-spec { padding: 0; border-bottom: 0; }
@media (max-width: 640px) {
  .viz-specs-wide { grid-auto-flow: row; grid-template-columns: 1fr 1fr; gap: 8px 14px; margin-top: 10px; }
}

.viz-warn { grid-column: 1 / -1; padding: 9px 11px; font-size: 12px; line-height: 1.45; background: rgba(185, 28, 28, .06); box-shadow: inset 0 0 0 1px rgba(185, 28, 28, .3); color: var(--cfg-err); }
.viz-warn:empty { display: none; }

/* Sous 1024 px l'aperçu passe au-dessus de la configuration et occupe toute la
   largeur : le récapitulatif peut respirer. */
@media (max-width: 1023px) {
  /* Colonne photo bornée : à pleine largeur elle deviendrait démesurée. */
  .viz-body { grid-template-columns: 268px minmax(0, 1fr); gap: 18px; }
  .viz-specs { grid-template-columns: 1fr 1fr; gap: 0 14px; }
  .viz-thumbs { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 640px) {
  .viz-body { display: block; }
  .viz-stage { max-width: 260px; margin: 0 auto; }
  .viz-thumbs { margin-top: 10px; }
  .viz-specs { grid-template-columns: 1fr 1fr; gap: 0 14px; margin-top: 12px; border-top: 1px solid rgba(0, 0, 0, .1); }
  .viz-warn { margin-top: 10px; }
}

/* Pied de l'aperçu — même traitement que le simulateur monte-charges : un seul
   bouton pleine largeur, pas de bandeau. */
.viz-cta { padding: 0 16px 16px; }
.viz-cta .btn-kmy { width: 100%; justify-content: center; }

/* ── Formulaire ──────────────────────────────────────────────── */
.form-group label {
  display: block; margin-bottom: 8px;
  font-size: 13px; font-weight: 500; letter-spacing: .06em; text-transform: uppercase;
  color: rgba(0, 0, 0, .55);
}
.form-group input, .form-group select, .form-group textarea {
  width: 100%; padding: 12px 16px; background: #fff; color: var(--cfg-ink);
  font: inherit; font-size: 15px; outline: none;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .15);
  transition: box-shadow .2s ease;
}
.form-group input::placeholder, .form-group textarea::placeholder { color: rgba(0, 0, 0, .62); }
.form-group textarea { resize: vertical; min-height: 96px; font: inherit; }
.form-group input:focus, .form-group select:focus { box-shadow: inset 0 0 0 2px var(--cfg-ink); }
.form-group input.error, .form-group select.error { box-shadow: inset 0 0 0 2px var(--cfg-err); }
.opt-label { font-weight: 400; letter-spacing: normal; text-transform: none; color: rgba(0, 0, 0, .62); }
.req { color: var(--cfg-err); margin-left: 2px; }

/* ── Récapitulatif ───────────────────────────────────────────── */
.recap-card { background: #fff; padding: 32px; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .1); }
.recap-sect { padding-bottom: 24px; margin-bottom: 24px; border-bottom: 1px solid rgba(0, 0, 0, .1); }
.recap-sect:last-of-type { border-bottom: none; }
.recap-title {
  margin-bottom: 16px;
  font-size: 12px; font-weight: 500; letter-spacing: .18em; text-transform: uppercase;
  color: rgba(0, 0, 0, .62);
}
.recap-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 640px) { .recap-grid { grid-template-columns: 1fr; } }
.ri-label { font-size: 13px; color: rgba(0, 0, 0, .62); margin-bottom: 2px; }
.ri-value { font-size: 16px; font-weight: 500; color: var(--cfg-ink); }

.price-box { background: var(--cfg-ink); color: #fff; padding: 28px 32px; text-align: center; }
.pb-label { font-size: 12px; font-weight: 500; letter-spacing: .18em; text-transform: uppercase; color: rgba(255, 255, 255, .5); }
.pb-ht { margin-top: 10px; font-size: 40px; font-weight: 600; line-height: 1; letter-spacing: -.03em; color: var(--cfg-amber); }
.pb-ttc { margin-top: 8px; font-size: 15px; color: rgba(255, 255, 255, .65); }
.pb-note { margin-top: 12px; font-size: 12px; color: rgba(255, 255, 255, .6); }

/* ── Boutons ─────────────────────────────────────────────────── */
.btn-kmy, .btn-back, .download-btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 24px; font: inherit; font-size: 15px; font-weight: 500; letter-spacing: -.01em;
  border: none; cursor: pointer; transition: all .2s ease;
}
.btn-kmy { background: var(--cfg-amber); color: #000; }
.btn-kmy:hover { background: var(--cfg-amber-dark); }
.btn-back { background: transparent; color: var(--cfg-ink); box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .15); }
.btn-back:hover { box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .5); }
.download-btn { background: var(--cfg-ink); color: #fff; }
.download-btn:hover { background: var(--cfg-ink-soft); }

/* ── Confirmation ────────────────────────────────────────────── */
.success-card { background: #fff; padding: 48px 32px; text-align: center; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .1); }
.success-icon {
  width: 64px; height: 64px; margin: 0 auto 24px;
  display: flex; align-items: center; justify-content: center;
  background: var(--cfg-amber); font-size: 26px; color: #000;
}

/* ── Overlay de génération ───────────────────────────────────── */
.loading-overlay {
  display: none; position: fixed; inset: 0; z-index: 60;
  background: rgba(1, 2, 6, .85);
  align-items: center; justify-content: center; flex-direction: column; gap: 20px;
}
.loading-overlay.show { display: flex; }
.loading-overlay p { color: #fff; font-size: 15px; font-weight: 500; }
.spinner {
  width: 44px; height: 44px; border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, .2); border-top-color: var(--cfg-amber);
  animation: cfg-spin .8s linear infinite;
}
@keyframes cfg-spin { to { transform: rotate(360deg); } }

/* Mention du supplément double accès / cuvette réduite (étape 1). */
.supp-note { margin-top: .75rem; font-size: 13px; line-height: 1.5; color: var(--cfg-ink); background: rgba(255, 194, 71, .22); padding: .6rem .8rem; border-left: 3px solid var(--cfg-amber); }
.supp-note[hidden], .pb-note[hidden] { display: none; }

/* Mention « à confirmer après étude » sous les dimensions de cabine (aperçu en direct). */
.viz-note { display: block; margin-top: 1px; font-size: 10px; font-weight: 400; line-height: 1.3; color: rgba(0, 0, 0, .5); }
