/* Custom Login Page Styles - Inspired by onesproxy.com */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body.login {
    background: linear-gradient(135deg, #e8f4f8 0%, #d4e9f7 50%, #e3f2fd 100%);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    position: relative;
}

/* Override WordPress default login structure */
body.login #login {
    width: auto;
    padding: 0;
    margin: 0;
}

/* For pages with left sidebar - show left content and right form */
body.login.login-with-sidebar {
    padding: 20px;
}

body.login.login-with-sidebar #login {
    width: auto;
    padding: 0;
    margin: 0;
}

/* For other login pages (retrieve password, etc.), keep original centered layout */
body.login:not(.login-with-sidebar) #login {
    background: #ffffff;
    padding: 45px 40px;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    max-width: 420px;
    margin-top: 0;
    animation: slideUp 0.5s ease-out;
}

/* Language Switcher in Top Right */
.login-language-switcher {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
}

.login-language-switcher select {
    background: #fff;
    border: 1px solid #d9d9d9;
    padding: 6px 30px 6px 12px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 13px;
    color: #333;
    transition: all 0.3s;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23666' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 8px center;
    min-width: 100px;
}

.login-language-switcher select:hover {
    border-color: #1890ff;
}

.login-language-switcher select:focus {
    outline: none;
    border-color: #1890ff;
}

/* Main Container */
.login-main-container {
    display: flex;
    max-width: 1200px;
    width: 100%;
    gap: 80px;
    align-items: flex-start;
    padding-top: 60px;
    margin: 0 auto;
}

/* Left Side - Branding and Features */
.login-left-side {
    flex: 1;
    max-width: 550px;
    padding-top: 20px;
}

/* Right Side - Login Form */
.login-right-side {
    flex: 0 0 420px;
}

.login-right-side #login {
    background: #ffffff;
    padding: 45px 40px;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    width: 100%;
    margin-top: 0;
    animation: slideUp 0.5s ease-out;
}

.login-brand-title {
    font-size: 24px;
    font-weight: 600;
    color: #333;
    margin-bottom: 40px;
    line-height: 1.4;
}

.login-brand-title .blue-text {
    color: #1890ff;
}

.feature-list {
    margin-bottom: 50px;
}

.feature-item {
    margin-bottom: 30px;
    padding-bottom: 30px;
    border-bottom: 1px dashed #b0bec5;
}

.feature-item:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.feature-header {
    display: flex;
    align-items: center;
    margin-bottom: 12px;
}

.feature-icon {
    width: 24px;
    height: 24px;
    margin-right: 12px;
    color: #1890ff;
    font-size: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.feature-title {
    font-size: 16px;
    font-weight: 600;
    color: #333;
    margin: 0;
}

.feature-description {
    font-size: 14px;
    color: #666;
    line-height: 1.8;
    margin: 0;
    padding-left: 36px;
}

.partners-section {
    margin-top: 50px;
}

.partners-title {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 25px;
}

.partners-title .blue-text {
    color: #1890ff;
}

.partners-logos {
    display: flex;
    flex-wrap: wrap;
    gap: 25px;
    align-items: center;
}

.partner-logo {
    font-size: 15px;
    color: #999;
    font-weight: 500;
    opacity: 0.7;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.login h1 {
    margin-bottom: 30px;
    text-align: center;
}

.login h1 a {
    background-image: none;
    width: auto;
    height: auto;
    color: #333;
    font-size: 24px;
    font-weight: 700;
    transition: all 0.3s ease;
    display: block;
}

.login h1 a:hover {
    color: #1890ff;
}

.login form {
    background: transparent;
    border: none;
    box-shadow: none;
    padding: 0;
    margin: 0;
}

.login label {
    color: #333;
    font-weight: 500;
    font-size: 14px;
    margin-bottom: 6px;
    display: block;
}

.login input[type="text"],
.login input[type="password"],
.login input[type="email"] {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid #d9d9d9;
    border-radius: 6px;
    font-size: 14px;
    transition: all 0.3s ease;
    background: #fff;
    box-sizing: border-box;
    margin-top: 8px;
    color: #333;
}

.login input[type="text"]:focus,
.login input[type="password"]:focus,
.login input[type="email"]:focus {
    border-color: #1890ff;
    outline: none;
    box-shadow: 0 0 0 2px rgba(24, 144, 255, 0.1);
}

.login .forgetmenot {
    margin: 20px 0;
    display: flex;
    align-items: center;
}

.login .forgetmenot label {
    font-weight: 400;
    color: #666;
    cursor: pointer;
    margin-left: 8px;
    font-size: 14px;
}

.login input[type="checkbox"] {
    width: 16px;
    height: 16px;
    cursor: pointer;
    accent-color: #1890ff;
}

.login .button-primary {
    width: 100%;
    padding: 12px;
    background: #1890ff;
    border: none;
    border-radius: 6px;
    color: #fff;
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(24, 144, 255, 0.3);
    margin-top: 15px;
}

.login .button-primary:hover {
    background: #40a9ff;
    box-shadow: 0 4px 12px rgba(24, 144, 255, 0.4);
}

.login .button-primary:active {
    background: #096dd9;
}

#nav {
    margin-top: 25px;
    text-align: center;
    font-size: 14px;
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

#nav a {
    color: #1890ff;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    padding: 5px 0;
}

#nav a:hover {
    color: #40a9ff;
    text-decoration: underline;
}

#backtoblog {
    margin-top: 20px;
    text-align: center;
}

#backtoblog a {
    color: #666;
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s ease;
}

#backtoblog a:hover {
    color: #1890ff;
}

.login-message {
    background: #e3f2fd;
    border-left: 4px solid #2196f3;
    padding: 12px 16px;
    border-radius: 4px;
    margin-bottom: 20px;
}

.login-error-list,
#login_error {
    background: #ffebee;
    border-left: 4px solid #f44336;
    padding: 12px 16px;
    border-radius: 4px;
    margin-bottom: 20px;
}

.wp-pwd {
    position: relative;
}

.wp-hide-pw {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    cursor: pointer;
    color: #1890ff;
    padding: 5px;
    font-size: 14px;
}

.wp-hide-pw:hover {
    color: #40a9ff;
}

/* Register page specific styles */
.register-form p {
    margin-bottom: 20px;
}

.register-form .input {
    margin-top: 8px;
}

.user-pass1-wrap,
.user-pass2-wrap {
    margin-bottom: 20px;
}

.user-pass1-wrap label,
.user-pass2-wrap label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #333;
}

#reg_passmail {
    font-size: 13px;
    color: #666;
    margin-top: 15px;
    padding: 12px 15px;
    background: linear-gradient(135deg, #f0f7ff 0%, #e8f4ff 100%);
    border-radius: 8px;
    border-left: 4px solid #1890ff;
    line-height: 1.6;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .login-main-container {
        flex-direction: column;
        gap: 40px;
    }
    
    .login-left-side {
        max-width: 100%;
        text-align: center;
    }
    
    .feature-description {
        padding-left: 0;
        margin-top: 10px;
    }
    
    .feature-header {
        justify-content: center;
    }
    
    .partners-logos {
        justify-content: center;
    }
    
    .login-right-side {
        flex: 0 0 auto;
        width: 100%;
        max-width: 420px;
    }
}

@media (max-width: 768px) {
    .login-with-sidebar .login-right-side #login {
        padding: 40px 30px;
        margin: 20px;
    }
    
    .login h1 a {
        font-size: 22px;
    }
    
    #nav {
        flex-direction: column;
        gap: 10px;
    }
    
    .login-language-switcher {
        top: 15px;
        right: 15px;
    }
    
    .login-language-switcher select {
        padding: 6px 30px 6px 12px;
        font-size: 13px;
        min-width: 110px;
    }
    
    .login-main-container {
        padding-top: 70px;
    }
    
    .login-brand-title {
        font-size: 20px;
    }
    
    .feature-title {
        font-size: 15px;
    }
    
    .feature-description {
        font-size: 13px;
    }
}

/* Captcha Field Styles */
.custom-captcha-field {
    margin-top: 20px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
}

.custom-captcha-field label {
    font-weight: 600;
    color: #333;
    font-size: 14px;
    white-space: nowrap;
    margin-right: 30px;
}

.custom-captcha-field input[type="text"] {
    padding: 12px 16px;
    border: 1px solid #d9d9d9;
    border-radius: 6px;
    font-size: 14px;
    transition: all 0.3s ease;
    background: #fff;
    color: #333;
    flex: 1;
    min-width: 200px;
}

.custom-captcha-field input[type="text"]:focus {
    outline: none;
    border-color: #1890ff;
    box-shadow: 0 0 0 2px rgba(24, 144, 255, 0.1);
}

/* Custom Password Field Styles */
.custom-password-field {
    margin-top: 20px;
    margin-bottom: 20px;
}

.custom-password-field label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #333;
    font-size: 14px;
}

.custom-password-field input {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid #d9d9d9;
    border-radius: 6px;
    font-size: 14px;
    transition: all 0.3s ease;
    background: #fff;
    box-sizing: border-box;
    color: #333;
}

.custom-password-field input:focus {
    outline: none;
    border-color: #1890ff;
    box-shadow: 0 0 0 2px rgba(24, 144, 255, 0.1);
}

/* Hide WordPress default registration elements */
body.register-page #reg_passmail,
body.register-page .user-pass1-wrap,
body.register-page .user-pass2-wrap,
body.register-page .wp-pwd,
body.register-page #submit,
body.register-page #backtoblog,
body.register-page #nav,
body.login .register {
    display: none !important;
}

/* Hide email notification message */
#reg_passmail {
    display: none !important;
}

/* Hide "Register for this site" text */
.register-page p#reg_passmail,
.register-page .description {
    display: none !important;
}

/* Hide back to blog link */
#backtoblog {
    display: none !important;
}

/* Hide all notice and message elements on register page */
body.register .notice,
body.register .message,
body.register p.message,
body.register p.notice {
    display: none !important;
}
