/* memovIA : nuit, ivoire, ambre. Filets art deco repris des trois traits du M. */
:root {
  --nuit: #0e0c0a;
  --nuit-2: #17130f;
  --ivoire: #f3ece1;
  --sable: #e6dac7;
  --encre: #1a1612;
  --ambre: #d4a24c;
  --ambre-fonce: #9a6b1f;
  --doux: rgba(243, 236, 225, 0.72);
  --doux-encre: rgba(26, 22, 18, 0.72);
  --titre: "Didot", "Bodoni 72", "Bodoni MT", "Playfair Display", Georgia, serif;
  --texte: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --pose: cubic-bezier(0.2, 0.7, 0.2, 1);
  --marge: clamp(20px, 5vw, 72px);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 76px; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--nuit);
  color: var(--ivoire);
  font: 17px/1.6 var(--texte);
  -webkit-font-smoothing: antialiased;
}
/* Grain de pellicule, tres leger. */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 50;
  opacity: 0.06;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='g'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23g)'/%3E%3C/svg%3E");
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
h1, h2, h3 { font-family: var(--titre); font-weight: 400; line-height: 1.08; margin: 0; letter-spacing: -0.01em; }
p { margin: 0; }

/* En-tete */
.barre {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  gap: 28px;
  padding: 14px var(--marge);
  padding-top: max(14px, env(safe-area-inset-top));
  transition: background 0.4s, box-shadow 0.4s;
}
.barre.pleine {
  background: rgba(14, 12, 10, 0.86);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  box-shadow: 0 1px 0 rgba(212, 162, 76, 0.18);
}
.marque { display: flex; align-items: center; gap: 10px; min-height: 44px; text-decoration: none; }
.mot { font-family: var(--titre); font-size: 26px; letter-spacing: 0.01em; }
.mot b { font-weight: 400; color: var(--ambre); }
.barre nav { display: flex; gap: 26px; margin-left: auto; }
.barre nav a { text-decoration: none; font-size: 15px; color: var(--doux); transition: color 0.2s; }
.barre nav a:hover { color: var(--ivoire); }

/* Boutons */
.bouton {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 28px;
  border: 1px solid var(--ambre);
  border-radius: 999px;
  background: var(--ambre);
  color: var(--nuit);
  font: 600 16px/1 var(--texte);
  letter-spacing: 0.01em;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.25s var(--pose), background 0.25s, color 0.25s;
}
.bouton:hover { transform: translateY(-2px); background: #e2b45f; }
.bouton-clair { background: transparent; color: var(--ivoire); border-color: rgba(243, 236, 225, 0.4); }
.bouton-clair:hover { background: rgba(243, 236, 225, 0.08); }
.bouton-petit { min-height: 42px; padding: 0 20px; font-size: 14px; }

/* Ouverture */
.ouverture {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  overflow: hidden;
  padding: 120px var(--marge) 80px;
}
.ouverture-fond { position: absolute; inset: 0; overflow: hidden; }
.ouverture-fond img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 72% 60%;
  animation: approche 24s var(--pose) both;
}
.ouverture-fond::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(14, 12, 10, 0.94) 0%, rgba(14, 12, 10, 0.7) 42%, rgba(14, 12, 10, 0.05) 75%),
    linear-gradient(0deg, var(--nuit) 0%, rgba(14, 12, 10, 0) 30%);
}
@keyframes approche { from { transform: scale(1.12); } to { transform: scale(1); } }
.ouverture-texte { position: relative; max-width: 640px; }
.surtitre {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ambre);
  margin-bottom: 22px;
}
.ouverture h1 { font-size: clamp(42px, 6.4vw, 84px); }
.ouverture h1 em { font-style: italic; color: var(--ambre); white-space: nowrap; }
.chapeau { margin-top: 26px; font-size: clamp(17px, 1.6vw, 20px); color: var(--doux); max-width: 540px; }
.actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 36px; }
.preuves { display: flex; flex-wrap: wrap; gap: 10px 26px; list-style: none; padding: 0; margin: 40px 0 0; font-size: 14px; color: var(--doux); }
.preuves li { display: flex; align-items: center; gap: 10px; }
.preuves li::before { content: ""; width: 18px; height: 7px; border-top: 1px solid var(--ambre); border-bottom: 1px solid var(--ambre); }

/* Sections */
.section { padding: clamp(80px, 11vw, 150px) var(--marge); }
.sombre { background: var(--nuit); }
.ivoire { background: var(--ivoire); color: var(--encre); }
.ivoire .surtitre { color: var(--ambre-fonce); }
.tete { max-width: 760px; margin: 0 auto clamp(44px, 6vw, 72px); text-align: center; }
.section h2 { font-size: clamp(36px, 5vw, 64px); }
.grand { font-size: clamp(18px, 1.7vw, 21px); margin-top: 26px; color: var(--doux); }
.ivoire .grand { color: var(--doux-encre); }
.filets {
  width: 72px;
  height: 9px;
  margin: 26px auto 0;
  border-top: 1px solid var(--ambre);
  border-bottom: 1px solid var(--ambre);
  position: relative;
}
.filets::after { content: ""; position: absolute; left: 0; right: 0; top: 3px; border-top: 1px solid var(--ambre); }
.deux-colonnes .filets { margin-left: 0; }

/* Cartes des supports */
.cartes {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 18px;
  max-width: 1400px;
  margin: 0 auto;
}
.carte { position: relative; }
.carte-image { border-radius: 6px; overflow: hidden; aspect-ratio: 4 / 5; background: var(--nuit-2); }
.carte img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 62%; transition: transform 1.2s var(--pose); }
.carte:hover img { transform: scale(1.05); }
.carte-texte { padding: 22px 2px 0; }
.carte h3 { font-size: 27px; }
.carte p { margin-top: 10px; font-size: 15px; line-height: 1.55; color: var(--doux); }

/* Restauration */
.deux-colonnes {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(40px, 7vw, 110px);
  max-width: 1200px;
  margin: 0 auto;
  align-items: start;
}
.liste-fine { list-style: none; margin: 0; padding: 0; }
.liste-fine li {
  display: grid;
  grid-template-columns: 170px 1fr;
  gap: 18px;
  padding: 24px 0;
  border-top: 1px solid rgba(26, 22, 18, 0.16);
}
.liste-fine li:last-child { border-bottom: 1px solid rgba(26, 22, 18, 0.16); }
.liste-fine strong { font-family: var(--titre); font-weight: 400; font-size: 22px; line-height: 1.2; }
.liste-fine span { color: var(--doux-encre); }

/* Etapes */
.etapes {
  list-style: none;
  margin: 0 auto;
  padding: 0;
  max-width: 1200px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}
.etapes li { padding: 34px 26px 30px; border: 1px solid rgba(212, 162, 76, 0.22); border-radius: 6px; background: var(--nuit-2); }
.chiffre { display: block; font-family: var(--titre); font-size: 44px; color: var(--ambre); line-height: 1; margin-bottom: 26px; }
.etapes h3 { font-size: 24px; }
.etapes p { margin-top: 12px; font-size: 15px; color: var(--doux); }

/* Engagements */
.trois { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(28px, 4vw, 60px); max-width: 1100px; margin: 0 auto; text-align: center; }
.trois h3 { font-size: 28px; }
.trois p { margin-top: 12px; color: var(--doux-encre); }

/* Questions */
.faq { max-width: 820px; margin: 0 auto; }
.faq details { border-top: 1px solid rgba(243, 236, 225, 0.16); }
.faq details:last-child { border-bottom: 1px solid rgba(243, 236, 225, 0.16); }
.faq summary {
  list-style: none;
  cursor: pointer;
  padding: 24px 44px 24px 0;
  position: relative;
  font-family: var(--titre);
  font-size: clamp(20px, 2.2vw, 25px);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  position: absolute;
  right: 6px;
  top: 50%;
  transform: translateY(-50%);
  font: 300 28px/1 var(--texte);
  color: var(--ambre);
  transition: transform 0.3s var(--pose);
}
.faq details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq details p { padding: 0 0 26px; color: var(--doux); max-width: 680px; }

/* Demande */
.formulaire {
  display: grid;
  grid-template-columns: 1fr 1.15fr;
  gap: clamp(24px, 4vw, 56px);
  max-width: 1100px;
  margin: 0 auto;
}
.quantites { border: 0; margin: 0; padding: 0; }
.quantites legend, .coordonnees label { font-weight: 600; font-size: 14px; letter-spacing: 0.04em; }
.quantites legend { margin-bottom: 8px; padding: 0; }
.quantite { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 0; border-bottom: 1px solid rgba(26, 22, 18, 0.14); }
.quantite label { font-family: var(--titre); font-size: 21px; }
.compteur { display: flex; align-items: center; border: 1px solid rgba(26, 22, 18, 0.25); border-radius: 999px; background: #fff; }
.compteur button {
  width: 46px;
  height: 46px;
  border: 0;
  background: none;
  font: 400 22px/1 var(--texte);
  color: var(--encre);
  cursor: pointer;
  border-radius: 999px;
}
.compteur button:hover { background: var(--sable); }
.compteur input {
  width: 64px;
  height: 46px;
  border: 0;
  background: none;
  text-align: center;
  font: 600 17px/1 var(--texte);
  color: var(--encre);
  -moz-appearance: textfield;
}
.compteur input::-webkit-inner-spin-button, .compteur input::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
.coordonnees { display: grid; gap: 16px; align-content: start; }
.coordonnees label { display: grid; gap: 7px; }
.coordonnees small { font-weight: 400; color: var(--doux-encre); letter-spacing: 0; }
.coordonnees input, .coordonnees textarea {
  width: 100%;
  min-height: 50px;
  padding: 13px 16px;
  border: 1px solid rgba(26, 22, 18, 0.25);
  border-radius: 8px;
  background: #fff;
  font: 16px/1.4 var(--texte);
  color: var(--encre);
  resize: vertical;
}
.coordonnees input:focus, .coordonnees textarea:focus, .compteur input:focus { outline: 2px solid var(--ambre); outline-offset: 1px; }
.coordonnees .bouton { width: 100%; margin-top: 6px; }
.piege { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.resume { min-height: 1.6em; font-family: var(--titre); font-size: 19px; }
.petit { font-size: 13px; color: var(--doux-encre); text-align: center; }
.message { max-width: 1100px; margin: 0 auto 32px; padding: 16px 20px; border-radius: 8px; font-weight: 600; }
.reussite { background: #e3eedc; color: #24411a; }
.echec { background: #f6dfd6; color: #6b2412; }

/* Pied */
.pied {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 40px var(--marge) max(40px, env(safe-area-inset-bottom));
  border-top: 1px solid rgba(212, 162, 76, 0.18);
  font-size: 14px;
  color: var(--doux);
}
.pied .mot { font-size: 22px; color: var(--ivoire); }
.pied p a { display: inline-block; padding: 12px 0; }

/* Apparition au defilement (classe posee par site.js) */
.anime .apparait { opacity: 0; transform: translateY(18px); transition: opacity 1.1s var(--pose), transform 1.1s var(--pose); }
.anime .apparait.vu { opacity: 1; transform: none; }

@media (max-width: 1100px) {
  .cartes { display: flex; flex-wrap: wrap; justify-content: center; }
  .carte { flex: 0 0 calc((100% - 36px) / 3); }
  .etapes { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 860px) {
  .barre nav { display: none; }
  .barre .bouton-petit { margin-left: auto; }
  .deux-colonnes, .formulaire, .trois { grid-template-columns: 1fr; }
  .liste-fine li { grid-template-columns: 1fr; gap: 6px; }
}
@media (max-width: 700px) {
  body { font-size: 16px; }
  .mot { font-size: 23px; }
  .barre { gap: 12px; padding-left: 18px; padding-right: 18px; }
  .ouverture { align-items: flex-end; padding-bottom: 56px; }
  .ouverture { padding-top: 44svh; }
  .ouverture-fond { bottom: auto; height: 62svh; }
  .ouverture-fond img { object-position: 86% 70%; }
  .ouverture-fond::after {
    background: linear-gradient(0deg, var(--nuit) 4%, rgba(14, 12, 10, 0.55) 38%, rgba(14, 12, 10, 0.1) 70%, rgba(14, 12, 10, 0.6) 100%);
  }
  .actions .bouton { flex: 1 1 100%; }
  .carte { flex: none; }
  .cartes {
    display: grid;
    justify-content: start;
    grid-template-columns: none;
    grid-auto-flow: column;
    grid-auto-columns: 78%;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    margin: 0 calc(var(--marge) * -1);
    padding: 0 var(--marge) 8px;
    scrollbar-width: none;
  }
  .cartes::-webkit-scrollbar { display: none; }
  .carte { scroll-snap-align: center; }
  .etapes { grid-template-columns: 1fr; }
  .quantite label { font-size: 19px; }
}
@media (max-width: 380px) {
  .barre .bouton-petit { padding: 0 14px; }
  .mot { font-size: 21px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .ouverture-fond img { animation: none; }
  .anime .apparait { opacity: 1; transform: none; transition: none; }
}
