/* ================================================
   EVERYDAY GENIE - AUTHENTICATION MODAL STYLES
   ================================================ */

/* ================================================
   MODAL OVERLAY
   ================================================ */

.auth-overlay {
    display: none !important;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(5px);
    z-index: var(--z-modal);
    align-items: center;
    justify-content: center;
}

.auth-overlay.active {
    display: flex !important;
}

/* ================================================
   MODAL CONTAINER
   ================================================ */

.auth-modal {
    background: var(--white);
    border-radius: var(--radius-xl);
    width: 90%;
    max-width: 480px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: slideUp 0.4s ease;
}

/* ================================================
   MODAL HEADER
   ================================================ */

.modal-header {
    text-align: center;
    padding: 30px 30px 20px;
    border-bottom: 1px solid var(--gray-200);
    position: relative;
}

.close-btn {
    position: absolute;
    top: 15px;
    right: 15px;
    background: none;
    border: none;
    font-size: 2rem;
    color: var(--gray-600);
    cursor: pointer;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-circle);
    transition: var(--transition-base);
    line-height: 1;
}

.close-btn:hover {
    background: #f0f0f0;
    color: var(--primary-dark);
    transform: rotate(90deg);
}

.modal-logo {
    height: 50px;
    margin-bottom: 15px;
}

.modal-header h2 {
    color: var(--primary-dark);
    margin-bottom: 8px;
    font-size: var(--font-size-2xl);
}

.modal-header > p {
    color: var(--gray-600);
    font-size: 0.95rem;
    margin-bottom: 20px;
}

/* ================================================
   TAB SWITCHER
   ================================================ */

.tab-switcher {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.tab-btn {
    flex: 1;
    padding: 12px 20px;
    background: transparent;
    border: 2px solid var(--gray-200);
    border-radius: var(--radius-md);
    color: var(--gray-600);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition-base);
}

.tab-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.tab-btn.active {
    background: var(--gradient-primary);
    border-color: var(--primary);
    color: var(--white);
}

/* ================================================
   MODAL BODY
   ================================================ */

.modal-body {
    padding: 30px;
}

/* ================================================
   AUTH FORMS
   ================================================ */

.auth-form {
    display: none;
}

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

/* Forgot Password Link */
.forgot-link {
    text-align: right;
    margin-bottom: 25px;
    margin-top: -10px;
}

.forgot-link a {
    color: var(--primary);
    text-decoration: none;
    font-size: 0.9rem;
}

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

/* Submit Button */
.submit-btn {
    width: 100%;
    padding: 14px 20px;
    background: var(--gradient-primary);
    color: var(--white);
    border: none;
    border-radius: var(--radius-md);
    font-size: var(--font-size-md);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition-base);
    box-shadow: var(--shadow-primary);
}

.submit-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: var(--shadow-primary-lg);
}

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

/* Loading State */
.submit-btn.loading {
    position: relative;
    color: transparent;
}

.submit-btn.loading::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    top: 50%;
    left: 50%;
    margin-left: -10px;
    margin-top: -10px;
    border: 2px solid var(--white);
    border-radius: var(--radius-circle);
    border-top-color: transparent;
    animation: spin 0.8s linear infinite;
}

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

/* ================================================
   SOCIAL LOGIN (Future Feature)
   ================================================ */

.social-divider {
    display: flex;
    align-items: center;
    margin: 25px 0;
    color: var(--gray-600);
    font-size: 0.9rem;
}

.social-divider::before,
.social-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--gray-300);
}

.social-divider span {
    padding: 0 15px;
}

.social-login-btns {
    display: flex;
    gap: 10px;
}

.social-btn {
    flex: 1;
    padding: 12px;
    border: 2px solid var(--gray-300);
    border-radius: var(--radius-md);
    background: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition-base);
}

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

/* ================================================
   RESPONSIVE MODAL STYLES
   ================================================ */

@media (max-width: 768px) {
    .auth-modal {
        width: 95%;
        max-height: 95vh;
        margin: 10px;
    }
    
    .modal-header {
        padding: 20px 20px 15px;
    }
    
    .modal-header h2 {
        font-size: var(--font-size-xl);
    }
    
    .modal-body {
        padding: 20px;
    }
    
    .tab-switcher {
        gap: 5px;
    }
    
    .tab-btn {
        padding: 10px 15px;
        font-size: 0.9rem;
    }
}
