:root {
  --bg: #000000;
  --fg: #ece4dc;
  --title: #f0e2d6;
  --muted: rgba(230, 230, 230, 0.5);
  --text: rgba(230, 230, 230, 0.72);
  --line: #2a2a2a;
  --radius: 16px;
  --gutter: clamp(16px, 3vw, 40px);
  --display: "Archivo", "Arial Black", sans-serif;
  --body: "Plus Jakarta Sans", system-ui, sans-serif;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--body);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
/* Images : pas de sélection, pas de glisser-déposer, pas de menu « Enregistrer » à l'appui long (iOS) */
img { -webkit-user-drag: none; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }

/* Titres en police large et grasse */
.name, .card-title, .player-title, .about .lead {
  font-family: var(--display);
  font-stretch: 125%;
  font-weight: 800;
  text-transform: uppercase;
  color: var(--title);
}

/* En-tête */
.site-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 32px var(--gutter) 40px;
}
.name { font-size: clamp(18px, 1.9vw, 26px); line-height: 1.05; } /* même police que l'accroche COLORIST, un peu plus grande */
.site-header nav { display: flex; gap: 24px; font-weight: 600; font-size: 14px; text-transform: uppercase; letter-spacing: 0.06em; }
.site-header nav a { color: var(--muted); transition: color .2s; white-space: nowrap; }
@media (max-width: 480px) {
  .name { font-size: 14px; white-space: nowrap; }
  .site-header nav { gap: 14px; font-size: 12px; }
}
.site-header nav a:hover,
.site-header nav a[aria-current="page"] { color: var(--fg); }

main { padding: 0 var(--gutter) 96px; }

/* Filtres */
.filters {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px 20px;
  margin: 0 0 32px;
  font-size: 14px;
  font-weight: 500;
}
.filter { color: var(--muted); transition: color .2s; }
.filter:hover, .filter.is-active { color: var(--fg); }

/* Grille de projets */
.grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 56px clamp(16px, 3vw, 32px);
}
@media (max-width: 700px) { .grid { grid-template-columns: 1fr; gap: 40px; } }

.card { display: block; width: 100%; text-align: right; }
.thumb {
  display: block;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: var(--radius);
  background: #111;
}
.thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .8s cubic-bezier(.2, .7, .2, 1);
}
.card:hover .thumb img { transform: scale(1.04); }
.card-title {
  display: block;
  margin-top: 18px;
  font-size: clamp(15px, 1.6vw, 22px);
  line-height: 1.15;
}
.card-category {
  display: block;
  margin-top: 4px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  color: var(--muted);
}

/* Lecteur */
.player {
  width: 100vw;
  height: 100vh;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 0;
  border: 0;
  background: rgba(0, 0, 0, 0.97);
  color: var(--fg);
  overflow-y: auto;
}
.player::backdrop { background: transparent; }
.player-inner {
  width: min(1400px, 100% - 2 * var(--gutter));
  margin: 72px auto 48px;
}
.video { display: grid; gap: 12px; }
.video.is-multi { grid-template-columns: 1fr 1fr; }
.frame { aspect-ratio: 16 / 9; background: #0a0a0a; border-radius: var(--radius); overflow: hidden; }
.frame { position: relative; }
.frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; display: block; }
.frame.is-cropped iframe {
  height: calc(100% * var(--stretch));
  top: 50%;
  transform: translateY(-50%);
}

/* Commandes du lecteur YouTube (remplacent celles de YouTube) */
.yt-ui { position: absolute; inset: 0; z-index: 1; }
.yt-hit { position: absolute; inset: 0; width: 100%; cursor: pointer; }
.yt-ui:not(.is-visible) .yt-hit { cursor: none; }
.yt-bar {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 28px 16px 12px;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.55));
  opacity: 0;
  visibility: hidden; /* une fois masquée, la barre ne recouvre plus du tout la vidéo */
  transition: opacity .35s, visibility 0s .35s;
  pointer-events: none;
}
.yt-ui.is-visible .yt-bar { opacity: 1; visibility: visible; transition: opacity .35s, visibility 0s; pointer-events: auto; }
.yt-btn { width: 26px; height: 26px; color: #fff; flex: none; }
.yt-btn svg { width: 100%; height: 100%; fill: currentColor; display: block; }
.yt-progress {
  flex: 1;
  height: 14px;
  display: flex;
  align-items: center;
  cursor: pointer;
  position: relative;
}
.yt-progress::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  height: 3px;
  border-radius: 3px;
  background: rgba(255, 255, 255, 0.3);
}
.yt-progress-fill {
  position: relative;
  height: 3px;
  width: 0;
  border-radius: 3px;
  background: var(--title);
}
.yt-time { font-size: 12px; font-weight: 500; color: #fff; font-variant-numeric: tabular-nums; flex: none; }
@media (max-width: 560px) { .yt-time { display: none; } }

/* Plein écran : le cadre remplit l'écran, sans recadrage */
.frame:fullscreen { border-radius: 0; aspect-ratio: auto; background: #000; }
.frame.is-cropped:fullscreen iframe { height: 100%; top: 0; transform: none; }

/* Plein écran de secours : la vidéo remplit la fenêtre */
.frame.is-fake-fullscreen {
  position: fixed;
  inset: 0;
  z-index: 100;
  width: 100vw;
  height: 100dvh;
  aspect-ratio: auto;
  border-radius: 0;
  background: #000;
}
.frame.is-cropped.is-fake-fullscreen iframe { height: 100%; top: 0; transform: none; }

/* Vignette affichée à la fin de la vidéo */
.end-cover {
  z-index: 2;
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: #000;
  cursor: pointer;
}
.end-cover img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: opacity .3s;
}
.end-cover:hover img { opacity: .75; }
.end-cover .replay {
  position: relative;
  padding: 10px 20px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  font-size: 14px;
  font-weight: 500;
  color: var(--fg);
}

/* Vidéos verticales : côte à côte, hauteur limitée à l'écran */
.video.is-vertical {
  grid-template-columns: repeat(auto-fit, min(100%, calc((100vh - 160px) * 9 / 16)));
  justify-content: center;
}
.video.is-vertical.is-multi {
  grid-template-columns: repeat(2, min(calc(50% - 6px), calc((100vh - 160px) * 9 / 16)));
}
.video.is-vertical .frame { aspect-ratio: 9 / 16; }

.player-title {
  margin: 20px 0 0;
  text-align: right;
  font-size: clamp(16px, 2vw, 26px);
  line-height: 1.15;
}
.stills {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin-top: 40px;
}
@media (max-width: 560px) { .stills { grid-template-columns: 1fr; } }
.stills img { width: 100%; display: block; border-radius: 12px; cursor: zoom-in; transition: opacity .2s; }
.stills img:hover { opacity: .85; }

/* Photo agrandie */
.lightbox {
  width: 100vw;
  height: 100vh;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 0;
  border: 0;
  background: #000;
  color: var(--fg);
  overflow: hidden;
}
.lightbox[open] { display: grid; place-items: center; }
.lightbox::backdrop { background: #000; }
.lightbox img {
  max-width: calc(100vw - 2 * var(--gutter) - 96px);
  max-height: calc(100vh - 120px);
  object-fit: contain;
  border-radius: 12px;
  user-select: none;
}
.lightbox .nav {
  position: fixed;
  top: 50%;
  transform: translateY(-50%);
  width: 48px;
  height: 72px;
  font-size: 44px;
  line-height: 1;
  color: var(--muted);
  transition: color .2s;
}
.lightbox .nav:hover { color: var(--fg); }
.lightbox .prev { left: calc(var(--gutter) - 8px); }
.lightbox .next { right: calc(var(--gutter) - 8px); }
.lightbox .counter {
  position: fixed;
  bottom: 20px;
  left: 0;
  right: 0;
  margin: 0;
  text-align: center;
  font-size: 13px;
  font-weight: 500;
  color: var(--muted);
}
@media (max-width: 700px) {
  .lightbox img { max-width: 100vw; border-radius: 0; }
  .lightbox .nav { display: none; }
}
.close {
  position: fixed;
  top: 16px;
  right: var(--gutter);
  font-size: 32px;
  line-height: 1;
  color: var(--muted);
}
.close:hover { color: var(--fg); }

/* Fin de page : texte + grande lueur qui déborde du bord gauche */
.outro {
  position: relative;
  margin: 160px 0 150px;
  padding-left: clamp(0px, 8vw, 150px);
}
.outro-text {
  position: relative;
  z-index: 2;
  margin: 0;
  max-width: 900px;
  font-family: var(--display);
  font-stretch: 125%;
  font-weight: 800;
  font-size: clamp(20px, 2.5vw, 36px);
  line-height: 1.15;
  color: var(--title);
}
.outro-text a { border-bottom: 2px solid currentColor; }
/* Lueur : un grand halo chaud et un noyau bleu, pilotés par la position de la souris (light.js).
   La zone .glow-area a une taille fixe et découpe la lueur : quelle que soit sa taille,
   elle ne change jamais les dimensions de la page. */
.glow-area {
  position: absolute;
  z-index: 1;
  left: calc(-1 * var(--gutter));
  top: -330px;
  bottom: -310px;
  width: 540px;
  overflow: hidden;
  pointer-events: none;
  mix-blend-mode: screen;
  -webkit-mask-image: linear-gradient(transparent, #000 15%, #000 50%, transparent);
  mask-image: linear-gradient(transparent, #000 15%, #000 50%, transparent);
}
.glow {
  position: absolute;
  left: 12px;
  top: calc(50% + 10px);
  width: 0;
  height: 0;
}
.glow span {
  position: absolute;
  border-radius: 50%;
  will-change: transform, opacity;
}
.glow-warm {
  width: 260px;
  height: 420px;
  left: -130px;
  top: -210px;
  background: linear-gradient(170deg, rgb(235, 160, 40) 5%, rgb(227, 45, 38) 40%, rgb(60, 90, 220) 78%, rgb(94, 207, 255) 95%);
  filter: blur(60px);
}
.glow-mid {
  width: 200px;
  height: 300px;
  left: -100px;
  top: -150px;
  background: radial-gradient(closest-side, rgb(255, 120, 150) 0%, rgb(210, 70, 170) 45%, rgb(130, 75, 225) 80%, rgba(100, 65, 225, .75) 92%, rgba(80, 60, 220, 0) 100%);
  filter: blur(40px);
}
.glow-cool {
  width: 110px;
  height: 150px;
  left: -55px;
  top: -75px;
  background: radial-gradient(closest-side, #f4faff 0%, #cfe8ff 25%, #7cc4ff 52%, rgba(40, 120, 240, .75) 78%, rgba(0, 109, 237, .35) 92%, rgba(0, 109, 237, 0) 100%);
  filter: blur(8px);
}
/* Aucun défilement latéral (iPhone) : la lueur ne peut jamais élargir la page */
html, body { overflow-x: clip; }
main { overflow-x: clip; }
@supports not (overflow: clip) { html, body, main { overflow-x: hidden; } }

/* Les lettres prennent la couleur inverse de la lueur quand elle passe dessus.
   light.js met à jour la position, la taille et la couleur du dégradé (--tint-*).
   Hors de la lueur, le texte garde sa couleur normale (currentColor). */
.tint-text {
  --tint-x: -999px;
  --tint-y: 50%;
  --tint-rx: 0px;
  --tint-ry: 0px;
  --tint-color: rgba(0, 0, 0, 0);
  background-image:
    radial-gradient(var(--tint-rx) var(--tint-ry) at var(--tint-x) var(--tint-y), var(--tint-color) 0%, transparent 100%),
    linear-gradient(currentColor, currentColor);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}


/* Empêche la page derrière le lecteur de défiler */
body:has(.player[open]) { overflow: hidden; }

/* À propos */
.about { padding-top: 16px; padding-bottom: 24px; }

/* Haut de page : texte à gauche, images qui défilent à droite */
.about-hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr);
  gap: clamp(32px, 7vw, 140px);
  align-items: center;
  max-width: 1840px; /* jusqu'à un écran de 1920 px, aligné sur l'en-tête ; au-delà, centré */
  margin-inline: auto;
  padding: clamp(8px, 4vh, 48px) 0 clamp(4px, 2vh, 26px);
}
/* Page About : grande zone pour que la lueur vive librement, sans bord visible.
   Le portrait passe par-dessus (z-index), la lueur reste donc toujours dessous. */
.about-hero .glow-area { width: 100vw; top: -520px; bottom: -380px; } /* toute la largeur de l'écran, sans jamais la dépasser */
.about-hero .glow { top: calc(50% - 110px); }
/* Pied de page : lien discret vers les mentions légales */
.site-footer {
  padding: 0 var(--gutter) 28px;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.site-footer a { color: rgba(230, 230, 230, 0.32); transition: color .2s; }
.site-footer a:hover, .site-footer a[aria-current="page"] { color: var(--muted); }

/* Page Mentions légales */
.legal { max-width: 720px; padding-top: 16px; }
.legal h1 {
  margin: 0 0 48px;
  font-family: var(--display);
  font-stretch: 125%;
  font-weight: 800;
  text-transform: uppercase;
  font-size: clamp(26px, 3.4vw, 44px);
  line-height: 1.05;
  color: var(--title);
}
.legal section { margin-bottom: 36px; }
.legal h2 {
  margin: 0 0 10px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}
.legal p { margin: 0 0 10px; font-size: 16px; line-height: 1.6; color: var(--text); }
.legal a { color: var(--fg); border-bottom: 1px solid var(--line); }
.legal a:hover { border-color: var(--fg); }

/* Page Work : la zone de la lueur s'arrête pile en bas de page (marge de .outro + marge de main) */
main:has(> .outro) { padding-bottom: 0; }
.outro { margin-bottom: 100px; }
/* la lueur continue derrière « Mentions légales » jusqu'en bas de page */
.outro .glow-area { bottom: -145px; }
.site-footer { position: relative; z-index: 2; }
.outro .glow { top: calc(50% + 42px); }
.about-text { position: relative; z-index: 2; }
.about .lead {
  font-size: clamp(28px, 3.6vw, 52px);
  line-height: 1.05;
  margin: 0 0 36px;
}
.about-text p:not(.lead) {
  margin: 0 0 20px;
  font-weight: 700; /* l'effet de couleur de la lueur affine le rendu : 700 donne la présence d'un 600 */
  color: rgba(236, 228, 220, 0.86); /* plus présent que le gris du texte courant */
  text-align: justify;
  hyphens: auto;
  font-size: clamp(18px, 1.55vw, 23px);
  line-height: 1.55;
}
.about-text p.about-motto {
  margin-top: 40px;
  font-family: var(--display);
  font-stretch: 125%;
  font-weight: 800;
  font-size: clamp(20px, 2.5vw, 36px); /* même taille que la phrase de la page Work */
  line-height: 1.15;
  color: var(--title);
}

.about-reel {
  position: relative;
  margin: 0;
  aspect-ratio: 16 / 10;
  border-radius: var(--radius);
  overflow: hidden;
  background: #0a0a0a;
}
.about-reel img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transform: scale(1.06);
  transition: opacity 1.4s ease, transform 6s ease-out;
}
.about-reel img.is-active { opacity: 1; transform: scale(1); }

/* Portrait */
.about-portrait {
  position: relative;
  z-index: 3; /* toujours au-dessus de la lueur */
  margin: 0;
  justify-self: end;
  width: 100%;
}
.about-portrait img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 5;
  max-height: 86vh;
  object-fit: cover;
  object-position: 60% 30%;
  border-radius: var(--radius); /* sans fondu : coins arrondis comme les vignettes */
}

/* Petits intitulés */
.about-label {
  margin: 0 0 20px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}


/* Contact */
.about-contact { margin: 0 0 40px; }
.about-link {
  display: block;
  width: fit-content;
  font-family: var(--display);
  font-stretch: 125%;
  font-weight: 800;
  font-size: clamp(22px, 3.4vw, 48px);
  line-height: 1.2;
  color: var(--title);
  background: linear-gradient(currentColor, currentColor) 0 100% / 0 2px no-repeat;
  transition: background-size .4s ease;
}
.about-link:hover { background-size: 100% 2px; }

/* E-mail / téléphone : l'intitulé laisse place à la vraie valeur au survol */
.js-reveal { display: grid; }
.js-reveal .reveal-label,
.js-reveal .reveal-value {
  grid-area: 1 / 1;
  transition: opacity .35s ease, transform .45s cubic-bezier(.2, .7, .2, 1), filter .35s ease;
}
.js-reveal .reveal-value { opacity: 0; transform: translateY(35%); filter: blur(6px); white-space: nowrap; }
.js-reveal.is-revealed .reveal-label { opacity: 0; transform: translateY(-35%); filter: blur(6px); }
.js-reveal.is-revealed .reveal-value { opacity: 1; transform: none; filter: none; }

@media (max-width: 860px) {
  .about-hero { grid-template-columns: 1fr; }
  .about-portrait { order: -1; justify-self: center; max-width: 320px; margin-bottom: -10px; }
  .about-portrait img { max-height: 50vh; }
  .about-text p:not(.lead) { -webkit-hyphens: auto; hyphens: auto; word-spacing: -0.02em; } /* justifié aussi sur téléphone, avec césure pour éviter les trous */
  .about-text p.about-motto { text-align: left; -webkit-hyphens: manual; hyphens: manual; } /* devise : ni justifiée ni coupée */
  .about { overflow: clip; padding-top: 0; margin-top: -20px; } /* page plus courte en bas ; portrait remonté : même espace au-dessus et en dessous */
  .about-hero { padding-top: 0; }
  .about-hero .glow { top: calc(520px + min(397px, 50vh) + 50px); } /* à hauteur de l'accroche, sous le portrait */
  .about-link { font-size: clamp(18px, 6vw, 30px); }
  .js-reveal .reveal-value { white-space: normal; word-break: break-all; }
}
