/**
 * Social Login Integration Styles
 * 
 * @package ReHub Child Theme
 * @version 1.0.0
 */

/* ==========================================================================
   Social Login Form Fixes
   ========================================================================== */

/**
 * Hide validation errors during social authentication
 */
.rehub-login-popup .rehub-errors:empty {
    display: none !important;
}

.social-login-processing .rehub-errors {
    display: none !important;
}

/**
 * Social login button container
 */
.social-login-wrapper {
    margin: 15px 0;
    padding: 15px;
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 6px;
}

.social-login-wrapper p {
    margin: 0 0 12px 0;
    font-weight: 600;
    color: #495057;
    font-size: 14px;
}

/**
 * Social login buttons
 */
.social-login-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 16px;
    margin: 4px 6px 4px 0;
    border: none;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s ease-in-out;
    min-width: 140px;
}

.social-login-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

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

/**
 * Google login button
 */
.social-login-btn--google {
    background-color: #4285f4;
    color: #ffffff;
}

.social-login-btn--google:hover {
    background-color: #3367d6;
    color: #ffffff;
}

/**
 * Facebook login button
 */
.social-login-btn--facebook {
    background-color: #1877f2;
    color: #ffffff;
}

.social-login-btn--facebook:hover {
    background-color: #166fe5;
    color: #ffffff;
}

/**
 * Loading state
 */
.social-login-btn--loading {
    opacity: 0.7;
    cursor: not-allowed;
    pointer-events: none;
}

.social-login-btn--loading::after {
    content: '';
    width: 16px;
    height: 16px;
    margin-left: 8px;
    border: 2px solid transparent;
    border-top: 2px solid currentColor;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ==========================================================================
   Form Integration
   ========================================================================== */

/**
 * Prevent form submission errors during social login
 */
.re-user-popup-wrap #rehub_login_form_modal.social-auth-active {
    pointer-events: none;
}

.re-user-popup-wrap #rehub_login_form_modal.social-auth-active .rehub-errors {
    display: none !important;
}

/**
 * Responsive design
 */
@media (max-width: 480px) {
    .social-login-btn {
        width: 100%;
        margin: 4px 0;
    }
    
    .social-login-wrapper {
        padding: 12px;
    }
}