/* Clean Banking Login Form - Complete & Self-Contained */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    line-height: 1.6;
}

.login-container {
    width: 100%;
    max-width: 400px;
}

.login-card {
    background: #ffffff;
    border-radius: 16px;
    padding: 40px 32px 32px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    border: 1px solid #f1f5f9;
    position: relative;
}

.login-header {
    text-align: center;
    margin-bottom: 32px;
}

.logo {
    margin-bottom: 16px;
    display: flex;
    justify-content: center;
}

.login-header h1 {
    color: #1e293b;
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 6px;
    letter-spacing: -0.025em;
}

.login-header p {
    color: #64748b;
    font-size: 14px;
    font-weight: 500;
}

/* Form Styles */
.form-group {
    margin-bottom: 20px;
    position: relative;
}

.form-group label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #374151;
    margin-bottom: 6px;
}

.form-group input {
    width: 100%;
    background: #ffffff;
    border: 1.5px solid #e2e8f0;
    border-radius: 8px;
    padding: 12px 14px;
    color: #1e293b;
    font-size: 15px;
    font-weight: 400;
    outline: none;
    transition: all 0.2s ease;
    font-family: inherit;
}

.form-group input:focus {
    border-color: #6366F1;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

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

/* Password Field */
.password-wrapper {
    position: relative;
}

.password-wrapper input {
    padding-right: 44px;
}

.password-toggle {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    color: #64748b;
    padding: 6px;
    border-radius: 4px;
    transition: color 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.password-toggle:hover {
    color: #6366F1;
}

.eye-closed {
    display: none;
}

.password-toggle.show-password .eye-open {
    display: none;
}

.password-toggle.show-password .eye-closed {
    display: block;
}

/* Form Options */
.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    flex-wrap: wrap;
    gap: 12px;
}

.checkbox-wrapper {
    display: flex;
    align-items: center;
    cursor: pointer;
    font-size: 13px;
    color: #374151;
    font-weight: 500;
}

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

.checkmark {
    width: 16px;
    height: 16px;
    border: 1.5px solid #d1d5db;
    border-radius: 3px;
    margin-right: 8px;
    position: relative;
    transition: all 0.2s ease;
    background: #ffffff;
}

.checkbox-wrapper input[type="checkbox"]:checked + .checkmark {
    background: #6366F1;
    border-color: #6366F1;
}

.checkmark::after {
    content: '';
    position: absolute;
    left: 4px;
    top: 1px;
    width: 3px;
    height: 7px;
    border: solid white;
    border-width: 0 1.5px 1.5px 0;
    transform: rotate(45deg);
    opacity: 0;
    transition: opacity 0.2s ease;
}

.checkbox-wrapper input[type="checkbox"]:checked + .checkmark::after {
    opacity: 1;
}

.forgot-link {
    color: #6366F1;
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;
    transition: color 0.2s ease;
}

.forgot-link:hover {
    color: #4f46e5;
}

/* Login Button */
.login-btn {
    width: 100%;
    background: #6366F1;
    color: #ffffff;
    border: none;
    border-radius: 8px;
    padding: 12px 20px;
    cursor: pointer;
    font-family: inherit;
    font-size: 15px;
    font-weight: 600;
    position: relative;
    margin-bottom: 20px;
    transition: all 0.2s ease;
    overflow: hidden;
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.login-btn:hover {
    background: #4f46e5;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.4);
}

.login-btn:active {
    transform: translateY(0);
}

.login-btn:disabled {
    background: #9ca3af;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.btn-text {
    transition: opacity 0.2s ease;
}

.btn-loader {
    position: absolute;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.spinner {
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top: 2px solid #ffffff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.login-btn.loading .btn-text {
    opacity: 0;
}

.login-btn.loading .btn-loader {
    opacity: 1;
}

/* Security Notice */
.security-notice {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-radius: 8px;
    margin-bottom: 16px;
}

.security-notice span {
    color: #166534;
    font-size: 12px;
    font-weight: 500;
}

/* Error States */
.error-message {
    color: #dc2626;
    font-size: 12px;
    font-weight: 500;
    margin-top: 4px;
    opacity: 0;
    transform: translateY(-2px);
    transition: all 0.2s ease;
}

.error-message.show {
    opacity: 1;
    transform: translateY(0);
}

.form-group.error input {
    border-color: #dc2626;
    background: #fef2f2;
}

.form-group.error input:focus {
    box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.1);
}

/* Success Message */
.success-message {
    display: none;
    text-align: center;
    padding: 32px 20px;
    opacity: 0;
    transform: translateY(16px);
    transition: all 0.3s ease;
}

.success-message.show {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

.success-icon {
    margin: 0 auto 16px;
    animation: successScale 0.5s ease-out;
}

@keyframes successScale {
    0% { transform: scale(0); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

.success-message h3 {
    color: #1e293b;
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 4px;
}

.success-message p {
    color: #64748b;
    font-size: 14px;
    font-weight: 500;
}

/* Mobile Responsive */
@media (max-width: 480px) {
    body {
        padding: 16px;
    }
    
    .login-card {
        padding: 32px 24px 24px;
        border-radius: 12px;
    }
    
    .login-header h1 {
        font-size: 1.5rem;
    }
    
    .form-options {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    
    .security-notice {
        flex-direction: column;
        text-align: center;
        gap: 6px;
    }
}