/* ── Fonts ───────────────────────────────────── */
@font-face {
  font-family: 'Everett';
  src: url('../fonts/TWKEverett-Light.woff2') format('woff2');
  font-weight: 300;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Everett';
  src: url('../fonts/TWKEverett-LightItalic.woff2') format('woff2');
  font-weight: 300;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: 'Everett';
  src: url('../fonts/TWKEverett-Regular.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Everett';
  src: url('../fonts/TWKEverett-Medium.woff2') format('woff2');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Everett';
  src: url('../fonts/TWKEverett-MediumItalic.woff2') format('woff2');
  font-weight: 500;
  font-style: italic;
  font-display: swap;
}

/* ── Design tokens ───────────────────────────── */
:root {
  --site-margin: clamp(6cm, 11vw, 10cm);
}

/* ── Reset ───────────────────────────────────── */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  hyphens: none !important;
  -webkit-hyphens: none !important;
  -ms-hyphens: none !important;
}
html { scroll-behavior: smooth; }
body {
  font-family: 'Everett', -apple-system, system-ui, sans-serif;
  background: #fff;
  color: #1a1a1a;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  position: relative;
  z-index: 1;
  -webkit-overflow-scrolling: touch;
}
a { color: inherit; text-decoration: none; }

/* ─────────────────────────────────────────────
   Anti-CLS défensive : permet aux attributs HTML
   width/height (nécessaires pour Core Web Vitals)
   de coexister avec le responsive CSS.
   Le navigateur utilise width/height pour le ratio
   intrinsèque, le CSS pilote la mise en page réelle.
   ───────────────────────────────────────────── */
img {
  max-width: 100%;
  height: auto;
}

/* ── iOS 26 edge-to-edge hint ────────────────── */
#ios26-hint {
  position: fixed;
  top: -1px; left: 0; right: 0;
  height: 1px;
  background: #1a1a1a;
  z-index: 0;
  pointer-events: none;
}
#ios26-hint-bottom {
  position: fixed;
  bottom: -1px; left: 0; right: 0;
  height: 1px;
  background: #1a1a1a;
  z-index: 0;
  pointer-events: none;
}

/* ── HEADER ──────────────────────────────────── */
#header {
  position: fixed;
  top: 1px; left: 0; right: 0;
  height: calc(56px + env(safe-area-inset-top));
  background: transparent;
  border-bottom: 1px solid transparent;
  z-index: 350;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  padding-top: max(0px, env(safe-area-inset-top));
  pointer-events: none;
  transition: background 0.3s ease, border-color 0.3s ease;
}
@media (min-width: 768px) { #header { padding: 0 48px; padding-top: max(0px, env(safe-area-inset-top)); } }

#header.scrolled {
  background: rgba(255, 255, 255, 0.92);
  -webkit-backdrop-filter: blur(12px);
          backdrop-filter: blur(12px);
  border-bottom-color: rgba(26, 26, 26, 0.1);
  pointer-events: auto;
}

#header-logo {
  font-size: 14px;
  font-weight: 600;
  color: #1a1a1a;
  letter-spacing: -0.1px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}
#header.scrolled #header-logo {
  opacity: 1;
  pointer-events: auto;
}
#header:has(#hamburger.is-active) #header-logo {
  opacity: 0 !important;
  pointer-events: none;
}
#header:has(#hamburger.is-active) {
  background: transparent !important;
  -webkit-backdrop-filter: none !important;
          backdrop-filter: none !important;
  border-bottom-color: transparent !important;
}

#header-nav {
  display: none;
  gap: 24px;
}
#header-nav a {
  font-size: 12px;
  font-weight: 300;
  color: #1a1a1a;
  cursor: pointer;
  background-image: linear-gradient(#1a1a1a, #1a1a1a);
  background-size: 0% 1px;
  background-repeat: no-repeat;
  background-position: left bottom;
  transition: background-size 0.3s ease;
}
#header-nav a:hover { background-size: 100% 1px; }
@media (min-width: 768px) { #header-nav { display: flex; } }

#hamburger {
  width: 44px; height: 44px;
  background: none; border: none;
  cursor: pointer;
  position: relative;
  padding: 0;
  z-index: 350;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}
#header.scrolled #hamburger {
  opacity: 1;
  pointer-events: auto;
}
.hamburger-line {
  position: absolute;
  width: 22px;
  height: 1.5px;
  background: #1a1a1a;
  left: calc(50% - 11px);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1),
              opacity 0.3s ease,
              top 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.hamburger-line:nth-child(1) { top: calc(50% - 4px); }
.hamburger-line:nth-child(2) { top: calc(50% + 3px); }
#hamburger.is-active .hamburger-line:nth-child(1) {
  top: 50%;
  transform: rotate(45deg);
}
#hamburger.is-active .hamburger-line:nth-child(2) {
  top: 50%;
  transform: rotate(-45deg);
}
@media (min-width: 768px) { #hamburger { display: none; } }

/* ── MENU OVERLAY ────────────────────────────── */
#menu-overlay {
  position: fixed;
  inset: 0;
  z-index: 300;
  background: rgba(255, 255, 255, 0.85);
  -webkit-backdrop-filter: blur(16px);
          backdrop-filter: blur(16px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}
#menu-overlay.is-open {
  opacity: 1;
  pointer-events: auto;
}
.menu-header {
  position: relative;
  height: calc(56px + env(safe-area-inset-top));
  padding: env(safe-area-inset-top) 24px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
}
@media (min-width: 768px) {
  .menu-header { padding-left: 48px; padding-right: 48px; }
}
.menu-logo {
  font-size: 14px;
  font-weight: 600;
  color: #1a1a1a;
  letter-spacing: -0.1px;
  text-decoration: none;
}
.menu-list {
  list-style: none;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 0 28px;
  margin: 0;
}
@media (min-width: 768px) {
  .menu-list { padding: 0 32px; }
}
@media (min-width: 1280px) {
  .menu-list { padding: 0 var(--site-margin); }
}
.menu-item {
  display: block;
  padding: 24px 0;
  border-bottom: 1px solid rgba(26, 26, 26, 0.12);
  text-decoration: none;
  color: #1a1a1a;
  transition: opacity 0.3s ease;
}
.menu-list li:last-child .menu-item { border-bottom: none; }
.menu-item:hover { opacity: 0.5; }
.menu-item[aria-current="page"] { opacity: 0.4; }
.menu-label {
  font-size: clamp(28px, 4.5vw, 40px);
  font-weight: 300;
  letter-spacing: -0.4px;
  line-height: 1.15;
}
.menu-footer {
  padding: 32px 28px;
  display: flex;
  gap: 16px;
  align-items: center;
  font-size: 12px;
  font-weight: 400;
  color: #5F5E5A;
  flex-shrink: 0;
}
@media (min-width: 768px) {
  .menu-footer { padding: 32px 32px; }
}
@media (min-width: 1280px) {
  .menu-footer { padding: 32px var(--site-margin); }
}
.menu-footer a {
  color: #5F5E5A;
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s ease;
}
.menu-footer a:hover { border-bottom-color: #5F5E5A; }
.menu-footer-sep { color: #8a8a87; }
@media (max-width: 400px) {
  .menu-footer {
    flex-direction: column;
    gap: 8px;
    align-items: flex-start;
  }
  .menu-footer-sep { display: none; }
}

/* ── PAGE TRANSITION ─────────────────────────── */
#page-transition {
  position: fixed; inset: 0;
  background: #fff;
  z-index: 9990;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

/* ── FOOTER ──────────────────────────────────── */
#footer {
  background: #1a1a1a;
  color: #fff;
  padding: 120px 24px 60px;
}
@media (min-width: 768px) {
  #footer { padding: 120px 32px 60px; }
}
@media (min-width: 1280px) {
  #footer { padding: 120px var(--site-margin) 60px; }
}
/* Mobile : fond immersif + safe area iOS */
@media (max-width: 767px) {
  #footer { padding-bottom: calc(100px + env(safe-area-inset-bottom, 0px)); }
}
.footer-divider {
  border: 0;
  height: 1px;
  background: rgba(255,255,255,0.12);
  margin: 0;
}
.footer-identity {
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
  padding-bottom: 96px;
  align-items: start;
}
@media (min-width: 768px) {
  .footer-identity {
    grid-template-columns: 1fr 1fr;
    gap: clamp(40px, 5vw, 80px);
    padding-bottom: 120px;
  }
  .footer-identity-right { align-items: flex-end; }
  .footer-cta-email,
  .footer-cta-phone { text-align: right; }
}
.footer-brand {
  font-size: clamp(22px, 2.5vw, 32px);
  font-weight: 500;
  letter-spacing: -0.4px;
  line-height: 1.05;
  color: #fff;
  text-transform: uppercase;
  margin-bottom: 16px;
}
.footer-intro,
h1.footer-intro {
  font-size: clamp(13px, 1vw, 14px);
  font-weight: 400;
  color: rgba(255,255,255,0.45);
  line-height: 1.65;
  margin: 0;
  letter-spacing: normal;
}
.footer-identity-right {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.footer-cta-email,
.footer-cta-phone {
  display: block;
  font-size: clamp(20px, 1.8vw, 24px);
  font-weight: 400;
  color: #fff;
  text-decoration: none;
  line-height: 1.35;
  letter-spacing: -0.2px;
  transition: opacity 0.25s ease;
}
.footer-cta-email:hover,
.footer-cta-phone:hover { opacity: 0.55; }
.footer-columns {
  display: flex;
  justify-content: space-between;
  align-items: start;
  padding: 84px 0;
}
.footer-col-separator { display: none; }
@media (max-width: 767px) {
  .footer-columns {
    display: grid;
    grid-template-columns: 1fr 1fr;
    column-gap: 24px;
    row-gap: 0;
    padding: 60px 0;
  }
  .footer-address { grid-column: 1; grid-row: 1; padding-bottom: 32px; }
  .footer-social-list { grid-column: 2; grid-row: 1; padding-bottom: 32px; }
  .footer-col-separator {
    display: block;
    grid-column: 1 / -1;
    grid-row: 2;
    height: 1px;
    background: rgba(255,255,255,0.12);
    border: 0;
    margin-bottom: 32px;
  }
  .footer-nav--a { grid-column: 1; grid-row: 3; }
  .footer-nav--b { grid-column: 2; grid-row: 3; }
}
.footer-address {
  font-style: normal;
  font-size: 12px;
  font-weight: 400;
  color: #fff;
  line-height: 1.9;
}
.footer-nav {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.footer-nav a {
  font-size: 12px;
  font-weight: 400;
  color: #fff;
  text-decoration: none;
  line-height: 1.5;
  transition: opacity 0.25s ease;
}
.footer-nav a:hover { opacity: 0.5; }
.footer-nav--b { align-items: flex-end; }
.footer-nav--b a { text-align: right; }
.footer-social-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
}
.footer-social-list a {
  display: inline-flex;
  align-items: center;
  width: 16px;
  height: 16px;
  color: #fff;
  text-decoration: none;
  transition: opacity 0.2s ease;
}
.footer-social-list a:hover { opacity: 0.5; }
.footer-social-icon { width: 16px; height: 16px; fill: currentColor; }
@media (max-width: 767px) {
  .footer-social-list {
    flex-direction: row;
    align-items: center;
    justify-content: flex-end;
    gap: 18px;
  }
  .footer-social-list a { width: 20px; height: 20px; }
  .footer-social-icon { width: 18px; height: 18px; }
}
/* ── Mobile étroit < 480px : BLOC 2 en empilement vertical ── */
@media (max-width: 479px) {
  /* Adresse : pleine largeur, row 1 */
  .footer-address {
    grid-column: 1 / -1;
    grid-row: 1;
    padding-bottom: 20px;
  }
  /* Séparateur existant : row 2, pas de margin-bottom */
  .footer-col-separator { grid-row: 2; margin-bottom: 0; }
  /* Icônes sociales : pleine largeur, row 3, flex-start, séparateur bas */
  .footer-social-list {
    grid-column: 1 / -1;
    grid-row: 3;
    justify-content: flex-start;
    padding-top: 28px;
    padding-bottom: 20px;
  }
  /* Navigation : grille 2 colonnes, row 4 */
  .footer-nav--a { grid-column: 1; grid-row: 4; padding-top: 20px; }
  .footer-nav--b { grid-column: 2; grid-row: 4; padding-top: 20px; }
}

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 36px;
  font-size: 11px;
  font-weight: 400;
  color: rgba(255,255,255,0.4);
  line-height: 1.6;
}
.footer-bottom a {
  color: rgba(255,255,255,0.4);
  text-decoration: none;
  transition: color 0.25s ease;
}
.footer-bottom a:hover { color: rgba(255,255,255,0.75); }
.fb-left-group  { display: contents; }
.fb-right-group { display: contents; }
@media (max-width: 767px) {
  .footer-bottom {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px 16px;
    align-items: start;
  }
  .fb-copy      { grid-column: 1; grid-row: 1; }
  .fb-ordre     { grid-column: 2; grid-row: 1; text-align: right; }
  .fb-siret     { grid-column: 1; grid-row: 2; }
  .fb-politique { grid-column: 2; grid-row: 2; text-align: right; }
}

/* ── PROJET — structure principale ──────────── */
.projet {
  padding-top: calc(56px + env(safe-area-inset-top));
}

/* ── En-tête du projet ───────────────────────── */
.projet-header {
  padding: 40px 24px 32px;
}
@media (min-width: 768px) {
  .projet-header {
    padding: 56px 32px 40px;
  }
}
@media (min-width: 1280px) {
  .projet-header {
    padding: 56px var(--site-margin) 40px;
  }
}
.projet-eyebrow {
  display: block;
  font-size: 10px;
  letter-spacing: 3px;
  text-transform: uppercase;
  font-weight: 400;
  color: #8a8a87;
  margin-bottom: 12px;
}
.projet-title {
  font-size: clamp(28px, 5vw, 44px);
  font-weight: 300;
  letter-spacing: -0.5px;
  line-height: 1.12;
  color: #1a1a1a;
  margin-bottom: 10px;
}
.projet-coords {
  font-size: 12px;
  font-weight: 400;
  color: #8a8a87;
  letter-spacing: 0.2px;
}

/* ── PROJET / Cartel métadonnées ────────────── */
.projet-cartel {
  border-top: 1px solid rgba(26,26,26,0.18);
  border-bottom: 1px solid rgba(26,26,26,0.18);
  padding: 20px 24px;
  margin: 0 0 56px;
}
@media (min-width: 768px) {
  .projet-cartel {
    padding: 24px 32px;
    margin-bottom: 80px;
  }
}
@media (min-width: 1280px) {
  .projet-cartel {
    padding: 24px var(--site-margin);
  }
}
.projet-cartel dl {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}
@media (min-width: 768px) {
  .projet-cartel dl {
    grid-template-columns: repeat(6, 1fr);
    gap: 24px;
  }
}
.projet-cartel-cell { display: block; }
.projet-cartel dt {
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: #8a8a87;
  margin-bottom: 6px;
}
.projet-cartel dd {
  font-size: 12px;
  font-weight: 300;
  line-height: 1.45;
  color: #1a1a1a;
}

/* ── PROJET / Body : grille images + texte ──── */
.projet-body {
  padding: 0 24px;
  display: flex;
  flex-direction: column;
  gap: 32px;
}
@media (min-width: 768px) {
  .projet-body {
    padding: 0 32px;
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 64px;
    align-items: start;
  }
  .projet-images {
    position: relative;
    z-index: 10;
  }
}
@media (min-width: 1280px) {
  .projet-body {
    padding: 0 var(--site-margin);
  }
}

/* ── PROJET / Images empilées ───────────────── */
.projet-images {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.projet-images figure { margin: 0; }
.projet-images img {
  width: 100%;
  display: block;
  position: relative;
  z-index: 1;
  transform-origin: left center;
  transition: transform 0.5s cubic-bezier(0.2, 0.7, 0.2, 1), box-shadow 0.5s ease;
}
@media (min-width: 768px) and (hover: hover) and (pointer: fine) {
  .projet-images figure:hover img,
  .projet-images img:hover {
    transform: scale(2);
    z-index: 100;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
  }
}

/* ── PROJET / Texte descriptif ──────────────── */
.projet-text p {
  font-size: clamp(14px, 1.1vw, 15px);
  font-weight: 300;
  line-height: 1.8;
  color: #1a1a1a;
  text-align: justify;
  margin-bottom: 1.4em;
}
.projet-text p:last-child { margin-bottom: 0; }

/* ── PROJET / Crédits colophon ──────────────── */
.projet-credits {
  padding: 60px 24px 0;
  margin-bottom: 12px;
  font-size: 12px;
  font-weight: 400;
  letter-spacing: 0.2px;
  text-transform: lowercase;
  color: #8a8a87;
}
@media (min-width: 768px) {
  .projet-credits {
    padding: 80px 32px 0;
  }
}
@media (min-width: 1280px) {
  .projet-credits {
    padding: 80px var(--site-margin) 0;
  }
}

/* ── PROJET / Mobile : réordonnancement via order ── */
@media (max-width: 767px) {
  .projet { display: flex; flex-direction: column; }
  .projet-body { display: contents; }
  .projet-images { display: contents; }

  .projet-images figure:nth-child(1) {
    order: -3;
    margin: 0 0 32px;
  }
  .projet-header { order: -2; padding: 0 24px; margin-bottom: 24px; }
  .projet-text { order: -1; padding: 0 24px; margin-bottom: 32px; }
  .projet-cartel { order: 0; margin: 0 0 32px; }
  .projet-images figure:nth-child(n+2) {
    order: 1;
    padding: 0 24px;
    margin-bottom: 16px;
  }
  .projet-credits { order: 2; }
  .projet-nav { order: 3; }
}

/* ── Navigation prev / next ──────────────────── */
.projet-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 32px 24px calc(32px + env(safe-area-inset-bottom));
  border-top: 1px solid rgba(26, 26, 26, 0.15);
  gap: 16px;
}
@media (min-width: 768px) {
  .projet-nav {
    padding: 40px 32px calc(40px + env(safe-area-inset-bottom));
  }
}
@media (min-width: 1280px) {
  .projet-nav {
    padding: 40px var(--site-margin) calc(40px + env(safe-area-inset-bottom));
  }
}
.projet-nav-link {
  font-size: 12px;
  font-weight: 300;
  color: #1a1a1a;
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: opacity 0.3s ease;
}
.projet-nav-link:hover { opacity: 0.5; }
.projet-nav-link--prev::before { content: '← '; }
.projet-nav-link--next::after  { content: ' →'; }
/* ── Protection casual des images ──────────── */
img {
  user-select: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  -webkit-user-drag: none;
  -webkit-touch-callout: none;
}

/* ── Bouton retour en haut ─────────────────────────────────────── */
#back-to-top {
  position: fixed;
  bottom: calc(24px + env(safe-area-inset-bottom));
  right: 24px;
  width: 44px;
  height: 44px;
  background: transparent;
  border: none;
  padding: 12px;
  color: rgba(26, 26, 26, 0.4);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transform: translateY(8px);
  transition: opacity 0.25s, transform 0.25s, color 0.2s;
  z-index: 200;
}
#back-to-top.is-visible {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}
#back-to-top:hover {
  color: rgba(26, 26, 26, 0.8);
}
#back-to-top svg {
  width: 20px;
  height: 20px;
}
