/* =====================================================
   AUBIN GILLES — Premium dark theme
   ===================================================== */

:root {
  --bg:        #05060d;
  --bg-soft:   #0a0c18;
  --ink:       #f4f6ff;
  --ink-dim:   #aab1d4;
  --ink-faint: #6b7299;

  --blue:   #4f7cff;
  --violet: #9a6bff;
  --silver: #c9d2f0;
  --halo:   #6e8bff;

  --glass:        rgba(255, 255, 255, 0.045);
  --glass-border: rgba(255, 255, 255, 0.10);

  --grad-text: linear-gradient(120deg, #ffffff 0%, #c9d2f0 40%, #9a6bff 100%);
  --grad-btn:  linear-gradient(120deg, #4f7cff 0%, #9a6bff 100%);

  --shadow-soft: 0 30px 80px -30px rgba(79, 124, 255, 0.45);
  --ease: cubic-bezier(0.16, 1, 0.3, 1);

  --maxw: 1280px;
  --gut: clamp(1.25rem, 5vw, 5rem);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body {
  background: var(--bg);
  color: var(--ink);
  font-family: "Space Grotesk", system-ui, sans-serif;
  line-height: 1.6;
  overflow-x: hidden;
}
/* Hide the native cursor ONLY once main.js has activated the custom one
   (class added in JS). Pages without the custom cursor — e.g. legal pages —
   or any case where the script fails to load keep the normal OS cursor. */
body.has-custom-cursor { cursor: none; }

/* subtle moving aurora behind everything */
body::before {
  content: "";
  position: fixed;
  inset: -20% -20% auto -20%;
  height: 80vh;
  background:
    radial-gradient(60% 60% at 30% 20%, rgba(79,124,255,.14), transparent 60%),
    radial-gradient(50% 50% at 80% 30%, rgba(154,107,255,.12), transparent 60%);
  filter: blur(40px);
  z-index: -2;
  pointer-events: none;
  animation: aurora 22s ease-in-out infinite alternate;
}
@keyframes aurora {
  0%   { transform: translate3d(-4%, -2%, 0) scale(1); }
  100% { transform: translate3d(5%, 4%, 0) scale(1.15); }
}

@media (max-width: 860px) { body { cursor: auto; } }

a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
::selection { background: rgba(154,107,255,.4); color: #fff; }

/* ---------- Preloader ---------- */
.preloader {
  position: fixed; inset: 0; z-index: 999;
  display: grid; place-items: center;
  background: var(--bg);
  transition: opacity .8s var(--ease), visibility .8s;
  /* FILET DE SÉCURITÉ (CSS pur, sans JS) : le préchargeur se masque tout seul même si
     le WebGL ne s'initialise pas — ex. le moteur de rendu de Googlebot. Sinon le voile
     noir reste affiché au crawl et Google voit une page vide → page non indexée. */
  animation: preloaderSafety .6s var(--ease) 2.2s forwards;
}
.preloader.is-done { opacity: 0; visibility: hidden; }
@keyframes preloaderSafety { to { opacity: 0; visibility: hidden; } }
.preloader__inner { display: grid; justify-items: center; gap: 1.4rem; }
.preloader__moon {
  width: 70px; height: 70px; border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #fff, #aab1d4 45%, #2a2f55 100%);
  box-shadow: 0 0 60px rgba(110,139,255,.6);
  animation: floatY 3s ease-in-out infinite;
}
.preloader__brand {
  font-family: "Sora", sans-serif; letter-spacing: .5em;
  font-size: .8rem; color: var(--ink-dim); padding-left: .5em;
}
.preloader__bar {
  width: 180px; height: 2px; border-radius: 2px;
  background: rgba(255,255,255,.1); overflow: hidden;
}
.preloader__bar span {
  display: block; height: 100%; width: 0%;
  background: var(--grad-btn);
}
@keyframes floatY { 50% { transform: translateY(-12px); } }

/* ---------- Custom cursor ---------- */
.cursor, .cursor-dot {
  position: fixed; top: 0; left: 0; z-index: 1000;
  pointer-events: none; border-radius: 50%;
  transform: translate(-50%, -50%);
  mix-blend-mode: screen;
  opacity: 0; transition: opacity .35s var(--ease); /* hidden until the mouse first moves */
}
.cursor.is-visible, .cursor-dot.is-visible { opacity: 1; }
.cursor {
  width: 38px; height: 38px;
  border: 1px solid rgba(154,107,255,.6);
  transition: width .3s var(--ease), height .3s var(--ease), background .3s, border-color .3s, opacity .35s var(--ease);
}
.cursor-dot {
  width: 5px; height: 5px; background: var(--silver);
}
.cursor.is-active {
  width: 64px; height: 64px;
  background: rgba(79,124,255,.12);
  border-color: rgba(79,124,255,.8);
}
@media (max-width: 860px) { .cursor, .cursor-dot { display: none; } }

/* ---------- Scroll progress ---------- */
.scroll-progress {
  position: fixed; top: 0; left: 0; height: 2px; width: 0%;
  background: var(--grad-btn); z-index: 200;
  box-shadow: 0 0 12px var(--blue);
}

/* ---------- Nav ---------- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 150;
  display: flex; align-items: center; justify-content: space-between;
  padding: 1.5rem var(--gut);
  transition: padding .4s var(--ease), background .4s var(--ease), backdrop-filter .4s;
}
.nav.is-scrolled {
  padding: .9rem var(--gut);
  background: rgba(5,6,13,.6);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--glass-border);
}
.nav__logo {
  font-family: "Sora", sans-serif; font-weight: 700; font-size: 1.15rem;
  display: flex; align-items: center; gap: .55rem; letter-spacing: -.01em;
}
.nav__logo span { color: var(--ink-dim); font-weight: 300; }
.nav__logo-mark {
  width: 18px; height: 18px; border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #fff, #9a6bff 70%, #2a2f55);
  box-shadow: 0 0 16px rgba(154,107,255,.8);
}
.nav__right { display: flex; align-items: center; gap: 1.1rem; }
.nav__cta {
  font-size: .9rem; padding: .65rem 1.4rem; border-radius: 100px;
  border: 1px solid var(--glass-border); background: var(--glass);
  white-space: nowrap; /* le CTA reste toujours sur une seule ligne */
  transition: border-color .3s, box-shadow .3s, transform .3s;
}
.nav__cta:hover { border-color: rgba(154,107,255,.7); box-shadow: 0 0 24px rgba(154,107,255,.35); }
/* version du CTA placée dans le menu (pop-up) : visible seulement sur mobile */
.nav__cta--menu { display: none; }

/* Menu toggle button */
.nav__toggle {
  display: inline-flex; align-items: center; gap: .6rem;
  background: none; border: 0; cursor: pointer; padding: .4rem .2rem;
  color: var(--ink); font-family: "Space Grotesk", sans-serif; font-size: .9rem;
}
.nav__toggle-label { letter-spacing: .06em; }
.nav__toggle-icon { position: relative; width: 24px; height: 12px; }
.nav__toggle-icon i {
  position: absolute; left: 0; width: 100%; height: 1.6px; border-radius: 2px;
  background: var(--ink); transition: transform .4s var(--ease), top .4s var(--ease), bottom .4s var(--ease);
}
.nav__toggle-icon i:first-child { top: 2px; }
.nav__toggle-icon i:last-child { bottom: 2px; }
.nav.is-open .nav__toggle-icon i:first-child { top: 5px; transform: rotate(45deg); }
.nav.is-open .nav__toggle-icon i:last-child { bottom: 5px; transform: rotate(-45deg); }

/* Vertical dropdown menu — items stacked, anchored under the CTA */
.nav__menu {
  position: absolute; top: 100%; right: var(--gut);
  width: min(320px, calc(100vw - 2 * var(--gut)));
  display: grid; gap: .15rem;
  margin-top: .55rem; padding: .7rem;
  background: rgba(10, 12, 24, .72); backdrop-filter: blur(18px);
  border: 1px solid var(--glass-border); border-radius: 20px;
  box-shadow: 0 30px 70px -25px rgba(0,0,0,.7), var(--shadow-soft);
  transform-origin: top right; z-index: 160;
  opacity: 0; transform: translateY(-12px) scale(.96); pointer-events: none;
  transition: opacity .4s var(--ease), transform .4s var(--ease);
}
.nav__menu::before {
  content: ""; position: absolute; inset: 0; border-radius: 20px; padding: 1px;
  background: linear-gradient(140deg, rgba(154,107,255,.5), transparent 45%, rgba(79,124,255,.4));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude; pointer-events: none;
}
.nav.is-open .nav__menu { opacity: 1; transform: none; pointer-events: auto; }

.nav__item {
  display: flex; align-items: center; gap: .9rem;
  padding: .9rem 1rem; border-radius: 13px; color: var(--ink-dim);
  opacity: 0; transform: translateX(10px);
  transition: opacity .45s var(--ease), transform .45s var(--ease), background .3s, color .3s;
}
.nav.is-open .nav__item { opacity: 1; transform: none; }
.nav.is-open .nav__item:nth-child(1) { transition-delay: .06s; }
.nav.is-open .nav__item:nth-child(2) { transition-delay: .12s; }
.nav.is-open .nav__item:nth-child(3) { transition-delay: .18s; }
.nav.is-open .nav__item:nth-child(4) { transition-delay: .24s; }
.nav.is-open .nav__item:nth-child(5) { transition-delay: .30s; }
.nav__item:hover { background: rgba(255,255,255,.05); color: var(--ink); }
.nav__item-num {
  font-family: "Sora", sans-serif; font-size: .72rem; letter-spacing: .1em;
  color: var(--violet); width: 1.7em;
}
.nav__item-label { font-family: "Sora", sans-serif; font-weight: 600; font-size: 1.02rem; flex: 1; white-space: nowrap; }
.nav__item-arrow {
  color: var(--violet); opacity: 0; transform: translateX(-8px);
  transition: opacity .3s var(--ease), transform .3s var(--ease);
}
.nav__item:hover .nav__item-arrow { opacity: 1; transform: none; }

@media (max-width: 560px) {
  .nav__toggle-label { display: none; }
  .nav__right { gap: .7rem; }
  /* on bride la colonne du menu à la largeur du cadre (sinon elle s'élargit pour
     épouser le libellé le plus long et tout déborde). Le libellé long peut alors
     revenir à la ligne au lieu de pousser le cadre. */
  .nav__menu { grid-template-columns: minmax(0, 1fr); }
  .nav__item-label { white-space: normal; }
  /* sur mobile : le CTA quitte l'en-tête et descend dans le menu (sous le 5e point) */
  .nav__right .nav__cta { display: none; }
  .nav__cta--menu {
    display: block; width: 100%; text-align: center;
    margin-top: .45rem; padding: .9rem 1rem; font-size: .92rem;
    color: #fff; background: var(--grad-btn); border: 0;
    box-shadow: var(--shadow-soft);
  }
  .nav__cta--menu:hover { box-shadow: 0 18px 40px -14px rgba(154,107,255,.6); }
}

/* ---------- Buttons ---------- */
.btn {
  position: relative; display: inline-flex; align-items: center; justify-content: center;
  font-family: "Sora", sans-serif; font-weight: 600; font-size: .95rem;
  padding: 1rem 2rem; border-radius: 100px; overflow: hidden;
  transition: transform .4s var(--ease), box-shadow .4s var(--ease);
}
.btn span { position: relative; z-index: 2; }
.btn--full { width: 100%; }
.btn--primary { color: #fff; background: var(--grad-btn); box-shadow: var(--shadow-soft); }
.btn--primary::after {
  content: ""; position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(120deg, #9a6bff, #4f7cff);
  opacity: 0; transition: opacity .4s var(--ease);
}
.btn--primary:hover::after { opacity: 1; }
.btn--primary:hover { transform: translateY(-3px); box-shadow: 0 24px 60px -18px rgba(154,107,255,.7); }
.btn--ghost { color: var(--ink); border: 1px solid var(--glass-border); background: var(--glass); }
.btn--ghost:hover { border-color: rgba(255,255,255,.35); transform: translateY(-3px); }

/* =====================================================
   HERO
   ===================================================== */
/* Cinematic scroll stage — the page stays pinned while we dive into the moon */
.cinematic { position: relative; height: 200vh; }
.cinematic__stage {
  position: sticky; top: 0; height: 100svh;
  display: grid; place-items: center;
  overflow: hidden; isolation: isolate;
  /* fond porté par le calque global .sky-layer (la lune est un canvas fixe global
     derrière le contenu) → stage transparent pour le laisser passer */
  background: transparent;
}

/* ============ LUNE GLOBALE PERSISTANTE — calques de fond fixes ============ */
/* Ciel profond "universel" : nébuleuses + base sombre, peint en CSS (présent dès
   le 1er octet, avant tout WebGL). Calque fixe placé DERRIÈRE le canvas de la lune.
   --sky-neb (1 dans le hero → 0 plus bas) estompe les nébuleuses hors hero pour que
   les sections basses gardent leur fond sombre uni. */
.sky-layer {
  position: fixed; inset: 0; z-index: -3; pointer-events: none;
  --sky-neb: 1;
  background:
    radial-gradient(42% 48% at 16% 24%, rgba(154,107,255,calc(.13 * var(--sky-neb))), transparent 60%),
    radial-gradient(46% 46% at 84% 70%, rgba(124,92,240,calc(.11 * var(--sky-neb))), transparent 62%),
    radial-gradient(36% 38% at 72% 12%, rgba(154,107,255,calc(.07 * var(--sky-neb))), transparent 60%),
    radial-gradient(55% 50% at 50% 92%, rgba(79,124,255,calc(.06 * var(--sky-neb))), transparent 65%),
    radial-gradient(80% 70% at 50% 40%, rgba(10,8,26,calc(.6 * var(--sky-neb))), transparent 70%),
    var(--bg);
}
/* Canvas Three.js unique et persistant : fixe, plein écran, derrière le contenu
   (au-dessus de .sky-layer et de l'aurore body::before). Transparent : seule la
   lune (et le starfield dans le hero) est peinte. */
.moon-layer {
  position: fixed; inset: 0; width: 100%; height: 100%;
  z-index: -1; pointer-events: none;
}

/* ============ Transitions inter-pages (lune fil conducteur) ============ */
/* Proxy 2D : disque-lune affiché à l'arrivée, le temps que le WebGL s'initialise,
   pour que la lune ne clignote pas entre les pages. Calé sur l'ancre mémorisée. */
.moon-proxy {
  position: fixed; z-index: -1; pointer-events: none;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  opacity: 1; transition: opacity .25s ease;
  background: radial-gradient(circle at 36% 32%, #6e54ff 0%, #542AE6 42%, #3a1cb0 78%, #2a1486 100%);
  box-shadow: 0 0 70px 12px rgba(110, 84, 255, .5),
              inset -16px -20px 60px rgba(8, 6, 30, .6),
              inset 14px 16px 42px rgba(190, 170, 255, .32);
}
/* Sortie : tout le contenu s'efface (sauf le décor sky + la lune) pendant l'outro,
   ce qui met la lune en avant tandis qu'elle s'éloigne. */
body.is-leaving > *:not(.sky-layer):not(.moon-layer):not(.moon-proxy) {
  transition: opacity .5s ease, filter .5s ease;
  opacity: 0; filter: blur(3px); pointer-events: none;
}
/* Cinématique "retour à l'accueil" (clic logo) : tout le contenu de la page — les
   sections (main) et le pied de page —, sauf le hero/page de garde, se dissout
   proprement (fondu + flou + léger retrait) pendant que la lune revient en grand
   au centre. Le décor sky et la lune restent. Classe posée/retirée par moon.js. */
html.ag-homecoming main,
html.ag-homecoming .footer {
  transition: opacity .55s var(--ease), filter .55s var(--ease), transform .55s var(--ease);
  opacity: 0;
  filter: blur(8px);
  transform: scale(.99);
  pointer-events: none;
}
/* Arrivée par handoff : le contenu est masqué (le script inline pose .ag-arriving
   AVANT le 1er paint pour éviter tout flash), puis révélé en fondu (.ag-reveal,
   posé par moon.js dès la 1re frame de l'intro). Le décor sky reste constant. */
html.ag-arriving #preloader { display: none !important; }
html.ag-arriving body > *:not(.sky-layer):not(.moon-layer):not(.moon-proxy) { opacity: 0; }
html.ag-arriving.ag-reveal body > *:not(.sky-layer):not(.moon-layer):not(.moon-proxy) {
  opacity: 1; transition: opacity .6s ease;
}
@media (prefers-reduced-motion: reduce) {
  .moon-proxy { display: none; }
  body.is-leaving > *:not(.sky-layer):not(.moon-layer) { transition: none; opacity: 1; filter: none; }
  html.ag-arriving body > * { opacity: 1 !important; }
}
.cinematic.no-cine { height: 100svh; }
.cinematic__vignette {
  position: absolute; inset: 0; z-index: 4; pointer-events: none;
  background: radial-gradient(circle at 50% 46%, transparent 38%, rgba(5,6,13,.55) 100%);
}
.cinematic__flash {
  position: absolute; inset: 0; z-index: 6; pointer-events: none; opacity: 0;
  background: radial-gradient(circle at 50% 47%, #ffffff 0%, #e3e9ff 16%, #9a6bff 40%, rgba(79,124,255,0) 72%);
  mix-blend-mode: screen; will-change: opacity;
}

.hero {
  position: relative; min-height: 100svh;
  display: grid; place-items: center;
  overflow: hidden; isolation: isolate;
}
.hero__glow {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  width: 70vmin; height: 70vmin; border-radius: 50%; z-index: -1;
  background: radial-gradient(circle, rgba(150,112,255,.20), transparent 60%);
  filter: blur(30px); pointer-events: none;
  animation: pulseGlow 6s ease-in-out infinite;
}
@keyframes pulseGlow { 50% { opacity: .65; transform: translate(-50%,-50%) scale(1.08); } }

.hero__content { position: relative; z-index: 5; text-align: center; padding: 0 1.5rem; width: min(900px, 100%); will-change: transform, opacity, filter; }
.hero__eyebrow {
  font-size: clamp(.56rem, 1.6vw, .68rem); letter-spacing: .2em; text-transform: uppercase;
  white-space: nowrap; /* garde l'eyebrow sur une seule ligne, dans la lune */
  color: var(--ink-dim); margin-bottom: 1.8rem;
  padding-left: .2em; /* compensate trailing letter-spacing so text is truly centered */
}
.hero__title {
  font-family: "Sora", sans-serif; font-weight: 300;
  font-size: clamp(2.2rem, 8.2vw, 6.4rem); line-height: .92;
  letter-spacing: -.02em; margin-bottom: 1.6rem;
}
.hero__title .line { display: block; overflow: hidden; margin-bottom: -.12em; white-space: nowrap; }
/* "Aubin Gilles" : vrai dégradé mauve moderne, animé, qui varie sur tout le texte
   (y compris sur "Gilles" — pas de mauve plat) */
.hero__title .line:first-child > span {
  background: linear-gradient(115deg, #ffffff 0%, #ffffff 32%, #c9b6ff 52%, #7a49de 76%, #471a9e 100%);
  -webkit-background-clip: text; background-clip: text;
}
/* "Digital" : blanc plein (sans mauve), plus petit, police géométrique épaisse (cf. digital.png) */
.hero__title .line--digital {
  margin-top: .2em;
}
.hero__title .line--digital > span {
  background: none; -webkit-background-clip: border-box; background-clip: border-box;
  color: #ffffff; -webkit-text-fill-color: #ffffff;
  font-family: "Space Grotesk", sans-serif; font-weight: 400;
  font-size: .3em; letter-spacing: .3em; text-indent: .3em;
  padding-bottom: .1em;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}
.hero__title .line:last-child { margin-bottom: 0; }
.hero__title .line > span {
  display: block;
  padding-bottom: .16em; /* room for descenders (g, j…) so they aren't clipped by overflow */
  background: var(--grad-text); -webkit-background-clip: text; background-clip: text;
  color: transparent;
  transform: translateY(110%);
  animation: heroLineUp 1.1s var(--ease) forwards;
}
.hero__title .line:nth-child(2) > span { animation-delay: .12s; }
@keyframes heroLineUp { to { transform: translateY(0); } }

.hero__subtitle { font-size: clamp(1rem, 2.4vw, 1.35rem); color: var(--ink-dim); margin-bottom: 2.6rem; }
.hero__actions { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }

/* reveal-text used in hero (delayed fade-up) — only the inner span is inline-block,
   the container stays block so the subtitle and the buttons never sit side by side */
.reveal-text > span { display: inline-block; }
.hero__eyebrow, .hero__subtitle, .hero__actions {
  opacity: 0; transform: translateY(24px);
  animation: fadeUp 1s var(--ease) forwards;
}
.hero__eyebrow { animation-delay: .15s; }
.hero__subtitle { animation-delay: .55s; }
.hero__actions { animation-delay: .75s; }
@keyframes fadeUp { to { opacity: 1; transform: translateY(0); } }

/* Mobile : on agrandit un peu le bloc logo "Aubin Gilles" + "digital"
   ("digital" suit automatiquement car dimensionné en em relatif au titre). */
@media (max-width: 760px) {
  .hero__title { font-size: clamp(2.8rem, 11vw, 4.4rem); }
  /* sous-titre forcé sur une seule ligne : police réduite en vw pour tenir
     sur les petits écrans sans retour à la ligne. */
  .hero__subtitle { white-space: nowrap; font-size: clamp(0.6rem, 3.1vw, 1rem); }
}

/* Desktop : rythme vertical optimisé du hero (meilleure UX, respirations équilibrées) */
@media (min-width: 861px) {
  .hero__eyebrow  { margin-bottom: 2.4rem; }      /* le kicker respire avant le nom */
  .hero__title    { margin-bottom: 2.2rem; }      /* sépare le bloc logo du sous-titre */
  .hero__title .line--digital { margin-top: .1em; } /* "digital" collé au nom : un seul bloc logo */
  .hero__subtitle { margin-bottom: 3rem; }        /* belle respiration avant le bouton */
}

/* scroll indicator */
.scroll-indicator {
  position: absolute; bottom: 2.2rem; left: 0; right: 0;
  width: max-content; margin-inline: auto;   /* centrage robuste, non cassé par l'animation */
  display: grid; justify-items: center; gap: .8rem; z-index: 5;
  opacity: 0; animation: fadeUp 1s var(--ease) 1.1s forwards;
}
.scroll-indicator__text {
  font-size: .68rem; letter-spacing: .3em; text-transform: uppercase; color: var(--ink-faint);
  padding-left: .3em; /* compensate trailing letter-spacing for true centering */
}
.scroll-indicator__line { position: relative; width: 1px; height: 54px; background: rgba(255,255,255,.15); overflow: hidden; }
.scroll-indicator__line i {
  position: absolute; top: -50%; left: 0; width: 100%; height: 50%;
  background: linear-gradient(transparent, var(--blue));
  animation: scrollLine 2s var(--ease) infinite;
}
@keyframes scrollLine { 0% { top: -50%; } 100% { top: 100%; } }

/* =====================================================
   SECTIONS (shared)
   ===================================================== */
.section {
  position: relative;
  max-width: var(--maxw); margin: 0 auto;
  padding: clamp(6rem, 14vh, 11rem) var(--gut);
}
.section__head { max-width: 760px; margin-bottom: clamp(3rem, 7vw, 5rem); }
.section__index {
  display: inline-block; font-size: .78rem; letter-spacing: .25em; text-transform: uppercase;
  color: var(--violet); margin-bottom: 1.3rem;
}
.section__title {
  font-family: "Sora", sans-serif; font-weight: 700;
  font-size: clamp(2rem, 5.2vw, 3.8rem); line-height: 1.05; letter-spacing: -.02em;
}
.section__lead { margin-top: 1.4rem; font-size: clamp(1rem, 2vw, 1.18rem); color: var(--ink-dim); max-width: 640px; }

/* ---------- Reveal animations ---------- */
[data-reveal] { opacity: 0; transform: translateY(40px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
[data-reveal].is-in { opacity: 1; transform: none; }

[data-reveal-lines] .word {
  display: inline-block; overflow: hidden; vertical-align: top;
}
[data-reveal-lines] .word > span {
  display: inline-block; transform: translateY(110%); transition: transform .9s var(--ease);
}
[data-reveal-lines].is-in .word > span { transform: translateY(0); }

/* ---------- Moonlight title (Agence) — signature "wow" heading ---------- */
.moon-title {
  font-family: "Sora", sans-serif; font-weight: 300;
  font-size: clamp(2rem, 5.4vw, 3.9rem); line-height: 1.12; letter-spacing: -.02em;
}
.moon-title__line { display: block; overflow: hidden; padding-bottom: .1em; }
.moon-title__inner {
  display: block;
  opacity: 0; transform: translateY(115%); filter: blur(10px);
  transition: transform 1.1s var(--ease), opacity 1.1s var(--ease), filter 1.1s var(--ease);
  /* moonlight that glides across the letters */
  background: linear-gradient(100deg,
    #7e84ad 0%, #c8cdf0 22%, #ffffff 38%, #eef1ff 46%,
    #9fa5ce 62%, #ffffff 80%, #7e84ad 100%);
  background-size: 230% 100%;
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  animation: moonShimmer 8s linear infinite;
}
.moon-title__line:nth-child(2) .moon-title__inner { transition-delay: .14s; }
.moon-title.is-in .moon-title__inner { opacity: 1; transform: translateY(0); filter: blur(0); }
@keyframes moonShimmer { to { background-position: -230% 0; } }

/* "lumière" — a soft luminous accent */
.mt-glow {
  font-style: normal;
  -webkit-text-fill-color: #eef1ff; color: #eef1ff;
  text-shadow: 0 0 22px rgba(210,218,255,.45);
}
/* "lune" — the keyword: italic, solid white, glowing halo */
.mt-moon {
  font-style: italic; font-weight: 400;
  padding-right: .14em; margin-right: -.14em; /* la boîte couvre tout le "e" italique sans décaler le point */
  background: linear-gradient(120deg, #c4a7ff 0%, #9a6bff 48%, #7b4dff 100%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
}

/* single-line title (font scales with the viewport so it always fits) */
.moon-title--oneline { font-size: clamp(1rem, 3.8vw, 2.9rem); }
.moon-title--oneline .moon-title__inner { white-space: nowrap; padding-right: .06em; }

/* titre sur 2 lignes garanties : chaque ligne reste sur une seule ligne, taille qui s'adapte */
.moon-title--two { font-size: clamp(1rem, 3.8vw, 2.9rem); }
.moon-title--two .moon-title__inner { white-space: nowrap; padding-right: .06em; }

/* mots accentués "exigence" / "vision" : balayage mauve qui passe et revient + halo */
.mt-sweep {
  font-style: normal; font-weight: 400;
  background: linear-gradient(105deg,
    #8a5cff 0%, #8a5cff 26%, #d9c2ff 43%, #ffffff 50%, #d9c2ff 57%, #8a5cff 74%, #8a5cff 100%);
  background-size: 250% 100%;
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  filter: drop-shadow(0 0 14px rgba(154,107,255,.4));
  animation: mtSweep 3.6s ease-in-out infinite;
}
.mt-sweep:nth-of-type(2) { animation-delay: .5s; } /* léger décalage entre les 2 mots */
@keyframes mtSweep {
  0%   { background-position: 120% 0; }
  50%  { background-position: -20% 0; }
  100% { background-position: 120% 0; }
}

@media (prefers-reduced-motion: reduce) {
  .moon-title__inner { animation: none; opacity: 1; transform: none; filter: none; }
  .mt-sweep { animation: none; background-position: 0 0; }
}

/* ---------- Glass cards (agence) ---------- */
.agence__grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem;
  align-items: start; /* let cards keep their own height + vertical offset */
  margin-top: clamp(3rem, 7vw, 6rem); /* dégage la grille du bloc "collaboration" au-dessus (parallax) */
}
/* floating cards — 3 layers: parallax (JS, outer) · levitation (CSS, middle) · tilt (JS, inner) */
.float-card { margin-top: var(--mt, 0); will-change: transform; }
.float-card__bob {
  animation: levitate var(--dur, 6s) ease-in-out infinite;
  animation-delay: var(--delay, 0s);
  will-change: transform;
}
@keyframes levitate {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(var(--bob, -10px)); }
}
/* entrance = opacity-only fade (no translateY) so it never fights the float/parallax transforms */
.float-card .glass-card[data-reveal],
.float-card .glass-card[data-reveal].is-in { transform: none; }
.glass-card {
  position: relative; padding: 2.4rem 2rem;
  background: var(--glass); border: 1px solid var(--glass-border);
  border-radius: 22px; backdrop-filter: blur(12px);
  transition: transform .5s var(--ease), border-color .5s, box-shadow .5s;
  transform-style: preserve-3d;
}
.glass-card::before {
  content: ""; position: absolute; inset: 0; border-radius: 22px; padding: 1px;
  background: linear-gradient(140deg, rgba(154,107,255,.5), transparent 40%, rgba(79,124,255,.4));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  opacity: 0; transition: opacity .5s;
}
.glass-card:hover { border-color: transparent; box-shadow: var(--shadow-soft); }
.glass-card:hover::before { opacity: 1; }
.glass-card__num {
  font-family: "Sora", sans-serif; font-weight: 700; font-size: 2.6rem;
  background: var(--grad-text); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.glass-card h3 { font-family: "Sora", sans-serif; font-weight: 600; font-size: 1.05rem; margin: .8rem 0 .5rem; }
.glass-card p { color: var(--ink-dim); font-size: .95rem; }

/* ---------- À propos : texte + bloc collaboration ---------- */
.about__cols {
  display: grid; grid-template-columns: 1.5fr 1fr;
  gap: clamp(1.6rem, 4vw, 3.2rem); align-items: start;
}
.about__text .section__lead:first-child { margin-top: 0; }
.about__text .section__lead { max-width: 60ch; }
.collab-card {
  position: relative; padding: clamp(1.8rem, 3vw, 2.4rem);
  background: var(--glass); border: 1px solid var(--glass-border);
  border-radius: 22px; backdrop-filter: blur(12px);
  transition: transform .5s var(--ease), border-color .5s, box-shadow .5s;
}
.collab-card::before {
  content: ""; position: absolute; inset: 0; border-radius: 22px; padding: 1px;
  background: linear-gradient(140deg, rgba(154,107,255,.55), transparent 45%, rgba(79,124,255,.45));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  opacity: .9; transition: opacity .5s; pointer-events: none;
}
.collab-card:hover { border-color: transparent; box-shadow: var(--shadow-soft); transform: translateY(-4px); }
.collab-card:hover::before { opacity: 1; }
.collab-card__eyebrow {
  display: block; font-size: .72rem; letter-spacing: .2em; text-transform: uppercase;
  color: var(--violet); margin-bottom: .6rem;
}
.collab-card__name {
  font-family: "Sora", sans-serif; font-weight: 600; font-size: clamp(1.3rem, 2.4vw, 1.7rem);
  margin-bottom: .7rem;
}
.collab-card__desc { color: var(--ink-dim); font-size: .95rem; margin-bottom: 1.5rem; }
/* mini fiche d'infos (réutilise le style des lignes de la carte d'identité) */
.collab-card__info { margin-bottom: 1.5rem; }
.collab-card__logo { display: block; height: clamp(44px, 6vw, 56px); width: auto; margin-bottom: 1.1rem; object-fit: contain; }
.collab-card__actions { display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; }
.collab-card__actions .btn { flex: 1 1 auto; }
.collab-card__icon {
  flex: 0 0 auto; width: 48px; height: 48px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  color: var(--ink); border: 1px solid var(--glass-border); background: var(--glass);
  transition: transform .4s var(--ease), border-color .4s, box-shadow .4s, color .4s;
}
.collab-card__icon svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.collab-card__icon:hover { color: #fff; border-color: rgba(154,107,255,.5); box-shadow: 0 0 20px rgba(154,107,255,.35); transform: translateY(-3px); }
@media (max-width: 860px) {
  .about__cols { grid-template-columns: 1fr; }
}

/* ---------- À propos — 2 panneaux, transition horizontale instantanée ---------- */
.apropos { position: relative; }            /* hauteur totale (room de pin) fixée en JS */
.apropos__sticky {
  position: sticky; top: 0; height: 100svh; overflow: hidden; isolation: isolate;
  perspective: 1800px; perspective-origin: 50% 50%;
}
/* la piste = travelling caméra ; chaque panneau possède sa propre profondeur 3D */
.apropos__track {
  display: flex; width: 200vw; height: 100%;
  transform: translate3d(0, 0, 0);
  transform-style: preserve-3d;
  transition: transform 1.45s cubic-bezier(0.62, 0, 0.18, 1);
  will-change: transform;
}
.apropos.is-second .apropos__track { transform: translate3d(-100vw, 0, 0); }

.apropos__panel {
  flex: 0 0 100vw; height: 100%;
  display: flex; align-items: center;
  padding: clamp(5rem, 12vh, 8rem) var(--gut);
  transform-style: preserve-3d;
  transition: transform 1.45s cubic-bezier(0.62, 0, 0.18, 1);
}
/* profondeur : le panneau sortant pivote et recule, l'entrant revient à plat face caméra */
.apropos__panel--me     { transform: rotateY(0deg) translateZ(0); }
.apropos__panel--aurora { transform: rotateY(-12deg) translateZ(-220px); }
.apropos.is-second .apropos__panel--me     { transform: rotateY(12deg) translateZ(-220px); }
.apropos.is-second .apropos__panel--aurora { transform: rotateY(0deg) translateZ(0); }

.apropos__inner {
  width: 100%; max-width: var(--maxw); margin: 0 auto;
  display: grid; gap: clamp(2rem, 5vw, 4.2rem); align-items: center;
  transition: transform 1.5s cubic-bezier(0.62, 0, 0.18, 1),
              opacity 1.1s ease, filter 1.1s ease;
  will-change: transform, opacity, filter;
}
.apropos__inner--me     { grid-template-columns: 1.35fr .9fr; }
.apropos__inner--aurora { grid-template-columns: minmax(280px, .9fr) 1.1fr; }
/* rack-focus : le contenu sortant se défocalise et recule, l'entrant se révèle net */
.apropos__panel--aurora .apropos__inner { transform: translateX(60px) scale(.9); opacity: .25; filter: blur(7px); }
.apropos.is-second .apropos__panel--me .apropos__inner { transform: translateX(-70px) scale(.9); opacity: .2; filter: blur(7px); }
.apropos.is-second .apropos__panel--aurora .apropos__inner { transform: translateX(0) scale(1); opacity: 1; filter: blur(0); }

/* indicateur de progression (01 Profil → 02 Aurora) */
.apropos__pager {
  position: absolute; left: 50%; bottom: clamp(1.4rem, 4vh, 2.6rem); transform: translateX(-50%);
  z-index: 6; display: flex; align-items: center; gap: 1.1rem;
  font-family: "Sora", sans-serif; font-size: .72rem; letter-spacing: .14em; text-transform: uppercase;
}
.apropos__pager-step { display: inline-flex; align-items: center; gap: .5rem; color: var(--ink-faint); transition: color .6s var(--ease); }
.apropos__pager-step b { color: var(--violet); font-weight: 600; }
.apropos__pager-step[data-step="0"] { color: var(--ink); }
.apropos.is-second .apropos__pager-step[data-step="0"] { color: var(--ink-faint); }
.apropos.is-second .apropos__pager-step[data-step="1"] { color: var(--ink); }
.apropos__pager-bar { position: relative; width: 70px; height: 2px; border-radius: 2px; background: rgba(255,255,255,.12); overflow: hidden; }
.apropos__pager-bar i {
  position: absolute; inset: 0; width: 50%; border-radius: 2px;
  background: var(--grad-btn); box-shadow: 0 0 12px var(--blue);
  transition: transform 1.45s cubic-bezier(0.62, 0, 0.18, 1);
}
.apropos.is-second .apropos__pager-bar i { transform: translateX(100%); }

/* étape verrouillée : la scène reste figée plein écran pendant le franchissement */
.apropos.is-locked .apropos__sticky { position: fixed; inset: 0; height: 100svh; }
/* bascule instantanée (à l'entrée dans la section) sans animation */
.apropos.no-anim .apropos__track,
.apropos.no-anim .apropos__panel,
.apropos.no-anim .apropos__inner,
.apropos.no-anim .apropos__pager-bar i { transition: none !important; }

.apropos__lead-col .section__index,
.apropos__aurora-col .section__index { margin-bottom: 1.3rem; }
.apropos__cta { margin-top: 2.2rem; display: flex; align-items: center; gap: 1.4rem; flex-wrap: wrap; }

/* indice visuel du mouvement horizontal vers Aurora Synergy */
.apropos__hint {
  display: inline-flex; align-items: center; gap: .55rem;
  font-size: .74rem; letter-spacing: .18em; text-transform: uppercase; color: var(--ink-faint);
}
.apropos__hint-arrow { color: var(--violet); animation: hintSlide 1.8s var(--ease) infinite; }
@keyframes hintSlide {
  0%, 100% { transform: translateX(0); opacity: .6; }
  50%      { transform: translateX(7px); opacity: 1; }
}

/* carte "informations clés" (panneau 1) */
.id-card {
  position: relative; padding: clamp(1.6rem, 3vw, 2.3rem);
  background: var(--glass); border: 1px solid var(--glass-border);
  border-radius: 22px; backdrop-filter: blur(12px);
}
.id-card::before {
  content: ""; position: absolute; inset: 0; border-radius: 22px; padding: 1px;
  background: linear-gradient(140deg, rgba(154,107,255,.5), transparent 45%, rgba(79,124,255,.4));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude; opacity: .9; pointer-events: none;
}
.id-card__eyebrow {
  display: block; font-size: .72rem; letter-spacing: .2em; text-transform: uppercase;
  color: var(--violet); margin-bottom: 1rem;
}
/* bouton du CTA placé dans la carte d'identité : visible seulement sur mobile */
.id-card__cta { display: none; }
.id-card__row {
  display: flex; justify-content: space-between; align-items: baseline; gap: 1rem;
  padding: .85rem 0; border-top: 1px solid var(--glass-border);
}
.id-card__row:first-of-type { border-top: 0; padding-top: 0; }
.id-card__k { color: var(--ink-faint); font-size: .76rem; letter-spacing: .1em; text-transform: uppercase; }
.id-card__v { color: var(--ink); font-weight: 500; text-align: right; font-family: "Sora", sans-serif; white-space: nowrap; }

/* fallback (touch / reduced motion) → pas de pin : les 2 panneaux s'empilent */
.apropos.no-pin { height: auto !important; }
.apropos.no-pin .apropos__sticky { position: static; height: auto; overflow: visible; }
.apropos.no-pin .apropos__track {
  width: 100%; flex-direction: column; transform: none !important; transition: none;
}
.apropos.no-pin .apropos__panel { flex: none; width: 100%; padding: clamp(5rem, 12vh, 7rem) var(--gut); }
.apropos.no-pin .apropos__panel,
.apropos.no-pin .apropos__inner { transform: none !important; opacity: 1 !important; filter: none !important; }
.apropos.no-pin .apropos__pager { display: none; }

/* ---------- Mobile : carrousel à swipe horizontal (Aubin ⇄ Aurora) ----------
   Scroll natif horizontal avec accroche (scroll-snap) : aucun verrouillage, le
   scroll vertical de la page reste 100 % libre. */
.apropos.is-carousel {
  height: auto !important;
  margin-top: clamp(3rem, 9vh, 6rem);        /* la section commence plus bas (n'arrive plus trop tôt) */
  margin-bottom: clamp(5.5rem, 14vh, 9rem);  /* plus d'espace avant "Services" */
}
.apropos.is-carousel .apropos__sticky { position: static; height: auto; overflow: visible; }
.apropos.is-carousel .apropos__track {
  width: 100%; flex-direction: row;
  overflow-x: auto; overflow-y: hidden;
  scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch;
  transform: none !important; transition: none;
  scrollbar-width: none;                       /* Firefox */
}
.apropos.is-carousel .apropos__track::-webkit-scrollbar { display: none; }
.apropos.is-carousel .apropos__panel {
  flex: 0 0 100%; width: 100%; height: auto;
  scroll-snap-align: center;
  align-items: flex-start;                     /* contenu calé en haut (pas de gros vide au-dessus) */
  transform: none !important;                  /* on annule la rotation/profondeur 3D */
}
.apropos.is-carousel .apropos__inner {
  transform: none !important; opacity: 1 !important; filter: none !important;  /* les 2 panneaux nets et visibles */
}
/* indicateur du carrousel : points / pilules modernes (sous les panneaux, cliquables) */
.apropos.is-carousel .apropos__pager {
  position: static; transform: none; display: flex; align-items: center;
  justify-content: center; gap: .5rem; margin: 1.5rem auto 0;
}
.apropos.is-carousel .apropos__pager-bar { display: none; }
.apropos.is-carousel .apropos__pager-step {
  cursor: pointer; font-size: 0; padding: 0; width: 8px; height: 8px;
  border-radius: 50%; background: rgba(255,255,255,.22);
  transition: width .35s var(--ease), background .35s var(--ease), border-radius .35s var(--ease);
}
.apropos.is-carousel .apropos__pager-step b { display: none; }
/* pilule active : panneau 0 par défaut, panneau 1 quand is-second */
.apropos.is-carousel .apropos__pager-step[data-step="0"] { width: 22px; border-radius: 5px; background: var(--violet); }
.apropos.is-carousel.is-second .apropos__pager-step[data-step="0"] { width: 8px; border-radius: 50%; background: rgba(255,255,255,.22); }
.apropos.is-carousel.is-second .apropos__pager-step[data-step="1"] { width: 22px; border-radius: 5px; background: var(--violet); }
/* (l'indice "Aurora Synergy →" reste masqué sur mobile — voir le bloc @media) */

/* version courte du texte Aurora : visible uniquement sur mobile */
.apropos__txt-mob { display: none; }

@media (max-width: 860px) {
  /* minmax(0,1fr) bride la colonne à la largeur du panneau : sinon une valeur en
     nowrap (ex. "Créateur digital indépendant") élargit la carte, qui déborde alors
     sur le panneau voisin du carrousel. */
  .apropos__inner--me, .apropos__inner--aurora { grid-template-columns: minmax(0, 1fr); }
  .apropos__inner--aurora .collab-card { order: 2; }   /* texte d'abord, carte ensuite en mobile */

  /* bascule texte long (desktop) → texte court (mobile) */
  .apropos__txt-full { display: none; }
  .apropos__txt-mob  { display: block; }

  /* AÉRÉ : en carrousel, plus de contrainte de hauteur d'écran → on respire.
     Textes plus grands, plus d'espace, carte d'identité allégée. */
  .apropos__panel { padding: clamp(2.6rem, 7vh, 4rem) var(--gut); }
  .apropos__inner { gap: 1.7rem; }
  .apropos .moon-title { font-size: clamp(1.55rem, 7vw, 2.1rem); line-height: 1.12; }
  /* Aubin : "Créateur digital, basé à Namur." sur UNE seule ligne, le plus grand possible.
     Les 2 morceaux passent en inline-block (animation de révélation préservée). */
  .apropos__inner--me .moon-title--two { white-space: nowrap; font-size: clamp(1.25rem, 5.7vw, 1.75rem); }
  .apropos__inner--me .moon-title--two .moon-title__line { display: inline-block; vertical-align: top; }
  .apropos__inner--me .moon-title--two .moon-title__line:first-child { margin-right: .3em; }
  /* Aurora : "La force d'un partenariat de confiance." sur UNE seule ligne aussi. */
  .apropos__inner--aurora .moon-title--two { white-space: nowrap; font-size: clamp(1rem, 4.3vw, 1.45rem); }
  .apropos__inner--aurora .moon-title--two .moon-title__line { display: inline-block; vertical-align: top; }
  .apropos__inner--aurora .moon-title--two .moon-title__line:first-child { margin-right: .3em; }
  .apropos .section__lead { font-size: 1rem; line-height: 1.62; margin-top: 1rem; }
  .apropos__lead-col .section__index,
  .apropos__aurora-col .section__index { margin-bottom: 1rem; }
  .apropos__cta { margin-top: 1.4rem; gap: 1rem; }
  .apropos__hint { display: none; }                 /* indice "Aurora →" inutile au toucher */
  /* le bouton "Travaillons ensemble" descend DANS la carte d'identité, en bas, pleine largeur */
  .apropos__inner--me .apropos__cta { display: none; }
  .id-card__cta { display: flex; width: 100%; margin-top: 1.5rem; padding: .95rem 1rem; }
  /* cartes raffinées : coins doux, eyebrow discret, lignes lisibles, valeurs qui rentrent */
  .id-card, .collab-card { padding: 1.4rem 1.35rem; border-radius: 20px; }
  .id-card__eyebrow, .collab-card__eyebrow {
    font-size: .6rem; letter-spacing: .24em; color: var(--ink-faint); margin-bottom: 1.05rem;
  }
  .id-card__row { padding: .64rem 0; gap: .8rem; border-top-color: rgba(255,255,255,.07); }
  .id-card__k { font-size: .63rem; letter-spacing: .08em; }
  /* la valeur tient sur une ligne sur les écrans normaux ; peut revenir à la ligne
     sur les très petits écrans au lieu de déborder. */
  .id-card__v { font-size: .88rem; white-space: normal; }
  .collab-card__logo { height: 40px; margin-bottom: .85rem; }
  .collab-card__name { margin-bottom: .55rem; font-size: 1.25rem; }
  .collab-card__desc { display: none; }             /* doublon avec le texte court : masqué sur mobile */
  .collab-card__info { margin-bottom: .95rem; }
}

/* ---------- Services — pinned horizontal scroll ---------- */
.hscroll { position: relative; }                 /* tall wrapper; total height set in JS */
.hscroll__stage {
  position: sticky; top: 0; height: 100svh; overflow: hidden;
  display: flex; flex-direction: column; justify-content: center; gap: clamp(1.8rem, 5vh, 3.4rem);
}
.hscroll__head { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 var(--gut); }
.hscroll__bar {
  margin-top: 1.6rem; width: min(280px, 60vw); height: 2px; border-radius: 2px;
  background: rgba(255,255,255,.1); overflow: hidden;
}
.hscroll__bar span { display: block; height: 100%; width: 0%; background: var(--grad-btn); box-shadow: 0 0 12px var(--blue); transition: width .1s linear; }
.hscroll__viewport { width: 100%; overflow: hidden; }
.hscroll__track {
  display: flex; align-items: stretch; gap: 1.6rem; width: max-content; will-change: transform;
  padding-right: var(--gut);
  /* le 1er bloc s'aligne sur la marge du conteneur (max-width) comme les autres sections */
  padding-left: max(var(--gut), calc((100vw - var(--maxw)) / 2 + var(--gut)));
}

/* fallback (reduced motion / no JS) → native horizontal swipe, no pinning */
.hscroll.no-pin { height: auto !important; }
.hscroll.no-pin .hscroll__stage { position: static; height: auto; padding: clamp(6rem,14vh,11rem) 0; }
.hscroll.no-pin .hscroll__viewport { overflow-x: auto; scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch; }

.service {
  position: relative; flex: 0 0 auto; width: clamp(280px, 33vw, 420px);
  padding: 2.6rem; border-radius: 22px; overflow: hidden; scroll-snap-align: center;
  background: linear-gradient(160deg, rgba(255,255,255,.05), rgba(255,255,255,.015));
  border: 1px solid var(--glass-border);
  transition: transform .5s var(--ease), box-shadow .5s;
  transform-style: preserve-3d;
}
.service__num {
  position: absolute; top: 1.7rem; right: 1.9rem; z-index: 2;
  font-family: "Sora", sans-serif; font-size: .8rem; letter-spacing: .15em; color: var(--violet); opacity: .85;
}
.service::after {
  content: ""; position: absolute; inset: 0; opacity: 0; transition: opacity .5s;
  background: radial-gradient(60% 80% at 80% 0%, rgba(154,107,255,.16), transparent 60%);
}
.service:hover { box-shadow: var(--shadow-soft); }
.service:hover::after { opacity: 1; }
.service__icon {
  width: 64px; height: 64px; margin-bottom: 1.6rem; border-radius: 16px;
  display: grid; place-items: center;
  background: var(--glass); border: 1px solid var(--glass-border); color: var(--silver);
  transition: transform .5s var(--ease), color .5s, box-shadow .5s;
}
.service__icon svg { width: 30px; height: 30px; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.service:hover .service__icon { transform: translateY(-6px) rotate(-4deg); color: #fff; box-shadow: 0 0 30px rgba(154,107,255,.5); }
.service h3 { font-family: "Sora", sans-serif; font-weight: 600; font-size: 1.4rem; margin-bottom: .6rem; }
.service p { color: var(--ink-dim); max-width: 42ch; }
.service__line { display: block; height: 1px; width: 0; margin-top: 1.6rem; background: var(--grad-btn); transition: width .6s var(--ease); }
.service:hover .service__line { width: 100%; }

/* Mobile : cartes à hauteur NATURELLE (on supprime l'étirement à la plus haute,
   d'où le vide sous le texte) + compactage pour qu'elles tiennent dans l'écran
   (le bas n'est plus coupé). */
@media (max-width: 860px) {
  .hscroll__track { align-items: start; }
  .service { padding: 1.8rem; }
  .service__icon { width: 50px; height: 50px; margin-bottom: 1rem; border-radius: 13px; }
  .service__icon svg { width: 25px; height: 25px; }
  .service h3 { font-size: 1.18rem; margin-bottom: .45rem; }
  .service p { font-size: .92rem; }
  .service__num { top: 1.4rem; right: 1.5rem; }
  .service__line { margin-top: 1.1rem; }
}

/* ---------- Works ---------- */
/* remonte très légèrement la section "Solutions" (écart un peu trop grand au-dessus) */
.works { padding-top: clamp(4.5rem, 11vh, 8.5rem); }
.works__grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.5rem; }
.work {
  position: relative; border-radius: 22px; overflow: hidden;
  border: 1px solid var(--glass-border); aspect-ratio: 16/11;
  transition: transform .6s var(--ease), box-shadow .6s, border-color .6s;
  transform-style: preserve-3d;
  /* couleur d'accent du survol (personnalisable par solution depuis le CRM) — bleu par défaut */
  --work-accent: 79, 124, 255;
}
.work:hover {
  box-shadow: 0 30px 80px -30px rgba(var(--work-accent), .45);
  border-color: rgba(var(--work-accent), .45);
}
.work__media { position: absolute; inset: 0; transition: transform 1s var(--ease); }
.work:hover .work__media { transform: scale(1.08); }
.work__media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(5,6,13,.85), transparent 60%); }
.work__media--1 { background: linear-gradient(135deg, #1b2b6b, #4f7cff 60%, #9a6bff); }
.work__media--2 { background: linear-gradient(135deg, #2a1b5e, #9a6bff 60%, #4f7cff); }
.work__media--3 { background: linear-gradient(135deg, #3a1b4e, #c06bff 55%, #4f7cff); }
.work__media--4 { background: linear-gradient(135deg, #0e2350, #4f7cff 60%, #6ee0ff); }
.work__info {
  position: absolute; inset: auto 0 0 0; z-index: 2;
  display: flex; align-items: flex-end; justify-content: space-between;
  padding: 1.8rem 2rem; gap: 1rem;
}
.work__text { display: flex; flex-direction: column; min-width: 0; }
.work__info h3 { font-family: "Sora", sans-serif; font-weight: 600; font-size: clamp(1.15rem, 2.6vw, 1.5rem); white-space: nowrap; }
.work__tag { display: block; order: 2; margin-top: .45rem; font-size: .72rem; letter-spacing: .2em; text-transform: uppercase; color: var(--silver); white-space: nowrap; }
.work__arrow { font-size: 1.6rem; transition: transform .5s var(--ease); }
.work:hover .work__arrow { transform: translate(6px, -6px); }

/* ---------- Why ---------- */
.why__grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0; }
.why__item {
  padding: 2.6rem 2rem; border-top: 1px solid var(--glass-border);
  transition: background .5s;
}
.why__item:nth-child(odd) { border-right: 1px solid var(--glass-border); }
.why__item:hover { background: rgba(255,255,255,.02); }
.why__num { font-family: "Sora", sans-serif; font-size: .9rem; color: var(--violet); letter-spacing: .15em; }
.why__item h3 { font-family: "Sora", sans-serif; font-weight: 600; font-size: clamp(1.4rem, 3vw, 2rem); margin: .8rem 0 .7rem; }
.why__item p { color: var(--ink-dim); max-width: 46ch; }

/* ---------- Contact ---------- */
.contact { position: relative; }
.contact__glow {
  position: absolute; left: 50%; top: 30%; transform: translateX(-50%);
  width: 80vmin; height: 50vmin; border-radius: 50%; z-index: -1;
  background: radial-gradient(circle, rgba(120,100,255,.16), transparent 65%); filter: blur(50px);
}
.contact__inner { display: grid; grid-template-columns: .85fr 1.15fr; gap: clamp(2.5rem, 6vw, 5.5rem); align-items: start; }

/* availability badge */
.contact__badge {
  display: inline-flex; align-items: center; gap: .6rem; margin-top: 2rem;
  padding: .55rem 1rem; border-radius: 100px;
  border: 1px solid var(--glass-border); background: var(--glass);
  font-size: .82rem; color: var(--ink-dim);
}
.contact__badge-dot {
  width: 8px; height: 8px; border-radius: 50%; background: #57e9a3;
  box-shadow: 0 0 0 0 rgba(87,233,163,.6); animation: pulseDot 2.4s ease-out infinite;
}
@keyframes pulseDot {
  0% { box-shadow: 0 0 0 0 rgba(87,233,163,.55); }
  70% { box-shadow: 0 0 0 9px rgba(87,233,163,0); }
  100% { box-shadow: 0 0 0 0 rgba(87,233,163,0); }
}

.contact__meta { list-style: none; margin-top: 2.5rem; display: grid; gap: 1.3rem; }
.contact__meta li { display: grid; gap: .25rem; padding-left: 1rem; border-left: 1px solid var(--glass-border); }
.contact__meta span { font-size: .72rem; letter-spacing: .2em; text-transform: uppercase; color: var(--ink-faint); }
.contact__meta a { transition: color .3s; }
.contact__meta a:hover { color: var(--violet); }

/* the form card */
.contact__form {
  position: relative; isolation: isolate;
  background: linear-gradient(165deg, rgba(255,255,255,.05), rgba(255,255,255,.015));
  border: 1px solid var(--glass-border);
  border-radius: 26px; padding: clamp(1.8rem, 4vw, 3rem); backdrop-filter: blur(16px);
  display: grid; gap: 1.7rem; overflow: hidden;
}
/* animated gradient border */
.contact__form::before {
  content: ""; position: absolute; inset: 0; border-radius: 26px; padding: 1px; z-index: 0;
  background: linear-gradient(140deg, rgba(154,107,255,.55), transparent 40%, rgba(79,124,255,.45));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude; pointer-events: none;
}
/* cursor-following spotlight */
.contact__card-glow {
  position: absolute; inset: 0; z-index: -1; pointer-events: none; opacity: 0;
  background: radial-gradient(220px circle at var(--mx, 50%) var(--my, 0%), rgba(154,107,255,.18), transparent 70%);
  transition: opacity .4s var(--ease);
}
.contact__form:hover .contact__card-glow { opacity: 1; }
.contact__form > * { position: relative; z-index: 1; }

/* selectable chips (project type / budget) */
.form-block { border: 0; padding: 0; margin: 0; }
.form-block__label {
  display: block; width: 100%; margin-bottom: 1rem; padding: 0;
  font-size: .72rem; letter-spacing: .18em; text-transform: uppercase; color: var(--ink-faint);
}
.chips { display: flex; flex-wrap: wrap; gap: .6rem; }
.chip {
  cursor: pointer; font-family: inherit; font-size: .9rem; color: var(--ink-dim);
  padding: .6rem 1.1rem; border-radius: 100px;
  background: rgba(255,255,255,.04); border: 1px solid var(--glass-border);
  transition: color .3s, border-color .3s, background .3s, transform .3s var(--ease), box-shadow .3s;
}
.chip:hover { color: var(--ink); border-color: rgba(154,107,255,.5); transform: translateY(-2px); }
.chip.is-selected {
  color: #fff; border-color: transparent;
  background: var(--grad-btn); box-shadow: 0 10px 24px -10px rgba(154,107,255,.7);
}

/* fields */
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1.7rem; }
.field { position: relative; }
.field input, .field textarea {
  width: 100%; background: transparent; border: 0; border-bottom: 1px solid var(--glass-border);
  padding: .9rem 0 .6rem; color: var(--ink); font-family: inherit; font-size: 1rem; resize: none;
}
.field input:focus, .field textarea:focus { outline: none; }
.field label {
  position: absolute; left: 0; top: .9rem; color: var(--ink-faint);
  pointer-events: none; transition: .35s var(--ease);
}
.field input:focus + label, .field input:not(:placeholder-shown) + label,
.field textarea:focus + label, .field textarea:not(:placeholder-shown) + label {
  top: -.6rem; font-size: .72rem; letter-spacing: .12em; color: var(--violet);
}
.field__line { position: absolute; left: 0; bottom: 0; height: 1px; width: 0; background: var(--grad-btn); transition: width .4s var(--ease); }
.field input:focus ~ .field__line, .field textarea:focus ~ .field__line { width: 100%; }

/* date & time — label above (native pickers don't support floating labels), dark theme */
.field--static { display: flex; flex-direction: column; }
.field--static label {
  position: static; top: auto; pointer-events: auto;
  font-size: .72rem; letter-spacing: .12em; text-transform: uppercase;
  color: var(--ink-faint); margin-bottom: .5rem;
}
.field--static input { padding-top: .3rem; color-scheme: dark; }
.field--static input::-webkit-calendar-picker-indicator { filter: invert(.7); cursor: pointer; opacity: .8; }
.field--static input:hover::-webkit-calendar-picker-indicator { opacity: 1; }

/* menu déroulant heure — même look que les champs (fond sombre, flèche violette) */
.field--static select {
  width: 100%; background: transparent; border: 0; border-bottom: 1px solid var(--glass-border);
  padding: .9rem 1.6rem .6rem 0; color: var(--ink); font-family: inherit; font-size: 1rem;
  cursor: pointer; color-scheme: dark; -webkit-appearance: none; appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%239a6bff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right .1rem center; background-size: 1.05rem;
}
.field--static select:focus { outline: none; }
.field--static select:focus ~ .field__line { width: 100%; }
.field--static select option { background: #0a0a14; color: var(--ink); }

/* submit — text on the left, arrow in a circle on the right, shine sweep on hover */
.contact__consent {
  display: flex; align-items: flex-start; gap: .7rem; margin: .2rem 0 .4rem;
  cursor: pointer; user-select: none;
}
.contact__consent input { flex-shrink: 0; width: 18px; height: 18px; margin-top: .15rem; accent-color: var(--violet); cursor: pointer; }
.contact__consent-text { font-size: .82rem; line-height: 1.5; color: var(--ink-dim); }
.contact__consent-text a { color: var(--ink); text-decoration: underline; text-underline-offset: 2px; }
.contact__consent-text a:hover { color: var(--violet); }

.contact__send {
  position: relative; overflow: hidden; isolation: isolate; cursor: pointer;
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  width: 100%; margin-top: .3rem; padding: .5rem .5rem .5rem 1.7rem; border: 0;
  border-radius: 100px; background: var(--grad-btn); color: #fff;
  font-family: "Sora", sans-serif; font-weight: 600; font-size: 1rem;
  box-shadow: var(--shadow-soft);
  transition: transform .4s var(--ease), box-shadow .4s var(--ease);
}
.contact__send::after {
  content: ""; position: absolute; top: 0; left: -65%; width: 45%; height: 100%; z-index: 1;
  background: linear-gradient(100deg, transparent, rgba(255,255,255,.4), transparent);
  transform: skewX(-20deg); transition: left .65s var(--ease); pointer-events: none;
}
.contact__send:hover { transform: translateY(-3px); box-shadow: 0 24px 60px -18px rgba(154,107,255,.7); }
.contact__send:hover::after { left: 130%; }
.contact__send-text { position: relative; z-index: 2; }
.contact__send-icon {
  position: relative; z-index: 2; flex: none;
  width: 48px; height: 48px; border-radius: 50%; display: grid; place-items: center;
  background: rgba(255,255,255,.18);
  transition: background .4s var(--ease), transform .4s var(--ease);
}
.contact__send-icon svg { width: 20px; height: 20px; transition: transform .4s var(--ease); }
.contact__send:hover .contact__send-icon { background: rgba(255,255,255,.3); }
.contact__send:hover .contact__send-icon svg { transform: translateX(3px); }
.contact__send:active { transform: translateY(-1px) scale(.99); }
.contact__status { font-size: .9rem; color: var(--ink-dim); min-height: 1.2em; text-align: center; }
.contact__status.is-ok { color: #7ce4b0; }
.contact__status.is-err { color: #ff8a8a; }

@media (max-width: 560px) {
  .field-row { grid-template-columns: 1fr; }
}

/* ---------- Footer ---------- */
.footer { border-top: 1px solid var(--glass-border); padding: 4rem var(--gut) 2.5rem; max-width: var(--maxw); margin: 0 auto; }
.footer__top { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 1rem; padding-bottom: 2.5rem; }
.footer__logo { font-family: "Sora", sans-serif; font-weight: 700; font-size: 1.6rem; }
.footer__logo span { color: var(--ink-dim); font-weight: 300; }
.footer__top p { color: var(--ink-dim); }
.footer__bottom { display: flex; flex-direction: column; gap: 1.1rem; padding-top: 2rem; border-top: 1px solid var(--glass-border); color: var(--ink-faint); font-size: .88rem; }
.footer__nav { display: flex; flex-wrap: wrap; gap: 1.6rem; font-size: .95rem; }
.footer__nav a { color: var(--ink-dim); }
.footer__nav a:hover { color: var(--ink); }
.footer__legal { display: flex; flex-wrap: wrap; align-items: center; gap: .55rem .75rem; padding-top: 1rem; border-top: 1px solid var(--glass-border); font-size: .82rem; }
.footer__legal a:hover { color: var(--ink); }
.footer__legal a::before { content: "·"; margin-right: .75rem; color: var(--ink-faint); opacity: .55; }

/* =====================================================
   Responsive
   ===================================================== */
@media (max-width: 980px) {
  .agence__grid { grid-template-columns: 1fr; }
  .float-card { margin-top: 0; } /* no vertical stagger when cards are stacked */
  .services__list, .works__grid, .why__grid { grid-template-columns: 1fr; }
  .why__item:nth-child(odd) { border-right: 0; }
  .contact__inner { grid-template-columns: 1fr; }

  /* Solutions (mobile) : la flèche ↗ ne sert à rien → masquée ; et le tag
     (ex. "Solution de gestion · Esthéticienne/Beauté") garde UNE seule ligne mais
     avec une police réduite pour tenir sans être coupé. S'applique à TOUTES les
     solutions, présentes et futures. */
  .work__arrow { display: none; }
  .work__info { padding: 1.5rem 1.6rem; }
  .work__tag { white-space: nowrap; font-size: clamp(.46rem, 2.3vw, .64rem); letter-spacing: .05em; }

  /* "Mon approche" (mobile) : chaque bloc apparaît en glissant, alterné un coup
     depuis la gauche, un coup depuis la droite. overflow:clip évite que le décalage
     ne provoque un scroll horizontal pendant l'animation. */
  .why__grid { overflow: clip; }
  .why__item[data-reveal] { transform: translateX(-46px); }
  .why__item:nth-child(2n)[data-reveal] { transform: translateX(46px); }
  .why__item[data-reveal].is-in { transform: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
  [data-reveal], [data-reveal-lines] .word > span, .hero__title .line > span { opacity: 1 !important; transform: none !important; }
}
