﻿:root {
  --blue: #2e74b5;
  --text: #000;
  --muted: #50514f;
  --shadow: 0 16px 36px rgba(0,0,0,0.15);
}

[hidden] { display: none !important; }
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
img { max-width: 100%; display: block; height: auto; }
body {
  font-family: Raleway, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
  color: var(--muted);
  line-height: 1.65;
  background: #fff;
  font-size: 17px;
}

.container {
  width: min(1680px, calc(100vw - 32px));
  margin: 0 auto;
  padding: 0;
}

/* HEADER */
.site-header { background: #fff; border-bottom: 2px solid #000; }
.header-container {
  width: 100vw;
  max-width: none;
  min-height: 92px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  column-gap: 12px;
}
.menu-toggle { display: none !important; }
.brand img { height: 92px; width: auto; }
.header-actions { justify-self: end; padding-right: 16px; }
.btn {
  display: inline-block;
  padding: .9rem 1.6rem;
  border: 2px solid #1e5a90;
  background: #2e74b5;
  color: #fff;
  font-weight: 700;
  text-decoration: none;
}
.btn:hover { filter: brightness(.96); }

/* HERO */
.hero {
  padding: 40px 0 20px;
  text-align: center;
}
.hero-title {
  font-family: Archivo, inherit;
  color: var(--blue);
  font-size: clamp(36px,5.2vw,88px);
  line-height: 1.1;
  margin: 10px 0 36px;
}
.separator {
  background: var(--blue);
  margin: 14px auto;
}
.separator.big { height: 10px; width: 100px; }
.separator.small { height: 6px; width: 120px; }
.separator.left { margin-left: 0; }
.tagline {
  font-weight: 700;
  color: var(--text);
  font-size: clamp(24px,3.2vw,34px);
  margin: 24px 0;
}

/* SECTIONS */
.section { padding: 40px 0 0; }
.section h2 {
  font-family: Archivo, inherit;
  font-size: clamp(24px,2.5vw,32px);
  margin: 0 0 12px;
  color: var(--text);
}
.separator.small.left { margin: 0 0 12px; }
.grid.two {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}
@media (max-width: 980px) {
  .grid.two { grid-template-columns: 1fr; gap: 32px; }
}

/* TEXTE justifié */
.section-text, .section-text p, p {
  text-align: justify !important;
  text-justify: inter-word;
}

/* FIGURES */
.figure { filter: drop-shadow(var(--shadow)); text-align: center; }
.tilt-left img { transform: rotate(-3deg); }
.tilt-right img { transform: rotate(3deg); }
.figure img {
  width: 80%;
  margin: 0 auto;
  height: auto;
  border-radius: 8px;
}

/* CONTACT */
.contact {
  padding: 52px 0 72px;
  background: #fafafa;
}
.contact .container { text-align: center; }
.contact h3 {
  font-size: clamp(24px,3.2vw,34px);
  color: var(--muted);
  margin: 24px 0;
}
.contact-form {
  width: min(940px,calc(100vw-64px));
  margin: 26px auto 18px;
  text-align: left;
}
.field { margin-bottom: 15px; }
.field label {
  display: block;
  font-weight: 600;
  margin-bottom: 5px;
  color: #444;
}
.field input, .field textarea {
  width: 100%;
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 12px 14px;
  font-size: 16px;
}
.field input:focus, .field textarea:focus {
  border-color: var(--blue);
}

/* Bloc résultat sous les champs */
.form-result {
  width: 100%;
  margin: 12px 0 18px;
  background: #fff;
  border: 1px solid #e6eef9;
  box-shadow: 0 8px 20px rgba(46,116,181,0.06);
  padding: 16px 18px;
  border-radius: 8px;
  color: #222;
}
.form-result h4 { margin: 0 0 8px; color: var(--blue); text-align: center; }
.form-result p.ok {
  margin: 6px 0;
  color: #2e7d32;
  font-weight: 700;
  text-align: center;
}
.form-result p.warn {
  margin: 6px 0;
  color: #8d6e63;
  text-align: center;
}
.form-result ul.kv { margin: 8px 0 0; padding-left: 18px; }
.form-result ul.kv li { margin: 4px 0; }

/* CONTACT META & FOOTER */
.contact-meta {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 38px;
  margin: 20px 0 28px;
  flex-wrap: wrap;
}
.contact-meta .item {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 700;
  color: #444;
}
.contact-meta .icon { width: 30px; height: 30px; }

.footer-brand {
  display: flex;
  flex-direction: column;
  align-items: center;
}
.footer-brand img {
  height: 60px;
  margin: 0 auto 8px;
}
.footer-brand p {
  margin: 0;
  line-height: 1.5;
  font-size: 1em;
  text-align: center !important;
}
.footer-brand p strong { font-weight: 800; }

/* MOBILE */
@media (max-width: 768px) {
  .header-actions, .menu-toggle, .mobile-menu {
    display: none !important;
  }

  figure { margin: 0 !important; }
  .tilt-left img, .tilt-right img { transform: none !important; }
  .figure {
    width: 100vw !important;
    margin-left: calc(50% - 50vw) !important;
    margin-right: calc(50% - 50vw) !important;
  }
  .figure img {
    width: 100vw !important;
    max-width: 100vw !important;
    margin: 0 !important;
    height: auto;
    border-radius: 0;
  }

  /* ✅ ESPACE ENTRE les deux sections (mobile uniquement) */
  #section2 {
    margin-bottom: 60px;
  }
}

/* Espaces entre sections */
#section1 { padding-bottom: 0; }
#section2 { padding-top: 0; padding-bottom: 0; }
#section3 { padding-top: 0; }

/* Correction tagline hero */
.hero .tagline { text-align: center !important; }

/* === Bouton retour en haut (flèche SVG carré) === */
#back-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  background: rgba(0, 0, 0, 0.75);
  color: #fff;
  border: none;
  border-radius: 10px; /* carré adouci */
  width: 52px;
  height: 52px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: all 0.3s ease;
  z-index: 1000;
  backdrop-filter: blur(3px);
  box-shadow: 0 4px 10px rgba(0,0,0,0.25);
}

#back-to-top svg {
  width: 26px;
  height: 26px;
  stroke: white;
}

#back-to-top.visible {
  opacity: 0.9;
  visibility: visible;
  transform: translateY(0);
}

#back-to-top:hover {
  background: #000;
  opacity: 1;
  transform: translateY(-3px);
}
