/* =========================================================================
   ChapDevis — feuille de style unique (mobile-first, zéro dépendance)
   Marque : navy #1B2A4A + orange #F5A623
   Contraste WCAG AA : texte foncé sur fonds clairs ; CTA = texte navy sur orange
   ========================================================================= */

:root {
  --navy: #1B2A4A;
  --navy-deep: #142038;      /* variante plus sombre (fonds) */
  --orange: #F5A623;
  --orange-dark: #d98c0a;    /* survol du CTA, contraste renforcé */
  --ink: #16213a;            /* texte courant (≈ navy, AA sur blanc) */
  --muted: #5a6478;          /* texte secondaire */
  --bg: #ffffff;
  --bg-soft: #f4f6fb;        /* sections alternées */
  --line: #e2e6ef;
  --radius: 14px;
  --shadow: 0 6px 20px rgba(20, 32, 56, 0.12);
  --maxw: 960px;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

/* --- Reset léger --- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, p, ol, ul, figure { margin: 0; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--navy); }

.container {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: 20px;
}

/* Focus visible (accessibilité clavier) */
a:focus-visible,
summary:focus-visible,
.btn-download:focus-visible {
  outline: 3px solid var(--orange);
  outline-offset: 3px;
  border-radius: 6px;
}

/* =========================== HEADER =========================== */
.site-header {
  background: var(--navy);
  color: #fff;
  position: sticky;
  top: 0;
  z-index: 10;
}
.header-inner {
  display: flex;
  align-items: center;
  min-height: 60px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: #fff;
}
.brand-logo {
  display: block;
  width: 40px;
  height: 40px;
  border-radius: 9px;
  object-fit: cover;
}
.brand-name {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: 0.2px;
}

/* ============================ HERO ============================ */
.hero {
  background: linear-gradient(160deg, var(--navy) 0%, var(--navy-deep) 100%);
  color: #fff;
  text-align: center;
  padding: 40px 0 48px;
}
.hero-title {
  font-size: clamp(1.6rem, 6vw, 2.4rem);
  line-height: 1.2;
  font-weight: 800;
  max-width: 18ch;
  margin-inline: auto;
}
.hero-sub {
  margin-top: 12px;
  font-size: 1.05rem;
  color: #cdd6e8;
}

/* CTA principal — élément le plus proéminent de la page */
.btn-download {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  max-width: 420px;
  margin: 28px auto 0;
  padding: 18px 24px;
  background: var(--orange);
  color: var(--navy);          /* texte foncé sur orange => AA */
  font-size: 1.2rem;
  font-weight: 800;
  text-decoration: none;
  border-radius: var(--radius);
  box-shadow: 0 10px 28px rgba(245, 166, 35, 0.4);
  transition: transform 0.12s ease, background-color 0.12s ease, box-shadow 0.12s ease;
}
.btn-download:hover { background: var(--orange-dark); }
.btn-download:active { transform: translateY(1px) scale(0.995); }
.btn-download-icon {
  font-size: 1.35rem;
  line-height: 1;
  font-weight: 900;
}
/* Sous-texte du CTA principal : lisible mais informatif, sous le bouton. */
.btn-download-sub {
  margin-top: 10px;
  font-size: 0.95rem;
  color: #cdd6e8;          /* clair sur navy => AA */
}
.hero-note {
  margin-top: 10px;
  font-size: 0.92rem;
  color: #aeb9d2;          /* ~7:1 sur navy => AA */
}

/* Lien de secours : nettement dé-emphasé (pas de chrome de bouton, texte plus
   petit, couleur atténuée) mais toujours trouvable — souligné, contraste AA. */
.download-fallback {
  margin-top: 22px;
}
.link-fallback {
  color: #aeb9d2;          /* atténué mais ~7:1 sur navy => AA */
  font-size: 0.9rem;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.link-fallback:hover {
  color: #ffffff;
}

/* ======================= SECTIONS GÉNÉRIQUES ================= */
section { padding: 40px 0; }
.steps { background: var(--bg-soft); }
.install-help { background: var(--bg-soft); }

.section-title {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--navy);
  text-align: center;
  margin-bottom: 24px;
}

/* ====================== COMMENT ÇA MARCHE ==================== */
.steps-list {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 16px;
}
.step {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
  text-align: center;
}
.step-icon {
  font-size: 2rem;
  display: block;
  margin-bottom: 8px;
}
.step-title {
  font-size: 1.1rem;
  color: var(--navy);
  margin-bottom: 4px;
}
.step-text {
  color: var(--muted);
  font-size: 0.98rem;
}

/* ========================= CAPTURES ========================= */
/* Bande scrollable horizontalement sur mobile ; cadres téléphone en CSS pur. */
.shots-strip {
  display: flex;
  gap: 18px;
  overflow-x: auto;
  padding: 6px 2px 16px;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
}
.phone {
  flex: 0 0 auto;
  width: 172px;
  padding: 8px;
  background: var(--navy);
  border-radius: 24px;
  box-shadow: var(--shadow);
  scroll-snap-align: center;
}
.phone-screen {
  position: relative;
  aspect-ratio: 9 / 16;      /* correspond aux captures 720×1280 (pas de rognage) */
  border-radius: 16px;
  background: var(--bg-soft);
  overflow: hidden;
}
.phone-screen img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.phone-caption {
  margin-top: 10px;
  color: #fff;
  font-size: 0.85rem;
  font-weight: 600;
  text-align: center;
}

/* ====================== AIDE INSTALLATION =================== */
.note {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 4px 20px;
  max-width: 640px;
  margin-inline: auto;
}
.note-summary {
  cursor: pointer;
  font-weight: 700;
  color: var(--navy);
  padding: 16px 0;
  list-style: none;
  display: flex;
  align-items: center;
  gap: 8px;
}
.note-summary::-webkit-details-marker { display: none; }
.note-summary::before {
  content: "＋";
  color: var(--orange);
  font-weight: 900;
  font-size: 1.2rem;
  line-height: 1;
}
.note[open] .note-summary::before { content: "－"; }
.note-body { padding-bottom: 16px; }
.note-body p { margin-bottom: 12px; color: var(--ink); }
.note-steps {
  margin: 0 0 12px;
  padding-left: 22px;
  color: var(--ink);
}
.note-steps li { margin-bottom: 6px; }
.note-reassure {
  background: #fdf3df;
  border-left: 4px solid var(--orange);
  padding: 12px 14px;
  border-radius: 8px;
  font-weight: 600;
  color: var(--navy);
}
code {
  background: #eef1f8;
  padding: 1px 6px;
  border-radius: 5px;
  font-size: 0.9em;
}

/* =========================== FOOTER ========================= */
.site-footer {
  background: var(--navy);
  color: #cdd6e8;
  text-align: center;
  padding: 28px 0;
  font-size: 0.92rem;
}
.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  justify-content: center;
  margin-bottom: 14px;
}
.footer-links a { color: var(--orange); text-decoration: none; font-weight: 600; }
.footer-links a:hover { text-decoration: underline; }
.footer-contact { margin-bottom: 10px; }
.footer-contact a { color: #cdd6e8; }
.footer-copy { color: #8b97b4; }

/* ===================== DESKTOP (secondaire) ================= */
@media (min-width: 720px) {
  body { font-size: 18px; }
  .hero { padding: 64px 0 72px; }
  .steps-list { grid-template-columns: repeat(3, 1fr); gap: 22px; }
  .shots-strip { justify-content: center; flex-wrap: wrap; overflow-x: visible; }
  .section-title { font-size: 1.7rem; }
}

/* ==================== PAGES LÉGALES ========================= */
.legal-header {
  background: var(--navy);
  color: #fff;
  padding: 14px 0;
}
.legal-header .brand-name { font-size: 18px; }
.legal-main {
  max-width: 68ch;
  margin: 0 auto;
  padding: 28px 20px 60px;
}
.doc-updated {
  color: var(--muted);
  font-size: 0.92rem;
  border-bottom: 1px solid var(--line);
  padding-bottom: 14px;
  margin-bottom: 24px;
}
.doc-content { line-height: 1.75; }
.doc-content h1 {
  font-size: 1.7rem;
  color: var(--navy);
  margin: 28px 0 12px;
  line-height: 1.25;
}
.doc-content h1:first-child { margin-top: 0; }
.doc-content h2 {
  font-size: 1.25rem;
  color: var(--navy);
  margin: 26px 0 8px;
}
.doc-content p { margin: 0 0 14px; }
.doc-content ul { margin: 0 0 16px; padding-left: 24px; }
.doc-content li { margin-bottom: 6px; }
.doc-content strong { color: var(--navy); }
.doc-error { color: #b3261e; font-weight: 600; }
.back-link {
  display: inline-block;
  margin-top: 32px;
  color: var(--navy);
  font-weight: 600;
}

/* ================== MOUVEMENT RÉDUIT (a11y) ================= */
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; scroll-behavior: auto !important; }
}
