/* Login Page Styles - Updated to match mockup */

.login-body {
    background: linear-gradient(135deg, #4f46e5 0%, #3b82f6 100%);
    min-height: 100vh;
    position: relative;
    overflow-x: hidden;
    font-family: 'Prompt', sans-serif;
}

.login-body::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: 
        radial-gradient(circle at 20% 50%, rgba(255, 255, 255, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(255, 255, 255, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 40% 80%, rgba(255, 255, 255, 0.1) 0%, transparent 50%);
    z-index: 0;
}

/* Back to Home Button */
.back-home {
    position: absolute;
    top: 20px;
    left: 20px;
    z-index: 1000;
}

.back-home .btn {
    border: 2px solid rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

.back-home .btn:hover {
    border-color: rgba(255, 255, 255, 0.6);
    background: rgba(255, 255, 255, 0.1);
    transform: translateX(-5px);
}

/* Login Container */
.login-container {
    position: relative;
    z-index: 1;
}

.login-card {
    background: white;
    border-radius: 16px;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.15);
    overflow: hidden;
    backdrop-filter: blur(10px);
    border: none;
    max-width: 400px;
    margin: 0 auto;
}

/* Login Form Container */
.login-form-container {
    padding: 2.5rem 2rem;
}

.login-header {
    margin-bottom: 2rem;
}

.login-logo {
    /* Remove colored rounded frame and animation so the provided logo image shows clean */
    width: auto;
    height: auto;
    margin: 0 auto 1rem;
    background: transparent;
    border-radius: 0;
    display: block;
    padding: 0;
    box-shadow: none;
    animation: none;
}

.login-logo img {
    display: block;
    margin: 0 auto;
    max-width: 220px;
    height: auto;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(79, 70, 229, 0.4);
    }
    50% {
        transform: scale(1.02);
        box-shadow: 0 0 0 8px rgba(79, 70, 229, 0);
    }
}

.login-title {
    color: #1f2937;
    font-weight: 600;
    margin-bottom: 0.5rem;
    font-size: 1.5rem;
}

.login-subtitle {
    color: #6b7280;
    font-size: 1rem;
    margin-bottom: 0;
}

/* Form Styles */
.login-form {
    margin-top: 1.5rem;
}

.form-label {
    color: #374151;
    font-weight: 600;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.form-control {
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    padding: 0.875rem 1rem;
    font-size: 1rem;
    background: #f9fafb;
    transition: all 0.3s ease;
    box-shadow: none;
}

.form-control:focus {
    background: white;
    border-color: #4f46e5;
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
    outline: none;
}

.form-control::placeholder {
    color: #9ca3af;
    font-size: 0.9rem;
}

.btn-primary {
    background: linear-gradient(135deg, #4f46e5 0%, #3b82f6 100%);
    border: none;
    padding: 1rem 1.5rem;
    font-weight: 600;
    border-radius: 12px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(79, 70, 229, 0.3);
    font-size: 1rem;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(79, 70, 229, 0.4);
    background: linear-gradient(135deg, #4338ca 0%, #2563eb 100%);
}

.btn-primary:active {
    transform: translateY(0);
}

/* Footer */
.login-footer {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e5e7eb;
}

.footer-text {
    color: #6b7280;
    font-size: 0.85rem;
    margin-bottom: 0.5rem;
}

.version-text {
    color: #9ca3af;
    font-size: 0.8rem;
    margin-bottom: 0;
}

/* Demo Info */
.demo-info .alert {
    background: rgba(79, 70, 229, 0.05);
    border: 1px solid rgba(79, 70, 229, 0.1);
    border-radius: 12px;
    font-size: 0.85rem;
    padding: 1rem;
}

.demo-info .alert h6 {
    color: #4f46e5;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.demo-info .alert p {
    color: #6b7280;
    margin-bottom: 0.25rem;
}

.demo-info .alert p:last-child {
    margin-bottom: 0;
}

/* Form Validation */
.form-control.is-invalid {
    border-color: #ef4444;
    background: #fef2f2;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1);
}

.invalid-feedback {
    display: block;
    color: #ef4444;
    font-size: 0.8rem;
    margin-top: 0.25rem;
    font-weight: 500;
}

/* Loading Spinner */
.loading-spinner {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(79, 70, 229, 0.9);
    display: none;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    z-index: 9999;
    color: white;
    backdrop-filter: blur(5px);
}

.loading-spinner.show {
    display: flex;
}

.loading-spinner .spinner-border {
    width: 3rem;
    height: 3rem;
    color: white;
}

.loading-spinner p {
    margin-top: 1rem;
    font-size: 1.1rem;
    font-weight: 500;
}

/* Alert Styles */
.alert {
    border-radius: 12px;
    border: none;
    font-size: 0.9rem;
}

.alert-success {
    background: rgba(34, 197, 94, 0.1);
    color: #059669;
}

.alert-danger {
    background: rgba(239, 68, 68, 0.1);
    color: #dc2626;
}

/* Responsive Design */
@media (max-width: 768px) {
    .login-form-container {
        padding: 2rem 1.5rem;
    }
    
    .login-title {
        font-size: 1.3rem;
    }
    
    .login-subtitle {
        font-size: 0.9rem;
    }
    
    .login-logo {
        width: 60px;
        height: 60px;
        font-size: 2rem;
        margin-bottom: 1rem;
    }
    
    .back-home {
        top: 10px;
        left: 10px;
    }
    
    .back-home .btn {
        padding: 0.5rem 1rem;
        font-size: 0.9rem;
    }
}

@media (max-width: 576px) {
    .login-form-container {
        padding: 1.5rem 1rem;
    }
    
    .login-title {
        font-size: 1.2rem;
    }
    
    .form-control {
        padding: 0.75rem;
    }
    
    .btn-primary {
        padding: 0.875rem 1.25rem;
    }
}

/* Animation Classes */
.fade-in {
    animation: fadeIn 0.6s ease forwards;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.shake {
    animation: shake 0.5s ease;
}

@keyframes shake {
    0%, 100% {
        transform: translateX(0);
    }
    25% {
        transform: translateX(-5px);
    }
    75% {
        transform: translateX(5px);
    }
}

/* Click to fill demo info */
.demo-info .alert {
    cursor: pointer;
    transition: all 0.3s ease;
}

.demo-info .alert:hover {
    background: rgba(79, 70, 229, 0.08);
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(79, 70, 229, 0.1);
}
