        /* ===== 聊天 + 表情 ===== */
        #chat-panel { position: absolute; left: 6px; right: 6px; bottom: 46px; z-index: 70;
            background: rgba(13,22,36,0.97); border: 1px solid rgba(255,255,255,0.14); border-radius: 14px;
            display: flex; flex-direction: column; box-shadow: 0 8px 30px rgba(0,0,0,0.6); max-height: 56vh; }
        .chat-head { display: flex; justify-content: space-between; align-items: center; padding: 8px 12px;
            border-bottom: 1px solid rgba(255,255,255,0.1); font-size: 14px; color: #e7eefb; }
        .chat-head button { background: none; border: none; color: #9fb0cc; font-size: 18px; cursor: pointer; }
        #chat-list { flex: 1; overflow-y: auto; padding: 8px 12px; min-height: 60px; max-height: 28vh; }
        .chat-row { font-size: 13px; margin-bottom: 5px; line-height: 1.4; }
        .chat-row .chat-name { color: #6ca0ff; font-weight: bold; margin-right: 6px; }
        .chat-row.mine .chat-name { color: #f4d35e; }
        .chat-row .chat-text { color: #dfe7f5; }
        .chat-emotes, .chat-phrases { display: flex; flex-wrap: wrap; gap: 6px; padding: 7px 10px; justify-content: center; }
        .chat-emotes { border-top: 1px solid rgba(255,255,255,0.08); }
        .emote-btn { flex: 0 0 auto; width: 38px; height: 38px; font-size: 20px; border-radius: 9px;
            background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.12); cursor: pointer; }
        .chat-phrases { flex-direction: column; flex-wrap: nowrap; align-items: stretch; gap: 4px; max-height: 56vh; overflow-y: auto; }   /* 单列竖排(nowrap 防多列横滑)，字体小一页显全 */
        .chat-phrase-toggle { flex: 0 0 auto; background: rgba(255,255,255,0.08); color: #cdd9ef;
            border: 1px solid rgba(255,255,255,0.16); border-radius: 9px; padding: 0 12px; font-size: 13px; font-weight: bold; cursor: pointer; }
        .chat-phrase-toggle.on { background: #3a86ff; color: #fff; border-color: #3a86ff; }
        .phrase-btn { width: 100%; text-align: left; padding: 6px 10px; font-size: 12px; line-height: 1.25; border-radius: 8px; white-space: normal;
            background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.14); color: #dfe7f5; cursor: pointer; }
        .phrase-btn::before { content: "◆ "; color: #6f88b5; }
        .chat-input-row { display: flex; gap: 8px; padding: 8px 10px 10px; }
        .chat-input-row input { flex: 1; min-width: 0; border-radius: 9px; border: 1px solid rgba(255,255,255,0.16);
            background: rgba(255,255,255,0.06); color: #fff; padding: 9px 11px; font-size: 14px; }
        .chat-input-row button { flex: 0 0 auto; background: #3a86ff; color: #fff; border: none; border-radius: 9px;
            padding: 0 16px; font-weight: bold; cursor: pointer; }
        /* 临时语音：按住录音，松开发送；只显示短暂的可点击气泡，不进历史 */
        #voice-btn { touch-action: none; user-select: none; -webkit-user-select: none; }
        #voice-btn.recording { color: #fff; background: #d64040; border-color: #ff8585;
            box-shadow: 0 0 0 4px rgba(214,64,64,0.22); animation: voicePulse .8s ease-in-out infinite; }
        #voice-recording { position: absolute; left: 50%; bottom: 48px; z-index: 95; transform: translateX(-50%);
            min-width: 168px; padding: 9px 15px; border-radius: 20px; text-align: center; pointer-events: none;
            background: rgba(18,27,43,.96); color: #fff; border: 1px solid rgba(255,255,255,.2);
            box-shadow: 0 6px 22px rgba(0,0,0,.45); font-size: 13px; font-weight: bold; }
        #voice-recording.cancel { background: rgba(130,38,38,.96); }
        @keyframes voicePulse { 50% { transform: scale(1.08); } }
        .voice-bubble { pointer-events: auto; padding: 4px 6px; overflow: visible; }
        .voice-bubble button, .voice-float button { border: none; border-radius: 13px; padding: 5px 10px;
            background: #eff5ff; color: #23334d; font-weight: bold; cursor: pointer; white-space: nowrap; }
        .voice-bubble button.playing, .voice-float button.playing { background: #3a86ff; color: #fff; }
        .voice-bubble .voice-sender { display: none; }
        .voice-float { position: fixed; left: 50%; top: 72px; z-index: 96; transform: translateX(-50%);
            display: flex; gap: 7px; align-items: center; padding: 7px 10px; border-radius: 17px;
            background: rgba(13,22,36,.94); color: #dfe7f5; box-shadow: 0 5px 18px rgba(0,0,0,.45);
            animation: bubbleIn .2s ease-out; }
        /* 弹幕（聊天消息右→左滚动，带发送者 id）*/
        #danmaku-layer { position: fixed; left: 0; right: 0; top: 64px; height: 42%; z-index: 90;
            pointer-events: none; overflow: hidden; }
        .danmaku { position: absolute; left: 0; white-space: nowrap; font-size: 15px; font-weight: bold; color: #fff;
            text-shadow: 0 1px 4px rgba(0,0,0,0.9); padding: 3px 11px; border-radius: 14px;
            background: rgba(0,0,0,0.3); will-change: transform; animation: dmMove 7s linear forwards; }
        .danmaku .dm-name { color: #6ca0ff; margin-right: 6px; }
        @keyframes dmMove { from { transform: translateX(100vw); } to { transform: translateX(-110%); } }
        /* 座位冒泡（聊天/表情）*/
        .seat-bubble { position: absolute; left: 50%; bottom: 100%; transform: translateX(-50%);
            background: #fff; color: #1a2238; padding: 4px 10px; border-radius: 12px; font-size: 13px;
            white-space: nowrap; max-width: 160px; overflow: hidden; text-overflow: ellipsis; z-index: 9;
            box-shadow: 0 3px 8px rgba(0,0,0,0.4); margin-bottom: 6px; animation: bubbleIn 0.2s ease-out; }
        .seat-bubble.big { background: none; box-shadow: none; font-size: 40px; padding: 0;
            animation: emoteFloat 2.2s ease-out forwards; }
        @keyframes bubbleIn { from { opacity: 0; transform: translate(-50%, 6px); } to { opacity: 1; transform: translateX(-50%); } }
        @keyframes emoteFloat { 0% { opacity: 0; transform: translate(-50%, 10px) scale(0.5); }
            20% { opacity: 1; transform: translate(-50%, 0) scale(1.1); }
            70% { opacity: 1; transform: translate(-50%, -18px) scale(1); }
            100% { opacity: 0; transform: translate(-50%, -42px) scale(0.9); } }

