/* ---------- Design tokens ---------- */
:root {
  --ink: #14241b;
  --ink-soft: #5b5848;
  --cream: #f6f1e4;
  --cream-alt: #eee6d2;
  --green-deep: #0e3b26;
  --green-deeper: #072a19;
  --green: #0b5d34;
  --gold: #b8862b;
  --gold-light: #d9b25c;
  --white: #ffffff;
  --radius: 4px;
  --shadow: 0 10px 28px rgba(14, 59, 38, 0.14);
  --font-display: "Fraunces", Georgia, serif;
  --font-body: "Public Sans", system-ui, -apple-system, Segoe UI, sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, Consolas, monospace;
  --container: 1080px;
  --gap: 1.5rem;
}

* {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}
body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
}
h1,
h2,
h3 {
  font-family: var(--font-display);
  color: var(--ink);
  margin: 0 0 0.4em;
  font-weight: 600;
  letter-spacing: -0.01em;
}
h2 {
  font-size: clamp(1.5rem, 1.1rem + 1.4vw, 2.1rem);
}
h3 {
  font-size: 1.05rem;
  font-weight: 600;
}
p {
  margin: 0 0 1em;
  color: var(--ink-soft);
}
a {
  color: var(--green);
}
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 2px;
  border-radius: 2px;
}
img {
  max-width: 100%;
  display: block;
}
.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 1.25rem;
}
.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold-light);
}
.eyebrow.dark {
  color: var(--gold);
}
.hairline {
  border: 0;
  border-top: 1px solid rgba(184, 134, 43, 0.35);
  margin: 2.5rem 0;
}

/* ---------- Skip link ---------- */
.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--gold);
  color: var(--green-deeper);
  padding: 0.6rem 1rem;
  z-index: 200;
  font-weight: 600;
  border-radius: 0 0 var(--radius) 0;
}
.skip-link:focus {
  left: 0;
}

/* ---------- Header / nav ---------- */
header.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 60;
  background: rgba(246, 241, 228, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(14, 59, 38, 0.1);
}
.nav-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.7rem 1.25rem;
}
.brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  text-decoration: none;
  color: var(--ink);
}
.brand svg {
  width: 34px;
  height: 34px;
  flex: none;
}
.brand-text {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1rem;
  line-height: 1.1;
}
.brand-text small {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.08em;
  color: var(--ink-soft);
  text-transform: uppercase;
  font-weight: 400;
}

nav.desktop-nav {
  display: none;
}
nav.desktop-nav ul {
  list-style: none;
  display: flex;
  gap: 1.75rem;
  margin: 0;
  padding: 0;
}
nav.desktop-nav a {
  text-decoration: none;
  color: var(--ink-soft);
  font-weight: 600;
  font-size: 0.92rem;
  padding: 0.3rem 0;
  border-bottom: 2px solid transparent;
}
nav.desktop-nav a.active,
nav.desktop-nav a:hover {
  color: var(--green);
  border-bottom-color: var(--gold);
}

.hamburger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: var(--radius);
  border: 1px solid rgba(14, 59, 38, 0.18);
  background: var(--white);
  cursor: pointer;
}
.hamburger svg {
  width: 20px;
  height: 20px;
}

/* Drawer mobile */
.backdrop {
  position: fixed;
  inset: 0;
  background: rgba(14, 36, 27, 0.45);
  z-index: 70;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}
.backdrop.open {
  opacity: 1;
  pointer-events: auto;
}
.drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(320px, 86vw);
  z-index: 80;
  background: var(--green-deep);
  color: var(--cream);
  transform: translateX(100%);
  transition: transform 0.3s ease;
  display: flex;
  flex-direction: column;
}
.drawer.open {
  transform: translateX(0);
}
.drawer-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.1rem 1.25rem;
  border-bottom: 1px solid rgba(246, 241, 228, 0.15);
}
.drawer-close {
  background: none;
  border: 0;
  color: var(--cream);
  font-size: 1.4rem;
  width: 44px;
  height: 44px;
  cursor: pointer;
  border-radius: var(--radius);
}
.drawer nav {
  padding: 1rem 0;
  flex: 1;
}
.drawer nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
}
.drawer nav a {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.9rem 1.25rem;
  color: var(--cream);
  text-decoration: none;
  font-weight: 500;
  min-height: 44px;
}
.drawer nav a:hover,
.drawer nav a:focus-visible {
  background: rgba(246, 241, 228, 0.08);
}
.drawer-bottom {
  padding: 1.1rem 1.25rem;
  border-top: 1px solid rgba(246, 241, 228, 0.15);
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 46px;
  padding: 0.65rem 1.3rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.92rem;
  text-decoration: none;
  cursor: pointer;
  border: 1px solid transparent;
  transition:
    transform 0.15s ease,
    background 0.15s ease;
}
.btn:hover {
  transform: translateY(-1px);
}
.btn-gold {
  background: var(--gold);
  color: var(--green-deeper);
}
.btn-gold:hover {
  background: var(--gold-light);
}
.btn-outline {
  background: transparent;
  color: var(--cream);
  border-color: rgba(246, 241, 228, 0.55);
}
.btn-outline:hover {
  background: rgba(246, 241, 228, 0.1);
}
.btn-soft {
  background: var(--white);
  color: var(--green-deep);
  border-color: rgba(14, 59, 38, 0.15);
}
.btn-soft:hover {
  background: var(--cream-alt);
}
.btn-block {
  width: 100%;
}

/* ---------- Hero ---------- */
.hero {
  background:
    radial-gradient(
      circle at 18% 20%,
      rgba(184, 134, 43, 0.16),
      transparent 45%
    ),
    var(--green-deep);
  color: var(--cream);
  padding: 6.5rem 0 4rem;
  position: relative;
  overflow: hidden;
}
.hero::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 10px;
  background: repeating-linear-gradient(
    135deg,
    var(--gold) 0 10px,
    transparent 10px 20px
  );
  opacity: 0.55;
}
.hero-grid {
  display: grid;
  gap: 2.5rem;
  align-items: center;
}
@media (min-width: 860px) {
  .hero-grid {
    grid-template-columns: 1.1fr 0.9fr;
  }
}
.seal {
  width: 64px;
  height: 64px;
  margin-bottom: 1.2rem;
}
.hero h1 {
  color: var(--white);
  font-size: clamp(1.7rem, 1.2rem + 2vw, 2.6rem);
  margin-top: 0.3rem;
}
.hero .role {
  color: var(--gold-light);
  font-weight: 600;
  margin-bottom: 1rem;
}
.hero address {
  font-style: normal;
  color: rgba(246, 241, 228, 0.85);
  font-size: 0.92rem;
  margin-bottom: 1.6rem;
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
}
.hero-photo {
  border: 1px solid rgba(184, 134, 43, 0.4);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  aspect-ratio: 3/3;
}
.hero-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

/* ---------- Sections génériques ---------- */
section {
  padding: 4rem 0;
}
section.alt {
  background: var(--cream-alt);
}
.section-head {
  max-width: 640px;
  margin-bottom: 2rem;
}
.two-col {
  display: grid;
  gap: 2.5rem;
  align-items: center;
}
@media (min-width: 860px) {
  .two-col {
    grid-template-columns: 1.1fr 0.9fr;
  }
}
.framed-img {
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid rgba(14, 59, 38, 0.12);
  /* aspect-ratio: 3/3; */
}
.framed-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top;
}

.responsibilities {
  list-style: none;
  margin: 1.2rem 0 0;
  padding: 0;
  display: grid;
  gap: 0.7rem;
  grid-template-columns: 1fr;
}
@media (min-width: 560px) {
  .responsibilities {
    grid-template-columns: 1fr 1fr;
  }
}
.responsibilities li {
  display: flex;
  gap: 0.6rem;
  color: var(--ink);
  font-weight: 500;
  font-size: 0.94rem;
}
.responsibilities li::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--gold);
  margin-top: 0.45rem;
  flex: none;
}

/* ---------- Missions (style "registre") ---------- */
.ledger {
  display: grid;
  gap: 1px;
  background: rgba(14, 59, 38, 0.12);
  border: 1px solid rgba(14, 59, 38, 0.12);
  border-radius: var(--radius);
  overflow: hidden;
}
@media (min-width: 700px) {
  .ledger {
    grid-template-columns: 1fr 1fr;
  }
}
.ledger-item {
  background: var(--cream);
  padding: 1.4rem 1.5rem;
  display: flex;
  gap: 1rem;
  transition: background 0.15s ease;
}
.ledger-item:hover {
  background: var(--white);
}
.ledger-mark {
  flex: none;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1.5px solid var(--gold);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--green-deep);
  font-size: 0.95rem;
}
.ledger-item p {
  margin: 0.25rem 0 0;
  font-size: 0.92rem;
}

/* ---------- Galerie ---------- */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.7rem;
}
@media (min-width: 640px) {
  .gallery-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}
.gallery-grid button {
  border: 0;
  padding: 0;
  background: none;
  cursor: zoom-in;
  border-radius: var(--radius);
  overflow: hidden;
  aspect-ratio: 4/3;
}
.gallery-grid img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top;
  transition: transform 0.35s ease;
}
.gallery-grid button:hover img,
.gallery-grid button:focus-visible img {
  transform: scale(1.06);
}

.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(7, 42, 25, 0.92);
  z-index: 100;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
}
.lightbox.open {
  display: flex;
}
.lightbox img {
  max-width: min(900px, 92vw);
  max-height: 85vh;
  border-radius: var(--radius);
}
.lightbox-close {
  position: absolute;
  top: 1.2rem;
  right: 1.2rem;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 0;
  background: var(--cream);
  font-size: 1.3rem;
  cursor: pointer;
}

/* ---------- Contact ---------- */
.contact-grid {
  display: grid;
  gap: 2rem;
}
@media (min-width: 920px) {
  .contact-grid {
    grid-template-columns: 2fr 1fr;
  }
}
.info-cards {
  display: grid;
  gap: 1rem;
  grid-template-columns: 1fr;
}
@media (min-width: 560px) {
  .info-cards {
    grid-template-columns: 1fr 1fr;
  }
}
.card {
  background: var(--white);
  border: 1px solid rgba(14, 59, 38, 0.12);
  border-radius: var(--radius);
  padding: 1.3rem 1.4rem;
}
.card h3 {
  margin-bottom: 0.6rem;
}
.tel-list {
  list-style: none;
  margin: 0;
  padding: 0;
  font-family: var(--font-mono);
  font-size: 0.92rem;
}
.tel-list li {
  margin-bottom: 0.4rem;
  display: flex;
  justify-content: space-between;
  gap: 0.5rem;
}
.tel-list span {
  color: var(--ink-soft);
  font-family: var(--font-body);
}

form {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  margin-top: 1rem;
}
@media (min-width: 560px) {
  form {
    grid-template-columns: 1fr 1fr;
  }
}
.field {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}
.field.full {
  grid-column: 1/-1;
}
label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--ink);
}
label .req {
  color: var(--green);
  font-weight: 700;
}
input,
textarea {
  font: inherit;
  padding: 0.65rem 0.8rem;
  border: 1px solid rgba(14, 59, 38, 0.25);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
}
.field-error {
  font-size: 0.78rem;
  color: #9b2c2c;
  min-height: 1.1em;
}
.form-actions {
  grid-column: 1/-1;
  display: flex;
  gap: 0.7rem;
  flex-wrap: wrap;
  align-items: center;
}
.form-status {
  grid-column: 1/-1;
  font-size: 0.88rem;
  border-radius: var(--radius);
  padding: 0.6rem 0.8rem;
  display: none;
}
.form-status.ok {
  display: block;
  background: #e7f3ec;
  color: #0e3b26;
}
.form-status.err {
  display: block;
  background: #fbeaea;
  color: #9b2c2c;
}

aside.id-card {
  background: var(--green-deep);
  color: var(--cream);
  border-radius: var(--radius);
  padding: 1.5rem;
  align-self: start;
}
aside.id-card h3 {
  color: var(--cream);
}
aside.id-card p {
  color: rgba(246, 241, 228, 0.85);
}
aside.id-card .links {
  display: grid;
  gap: 0.5rem;
  margin-top: 1rem;
  font-size: 0.9rem;
}
aside.id-card .links a {
  color: var(--gold-light);
  text-decoration: none;
}
aside.id-card .links a:hover {
  text-decoration: underline;
}

/* ---------- Localisation / QR ---------- */
.find-grid {
  display: grid;
  gap: 2rem;
}
@media (min-width: 860px) {
  .find-grid {
    grid-template-columns: 1fr 1fr;
  }
}
.map-frame {
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid rgba(14, 59, 38, 0.15);
}
.map-frame iframe {
  width: 100%;
  height: 280px;
  border: 0;
  display: block;
}
.qr-box {
  background: var(--white);
  border: 1px solid rgba(14, 59, 38, 0.12);
  border-radius: var(--radius);
  padding: 1.5rem;
  width: min(100%, 260px);
  margin: 0 auto;
  display: grid;
  place-items: center;
}
#qr-canvas {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: min(100%, 220px);
  max-width: 100%;
  aspect-ratio: 1;
  margin: 0 auto;
}
#qr-canvas img,
#qr-canvas canvas {
  width: 100%;
  height: 100%;
  display: block;
  border-radius: 2px;
}
.qr-fallback {
  font-size: 0.85rem;
  color: var(--ink-soft);
}
.qr-actions {
  display: flex;
  gap: 0.7rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 1.1rem;
}

/* ---------- Footer ---------- */
footer {
  background: var(--green-deeper);
  color: rgba(246, 241, 228, 0.85);
  padding: 2.5rem 0;
}
footer .container {
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
}
@media (min-width: 768px) {
  footer .container {
    flex-direction: row;
    justify-content: space-between;
    align-items: flex-start;
  }
}
footer strong {
  color: var(--cream);
}
footer a {
  color: var(--gold-light);
  text-decoration: none;
}
footer a:hover {
  text-decoration: underline;
}
.footer-links {
  display: flex;
  gap: 1rem;
  margin-top: 0.8rem;
  flex-wrap: wrap;
}

/* ---------- Flottants ---------- */
.float-wa {
  position: fixed;
  bottom: 1.4rem;
  right: 1.4rem;
  z-index: 50;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--green);
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  box-shadow: var(--shadow);
  font-size: 1.5rem;
}
.float-wa:hover {
  background: var(--green-deep);
}
.to-top {
  position: fixed;
  bottom: 1.4rem;
  left: 1.4rem;
  z-index: 50;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: var(--white);
  border: 1px solid rgba(14, 59, 38, 0.2);
  box-shadow: var(--shadow);
  display: none;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--green-deep);
  font-size: 1.1rem;
}
.to-top.show {
  display: flex;
}

/* ---------- Reveal au scroll ---------- */
.reveal {
  opacity: 0;
  transform: translateY(16px);
  transition:
    opacity 0.6s ease,
    transform 0.6s ease;
}
.reveal.in {
  opacity: 1;
  transform: none;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

@media (min-width: 860px) {
  nav.desktop-nav {
    display: flex;
  }
  .hamburger {
    display: none;
  }
}
