:root {
    --primary: #6C63FF;
    --primary-dark: #554FD8;
    --primary-light: #8B85FF;
    --secondary: #4CC9F0;
    --success: #4CAF50;
    --danger: #F44336;
    --warning: #FF9800;
    --dark: #212529;
    --gray: #6C757D;
    --gray-light: #ADB5BD;
    --light: #F8F9FA;
    --white: #FFFFFF;
    --shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 20px 60px rgba(0, 0, 0, 0.12);
    --radius: 12px;
    --radius-lg: 20px;
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.auth-container {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 30px;
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
}

.auth-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    padding: 40px;
    box-shadow: var(--shadow-lg);
    animation: slideUp 0.5s ease;
}

.auth-header {
    text-align: center;
    margin-bottom: 30px;
}

.logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    margin-bottom: 20px;
}

.logo img {
    height: 40px;
    width: auto;
}

.logo-text {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary);
}

.auth-header h1 {
    font-size: 2rem;
    margin-bottom: 10px;
    color: var(--dark);
}

.auth-header p {
    color: var(--gray);
}

.auth-form {
    margin-bottom: 20px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--dark);
    font-size: 0.9rem;
}

.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.input-wrapper i:not(.password-toggle i) {
    position: absolute;
    left: 15px;
    color: var(--gray);
    font-size: 1rem;
}

.input-wrapper input {
    width: 100%;
    padding: 15px 15px 15px 45px;
    border: 2px solid var(--light);
    border-radius: var(--radius);
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    transition: var(--transition);
    background: var(--white);
}

.input-wrapper input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(108, 99, 255, 0.1);
}

.password-toggle {
    position: absolute;
    right: 15px;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--gray);
    font-size: 1rem;
    padding: 5px;
}

.password-toggle:hover {
    color: var(--primary);
}

.password-strength {
    height: 4px;
    background: var(--light);
    border-radius: 2px;
    margin-top: 8px;
    overflow: hidden;
}

.strength-bar {
    height: 100%;
    width: 0;
    transition: var(--transition);
}

.strength-bar.weak {
    width: 33.33%;
    background: var(--danger);
}

.strength-bar.medium {
    width: 66.66%;
    background: var(--warning);
}

.strength-bar.strong {
    width: 100%;
    background: var(--success);
}

.password-hint {
    font-size: 0.8rem;
    color: var(--gray);
    margin-top: 5px;
}

.checkbox-group {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 15px 0;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 0.9rem;
    color: var(--gray);
}

.checkbox-label input {
    position: absolute;
    opacity: 0;
    cursor: pointer;
    height: 0;
    width: 0;
}

.checkmark {
    display: inline-block;
    width: 18px;
    height: 18px;
    background: var(--light);
    border-radius: 4px;
    position: relative;
    transition: var(--transition);
}

.checkbox-label input:checked ~ .checkmark {
    background: var(--primary);
}

.checkbox-label input:checked ~ .checkmark::after {
    content: '\f00c';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: var(--white);
    font-size: 10px;
}

.checkbox-label a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 500;
}

.checkbox-label a:hover {
    text-decoration: underline;
}

.forgot-link {
    color: var(--primary);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
}

.forgot-link:hover {
    text-decoration: underline;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 15px 30px;
    border-radius: var(--radius);
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: var(--transition);
    border: none;
    text-decoration: none;
}

.btn-block {
    width: 100%;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    color: var(--white);
}

.btn-primary:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(108, 99, 255, 0.4);
}

.btn-primary:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--primary);
    color: var(--primary);
}

.btn-outline:hover {
    background: var(--primary);
    color: var(--white);
}

.btn-block {
    margin-bottom: 10px;
}

.auth-divider {
    text-align: center;
    margin: 20px 0;
    position: relative;
}

.auth-divider::before,
.auth-divider::after {
    content: '';
    position: absolute;
    top: 50%;
    width: calc(50% - 30px);
    height: 1px;
    background: var(--light);
}

.auth-divider::before {
    left: 0;
}

.auth-divider::after {
    right: 0;
}

.auth-divider span {
    background: var(--white);
    padding: 0 10px;
    color: var(--gray);
    font-size: 0.9rem;
}

.free-trial-btn {
    background: rgba(255, 152, 0, 0.1);
    border: 1px solid var(--warning);
    color: var(--warning);
    margin-bottom: 20px;
}

.free-trial-btn:hover {
    background: var(--warning);
    color: var(--white);
}

.auth-footer {
    text-align: center;
    margin-top: 20px;
}

.auth-footer p {
    color: var(--gray);
    font-size: 0.9rem;
}

.auth-footer a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
}

.auth-footer a:hover {
    text-decoration: underline;
}

.auth-terms {
    text-align: center;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--light);
}

.auth-terms p {
    color: var(--gray);
    font-size: 0.8rem;
}

.auth-terms a {
    color: var(--primary);
    text-decoration: none;
}

.auth-terms a:hover {
    text-decoration: underline;
}

.auth-features {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.feature {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    padding: 25px;
    border-radius: var(--radius-lg);
    color: var(--white);
    text-align: center;
    animation: slideRight 0.5s ease;
    animation-fill-mode: both;
}

.feature:nth-child(1) { animation-delay: 0.1s; }
.feature:nth-child(2) { animation-delay: 0.2s; }
.feature:nth-child(3) { animation-delay: 0.3s; }

.feature i {
    font-size: 2rem;
    margin-bottom: 15px;
}

.feature h3 {
    margin-bottom: 10px;
    font-size: 1.1rem;
}

.feature p {
    font-size: 0.9rem;
    opacity: 0.9;
}

.success-message {
    text-align: center;
    padding: 20px;
}

.success-message i {
    font-size: 4rem;
    color: var(--success);
    margin-bottom: 20px;
}

.success-message h3 {
    margin-bottom: 10px;
    color: var(--success);
}

.success-message p {
    color: var(--gray);
    margin-bottom: 30px;
}

/* QR Modal */
.qr-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 1000;
    align-items: center;
    justify-content: center;
}

.qr-modal.show {
    display: flex;
}

.qr-modal-content {
    background: var(--white);
    border-radius: var(--radius-lg);
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    animation: modalSlideIn 0.3s ease;
}

.qr-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid var(--light);
}

.qr-modal-header h3 {
    margin: 0;
    color: var(--dark);
}

.qr-modal-close {
    background: none;
    border: none;
    font-size: 2rem;
    cursor: pointer;
    color: var(--gray);
}

.qr-modal-close:hover {
    color: var(--primary);
}

.qr-modal-body {
    padding: 30px;
    text-align: center;
}

.qr-codes {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin: 30px 0;
}

.qr-item {
    text-align: center;
}

.qr-item img {
    width: 150px;
    height: 150px;
    border-radius: var(--radius);
    margin-bottom: 10px;
}

.qr-item p {
    color: var(--gray);
    font-weight: 600;
}

.qr-note {
    color: var(--gray);
    font-size: 0.9rem;
}

/* Toast Notification */
.toast {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    padding: 15px 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    z-index: 1000;
    transform: translateX(400px);
    transition: transform 0.3s ease;
}

.toast.show {
    transform: translateX(0);
}

.toast-content {
    display: flex;
    align-items: center;
    gap: 10px;
}

.toast-content i {
    font-size: 1.2rem;
}

.toast-content i.fa-check-circle {
    color: var(--success);
}

.toast-content i.fa-exclamation-circle {
    color: var(--danger);
}

.toast-content i.fa-exclamation-triangle {
    color: var(--warning);
}

.toast-message {
    color: var(--dark);
    font-weight: 500;
}

/* Animations */
@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideRight {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive Design */
@media (max-width: 1024px) {
    .auth-container {
        grid-template-columns: 1fr;
        max-width: 500px;
    }
    
    .auth-features {
        flex-direction: row;
        flex-wrap: wrap;
    }
    
    .feature {
        flex: 1;
        min-width: 200px;
    }
}

@media (max-width: 768px) {
    .auth-card {
        padding: 30px 20px;
    }
    
    .form-row {
        grid-template-columns: 1fr;
        gap: 0;
    }
    
    .qr-codes {
        flex-direction: column;
        gap: 20px;
    }
    
    .auth-features {
        flex-direction: column;
    }
    
    .toast {
        left: 20px;
        right: 20px;
        bottom: 20px;
        transform: translateY(400px);
    }
    
    .toast.show {
        transform: translateY(0);
    }
}