/* ============================================================
   /beta — la page d'installation
   ------------------------------------------------------------
   Chargée APRÈS style.css, dont elle réutilise les tokens, les
   boutons et le fond. Elle ne redéclare rien : elle ajoute la
   carte d'installation.

   Contrainte de conception : tenir sur UN écran de téléphone —
   logo, indicateur d'étape, un bouton principal, « Ça bloque ? ».
   Tout le reste est replié.
   ============================================================ */

/* Header statique ici, pas le header fixe de la landing : la page tient sur
   un écran, il n'y a rien à scroller derrière. */
.beta-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px max(20px, var(--safe-l)) 0 max(20px, var(--safe-r));
  max-width: 640px;
  margin: 0 auto;
}
.beta-header .brand { font-size: 1.2rem; }
.beta-header .brand img { width: 34px; height: 34px; }
.beta-back {
  font-size: 0.9rem;
  color: var(--text-2);
  text-decoration: none;
}
.beta-back:hover { color: var(--text); }

.beta {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(20px, 5vw, 48px) max(16px, var(--safe-l))
           calc(clamp(28px, 6vw, 56px) + var(--safe-b)) max(16px, var(--safe-r));
}

.beta-card {
  position: relative;
  width: 100%;
  max-width: 560px;
  padding: clamp(26px, 6vw, 44px) clamp(20px, 5vw, 40px);
  border-radius: var(--radius-lg);
  background: var(--surface);
  border: 1px solid var(--stroke);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  overflow: hidden;
}
.beta-card::after {
  content: "";
  position: absolute;
  top: -40%;
  left: 50%;
  transform: translateX(-50%);
  width: 80%;
  aspect-ratio: 2;
  background: radial-gradient(ellipse, rgba(237, 6, 102, 0.16), transparent 65%);
  pointer-events: none;
}
.beta-card > * { position: relative; z-index: 1; }

.beta-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.9rem, 7vw, 2.6rem);
  line-height: 1.06;
  letter-spacing: -0.03em;
  margin: 18px 0 0;
}

/* ---------- Indicateur d'étape ---------- */
.beta-progress { margin-top: 22px; }
.beta-progress-label {
  display: block;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-2);
  margin-bottom: 10px;
}
.beta-progress-bar {
  display: block;
  height: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  overflow: hidden;
}
.beta-progress-bar > i {
  display: block;
  height: 100%;
  width: 0;
  border-radius: 999px;
  background: var(--grad);
  transition: width 0.4s cubic-bezier(0.22, 1, 0.36, 1);
}

/* ---------- Étapes ---------- */
.beta-lead {
  color: var(--text-2);
  margin-top: 20px;
}
.beta-lead-sm { font-size: 0.95rem; margin-top: 26px; }

.beta-steps {
  list-style: none;
  margin: 26px 0 0;
  padding: 0;
  display: grid;
  gap: 14px;
}
.beta-step {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr);
  gap: 14px;
  align-items: start;
  padding: 14px 16px;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  transition: border-color 0.3s ease, background 0.3s ease, opacity 0.3s ease;
}
.beta-step.is-current {
  background: rgba(11, 7, 16, 0.45);
  border-color: rgba(237, 6, 102, 0.4);
}
.beta-step.is-todo { opacity: 0.42; }
.beta-step.is-done { opacity: 0.72; }

.beta-step-num {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 1px solid var(--stroke);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text-2);
}
.beta-step-num.is-done {
  border-color: transparent;
  background: var(--grad);
  color: #fff;
}
.beta-step.is-current .beta-step-num {
  border-color: var(--pink);
  color: var(--pink-light);
}

.beta-step-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.12rem;
  letter-spacing: -0.01em;
  line-height: 1.3;
  margin: 3px 0 0;
}
.beta-step-hint {
  color: var(--text-2);
  font-size: 0.95rem;
  margin: 8px 0 0;
}
.beta-step-cta {
  margin-top: 16px;
  width: 100%;
  padding: 15px 26px;
}
.beta-step-skip {
  display: block;
  margin: 12px auto 0;
  padding: 0;
  font-size: 0.85rem;
  color: var(--text-2);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.beta-step-skip:hover { color: var(--text); }

.beta-done {
  margin-top: 24px;
  padding: 18px 20px;
  border-radius: var(--radius-sm);
  background: rgba(237, 6, 102, 0.08);
  border: 1px solid rgba(237, 6, 102, 0.28);
}
.beta-done p { margin: 0; font-size: 0.98rem; }
.beta-done p + p { margin-top: 8px; color: var(--text-2); }

.beta-reset {
  display: block;
  margin: 18px auto 0;
  font-size: 0.85rem;
  color: var(--text-2);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.beta-reset:hover { color: var(--text); }
.beta-retry { margin-top: 20px; }

/* ---------- Ordinateur : QR ---------- */
.beta-qr {
  margin: 26px auto 0;
  width: max-content;
  padding: 14px;
  border-radius: 20px;
  background: #fff;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
}
.beta-qr img { width: clamp(160px, 42vw, 200px); height: auto; }

/* ---------- Sélecteur de plateforme ---------- */
.beta-switch {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 26px;
  padding-top: 20px;
  border-top: 1px solid var(--stroke);
  font-size: 0.88rem;
  color: var(--text-2);
}
.beta-switch button {
  padding: 8px 16px;
  border-radius: 999px;
  border: 1px solid var(--stroke);
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-2);
  transition: color 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}
.beta-switch button:hover { color: var(--text); background: var(--surface-2); }
.beta-switch button.is-current {
  color: var(--text);
  border-color: var(--pink);
  background: rgba(237, 6, 102, 0.12);
}

/* ---------- Replis : aide + email ---------- */
.beta-fold {
  margin-top: 16px;
  border-top: 1px solid var(--stroke);
  padding-top: 16px;
}
.beta-fold > summary {
  cursor: pointer;
  list-style: none;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-2);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.beta-fold > summary::-webkit-details-marker { display: none; }
.beta-fold > summary::after {
  content: "+";
  font-family: var(--font-display);
  font-size: 1.3rem;
  line-height: 1;
  color: var(--pink-light);
  transition: transform 0.25s ease;
}
.beta-fold[open] > summary::after { transform: rotate(45deg); }
.beta-fold > summary:hover { color: var(--text); }

.beta-fold-body {
  margin-top: 14px;
  font-size: 0.93rem;
  color: var(--text-2);
}
.beta-fold-body p { margin: 0 0 10px; }
.beta-fold-body p:last-child { margin-bottom: 0; }
.beta-fold-body strong { color: var(--text); }

/* Le formulaire email hérite de .waitlist-form (style.css) : même champ, même
   bouton, même messages que la landing — c'est le MÊME parcours, pas un
   second système. Ici il passe en colonne : la carte est étroite. */
.beta-email .waitlist-form {
  margin-top: 16px;
  flex-direction: column;
  max-width: none;
}
.beta-email .waitlist-form .btn { width: 100%; }
.beta-email .form-msg { text-align: center; font-size: 0.92rem; }

@media (min-width: 480px) {
  .beta-email .waitlist-form { flex-direction: row; }
  .beta-email .waitlist-form .btn { width: auto; }
}

.beta-foot {
  max-width: 560px;
  margin: 18px auto 0;
  padding: 0 max(20px, var(--safe-l)) calc(24px + var(--safe-b)) max(20px, var(--safe-r));
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  justify-content: center;
  font-size: 0.8rem;
  color: #6F6878;
}
.beta-foot a { color: inherit; text-decoration: underline; text-underline-offset: 3px; }
.beta-foot a:hover { color: var(--text-2); }

@media (prefers-reduced-motion: reduce) {
  .beta-progress-bar > i,
  .beta-step { transition: none; }
}
