/* Feuille commune du site public (accueil, support, pages légales).
   Mêmes couleurs que l'app et que invite.html. */
:root {
  color-scheme: light dark;
  --bg: #f7f6f3;
  --surface: #fffdf8;
  --text: #12110f;
  --muted: #5c574e;
  --line: rgba(18, 17, 15, 0.12);
  --accent: #a3ff00;
  --accent-text: #000000;
  /* Vert lisible sur fond clair (texte), le fluo restant pour les boutons. */
  --accent-ink: #4f7d00;
  /* Liseré du cadre des captures. */
  --frame-rim: rgba(0, 0, 0, 0.35);
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #12110f;
    --surface: #1c1b19;
    --text: #f7f6f3;
    --muted: #b7b1a8;
    --line: rgba(247, 246, 243, 0.14);
    --accent-ink: var(--accent);
    --frame-rim: rgba(255, 255, 255, 0.16);
  }
}

* {
  box-sizing: border-box;
}
html {
  -webkit-text-size-adjust: 100%;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: 16px;
  line-height: 1.55;
}
a {
  color: inherit;
}

.wrap {
  width: min(960px, 100%);
  margin: 0 auto;
  padding: 0 20px;
}

/* En-tête */
.site-header {
  border-bottom: 1px solid var(--line);
}
.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: 64px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  letter-spacing: -0.2px;
  text-decoration: none;
}
.brand img {
  width: 32px;
  height: 32px;
  border-radius: 8px;
}
.site-header nav a {
  margin-left: 18px;
  color: var(--muted);
  font-size: 15px;
  text-decoration: none;
}
.site-header nav a:hover,
.site-header nav a[aria-current='page'] {
  color: var(--text);
}

/* Boutons */
.button {
  display: inline-block;
  border-radius: 999px;
  padding: 14px 24px;
  font-weight: 700;
  text-decoration: none;
  background: var(--accent);
  color: var(--accent-text);
}

/* Accueil */
.hero {
  padding: 72px 20px 24px;
  text-align: center;
}
.hero h1 {
  max-width: 14ch;
  margin: 0 auto 16px;
  font-size: clamp(36px, 7vw, 64px);
  line-height: 1.02;
  letter-spacing: -1.4px;
}
.hero p {
  max-width: 36ch;
  margin: 0 auto 28px;
  color: var(--muted);
  font-size: 19px;
}
.hero .note {
  margin-top: 12px;
  font-size: 14px;
}

/* Phrase dont les mots s'allument au fil du scroll (story.js). */
.manifesto {
  padding: 96px 20px;
}
.manifesto p {
  max-width: 22ch;
  margin: 0 auto;
  font-size: clamp(30px, 5.4vw, 56px);
  font-weight: 700;
  line-height: 1.12;
  letter-spacing: -1px;
  text-align: center;
}
.manifesto .word {
  color: color-mix(in srgb, var(--text) 18%, transparent);
  transition: color 0.25s ease;
}
.manifesto .word.lit {
  color: var(--text);
}
.manifesto .word.accent.lit {
  color: var(--accent-ink);
}

/* Étapes : texte qui défile, capture fixe qui change d'image. */
.story {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  padding: 0 20px 48px;
}
.story-media {
  position: sticky;
  top: 12vh;
  height: 76vh;
  order: 2;
}
/* Cadre de téléphone sobre, sans marque : bordure noire fine, arrondi
   d'un écran moderne, liseré du contour et ombre portée. Mêmes proportions
   en grand (--edge et --corner suivent la hauteur de la capture) et sur
   téléphone (elles suivent sa largeur). */
.story-media img,
.step-shot {
  --edge: 1.15vh;
  --corner: 5.4vh;
  border: var(--edge) solid #0d0d0e;
  border-radius: var(--corner);
  background: #0d0d0e;
  box-shadow:
    0 0 0 1px var(--frame-rim),
    0 2px 6px rgba(0, 0, 0, 0.12),
    0 40px 80px -24px rgba(0, 0, 0, 0.45);
}
.story-media img {
  position: absolute;
  top: 0;
  left: 50%;
  height: 100%;
  width: auto;
  max-width: 100%;
  object-fit: contain;
  opacity: 0;
  transform: translate(-50%, 24px) scale(0.97);
  transition:
    opacity 0.55s ease,
    transform 0.55s ease;
}
.story[data-active='1'] .story-media img[data-for='1'],
.story[data-active='2'] .story-media img[data-for='2'],
.story[data-active='3'] .story-media img[data-for='3'] {
  opacity: 1;
  transform: translate(-50%, 0);
}
.step {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 90vh;
  opacity: 0.3;
  transition: opacity 0.4s ease;
}
.story[data-active='1'] .step[data-step='1'],
.story[data-active='2'] .step[data-step='2'],
.story[data-active='3'] .step[data-step='3'] {
  opacity: 1;
}
.step-num {
  margin-bottom: 12px;
  color: var(--accent-ink);
  font-size: 15px;
  font-weight: 800;
  letter-spacing: 1px;
}
.step h2 {
  margin: 0 0 12px;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.08;
  letter-spacing: -0.8px;
}
.step p {
  max-width: 34ch;
  margin: 0;
  color: var(--muted);
  font-size: 18px;
}
/* Sur grand écran, la capture est dans la colonne fixe. */
.step-shot {
  display: none;
}

/* Cartes des fonctions annexes. */
.extras {
  padding: 48px 20px 24px;
}
.extras h2 {
  margin: 0 0 28px;
  font-size: clamp(28px, 4.6vw, 44px);
  letter-spacing: -0.8px;
  text-align: center;
}
.extras-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}
.extra {
  background: var(--surface);
  border-radius: 20px;
  padding: 24px;
}
.extra h3 {
  margin: 0 0 6px;
  font-size: 18px;
}
.extra p {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
}

/* Apparition à l'entrée dans l'écran (story.js ajoute .visible). */
.js .reveal {
  opacity: 0;
  transform: translateY(32px);
  transition:
    opacity 0.7s ease,
    transform 0.7s ease;
  transition-delay: calc(var(--i, 0) * 90ms);
}
.js .reveal.visible {
  opacity: 1;
  transform: none;
}

.outro {
  padding: 48px 20px 96px;
  text-align: center;
}
.outro h2 {
  margin: 0 0 24px;
  font-size: clamp(28px, 5vw, 44px);
  letter-spacing: -0.8px;
}

/* Pages de texte (légal, support) */
.page {
  width: min(720px, 100%);
  margin: 0 auto;
  padding: 48px 20px 72px;
}
.page h1 {
  margin: 0 0 6px;
  font-size: clamp(28px, 5vw, 38px);
  line-height: 1.1;
  letter-spacing: -0.6px;
}
.page .updated {
  margin: 0 0 32px;
  color: var(--muted);
  font-size: 14px;
}
.page h2 {
  margin: 36px 0 10px;
  font-size: 20px;
  letter-spacing: -0.2px;
}
.page h3 {
  margin: 20px 0 6px;
  font-size: 16px;
}
.page p,
.page li {
  color: var(--muted);
}
.page p {
  margin: 0 0 12px;
}
.page ul {
  margin: 0 0 12px;
  padding-left: 20px;
}
.page li {
  margin-bottom: 6px;
}
.page strong {
  color: var(--text);
  font-weight: 600;
}
.contact-card {
  background: var(--surface);
  border-radius: 20px;
  padding: 22px;
  margin: 24px 0 8px;
}
.contact-card p {
  margin: 0 0 14px;
}

/* Pied de page */
.site-footer {
  border-top: 1px solid var(--line);
  padding: 24px 0 40px;
  color: var(--muted);
  font-size: 14px;
}
.site-footer .wrap {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px 24px;
}
.site-footer nav a {
  margin-right: 16px;
  text-decoration: none;
  white-space: nowrap;
}
.site-footer nav a:hover {
  color: var(--text);
}

@media (max-width: 720px) {
  .hero {
    padding-top: 48px;
  }
  .manifesto {
    padding: 64px 20px;
  }
  /* Une colonne : chaque étape porte sa propre capture. */
  .story {
    grid-template-columns: 1fr;
    gap: 0;
  }
  .story-media {
    display: none;
  }
  .step {
    min-height: 0;
    padding: 40px 0;
    opacity: 1;
  }
  .step-shot {
    --edge: min(9px, 2.4vw);
    --corner: min(46px, 12vw);
    display: block;
    width: min(300px, 78vw);
    height: auto;
    margin: 28px auto 0;
  }
  .extras-grid {
    grid-template-columns: 1fr;
  }
  .site-header nav a {
    margin-left: 14px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .js .reveal,
  .story-media img,
  .manifesto .word {
    transition: none;
  }
  .js .reveal {
    opacity: 1;
    transform: none;
  }
}
