/*
  ═══════════════════════════════════════════════════════════════════════════
  Épure — Atelier d'architecture · PREMIUM « éditorial kinétique » (démo fictive)
  ───────────────────────────────────────────────────────────────────────────
  Un site réalisé par Webastide — Création de sites web · webastide.fr
  Antoine Lachaize · © 2026 Webastide
  ───────────────────────────────────────────────────────────────────────────
  Parti pris : béton clair, encre, un seul accent vermillon. Grotesque
  expressif, typographie cinétique, galerie horizontale, curseur et boutons
  magnétiques, grille « blueprint ». Feuille de style autonome.
  ═══════════════════════════════════════════════════════════════════════════
*/

:root {
  --papier:   #EFEDE7;   /* béton clair, fond principal */
  --beton:    #E4E1D9;   /* fond alterné */
  --encre:    #17160F;   /* presque noir */
  --gris:     #5E5C54;   /* texte secondaire (contraste AA) */
  --accent:   #E5401F;   /* vermillon — graphismes & grands textes */
  --accent-txt:#BE2E12;  /* vermillon foncé — petits textes (AA) */
  --accent-fonce:#B02810;/* vermillon profond — aplats sous texte crème (AA) */
  --ligne:    color-mix(in srgb, var(--encre) 12%, transparent);
  --display:  'Bricolage Grotesque', 'Arial Black', sans-serif;
  --sans:     'Inter', -apple-system, Arial, sans-serif;
  --largeur:  1220px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 84px; }
body {
  font-family: var(--sans); font-size: 16px; line-height: 1.6;
  color: var(--encre); background: var(--papier);
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.wrap { width: 100%; max-width: var(--largeur); margin: 0 auto; padding: 0 44px; }

.skip { position: absolute; left: 16px; top: -60px; z-index: 300; background: var(--encre); color: var(--papier); padding: 10px 18px; font-size: .85rem; font-weight: 600; border-radius: 4px; transition: top .25s; }
.skip:focus { top: 16px; }

.eyebrow { display: inline-block; font-size: .72rem; font-weight: 600; letter-spacing: .18em; text-transform: uppercase; color: var(--accent-txt); }
.titre { font-family: var(--display); font-weight: 700; font-size: clamp(2.4rem, 6vw, 4.6rem); line-height: .98; letter-spacing: -.02em; margin: 14px 0 0; }
.titre em { font-style: normal; color: var(--accent); }

/* Curseur sur mesure */
.curseur { position: fixed; top: 0; left: 0; width: 12px; height: 12px; background: var(--accent); border-radius: 50%; transform: translate(-50%, -50%); pointer-events: none; z-index: 9999; opacity: 0; transition: width .3s, height .3s, background-color .3s, opacity .3s; display: flex; align-items: center; justify-content: center; }
.curseur.est-visible { opacity: 1; }
.curseur.sur-lien { width: 42px; height: 42px; background: color-mix(in srgb, var(--accent) 20%, transparent); border: 1.5px solid var(--accent); }
.curseur.sur-rail { width: 84px; height: 84px; background: var(--accent); }
.curseur__txt { font-family: var(--sans); font-size: .7rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--papier); opacity: 0; transition: opacity .2s; }
.curseur.sur-rail .curseur__txt { opacity: 1; }
@media (pointer: coarse) { .curseur { display: none; } }

/* ── Navigation ───────────────────────────────────────────────────── */
.nav { position: fixed; top: 0; left: 0; right: 0; z-index: 100; transition: background .3s, box-shadow .3s; }
.nav.est-defile { background: color-mix(in srgb, var(--papier) 90%, transparent); backdrop-filter: blur(10px); box-shadow: 0 1px 0 var(--ligne); }
.nav__inner { max-width: var(--largeur); margin: 0 auto; padding: 22px 44px; display: flex; align-items: center; justify-content: space-between; }
.nav__logo { font-family: var(--display); font-weight: 700; font-size: 1.35rem; letter-spacing: -.01em; display: flex; align-items: center; gap: 10px; }
.nav__carre { width: 13px; height: 13px; background: var(--accent); display: inline-block; }
.nav__menu { display: flex; align-items: center; gap: 32px; }
.nav__menu a:not(.nav__cta) { font-size: .9rem; font-weight: 500; color: var(--encre); position: relative; }
.nav__menu a:not(.nav__cta)::after { content: ""; position: absolute; left: 0; bottom: -5px; width: 100%; height: 2px; background: var(--accent); transform: scaleX(0); transform-origin: right; transition: transform .3s; }
.nav__menu a:not(.nav__cta):hover::after { transform: scaleX(1); transform-origin: left; }
.nav__cta { font-size: .9rem; font-weight: 600; color: var(--papier); background: var(--encre); padding: 11px 22px; border-radius: 100px; transition: background .25s; }
.nav__cta:hover { background: var(--accent-fonce); }
.nav__burger { display: none; background: none; border: none; cursor: pointer; width: 30px; height: 16px; position: relative; z-index: 120; }
.nav__burger span { position: absolute; left: 0; height: 2.5px; width: 100%; background: var(--encre); transition: .3s; }
.nav__burger span:nth-child(1) { top: 0; } .nav__burger span:nth-child(2) { top: 12px; }
.nav__burger[aria-expanded="true"] span:nth-child(1) { top: 7px; transform: rotate(45deg); }
.nav__burger[aria-expanded="true"] span:nth-child(2) { top: 7px; transform: rotate(-45deg); }

/* ── Hero kinétique ───────────────────────────────────────────────── */
.hero { position: relative; padding: 160px 0 70px; overflow: hidden; }
.hero__grille { position: absolute; inset: 0; z-index: 0; display: grid; grid-template-columns: repeat(4, 1fr); max-width: var(--largeur); margin: 0 auto; pointer-events: none; }
.hero__grille span { border-left: 1px solid var(--ligne); }
.hero__reseau { position: absolute; inset: 0; z-index: 1; pointer-events: none; }
.hero .wrap { position: relative; z-index: 2; }
.hero__titre { font-family: var(--display); font-weight: 800; font-size: clamp(3.6rem, 15vw, 12rem); line-height: .86; letter-spacing: -.03em; margin: 20px 0 0; }
.hero__titre em { font-style: normal; color: var(--accent); }
.ligne { display: block; overflow: hidden; padding-bottom: .04em; }
.ligne > span { display: inline-block; }
.js-anim .hero__titre .ligne > span { transform: translateY(112%); animation: monte 1.1s cubic-bezier(.16,1,.3,1) forwards; }
.js-anim .hero__titre .ligne:nth-child(1) > span { animation-delay: .2s; }
.js-anim .hero__titre .ligne:nth-child(2) > span { animation-delay: .34s; }
@keyframes monte { to { transform: none; } }
.hero__bas { display: flex; align-items: flex-end; justify-content: space-between; gap: 40px; margin-top: 44px; flex-wrap: wrap; }
.hero__txt { max-width: 42ch; color: var(--gris); font-size: 1.1rem; }
.lien-rond { flex: 0 0 auto; width: 116px; height: 116px; border-radius: 50%; background: var(--accent-fonce); color: var(--papier); display: flex; align-items: center; justify-content: center; text-align: center; font-size: .82rem; font-weight: 600; line-height: 1.25; transition: transform .3s; will-change: transform; }
.hero__img { margin-top: 60px; overflow: hidden; position: relative; z-index: 2; }
.hero__img img { width: 100%; aspect-ratio: 16 / 8; object-fit: cover; }

/* ── Marquee ──────────────────────────────────────────────────────── */
.marquee { overflow: hidden; border-top: 1.5px solid var(--encre); border-bottom: 1.5px solid var(--encre); padding: 20px 0; background: var(--papier); }
.marquee__piste { display: flex; width: max-content; animation: defile 32s linear infinite; }
.marquee__piste span { font-family: var(--display); font-weight: 700; font-size: clamp(1.4rem, 3vw, 2.2rem); text-transform: uppercase; letter-spacing: -.01em; padding: 0 .3em; white-space: nowrap; }
.marquee__piste span:nth-child(even) { color: var(--accent); }
@keyframes defile { to { transform: translateX(-50%); } }

/* ── Manifeste ────────────────────────────────────────────────────── */
.manifeste { padding: 14vh 0; }
.manifeste__txt { font-family: var(--display); font-weight: 500; font-size: clamp(1.7rem, 4.4vw, 3.4rem); line-height: 1.22; letter-spacing: -.02em; max-width: 20ch; }
.manifeste__txt em { font-style: normal; color: var(--accent); }

/* ── Projets (galerie horizontale) ────────────────────────────────── */
.projets { padding: 6vh 0 12vh; background: var(--beton); }
.projets__tete { display: flex; align-items: flex-end; justify-content: space-between; margin-bottom: 46px; }
.projets__hint { font-size: .85rem; letter-spacing: .1em; text-transform: uppercase; color: var(--gris); }
.rail { display: flex; gap: 24px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 0 44px 8px; scrollbar-width: none; cursor: grab; }
.rail::-webkit-scrollbar { display: none; }
.rail.est-glisse { cursor: grabbing; }
.carte-p { flex: 0 0 auto; width: min(80vw, 420px); scroll-snap-align: start; }
.carte-p__img { overflow: hidden; }
.carte-p__img img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; transition: transform .8s cubic-bezier(.2,.7,.2,1); }
.carte-p:hover .carte-p__img img { transform: scale(1.05); }
.carte-p__pied { display: flex; align-items: baseline; justify-content: space-between; gap: 14px; padding: 16px 2px 0; border-top: 2px solid var(--encre); margin-top: 14px; }
.carte-p__pied h3 { font-family: var(--display); font-weight: 700; font-size: 1.4rem; letter-spacing: -.01em; }
.carte-p__pied span { font-size: .78rem; letter-spacing: .04em; color: var(--gris); text-align: right; }

/* ── Expertise ────────────────────────────────────────────────────── */
.expertise { padding: 12vh 0; }
.sec__tete { margin-bottom: 54px; }
.exps { list-style: none; border-top: 1px solid var(--ligne); }
.exp { display: grid; grid-template-columns: auto 1fr 1.4fr; gap: 30px; align-items: start; padding: 36px 0; border-bottom: 1px solid var(--ligne); transition: background .3s; }
.exp:hover { background: color-mix(in srgb, var(--accent) 5%, transparent); }
.exp__num { font-family: var(--display); font-weight: 700; font-size: 1rem; color: var(--accent); }
.exp h3 { font-family: var(--display); font-weight: 700; font-size: clamp(1.5rem, 3vw, 2.2rem); letter-spacing: -.02em; }
.exp p { color: var(--gris); max-width: 46ch; }

/* ── L'atelier ────────────────────────────────────────────────────── */
.atelier { padding: 6vh 0 12vh; }
.atelier__grid { display: grid; grid-template-columns: .85fr 1.15fr; gap: clamp(30px, 6vw, 80px); align-items: center; }
.atelier__img { overflow: hidden; }
.atelier__img img { width: 100%; aspect-ratio: 5 / 6; object-fit: cover; }
.atelier__txt p { color: var(--gris); margin: 18px 0 0; max-width: 48ch; }
.chiffres { list-style: none; display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 36px; }
.chiffres li { border-top: 2px solid var(--encre); padding-top: 14px; }
.chiffres__k { display: block; font-family: var(--display); font-weight: 700; font-size: clamp(2rem, 4.5vw, 3rem); line-height: 1; letter-spacing: -.02em; }
.chiffres__k small { font-size: 1rem; color: var(--accent); }
.chiffres__l { display: block; margin-top: 8px; font-size: .74rem; letter-spacing: .1em; text-transform: uppercase; color: var(--gris); }

/* ── Contact ──────────────────────────────────────────────────────── */
.contact { padding: 12vh 0 6vh; background: var(--encre); color: var(--papier); }
.contact .eyebrow { color: var(--accent); }
.contact__titre { font-family: var(--display); font-weight: 800; font-size: clamp(2.6rem, 8vw, 6rem); line-height: .96; letter-spacing: -.03em; margin: 16px 0 40px; }
.contact__titre em { font-style: normal; color: var(--accent); }
.contact__mail { display: inline-block; font-family: var(--display); font-weight: 500; font-size: clamp(1.3rem, 3.4vw, 2.4rem); letter-spacing: -.01em; border-bottom: 2px solid color-mix(in srgb, var(--papier) 40%, transparent); padding-bottom: 4px; transition: border-color .3s, color .3s; will-change: transform; }
.contact__mail:hover { color: var(--accent); border-color: var(--accent); }
.contact__infos { display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px; margin-top: 70px; padding-top: 34px; border-top: 1px solid color-mix(in srgb, var(--papier) 18%, transparent); }
.contact__infos h3 { font-family: var(--display); font-weight: 700; font-size: 1rem; color: var(--accent); margin-bottom: 8px; }
.contact__infos address, .contact__infos p { font-style: normal; color: color-mix(in srgb, var(--papier) 78%, transparent); font-size: .95rem; line-height: 1.7; }
.contact__infos a { border-bottom: 1px solid color-mix(in srgb, var(--papier) 35%, transparent); }

/* ── Pied ─────────────────────────────────────────────────────────── */
.pied { background: var(--encre); color: color-mix(in srgb, var(--papier) 65%, transparent); padding: 40px 0; text-align: center; border-top: 1px solid color-mix(in srgb, var(--papier) 14%, transparent); }
.pied__logo { font-family: var(--display); font-weight: 700; font-size: 1.3rem; color: var(--papier); display: inline-flex; align-items: center; gap: 9px; }
.pied small { display: block; margin-top: 14px; font-size: .8rem; }
.pied__credit { margin-top: 12px; font-size: .82rem; }
.pied__credit a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.pied__credit strong { color: var(--papier); font-weight: 600; }

/* ── Révélations ──────────────────────────────────────────────────── */
.reveal { opacity: 1; }
.js-anim .reveal { opacity: 0; transform: translateY(26px); transition: opacity .8s ease, transform .8s cubic-bezier(.16,1,.3,1); }
.js-anim .reveal.est-visible { opacity: 1; transform: none; }
.js-anim .reveal-img img { clip-path: inset(0 0 101% 0); transition: clip-path 1.2s cubic-bezier(.16,1,.3,1); }
.js-anim .reveal-img.est-visible img { clip-path: inset(0 0 0 0); }

/* ── Responsive ───────────────────────────────────────────────────── */
@media (max-width: 900px) {
  .nav__burger { display: block; }
  .nav__menu { position: fixed; inset: 0; background: var(--papier); flex-direction: column; justify-content: center; gap: 30px; transform: translateX(100%); transition: transform .4s; }
  .nav__menu.est-ouvert { transform: none; }
  .nav__menu a:not(.nav__cta) { font-size: 1.6rem; font-family: var(--display); font-weight: 700; }
  .exp { grid-template-columns: auto 1fr; }
  .exp p { grid-column: 2; }
  .atelier__grid { grid-template-columns: 1fr; }
  .atelier__img { order: -1; max-height: 60vh; }
  .contact__infos { grid-template-columns: 1fr; gap: 22px; }
}
@media (max-width: 560px) {
  .wrap, .nav__inner { padding-left: 24px; padding-right: 24px; }
  .rail { padding-left: 24px; padding-right: 24px; }
  .hero__bas { flex-direction: column; align-items: flex-start; }
  .chiffres { grid-template-columns: 1fr; }
}

/* ── Réduire les animations ───────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
  .marquee__piste { animation: none; }
  .js-anim .reveal { opacity: 1; transform: none; }
  .js-anim .reveal-img img { clip-path: none; }
  .js-anim .hero__titre .ligne > span { transform: none; animation: none; }
  .curseur { display: none; }
}


/* ── Bandeau de démonstration ─────────────────────────────────────────── */
/* La barre de navigation est en position fixe : posé dans le flux, le bandeau
   passerait dessous. Il est donc fixe lui aussi, au-dessus d'elle, et c'est
   la barre qui descend de sa hauteur. */
:root { --bandeau-h: 36px; }
@media (max-width: 620px) { :root { --bandeau-h: 54px; } }

.demo-bandeau {
  position: fixed; top: 0; left: 0; right: 0; z-index: 300; margin: 0;
  background: var(--encre); color: var(--papier);
  text-align: center; font-size: .8rem; letter-spacing: .04em; padding: 7px 16px;
}
.demo-bandeau a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.nav { top: var(--bandeau-h); }
