/**
 * Social Authentication Styles
 *
 * @package Agent_Builder
 * @since 0.2.0
 */

/* Auth Page Container */
.agentic-auth-page {
    min-height: calc(100vh - 200px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    background: linear-gradient(135deg, #f5f7fa 0%, #e4e8ec 100%);
}

/* Auth Card */
.agentic-auth-container {
    width: 100%;
    max-width: 440px;
}

.auth-card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.08);
    padding: 2.5rem;
}

/* Auth Header */
.auth-header {
    text-align: center;
    margin-bottom: 2rem;
}

.auth-header h1 {
    font-size: 1.75rem;
    font-weight: 700;
    margin: 0 0 0.5rem;
    color: #1a1a1a;
}

.auth-header p {
    color: #666;
    margin: 0;
    font-size: 0.9375rem;
}

/* Social Buttons */
.auth-social {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.social-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    width: 100%;
    padding: 0.875rem 1.25rem;
    border: 1px solid #ddd;
    border-radius: 8px;
    background: #fff;
    font-size: 0.9375rem;
    font-weight: 500;
    color: #333;
    cursor: pointer;
    transition: all 0.2s ease;
}

.social-btn:hover {
    background: #f9f9f9;
    border-color: #ccc;
}

.social-btn:active {
    transform: scale(0.98);
}

.social-btn svg {
    flex-shrink: 0;
}

/* Provider-specific colors */
.social-btn-google:hover {
    background: #f8f8f8;
    border-color: #4285f4;
}

.social-btn-github {
    background: #24292e;
    border-color: #24292e;
    color: #fff;
}

.social-btn-github:hover {
    background: #1b1f23;
    border-color: #1b1f23;
}

.social-btn-wordpress:hover {
    border-color: #21759b;
}

.social-btn-twitter {
    background: #000;
    border-color: #000;
    color: #fff;
}

.social-btn-twitter:hover {
    background: #1a1a1a;
}

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

.social-btn.loading span::after {
    content: '...';
    animation: dots 1.5s infinite;
}

@keyframes dots {
    0%, 20% { content: '.'; }
    40% { content: '..'; }
    60%, 100% { content: '...'; }
}

/* Divider */
.auth-divider {
    display: flex;
    align-items: center;
    margin: 1.5rem 0;
}

.auth-divider::before,
.auth-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #e0e0e0;
}

.auth-divider span {
    padding: 0 1rem;
    color: #999;
    font-size: 0.875rem;
    text-transform: uppercase;
}

/* Auth Form */
.auth-form {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group label {
    font-weight: 500;
    font-size: 0.875rem;
    color: #333;
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="password"] {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 1rem;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.form-group input:focus {
    outline: none;
    border-color: #2271b1;
    box-shadow: 0 0 0 3px rgba(34, 113, 177, 0.15);
}

.form-group-inline {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    cursor: pointer;
}

.forgot-link {
    font-size: 0.875rem;
    color: #2271b1;
    text-decoration: none;
}

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

.form-hint {
    font-size: 0.8125rem;
    color: #666;
    margin: -0.5rem 0 0;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.875rem 1.5rem;
    border: none;
    border-radius: 6px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
}

.btn-primary {
    background: #2271b1;
    color: #fff;
}

.btn-primary:hover {
    background: #135e96;
}

.btn-block {
    width: 100%;
}

/* Auth Footer */
.auth-footer {
    text-align: center;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid #eee;
}

.auth-footer p {
    margin: 0;
    font-size: 0.9375rem;
    color: #666;
}

.auth-footer a {
    color: #2271b1;
    font-weight: 500;
    text-decoration: none;
}

.auth-footer a:hover {
    text-decoration: underline;
}

/* Error/Success Messages */
.auth-message {
    padding: 1rem;
    border-radius: 6px;
    margin-bottom: 1rem;
    font-size: 0.875rem;
}

.auth-message.error {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #991b1b;
}

.auth-message.success {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    color: #166534;
}

/* Responsive */
@media (max-width: 480px) {
    .agentic-auth-page {
        padding: 1rem;
    }

    .auth-card {
        padding: 1.5rem;
    }

    .auth-header h1 {
        font-size: 1.5rem;
    }
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
    .agentic-auth-page {
        background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    }

    .auth-card {
        background: #1e1e2d;
        box-shadow: 0 4px 24px rgba(0, 0, 0, 0.3);
    }

    .auth-header h1 {
        color: #fff;
    }

    .auth-header p,
    .auth-footer p {
        color: #a0a0a0;
    }

    .social-btn {
        background: #2a2a3a;
        border-color: #3a3a4a;
        color: #fff;
    }

    .social-btn:hover {
        background: #3a3a4a;
    }

    .social-btn-google {
        background: #fff;
        color: #333;
    }

    .auth-divider::before,
    .auth-divider::after {
        background: #3a3a4a;
    }

    .auth-divider span {
        color: #666;
    }

    .form-group label {
        color: #ddd;
    }

    .form-group input {
        background: #2a2a3a;
        border-color: #3a3a4a;
        color: #fff;
    }

    .form-group input:focus {
        border-color: #4fa3d7;
        box-shadow: 0 0 0 3px rgba(79, 163, 215, 0.2);
    }

    .auth-footer {
        border-top-color: #3a3a4a;
    }

    .checkbox-label {
        color: #ccc;
    }
}

/* OAuth Provider Settings in Admin */
.oauth-provider-settings {
    background: #fff;
    border: 1px solid #ccd0d4;
    border-radius: 4px;
    padding: 1rem;
    margin-bottom: 1rem;
}

.oauth-provider-settings h3 {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0 0 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid #eee;
}

.oauth-provider-settings h3 svg {
    flex-shrink: 0;
}
