/* ============================================================================
   Radar Québec — feuille de style unique.
   Aucune dépendance, aucune police distante : tout est servi depuis le domaine.

   Sommaire
     1. Jetons (couleurs, typo, espacements)
     2. Réglages de base
     3. Pièces réutilisables (boutons, section, cartes)
     4. En-tête et navigation
     5. Héros
     6. Sections de contenu
     7. Formulaire de contact
     8. Pied de page
     9. Apparition au défilement, impression
   ========================================================================== */

/* --- 1. Jetons ----------------------------------------------------------- */

:root {
  color-scheme: light dark;

  /* Palette claire. Un bleu profond, celui des cartes et des registres : on
     vend des documents publics, pas un logiciel de plus. */
  --papier: #fbfaf7;
  --papier-2: #f3f1ea;
  --surface: #ffffff;
  --encre: #12191b;
  --encre-2: #45535a;
  --encre-3: #6d7b81;
  --trait: #e4e0d6;
  --trait-fort: #cec9bb;
  --accent: #1f4e8c;
  --accent-fort: #163a6a;
  --accent-doux: #e8eef9;
  --sauge: #2c6154;
  --sauge-doux: #e8f0ed;
  --ombre: 0 1px 2px rgb(18 25 27 / 4%), 0 8px 24px -12px rgb(18 25 27 / 14%);
  --ombre-forte: 0 2px 4px rgb(18 25 27 / 5%), 0 18px 40px -18px rgb(18 25 27 / 22%);

  --police: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto,
    "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  --police-mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas,
    "Liberation Mono", monospace;

  --r-s: 7px;
  --r-m: 14px;
  --r-l: 24px;

  --largeur: 1180px;
  --gouttiere: clamp(1.25rem, 4vw, 3rem);
  --hauteur-entete: 68px;
}

/* Le thème sombre s'applique par préférence système **et** par choix explicite.
   `:root[data-theme="dark"]` doit rester après le bloc média, sinon la bascule
   manuelle vers le sombre ne l'emporte pas sur un système réglé en clair. */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --papier: #0d1315;
    --papier-2: #121a1c;
    --surface: #17201f;
    --encre: #ecebe4;
    --encre-2: #a8b5b7;
    --encre-3: #7d8b8e;
    --trait: #27312f;
    --trait-fort: #37423f;
    --accent: #86b4f2;
    --accent-fort: #aacbf8;
    --accent-doux: #152338;
    --sauge: #74b6a3;
    --sauge-doux: #16221f;
    --ombre: 0 1px 2px rgb(0 0 0 / 30%), 0 8px 24px -12px rgb(0 0 0 / 60%);
    --ombre-forte: 0 2px 4px rgb(0 0 0 / 35%), 0 18px 40px -18px rgb(0 0 0 / 70%);
  }
}

:root[data-theme="dark"] {
  --papier: #0d1315;
  --papier-2: #121a1c;
  --surface: #17201f;
  --encre: #ecebe4;
  --encre-2: #a8b5b7;
  --encre-3: #7d8b8e;
  --trait: #27312f;
  --trait-fort: #37423f;
  --accent: #86b4f2;
  --accent-fort: #aacbf8;
  --accent-doux: #152338;
  --sauge: #74b6a3;
  --sauge-doux: #16221f;
  --ombre: 0 1px 2px rgb(0 0 0 / 30%), 0 8px 24px -12px rgb(0 0 0 / 60%);
  --ombre-forte: 0 2px 4px rgb(0 0 0 / 35%), 0 18px 40px -18px rgb(0 0 0 / 70%);
}

/* --- 2. Réglages de base ------------------------------------------------- */

/* `hidden` doit l'emporter sur le `display` des classes (.bouton, .section…) :
   sert à masquer une zone gardée dans le HTML (ex. #abonnements). */
[hidden] {
  display: none !important;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--papier);
  color: var(--encre);
  font-family: var(--police);
  font-size: 1.0625rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-wrap: break-word;
}

h1,
h2,
h3,
h4 {
  margin: 0;
  line-height: 1.12;
  letter-spacing: -0.022em;
  font-weight: 680;
  text-wrap: balance;
}

p {
  margin: 0;
}

a {
  color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

a:hover {
  color: var(--accent-fort);
}

img,
svg {
  max-width: 100%;
}

/* `ol` autant que `ul` : oublié, le retrait de 40 px d'une liste ordonnée
   rétrécit sa grille d'une colonne entière (les quatre étapes de l'approche
   passaient à trois par rangée), et ses puces décimales se superposent aux
   numéros dessinés par le compteur CSS. */
ul,
ol {
  margin: 0;
  padding: 0;
  list-style: none;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 3px;
}

.contenant {
  width: 100%;
  max-width: var(--largeur);
  margin-inline: auto;
  padding-inline: var(--gouttiere);
}

/* Lien d'évitement : premier élément focalisable de la page. */
.saut-contenu {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 100;
  padding: 0.75rem 1.25rem;
  background: var(--accent);
  color: #fff;
  border-radius: 0 0 var(--r-s) 0;
  font-weight: 600;
  text-decoration: none;
}

.saut-contenu:focus {
  left: 0;
  color: #fff;
}

/* Le porteur du <symbol> du logo. Sans cette règle il occuperait la taille par
   défaut d'un <svg> sans dimensions — 300 × 150 px de blanc en haut de page. */
.svg-defs {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

/* Réservé aux lecteurs d'écran. */
.hors-ecran {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* --- 3. Pièces réutilisables --------------------------------------------- */

.bouton {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.72rem 1.35rem;
  border: 1px solid transparent;
  border-radius: 999px;
  font: inherit;
  font-size: 0.975rem;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.18s ease, border-color 0.18s ease,
    color 0.18s ease, transform 0.18s ease;
}

.bouton:active {
  transform: translateY(1px);
}

.bouton--primaire {
  background: var(--accent);
  color: #fff;
}

.bouton--primaire:hover {
  background: var(--accent-fort);
  color: #fff;
}

/* En thème sombre l'accent s'éclaircit : du blanc dessus deviendrait illisible. */
:root[data-theme="dark"] .bouton--primaire,
:root[data-theme="dark"] .saut-contenu {
  color: #0b1526;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .bouton--primaire,
  :root:not([data-theme="light"]) .saut-contenu {
    color: #0b1526;
  }
}

.bouton--fantome {
  background: transparent;
  border-color: var(--trait-fort);
  color: var(--encre);
}

.bouton--fantome:hover {
  border-color: var(--encre-2);
  background: var(--surface);
  color: var(--encre);
}

.bouton--large {
  width: 100%;
}

.surtitre {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  margin: 0 0 1rem;
  font-family: var(--police-mono);
  font-size: 0.775rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
}

.surtitre::before {
  content: "";
  width: 1.6rem;
  height: 1px;
  background: currentColor;
  opacity: 0.5;
}

.section {
  padding-block: clamp(2.25rem, 4.5vw, 3.75rem);
  scroll-margin-top: calc(var(--hauteur-entete) + 12px);
}

.section--teinte {
  background: var(--papier-2);
  border-block: 1px solid var(--trait);
}

.section-entete {
  max-width: 46rem;
  margin-bottom: clamp(1.5rem, 3vw, 2.25rem);
}

.section-titre {
  font-size: clamp(1.85rem, 1.25rem + 2.4vw, 2.85rem);
}

.section-intro {
  margin-top: 0.8rem;
  font-size: clamp(1.02rem, 0.98rem + 0.3vw, 1.18rem);
  color: var(--encre-2);
  max-width: 40rem;
  text-wrap: pretty;
}

.carte {
  background: var(--surface);
  border: 1px solid var(--trait);
  border-radius: var(--r-m);
  padding: clamp(1.15rem, 2vw, 1.5rem);
}

/* --- 4. En-tête et navigation -------------------------------------------- */

.entete {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--papier) 86%, transparent);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

/* Classe posée par le script dès que la page a défilé : au repos, l'en-tête
   doit se fondre dans le héros, pas le souligner d'un trait. */
.entete.est-detachee {
  border-bottom-color: var(--trait);
  box-shadow: var(--ombre);
}

.entete-barre {
  display: flex;
  align-items: center;
  gap: 1rem;
  min-height: var(--hauteur-entete);
}

.marque {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--encre);
  font-size: 1.075rem;
  font-weight: 660;
  letter-spacing: -0.02em;
  text-decoration: none;
  flex: none;
}

.marque:hover {
  color: var(--encre);
}

.marque-logo {
  width: 30px;
  height: 30px;
  color: var(--accent);
  flex: none;
}

.nav {
  margin-left: auto;
}

.nav-liste {
  display: flex;
  align-items: center;
  gap: clamp(0.5rem, 1.6vw, 1.4rem);
}

.nav-lien {
  display: block;
  padding: 0.45rem 0.35rem;
  color: var(--encre-2);
  font-size: 0.945rem;
  font-weight: 550;
  text-decoration: none;
  border-bottom: 2px solid transparent;
  transition: color 0.15s ease, border-color 0.15s ease;
}

.nav-lien:hover,
.nav-lien.est-active {
  color: var(--encre);
  border-bottom-color: var(--accent);
}

.nav-cta {
  display: none;
}

.entete-outils {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  flex: none;
}

/* « Demander une démo » sur une seule ligne, jamais coupé en deux. */
.entete-cta {
  white-space: nowrap;
}

/* Accueil, sur grand écran : le menu au centre exact de la barre, le logo à
   gauche, les outils à droite. Trois colonnes, les deux extrêmes de même
   largeur : le menu reste centré quelle que soit la largeur du logo ou des
   outils. Sous 1 000 px, le menu redevient un panneau (voir plus bas). */
@media (min-width: 1001px) {
  .entete-barre--centree {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
  }

  .entete-barre--centree .marque {
    justify-self: start;
  }

  .entete-barre--centree .nav {
    margin-left: 0;
  }

  .entete-barre--centree .entete-outils {
    justify-self: end;
  }
}

/* Pages sans navigation (confidentialité, 404) : c'est le bloc d'outils qui
   doit être poussé à droite, faute de `.nav` pour le faire. */
.entete-outils--seules {
  margin-left: auto;
}

.langues {
  display: flex;
  align-items: center;
  border: 1px solid var(--trait);
  border-radius: 999px;
  overflow: hidden;
  background: var(--surface);
}

.lien-langue {
  padding: 0.3rem 0.6rem;
  font-family: var(--police-mono);
  font-size: 0.735rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--encre-3);
  text-decoration: none;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.lien-langue:hover {
  color: var(--encre);
  background: var(--papier-2);
}

.lien-langue[aria-current="true"] {
  background: var(--encre);
  color: var(--papier);
}

.bascule-theme,
.bascule-menu {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  padding: 0;
  background: var(--surface);
  border: 1px solid var(--trait);
  border-radius: 999px;
  color: var(--encre-2);
  cursor: pointer;
  transition: color 0.15s ease, border-color 0.15s ease;
}

.bascule-theme:hover,
.bascule-menu:hover {
  color: var(--encre);
  border-color: var(--trait-fort);
}

.bascule-menu {
  display: none;
}

/* L'icône affichée dépend du thème courant : une seule est visible à la fois. */
.icone-soleil {
  display: none;
}

:root[data-theme="dark"] .icone-soleil {
  display: block;
}

:root[data-theme="dark"] .icone-lune {
  display: none;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .icone-soleil {
    display: block;
  }

  :root:not([data-theme="light"]) .icone-lune {
    display: none;
  }
}

/* Panneau sous 1 000 px (et non 900) depuis l'ajout de « Notre plateforme » :
   cinq liens plus le bouton ne tiennent plus sur une ligne en dessous. */
@media (max-width: 1000px) {
  .bascule-menu {
    display: inline-flex;
  }

  .entete-cta {
    display: none;
  }

  /* Le menu devient un panneau sous la barre. `visibility` en plus de
     l'opacité : sans elle, les liens restent cliquables une fois « fermés ». */
  .nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    margin: 0;
    padding: 0.5rem var(--gouttiere) 1.25rem;
    background: var(--papier);
    border-bottom: 1px solid var(--trait);
    box-shadow: var(--ombre-forte);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity 0.18s ease, transform 0.18s ease,
      visibility 0s linear 0.18s;
  }

  .nav[data-ouvert="true"] {
    opacity: 1;
    visibility: visible;
    transform: none;
    transition-delay: 0s;
  }

  .nav-liste {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    max-width: var(--largeur);
    margin-inline: auto;
  }

  .nav-lien {
    padding: 0.85rem 0;
    font-size: 1.05rem;
    border-bottom: 1px solid var(--trait);
  }

  .nav-lien:hover,
  .nav-lien.est-active {
    border-bottom-color: var(--trait);
    color: var(--accent);
  }

  .nav-cta {
    display: block;
    margin-top: 1.1rem;
  }
}

/* --- 5. Héros ------------------------------------------------------------ */

.heros {
  position: relative;
  overflow: hidden;
  padding-block: clamp(2.5rem, 6vw, 4.5rem) clamp(2.5rem, 5vw, 3.75rem);
  border-bottom: 1px solid var(--trait);
}

/* L'écran radar : un masque, pas une image. Le SVG ne sert que de canal
   alpha, la couleur vient d'ici — donc elle suit le thème. Le garde
   `@supports` évite le carré plein sur un navigateur sans `mask-image`. */
.radar {
  position: absolute;
  inset: -20% -10% auto auto;
  width: min(115vh, 1000px);
  aspect-ratio: 1;
  pointer-events: none;
  display: none;
}

@supports (mask-image: url("radar.svg")) or
  (-webkit-mask-image: url("radar.svg")) {
  .radar {
    display: block;
    background-color: var(--accent);
    opacity: 0.16;
    -webkit-mask: url("radar.svg") center / contain no-repeat;
    mask: url("radar.svg") center / contain no-repeat;
  }
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .radar {
    opacity: 0.22;
  }
}

:root[data-theme="dark"] .radar {
  opacity: 0.22;
}

.heros-contenu {
  position: relative;
  /* 50rem : la première ligne du titre (« Ce que les municipalités décident, »)
     tient sur UNE ligne à 3.5rem ; le titre est sur deux lignes dès ~700px. */
  max-width: 50rem;
}

.heros-titre {
  font-size: clamp(2.4rem, 1.2rem + 3.4vw, 3.5rem);
  letter-spacing: -0.033em;
}

.heros-titre em {
  font-style: normal;
  color: var(--accent);
}

.heros-accroche {
  margin-top: 1.5rem;
  font-size: clamp(1.075rem, 1rem + 0.55vw, 1.32rem);
  line-height: 1.6;
  color: var(--encre-2);
  max-width: 34rem;
  text-wrap: pretty;
}

/* Paragraphes successifs de l'accroche : moins d'écart qu'entre le titre et le premier. */
.heros-accroche + .heros-accroche {
  margin-top: 0.75rem;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 2.25rem;
}

/* Trois affirmations sous le héros : ce qui distingue, pas des statistiques
   inventées. */
.faits {
  position: relative;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  gap: 1px;
  margin-top: clamp(2rem, 4.5vw, 3rem);
  background: var(--trait);
  border: 1px solid var(--trait);
  border-radius: var(--r-m);
  overflow: hidden;
}

.fait {
  background: var(--surface);
  padding: 1.5rem;
}

.fait-titre {
  font-size: 1.02rem;
  font-weight: 640;
}

.fait-texte {
  margin-top: 0.4rem;
  font-size: 0.94rem;
  color: var(--encre-2);
}

/* --- 6. Sections de contenu ---------------------------------------------- */

/* Services */
.services {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 18.5rem), 1fr));
  gap: clamp(1rem, 2vw, 1.5rem);
}

/* Deux grilles de cartes à la suite (Données : 01-03 puis 04-09) : le même écart qu'entre deux cartes. */
.services + .services {
  margin-top: clamp(1rem, 2vw, 1.5rem);
}

.service {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  transition: border-color 0.18s ease, box-shadow 0.18s ease,
    transform 0.18s ease;
}

.service:hover {
  border-color: var(--trait-fort);
  box-shadow: var(--ombre);
  transform: translateY(-2px);
}

.service-num {
  font-family: var(--police-mono);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  color: var(--accent);
}

.service-titre {
  font-size: 1.19rem;
  letter-spacing: -0.015em;
}

.service-texte {
  color: var(--encre-2);
  font-size: 0.97rem;
}

.service-liste {
  margin-top: auto;
  padding-top: 0.75rem;
  border-top: 1px dashed var(--trait);
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.75rem;
  font-size: 0.855rem;
  color: var(--encre-3);
}

.service-liste li {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.service-liste li::before {
  content: "";
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--sauge);
  flex: none;
}

/* Approche */
.etapes {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 15rem), 1fr));
  gap: clamp(1.25rem, 3vw, 2.25rem);
  counter-reset: etape;
}

.etape {
  position: relative;
  padding-top: 2.5rem;
  border-top: 2px solid var(--trait-fort);
  counter-increment: etape;
}

.etape::before {
  content: counter(etape, decimal-leading-zero);
  position: absolute;
  top: 0.9rem;
  left: 0;
  font-family: var(--police-mono);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  color: var(--accent);
}

.etape::after {
  content: "";
  position: absolute;
  top: -2px;
  left: 0;
  width: 2.5rem;
  height: 2px;
  background: var(--accent);
}

.etape-titre {
  font-size: 1.15rem;
}

.etape-texte {
  margin-top: 0.65rem;
  color: var(--encre-2);
  font-size: 0.97rem;
}

/* Technologies */
.piles {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 16rem), 1fr));
  gap: clamp(1.25rem, 2.5vw, 2rem);
}

.pile-titre {
  font-family: var(--police-mono);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--encre-3);
  padding-bottom: 0.75rem;
  margin-bottom: 1rem;
  border-bottom: 1px solid var(--trait);
}

.jetons {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.jeton {
  padding: 0.32rem 0.7rem;
  background: var(--surface);
  border: 1px solid var(--trait);
  border-radius: var(--r-s);
  font-size: 0.855rem;
  color: var(--encre-2);
}

.note-pile {
  margin-top: clamp(2rem, 4vw, 3rem);
  padding: 1.15rem 1.35rem;
  background: var(--sauge-doux);
  border-left: 3px solid var(--sauge);
  border-radius: 0 var(--r-s) var(--r-s) 0;
  font-size: 0.96rem;
  color: var(--encre-2);
  max-width: 46rem;
}

/* Mandats types */
.mandats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 19rem), 1fr));
  gap: clamp(1rem, 2vw, 1.5rem);
}

/* Quatre cartes (section Méthode) : un minimum plus bas pour qu'elles
   tiennent sur une rangée à 1 180 px, au lieu de trois plus une. */
.mandats--quatre {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 15rem), 1fr));
}

.mandat {
  display: flex;
  flex-direction: column;
}

.mandat-etiquette {
  align-self: flex-start;
  padding: 0.22rem 0.6rem;
  margin-bottom: 1rem;
  background: var(--accent-doux);
  border-radius: 999px;
  font-family: var(--police-mono);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--accent-fort);
}

:root[data-theme="dark"] .mandat-etiquette {
  color: var(--accent);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .mandat-etiquette {
    color: var(--accent);
  }
}

.mandat-titre {
  font-size: 1.12rem;
}

.mandat-texte {
  margin-top: 0.7rem;
  color: var(--encre-2);
  font-size: 0.97rem;
}

/* Exemples sous le texte d'une carte (section Nos services). */
.mandat-liste {
  margin: 0.9rem 0 0;
  padding: 0.9rem 0 0;
  list-style: none;
  border-top: 1px solid var(--trait);
  display: grid;
  gap: 0.45rem;
  color: var(--encre-2);
  font-size: 0.93rem;
}

.mandat-liste li {
  position: relative;
  padding-left: 1.1rem;
}

.mandat-liste li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.62em;
  width: 0.4rem;
  height: 0.4rem;
  border-radius: 50%;
  background: var(--accent);
}

/* À propos */
.apropos {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: clamp(2rem, 5vw, 4rem);
  align-items: start;
}

@media (max-width: 820px) {
  .apropos {
    grid-template-columns: 1fr;
  }
}

.apropos-texte p + p {
  margin-top: 1.1rem;
}

.apropos-texte p {
  color: var(--encre-2);
  font-size: 1.03rem;
  text-wrap: pretty;
}

/* Le premier paragraphe suit directement le titre de section : sans marge il
   s'y colle, et `p + p` ne le rattrape pas. Vaut aussi pour le bloc contact. */
.apropos-texte .section-titre + p,
.contact-infos .section-titre + p {
  margin-top: 1.15rem;
}

.apropos-liste li {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.85rem;
  padding: 0.7rem 0;
  border-bottom: 1px solid var(--trait);
  font-size: 0.97rem;
}

.apropos-liste li:first-child {
  border-top: 1px solid var(--trait);
}

.apropos-liste svg {
  width: 20px;
  height: 20px;
  margin-top: 0.15rem;
  color: var(--sauge);
  flex: none;
}

/* FAQ */
.faq {
  max-width: 48rem;
}

.faq-item {
  border-bottom: 1px solid var(--trait);
}

.faq-item summary {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1.5rem;
  padding: 0.95rem 0;
  font-size: 1.06rem;
  font-weight: 620;
  cursor: pointer;
  list-style: none;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "";
  width: 11px;
  height: 11px;
  margin-top: 0.4rem;
  border-right: 2px solid var(--accent);
  border-bottom: 2px solid var(--accent);
  transform: rotate(45deg);
  transition: transform 0.2s ease;
  flex: none;
}

.faq-item[open] summary::after {
  transform: rotate(-135deg);
  margin-top: 0.65rem;
}

.faq-reponse {
  padding-bottom: 1.4rem;
  color: var(--encre-2);
  font-size: 0.99rem;
  max-width: 44rem;
}

/* Chiffres clés : quatre nombres sous l'intro de la section Données. */
.chiffres {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 11rem), 1fr));
  gap: 1px;
  margin-bottom: clamp(1.5rem, 3vw, 2rem);
  background: var(--trait);
  border: 1px solid var(--trait);
  border-radius: var(--r-m);
  overflow: hidden;
}

/* Rangées de chiffres successives : serrées entre elles. */
.chiffres:has(+ .chiffres) {
  margin-bottom: 0.75rem;
}

.chiffre {
  background: var(--surface);
  padding: 1rem 1.35rem;
}

.chiffre-valeur {
  font-family: var(--police-mono);
  font-size: clamp(1.6rem, 1.2rem + 1.4vw, 2.3rem);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.1;
  color: var(--accent);
}

.chiffre-texte {
  margin-top: 0.35rem;
  font-size: 0.9rem;
  color: var(--encre-2);
}

/* Ce que porte chaque document : une liste à coches, après les trois cartes. */
.contenu-document {
  margin-top: clamp(1.5rem, 3vw, 2.25rem);
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: clamp(1.5rem, 4vw, 3rem);
  align-items: start;
}

@media (max-width: 820px) {
  .contenu-document {
    grid-template-columns: 1fr;
  }
}

.contenu-document h3 {
  font-size: 1.3rem;
}

.contenu-document p {
  margin-top: 0.8rem;
  color: var(--encre-2);
}

/* Abonnements */
/* Abonnements : grille automatique ; au-dessus de 1 100 px, voir plus bas. */
.offres {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 13.25rem), 1fr));
  gap: clamp(1rem, 2vw, 1.5rem);
  margin-top: clamp(1.5rem, 3vw, 2.25rem);
}

.offre {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}

/* Le palier qu'on met en avant : bordure accent, pas une couleur de fond qui
   le ferait passer pour un bouton. */
.offre--phare {
  border-color: var(--accent);
  box-shadow: var(--ombre-forte);
}

.offre-nom {
  font-size: 1.15rem;
  letter-spacing: -0.015em;
}

.offre-prix {
  margin-top: 0.3rem;
  font-family: var(--police-mono);
  font-size: 1.85rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1;
}

.offre-prix small {
  margin-left: 0.3rem;
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--encre-3);
}

.offre-pour {
  color: var(--encre-2);
  font-size: 0.95rem;
}

.offre-liste {
  margin-top: auto;
  padding-top: 1rem;
  border-top: 1px dashed var(--trait);
  display: grid;
  gap: 0.4rem;
  font-size: 0.9rem;
  color: var(--encre-2);
}

.offre-liste li {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.55rem;
  align-items: start;
}

.offre-liste li::before {
  content: "";
  width: 6px;
  height: 6px;
  margin-top: 0.55rem;
  border-radius: 50%;
  background: var(--sauge);
}

/* Cinq paliers, tous verticaux, sur UNE rangée dès que la page est assez
   large : les cartes se resserrent (marges, prix, titre) plutôt que de
   laisser le cinquième seul en dessous. En dessous de 1 100 px, la grille
   automatique reprend (3 + 2, puis 2 + 2 + 1, puis une colonne). */
@media (min-width: 1100px) {
  .offres {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 1rem;
  }

  .offre {
    padding: 1.3rem 1.15rem;
  }

  .offre-nom {
    font-size: 1.05rem;
  }

  .offre-prix {
    font-size: 1.55rem;
  }

  /* « / mois » passe sous le montant : sur 160 px de large, « 3 500 $ / mois »
     se coupait n'importe où. */
  .offre-prix small {
    display: block;
    margin: 0.35rem 0 0;
  }
}

.offres-note {
  margin-top: clamp(1.5rem, 3vw, 2.25rem);
  max-width: 52rem;
  font-size: 0.93rem;
  color: var(--encre-2);
}

.offres-note p + p {
  margin-top: 0.6rem;
}

/* --- 7. Formulaire de contact -------------------------------------------- */

.contact {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  gap: clamp(2rem, 5vw, 4rem);
  align-items: start;
}

@media (max-width: 880px) {
  .contact {
    grid-template-columns: 1fr;
  }
}

.contact-infos p {
  color: var(--encre-2);
  max-width: 30rem;
}

.contact-liste {
  margin-top: 2rem;
}

.contact-liste li + li {
  margin-top: 1.25rem;
}

.contact-etiquette {
  display: block;
  font-family: var(--police-mono);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: var(--encre-3);
  margin-bottom: 0.2rem;
}

.contact-valeur {
  font-size: 1.02rem;
  font-weight: 550;
}

.formulaire {
  background: var(--surface);
  border: 1px solid var(--trait);
  border-radius: var(--r-m);
  padding: clamp(1.4rem, 3vw, 2.25rem);
  box-shadow: var(--ombre);
}

.duo {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 13rem), 1fr));
  gap: 1.1rem;
}

.champ {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  margin-bottom: 1.1rem;
}

.duo .champ {
  margin-bottom: 0;
}

/* Les `.champ` d'une rangée n'ont pas de marge basse (c'est la grille qui
   espace) : sans cette règle, deux rangées successives se collent. */
.duo + .duo,
.duo + .champ {
  margin-top: 1.1rem;
}

.etiquette {
  font-size: 0.885rem;
  font-weight: 600;
  color: var(--encre);
}

.etiquette .facultatif {
  font-weight: 400;
  color: var(--encre-3);
}

.saisie {
  width: 100%;
  padding: 0.68rem 0.85rem;
  background: var(--papier);
  border: 1px solid var(--trait-fort);
  border-radius: var(--r-s);
  color: var(--encre);
  font: inherit;
  font-size: 0.97rem;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.saisie:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 18%, transparent);
}

textarea.saisie {
  min-height: 8.5rem;
  resize: vertical;
}

select.saisie {
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, currentColor 50%),
    linear-gradient(135deg, currentColor 50%, transparent 50%);
  background-position: calc(100% - 18px) 52%, calc(100% - 13px) 52%;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
  padding-right: 2.25rem;
}

/* Message d'erreur par champ, posé par le script. Réservé en hauteur : sans
   ça, l'apparition d'une erreur décale tout le formulaire d'un cran. */
.erreur {
  min-height: 1.1rem;
  font-size: 0.83rem;
  color: #c0392b;
}

:root[data-theme="dark"] .erreur {
  color: #f08a7d;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .erreur {
    color: #f08a7d;
  }
}

.saisie[aria-invalid="true"] {
  border-color: #c0392b;
}

/* Piège à pourriel : invisible à l'œil, rempli par les robots. `display:none`
   suffirait, mais certains robots ignorent les champs ainsi masqués. */
.pot-de-miel {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.mention-formulaire {
  margin-top: 1rem;
  font-size: 0.82rem;
  color: var(--encre-3);
}

.retour-formulaire {
  margin-top: 1.1rem;
  padding: 0.85rem 1rem;
  border-radius: var(--r-s);
  font-size: 0.92rem;
  border: 1px solid transparent;
}

.retour-formulaire:empty {
  display: none;
}

.retour-formulaire[data-etat="succes"] {
  background: var(--sauge-doux);
  border-color: var(--sauge);
  color: var(--encre);
}

.retour-formulaire[data-etat="echec"],
.retour-formulaire[data-etat="config"] {
  background: var(--accent-doux);
  border-color: var(--accent);
  color: var(--encre);
}

/* Page « Demande de démo » (demo.html) : la grille de .contact, le titre et
   ses promesses à gauche, le formulaire à droite. */
.demo {
  padding-block: clamp(2.5rem, 5vw, 4rem);
}

/* Les trois promesses sous le titre : une par ligne, une coche devant. */
.demo-points {
  margin-top: 0.9rem;
  display: grid;
  gap: 0.4rem;
  font-size: clamp(1.02rem, 0.98rem + 0.25vw, 1.12rem);
  color: var(--encre-2);
}

.demo-points li {
  display: grid;
  grid-template-columns: 1.1rem 1fr;
  gap: 0.6rem;
  align-items: baseline;
}

.demo-points li::before {
  content: "✓";
  color: var(--sauge);
  font-weight: 700;
}







.obligatoire {
  color: var(--accent);
}

.aide-champ {
  margin-top: 0.4rem;
  margin-bottom: 1.1rem;
  font-size: 0.82rem;
  color: var(--encre-3);
}

/* Case à cocher et son texte : la case en haut à gauche du paragraphe. */
.case {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.65rem;
  align-items: start;
  font-size: 0.88rem;
  color: var(--encre-2);
  cursor: pointer;
}

.case input {
  width: 1.05rem;
  height: 1.05rem;
  margin-top: 0.2rem;
  accent-color: var(--accent);
}

/* --- 8. Pied de page ----------------------------------------------------- */

.pied {
  background: var(--papier-2);
  border-top: 1px solid var(--trait);
  padding-block: clamp(3rem, 6vw, 4.5rem) 2rem;
}

.pied-haut {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) repeat(auto-fit, minmax(9rem, 1fr));
  gap: clamp(2rem, 4vw, 3.5rem);
  padding-bottom: 2.5rem;
  border-bottom: 1px solid var(--trait);
}

@media (max-width: 700px) {
  .pied-haut {
    grid-template-columns: 1fr 1fr;
  }

  .pied-marque {
    grid-column: 1 / -1;
  }
}

.pied-devise {
  margin-top: 0.9rem;
  font-size: 0.94rem;
  color: var(--encre-2);
  max-width: 24rem;
}

.pied-titre {
  font-family: var(--police-mono);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: var(--encre-3);
  margin-bottom: 0.9rem;
}

.pied-liste li + li {
  margin-top: 0.5rem;
}

/* `inline-block` + rembourrage vertical pour amener la zone cliquable à 24 px
   de haut (WCAG 2.5.8). Un lien de pied de page est une cible isolée, pas un
   lien au fil d'une phrase : l'exemption « inline » ne s'y applique pas. */
.pied-liste a,
.pied-bas a,
.contact-valeur {
  display: inline-block;
  padding-block: 0.2rem;
}

.pied-liste a {
  color: var(--encre-2);
  font-size: 0.94rem;
  text-decoration: none;
}

.pied-liste a:hover {
  color: var(--accent);
  text-decoration: underline;
}

.pied-bas {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-top: 1.5rem;
  font-size: 0.86rem;
  color: var(--encre-3);
}

.pied-bas a {
  color: var(--encre-3);
}

/* --- 9. Pages de texte (confidentialité, 404) ---------------------------- */

.doc {
  max-width: 44rem;
  padding-block: clamp(3rem, 7vw, 5.5rem);
}

.doc-titre {
  font-size: clamp(1.9rem, 1.4rem + 2vw, 2.7rem);
}

.doc-date {
  margin-top: 0.85rem;
  font-family: var(--police-mono);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--encre-3);
}

.doc h2 {
  margin-top: 2.75rem;
  font-size: 1.28rem;
}

.doc h2 + p {
  margin-top: 0.9rem;
}

.doc p,
.doc li {
  color: var(--encre-2);
}

.doc p + p,
.doc p + ul,
.doc ul + p {
  margin-top: 1rem;
}

.doc ul {
  padding-left: 1.15rem;
  list-style: disc;
}

.doc li {
  margin-top: 0.4rem;
}

/* À remplacer par les mentions réelles avant la mise en ligne — le fond jaune
   est là pour qu'on ne puisse pas les oublier. */
.a-completer {
  background: #fff3c4;
  color: #4a3a00;
  padding: 0.05em 0.3em;
  border-radius: 3px;
  font-weight: 600;
}

:root[data-theme="dark"] .a-completer {
  background: #4a3d10;
  color: #ffe9a3;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .a-completer {
    background: #4a3d10;
    color: #ffe9a3;
  }
}

/* Page 404 : centrée, sans le reste du site autour. */
.page-centree {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1.25rem;
  min-height: 78vh;
  text-align: center;
  padding-block: 4rem;
}

.page-centree-surtitre {
  font-family: var(--police-mono);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  color: var(--accent);
}

.page-centree-titre {
  font-size: clamp(1.8rem, 1.3rem + 2vw, 2.6rem);
}

.page-centree-texte {
  color: var(--encre-2);
  max-width: 30rem;
}

/* --- 10. Apparition au défilement, impression ---------------------------- */

/* L'état de départ n'est posé que si le script tourne (classe sur <html>) :
   sans JavaScript, rien n'est masqué et la page reste entière. */
.js .a-reveler {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.55s ease, transform 0.55s ease;
}

.js .a-reveler.est-visible {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .js .a-reveler {
    opacity: 1;
    transform: none;
  }
}

@media print {
  .entete,
  .radar,
  .actions,
  .formulaire,
  .bascule-theme,
  .bascule-menu {
    display: none !important;
  }

  body {
    background: #fff;
    color: #000;
    font-size: 11pt;
  }

  .section {
    padding-block: 1.5rem;
    break-inside: avoid;
  }

  .faq-item[open] .faq-reponse,
  .faq-reponse {
    display: block;
  }
}
