/* Site de Thomas Dechaud-Fauchet — v8.
   Même famille que lelivredessons.fr : Jost pour les titres, Newsreader pour le texte,
   noir chaud et ocre. Le « fond vivant » prend les couleurs de l'œuvre regardée. */

@font-face { font-family: "Jost"; src: url("../fonts/jost-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Jost"; src: url("../fonts/jost-latin-500-normal.woff2") format("woff2"); font-weight: 500; font-style: normal; font-display: swap; }
@font-face { font-family: "Jost"; src: url("../fonts/jost-latin-600-normal.woff2") format("woff2"); font-weight: 600; font-style: normal; font-display: swap; }
@font-face { font-family: "Jost"; src: url("../fonts/jost-latin-500-italic.woff2") format("woff2"); font-weight: 500; font-style: italic; font-display: swap; }
@font-face { font-family: "Jost"; src: url("../fonts/jost-latin-600-italic.woff2") format("woff2"); font-weight: 600; font-style: italic; font-display: swap; }
@font-face { font-family: "Newsreader"; src: url("../fonts/newsreader-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Newsreader"; src: url("../fonts/newsreader-latin-400-italic.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: "Newsreader"; src: url("../fonts/newsreader-latin-500-normal.woff2") format("woff2"); font-weight: 500; font-style: normal; font-display: swap; }

:root {
  color-scheme: dark;
  --nuit: #14110f;
  --craie: #e8e6e1;
  --cendre: #a7a39b;
  --fumee: #8a857c;
  --ocre: #d8a657;
  --filet: rgba(232, 230, 225, .13);
  --titre: "Jost", "Century Gothic", "Futura", sans-serif;
  --texte: "Newsreader", Georgia, "Times New Roman", serif;
  --large: 68rem;
  --mesure: 38rem;
  --marge: max(1.25rem, calc((100% - var(--large)) / 2));
  --doux: cubic-bezier(.2, .6, .2, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { background: var(--nuit); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100vh;
  background: transparent;
  color: var(--craie);
  font-family: var(--texte);
  font-size: 1.125rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ---------- fond vivant ---------- */
.fond {
  position: fixed; inset: 0; z-index: -1; overflow: hidden; pointer-events: none;
  background:
    radial-gradient(70rem 45rem at 82% -18%, rgba(216, 166, 87, .15), transparent 70%),
    var(--nuit);
}
.fond .calque {
  position: absolute; inset: -12%;
  background-size: cover; background-position: center;
  filter: blur(72px) saturate(1.4) brightness(.9);
  opacity: 0; transform: scale(1.1);
  transition: opacity 1.8s ease, transform 5s var(--doux);
  will-change: opacity, transform;
}
.fond .calque.on { opacity: .64; transform: scale(1); }
.fond::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(20, 17, 15, .12) 0%, rgba(20, 17, 15, .45) 55%, rgba(20, 17, 15, .78) 100%);
}

/* ---------- liens, focus ---------- */
a {
  color: inherit;
  text-decoration-thickness: 1px;
  text-underline-offset: .22em;
  text-decoration-color: rgba(232, 230, 225, .4);
  transition: color .25s, text-decoration-color .25s;
}
a:hover { color: var(--ocre); text-decoration-color: currentColor; }
:focus-visible { outline: 2px solid var(--ocre); outline-offset: 3px; border-radius: 2px; }
.evitement {
  position: absolute; left: 1rem; top: -4rem; z-index: 20;
  padding: .6rem 1rem; background: var(--craie); color: var(--nuit);
  font-family: var(--titre); font-size: .9rem; text-decoration: none;
}
.evitement:focus { top: 1rem; }

/* ---------- en-tête ---------- */
.entete {
  position: sticky; top: 0; z-index: 10;
  display: flex; align-items: baseline; gap: .5rem 2rem;
  padding: 1rem var(--marge);
  background: rgba(20, 17, 15, .5);
  -webkit-backdrop-filter: blur(20px) saturate(1.4);
  backdrop-filter: blur(20px) saturate(1.4);
  border-bottom: 1px solid var(--filet);
  font-family: var(--titre); font-size: .95rem; line-height: 1.4;
}
.entete p { margin: 0; }
.entete .nom { font-weight: 600; letter-spacing: -.005em; }
.entete nav { flex: 1; }
.entete ul { display: flex; gap: 1.6rem; margin: 0; padding: 0; list-style: none; }
.entete a { text-decoration: none; color: var(--cendre); }
.entete .nom a, .entete a:hover, .entete [aria-current="page"] { color: var(--craie); }
.entete [aria-current="page"] { text-decoration: underline; text-decoration-color: var(--ocre); text-underline-offset: .45em; }
.entete .langue { font-size: .85rem; }

@media (max-width: 52rem) {
  .entete { flex-wrap: wrap; padding-bottom: .75rem; }
  .entete .nom { flex: 1; }
  .entete nav {
    order: 3; flex-basis: 100%;
    overflow-x: auto; scrollbar-width: none;
    margin: 0 -1.25rem; padding: .15rem 1.25rem .1rem;
  }
  .entete nav::-webkit-scrollbar { display: none; }
  .entete ul { gap: 1.25rem; white-space: nowrap; }
}

/* ---------- contenu ---------- */
main { display: block; padding: 0 var(--marge) 6rem; }
main p, main > ul, main > ol, main details, main figure { max-width: var(--mesure); }

h1 {
  font-family: var(--titre); font-weight: 600;
  font-size: clamp(2.6rem, 6.5vw, 4.75rem);
  line-height: 1; letter-spacing: -.022em;
  margin: 4.5rem 0 1.25rem; max-width: 18ch;
  text-wrap: balance;
}
h2 {
  font-family: var(--titre); font-weight: 500;
  font-size: 1.4rem; line-height: 1.25; letter-spacing: -.005em;
  margin: 3.5rem 0 1rem;
}
h3 { font-family: var(--titre); font-weight: 500; font-size: 1.15rem; line-height: 1.3; margin: 0; }
cite { font-style: italic; }
main ol, main ul { padding-left: 1.25rem; }
main li { margin: .2rem 0; }

.annee {
  font-family: var(--titre); font-size: .92rem; letter-spacing: .01em;
  color: var(--cendre); margin: 0 0 1.75rem;
  font-variant-numeric: tabular-nums;
}
.duree { color: var(--fumee); font-family: var(--titre); font-size: .85em; font-variant-numeric: tabular-nums; margin-left: .5rem; }
.etiquettes {
  list-style: none; padding: 0; margin: 1.25rem 0 0;
  display: flex; flex-wrap: wrap;
  font-family: var(--titre); font-size: .85rem; color: var(--fumee);
}
main .etiquettes { padding-left: 0; }
.etiquettes li { margin: 0; }
.etiquettes li + li::before { content: ", "; white-space: pre; }

mark {
  background: rgba(216, 166, 87, .9); color: var(--nuit);
  padding: .2em .3em .06em; border-radius: 2px;
  -webkit-box-decoration-break: clone; box-decoration-break: clone;
}

details { font-size: .95rem; color: var(--cendre); }
summary { cursor: pointer; font-family: var(--titre); font-size: .88rem; }
summary:hover { color: var(--craie); }

/* ---------- accueil ---------- */
.ouverture {
  min-height: min(78vh, 46rem);
  min-height: min(78svh, 46rem);
  display: flex; flex-direction: column; justify-content: flex-end;
  padding: 6rem 0 4.5rem;
}
.ouverture h1 {
  font-size: clamp(2.5rem, 8vw, 7.25rem);
  line-height: .95; letter-spacing: -.035em;
  margin: 0 0 1.75rem; max-width: none;
}
.ouverture h1 .ligne { display: block; white-space: nowrap; }
.ouverture p {
  font-style: italic; color: var(--cendre);
  font-size: clamp(1.2rem, 2.2vw, 1.55rem); line-height: 1.45;
  max-width: 32ch; margin: 0;
}
.ouverture p cite { font-style: normal; }
main > section + section { margin-top: 6rem; }
main > section > h2 { margin-top: 0; }

.chrono { list-style: none; margin: 0; padding: 0; max-width: none; border-top: 1px solid var(--filet); }
main .chrono { padding-left: 0; }
.chrono > li { margin: 0; border-bottom: 1px solid var(--filet); }
.rangee {
  display: grid; grid-template-columns: 7.5rem 7rem minmax(0, 1fr);
  gap: 0 2rem; align-items: center;
  padding: 1.5rem .75rem; margin: 0 -.75rem;
  text-decoration: none; border-radius: 4px;
  transition: background-color .4s;
}
.rangee:hover { color: inherit; background: rgba(232, 230, 225, .045); }
.rangee .quand {
  align-self: start; padding-top: .45rem;
  font-family: var(--titre); font-size: .95rem; color: var(--cendre);
  font-variant-numeric: tabular-nums;
}
.vignette {
  display: block; aspect-ratio: 1; overflow: hidden; border-radius: 3px;
  background: rgba(232, 230, 225, .04);
  outline: 1px solid var(--filet); outline-offset: -1px;
}
.vignette img {
  display: block; width: 100%; height: 100%; object-fit: cover;
  filter: saturate(.92);
  transition: transform .9s var(--doux), filter .6s;
}
.rangee:hover .vignette img { transform: scale(1.05); filter: saturate(1.1); }
.vignette.vide { display: grid; place-items: center; }
.disque {
  display: block; width: 46%; aspect-ratio: 1; border-radius: 50%;
  background: radial-gradient(circle, var(--ocre) 0 52%, rgba(216, 166, 87, 0) 72%);
  transition: transform .9s var(--doux);
}
.rangee:hover .disque { transform: scale(1.12); }
.rangee h3 {
  font-size: clamp(1.45rem, 2.6vw, 2.1rem); font-weight: 500;
  letter-spacing: -.012em; line-height: 1.12;
  transition: color .3s;
}
.rangee:hover h3 { color: var(--ocre); }
.rangee .resume { display: block; margin-top: .45rem; color: var(--cendre); max-width: 36rem; }
.rangee .etiq { display: block; margin-top: .55rem; font-family: var(--titre); font-size: .85rem; color: var(--fumee); }

@media (max-width: 40rem) {
  .rangee { grid-template-columns: 4.75rem minmax(0, 1fr); gap: .15rem 1.1rem; align-items: start; padding: 1.25rem .5rem; margin: 0 -.5rem; }
  .rangee .vignette { grid-column: 1; grid-row: 1 / span 2; }
  .rangee .quand { grid-column: 2; grid-row: 1; padding-top: 0; font-size: .85rem; }
  .rangee .quoi { grid-column: 2; grid-row: 2; }
}

.offres {
  list-style: none; margin: 0; padding: 0; max-width: none;
  display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 18rem), 1fr)); gap: 0 2.5rem;
}
main .offres { padding-left: 0; }
.offres > li { margin: 0; border-top: 1px solid var(--filet); }
.offres a { display: block; padding: 1.2rem 0 1.6rem; text-decoration: none; }
.offres a:hover { color: inherit; }
.offres h3 { font-size: 1.25rem; transition: color .3s; }
.offres a:hover h3 { color: var(--ocre); }
.offres .resume { display: block; margin-top: .35rem; color: var(--cendre); font-size: 1.02rem; line-height: 1.5; }

.courriel {
  font-family: var(--titre); font-weight: 500;
  font-size: clamp(1.6rem, 4.5vw, 3rem); letter-spacing: -.015em; line-height: 1.2;
  margin: 0; overflow-wrap: anywhere;
}

/* ---------- images ---------- */
figure { margin: 2rem 0; }
figure img {
  display: block; max-width: 100%; height: auto; border-radius: 4px;
  outline: 1px solid rgba(255, 255, 255, .1); outline-offset: -1px;
}
.portrait img { max-height: 34rem; width: auto; }
figcaption { margin-top: .6rem; font-family: var(--titre); font-size: .85rem; color: var(--cendre); }
.banniere { max-width: none; }
.banniere img { width: 100%; }

.sorties, .galerie, .realisations { list-style: none; padding: 0; margin: 1.5rem 0; max-width: none; display: grid; }
main .sorties, main .galerie, main .realisations { padding-left: 0; }
.sorties > li, .galerie > li, .realisations > li { margin: 0; }
.sorties { grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr)); gap: 2.25rem 1.75rem; }
.sorties img, .galerie img {
  display: block; width: 100%; height: auto; aspect-ratio: 1; object-fit: cover;
  border-radius: 4px; outline: 1px solid rgba(255, 255, 255, .1); outline-offset: -1px;
  transition: transform .8s var(--doux), box-shadow .8s var(--doux);
}
.sorties li:hover img, .galerie li:hover img { transform: translateY(-4px); box-shadow: 0 1.5rem 3rem -1.2rem rgba(0, 0, 0, .7); }
.sorties h2 { font-size: 1.2rem; margin: 1rem 0 .15rem; }
.sorties .annee { margin-bottom: .35rem; font-size: .85rem; }
.sorties ol { margin: .5rem 0 0; }

.galerie { grid-template-columns: repeat(auto-fill, minmax(10rem, 1fr)); gap: 1.1rem; }
.galerie a { display: block; text-decoration: none; font-family: var(--titre); font-size: .88rem; color: var(--cendre); }
.galerie a:hover { color: var(--craie); }
.galerie span { display: block; margin-top: .45rem; }

.realisations { grid-template-columns: repeat(auto-fill, minmax(16rem, 1fr)); gap: 2rem; }
.realisations img {
  display: block; width: 100%; aspect-ratio: 16 / 10; object-fit: cover; object-position: top left;
  border-radius: 4px; outline: 1px solid rgba(255, 255, 255, .1); outline-offset: -1px;
}
.realisations h3 { margin: .8rem 0 .15rem; }
.realisations h3 a { text-decoration: none; }
.realisations .annee { margin: 0 0 .3rem; font-size: .85rem; }
.realisations p { margin: 0; font-size: 1rem; line-height: 1.5; color: var(--cendre); }

/* ---------- pied ---------- */
footer {
  margin: 0 var(--marge); padding: 2rem 0 3rem;
  border-top: 1px solid var(--filet);
  font-family: var(--titre); font-size: .85rem; color: var(--cendre);
}
footer p { margin: 0; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: .01ms !important; animation: none !important; }
  .fond .calque, .fond .calque.on { transform: none; }
}
