:root {
    --bg-main: #121212;
    --bg-secondary: #1E1E1E;
    --surface: #2A2A2A;
    --surface-hover: #343434;
    --surface-dark: #1a1a1a;
    --surface-green: rgba(0, 198, 167, 0.1);
    --surface-red: rgba(255, 71, 87, 0.1);

    --text-main: #E0E0E0;
    --text-secondary: #A0A0A0;
    --text-muted: #a0a0a0;
    --text-white: #FFFFFF;

    --primary: #4F8AFF;
    --primary-dark: #3a7cff;
    --accent: #00C6A7;
    --accent-red: #FF4757;

    --radius: 14px;
    --radius-lg: 20px;
    --radius-sm: 8px;
    --transition: .3s ease;

    --shadow: 0 8px 30px rgba(0, 0, 0, 0.2);
    --shadow-hover: 0 15px 40px rgba(0, 0, 0, 0.3);
    --shadow-input: 0 4px 12px rgba(0, 0, 0, 0.1);
}

body {
    background: var(--bg-main);
    color: var(--text-main);
    font-family: 'Inter', system-ui, sans-serif;
    line-height: 1.6;
    min-height: 100vh;
    margin: 0;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 24px;
    width: 100%;
}

.page-header {
    text-align: center;
    padding: 60px 0 40px;
}

.page-header h1 {
    font-size: 48px;
    font-weight: 700;
    margin-bottom: 20px;
    color: var(--text-white);
    background: var(--text-white);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.page-header p {
    color: var(--text-secondary);
    font-size: 18px;
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.6;
}

.login-container {
    display: flex;
    justify-content: center;
    padding: 0 0 80px;
}

.login-card {
    background: linear-gradient(145deg, var(--surface) 0%, var(--surface-dark) 100%);
    border-radius: var(--radius-lg);
    padding: 50px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: var(--shadow);
    width: 100%;
    max-width: 480px;
    transition: all var(--transition);
}

.login-card:hover {
    box-shadow: var(--shadow-hover);
    border-color: rgba(79, 138, 255, 0.2);
}

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

.login-header h2 {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 10px;
    color: var(--text-white);
}

.login-header p {
    color: var(--text-secondary);
    font-size: 16px;
}

.form-group {
    margin-bottom: 25px;
}

.form-label {
    display: block;
    margin-bottom: 10px;
    font-weight: 600;
    color: var(--text-main);
    font-size: 15px;
}

.form-label.required::after {
    content: ' *';
    color: var(--accent-red);
}

.form-input {
    width: 100%;
    padding: 16px 20px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius);
    color: var(--text-main);
    font-size: 15px;
    transition: all var(--transition);
    box-shadow: var(--shadow-input);
}

.form-input:focus {
    outline: none;
    border-color: var(--primary);
    background: rgba(255, 255, 255, 0.08);
    box-shadow: 0 0 0 3px rgba(79, 138, 255, 0.1);
}

.form-input:hover {
    border-color: rgba(255, 255, 255, 0.2);
}

.form-input.error {
    border-color: var(--accent-red);
    background: var(--surface-red);
}

.form-hint {
    display: block;
    margin-top: 8px;
    font-size: 13px;
    color: var(--text-muted);
}

.form-hint.error {
    color: var(--accent-red);
}

.password-field {
    position: relative;
}

.toggle-password {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 4px;
    font-size: 18px;
    transition: color var(--transition);
}

.toggle-password:hover {
    color: var(--primary);
}

.checkbox-group {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 30px;
}

.checkbox {
    width: 20px;
    height: 20px;
    cursor: pointer;
    flex-shrink: 0;
}

.checkbox-label {
    color: var(--text-secondary);
    font-size: 14px;
    cursor: pointer;
}

.form-actions {
    margin-bottom: 30px;
}

.btn {
    width: 100%;
    padding: 18px 32px;
    border-radius: var(--radius);
    font-weight: 600;
    font-size: 16px;
    cursor: pointer;
    transition: all var(--transition);
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.btn-primary {
    background: linear-gradient(90deg, var(--primary), var(--primary-dark));
    color: var(--text-white);
    box-shadow: 0 8px 20px rgba(79, 138, 255, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 25px rgba(79, 138, 255, 0.4);
}

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

.btn-primary:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none !important;
}

.login-links {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-top: 25px;
    padding-top: 25px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.login-link {
    color: var(--text-secondary);
    font-size: 14px;
}

.login-link a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
    transition: color var(--transition);
}

.login-link a:hover {
    color: var(--accent);
    text-decoration: underline;
}

.divider {
    text-align: center;
    margin: 30px 0;
    position: relative;
    color: var(--text-muted);
    font-size: 14px;
}

.divider::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    width: 45%;
    height: 1px;
    background: rgba(255, 255, 255, 0.1);
}

.divider::after {
    content: '';
    position: absolute;
    right: 0;
    top: 50%;
    width: 45%;
    height: 1px;
    background: rgba(255, 255, 255, 0.1);
}

.social-login {
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

.social-btn {
    flex: 1;
    padding: 14px;
    border-radius: var(--radius);
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-main);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    cursor: pointer;
    transition: all var(--transition);
    font-weight: 500;
}

.social-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}

.social-icon {
    font-size: 20px;
}

.error-message {
    padding: 15px;
    background: var(--surface-red);
    border-radius: var(--radius-sm);
    border-left: 3px solid var(--accent-red);
    color: var(--accent-red);
    margin-bottom: 25px;
    font-size: 14px;
    display: none;
}

.error-message.show {
    display: block;
    animation: fadeIn 0.3s ease;
}

.success-message {
    text-align: center;
    padding: 40px 0;
    display: none;
}

.success-message.show {
    display: block;
    animation: fadeIn 0.3s ease;
}

.success-icon {
    width: 80px;
    height: 80px;
    background: var(--accent);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 30px;
    font-size: 40px;
    color: white;
}

.success-title {
    font-size: 24px;
    font-weight: 700;
    color: var(--text-white);
    margin-bottom: 15px;
}

.success-text {
    color: var(--text-secondary);
    max-width: 400px;
    margin: 0 auto 30px;
    line-height: 1.6;
}

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

@media (max-width: 768px) {
    .container {
        padding: 0 16px;
    }

    .page-header {
        padding: 40px 0 30px;
    }

    .page-header h1 {
        font-size: 32px;
    }

    .page-header p {
        font-size: 16px;
        padding: 0 16px;
    }

    .login-card {
        padding: 30px 25px;
    }

    .login-header h2 {
        font-size: 28px;
    }

    .social-login {
        flex-direction: column;
    }
}

@media (max-width: 480px) {
    .page-header h1 {
        font-size: 28px;
    }

    .login-card {
        padding: 25px 20px;
    }

    .login-header h2 {
        font-size: 24px;
    }
}

.hidden {
    display: none;
}
