/* =========================================================
   Page d'attente facilivre.fr — hero + scène 3D
   La scène est dimensionnée en `em` : sa taille de police (--u)
   fixe l'échelle de tout le décor.
   ========================================================= */

body.accueil {
  background:
    radial-gradient(55% 65% at 76% 56%, rgba(0, 197, 148, 0.17), transparent 70%),
    radial-gradient(38% 42% at 6% 0%, rgba(0, 197, 148, 0.08), transparent 70%),
    var(--main);
  color: #fff;
  overflow-x: clip;
}

/* Filet de sécurité : liens ajoutés par les détecteurs de données d'iOS dans la scène */
.scene a[x-apple-data-detectors] {
  color: inherit !important;
  text-decoration: none !important;
  pointer-events: none;
}

.sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.ico {
  width: 1em;
  height: 1em;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ---------- Barre du haut ---------- */
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 26px clamp(20px, 4vw, 56px) 0;
}

.topbar-logo img {
  display: block;
  height: 32px;
  width: auto;
}

.topbar-contact {
  font-size: 14px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.66);
  text-decoration: none;
  transition: color 0.2s ease;
}

.topbar-contact:hover {
  color: #fff;
}

/* ---------- Hero ---------- */
.hero {
  flex: 1;
  width: 100%;
  max-width: 1500px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
  align-items: center;
  gap: clamp(16px, 3vw, 48px);
  padding: 12px clamp(20px, 4vw, 56px);
}

.hero-texte {
  max-width: 680px;
  animation: monter 0.9s cubic-bezier(0.2, 0.7, 0.2, 1) both;
}

.pastille {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 7px 14px;
  border-radius: 999px;
  border: 1px solid rgba(0, 197, 148, 0.4);
  background: rgba(0, 197, 148, 0.08);
  color: var(--action);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.pastille-point,
.live-point {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--action);
  box-shadow: 0 0 0 0 rgba(0, 197, 148, 0.6);
  animation: battement 2.2s ease-out infinite;
}

.accroche {
  margin: 22px 0 14px;
  font-size: 15px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.58);
}

.hero-texte h1 {
  text-wrap: balance;
  font-size: clamp(34px, min(3.9vw, 6.8vh), 70px);
  font-weight: 800;
  line-height: 1.03;
  letter-spacing: -0.038em;
}

.hero-texte h1 .accent {
  display: block;
  background: linear-gradient(100deg, #00c594 0%, #5df0c6 55%, #c8fff0 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.sous-titre {
  margin-top: 22px;
  max-width: 34em;
  font-size: clamp(16px, 1.2vw, 20px);
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.7);
}

.actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 20px;
  margin-top: 32px;
}

.btn-contact {
  display: inline-block;
  padding: 15px 28px;
  border-radius: 12px;
  background: var(--action);
  color: var(--main);
  font-weight: 800;
  text-decoration: none;
  box-shadow: 0 10px 30px -10px rgba(0, 197, 148, 0.7);
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn-contact:hover {
  background: #1fe0ae;
  transform: translateY(-2px);
  box-shadow: 0 16px 36px -12px rgba(0, 197, 148, 0.85);
}

.actions-mail {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 15px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.75);
}

.btn-copier {
  padding: 6px 12px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 8px;
  background: transparent;
  color: rgba(255, 255, 255, 0.85);
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: border-color 0.2s ease, color 0.2s ease;
}

.btn-copier:hover {
  border-color: var(--action);
  color: #fff;
}

.btn-copier.copie {
  border-color: var(--action);
  color: var(--action);
}

.atouts {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 10px 22px;
  margin-top: 30px;
  font-size: 14px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.72);
}

.atouts li {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.atouts .ico {
  color: var(--action);
  font-size: 16px;
  stroke-width: 2.6;
}

/* ---------- Pied de page ---------- */
.pied {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 24px;
  padding: 18px clamp(20px, 4vw, 56px) 22px;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.5);
}

.pied nav {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 20px;
}

.pied a {
  color: rgba(255, 255, 255, 0.6);
  text-decoration: none;
}

.pied a:hover {
  color: #fff;
  text-decoration: underline;
}

/* =========================================================
   Scène 3D
   ========================================================= */
.scene {
  --u: clamp(5px, min(0.7vw, calc((100vh - 180px) / 55)), 13px);
  position: relative;
  font-size: var(--u);
  text-align: left;
  width: 66em;
  height: 52em;
  margin: 0 auto;
  perspective: 190em;
  perspective-origin: 55% 22%;
  /* L'opacité est animée ici et non sur le plateau : sur un élément en preserve-3d,
     elle aplatirait les plans de profondeur */
  animation: fondu 1.2s ease 0.15s both;
}

/* Ombre portée au sol, pour ancrer le décor */
.scene::before {
  content: '';
  position: absolute;
  left: 8%;
  right: 4%;
  bottom: -3em;
  height: 10em;
  background:
    radial-gradient(closest-side, rgba(0, 0, 0, 0.6), transparent),
    radial-gradient(closest-side, rgba(0, 197, 148, 0.18), transparent);
  filter: blur(1.2em);
  pointer-events: none;
}

.scene-plateau {
  --rx: 8deg;
  --ry: -15deg;
  --reflet: 50%;
  position: absolute;
  inset: 1em;
  transform-style: preserve-3d;
  transform: rotateX(var(--rx)) rotateY(var(--ry));
  animation: apparaitre 1.4s cubic-bezier(0.2, 0.7, 0.2, 1) 0.15s both;
}

.scene-plateau > * {
  position: absolute;
}

/* ---------- Fenêtre du tableau de bord ---------- */
.dash {
  left: 8em;
  top: 3em;
  width: 54em;
  height: 40.6em;
  border-radius: 1.4em;
  background: #FBFFFE;
  color: var(--text-primary);
  overflow: hidden;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.5),
    0 3em 7em rgba(0, 0, 0, 0.55),
    0 0 9em rgba(0, 197, 148, 0.22);
}

/* Reflet lumineux qui glisse sur la vitre quand la scène pivote */
.dash::after,
.tel-ecran::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 3;
  pointer-events: none;
  background: linear-gradient(112deg, transparent 38%, rgba(255, 255, 255, 0.42) 49%, transparent 60%);
  background-size: 260% 100%;
  background-position: var(--reflet) 0;
  opacity: 0.55;
}

.dash-barre {
  height: 3.4em;
  display: flex;
  align-items: center;
  gap: 1.2em;
  padding: 0 1.4em;
  background: #F1F7F6;
  border-bottom: 1px solid #DFECEA;
}

.dash-points {
  display: flex;
  gap: 0.5em;
}

.dash-points i {
  width: 0.9em;
  height: 0.9em;
  border-radius: 50%;
  background: #CBD8D6;
}

.dash-titre {
  flex: 1;
  font-size: 1.05em;
  font-weight: 700;
  color: #4A6361;
}

.dash-corps {
  display: grid;
  grid-template-columns: 13em 1fr;
  height: calc(100% - 3.4em);
}

/* Barre latérale sombre, comme dans le logiciel */
.dash-menu {
  display: flex;
  flex-direction: column;
  gap: 0.25em;
  padding: 1.7em 0.9em;
  background: var(--main);
}

.dash-logo {
  width: 9.6em;
  height: auto;
  margin: 0 0 1.6em 0.6em;
}

.menu-titre {
  margin: 0 0 0.6em 0.8em;
  font-size: 0.72em;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.45);
}

.menu-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.7em 0.9em;
  border-radius: 0.7em;
  font-size: 1em;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.72);
}

.menu-item.actif {
  background: rgba(0, 197, 148, 0.14);
  color: var(--action);
}

.menu-badge {
  min-width: 1.7em;
  padding: 0.1em 0.5em;
  border-radius: 1em;
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  font-size: 0.8em;
  font-style: normal;
  font-weight: 800;
  text-align: center;
}

.dash-contenu {
  padding: 1.6em 1.9em;
  background: #F8FAFA;
}

.dash-entete {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1em;
}

.dash-entete > div {
  display: flex;
  flex-direction: column;
}

.dash-h {
  font-size: 1.6em;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.dash-date {
  font-size: 0.9em;
  font-weight: 600;
  color: #5A6E6C;
}

.dash-bouton {
  padding: 0.75em 1.2em;
  border-radius: 0.7em;
  background: var(--action);
  color: var(--main);
  font-size: 0.95em;
  font-weight: 800;
  white-space: nowrap;
}

.kpis {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.9em;
  margin: 1.3em 0 1.4em;
}

.kpi {
  display: flex;
  flex-direction: column;
  gap: 0.45em;
  padding: 1em 1.1em;
  border: 1px solid #E5ECEB;
  border-radius: 1em;
  background: #fff;
}

.kpi-titre {
  font-size: 0.85em;
  font-weight: 600;
  color: #5A6E6C;
}

.kpi-ligne {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5em;
}

.kpi-pct,
.kpi-badge {
  padding: 0.25em 0.6em;
  border-radius: 1em;
  font-size: 0.78em;
  font-weight: 800;
}

.kpi-pct {
  background: rgba(0, 197, 148, 0.14);
  color: #00936f;
}

.kpi-badge {
  background: #FEF3C7;
  color: #B45309;
}

/* Jauges (avancement, forfait SMS, progression du livreur) */
.jauge {
  display: block;
  height: 0.45em;
  border-radius: 1em;
  background: #EEF3F2;
  overflow: hidden;
}

.jauge i {
  display: block;
  height: 100%;
  width: calc(var(--p) * 1%);
  border-radius: inherit;
  background: var(--action);
  transition: width 0.8s cubic-bezier(0.3, 0.7, 0.2, 1);
}

[data-jauge="avancement"],
[data-jauge="tel"] {
  --p: 33;
}

[data-jauge="sms"] {
  --p: 6.5;
}

.jauge-sms i {
  background: #8B5CF6;
}

.dash-section {
  display: block;
  margin-bottom: 0.7em;
  font-size: 1.1em;
  font-weight: 800;
}

.kpi strong {
  font-size: 1.7em;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.kpi strong,
.kpi b {
  display: inline-block;
}

.kpi .saut {
  animation: saut 0.7s cubic-bezier(0.3, 1.6, 0.5, 1);
}

.creneaux {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.7em;
  transition: opacity 0.4s ease;
}

.creneaux.reinit {
  opacity: 0;
}

.creneau {
  position: relative;
  display: grid;
  grid-template-columns: 5.2em 1fr auto;
  align-items: center;
  gap: 0.8em;
  padding: 0.85em 1.1em;
  border: 1px solid #E5ECEB;
  border-radius: 1em;
  background: #fff;
  overflow: hidden;
  isolation: isolate;
  transition: border-color 0.4s ease, box-shadow 0.4s ease;
}

/* Remplissage vert au passage à « Livré » */
.creneau::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(90deg, rgba(0, 197, 148, 0.16), rgba(0, 197, 148, 0.06));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.9s cubic-bezier(0.6, 0, 0.2, 1);
}

.creneau[data-etat="livre"]::before {
  transform: scaleX(1);
}

.creneau[data-etat="route"] {
  border-color: rgba(245, 158, 11, 0.55);
  box-shadow: 0 0 0 0.3em rgba(245, 158, 11, 0.12);
}

.creneau-heure {
  font-size: 1.15em;
  font-weight: 800;
  color: #4A6361;
}

.creneau-infos {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.creneau-infos strong {
  font-size: 1.2em;
  font-weight: 700;
}

.creneau-infos span {
  font-size: 0.95em;
  color: #7C9492;
  white-space: nowrap;
}

/* Pastilles d'état (planning et téléphone) */
.etat,
.carte-etat {
  display: inline-flex;
  align-items: center;
  padding: 0.45em 0.95em;
  border-radius: 2em;
  font-size: 0.95em;
  font-weight: 800;
  background: #DBEAFE;
  color: #1D4ED8;
  transition: background 0.35s ease, color 0.35s ease;
}

[data-etat="route"] .etat,
.tel[data-etat="route"] .carte-etat {
  background: #FEF3C7;
  color: #B45309;
}

[data-etat="livre"] .etat,
.tel[data-etat="livre"] .carte-etat {
  background: rgba(0, 197, 148, 0.16);
  color: #00936f;
}

.etat-txt {
  display: inline-block;
}

.etat-txt.change {
  animation: changer 0.45s ease;
}

/* ---------- Téléphone du livreur ---------- */
.tel {
  font-size: 0.94em;
  /* Le téléphone masque entièrement la barre latérale sous le logo (pas de libellés coupés) */
  left: 7.6em;
  top: 13.2em;
  width: 19.5em;
  height: 38.5em;
  padding: 0.6em;
  border-radius: 3.3em;
  background: linear-gradient(145deg, #2a3c3b, #0a1716 40%, #050d0c);
  box-shadow:
    inset 0 0 0 0.12em rgba(255, 255, 255, 0.22),
    0 0 0 0.08em rgba(0, 197, 148, 0.35),
    0 3em 6em rgba(0, 0, 0, 0.6),
    0 0 6em rgba(0, 197, 148, 0.25);
  transform: translateZ(10em);
}

.tel-ecran {
  position: relative;
  height: 100%;
  border-radius: 2.75em;
  overflow: hidden;
  background: #F8FAFA;
  color: var(--text-primary);
}

.tel-ilot {
  position: absolute;
  top: 0.8em;
  left: 50%;
  width: 5.6em;
  height: 1.6em;
  margin-left: -2.8em;
  border-radius: 1em;
  background: #000;
  z-index: 2;
}

.tel-statut {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 3.2em;
  padding: 0.9em 1.7em 0;
  background: var(--main);
  color: #fff;
  font-size: 0.95em;
  font-weight: 700;
}

.tel-reseau {
  display: flex;
  align-items: flex-end;
  gap: 0.18em;
}

.tel-reseau i {
  width: 0.28em;
  background: #fff;
  border-radius: 0.1em;
}

.tel-reseau i:nth-child(1) { height: 0.45em; }
.tel-reseau i:nth-child(2) { height: 0.7em; }
.tel-reseau i:nth-child(3) { height: 0.95em; }

.tel-entete {
  display: flex;
  flex-direction: column;
  gap: 0.2em;
  padding: 0.5em 1.5em 1.5em;
  background: var(--main);
  color: #fff;
}

.tel-h {
  font-size: 1.65em;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.tel-sous {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 0.4em;
  font-size: 0.85em;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.7);
}

.tel-sous b {
  color: #fff;
}

.jauge-tel {
  margin-top: 0.5em;
  background: rgba(255, 255, 255, 0.12);
}

.carte {
  position: relative;
  margin: -0.6em 1em 0;
  padding: 1.2em;
  border-radius: 1.3em;
  background: #fff;
  box-shadow: 0 0.8em 2em rgba(0, 21, 20, 0.12);
  transition: opacity 0.35s ease, transform 0.35s ease;
}

.carte.sortie {
  opacity: 0;
  transform: translateX(-1.5em);
}

.carte.entree {
  opacity: 0;
  transform: translateX(1.5em);
  transition: none;
}

.carte-haut {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5em;
}

.carte-etat {
  font-size: 0.8em;
}

.carte-heure {
  display: inline-flex;
  align-items: center;
  gap: 0.3em;
  font-size: 0.8em;
  font-weight: 600;
  color: #7C9492;
}

.carte-heure b {
  color: var(--text-primary);
}

.carte-nom {
  display: block;
  margin-top: 0.8em;
  font-size: 1.25em;
  font-weight: 800;
  letter-spacing: -0.01em;
}

.carte-adresse {
  display: flex;
  align-items: flex-start;
  gap: 0.35em;
  margin-top: 0.3em;
  font-size: 0.88em;
  line-height: 1.35;
  color: #5A6E6C;
}

.carte-adresse .ico {
  margin-top: 0.15em;
}

.carte-outils {
  display: flex;
  gap: 0.6em;
  margin: 1em 0;
}

.carte-outils span {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4em;
  padding: 0.6em 0.3em;
  border: 1px solid #E5ECEB;
  border-radius: 0.7em;
  white-space: nowrap;
  font-size: 0.76em;
  font-weight: 700;
  color: #4A6361;
}

.carte-action {
  position: relative;
  display: grid;
  width: 100%;
  height: 3.4em;
  border: 0;
  border-radius: 0.9em;
  font: inherit;
  font-size: 1em;
  font-weight: 800;
  background: var(--action);
  color: var(--main);
  cursor: pointer;
  transition: background 0.35s ease, color 0.35s ease, transform 0.15s ease;
}

.carte-action > span {
  grid-area: 1 / 1;
  place-self: center;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.tel[data-etat="attente"] .action-demarrer,
.tel[data-etat="route"] .action-confirmer,
.tel[data-etat="livre"] .action-livree {
  opacity: 1;
}

.tel[data-etat="route"] .carte-action {
  background: var(--main);
  color: #fff;
}

.tel[data-etat="livre"] .carte-action {
  background: rgba(0, 197, 148, 0.16);
  color: #00936f;
  cursor: default;
}

.carte-action:active {
  transform: scale(0.97);
}

/* Doigt fantôme qui « tape » sur le bouton */
.doigt {
  position: absolute;
  right: 3.2em;
  bottom: 0.4em;
  width: 3.6em;
  height: 3.6em;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
  border: 0.15em solid rgba(255, 255, 255, 0.95);
  box-shadow: 0 0.6em 1.6em rgba(0, 21, 20, 0.35);
  opacity: 0;
  pointer-events: none;
}

.doigt::after {
  content: '';
  position: absolute;
  inset: -0.15em;
  border-radius: 50%;
  border: 0.15em solid rgba(255, 255, 255, 0.9);
  opacity: 0;
}

.tel.tape .doigt {
  animation: doigt 0.95s cubic-bezier(0.3, 0.7, 0.3, 1) both;
}

.tel.tape .doigt::after {
  animation: onde 0.95s ease-out both;
}

.tel.tape .carte-action {
  animation: presse 0.95s ease both;
}

.tel-onglets {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  justify-content: space-around;
  padding: 0.9em 0.6em 1.6em;
  border-top: 1px solid #E5ECEB;
  background: #fff;
}

.tel-onglets span {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35em;
  font-size: 0.75em;
  font-weight: 700;
  color: #8FA3A0;
}

.tel-onglets .ico {
  font-size: 1.9em;
}

.tel-onglets .actif {
  color: #00936f;
}

/* ---------- Notification SMS ---------- */
.sms {
  left: 36em;
  top: 0;
  width: 27em;
  padding: 1.1em 1.3em 1.2em;
  border-radius: 1.6em;
  background: rgba(250, 252, 252, 0.97);
  color: var(--text-primary);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.6),
    0 2.5em 5em rgba(0, 0, 0, 0.5),
    0 0 5em rgba(0, 197, 148, 0.25);
  transform: translateZ(13em);
  transition: opacity 0.5s ease, translate 0.7s cubic-bezier(0.2, 1.3, 0.4, 1), scale 0.7s cubic-bezier(0.2, 1.3, 0.4, 1);
}

.sms[data-visible="non"] {
  opacity: 0;
  translate: 0 2.5em;
  scale: 0.9;
  transition: opacity 0.4s ease, translate 0.5s ease, scale 0.5s ease;
}

.sms-haut {
  display: flex;
  align-items: center;
  gap: 0.6em;
}

.sms-app {
  display: grid;
  place-items: center;
  width: 1.9em;
  height: 1.9em;
  border-radius: 0.5em;
  background: linear-gradient(160deg, #3ce3b3, #00a37a);
  color: #fff;
}

.sms-app .ico {
  stroke-width: 3;
}

.sms-source {
  flex: 1;
  font-size: 0.85em;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #7C9492;
}

.sms-quand {
  font-size: 0.85em;
  color: #8FA3A0;
}

.sms-exp {
  display: block;
  margin-top: 0.7em;
  font-size: 1.1em;
  font-weight: 800;
}

.sms-texte {
  margin-top: 0.2em;
  font-size: 1.05em;
  line-height: 1.45;
  color: #12302e;
}

/* ---------- Faisceau de synchronisation (2D, au-dessus de la scène) ---------- */
.faisceau {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
  pointer-events: none;
}

.faisceau path {
  fill: none;
  stroke-linecap: round;
}

.faisceau-trace {
  stroke: rgba(0, 197, 148, 0.5);
  stroke-width: 1.6;
  stroke-dasharray: 0.012 0.018;
  opacity: 0;
  transition: opacity 0.4s ease;
}

.faisceau-comete {
  stroke: url(#g-faisceau);
  stroke-width: 5;
  stroke-dasharray: 0.3 1.4;
  stroke-dashoffset: 0.3;
  opacity: 0;
  filter: drop-shadow(0 0 4px rgba(0, 197, 148, 1)) drop-shadow(0 0 14px rgba(0, 197, 148, 0.8));
}

.faisceau-impact {
  fill: #b6ffec;
  opacity: 0;
  filter: drop-shadow(0 0 8px rgba(0, 197, 148, 1));
}

.faisceau.tir .faisceau-trace {
  opacity: 1;
}

.faisceau.tir .faisceau-comete {
  animation: comete 0.75s cubic-bezier(0.5, 0, 0.3, 1) both;
}

.faisceau.tir .faisceau-impact {
  animation: impact 0.9s ease-out 0.55s both;
}

/* ---------- Animations ---------- */
@keyframes monter {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: none; }
}

@keyframes apparaitre {
  from { translate: 0 4em; scale: 0.94; }
  to { translate: 0 0; scale: 1; }
}

@keyframes fondu {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes battement {
  0% { box-shadow: 0 0 0 0 rgba(0, 197, 148, 0.55); }
  70%, 100% { box-shadow: 0 0 0 0.6em rgba(0, 197, 148, 0); }
}

@keyframes saut {
  0% { transform: scale(1); color: inherit; }
  35% { transform: scale(1.3); color: #00936f; }
  100% { transform: scale(1); color: #001514; }
}

@keyframes changer {
  0% { opacity: 0; transform: translateY(0.5em); }
  100% { opacity: 1; transform: none; }
}

@keyframes doigt {
  0% { opacity: 0; transform: translate(2.5em, 3em) scale(1.1); }
  35% { opacity: 1; transform: translate(0, 0) scale(1); }
  55% { opacity: 1; transform: scale(0.8); }
  75% { opacity: 1; transform: scale(1); }
  100% { opacity: 0; transform: translate(0.6em, 0.8em) scale(1); }
}

@keyframes onde {
  0%, 52% { opacity: 0; transform: scale(1); }
  60% { opacity: 1; transform: scale(1); }
  100% { opacity: 0; transform: scale(2.3); }
}

@keyframes presse {
  0%, 48% { transform: scale(1); }
  58% { transform: scale(0.95); }
  72%, 100% { transform: scale(1); }
}

@keyframes comete {
  0% { stroke-dashoffset: 0.3; opacity: 1; }
  85% { opacity: 1; }
  100% { stroke-dashoffset: -1.02; opacity: 0; }
}

@keyframes impact {
  0% { opacity: 0; r: 2; }
  20% { opacity: 1; r: 7; }
  100% { opacity: 0; r: 18; }
}

/* ---------- Adaptation aux écrans ---------- */
@media (max-width: 1023px) {
  .hero {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 0;
    padding-top: 28px;
    padding-bottom: 24px;
  }

  /* Les éléments du texte deviennent des enfants directs du hero pour intercaler la scène */
  .hero-texte {
    display: contents;
  }

  .hero-texte > * {
    max-width: 640px;
    animation: monter 0.9s cubic-bezier(0.2, 0.7, 0.2, 1) both;
  }

  .pastille { order: 1; }
  .accroche { order: 2; }
  .hero-texte h1 { order: 3; }
  .scene { order: 4; }
  .sous-titre { order: 5; }
  .actions { order: 6; }
  .atouts { order: 7; }

  .sous-titre {
    margin-left: auto;
    margin-right: auto;
  }

  .actions,
  .atouts {
    justify-content: center;
  }

  .scene {
    --u: min(calc((100vw - 32px) / 70), 9.5px);
    margin: 28px auto 8px;
  }

  .scene-plateau {
    --rx: 7deg;
    --ry: -12deg;
  }
}

@media (max-width: 600px) {
  .topbar-contact {
    display: none;
  }

  /* Le SMS est le message clé : un peu plus lisible sur téléphone */
  .sms {
    font-size: 1.12em;
    left: 30em;
  }

  .accroche {
    margin: 16px 0 10px;
    font-size: 14px;
  }

  .hero-texte h1 {
    font-size: clamp(30px, 8.4vw, 44px);
  }

  .sous-titre {
    font-size: 16px;
  }

  .actions {
    flex-direction: column;
    gap: 10px;
  }

  .pied {
    justify-content: center;
    text-align: center;
  }

  .pied nav {
    justify-content: center;
  }
}

@media (prefers-reduced-motion: reduce) {
  .scene,
  .hero-texte,
  .hero-texte > *,
  .scene-plateau,
  .pastille-point,
  .live-point {
    animation: none;
  }

  .btn-contact,
  .creneau::before,
  .sms {
    transition: none;
  }
}
