/* base.css — reset, typographie, boutons, apparitions. */

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-behavior: smooth; background: var(--bg); color-scheme: dark; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font: 400 var(--t-body)/1.55 var(--sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}
img, svg { display: block; max-width: 100%; }
button { font: inherit; color: inherit; }
a { color: inherit; }
:focus-visible { outline: 2px solid var(--fg); outline-offset: 3px; border-radius: 6px; }
::selection { background: rgba(255,255,255,.22); }
[hidden] { display: none !important; }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip {
  position: absolute; left: 16px; top: -60px; z-index: 100;
  padding: 10px 14px; background: var(--fg); color: var(--bg);
  border-radius: 10px; text-decoration: none;
}
.skip:focus { top: 12px; }

/* La scène 3D, derrière toute la page. */
.gl { position: fixed; inset: 0; width: 100vw; height: 100vh; z-index: 0; pointer-events: none; }
main, .nav, footer { position: relative; z-index: 1; }

/* Mise en page. */
.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.section { padding: var(--section) 0 0; }
/* Atteinte par le menu (#tarifs, #demo…) : le titre arrive à 40 px sous
   l'en-tête fixe (68 px), pas après tout l'espace qui sépare les sections. */
.section[id] { scroll-margin-top: calc(108px - var(--section)); }
.center { text-align: center; }

/* Titres. Space Grotesk, blanc ; le mot qui porte, en argent. */
.hero-title, .h2, .h3 {
  font-family: var(--display);
  font-weight: 600;
  color: var(--fg);
  margin: 0;
  text-wrap: balance;
}
.hero-title { font-size: var(--t-hero); line-height: 1.0; letter-spacing: -0.028em; }
.h2 { font-size: var(--t-h2); line-height: 1.04; letter-spacing: -0.022em; }
.h3 { font-size: var(--t-h3); line-height: 1.15; letter-spacing: -0.01em; }
.accent {
  font-weight: 500;
  background: linear-gradient(100deg, #FFFFFF 10%, #9A9AA0 90%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  padding-right: .06em;
  /* Coupé sur deux lignes, chaque morceau garde son dégradé. */
  -webkit-box-decoration-break: clone; box-decoration-break: clone;
}
.lead {
  font-size: var(--t-lead); line-height: 1.5; color: var(--fg-3);
  margin: 20px auto 0; max-width: 34em; text-wrap: pretty;
}
.note { font: 500 var(--t-mono)/1.45 var(--mono); color: var(--fg-4); letter-spacing: .01em; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px; margin: 0 0 22px;
  font: 500 12.5px/1 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--fg-4);
}
.eyebrow::before { content: ""; width: 18px; height: 1px; background: var(--fg-5); }
.head { max-width: 780px; margin: 0 auto; text-align: center; }
.head .eyebrow { justify-content: center; }

/* Boutons. Un seul plein à l'écran : le blanc. */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 50px; padding: 0 22px; border-radius: var(--r-btn);
  border: 0; cursor: pointer; text-decoration: none;
  font: 600 15.5px/1 var(--sans); letter-spacing: -0.005em;
  transition: background-color var(--t-fast) var(--ease), transform var(--t-fast) var(--ease), box-shadow var(--t-fast) var(--ease);
}
.btn:active { transform: scale(.98); }
.btn svg { width: 17px; height: 17px; flex: none; }
.btn-light { background: var(--fg); color: #0A0A0C; box-shadow: 0 0 0 1px rgba(255,255,255,.4), 0 8px 30px -8px rgba(255,255,255,.28); }
.btn-light:hover { background: #FFFFFF; }
.btn-ghost { background: none; color: var(--fg-2); padding: 0 16px; }
.btn-ghost:hover { background: rgba(255,255,255,.06); color: var(--fg); }
.btn-ghost .arrow { transition: transform var(--t-fast) var(--ease); }
.btn-ghost:hover .arrow { transform: translateX(3px); }
.btn-line { background: none; color: var(--fg); box-shadow: inset 0 0 0 1px var(--line-2); }
.btn-line:hover { background: rgba(255,255,255,.06); }
.btn-small { min-height: 38px; padding: 0 14px; font-size: 14px; border-radius: 10px; }
/* Le bouton de la nav s'efface en contour quand un bouton plein du contenu
   est à l'écran. */
.btn-light.quiet { background: none; color: var(--fg); box-shadow: inset 0 0 0 1px var(--line-2); }
.btn-light.quiet:hover { background: rgba(255,255,255,.06); }

/* Une touche du clavier. */
.key {
  display: inline-grid; place-items: center; min-width: 26px; height: 26px; padding: 0 7px;
  border-radius: var(--r-key); background: #1C1C1E; color: var(--fg-2);
  box-shadow: inset 0 -2px 0 rgba(0,0,0,.5), 0 0 0 1px rgba(255,255,255,.12);
  font: 600 12px/1 var(--mono);
}

/* Carte : un fond, un filet, et une lumière qui suit la souris au survol. */
.card {
  position: relative; background: var(--bg-2); border-radius: var(--r-card);
  box-shadow: inset 0 0 0 1px var(--line);
}
.card::before {
  content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none;
  background: radial-gradient(420px circle at var(--mx, 50%) var(--my, 0%), rgba(255,255,255,.07), transparent 60%);
  opacity: 0; transition: opacity 300ms var(--ease);
}
.card:hover::before { opacity: 1; }

/* Apparition à l'entrée dans l'écran — seulement si le JS est là. */
.js .reveal { opacity: 0; transform: translateY(22px); transition: opacity var(--t-in) var(--ease), transform var(--t-in) var(--ease); }
.js .reveal.is-in { opacity: 1; transform: none; }
.js .reveal[data-delay="1"] { transition-delay: 90ms; }
.js .reveal[data-delay="2"] { transition-delay: 180ms; }
.js .reveal[data-delay="3"] { transition-delay: 270ms; }
.instant .reveal { transition: none !important; }
/* Le haut de page paraît par la feuille seule, sans attendre le JS (common.js
   n'ajoute `is-in` qu'une fois les scripts chargés) : c'est son texte qui
   compte pour le premier affichage. */
@keyframes rise { from { opacity: 0; transform: translateY(22px); } to { opacity: 1; transform: none; } }
.js .hero .reveal { opacity: 1; transform: none; transition: none; animation: rise var(--t-in) var(--ease) both; animation-play-state: running !important; }
.js .hero .reveal[data-delay="1"] { animation-delay: 90ms; }
.js .hero .reveal[data-delay="2"] { animation-delay: 180ms; }
.js .hero .reveal[data-delay="3"] { animation-delay: 270ms; }
.instant .hero .reveal { animation: none !important; }
.static *, .static *::before, .static *::after { transition: none !important; animation: none !important; }

/* Les boucles d'une section ne tournent qu'à l'écran. */
.js [data-live]:not(.live) *, .js [data-live]:not(.live) *::before, .js [data-live]:not(.live) *::after { animation-play-state: paused !important; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 1ms !important; animation-iteration-count: 1 !important; transition-duration: 1ms !important; transition-delay: 0ms !important; }
  .js .reveal { opacity: 1; transform: none; }
}
