/* =========================================================================
   LR Maçonnerie — thème beige & bleu canard, tout centré
   ========================================================================= */

:root {
  --white: #ffffff;
  --cream: #fbf7f0;
  --beige: #f3ebdd;
  --beige-dark: #e8dcc6;
  --sand: #d9c9ab;

  --teal: #15636b;          /* bleu canard */
  --teal-dark: #0e474d;
  --teal-light: #2b838c;
  --teal-soft: #e2edec;

  --ink: #17282a;
  --ink-soft: #3d4f50;
  --ink-muted: #6c7a78;

  --border: #e5dccb;
  --shadow: 0 24px 64px rgba(20, 40, 42, 0.10);
  --shadow-soft: 0 10px 34px rgba(20, 40, 42, 0.07);

  --font-serif: "Cormorant Garamond", Georgia, "Times New Roman", serif;
  --font-sans: "Outfit", system-ui, -apple-system, Segoe UI, sans-serif;

  --header-h: 5.25rem;
  --max-width: 74rem;
  --radius: 4px;
  --transition: 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-sans);
  font-weight: 300;
  font-size: 1.05rem;
  line-height: 1.75;
  color: var(--ink-soft);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
  text-align: center;
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--teal); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--teal-dark); }

h1, h2, h3 { font-family: var(--font-serif); color: var(--ink); font-weight: 500; }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); border: 0;
}

.container {
  width: min(100% - 2.5rem, var(--max-width));
  margin-inline: auto;
}

/* ---------- Typographie utilitaire ---------- */
.eyebrow {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--teal);
  margin: 0 0 1.1rem;
}

.section-title {
  font-size: clamp(2rem, 4.6vw, 3.1rem);
  line-height: 1.12;
  margin: 0 0 1.1rem;
}

.section-lead {
  font-size: 1.15rem;
  color: var(--ink-muted);
  max-width: 42rem;
  margin: 0 auto 1.5rem;
}

.divider {
  width: 66px; height: 2px; margin: 0 auto 1.6rem;
  background: var(--teal);
  opacity: 0.85;
}

/* ---------- Boutons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-family: var(--font-sans);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  padding: 0.95rem 2.1rem;
  border-radius: var(--radius);
  border: 1px solid transparent;
  cursor: pointer;
  transition: all var(--transition);
}

.btn-primary { background: var(--teal); color: #fff; }
.btn-primary:hover { background: var(--teal-dark); color: #fff; transform: translateY(-2px); box-shadow: var(--shadow-soft); }

.btn-ghost { background: transparent; color: var(--ink); border-color: var(--ink); }
.btn-ghost:hover { background: var(--ink); color: #fff; }

.btn-light { background: rgba(255,255,255,0.14); color: #fff; border-color: rgba(255,255,255,0.5); backdrop-filter: blur(4px); }
.btn-light:hover { background: #fff; color: var(--teal-dark); }

/* ---------- En-tête ---------- */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 100;
  height: var(--header-h);
  background: rgba(251, 247, 240, 0.9);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color var(--transition), box-shadow var(--transition), background var(--transition);
}
.site-header.is-scrolled {
  border-bottom-color: var(--border);
  box-shadow: var(--shadow-soft);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

.logo { display: inline-flex; align-items: center; gap: 0.7rem; }
.logo-img { height: 44px; width: auto; }
.logo-word {
  font-family: var(--font-serif);
  font-size: 1.5rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--ink);
  line-height: 1;
}
.logo-word span { color: var(--teal); }

.site-nav { display: flex; align-items: center; gap: 2rem; }
.site-nav a {
  position: relative;
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-soft);
}
.site-nav a::after {
  content: ""; position: absolute; left: 0; bottom: -6px;
  width: 0; height: 2px; background: var(--teal);
  transition: width var(--transition);
}
.site-nav a:hover, .site-nav a.is-active { color: var(--teal); }
.site-nav a.is-active::after, .site-nav a:hover::after { width: 100%; }

.nav-toggle {
  display: none;
  width: 44px; height: 44px;
  border: 1px solid var(--border);
  background: var(--white);
  border-radius: var(--radius);
  cursor: pointer;
  position: relative;
  flex-shrink: 0;
}
.nav-toggle-bar, .nav-toggle-bar::before, .nav-toggle-bar::after {
  content: ""; position: absolute; left: 50%; top: 50%;
  width: 20px; height: 2px; background: var(--ink);
  transform: translate(-50%, -50%);
  transition: transform var(--transition), opacity var(--transition);
}
.nav-toggle-bar::before { transform: translate(-50%, -7px); }
.nav-toggle-bar::after { transform: translate(-50%, 5px); }

@media (max-width: 860px) {
  .header-inner {
    gap: 0.75rem;
  }

  .logo {
    min-width: 0;
    flex: 1;
  }

  .logo-word {
    font-size: clamp(1.05rem, 4.2vw, 1.35rem);
  }

  .nav-toggle {
    display: grid;
    place-items: center;
  }

  /* Menu masqué par défaut — évite l'affichage miniature dans la barre */
  .site-nav {
    display: none;
    position: fixed;
    top: var(--header-h);
    left: 0;
    right: 0;
    width: 100%;
    z-index: 99;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--cream);
    border-bottom: 1px solid var(--border);
    padding: 0.35rem 0 1rem;
    box-shadow: var(--shadow-soft);
  }

  .site-nav.is-open {
    display: flex;
  }

  .site-nav a {
    padding: 0.95rem 1.25rem;
    width: 100%;
    font-size: 0.88rem;
    text-align: center;
  }

  .site-nav a::after { display: none; }
}

body.nav-open {
  overflow: hidden;
}

/* ---------- Hero (accueil) ---------- */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
  padding: var(--header-h) 1rem 2rem;
}
.hero-media {
  position: absolute; inset: 0;
  background: var(--teal-dark) center/cover no-repeat;
  transform: scale(1.05);
}
.hero-overlay {
  position: absolute; inset: 0;
  background:
    linear-gradient(180deg, rgba(14,71,77,0.55) 0%, rgba(14,71,77,0.35) 40%, rgba(23,40,42,0.7) 100%);
}
.hero-content { position: relative; z-index: 2; max-width: 60rem; }
.hero .eyebrow { color: #e7d8bd; }

.hero-title {
  font-size: clamp(2.1rem, 7.4vw, 6rem);
  line-height: 1.02;
  font-weight: 500;
  color: #fff;
  margin: 0 0 1.4rem;
  white-space: nowrap;           /* gros titre sur une seule ligne */
  letter-spacing: 0.01em;
  text-shadow: 0 2px 30px rgba(0,0,0,0.25);
}
.hero-lead {
  font-size: 1.2rem;
  color: rgba(255,255,255,0.92);
  max-width: 40rem;
  margin: 0 auto 2.2rem;
  font-weight: 300;
}
.hero-actions { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }

.scroll-cue {
  position: absolute; bottom: 1.6rem; left: 50%; transform: translateX(-50%);
  z-index: 2; color: rgba(255,255,255,0.7); font-size: 0.7rem;
  letter-spacing: 0.25em; text-transform: uppercase;
}
.scroll-cue::after {
  content: ""; display: block; width: 1px; height: 34px; margin: 0.6rem auto 0;
  background: rgba(255,255,255,0.6);
  animation: cue 1.8s ease-in-out infinite;
}
@keyframes cue { 0%,100% { transform: scaleY(0.4); opacity: 0.4; } 50% { transform: scaleY(1); opacity: 1; } }

/* ---------- Sections ---------- */
.section { padding: clamp(4rem, 9vw, 7.5rem) 0; }
.section-alt { background: var(--beige); }
.section-teal { background: var(--teal); color: #fff; }
.section-teal .section-title,
.section-teal h2 { color: #fff; }
.section-teal .section-lead { color: rgba(255,255,255,0.85); }
.section-teal .eyebrow { color: #e7d8bd; }

.section-header { margin-bottom: 3.4rem; }

/* Bandeau page interne */
.page-hero {
  padding: calc(var(--header-h) + 4.5rem) 1rem 4rem;
  background: var(--teal);
  color: #fff;
}
.page-hero .eyebrow { color: #e7d8bd; }
.page-hero h1 { font-size: clamp(2.3rem, 5.5vw, 3.6rem); color: #fff; margin: 0 0 0.8rem; }
.page-hero p { color: rgba(255,255,255,0.85); max-width: 40rem; margin: 0 auto; }

/* ---------- Stats ---------- */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2rem;
}
.stat-value {
  display: block;
  font-family: var(--font-serif);
  font-size: clamp(2.4rem, 5vw, 3.4rem);
  color: var(--teal);
  line-height: 1;
}
.stat-label {
  display: block;
  font-size: 0.8rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-muted);
  margin-top: 0.6rem;
}
@media (max-width: 760px) { .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 2.4rem; } }

/* ---------- Grille de services ---------- */
.cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.6rem;
}
@media (max-width: 900px) { .cards { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .cards { grid-template-columns: 1fr; } }

.card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2.4rem 1.8rem;
  transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
}
.card:hover { transform: translateY(-6px); box-shadow: var(--shadow); border-color: var(--sand); }
.card-icon {
  width: 58px; height: 58px; margin: 0 auto 1.3rem;
  display: grid; place-items: center;
  border-radius: 50%;
  background: var(--teal-soft);
  color: var(--teal);
}
.card-icon svg { width: 28px; height: 28px; }
.card h3 { font-size: 1.5rem; margin: 0 0 0.6rem; }
.card p { margin: 0; color: var(--ink-muted); font-size: 0.98rem; }

/* ---------- Bloc "à propos" centré ---------- */
.about { max-width: 46rem; margin: 0 auto; }
.about p { margin: 0 0 1.2rem; }

.feature-list {
  list-style: none; padding: 0; margin: 2rem auto 0;
  display: inline-flex; flex-direction: column; gap: 0.9rem;
  text-align: left;
}
.feature-list li { display: flex; gap: 0.75rem; align-items: flex-start; color: var(--ink-soft); }
.feature-list svg { flex: none; width: 22px; height: 22px; color: var(--teal); margin-top: 3px; }

/* ---------- Savoir-faire (cartes image de fond) ---------- */
.services-gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.2rem;
}
@media (max-width: 1100px) { .services-gallery { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .services-gallery { grid-template-columns: 1fr; } }

.service-item {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  aspect-ratio: 4 / 3;
  background: var(--beige-dark);
}
.service-media {
  position: absolute;
  inset: 0;
}
.service-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}
.service-item:hover .service-media img { transform: scale(1.06); }
.service-media.is-fallback {
  background: linear-gradient(150deg, var(--teal-soft), var(--beige-dark));
}
.service-caption {
  position: absolute;
  inset: auto 0 0 0;
  z-index: 2;
  padding: 1.5rem 1.2rem 1.2rem;
  background: linear-gradient(180deg, transparent 0%, rgba(14,71,77,0.88) 55%, rgba(14,71,77,0.95) 100%);
  color: #fff;
  text-align: left;
}
.service-caption strong {
  display: block;
  font-family: var(--font-serif);
  font-size: 1.3rem;
  font-weight: 500;
  margin-bottom: 0.35rem;
}
.service-caption p {
  margin: 0;
  font-size: 0.92rem;
  line-height: 1.55;
  color: rgba(255,255,255,0.9);
}

/* ---------- Mosaïque réalisations ---------- */
.container--wide {
  width: min(100% - 2rem, 80rem);
  margin-inline: auto;
}

.mosaic {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 0.45rem;
}
@media (min-width: 900px) {
  .mosaic { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 0.55rem; }
}

.mosaic-item {
  position: relative;
  display: block;
  padding: 0;
  border: none;
  border-radius: var(--radius);
  overflow: hidden;
  cursor: pointer;
  background: var(--beige-dark);
  aspect-ratio: 1;
}
.mosaic-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1), filter var(--transition);
}
.mosaic-item:hover img {
  transform: scale(1.04);
  filter: brightness(1.05);
}

/* ---------- Galerie / réalisations (legacy) ---------- */
.gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.2rem;
}
@media (max-width: 900px) { .gallery { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .gallery { grid-template-columns: 1fr; } }

.gallery-item {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  cursor: pointer;
  background: var(--beige-dark);
  aspect-ratio: 4 / 3;
}
.gallery-item img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform 0.6s cubic-bezier(0.4,0,0.2,1);
}
.gallery-item:hover img { transform: scale(1.06); }
.gallery-caption {
  position: absolute; inset: auto 0 0 0;
  padding: 1.5rem 1rem 1rem;
  background: linear-gradient(180deg, transparent, rgba(14,71,77,0.85));
  color: #fff;
  text-align: left;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity var(--transition), transform var(--transition);
}
.gallery-item:hover .gallery-caption { opacity: 1; transform: translateY(0); }
.gallery-caption strong { display: block; font-family: var(--font-serif); font-size: 1.25rem; font-weight: 500; }
.gallery-caption span { font-size: 0.8rem; letter-spacing: 0.08em; opacity: 0.85; }
.gallery-count {
  position: absolute; top: 0.8rem; right: 0.8rem;
  background: rgba(23,40,42,0.7); color: #fff;
  font-size: 0.72rem; letter-spacing: 0.05em;
  padding: 0.25rem 0.6rem; border-radius: 40px;
  display: inline-flex; align-items: center; gap: 0.3rem;
}

.empty-state {
  padding: 3rem 1rem; color: var(--ink-muted);
  border: 1px dashed var(--border); border-radius: var(--radius);
}

/* ---------- Bandeau CTA ---------- */
.cta-band { padding: clamp(4rem, 8vw, 6.5rem) 0; }
.cta-inner h2 { font-size: clamp(2rem, 4.5vw, 3rem); margin: 0 0 1rem; }
.cta-inner p { margin: 0 auto 2rem; max-width: 34rem; }

/* ---------- Contact ---------- */
.contact-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.6rem;
  margin-bottom: 3.2rem;
}
@media (max-width: 760px) { .contact-grid { grid-template-columns: 1fr; } }
.contact-card {
  background: var(--white); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 2rem 1.5rem;
}
.contact-card .card-icon { margin-bottom: 1rem; }
.contact-card h3 { font-size: 1.2rem; margin: 0 0 0.4rem; }
.contact-card p, .contact-card a { margin: 0; font-size: 0.98rem; color: var(--ink-soft); }

.form {
  max-width: 40rem; margin: 0 auto; text-align: left;
  display: grid; gap: 1.1rem;
}
.field { display: grid; gap: 0.4rem; }
.field span { font-size: 0.78rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-muted); }
.field input, .field textarea, .field select {
  font-family: var(--font-sans); font-size: 1rem; color: var(--ink);
  padding: 0.85rem 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--white);
  transition: border-color var(--transition), box-shadow var(--transition);
}
.field input:focus, .field textarea:focus, .field select:focus {
  outline: none; border-color: var(--teal);
  box-shadow: 0 0 0 3px var(--teal-soft);
}
.field textarea { resize: vertical; min-height: 140px; }
.form .btn { justify-self: center; margin-top: 0.5rem; }

.form-status { text-align: center; font-size: 0.95rem; min-height: 1.4rem; margin: 0; }
.form-status.is-ok { color: var(--teal); }
.form-status.is-error { color: #b4433a; }

.captcha-q {
  margin: 0 0 0.5rem;
  font-family: var(--font-serif);
  font-size: 1.35rem;
  color: var(--teal);
}

.hp-field {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* ---------- Pages de texte (légal) ---------- */
.prose { max-width: 46rem; margin: 0 auto; text-align: left; }
.prose h2 { font-size: 1.6rem; margin: 2.2rem 0 0.6rem; }
.prose h2:first-child { margin-top: 0; }
.prose p { margin: 0 0 1rem; }
.prose a { text-decoration: underline; }

/* ---------- Pied de page ---------- */
.site-footer {
  background: var(--ink);
  color: rgba(255,255,255,0.72);
  padding: 3.5rem 0 2rem;
}
.footer-inner { display: flex; flex-direction: column; align-items: center; gap: 1.3rem; }
.footer-logo .logo-word { color: #fff; }
.footer-logo .logo-word span { color: var(--teal-light); }
.footer-tagline { max-width: 34rem; margin: 0; }
.footer-nav { display: flex; flex-wrap: wrap; gap: 1.5rem; justify-content: center; }
.footer-nav a { color: rgba(255,255,255,0.72); font-size: 0.82rem; letter-spacing: 0.1em; text-transform: uppercase; }
.footer-nav a:hover { color: #fff; }
.footer-copy { font-size: 0.82rem; color: rgba(255,255,255,0.5); margin: 0.5rem 0 0; }
.footer-copy a { color: rgba(255,255,255,0.7); }
.footer-copy a:hover { color: #fff; }

/* ---------- Loader ---------- */
.site-loader {
  position: fixed; inset: 0; z-index: 2000;
  display: grid; place-items: center;
  background: var(--cream);
  transition: opacity 0.6s ease, visibility 0.6s ease;
}
.site-loader.is-hidden { opacity: 0; visibility: hidden; }
.loader-logo { width: 90px; height: auto; animation: pulse 1.6s ease-in-out infinite; }
@keyframes pulse { 0%,100% { opacity: 0.35; transform: scale(0.96); } 50% { opacity: 1; transform: scale(1); } }

/* ---------- Animations au scroll ---------- */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity 0.8s ease, transform 0.8s ease; }
.reveal.is-visible { opacity: 1; transform: none; }

/* ---------- Visionneuse d'images ---------- */
.viewer { position: fixed; inset: 0; z-index: 900; display: none; place-items: center; background: rgba(17,26,27,0.92); }
.viewer.is-open { display: grid; }
.viewer img { max-width: 90vw; max-height: 84vh; border-radius: var(--radius); box-shadow: 0 30px 80px rgba(0,0,0,0.5); }
.viewer button {
  position: absolute; background: rgba(255,255,255,0.12); color: #fff;
  border: 1px solid rgba(255,255,255,0.3); width: 52px; height: 52px;
  border-radius: 50%; font-size: 1.4rem; cursor: pointer; transition: background var(--transition);
}
.viewer button:hover { background: rgba(255,255,255,0.28); }
.viewer-close { top: 1.4rem; right: 1.4rem; }
.viewer-prev { left: 1.4rem; top: 50%; transform: translateY(-50%); }
.viewer-next { right: 1.4rem; top: 50%; transform: translateY(-50%); }
@media (max-width: 600px) { .viewer-prev { left: 0.6rem; } .viewer-next { right: 0.6rem; } }
