/* ==========================================================
   INGELYO – Feuille de style
   Site statique – aucune dépendance externe
   ========================================================== */

:root {
  --navy: #0b2440;
  --navy-2: #123a63;
  --sun: #f5a623;
  --sun-dark: #d98b0a;
  --ink: #1c2733;
  --muted: #5b6b7b;
  --line: #e3e8ee;
  --bg: #ffffff;
  --bg-soft: #f5f7fa;
  --radius: 10px;
  --shadow: 0 6px 24px rgba(11, 36, 64, .10);
  --maxw: 1140px;
  --header-h: 76px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 12px); }
body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--navy-2); }
a:hover { color: var(--sun-dark); }
h1, h2, h3, h4 { line-height: 1.2; color: var(--navy); margin: 0 0 .6em; }
h1 { font-size: clamp(2rem, 4.6vw, 3.2rem); letter-spacing: -.01em; }
h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; }
ul { padding-left: 1.2em; }
.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 22px; }
.skip-link { position: absolute; left: -999px; top: 0; background: var(--sun); color: #000; padding: 10px 16px; z-index: 200; }
.skip-link:focus { left: 10px; top: 10px; }

/* ---------- En-tête & navigation ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255, 255, 255, .97);
  backdrop-filter: saturate(140%) blur(6px);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; height: var(--header-h); gap: 20px; }
.brand img { height: 46px; width: auto; }
.nav-toggle {
  display: none; background: none; border: 1px solid var(--line); border-radius: 8px;
  padding: 8px 12px; font-size: 1.25rem; line-height: 1; cursor: pointer; color: var(--navy);
}
.main-nav > ul { list-style: none; display: flex; gap: 4px; margin: 0; padding: 0; align-items: center; }
.main-nav a {
  display: block; padding: 10px 14px; text-decoration: none; color: var(--navy);
  font-weight: 600; font-size: .95rem; border-radius: 8px;
}
.main-nav a:hover, .main-nav a:focus-visible { background: var(--bg-soft); color: var(--sun-dark); }
.main-nav a[aria-current="page"] { color: var(--sun-dark); }
.main-nav .nav-cta { background: var(--sun); color: #1a1a1a; margin-left: 6px; }
.main-nav .nav-cta:hover { background: var(--sun-dark); color: #fff; }
.has-sub { position: relative; }
.has-sub > .sub {
  list-style: none; margin: 0; padding: 8px; min-width: 260px;
  position: absolute; left: 0; top: 100%;
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow); display: none;
}
.has-sub:hover > .sub, .has-sub:focus-within > .sub { display: block; }
.sub a { font-weight: 500; padding: 9px 12px; }

/* ---------- Boutons ---------- */
.btn {
  display: inline-block; padding: 13px 26px; border-radius: 999px; font-weight: 700;
  text-decoration: none; border: 2px solid transparent; cursor: pointer; font-size: 1rem;
  transition: transform .15s ease, background .15s ease, color .15s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--sun); color: #1a1a1a; }
.btn-primary:hover { background: var(--sun-dark); color: #fff; }
.btn-ghost { border-color: rgba(255,255,255,.7); color: #fff; }
.btn-ghost:hover { background: #fff; color: var(--navy); }
.btn-outline { border-color: var(--navy); color: var(--navy); }
.btn-outline:hover { background: var(--navy); color: #fff; }

/* ---------- Héros ---------- */
.hero {
  position: relative; color: #fff; overflow: hidden;
  background:
    radial-gradient(circle at 82% 18%, rgba(245,166,35,.55) 0, rgba(245,166,35,0) 34%),
    linear-gradient(135deg, var(--navy) 0%, var(--navy-2) 100%);
  padding: 96px 0 88px;
}
.hero h1 { color: #fff; max-width: 15em; margin-bottom: .45em; }
.hero .lead { font-size: 1.2rem; max-width: 40em; opacity: .93; }
.hero .tags { display: flex; flex-wrap: wrap; gap: 10px; margin: 26px 0 34px; padding: 0; list-style: none; }
.hero .tags li { background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.25); padding: 6px 14px; border-radius: 999px; font-size: .92rem; }
.hero .actions { display: flex; flex-wrap: wrap; gap: 14px; }
.page-hero { padding: 52px 0 44px; }
.page-hero h1 { font-size: clamp(1.8rem, 4vw, 2.7rem); }

/* ---------- Sections ---------- */
section { padding: 52px 0; }
.section-soft { background: var(--bg-soft); }
.section-title { text-align: center; max-width: 46em; margin: 0 auto 30px; }
.eyebrow { text-transform: uppercase; letter-spacing: .14em; font-size: .8rem; font-weight: 700; color: var(--sun-dark); margin-bottom: 10px; display: block; }
.grid { display: grid; gap: 26px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

.card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 28px; box-shadow: 0 1px 2px rgba(11,36,64,.04);
  transition: box-shadow .2s ease, transform .2s ease;
}
a.card { text-decoration: none; color: inherit; display: block; }
a.card:hover { box-shadow: var(--shadow); transform: translateY(-3px); }
.card h3 { margin-bottom: .4em; }
.card p { color: var(--muted); margin: 0; }
.card .more { display: inline-block; margin-top: 14px; font-weight: 700; color: var(--sun-dark); }

.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; text-align: center; }
.stat strong { display: block; font-size: 2.4rem; color: var(--navy); line-height: 1.1; }
.stat span { color: var(--muted); font-size: .95rem; }

.quote { max-width: 46em; margin: 0 auto; text-align: center; font-size: 1.15rem; font-style: italic; color: var(--navy); }
.quote p { margin-bottom: .8em; }

/* ---------- Blocs texte + image ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 44px; align-items: center; margin-bottom: 56px; }
.split:last-child { margin-bottom: 0; }
.split.reverse > :first-child { order: 2; }
.split img { border-radius: var(--radius); box-shadow: var(--shadow); width: 100%; object-fit: cover; }
.split h3 { color: var(--navy); }

.block-head { display: flex; align-items: center; gap: 14px; margin-bottom: 30px; padding-bottom: 14px; border-bottom: 3px solid var(--sun); }
.block-head h2 { margin: 0; }

.checklist { list-style: none; padding: 0; }
.checklist li { position: relative; padding-left: 28px; margin-bottom: 10px; }
.checklist li::before { content: "✓"; position: absolute; left: 0; color: var(--sun-dark); font-weight: 800; }

.callout { background: var(--bg-soft); border-left: 4px solid var(--sun); padding: 22px 26px; border-radius: 0 var(--radius) var(--radius) 0; margin: 26px 0; }

/* ---------- Références ---------- */
.ref-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 20px; }
.ref-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.ref-card img { width: 100%; aspect-ratio: 400 / 284; object-fit: cover; background: var(--bg-soft); }
.ref-card h3 { font-size: 1rem; margin: 0; padding: 14px 16px 16px; }
.download-box { text-align: center; margin-bottom: 40px; }

/* ---------- Équipe ---------- */
.member { display: grid; grid-template-columns: 170px 1fr; gap: 34px; margin-bottom: 64px; align-items: start; }
.member img { border-radius: var(--radius); box-shadow: var(--shadow); width: 100%; aspect-ratio: 709 / 877; object-fit: cover; }
.member .role { color: var(--sun-dark); font-weight: 700; margin-bottom: 16px; }
.member .cv { background: var(--bg-soft); border-radius: var(--radius); padding: 16px 22px; margin: 18px 0; font-size: .95rem; }
.member .cv ul { list-style: none; padding: 0; margin: 8px 0 0; }
.member .cv li { margin-bottom: 4px; }

/* ---------- Contact ---------- */
.agency h3 { margin-bottom: .2em; }
.agency .region { color: var(--sun-dark); font-weight: 700; font-size: .9rem; text-transform: uppercase; letter-spacing: .08em; margin-bottom: 12px; display: block; }
.agency address { font-style: normal; margin-bottom: 14px; color: var(--ink); }
.agency p { color: var(--ink); margin-bottom: .4em; }
.agency .entity { color: var(--muted); font-size: .9rem; }

/* ---------- Bandeau d'appel à l'action ---------- */
.cta-band { background: linear-gradient(135deg, var(--navy), var(--navy-2)); color: #fff; text-align: center; padding: 46px 0; }
.cta-band h2 { color: #fff; }
.cta-band p { max-width: 38em; margin: 0 auto 26px; opacity: .92; }

/* ---------- Pied de page ---------- */
.site-footer { background: #071a30; color: #cbd5e1; padding: 52px 0 26px; font-size: .95rem; }
.site-footer a { color: #e2e8f0; text-decoration: none; }
.site-footer a:hover { color: var(--sun); text-decoration: underline; }
.site-footer h4 { color: #fff; font-size: 1rem; margin-bottom: .8em; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 34px; margin-bottom: 34px; }
.footer-brand { font-size: 1.5rem; font-weight: 800; color: #fff; letter-spacing: .04em; margin-bottom: 8px; }
.footer-brand span { color: var(--sun); }
.footer-links { list-style: none; padding: 0; margin: 0; }
.footer-links li { margin-bottom: 6px; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.12); padding-top: 20px; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; font-size: .88rem; }

/* ==========================================================
   PHOTOS DE PROJETS
   ========================================================== */

/* ---------- Carrousel plein écran de la page d'accueil ---------- */
.hero-carousel {
  min-height: clamp(540px, 80vh, 780px);
  display: flex; align-items: center;
  background: var(--navy);
  padding: 0;
}
.hero-slides { position: absolute; inset: 0; margin: 0; padding: 0; list-style: none; }
.hero-slide { position: absolute; inset: 0; opacity: 0; transition: opacity 1.3s ease; }
.hero-slide.is-active { opacity: 1; z-index: 1; }
.hero-slide img { width: 100%; height: 100%; object-fit: cover; box-shadow: none; border-radius: 0; transform: scale(1.02); }
.hero-slide.is-active img { animation: hero-zoom 10s ease-out forwards; }
@keyframes hero-zoom { from { transform: scale(1.02); } to { transform: scale(1.10); } }
.hero-carousel::before {
  content: ""; position: absolute; inset: 0; z-index: 2; pointer-events: none;
  background: linear-gradient(95deg, rgba(11,36,64,.90) 0%, rgba(11,36,64,.68) 45%, rgba(11,36,64,.28) 100%);
}
.hero-carousel > .container { position: relative; z-index: 3; padding-top: 80px; padding-bottom: 110px; }
.hero-controls {
  position: absolute; z-index: 4; left: 0; right: 0; bottom: 26px;
  display: flex; justify-content: center; align-items: center; gap: 12px;
}
.hero-dots { display: flex; gap: 10px; margin: 0 8px; }
.hero-dot { width: 12px; height: 12px; border-radius: 50%; padding: 0; border: 2px solid #fff; background: transparent; cursor: pointer; }
.hero-dot[aria-current="true"] { background: var(--sun); border-color: var(--sun); }
.hero-arrow, .hero-pause {
  width: 40px; height: 40px; border-radius: 50%; border: 1px solid rgba(255,255,255,.7);
  background: rgba(11,36,64,.35); color: #fff; font-size: 1.1rem; line-height: 1; cursor: pointer;
}
.hero-arrow:hover, .hero-pause:hover { background: var(--sun); border-color: var(--sun); color: #1a1a1a; }
.hero-pause { font-size: .8rem; }

/* ---------- Galerie « Sur le terrain » ---------- */
.photo-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.photo-tile { position: relative; display: block; overflow: hidden; border-radius: var(--radius); aspect-ratio: 4 / 3; background: var(--bg-soft); }
.photo-tile img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.photo-tile:hover img { transform: scale(1.06); }
.photo-tile span {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 32px 16px 12px;
  color: #fff; font-weight: 600; font-size: .95rem;
  background: linear-gradient(transparent, rgba(11,36,64,.88));
}

/* ---------- Bandeaux photo des pages intérieures ---------- */
.page-hero { background-size: cover; background-position: center; }
body:has(.main-nav a[aria-current="page"][href="services.html"]) .page-hero {
  background-image: linear-gradient(135deg, rgba(11,36,64,.90), rgba(18,58,99,.78)), url("../img/svc-exploitation.jpg");
}
body:has(.main-nav a[aria-current="page"][href="solutions.html"]) .page-hero {
  background-image: linear-gradient(135deg, rgba(11,36,64,.90), rgba(18,58,99,.78)), url("../img/sol-toiture.jpg");
}
body:has(.main-nav a[aria-current="page"][href="developpement.html"]) .page-hero {
  background-image: linear-gradient(135deg, rgba(11,36,64,.90), rgba(18,58,99,.78)), url("../img/dev-ombrieres.jpg");
}
body:has(.main-nav a[aria-current="page"][href="references.html"]) .page-hero {
  background-image: linear-gradient(135deg, rgba(11,36,64,.90), rgba(18,58,99,.78)), url("../img/hero/hero-les-mees.jpg");
}
body:has(.main-nav a[aria-current="page"][href="equipe.html"]) .page-hero,
body:has(.main-nav a[aria-current="page"][href="contact.html"]) .page-hero,
html:has(link[rel="canonical"][href$="/a-propos.html"]) .page-hero {
  background-image: linear-gradient(135deg, rgba(11,36,64,.90), rgba(18,58,99,.78)), url("../img/hero/inner-aleria.jpg");
}

body:has(.main-nav a[aria-current="page"][href="reglementation.html"]) .page-hero {
  background-image: linear-gradient(135deg, rgba(11,36,64,.90), rgba(18,58,99,.78)), url("../img/svc-loi-climat.jpg");
}

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .split, .member { grid-template-columns: 1fr; }
  .split.reverse > :first-child { order: 0; }
  .member img { max-width: 170px; }
}
@media (max-width: 860px) {
  .nav-toggle { display: block; }
  .main-nav {
    display: none; position: absolute; left: 0; right: 0; top: var(--header-h);
    background: #fff; border-bottom: 1px solid var(--line); box-shadow: var(--shadow);
    max-height: calc(100vh - var(--header-h)); overflow-y: auto; padding: 10px 22px 20px;
  }
  .main-nav.open { display: block; }
  .main-nav > ul { flex-direction: column; align-items: stretch; }
  .has-sub > .sub { position: static; display: block; box-shadow: none; border: 0; padding: 0 0 0 14px; min-width: 0; }
  .main-nav .nav-cta { margin: 8px 0 0; text-align: center; }
}
@media (max-width: 700px) {
  .photo-grid { grid-template-columns: repeat(2, 1fr); }
  .hero-carousel::before { background: linear-gradient(180deg, rgba(11,36,64,.78), rgba(11,36,64,.66)); }
}
@media (max-width: 600px) {
  body { font-size: 16px; }
  section { padding: 38px 0; }
  .hero { padding: 64px 0 60px; }
  .hero-carousel { padding: 0; min-height: 600px; }
  .hero-carousel > .container { padding-top: 56px; padding-bottom: 96px; }
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .ref-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .btn, .card, .photo-tile img { transition: none; }
  .hero-slide { transition: none; }
  .hero-slide.is-active img { animation: none; }
}
@media print {
  .site-header, .site-footer, .cta-band, .nav-toggle, .hero-controls { display: none; }
  section { padding: 20px 0; }
}

/* Équipe : 3 colonnes */
.team-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 36px; align-items: start; }
.team-grid .member { grid-template-columns: 1fr; gap: 20px; margin-bottom: 0; }
.team-grid .member img { max-width: 170px; }
@media (max-width: 960px) { .team-grid { grid-template-columns: 1fr; gap: 48px; } }
