/* ═══════════════════════════════════════════
   PRODIGO — PAGE D'INSCRIPTION
   Design: Refined dark/light split
   Font: Sora + JetBrains Mono
═══════════════════════════════════════════ */

*, *::before, *::after { box-sizing: border-box; }

:root {
  --left-bg: #0f0a1e;
  --left-accent: #7c4dff;
  --left-accent2: #00e5ff;
  --right-bg: #f8f7fc;
  --right-surface: #ffffff;
  --text-primary: #1a1333;
  --text-secondary: #6b6780;
  --text-muted: #a09dbb;
  --border: #e4e1f0;
  --border-focus: #7c4dff;
  --danger: #ef4444;
  --success: #10b981;
  --warn: #f59e0b;
  --radius: 10px;
  --font: 'Sora', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
}

body {
  margin: 0;
  font-family: var(--font);
  background: var(--right-bg);
}

/* ── LAYOUT ─────────────────────────────── */
.prodigo-page {
  min-height: 100vh;
  display: flex;
}

/* ── PANNEAU GAUCHE ─────────────────────── */
.left-panel {
  background: var(--left-bg);
  background-image:
    radial-gradient(ellipse at 20% 20%, rgba(124,77,255,0.18) 0%, transparent 60%),
    radial-gradient(ellipse at 80% 80%, rgba(0,229,255,0.1) 0%, transparent 60%);
  color: #fff;
  padding: 2.5rem 2rem;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
}

/* Logo */
.logo-area { text-align: center; }

.logo-circle {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: rgba(255,255,255,0.08);
  border: 1.5px solid rgba(255,255,255,0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 0.75rem;
  overflow: hidden;
}

.brand-name {
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: -0.5px;
  background: linear-gradient(135deg, #fff 40%, var(--left-accent2));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.brand-tagline {
  font-size: 0.78rem;
  color: rgba(255,255,255,0.45);
  margin-top: 3px;
  font-weight: 300;
  letter-spacing: 0.3px;
}

/* Trust badges */
.trust-badges {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.trust-item {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.8rem;
  color: rgba(255,255,255,0.65);
  background: rgba(255,255,255,0.05);
  border: 0.5px solid rgba(255,255,255,0.1);
  border-radius: 8px;
  padding: 0.5rem 0.75rem;
}

.trust-icon { font-size: 1rem; }

/* Slider avis */
.reviews-section { width: 100%; }

.reviews-title {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: rgba(255,255,255,0.35);
  margin-bottom: 0.6rem;
  font-family: var(--font-mono);
}

.reviews-slider-wrapper {
  position: relative;
  overflow: hidden;
  width: 100%;
  border-radius: var(--radius);
}

.reviews-track {
  display: flex;
  transition: transform 0.55s cubic-bezier(0.4, 0, 0.2, 1);
}

.review-card {
  background: rgba(255,255,255,0.06);
  border: 0.5px solid rgba(255,255,255,0.1);
  border-radius: var(--radius);
  padding: 0.85rem 1rem;
  min-width: 100%;
  box-sizing: border-box;
}

.review-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
}

.avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  font-weight: 600;
  flex-shrink: 0;
}

.av-1 { background: #7c4dff; color: #fff; }
.av-2 { background: #00bfa5; color: #fff; }
.av-3 { background: #f06292; color: #fff; }
.av-4 { background: #ff9800; color: #fff; }
.av-5 { background: #2196f3; color: #fff; }

.review-name { font-size: 0.8rem; font-weight: 500; color: #fff; }
.stars { font-size: 10px; color: #ffc107; margin-left: auto; }

.review-text {
  font-size: 0.75rem;
  color: rgba(255,255,255,0.55);
  line-height: 1.55;
  margin: 0;
}

.slider-dots {
  display: flex;
  justify-content: center;
  gap: 5px;
  margin-top: 8px;
}

.dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: rgba(255,255,255,0.2);
  cursor: pointer;
  transition: all 0.3s;
}

.dot.active {
  background: var(--left-accent2);
  transform: scale(1.4);
}

/* Étapes */
.process-steps { width: 100%; }

.process-title {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: rgba(255,255,255,0.35);
  margin-bottom: 0.6rem;
  font-family: var(--font-mono);
}

.step-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.5rem;
  font-size: 0.8rem;
  color: rgba(255,255,255,0.6);
}

.step-num {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--left-accent), var(--left-accent2));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.65rem;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
}

/* ── PANNEAU DROIT ──────────────────────── */
.right-panel {
  background: var(--right-bg);
  padding: 2rem;
  display: flex;
  justify-content: center;
  overflow-y: auto;
}

.form-wrapper {
  max-width: 480px;
  width: 100%;
  padding: 0.5rem 0 3rem;
}

/* En-tête formulaire */
.form-badge {
  display: inline-block;
  font-size: 0.7rem;
  font-family: var(--font-mono);
  font-weight: 500;
  color: var(--left-accent);
  background: rgba(124,77,255,0.08);
  border: 1px solid rgba(124,77,255,0.2);
  border-radius: 20px;
  padding: 3px 12px;
  margin-bottom: 0.75rem;
  letter-spacing: 0.5px;
}

.form-header h2 {
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0 0 6px;
  letter-spacing: -0.5px;
}

.form-header p {
  font-size: 0.855rem;
  color: var(--text-secondary);
  margin: 0 0 1.25rem;
  line-height: 1.5;
}

/* Bannière info */
.info-banner {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  background: rgba(124,77,255,0.06);
  border: 1px solid rgba(124,77,255,0.15);
  border-left: 3px solid var(--left-accent);
  border-radius: var(--radius);
  padding: 0.65rem 0.85rem;
  font-size: 0.78rem;
  color: var(--text-secondary);
  margin-bottom: 1.25rem;
  line-height: 1.5;
}

.info-icon { font-size: 1rem; flex-shrink: 0; margin-top: 1px; }

/* Sections du formulaire */
.form-section {
  background: var(--right-surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.2rem 1.2rem 0.6rem;
  margin-bottom: 1rem;
}

.section-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.8px;
  margin-bottom: 1rem;
  padding-bottom: 0.6rem;
  border-bottom: 1px solid var(--border);
  font-family: var(--font-mono);
}

.section-num {
  background: var(--left-accent);
  color: #fff;
  font-size: 0.65rem;
  font-weight: 700;
  width: 20px;
  height: 20px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Champs */
.form-label {
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 4px;
  display: block;
}

.required { color: var(--danger); margin-left: 1px; }

.form-control,
.form-select {
  font-size: 0.855rem;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  padding: 0.5rem 0.75rem;
  background: var(--right-bg);
  color: var(--text-primary);
  transition: border-color 0.2s, box-shadow 0.2s;
  font-family: var(--font);
}

.form-control:focus,
.form-select:focus {
  border-color: var(--border-focus);
  box-shadow: 0 0 0 3px rgba(124,77,255,0.1);
  background: #fff;
  outline: none;
}

.input-group-text {
  background: var(--right-bg);
  border: 1.5px solid var(--border);
  border-right: none;
  font-size: 13px;
  color: var(--text-muted);
  border-radius: 8px 0 0 8px;
}

.input-group .form-control {
  border-left: none;
  border-radius: 0 8px 8px 0;
}

.input-group .form-control:focus {
  border-left: none;
}

textarea.form-control { resize: vertical; min-height: 80px; }

.password-toggle {
  background: var(--right-bg);
  border: 1.5px solid var(--border);
  border-left: none;
  cursor: pointer;
  border-radius: 0 8px 8px 0;
  padding: 0 10px;
  color: var(--text-muted);
  font-size: 13px;
  transition: background 0.2s;
}

.password-toggle:hover { background: var(--border); }

.field-hint {
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-top: 3px;
}

/* ── VALIDATION DES CHAMPS ─────────────── */
.field-error {
  animation: shake 0.3s ease-in-out;
  transition: all 0.2s ease;
}

.field-error:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.15);
}

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-5px); }
  75% { transform: translateX(5px); }
}

/* Force mot de passe */
.pwd-strength {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-top: 6px;
}

.strength-bar {
  flex: 1;
  height: 4px;
  background: var(--border);
  border-radius: 2px;
  overflow: hidden;
}

.strength-fill {
  height: 100%;
  width: 0%;
  border-radius: 2px;
  transition: width 0.3s, background 0.3s;
}

.strength-label {
  font-size: 0.7rem;
  color: var(--text-muted);
  white-space: nowrap;
  font-family: var(--font-mono);
}

/* Checkbox conditions */
.terms-block {
  background: var(--right-surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 0.85rem 1rem;
  margin-bottom: 1rem;
  transition: border-color 0.2s;
}

.terms-block:has(#terms:checked) {
  border-color: var(--left-accent);
  background: rgba(124,77,255,0.03);
}

.terms-label {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  cursor: pointer;
  margin: 0;
}

.terms-label input[type="checkbox"] {
  width: 17px;
  height: 17px;
  flex-shrink: 0;
  margin-top: 1px;
  accent-color: var(--left-accent);
  cursor: pointer;
}

.terms-text {
  font-size: 0.8rem;
  color: var(--text-secondary);
  line-height: 1.55;
}

.terms-link {
  color: var(--left-accent);
  text-decoration: none;
  font-weight: 500;
}

.terms-link:hover { text-decoration: underline; }

/* Bouton principal */
.btn-register {
  width: 100%;
  background: linear-gradient(135deg, #2d1b6e, #7c4dff);
  color: #fff;
  border: none;
  border-radius: var(--radius);
  padding: 0.75rem 1.5rem;
  font-size: 0.9rem;
  font-weight: 600;
  font-family: var(--font);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  cursor: pointer;
  transition: all 0.25s;
  position: relative;
  overflow: hidden;
  margin-bottom: 1rem;
}

.btn-register:not(:disabled):hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(124,77,255,0.35);
}

.btn-register:not(:disabled):active {
  transform: translateY(0);
}

.btn-register:disabled {
  background: linear-gradient(135deg, #c5c0d8, #b8b4cc);
  cursor: not-allowed;
  opacity: 0.7;
  transform: none;
  box-shadow: none;
}

.btn-icon { font-size: 1rem; }

/* Message succès */
.success-msg {
  text-align: center;
  background: rgba(16,185,129,0.06);
  border: 1.5px solid rgba(16,185,129,0.25);
  border-radius: 12px;
  padding: 1.5rem;
  margin-bottom: 1rem;
  animation: fadeIn 0.4s ease;
}

.success-icon { font-size: 2.5rem; margin-bottom: 0.5rem; }

.success-title {
  font-size: 1rem;
  font-weight: 600;
  color: var(--success);
  margin-bottom: 0.4rem;
}

.success-text {
  font-size: 0.82rem;
  color: var(--text-secondary);
  line-height: 1.55;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Lien connexion */
.login-link {
  text-align: center;
  font-size: 0.82rem;
  color: var(--text-secondary);
  margin-top: 0.5rem;
}

.login-link a {
  color: var(--left-accent);
  text-decoration: none;
  font-weight: 600;
}

.login-link a:hover { text-decoration: underline; }

/* ── BACK BUTTON ── */
.btn-back {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  background: var(--right-surface);
  border: 1.5px solid var(--border);
  color: var(--text-primary);
  border-radius: 10px;
  padding: .6rem 1rem;
  font-size: .85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all .2s;
  font-family: var(--font);
  text-decoration: none;
  box-shadow: 0 1px 3px rgba(0,0,0,.08);
  margin-bottom: 1rem
}

.btn-back:hover {
  border-color: var(--left-accent);
  color: var(--left-accent);
  background: rgba(124,77,255,0.06);
  transform: translateX(-2px);
  box-shadow: 0 4px 12px rgba(124,77,255,.15)
}

.btn-back:active {
  transform: translateX(0)
}

.btn-back i {
  font-size: 1rem;
  transition: transform .2s
}

.btn-back:hover i {
  transform: translateX(-2px)
}

/* ── RESPONSIVE ─────────────────────────── */
@media (max-width: 767px) {
  .prodigo-page { flex-direction: column; }

  .left-panel {
    position: static;
    height: auto;
    padding: 1.5rem 1.25rem;
    gap: 1rem;
  }

  .process-steps { display: none; }

  .right-panel { padding: 1.25rem; }
}