/* ==========================================================
   GROUPE LOGO BTP — feuille de style
   Palette « chantier » : béton, encre de plan, jaune signal, latérite
   ========================================================== */

:root {
  --beton: #eeeeeb;        /* fond principal, gris béton froid */
  --beton-fonce: #dcdcd7;  /* filets, fonds secondaires */
  --encre: #17212b;        /* texte, fonds sombres (encre de plan) */
  --acier: #5e6b78;        /* texte secondaire */
  --signal: #f5b800;       /* jaune chantier : actions, cotes */
  --laterite: #9c3f1e;     /* accent ponctuel (terre rouge d'Abidjan) */
  --blanc: #ffffff;

  --police: "Archivo", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --largeur: 1200px;
  --gouttiere: clamp(16px, 4vw, 40px);
  --rayon: 4px;
}

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

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

body {
  margin: 0;
  background: var(--beton);
  color: var(--encre);
  font-family: var(--police);
  font-size: 1.0625rem;
  line-height: 1.6;
  font-variation-settings: "wdth" 100;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
p { margin: 0 0 1em; max-width: 68ch; }

h1, h2, h3 {
  margin: 0 0 0.5em;
  line-height: 1.08;
  font-weight: 800;
  font-variation-settings: "wdth" 125;
  letter-spacing: -0.01em;
}
h1 { font-size: clamp(2.25rem, 6vw, 4.5rem); }
h2 { font-size: clamp(1.75rem, 3.6vw, 2.75rem); }
h3 { font-size: clamp(1.2rem, 2vw, 1.45rem); font-variation-settings: "wdth" 112; }

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

.visuellement-cache {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

.lien-evitement {
  position: absolute; left: 16px; top: -60px; z-index: 100;
  background: var(--signal); color: var(--encre); padding: 10px 16px;
  font-weight: 700; text-decoration: none;
}
.lien-evitement:focus { top: 12px; }

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

/* ---------- Boutons ---------- */
.bouton {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5em;
  min-height: 48px; padding: 0.75em 1.4em;
  border: 2px solid transparent; border-radius: var(--rayon);
  font: inherit; font-weight: 700; font-variation-settings: "wdth" 110;
  text-decoration: none; cursor: pointer;
  transition: background-color 0.15s, color 0.15s, border-color 0.15s;
}
.bouton--signal { background: var(--signal); color: var(--encre); }
.bouton--signal:hover { background: #ffcb2e; }
.bouton--contour { border-color: currentColor; background: transparent; }
.bouton--contour:hover { background: rgba(255, 255, 255, 0.12); }
.bouton--encre { background: var(--encre); color: var(--blanc); }
.bouton--encre:hover { background: #263443; }
.bouton svg { width: 1.2em; height: 1.2em; flex: none; }

.groupe-boutons { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- En-tête ---------- */
.entete {
  position: sticky; top: 0; z-index: 50;
  background: var(--blanc);
  border-bottom: 1px solid var(--beton-fonce);
}
.entete__barre {
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  min-height: 76px;
}
.entete__logo img { height: 60px; width: auto; }

.nav { display: flex; align-items: center; gap: 28px; }
.nav__liste { display: flex; gap: 24px; list-style: none; margin: 0; padding: 0; }
.nav__liste a {
  text-decoration: none; font-weight: 600; font-size: 0.98rem;
  padding: 6px 0; border-bottom: 3px solid transparent;
}
.nav__liste a:hover { border-bottom-color: var(--beton-fonce); }
.nav__liste a[aria-current="page"] { border-bottom-color: var(--signal); }
.nav .bouton { min-height: 42px; padding: 0.5em 1em; font-size: 0.95rem; }

.nav__ouvrir {
  display: none;
  background: none; border: 0; padding: 10px; margin-right: -10px; cursor: pointer; color: var(--encre);
}
.nav__ouvrir svg { width: 28px; height: 28px; }

@media (max-width: 960px) {
  .nav__ouvrir { display: block; }
  .nav {
    position: absolute; left: 0; right: 0; top: 100%;
    flex-direction: column; align-items: stretch; gap: 16px;
    background: var(--blanc); padding: 16px var(--gouttiere) 24px;
    border-bottom: 1px solid var(--beton-fonce);
    display: none;
  }
  .nav[data-ouvert="true"] { display: flex; }
  .nav__liste { flex-direction: column; gap: 0; }
  .nav__liste a { display: block; padding: 14px 0; border-bottom: 1px solid var(--beton); }
  .nav__liste a[aria-current="page"] { border-bottom-color: var(--beton); box-shadow: inset 4px 0 0 var(--signal); padding-left: 12px; }
}

/* ---------- Héros d'accueil ---------- */
.heros {
  position: relative; isolation: isolate;
  color: var(--blanc); background: var(--encre);
  min-height: min(88vh, 760px);
  display: flex; align-items: flex-end;
  padding-block: 120px 64px;
}
.heros__image {
  position: absolute; inset: 0; z-index: -2;
  width: 100%; height: 100%; object-fit: cover;
}
.heros::after {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(180deg, rgba(23, 33, 43, 0.35) 0%, rgba(23, 33, 43, 0.92) 78%);
}
.heros h1 { font-size: clamp(2.6rem, 8.5vw, 6.5rem); max-width: 11ch; margin-bottom: 0.35em; }
.heros__texte { font-size: clamp(1.1rem, 2vw, 1.3rem); max-width: 46ch; margin-bottom: 1.6em; }

/* La « cote » : ligne de mesure de plan technique, élément signature */
.cote {
  display: flex; align-items: center; gap: 14px;
  max-width: 640px; margin: 0 0 2rem;
  color: var(--signal); font-weight: 700; font-size: 0.95rem;
  font-variation-settings: "wdth" 110;
}
.cote::before, .cote::after {
  content: ""; flex: 1; height: 12px;
  border-top: 2px solid currentColor;
  transform: translateY(5px);
}
.cote::before { border-left: 2px solid currentColor; }
.cote::after { border-right: 2px solid currentColor; }
.cote span { white-space: nowrap; }

@media (prefers-reduced-motion: no-preference) {
  .cote::before, .cote::after { transform-origin: center; animation: tracer 0.9s 0.3s cubic-bezier(0.2, 0.7, 0.2, 1) both; }
  .cote::before { transform-origin: right; }
  .cote::after { transform-origin: left; }
  @keyframes tracer { from { transform: translateY(5px) scaleX(0); } to { transform: translateY(5px) scaleX(1); } }
}

/* ---------- Héros des pages intérieures ---------- */
.bandeau-page {
  background: var(--encre); color: var(--blanc);
  padding-block: clamp(56px, 9vw, 104px) clamp(40px, 6vw, 64px);
}
.bandeau-page h1 { max-width: 16ch; }
.bandeau-page p { font-size: 1.15rem; color: #c9d1d9; margin: 0; }

/* ---------- Sections ---------- */
.section { padding-block: clamp(64px, 9vw, 112px); }
.section--blanche { background: var(--blanc); }
.section--encre { background: var(--encre); color: var(--blanc); }
.section--encre p { color: #c9d1d9; }

.entete-section { max-width: 720px; margin-bottom: clamp(32px, 5vw, 56px); }
.entete-section p { color: var(--acier); font-size: 1.1rem; margin: 0; }
.section--encre .entete-section p { color: #c9d1d9; }

.entete-section--ligne {
  max-width: none; display: flex; flex-wrap: wrap; align-items: flex-end;
  justify-content: space-between; gap: 16px 40px;
}
.entete-section--ligne > div { max-width: 640px; }

.lien-fleche {
  font-weight: 700; text-decoration-thickness: 2px; text-underline-offset: 5px;
  text-decoration-color: var(--signal);
}
.lien-fleche:hover { text-decoration-thickness: 4px; }

/* ---------- Métiers (accueil) ---------- */
.metiers {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(24px, 3vw, 40px);
}
.metier img { aspect-ratio: 4 / 3; object-fit: cover; width: 100%; border-radius: var(--rayon); margin-bottom: 20px; background: var(--beton-fonce); }
.metier p { color: var(--acier); margin: 0; }
@media (max-width: 860px) { .metiers { grid-template-columns: 1fr; } }

/* ---------- Services détaillés (alternance) ---------- */
.service {
  display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 5vw, 72px); align-items: center;
}
.service + .service { margin-top: clamp(64px, 9vw, 112px); }
.service:nth-child(even) .service__image { order: 2; }
.service__image img { width: 100%; aspect-ratio: 5 / 4; object-fit: cover; border-radius: var(--rayon); background: var(--beton-fonce); }
.service__liste { margin: 1.25em 0 0; padding: 0; list-style: none; }
.service__liste li { padding: 10px 0 10px 28px; border-top: 1px solid var(--beton-fonce); position: relative; }
.service__liste li::before {
  content: ""; position: absolute; left: 0; top: 19px; width: 14px; height: 8px;
  border-left: 3px solid var(--laterite); border-bottom: 3px solid var(--laterite);
  transform: rotate(-45deg);
}
@media (max-width: 860px) {
  .service { grid-template-columns: 1fr; }
  .service:nth-child(even) .service__image { order: 0; }
}

/* ---------- Atouts ---------- */
.atouts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; border-top: 2px solid var(--encre); }
.atout { padding: 28px 28px 0 0; }
.atout + .atout { padding-left: 28px; border-left: 1px solid var(--beton-fonce); }
.atout p { color: var(--acier); margin: 0; font-size: 1rem; }
@media (max-width: 960px) {
  .atouts { grid-template-columns: 1fr 1fr; }
  .atout, .atout + .atout { padding: 28px 24px 28px 0; border-left: 0; }
  .atout:nth-child(even) { padding-left: 24px; border-left: 1px solid var(--beton-fonce); }
}
@media (max-width: 560px) {
  .atouts { grid-template-columns: 1fr; }
  .atout:nth-child(even) { padding-left: 0; border-left: 0; }
  .atout + .atout { border-top: 1px solid var(--beton-fonce); }
}

/* ---------- Galeries ---------- */
.galerie {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px;
  list-style: none; margin: 0; padding: 0;
}
.galerie--accueil { grid-template-columns: 2fr 1fr 1fr; grid-auto-rows: 240px; }
.galerie--accueil li:first-child { grid-row: span 2; }
@media (max-width: 760px) {
  .galerie--accueil { grid-template-columns: 1fr 1fr; grid-auto-rows: 180px; }
  .galerie--accueil li:first-child { grid-column: span 2; grid-row: span 1; }
}

.vignette {
  display: block; width: 100%; height: 100%; padding: 0; border: 0; margin: 0;
  background: var(--beton-fonce); cursor: zoom-in; border-radius: var(--rayon); overflow: hidden;
}
.galerie:not(.galerie--accueil) .vignette { height: auto; }
.galerie:not(.galerie--accueil) .vignette img { height: auto; aspect-ratio: 4 / 3; }
.vignette img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s ease; }
.vignette:hover img { transform: scale(1.03); }
@media (prefers-reduced-motion: reduce) { .vignette img { transition: none; } .vignette:hover img { transform: none; } }

.legende { margin-top: 10px; font-weight: 600; font-size: 0.98rem; }
.legende small { display: block; font-weight: 400; color: var(--acier); font-size: 0.92rem; }

/* Visionneuse */
.visionneuse {
  width: min(1100px, 94vw); max-height: 92vh; padding: 0; border: 0;
  background: transparent; color: var(--blanc);
}
.visionneuse::backdrop { background: rgba(23, 33, 43, 0.92); }
.visionneuse img { max-height: 82vh; width: auto; margin-inline: auto; border-radius: var(--rayon); }
.visionneuse__barre { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: 12px; }
.visionneuse button {
  min-width: 48px; min-height: 48px; border: 2px solid rgba(255,255,255,0.5); border-radius: var(--rayon);
  background: transparent; color: var(--blanc); font: inherit; font-weight: 700; cursor: pointer; padding: 0 14px;
}
.visionneuse button:hover { border-color: var(--signal); color: var(--signal); }

/* ---------- Appel à l'action ---------- */
.appel {
  display: grid; grid-template-columns: 1.4fr 1fr; gap: 32px 64px; align-items: end;
}
.appel h2 { margin-bottom: 0.3em; }
.appel p { margin: 0; }
.appel .groupe-boutons { justify-content: flex-end; }
@media (max-width: 860px) { .appel { grid-template-columns: 1fr; } .appel .groupe-boutons { justify-content: flex-start; } }

/* ---------- Contact ---------- */
.contact { display: grid; grid-template-columns: 1.2fr 1fr; gap: clamp(40px, 6vw, 80px); }
@media (max-width: 900px) { .contact { grid-template-columns: 1fr; } }

.formulaire { display: grid; gap: 20px; }
.champ { display: grid; gap: 6px; }
.champ label { font-weight: 600; }
.champ label span { color: var(--acier); font-weight: 400; }
.champ input, .champ textarea, .champ select {
  font: inherit; color: var(--encre); background: var(--blanc);
  border: 2px solid var(--beton-fonce); border-radius: var(--rayon);
  padding: 12px 14px; min-height: 50px; width: 100%;
}
.champ textarea { min-height: 150px; resize: vertical; }
.champ input:focus, .champ textarea:focus, .champ select:focus { outline: none; border-color: var(--encre); box-shadow: 0 0 0 3px var(--signal); }
.duo { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
@media (max-width: 560px) { .duo { grid-template-columns: 1fr; } }
.piege { display: none; }

.formulaire__etat { min-height: 1.5em; margin: 0; font-weight: 600; }
.formulaire__etat[data-type="ok"] { color: #1f6b3a; }
.formulaire__etat[data-type="erreur"] { color: var(--laterite); }
.formulaire__note { font-size: 0.92rem; color: var(--acier); margin: 0; }

.coordonnees { display: grid; gap: 28px; align-content: start; }
.coordonnees h3 { font-size: 1.05rem; margin-bottom: 0.4em; font-variation-settings: "wdth" 110; }
.coordonnees p, .coordonnees ul { margin: 0; }
.coordonnees ul { list-style: none; padding: 0; }
.coordonnees li { padding: 3px 0; }
.coordonnees a { text-decoration-color: var(--beton-fonce); text-underline-offset: 4px; }
.coordonnees a:hover { text-decoration-color: var(--signal); }
.horaires { display: grid; grid-template-columns: auto 1fr; gap: 4px 20px; margin: 0; }
.horaires dt { font-weight: 600; }
.horaires dd { margin: 0; }

.carte { margin-top: clamp(48px, 7vw, 80px); border-radius: var(--rayon); overflow: hidden; background: var(--beton-fonce); }
.carte iframe { display: block; width: 100%; height: 380px; border: 0; }

/* ---------- À propos ---------- */
.colonnes { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 6vw, 80px); }
@media (max-width: 860px) { .colonnes { grid-template-columns: 1fr; } }
.liste-offre { list-style: none; margin: 0; padding: 0; border-top: 2px solid var(--encre); }
.liste-offre li {
  padding: 18px 0; border-bottom: 1px solid var(--beton-fonce);
  font-weight: 700; font-size: 1.2rem; font-variation-settings: "wdth" 115;
}

/* ---------- Blog / textes longs ---------- */
.article { max-width: 72ch; }
.article h2 { font-size: clamp(1.45rem, 2.6vw, 1.9rem); margin-top: 1.8em; }
.article h3 { margin-top: 1.4em; }
.article p, .article li { font-size: 1.08rem; }
.article ul { padding-left: 1.2em; }
.article li { margin-bottom: 0.4em; }
.article figure { margin: 2em 0; }
.article figure img { width: 100%; border-radius: var(--rayon); }
.article__meta { color: #c9d1d9; font-size: 1rem; margin-top: 1em; }

.carte-article {
  display: grid; grid-template-columns: 1fr 1.2fr; gap: clamp(24px, 4vw, 48px); align-items: center;
  text-decoration: none; background: var(--blanc); border-radius: var(--rayon); overflow: hidden;
}
.carte-article img { width: 100%; height: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.carte-article > div { padding: 24px 24px 24px 0; }
.carte-article time { color: var(--acier); font-size: 0.95rem; }
.carte-article:hover h2 { text-decoration: underline; text-decoration-color: var(--signal); text-decoration-thickness: 3px; text-underline-offset: 6px; }
@media (max-width: 760px) { .carte-article { grid-template-columns: 1fr; } .carte-article > div { padding: 0 20px 24px; } }

.texte-legal { max-width: 72ch; }
.texte-legal h2 { font-size: 1.4rem; margin-top: 1.8em; }
.a-completer { background: #fff3c4; padding: 0 4px; border-radius: 2px; }

/* ---------- Pied de page ---------- */
.pied { background: var(--encre); color: #c9d1d9; padding-block: 64px 32px; font-size: 0.98rem; }
.pied a { color: var(--blanc); text-decoration: none; }
.pied a:hover { text-decoration: underline; text-decoration-color: var(--signal); text-underline-offset: 4px; }
.pied__grille { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 40px; }
.pied__logo { background: var(--blanc); border-radius: var(--rayon); padding: 10px 14px; display: inline-block; margin-bottom: 16px; }
.pied__logo img { height: 56px; width: auto; }
.pied h2 { font-size: 1rem; color: var(--blanc); font-variation-settings: "wdth" 110; margin-bottom: 14px; }
.pied ul { list-style: none; margin: 0; padding: 0; }
.pied li { padding: 4px 0; }
.pied__social { display: flex; gap: 10px; margin-top: 16px; }
.pied__social a {
  display: grid; place-items: center; width: 44px; height: 44px;
  border: 1px solid #3a4856; border-radius: var(--rayon);
}
.pied__social a:hover { border-color: var(--signal); }
.pied__social svg { width: 20px; height: 20px; fill: currentColor; }
.pied__bas {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px;
  margin-top: 48px; padding-top: 24px; border-top: 1px solid #2b3946; font-size: 0.9rem;
}
@media (max-width: 900px) { .pied__grille { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .pied__grille { grid-template-columns: 1fr; } }

/* Bouton WhatsApp flottant (mobile) */
.whatsapp-flottant {
  position: fixed; right: 16px; bottom: 16px; z-index: 40;
  display: none; place-items: center; width: 58px; height: 58px; border-radius: 50%;
  background: #25d366; color: var(--blanc); box-shadow: 0 6px 18px rgba(23, 33, 43, 0.3);
}
.whatsapp-flottant svg { width: 30px; height: 30px; fill: currentColor; }
@media (max-width: 960px) { .whatsapp-flottant { display: grid; } }

/* ---------- 404 ---------- */
.erreur-404 { min-height: 60vh; display: flex; align-items: center; }
.erreur-404 h1 { font-size: clamp(2rem, 5vw, 3.5rem); }

.article figcaption { margin-top: 8px; color: var(--acier); font-size: 0.95rem; }
