/* =========================================================
   Design Studio ALW — feuille de style
   ========================================================= */

@font-face {
  font-family: "Jost";
  src: url("../fonts/jost-latin-wght-normal.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Jost";
  src: url("../fonts/jost-latin-wght-italic.woff2") format("woff2");
  font-weight: 100 900;
  font-style: italic;
  font-display: swap;
}

:root {
  --paper: #ffffff;
  --ink: #000000;
  --stone: #929292;        /* le gris du site actuel */
  --stone-deep: #858585;
  --gold: #b69667;         /* le W du logo */
  --gold-deep: #6e5530;    /* or lisible sur fond gris */
  --cream: #faf6ef;

  --font: "Jost", "Futura", "Century Gothic", "Avenir Next", system-ui, sans-serif;
  --header-h: 168px;
  --wrap: 1180px;
  --ease: cubic-bezier(.65, .05, .2, 1);
}

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

html { scroll-behavior: smooth; scroll-padding-top: 96px; }

body {
  margin: 0;
  font-family: var(--font);
  font-weight: 350;
  font-size: 1.125rem;
  line-height: 1.6;
  color: var(--ink);
  background: var(--stone);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img, video { max-width: 100%; display: block; }
a { color: inherit; }
p { margin: 0 0 1.1em; }
h1, h2, h3 { margin: 0; font-weight: 350; line-height: 1.15; }

:focus-visible { outline: 2px solid var(--gold); outline-offset: 4px; border-radius: 4px; }

.skip {
  position: absolute; left: 1rem; top: -4rem; z-index: 100;
  background: var(--ink); color: var(--paper); padding: .6rem 1rem; border-radius: 99px;
}
.skip:focus { top: 1rem; }

.wrap { width: min(100% - 3rem, var(--wrap)); margin-inline: auto; }

/* ---------- En-tête ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: var(--paper);
  transition: box-shadow .4s var(--ease);
}
.site-header.is-scrolled { box-shadow: 0 1px 0 rgba(0,0,0,.08); }

.nav {
  display: grid;
  grid-template-columns: 1fr 1fr auto 1fr 1fr;
  align-items: center;
  justify-items: center;
  width: min(100% - 2rem, 1440px);
  margin-inline: auto;
  padding: 1rem 0;
  transition: padding .4s var(--ease);
}

.brand img {
  width: 140px; height: 140px;
  transition: width .4s var(--ease), height .4s var(--ease);
}
.is-scrolled .nav { padding: .4rem 0; }
.is-scrolled .brand img { width: 72px; height: 72px; }

.nav-link {
  position: relative;
  font-size: clamp(1.1rem, 1.9vw, 1.75rem);
  font-weight: 300;
  text-decoration: none;
  padding: .45em 1em;
  border-radius: 999px;
  border: 1px solid transparent;
  transition: color .3s, border-color .3s;
}
.nav-link:hover { color: var(--gold); }
.nav-link.is-active { color: var(--gold); border-color: var(--gold); }

/* ---------- Accueil ---------- */
.hero {
  position: relative;
  min-height: calc(100svh - var(--header-h));
  display: grid;
  place-items: center;
  overflow: hidden;
  background: #2b2826;
  color: var(--cream);
  text-align: center;
}
.hero-video {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  opacity: .75;
}
.hero-veil {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(20,18,17,.15) 0%, rgba(20,18,17,.55) 100%);
}
.hero-text {
  position: relative;
  width: min(100% - 3rem, 64rem);
  padding: 4rem 0;
}
.hero-title {
  font-size: clamp(2.6rem, 7.5vw, 6rem);
  font-weight: 300;
  letter-spacing: .02em;
  line-height: 1;
}
.hero-title .line { display: block; overflow: hidden; padding-bottom: .08em; }
.hero-title .line > span { display: inline-block; }
.hero-sub {
  margin: 1.2rem 0 1.6rem;
  font-size: clamp(1.1rem, 2vw, 1.4rem);
  color: var(--gold);
  font-weight: 400;
}
.hero-lead { max-width: 34rem; margin: 0 auto 2.2rem; font-weight: 300; }

/* séquence d'ouverture (unique moment animé non déclenché) */
.js .hero-title .line > span { transform: translateY(105%); }
.js .hero-sub, .js .hero-lead, .js .hero .btn { opacity: 0; transform: translateY(12px); }
.js.is-loaded .hero-title .line > span { transform: none; transition: transform 1.2s var(--ease) .15s; }
.js.is-loaded .hero-sub  { opacity: 1; transform: none; transition: all .9s var(--ease) .8s; }
.js.is-loaded .hero-lead { opacity: 1; transform: none; transition: all .9s var(--ease) 1s; }
.js.is-loaded .hero .btn { opacity: 1; transform: none; transition: all .9s var(--ease) 1.2s; }

/* ---------- Boutons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: .6em;
  font: inherit; font-size: 1.1rem; font-weight: 400;
  text-decoration: none;
  padding: .55em 1.4em;
  border: 1px solid currentColor;
  border-radius: 999px;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  transition: background .3s, color .3s, border-color .3s;
}
.btn:hover { background: var(--ink); color: var(--paper); }
.btn-light { color: var(--cream); }
.btn-light:hover { background: var(--cream); color: var(--ink); border-color: var(--cream); }

/* ---------- Sections ---------- */
.section { padding: clamp(4rem, 9vw, 7.5rem) 0; }
.section-stone { background: var(--stone); }
.section-rule .wrap { border-top: 1px solid var(--gold); padding-top: clamp(3rem, 7vw, 5.5rem); }
.section-rule { padding-top: 0; }

.section-title {
  font-size: clamp(2.2rem, 4.5vw, 3.4rem);
  font-weight: 300;
  color: var(--paper);
  margin-bottom: 1.5rem;
}

/* ---------- Projets ---------- */
#projets .section-title { text-align: center; }
.mission {
  max-width: 52rem;
  margin: 0 auto clamp(3rem, 8vw, 6rem);
  text-align: center;
  font-size: clamp(1.2rem, 2.2vw, 1.6rem);
  font-weight: 300;
  line-height: 1.5;
}

.project {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 4fr);
  gap: clamp(2rem, 6vw, 6rem);
  align-items: center;
  margin-bottom: clamp(4rem, 9vw, 7rem);
}
.project:last-child { margin-bottom: 0; }
.project-flip .project-media { order: 2; }

.project-media {
  position: relative;
  padding: 0; border: 0; background: none;
  cursor: zoom-in;
  overflow: hidden;
  aspect-ratio: 4 / 5;
  width: 100%;
}
.project-media img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform 1.2s var(--ease);
}
.project-media:hover img { transform: scale(1.03); }

.project-text h3 {
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  font-weight: 300;
  color: var(--paper);
  padding-bottom: .6rem;
  margin-bottom: 1.2rem;
  border-bottom: 1px solid var(--gold);
  display: inline-block;
}
.project-text p { font-size: clamp(1.15rem, 1.8vw, 1.4rem); font-weight: 300; max-width: 26rem; }

/* Effet « store qui se lève » : lamelles qui remontent pour dévoiler la photo */
.js .blind::after {
  content: "";
  position: absolute; inset: 0;
  background:
    repeating-linear-gradient(180deg, rgba(0,0,0,0) 0 calc(16.66% - 1px), rgba(0,0,0,.18) calc(16.66% - 1px) 16.66%),
    linear-gradient(180deg, #c9b99c, #b5a17d);
  transform-origin: top;
  transition: transform 1.4s var(--ease);
  pointer-events: none;
}
.js .blind.is-visible::after { transform: scaleY(0); }

/* ---------- Services ---------- */
.services {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(2rem, 6vw, 6rem);
}
.services-intro { position: sticky; top: 130px; align-self: start; }
.services-kicker { font-size: clamp(1.6rem, 3vw, 2.2rem); color: var(--gold-deep); font-style: italic; font-weight: 300; margin-top: -.6rem; }
.services-lead { font-size: clamp(1.25rem, 2vw, 1.55rem); font-weight: 300; line-height: 1.5; max-width: 30rem; }

.service { padding: 0 0 2.2rem; margin-bottom: 2.2rem; border-bottom: 1px solid var(--gold); }
.service:last-child { margin-bottom: 0; border-bottom: 0; }
.service h3 {
  font-size: clamp(1.4rem, 2.2vw, 1.75rem);
  font-weight: 400;
  color: var(--paper);
  margin-bottom: .8rem;
}
.service p { margin: 0; max-width: 36rem; }

/* ---------- À propos ---------- */
.about {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(2rem, 6vw, 5rem);
  align-items: start;
}
.about-media { position: sticky; top: 130px; }
.about-media video { width: 100%; height: auto; aspect-ratio: 16 / 9; background: #1e1c1b; }
.caption { margin-top: .8rem; font-size: .95rem; color: var(--paper); }
.about-text p { max-width: 36rem; }

/* ---------- Contact ---------- */
.contact { text-align: center; }
.contact-card {
  font-style: normal;
  display: flex; flex-direction: column; align-items: center;
  gap: .15rem;
  font-size: clamp(1.3rem, 2.4vw, 1.8rem);
  font-weight: 300;
  margin-bottom: 2.5rem;
}
.contact-name { font-weight: 400; font-size: 1.15em; margin-bottom: .2rem; }
.contact-card a { text-decoration: none; }
.contact-mail { color: var(--paper); border-bottom: 1px solid var(--gold); }
.contact-mail:hover, .contact-tel:hover { color: var(--gold-deep); }

/* ---------- Pied de page ---------- */
.site-footer {
  display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap;
  width: min(100% - 3rem, var(--wrap));
  margin-inline: auto;
  padding: 3rem 0 2.5rem;
  border-top: 1px solid var(--gold);
  font-size: 1.15rem;
}
.footer-link {
  font: inherit; font-weight: 300; color: inherit;
  background: none; border: 0; padding: 0; cursor: pointer;
  text-decoration: none;
}
.footer-link:hover { color: var(--paper); }
.footer-copy { margin: 0; font-size: .95rem; color: #3a3a3a; }

/* ---------- Boîtes de dialogue ---------- */
dialog {
  border: 0; padding: 0;
  max-width: min(92vw, 900px);
  background: transparent;
}
dialog::backdrop { background: rgba(20,18,17,.85); }
dialog[open] { animation: open .45s var(--ease); }
@keyframes open { from { opacity: 0; transform: translateY(10px); } }

.lightbox img { max-height: 88vh; width: auto; margin: auto; }
.dialog-close {
  position: fixed; top: 1rem; right: 1.2rem;
  width: 48px; height: 48px;
  font: 300 2.2rem/1 var(--font);
  color: var(--cream); background: none; border: 1px solid var(--cream); border-radius: 50%;
  cursor: pointer;
}
.dialog-close:hover { background: var(--cream); color: var(--ink); }

.legal {
  background: var(--paper);
  padding: 2.5rem clamp(1.5rem, 4vw, 3rem);
  max-width: 44rem;
  font-size: 1rem;
}
.legal h2 { font-size: 2rem; font-weight: 300; margin-bottom: 1.5rem; }
.legal h3 { font-size: 1.1rem; font-weight: 500; color: var(--gold-deep); margin: 1.4rem 0 .3rem; }

/* ---------- Mobile ---------- */
@media (max-width: 860px) {
  :root { --header-h: 150px; }
  html { scroll-padding-top: 110px; }
  .nav {
    grid-template-columns: repeat(4, auto);
    justify-content: space-between;
    row-gap: .2rem;
  }
  .brand { grid-column: 1 / -1; grid-row: 1; }
  .brand img { width: 84px; height: 84px; }
  .nav-link { font-size: 1.05rem; padding: .35em .75em; }
  .is-scrolled .brand img { width: 48px; height: 48px; }

  .project, .services, .about { grid-template-columns: 1fr; }
  .project-flip .project-media { order: 0; }
  .services-intro, .about-media { position: static; }
  .site-footer { justify-content: center; text-align: center; }
}

@media (max-width: 400px) {
  .nav-link { font-size: .95rem; padding: .3em .5em; }
}

/* ---------- Mouvement réduit ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
  .js .hero-title .line > span, .js .hero-sub, .js .hero-lead, .js .hero .btn { opacity: 1; transform: none; }
  .js .blind::after { display: none; }
  .hero-video { display: none; }
  .hero { background: #2b2826 url("../img/hero-poster.jpg") center / cover; }
}
