/* 顺律通在线客服浮动按钮 */
.chatbot-float-btn {
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, var(--primary, #1635b9) 0%, var(--secondary, #37c7d4) 100%);
    color: #fff;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.6rem;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 20px rgba(0,0,0,0.25);
    z-index: 9998;
    transition: transform 0.3s, box-shadow 0.3s;
    -webkit-tap-highlight-color: transparent;
}
.chatbot-float-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 28px rgba(0,0,0,0.35);
}
.chatbot-float-btn:active {
    transform: scale(0.95);
}

/* 小红点提示 */
.chatbot-float-btn .badge {
    position: absolute;
    top: -2px;
    right: -2px;
    width: 14px;
    height: 14px;
    background: #ff4d4f;
    border-radius: 50%;
    border: 2px solid #fff;
    display: none;
}

/* 对话框容器 */
.chatbot-dialog {
    position: fixed;
    bottom: 92px;
    right: 24px;
    width: 400px;
    height: 560px;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 12px 48px rgba(0,0,0,0.2);
    z-index: 9999;
    display: none;
    overflow: hidden;
    animation: chatbotSlideUp 0.3s ease;
}
.chatbot-dialog.open {
    display: flex;
    flex-direction: column;
}

@keyframes chatbotSlideUp {
    from { opacity: 0; transform: translateY(20px) scale(0.95); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

/* iframe 嵌入 */
.chatbot-dialog iframe {
    width: 100%;
    height: 100%;
    border: none;
    flex: 1;
}

/* 关闭按钮 */
.chatbot-close-btn {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 32px;
    height: 32px;
    background: rgba(0,0,0,0.15);
    border: none;
    border-radius: 50%;
    color: #fff;
    font-size: 1.1rem;
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 10;
    transition: background 0.2s;
}
.chatbot-close-btn:hover {
    background: rgba(0,0,0,0.3);
}

/* 移动端全屏 */
@media (max-width: 768px) {
    .chatbot-dialog {
        width: 100%;
        height: 100%;
        bottom: 0;
        right: 0;
        border-radius: 0;
    }
    .chatbot-float-btn {
        bottom: 16px;
        right: 16px;
        width: 50px;
        height: 50px;
        font-size: 1.4rem;
    }
}
