/* Authentication Modal Styles */
.auth-modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 10000;
    animation: fadeIn 0.3s ease;
}

.auth-modal-overlay.show {
    display: flex;
    align-items: center;
    justify-content: center;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.auth-modal {
    background: white;
    border-radius: 24px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
    max-width: 440px;
    width: 90%;
    position: relative;
    animation: slideUp 0.3s ease;
    overflow: hidden;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.auth-modal-header {
    background: linear-gradient(135deg, var(--color-accent) 0%, var(--color-primary-hover) 100%);
    padding: 32px;
    text-align: center;
    color: white;
}

.auth-modal-header h2 {
    margin: 0;
    font-size: 28px;
    font-weight: 700;
    font-family: 'Outfit', sans-serif;
}

.auth-modal-header p {
    margin: 8px 0 0 0;
    opacity: 0.95;
    font-size: 14px;
}

.auth-modal-body {
    padding: 40px 32px;
}

.auth-form-group {
    margin-bottom: 20px;
}

.auth-form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #2D3748;
    font-size: 14px;
}

.auth-form-group input {
    width: 100%;
    padding: 14px 16px;
    border: 2px solid #E2E8F0;
    border-radius: 12px;
    font-size: 15px;
    transition: all 0.3s ease;
    box-sizing: border-box;
    font-family: 'DM Sans', sans-serif;
}

.auth-form-group input:focus {
    outline: none;
    border-color: var(--color-accent);
    box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.1);
}

.auth-form-group input::placeholder {
    color: #A0AEC0;
}

.auth-error-message {
    background: #FEE2E2;
    color: #DC2626;
    padding: 12px 16px;
    border-radius: 12px;
    margin-bottom: 20px;
    font-size: 14px;
    display: none;
}

.auth-error-message.show {
    display: block;
}

.auth-submit-btn {
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, var(--color-accent) 0%, var(--color-primary-hover) 100%);
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 10px;
    box-shadow: 0 4px 12px rgba(124, 58, 237, 0.2);
}

.auth-submit-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(124, 58, 237, 0.3);
}

.auth-submit-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.auth-divider {
    text-align: center;
    margin: 25px 0;
    position: relative;
}

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

.auth-divider span {
    background: white;
    padding: 0 15px;
    position: relative;
    color: #718096;
    font-size: 14px;
}

.auth-switch {
    text-align: center;
    color: #718096;
    font-size: 14px;
}

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

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

.auth-close-btn {
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    font-size: 24px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

.auth-close-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: rotate(90deg);
}

.form-hidden {
    display: none;
}

/* Loading Spinner */
.auth-submit-btn .spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
    margin-right: 8px;
    vertical-align: middle;
}

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

/* Success Message */
.auth-success-message {
    background: #D1FAE5;
    color: #065F46;
    padding: 12px 16px;
    border-radius: 12px;
    margin-bottom: 20px;
    font-size: 14px;
    display: none;
}

.auth-success-message.show {
    display: block;
}

/* Mobile Responsive */
@media (max-width: 480px) {
    .auth-modal {
        max-width: 95%;
        margin: 10px;
    }

    .auth-modal-body {
        padding: 30px 20px;
    }

    .auth-modal-header {
        padding: 28px 20px;
    }
}