/* Authentication-Specific Styles */

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

.auth-form {
    background-color: var(--bg-primary);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
    padding: 2rem;
    animation: scaleIn 0.4s ease;
    display: none;
}

.auth-form.active {
    display: block;
}

.auth-header {
    text-align: center;
    margin-bottom: 2rem;
}

.auth-header h1 {
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.auth-header p {
    color: var(--text-secondary);
    font-size: var(--font-size-sm);
}

/* Remember & Forgot */
.remember-forgot {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.remember-forgot .checkbox-label {
    margin: 0;
}

/* Auth Switch */
.auth-switch {
    text-align: center;
    color: var(--text-secondary);
    margin-top: 1rem;
}

.auth-switch .link-btn {
    margin-left: 0.25rem;
}

/* Success Message */
.success-content {
    text-align: center;
    padding: 1rem 0;
}

.success-content p {
    margin-bottom: 1.5rem;
    font-size: var(--font-size-lg);
    color: var(--text-primary);
}

/* Alert Container */
.alert-container {
    position: fixed;
    top: 1rem;
    right: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    max-width: 400px;
    z-index: 1000;
}

.alert-container .alert {
    margin-bottom: 0;
    animation: slideIn 0.3s ease;
    box-shadow: var(--shadow-lg);
}

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

.alert.removing {
    animation: slideOut 0.3s ease;
}

/* Loading States */
.btn.loading {
    position: relative;
    color: transparent;
}

.btn.loading::after {
    content: "";
    position: absolute;
    width: 1rem;
    height: 1rem;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

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

/* Input Focus States */
input:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

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

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

/* Responsive Adjustments */
@media (max-width: 480px) {
    .auth-container {
        max-width: 100%;
    }

    .auth-form {
        padding: 1.5rem;
    }

    .auth-header {
        margin-bottom: 1.5rem;
    }

    .auth-header h1 {
        font-size: var(--font-size-xl);
    }

    .remember-forgot {
        flex-direction: column;
        align-items: flex-start;
    }

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

    .alert-container {
        left: 1rem;
        right: 1rem;
        max-width: none;
    }

    .form-field input[type="text"],
    .form-field input[type="email"],
    .form-field input[type="password"] {
        font-size: 16px;
    }
}

/* Dark Mode Support (optional) */
@media (prefers-color-scheme: dark) {
    :root {
        --text-primary: #f9fafb;
        --text-secondary: #d1d5db;
        --text-light: #9ca3af;
        --bg-primary: #111827;
        --bg-secondary: #1f2937;
        --bg-tertiary: #374151;
        --border-color: #4b5563;
        --border-color-light: #2d3748;
    }

    body {
        background: linear-gradient(135deg, #1e3a8a 0%, #312e81 100%);
    }

    .form-field input[type="text"],
    .form-field input[type="email"],
    .form-field input[type="password"] {
        background-color: var(--bg-secondary);
    }
}

/* Print Styles */
@media print {
    body {
        background: white;
    }

    .auth-container {
        box-shadow: none;
        max-width: 100%;
    }
}
