/* ========================================
   RESET & BASE
   ======================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: #f0f2f5;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

/* ========================================
   AUTH WRAPPER
   ======================================== */
.auth-wrapper {
    width: 100%;
    max-width: 1100px;
    margin: 0 auto;
}

.auth-container {
    display: flex;
    background: #ffffff;
    border-radius: 24px;
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.08), 0 10px 30px rgba(0, 0, 0, 0.05);
    overflow: hidden;
    min-height: 650px;
    border: 1px solid rgba(0, 0, 0, 0.04);
}

/* ========================================
   LEFT PANEL - BRANDING
   ======================================== */
.auth-left {
    background: #ffffff;
    padding: 50px 40px;
    width: 42%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    border-right: 1px solid #f0f0f0;
}

.brand-logo {
    width: 72px;
    height: 72px;
    background: #4F46E5;
    border-radius: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 24px;
}

.brand-logo i {
    font-size: 36px;
    color: white;
}

.auth-brand h1 {
    font-size: 32px;
    font-weight: 800;
    color: #111827;
    letter-spacing: -0.5px;
}

.auth-brand h1 span {
    color: #4F46E5;
}

.auth-brand .brand-tagline {
    font-size: 15px;
    color: #6B7280;
    margin-top: 8px;
    font-weight: 400;
    letter-spacing: 0.3px;
}

.auth-features {
    margin-top: 40px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 16px;
    background: #F9FAFB;
    border-radius: 12px;
    transition: all 0.2s ease;
    border: 1px solid transparent;
}

.feature-item:hover {
    background: #F3F4F6;
    border-color: #E5E7EB;
}

.feature-item i {
    font-size: 20px;
    color: #4F46E5;
    width: 28px;
    text-align: center;
}

.feature-item span {
    font-size: 14px;
    color: #374151;
    font-weight: 500;
}

.auth-footer-brand {
    margin-top: 40px;
    display: flex;
    gap: 12px;
    font-size: 13px;
    color: #9CA3AF;
}

.auth-footer-brand span {
    color: #9CA3AF;
}

/* ========================================
   RIGHT PANEL - FORMS
   ======================================== */
.auth-right {
    width: 58%;
    padding: 50px 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #ffffff;
}

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

/* Tabs */
.auth-tabs {
    display: flex;
    gap: 6px;
    margin-bottom: 32px;
    background: #F3F4F6;
    border-radius: 14px;
    padding: 5px;
}

.auth-tab {
    flex: 1;
    padding: 10px 16px;
    border: none;
    border-radius: 10px;
    background: none;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.25s ease;
    color: #6B7280;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-family: 'Inter', sans-serif;
}

.auth-tab i {
    font-size: 16px;
}

.auth-tab.active {
    background: #ffffff;
    color: #4F46E5;
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.12);
}

.auth-tab:hover:not(.active) {
    color: #374151;
    background: rgba(255, 255, 255, 0.5);
}

/* Forms */
.auth-form {
    display: none;
}

.auth-form.active {
    display: block;
    animation: fadeSlideUp 0.35s ease;
}

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

.form-header {
    margin-bottom: 28px;
}

.form-header h2 {
    font-size: 24px;
    font-weight: 700;
    color: #111827;
    letter-spacing: -0.3px;
}

.auth-subtitle {
    color: #6B7280;
    font-size: 15px;
    margin-top: 4px;
}

/* Form Groups */
.form-group {
    margin-bottom: 18px;
}

.form-group label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #374151;
    margin-bottom: 6px;
}

.form-group label i {
    margin-right: 6px;
    color: #6B7280;
    font-size: 14px;
}

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

.input-group .input-icon {
    position: absolute;
    left: 14px;
    color: #9CA3AF;
    font-size: 18px;
    pointer-events: none;
}

.input-group input {
    width: 100%;
    padding: 12px 44px 12px 44px;
    border: 2px solid #E5E7EB;
    border-radius: 12px;
    font-size: 15px;
    transition: all 0.2s ease;
    font-family: 'Inter', sans-serif;
    background: #FAFBFC;
}

.input-group input:focus {
    outline: none;
    border-color: #4F46E5;
    background: #ffffff;
    box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.08);
}

.input-group input::placeholder {
    color: #9CA3AF;
}

.toggle-password {
    position: absolute;
    right: 14px;
    background: none;
    border: none;
    color: #9CA3AF;
    cursor: pointer;
    padding: 4px;
    font-size: 18px;
    transition: color 0.2s ease;
}

.toggle-password:hover {
    color: #4F46E5;
}

.password-hint {
    display: block;
    font-size: 12px;
    color: #9CA3AF;
    margin-top: 4px;
}

/* Form Options */
.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 16px 0 24px;
}

.remember-me {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: #4B5563;
    cursor: pointer;
}

.remember-me input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: #4F46E5;
    cursor: pointer;
}

.forgot-link {
    font-size: 14px;
    color: #4F46E5;
    text-decoration: none;
    font-weight: 500;
}

.forgot-link:hover {
    text-decoration: underline;
}

/* Buttons */
.btn-primary {
    background: #4F46E5;
    color: white;
    border: none;
    padding: 14px 24px;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.25s ease;
    width: 100%;
    font-family: 'Inter', sans-serif;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.btn-primary:hover {
    background: #4338CA;
    transform: translateY(-1px);
    box-shadow: 0 8px 25px rgba(79, 70, 229, 0.25);
}

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

.btn-full {
    margin-top: 4px;
}

/* Divider */
.auth-divider {
    text-align: center;
    margin: 24px 0 16px;
    position: relative;
}

.auth-divider::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    width: 100%;
    height: 1px;
    background: #E5E7EB;
}

.auth-divider span {
    background: white;
    padding: 0 16px;
    font-size: 12px;
    color: #9CA3AF;
    font-weight: 500;
    position: relative;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

/* Demo Credentials */
.demo-creds {
    background: #F9FAFB;
    padding: 16px 20px;
    border-radius: 12px;
    border: 1px solid #E5E7EB;
}

.demo-row {
    display: flex;
    justify-content: space-between;
    padding: 4px 0;
    font-size: 14px;
}

.demo-label {
    color: #6B7280;
}

.demo-value {
    color: #111827;
    font-weight: 600;
    font-family: 'Inter', monospace;
    background: #F3F4F6;
    padding: 0 8px;
    border-radius: 4px;
}

/* Terms */
.auth-terms {
    text-align: center;
    font-size: 13px;
    color: #6B7280;
    margin-top: 18px;
}

.auth-terms a {
    color: #4F46E5;
    text-decoration: none;
    font-weight: 500;
}

.auth-terms a:hover {
    text-decoration: underline;
}

/* ========================================
   MESSAGE TOAST
   ======================================== */
.message {
    position: fixed;
    top: 24px;
    right: 24px;
    padding: 16px 24px;
    border-radius: 14px;
    background: #1F2937;
    color: white;
    display: none;
    z-index: 2000;
    animation: slideInRight 0.35s ease;
    max-width: 440px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
    font-family: 'Inter', sans-serif;
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.message.show {
    display: flex;
    align-items: center;
    gap: 12px;
}

.message.success {
    background: #059669;
}

.message.error {
    background: #DC2626;
}

.message.info {
    background: #2563EB;
}

.message::before {
    font-family: 'bootstrap-icons';
    font-size: 20px;
}

.message.success::before {
    content: '\F26A';
}

.message.error::before {
    content: '\F623';
}

.message.info::before {
    content: '\F431';
}

/* ========================================
   RESPONSIVE
   ======================================== */
@media (max-width: 968px) {
    .auth-container {
        flex-direction: column;
        min-height: auto;
        border-radius: 20px;
    }

    .auth-left {
        width: 100%;
        padding: 35px 30px;
        border-right: none;
        border-bottom: 1px solid #F0F0F0;
    }

    .auth-right {
        width: 100%;
        padding: 35px 30px;
    }

    .brand-logo {
        width: 60px;
        height: 60px;
    }

    .brand-logo i {
        font-size: 28px;
    }

    .auth-brand h1 {
        font-size: 26px;
    }

    .auth-features {
        margin-top: 24px;
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 8px;
    }

    .feature-item {
        padding: 10px 12px;
        font-size: 13px;
    }

    .auth-footer-brand {
        margin-top: 24px;
    }
}

@media (max-width: 600px) {
    body {
        padding: 10px;
    }

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

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

    .auth-features {
        grid-template-columns: 1fr;
    }

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

    .auth-tabs {
        flex-direction: column;
        gap: 4px;
    }

    .auth-tab {
        padding: 10px;
        justify-content: center;
    }

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

    .demo-creds {
        padding: 12px 16px;
    }

    .message {
        top: 12px;
        right: 12px;
        left: 12px;
        max-width: none;
    }
}