/* 全局样式 - UI增强版 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* 动态背景容器 */
.dynamic-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
    background: linear-gradient(135deg, #000000 0%, #071a12 25%, #0a2e20 50%, #071a12 75%, #000000 100%);
}

/* 粒子容器 */
.particles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

/* 单个粒子 */
.particle {
    position: absolute;
    width: 2px;
    height: 2px;
    background-color: var(--primary-light);
    border-radius: 50%;
    opacity: 0.6;
    animation: float 15s infinite linear;
    box-shadow: 0 0 8px var(--primary-light);
}

/* 粒子动画 */
@keyframes float {
    0% {
        transform: translateY(100vh) translateX(0);
        opacity: 0;
    }
    10% {
        opacity: 0.6;
    }
    90% {
        opacity: 0.6;
    }
    100% {
        transform: translateY(-10vh) translateX(100px);
        opacity: 0;
    }
}

@keyframes floatUp {
    0% {
        transform: translateY(100vh) translateX(0);
        opacity: 0;
    }
    10% {
        opacity: 0.8;
    }
    90% {
        opacity: 0.8;
    }
    100% {
        transform: translateY(-10vh) translateX(-50px);
        opacity: 0;
    }
}

@keyframes floatDiagonal {
    0% {
        transform: translateY(100vh) translateX(0);
        opacity: 0;
    }
    20% {
        opacity: 0.7;
    }
    80% {
        opacity: 0.7;
    }
    100% {
        transform: translateY(-20vh) translateX(150px) rotate(180deg);
        opacity: 0;
    }
}

/* 流动渐变背景 */
.flowing-gradient {
    position: absolute;
    top: 0;
    left: 0;
    width: 300%;
    height: 300%;
    background: radial-gradient(circle at 20% 50%, rgba(7, 193, 96, 0.15) 0%, transparent 50%),
                radial-gradient(circle at 80% 20%, rgba(24, 144, 255, 0.12) 0%, transparent 50%),
                radial-gradient(circle at 40% 80%, rgba(114, 46, 209, 0.12) 0%, transparent 50%),
                radial-gradient(circle at 60% 30%, rgba(19, 194, 194, 0.12) 0%, transparent 50%),
                radial-gradient(circle at 90% 70%, rgba(250, 50, 250, 0.1) 0%, transparent 50%),
                radial-gradient(circle at 10% 90%, rgba(50, 250, 250, 0.1) 0%, transparent 50%);
    animation: flow 25s infinite linear;
    filter: blur(1px);
    z-index: -1;
}

/* 流动动画 */
@keyframes flow {
    0% {
        transform: translate(0, 0) rotate(0deg);
    }
    50% {
        transform: translate(-25%, -25%) rotate(180deg);
    }
    100% {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}

/* 网格线效果 */
.grid-lines {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: linear-gradient(rgba(7, 193, 96, 0.05) 1px, transparent 1px),
                      linear-gradient(90deg, rgba(7, 193, 96, 0.05) 1px, transparent 1px);
    background-size: 50px 50px;
    animation: gridMove 20s infinite linear;
}

/* 网格移动动画 */
@keyframes gridMove {
    0% {
        background-position: 0 0;
    }
    100% {
        background-position: 50px 50px;
    }
}

/* CSS变量 - 扩展颜色方案 */
:root {
    /* 主色调 */
    --primary-color: #07c160;
    --primary-dark: #06ad56;
    --primary-darker: #059b4b;
    --primary-light: #09d26c;
    --primary-lighter: #0aff7a;
    
    /* 辅助色 */
    --secondary-color: #1890ff;
    --secondary-light: #40a9ff;
    --secondary-dark: #096dd9;
    --secondary-lighter: #69c0ff;
    
    /* 强调色 */
    --accent-color: #ff7875;
    --accent-purple: #722ed1;
    --accent-orange: #fa8c16;
    --accent-pink: #eb2f96;
    --accent-cyan: #13c2c2;
    
    /* 功能色 */
    --warning-color: #ffc107;
    --success-color: #52c41a;
    --error-color: #ff4d4f;
    --info-color: #1890ff;
    
    /* 中性色 */
    --white: #ffffff;
    --gray-50: #fafafa;
    --gray-100: #f5f5f5;
    --gray-200: #e5e5e5;
    --gray-300: #d9d9d9;
    --gray-400: #bfbfbf;
    --gray-500: #8c8c8c;
    --gray-600: #595959;
    --gray-700: #434343;
    --gray-800: #262626;
    --gray-900: #1f1f1f;
    
    /* 文本颜色 */
    --text-primary: #333333;
    --text-secondary: #666666;
    --text-tertiary: #999999;
    --text-light: #ffffff;
    
    /* 背景色 */
    --bg-primary: #ffffff;
    --bg-secondary: #f7f7f7;
    --bg-tertiary: #f0f0f0;
    --bg-gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --bg-gradient-2: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    --bg-gradient-3: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    --bg-gradient-4: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%);
    
    /* 边框和阴影 */
    --border-color: #e5e5e5;
    --border-light: rgba(255, 255, 255, 0.1);
    --shadow-light: 0 2px 8px rgba(0, 0, 0, 0.08);
    --shadow-medium: 0 4px 16px rgba(0, 0, 0, 0.12);
    --shadow-heavy: 0 8px 32px rgba(0, 0, 0, 0.16);
    --shadow-glow: 0 0 16px rgba(7, 193, 96, 0.4);
    --shadow-glow-purple: 0 0 16px rgba(114, 46, 209, 0.4);
    --shadow-glow-blue: 0 0 16px rgba(24, 144, 255, 0.4);
    
    /* 间距 */
    --spacing-xs: 4px;
    --spacing-sm: 8px;
    --spacing-md: 16px;
    --spacing-lg: 24px;
    --spacing-xl: 32px;
    --spacing-xxl: 48px;
    
    /* 圆角 */
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 20px;
    --radius-xxl: 30px;
    --radius-full: 50%;
    
    /* 过渡 */
    --transition-fast: 0.15s ease;
    --transition-normal: 0.3s ease;
    --transition-slow: 0.5s ease;
    --transition-cubic: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-bounce: 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

/* 深色模式变量 */
[data-theme="dark"] {
    /* 主色调 */
    --primary-color: #09d26c;
    --primary-dark: #06ad56;
    --primary-darker: #059b4b;
    --primary-light: #0aff7a;
    --primary-lighter: #0aff7a;
    
    /* 辅助色 */
    --secondary-color: #40a9ff;
    --secondary-light: #69c0ff;
    --secondary-dark: #1890ff;
    --secondary-lighter: #91d5ff;
    
    /* 强调色 */
    --accent-color: #ff7875;
    --accent-purple: #9254de;
    --accent-orange: #ff9c6e;
    --accent-pink: #f56a79;
    --accent-cyan: #36cfc9;
    
    /* 功能色 */
    --warning-color: #ffd666;
    --success-color: #95de64;
    --error-color: #ff7875;
    --info-color: #40a9ff;
    
    /* 中性色 */
    --white: #1f1f1f;
    --gray-50: #262626;
    --gray-100: #434343;
    --gray-200: #595959;
    --gray-300: #8c8c8c;
    --gray-400: #bfbfbf;
    --gray-500: #d9d9d9;
    --gray-600: #e5e5e5;
    --gray-700: #f5f5f5;
    --gray-800: #fafafa;
    --gray-900: #ffffff;
    
    /* 文本颜色 */
    --text-primary: #ffffff;
    --text-secondary: #d9d9d9;
    --text-tertiary: #8c8c8c;
    --text-light: #ffffff;
    
    /* 背景色 */
    --bg-primary: #1f1f1f;
    --bg-secondary: #262626;
    --bg-tertiary: #434343;
    --bg-gradient: linear-gradient(135deg, #373b44 0%, #4286f4 100%);
    --bg-gradient-2: linear-gradient(135deg, #2c3e50 0%, #fd746c 100%);
    --bg-gradient-3: linear-gradient(135deg, #141e30 0%, #243b55 100%);
    --bg-gradient-4: linear-gradient(135deg, #134e5e 0%, #71b280 100%);
    
    /* 边框和阴影 */
    --border-color: #434343;
    --border-light: rgba(255, 255, 255, 0.1);
    --shadow-light: 0 2px 8px rgba(0, 0, 0, 0.3);
    --shadow-medium: 0 4px 16px rgba(0, 0, 0, 0.4);
    --shadow-heavy: 0 8px 32px rgba(0, 0, 0, 0.5);
    --shadow-glow: 0 0 16px rgba(9, 210, 108, 0.4);
    --shadow-glow-purple: 0 0 16px rgba(146, 84, 222, 0.4);
    --shadow-glow-blue: 0 0 16px rgba(64, 169, 255, 0.4);
}

body {
    font-family: 'Microsoft YaHei', 'PingFang SC', 'Hiragino Sans GB', 'Segoe UI', Roboto, sans-serif;
    background-color: var(--bg-secondary);
    background-image: 
        radial-gradient(circle at 10% 20%, rgba(7, 193, 96, 0.05) 0%, rgba(7, 193, 96, 0) 20%),
        radial-gradient(circle at 80% 80%, rgba(24, 144, 255, 0.05) 0%, rgba(24, 144, 255, 0) 20%);
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: var(--spacing-md);
    transition: background-color var(--transition-normal);
}

/* 聊天容器 */
.chat-container {
    width: 100%;
    max-width: 800px;
    height: 90vh;
    background-color: #ffffff;
    border-radius: 10px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

/* 聊天头部 */
.chat-header {
    background-color: #ffffff;
    border-bottom: 1px solid #e5e5e5;
    padding: 16px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.group-info h1 {
    font-size: 18px;
    font-weight: 600;
    margin: 0;
    color: #333;
}

.user-details {
    display: flex;
    align-items: center;
    gap: 15px;
}

.current-nickname {
    font-size: 14px;
    color: #666;
    margin-right: 10px;
    font-weight: 500;
}

/* 用户头像 */
.avatar-container {
    position: relative;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.avatar-container::before {
    content: '';
    position: absolute;
    top: -4px;
    left: -4px;
    right: -4px;
    bottom: -4px;
    border-radius: 50%;
    background: linear-gradient(45deg, #07c160, #4fc1e9, #9370db, #07c160);
    z-index: -1;
    opacity: 0;
    transition: all 0.3s ease;
    animation: rotateGradient 3s linear infinite;
}

@keyframes rotateGradient {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

.avatar-container:hover::before {
    opacity: 1;
    transform: scale(1.05);
    box-shadow: 0 0 20px rgba(7, 193, 96, 0.4);
}

.avatar-container:hover {
    transform: translateY(-2px) scale(1.05);
}

.user-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background-color: #ffffff;
    border: 2px solid transparent;
    object-fit: cover;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    background-clip: padding-box;
    position: relative;
}

.user-avatar::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 50%;
    border: 2px solid transparent;
    background: linear-gradient(45deg, #07c160, #4fc1e9, #9370db) border-box;
    -webkit-mask: linear-gradient(#fff 0 0) padding-box, linear-gradient(#fff 0 0);
    mask: linear-gradient(#fff 0 0) padding-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.user-avatar:hover::after {
    opacity: 1;
}

.user-avatar:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(7, 193, 96, 0.3);
}

/* 昵称容器 */
.nickname-container {
    display: flex;
    align-items: center;
    gap: 10px;
}

.nickname-container label {
    font-size: 14px;
    color: #666;
}

/* 昵称输入框 */
.nickname-input {
    padding: 4px 8px;
    border: 1px solid #dcdcdc;
    border-radius: 4px;
    font-size: 14px;
    outline: none;
    width: 130px;
    background-color: #f7f7f7;
}

.nickname-input:focus {
    border-color: #07c160;
    background-color: #ffffff;
}

/* 聊天主区域 */
.chat-main {
    flex: 1;
    display: flex;
    overflow: hidden;
}

/* 聊天消息区域 */
.chat-messages {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
    background-color: #f7f7f7;
    background-image: url("data:image/svg+xml,%3Csvg width='32' height='32' viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23e5e5e5' fill-opacity='0.4'%3E%3Cpath d='M10 0h2v2h-2V0zm12 0h2v2h-2V0zM0 10h2v2H0v-2zm2 12h2v2H2v-2zM10 24h2v2h-2v-2zm12 0h2v2h-2v-2zM24 10h2v2h-2v-2zm0 12h2v2h-2v-2zM10 12h2v2h-2v-2zm12 0h2v2h-2v-2zM2 10h2v2H2v-2z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    display: flex;
    flex-direction: column;
    gap: 12px;
    transition: transform 0.3s ease;
}

/* 群成员列表 */
.group-members {
    width: 280px;
    background-color: #ffffff;
    border-left: 1px solid #e5e5e5;
    display: flex;
    flex-direction: column;
    transform: translateX(100%);
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: absolute;
    top: 60px;
    right: 0;
    bottom: 0;
    z-index: 100;
    box-shadow: -4px 0 16px rgba(0, 0, 0, 0.12);
    overflow: hidden;
}

/* 左侧联系人侧栏 */
.contacts-sidebar {
    width: 280px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.95) 0%, rgba(245, 245, 245, 0.9) 100%);
    backdrop-filter: blur(10px);
    border-right: 1px solid rgba(255, 255, 255, 0.2);
    display: flex;
    flex-direction: column;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 2px 0 16px rgba(0, 0, 0, 0.1), 0 0 30px rgba(7, 193, 96, 0.05);
    position: relative;
    overflow: hidden;
}

.contacts-sidebar::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 1px;
    height: 100%;
    background: linear-gradient(to bottom, transparent, rgba(7, 193, 96, 0.3), transparent);
    animation: sidebarGlow 3s ease-in-out infinite;
}

@keyframes sidebarGlow {
    0%, 100% {
        opacity: 0.3;
        transform: scaleY(0.8);
    }
    50% {
        opacity: 1;
        transform: scaleY(1);
    }
}

/* 联系人侧栏头部 */
.sidebar-header {
    padding: 16px 20px;
    border-bottom: 1px solid #e5e5e5;
    background-color: #f7f7f7;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.sidebar-header h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
    color: #333;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* 联系人列表 */
.contacts-list {
    flex: 1;
    padding: 12px 0;
    overflow-y: auto;
    background-color: #ffffff;
}

/* 联系人项 */
.contact-item {
    padding: 12px 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    border-bottom: 1px solid rgba(0, 0, 0, 0.03);
    background: linear-gradient(90deg, transparent, rgba(7, 193, 96, 0.03), transparent);
    background-size: 200% 100%;
    background-position: -100% 0;
}

/* 联系人项悬停效果 */
.contact-item:hover {
    background-color: rgba(7, 193, 96, 0.08);
    transform: translateX(4px) translateY(-1px);
    box-shadow: inset 4px 0 0 #07c160, 0 4px 8px rgba(0, 0, 0, 0.08);
    background-position: 100% 0;
}

/* 联系人项激活状态 */
.contact-item.active {
    background-color: rgba(7, 193, 96, 0.15);
    box-shadow: inset 4px 0 0 #07c160, 0 2px 4px rgba(7, 193, 96, 0.1);
    font-weight: 500;
    transform: translateX(4px);
}

/* 联系人头像 */
.contact-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid transparent;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    background-color: #f0f0f0;
    position: relative;
    overflow: hidden;
}

.contact-avatar::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transform: translateX(-100%);
    transition: transform 0.5s ease;
}

.contact-item:hover .contact-avatar {
    border-color: #07c160;
    transform: scale(1.1) rotate(5deg);
    box-shadow: 0 4px 12px rgba(7, 193, 96, 0.3);
}

.contact-item:hover .contact-avatar::before {
    transform: translateX(100%);
}

/* 联系人信息 */
.contact-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
    overflow: hidden;
}

/* 联系人名称 */
.contact-name {
    font-size: 15px;
    font-weight: 500;
    color: #333;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    transition: all 0.3s ease;
    position: relative;
}

.contact-item:hover .contact-name {
    color: #07c160;
    transform: translateX(4px);
}

/* 联系人在线状态 */
.contact-status {
    font-size: 12px;
    color: #999;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: all 0.3s ease;
}

.contact-item:hover .contact-status {
    color: #07c160;
    transform: translateX(4px);
}

/* 在线状态指示器 */
.status-indicator {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: #ccc;
    transition: all 0.3s ease;
    position: relative;
}

.status-indicator::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background-color: inherit;
    animation: ripple 2s infinite;
}

.status-indicator.online {
    background-color: #07c160;
    box-shadow: 0 0 8px rgba(7, 193, 96, 0.6), 0 0 16px rgba(7, 193, 96, 0.3);
    animation: pulse 2s infinite;
}

/* 在线状态脉冲动画 */
@keyframes pulse {
    0% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.3);
        opacity: 0.8;
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

/* 波纹扩散动画 */
@keyframes ripple {
    0% {
        transform: translate(-50%, -50%) scale(0.8);
        opacity: 1;
    }
    100% {
        transform: translate(-50%, -50%) scale(2.5);
        opacity: 0;
    }
}

/* 联系人列表滚动条样式 */
.contacts-list::-webkit-scrollbar {
    width: 6px;
}

.contacts-list::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.contacts-list::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 3px;
}

.contacts-list::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

.group-members.open {
    transform: translateX(0);
}

.group-members.open + .chat-messages {
    transform: translateX(-280px);
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

/* 群成员列表头部 */
.members-header {
    padding: 16px 20px;
    border-bottom: 1px solid #e5e5e5;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #f7f7f7;
}

.members-header h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
    color: #333;
}

.close-btn {
    width: 24px;
    height: 24px;
    border: none;
    background-color: transparent;
    color: #666;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 50%;
    transition: all 0.2s ease;
}

.close-btn:hover {
    background-color: #e5e5e5;
    color: #333;
}

/* 群成员列表内容 */
.members-list {
    flex: 1;
    padding: 12px 0;
    overflow-y: auto;
}

/* 群成员项 */
.member-item {
    padding: 12px 20px;
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    border-bottom: 1px solid rgba(0, 0, 0, 0.03);
    overflow: hidden;
}

.member-item:hover {
    background-color: #f5faff;
    transform: translateX(-4px);
    box-shadow: inset 4px 0 0 #07c160;
}

/* 群成员头像容器 */
.member-avatar-container {
    position: relative;
    width: 40px;
    height: 40px;
    flex-shrink: 0;
}

/* 群成员头像 */
.member-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
    transition: all 0.3s ease;
    background-color: #f0f0f0;
    border: 2px solid transparent;
}

.member-item:hover .member-avatar {
    border-color: #07c160;
    transform: scale(1.1);
}

/* 在线状态指示器 */
.member-status {
    position: absolute;
    bottom: -2px;
    right: -2px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: #ccc;
    border: 2px solid #ffffff;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
}

.member-status.online {
    background-color: #07c160;
    animation: pulse 2s infinite;
}

/* 群成员信息 */
.member-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.member-name {
    font-size: 14px;
    font-weight: 500;
    color: #333;
}

.member-join-time {
    font-size: 12px;
    color: #999;
}

/* 群成员按钮 */
.members-btn {
    background-color: #07c160;
    color: white;
    border: none;
    padding: 6px 12px;
    border-radius: 16px;
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    margin-left: 12px;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 4px;
}

.members-btn:hover {
    background-color: #06ad56;
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(7, 193, 96, 0.3);
}

.members-btn:active {
    background-color: #059b4b;
    transform: translateY(0);
    box-shadow: 0 1px 2px rgba(7, 193, 96, 0.3);
}

/* 消息容器 */
.message-container {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin-bottom: 12px;
    animation: messageSlideIn 0.3s ease-out;
}

.message-container.own {
    flex-direction: row-reverse;
}

/* 消息头像 */
.message-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background-color: #ffffff;
    border: 1px solid #e5e5e5;
    object-fit: cover;
    flex-shrink: 0;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

/* 单个消息样式 */
.message {
    background: linear-gradient(145deg, #ffffff, #f0f0f0);
    padding: 10px 14px;
    border-radius: 18px 18px 18px 4px;
    max-width: 70%;
    display: flex;
    flex-direction: column;
    gap: 4px;
    position: relative;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.08), 0 0 0 1px rgba(0, 0, 0, 0.02);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 14px;
    overflow: hidden;
    backdrop-filter: blur(5px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* 发送者自己的消息样式 */
.message.own {
    background: linear-gradient(145deg, #07c160, #06ad56);
    border-radius: 18px 18px 4px 18px;
    box-shadow: 0 4px 8px rgba(7, 193, 96, 0.15), 0 0 0 1px rgba(7, 193, 96, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* 消息悬停效果 */
.message:hover {
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.12), 0 0 20px rgba(255, 255, 255, 0.1);
    transform: translateY(-3px) scale(1.02);
    border-color: rgba(255, 255, 255, 0.3);
}

.message.own:hover {
    box-shadow: 0 8px 16px rgba(7, 193, 96, 0.25), 0 0 20px rgba(7, 193, 96, 0.15);
    transform: translateY(-3px) scale(1.02);
    border-color: rgba(255, 255, 255, 0.2);
}

/* 消息滑入动画 */
@keyframes messageSlideIn {
    0% {
        opacity: 0;
        transform: translateY(20px) scale(0.9) rotateX(10deg);
        filter: blur(3px);
    }
    50% {
        opacity: 0.6;
        transform: translateY(-5px) scale(1.02) rotateX(-2deg);
        filter: blur(1px);
    }
    80% {
        opacity: 0.9;
        transform: translateY(2px) scale(1.0) rotateX(0deg);
        filter: blur(0px);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1) rotateX(0deg);
        filter: blur(0px);
    }
}

/* 消息容器动画增强 */
.message-container {
    animation: messageSlideIn 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

/* 消息头像动画 */
.message-avatar {
    animation: avatarPopIn 0.4s ease-out 0.1s both;
}

@keyframes avatarPopIn {
    0% {
        opacity: 0;
        transform: scale(0.5) translateY(10px);
    }
    100% {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

/* 消息内容动画 */
.message-content {
    animation: contentFadeIn 0.3s ease-out 0.2s both;
}

@keyframes contentFadeIn {
    0% {
        opacity: 0;
        transform: translateX(10px);
    }
    100% {
        opacity: 1;
        transform: translateX(0);
    }
}

/* 消息时间动画 */
.message-time {
    animation: timeFadeIn 0.3s ease-out 0.3s both;
}

@keyframes timeFadeIn {
    0% {
        opacity: 0;
    }
    100% {
        opacity: 0.6;
    }
}

/* 消息昵称样式 */
.message-nickname {
    font-size: 12px;
    font-weight: 500;
    color: #666;
    margin-bottom: 2px;
}

.message.own .message-nickname {
    color: rgba(255, 255, 255, 0.8);
}

/* 图片消息样式 */
.message-image-container {
    position: relative;
    display: inline-block;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    cursor: pointer;
}

.message-image-container:hover {
    transform: translateY(-2px) scale(1.01);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.message-image {
    max-width: 100%;
    max-height: 300px;
    border-radius: 10px;
    display: block;
    transition: transform 0.3s ease;
}

.message-image-container:hover .message-image {
    transform: scale(1.03);
}

/* 图片加载动画 */
.message-image-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transform: translateX(-100%);
    animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
    100% {
        transform: translateX(100%);
    }
}

/* 图片查看提示 */
.message-image-container::after {
    content: '点击查看大图';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 8px;
    background: rgba(0, 0, 0, 0.6);
    color: white;
    font-size: 12px;
    text-align: center;
    opacity: 0;
    transition: opacity 0.3s ease;
    transform: translateY(100%);
}

.message-image-container:hover::after {
    opacity: 1;
    transform: translateY(0);
}

.message.own .message-image-container {
    border-radius: 10px;
}

/* 图片放大查看模式 */
.image-viewer {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.image-viewer.active {
    opacity: 1;
    visibility: visible;
}

.image-viewer img {
    max-width: 90%;
    max-height: 90%;
    border-radius: 8px;
    transform: scale(0.8);
    transition: transform 0.3s ease;
}

.image-viewer.active img {
    transform: scale(1);
}

.image-viewer-close {
    position: absolute;
    top: 20px;
    right: 30px;
    font-size: 32px;
    color: white;
    cursor: pointer;
    opacity: 0.8;
    transition: all 0.3s ease;
}

.image-viewer-close:hover {
    opacity: 1;
    transform: rotate(90deg);
}

/* 文本消息样式 */
.message-text {
    word-wrap: break-word;
    line-height: 1.4;
    color: #333;
    font-size: 14px;
}

.message.own .message-text {
    color: #ffffff;
}

/* 文件消息样式 */
.message-file-container {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 12px;
    background-color: rgba(255, 255, 255, 0.95);
    border-radius: 10px;
    border: 1px solid var(--border-color);
    max-width: 80%;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    position: relative;
    overflow: hidden;
}

.message-file-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.3s ease;
}

.message-file-container:hover::before {
    transform: scaleX(1);
}

.message-file-container:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.message.own .message-file-container {
    background-color: rgba(255, 255, 255, 0.25);
    border-color: rgba(255, 255, 255, 0.4);
}

.message.own .message-file-container::before {
    background: linear-gradient(90deg, rgba(255, 255, 255, 0.6), rgba(255, 255, 255, 0.3));
}

.file-icon {
    font-size: 28px;
    line-height: 1;
    margin-top: 2px;
    opacity: 0.7;
    transition: all 0.3s ease;
}

.message-file-container:hover .file-icon {
    transform: scale(1.1);
    opacity: 1;
}

.file-info {
    flex: 1;
    min-width: 0;
}

.file-name {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-primary);
    word-wrap: break-word;
    margin-bottom: 2px;
    display: -webkit-box;
    display: -moz-box;
    display: box;
    -webkit-line-clamp: 2;
    -moz-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    -moz-box-orient: vertical;
    box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    transition: color 0.3s ease;
}

.message.own .file-name {
    color: rgba(255, 255, 255, 0.95);
}

.file-name:hover {
    color: var(--secondary-color);
}

.file-size {
    font-size: 11px;
    color: var(--text-tertiary);
    margin-bottom: 4px;
}

.message.own .file-size {
    color: rgba(255, 255, 255, 0.7);
}

.file-download-link {
    display: inline-block;
    font-size: 11px;
    color: var(--secondary-color);
    text-decoration: none;
    padding: 4px 8px;
    border-radius: 6px;
    background-color: rgba(24, 144, 255, 0.1);
    transition: all 0.3s ease;
    font-weight: 500;
    border: 1px solid rgba(24, 144, 255, 0.2);
}

.file-download-link:hover {
    background-color: rgba(24, 144, 255, 0.25);
    text-decoration: none;
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(24, 144, 255, 0.2);
    border-color: rgba(24, 144, 255, 0.4);
}

.file-download-link:active {
    transform: translateY(0);
    box-shadow: 0 1px 2px rgba(24, 144, 255, 0.2);
}

/* 上传进度条 */
.upload-progress-bar {
    height: 4px;
    background-color: rgba(0, 0, 0, 0.1);
    border-radius: 2px;
    overflow: hidden;
    margin-top: 4px;
    transition: width 0.3s ease;
}

.message.own .upload-progress-bar {
    background-color: rgba(255, 255, 255, 0.2);
}

.upload-progress-bar::after {
    content: '';
    display: block;
    height: 100%;
    background-color: var(--primary-color);
    border-radius: 2px;
    background-image: linear-gradient(
        -45deg,
        rgba(255, 255, 255, 0.3) 25%,
        transparent 25%,
        transparent 50%,
        rgba(255, 255, 255, 0.3) 50%,
        rgba(255, 255, 255, 0.3) 75%,
        transparent 75%,
        transparent
    );
    background-size: 20px 20px;
    animation: progressAnimation 1s linear infinite;
}

@keyframes progressAnimation {
    0% {
        background-position: 0 0;
    }
    100% {
        background-position: 20px 20px;
    }
}

.upload-progress-text {
    font-size: 11px;
    color: var(--primary-color);
    margin-top: 2px;
    font-weight: 500;
}

.message.own .upload-progress-text {
    color: var(--primary-light);
}

/* 时间戳样式 */
.message-time {
    font-size: 11px;
    color: #999;
    text-align: right;
    margin-top: 2px;
}

.message.own .message-time {
    color: rgba(255, 255, 255, 0.6);
}

/* 消息操作按钮容器 */
.message-actions {
    display: flex;
    gap: 8px;
    margin-top: 4px;
    justify-content: flex-end;
}

/* 撤回消息样式 */
.message-recalled {
    color: #999;
    font-style: italic;
    font-size: 14px;
    padding: 10px 0;
}

/* 撤回按钮样式 */
.recall-btn {
    background-color: transparent;
    border: none;
    color: #666;
    cursor: pointer;
    font-size: 14px;
    padding: 5px 10px;
    border-radius: 5px;
    transition: all 0.3s ease;
}

.recall-btn:hover {
    background-color: rgba(255, 0, 0, 0.1);
    color: #ff4444;
    transform: scale(1.1);
    box-shadow: 0 0 10px rgba(255, 0, 0, 0.3);
}

/* 回复输入容器 */
.reply-input-container {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 8px;
    padding: 10px;
    background-color: rgba(240, 240, 240, 0.8);
    border-radius: 8px;
    border: 1px solid var(--border-color);
    animation: fadeIn 0.3s ease-out;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

.reply-preview {
    font-size: 12px;
    color: var(--text-secondary);
    padding: 6px 10px;
    background-color: rgba(255, 255, 255, 0.9);
    border-radius: 6px;
    border-left: 3px solid var(--primary-color);
}

.reply-input {
    padding: 8px 12px;
    border: 1px solid var(--border-color);
    border-radius: 20px;
    font-size: 14px;
    outline: none;
    transition: all 0.2s ease;
    background-color: #ffffff;
}

.reply-input:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(7, 193, 96, 0.1);
}

.send-reply-btn {
    padding: 6px 16px;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    align-self: flex-start;
}

.send-reply-btn:hover {
    background-color: var(--primary-dark);
    transform: scale(1.05);
    box-shadow: 0 2px 8px rgba(7, 193, 96, 0.3);
}

/* 操作按钮基础样式 */
.action-btn {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: none;
    background-color: rgba(255, 255, 255, 0.8);
    color: #666;
    font-size: 14px;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: all 0.2s ease;
}

.action-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 0 8px rgba(7, 193, 96, 0.4);
    background-color: white;
}

/* 点赞按钮 */
.action-btn.like-btn {
    position: relative;
    overflow: visible;
}

.action-btn.like-btn:hover {
    transform: scale(1.1);
    color: #07c160;
}

/* 点赞按钮激活状态动画 */
.action-btn.liked {
    animation: likePulse 0.6s ease-out;
    color: #07c160;
    filter: drop-shadow(0 0 4px rgba(7, 193, 96, 0.5));
}

/* 收藏按钮激活状态 */
.action-btn.favorited {
    color: #ffc107;
    transform: scale(1.1);
}

@keyframes likePulse {
    0% { transform: scale(1); }
    25% { transform: scale(1.4) rotate(-10deg); }
    50% { transform: scale(1.2) rotate(5deg); }
    75% { transform: scale(1.1) rotate(-3deg); }
    100% { transform: scale(1) rotate(0); }
}

/* 点赞波纹效果 */
@keyframes likeRipple {
    0% {
        width: 0;
        height: 0;
        opacity: 0.6;
    }
    100% {
        width: 40px;
        height: 40px;
        opacity: 0;
    }
}

/* 撤回的消息样式 */
.recalled-message {
    font-style: italic;
    color: #999;
    font-size: 12px;
}

/* 回复消息样式 */
.reply-message {
    font-size: 12px;
    color: #666;
    padding: 4px 8px;
    background-color: rgba(255, 255, 255, 0.8);
    border-radius: 8px;
    margin-bottom: 4px;
    border-left: 3px solid #07c160;
}

.message.own .reply-message {
    background-color: rgba(255, 255, 255, 0.2);
    color: rgba(255, 255, 255, 0.9);
}

/* 聊天输入区域 */
.chat-input-container {
    padding: 12px 20px;
    background-color: #f0f0f0;
    border-top: 1px solid #e5e5e5;
}

.input-wrapper {
    display: flex;
    gap: 8px;
    align-items: center;
    background-color: #ffffff;
    padding: 8px 12px;
    border-radius: 20px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08);
}

/* 功能按钮 */
.input-wrapper button {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    background-color: transparent;
    color: #666;
    font-size: 16px;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.input-wrapper button:hover {
    background-color: rgba(7, 193, 96, 0.1);
    color: var(--primary-color);
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(7, 193, 96, 0.2);
}

.input-wrapper button:active {
    background-color: rgba(7, 193, 96, 0.2);
    transform: scale(0.95);
    box-shadow: 0 2px 6px rgba(7, 193, 96, 0.3);
}

/* 按钮波纹效果 */
.input-wrapper button::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background-color: rgba(7, 193, 96, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.input-wrapper button:active::after {
    width: 200px;
    height: 200px;
}

/* 图片按钮 */
.image-btn {
    order: 1;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    background-color: transparent;
    color: #666;
    font-size: 18px;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.image-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.3) 0%, transparent 70%);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.image-btn:hover {
    background-color: rgba(79, 193, 233, 0.1);
    color: #4fc1e9;
    transform: scale(1.15);
    box-shadow: 0 0 16px rgba(79, 193, 233, 0.3);
}

.image-btn:hover::before {
    width: 100px;
    height: 100px;
}

/* 文件按钮 */
.file-btn {
    order: 1;
    margin-left: 4px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    background-color: transparent;
    color: #666;
    font-size: 18px;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.file-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.3) 0%, transparent 70%);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.file-btn:hover {
    background-color: rgba(147, 112, 219, 0.1);
    color: #9370db;
    transform: scale(1.15);
    box-shadow: 0 0 16px rgba(147, 112, 219, 0.3);
}

.file-btn:hover::before {
    width: 100px;
    height: 100px;
}

/* 消息输入框 */
.message-input {
    flex: 1;
    height: 36px;
    padding: 0 12px;
    border: none;
    border-radius: 18px;
    font-size: 14px;
    outline: none;
    background-color: transparent;
    color: #333;
    resize: none;
    font-family: inherit;
}

.message-input::placeholder {
    color: #999;
}

/* 表情按钮 */
.emoji-btn {
    order: 1;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    background-color: transparent;
    color: #666;
    font-size: 18px;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.emoji-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.3) 0%, transparent 70%);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.emoji-btn:hover {
    background-color: rgba(7, 193, 96, 0.1);
    color: var(--primary-color);
    transform: scale(1.15);
    box-shadow: 0 0 16px rgba(7, 193, 96, 0.3);
}

.emoji-btn:hover::before {
    width: 100px;
    height: 100px;
}

/* 发送按钮 */
.send-btn {
    order: 3;
    width: auto;
    height: 32px;
    padding: 0 16px;
    border-radius: 16px;
    background: linear-gradient(135deg, #07c160 0%, #0cb85a 50%, #06ad56 100%);
    color: white;
    font-size: 14px;
    font-weight: 500;
    margin-left: 8px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    transform: translateY(0) scale(1);
    position: relative;
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(7, 193, 96, 0.15);
}

.send-btn::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.4s ease, height 0.4s ease;
}

.send-btn:active::after {
    width: 200px;
    height: 200px;
}

.send-btn:hover {
    background: linear-gradient(135deg, #08d168 0%, #0dd76c 50%, #07c160 100%);
    transform: translateY(-2px) scale(1.05);
    box-shadow: 0 6px 16px rgba(7, 193, 96, 0.4), 0 0 12px rgba(7, 193, 96, 0.2);
}

.send-btn:active {
    background: linear-gradient(135deg, #059b4b 0%, #06ad56 50%, #07c160 100%);
    transform: translateY(0) scale(1);
    box-shadow: 0 2px 6px rgba(7, 193, 96, 0.2);
}

.send-btn:disabled {
    background-color: #ccc;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* 响应式设计 */
/* 表情选择器 */
.emoji-picker {
    position: absolute;
    bottom: 80px;
    left: 20px;
    width: 360px;
    background-color: white;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    display: none;
    flex-direction: column;
    overflow: hidden;
    z-index: 1000;
    animation: fadeInUp 0.2s ease-out;
}

.emoji-picker.active {
    display: flex;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 表情分类 */
.emoji-categories {
    display: flex;
    padding: 8px;
    border-bottom: 1px solid #e5e5e5;
    background-color: #f7f7f7;
}

.emoji-category-btn {
    width: 40px;
    height: 40px;
    border: none;
    background-color: transparent;
    border-radius: 8px;
    font-size: 16px;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-right: 4px;
    transition: all 0.2s ease;
}

.emoji-category-btn:hover {
    background-color: rgba(7, 193, 96, 0.1);
    transform: scale(1.1);
}

.emoji-category-btn.active {
    background-color: #07c160;
    color: white;
}

/* 表情搜索 */
.emoji-search {
    padding: 12px;
    border-bottom: 1px solid #e5e5e5;
}

.emoji-search-input {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #e5e5e5;
    border-radius: 20px;
    font-size: 14px;
    outline: none;
    transition: all 0.2s ease;
}

.emoji-search-input:focus {
    border-color: #07c160;
    box-shadow: 0 0 0 2px rgba(7, 193, 96, 0.1);
}

/* 表情列表 */
.emoji-container {
    max-height: 240px;
    overflow-y: auto;
}

.emoji-list {
    display: grid;
    grid-template-columns: repeat(9, 1fr);
    gap: 4px;
    padding: 12px;
}

.emoji-item {
    width: 36px;
    height: 36px;
    border: none;
    background-color: transparent;
    border-radius: 6px;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: all 0.15s ease;
}

.emoji-item:hover {
    background-color: rgba(7, 193, 96, 0.1);
    transform: scale(1.2);
}

/* 无最近表情提示 */
.no-recent-emojis {
    text-align: center;
    padding: 40px 20px;
    color: #999;
    font-size: 14px;
    grid-column: 1 / -1;
}

/* 响应式设计 */
@media (max-width: 600px) {
    body {
        padding: 0;
    }
    
    .chat-container {
        height: 100vh;
        border-radius: 0;
    }
    
    .chat-header {
        padding: 12px 16px;
    }
    
    .message {
        max-width: 80%;
        padding: 8px 12px;
    }
    
    .chat-messages {
        padding: 12px;
        gap: 10px;
    }
    
    .chat-input-container {
        padding: 8px 12px;
    }
    
    .input-wrapper {
        padding: 6px 10px;
        gap: 6px;
    }
}

/* 滚动条样式 */
.chat-messages::-webkit-scrollbar {
    width: 6px;
}

.chat-messages::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.chat-messages::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 3px;
}

.chat-messages::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

/* 底部导航栏 */
.bottom-nav {
    display: flex;
    background-color: #ffffff;
    border-top: 1px solid #e5e5e5;
    box-shadow: 0 -1px 3px rgba(0, 0, 0, 0.05);
}

.nav-btn {
    flex: 1;
    padding: 16px;
    border: none;
    background-color: transparent;
    color: #666;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.nav-btn:hover {
    background-color: #f7f7f7;
    color: #333;
}

.nav-btn.active {
    background-color: #f0f0f0;
    color: #07c160;
    border-bottom: 2px solid #07c160;
}

/* 个人中心面板 */
.profile-panel {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #ffffff;
    z-index: 200;
    transform: translateX(100%);
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    box-shadow: -8px 0 20px rgba(0, 0, 0, 0.12);
}

/* 个人中心打开时，聊天区域的滑动效果 */
.profile-panel.open + .chat-main {
    transform: translateX(-30px);
    opacity: 0.3;
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.profile-panel.open {
    transform: translateX(0);
}

.profile-header {
    padding: 16px 20px;
    border-bottom: 1px solid #e5e5e5;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #f7f7f7;
}

.profile-header h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: #333;
}

.profile-content {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
}

/* 好友功能样式 */
.add-friend-container {
    display: flex;
    gap: 10px;
    margin-bottom: 10px;
}

.friend-input {
    flex: 1;
    padding: 8px 12px;
    border: 1px solid #e5e5e5;
    border-radius: 4px;
    font-size: 14px;
    outline: none;
    transition: border-color 0.3s ease;
}

.friend-input:focus {
    border-color: #07c160;
}

.send-request-btn {
    padding: 8px 16px;
    background-color: #07c160;
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 14px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.send-request-btn:hover {
    background-color: #05af56;
}

.send-request-btn:active {
    transform: translateY(1px);
}

/* 好友列表和请求列表样式 */
.friend-item, .request-item {
    display: flex;
    align-items: center;
    padding: 10px;
    border-bottom: 1px solid #f0f0f0;
    transition: background-color 0.2s ease;
}

.friend-item:hover, .request-item:hover {
    background-color: #f7f7f7;
}

.friend-avatar, .request-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    margin-right: 12px;
    object-fit: cover;
}

.friend-info, .request-info {
    flex: 1;
}

.friend-name, .request-name {
    font-weight: 500;
    color: #333;
    margin-bottom: 2px;
}

.request-time {
    font-size: 12px;
    color: #999;
}

.request-actions {
    display: flex;
    gap: 8px;
}

.accept-btn, .decline-btn {
    padding: 4px 12px;
    border: none;
    border-radius: 4px;
    font-size: 12px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.accept-btn {
    background-color: #07c160;
    color: white;
}

.accept-btn:hover {
    background-color: #05af56;
}

.decline-btn {
    background-color: #f5f5f5;
    color: #666;
    border: 1px solid #e5e5e5;
}

.decline-btn:hover {
    background-color: #e5e5e5;
}

.no-friends, .no-requests {
    color: #999;
    text-align: center;
    padding: 20px;
    font-size: 14px;
}

.profile-section {
    margin-bottom: 30px;
}

.profile-section h4 {
    margin: 0 0 15px 0;
    font-size: 16px;
    font-weight: 600;
    color: #333;
    border-bottom: 1px solid #e5e5e5;
    padding-bottom: 8px;
}

.profile-item {
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 15px;
}

.profile-item label {
    width: 80px;
    font-size: 14px;
    color: #666;
    font-weight: 500;
}

.profile-item div {
    flex: 1;
    font-size: 14px;
    color: #333;
}

#friendsList {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.no-friends {
    text-align: center;
    color: #999;
    padding: 20px 0;
    font-style: italic;
}

/* 私信面板样式 */
.private-chat-panel {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #ffffff;
    z-index: 300;
    display: flex;
    flex-direction: column;
    transform: translateX(100%);
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: -8px 0 20px rgba(0, 0, 0, 0.12);
}

.private-chat-panel.open {
    transform: translateX(0);
}

/* 私信头部 */
.private-chat-header {
    padding: 16px 20px;
    border-bottom: 1px solid #e5e5e5;
    display: flex;
    align-items: center;
    gap: 15px;
    background-color: #f7f7f7;
}

.back-btn {
    width: 32px;
    height: 32px;
    border: none;
    background-color: transparent;
    color: #333;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 50%;
    transition: all 0.2s ease;
}

.back-btn:hover {
    background-color: #e5e5e5;
    color: #000;
}

.private-chat-info {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 12px;
}

.private-chat-info .friend-avatar {
    margin: 0;
}

.private-chat-info .friend-name {
    font-weight: 600;
    color: #333;
    font-size: 16px;
}

/* 私信消息区域 */
.private-chat-messages {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
    background-color: #f7f7f7;
    background-image: url("data:image/svg+xml,%3Csvg width='32' height='32' viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23e5e5e5' fill-opacity='0.4'%3E%3Cpath d='M10 0h2v2h-2V0zm12 0h2v2h-2V0zM0 10h2v2H0v-2zm2 12h2v2H2v-2zM10 24h2v2h-2v-2zm12 0h2v2h-2v-2zM24 10h2v2h-2v-2zm0 12h2v2h-2v-2zM10 12h2v2h-2v-2zm12 0h2v2h-2v-2zM2 10h2v2H2v-2z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* 私信输入区域 */
.private-chat-input-container {
    padding: 12px 20px;
    background-color: #f0f0f0;
    border-top: 1px solid #e5e5e5;
}

/* 点击好友项时的样式 */
.friend-item {
    cursor: pointer;
    position: relative;
}

.friend-item::after {
    content: '';
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    width: 6px;
    height: 6px;
    border-top: 2px solid #666;
    border-right: 2px solid #666;
    transform: translateY(-50%) rotate(45deg);
    opacity: 0;
    transition: opacity 0.2s ease;
}

.friend-item:hover::after {
    opacity: 1;
}
