/* Technologies Salim — feuille de style unique
   Palette et typographie conformes à charte-de-marque.md (2026-08-02).
   Aucune couleur hors charte : l'ambition passe par l'exécution. */

/* ---------- Polices autohébergées ----------
   Fichiers VARIABLES de Google Fonts (une même woff2 couvre plusieurs
   graisses), servis depuis notre origine : aucune adresse IP de visiteur
   n'atteint Google (Loi 25), la CSP reste à « 'self' », et on économise
   une négociation de connexion tierce dans le chemin critique de rendu.
   Les fichiers -latin-ext ne sont téléchargés par le navigateur que si un
   caractère hors du bloc latin de base apparaît (« œ », par exemple). */
@font-face {
  font-family: 'Space Grotesk';
  font-style: normal;
  font-weight: 500 700;
  font-display: swap;
  src: url('/assets/fonts/space-grotesk-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Space Grotesk';
  font-style: normal;
  font-weight: 500 700;
  font-display: swap;
  src: url('/assets/fonts/space-grotesk-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400 500;
  font-display: swap;
  src: url('/assets/fonts/inter-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400 500;
  font-display: swap;
  src: url('/assets/fonts/inter-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  --bg-void: #0D1021;
  --surface-card: #171B33;
  --accent-blue: #5B6EF5;
  --accent-violet: #8873E8;
  --text-primary: #F0EEEA;
  --text-muted: #8890B0;
  --border-soft: rgba(255, 255, 255, 0.08);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  background: var(--bg-void);
  color: var(--text-primary);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* Marges latérales en propriétés longues : la raccourcie `padding` remettait
   à zéro le padding vertical des sections qui portent aussi .container
   (et inversement, .hero écrasait les marges latérales). */
.container {
  max-width: 1080px;
  margin: 0 auto;
  padding-left: 24px;
  padding-right: 24px;
}

/* Accessibilité — focus toujours visible au clavier */
a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--accent-violet);
  outline-offset: 3px;
  border-radius: 4px;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 8px;
  background: var(--surface-card);
  color: var(--text-primary);
  padding: 12px 20px;
  border-radius: 8px;
  border: 1px solid var(--border-soft);
  z-index: 100;
  text-decoration: none;
  font-size: 14px;
}
.skip-link:focus { left: 24px; }

/* ---------- Révélation au défilement ---------- */
/* Masqué UNIQUEMENT quand le JS a confirmé pouvoir révéler. */
.js-reveal [data-reveal] {
  opacity: 0;
  transform: translateY(20px);
}
.js-reveal [data-reveal].is-revealed {
  opacity: 1;
  transform: none;
  transition: opacity 0.7s var(--ease-out), transform 0.7s var(--ease-out);
}

/* ---------- Navigation ---------- */
nav.site-nav {
  position: sticky;
  top: 0;
  z-index: 10;
  /* Pas de backdrop-filter : sur une machine chargée, le flou d'arrière-plan
     d'une barre collante est recalculé à chaque image pendant le défilement
     et suffit à figer le rendu. Un fond opaque donne le même résultat visuel
     sur une page sombre, pour zéro coût. */
  background: rgba(13, 16, 33, 0.86);
  border-bottom: 1px solid transparent;
  transition: background 0.3s ease, border-color 0.3s ease;
}
nav.site-nav.is-scrolled {
  background: #0F1226;
  border-bottom-color: var(--border-soft);
}
nav.site-nav .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}
.nav-logo {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  font-size: 18px;
  color: var(--text-primary);
  text-decoration: none;
}
.nav-links { display: flex; gap: 32px; list-style: none; }
.nav-links a {
  position: relative;
  color: var(--text-muted);
  text-decoration: none;
  font-size: 14px;
  transition: color 0.2s;
}
.nav-links a::after {
  content: '';
  position: absolute;
  left: 0; bottom: -5px;
  width: 100%; height: 1px;
  background: linear-gradient(90deg, var(--accent-blue), var(--accent-violet));
  transform: scaleX(0);
  transform-origin: left;
  /* Ressort léger : le dépassement du cubic-bezier donne l'élasticité. */
  transition: transform 0.45s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.nav-links a:hover,
.nav-links a:focus-visible { color: var(--text-primary); }
.nav-links a:hover::after,
.nav-links a:focus-visible::after { transform: scaleX(1); }

/* ---------- Hero ---------- */
.hero {
  padding-top: 76px;
  padding-bottom: 84px;
  display: grid;
  grid-template-columns: 1fr 1.18fr;
  gap: 36px;
  align-items: center;
}
.hero-eyebrow {
  font-size: 13px;
  color: var(--accent-violet);
  letter-spacing: 1px;
  text-transform: uppercase;
  margin-bottom: 20px;
}
.hero h1 {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  font-size: 46px;
  line-height: 1.14;
  margin-bottom: 20px;
  letter-spacing: -0.5px;
}
.hero p {
  font-size: 16.5px;
  color: var(--text-muted);
  line-height: 1.65;
  margin-bottom: 32px;
  max-width: 460px;
}

.btn-primary {
  display: inline-block;
  position: relative;
  background: linear-gradient(135deg, var(--accent-blue), var(--accent-violet));
  color: #0A0E2E;
  font-weight: 500;
  padding: 14px 28px;
  border-radius: 8px;
  text-decoration: none;
  font-size: 15px;
  transition: transform 0.2s var(--ease-out), box-shadow 0.2s var(--ease-out);
  box-shadow: 0 4px 20px rgba(91, 110, 245, 0.18);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 34px rgba(91, 110, 245, 0.38);
}
.btn-primary:active { transform: translateY(0); }
/* Magnétisme (pointeur fin seulement, posé par reveal.js) : pendant que le
   pointeur est dessus, la transform suit sans transition — c'est le retour
   au repos qui a droit au ressort, pas la poursuite. */
.btn-primary.is-magnet {
  transition: box-shadow 0.2s var(--ease-out);
  box-shadow: 0 10px 34px rgba(91, 110, 245, 0.38);
}

/* ---------- L'atelier (pièce maîtresse du hero) ---------- */
.atelier {
  position: relative;
  perspective: 1200px;
  /* Pas de min-height : elle réservait 420 px alors que le contenu en fait ~300,
     ce qui creusait un vide sous l'atelier. La hauteur vient du panneau. */
}
.atelier-stage {
  position: relative;
  /* Ni transform-style: preserve-3d (re-rastérisait tout le sous-arbre à chaque
     caractère), ni will-change: transform (forçait une couche permanente sur un
     grand sous-arbre). Les deux figeaient le rendu sur une machine chargée. */
}

/* Salim Robot — sa main tendue projette l'hologramme.
   La bannière n'a pas de version détourée : son fond indigo est CUIT dans
   l'image, et il est légèrement plus clair que celui du site — d'où un
   rectangle visible. Un masque ne suffisait pas (il n'atteignait que ~57 %
   d'opacité au bord). On peint donc par-dessus un voile de la couleur EXACTE
   du fond : la transition est garantie sans couture, quelle que soit l'image. */
.atelier-robot {
  position: absolute;
  left: 0;
  bottom: 0;
  width: 43%;
  max-width: 232px;
  z-index: 2;
  /* Pas de flottement en boucle : une transform animée en continu à
     l'intérieur du contexte 3D re-rastérisait la couche sans arrêt. */
}
.atelier-robot img {
  display: block;
  width: 100%;
  height: auto;
}
.atelier-robot::after {
  content: '';
  position: absolute;
  inset: -1px;
  pointer-events: none;
  background:
    radial-gradient(ellipse 64% 66% at 43% 50%,
      rgba(13, 16, 33, 0) 40%,
      rgba(13, 16, 33, 0.45) 68%,
      rgba(13, 16, 33, 0.92) 88%,
      var(--bg-void) 100%);
}

/* Le faisceau : reprend la lumière de la main et la porte jusqu'au panneau,
   ce que le voile ci-dessus efface dans l'image elle-même. */
.atelier-beam {
  position: absolute;
  left: 30%;
  bottom: 36%;
  width: 24%;
  height: 16%;
  z-index: 1;
  pointer-events: none;
  /* Pas de filter: blur() — l'animer force un recalcul du flou à chaque image
     et fige le rendu. Le dégradé radial donne déjà un bord doux, gratuitement. */
  background: radial-gradient(ellipse at 10% 50%,
    rgba(178, 160, 255, 0.50) 0%,
    rgba(150, 130, 240, 0.26) 30%,
    rgba(136, 115, 232, 0.10) 55%,
    rgba(91, 110, 245, 0) 80%);
  /* Statique aussi : même raison que le robot et le reflet. */
}

/* Le panneau holographique en construction */
.atelier-holo {
  position: relative;
  /* Aucun chevauchement avec le robot (40 % de large) : le voile de fond
     peindrait sinon la couleur opaque du site par-dessus le bord du panneau. */
  margin-left: 45%;
  transform: rotateY(-12deg) rotateX(3deg);
}

.holo-frame {
  position: relative;
  /* Plus clair que le fond du site : sans ça le panneau se noyait dedans. */
  background: linear-gradient(158deg, rgba(31, 36, 66, 0.97), rgba(19, 23, 44, 0.94));
  border: 1px solid rgba(136, 115, 232, 0.42);
  border-radius: 12px;
  overflow: hidden;
  box-shadow:
    0 0 0 1px rgba(91, 110, 245, 0.12),
    0 26px 60px rgba(0, 0, 0, 0.55),
    0 0 80px rgba(91, 110, 245, 0.20);
}

/* Reflet holographique — STATIQUE.
   C'était un balayage animé en boucle ; à l'intérieur d'un conteneur
   transformé en 3D avec overflow:hidden, le navigateur ne peut pas le
   promouvoir sur le compositeur et re-rastérisait la couche à chaque image.
   Un reflet fixe donne la même lecture « hologramme » pour zéro coût. */
.holo-frame::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(168deg,
    rgba(136, 115, 232, 0.14) 0%,
    rgba(136, 115, 232, 0.03) 42%,
    transparent 70%);
  pointer-events: none;
  z-index: 1;
}
.holo-frame > * { position: relative; z-index: 2; }

.holo-chrome {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 9px 12px;
  border-bottom: 1px solid var(--border-soft);
  background: rgba(255, 255, 255, 0.02);
}
.holo-chrome i {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: rgba(136, 144, 176, 0.4);
}
.holo-url {
  margin-left: 8px;
  font-size: 9.5px;
  color: var(--text-muted);
  font-family: ui-monospace, 'SF Mono', Menlo, Consolas, monospace;
  letter-spacing: 0.2px;
}

.holo-body { padding: 12px; min-height: 176px; }

/* Les pièces qui s'assemblent */
[data-piece] { transform-origin: left center; }
.atelier.js-on [data-piece] {
  opacity: 0;
  transform: translateY(8px) scale(0.97);
}
.atelier.js-on [data-piece].is-built {
  opacity: 1;
  transform: none;
  transition: opacity 0.45s var(--ease-out), transform 0.45s var(--ease-out);
}

.holo-nav {
  height: 15px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.13);
  margin-bottom: 12px;
}
.holo-hero { margin-bottom: 14px; }
.holo-bar {
  height: 9px;
  border-radius: 3px;
  background: linear-gradient(90deg, rgba(160, 142, 245, 0.92), rgba(91, 110, 245, 0.42));
  margin-bottom: 7px;
}
.holo-bar.w70 { width: 70%; }
.holo-bar.w45 { width: 45%; }
.holo-cta {
  width: 76px; height: 20px;
  border-radius: 5px;
  background: linear-gradient(135deg, var(--accent-blue), var(--accent-violet));
  margin-top: 10px;
}
.holo-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.holo-card {
  height: 44px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.09);
  border: 1px solid rgba(255, 255, 255, 0.14);
}
.holo-card::before {
  content: '';
  display: block;
  width: 16px; height: 2px;
  border-radius: 1px;
  margin: 9px 0 0 9px;
  background: linear-gradient(90deg, var(--accent-blue), var(--accent-violet));
}
/* Les trois cartes apparaissent en cascade quand leur conteneur est bâti.
   Le conteneur porte data-piece, pas chaque carte — sinon une seule serait
   enregistrée côté JS (les clés data-piece doivent être uniques). */
.atelier.js-on .holo-cards .holo-card {
  opacity: 0;
  transform: translateY(8px) scale(0.97);
}
.atelier.js-on .holo-cards.is-built .holo-card {
  opacity: 1;
  transform: none;
  transition: opacity 0.45s var(--ease-out), transform 0.45s var(--ease-out);
}
.atelier.js-on .holo-cards.is-built .holo-card:nth-child(2) { transition-delay: 0.10s; }
.atelier.js-on .holo-cards.is-built .holo-card:nth-child(3) { transition-delay: 0.20s; }

/* Badge « en ligne » */
.holo-live {
  position: absolute;
  right: 10px; top: 8px;
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 9px;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: #7FE3B0;
  z-index: 3;
}
.holo-live::before {
  content: '';
  width: 5px; height: 5px;
  border-radius: 50%;
  background: #7FE3B0;
  box-shadow: 0 0 8px #7FE3B0;
}

/* Le code qui s'écrit sous le panneau — hors du sous-arbre 3D (voir index.html) */
.holo-code {
  margin-left: 45%;
  margin-top: 16px;
  padding: 11px 13px;
  border-radius: 9px;
  background: rgba(10, 12, 26, 0.72);
  border: 1px solid var(--border-soft);
  font-family: ui-monospace, 'SF Mono', Menlo, Consolas, monospace;
  font-size: 11px;
  line-height: 1.85;
  min-height: 74px;
  overflow: hidden;
}
.holo-code-line {
  display: block;
  white-space: pre;
  overflow: hidden;
  text-overflow: ellipsis;
}
.holo-code-line.is-done { color: rgba(136, 144, 176, 0.5); }
.holo-code-line.is-live { color: var(--accent-violet); }
.holo-caret {
  display: inline-block;
  width: 6px;
  height: 12px;
  margin-left: 2px;
  vertical-align: -2px;
  background: var(--accent-violet);
  animation: caret-blink 1s steps(2, start) infinite;
}
@keyframes caret-blink { 0%, 100% { opacity: 1; } 50% { opacity: 0; } }

/* ---------- Sections ---------- */
section { padding-top: 76px; padding-bottom: 76px; }
.section-eyebrow {
  font-size: 13px;
  color: var(--accent-violet);
  letter-spacing: 1px;
  text-transform: uppercase;
  margin-bottom: 12px;
}
h2 {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  font-size: 32px;
  margin-bottom: 16px;
  letter-spacing: -0.3px;
}
.section-intro {
  color: var(--text-muted);
  font-size: 15.5px;
  max-width: 540px;
  margin-bottom: 44px;
  line-height: 1.65;
}

.services-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.service-card {
  position: relative;
  background: var(--surface-card);
  border: 1px solid var(--border-soft);
  border-radius: 14px;
  padding: 30px 26px;
  overflow: hidden;
  transition: transform 0.35s var(--ease-out), border-color 0.35s ease;
}
/* Lueur qui suit le curseur (--mx / --my posés par reveal.js) */
.service-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(320px circle at var(--mx, 50%) var(--my, 50%),
              rgba(136, 115, 232, 0.13), transparent 62%);
  opacity: 0;
  transition: opacity 0.35s ease;
  pointer-events: none;
}
.service-card:hover {
  /* --rx / --ry : inclinaison posée par reveal.js (pointeur fin seulement).
     Au doigt ou en reduced-motion les variables restent absentes et il ne
     reste que l'élévation. L'amorti vient de la transition de .35s : la
     carte suit le pointeur avec une inertie voulue, pas en le collant. */
  transform: perspective(700px) rotateX(var(--ry, 0deg)) rotateY(var(--rx, 0deg)) translateY(-5px);
  border-color: rgba(136, 115, 232, 0.36);
}
.service-card:hover::before { opacity: 1; }
.service-card > * { position: relative; }

.card-accent {
  width: 32px;
  height: 4px;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--accent-blue), var(--accent-violet));
  margin-bottom: 18px;
  transition: width 0.35s var(--ease-out);
}
.service-card:hover .card-accent { width: 52px; }
.service-card h3 {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 18px;
  font-weight: 500;
  margin-bottom: 10px;
}
.service-card p { color: var(--text-muted); font-size: 14px; line-height: 1.65; }

.about-text p {
  color: var(--text-muted);
  font-size: 15.5px;
  line-height: 1.75;
  margin-bottom: 16px;
  max-width: 640px;
}
.about-text strong { color: var(--text-primary); font-weight: 500; }

/* Deux blocs sous un seul « À propos » : l'entreprise, puis le fondateur.
   La séparation est une ligne fine + de l'air — pas un titre écrit. */
.about-block + .about-block {
  margin-top: 52px;
  padding-top: 52px;
  border-top: 1px solid var(--border-soft);
}
/* Le bloc fondateur est prêt à recevoir une photo : il suffit de
   décommenter la <figure> dans index.html — la grille s'adapte seule. */
.about-founder { display: grid; grid-template-columns: minmax(0, 1fr); gap: 32px; }
.about-photo { margin: 0; }
.about-photo img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 14px;
  border: 1px solid var(--border-soft);
}
@media (min-width: 720px) {
  .about-founder:has(.about-photo) {
    grid-template-columns: 220px minmax(0, 1fr);
    align-items: start;
  }
}

/* ---------- La preuve : les Web Vitals de la visite, mesurés en direct ----------
   Les valeurs sont écrites par preuve.js (PerformanceObserver, première partie).
   Chaque tuile réserve sa hauteur : le panneau qui prouve la stabilité visuelle
   ne doit évidemment causer aucun décalage lui-même. */
.preuve { padding-top: 0; }
.preuve-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
  margin-bottom: 18px;
}
.preuve-tile {
  position: relative;
  background: var(--surface-card);
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  padding: 18px 18px 16px;
  min-height: 122px;
  overflow: hidden;
}
.preuve-tile::before {
  content: '';
  position: absolute;
  left: 0; right: 0; top: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--accent-blue), var(--accent-violet));
  opacity: 0.55;
}
.preuve-tile dt {
  font-size: 12px;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 10px;
}
.preuve-tile abbr { text-decoration: none; color: var(--accent-violet); }
.preuve-valeur {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  font-size: 30px;
  letter-spacing: -0.5px;
  font-variant-numeric: tabular-nums;
  margin: 0 0 6px;
  min-height: 36px; /* la valeur arrive après coup : la place est déjà prise */
}
.preuve-seuil {
  font-size: 12.5px;
  color: var(--text-muted);
  margin: 0;
}
.preuve-check { color: var(--accent-violet); white-space: nowrap; }
.preuve-tile.is-na .preuve-valeur { color: var(--text-muted); }
.preuve-note {
  font-size: 13px;
  color: var(--text-muted);
  max-width: 640px;
  line-height: 1.6;
}

.contact { text-align: center; }
.contact-box {
  background: var(--surface-card);
  border: 1px solid var(--border-soft);
  border-radius: 16px;
  padding: 52px 40px;
  max-width: 540px;
  margin: 0 auto;
}
.contact-box p { color: var(--text-muted); margin-bottom: 26px; font-size: 15px; }

/* ---------- Pied de page ---------- */
footer { border-top: 1px solid var(--border-soft); padding: 28px 0; }
footer .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
  font-size: 13px;
  color: var(--text-muted);
}
.footer-links { display: flex; gap: 20px; flex-wrap: wrap; }
.footer-links a { color: var(--text-muted); text-decoration: none; transition: color 0.2s; }
.footer-links a:hover { color: var(--text-primary); text-decoration: underline; }

/* ---------- Pages de politiques ---------- */
.legal { padding: 64px 0 40px; max-width: 760px; }
.legal h1 {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  font-size: 34px;
  line-height: 1.2;
  margin-bottom: 14px;
}
.legal .legal-date { color: var(--text-muted); font-size: 14px; margin-bottom: 28px; }
.legal-notice {
  background: var(--surface-card);
  border: 1px solid var(--border-soft);
  border-left: 3px solid var(--accent-violet);
  border-radius: 10px;
  padding: 16px 20px;
  margin-bottom: 40px;
  color: var(--text-muted);
  font-size: 14.5px;
  line-height: 1.6;
}
.legal h2 {
  font-size: 20px;
  margin-top: 38px;
  margin-bottom: 12px;
  color: var(--text-primary);
}
.legal p {
  color: var(--text-muted);
  font-size: 15.5px;
  line-height: 1.75;
  margin-bottom: 14px;
}
.legal ul { margin: 0 0 14px 22px; }
.legal li {
  color: var(--text-muted);
  font-size: 15.5px;
  line-height: 1.75;
  margin-bottom: 8px;
}
.legal strong { color: var(--text-primary); font-weight: 500; }
.legal a { color: var(--accent-violet); }
.legal-back {
  display: inline-block;
  margin-top: 40px;
  color: var(--text-muted);
  font-size: 14px;
  text-decoration: none;
}
.legal-back:hover { color: var(--text-primary); }

/* ---------- Tablette ---------- */
@media (max-width: 940px) {
  .hero {
    grid-template-columns: 1fr;
    gap: 48px;
    padding-top: 56px;
    padding-bottom: 64px;
  }
  .hero h1 { font-size: 38px; }
  .atelier { min-height: 380px; max-width: 520px; }
  .atelier-holo { transform: rotateY(-8deg); }
}

/* ---------- Mobile ---------- */
@media (max-width: 700px) {
  .nav-links { display: none; }
  .hero { padding-top: 40px; padding-bottom: 56px; }
  .hero h1 { font-size: 31px; }
  .hero p { font-size: 15.5px; }
  section { padding-top: 56px; padding-bottom: 56px; }
  h2 { font-size: 26px; }
  .services-grid { grid-template-columns: 1fr; }
  .preuve-grid { grid-template-columns: repeat(2, 1fr); }
  .preuve-valeur { font-size: 24px; min-height: 30px; }
  .contact-box { padding: 38px 24px; }
  footer .container { flex-direction: column; align-items: flex-start; }
  .legal h1 { font-size: 27px; }

  /* L'atelier reste impressionnant, mais allégé : pas de 3D, pas de
     balayage, hologramme à plat pour préserver la lisibilité et la batterie. */
  .atelier { perspective: none; }
  .atelier-holo { transform: none; margin-left: 38%; }
  .atelier-robot { width: 36%; max-width: 138px; }
  .atelier-beam { left: 25%; width: 22%; }
  .holo-code { margin-left: 0; }
  .holo-body { min-height: 148px; padding: 10px; }
  .holo-code { font-size: 10px; min-height: 66px; }
}

/* ---------- Transitions entre pages (View Transitions, cross-document) ----------
   Déclaratif, zéro JavaScript : les navigateurs qui ne connaissent pas la
   règle naviguent normalement. Même origine seulement — exactement notre cas
   (index ↔ pages légales). */
@view-transition { navigation: auto; }
::view-transition-old(root) { animation: vt-leave 0.16s cubic-bezier(0.4, 0, 1, 1) both; }
::view-transition-new(root) { animation: vt-enter 0.26s cubic-bezier(0, 0, 0.2, 1) both; }
@keyframes vt-leave { to { opacity: 0; transform: translateY(-8px); } }
@keyframes vt-enter { from { opacity: 0; transform: translateY(10px); } }

/* ---------- Animations pilotées par le défilement (CSS pur) ----------
   Progressive enhancement : @supports isole tout, et reveal.js reste le
   mécanisme de révélation (sémantique « une seule fois » que la timeline de
   défilement, qui va-et-vient, ne sait pas exprimer). Ici : uniquement du
   décoratif que le va-et-vient sert au lieu de trahir. */
@supports (animation-timeline: scroll()) {
  @media (prefers-reduced-motion: no-preference) {
    /* Fil de progression de lecture sous la barre de navigation. */
    nav.site-nav::after {
      content: '';
      position: absolute;
      left: 0; right: 0; bottom: -1px;
      height: 2px;
      background: linear-gradient(90deg, var(--accent-blue), var(--accent-violet));
      transform: scaleX(0);
      transform-origin: left;
      animation: nav-progress linear both;
      animation-timeline: scroll(root);
    }
    /* Le hero s'enfonce doucement en quittant l'écran — profondeur, pas décor. */
    .hero {
      animation: hero-drift linear both;
      animation-timeline: view();
      animation-range: exit 0% exit 100%;
    }
  }
}
@keyframes nav-progress { to { transform: scaleX(1); } }
@keyframes hero-drift { to { transform: translateY(-26px); opacity: 0.3; } }

/* ---------- Respect de prefers-reduced-motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
  .holo-caret { animation: none; opacity: 1; }
  /* View Transitions : navigation instantanée, pas de mouvement. */
  ::view-transition-group(*),
  ::view-transition-image-pair(*),
  ::view-transition-old(*),
  ::view-transition-new(*) { animation: none !important; }
}
