    /* 文件: css/stickers.css */

    /* ========== 表情包面板主容器 (Telegram风格) ========== */
    #sticker-panel {
        position: absolute;
        bottom: 0;
        left: 0;
        right: 0;
        background: #ffffff;
        border-radius: 20px 20px 0 0;
        box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.15);
        width: 100%;
        height: 50vh; /* 紧凑高度，缩短底部距离 */
        display: flex;
        flex-direction: column;
        transform: translateY(100%);
        transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        z-index: 1001;
        pointer-events: auto;
        overflow: hidden;
    }

    #sticker-panel.visible {
        transform: translateY(0);
    }

    #sticker-panel.hidden {
        transform: translateY(100%);
    }

    /* ========== 分类标签页 ========== */
    .sticker-category-tabs {
        display: flex;
        gap: 8px;
        padding: 16px 16px 12px;
        border-bottom: 1px solid #e8e8e8;
        overflow-x: auto;
        scrollbar-width: none;
        -ms-overflow-style: none;
    }

    .sticker-category-tabs::-webkit-scrollbar {
        display: none;
    }

    .category-tab {
        display: flex;
        align-items: center;
        gap: 6px;
        padding: 8px 16px;
        background: #f0f0f0;
        border-radius: 20px;
        cursor: pointer;
        transition: all 0.2s ease;
        white-space: nowrap;
        user-select: none;
    }

    .category-tab:hover {
        background: #e0e0e0;
        transform: translateY(-2px);
    }

    .category-tab.active {
        background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
        color: white;
        box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
    }

    .category-emoji {
        font-size: 20px;
    }

    .category-name {
        font-size: 14px;
        font-weight: 600;
        font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
        letter-spacing: 0.01em;
        text-rendering: optimizeLegibility;
        -webkit-font-smoothing: antialiased;
        -moz-osx-font-smoothing: grayscale;
        line-height: 1.4;
    }

    /* ========== 表情包网格 ========== */
    .sticker-grid-container {
        flex: 1;
        overflow-y: auto;
        padding: 16px;
    }

    .sticker-grid {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(70px, 1fr));
        gap: 8px;
    }

    /* Recent 网格（与sticker-grid风格一致，尺寸略小） */
    .recent-stickers-grid {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(70px, 1fr));
        gap: 8px;
    }

    .sticker-item {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        cursor: pointer;
        border-radius: 12px;
        background: transparent;
        transition: transform 0.2s ease, background 0.2s ease;
        overflow: visible;
        padding: 6px;
        height: 70px; /* 紧凑高度，与缩小间距匹配 */
    }

    .sticker-item:hover {
        background: rgba(0, 0, 0, 0.05);
        transform: scale(1.1);
        /* 移除阴影效果 */
    }

    .sticker-item:active {
        transform: scale(0.95);
    }

    .sticker-item img {
        width: 100%;
        height: 100%;
        object-fit: contain;
        pointer-events: none;
        border-radius: 8px;
    }

    /* 方形缩略图容器，保证贴纸完整显示 */
    .sticker-thumb {
        width: 100%;
        aspect-ratio: 1 / 1;
        border-radius: 8px;
        overflow: hidden;
        flex: 0 0 auto;
    }

    /* 标题（多语言显示名）- 已隐藏 */
    .sticker-caption {
        display: none !important;
        width: 0;
        height: 0;
        margin: 0;
        padding: 0;
        font-size: 0;
        overflow: hidden;
    }

    .empty-stickers {
        grid-column: 1 / -1;
        text-align: center;
        padding: 40px 20px;
        color: #999;
        font-size: 14px;
        font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
        font-weight: 500;
        letter-spacing: 0.005em;
        text-rendering: optimizeLegibility;
        -webkit-font-smoothing: antialiased;
        -moz-osx-font-smoothing: grayscale;
        line-height: 1.5;
    }

    /* ========== 功能标签页 ========== */
    .sticker-function-tabs {
        display: flex;
        border-top: 1px solid #e8e8e8;
        background: white;
        padding: 8px;
        gap: 4px;
    }

    .function-tab {
        flex: 1;
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 4px;
        padding: 10px;
        background: transparent;
        border: none;
        border-radius: 12px;
        cursor: pointer;
        transition: all 0.2s ease;
        font-size: 12px;
        color: #666;
    }

    .function-tab:hover {
        background: #f0f0f0;
    }

    .function-tab.active {
        background: #667eea;
        color: white;
    }

    .tab-icon {
        font-size: 20px;
    }

    .tab-label {
        font-size: 12px;
        font-weight: 600;
        font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
        letter-spacing: 0.01em;
        text-rendering: optimizeLegibility;
        -webkit-font-smoothing: antialiased;
        -moz-osx-font-smoothing: grayscale;
    }

    /* ========== 表情包在聊天中的样式 ========== */
    .sticker-message {
        background: transparent !important;
        box-shadow: none !important;
        padding: 4px !important;
    }

    .sticker-container {
        display: inline-block;
        max-width: 150px;
    }

    .sticker-img {
        width: 100%;
        height: auto;
        display: block;
        border-radius: 8px;
    }

    /* ========== 表情包动画 ========== */

    /* 发送动画 - 弹出效果 */
    @keyframes popIn {
        0% {
            transform: scale(0);
            opacity: 0;
        }
        50% {
            transform: scale(1.1);
        }
        100% {
            transform: scale(1);
            opacity: 1;
        }
    }

    .sticker-pop-in {
        animation: popIn 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    }

    /* 接收动画 - 弹跳效果 */
    @keyframes bounceIn {
        0% {
            transform: scale(0) rotate(-10deg);
            opacity: 0;
        }
        50% {
            transform: scale(1.2) rotate(5deg);
        }
        70% {
            transform: scale(0.9) rotate(-5deg);
        }
        100% {
            transform: scale(1) rotate(0deg);
            opacity: 1;
        }
    }

    .sticker-bounce-in {
        animation: bounceIn 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    }

    /* 飞入动画 - 表情从面板飞到聊天区域 */
    .sticker-flying {
        pointer-events: none;
        animation: flyingRotate 0.4s ease-out;
    }

    @keyframes flyingRotate {
        0% {
            transform: scale(1) rotate(0deg);
        }
        100% {
            transform: scale(0.8) rotate(360deg);
        }
    }

    /* ========== Toast 提示 ========== */
    .sticker-toast {
        position: fixed;
        top: 20px;
        left: 50%;
        transform: translateX(-50%) translateY(-100px);
        background: rgba(0, 0, 0, 0.8);
        color: white;
        padding: 12px 24px;
        border-radius: 20px;
        font-size: 14px;
        z-index: 10001;
        opacity: 0;
        transition: all 0.3s ease;
        pointer-events: none;
    }

    .sticker-toast.show {
        transform: translateX(-50%) translateY(0);
        opacity: 1;
    }

    /* ========== 永久移除所有sticker阴影 ========== */
    .sticker-item,
    .sticker-item *,
    .sticker-item:hover,
    .sticker-item:active,
    .sticker-item:focus,
    .sticker-thumb,
    .sticker-thumb *,
    .emoji-content-area .sticker-item,
    .emoji-content-area .sticker-thumb,
    .emoji-content-area .sticker-item *,
    .emoji-content-area .sticker-thumb *,
    .sticker-grid .sticker-item,
    .recent-stickers-grid .sticker-item,
    .sticker-grid .sticker-thumb,
    .recent-stickers-grid .sticker-thumb {
        box-shadow: none !important;
        filter: none !important;
        text-shadow: none !important;
        -webkit-box-shadow: none !important;
        -moz-box-shadow: none !important;
        background: transparent !important;
        outline: none !important;
        border: none !important;
    }

    .sticker-item {
        background: #f8f9fa !important;
    }

    .sticker-item:hover {
        transform: scale(1.1) !important;
        background: #e9ecef !important;
        /* 确保绝对没有阴影 */
    }

    .sticker-thumb {
        background: transparent !important;
    }

    /* ========== 表情包按钮样式 ========== */
    .sticker-btn {
        font-size: 22px;
        padding: 8px 12px;
        background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
        border: none;
        border-radius: 12px;
        cursor: pointer;
        transition: all 0.3s ease;
        box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
    }

    .sticker-btn:hover {
        transform: scale(1.1) rotate(5deg);
        box-shadow: 0 4px 16px rgba(102, 126, 234, 0.5);
    }

    .sticker-btn:active {
        transform: scale(0.95);
    }

    /* ========== 滚动条美化 ========== */
    .sticker-grid-container::-webkit-scrollbar {
        width: 6px;
    }

    .sticker-grid-container::-webkit-scrollbar-track {
        background: #f1f1f1;
        border-radius: 10px;
    }

    .sticker-grid-container::-webkit-scrollbar-thumb {
        background: linear-gradient(180deg, #667eea 0%, #764ba2 100%);
        border-radius: 10px;
    }

    .sticker-grid-container::-webkit-scrollbar-thumb:hover {
        background: linear-gradient(180deg, #764ba2 0%, #667eea 100%);
    }

    /* ========== 响应式设计 ========== */
    @media (max-width: 768px) {
        #sticker-panel {
            max-width: 100%;
            height: 48vh; /* 平板紧凑高度 */
            border-radius: 16px 16px 0 0;
            z-index: 10001; /* 在移动端提高z-index确保显示在聊天窗口上方 */
        }

        .emoji-container {
            z-index: 10001;
        }
        
        .sticker-grid {
            grid-template-columns: repeat(auto-fill, minmax(70px, 1fr));
            gap: 8px;
        }
        
        .category-tab {
            padding: 6px 12px;
        }
        
        .category-name {
            font-size: 12px;
            font-weight: 600;
            font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
            letter-spacing: 0.01em;
            text-rendering: optimizeLegibility;
            -webkit-font-smoothing: antialiased;
            -moz-osx-font-smoothing: grayscale;
            line-height: 1.4;
        }
        
        .sticker-container {
            max-width: 120px;
        }
    }

    @media (max-width: 480px) {
        #sticker-panel {
            height: 40vh; /* 手机紧凑高度，进一步缩短底部距离 */
        }
        
        .sticker-grid {
            grid-template-columns: repeat(auto-fill, minmax(60px, 1fr));
            gap: 6px;
        }
        
        .sticker-category-tabs {
            padding: 12px 12px 8px;
        }
        
        .category-emoji {
            font-size: 18px;
        }
        
        .tab-icon {
            font-size: 18px;
        }
        
        .function-tab {
            padding: 8px 4px;
            font-size: 11px;
        }
    }

    /* ========== 加载状态 ========== */
    .sticker-item img[loading="lazy"] {
        background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
        background-size: 200% 100%;
        animation: loading 1.5s infinite;
    }

    @keyframes loading {
        0% {
            background-position: 200% 0;
        }
        100% {
            background-position: -200% 0;
        }
    }

    /* ========== 消息时间戳 ========== */
    .message-time {
        font-size: 11px;
        color: #999;
        margin-top: 4px;
        text-align: right;
    }

    .sticker-message .message-time {
        text-align: center;
    }

    /* ========== 过滤/过渡动画 ========== */
    .emoji-item-btn,
    .sticker-item {
        transition: opacity 0.18s ease, transform 0.18s ease;
    }

    .filter-hide {
        opacity: 0;
        transform: scale(0.96);
        pointer-events: none;
    }

    /* 标签页内容淡入（可由JS选择性添加） */
    .content-fade-enter {
        opacity: 0;
    }
    .content-fade-enter.content-fade-enter-active {
        opacity: 1;
        transition: opacity 0.18s ease;
    }

    /* ========== 预览 Overlay ========== */
    .sticker-preview-overlay {
        position: fixed;
        inset: 0;
        background: rgba(0,0,0,0.35);
        display: flex;
        align-items: center;
        justify-content: center;
        opacity: 0;
        transition: opacity 0.2s ease;
        z-index: 10002;
    }
    .sticker-preview-overlay.show {
        opacity: 1;
    }
    .sticker-preview-img {
        width: min(60vw, 360px);
        height: auto;
        border-radius: 12px;
        box-shadow: 0 10px 30px rgba(0,0,0,0.25);
        background: #fff;
    }

    /* ========== Emoji模式样式 ========== */
    .emoji-container {
        position: absolute;
        bottom: 0;
        left: 0;
        right: 0;
        background: #f5f5f5;
        border-radius: 20px 20px 0 0;
        width: 100%;
        height: 300px;
        padding: 20px;
        transform: translateY(100%);
        transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        z-index: 1002; /* 在面板内部显示 */
        overflow-y: auto;
        pointer-events: auto;
    }

    .emoji-container.visible {
        transform: translateY(0);
    }

    /* 确保emoji容器在sticker面板内部正确显示 */
    #sticker-panel .emoji-container {
        position: absolute;
        bottom: 0;
        left: 0;
        right: 0;
        height: 300px;
    }

    .emoji-grid {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(40px, 1fr));
        gap: 6px;
    }

    /* 表情面板内部的按钮，避免与聊天输入区的表情按钮冲突 */
    .sticker-panel .emoji-btn,
    .emoji-panel .emoji-btn {
        background: none;
        border: none;
        font-size: 24px;
        padding: 6px;
        border-radius: 8px;
        cursor: pointer;
        transition: all 0.2s ease;
        text-align: center;
    }

    .sticker-panel .emoji-btn:hover,
    .emoji-panel .emoji-btn:hover {
        background: rgba(0,0,0,0.1);
        transform: scale(1.1);
    }


    /* ========== 性能优化 ========== */
    .sticker-item,
    .category-tab,
    .function-tab {
        will-change: transform;
    }

    #sticker-panel {
        will-change: transform;
        -webkit-overflow-scrolling: touch;
    }

    /* 减少动画性能消耗 */
    @media (prefers-reduced-motion: reduce) {
        * {
            animation-duration: 0.01ms !important;
            animation-iteration-count: 1 !important;
            transition-duration: 0.01ms !important;
        }
    }

    /* ========== Glassmorphism 表情包面板 ========== */

/* Glassmorphism 标签容器 */
.glassmorphism-tabs {
    display: flex;
    position: relative;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 16px;
    padding: 6px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    margin-bottom: 8px;
}

    /* Glassmorphism 标签 */
    .glassmorphism-tabs .glass-tab {
        flex: 1;
        padding: 14px 20px;
        text-align: center;
        cursor: pointer;
        transition: all 0.3s;
        font-weight: 600;
        color: #666;
        position: relative;
        z-index: 1;
        border-radius: 10px;
        font-size: 14px;
        font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
        letter-spacing: 0.015em;
        text-rendering: optimizeLegibility;
        -webkit-font-smoothing: antialiased;
        -moz-osx-font-smoothing: grayscale;
        line-height: 1.4;
    }

    .glassmorphism-tabs .glass-tab.active {
        color: #333;
    }

    /* Glassmorphism 滑块 */
    .glassmorphism-tabs .glass-slider {
        position: absolute;
        top: 6px;
        height: calc(100% - 12px);
        background: white;
        border-radius: 10px;
        transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
        box-shadow: 0 8px 16px rgba(0,0,0,0.1);
        z-index: 0;
    }

/* 内容包装器（带水印） */
.glass-content-wrapper {
    position: relative;
    margin-top: 0;
    padding: 0;
    background: #f8f9fa;
    border-radius: 12px;
    height: 100%;
    min-height: 150px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

/* 背景水印 */
.glass-content-wrapper::before {
    content: attr(data-bg);
    position: absolute;
    font-size: 5em;
    color: rgba(0, 0, 0, 0.04);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    pointer-events: none;
    user-select: none;
    z-index: 0;
    opacity: 0.7;
}

/* 表情包视窗 */
.sticker-pack-viewport {
    position: relative;
    z-index: 1;
    width: 100%;
    height: 100%;
    flex: 1;
    overflow: hidden;
}

    /* ========== Telegram风格表情包面板 ========== */

    /* CSS 变量定义 */
    :root {
        --tg-blue: #2AABEE;
        --tg-blue-hover: rgba(42, 171, 238, 0.08);
        --tg-blue-focus: rgba(42, 171, 238, 0.35);
        --tg-text-secondary: #6b7785;
        --tg-border: #e4e4e7;
        --tg-shadow: rgba(0, 0, 0, 0.04);
    }

    /* 标签页栏 */
    .emoji-tab-bar {
        display: flex;
        background: linear-gradient(180deg, #ffffff 0%, #fafbfc 100%);
        padding: 0;
        margin: 0;
        position: relative;
        box-shadow: 0 1px 0 var(--tg-shadow);
        backdrop-filter: blur(8px);
        -webkit-backdrop-filter: blur(8px);
    }

    .emoji-tab {
        flex: 1;
        display: flex;
        flex-direction: row;
        align-items: center;
        justify-content: center;
        padding: 12px 16px;
        background: none;
        border: none;
        cursor: pointer;
        transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
        font-size: 13px;
        font-weight: 500;
        color: var(--tg-text-secondary);
        position: relative;
        letter-spacing: 0.3px;
        min-height: 48px;
        box-sizing: border-box;
        border-radius: 8px;
        margin: 4px 2px;
    }

    .emoji-tab::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: var(--tg-blue-hover);
        border-radius: inherit;
        opacity: 0;
        transition: opacity 0.2s ease;
    }

    .emoji-tab:hover {
        color: var(--tg-blue);
        transform: translateY(-1px);
    }

    .emoji-tab:hover::before {
        opacity: 1;
    }

    .emoji-tab.active {
        color: var(--tg-blue);
        background: transparent;
        font-weight: 600;
        transform: translateY(-1px);
    }

    .emoji-tab.active::before {
        opacity: 1;
        background: var(--tg-blue-hover);
    }

    .emoji-tab:focus-visible {
        outline: 2px solid var(--tg-blue-focus);
        outline-offset: 2px;
        border-radius: 8px;
    }

    .emoji-tab .tab-icon {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 16px;
        height: 16px;
        margin-right: 6px;
        flex-shrink: 0;
        opacity: 0.7;
        transition: opacity 0.2s ease;
    }

    .emoji-tab:hover .tab-icon,
    .emoji-tab.active .tab-icon {
        opacity: 1;
    }

    .emoji-tab .tab-icon svg {
        width: 16px;
        height: 16px;
        stroke-width: 1.5;
    }

    .emoji-tab .tab-label {
        font-size: 13px;
        line-height: 1.3;
        white-space: nowrap;
        font-weight: 600;
        font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
        letter-spacing: 0.02em;
        text-rendering: optimizeLegibility;
        -webkit-font-smoothing: antialiased;
        -moz-osx-font-smoothing: grayscale;
    }

    /* Telegram风格：顶栏滑块指示器 */
    .emoji-tab-indicator {
        position: absolute;
        bottom: 4px;
        left: 0;
        height: 2px;
        background: linear-gradient(90deg, var(--tg-blue) 0%, #5AC8FA 100%);
        border-radius: 1px;
        transform: translateX(0) scaleX(0);
        width: 0;
        transition: transform 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94), width 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
        box-shadow: 0 1px 3px rgba(42, 171, 238, 0.3);
        will-change: transform, width;
    }

    .tab-label {
        font-size: 12px;
        font-weight: 600;
        font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
        letter-spacing: 0.01em;
        text-rendering: optimizeLegibility;
        -webkit-font-smoothing: antialiased;
        -moz-osx-font-smoothing: grayscale;
    }

    /* 内容区域 */
    .emoji-content-area {
        flex: 1;
        overflow: hidden; /* 内部网格滚动，保持统一高度 */
        display: flex;
        flex-direction: column;
        min-height: 0; /* 防止子元素溢出导致高度跳变 */
    }

    /* 统一三个tab内容区域高度：网格在内容区内滚动 */
    .emoji-content-area > .emoji-grid,
    .emoji-content-area > .sticker-grid,
    .emoji-content-area > .recent-stickers-grid {
        flex: 1;
        min-height: 0;
        overflow-y: auto;
        overscroll-behavior: contain; /* 防止外层滚动穿透 */
        -webkit-overflow-scrolling: touch; /* 惯性滚动 */
    }

    /* 统一内容入场动画（与stickers行为一致，轻微淡入+上移） */
    .content-enter {
        opacity: 0;
        transform: translateY(8px);
    }
    .content-enter-active {
        opacity: 1;
        transform: translateY(0);
        transition: opacity .18s ease, transform .18s ease;
    }

    /* Telegram风格：Pack strip + 水平视窗 */
    .sticker-pack-strip {
        position: relative;
        display: flex;
        gap: 8px;
        padding: 12px 12px 8px;
        background: #f8f9fa;
        border-bottom: 1px solid #e9ecef;
        overflow-x: auto;
        scrollbar-width: none;
    }
    .sticker-pack-strip::-webkit-scrollbar { display: none; }
    .pack-btn {
        width: 40px;
        height: 40px;
        border-radius: 50%;
        border: 2px solid #e9ecef;
        background: #fff;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 20px;
        cursor: pointer;
        transition: transform .18s ease, border-color .18s ease, background .18s ease;
    }
    .pack-btn:hover { transform: scale(1.1); border-color: #0088cc; }
    .pack-btn.active { background: #0088cc; color: #fff; border-color: #0088cc; }
    .pack-indicator {
        position: absolute;
        bottom: 0;
        left: 0;
        height: 3px;
        background: #0088cc;
        border-radius: 2px;
        transition: transform .18s ease, width .18s ease;
    }

    .sticker-pack-viewport {
        position: relative;
        width: 100%;
        flex: 1;
        overflow: hidden;
    }
    .sticker-pack-pages {
        display: flex;
        width: 100%;
        height: 100%;
        will-change: transform;
        transition: transform .2s cubic-bezier(.4,0,.2,1);
    }
    .sticker-pack-page {
        flex: 0 0 100%;
        overflow-y: auto;
    }

    /* 弹性下拉/上推时的位移过渡 */
    .elastic-scrolling {
        will-change: transform;
        transition: transform 0.2s ease-out;
    }

    /* 表情包分类选择器 */
    .sticker-category-selector {
        display: flex;
        gap: 8px;
        padding: 12px 16px;
        background: linear-gradient(180deg, #ffffff 0%, #fafbfc 100%);
        border-bottom: 1px solid var(--tg-border);
        overflow-x: auto;
        scrollbar-width: none;
        -ms-overflow-style: none;
        position: relative;
        box-shadow: 0 1px 0 var(--tg-shadow);
    }

    .sticker-category-selector::-webkit-scrollbar {
        display: none;
    }

    .category-selector-btn {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 44px;
        height: 44px;
        border-radius: 50%;
        background: white;
        border: 2px solid var(--tg-border);
        cursor: pointer;
        transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
        font-size: 20px;
        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.06);
        position: relative;
        overflow: hidden;
    }

    .category-selector-btn::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: var(--tg-blue-hover);
        border-radius: inherit;
        opacity: 0;
        transition: opacity 0.25s ease;
    }

    .category-selector-btn:hover {
        border-color: var(--tg-blue);
        transform: translateY(-2px) scale(1.05);
        box-shadow: 0 4px 8px rgba(42, 171, 238, 0.15);
    }

    .category-selector-btn:hover::before {
        opacity: 1;
    }

    .category-selector-btn.active {
        background: var(--tg-blue);
        border-color: var(--tg-blue);
        color: white;
        transform: translateY(-2px) scale(1.05);
        box-shadow: 0 4px 12px rgba(42, 171, 238, 0.3);
    }

    .category-selector-btn.active::before {
        opacity: 0;
    }

    .category-selector-btn .category-emoji {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 20px;
        height: 20px;
        position: relative;
        z-index: 1;
    }

    .category-selector-btn .category-emoji svg {
        width: 20px;
        height: 20px;
        stroke-width: 1.5;
    }

    /* 表情包分类滑块指示器 */
    .sticker-category-indicator {
        position: absolute;
        bottom: 6px;
        left: 0;
        height: 3px;
        background: linear-gradient(90deg, var(--tg-blue) 0%, #5AC8FA 100%);
        border-radius: 2px;
        transform: translateX(0) scaleX(0);
        width: 0;
        transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94), width 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
        box-shadow: 0 1px 4px rgba(42, 171, 238, 0.3);
        will-change: transform, width;
        pointer-events: none;
    }

    /* 底部操作栏已移除 */

    /* 响应式设计 */
    @media (max-width: 768px) {
        #sticker-panel {
            max-height: 48vh; /* 与平板高度保持一致 */
        }

        .emoji-tab {
            padding: 10px 6px;
        }

        .emoji-item-btn {
            min-height: 40px;
            font-size: 24px;
        }
    }

    @media (max-width: 480px) {
        #sticker-panel {
            max-height: 40vh; /* 与手机高度保持一致 */
        }

        .emoji-tab-bar {
            padding: 0 8px;
        }

        .emoji-tab {
            padding: 10px 12px;
            font-size: 12px;
            min-height: 44px;
            margin: 2px 1px;
        }

        .emoji-tab .tab-icon {
            width: 14px;
            height: 14px;
            margin-right: 4px;
        }

        .emoji-tab .tab-icon svg {
            width: 14px;
            height: 14px;
        }

        .emoji-tab .tab-label {
            font-size: 11px;
        }

        .category-selector-btn {
            width: 40px;
            height: 40px;
        }

        .category-selector-btn .category-emoji svg {
            width: 18px;
            height: 18px;
        }
    }

    /* 触摸设备优化 */
    @media (hover: none) and (pointer: coarse) {
        .emoji-tab {
            min-height: 44px;
            padding: 12px 16px;
        }

        .emoji-tab:hover {
            transform: none;
        }

        .emoji-tab:active {
            transform: scale(0.98);
            transition: transform 0.1s ease;
        }
    }

    /* 高对比度模式支持 */
    @media (prefers-contrast: high) {
        .emoji-tab {
            border: 1px solid transparent;
        }

        .emoji-tab.active {
            border-color: var(--tg-blue);
            background: rgba(42, 171, 238, 0.1);
        }
    }

    /* 减少动画偏好 */
    @media (prefers-reduced-motion: reduce) {
        .emoji-tab,
        .emoji-tab-indicator {
            transition: none;
        }

        .emoji-tab:hover,
        .emoji-tab.active {
            transform: none;
        }

        .category-selector-btn,
        .sticker-category-indicator {
            transition: none;
        }

        .category-selector-btn:hover,
        .category-selector-btn.active {
            transform: none;
        }

        .category-selector-btn:hover {
            transform: none;
        }

        .category-selector-btn:active {
            transform: scale(0.95);
            transition: transform 0.1s ease;
        }
    }

