/* ───────────────────────────────────────────
   Rencontre Inscription – Styles
─────────────────────────────────────────── */

.ri-wrapper {
    max-width: 520px;
    margin: 40px auto;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    color: #2c3e50;
}

/* ── Progression ──────────────────────────── */
.ri-progress {
    display: flex;
    justify-content: space-between;
    margin-bottom: 32px;
    position: relative;
}
.ri-progress::before {
    content: '';
    position: absolute;
    top: 16px;
    left: 10%;
    right: 10%;
    height: 2px;
    background: #dfe6e9;
    z-index: 0;
}
.ri-progress-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    position: relative;
    z-index: 1;
}
.ri-progress-dot {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #dfe6e9;
    color: #95a5a6;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 13px;
    transition: background .3s, color .3s;
}
.ri-progress-step.active .ri-progress-dot {
    background: #e74c3c;
    color: #fff;
    box-shadow: 0 0 0 4px rgba(231,76,60,.2);
}
.ri-progress-step.done .ri-progress-dot {
    background: #27ae60;
    color: #fff;
}
.ri-progress-step span {
    font-size: 11px;
    color: #7f8c8d;
    text-align: center;
}
.ri-progress-step.active span { color: #e74c3c; font-weight: 600; }
.ri-progress-step.done span   { color: #27ae60; }

/* ── Alertes ──────────────────────────────── */
.ri-alert {
    padding: 12px 16px;
    border-radius: 6px;
    margin-bottom: 20px;
    font-size: 14px;
}
.ri-alert.error   { background: #fdf0ed; border-left: 4px solid #e74c3c; color: #c0392b; }
.ri-alert.success { background: #eafaf1; border-left: 4px solid #27ae60; color: #1e8449; }

/* ── Étapes ───────────────────────────────── */
.ri-step h2 {
    font-size: 20px;
    margin: 0 0 4px;
}
.ri-subtitle {
    color: #7f8c8d;
    font-size: 13px;
    margin: 0 0 24px;
}

/* ── Champs ───────────────────────────────── */
.ri-field { margin-bottom: 18px; }
.ri-field > label {
    display: block;
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 6px;
}
.req { color: #e74c3c; }

.ri-input,
.ri-select {
    width: 100%;
    padding: 10px 14px;
    border: 1.5px solid #dfe6e9;
    border-radius: 6px;
    font-size: 14px;
    transition: border-color .2s, box-shadow .2s;
    box-sizing: border-box;
    background: #fff;
}
.ri-input:focus,
.ri-select:focus {
    outline: none;
    border-color: #e74c3c;
    box-shadow: 0 0 0 3px rgba(231,76,60,.15);
}
.ri-input-small {
    width: 80px;
    padding: 8px 12px;
    border: 1.5px solid #dfe6e9;
    border-radius: 6px;
    font-size: 14px;
}
.ri-input-small:focus {
    outline: none;
    border-color: #e74c3c;
}

/* ── Radio group ──────────────────────────── */
.ri-radio-group {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}
.ri-radio-label {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    border: 1.5px solid #dfe6e9;
    border-radius: 20px;
    cursor: pointer;
    font-size: 13px;
    transition: border-color .2s, background .2s;
}
.ri-radio-label:hover { border-color: #e74c3c; }
.ri-radio-label input[type="radio"] { display: none; }
.ri-radio-label.selected {
    border-color: #e74c3c;
    background: #fdf0ed;
    color: #c0392b;
    font-weight: 600;
}

/* ── Tranche d'âge ────────────────────────── */
.ri-range-row {
    display: flex;
    align-items: center;
    gap: 10px;
}
.ri-range-sep { color: #7f8c8d; font-size: 13px; }
.ri-sub-label { display: block; font-size: 11px; color: #95a5a6; margin-bottom: 2px; }

/* ── Password ─────────────────────────────── */
.ri-password-wrap {
    position: relative;
}
.ri-password-wrap .ri-input { padding-right: 44px; }
.ri-eye {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    font-size: 18px;
    opacity: .5;
}
.ri-eye:hover { opacity: 1; }

/* ── Info box ─────────────────────────────── */
.ri-info-box {
    background: #eaf4fb;
    border-left: 4px solid #3498db;
    padding: 12px 14px;
    border-radius: 6px;
    font-size: 13px;
    color: #1a5276;
}

/* ── Boutons ──────────────────────────────── */
.ri-btn {
    padding: 11px 22px;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: opacity .2s, transform .1s;
}
.ri-btn:active { transform: scale(.97); }
.ri-btn:disabled { opacity: .4; cursor: not-allowed; }
.ri-btn-primary   { background: #e74c3c; color: #fff; }
.ri-btn-secondary { background: #ecf0f1; color: #2c3e50; }
.ri-btn-primary:hover:not(:disabled) { opacity: .88; }
.ri-btn-full { width: 100%; }

.ri-nav {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    margin-top: 10px;
}

/* ── Caméra ───────────────────────────────── */
.ri-camera-box {
    background: #000;
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 14px;
    aspect-ratio: 4/3;
    display: flex;
    align-items: center;
    justify-content: center;
}
#ri-video,
#ri-snapshot {
    width: 100%;
    border-radius: 10px;
    display: block;
}
#ri-camera-controls {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 20px;
}

/* ── Géo ──────────────────────────────────── */
.ri-geo-box {
    background: #fdf9ec;
    border: 1.5px solid #f39c12;
    border-radius: 8px;
    padding: 16px;
    font-size: 13px;
}
.ri-geo-box p { margin: 0 0 10px; }
#ri-geo-status { color: #27ae60; font-weight: 600; }

/* ── Succès ───────────────────────────────── */
.ri-success-box {
    text-align: center;
    padding: 40px 20px;
    background: #eafaf1;
    border-radius: 12px;
    border: 2px solid #27ae60;
}
.ri-success-icon { font-size: 56px; margin-bottom: 16px; }
.ri-success-box h2 { color: #1e8449; margin: 0 0 12px; }
.ri-success-box p  { color: #1e8449; font-size: 15px; margin: 0 0 8px; }
.ri-note { font-size: 13px !important; color: #27ae60 !important; opacity: .8; }

/* ── Spinner ──────────────────────────────── */
.ri-spinner {
    display: inline-block;
    width: 14px;
    height: 14px;
    border: 2px solid rgba(255,255,255,.4);
    border-top-color: #fff;
    border-radius: 50%;
    animation: ri-spin .6s linear infinite;
    vertical-align: middle;
    margin-right: 6px;
}
@keyframes ri-spin { to { transform: rotate(360deg); } }

/* ── Responsive ───────────────────────────── */
@media (max-width: 540px) {
    .ri-wrapper { margin: 20px 16px; }
    .ri-progress-step span { display: none; }
}
