/* 前台浮动客服入口（由 view('kefu/embed.tag') 引入，未引入则无样式） */
.kefu-float-entry {
    position: fixed;
    right: 24px;
    bottom: 24px;
    width: 48px;
    height: 48px;
    margin: 0;
    padding: 0;
    border: none;
    border-radius: 5px;
    background: #1989fa;
    color: #fff;
    box-shadow: 0 2px 10px rgba(25, 137, 250, 0.3);
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s ease;
    text-decoration: none;
    cursor: pointer;
    font: inherit;
    line-height: 1;
    -webkit-tap-highlight-color: transparent;
 
}
.kefu-float-entry:hover {
    background: #0d6edb;
    color: #fff;
    transform: none;
}
.kefu-float-entry .layui-icon {
    font-size: 24px;
}
.kefu-float-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    min-width: 18px;
    height: 18px;
    border-radius: 0;
    background: #f56c6c;
    color: #fff;
    font-size: 11px;
    font-weight: 600;
    line-height: 18px;
    text-align: center;
    padding: 0 5px;
    display: none;
    box-sizing: border-box;
    z-index: 2;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.15);
    align-items: center;
    justify-content: center;
}

/* 右下角 iframe 客服浮层 */
.kefu-float-panel {
    position: fixed;
    right: 24px;
    bottom: 84px;
    z-index: 99998;
    width: min(420px, calc(100vw - 32px));
    height: min(560px, calc(100vh - 96px));
    max-height: min(560px, calc(100vh - 96px));
    min-height: 280px;
    display: flex;
    flex-direction: column;
    background: #fff;
    border-radius: 0;
    overflow: hidden;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.12), 0 0 0 1px rgba(0, 0, 0, 0.06);
    box-sizing: border-box;
}
.kefu-float-panel[hidden] {
    display: none !important;
}
.kefu-float-panel-hd {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 0 16px;
    height: 44px;
    background: #1e3a5f;
    border-bottom: none;
}
.kefu-float-panel-title {
    font-size: 14px;
    font-weight: 600;
    color: #fff;
}
.kefu-float-panel-close {
    margin: 0;
    padding: 0 6px;
    border: none;
    background: transparent;
    color: rgba(255, 255, 255, 0.7);
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
    border-radius: 0;
    transition: color 0.15s;
}
.kefu-float-panel-close:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
}
.kefu-float-panel-frame {
    flex: 1 1 auto;
    width: 100%;
    min-height: 0;
    border: 0;
    background: #f0f2f5;
}
@media (max-width: 480px) {
    .kefu-float-panel {
        right: 0;
        left: 0;
        bottom: 72px;
        width: auto;
        height: min(520px, calc(100vh - 80px));
        max-height: min(520px, calc(100vh - 80px));
    }
}
