/* Polices hébergées sur le site (pas d'appel à Google Fonts : RGPD et vitesse). Licence SIL OFL. */
@font-face { font-family: "Bricolage Grotesque"; font-style: normal; font-weight: 200 800; font-display: swap; src: url(fonts/bricolage-grotesque.woff2) format("woff2"); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: "Public Sans"; font-style: normal; font-weight: 400; font-display: swap; src: url(fonts/public-sans-400.woff2) format("woff2"); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: "Public Sans"; font-style: normal; font-weight: 500; font-display: swap; src: url(fonts/public-sans-500.woff2) format("woff2"); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: "Public Sans"; font-style: normal; font-weight: 600; font-display: swap; src: url(fonts/public-sans-600.woff2) format("woff2"); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: "IBM Plex Mono"; font-style: normal; font-weight: 400; font-display: swap; src: url(fonts/ibm-plex-mono-400.woff2) format("woff2"); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: "IBM Plex Mono"; font-style: normal; font-weight: 500; font-display: swap; src: url(fonts/ibm-plex-mono-500.woff2) format("woff2"); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }

/* Concept : un mur en appareil "à joints croisés" — sections posées comme des rangs,
   ardoise de Savoie pour l'encre, bleu ciel de l'entreprise pour l'accent. */
:root {
  --ardoise: #1e2a32;      /* encre principale, fonds sombres */
  --ardoise-2: #2b3a44;
  --pierre: #edf3f7;       /* fond de section alterné, pierre calcaire froide */
  --blanc: #fbfbf9;        /* fond principal */
  --beton: #5a666d;        /* texte secondaire, gris béton */
  --joint: #d3dde3;        /* filets, joints */
  --cordeau: #6cc3ef;      /* accent : bleu ciel, couleur de l'entreprise */
  --cordeau-fonce: #1d6a96;  /* bleu ciel assombri, lisible sur fond clair */

  --f-titre: "Bricolage Grotesque", "Arial Narrow", Arial, sans-serif;
  --f-texte: "Public Sans", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --f-mono: "IBM Plex Mono", ui-monospace, Menlo, Consolas, monospace;

  --largeur: 72rem;
  --gouttiere: clamp(1rem, 4vw, 2.5rem);
  --rayon: 4px;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; } }

body {
  margin: 0;
  background: var(--blanc);
  color: var(--ardoise);
  font-family: var(--f-texte);
  font-size: 1.0625rem;
  line-height: 1.6;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, summary:focus-visible {
  outline: 3px solid var(--cordeau); outline-offset: 2px;
}
h1, h2, h3 { font-family: var(--f-titre); line-height: 1.08; text-wrap: balance; margin: 0; letter-spacing: -0.01em; }
h1 { font-size: clamp(2.3rem, 6.2vw, 4.4rem); font-weight: 700; }
h2 { font-size: clamp(1.75rem, 3.6vw, 2.6rem); font-weight: 700; }
h3 { font-size: 1.3rem; font-weight: 600; }
p { margin: 0; max-width: 65ch; }

.enveloppe { max-width: var(--largeur); margin-inline: auto; padding-inline: var(--gouttiere); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.etiquette {
  font-family: var(--f-mono); font-size: 0.78rem; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--beton);
}

/* ---------- En-tête ---------- */
.entete {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20;
  background: var(--blanc); border-bottom: 1px solid var(--joint);
}
.entete .enveloppe { display: flex; align-items: center; gap: 1.25rem; min-height: 4.25rem; flex-wrap: wrap; padding-block: 0.5rem; }
.logo { display: flex; align-items: center; gap: 0.65rem; text-decoration: none; margin-right: auto; }
.logo-marque {
  width: 2.4rem; height: 2.4rem; flex: none; border-radius: var(--rayon);
  background: var(--ardoise); color: var(--cordeau);
  display: grid; place-items: center; font-family: var(--f-titre); font-weight: 800; font-size: 1.05rem;
}
.logo-nom { font-family: var(--f-titre); font-weight: 700; font-size: 1.15rem; line-height: 1.1; }
.logo-nom small { display: block; font-family: var(--f-texte); font-weight: 400; font-size: 0.78rem; color: var(--beton); }
.nav { display: flex; gap: 0.25rem; align-items: center; flex-wrap: wrap; }
.nav a {
  text-decoration: none; padding: 0.5rem 0.75rem; border-radius: var(--rayon); font-weight: 500; font-size: 0.98rem;
}
.nav a:hover { background: var(--pierre); }
.nav a[aria-current="page"] { box-shadow: inset 0 -3px 0 var(--cordeau); border-radius: 0; }
.nav .btn-tel { margin-left: 0.5rem; }

/* ---------- Boutons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 0.5rem; justify-content: center;
  padding: 0.8rem 1.25rem; border-radius: var(--rayon); font-weight: 600; text-decoration: none;
  border: 2px solid transparent; cursor: pointer; font: inherit; font-weight: 600; line-height: 1.2;
}
.btn-accent { background: var(--cordeau); color: var(--ardoise); }
.btn-accent:hover { background: #8fd3f5; }
.btn-ligne { border-color: currentColor; background: transparent; }
.btn-ligne:hover { background: rgba(255,255,255,0.08); }
.btn-tel { background: var(--ardoise); color: var(--blanc); padding: 0.55rem 0.9rem; font-variant-numeric: tabular-nums; }
.btn-tel:hover { background: var(--ardoise-2); }

/* ---------- Héros ---------- */
.heros {
  position: relative; color: var(--blanc); background-color: var(--ardoise); overflow: hidden;
  /* appareil à joints croisés : rangs de 25 cm, joints décalés d'un demi-bloc */
  background-image:
    linear-gradient(rgba(255,255,255,0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.06) 1px, transparent 1px);
  background-size: 100% 48px, 192px 96px, 192px 96px;
  background-position: 0 0, 0 0, 96px 48px;
}
.heros::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(100deg, var(--ardoise) 35%, rgba(30,42,50,0.55) 100%);
}
.heros .enveloppe { position: relative; z-index: 1; padding-block: clamp(3.5rem, 9vw, 6.5rem) clamp(2.5rem, 6vw, 4rem); display: grid; gap: 1.5rem; }
.heros .etiquette { color: var(--cordeau); }
.heros h1 { max-width: 18ch; }
.heros h1 em { font-style: normal; color: var(--cordeau); }
.heros p.chapeau { font-size: clamp(1.1rem, 2vw, 1.3rem); color: #d7dee2; max-width: 52ch; }
.heros .actions { display: flex; gap: 0.75rem; flex-wrap: wrap; margin-top: 0.5rem; }
.cordeau { height: 3px; width: 6rem; background: var(--cordeau); }
.fiche {
  display: flex; flex-wrap: wrap; gap: 0.5rem 2rem; margin-top: 1.5rem; padding-top: 1.25rem;
  border-top: 1px solid rgba(255,255,255,0.15);
  font-family: var(--f-mono); font-size: 0.82rem; color: #b9c4ca; font-variant-numeric: tabular-nums;
}
.fiche b { color: var(--blanc); font-weight: 500; }

.heros-page .enveloppe { padding-block: clamp(2.5rem, 6vw, 4rem); }
.heros-page h1 { font-size: clamp(2rem, 5vw, 3.2rem); max-width: 22ch; }

/* ---------- Sections ---------- */
.section { padding-block: clamp(3.5rem, 8vw, 6rem); }
.section-pierre { background: var(--pierre); }
.section-sombre { background: var(--ardoise); color: var(--blanc); }
.section-tete { display: grid; gap: 0.75rem; margin-bottom: clamp(2rem, 4vw, 3rem); }
.section-tete p { color: var(--beton); font-size: 1.1rem; }
.section-sombre .section-tete p, .section-sombre .etiquette { color: #b9c4ca; }

/* Savoir-faire : rangs décalés comme des blocs */
.rangs { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 0.75rem; }
.bloc {
  grid-column: span 2; background: var(--blanc); border: 1px solid var(--joint); border-radius: var(--rayon);
  padding: 1.5rem; display: grid; gap: 0.6rem; align-content: start; min-width: 0;
}
.rangs .bloc:nth-child(4) { grid-column: 2 / span 2; }
.bloc .etiquette { color: var(--cordeau-fonce); }
.bloc p { color: #3e4a51; font-size: 1rem; }
.bloc ul { margin: 0.25rem 0 0; padding-left: 1.1rem; color: #3e4a51; font-size: 0.97rem; }
@media (max-width: 860px) {
  .rangs { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .bloc, .rangs .bloc:nth-child(4) { grid-column: span 1; }
  .rangs .bloc:last-child { grid-column: 1 / -1; }
}
@media (max-width: 560px) { .rangs { grid-template-columns: 1fr; } .bloc, .rangs .bloc:nth-child(4), .rangs .bloc:last-child { grid-column: 1; } }

/* Méthode : vraie séquence de chantier */
.etapes { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; counter-reset: etape; }
.etapes li { padding: 1.25rem 1.25rem 0 0; border-top: 3px solid rgba(255,255,255,0.18); counter-increment: etape; display: grid; gap: 0.5rem; align-content: start; min-width: 0; }
.etapes li:first-child { border-top-color: var(--cordeau); }
.etapes li::before { content: counter(etape, decimal-leading-zero); font-family: var(--f-mono); color: var(--cordeau); font-size: 0.85rem; }
.etapes p { color: #c9d2d7; font-size: 0.98rem; }
@media (max-width: 860px) { .etapes { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 1.5rem; } }
@media (max-width: 520px) { .etapes { grid-template-columns: 1fr; } }

/* Entreprise */
.deux-col { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: clamp(2rem, 5vw, 4rem); align-items: start; }
@media (max-width: 860px) { .deux-col { grid-template-columns: 1fr; } }
.texte { display: grid; gap: 1rem; }
.citation {
  margin: 0.5rem 0 0; padding: 0 0 0 1.25rem; border-left: 3px solid var(--cordeau);
  font-family: var(--f-titre); font-size: 1.35rem; line-height: 1.3; font-weight: 500; max-width: 32ch;
}
.registre { margin: 0; display: grid; grid-template-columns: auto 1fr; border-top: 1px solid var(--joint); font-variant-numeric: tabular-nums; }
.registre dt, .registre dd { padding: 0.7rem 0; border-bottom: 1px solid var(--joint); margin: 0; }
.registre dt { font-family: var(--f-mono); font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--beton); padding-right: 1.5rem; padding-top: 0.85rem; }
.registre dd { font-weight: 500; min-width: 0; overflow-wrap: anywhere; }

/* Zone */
.communes { list-style: none; margin: 1.25rem 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 0.5rem; }
.communes li { padding: 0.35rem 0.75rem; border: 1px solid var(--joint); border-radius: 999px; font-size: 0.95rem; background: var(--blanc); }
.communes li.siege { background: var(--ardoise); color: var(--blanc); border-color: var(--ardoise); }
.carte-lien {
  display: grid; gap: 0.5rem; padding: 1.5rem; border-radius: var(--rayon); text-decoration: none;
  background: var(--ardoise); color: var(--blanc);
  background-image: radial-gradient(circle at 70% 40%, rgba(108,195,239,0.35) 0 0.5rem, transparent 0.55rem),
                    repeating-radial-gradient(circle at 70% 40%, transparent 0 2.2rem, rgba(255,255,255,0.07) 2.2rem 2.3rem);
  min-height: 15rem; align-content: end;
}
.carte-lien .etiquette { color: var(--cordeau); }
.carte-lien:hover { background-color: var(--ardoise-2); }

/* Bandeau devis */
.bandeau { background: var(--cordeau); color: var(--ardoise); }
.bandeau .enveloppe { padding-block: clamp(2.5rem, 6vw, 3.5rem); display: flex; flex-wrap: wrap; gap: 1.5rem; align-items: center; justify-content: space-between; }
.bandeau h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); max-width: 24ch; }
.bandeau .actions { display: flex; flex-wrap: wrap; gap: 0.75rem; }
.bandeau .btn-ligne:hover { background: rgba(30,42,50,0.08); }

/* Réalisations */
.filtres { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 2rem; }
.filtres button {
  font: inherit; font-size: 0.95rem; padding: 0.45rem 0.9rem; border-radius: 999px; cursor: pointer;
  border: 1px solid var(--joint); background: var(--blanc); color: var(--ardoise);
}
.filtres button[aria-pressed="true"] { background: var(--ardoise); color: var(--blanc); border-color: var(--ardoise); }
.galerie { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 17rem), 1fr)); gap: 1rem; }
.galerie figure { margin: 0; display: grid; gap: 0.6rem; align-content: start; }
.galerie img, .photo-attente { aspect-ratio: 4 / 3; width: 100%; max-width: 100%; object-fit: cover; border-radius: var(--rayon); }
.photo-attente {
  display: grid; place-items: center; text-align: center; padding: 1rem;
  background-color: #dde7ee;
  background-image:
    linear-gradient(#fbfbf9 2px, transparent 2px),
    linear-gradient(90deg, #fbfbf9 2px, transparent 2px),
    linear-gradient(90deg, #fbfbf9 2px, transparent 2px);
  background-size: 100% 32px, 96px 64px, 96px 64px;
  background-position: 0 0, 0 0, 48px 32px;
  font-family: var(--f-mono); font-size: 0.78rem; color: var(--beton); letter-spacing: 0.04em;
}
.photo-attente span { background: var(--blanc); padding: 0.3rem 0.6rem; border-radius: var(--rayon); }
.galerie figcaption { display: grid; gap: 0.15rem; }
.galerie figcaption strong { font-weight: 600; }
.galerie figcaption span { color: var(--beton); font-size: 0.92rem; }

/* Contact */
.contact-grille { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); gap: clamp(2rem, 5vw, 4rem); align-items: start; }
@media (max-width: 860px) { .contact-grille { grid-template-columns: 1fr; } }
.coordonnees { display: grid; gap: 1.5rem; }
.coordonnees a { text-decoration-color: var(--cordeau-fonce); text-underline-offset: 3px; text-decoration-thickness: 2px; }
.coordonnees .gros { font-family: var(--f-titre); font-size: 1.6rem; font-weight: 600; font-variant-numeric: tabular-nums; }
.formulaire { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; background: var(--pierre); padding: clamp(1.25rem, 3vw, 2rem); border-radius: var(--rayon); }
.formulaire .plein { grid-column: 1 / -1; }
@media (max-width: 560px) { .formulaire { grid-template-columns: 1fr; } }
.champ { display: grid; gap: 0.35rem; min-width: 0; }
.champ label { font-weight: 600; font-size: 0.95rem; }
.champ input, .champ select, .champ textarea {
  font: inherit; font-size: 1rem; padding: 0.7rem 0.8rem; border: 1px solid #b9c1bd; border-radius: var(--rayon);
  background: var(--blanc); color: var(--ardoise); width: 100%;
}
.champ textarea { min-height: 9rem; resize: vertical; }
.consent { display: flex; gap: 0.6rem; align-items: flex-start; font-size: 0.92rem; color: #3e4a51; }
.consent input { margin-top: 0.3rem; }
.piege { position: absolute; left: -9999px; }
.message-envoi { padding: 0.9rem 1rem; border-radius: var(--rayon); background: var(--ardoise); color: var(--blanc); }

/* Mentions */
.legal { display: grid; gap: 2rem; }
.legal section { display: grid; gap: 0.6rem; }
.legal h2 { font-size: 1.4rem; }

/* ---------- Pied de page ---------- */
.pied { background: var(--ardoise); color: #c9d2d7; font-size: 0.95rem; padding-bottom: 5rem; }
.pied .enveloppe { padding-block: 3rem 1.5rem; display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 2rem; }
.pied h2 { font-size: 1rem; color: var(--blanc); font-family: var(--f-texte); font-weight: 600; margin-bottom: 0.6rem; }
.pied ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.35rem; }
.pied a { color: #e4e9ec; }
.pied address { font-style: normal; display: grid; gap: 0.2rem; }
.pied .bas { grid-column: 1 / -1; border-top: 1px solid rgba(255,255,255,0.12); padding-top: 1.25rem; display: flex; flex-wrap: wrap; gap: 0.5rem 1.5rem; justify-content: space-between; font-size: 0.85rem; color: #93a1a9; }
@media (max-width: 760px) { .pied .enveloppe { grid-template-columns: 1fr; } }
@media (min-width: 761px) { .pied { padding-bottom: 0; } }

/* Barre d'appel mobile */
.barre-mobile {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; display: none; gap: 0.5rem;
  padding: 0.6rem 1rem calc(0.6rem + env(safe-area-inset-bottom, 0px));
  background: var(--blanc); border-top: 1px solid var(--joint);
}
.barre-mobile .btn { flex: 1; padding-block: 0.75rem; }
@media (max-width: 760px) {
  .barre-mobile { display: flex; }
  .nav .btn-tel { display: none; }
  .entete .enveloppe { gap: 0.25rem 1rem; }
  .nav { width: 100%; margin-inline: -0.6rem; flex-wrap: nowrap; overflow-x: auto; }
  .nav a { padding: 0.45rem 0.6rem; white-space: nowrap; }
}

/* Photos */
.heros-photo { background-image: var(--photo); background-size: cover; background-position: center 60%; }
.heros-photo::after { background: linear-gradient(100deg, rgba(30,42,50,0.92) 30%, rgba(30,42,50,0.55) 100%); }
.galerie a.zoom { display: block; border-radius: var(--rayon); overflow: hidden; cursor: zoom-in; }
.galerie a.zoom img { transition: transform 0.3s ease; }
.galerie a.zoom:hover img { transform: scale(1.03); }
.galerie-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 760px) { .galerie-3 { grid-template-columns: 1fr; } }
.section-tete-ligne { display: flex; flex-wrap: wrap; gap: 1rem; align-items: end; justify-content: space-between; }
.section-tete-ligne > div { display: grid; gap: 0.75rem; }
.visionneuse { border: 0; padding: 0; background: var(--ardoise); color: var(--blanc); max-width: min(92vw, 1200px); max-height: 92vh; border-radius: var(--rayon); }
.visionneuse::backdrop { background: rgba(15,20,25,0.85); }
.visionneuse img { max-height: 80vh; width: auto; max-width: 100%; margin-inline: auto; }
.visionneuse p { padding: 0.75rem 1rem; margin: 0; font-size: 0.95rem; }
.visionneuse form { position: absolute; top: 0.5rem; right: 0.5rem; }
.fermer { font: inherit; font-size: 1.6rem; line-height: 1; width: 2.5rem; height: 2.5rem; border-radius: 50%; border: 0; cursor: pointer; background: rgba(30,42,50,0.8); color: var(--blanc); }
.galerie picture { display: block; }
