/* ============================================================
   DEVIS ISOLATION / VENTILATION — feuille de style
   Palette : bleu nuit, gris-bleu, bleu électrique (action)
   ============================================================ */
:root {
  --bg: #f3f5f9;
  --ink: #131a2a;
  --ink-soft: #3f4a5e;
  --muted: #6b7587;
  --pine: #14213d;          /* bleu nuit (nom conservé pour ne pas renommer toutes les règles) */
  --pine-deep: #0d1730;
  --sage: #dfe5ef;          /* gris-bleu clair : tuiles au repos, bordures de champs */
  --sage-soft: #eef1f6;
  --amber: #2f6bff;         /* bleu électrique : la seule couleur d'action */
  --amber-deep: #1f55d6;
  --line: #cfd6e2;
  --white: #ffffff;
  --danger: #b4362e;
  --ok: #1f7a4d;
  --font: "Bricolage Grotesque", "Segoe UI", -apple-system, BlinkMacSystemFont, Arial, sans-serif;
  --max: 1120px;
  --r-tile: 10px;
  --r-card: 14px;
  --r-btn: 8px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; }
img, svg { display: block; max-width: 100%; }
button, input, select, textarea { font: inherit; color: inherit; }
ul { list-style: none; }
fieldset { border: 0; min-width: 0; }
legend { padding: 0; display: block; }

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 20px; }

.skip-link { position: absolute; left: -9999px; top: 0; z-index: 100; background: var(--pine); color: #fff; padding: 10px 16px; border-radius: 0 0 var(--r-btn) 0; }
.skip-link:focus { left: 0; }

:focus-visible { outline: 3px solid var(--amber); outline-offset: 3px; }

/* ---------- En-tête : logo, menu de catégories, bouton ---------- */
.site-header { background: var(--white); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 70; }
.nav-row { height: 66px; display: flex; align-items: center; gap: 28px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 800; font-size: 20px; letter-spacing: -0.01em; color: var(--pine); }
.brand-mark { width: 30px; height: 30px; }
.main-nav { display: none; gap: 26px; margin-left: auto; }
.main-nav a { text-decoration: none; font-weight: 600; font-size: 15px; color: var(--ink-soft); padding: 6px 0; border-bottom: 2px solid transparent; }
.main-nav a:hover { color: var(--pine); border-bottom-color: var(--amber); }
.nav-cta { margin-left: auto; min-height: 42px; padding: 0 18px; font-size: 15px; }
@media (min-width: 900px) { .main-nav { display: flex; } .nav-cta { margin-left: 0; } }

/* ---------- Hero photo + formulaire ---------- */
/* Mets ta photo dans assets/img/hero.jpg (1800 px de large environ). Sans photo, le dégradé bleu nuit s'affiche. */
.hero {
  padding: 40px 0 44px; color: #fff;
  background: linear-gradient(100deg, rgba(20,33,61,.92) 0%, rgba(20,33,61,.72) 55%, rgba(20,33,61,.55) 100%), var(--pine) url("../img/hero.jpg") center / cover no-repeat;
}
.hero-grid { display: grid; grid-template-columns: 1fr; gap: 26px; }
@media (min-width: 900px) {
  .hero { padding: 34px 0 56px; }
  .hero-grid { grid-template-columns: 6fr 5fr; gap: 56px; align-items: center; }
}
.hero h1 {
  font-size: clamp(32px, 5vw, 54px);
  line-height: 1.04;
  font-weight: 800;
  letter-spacing: -0.025em;
  font-stretch: 95%;
  color: #fff;
  max-width: 16ch;
  text-shadow: 0 2px 18px rgba(0,0,0,.25);
}
.hero-lead { margin-top: 18px; font-size: 18px; color: rgba(255,255,255,.86); max-width: 46ch; }
.hero-points { margin-top: 22px; display: grid; gap: 10px; }
.hero-points li { display: flex; gap: 12px; align-items: flex-start; font-size: 16px; color: rgba(255,255,255,.92); }
.hero-points svg { flex: 0 0 22px; width: 22px; height: 22px; margin-top: 2px; color: #8fb0ff; }
.hero-points strong { font-weight: 700; color: #fff; }
@media (max-width: 899px) { .hero-points { display: none; } }
.zone-bar { background: var(--sage-soft); border-bottom: 1px solid var(--line); padding: 12px 0; font-size: 14.5px; color: var(--muted); text-align: center; }

/* Carte du formulaire : la seule ombre du site */
#lead-form { scroll-margin-top: 80px; }
.form-card {
  color: var(--ink);
  background: var(--white);
  border-radius: var(--r-card);
  box-shadow: 0 18px 50px -24px rgba(20, 33, 61, 0.35);
  overflow: hidden;
}
.progress { height: 6px; background: var(--sage); }
.progress-bar { height: 100%; width: 33%; background: var(--amber); transition: width .35s ease; }
.form-inner { padding: 20px 20px 22px; }
@media (min-width: 640px) { .form-inner { padding: 22px 28px 24px; } }
.step-label { font-size: 14px; color: var(--muted); font-weight: 500; }
.form-card h2 { font-size: 23px; line-height: 1.15; font-weight: 800; letter-spacing: -0.015em; color: var(--ink); }
.form-help { margin-top: 4px; color: var(--muted); font-size: 14px; }

.step { display: none; }
.step.active { display: block; }

/* Tuiles de choix */
.tiles { margin-top: 18px; display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.tiles.cols-3 { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 420px) { .tiles.cols-3:not(.tiles-main) { grid-template-columns: repeat(2, 1fr); } }
.tile { position: relative; }
.tile input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.tile label {
  display: flex; flex-direction: column; align-items: flex-start; gap: 10px;
  min-height: 84px; padding: 14px 14px 12px;
  border: 2px solid var(--sage); border-radius: var(--r-tile);
  background: var(--sage-soft); cursor: pointer; font-weight: 600; font-size: 15px; line-height: 1.25;
  transition: border-color .15s, background .15s;
}
.tile label svg { width: 26px; height: 26px; color: var(--pine); }
.tile label:hover { border-color: var(--pine); }
.tile input:checked + label { border-color: var(--pine); background: var(--white); box-shadow: inset 0 0 0 1px var(--pine); }
.tile input:focus-visible + label { outline: 3px solid var(--amber); outline-offset: 2px; }
.tile.compact label { min-height: 0; flex-direction: row; align-items: center; padding: 12px 14px; }
.field .tiles { margin-top: 0; }
.tiles.tiles-main .tile label { height: 100%; min-height: 50px; flex-direction: row; flex-wrap: nowrap; gap: 7px; align-items: center; justify-content: center; text-align: center; font-size: 14.5px; padding: 8px 6px; }
.tiles.tiles-main .tile label span { white-space: nowrap; }
.tiles.tiles-main .tile label svg { width: 20px; height: 20px; flex: 0 0 20px; }
@media (max-width: 560px) { .tiles.tiles-main .tile label svg { display: none; } }

/* Champs */
.field { margin-top: 11px; }
.field > label { display: block; font-weight: 600; font-size: 15px; margin-bottom: 6px; }
.field .hint { font-weight: 400; color: var(--muted); }
.field input[type="text"], .field input[type="tel"], .field input[type="email"], .field select {
  width: 100%; height: 46px; padding: 0 14px;
  border: 2px solid var(--sage); border-radius: var(--r-tile); background: var(--white);
  font-size: 16px; transition: border-color .15s;
}
.field select { appearance: none; -webkit-appearance: none; padding-right: 36px; background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2314213d' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'><polyline points='6 9 12 15 18 9'/></svg>"); background-repeat: no-repeat; background-position: right 12px center; background-size: 16px; }
.field input:focus, .field select:focus { border-color: var(--pine); outline: none; }
.field input[aria-invalid="true"] { border-color: var(--danger); }
.field-row { display: grid; grid-template-columns: 1fr; gap: 0 14px; }
@media (min-width: 560px) { .field-row { grid-template-columns: 1fr 1fr; } }
.error { display: none; margin-top: 10px; padding: 10px 12px; border-radius: var(--r-btn); background: #fbeae8; color: var(--danger); font-size: 14.5px; font-weight: 500; }
.error.show { display: block; }

.consent { margin-top: 12px; display: flex; gap: 12px; align-items: flex-start; font-size: 14px; color: var(--ink-soft); }
.consent input { width: 20px; height: 20px; margin-top: 2px; flex: 0 0 20px; accent-color: var(--pine); }
.consent a { color: var(--pine); }

.hp { position: absolute; left: -9999px; opacity: 0; height: 0; overflow: hidden; }

/* Boutons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 52px; padding: 0 22px; border-radius: var(--r-btn); border: 2px solid transparent;
  font-weight: 700; font-size: 16px; cursor: pointer; text-decoration: none; transition: background .15s, border-color .15s;
}
.btn-primary { background: var(--amber); color: #fff; }
.btn-primary:hover { background: var(--amber-deep); }
.btn-primary:disabled { opacity: .6; cursor: wait; }
.btn-ghost { background: transparent; border-color: var(--line); color: var(--ink-soft); }
.btn-ghost:hover { border-color: var(--pine); color: var(--pine); }
.btn-wide { width: 100%; }
.actions { margin-top: 14px; display: flex; gap: 10px; }
.actions .btn-primary { flex: 1; }
.form-foot { margin-top: 12px; font-size: 13px; color: var(--muted); text-align: center; }

/* ---------- Sections ---------- */
section { padding: 56px 0; }
@media (min-width: 900px) { section { padding: 72px 0; } }
.section-title { font-size: clamp(26px, 3.6vw, 36px); line-height: 1.1; font-weight: 800; letter-spacing: -0.02em; color: var(--pine); max-width: 22ch; }
.section-intro { margin-top: 12px; color: var(--ink-soft); max-width: 60ch; }

.steps { list-style: none; margin-top: 32px; display: grid; gap: 22px; }
@media (min-width: 760px) { .steps { grid-template-columns: repeat(3, 1fr); gap: 28px; } }
.steps li { border-top: 3px solid var(--pine); padding-top: 16px; }
.steps .num { font-size: 15px; font-weight: 700; color: var(--pine); }
.steps h3 { margin-top: 6px; font-size: 20px; font-weight: 800; letter-spacing: -0.01em; }
.steps p { margin-top: 8px; color: var(--ink-soft); font-size: 16px; }

.band { background: var(--sage-soft); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.band-grid { margin-top: 30px; display: grid; gap: 18px; }
@media (min-width: 760px) { .band-grid { grid-template-columns: repeat(3, 1fr); gap: 24px; } }
.band-grid div { padding: 20px 20px 22px; border-radius: var(--r-tile); background: var(--white); border: 1px solid var(--line); }
.band-grid h3 { font-size: 19px; font-weight: 800; }
.band-grid p { margin-top: 8px; font-size: 15.5px; color: var(--ink-soft); }
.band-note { margin-top: 22px; font-size: 14px; color: var(--muted); max-width: 70ch; }

.two-col { display: grid; gap: 28px; }
@media (min-width: 860px) { .two-col { grid-template-columns: 1fr 1fr; gap: 56px; } }
.checklist { margin-top: 18px; display: grid; gap: 12px; }
.checklist li { display: flex; gap: 12px; align-items: flex-start; }
.checklist svg { flex: 0 0 22px; width: 22px; height: 22px; margin-top: 2px; color: var(--pine); }
.prose p { margin-top: 12px; color: var(--ink-soft); }
.prose h3 { margin-top: 24px; font-size: 20px; font-weight: 800; }

.faq { margin-top: 26px; border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { list-style: none; cursor: pointer; padding: 18px 0; font-weight: 700; font-size: 17px; display: flex; justify-content: space-between; gap: 16px; align-items: center; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; flex: 0 0 12px; width: 12px; height: 12px; border-right: 2px solid var(--pine); border-bottom: 2px solid var(--pine); transform: rotate(45deg); transition: transform .2s; margin-right: 4px; }
.faq details[open] summary::after { transform: rotate(-135deg); }
.faq .answer { padding: 0 0 18px; color: var(--ink-soft); max-width: 70ch; }

.cta-final { text-align: left; }
.cta-final .btn { margin-top: 22px; }

/* ---------- Pied de page ---------- */
footer { background: var(--sage-soft); border-top: 1px solid var(--line); padding: 36px 0 28px; font-size: 14px; color: var(--ink-soft); }
.footer-grid { display: grid; gap: 22px; }
@media (min-width: 760px) { .footer-grid { grid-template-columns: 2fr 1fr 1fr; gap: 32px; } }
footer h4 { font-size: 15px; font-weight: 800; color: var(--ink); margin-bottom: 8px; }
footer li { margin-top: 6px; }
footer a { color: var(--pine); }
.footer-bottom { margin-top: 26px; padding-top: 16px; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; gap: 8px 20px; justify-content: space-between; font-size: 13px; color: var(--muted); }

/* ---------- Bandeau cookies ---------- */
.cookie-banner {
  position: fixed; left: 12px; right: 12px; bottom: 12px; z-index: 90;
  background: var(--white); border: 1px solid var(--line); border-radius: var(--r-card);
  box-shadow: 0 18px 50px -24px rgba(23,33,30,.45); padding: 18px 18px 16px;
  display: none; max-width: 520px; margin: 0 auto;
}
.cookie-banner.show { display: block; }
.cookie-banner p { font-size: 14.5px; color: var(--ink-soft); }
.cookie-banner .actions { margin-top: 14px; }
.cookie-banner .btn { min-height: 44px; font-size: 15px; }

/* ---------- Barre d'action fixe (mobile, quand le formulaire n'est plus visible) ---------- */
.sticky-cta { position: fixed; left: 0; right: 0; bottom: 0; z-index: 80; padding: 10px 16px calc(10px + env(safe-area-inset-bottom)); background: rgba(243,245,249,.96); border-top: 1px solid var(--line); transform: translateY(110%); transition: transform .25s; }
.sticky-cta.show { transform: none; }
@media (min-width: 900px) { .sticky-cta { display: none; } }
.cookie-banner.show ~ .sticky-cta, .cookie-banner.show + script + .sticky-cta { display: none; }

/* ---------- Pages simples (merci, légal, 404) ---------- */
.page { padding: 56px 0 72px; }
.page-narrow { max-width: 720px; }
.page h1 { font-size: clamp(30px, 5vw, 44px); line-height: 1.05; font-weight: 800; letter-spacing: -0.02em; color: var(--pine); }
.page h2 { margin-top: 32px; font-size: 22px; font-weight: 800; }
.page p, .page li { margin-top: 12px; color: var(--ink-soft); }
.page ul { list-style: disc; padding-left: 22px; }
.ok-mark { width: 64px; height: 64px; border-radius: 50%; background: var(--ok); display: flex; align-items: center; justify-content: center; margin-bottom: 22px; }
.next-steps { list-style: none; padding-left: 0; margin-top: 26px; display: grid; gap: 14px; }
.next-steps li { display: flex; gap: 14px; align-items: flex-start; }
.next-steps .num { flex: 0 0 32px; height: 32px; border-radius: 50%; background: var(--sage); color: var(--pine); font-weight: 800; display: flex; align-items: center; justify-content: center; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
  html { scroll-behavior: auto; }
}
