:root {
  --bleu: #4f46e5;        /* indigo principal (variable historique réutilisée) */
  --bleu-clair: #eef0fe;
  --bleu-fonce: #4c1d95;  /* violet foncé */
  --vert: #7c3aed;        /* accent violet (étapes validées) */
  --or: #e11d48;          /* rouge/rose accent */
  --or-fonce: #be123c;
  --gris: #5b5b6b;
  --gris-clair: #f1f1f7;
  --bord: #e3e2ef;
  --texte: #16131f;
  --radius: 14px;
  --ombre: 0 4px 20px rgba(79, 70, 229, .14);
  --grad: linear-gradient(120deg, #16225c 0%, #4a1685 50%, #7a0f2e 100%);
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background: #f4f5fb;
  color: var(--texte);
  line-height: 1.5;
  padding-bottom: 60px;
}

/* En-tête */
.app-header {
  background: var(--grad);
  color: #fff;
  padding: 24px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 20;
  overflow: hidden;
}
/* Voile sombre dégradé pour garder le texte/boutons lisibles sur la photo */
.app-header::after {
  content: "";
  position: absolute;
  inset: 0;
  background: none;
  pointer-events: none;
  z-index: 0;
}
.app-header > * { position: relative; z-index: 1; }
.brand { display: flex; align-items: center; gap: 12px; }
.brand .logo { width: 42px; height: 42px; display: block; flex: 0 0 auto; }
.brand h1 { margin: 0; font-size: 20px; letter-spacing: -.5px; }
.brand p { margin: 0; font-size: 12px; opacity: .85; }

/* Étapes */
.steps {
  display: flex;
  overflow-x: auto;
  gap: 6px;
  padding: 12px;
  background: #fff;
  border-bottom: 1px solid var(--bord);
  position: sticky;
  top: 64px;
  z-index: 15;
  scrollbar-width: none;
}
.steps::-webkit-scrollbar { display: none; }
.step {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 6px;
  border: 1px solid var(--bord);
  background: #fff;
  color: var(--gris);
  padding: 8px 12px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
}
.step span:first-child {
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--gris-clair);
  color: var(--gris);
  font-size: 12px;
  flex: 0 0 auto;
}
.step.is-active { border-color: var(--bleu); color: var(--bleu); background: var(--bleu-clair); }
.step.is-active span:first-child { background: var(--grad); color: #fff; }
.step.is-done span:first-child { background: var(--vert); color: #fff; }

/* Conteneur + carrousel natif (glissement géré par le navigateur) */
.wrap { max-width: 760px; margin: 0 auto; padding: 0; }
.panels-track {
  display: flex;
  transition: transform .34s cubic-bezier(.4, 0, .2, 1);
  will-change: transform;
}
.panel {
  flex: 0 0 100%;
  width: 100%;
  min-width: 100%;
  padding: 18px;
}

/* Mise en page plein écran sur la page principale : chaque étape défile à l'intérieur */
body.app-carrousel { height: 100vh; height: 100dvh; display: flex; flex-direction: column; overflow: hidden; padding-bottom: 0; background: #f4f5fb; }
body.app-carrousel .wrap, body.app-carrousel .panel { background: #f4f5fb; }
body.app-carrousel .app-header { position: relative; }
body.app-carrousel .steps { position: static; }
body.app-carrousel .wrap { flex: 1 1 auto; min-height: 0; width: 100%; overflow: hidden; }
body.app-carrousel .panels-track { height: 100%; overflow-x: auto; overflow-y: hidden; scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
body.app-carrousel .panels-track::-webkit-scrollbar { display: none; }
body.app-carrousel .panel { height: 100%; overflow-y: auto; -webkit-overflow-scrolling: touch; scroll-snap-align: start; scroll-snap-stop: always; }
body.app-carrousel .app-footer { flex: 0 0 auto; padding: 8px; }

.panel h2 { font-size: 22px; margin: 0 0 4px; letter-spacing: -.5px; }
.hint { color: var(--gris); font-size: 14px; margin: 0 0 18px; }

/* Formulaires */
.grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
.grid .col-2 { grid-column: 1 / -1; }
label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 13px;
  font-weight: 600;
  color: #334155;
}
input, select {
  font: inherit;
  font-weight: 400;
  padding: 12px;
  border: 1px solid var(--bord);
  border-radius: 10px;
  background: #fff;
  color: var(--texte);
  width: 100%;
}
input, select, textarea { transition: border-color .15s ease, box-shadow .15s ease, background .15s ease; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--bleu); box-shadow: 0 0 0 3px rgba(79, 70, 229, .16); }
.readonly input, input[readonly] { background: var(--gris-clair); font-weight: 700; color: var(--bleu-fonce); }

/* Fenêtre Abonnement (paywall) */
.modal-overlay {
  position: fixed; inset: 0; z-index: 100;
  background: rgba(15, 10, 38, .55);
  display: flex; align-items: center; justify-content: center;
  padding: 24px;
}
.modal-overlay[hidden] { display: none; }
.modal {
  background: #fff; border-radius: 18px; padding: 26px 22px;
  max-width: 360px; width: 100%; text-align: center;
  box-shadow: 0 20px 60px rgba(0,0,0,.35);
}
.modal-ico { font-size: 40px; margin-bottom: 6px; }
.modal h3 { margin: 0 0 8px; font-size: 20px; color: var(--bleu-fonce); }
.modal p { margin: 0 0 18px; color: var(--gris); font-size: 14.5px; }
.modal .btn-primary { width: 100%; margin-bottom: 8px; }
.modal .btn-ghost { width: 100%; }

/* Schéma état carrosserie (vue du dessus) */
.etat-wrap { margin-bottom: 4px; }
.etat-pad {
  width: 100%;
  max-width: 440px;
  margin: 0 auto;
  height: 200px;
  background: #fff;
  border: 2px solid var(--bord);
  border-radius: 12px;
  touch-action: none;
  display: block;
}
.etat-wrap .btn-ghost.small { margin-top: 8px; }

/* Deux scans côte à côte (recto / verso) */
.scan-duo { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-bottom: 20px; }
.scan-duo .scanbox { margin-bottom: 0; }
@media (max-width: 560px) { .scan-duo { grid-template-columns: 1fr; } }

/* Boîte de scan */
.scanbox {
  background: var(--bleu-clair);
  border: 2px dashed #bfdbfe;
  border-radius: var(--radius);
  padding: 18px;
  text-align: center;
  margin-bottom: 20px;
}
.btn-scan {
  background: #fff;
  border: 1px solid var(--bleu);
  color: var(--bleu);
  font-weight: 700;
  font-size: 15px;
  padding: 14px 20px;
  border-radius: 12px;
  cursor: pointer;
  box-shadow: var(--ombre);
}
.btn-scan:active { transform: scale(.98); }
.preview {
  display: block;
  max-width: 100%;
  max-height: 220px;
  margin: 14px auto 0;
  border-radius: 10px;
  border: 1px solid var(--bord);
}
.ocr-status { margin-top: 10px; font-size: 13px; font-weight: 600; color: var(--bleu); min-height: 18px; }
.ocr-status.error { color: #dc2626; }
.ocr-status.ok { color: var(--vert); }

/* Boutons d'action */
.actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-top: 24px;
}
.btn-primary {
  background: var(--grad);
  color: #fff;
  border: 0;
  padding: 14px 22px;
  border-radius: 12px;
  font-weight: 700;
  font-size: 15px;
  cursor: pointer;
  box-shadow: var(--ombre);
}
.btn-primary:active { transform: scale(.98); }
.btn-ghost {
  background: transparent;
  border: 1px solid var(--bord);
  color: var(--gris);
  padding: 12px 18px;
  border-radius: 12px;
  font-weight: 600;
  cursor: pointer;
}
.btn-ghost.small { padding: 8px 14px; font-size: 13px; margin-top: 8px; }

/* Signatures */
.sign-group { display: grid; gap: 22px; }
.sign-block h3 { margin: 0 0 8px; font-size: 15px; }
.sigpad {
  width: 100%;
  height: 200px;
  background: #fff;
  border: 2px solid var(--bord);
  border-radius: 12px;
  touch-action: none;
  display: block;
}
.check {
  flex-direction: row;
  align-items: flex-start;
  gap: 10px;
  margin-top: 22px;
  font-weight: 500;
  font-size: 14px;
  color: #334155;
}
.check input { width: 20px; height: 20px; margin-top: 1px; }

/* Récapitulatif */
.recap {
  background: #fff;
  border: 1px solid var(--bord);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--ombre);
}
.recap h3 { margin: 18px 0 8px; font-size: 15px; color: var(--bleu-fonce); border-bottom: 1px solid var(--bord); padding-bottom: 6px; }
.recap h3:first-child { margin-top: 0; }
.recap .row { display: flex; justify-content: space-between; gap: 12px; padding: 4px 0; font-size: 14px; }
.recap .row span:first-child { color: var(--gris); }
.recap .row span:last-child { font-weight: 600; text-align: right; }
.recap .sigimg { max-height: 70px; border: 1px solid var(--bord); border-radius: 8px; background: #fff; }

.app-footer { text-align: center; color: var(--gris); font-size: 12px; padding: 20px; }

/* Sous-titres de section dans un panneau */
.section-titre {
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: .6px;
  color: var(--bleu);
  margin: 24px 0 12px;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--bord);
}
.section-titre:first-of-type { margin-top: 8px; }

textarea {
  font: inherit;
  font-weight: 400;
  padding: 12px;
  border: 1px solid var(--bord);
  border-radius: 10px;
  background: #fff;
  color: var(--texte);
  width: 100%;
  resize: vertical;
}
textarea:focus { outline: 2px solid var(--bleu); border-color: var(--bleu); }

/* Zone logo & cachet */
.logo-zone { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.logo-item { display: flex; flex-direction: column; gap: 8px; }
.logo-libelle { font-size: 13px; font-weight: 600; color: #334155; }
.logo-apercu {
  height: 110px;
  border: 2px dashed #bfdbfe;
  border-radius: 12px;
  background: var(--bleu-clair);
  display: grid;
  place-items: center;
  overflow: hidden;
}
.logo-apercu img { max-width: 100%; max-height: 100%; object-fit: contain; }
.logo-vide { color: var(--gris); font-size: 13px; }
.logo-btns { display: flex; gap: 8px; }
.logo-btns .btn-ghost.small { margin-top: 0; }

@media (max-width: 560px) {
  .logo-zone { grid-template-columns: 1fr; }
}

/* Mode arabe (droite-à-gauche) */
[dir="rtl"] input, [dir="rtl"] textarea, [dir="rtl"] select { text-align: right; }
[dir="rtl"] .recap .row span:last-child { text-align: left; }
[dir="rtl"] .hint, [dir="rtl"] .section-titre { text-align: right; }
[dir="rtl"] #btnLangue { font-weight: 700; }

/* En-tête : actions à droite */
.header-actions { display: flex; gap: 8px; align-items: center; }
.app-header .btn-ghost { color: #fff; border-color: rgba(255,255,255,.45); }
.app-header .btn-ghost:hover { background: rgba(255,255,255,.12); }
.btn-abo { text-decoration: none; }

/* ===================== PAGE ABONNEMENT ===================== */
.tarifs-wrap { max-width: 560px; }
.tarifs-intro { text-align: center; margin-bottom: 22px; }
.tarifs-intro h2 { font-size: 26px; margin: 0 0 6px; letter-spacing: -.5px; }
.tarifs-intro .hint { margin: 0; }

.toggles { display: flex; flex-direction: column; gap: 12px; align-items: center; margin-bottom: 22px; }
.toggle {
  display: inline-flex;
  flex-wrap: wrap;                 /* passe à la ligne sur petit écran (sinon les devises sortent de l'écran) */
  justify-content: center;
  max-width: 100%;
  background: var(--gris-clair);
  border-radius: 22px;
  padding: 4px;
  gap: 4px;
}
.toggle button {
  border: 0;
  background: transparent;
  padding: 9px 18px;
  border-radius: 999px;
  font: inherit;
  font-weight: 700;
  font-size: 14px;
  color: var(--gris);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.toggle button.is-on { background: #fff; color: var(--bleu); box-shadow: var(--ombre); }
/* Sur mobile : le sélecteur de devises (10 boutons) devient une bande qui glisse,
   contenue dans le cadre (rien ne déborde) au lieu de sortir de l'écran. */
@media (max-width: 640px) {
  #toggleDevise {
    flex-wrap: nowrap;
    align-self: stretch;
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    justify-content: flex-start;
  }
  #toggleDevise::-webkit-scrollbar { display: none; }
  #toggleDevise button { flex: 0 0 auto; }
}
.save-badge {
  background: var(--vert);
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  padding: 2px 7px;
  border-radius: 999px;
}

.plan-card {
  background: #fff;
  border: 1px solid var(--bord);
  border-radius: 18px;
  box-shadow: var(--ombre);
  overflow: hidden;
}
.plan-head {
  background: var(--grad);
  color: #fff;
  padding: 26px 24px 22px;
  text-align: center;
}
.plan-label { font-size: 13px; text-transform: uppercase; letter-spacing: 1px; opacity: .85; font-weight: 700; }
.plan-price { display: flex; align-items: baseline; justify-content: center; gap: 4px; margin-top: 8px; }
.plan-price #planPrice { font-size: 52px; font-weight: 800; line-height: 1; letter-spacing: -1px; }
.plan-cur { font-size: 26px; font-weight: 700; }
.plan-per { font-size: 16px; opacity: .85; align-self: flex-end; margin-bottom: 6px; }
.plan-note { margin: 12px 0 0; font-size: 13px; opacity: .95; min-height: 16px; }

.plan-features { list-style: none; margin: 0; padding: 22px 24px; display: grid; gap: 12px; }
.plan-features li { font-size: 14.5px; color: #1e293b; }
.plan-features strong { color: var(--bleu-fonce); }

.pay-zone { padding: 0 24px 26px; text-align: center; }
.btn-pay {
  display: block;
  background: var(--grad);
  color: #fff;
  text-decoration: none;
  font-weight: 800;
  font-size: 17px;
  padding: 16px;
  border-radius: 12px;
  box-shadow: 0 6px 18px rgba(124,58,237,.35);
}
.btn-pay:active { transform: scale(.98); }
.btn-pay.is-disabled { background: #cbd5e1; box-shadow: none; cursor: not-allowed; }
.pay-secu { margin: 12px 0 0; font-size: 12.5px; color: var(--gris); }

/* Liste des moyens de paiement (abonnement) */
.pay-titre { text-align: center; font-size: 13px; font-weight: 700; color: var(--gris); text-transform: uppercase; letter-spacing: .5px; margin: 4px 0 14px; }
.pay-methods { display: grid; gap: 10px; }
.pay-method {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  text-align: left;
  background: #fff;
  border: 1px solid var(--bord);
  border-radius: 12px;
  padding: 14px 16px;
  font: inherit;
  font-weight: 600;
  color: var(--texte);
  cursor: pointer;
  text-decoration: none;
}
.pay-method:hover { border-color: var(--bleu); background: var(--bleu-clair); }
.pay-method .pm-ico { font-size: 22px; width: 28px; text-align: center; }
.pay-method .pm-txt { flex: 1; }
.pay-method .pm-txt small { display: block; font-weight: 400; color: var(--gris); font-size: 12px; }
.pay-method .pm-fleche { color: var(--gris); font-weight: 700; }
.pay-method.is-disabled { opacity: .5; cursor: not-allowed; }

.iban-box {
  background: var(--gris-clair);
  border: 1px dashed var(--bord);
  border-radius: 12px;
  padding: 14px 16px;
  font-size: 13.5px;
  margin-top: 4px;
}
.iban-box .row { display: flex; justify-content: space-between; gap: 10px; padding: 3px 0; }
.iban-box .row span:first-child { color: var(--gris); }
.iban-box .row span:last-child { font-weight: 700; text-align: right; word-break: break-all; }

/* Cases moyens de paiement acceptés (onglet agence) */
.pm-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.pm-check {
  flex-direction: row;
  align-items: center;
  gap: 9px;
  background: #fff;
  border: 1px solid var(--bord);
  border-radius: 10px;
  padding: 11px 13px;
  font-weight: 600;
  font-size: 14px;
  color: #2a3a31;
  cursor: pointer;
}
.pm-check input { width: 18px; height: 18px; accent-color: var(--bleu); }
@media (max-width: 560px) { .pm-grid { grid-template-columns: 1fr; } }

.activation { margin-top: 22px; background: var(--bleu-clair); border: 1px solid var(--bord); border-radius: 14px; padding: 18px; text-align: center; }
.activation .act-titre { font-weight: 800; font-size: 16px; color: var(--bleu-fonce); margin: 0 0 2px; }
.activation .act-sub { font-size: 13px; color: var(--gris); margin: 0 0 12px; }

.tarifs-foot { text-align: center; font-size: 13px; color: var(--gris); margin-top: 22px; }
.tarifs-foot a { color: var(--bleu); }

.config-help {
  margin-top: 26px;
  background: #fffbeb;
  border: 1px solid #fde68a;
  border-radius: 12px;
  padding: 16px 18px;
  font-size: 13.5px;
  color: #78350f;
}
.config-help h3 { margin: 0 0 8px; font-size: 15px; }
.config-help code { background: #fef3c7; padding: 1px 6px; border-radius: 5px; font-size: 12.5px; }
.config-help a { color: #b45309; font-weight: 600; }

/* Téléphone */
@media (max-width: 560px) {
  .grid { grid-template-columns: 1fr; }
  .grid .col-2 { grid-column: 1; }
  .panel h2 { font-size: 19px; }
  .steps { top: 60px; }
  .header-actions .btn-abo { padding: 8px 10px; font-size: 13px; }
}

/* ===================== FINITIONS PREMIUM ===================== */
/* Boutons : micro-interactions + relief */
.btn-primary, .btn-pay, .btn-scan, .step, .btn-ghost {
  transition: transform .12s ease, box-shadow .2s ease, filter .2s ease, background .2s ease, border-color .2s ease;
}
.btn-primary:hover, .btn-pay:hover { filter: brightness(1.05); box-shadow: 0 10px 24px rgba(124, 58, 237, .30); }
.btn-primary:active, .btn-pay:active, .btn-scan:active, .pay-method:active { transform: translateY(1px) scale(.99); }
.btn-scan:hover { border-color: var(--bleu-fonce); box-shadow: 0 8px 20px rgba(79, 70, 229, .18); }

/* Cartes & zones : profondeur douce */
.scanbox, .logo-apercu, .etat-pad, .sigpad { transition: border-color .2s ease, box-shadow .2s ease, background .2s ease; }
.scanbox:hover, .logo-apercu:hover { border-color: var(--bleu); box-shadow: 0 6px 18px rgba(79, 70, 229, .10); }
.recap, .plan-card { box-shadow: 0 10px 34px rgba(79, 70, 229, .12); }

/* Étapes : l'étape active prend un léger relief */
.step.is-active { box-shadow: 0 4px 14px rgba(79, 70, 229, .18); }
.step span:first-child { transition: transform .15s ease; }
.step.is-active span:first-child { transform: scale(1.06); }

/* Sous-titres de section : petit liseré dégradé à gauche */
.section-titre { position: relative; padding-left: 12px; }
.section-titre::before {
  content: ""; position: absolute; left: 0; top: 50%; transform: translateY(-55%);
  width: 4px; height: 14px; border-radius: 3px; background: var(--grad);
}
[dir="rtl"] .section-titre { padding-left: 0; padding-right: 12px; }
[dir="rtl"] .section-titre::before { left: auto; right: 0; }

/* Champs : fond très légèrement plus doux, coins un poil plus ronds */
input, select, textarea { border-radius: 11px; background: #fff; }
input:hover, select:hover, textarea:hover { border-color: #c7c9e0; }

/* ===================== EN-TÊTE ÉPURÉ ===================== */
.header-actions { gap: 7px; }
.btn-abo, #btnReset { display: inline-flex; align-items: center; gap: 5px; }
.app-header .btn-ghost { padding: 9px 12px; }
#selLangue { padding: 9px 8px; cursor: pointer; }
.app-header .btn-ghost, #selLangue { transition: background .2s ease, border-color .2s ease; }
@media (max-width: 600px) {
  .app-header { padding: 14px 12px; }
  .brand p { display: none; }                  /* sous-titre masqué (évite le retour à la ligne) */
  .brand .logo { width: 36px; height: 36px; }
  .brand h1 { font-size: 18px; letter-spacing: -.3px; }
  .header-actions { gap: 6px; }
  .header-actions .ha-txt { display: none; }    /* actions en icônes seules sur mobile */
  .app-header .btn-ghost { padding: 9px 11px; font-size: 15px; }
  .btn-abo, #btnReset { gap: 0; }
  /* Barre d'étapes : pastilles numérotées seules (le titre de la page suffit) */
  .steps { justify-content: space-between; gap: 2px; padding: 10px 14px; overflow-x: visible; }
  .step, .step.is-active { padding: 4px; border-color: transparent; background: transparent; }
  .step span:nth-child(2) { display: none; }
}

/* ===================== MODE SOMBRE ===================== */
html[data-theme="dark"] {
  --texte: #e9eaf2;
  --gris: #a6abc0;
  --gris-clair: #232636;
  --bleu-clair: #1b1d39;
  --bleu-fonce: #c4b5fd;
  --bord: #313548;
  --ombre: 0 6px 24px rgba(0, 0, 0, .45);
}
html[data-theme="dark"] body,
html[data-theme="dark"] body.app-carrousel,
html[data-theme="dark"] body.app-carrousel .wrap,
html[data-theme="dark"] body.app-carrousel .panel { background: #0f1117; }

/* Surfaces blanches -> sombres */
html[data-theme="dark"] .steps,
html[data-theme="dark"] .step,
html[data-theme="dark"] input,
html[data-theme="dark"] select,
html[data-theme="dark"] textarea,
html[data-theme="dark"] .btn-scan,
html[data-theme="dark"] .recap,
html[data-theme="dark"] .plan-card,
html[data-theme="dark"] .modal,
html[data-theme="dark"] .pay-method,
html[data-theme="dark"] .pm-check,
html[data-theme="dark"] .toggle button.is-on { background: #1a1d29; }

html[data-theme="dark"] .btn-scan { color: #a5b4fc; border-color: #4338ca; }
html[data-theme="dark"] .step.is-active { color: #c7d2fe; }

/* Textes sombres -> clairs */
html[data-theme="dark"] label,
html[data-theme="dark"] .check,
html[data-theme="dark"] .logo-libelle,
html[data-theme="dark"] .plan-features li,
html[data-theme="dark"] .pm-check { color: #d6d8e6; }
html[data-theme="dark"] input::placeholder,
html[data-theme="dark"] textarea::placeholder { color: #6b7088; }

/* Bordures pointillées un peu plus discrètes */
html[data-theme="dark"] .scanbox,
html[data-theme="dark"] .logo-apercu { border-color: #3a3f63; }

/* Champ en lecture seule (total…) */
html[data-theme="dark"] .readonly input,
html[data-theme="dark"] input[readonly] { background: #232636; color: #c4b5fd; }

/* Encadré d'aide (jaune -> ambre sombre) */
html[data-theme="dark"] .config-help { background: #2a2410; border-color: #4d3f12; color: #f3d99b; }
html[data-theme="dark"] .config-help code { background: #3a3115; }
html[data-theme="dark"] .config-help a { color: #fbbf24; }

/* Zones de DESSIN : restent BLANCHES (encre noire visible + identique au PDF) */
html[data-theme="dark"] .sigpad,
html[data-theme="dark"] .etat-pad { background: #fff; }

/* ===================== PAGE D'ACCUEIL (vitrine) ===================== */
.lp-nav { display: flex; align-items: center; justify-content: space-between; max-width: 1080px; margin: 0 auto; padding: 16px 20px; }
.lp-nav-links { display: flex; gap: 10px; align-items: center; }
.lp-nav-links a { text-decoration: none; }
/* Barre de nav responsive : sur petit écran, tout passe à la ligne et se centre (sinon « Commencer » dépasse) */
@media (max-width: 600px) {
  .lp-nav { flex-wrap: wrap; justify-content: center; gap: 8px 10px; padding: 12px 12px; }
  .lp-nav-links { flex-wrap: wrap; justify-content: center; gap: 8px; }
  .lp-nav-links .btn-ghost, .lp-nav-links .btn-primary, #lpLang { padding: 8px 12px; font-size: 14px; }
}
.lp-hero { display: grid; grid-template-columns: 1.05fr .95fr; gap: 30px; align-items: center; max-width: 1080px; margin: 0 auto; padding: 34px 20px 46px; }
.lp-hero-img { background: var(--grad); border-radius: 20px; min-height: 330px; box-shadow: var(--ombre); display: grid; place-items: center; overflow: hidden; }
.lp-hero-car { width: 58%; max-width: 230px; height: auto; filter: drop-shadow(0 10px 20px rgba(0, 0, 0, .25)); }
.lp-badge { display: inline-block; background: var(--bleu-clair); color: var(--bleu); padding: 5px 12px; border-radius: 999px; font-size: 12.5px; font-weight: 700; }
.lp-hero-text h2 { font-size: 42px; line-height: 1.08; letter-spacing: -1px; margin: 12px 0 14px; }
.lp-grad-text { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.lp-hero-text p.lp-sub { color: var(--gris); font-size: 16.5px; max-width: 520px; margin: 0 0 8px; }
.lp-cta { display: flex; gap: 12px; flex-wrap: wrap; margin: 22px 0 12px; }
.lp-big { padding: 15px 24px; font-size: 16px; text-decoration: none; }
.lp-note { font-size: 13.5px; color: var(--gris); margin: 0; }
.lp-section { max-width: 1080px; margin: 0 auto; padding: 38px 20px; }
.lp-h3 { text-align: center; font-size: 28px; letter-spacing: -.5px; margin: 0 0 26px; }
.lp-cards { display: flex; flex-wrap: wrap; justify-content: center; gap: 16px; }
.lp-card { background: #fff; border: 1px solid var(--bord); border-radius: 16px; padding: 22px; box-shadow: var(--ombre); flex: 1 1 260px; max-width: 320px; text-align: center; }
.lp-ico { font-size: 30px; }
.lp-card h4 { margin: 10px 0 6px; font-size: 16.5px; }
.lp-card p { margin: 0; color: var(--gris); font-size: 14px; }
.lp-steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.lp-step { text-align: center; padding: 18px; }
.lp-step span { display: inline-grid; place-items: center; width: 46px; height: 46px; border-radius: 50%; background: var(--grad); color: #fff; font-size: 20px; font-weight: 800; box-shadow: var(--ombre); }
.lp-step h4 { margin: 12px 0 6px; font-size: 16.5px; }
.lp-step p { color: var(--gris); font-size: 14px; margin: 0; }
.lp-pricing { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; max-width: 640px; margin: 0 auto 20px; }
.lp-price-card { background: #fff; border: 1px solid var(--bord); border-radius: 18px; padding: 24px; text-align: center; box-shadow: var(--ombre); display: block; text-decoration: none; color: inherit; cursor: pointer; transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease; }
.lp-price-card:hover { transform: translateY(-3px); border-color: var(--bleu); box-shadow: 0 12px 32px rgba(79, 70, 229, .18); }
/* Section pliable « 2ème conducteur » */
details.cond2 { margin-top: 6px; border: 1px dashed var(--bord); border-radius: 14px; padding: 12px 14px; }
details.cond2 > summary { cursor: pointer; font-weight: 800; color: var(--bleu); list-style: none; font-size: 15px; }
details.cond2 > summary::-webkit-details-marker { display: none; }
details.cond2[open] > summary { margin-bottom: 10px; }
.lp-price-card.lp-featured { border-color: var(--bleu); box-shadow: 0 12px 36px rgba(79, 70, 229, .22); }
.lp-plan { font-size: 13px; text-transform: uppercase; letter-spacing: 1px; font-weight: 800; color: var(--bleu); }
.lp-amount { font-size: 36px; font-weight: 800; margin: 8px 0 14px; }
.lp-amount small { font-size: 15px; font-weight: 600; color: var(--gris); }
.lp-price-card ul { list-style: none; padding: 0; margin: 0; text-align: left; display: grid; gap: 8px; }
.lp-price-card li { font-size: 14px; }
.lp-final { text-align: center; padding: 48px 20px 26px; }
.lp-final h3 { font-size: 26px; letter-spacing: -.5px; margin: 0 0 18px; }
.lp-center { text-align: center; }
html[data-theme="dark"] .lp-card,
html[data-theme="dark"] .lp-price-card { background: #1a1d29; }
@media (max-width: 860px) { .lp-cards { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 760px) {
  .lp-hero { grid-template-columns: 1fr; }
  .lp-hero-img { min-height: 190px; order: -1; }
  .lp-hero-text h2 { font-size: 34px; }
  .lp-steps { grid-template-columns: 1fr; }
}
@media (max-width: 560px) { .lp-cards { grid-template-columns: 1fr; } .lp-pricing { grid-template-columns: 1fr; } }
