/* Business persona — friendlier, larger, less technical-looking. */

.b3chat.b3chat-business {
    --b3chat-business-accent: #2c6e49;
    --b3chat-business-accent-hover: #1d4d33;
    --b3chat-business-bg: #fafaf7;
    --b3chat-business-card-bg: #ffffff;
    --b3chat-business-border: #e6e6e0;
    --b3chat-business-text: #2a2a2a;
    --b3chat-business-muted: #6b6b65;
    font-size: 16px;
}

.b3chat.b3chat-business .b3chat-business-header {
    background: var(--b3chat-business-card-bg);
    border-bottom: 1px solid var(--b3chat-business-border);
    /* Right padding leaves room for an external close button overlay (e.g. SiteAssistantBubble's X) */
    padding: 14px 56px 14px 16px;
}

.b3chat.b3chat-business .b3chat-panel-title {
    font-weight: 600;
    color: var(--b3chat-business-text);
    font-size: 1.05rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

.b3chat.b3chat-business .b3chat-panel-title .bi-stars {
    color: var(--b3chat-business-accent);
}

.b3chat-business-newchat {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: transparent;
    color: var(--b3chat-business-accent);
    border: 1.5px solid var(--b3chat-business-accent);
    padding: 6px 12px;
    border-radius: 999px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s ease;
}

.b3chat-business-newchat:hover {
    background: var(--b3chat-business-accent);
    color: white;
}

.b3chat-business-newchat i {
    font-size: 0.9rem;
}

/* "Cancel Changes" — replaces "New Chat" when there are pending AI edits. Red to signal destructive action. */
.b3chat-business-cancel {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: transparent;
    color: #a83232;
    border: 1.5px solid #a83232;
    padding: 6px 12px;
    border-radius: 999px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s ease;
}

.b3chat-business-cancel:hover {
    background: #a83232;
    color: white;
}

.b3chat-business-cancel i {
    font-size: 0.9rem;
}

/* Inside the publish-bar's confirm card, the "Yes, discard" button uses the cancel red */
.b3chat-cancel-go {
    background: #a83232 !important;
}
.b3chat-cancel-go:hover {
    background: #842525 !important;
}

/* Welcome card */
.b3chat-business-welcome {
    padding: 24px 20px;
    text-align: center;
}

.b3chat-business-welcome h3 {
    margin: 0 0 8px 0;
    font-size: 1.25rem;
    color: var(--b3chat-business-text);
    font-weight: 600;
}

.b3chat-business-welcome-sub {
    margin: 0 0 20px 0;
    color: var(--b3chat-business-muted);
    font-size: 0.95rem;
}

.b3chat-welcome-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 16px;
}

.b3chat-welcome-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 16px 12px;
    background: var(--b3chat-business-card-bg);
    border: 1.5px solid var(--b3chat-business-border);
    border-radius: 12px;
    color: var(--b3chat-business-text);
    cursor: pointer;
    transition: all 0.15s ease;
    font-size: 0.92rem;
    font-weight: 500;
    line-height: 1.25;
    min-height: 80px;
    text-align: center;
}

.b3chat-welcome-btn:hover:not(:disabled) {
    border-color: var(--b3chat-business-accent);
    background: #f5f9f7;
    transform: translateY(-1px);
}

.b3chat-welcome-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.b3chat-welcome-btn i {
    font-size: 1.4rem;
    color: var(--b3chat-business-accent);
}

.b3chat-business-context {
    margin-top: 12px;
    padding: 8px 12px;
    background: #f0f4f1;
    border-radius: 8px;
    font-size: 0.85rem;
    color: var(--b3chat-business-muted);
    text-align: center;
}

.b3chat-business-context strong {
    color: var(--b3chat-business-text);
    font-weight: 600;
}

/* Roomier message bubbles in business mode */
.b3chat.b3chat-business .b3chat-msg {
    font-size: 0.98rem;
    line-height: 1.55;
    padding: 12px 14px;
}

.b3chat.b3chat-business .b3chat-msg.user {
    background: var(--b3chat-business-accent);
    color: white;
}

.b3chat.b3chat-business .b3chat-msg.assistant {
    background: var(--b3chat-business-card-bg);
    border: 1px solid var(--b3chat-business-border);
}

.b3chat.b3chat-business .b3chat-input {
    font-size: 1rem;
    padding: 12px;
}

.b3chat.b3chat-business .b3chat-send-btn {
    background: var(--b3chat-business-accent);
}

.b3chat.b3chat-business .b3chat-send-btn:hover:not(:disabled) {
    background: var(--b3chat-business-accent-hover);
}

/* Hide power-user surfaces if they slip through */
.b3chat.b3chat-business .b3chat-blocks-btn,
.b3chat.b3chat-business .b3chat-model-select-inline,
.b3chat.b3chat-business .b3chat-lock-btn {
    display: none !important;
}

@media (max-width: 480px) {
    .b3chat-welcome-actions {
        grid-template-columns: 1fr;
    }
}

/* Action bar (Refresh Page / Cancel Changes flow) — stacks vertically so hint
   text falls below the button instead of running off the side */
.b3chat-publish-bar {
    margin-top: 10px;
    padding: 10px 12px;
    background: #f7f4ee;
    border: 1px solid #e6dfcf;
    border-radius: 10px;
    font-size: 0.88rem;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
}

.b3chat-publish-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #2c6e49;
    color: white;
    border: none;
    padding: 8px 14px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s ease;
}

.b3chat-publish-btn:hover:not(:disabled) {
    background: #1d4d33;
    transform: translateY(-1px);
}

.b3chat-publish-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.b3chat-publish-btn i {
    font-size: 1rem;
}

.b3chat-publish-hint {
    color: #6b6b65;
    font-size: 0.82rem;
}

.b3chat-publish-confirm {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.b3chat-publish-confirm strong {
    color: #2a2a2a;
}

.b3chat-publish-confirm span {
    color: #555;
    font-size: 0.85rem;
}

.b3chat-publish-actions {
    display: flex;
    gap: 8px;
    margin-top: 6px;
}

.b3chat-publish-go {
    background: #c08a3e;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
}

.b3chat-publish-go:hover {
    background: #a87432;
}

.b3chat-publish-cancel {
    background: transparent;
    color: #6b6b65;
    border: 1px solid #cfcfc7;
    padding: 8px 14px;
    border-radius: 8px;
    cursor: pointer;
}

.b3chat-publish-cancel:hover {
    background: #ececdf;
}

.b3chat-publish-progress {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #555;
    padding: 4px 0;
}

.b3chat-publish-result {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 4px 0;
    font-weight: 500;
}

.b3chat-publish-result.success {
    color: #2c6e49;
}

.b3chat-publish-result.success i {
    color: #2c6e49;
}

.b3chat-publish-result.error {
    color: #a83232;
}

.b3chat-publish-result.error i {
    color: #a83232;
}

.b3chat-publish-dismiss {
    margin-left: auto;
    background: transparent;
    color: inherit;
    border: 1px solid currentColor;
    padding: 4px 12px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.85rem;
    opacity: 0.7;
}

.b3chat-publish-dismiss:hover {
    opacity: 1;
}
