/**
 * Login Page Styles
 * 
 * @package LiteTheme
 */

/* Ensure full height layout */
html,
body.login {
    height: 100%;
    margin: 0;
    padding: 0;
}

body.login {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* Main login container */
#login {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 20px;
}

/* Form animations */
.login form {
    animation: fadeInUp 0.4s ease-out;
}

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

/* Improve form field focus states */
.login input[type="text"]:focus,
.login input[type="password"]:focus,
.login input[type="email"]:focus {
    background-color: #fff;
    transition: all 0.2s ease;
}

/* Password field with visibility toggle */
.user-pass-wrap {
    position: relative;
}

.wp-pwd {
    position: relative;
}

/* Remember me checkbox */
.forgetmenot {
    margin-bottom: 16px;
}

.forgetmenot input[type="checkbox"] {
    margin-right: 8px;
}

/* Submit button full width */
.login .submit {
    padding: 0;
}

.login .button-primary {
    width: 100%;
    margin-top: 12px;
}

/* Loading state for button */
.login .button-primary.loading {
    position: relative;
    color: transparent;
}

.login .button-primary.loading:after {
    content: "";
    position: absolute;
    width: 16px;
    height: 16px;
    top: 50%;
    left: 50%;
    margin-left: -8px;
    margin-top: -8px;
    border: 2px solid #f3f3f3;
    border-radius: 50%;
    border-top: 2px solid #3498db;
    animation: spin 1s linear infinite;
}

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

/* Privacy policy link */
.privacy-policy-page-link {
    margin-top: 20px;
    text-align: center;
}

/* Mobile responsive improvements */
@media (max-width: 600px) {
    .litetheme-login-header {
        padding: 15px 0;
    }
    
    .litetheme-login-header img {
        max-height: 50px;
    }
    
    .login form {
        padding: 20px;
    }
    
    .login input[type="text"],
    .login input[type="password"],
    .login input[type="email"] {
        font-size: 16px; /* Prevents zoom on iOS */
    }
}

/* Language selector if present */
.language-switcher {
    margin: 20px 0;
    text-align: center;
}

.language-switcher select {
    padding: 5px 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: #fff;
}

/* Interim login */
.interim-login .litetheme-login-header,
.interim-login .litetheme-login-footer {
    display: none;
}

/* Password strength indicator improvements */
#pass-strength-result {
    margin-top: 5px;
    padding: 8px;
    text-align: center;
    border-radius: 3px;
    font-weight: 500;
}

/* Back to links styling */
#backtoblog {
    margin-top: 24px;
}

.login #nav {
    margin: 24px 0 0;
}

/* Error and message styling improvements */
.login .message,
.login #login_error {
    padding: 12px;
    margin-left: 0;
    margin-right: 0;
}

/* Two-factor authentication support */
.login .two-factor-prompt {
    margin-bottom: 16px;
}

/* Support for other login-related plugins */
.login .social-login-buttons {
    margin-top: 20px;
    text-align: center;
}

.login .social-login-buttons a {
    display: inline-block;
    margin: 0 5px;
}

/* Print styles */
@media print {
    .litetheme-login-header,
    .litetheme-login-footer,
    #backtoblog,
    #nav {
        display: none;
    }
}