/* Nevesadur — feuille de style du site nevesadur.fr. Polices hébergées ici même : aucun appel à un service tiers, aucun cookie. */
@font-face { font-family: 'Figtree'; src: url('/polices/Figtree-Regular.ttf') format('truetype'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'Figtree'; src: url('/polices/Figtree-SemiBold.ttf') format('truetype'); font-weight: 600; font-display: swap; }
@font-face { font-family: 'Figtree'; src: url('/polices/Figtree-Bold.ttf') format('truetype'); font-weight: 700; font-display: swap; }
@font-face { font-family: 'Bricolage Grotesque'; src: url('/polices/BricolageGrotesque-Bold.ttf') format('truetype'); font-weight: 700 800; font-display: swap; }

:root {
  --fond: #FAF7F2;
  --fond-2: #F1EBE2;
  --surface: #FFFFFF;
  --encre: #1E2A27;
  --gris: #4F5B57;
  --filet: #E6DED2;
  --sapin: #1F5C4F;
  --sapin-fonce: #163F37;
  --sapin-doux: #DCEBE6;
  --abricot: #F2A65A;
  --abricot-doux: #FDE9D3;
  --abricot-texte: #7A4410;
  --titre: 'Bricolage Grotesque', 'Avenir Next', system-ui, sans-serif;
  --texte: 'Figtree', 'Helvetica Neue', system-ui, sans-serif;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --fond: #121816; --fond-2: #18201D; --surface: #1C2522; --encre: #EDE8E0; --gris: #A9B3AE; --filet: #2F3B37;
    --sapin: #7FC2AF; --sapin-fonce: #A8D8C9; --sapin-doux: #1F3A33; --abricot-doux: #3A2A1A; --abricot-texte: #F6C38E;
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; background: var(--fond); color: var(--encre); font-family: var(--texte); font-size: 17px; line-height: 1.6; }
a { color: var(--sapin); text-underline-offset: 3px; }
a:focus-visible, button:focus-visible, summary:focus-visible { outline: 2px solid var(--abricot); outline-offset: 3px; border-radius: 6px; }
img { max-width: 100%; display: block; }
[id] { scroll-margin-top: 90px; }

.conteneur { max-width: 1120px; margin: 0 auto; padding-left: max(16px, env(safe-area-inset-left)); padding-right: max(16px, env(safe-area-inset-right)); }

/* En-tête */
header.site { position: sticky; top: 0; z-index: 10; background: color-mix(in srgb, var(--fond) 92%, transparent); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); border-bottom: 1px solid var(--filet); }
header.site .conteneur { display: flex; align-items: center; justify-content: space-between; gap: 12px 20px; padding-block: 12px; flex-wrap: wrap; }
.marque { display: inline-flex; align-items: center; gap: 10px; font-family: var(--titre); font-weight: 700; font-size: 22px; color: var(--encre); text-decoration: none; letter-spacing: -0.2px; }
.marque svg { width: 34px; height: 34px; flex-shrink: 0; }
nav.principale { display: flex; align-items: center; gap: 6px 20px; flex-wrap: wrap; font-size: 15.5px; }
nav.principale a { color: var(--gris); text-decoration: none; font-weight: 600; }
nav.principale a:hover, nav.principale a[aria-current="page"] { color: var(--encre); }
nav.principale a.connexion { color: var(--sapin); border: 1.5px solid var(--sapin); border-radius: 999px; padding: 6px 14px; }
nav.principale a.connexion:hover { background: var(--sapin); color: var(--fond); }
@media (max-width: 720px) { nav.principale .secondaire { display: none; } }

/* Typographie */
h1, h2, h3 { font-family: var(--titre); font-weight: 700; line-height: 1.08; letter-spacing: -0.5px; text-wrap: balance; margin: 0; }
h1 { font-size: clamp(38px, 6.2vw, 64px); font-weight: 800; letter-spacing: -1.4px; }
h2 { font-size: clamp(28px, 4vw, 40px); letter-spacing: -0.8px; }
h3 { font-size: 21px; letter-spacing: -0.2px; }
p { margin: 0; }
.chapeau { font-size: clamp(18px, 2.2vw, 21px); color: var(--gris); max-width: 60ch; }
.surtitre { font-size: 13px; font-weight: 700; letter-spacing: 1.3px; text-transform: uppercase; color: var(--sapin); }
.note { font-size: 14.5px; color: var(--gris); }

/* Sections */
main section.bande { padding-block: clamp(56px, 8vw, 96px); }
main section.bande.teinte { background: var(--fond-2); }
.entete-section { display: flex; flex-direction: column; gap: 14px; margin-bottom: 36px; max-width: 760px; }

/* Boutons */
.actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.bouton { display: inline-flex; align-items: center; gap: 8px; background: var(--sapin); color: #FAF7F2; font-weight: 700; text-decoration: none; padding: 14px 22px; border-radius: 999px; border: 1.5px solid var(--sapin); min-height: 48px; }
.bouton:hover { background: var(--sapin-fonce); border-color: var(--sapin-fonce); }
.bouton.secondaire { background: transparent; color: var(--sapin); }
.bouton.secondaire:hover { background: var(--sapin-doux); }
@media (prefers-color-scheme: dark) { .bouton { color: #121816; } .bouton.secondaire { color: var(--sapin); } }

/* Héros */
.heros { padding-block: clamp(40px, 6vw, 80px) clamp(48px, 7vw, 88px); }
.heros .conteneur { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); gap: 40px; align-items: center; }
.heros .texte-heros { display: flex; flex-direction: column; gap: 22px; }
.disponibilite { display: inline-flex; align-items: center; gap: 8px; align-self: flex-start; font-size: 14px; font-weight: 600; color: var(--abricot-texte); background: var(--abricot-doux); border-radius: 999px; padding: 6px 14px; }
.disponibilite::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--abricot); }
.duo { position: relative; height: 560px; }
.duo .ecran { position: absolute; width: 250px; }
.duo .ecran:first-child { left: 4%; top: 0; transform: rotate(-4deg); }
.duo .ecran:last-child { right: 4%; top: 60px; transform: rotate(4deg); }
@media (max-width: 880px) {
  .heros .conteneur { grid-template-columns: 1fr; }
  .duo { height: 430px; max-width: 420px; width: 100%; margin: 0 auto; }
  .duo .ecran { width: 190px; }
}

/* Écran de téléphone */
.ecran { border-radius: 28px; overflow: hidden; border: 8px solid #1E2A27; background: #1E2A27; box-shadow: 0 18px 40px rgba(30, 42, 39, 0.18); }
.ecran img { width: 100%; height: auto; aspect-ratio: 498 / 1020; object-fit: cover; }
@media (prefers-color-scheme: dark) { .ecran { border-color: #2F3B37; background: #2F3B37; box-shadow: none; } }

/* Citations */
.citations { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); gap: 14px; }
.citation { background: var(--surface); border: 1px solid var(--filet); border-radius: 20px; padding: 18px 20px; font-size: 16.5px; line-height: 1.45; }

/* Promesses */
.promesses { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); gap: 18px; }
.promesse { border-radius: 24px; padding: 26px 26px 28px; display: flex; flex-direction: column; gap: 10px; }
.promesse svg { width: 34px; height: 34px; }
.promesse p { color: var(--gris); }
.promesse.vert { background: var(--sapin-doux); }
.promesse.abricot { background: var(--abricot-doux); }
.promesse.abricot h3 { color: var(--abricot-texte); }
.promesse.sable { background: var(--fond-2); border: 1px solid var(--filet); }

/* Galerie */
.galerie { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(200px, 1fr); gap: 22px; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 12px; }
@media (min-width: 1000px) { .galerie { grid-auto-flow: row; grid-template-columns: repeat(6, minmax(0, 1fr)); overflow: visible; } }
.galerie figure { margin: 0; display: flex; flex-direction: column; gap: 12px; scroll-snap-align: start; }
.galerie figcaption { font-size: 15px; color: var(--gris); }
.galerie figcaption strong { display: block; color: var(--encre); font-size: 16.5px; }

/* Cartes de fonctions */
.cartes { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr)); gap: 16px; }
.carte { background: var(--surface); border: 1px solid var(--filet); border-radius: 20px; padding: 22px 22px 24px; display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.carte .icone { width: 40px; height: 40px; border-radius: 12px; display: flex; align-items: center; justify-content: center; background: var(--sapin-doux); color: var(--sapin); }
.carte .icone.abricot { background: var(--abricot-doux); color: var(--abricot-texte); }
.carte .icone svg { width: 22px; height: 22px; }
.carte p { color: var(--gris); font-size: 16px; }
.lien-suite { font-weight: 700; text-decoration: none; }
.lien-suite:hover { text-decoration: underline; }

/* Encadré vert */
.encadre { background: #1F5C4F; color: #FAF7F2; border-radius: 28px; padding: clamp(28px, 4vw, 48px); display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); gap: 26px 40px; }
.encadre h2 { color: #FAF7F2; }
.encadre p { color: #DCEBE6; }
.encadre .points { display: flex; flex-direction: column; gap: 16px; }
.encadre .points strong { color: #FAF7F2; display: block; }

/* Données */
.garanties { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 190px), 1fr)); gap: 16px; }
.garantie { border-top: 4px solid var(--sapin); padding-top: 14px; display: flex; flex-direction: column; gap: 6px; }
.garantie p { color: var(--gris); font-size: 16px; }

/* Tarifs */
.offres { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); gap: 20px; align-items: stretch; }
.offre { background: var(--surface); border: 1px solid var(--filet); border-radius: 26px; padding: 28px; display: flex; flex-direction: column; gap: 16px; }
.offre.mise-en-avant { border: 2px solid var(--sapin); }
.offre .prix { font-family: var(--titre); font-weight: 800; font-size: 40px; line-height: 1; letter-spacing: -1px; }
.offre .prix small { font-family: var(--texte); font-size: 16px; font-weight: 600; color: var(--gris); letter-spacing: 0; }
.offre ul { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 8px; }
.offre li { padding-left: 28px; position: relative; }
.offre li::before { content: ""; position: absolute; left: 4px; top: 8px; width: 12px; height: 7px; border-left: 2.5px solid var(--sapin); border-bottom: 2.5px solid var(--sapin); transform: rotate(-45deg); }
.etiquette { align-self: flex-start; font-size: 13px; font-weight: 700; padding: 4px 12px; border-radius: 999px; background: var(--sapin-doux); color: var(--sapin); }

/* Questions */
.questions { display: flex; flex-direction: column; gap: 10px; max-width: 820px; }
.questions details { background: var(--surface); border: 1px solid var(--filet); border-radius: 18px; padding: 0 22px; }
.questions summary { cursor: pointer; list-style: none; font-weight: 700; font-size: 17.5px; padding: 18px 28px 18px 0; position: relative; }
.questions summary::-webkit-details-marker { display: none; }
.questions summary::after { content: "+"; position: absolute; right: 0; top: 14px; font-size: 24px; font-weight: 400; color: var(--sapin); }
.questions details[open] summary::after { content: "–"; }
.questions details p { color: var(--gris); padding-bottom: 18px; }

/* Appel final */
.appel { text-align: center; display: flex; flex-direction: column; align-items: center; gap: 18px; }
.appel .actions { justify-content: center; }

/* Page Fonctionnalités */
.fonction { display: grid; grid-template-columns: minmax(0, 1fr) 260px; gap: 40px; align-items: center; padding-block: 44px; border-top: 1px solid var(--filet); }
.fonction:first-of-type { border-top: 0; }
.fonction.sans-ecran { grid-template-columns: minmax(0, 1fr); }
.fonction .contenu { display: flex; flex-direction: column; gap: 14px; }
.fonction ul { margin: 0; padding-left: 22px; color: var(--gris); display: flex; flex-direction: column; gap: 6px; max-width: 64ch; }
.fonction ul strong { color: var(--encre); }
.fonction .ecran { width: 100%; max-width: 260px; justify-self: center; }
@media (max-width: 760px) { .fonction { grid-template-columns: 1fr; } .fonction .ecran { max-width: 220px; } }

/* Pages de texte (légales) */
.page-texte { padding-block: 48px 80px; }
.page-texte .entete-section { margin-bottom: 28px; }
.texte p { margin: 0 0 14px; max-width: 70ch; }
.texte h2 { margin: 36px 0 12px; font-size: 25px; }
.texte h3 { margin: 24px 0 8px; font-size: 18px; font-family: var(--texte); font-weight: 700; letter-spacing: 0; }
.texte ul, .texte ol { margin: 0 0 14px; padding-left: 22px; max-width: 68ch; }
.texte li { margin-bottom: 6px; }
.texte table { border-collapse: collapse; width: 100%; max-width: 720px; margin: 0 0 16px; font-size: 15.5px; }
.texte th, .texte td { text-align: left; vertical-align: top; padding: 10px 12px; border-bottom: 1px solid var(--filet); }
.texte thead th { font-weight: 700; }
.encadre-texte { background: var(--sapin-doux); border-radius: 22px; padding: 24px 26px; display: flex; flex-direction: column; gap: 10px; margin-bottom: 28px; max-width: 760px; }
.encadre-texte p { margin: 0; }

/* Pied de page */
footer.site { border-top: 1px solid var(--filet); background: var(--fond); }
footer.site .conteneur { padding-block: 32px 44px; display: flex; flex-wrap: wrap; gap: 14px 32px; justify-content: space-between; font-size: 14.5px; color: var(--gris); }
footer.site nav { display: flex; flex-wrap: wrap; gap: 8px 20px; }
footer.site a { color: var(--gris); }
footer.site a:hover { color: var(--encre); }

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

/* Captures cliquables et agrandissement (agrandir.js) */
a.ecran { display: block; cursor: zoom-in; transition: transform .2s ease, box-shadow .2s ease; }
a.ecran:hover { box-shadow: 0 22px 48px rgba(30, 42, 39, 0.26); }
.galerie a.ecran:hover, .fonction a.ecran:hover { transform: translateY(-3px); }
.galerie .astuce { margin-top: 18px; }
@media (min-width: 1100px) { .galerie { grid-template-columns: repeat(7, minmax(0, 1fr)); } }
dialog.agrandi { border: 0; padding: 0; background: transparent; max-width: 100vw; max-height: 100vh; width: 100vw; height: 100vh; margin: 0; display: none; align-items: center; justify-content: center; gap: 12px; }
dialog.agrandi[open] { display: flex; }
dialog.agrandi::backdrop { background: rgba(18, 24, 22, 0.86); }
dialog.agrandi figure { margin: 0; display: flex; flex-direction: column; align-items: center; gap: 12px; }
dialog.agrandi img { max-height: calc(100vh - 110px); max-width: min(92vw, 460px); width: auto; height: auto; border-radius: 30px; border: 8px solid #1E2A27; background: #1E2A27; }
dialog.agrandi figcaption { color: #FAF7F2; font-weight: 600; font-size: 16px; text-align: center; }
dialog.agrandi button { background: rgba(250, 247, 242, 0.14); color: #FAF7F2; border: 0; border-radius: 999px; width: 48px; height: 48px; font-size: 30px; line-height: 1; cursor: pointer; font-family: var(--texte); flex: none; }
dialog.agrandi button:hover { background: rgba(250, 247, 242, 0.26); }
dialog.agrandi .agrandi-fermer { position: fixed; top: max(14px, env(safe-area-inset-top)); right: max(14px, env(safe-area-inset-right)); }
dialog.agrandi button[hidden] { display: none; }
@media (max-width: 600px) {
  dialog.agrandi .agrandi-prec, dialog.agrandi .agrandi-suiv { position: fixed; bottom: max(16px, env(safe-area-inset-bottom)); }
  dialog.agrandi .agrandi-prec { left: 24px; } dialog.agrandi .agrandi-suiv { right: 24px; }
  dialog.agrandi img { max-height: calc(100vh - 150px); }
}
