/* ============================================================
   TGF Échafaudage — Accueil
   Charte : bleu nuit #001523 · rouge #d81f27 / #ff4136 · blanc
   Typo   : Archivo (titre hero) · IBM Plex Sans (reste)
   Boutons : toujours à angles droits
   ============================================================ */

*, *::before, *::after { box-sizing: border-box; }
h1, h2, h3, h4, h5, p { margin: 0; }
button, a, input, textarea, select { font-family: inherit; }
a { text-decoration: none; color: inherit; }

body {
  margin: 0;
  background: #ffffff;
  color: #28323c;
  font-family: 'IBM Plex Sans', sans-serif;
  -webkit-font-smoothing: antialiased;
}

input::placeholder, textarea::placeholder { color: #9aa6b2; }

.wrap {
  max-width: 1200px;
  margin: 0 auto;
  padding-left: clamp(18px, 5vw, 40px);
  padding-right: clamp(18px, 5vw, 40px);
}

.accent { color: #d81f27; }
.accent-strong {
  color: #d81f27;
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* Buttons — square corners */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 0;
  cursor: pointer;
  white-space: nowrap;
  font: 600 14px 'IBM Plex Sans', sans-serif;
}
.btn span { font-size: 16px; line-height: 1; }
.btn-red { background: #d81f27; color: #fff; padding: 12px 22px; }

/* ---------------- Header ---------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(0, 21, 35, .88);
  -webkit-backdrop-filter: blur(12px) saturate(1.3);
  backdrop-filter: blur(12px) saturate(1.3);
  border-bottom: 1px solid #0e2233;
}
.head {
  max-width: 1200px;
  margin: 0 auto;
  padding: 14px clamp(18px, 5vw, 40px);
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
}
.brand { display: flex; align-items: center; }
.brand img { height: 94px; width: auto; display: block; }

.nav {
  display: flex;
  align-items: center;
  gap: 34px;
  justify-content: flex-start;
  margin-left: 30px;
  margin-right: auto;
}
.nav a {
  position: relative;
  font: 600 15px 'IBM Plex Sans', sans-serif;
  color: #aeb9c4;
  padding: 6px 0;
  white-space: nowrap;
  transition: color .2s ease;
}
.nav a.active { color: #ffffff; }
.nav a .underline {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 2px;
  background: #ff4136;
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform .24s cubic-bezier(.2, .7, .2, 1);
}
.nav a.active .underline { transform: scaleX(1); }

.actions { display: flex; align-items: center; gap: 18px; }
.head-phone {
  font: 700 15px 'IBM Plex Sans', sans-serif;
  color: #fff;
  white-space: nowrap;
}

/* ---------------- Hero ---------------- */
.hero { border-bottom: 1px solid #e5e9ed; }
.hero-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 330px), 1fr));
  gap: 48px;
  align-items: center;
  padding-top: 60px;
  padding-bottom: 60px;
}
.hero h1 {
  font: 800 clamp(31px, 6.6vw, 52px)/1.04 'Archivo', sans-serif;
  color: #0e1b27;
  letter-spacing: -.02em;
}
.hero-lead {
  font: 400 18px/1.6 'IBM Plex Sans', sans-serif;
  color: #4a5560;
  max-width: 480px;
  margin-top: 22px;
}
.hero-underline {
  font-style: italic;
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 3px;
  color: #0e1b27;
}
.hero-cta { display: flex; gap: 14px; margin-top: 30px; align-items: center; flex-wrap: wrap; }
.hero-cta .btn-red { padding: 15px 26px; font-size: 15px; }
.hero-call {
  align-self: center;
  font: 600 16px 'IBM Plex Sans', sans-serif;
  color: #4a5560;
  cursor: pointer;
}
.hero-img {
  width: 100%;
  height: 460px;
  object-fit: cover;
  display: block;
}

/* ---------------- Section heads ---------------- */
.eyebrow {
  font: 600 14px 'IBM Plex Sans', sans-serif;
  color: #d81f27;
  margin-bottom: 10px;
}
.eyebrow-lg { font: 700 24px 'IBM Plex Sans', sans-serif; }
.eyebrow-bright { color: #ff4136; }

.section-head h2,
.zone-grid h2,
.contact-grid h2 {
  font: 700 clamp(25px, 4.4vw, 34px)/1.15 'IBM Plex Sans', sans-serif;
  color: #0e1b27;
  letter-spacing: -.01em;
}
h2.on-dark { color: #fff; }

/* ---------------- Services ---------------- */
.services { padding-top: 64px; padding-bottom: 24px; }
.services .section-head { max-width: 620px; margin-bottom: 30px; }
.services .section-head .eyebrow-lg { margin-bottom: 10px; }

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 34px 44px;
}
.service {
  display: flex;
  flex-direction: column;
  gap: 9px;
  padding-right: 10px;
}
.service-num { font: 600 42px/1 'IBM Plex Sans', sans-serif; color: #d9e0e7; }
.service h3 { font: 600 19px/1.2 'IBM Plex Sans', sans-serif; color: #0e1b27; margin-top: 2px; }
.service p { font: 400 14.5px/1.55 'IBM Plex Sans', sans-serif; color: #4a5560; flex: 1; }

.bureau-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  border: 1px solid #e5e9ed;
  background: #f4f6f8;
  padding: 24px 28px;
  margin-top: 16px;
}
.bureau-title { font: 600 18px 'IBM Plex Sans', sans-serif; color: #0e1b27; }
.bureau-desc {
  font: 400 14.5px/1.5 'IBM Plex Sans', sans-serif;
  color: #4a5560;
  margin-top: 5px;
  max-width: 640px;
}

/* ---------------- Stats band ---------------- */
.stats-band {
  background: #f4f6f8;
  border-top: 1px solid #e5e9ed;
  border-bottom: 1px solid #e5e9ed;
}
.stats-grid {
  padding-top: 44px;
  padding-bottom: 44px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(195px, 1fr));
  gap: 24px;
}
.stat { padding-left: 18px; border-left: 2px solid #d81f27; }
.stat-num { font: 700 30px 'IBM Plex Sans', sans-serif; color: #0e1b27; }
.stat-label { font: 400 14px 'IBM Plex Sans', sans-serif; color: #6b7681; margin-top: 4px; }

/* ---------------- Réalisations (marquee) ---------------- */
.realisations { padding-top: 64px; padding-bottom: 64px; }
.realisations .section-head { margin-bottom: 26px; }

.marquee { overflow: hidden; }
.marquee-track {
  display: flex;
  gap: 14px;
  width: max-content;
  animation: tgf-marquee 120s linear infinite;
}
#tgf-marquee:hover .marquee-track { animation-play-state: paused; }
@keyframes tgf-marquee {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}
.chantier-slide {
  position: relative;
  flex: 0 0 auto;
  width: 340px;
  height: 250px;
  overflow: hidden;
  background: #0e1b27;
}
.chantier-slide img { width: 100%; height: 100%; object-fit: cover; display: block; }
.chantier-cap {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 42px 16px 15px;
  background: linear-gradient(to top, rgba(9,17,24,0.94), rgba(9,17,24,0));
  pointer-events: none;
}
.chantier-cap span {
  font: 700 14.5px/1.3 'IBM Plex Sans', sans-serif;
  color: #ffffff;
}

/* ---------------- Zone d'intervention ---------------- */
.zone-band {
  background: #f4f6f8;
  border-top: 1px solid #e5e9ed;
  border-bottom: 1px solid #e5e9ed;
}
.zone-band > .wrap { padding-top: 60px; padding-bottom: 60px; }
.zone-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 48px;
  align-items: center;
}
.zone-lead {
  font: 400 16.5px/1.6 'IBM Plex Sans', sans-serif;
  color: #4a5560;
  margin-top: 16px;
  max-width: 460px;
}
.zone-hint {
  font: 400 14px 'IBM Plex Sans', sans-serif;
  color: #8794a0;
  margin-top: 14px;
}
.map { height: 460px; width: 100%; background: #f4f6f8; }
.leaflet-tile-pane { filter: grayscale(0.5) saturate(0.7) opacity(0.5); }

.dept-columns {
  column-width: 210px;
  column-gap: 26px;
  margin-top: clamp(18px, 5vw, 40px);
}
.dept {
  break-inside: avoid;
  display: inline-block;
  width: 100%;
  margin-bottom: 14px;
  padding-bottom: 14px;
  border-bottom: 1px solid #e2e7ee;
}
.dept-name { font: 600 14px 'IBM Plex Sans', sans-serif; color: #0e1b27; margin-bottom: 5px; }
.dept-name .code { color: #d81f27; }
.dept-cities { font: 400 13px/1.6 'IBM Plex Sans', sans-serif; color: #6b7681; }

/* ---------------- Avis Google ---------------- */
.avis-band { background: #ffffff; border-top: 1px solid #e5e9ed; }
.avis-band > .wrap { padding-top: clamp(48px, 6vw, 68px); padding-bottom: clamp(48px, 6vw, 68px); }
.avis-head { margin-bottom: 26px; }
.avis-eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font: 600 14px 'IBM Plex Sans', sans-serif; color: #5a6773; margin-bottom: 10px;
}
.avis-eyebrow svg { display: block; }
.avis-head h2 {
  font: 700 clamp(25px, 4.4vw, 34px)/1.15 'IBM Plex Sans', sans-serif;
  color: #0e1b27; letter-spacing: -.01em;
}
.avis-loading { font: 400 15px 'IBM Plex Sans', sans-serif; color: #8794a0; }

.avis-summary {
  display: flex; align-items: center; flex-wrap: wrap; gap: 14px 28px;
  padding: 22px 24px; border: 1px solid #e5e9ed; background: #f8fafb;
}
.avis-rating-num { font: 700 46px/1 'IBM Plex Sans', sans-serif; color: #0e1b27; }
.avis-summary-mid { display: flex; flex-direction: column; gap: 5px; margin-right: auto; }
.avis-stars { display: inline-flex; gap: 1px; }
.avis-star { display: block; }
.avis-count { font: 500 14px 'IBM Plex Sans', sans-serif; color: #6b7681; }
.avis-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.avis-btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 11px 18px; font: 600 14px 'IBM Plex Sans', sans-serif;
  color: #0e1b27; background: #fff; border: 1px solid #cfd8de; white-space: nowrap;
}
.avis-btn-red { background: #d81f27; color: #fff; border-color: #d81f27; }

.avis-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 16px; margin-top: 16px;
}
.avis-card { border: 1px solid #e5e9ed; background: #fff; padding: 18px 20px; }
.avis-card-head { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.avis-avatar { width: 42px; height: 42px; border-radius: 50%; object-fit: cover; flex: 0 0 auto; display: block; }
.avis-avatar-ph {
  display: flex; align-items: center; justify-content: center;
  background: #001523; color: #fff; font: 700 18px 'IBM Plex Sans', sans-serif;
}
.avis-meta { min-width: 0; }
.avis-author { font: 600 15px 'IBM Plex Sans', sans-serif; color: #0e1b27; }
.avis-sub { display: flex; align-items: center; gap: 8px; margin-top: 3px; }
.avis-time { font: 400 12.5px 'IBM Plex Sans', sans-serif; color: #8794a0; }
.avis-text { font: 400 14px/1.6 'IBM Plex Sans', sans-serif; color: #4a5560; }
.avis-attrib { font: 400 12.5px 'IBM Plex Sans', sans-serif; color: #9aa6b2; margin-top: 16px; }

.avis-fallback {
  display: flex; flex-direction: column; align-items: flex-start; gap: 16px;
  padding: 26px 24px; border: 1px solid #e5e9ed; background: #f8fafb;
}
.avis-fallback-text { font: 400 16px/1.6 'IBM Plex Sans', sans-serif; color: #4a5560; max-width: 520px; }

/* ---------------- Contact ---------------- */
.contact-band { background: #0e1b27; color: #dbe2e8; }
.contact-grid {
  padding-top: 60px;
  padding-bottom: 60px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 52px;
  align-items: start;
}
.contact-grid .eyebrow-lg { margin-bottom: 12px; }
.contact-lead {
  font: 400 16px/1.6 'IBM Plex Sans', sans-serif;
  color: #aeb9c4;
  margin-top: 14px;
  max-width: 420px;
}
.contact-coords { margin-top: 26px; display: flex; flex-direction: column; gap: 16px; }
.coord-label { font: 500 13px 'IBM Plex Sans', sans-serif; color: #8794a0; }
.coord-phone { font: 600 22px 'IBM Plex Sans', sans-serif; color: #fff; display: block; margin-top: 2px; }
.coord-mail { font: 500 16px 'IBM Plex Sans', sans-serif; color: #fff; display: block; margin-top: 2px; }
.coord-addr { font: 500 16px 'IBM Plex Sans', sans-serif; color: #fff; margin-top: 2px; }

.contact-form { display: flex; flex-direction: column; gap: 14px; }
.field-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 12px;
}
.contact-form input,
.contact-form textarea,
.contact-form select {
  border: 1px solid #2a3a48;
  background: #0a141d;
  color: #fff;
  padding: 14px 15px;
  font: 400 15px 'IBM Plex Sans', sans-serif;
  width: 100%;
}
.contact-form textarea { resize: vertical; }
.contact-form select,
.contact-form input[type="date"] { color-scheme: dark; }

.chantier-block {
  border-top: 1px solid #1c2836;
  margin-top: 6px;
  padding-top: 16px;
}
.chantier-title { font: 600 13px 'IBM Plex Sans', sans-serif; color: #c2ccd6; margin-bottom: 14px; }
.chantier-title .muted { color: #5a6774; font-weight: 500; }

.chip-group { margin-bottom: 14px; }
.chip-group:nth-of-type(2) { margin-bottom: 16px; }
.chip-label { font: 500 12px 'IBM Plex Sans', sans-serif; color: #8794a0; margin-bottom: 8px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  padding: 9px 14px;
  border: 1px solid #2a3a48;
  background: transparent;
  color: #c2ccd6;
  font: 600 13px 'IBM Plex Sans', sans-serif;
  cursor: pointer;
  user-select: none;
  transition: background .15s ease, border-color .15s ease, color .15s ease;
}
.chip.selected { background: #d81f27; border-color: #d81f27; color: #fff; }

.detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.detail-grid label { display: flex; flex-direction: column; gap: 6px; }
.detail-grid label span { font: 500 12px 'IBM Plex Sans', sans-serif; color: #8794a0; }
.detail-grid input,
.detail-grid select { padding: 13px 14px; }

.btn-submit { width: fit-content; padding: 15px 24px; font-size: 15px; }

/* ---------------- Footer ---------------- */
.site-footer { background: #0a141d; color: #8794a0; }
.foot {
  padding-top: 28px;
  padding-bottom: 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}
.foot-brand { display: flex; align-items: center; gap: 12px; }
.foot-brand img { width: 42px; height: 42px; object-fit: cover; display: block; }
.foot-name { font: 700 16px 'IBM Plex Sans', sans-serif; color: #dbe2e8; }
.foot-sub { font: 400 12.5px 'IBM Plex Sans', sans-serif; margin-top: 2px; }
.foot-legal { font: 400 13px 'IBM Plex Sans', sans-serif; text-align: right; }

/* ---------------- Nouveaux blocs ---------------- */
.nav-toggle { display: none; }

/* vignettes du carrousel : <figure> a une marge par défaut */
.chantier-slide { margin: 0; }
.chantier-cap { margin: 0; }

/* étoiles de la note Google */
.avis-stars { color: #fbbc04; font-size: 19px; letter-spacing: 2px; line-height: 1; }

.map-fallback {
  font: 400 15px/1.6 'IBM Plex Sans', sans-serif; color: #6b7681;
  padding: 24px; border: 1px dashed #cfd8de; background: #fff;
}

/* FAQ */
.faq-band { padding-top: 56px; padding-bottom: 56px; }
.faq-band .section-head { max-width: 680px; margin-bottom: 22px; }
.pfaq { border-top: 1px solid #e5e9ed; padding: 20px 0 6px; }
.pfaq h3 {
  font: 600 18px/1.35 'IBM Plex Sans', sans-serif; color: #0e1b27;
  margin-bottom: 8px; text-wrap: balance;
}
.pfaq p { font: 400 15.5px/1.7 'IBM Plex Sans', sans-serif; color: #4a5560; max-width: 82ch; }

/* ---------------- Responsive ---------------- */
@media (max-width: 860px) {
  body { padding-bottom: 62px; }              /* place pour la barre de contact */
  #tgf-head { align-items: center; gap: 10px 14px; padding-top: 10px; padding-bottom: 10px; }
  .brand img { height: 54px; width: auto; }

  /* bouton ☰ */
  .nav-toggle {
    display: inline-flex; flex-direction: column; justify-content: center; gap: 5px;
    width: 46px; height: 42px; padding: 10px; margin-left: auto;
    background: transparent; border: 1px solid #24384a; cursor: pointer;
  }
  .nav-toggle span { display: block; height: 2px; width: 100%; background: #fff; transition: transform .25s ease, opacity .2s ease; }
  .nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav-toggle.open span:nth-child(2) { opacity: 0; }
  .nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

  #tgf-nav, #tgf-actions { display: none; }

  #tgf-head.open #tgf-nav {
    display: flex; flex-direction: column; align-items: stretch;
    flex: 1 1 100%; gap: 0; margin: 6px 0 0; order: 5;
  }
  #tgf-head.open #tgf-nav a {
    padding: 15px 2px; border-top: 1px solid #12283a;
    font-size: 16px; color: #fff; white-space: normal;
  }
  #tgf-head.open #tgf-nav a .underline { display: none; }
  #tgf-head.open #tgf-actions {
    display: flex; flex-direction: column; align-items: stretch;
    flex: 1 1 100%; gap: 12px; margin-top: 14px; order: 6;
  }
  #tgf-head.open .head-phone { display: block; text-align: center; padding: 8px; font-size: 18px; }
  #tgf-head.open #tgf-actions .btn-red { justify-content: center; }
}

@media (max-width: 640px) {
  /* marges latérales confortables (le texte ne colle plus aux bords) */
  .wrap, .head { padding-left: 24px; padding-right: 24px; }
  .detail-grid { grid-template-columns: 1fr; }

  .hero-grid { gap: 24px; padding-top: 34px; padding-bottom: 34px; }
  .hero h1 { font-size: 25px; line-height: 1.14; }
  .hero-lead { font-size: 16px; margin-top: 18px; line-height: 1.65; }
  .hero-cta { flex-direction: column; align-items: stretch; gap: 12px; }
  .hero-cta .btn-red { justify-content: center; }
  .hero-call { text-align: center; }
  .hero-img { height: 230px; }

  .section-head h2, .zone-grid h2, .contact-grid h2, .avis-head h2 { font-size: 23px; }
  .services { padding-top: 46px; padding-bottom: 18px; }
  .realisations { padding-top: 46px; padding-bottom: 46px; }
  .faq-band { padding-top: 40px; padding-bottom: 40px; }
  .zone-band > .wrap { padding-top: 46px; padding-bottom: 46px; }
  .contact-grid { padding-top: 46px; padding-bottom: 46px; }

  .stats-grid { grid-template-columns: 1fr 1fr; gap: 20px 16px; padding-top: 34px; padding-bottom: 34px; }
  .stat-num { font-size: 22px; }
  .stat { padding-left: 14px; }

  .chantier-slide { width: 300px; height: 220px; }
  .map { height: 320px; }

  .contact-form input, .contact-form select, .contact-form textarea { font-size: 16px; }
  .btn-submit { width: 100%; justify-content: center; }

  .foot { justify-content: flex-start; }
  .foot-legal { text-align: left; }
}

/* ---------------- Barre de contact mobile (1 clic) ---------------- */
.tgf-contactbar { display: none; }
@media (max-width: 860px) {
  .tgf-contactbar {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 120;
    display: flex; background: #fff;
    box-shadow: 0 -8px 24px rgba(2, 12, 20, .22);
    padding-bottom: env(safe-area-inset-bottom);
  }
  .tcb-btn {
    flex: 1 1 50%; display: inline-flex; align-items: center; justify-content: center;
    gap: 10px; padding: 17px 10px;
    font: 700 15.5px 'IBM Plex Sans', sans-serif; letter-spacing: .01em;
  }
  .tcb-btn svg { display: block; flex: 0 0 auto; }
  .tcb-call { background: #d81f27; color: #fff; }
  .tcb-mail { background: #001523; color: #fff; }
}

/* ---- Formulaire : champ piège anti-robots + messages ---- */
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-status { font: 500 14.5px/1.5 'IBM Plex Sans', sans-serif; color: #aeb9c4; margin-top: 4px; min-height: 1px; }
.form-status.ok { color: #7fd2a2; }
.form-status.err { color: #ff8a80; }
