/* Styles propres à chaque écran : accueil (scène 3D), assistant (plan), comparateur, kit, bloqué, modèles, offres, accès. */

/* ————— accueil ————— */
.heros { position: relative; margin: -4px 0 18px; }
.scene { position: relative; height: min(46vh, 350px); margin: 0 calc(-1 * var(--marge)); touch-action: pan-y; }
.scene-canvas { position: absolute; inset: 0; width: 100% !important; height: 100% !important; display: block; opacity: 0; transition: opacity 0.9s var(--ressort); }
.scene.prete .scene-canvas { opacity: 1; }
.scene.prete .tel-repli { opacity: 0; transform: scale(0.92); }
.scene-sol { position: absolute; left: 15%; right: 15%; bottom: 4%; height: 34px; border-radius: 50%; background: radial-gradient(closest-side, rgba(77, 141, 255, 0.45), transparent); pointer-events: none; }
.heros .entete { position: relative; margin-top: -26px; }
.heros h1 { font-size: clamp(2.6rem, 12vw, 3.8rem); line-height: 1; padding-top: 0.08em; }

/* le téléphone en CSS (repli de la 3D) */
.tel-repli { position: absolute; left: 50%; top: 50%; width: 150px; height: 300px; margin: -150px 0 0 -75px; perspective: 900px; transition: opacity 0.6s, transform 0.6s var(--ressort); }
.tel-ecran {
  position: absolute; inset: 0; border-radius: 30px; padding: 26px 14px 18px;
  background: linear-gradient(170deg, #121a44, #070a18 70%); border: 2px solid rgba(127, 176, 255, 0.45);
  box-shadow: 0 0 0 6px #0c1130, 0 0 0 7px rgba(127, 176, 255, 0.25), 0 40px 80px -30px rgba(77, 101, 255, 0.9), 0 0 60px -10px rgba(155, 107, 255, 0.6);
  display: grid; grid-template-columns: 1fr 1fr; grid-auto-rows: min-content; gap: 8px;
  transform: rotateY(-18deg) rotateX(8deg); animation: tel-balance 7s ease-in-out infinite;
  background-image: linear-gradient(rgba(127, 176, 255, 0.08) 1px, transparent 1px), linear-gradient(90deg, rgba(127, 176, 255, 0.08) 1px, transparent 1px), linear-gradient(170deg, #121a44, #070a18 70%);
  background-size: 14px 14px, 14px 14px, auto;
}
@keyframes tel-balance { 50% { transform: rotateY(14deg) rotateX(4deg) translateY(-6px); } }
.tel-ecran .b { display: block; border-radius: 7px; opacity: 0; animation: brique 0.7s var(--ressort-rebond) both; box-shadow: 0 0 14px -2px currentColor; }
.tel-ecran .b1 { grid-column: 1 / -1; height: 10px; background: var(--cyan); color: var(--cyan); animation-delay: 0.3s; }
.tel-ecran .b2 { grid-column: 1 / -1; height: 62px; background: linear-gradient(120deg, #2f5bea, #6d3fe0); color: #4d8dff; animation-delay: 0.45s; }
.tel-ecran .b3, .tel-ecran .b4, .tel-ecran .b5, .tel-ecran .b6 { height: 42px; }
.tel-ecran .b3 { background: #6d3fe0; color: #6d3fe0; animation-delay: 0.6s; }
.tel-ecran .b4 { background: #4d8dff; color: #4d8dff; animation-delay: 0.7s; }
.tel-ecran .b5 { background: #2fc6e0; color: #3ee6ff; animation-delay: 0.8s; }
.tel-ecran .b6 { background: #9b6bff; color: #9b6bff; animation-delay: 0.9s; }
.tel-ecran .b7 { grid-column: 1 / -1; height: 24px; border-radius: 999px; background: var(--or); color: var(--or); animation-delay: 1.05s; margin-top: 6px; }
.tel-ecran .b8 { grid-column: 1 / -1; width: 50%; height: 4px; justify-self: center; background: #dfe6ff; color: #dfe6ff; animation-delay: 1.15s; margin-top: 4px; }
@keyframes brique { from { opacity: 0; transform: translate3d(40px, -30px, 0) rotate(18deg) scale(0.6); } to { opacity: 1; transform: none; } }
.sans3d .tel-repli { opacity: 1 !important; transform: none !important; }

/* ————— assistant : le plan de construction ————— */
.plan { padding: 16px; background-image: linear-gradient(rgba(62, 230, 255, 0.07) 1px, transparent 1px), linear-gradient(90deg, rgba(62, 230, 255, 0.07) 1px, transparent 1px), linear-gradient(160deg, rgba(20, 40, 100, 0.65), rgba(10, 14, 34, 0.75)); background-size: 18px 18px, 18px 18px, auto; border-color: rgba(62, 230, 255, 0.25); }
.plan-tete { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; }
.plan-titre { font: 500 0.66rem/1 var(--police-mono); color: var(--cyan); text-transform: uppercase; letter-spacing: 0.06em; }
.plan-compte { font: 600 0.75rem/1 var(--police-mono); color: var(--texte); }
.plan-pieces { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.piece {
  position: relative; display: grid; gap: 4px; min-height: 64px; padding: 10px 12px; border-radius: 12px;
  border: 1px dashed rgba(127, 176, 255, 0.35); color: var(--texte-pale); font-size: 0.78rem; line-height: 1.3;
  transition: border-color 0.4s, background 0.5s, color 0.4s, transform 0.6s var(--ressort-rebond), box-shadow 0.5s;
}
.piece:first-child, .piece:nth-child(2) { grid-column: span 1; }
.piece-n { font: 600 0.62rem/1 var(--police-mono); color: var(--texte-pale); }
.piece-texte { overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.piece.active { border-color: var(--cyan); color: var(--texte-doux); box-shadow: 0 0 0 1px rgba(62, 230, 255, 0.3), 0 0 24px -8px rgba(62, 230, 255, 0.8); }
.piece.posee { border-style: solid; border-color: rgba(127, 176, 255, 0.5); color: var(--texte); background: linear-gradient(135deg, rgba(47, 91, 234, 0.55), rgba(109, 63, 224, 0.45)); animation: pose 0.6s var(--ressort-rebond); }
.piece.posee .piece-n { color: var(--cyan); }
.piece.posee::after { content: "✓"; position: absolute; top: 8px; right: 10px; font-size: 0.75rem; color: var(--jade); }
@keyframes pose { 0% { transform: translateY(-14px) scale(1.06) rotate(-2deg); } 100% { transform: none; } }
.plan-barre { height: 3px; margin-top: 14px; border-radius: 3px; background: rgba(127, 176, 255, 0.15); overflow: hidden; }
.plan-barre span { display: block; height: 100%; background: linear-gradient(90deg, var(--cyan), var(--violet), var(--or)); transform: scaleX(0); transform-origin: left; transition: transform 0.7s var(--ressort); }
.plan.assemble .piece { animation: assemble 0.9s var(--ressort) both; animation-delay: calc(var(--i) * 70ms); }
@keyframes assemble { 40% { transform: scale(0.94); box-shadow: 0 0 30px -4px rgba(62, 230, 255, 0.9); } 100% { transform: none; } }
.etape-compte { margin: 0; font: 500 0.68rem/1 var(--police-mono); color: var(--cyan); text-transform: uppercase; letter-spacing: 0.06em; }
.pas-a-pas .etape.vient-droite { animation: vient-droite 0.5s var(--ressort) both; }
.pas-a-pas .etape.vient-gauche { animation: vient-gauche 0.5s var(--ressort) both; }
@keyframes vient-droite { from { opacity: 0; transform: translateX(40px); } }
@keyframes vient-gauche { from { opacity: 0; transform: translateX(-40px); } }
.etapes-nav { display: flex; gap: 10px; justify-content: space-between; }
.etapes-nav .bouton { flex: 1; }
.pas-a-pas [data-envoyer] { width: 100%; }
.preparation { display: grid; gap: 10px; }
.fichiers h2 { margin-top: 4px; }
.fichiers-liste { display: grid; gap: 14px; }
.fichier { padding: 14px; border-radius: 16px; border: 1px solid rgba(62, 230, 255, 0.25); background: rgba(8, 12, 30, 0.6); }
.fichiers-liste > .fichier { animation: plan-arrive 0.8s var(--ressort) both; animation-delay: calc(0.1s + var(--i, 0) * 140ms); }
@keyframes plan-arrive { from { opacity: 0; transform: translateY(30px) rotateX(-25deg) scale(0.96); } }
.fichier-tete { display: flex; align-items: center; gap: 10px; }
.fichier-tete h3 { margin: 0; font-family: var(--police-mono); font-size: 0.85rem; font-weight: 600; text-transform: none; }
.fichier-icone svg { width: 28px; height: 28px; }
.fichier pre { max-height: 220px; }

/* ————— comparateur ————— */
.filtres { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; padding: 14px; border-radius: var(--rayon); }
.filtres .champ > span { font: 500 0.66rem/1 var(--police-mono); text-transform: uppercase; color: var(--texte-doux); }
.filtres-compte { grid-column: 1 / -1; margin: 0; font: 500 0.7rem/1 var(--police-mono); color: var(--cyan); }
.liste-outils { display: grid; gap: 0; }
.outil-tete { display: flex; align-items: center; gap: 12px; }
.outil-tete h3 { margin: 0; }
.outil-initiale { width: 40px; height: 40px; flex: none; display: grid; place-items: center; border-radius: 12px; font: 800 1.3rem/1 var(--police-titre); color: #fff; background: linear-gradient(135deg, #2f5bea, #6d3fe0); box-shadow: 0 0 20px -6px rgba(77, 141, 255, 0.9); }
.formules { list-style: none; padding: 0; margin: 12px 0 6px; display: grid; gap: 8px; }
.formules li { padding: 10px 12px; border-radius: 12px; background: rgba(8, 12, 30, 0.5); border: 1px solid var(--filet); font-size: 0.92rem; }
.formule-prix { font-weight: 650; }
.outil-equip { font-size: 0.85rem; margin-bottom: 0; }

/* ————— kit ————— */
.kit-apercu { display: grid; place-items: center; margin: 4px 0 18px; transition: transform 0.4s var(--ressort); }
.kit-tel {
  --kit: #0aa77a;
  width: 156px; height: 262px; border-radius: 28px; padding: 18px 12px 14px; display: grid; grid-template-rows: auto auto auto 1fr auto; gap: 10px;
  background: linear-gradient(170deg, #10183c, #070a18 75%);
  border: 2px solid color-mix(in srgb, var(--kit) 70%, white 10%);
  box-shadow: 0 0 0 6px #0b1030, 0 30px 70px -30px var(--kit), 0 0 50px -12px var(--kit);
  transition: border-color 0.4s, box-shadow 0.4s;
}
.kit-encoche { width: 52px; height: 6px; border-radius: 6px; background: rgba(255, 255, 255, 0.18); justify-self: center; }
.kit-nom { margin: 0; font: 800 1.3rem/1 var(--police-titre); text-transform: uppercase; color: #fff; text-align: center; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.kit-heros { height: 54px; border-radius: 14px; background: linear-gradient(135deg, var(--kit), color-mix(in srgb, var(--kit) 40%, #6d3fe0)); transition: background 0.4s; }
.kit-produits { display: flex; flex-wrap: wrap; gap: 6px; align-content: start; }
.kit-produits span { padding: 4px 8px; border-radius: 999px; font-size: 0.7rem; color: #fff; background: color-mix(in srgb, var(--kit) 30%, #10183c); border: 1px solid color-mix(in srgb, var(--kit) 60%, transparent); animation: monte 0.4s var(--ressort) both; }
.kit-bouton { height: 32px; border-radius: 999px; display: grid; place-items: center; font-size: 0.9rem; background: var(--kit); color: #fff; }
.kit-tel.envol { animation: envol 1.1s var(--ressort); }
@keyframes envol { 30% { transform: translateY(-10px) rotateY(180deg) scale(1.05); } 100% { transform: rotateY(360deg); } }
.champ-couleur { display: flex; align-items: center; gap: 10px; }
.pastille { --kit: #0aa77a; width: 50px; height: 50px; flex: none; border-radius: 14px; background: var(--kit); border: 1px solid var(--filet-fort); box-shadow: 0 0 20px -6px var(--kit); transition: background 0.3s; }

/* ————— je suis bloqué ————— */
.fil { list-style: none; margin: 0 0 4px; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.fil:empty { display: none; }
.fil li { font-size: 0.78rem; padding: 6px 10px; border-radius: 999px; background: rgba(77, 141, 255, 0.14); border: 1px solid rgba(127, 176, 255, 0.25); color: var(--texte-doux); animation: monte 0.4s var(--ressort) both; }
.fil li + li::before { content: "→ "; color: var(--cyan); }
.choix-liste { display: grid; gap: 10px; }
.choix-liste .bouton { margin: 0; justify-content: flex-start; text-align: left; border-radius: 16px; padding: 14px 18px; min-height: 54px; }
.choix-liste .bouton::before { content: ""; width: 8px; height: 8px; flex: none; border-radius: 50%; background: var(--cyan); box-shadow: 0 0 10px var(--cyan); }
.glisse-avant { animation: vient-droite 0.5s var(--ressort) both; }
.glisse-retour { animation: vient-gauche 0.5s var(--ressort) both; }
.solution { border-color: rgba(59, 227, 160, 0.4); background: linear-gradient(160deg, rgba(20, 80, 70, 0.5), rgba(14, 18, 38, 0.7)); }
.solution .badge { color: var(--jade); background: rgba(59, 227, 160, 0.12); border-color: rgba(59, 227, 160, 0.35); }
.solution .bouton { width: 100%; }

/* ————— modèles ————— */
.grille-modeles { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.modele { margin: 0; display: grid; gap: 10px; align-content: space-between; padding: 16px; }
.modele h3 { margin: 0; font-size: 1.25rem; }
.modele-icone svg { width: 30px; height: 30px; }
.modele-actions { display: grid; gap: 6px; }
.modele-actions .bouton { min-height: 44px; padding: 10px 12px; font-size: 0.9rem; margin: 0; }
.apercu-modele { animation: vt-entree 0.55s var(--ressort) both; }

/* ————— offres ————— */
.offres-liste { display: grid; gap: 14px; perspective: 1000px; }
.offre { margin: 0; padding: 22px 20px; transition: transform 0.5s var(--ressort); transform-style: preserve-3d; overflow: hidden; }
.offre::before { content: ""; position: absolute; inset: 0; pointer-events: none; background: radial-gradient(260px circle at var(--px, 80%) var(--py, 0%), rgba(127, 176, 255, 0.18), transparent 60%); }
.offre-n { margin: 0; font: 500 0.66rem/1 var(--police-mono); color: var(--texte-pale); }
.offre h2 { margin: 8px 0 6px; font-size: 1.9rem; }
.offre .prix { font: 500 0.78rem/1.4 var(--police-mono); color: var(--cyan); margin: 0 0 12px; }
.offre ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.offre li { position: relative; padding-left: 26px; color: var(--texte-doux); }
.offre li::before { content: ""; position: absolute; left: 2px; top: 0.45em; width: 12px; height: 7px; border-left: 2px solid var(--jade); border-bottom: 2px solid var(--jade); transform: rotate(-45deg); }
.offre-vie { border-color: rgba(240, 192, 98, 0.45); background: linear-gradient(160deg, rgba(90, 64, 20, 0.55), rgba(30, 22, 50, 0.7) 50%, rgba(14, 18, 38, 0.75)); box-shadow: 0 30px 60px -30px rgba(240, 192, 98, 0.6), var(--ombre); }
.offre-vie .prix, .offre-vie .offre-n { color: var(--or); }
.offre-vie h2 { background: linear-gradient(110deg, #fff, #f6d48a 50%, var(--or)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.offre-vie li::before { border-color: var(--or); }
.offres .bouton.or { width: 100%; margin-top: 18px; }

/* ————— mon accès ————— */
.carte-acces { overflow: hidden; }
.acces-tete { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.acces-icone svg { width: 40px; height: 40px; }
.acces-orbe { width: 16px; height: 16px; border-radius: 50%; background: var(--texte-pale); box-shadow: 0 0 0 6px rgba(139, 150, 191, 0.15); animation: pouls 2.4s ease-in-out infinite; }
.temoin-or .acces-orbe { background: var(--or); box-shadow: 0 0 18px var(--or), 0 0 0 6px rgba(240, 192, 98, 0.18); }
.temoin-ouvert .acces-orbe { background: var(--jade); box-shadow: 0 0 18px var(--jade), 0 0 0 6px rgba(59, 227, 160, 0.18); }
.temoin-bientot .acces-orbe { background: var(--or); }
.temoin-or { border-color: rgba(240, 192, 98, 0.4); }
@keyframes pouls { 50% { transform: scale(1.25); } }
.mon-acces .bouton { width: 100%; }

/* ————— erreurs ————— */
.carte.erreur { border-color: rgba(255, 107, 129, 0.4); }
.formules .badge { border-radius: 10px; }
