/* Login Page Styles */

/* Left Panel Background Animation */
.login-left-panel {
    position: relative;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-hover-color) 100%);
}

/* Animated background pattern */
@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-20px);
    }
}

/* Animation removed - icon is now static */
.login-left-panel .fa-graduation-cap {
    /* animation: float 3s ease-in-out infinite; */
}

/* Input field enhancements */
#login-form input {
    transition: all 0.3s ease;
}

#login-form input:focus {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* Password toggle button */
#toggle-password {
    z-index: 10;
    background: transparent;
    border: none;
    outline: none;
}

#toggle-password:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
    border-radius: 4px;
}

#toggle-password:active {
    transform: scale(0.95);
}

#password-eye-icon {
    transition: all 0.2s ease;
}

#toggle-password:hover #password-eye-icon {
    transform: scale(1.1);
}

/* Button animations */
#login-submit-btn {
    position: relative;
    overflow: hidden;
}

#login-submit-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

#login-submit-btn:hover::before {
    width: 300px;
    height: 300px;
}

/* Loading state for submit button */
#login-submit-btn.loading {
    pointer-events: none;
    opacity: 0.7;
}

#login-submit-btn.loading::after {
    content: '';
    position: absolute;
    width: 16px;
    height: 16px;
    top: 50%;
    left: 50%;
    margin-left: -8px;
    margin-top: -8px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

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

/* Card entrance animation */
#login-card {
    animation: slideInUp 0.5s ease-out;
}

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

/* Responsive adjustments */
@media (max-width: 1024px) {
    .login-left-panel {
        display: none !important;
    }
}

/* Dark mode specific styles for login */
.dark #login-card {
    background-color: #1f2937;
    border-color: #374151;
}

.dark #login-form input {
    background-color: #374151;
    border-color: #4b5563;
    color: white;
}

.dark #login-form input::placeholder {
    color: #9ca3af;
}

.dark #login-form input:focus {
    background-color: #374151;
    border-color: var(--primary-color);
}

/* Enhanced focus states */
#login-form input:focus + .absolute i {
    color: var(--primary-color);
}

/* Success state for inputs */
#login-form input.valid {
    border-color: #10b981;
}

#login-form input.valid + .absolute i {
    color: #10b981;
}

/* Error state improvements */
#login-error {
    animation: shake 0.5s;
}

@keyframes shake {
    0%, 100% {
        transform: translateX(0);
    }
    10%, 30%, 50%, 70%, 90% {
        transform: translateX(-5px);
    }
    20%, 40%, 60%, 80% {
        transform: translateX(5px);
    }
}

/* Demo info box pulse */
#login-card .bg-blue-50 {
    animation: pulse-border 2s infinite;
}

@keyframes pulse-border {
    0%, 100% {
        border-color: rgb(191, 219, 254);
    }
    50% {
        border-color: rgb(147, 197, 253);
    }
}

/* Hover effects for cancel button */
#cancel-login {
    position: relative;
    overflow: hidden;
}

#cancel-login::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

#cancel-login:hover::before {
    left: 100%;
}

/* Feature checkmarks animation */
.login-left-panel .fa-check-circle {
    animation: fadeInLeft 0.6s ease-out backwards;
}

.login-left-panel .flex:nth-child(1) .fa-check-circle {
    animation-delay: 0.2s;
}

.login-left-panel .flex:nth-child(2) .fa-check-circle {
    animation-delay: 0.4s;
}

.login-left-panel .flex:nth-child(3) .fa-check-circle {
    animation-delay: 0.6s;
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}
