/* Tesseria — feuille de style du site.
   Une page blanche, Inter, et des cartes de couleur : un fond pastel, un titre de la même
   teinte en vif, un texte de la même teinte en sombre. */

@font-face {
  font-family: "Inter";
  src: url("fonts/inter-latin-wght-normal.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

:root {
  color-scheme: light;
  --blanc: #FFFFFF;
  --doux: #F4F6F7;
  --encre: #2D3436;
  --texte: #2D3436;
  --texte-doux: #636E72;
  --trait: #DFE6E9;

  --bleu: #0984E3;
  --orange: #E17055;
  --rose: #E84393;
  --vert: #00B894;

  --police: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas, monospace;
  --nav: 68px;
  --ombre: 0 1px 2px rgba(45, 52, 54, .06), 0 12px 32px -8px rgba(45, 52, 54, .14), 0 40px 80px -32px rgba(45, 52, 54, .22);
}

/* Les teintes, tirées de la palette « US » de Flat UI Colors : --vif (la couleur telle quelle),
   --fond (son pastel), --ton (titres et icônes : la même couleur, assombrie à teinte égale seulement
   là où elle ne se lirait pas sur le pastel) et --sombre (texte courant). */
.t-cyan   { --vif: #00CEC9; --fond: #DBF8F7; --ton: #009B97; --sombre: #00605E; }
.t-bleu   { --vif: #0984E3; --fond: #DDEEFB; --ton: #0984E3; --sombre: #065592; }
.t-violet { --vif: #6C5CE7; --fond: #EAE8FC; --ton: #6C5CE7; --sombre: #422DE0; }
.t-rose   { --vif: #E84393; --fond: #FCE5F0; --ton: #E84393; --sombre: #9D1356; }
.t-rouge  { --vif: #D63031; --fond: #F9E2E2; --ton: #D63031; --sombre: #9B1F1F; }
.t-orange { --vif: #E17055; --fond: #FBEBE7; --ton: #DE6346; --sombre: #95321A; }
.t-jaune  { --vif: #FDCB6E; --fond: #FFF8EB; --ton: #C58103; --sombre: #7C5102; }
.t-vert   { --vif: #00B894; --fond: #DBF5F0; --ton: #009C7D; --sombre: #00614E; }

*, *::before, *::after { box-sizing: border-box; }
/* Un lien du menu cale sa section juste sous la barre : sa hauteur plus son filet. */
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--nav) + 1px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--blanc);
  color: var(--texte);
  font-family: var(--police);
  font-size: 17px;
  line-height: 1.6;
  font-feature-settings: "cv11", "ss03";
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
h1, h2, h3, p, ul, ol, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
img, svg { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--bleu); outline-offset: 3px; border-radius: 6px; }

.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.invisible { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.miel { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.evitement { position: absolute; left: 16px; top: -60px; z-index: 50; padding: 10px 16px; border-radius: 10px; background: var(--encre); color: #fff; text-decoration: none; }
.evitement:focus { top: 12px; }

.cadre { width: 100%; max-width: 1136px; margin-inline: auto; padding-inline: clamp(16px, 4vw, 32px); }
.cadre.large { max-width: 1360px; }
.cadre.etroit { max-width: 800px; }

/* ───────── Titres et textes ───────── */
h1, h2, h3 { color: var(--encre); text-wrap: balance; }
h1 { font-size: clamp(2.5rem, 7vw, 5rem); line-height: 1.02; font-weight: 800; letter-spacing: -.04em; }
h1 em { font-style: normal; color: var(--bleu); }
h2 { font-size: clamp(1.9rem, 4.2vw, 3rem); line-height: 1.08; font-weight: 800; letter-spacing: -.032em; }
h3 { font-size: 1.08rem; line-height: 1.3; font-weight: 700; letter-spacing: -.012em; }
.surtitre { margin-bottom: 14px; color: var(--bleu); font-size: .78rem; font-weight: 750; letter-spacing: .1em; text-transform: uppercase; }
.chapo { font-size: clamp(1.06rem, 1.6vw, 1.22rem); line-height: 1.55; color: var(--texte-doux); text-wrap: pretty; }
.corps { margin-top: 16px; font-size: 1.08rem; color: var(--texte-doux); text-wrap: pretty; }
b[class^="t-"] { color: var(--ton); font-weight: 750; }
code { font-family: var(--mono); font-size: .9em; padding: .1em .38em; border-radius: 6px; background: rgba(255, 255, 255, .6); }

/* ───────── Bouton ───────── */
.bouton {
  display: inline-flex; align-items: center; justify-content: center; gap: 12px;
  min-height: 48px; padding: 0 22px;
  border: 0; border-radius: 13px;
  background: var(--encre);
  color: #fff;
  font: inherit; font-weight: 600; font-size: .98rem; letter-spacing: -.01em; white-space: nowrap; text-decoration: none;
  cursor: pointer;
  transition: background-color .2s ease, transform .2s ease;
}
.bouton:has(svg) { padding-right: 10px; }
.bouton svg { width: 28px; height: 28px; padding: 7px; border-radius: 9px; background: rgba(255, 255, 255, .14); transition: transform .2s ease, background-color .2s ease; }
.bouton:hover { background: #4A5052; }
.bouton:hover svg { transform: translateX(2px); background: rgba(255, 255, 255, .22); }
.bouton:active { transform: translateY(1px); }
.bouton:disabled { opacity: .6; cursor: progress; }
.bouton-petit { min-height: 40px; padding: 0 16px; border-radius: 11px; font-size: .92rem; }

/* ───────── Navigation ───────── */
.nav { position: sticky; top: 0; z-index: 20; background: rgba(255, 255, 255, .72); backdrop-filter: saturate(1.8) blur(28px); -webkit-backdrop-filter: saturate(1.8) blur(28px); border-bottom: 1px solid var(--trait); }
.nav-rang { display: flex; align-items: center; gap: 24px; height: var(--nav); }
.nav-logo img { width: auto; height: 30px; }
.nav-liens { display: flex; gap: 4px; margin-left: auto; }
.nav-liens a { padding: 8px 12px; border-radius: 10px; color: var(--texte-doux); font-size: .94rem; font-weight: 550; text-decoration: none; transition: color .15s ease, background-color .15s ease; }
/* Le lien de la section à l'écran s'allume comme au survol ; un voile plutôt qu'un gris, pour rester visible sur les bandes grises. */
.nav-liens a:hover, .nav-liens a.actif { color: var(--encre); background: rgba(45, 52, 54, .06); }

/* ───────── Héros ───────── */
.heros { padding: clamp(48px, 7vw, 92px) 0 clamp(40px, 6vw, 80px); overflow: hidden; }
.heros { position: relative; }
.heros-texte { position: relative; z-index: 1; text-align: center; }
.vitrine { position: relative; z-index: 1; }

/* Les widgets qui flottent autour du titre. Chacun est une tuile comme dans l'app : un pictogramme
   blanc sur la couleur de son widget. Ils sont placés depuis le centre, dans les marges : sur un
   écran plus étroit, les plus éloignés sortent simplement du cadre. Au défilement, main.js donne
   --defile (en px) ; chaque tuile descend d'une fraction (--v) et tourne un peu (--vr), ce qui
   les fait paraître plus ou moins loin. Elles passent derrière la grande capture. */
.flottants { position: absolute; inset: 0; z-index: 0; pointer-events: none; --defile: 0; }
.flottant {
  position: absolute; display: grid; place-items: center;
  width: var(--t); height: var(--t); border-radius: 27%;
  background: var(--vif); color: #fff;
  box-shadow: 0 14px 28px -14px var(--vif);
  translate: 0 calc(var(--defile) * var(--v) * 1px);
  rotate: calc(var(--r) + var(--defile) * var(--vr) * 1deg);
  animation: apparition .9s cubic-bezier(.2, .7, .2, 1) var(--d) both, flotte 7s ease-in-out var(--d) infinite;
  will-change: translate, rotate, transform;
}
.flottant:nth-child(3n) { animation-duration: .9s, 8.5s; }
.flottant:nth-child(3n + 1) { animation-duration: .9s, 6.2s; }
.flottant svg { width: 50%; height: 50%; }
.flottant.petit { display: none; }
@keyframes apparition { from { opacity: 0; scale: .6; } }
@keyframes flotte { 0%, 100% { transform: translateY(0) rotate(0); } 50% { transform: translateY(-10px) rotate(4deg); } }
.pastille { display: inline-flex; align-items: center; gap: 9px; margin-bottom: 26px; padding: 7px 14px 7px 12px; border-radius: 999px; background: var(--fond); color: var(--ton); font-size: .86rem; font-weight: 700; }
.pastille i { width: 8px; height: 8px; border-radius: 3px; background: currentColor; transform: rotate(12deg); }
.devise { margin-top: 24px; color: var(--encre); font-size: clamp(1.2rem, 2.5vw, 1.7rem); line-height: 1.3; font-weight: 650; letter-spacing: -.02em; text-wrap: balance; }
.heros .chapo { max-width: 660px; margin: 18px auto 0; }
.heros .inscription { margin-top: 34px; }

.inscription { max-width: 520px; margin-inline: auto; }
.inscription-rang {
  display: flex; gap: 6px; padding: 6px;
  border: 1px solid #DFE6E9; border-radius: 19px;
  background: #fff;
  box-shadow: 0 1px 2px rgba(45, 52, 54, .05), 0 10px 28px -14px rgba(45, 52, 54, .22);
  transition: border-color .2s ease, box-shadow .2s ease;
}
.inscription-rang:focus-within { border-color: rgba(9, 132, 227, .55); box-shadow: 0 0 0 4px rgba(9, 132, 227, .13), 0 10px 28px -14px rgba(45, 52, 54, .22); }
.inscription input[type="email"] {
  flex: 1; min-width: 0; min-height: 48px; padding: 0 14px;
  border: 0; border-radius: 13px;
  background: transparent; color: var(--encre);
  font: inherit; font-size: 1rem;
}
.inscription input[type="email"]:focus { outline: none; }
/* Le remplissage automatique du navigateur peint le champ en bleu : on le garde blanc dans la capsule. */
.inscription input[type="email"]:-webkit-autofill { -webkit-box-shadow: 0 0 0 40px #fff inset; -webkit-text-fill-color: var(--encre); caret-color: var(--encre); }
.inscription input[type="email"]::placeholder { color: #B2BEC3; }
.inscription.en-erreur .inscription-rang { border-color: #EFB0B1; box-shadow: 0 0 0 4px rgba(214, 48, 49, .1), 0 10px 28px -14px rgba(45, 52, 54, .22); animation: secousse .36s ease; }
.inscription-note { margin-top: 14px; color: var(--texte-doux); font-size: .9rem; text-align: center; }
/* L'erreur et la réussite : une petite étiquette avec son pictogramme, plutôt qu'une phrase en gras. */
.inscription-note.erreur, .inscription-note.reussi {
  display: flex; align-items: center; gap: 8px; width: fit-content; max-width: 100%; margin-inline: auto;
  padding: 7px 14px 7px 9px; border-radius: 11px;
  font-size: .88rem; font-weight: 500; text-align: left;
  animation: note-entree .25s ease;
}
.inscription-note.erreur::before, .inscription-note.reussi::before { content: ""; flex: none; width: 18px; height: 18px; background: center / contain no-repeat; }
.inscription-note.erreur { background: #FCEEEF; border: 1px solid #F6D1D2; color: #9B1F1F; }
.inscription-note.erreur::before { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Ccircle cx='8' cy='8' r='8' fill='%23D4443B'/%3E%3Cpath d='M8 4.3v4.4' stroke='white' stroke-width='1.8' stroke-linecap='round'/%3E%3Ccircle cx='8' cy='11.6' r='1.05' fill='white'/%3E%3C/svg%3E"); }
.inscription-note.reussi { padding: 10px 18px 10px 12px; border-radius: 14px; background: #E6F8F4; border: 1px solid #B8EBE1; color: #00614E; font-size: 1rem; font-weight: 600; }
.inscription-note.reussi::before { width: 22px; height: 22px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Ccircle cx='8' cy='8' r='8' fill='%233FA95A'/%3E%3Cpath d='m4.8 8.2 2.2 2.2 4.3-4.6' fill='none' stroke='white' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); }
.inscription.fait .inscription-rang { display: none; }
@keyframes note-entree { from { opacity: 0; transform: translateY(-4px); } }
@keyframes secousse { 20%, 60% { transform: translateX(-4px); } 40%, 80% { transform: translateX(4px); } }

/* ───────── Captures de l'app ───────── */
.capture img { width: 100%; border-radius: clamp(8px, 1.1vw, 14px); border: 1px solid rgba(45, 52, 54, .1); box-shadow: var(--ombre); }
.capture figcaption { margin-top: 14px; color: var(--texte-doux); font-size: .92rem; text-align: center; }
.vitrine {
  margin-top: clamp(40px, 6vw, 72px);
  padding: clamp(10px, 2.6vw, 36px);
  border-radius: clamp(18px, 3vw, 40px);
  background:
    linear-gradient(115deg, #DDEEFB 0%, #EAE8FC 28%, #FCE5F0 52%, #FBEBE7 76%, #FFF8EB 100%);
}
.encadree { padding: clamp(16px, 2.6vw, 36px); border-radius: clamp(20px, 2.6vw, 32px); background: var(--fond); }
.encadree figcaption { color: var(--sombre); }

/* ───────── Bandes ───────── */
.bande { padding: clamp(64px, 9vw, 120px) 0; }
.bande.doux { background: var(--doux); }
.tete { max-width: 740px; margin-bottom: clamp(32px, 4.5vw, 56px); }
.deux { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: clamp(32px, 6vw, 80px); align-items: center; }

/* ───────── Cartes de couleur ───────── */
.cartes { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.carte { display: flex; flex-direction: column; padding: clamp(24px, 2.6vw, 32px); border-radius: 26px; background: var(--fond); }
.carte-icone { width: 34px; height: 34px; margin-bottom: 20px; color: var(--ton); }
.carte h3 { color: var(--ton); font-size: clamp(1.3rem, 2vw, 1.55rem); line-height: 1.15; font-weight: 800; letter-spacing: -.025em; }
.carte p { margin-top: 12px; color: var(--sombre); font-size: 1.02rem; line-height: 1.5; font-weight: 500; }
.carte .legende { margin-top: auto; padding-top: 26px; color: var(--ton); font-size: .74rem; font-weight: 750; letter-spacing: .09em; text-transform: uppercase; }
.suite { max-width: 640px; margin: 36px auto 0; color: var(--texte-doux); text-align: center; }
/* Pas de mot laissé seul en fin de paragraphe. */
.carte p, .gestes p, .preuves p, .suite, .capture figcaption, .faq details p { text-wrap: pretty; }

/* ───────── Composer ───────── */
.gestes { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(24px, 3vw, 40px); margin: clamp(44px, 6vw, 72px) 0; }
.gestes svg, .preuves svg { flex: none; width: 44px; height: 44px; padding: 11px; border-radius: 13px; background: var(--fond); color: var(--ton); }
.gestes h3 { margin-top: 16px; }
.gestes p, .preuves p { margin-top: 6px; color: var(--texte-doux); font-size: .97rem; line-height: 1.55; }
.duo { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(20px, 3vw, 32px); }

/* ───────── Agents ───────── */
.preuves { display: grid; gap: 24px; margin-top: 36px; }
.preuves li { display: flex; gap: 16px; }

/* ───────── Questions ───────── */
.faq { border-top: 1px solid #DFE6E9; }
.faq details { border-bottom: 1px solid #DFE6E9; }
.faq summary { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 22px 0; color: var(--encre); font-size: 1.1rem; font-weight: 650; letter-spacing: -.012em; cursor: pointer; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; flex: none; width: 12px; height: 12px; border-right: 2px solid var(--bleu); border-bottom: 2px solid var(--bleu); transform: translateY(-3px) rotate(45deg); transition: transform .34s cubic-bezier(.2, .7, .2, 1); }
.faq details[open] summary::after { transform: translateY(3px) rotate(-135deg); }
/* Pendant la fermeture, le bloc reste ouvert le temps de glisser : la flèche, elle, se retourne tout de suite. */
.faq details.fermeture summary::after { transform: translateY(-3px) rotate(45deg); }
.faq details p { max-width: 660px; padding-bottom: 24px; color: var(--texte-doux); }

/* ───────── Appel final ───────── */
.final { padding: clamp(40px, 7vw, 88px) clamp(20px, 5vw, 64px); border-radius: clamp(24px, 3.4vw, 40px); background: var(--fond); text-align: center; }
.final-marque { width: 56px; height: 56px; margin: 0 auto 24px; }
.final h2 { color: var(--ton); }
.final .chapo { max-width: 520px; margin: 16px auto 30px; color: var(--sombre); }
.final .inscription-note { color: var(--sombre); }
.final .inscription-note.erreur { color: #9B1F1F; }
.final .inscription-note.reussi { color: #00614E; }
.final .inscription-rang { border-color: transparent; }

/* ───────── Pied ───────── */
.pied { padding: 36px 0 44px; border-top: 1px solid var(--trait); color: var(--texte-doux); font-size: .9rem; }
.pied-rang { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 28px; }
.pied-rang img { width: auto; height: 26px; }
.pied a { color: var(--encre); font-weight: 600; text-underline-offset: 3px; }
.pied-marques { flex-basis: 100%; font-size: .8rem; color: #636E72; }

/* ───────── Apparition au défilement ───────── */
.js .apparait { opacity: 0; transform: translateY(16px); transition: opacity .6s ease, transform .6s cubic-bezier(.2, .7, .2, 1); }
.js .apparait.vu { opacity: 1; transform: none; }

/* ───────── Écrans plus étroits ───────── */
@media (max-width: 980px) {
  .cartes { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .gestes { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .deux { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 820px) {
  .nav-liens { display: none; }
  .nav-rang { justify-content: space-between; }
  .duo { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 760px) {
  .flottant.large { display: none; }
  .flottant.petit { display: grid; opacity: .9; }
}
@media (max-width: 620px) {
  body { font-size: 16px; }
  .cartes, .gestes { grid-template-columns: minmax(0, 1fr); }
  .inscription-rang { flex-direction: column; }
  .inscription input[type="email"] { text-align: center; }
  .bouton { width: 100%; }
  .nav .bouton { width: auto; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
  .js .apparait { opacity: 1; transform: none; }
}
