/* Polices auto-hébergées (sous-ensemble latin, variables) */
@font-face {
  font-family: "Newsreader";
  src: url("/fonts/newsreader-latin-wght-normal.woff2") format("woff2");
  font-style: normal;
  font-weight: 200 800;
  font-display: swap;
}
@font-face {
  font-family: "Newsreader";
  src: url("/fonts/newsreader-latin-wght-italic.woff2") format("woff2");
  font-style: italic;
  font-weight: 200 800;
  font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("/fonts/inter-latin-wght-normal.woff2") format("woff2");
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
}

:root {
  /* Palette imposée : aucune autre couleur dans ce fichier */
  --ink: #18191D;
  --cream: #F3EFE7;
  --sand: #CFC5B3;
  --greige: #E9E3D6;
  --grey: #4B5B51;

  /* Couleurs par contexte. Le gris n'atteint AA que sur crème et grège. */
  --bg: var(--cream);
  --fg: var(--ink);
  --fg-soft: var(--grey);

  --serif: "Newsreader", Georgia, serif;
  --sans: "Inter", system-ui, sans-serif;

  --gutter: clamp(1rem, 0.6rem + 1.6vw, 1.5rem);
  --section: clamp(3rem, 2.4rem + 2.65vw, 6rem);
  --gap: clamp(1.75rem, 1.45rem + 1.3vw, 3rem);
  --wrap: clamp(60rem, 62.5vw, 75rem);
}

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--serif);
  -webkit-font-smoothing: antialiased;
  overflow-wrap: break-word;
}

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

::selection { background: var(--ink); color: var(--cream); }

img { display: block; max-width: 100%; height: auto; }
figure { margin: 0; }
h1, h2, p { margin: 0; }

a { color: inherit; text-underline-offset: 0.2em; }
a:hover { text-decoration-thickness: 2px; }

:focus-visible {
  outline: 2px solid var(--fg);
  outline-offset: 3px;
}

/* Mise en page */
.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.block {
  padding-block: var(--section);
  background: var(--bg);
  color: var(--fg);
}
.block--sand { --bg: var(--sand); --fg-soft: var(--ink); }
.block--greige { --bg: var(--greige); }
.block--ink { --bg: var(--ink); --fg: var(--cream); --fg-soft: var(--sand); }

.row {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--gap);
  align-items: center;
}

.txt {
  display: flex;
  flex-direction: column;
  gap: 0.875rem;
  min-width: 0;
}

.fig {
  display: flex;
  flex-direction: column;
  gap: 0.625rem;
  min-width: 0;
}
.fig img { width: 100%; }
.fig--portrait { max-width: min(100%, 22rem); }

@media (min-width: 48em) {
  .row--hero { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .row--who { grid-template-columns: minmax(0, 300fr) minmax(0, 572fr); }
  .row--teaser { grid-template-columns: minmax(0, 492fr) minmax(0, 380fr); }
  .row--sketch { grid-template-columns: minmax(0, 532fr) minmax(0, 340fr); }
  .row--contact { grid-template-columns: minmax(0, 432fr) minmax(0, 440fr); align-items: start; }

  .fig--portrait { max-width: none; }
  .txt--who { max-width: 32.5rem; }
  .row--hero .txt { max-width: 27.5rem; }
  .row--contact .txt { max-width: 22.5rem; }
}

/* Typographie */
h1 {
  font-size: clamp(2rem, 1.87rem + 1.1vw, 3.25rem);
  font-weight: 300;
  line-height: 1.08;
  letter-spacing: -0.01em;
}
h2 {
  font-size: clamp(1.625rem, 1.52rem + 0.44vw, 2.25rem);
  font-weight: 300;
  line-height: 1.15;
}
.lead {
  font-size: clamp(1.0625rem, 1.03rem + 0.25vw, 1.375rem);
  font-weight: 300;
  line-height: 1.5;
}
.en {
  color: var(--fg-soft);
  font-size: clamp(0.9375rem, 0.92rem + 0.1vw, 1.0625rem);
  font-style: italic;
  font-weight: 300;
  line-height: 1.5;
}
.label {
  color: var(--fg-soft);
  font-family: var(--sans);
  font-size: 0.75rem;
  font-weight: 400;
  letter-spacing: 0.18em;
  line-height: 1.4;
  text-transform: uppercase;
}
.cap {
  color: var(--fg-soft);
  font-family: var(--sans);
  font-size: 0.75rem;
  font-weight: 400;
  line-height: 1.5;
}

/* « Sur le papier » reste collé au titre qu'il annonce */
.row--sketch .label + h2 { margin-top: -0.375rem; }

/* Les croquis se fondent dans le fond de leur section, comme sur la maquette */
.sketch { mix-blend-mode: multiply; }

.signature {
  width: min(15rem, 70%);
  margin-top: 0.25rem;
}

/* En-tête */
.site-header { border-bottom: 1px solid var(--sand); }
.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 4.25rem;
}
.brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-width: 0;
}
.brand__emblem { width: auto; height: 2.125rem; flex: none; }
.brand__name {
  font-family: var(--sans);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  line-height: 1.3;
  text-transform: uppercase;
}
.nav-link {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
  flex: none;
  color: var(--ink);
  text-decoration: none;
}
.nav-link:hover { text-decoration: underline; }

/* Lieu : pleine largeur */
.where__img {
  width: 100%;
  height: clamp(15rem, 30vw, 36rem);
  object-fit: cover;
  object-position: 50% 30%;
}
.where__caption { padding-block: 0.875rem; }

/* Formulaire */
.form {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  min-width: 0;
}
.field {
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
}
input[type="text"],
input[type="email"],
textarea {
  width: 100%;
  min-height: 2.75rem;
  padding: 0.625rem 0;
  border: 0;
  border-bottom: 1px solid var(--grey);
  border-radius: 0;
  background: transparent;
  color: var(--ink);
  font-family: var(--serif);
  font-size: 1.0625rem;
  line-height: 1.4;
  appearance: none;
}
textarea { resize: vertical; }
input[type="text"]:focus,
input[type="email"]:focus,
textarea:focus {
  outline: none;
  border-bottom: 2px solid var(--ink);
  padding-bottom: calc(0.625rem - 1px);
}
input:-webkit-autofill,
input:-webkit-autofill:focus {
  -webkit-text-fill-color: var(--ink);
  box-shadow: inset 0 0 0 100vmax var(--cream);
}
[aria-invalid="true"] {
  border-bottom: 2px solid var(--ink);
  padding-bottom: calc(0.625rem - 1px);
}
.field-error {
  color: var(--ink);
  font-family: var(--sans);
  font-size: 0.8125rem;
  font-weight: 600;
  line-height: 1.4;
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

.check {
  display: flex;
  align-items: flex-start;
  gap: 0.25rem;
  font-size: 0.9375rem;
  line-height: 1.4;
}
.check label {
  flex: 1;
  min-width: 0;
  padding-block: 0.625rem;
  cursor: pointer;
}
/* Case dessinée pour ne pas sortir de la palette ; zone tactile de 44 px */
.check input {
  flex: none;
  display: grid;
  place-content: center;
  width: 2.75rem;
  height: 2.75rem;
  margin: 0 0 0 -0.75rem;
  background: transparent;
  cursor: pointer;
  appearance: none;
}
.check input::before {
  content: "";
  width: 1.25rem;
  height: 1.25rem;
  border: 1px solid var(--grey);
  background: transparent;
}
.check input:checked::before {
  border-color: var(--ink);
  background: var(--ink);
  box-shadow: inset 0 0 0 3px var(--cream);
}
.check input:focus-visible { outline-offset: -4px; }

/* Champ piège : hors de vue, ni clavier ni lecteur d'écran */
.trap {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.btn {
  min-height: 3rem;
  padding: 0.875rem 1.625rem;
  border: 1px solid var(--ink);
  border-radius: 0;
  background: var(--ink);
  color: var(--cream);
  font-family: var(--sans);
  font-size: 0.75rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  cursor: pointer;
  appearance: none;
}
.btn:hover { background: var(--cream); color: var(--ink); }
.btn:focus-visible { outline: 2px solid var(--ink); }
.btn[disabled] {
  background: var(--greige);
  color: var(--ink);
  cursor: progress;
}

.form-status {
  font-size: 1.0625rem;
  font-weight: 600;
  line-height: 1.4;
}
.form-status:empty { display: none; }
.status-en {
  display: block;
  margin-top: 0.25rem;
  font-size: 0.9375rem;
  font-style: italic;
  font-weight: 400;
}

/* Pied de page */
.site-footer { border-top: 1px solid var(--sand); }
.site-footer__inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.75rem 2rem;
  padding-block: 1.5rem;
  font-size: 0.875rem;
  line-height: 1.4;
}
.site-footer__id {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  min-width: 0;
}
.site-footer__emblem { width: auto; height: 1.5rem; flex: none; }
.site-footer__links {
  display: flex;
  flex-wrap: wrap;
  gap: 0 1.5rem;
  min-width: 0;
}
.site-footer__links a {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
}
