:root {
  --marque: #c2410c;          /* couleur du couvreur, modifiable dans les réglages */
  --encre: #1c1f24;
  --encre-2: #4a5059;
  --encre-3: #7c838d;
  --trait: #e3e0da;
  --fond: #f7f5f1;
  --surface: #ffffff;
  --rayon: 10px;
  --serif: "Source Serif 4", Georgia, serif;
  --sans: "Archivo", system-ui, -apple-system, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  background: var(--fond);
  color: var(--encre);
  font: 16px/1.5 var(--sans);
  -webkit-font-smoothing: antialiased;
}
button, input { font: inherit; color: inherit; }
[hidden] { display: none !important; }

.bandeau-demo {
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
  padding: 8px 16px; background: var(--encre); color: #e9e6e0; font-size: 13px;
}
.bandeau-demo .lien { color: #fff; }

.entete {
  display: flex; justify-content: space-between; align-items: center;
  max-width: 560px; margin: 0 auto; padding: 18px 16px 6px;
}
.marque { display: flex; align-items: center; gap: 10px; font-weight: 700; letter-spacing: -0.01em; }
.marque-logo {
  display: grid; place-items: center; width: 34px; height: 34px;
  border-radius: 8px; background: var(--marque); color: #fff;
}
.langues { display: flex; border: 1px solid var(--trait); border-radius: 8px; overflow: hidden; background: var(--surface); }
.langues button { border: 0; background: none; padding: 6px 12px; font-size: 13px; font-weight: 600; color: var(--encre-3); cursor: pointer; }
.langues button.actif { background: var(--encre); color: #fff; }

.widget { max-width: 560px; margin: 0 auto; padding: 8px 16px 32px; }
.etape { animation: entree .18s ease-out; }
@keyframes entree { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }

.sur-titre {
  margin: 18px 0 6px; font-size: 12px; font-weight: 700; letter-spacing: .08em;
  text-transform: uppercase; color: var(--marque);
}
h1, h2 { font-family: var(--serif); font-weight: 600; letter-spacing: -0.015em; margin: 0 0 10px; }
h1 { font-size: clamp(30px, 7vw, 40px); line-height: 1.1; }
h2 { font-size: 26px; line-height: 1.2; }
.intro { color: var(--encre-2); margin: 0 0 18px; }
.aide { font-size: 14px; color: var(--encre-3); margin: 10px 0 0; }

.champ { display: block; margin: 0 0 14px; }
.champ > span { display: block; font-size: 14px; font-weight: 600; margin-bottom: 6px; }
.champ input {
  width: 100%; padding: 14px 14px; border: 1.5px solid var(--trait); border-radius: var(--rayon);
  background: var(--surface); font-size: 17px; outline: none;
}
.champ input:focus { border-color: var(--encre); }

.autocomplete { position: relative; }
.suggestions {
  position: absolute; z-index: 1000; left: 0; right: 0; top: calc(100% + 4px);
  margin: 0; padding: 4px 0; list-style: none; background: var(--surface);
  border: 1px solid var(--trait); border-radius: var(--rayon); box-shadow: 0 8px 24px rgba(28,31,36,.08);
}
.suggestions li { padding: 12px 14px; cursor: pointer; border-bottom: 1px solid var(--trait); }
.suggestions li:last-child { border-bottom: 0; }
.suggestions li:hover, .suggestions li.actif { background: var(--fond); }

.carte { height: 340px; border-radius: var(--rayon); overflow: hidden; border: 1px solid var(--trait); background: #d8d4cc; }
.mesure { min-height: 24px; margin: 10px 0 0; font-weight: 600; }

.actions { display: flex; gap: 10px; margin-top: 18px; }
.actions > * { flex: 1; }
.btn-plein, .btn-filet {
  padding: 14px 16px; border-radius: var(--rayon); font-weight: 700; cursor: pointer; font-size: 16px;
}
.btn-plein { background: var(--marque); color: #fff; border: 0; }
.btn-plein:disabled { opacity: .4; cursor: not-allowed; }
.btn-filet { background: none; border: 1.5px solid var(--trait); }
.btn-plein.large { width: 100%; }
.lien { background: none; border: 0; padding: 0; text-decoration: underline; cursor: pointer; color: var(--encre-2); }
.lien.petit { display: block; margin: 16px auto 0; font-size: 14px; }

.manuel { margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--trait); }

.choix { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.carte-choix {
  display: flex; flex-direction: column; align-items: flex-start; gap: 2px; padding: 12px;
  background: var(--surface); border: 1.5px solid var(--trait); border-radius: var(--rayon); cursor: pointer; text-align: left;
}
.carte-choix:hover { border-color: var(--encre-3); }
.carte-choix svg { width: 100%; height: 64px; margin-bottom: 6px; }
.carte-choix svg rect { fill: #ece8e1; stroke: var(--encre-3); stroke-width: 1.5; }
.carte-choix svg .toit { fill: none; stroke: var(--marque); stroke-width: 4; stroke-linecap: round; stroke-linejoin: round; }
.carte-choix span { font-size: 13px; color: var(--encre-3); }

.liste { border-top: 1px solid var(--trait); }
.ligne-materiau {
  display: flex; justify-content: space-between; align-items: center; gap: 12px; width: 100%;
  padding: 16px 4px; background: none; border: 0; border-bottom: 1px solid var(--trait); cursor: pointer; text-align: left;
}
.ligne-materiau strong { display: block; font-size: 17px; }
.ligne-materiau span { font-size: 14px; color: var(--encre-3); }
.ligne-materiau svg { flex: none; color: var(--encre-3); }
.ligne-materiau:hover strong { color: var(--marque); }

.prix { font-family: var(--serif); font-size: clamp(34px, 9vw, 46px); font-weight: 600; margin: 0; letter-spacing: -0.02em; }
.detail { color: var(--encre-2); margin: 6px 0 12px; }
.avertissement { font-size: 13px; color: var(--encre-3); margin: 0 0 24px; padding-left: 12px; border-left: 3px solid var(--trait); }

.formulaire { padding-top: 22px; border-top: 1px solid var(--trait); }
.case { display: flex; gap: 10px; align-items: flex-start; font-size: 13px; color: var(--encre-2); margin: 4px 0 16px; }
.case input { margin-top: 3px; width: 18px; height: 18px; flex: none; accent-color: var(--marque); }
.erreur { color: #b42318; font-size: 14px; font-weight: 600; margin: 0 0 12px; }

.crm { background: var(--surface); border: 1px solid var(--trait); border-radius: var(--rayon); margin: 0 0 20px; overflow: hidden; }
.crm-tete { display: flex; align-items: center; gap: 8px; padding: 12px 14px; font-weight: 700; border-bottom: 1px solid var(--trait); }
.crm-point { width: 9px; height: 9px; border-radius: 50%; background: #16a34a; }
.crm-heure { margin-left: auto; font-weight: 500; font-size: 13px; color: var(--encre-3); }
.crm-corps { margin: 0; padding: 6px 14px; display: grid; grid-template-columns: auto 1fr; column-gap: 16px; }
.crm-corps dt { color: var(--encre-3); font-size: 14px; padding: 7px 0; }
.crm-corps dd { margin: 0; font-weight: 600; padding: 7px 0; overflow-wrap: anywhere; }
.crm-pied { margin: 0; padding: 10px 14px; font-size: 13px; color: var(--encre-3); background: var(--fond); }

.reglages { border: 0; border-radius: var(--rayon); padding: 0; width: min(520px, calc(100vw - 32px)); max-height: calc(100vh - 32px); }
.reglages::backdrop { background: rgba(28,31,36,.45); }
.reglages-corps { padding: 20px; }
.prix-materiaux { border: 1px solid var(--trait); border-radius: var(--rayon); padding: 12px; margin: 0 0 14px; }
.prix-materiaux legend { font-size: 14px; font-weight: 600; padding: 0 4px; }
.ligne-prix { display: grid; grid-template-columns: 1fr 90px 90px; gap: 8px; align-items: center; margin: 6px 0; font-size: 14px; }
.ligne-prix input { padding: 8px; border: 1.5px solid var(--trait); border-radius: 8px; width: 100%; }

.pied { max-width: 560px; margin: 0 auto; padding: 0 16px 24px; font-size: 11px; color: var(--encre-3); }

.leaflet-container { font: inherit; }

.champ-titre { font-weight: 600; margin: 0 0 10px; }
.tailles { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.taille {
  display: flex; flex-direction: column; align-items: flex-start; gap: 2px; padding: 12px;
  background: var(--surface); border: 1.5px solid var(--trait); border-radius: var(--rayon); cursor: pointer; text-align: left;
}
.taille:hover { border-color: var(--encre-3); }
.taille span { font-size: 13px; color: var(--encre-3); }

.bandeau-liens { display: flex; gap: 14px; flex: none; }
.bandeau-demo a.lien { color: #fff; }
.lien-marque { display: inline-flex; align-items: center; gap: 6px; }
.barre-demo { display: flex; flex-wrap: wrap; gap: 6px 14px; justify-content: space-between; padding: 8px 16px; background: #000; color: #e9e6e0; font-size: 13px; }
.barre-demo b { color: #fff; }
.barre-demo a { color: #fff; font-weight: 700; }

.lien-choix { display: flex; flex-wrap: wrap; gap: 4px 8px; align-items: baseline; width: 100%; margin-top: 10px; padding: 14px 12px; background: var(--surface); border: 1.5px dashed var(--trait); border-radius: var(--rayon); cursor: pointer; text-align: left; }
.lien-choix span { font-size: 13px; color: var(--encre-3); }
.autre { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--trait); }
.piege { position: absolute; left: -9999px; }
.indisponible { margin: 40px 0; font-size: 18px; color: var(--encre-2); text-align: center; }
.reel .bandeau-demo, .reel .demo-seulement { display: none !important; }
html:not(.reel) .reel-seulement { display: none; }
.integre body { background: transparent; }
.integre .pied { padding-bottom: 8px; }
.integre .widget { padding-bottom: 12px; }
.pied a { color: inherit; }
.reglages { width: min(640px, calc(100vw - 32px)); }
.champ input[type=color] { height: 48px; padding: 4px; cursor: pointer; }
