/* ============================================================
   Optique Squash — Saint-Cloud
   Feuille de style principale
   ------------------------------------------------------------
   Palette et matières reprises de la boutique :
   chêne clair des étagères, lumière chaude en rampe,
   velours bleu paon du fauteuil, encre noire de l'enseigne.
   ============================================================ */

/* ---------- 1. Jetons de design ---------- */
:root {
  /* Couleurs */
  --ivoire:        #FBF8F3;
  --ivoire-creux:  #F2EBE0;
  --chene:         #C8A170;
  --chene-clair:   #E8D6BC;
  --encre:         #191A1C;
  --encre-doux:    #5A5C60;
  --paon:          #1D5C5C;
  --paon-vif:      #2A807C;
  --blanc:         #FFFFFF;

  /* Typographie */
  --enseigne: "Yellowtail", cursive;
  --titre:    "Fraunces", Georgia, serif;
  --texte:    "Jost", "Helvetica Neue", Arial, sans-serif;

  /* Rythme */
  --gouttiere: clamp(1.25rem, 4vw, 2.5rem);
  --section:   clamp(4.5rem, 10vw, 8rem);
  --largeur:   1180px;

  /* Transitions */
  --doux: 380ms cubic-bezier(.22, .61, .36, 1);
}

/* ---------- 2. Réinitialisation ---------- */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--ivoire);
  color: var(--encre);
  font-family: var(--texte);
  font-size: 1.125rem;
  line-height: 1.68;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
}

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

a { color: inherit; }

h1, h2, h3 { margin: 0; font-weight: 400; line-height: 1.15; }

p { margin: 0 0 1.15em; }

ul { margin: 0; padding: 0; list-style: none; }

/* ---------- 3. Accessibilité ---------- */
:focus-visible {
  outline: 2px solid var(--paon-vif);
  outline-offset: 3px;
}

.saut-contenu {
  position: absolute;
  left: -9999px;
  background: var(--encre);
  color: var(--ivoire);
  padding: .75rem 1.25rem;
  z-index: 999;
}
.saut-contenu:focus { left: 1rem; top: 1rem; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    transition-duration: .01ms !important;
  }
}

/* ---------- 4. Trame ---------- */
.trame {
  width: min(100% - 2 * var(--gouttiere), var(--largeur));
  margin-inline: auto;
}

.section { padding-block: var(--section); }

.section--creux { background: var(--ivoire-creux); }

/* ---------- 5. Élément signature : la rampe lumineuse ----------
   Reprise des réglettes LED sous chaque étagère de la boutique :
   un filet de chêne surmonté d'un halo chaud qui se dissipe.       */
.rampe {
  position: relative;
  height: 1px;
  background: var(--chene);
  margin-block: 1.4rem 2.6rem;
  max-width: 8rem;
}
.rampe::after {
  content: "";
  position: absolute;
  inset: 1px 0 auto 0;
  height: 30px;
  background: linear-gradient(to bottom, rgba(200, 161, 112, .26), rgba(200, 161, 112, 0));
  -webkit-mask-image: linear-gradient(to right, #000 45%, transparent 100%);
          mask-image: linear-gradient(to right, #000 45%, transparent 100%);
  pointer-events: none;
}
.rampe--large { max-width: none; }
.rampe--claire { background: rgba(232, 214, 188, .55); }
.rampe--claire::after {
  background: linear-gradient(to bottom, rgba(232, 214, 188, .22), rgba(232, 214, 188, 0));
}

/* ---------- 6. Typographie de composition ---------- */
.surtitre {
  font-family: var(--texte);
  font-size: .75rem;
  font-weight: 400;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--paon);
  margin: 0;
}

.titre-section {
  font-family: var(--titre);
  font-size: clamp(2rem, 4.6vw, 3.1rem);
  font-weight: 560;
  letter-spacing: -.015em;
}

.chapeau {
  font-size: clamp(1.05rem, 1.8vw, 1.2rem);
  color: var(--encre-doux);
  max-width: 46ch;
}

/* ---------- 7. Boutons ---------- */
.bouton {
  display: inline-block;
  font-family: var(--texte);
  font-size: .8rem;
  font-weight: 400;
  letter-spacing: .16em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 1.05rem 2.2rem;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background var(--doux), color var(--doux), border-color var(--doux);
}

.bouton--plein {
  background: var(--paon);
  color: var(--ivoire);
}
.bouton--plein:hover,
.bouton--plein:focus-visible { background: var(--paon-vif); }

.bouton--ligne {
  background: transparent;
  color: var(--encre);
  border-color: var(--encre);
}
.bouton--ligne:hover,
.bouton--ligne:focus-visible {
  background: var(--encre);
  color: var(--ivoire);
}

.bouton--clair {
  background: transparent;
  color: var(--ivoire);
  border-color: rgba(251, 248, 243, .6);
}
.bouton--clair:hover,
.bouton--clair:focus-visible {
  background: var(--ivoire);
  color: var(--encre);
  border-color: var(--ivoire);
}

/* ---------- 8. En-tête ---------- */
.entete {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  transition: background var(--doux), box-shadow var(--doux);
}

.entete__barre {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding-block: 1.15rem;
}

.enseigne {
  white-space: nowrap;
  font-family: var(--enseigne);
  font-size: clamp(1.5rem, 3vw, 1.9rem);
  line-height: 1;
  text-decoration: none;
  color: var(--ivoire);
  padding-top: .2em;
  transition: color var(--doux);
}

.nav { display: flex; align-items: center; gap: clamp(1.1rem, 2.4vw, 2.1rem); }

.nav a {
  white-space: nowrap;
  font-size: .78rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--ivoire);
  padding-block: .35rem;
  border-bottom: 1px solid transparent;
  transition: color var(--doux), border-color var(--doux);
}
.nav a:hover,
.nav a:focus-visible { border-bottom-color: currentColor; }

.nav__rdv {
  border: 1px solid rgba(251, 248, 243, .6);
  padding: .7rem 1.3rem !important;
  border-bottom-width: 1px !important;
}
.nav__rdv:hover,
.nav__rdv:focus-visible {
  background: var(--ivoire);
  color: var(--encre) !important;
  border-color: var(--ivoire) !important;
}

/* État après défilement */
.entete.est-posee {
  background: var(--ivoire);
  box-shadow: 0 1px 0 rgba(25, 26, 28, .08), 0 12px 30px -22px rgba(25, 26, 28, .5);
}
.entete.est-posee .enseigne,
.entete.est-posee .nav a { color: var(--encre); }
.entete.est-posee .nav__rdv { border-color: var(--encre); }
.entete.est-posee .nav__rdv:hover,
.entete.est-posee .nav__rdv:focus-visible {
  background: var(--encre);
  color: var(--ivoire) !important;
}
.entete.est-posee .burger span { background: var(--encre); }

/* Menu mobile */
.burger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  padding: 0;
  background: none;
  border: 0;
  cursor: pointer;
}
.burger span {
  display: block;
  height: 1px;
  width: 24px;
  background: var(--ivoire);
  transition: transform var(--doux), opacity var(--doux), background var(--doux);
}
.burger[aria-expanded="true"] span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.burger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

/* ---------- 9. Bandeau d'ouverture ---------- */
.ouverture {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
}

.ouverture__fond {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 42%;
  transform: scale(1.06);
  animation: respire 22s ease-out forwards;
}

@keyframes respire {
  from { transform: scale(1.13); }
  to   { transform: scale(1.02); }
}

.ouverture__voile {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to top, rgba(15, 16, 18, .88) 0%, rgba(15, 16, 18, .42) 42%, rgba(15, 16, 18, .28) 100%);
}

.ouverture__texte {
  position: relative;
  padding-bottom: clamp(3.5rem, 9vh, 6rem);
  padding-top: 9rem;
  color: var(--ivoire);
  max-width: 40rem;
}

.ouverture__enseigne {
  font-family: var(--enseigne);
  font-size: clamp(3.2rem, 11vw, 6rem);
  line-height: .95;
  margin: 0 0 .35em;
  font-weight: 400;
}

.ouverture__accroche {
  font-family: var(--titre);
  font-size: clamp(1.35rem, 3.2vw, 2rem);
  font-weight: 500;
  line-height: 1.3;
  margin: 0 0 1rem;
}

.ouverture__note {
  color: rgba(251, 248, 243, .82);
  max-width: 34ch;
  margin-bottom: 2.2rem;
}

.ouverture__actions { display: flex; flex-wrap: wrap; gap: .9rem; }

/* ---------- 10. La boutique ---------- */
.boutique {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 6vw, 5rem);
  align-items: center;
}

.boutique__image {
  position: relative;
  aspect-ratio: 3 / 4;
  overflow: hidden;
}
.boutique__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.equipe {
  display: flex;
  gap: 1.5rem;
  margin-top: 2rem;
  padding-top: 1.6rem;
  border-top: 1px solid rgba(200, 161, 112, .45);
}
.equipe__nom {
  font-family: var(--titre);
  font-size: 1.35rem;
  font-weight: 500;
  display: block;
}
.equipe__role {
  font-size: .74rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--paon);
}

/* ---------- 11. Prestations ---------- */
.prestations {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  column-gap: clamp(1.5rem, 3.4vw, 3rem);
  row-gap: 0;
  margin-top: 3rem;
}

.prestation {
  padding: 2rem 0 2.6rem;
  border-top: 1px solid var(--chene);
  position: relative;
}
.prestation::before {
  content: "";
  position: absolute;
  inset: 1px 0 auto 0;
  height: 26px;
  background: linear-gradient(to bottom, rgba(200, 161, 112, .24), rgba(200, 161, 112, 0));
  -webkit-mask-image: linear-gradient(to right, #000 55%, transparent 100%);
          mask-image: linear-gradient(to right, #000 55%, transparent 100%);
  pointer-events: none;
}
.prestation--pleine { grid-column: 1 / -1; }
.prestation--pleine p { max-width: 62ch; }
.prestation--pleine a {
  color: var(--paon);
  text-decoration: none;
  border-bottom: 1px solid currentColor;
  white-space: nowrap;
}

.prestation h3 {
  font-family: var(--titre);
  font-size: 1.3rem;
  font-weight: 500;
  margin-bottom: .5rem;
}
.prestation p {
  font-size: .96rem;
  color: var(--encre-doux);
  margin: 0;
}

/* ---------- 12. Collections ---------- */
.mosaique {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(.6rem, 1.4vw, 1rem);
  margin-top: 3rem;
}
.mosaique figure { margin: 0; overflow: hidden; }
.mosaique img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 900ms cubic-bezier(.22, .61, .36, 1);
}
.mosaique figure:hover img { transform: scale(1.045); }

.mosaique__haute { grid-row: span 2; height: 100%; }
.mosaique__large { grid-column: span 2; aspect-ratio: 16 / 9; }
.mosaique__pleine { grid-column: 1 / -1; aspect-ratio: 24 / 8; }

/* ---------- 13. Service à domicile ---------- */
.domicile {
  background: var(--paon);
  color: var(--ivoire);
}
.domicile .surtitre { color: var(--chene-clair); }
.domicile__grille {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: end;
}
.domicile p { color: rgba(251, 248, 243, .84); max-width: 48ch; margin-bottom: 0; }

/* ---------- 14. Rendez-vous ---------- */
.rdv__grille {
  display: grid;
  grid-template-columns: 0.85fr 1fr;
  gap: clamp(2.5rem, 6vw, 5rem);
  align-items: start;
  margin-top: 3rem;
}

.formulaire { display: grid; gap: 1.4rem; }

.champ { display: grid; gap: .45rem; }

.champ label {
  font-size: .74rem;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--encre-doux);
}

.requis {
  color: var(--paon);
  letter-spacing: 0;
}

.formulaire__legende {
  font-size: .82rem;
  color: var(--encre-doux);
  margin: -.4rem 0 .2rem;
}

.champ input,
.champ select,
.champ textarea {
  font-family: var(--texte);
  font-size: 1.05rem;
  font-weight: 400;
  color: var(--encre);
  background: var(--blanc);
  border: 1px solid rgba(25, 26, 28, .16);
  border-radius: 0;
  padding: .85rem 1rem;
  transition: border-color var(--doux), box-shadow var(--doux);
}
.champ input:focus,
.champ select:focus,
.champ textarea:focus {
  outline: none;
  border-color: var(--paon);
  box-shadow: 0 0 0 3px rgba(42, 128, 124, .14);
}
.champ textarea { resize: vertical; min-height: 6.5rem; }

.champ--duo {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.4rem;
}

.consentement {
  display: flex;
  gap: .75rem;
  align-items: flex-start;
  font-size: .88rem;
  color: var(--encre-doux);
  line-height: 1.5;
}
.consentement input { margin-top: .28rem; accent-color: var(--paon); }
.consentement a { color: var(--paon); }
.champ textarea::placeholder { color: rgba(25, 26, 28, .38); font-size: .93rem; }
/* La cible d'une ancre ne doit pas passer sous l'en-tête fixe */
:target { scroll-margin-top: 7rem; }

.message-formulaire {
  padding: .9rem 1.1rem;
  font-size: .93rem;
  border-left: 3px solid var(--paon);
  background: rgba(42, 128, 124, .08);
}
.message-formulaire[hidden] { display: none; }
.message-formulaire--erreur {
  border-left-color: #A6392F;
  background: rgba(166, 57, 47, .08);
}

.rdv__aparte {
  background: var(--ivoire-creux);
  padding: clamp(1.8rem, 4vw, 2.5rem);
}
.rdv__aparte h3 {
  font-family: var(--titre);
  font-size: 1.4rem;
  font-weight: 500;
  margin-bottom: .6rem;
}
.telephone {
  font-family: var(--titre);
  font-size: clamp(1.5rem, 3.4vw, 1.95rem);
  font-weight: 500;
  text-decoration: none;
  display: inline-block;
  margin-block: .3rem 1.4rem;
  border-bottom: 1px solid var(--chene);
  padding-bottom: .12em;
}
.telephone:hover { border-bottom-color: var(--encre); }

/* ---------- 15. Informations pratiques ---------- */
.infos {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  gap: clamp(2rem, 5vw, 4rem);
  margin-top: 3rem;
}
.infos h3 {
  font-family: var(--texte);
  font-size: .74rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--paon);
  margin-bottom: 1.1rem;
}

.horaires li {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding-block: .55rem;
  border-bottom: 1px solid rgba(25, 26, 28, .09);
  font-size: .98rem;
}
.horaires li:last-child { border-bottom: 0; }
.horaires .ferme { color: var(--encre-doux); }

.adresse { font-style: normal; line-height: 1.9; }
.adresse a { text-decoration: none; border-bottom: 1px solid var(--chene); }

.carte { margin: 3.5rem 0 0; }
.carte iframe {
  display: block;
  width: 100%;
  height: clamp(280px, 42vw, 400px);
  border: 1px solid rgba(25, 26, 28, .14);
  filter: grayscale(.3) contrast(1.04);
}
.carte figcaption {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: .5rem 1.5rem;
  margin-top: .7rem;
  font-size: .78rem;
  color: var(--encre-doux);
}
.carte figcaption a {
  color: var(--paon);
  text-decoration: none;
  border-bottom: 1px solid currentColor;
}

/* ---------- 16. Pied de page ---------- */
.pied {
  background: var(--encre);
  color: rgba(251, 248, 243, .72);
  padding-block: 3.5rem 2.5rem;
  font-size: .9rem;
}
.pied__haut {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 1.5rem;
}
.pied .enseigne { color: var(--ivoire); }
.pied nav { display: flex; flex-wrap: wrap; gap: 1.6rem; }
.pied a { text-decoration: none; border-bottom: 1px solid transparent; }
.pied a:hover, .pied a:focus-visible { border-bottom-color: var(--chene); color: var(--ivoire); }
.pied__bas {
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(251, 248, 243, .14);
  font-size: .82rem;
  color: rgba(251, 248, 243, .5);
}

/* ---------- 17. Apparition au défilement ---------- */
.apparait {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 800ms ease, transform 800ms cubic-bezier(.22, .61, .36, 1);
}
.apparait.est-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  .apparait { opacity: 1; transform: none; }
  .ouverture__fond { animation: none; transform: none; }
}

/* ---------- 18. Page intérieure (mentions légales) ---------- */
.page-interieure { padding-top: clamp(8rem, 16vh, 11rem); }
.prose { max-width: 62ch; }
.prose h2 {
  font-family: var(--titre);
  font-size: 1.45rem;
  font-weight: 500;
  margin-top: 2.6rem;
  margin-bottom: .7rem;
}
.prose h2:first-of-type { margin-top: 1.5rem; }
.prose a { color: var(--paon); }

/* ---------- 19. Adaptations mobiles ---------- */
@media (max-width: 1120px) {
  .burger { display: flex; }

  .nav {
    position: fixed;
    inset: 0 0 auto 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--ivoire);
    padding: 5.5rem var(--gouttiere) 2rem;
    transform: translateY(-100%);
    transition: transform var(--doux);
    box-shadow: 0 20px 40px -30px rgba(25, 26, 28, .8);
  }
  .nav.est-ouverte { transform: translateY(0); }
  .nav a {
    color: var(--encre);
    padding-block: 1.05rem;
    border-bottom: 1px solid rgba(25, 26, 28, .1);
    font-size: .85rem;
  }
  .nav__rdv {
    margin-top: 1.4rem;
    text-align: center;
    border: 1px solid var(--encre) !important;
    color: var(--encre) !important;
  }
  .entete__barre { position: relative; z-index: 2; }
  /* L'enseigne et le bouton restent au-dessus du panneau déroulant,
     sans quoi le menu ouvert masque la croix de fermeture. */
  .entete__barre > .enseigne,
  .burger { position: relative; z-index: 3; }

}

@media (max-width: 900px) {
  .boutique { grid-template-columns: 1fr; }
  .boutique__image { aspect-ratio: 4 / 3; order: -1; }
  .rdv__grille { grid-template-columns: 1fr; }
  .domicile__grille { grid-template-columns: 1fr; align-items: start; }
  .prestations { grid-template-columns: repeat(2, 1fr); }
  .mosaique { grid-template-columns: 1fr 1fr; }
  .mosaique__haute { grid-row: span 1; aspect-ratio: 3 / 4; }
  .mosaique__large { grid-column: span 2; }
  .mosaique__pleine { aspect-ratio: 16 / 9; }
}

@media (max-width: 760px) {
  .champ--duo { grid-template-columns: 1fr; }
  .prestations { grid-template-columns: 1fr; }
  .mosaique { grid-template-columns: 1fr; }
  .mosaique__large,
  .mosaique__pleine { grid-column: span 1; aspect-ratio: 4 / 3; }
  .mosaique__haute { aspect-ratio: 4 / 3; }
  .equipe { flex-direction: column; gap: 1rem; }
}
