/* Long Vân SSO gate for the browser chat only. */

.auth-gate {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: var(--bg-main);
}

.auth-card {
    width: min(100%, 520px);
    padding: 54px 52px 46px;
    text-align: center;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 24px;
    box-shadow: var(--shadow-lg);
}

.auth-logo {
    width: 96px;
    height: 96px;
    margin: 0 auto 28px;
    padding: 16px;
    border-radius: 20px;
    background: #ffffff;
    border: 1px solid var(--border-color);
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.1);
}

.auth-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.auth-card h1 {
    margin: 0;
    color: var(--text-main);
    font-size: 30px;
    letter-spacing: -0.5px;
}

.auth-description {
    margin: 12px auto 0;
    max-width: 380px;
    color: var(--text-muted);
    font-size: 16px;
    line-height: 1.65;
}

.auth-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 28px;
    color: var(--text-muted);
    font-size: 13px;
}

.auth-login-btn,
.auth-retry-btn {
    width: 100%;
    min-height: 52px;
    margin-top: 34px;
    border: 0;
    border-radius: 12px;
    color: #fff;
    background: linear-gradient(135deg, var(--primary), var(--primary-hover));
    box-shadow: var(--shadow-sm);
    cursor: pointer;
    font: inherit;
    font-size: 16px;
    font-weight: 600;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.auth-login-btn:hover,
.auth-retry-btn:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-glow);
}

.auth-retry-btn {
    margin-top: 10px;
    color: var(--text-main);
    background: transparent;
    border: 1px solid var(--border-color);
}

.auth-error {
    margin: 14px 0 0;
    color: #dc2626;
    font-size: 13px;
    line-height: 1.5;
}

.auth-security-note {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin-top: 28px;
    padding: 11px 12px;
    text-align: left;
    color: var(--text-muted);
    background: var(--border-subtle);
    border-radius: 10px;
    font-size: 11px;
    line-height: 1.5;
}

.auth-security-note i {
    flex: 0 0 auto;
    margin-top: 2px;
    color: var(--accent-teal);
}

.auth-user-menu {
    display: flex;
    align-items: center;
    gap: 8px;
    max-width: 180px;
    padding: 4px 5px 4px 10px;
    border: 1px solid var(--border-color);
    border-radius: 20px;
    background: var(--bg-card);
}

.auth-user-name {
    overflow: hidden;
    color: var(--text-muted);
    font-size: 12px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.auth-logout-btn {
    width: 28px;
    height: 28px;
    border: 0;
    border-radius: 50%;
    color: var(--text-muted);
    background: transparent;
    cursor: pointer;
}

.auth-logout-btn:hover {
    color: #dc2626;
    background: var(--border-subtle);
}

@media (max-width: 600px) {
    .auth-card {
        padding: 42px 24px 34px;
    }

    .auth-card h1 {
        font-size: 25px;
    }

    .auth-user-name {
        display: none;
    }
}
