* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #f59e0b;
    --primary-dark: #d97706;
    --primary-light: #fbbf24;
    --secondary-color: #1e3a5f;
    --secondary-dark: #0f2744;
    --success-color: #10b981;
    --error-color: #ef4444;
    --warning-color: #f59e0b;
    --text-dark: #1f2937;
    --text-light: #6b7280;
    --bg-light: #f9fafb;
    --white: #ffffff;
    --shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 20px 60px rgba(0, 0, 0, 0.15);
}

body {
    font-family: 'Poppins', sans-serif;
    background: var(--bg-light);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

/* ========== Auth Container ========== */
.auth-container {
    display: flex;
    width: 100%;
    max-width: 1100px;
    min-height: 650px;
    background: var(--white);
    border-radius: 24px;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
}

/* ========== Left Panel - Branding ========== */
.auth-left {
    flex: 1;
    background: linear-gradient(135deg, var(--secondary-color) 0%, var(--secondary-dark) 100%);
    padding: 60px 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.auth-left::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, rgba(245, 158, 11, 0.1) 0%, transparent 70%);
    animation: pulse 4s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 0.5; }
    50% { transform: scale(1.1); opacity: 0.8; }
}

.brand-content {
    position: relative;
    z-index: 1;
    text-align: center;
    color: var(--white);
}

/* Sun Animation */
.sun-animation {
    margin-bottom: 30px;
}

.sun {
    width: 100px;
    height: 100px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    border-radius: 50%;
    margin: 0 auto;
    position: relative;
    box-shadow: 0 0 60px rgba(245, 158, 11, 0.6),
                0 0 100px rgba(245, 158, 11, 0.4),
                0 0 140px rgba(245, 158, 11, 0.2);
    animation: glow 3s ease-in-out infinite;
}

@keyframes glow {
    0%, 100% { box-shadow: 0 0 60px rgba(245, 158, 11, 0.6), 0 0 100px rgba(245, 158, 11, 0.4); }
    50% { box-shadow: 0 0 80px rgba(245, 158, 11, 0.8), 0 0 120px rgba(245, 158, 11, 0.5); }
}

.sun-rays {
    position: absolute;
    width: 100%;
    height: 100%;
    animation: rotate 20s linear infinite;
}

.sun-rays::before,
.sun-rays::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 150px;
    height: 150px;
    transform: translate(-50%, -50%);
    background: repeating-conic-gradient(
        from 0deg,
        transparent 0deg 15deg,
        rgba(245, 158, 11, 0.3) 15deg 30deg
    );
    border-radius: 50%;
}

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

.brand-content h1 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.2);
}

.brand-content > p {
    font-size: 0.95rem;
    opacity: 0.9;
    margin-bottom: 40px;
    line-height: 1.6;
}

.features {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

.feature-item:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateX(5px);
}

.feature-item i {
    font-size: 1.2rem;
    color: var(--primary-color);
}

.feature-item span {
    font-size: 0.9rem;
    font-weight: 500;
}

/* ========== Right Panel - Form ========== */
.auth-right {
    flex: 1;
    padding: 60px 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow-y: auto;
}

.auth-form-container {
    width: 100%;
    max-width: 400px;
}

.auth-header {
    text-align: center;
    margin-bottom: 30px;
}

.auth-header h2 {
    font-size: 1.8rem;
    color: var(--text-dark);
    margin-bottom: 8px;
}

.auth-header p {
    color: var(--text-light);
    font-size: 0.95rem;
}

/* ========== Alert Messages ========== */
.alert {
    padding: 12px 16px;
    border-radius: 10px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.9rem;
    animation: slideIn 0.3s ease;
}

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

.alert-error {
    background: #fef2f2;
    color: #dc2626;
    border: 1px solid #fecaca;
}

.alert-success {
    background: #f0fdf4;
    color: #16a34a;
    border: 1px solid #bbf7d0;
}

.alert-warning {
    background: #fffbeb;
    color: #d97706;
    border: 1px solid #fde68a;
}

.alert i {
    font-size: 1.1rem;
}

/* ========== Form Styles ========== */
.auth-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.input-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.input-group label {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-dark);
}

.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.input-wrapper i:first-child {
    position: absolute;
    left: 16px;
    color: var(--text-light);
    font-size: 1rem;
    transition: color 0.3s ease;
}

.input-wrapper input {
    width: 100%;
    padding: 14px 45px;
    font-size: 0.95rem;
    font-family: inherit;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    background: var(--bg-light);
    color: var(--text-dark);
    transition: all 0.3s ease;
}

.input-wrapper input:focus {
    outline: none;
    border-color: var(--primary-color);
    background: var(--white);
    box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.1);
}

.input-wrapper input:focus ~ i:first-child,
.input-wrapper input:focus + .input-status {
    color: var(--primary-color);
}

.input-wrapper.valid input {
    border-color: var(--success-color);
}

.input-wrapper.valid .input-status::after {
    content: '\f00c';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    color: var(--success-color);
}

.input-wrapper.invalid input {
    border-color: var(--error-color);
}

.input-status {
    position: absolute;
    right: 16px;
    font-size: 0.9rem;
}

.toggle-password {
    position: absolute;
    right: 16px;
    background: none;
    border: none;
    color: var(--text-light);
    cursor: pointer;
    padding: 5px;
    transition: color 0.3s ease;
}

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

.error-message {
    font-size: 0.8rem;
    color: var(--error-color);
    min-height: 18px;
    display: block;
}

/* ========== Form Options ========== */
.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.remember-me {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
    color: var(--text-light);
    cursor: pointer;
    position: relative;
    padding-left: 28px;
}

.remember-me input {
    position: absolute;
    opacity: 0;
    cursor: pointer;
}

.checkmark {
    position: absolute;
    left: 0;
    width: 20px;
    height: 20px;
    background: var(--bg-light);
    border: 2px solid #e5e7eb;
    border-radius: 6px;
    transition: all 0.3s ease;
}

.remember-me input:checked ~ .checkmark {
    background: var(--primary-color);
    border-color: var(--primary-color);
}

.checkmark::after {
    content: '';
    position: absolute;
    display: none;
    left: 6px;
    top: 2px;
    width: 5px;
    height: 10px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.remember-me input:checked ~ .checkmark::after {
    display: block;
}

.forgot-password {
    font-size: 0.85rem;
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.forgot-password:hover {
    color: var(--primary-dark);
    text-decoration: underline;
}

/* ========== Buttons ========== */
.btn {
    width: 100%;
    padding: 15px;
    font-size: 1rem;
    font-weight: 600;
    font-family: inherit;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn-primary {
    color: var(--white);
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(245, 158, 11, 0.4);
}

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

.btn.loading .btn-text {
    visibility: hidden;
}

.btn .btn-loader {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: none;
}

.btn.loading .btn-loader {
    display: block;
}

/* ========== Divider ========== */
.divider {
    display: flex;
    align-items: center;
    gap: 15px;
    color: var(--text-light);
    font-size: 0.85rem;
}

.divider::before,
.divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #e5e7eb;
}

/* ========== Social Login ========== */
.social-login {
    display: flex;
    gap: 12px;
}

.social-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px;
    font-size: 0.9rem;
    font-weight: 500;
    font-family: inherit;
    background: var(--white);
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.social-btn:hover {
    border-color: var(--text-light);
    background: var(--bg-light);
}

.social-btn.google i {
    color: #ea4335;
}

.social-btn.microsoft i {
    color: #00a4ef;
}

/* ========== Auth Links ========== */
.auth-link {
    text-align: center;
    font-size: 0.9rem;
    color: var(--text-light);
}

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

.auth-link a:hover {
    color: var(--primary-dark);
    text-decoration: underline;
}

/* ========== Back Link ========== */
.back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--text-light);
    text-decoration: none;
    font-size: 0.9rem;
    margin-bottom: 20px;
    transition: color 0.3s ease;
}

.back-link:hover {
    color: var(--primary-color);
}

/* ========== Password Strength ========== */
.password-strength {
    margin-top: 8px;
}

.strength-bar {
    height: 4px;
    background: #e5e7eb;
    border-radius: 2px;
    overflow: hidden;
}

.strength-fill {
    height: 100%;
    width: 0;
    transition: all 0.3s ease;
    border-radius: 2px;
}

.strength-fill.weak { width: 33%; background: var(--error-color); }
.strength-fill.medium { width: 66%; background: var(--warning-color); }
.strength-fill.strong { width: 100%; background: var(--success-color); }

.strength-text {
    font-size: 0.75rem;
    margin-top: 5px;
    color: var(--text-light);
}

/* ========== Toast Notification ========== */
.toast {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 16px 24px;
    background: var(--white);
    border-radius: 12px;
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: center;
    gap: 12px;
    transform: translateX(120%);
    transition: transform 0.4s ease;
    z-index: 1000;
}

.toast.show {
    transform: translateX(0);
}

.toast.success {
    border-left: 4px solid var(--success-color);
}

.toast.success i {
    color: var(--success-color);
}

.toast.error {
    border-left: 4px solid var(--error-color);
}

.toast.error i {
    color: var(--error-color);
}

.toast-message {
    font-size: 0.9rem;
    color: var(--text-dark);
}

/* ========== Responsive Design ========== */
@media (max-width: 900px) {
    .auth-container {
        flex-direction: column;
        max-width: 500px;
    }

    .auth-left {
        padding: 40px 30px;
    }

    .brand-content h1 {
        font-size: 1.6rem;
    }

    .features {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
    }

    .feature-item {
        padding: 10px 15px;
    }

    .auth-right {
        padding: 40px 30px;
    }
}

@media (max-width: 480px) {
    .auth-container {
        border-radius: 16px;
    }

    .auth-left {
        padding: 30px 20px;
    }

    .sun {
        width: 70px;
        height: 70px;
    }

    .sun-rays::before,
    .sun-rays::after {
        width: 110px;
        height: 110px;
    }

    .brand-content h1 {
        font-size: 1.4rem;
    }

    .features {
        display: none;
    }

    .auth-right {
        padding: 30px 20px;
    }

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

    .form-options {
        flex-direction: column;
        gap: 12px;
        align-items: flex-start;
    }
}
