/* Petric Sonja — feuille de style unique, sans framework.
   Direction : « brutalisme méditerranéen ». Palette Chaux & Terre, radius 0, filets de 1 px, aucune ombre.
   Mouvements courts (150 à 250 ms) ; seuls transform et opacity sont animés. */

/* ---------- Polices (hébergées sur le site, latin + latin étendu chargé à la demande) ---------- */
@font-face {
  font-family: "Cormorant Garamond";
  src: url("/fonts/cormorant-garamond.woff2") format("woff2");
  font-weight: 300 700;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Cormorant Garamond";
  src: url("/fonts/cormorant-garamond-ext.woff2") format("woff2");
  font-weight: 300 700;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0100-0130, U+0132-0151, U+0154-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Cormorant Garamond";
  src: url("/fonts/cormorant-garamond-italic.woff2") format("woff2");
  font-weight: 300 700;
  font-style: italic;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Cormorant Garamond";
  src: url("/fonts/cormorant-garamond-italic-ext.woff2") format("woff2");
  font-weight: 300 700;
  font-style: italic;
  font-display: swap;
  unicode-range: U+0100-0130, U+0132-0151, U+0154-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Inter Tight";
  src: url("/fonts/inter-tight.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Inter Tight";
  src: url("/fonts/inter-tight-ext.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0100-0130, U+0132-0151, U+0154-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "IBM Plex Mono";
  src: url("/fonts/ibm-plex-mono-400.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "IBM Plex Mono";
  src: url("/fonts/ibm-plex-mono-400-ext.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0100-0130, U+0132-0151, U+0154-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "IBM Plex Mono";
  src: url("/fonts/ibm-plex-mono-500.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "IBM Plex Mono";
  src: url("/fonts/ibm-plex-mono-500-ext.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0100-0130, U+0132-0151, U+0154-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* ---------- Design tokens ---------- */
/* Palette « Chaux & Terre ». Contrastes mesurés sur --chaux (clair) et --encre (sombre). */
:root {
  --chaux: #EFEAE2;        /* fond principal */
  --pierre: #CFC6B8;       /* filets décoratifs, fonds secondaires ; jamais pour du texte (1,4 : 1) */
  --beton: #8A8580;        /* filets marqués, bordures de champs (3,1 : 1) */
  --beton-texte: #66615C;  /* métadonnées, légendes (5,1 : 1) */
  --encre: #1A1714;        /* texte principal (14,9 : 1) */
  --terre: #A34A26;        /* seule couleur d'accent : liens actifs, focus, états (4,9 : 1) */
  --olive: #5C5B3F;        /* rares aplats de section, texte --chaux dessus (5,8 : 1) */

  /* Rôles utilisés par les composants */
  --bg: var(--chaux);
  --bg-elevated: #E7E1D7;
  --surface: #E2DBCF;
  --line: var(--pierre);
  --line-fort: var(--beton);
  --text: var(--encre);
  --text-muted: var(--beton-texte);
  --text-faint: #9A948D;   /* décoratif uniquement, jamais pour une information */
  --accent: var(--terre);
  --sur-accent: var(--chaux);
  --grain-opacite: 0.06;

  --serif: "Cormorant Garamond", Garamond, "Times New Roman", serif;   /* titres et mot-manifeste */
  --sans: "Inter Tight", "Helvetica Neue", Arial, sans-serif;          /* texte courant et nom */
  --mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;  /* données, navigation, boutons */
  --nom: var(--sans);

  --marge: clamp(20px, 6vw, 96px);
  --gouttiere: clamp(16px, 2vw, 32px);
  --entete: 64px;

  --t-xxl: clamp(3.2rem, 9vw, 9.5rem);
  --t-xl: clamp(2.6rem, 6.5vw, 6.5rem);
  --t-l: clamp(2rem, 4vw, 3.8rem);
  --t-m: clamp(1.25rem, 1.6vw, 1.5rem);
  --t-base: 1.125rem;      /* 18 px */
  --t-mono: 0.78rem;       /* 12,5 px */

  --duree: 200ms;
  --ease: cubic-bezier(0.2, 0, 0, 1);
  color-scheme: light;
}

/* Variante sombre « Nuit d'été » : automatique, ou choisie avec le bouton de l'en-tête */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="clair"]) {
    --bg: var(--encre); --bg-elevated: #221E1A; --surface: #2A2521;
    --line: #3A342E; --line-fort: #77706A;  /* 3,7 : 1 */
    --text: var(--chaux); --text-muted: #A8A29B;  /* 7,1 : 1 */
    --text-faint: #6B655F; --accent: #D07A52;  /* 5,6 : 1 */
    --sur-accent: var(--encre); --grain-opacite: 0.04;
    color-scheme: dark;
  }
}
:root[data-theme="sombre"] {
  --bg: var(--encre); --bg-elevated: #221E1A; --surface: #2A2521;
  --line: #3A342E; --line-fort: #77706A;
  --text: var(--chaux); --text-muted: #A8A29B;
  --text-faint: #6B655F; --accent: #D07A52;
  --sur-accent: var(--encre); --grain-opacite: 0.04;
  color-scheme: dark;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; border-radius: 0; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; background: var(--bg); }
body {
  margin: 0;
  color: var(--text);
  font-family: var(--sans);
  font-size: var(--t-base);
  line-height: 1.55;
  font-weight: 400;
  font-variant-numeric: lining-nums;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}
img { display: block; max-width: 100%; height: auto; }
picture { display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
h1, h2, h3, p, ul, figure { margin: 0; }
ul { padding: 0; list-style: none; }
::selection { background: var(--accent); color: var(--sur-accent); }

.mono {
  font-family: var(--mono);
  font-size: var(--t-mono);
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  line-height: 1.6;
}
.faible { color: var(--text-faint); }
.faible-texte { color: var(--text-muted); }

/* Grain de chaux : posé derrière le contenu, il ne touche jamais les photos (opaques) */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: var(--grain-opacite);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='g'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0.1 0 0 0 0 0.09 0 0 0 0 0.08 0 0 0 1 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23g)'/%3E%3C/svg%3E");
}
:root[data-theme="sombre"] body::after { filter: invert(1); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="clair"]) body::after { filter: invert(1); } }

/* Focus clavier : toujours visible */
:focus { outline: none; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

.evitement {
  position: fixed; left: var(--marge); top: 12px; z-index: 200;
  background: var(--text); color: var(--bg); padding: 8px 12px;
  transform: translateY(-200%);
}
.evitement:focus-visible { transform: none; }

/* ---------- Grille 12 colonnes ---------- */
.grille {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: var(--gouttiere);
  padding-left: var(--marge);
  padding-right: var(--marge);
}
.col-entete { grid-column: 1 / span 3; }
.col-large { grid-column: 4 / -1; }
.col-principale { grid-column: 4 / span 8; }

.section { padding-top: clamp(96px, 14vw, 200px); }
.entete-page { padding-top: calc(var(--entete) + clamp(64px, 10vw, 160px)); padding-bottom: clamp(48px, 7vw, 112px); border-bottom: 1px solid var(--line); }

.index-section { display: flex; gap: 12px; color: var(--text-muted); margin-bottom: 24px; }
.index-section span:first-child { color: var(--text-muted); }

@media (max-width: 760px) {
  .col-entete, .col-large, .col-principale { grid-column: 1 / -1; }
}

/* ---------- Typographie ---------- */
.titre-xxl { font-size: var(--t-xxl); font-weight: 500; line-height: 0.95; letter-spacing: -0.015em; }
/* Le nom garde sa police d'origine */
.titre-xxl, .titre-xl, .titre-l, .titre-m, .titre-s, .lp-titre { font-family: var(--serif); }
.titre-s { font-size: clamp(1.5rem, 2.2vw, 2rem); font-weight: 500; line-height: 1.1; }
.nom, .logo { font-family: var(--nom); }
.titre-xxl.nom { line-height: 0.92; letter-spacing: -0.035em; }
.titre-xl { font-size: var(--t-xl); font-weight: 500; line-height: 1; letter-spacing: -0.01em; }
.titre-m { font-size: var(--t-m); font-weight: 500; line-height: 1.2; margin-top: 2.2em; }
.texte-legal { max-width: 68ch; }
.texte-legal p { margin-top: 0.8em; }
.texte-legal h2:first-child { margin-top: 0; }
.titre-l { font-size: var(--t-l); font-weight: 500; line-height: 1.02; letter-spacing: -0.005em; }
.texte-large { font-size: var(--t-m); line-height: 1.45; letter-spacing: -0.005em; max-width: 34em; }
.intro { margin-top: clamp(28px, 4vw, 56px); }
.num { color: var(--text-muted); }

/* ---------- Liens ---------- */
.lien { position: relative; display: inline-block; }
.lien::after, .lien-fort::after {
  content: "";
  position: absolute; left: 0; right: 0; bottom: -2px; height: 1px;
  background: currentColor;
  transform: scaleX(0); transform-origin: right;
  transition: transform var(--duree) var(--ease);
}
.lien:hover::after, .lien:focus-visible::after,
.lien-fort:hover::after, .lien-fort:focus-visible::after { transform: scaleX(1); transform-origin: left; }

.lien-fort {
  position: relative; display: inline-flex; gap: 0.6em; align-items: baseline;
  font-family: var(--mono); font-size: 0.875rem; font-weight: 500; letter-spacing: 0.04em; text-transform: uppercase;
  padding: 0.9em 0; min-height: 24px;
}
.lien-fort span { display: inline-block; transition: transform var(--duree) var(--ease); }
.lien-fort:hover span { transform: translateX(6px); }
.lien-fort::after { bottom: 0.6em; }
.lien-fort.accent::after { transform: scaleX(1); }
.accent { color: var(--accent); }

/* ---------- En-tête ---------- */
.entete {
  position: fixed; inset: 0 0 auto 0; z-index: 50;
  height: var(--entete);
  display: flex; align-items: center; gap: clamp(16px, 2.4vw, 36px);
  padding: 0 var(--marge);
  background: var(--bg);
  border-bottom: 1px solid var(--line);
}
.logo { margin-right: auto; display: inline-flex; align-items: center; gap: 12px; justify-self: start; font-weight: 500; letter-spacing: -0.01em; font-size: 1.05rem; }
.logo-sp { width: auto; height: 38px; flex: none; }
.indicateur { color: var(--text-muted); margin: 0 auto 0 0; }
.entete .mono { letter-spacing: 0.08em; }
.nav { display: flex; justify-content: flex-end; align-items: center; gap: clamp(16px, 2.4vw, 36px); }
.nav ul { display: flex; gap: clamp(14px, 2vw, 28px); }
.lien-nav { position: relative; color: var(--text-muted); display: inline-flex; gap: 6px; white-space: nowrap; padding: 6px 0; transition: color var(--duree) var(--ease); }
.lien-nav .num { color: var(--text-muted); }
.lien-nav:hover, .lien-nav[aria-current] { color: var(--text); }
.nav ul .lien-nav[aria-current]::before {
  content: ""; position: absolute; left: -10px; top: 50%; width: 4px; height: 4px; margin-top: -2px; background: var(--accent);
}
.langues { display: flex; gap: 10px; padding-left: clamp(14px, 2vw, 28px); border-left: 1px solid var(--line); }
.theme-bouton { color: var(--text-muted); padding: 6px 0; min-width: 24px; }
.theme-bouton:hover { color: var(--text); }
.menu-bouton { display: none; padding: 10px 0; }
/* « Votre projet » : toujours visible, le seul bouton plein du site */
.cta-entete {
  flex: none; display: inline-flex; gap: 0.5em; align-items: center; min-height: 36px; padding: 0 14px;
  background: var(--accent); color: var(--sur-accent); border: 1px solid var(--accent);
  transition: background-color var(--duree) var(--ease), color var(--duree) var(--ease);
}
.cta-entete:hover, .cta-entete[aria-current] { background: transparent; color: var(--accent); }

@media (max-width: 1600px) {
  .indicateur { display: none; }
}
@media (max-width: 1440px) {
  .nav ul { gap: 14px; }
  .lien-nav .num { display: none; }
}
@media (max-width: 1180px) {
  .menu-bouton { display: block; }
  .nav {
    position: fixed; inset: var(--entete) 0 0 0; z-index: 49;
    flex-direction: column; justify-content: space-between; align-items: stretch;
    padding: 32px var(--marge) 40px;
    background: var(--bg);
    visibility: hidden; opacity: 0;
    transition: opacity var(--duree) var(--ease), visibility 0s var(--duree);
  }
  .nav.ouvert { visibility: visible; opacity: 1; transition: opacity var(--duree) var(--ease); }
  .nav ul { flex-direction: column; gap: 0; }
  .nav ul li { border-bottom: 1px solid var(--line); }
  .nav ul .lien-nav { font-family: var(--serif); text-transform: none; letter-spacing: 0; font-size: clamp(2.4rem, 10vw, 3.8rem); font-weight: 500; line-height: 1; padding: 18px 0; gap: 16px; align-items: baseline; color: var(--text); }
  .nav ul .lien-nav .num { font-family: var(--mono); font-size: var(--t-mono); letter-spacing: 0.04em; }
  .nav ul .lien-nav { display: flex; width: 100%; white-space: normal; overflow-wrap: anywhere; }
  .nav ul .lien-nav[aria-current]::before { left: auto; right: 0; }
  .langues { border: 0; padding: 0; }
}
@media (max-width: 359px) {
  .logo-texte { display: none; }
}

/* ---------- Accueil ---------- */
.hero {
  min-height: 100svh;
  padding-top: calc(var(--entete) + clamp(40px, 6vw, 96px));
  padding-bottom: clamp(40px, 5vw, 72px);
  grid-template-rows: auto 1fr auto;
  row-gap: clamp(32px, 4vw, 56px);
  border-bottom: 1px solid var(--line);
}
.hero-meta { grid-column: 1 / span 6; grid-row: 1; display: flex; gap: 12px; color: var(--text-muted); }
.hero-meta span:first-child { color: var(--text-muted); }
.hero-titre { grid-column: 1 / span 7; grid-row: 2; align-self: end; position: relative; z-index: 2; display: grid; gap: clamp(16px, 2vw, 28px); font-weight: 500; }
.hero-qui { font-size: var(--t-mono); color: var(--text); }
.hero-manifeste { font-family: var(--serif); font-size: clamp(2.8rem, 6.6vw, 8rem); line-height: 0.95; letter-spacing: -0.015em; }
.hero-texte { grid-column: 1 / span 5; grid-row: 3; display: grid; gap: 24px; }
.surtitre { color: var(--text-muted); max-width: 40em; }
.actions { display: flex; flex-wrap: wrap; gap: 8px 36px; }
.hero-portrait { grid-column: 8 / -1; grid-row: 1 / span 3; align-self: start; }
.hero-image { aspect-ratio: 1086 / 1448; }

@media (max-width: 760px) {
  .hero { min-height: 0; grid-template-rows: none; }
  .hero-meta, .hero-titre, .hero-texte { grid-column: 1 / -1; grid-row: auto; }
  .hero-portrait { grid-column: 3 / -1; grid-row: auto; }
}

/* Prestations en liste (accueil) */
.liste-prestations { border-top: 1px solid var(--line); }
.ligne-prestation { border-bottom: 1px solid var(--line); }
.ligne-prestation a {
  display: grid; grid-template-columns: 48px minmax(0, 1.1fr) minmax(0, 1fr) 24px; gap: var(--gouttiere);
  align-items: baseline; padding: clamp(20px, 2.6vw, 36px) 0;
}
.lp-titre { font-size: var(--t-l); font-weight: 500; letter-spacing: -0.005em; line-height: 1; transition: transform var(--duree) var(--ease); }
.lp-resume { color: var(--text-muted); max-width: 30em; }
.lp-fleche { color: var(--text-muted); transition: transform var(--duree) var(--ease), color var(--duree); justify-self: end; }
.ligne-prestation a:hover .lp-titre { transform: translateX(12px); }
.ligne-prestation a:hover .lp-fleche { transform: translateX(4px); color: var(--text); }
@media (max-width: 760px) {
  .ligne-prestation a { grid-template-columns: 36px 1fr 20px; }
  .lp-resume { grid-column: 2 / 3; grid-row: 2; }
  .lp-fleche { grid-column: 3; grid-row: 1; }
}

/* ---------- Œuvres : jamais recadrées ---------- */
.galerie { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gouttiere); row-gap: clamp(56px, 8vw, 128px); align-items: start; }
.oeuvre { position: relative; }
.oeuvre[data-ouvrable] { cursor: zoom-in; }
.oeuvre-image { overflow: hidden; }
.oeuvre-image img { width: 100%; transition: transform var(--duree) var(--ease); }
.prestation-image img { width: 100%; }
.oeuvre[data-ouvrable]:hover .oeuvre-image img { transform: scale(1.025); }
.oeuvre[hidden] { display: none; }

.cartel { display: grid; grid-template-columns: 48px 1fr; column-gap: 12px; padding-top: 12px; color: var(--text-muted); border-top: 1px solid var(--line); margin-top: 12px; }
.cartel-num { color: var(--text-muted); grid-row: span 2; }
.cartel-titre { color: var(--text); }
.hero-portrait .cartel, .apropos-portrait .cartel, .conservation-image .cartel, .prestation-image .cartel { grid-template-columns: 1fr; }

/* Accueil : composition asymétrique */
.galerie-accueil .oeuvre:nth-child(1) { grid-column: 1 / span 7; }
.galerie-accueil .oeuvre:nth-child(2) { grid-column: 9 / span 4; margin-top: clamp(80px, 12vw, 200px); }
.galerie-accueil .oeuvre:nth-child(3) { grid-column: 3 / span 5; }

/* Page Réalisations : rythme éditorial */
.section-galerie { padding-top: clamp(32px, 4vw, 56px); padding-bottom: 32px; }
.section-galerie .galerie { grid-column: 1 / -1; padding-top: clamp(48px, 6vw, 96px); }
.galerie-complete .oeuvre:nth-child(4n+1) { grid-column: 1 / span 6; }
.galerie-complete .oeuvre:nth-child(4n+2) { grid-column: 8 / span 5; margin-top: clamp(64px, 10vw, 160px); }
.galerie-complete .oeuvre:nth-child(4n+3) { grid-column: 2 / span 5; }
.galerie-complete .oeuvre:nth-child(4n+4) { grid-column: 8 / span 4; margin-top: clamp(32px, 5vw, 80px); }
@media (max-width: 760px) {
  .galerie .oeuvre:nth-child(n) { grid-column: 1 / -1; margin-top: 0; }
}

.filtres { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 8px 28px; border-bottom: 1px solid var(--line); padding-bottom: 16px; }
.filtre { position: relative; color: var(--text-muted); padding: 6px 0; transition: color var(--duree) var(--ease); }
.filtre .compte { color: var(--text-muted); margin-left: 4px; }
.filtre:hover, .filtre[aria-pressed="true"] { color: var(--text); }
.filtre::after { content: ""; position: absolute; left: 0; right: 0; bottom: -17px; height: 1px; background: var(--text); transform: scaleX(0); transform-origin: left; transition: transform var(--duree) var(--ease); }
.filtre[aria-pressed="true"]::after { transform: scaleX(1); }

/* Image en attente : sobre, sans dégradé */
.attente { aspect-ratio: 4 / 5; background: var(--bg-elevated); border: 1px solid var(--line); display: flex; align-items: flex-end; padding: 14px; }
.attente span { font-family: var(--mono); font-size: var(--t-mono); text-transform: uppercase; letter-spacing: 0.04em; color: var(--text-muted); }

/* Chargement progressif : fondu depuis la couleur dominante */
.js picture.fondu img { opacity: 0; transition: opacity var(--duree) var(--ease); }
.js picture.fondu.charge img { opacity: 1; }

/* ---------- Page Prestations ---------- */
.prestation { padding-top: clamp(80px, 11vw, 168px); padding-bottom: clamp(80px, 11vw, 168px); border-bottom: 1px solid var(--line); row-gap: 32px; align-items: start; scroll-margin-top: var(--entete); }
.prestation-num { grid-column: 1 / span 2; }
.prestation-texte { grid-column: 3 / span 4; display: grid; gap: 28px; }
.prestation-image { grid-column: 8 / -1; }
.prestation.inverse .prestation-texte { grid-column: 8 / -1; grid-row: 1; }
.prestation.inverse .prestation-image { grid-column: 2 / span 5; grid-row: 1; }
.prestation.inverse .prestation-num { grid-column: 7 / span 1; grid-row: 1; }
.liste-mono { color: var(--text-muted); border-top: 1px solid var(--line); }
.liste-mono li { padding: 10px 0; border-bottom: 1px solid var(--line); }
@media (max-width: 760px) {
  .prestation-num, .prestation-texte, .prestation-image,
  .prestation.inverse .prestation-num, .prestation.inverse .prestation-texte, .prestation.inverse .prestation-image { grid-column: 1 / -1; grid-row: auto; }
}

/* ---------- Appel au devis ---------- */
.appel { padding-bottom: clamp(96px, 12vw, 180px); }
.appel .col-principale { display: grid; gap: 32px; }

/* ---------- À propos ---------- */
.apropos { row-gap: 48px; align-items: start; }
.apropos-portrait { grid-column: 1 / span 4; }
.apropos-texte { grid-column: 6 / span 6; display: grid; gap: 24px; }
.apropos-texte .index-section { margin: 32px 0 0; }
.parcours { border-top: 1px solid var(--line); }
.parcours li { display: grid; grid-template-columns: 96px 1fr; gap: var(--gouttiere); padding: 14px 0; border-bottom: 1px solid var(--line); }
.annee { color: var(--text-muted); }
@media (max-width: 760px) {
  .apropos-portrait { grid-column: 1 / span 9; }
  .apropos-texte { grid-column: 1 / -1; }
}

/* ---------- Contact ---------- */
.contact { row-gap: 64px; padding-bottom: clamp(96px, 12vw, 180px); align-items: start; }
.coordonnees { grid-column: 1 / span 4; border-top: 1px solid var(--line); }
.coordonnees li { display: grid; gap: 6px; padding: 18px 0; border-bottom: 1px solid var(--line); }
.etiquette { color: var(--text-muted); }
.email { font-size: var(--t-m); justify-self: start; }
.copier { justify-self: start; color: var(--text-muted); padding: 4px 0; }
.copier:hover { color: var(--text); }
.formulaire { grid-column: 6 / -1; display: grid; gap: 28px; }
.deux-colonnes { display: grid; grid-template-columns: 1fr 1fr; gap: 28px var(--gouttiere); }
.champ { display: grid; gap: 10px; }
.champ > span { color: var(--text-muted); }
.champ input, .champ textarea, .champ select {
  font: inherit; font-size: var(--t-m); color: var(--text);
  background: transparent; border: 0; border-bottom: 1px solid var(--line-fort);
  padding: 6px 0 12px; width: 100%; resize: vertical;
  transition: border-color var(--duree) var(--ease);
}
.champ select { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--text-muted) 50%), linear-gradient(135deg, var(--text-muted) 50%, transparent 50%); background-position: calc(100% - 10px) 55%, calc(100% - 5px) 55%; background-size: 5px 5px; background-repeat: no-repeat; }
.champ select option { background: var(--bg-elevated); color: var(--text); }
.champ input:hover, .champ textarea:hover, .champ select:hover { border-bottom-color: var(--text); }
.champ input:focus-visible, .champ textarea:focus-visible, .champ select:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-bottom-color: var(--text); }
.mention { color: var(--text-muted); text-transform: none; }
.envoi { display: grid; gap: 12px; justify-items: start; }
.envoi button[disabled] { opacity: 0.5; cursor: wait; }
.etat { min-height: 1.6em; text-transform: none; }
.etat.ok { color: var(--text); }
.etat.ko { color: var(--accent); }
.etat a { text-decoration: underline; text-underline-offset: 3px; }
.piege { position: absolute; left: -9999px; }
.consignes { display: grid; gap: 8px; padding: 18px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); color: var(--text-muted); max-width: 60ch; }
.consignes .mono { color: var(--text); }
.case { display: grid; grid-template-columns: 24px 1fr; gap: 12px; align-items: start; cursor: pointer; }
.case input { width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--accent); }
@media (max-width: 760px) {
  .coordonnees, .formulaire { grid-column: 1 / -1; }
  .deux-colonnes { grid-template-columns: 1fr; }
}

/* ---------- Lot 3 : registre, pour qui, étapes, questions, professionnels ---------- */
.lp-resume .mono { color: var(--text-muted); margin-right: 8px; }
.sur-devis { color: var(--text); }

/* Registre des projets */
.registre { width: 100%; border-collapse: collapse; border-top: 1px solid var(--line-fort); }
.registre th, .registre td { text-align: left; vertical-align: baseline; padding: 14px var(--gouttiere) 14px 0; border-bottom: 1px solid var(--line); font-weight: 400; }
.registre thead th { font-weight: 500; color: var(--text-muted); padding-top: 10px; padding-bottom: 10px; }
.registre .r-projet { font-family: var(--serif); font-size: var(--t-m); font-weight: 500; }
.registre .r-num, .registre .r-annee, .registre .r-lieu { color: var(--text-muted); }
.r-num { width: 64px; }
.r-etiquette { display: none; }
.galerie-accueil { margin-top: clamp(56px, 8vw, 112px); }
@media (max-width: 760px) {
  .registre thead { display: none; }
  .registre tr { display: grid; grid-template-columns: 48px 1fr; column-gap: 12px; row-gap: 4px; padding: 16px 0; border-bottom: 1px solid var(--line); }
  .registre th, .registre td { border: 0; padding: 0; }
  .registre .r-num { grid-row: span 4; }
  .r-etiquette { display: inline-block; min-width: 96px; color: var(--text-muted); font-family: var(--mono); font-size: var(--t-mono); text-transform: uppercase; letter-spacing: 0.04em; }
}

/* Pour qui */
.pour-qui { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); border-top: 1px solid var(--line); }
.pour-qui li { display: grid; gap: 14px; align-content: start; padding: clamp(24px, 3vw, 40px) var(--gouttiere) clamp(24px, 3vw, 40px) 0; border-bottom: 1px solid var(--line); }
.pour-qui li:nth-child(odd) { border-right: 1px solid var(--line); }
.pour-qui li:nth-child(even) { padding-left: var(--gouttiere); }
.pour-qui p { color: var(--text-muted); max-width: 34em; }
.pour-qui .lien { justify-self: start; }
@media (max-width: 760px) {
  .pour-qui { grid-template-columns: 1fr; }
  .pour-qui li:nth-child(odd) { border-right: 0; }
  .pour-qui li:nth-child(even) { padding-left: 0; }
}

/* Étapes numérotées : méthode, principes, interventions */
.etapes { list-style: none; padding: 0; margin: 0; border-top: 1px solid var(--line); }
.etapes li { display: grid; grid-template-columns: 48px minmax(0, 1fr) minmax(0, 1.4fr); gap: var(--gouttiere); align-items: baseline; padding: clamp(18px, 2.4vw, 32px) 0; border-bottom: 1px solid var(--line); }
.etapes p { color: var(--text-muted); max-width: 40em; }
.etapes + .sur-devis { margin-top: 24px; }
@media (max-width: 760px) {
  .etapes li { grid-template-columns: 36px 1fr; row-gap: 8px; }
  .etapes p { grid-column: 2; }
}

/* Questions fréquentes */
.faq { border-top: 1px solid var(--line); }
.question { border-bottom: 1px solid var(--line); }
.question summary { display: flex; justify-content: space-between; align-items: baseline; gap: var(--gouttiere); padding: clamp(18px, 2.4vw, 28px) 0; cursor: pointer; list-style: none; }
.question summary::-webkit-details-marker { display: none; }
.question summary:hover .titre-s { color: var(--accent); }
.question .plus { color: var(--text-muted); transition: transform var(--duree) var(--ease); }
.question[open] .plus { transform: rotate(45deg); }
.reponse { display: grid; gap: 12px; padding-bottom: 28px; max-width: 46em; color: var(--text-muted); }

/* Professionnels */
.pro { padding-top: clamp(64px, 9vw, 128px); padding-bottom: clamp(64px, 9vw, 128px); border-bottom: 1px solid var(--line); row-gap: 28px; align-items: start; scroll-margin-top: var(--entete); }
.pro-texte { grid-column: 3 / span 5; display: grid; gap: 24px; }
.pro-points { grid-column: 9 / -1; }
.engagements { border-top: 1px solid var(--line-fort); }
.engagements li { font-family: var(--serif); font-size: var(--t-m); padding: 16px 0; border-bottom: 1px solid var(--line); }
.engagements + .sur-devis { margin-top: 24px; }
@media (max-width: 760px) {
  .pro-texte, .pro-points { grid-column: 1 / -1; }
}

/* Divers */
.diplome { display: grid; gap: 20px; border-top: 1px solid var(--line-fort); padding-top: 28px; }
.liens-suite { display: flex; flex-wrap: wrap; gap: 8px 28px; }
.planche .galerie { grid-column: 1 / -1; padding-top: clamp(32px, 4vw, 64px); }
.planche .col-large p { max-width: 40em; }
.section-galerie .col-large + .galerie { padding-top: clamp(56px, 8vw, 112px); }
.fiche { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 0 var(--gouttiere); margin: clamp(28px, 4vw, 48px) 0 0; border-top: 1px solid var(--line); }
.fiche div { padding: 12px 0; border-bottom: 1px solid var(--line); }
.fiche dt { color: var(--text-muted); }
.fiche dd { margin: 4px 0 0; }
.etude { row-gap: 8px; }
.etude .col-principale { margin-bottom: 40px; }
.bandeau-exemple { display: inline-block; background: var(--accent); color: var(--sur-accent); padding: 6px 10px; margin-bottom: 24px; }

/* ---------- Pied de page ---------- */
.pied { display: flex; flex-wrap: wrap; gap: 10px 28px; border-top: 1px solid var(--line); padding-top: 24px; padding-bottom: 32px; color: var(--text-muted); }
.pied > :first-child { margin-right: auto; }
@media (max-width: 760px) { .pied { flex-direction: column; } }

/* ---------- Vue en grand ---------- */
.visionneuse {
  position: fixed; inset: 0; z-index: 80;
  background: var(--bg);
  display: grid; grid-template-rows: auto 1fr auto;
  padding: 20px var(--marge);
  opacity: 0; transition: opacity var(--duree) var(--ease);
}
.visionneuse[hidden] { display: none; }
.visionneuse.ouverte { opacity: 1; }
.vis-barre, .vis-nav { display: flex; justify-content: space-between; align-items: center; color: var(--text-muted); }
.vis-barre { border-bottom: 1px solid var(--line); padding-bottom: 14px; }
.vis-nav { border-top: 1px solid var(--line); padding-top: 14px; }
.vis-barre button, .vis-nav button { padding: 6px 0; }
.vis-barre button:hover, .vis-nav button:hover { color: var(--text); }
.vis-figure { display: grid; grid-template-rows: minmax(0, 1fr) auto; justify-items: center; align-content: center; min-height: 0; padding: 24px 0; gap: 0; }
.vis-figure img { max-height: 100%; max-width: 100%; width: auto; height: auto; object-fit: contain; min-height: 0; transition: opacity var(--duree) var(--ease), transform var(--duree) var(--ease); }
.vis-figure img.change { opacity: 0; transform: translateY(8px); }
.vis-figure .cartel { width: min(100%, 560px); }
body.vis-active { overflow: hidden; }

/* ---------- Révélations au défilement (uniquement avec JS) ---------- */
.js [data-reveal]:not([data-reveal="masque"]) { opacity: 0; transform: translateY(8px); transition: opacity var(--duree) var(--ease), transform var(--duree) var(--ease); }
.js [data-reveal].visible:not([data-reveal="masque"]) { opacity: 1; transform: none; }
.ligne { display: block; overflow: hidden; padding-bottom: 0.06em; margin-bottom: -0.06em; }
.ligne > span { display: block; }
.js [data-reveal="masque"] .ligne > span { transform: translateY(105%); transition: transform var(--duree) var(--ease); }
.js [data-reveal="masque"] .ligne:nth-child(2) > span { transition-delay: 40ms; }
.js [data-reveal="masque"].visible .ligne > span { transform: none; }

/* ---------- Transitions entre pages (navigateurs compatibles) ---------- */
@view-transition { navigation: auto; }
::view-transition-old(root) { animation: 150ms var(--ease) both sortie; }
::view-transition-new(root) { animation: 200ms var(--ease) both entree; }
@keyframes sortie { to { opacity: 0; } }
@keyframes entree { from { opacity: 0; } }

/* ---------- Mouvement réduit : tout est immédiat ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
  .js [data-reveal]:not([data-reveal="masque"]), .js [data-reveal="masque"] .ligne > span { opacity: 1; transform: none; }
  .js picture.fondu img { opacity: 1; }
  @view-transition { navigation: none; }
}

/* Curseur pinceau (souris uniquement, ajouté par main.js) : pinceau au repos, pinceau chargé de terre sur ce qui se clique.
   La traînée est dessinée dans un canvas par main.js. */
.pinceau, .pinceau body { cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' viewBox='0 0 32 32'%3E%3Cg transform='translate(2.5 29.5) rotate(45)' stroke='%23EFEAE2' stroke-width='1.5' stroke-linejoin='round' paint-order='stroke'%3E%3Cpath d='M-2.4 -17 L-1.5 -35.5 Q0 -38 1.5 -35.5 L2.4 -17Z' fill='%231A1714'/%3E%3Crect x='-3.3' y='-17.5' width='6.6' height='6.5' fill='%238A8580'/%3E%3Cpath d='M0 0 C-1.2 -3 -3.3 -7 -3.3 -11 L3.3 -11 C3.3 -7 1.2 -3 0 0Z' fill='%233B2F27'/%3E%3C/g%3E%3Cpath d='M2.5 29.5 C3.2 27.2 4.2 25.6 5.6 24.2 L7.8 26.4 C6.4 27.8 4.8 28.8 2.5 29.5Z' fill='%23A34A26'/%3E%3C/svg%3E") 2 30, auto; }
.pinceau a, .pinceau button, .pinceau summary, .pinceau label, .pinceau select, .pinceau [role="button"], .pinceau .case { cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' viewBox='0 0 32 32'%3E%3Cg transform='translate(2.5 29.5) rotate(45)' stroke='%23EFEAE2' stroke-width='1.5' stroke-linejoin='round' paint-order='stroke'%3E%3Cpath d='M-2.4 -17 L-1.5 -35.5 Q0 -38 1.5 -35.5 L2.4 -17Z' fill='%231A1714'/%3E%3Crect x='-3.3' y='-17.5' width='6.6' height='6.5' fill='%238A8580'/%3E%3Cpath d='M0 0 C-1.2 -3 -3.3 -7 -3.3 -11 L3.3 -11 C3.3 -7 1.2 -3 0 0Z' fill='%23A34A26'/%3E%3C/g%3E%3Cpath d='M2.5 29.5 C3.2 27.2 4.2 25.6 5.6 24.2 L7.8 26.4 C6.4 27.8 4.8 28.8 2.5 29.5Z' fill='%23A34A26'/%3E%3C/svg%3E") 2 30, pointer; }
.pinceau input:not([type="checkbox"]):not([type="radio"]):not([type="submit"]), .pinceau textarea { cursor: text; }
.pinceau .oeuvre[data-ouvrable] { cursor: zoom-in; }
.pinceau .envoi button[disabled] { cursor: wait; }
.trainee { position: fixed; inset: 0; z-index: 300; pointer-events: none; mix-blend-mode: multiply; }
:root[data-theme="sombre"] .trainee { mix-blend-mode: normal; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="clair"]) .trainee { mix-blend-mode: normal; } }
