/* Auth Module Styles */
.auth-body {
    margin: 0;
    padding: 0;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow-x: hidden;
    overflow-y: auto;
}

/* Background Animation */
.auth-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.floating-crypto {
    position: absolute;
    width: 100%;
    height: 100%;
}

.floating-crypto i {
    position: absolute;
    font-size: 2rem;
    color: rgba(255, 255, 255, 0.1);
    animation: float 20s infinite linear;
}

.floating-crypto i:nth-child(1) {
    top: 20%;
    left: 10%;
    animation-delay: 0s;
}

.floating-crypto i:nth-child(2) {
    top: 60%;
    left: 80%;
    animation-delay: 5s;
}

.floating-crypto i:nth-child(3) {
    top: 80%;
    left: 20%;
    animation-delay: 10s;
}

@keyframes float {
    0% {
        transform: translateY(0px) rotate(0deg);
        opacity: 0.1;
    }
    50% {
        transform: translateY(-20px) rotate(180deg);
        opacity: 0.2;
    }
    100% {
        transform: translateY(0px) rotate(360deg);
        opacity: 0.1;
    }
}

/* Auth Container */
.auth-container {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    padding: 2rem;
    width: 100%;
    max-width: 450px;
    margin: 1rem;
    position: relative;
    z-index: 10;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Logo */
.auth-logo {
    text-align: center;
    margin-bottom: 2rem;
}

.auth-logo h1 {
    font-size: 1.8rem;
    font-weight: 700;
    color: #2d3748;
    margin: 0 0 0.5rem 0;
}

.auth-logo h1 span {
    color: #667eea;
}

.auth-logo p {
    color: #718096;
    font-size: 0.9rem;
    margin: 0;
}

/* Tab Navigation */
.auth-tabs {
    display: flex;
    margin-bottom: 2rem;
    background: #f7fafc;
    border-radius: 12px;
    padding: 0.25rem;
}

.tab-btn {
    flex: 1;
    padding: 0.75rem 1rem;
    border: none;
    background: transparent;
    color: #718096;
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.tab-btn:hover {
    color: #4a5568;
}

.tab-btn.active {
    background: white;
    color: #667eea;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.tab-btn i {
    font-size: 0.9rem;
}

/* Auth Forms */
.auth-form-container {
    animation: fadeIn 0.3s ease;
}

.auth-form-container.hidden {
    display: none;
}

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

.auth-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.form-group {
    position: relative;
}

.form-group label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    color: #2d3748;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.form-group label i {
    color: #667eea;
    font-size: 0.8rem;
}

.form-group input {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    background: white;
}

.form-group input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.form-group input::placeholder {
    color: #a0aec0;
}

/* Password Toggle */
.password-toggle {
    position: absolute;
    right: 1rem;
    top: 2.5rem;
    background: none;
    border: none;
    color: #718096;
    cursor: pointer;
    padding: 0.25rem;
    transition: color 0.3s ease;
}

.password-toggle:hover {
    color: #667eea;
}

/* Top Actions */
.auth-top-actions {
    display: flex;
    justify-content: flex-start;
    margin-bottom: 1rem;
}

.auth-home-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    color: #4a5568;
    font-weight: 600;
    font-size: 0.9rem;
}

.auth-home-link:hover {
    color: #667eea;
}

/* Captcha */
.captcha-row {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.captcha-question {
    background: #f7fafc;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    padding: 0.65rem 0.75rem;
    font-weight: 700;
    color: #2d3748;
    min-width: 160px;
    text-align: center;
}

.captcha-row input {
    flex: 1;
}

.captcha-refresh {
    border: 2px solid #e2e8f0;
    background: #ffffff;
    color: #4a5568;
    border-radius: 8px;
    padding: 0.65rem 0.75rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.captcha-refresh:hover {
    border-color: #cbd5e0;
    color: #667eea;
}

/* reCAPTCHA */
.g-recaptcha {
    margin: 0.5rem 0;
    display: flex;
    justify-content: center;
}

/* Form Options */
.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 0.5rem 0;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    color: #4a5568;
    cursor: pointer;
}

.checkbox-label input[type="checkbox"] {
    display: none;
}

.checkmark {
    width: 18px;
    height: 18px;
    border: 2px solid #e2e8f0;
    border-radius: 4px;
    position: relative;
    transition: all 0.3s ease;
}

.checkbox-label input[type="checkbox"]:checked + .checkmark {
    background: #667eea;
    border-color: #667eea;
}

.checkbox-label input[type="checkbox"]:checked + .checkmark::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 0.7rem;
    font-weight: bold;
}

.forgot-password,
.terms-link,
.privacy-link {
    color: #667eea;
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.3s ease;
}

.forgot-password:hover,
.terms-link:hover,
.privacy-link:hover {
    color: #5a67d8;
    text-decoration: underline;
}

/* Buttons */
.btn {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    text-decoration: none;
    font-size: 0.95rem;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.3);
}

.btn-secondary {
    background: #f7fafc;
    color: #4a5568;
    border: 2px solid #e2e8f0;
}

.btn-secondary:hover {
    background: #edf2f7;
    border-color: #cbd5e0;
}

.btn-full {
    width: 100%;
}

/* Security Notice */
.security-notice {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin: 1.5rem 0;
    padding: 1rem;
    background: #f0fff4;
    border: 1px solid #c6f6d5;
    border-radius: 8px;
}

.security-notice i {
    color: #48bb78;
    font-size: 1.2rem;
}

.security-notice strong {
    color: #22543d;
    font-size: 0.9rem;
}

.security-notice p {
    color: #2f855a;
    font-size: 0.8rem;
    margin: 0.25rem 0 0 0;
}

/* Back Home */
.back-home {
    text-align: center;
    margin-top: 1.5rem;
}

.back-home .btn {
    font-size: 0.9rem;
    padding: 0.5rem 1rem;
}

/* Loading Overlay */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.loading-overlay.hidden {
    display: none;
}

.loading-spinner {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.loading-spinner i {
    font-size: 2rem;
    color: #667eea;
    margin-bottom: 1rem;
}

.loading-spinner p {
    color: #4a5568;
    font-weight: 600;
    margin: 0;
}

/* Toast Notifications */
.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1100;
}

.toast {
    background: white;
    padding: 1rem 1.5rem;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    min-width: 300px;
    animation: slideIn 0.3s ease;
}

.toast.success {
    border-left: 4px solid #48bb78;
}

.toast.error {
    border-left: 4px solid #f56565;
}

.toast.warning {
    border-left: 4px solid #ed8936;
}

.toast.info {
    border-left: 4px solid #4299e1;
}

.toast i {
    font-size: 1.2rem;
}

.toast.success i {
    color: #48bb78;
}

.toast.error i {
    color: #f56565;
}

.toast.warning i {
    color: #ed8936;
}

.toast.info i {
    color: #4299e1;
}

.toast-content {
    flex: 1;
}

.toast-title {
    font-weight: 600;
    color: #2d3748;
    margin-bottom: 0.25rem;
}

.toast-message {
    color: #718096;
    font-size: 0.9rem;
    margin: 0;
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .auth-container {
        margin: 1rem;
        padding: 1.5rem;
    }

    .auth-body {
        align-items: flex-start;
        padding: 1rem 0;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .form-options {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }
    
    .auth-tabs {
        flex-direction: column;
    }
    
    .tab-btn {
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .auth-container {
        margin: 0.5rem;
        padding: 1rem;
    }

    .captcha-row {
        flex-wrap: wrap;
        gap: 0.5rem;
    }

    .captcha-question {
        min-width: 100%;
        width: 100%;
        order: 1;
    }

    .captcha-row input {
        order: 2;
    }

    .captcha-refresh {
        order: 3;
        flex: 0 0 auto;
    }
    
    .auth-logo h1 {
        font-size: 1.5rem;
    }
    
    .toast-container {
        left: 10px;
        right: 10px;
    }
    
    .toast {
        min-width: auto;
    }
}

/* Estilos para CAPTCHA en formulario de recuperación */
.captcha-container {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.captcha-question {
    background: #f8f9fa;
    padding: 1rem;
    border-radius: 6px;
    border-left: 4px solid #667eea;
    margin-bottom: 0.5rem;
}

.captcha-question span {
    font-weight: 600;
    color: #333;
    font-size: 1rem;
}

.captcha-input-group {
    display: flex;
    gap: 0.75rem;
    align-items: center;
}

.captcha-input-group input {
    flex: 1;
    padding: 0.75rem;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

.captcha-input-group input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.btn-refresh-captcha {
    padding: 0.75rem 1rem;
    background: #667eea;
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 1rem;
    transition: background 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 48px;
    height: 48px;
}

.btn-refresh-captcha:hover {
    background: #5a67d8;
}

.btn-refresh-captcha:active {
    transform: scale(0.98);
}