/* DevQ Chatbot — public site widget. Scoped under .devq-chatbot to avoid
   clashing with theme styles. Floating bottom-right bubble that expands
   into a chat panel. */

.devq-chatbot {
    position: fixed;
    right: 22px;
    bottom: 22px;
    z-index: 2147483600;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    color: #0f172a;
}

.devq-chatbot-bubble {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    border: none;
    border-radius: 50%;
    background: linear-gradient(135deg, #00c2ab, #008e7d);
    color: #fff;
    cursor: pointer;
    box-shadow: 0 10px 28px -8px rgba(0, 142, 125, 0.55), 0 4px 12px rgba(0,0,0,0.18);
    transition: transform 0.18s ease, box-shadow 0.18s ease;
}
.devq-chatbot-bubble:hover {
    transform: translateY(-2px) scale(1.04);
    box-shadow: 0 14px 32px -8px rgba(0, 142, 125, 0.65), 0 6px 16px rgba(0,0,0,0.2);
}
.devq-chatbot-bubble svg { display: block; }

.devq-chatbot-panel {
    position: absolute;
    right: 0;
    bottom: 72px;
    width: min(360px, calc(100vw - 32px));
    height: min(520px, calc(100vh - 110px));
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 24px 60px -16px rgba(15, 23, 42, 0.35), 0 8px 20px rgba(0,0,0,0.12);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    animation: devqChatbotIn 0.18s ease-out;
}
@keyframes devqChatbotIn {
    from { transform: translateY(8px) scale(0.97); opacity: 0; }
    to   { transform: translateY(0) scale(1); opacity: 1; }
}

.devq-chatbot-head {
    background: linear-gradient(135deg, #00c2ab, #008e7d);
    color: #fff;
    padding: 14px 18px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.devq-chatbot-title {
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.01em;
}
.devq-chatbot-close {
    background: transparent;
    border: none;
    color: rgba(255,255,255,0.85);
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
    padding: 0 4px;
    transition: color 0.12s;
}
.devq-chatbot-close:hover { color: #fff; }

.devq-chatbot-log {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    background: #f8fafc;
}

.devq-chatbot-msg {
    max-width: 80%;
    padding: 9px 13px;
    border-radius: 14px;
    font-size: 13.5px;
    line-height: 1.45;
    word-wrap: break-word;
    animation: devqChatbotMsgIn 0.16s ease-out;
}
@keyframes devqChatbotMsgIn {
    from { transform: translateY(4px); opacity: 0; }
    to   { transform: translateY(0); opacity: 1; }
}
.devq-chatbot-msg--user {
    align-self: flex-end;
    background: #00c2ab;
    color: #fff;
    border-bottom-right-radius: 4px;
}
.devq-chatbot-msg--assistant {
    align-self: flex-start;
    background: #fff;
    color: #1e293b;
    border: 1px solid rgba(15, 23, 42, 0.08);
    border-bottom-left-radius: 4px;
}
.devq-chatbot-msg--assistant a {
    color: #008e7d;
    text-decoration: underline;
}

.devq-chatbot-typing {
    display: inline-flex;
    gap: 4px;
    padding: 12px 14px;
}
.devq-chatbot-typing span {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #94a3b8;
    animation: devqChatbotTyping 1.2s infinite ease-in-out;
}
.devq-chatbot-typing span:nth-child(2) { animation-delay: 0.15s; }
.devq-chatbot-typing span:nth-child(3) { animation-delay: 0.3s; }
@keyframes devqChatbotTyping {
    0%, 60%, 100% { transform: translateY(0); opacity: 0.5; }
    30% { transform: translateY(-4px); opacity: 1; }
}

.devq-chatbot-form {
    display: flex;
    gap: 8px;
    padding: 12px;
    border-top: 1px solid rgba(15, 23, 42, 0.08);
    background: #fff;
}
.devq-chatbot-input {
    flex: 1;
    border: 1px solid rgba(15, 23, 42, 0.12);
    border-radius: 999px;
    padding: 9px 14px;
    font-size: 13.5px;
    color: #0f172a;
    background: #f1f5f9;
    outline: none;
    transition: border 0.12s, background 0.12s;
}
.devq-chatbot-input:focus {
    border-color: #00c2ab;
    background: #fff;
}
.devq-chatbot-send {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 50%;
    background: #00c2ab;
    color: #fff;
    cursor: pointer;
    transition: background 0.12s, transform 0.12s;
}
.devq-chatbot-send:hover { background: #008e7d; transform: scale(1.05); }
.devq-chatbot-send:disabled { background: #cbd5e1; cursor: not-allowed; }
