/* 全局样式 */
:root {
    --primary-color: #2c3e50;
    --secondary-color: #34495e;
    --accent-color: #3498db;
    --text-color: #ecf0f1;
    --background-color: #1a1a1a;
    --card-background: #2c2c2c;
    --border-color: #444;
    --hover-color: #3498db;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Arial', sans-serif;
    background-color: var(--background-color);
    color: var(--text-color);
    overflow-x: hidden;
    height: 100vh;
    display: flex;
    flex-direction: column;
}

/* 顶部菜单 */
.top-menu {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 60px;
    background-color: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: space-around;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

.top-menu button {
    background: none;
    border: none;
    color: var(--text-color);
    font-size: 12px;
    font-weight: bold;
    cursor: pointer;
    padding: 10px;
    border-radius: 5px;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
}

.menu-icon {
    font-size: 24px;
}

.top-menu button:hover {
    background-color: var(--hover-color);
}

/* 底部菜单 */
.bottom-menu {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: 60px;
    overflow: visible;
    background-color: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: space-around;
    z-index: 1000;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.5);
}

.bottom-menu button {
    background: none;
    border: none;
    color: var(--text-color);
    font-size: 14px;
    font-weight: bold;
    cursor: pointer;
    padding: 10px;
    border-radius: 5px;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
}

.bottom-menu button:hover {
    background-color: var(--hover-color);
}

.bottom-menu button.active {
    color: var(--accent-color) !important;
}

.bottom-menu button.active::after {
    content: '';
    position: absolute;
    bottom: 5px;
    left: 50%;
    transform: translateX(-50%);
    width: 20px;
    height: 3px;
    background-color: var(--accent-color);
    border-radius: 2px;
}

.bottom-menu button.active .menu-icon i {
    color: var(--accent-color) !important;
}

/* 主内容区域 */
.main-content {
    flex: 1;
    margin-top: 0;
    margin-bottom: 60px;
    overflow-y: auto;
    position: relative;
}

/* 首页标签页样式 */
.home-tab-content {
    display: none;
    min-height: calc(100vh - 110px);
    padding: 30px 0 0 0;
}

.home-tab-content.active {
    display: block;
}

.home-tab-page {
    padding: 0;
}

/* 页面容器 */
.page {
    display: none;
    padding: 5px;
    min-height: calc(100vh - 120px);
    overflow-x: hidden;
    position: relative;
}

/* 我的页面无padding */
#my.page {
    padding: 0;
    overflow-x: visible;
    overflow-y: visible;
}

.page.active {
    display: block;
}

#moreContentPage {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 60px;
    overflow-y: auto;
    z-index: 100;
    padding: 0 5px 20px 5px !important;
    background: var(--bg-color);
}

#co-creation {
    padding: 0 !important;
    min-height: calc(100vh - 120px);
    height: 100%;
    overflow: hidden;
    display: none;
    flex-direction: column;
}

#co-creation.active {
    display: flex;
}

/* 广告视图位 */
.ad-section {
    height: calc(20vh + 15px);
    background-color: var(--card-background);
    border-radius: 10px;
    margin-top: -10px;
    margin-bottom: 5px;
    overflow: hidden;
    position: relative;
    cursor: pointer;
}

.ad-carousel {
    width: 100%;
    height: 100%;
    position: relative;
    overflow: hidden;
}

.ad-slides-wrapper {
    display: flex;
    transition: transform 0.5s ease;
    height: 100%;
}

.ad-slide {
    flex: 0 0 100%;
    width: 100%;
    height: 100%;
    position: relative;
    cursor: pointer;
}

.ad-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.ad-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    padding: 5px;
    color: white;
}

.ad-prev, .ad-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0,0,0,0.5);
    border: none;
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 18px;
    cursor: pointer;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.3s ease;
}

.ad-prev:hover, .ad-next:hover {
    background-color: rgba(0,0,0,0.8);
}

.ad-prev {
    left: 10px;
}

.ad-next {
    right: 10px;
}

.ad-indicators {
    position: absolute;
    bottom: 10px;
    right: 15px;
    display: flex;
    gap: 5px;
}

.ad-indicator {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.ad-indicator.active {
    background-color: var(--accent-color);
}

/* 内容区域 */
.content-section {
    margin-bottom: 20px;
    padding: 0 15px;
}

/* 众创页面折叠样式 */
.forum-headers-container {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
}

.forum-section {
    margin-bottom: 0;
    background-color: transparent;
    border-radius: 0;
    overflow: visible;
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.forum-section.collapsed {
    background-color: var(--primary-color);
    flex: 0 0 auto;
    height: auto;
}

.forum-section.collapsed .forum-section-header {
    height: auto;
    padding: 15px 20px;
}

#discussionsSection.collapsed {
    position: relative;
}

.forum-section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    z-index: 10;
    background: rgba(44, 62, 80, 0.6);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.3);
}

#tasksSection .forum-section-header {
    position: sticky;
    top: 48px;
}

#tasksSection.collapsed {
    margin-bottom: 0;
    position: fixed;
    bottom: 60px;
    left: 0;
    right: 0;
    z-index: 100;
    border-radius: 0;
    height: 50px;
    flex: 0 0 auto;
}

#tasksSection.collapsed .forum-section-header {
    height: 100%;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.forum-section-header:hover {
    background-color: var(--secondary-color);
}

.toggle-icon {
    font-size: 12px;
    color: var(--text-color);
    transition: transform 0.3s ease;
}

.forum-section.collapsed .toggle-icon {
    transform: rotate(180deg);
}

.forum-section-content {
    padding: 55px 20px 70px 20px;
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    background-color: var(--card-background);
    width: 100%;
    box-sizing: border-box;
}

.forum-section.collapsed .forum-section-content {
    display: none;
}

.forum-list {
    display: flex;
    flex-direction: column;
    gap: 5px;
    width: 100%;
    box-sizing: border-box;
}

.forum-list .card {
    display: flex;
    flex-direction: row;
    width: 100%;
    max-width: 100%;
    border-radius: 8px;
    overflow: hidden;
    box-sizing: border-box;
}

.forum-list .card-image {
    width: 120px;
    height: 100px;
    flex-shrink: 0;
    object-fit: cover;
}

.forum-list .card-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 2px 10px;
    gap: 1px;
    min-width: 0;
    overflow: hidden;
    line-height: 1.2;
}

.forum-list .card-title {
    font-size: 14px;
    margin-bottom: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.forum-list .card-user-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    color: #999;
}

.forum-list .card-stats {
    display: flex;
    gap: 10px;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.section-title {
    font-size: 18px;
    font-weight: bold;
    color: var(--accent-color);
    margin: 0;
}

.section-more {
    color: #666;
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s ease;
}

.section-more:hover {
    color: #333;
    text-decoration: underline;
}

.section-post-button {
    width: 50px;
    height: 25px;
    border-radius: 5px;
    border: none;
    background-color: #f0f0f0;
    color: #333;
    font-size: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.section-post-button:hover {
    background-color: #e0e0e0;
}

/* 瀑布流布局（发现、同城、商城、众筹页面）*/
.grid-container {
    display: flex;
    gap: 12px;
    padding: 15px 0;
    width: 100%;
    max-width: 700px;
    margin: 0 auto;
    align-items: flex-start;
}

.grid-container > * {
    margin-bottom: 0;
}

/* 瀑布流布局（商城、众筹页面）*/
.grid-container.grid-waterfall {
    display: flex;
    gap: 12px;
    padding: 5px 1px;
    width: 100%;
    max-width: 700px;
    margin: 0 auto;
    box-sizing: border-box;
    align-items: flex-start;
}

.grid-container.grid-waterfall > * {
    margin-bottom: 0;
}

.waterfall-column {
    display: flex;
    flex-direction: column;
    gap: 12px;
    flex: 1;
    min-width: 0;
}

.grid-waterfall .card {
    width: 100%;
    margin-bottom: 0;
    display: block;
}

/* 标准网格布局（推荐页面）*/
.grid-container.grid-normal {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    column-count: unset;
    column-gap: 15px;
    gap: 15px;
    justify-content: center;
    align-content: start;
    align-items: stretch;
}

@media (min-width: 480px) {
    .grid-container.grid-normal {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (min-width: 768px) {
    .grid-container.grid-normal {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (min-width: 1024px) {
    .grid-container.grid-normal {
        grid-template-columns: repeat(5, 1fr);
    }
}

@media (min-width: 1280px) {
    .grid-container.grid-normal {
        grid-template-columns: repeat(6, 1fr);
    }
}

@media (min-width: 1536px) {
    .grid-container.grid-normal {
        grid-template-columns: repeat(7, 1fr);
    }
}

@media (min-width: 1792px) {
    .grid-container.grid-normal {
        grid-template-columns: repeat(8, 1fr);
    }
}

/* PC端用户信息页面卡片正方形显示 */
@media (min-width: 769px) {
    #userVideos img, #userImages img, #userProducts img, 
    #userDiscussions img, #userTasks img, #userCrowdfunds img,
    #favoriteVideos img, #favoriteImages img, #favoriteProducts img,
    #favoriteDiscussions img, #favoriteTasks img, #favoriteCrowdfunds img {
        height: auto !important;
        aspect-ratio: 1 / 1 !important;
    }
}

/* 卡片样式 */
.card {
    background-color: var(--card-background);
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 0;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    cursor: pointer;
    display: block;
    width: 100%;
}

/* 推荐页面卡片样式 */
.grid-normal .card {
    margin-bottom: 0;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.card:hover {
    transform: scale(1.02);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}

.card-image {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
}

/* 推荐页面卡片图片固定高度 */
.grid-normal .card-image {
    height: 120px;
    flex-shrink: 0;
}

/* 推荐页面卡片内容区域自动填充剩余空间 */
.grid-normal .card-content {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.card-content {
    padding: 10px;
}

.card-title {
    font-size: 14px;
    font-weight: bold;
    margin-bottom: 5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* 用户名称一行显示并截断 */
.username-single-line {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: inline-block;
    max-width: 100%;
}

.card-info {
    font-size: 12px;
    color: var(--text-color);
}

.card-info .username-single-line {
    flex: 1;
    min-width: 0;
}

/* 地图容器 */
.map-container {
    height: 70vh;
    background-color: var(--card-background);
    border-radius: 10px;
    overflow: hidden;
    position: relative;
}

.map-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    color: #999;
}

/* 消息列表 */
.message-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.message-item {
    background-color: var(--card-background);
    border-radius: 10px;
    padding: 15px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
    cursor: pointer;
}

.message-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.message-sender {
    font-weight: bold;
}

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

/* 关注/粉丝列表 */
#friends {
    display: none;
    flex-direction: column;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 2000;
    overflow: hidden;
}

#friends .search-bar {
    margin-bottom: 10px;
}

.friends-container {
    display: flex;
    flex: 1;
    overflow: hidden;
    width: 100%;
    gap: 0;
}

.friends-list {
    background-color: rgba(44, 44, 44, 0.5);
    border-radius: 10px 0 0 10px;
    padding: 15px;
    display: flex;
    flex-direction: column;
    flex: 2;
    border-right: 1px solid var(--border-color);
    min-width: 0;
}

.follow-tabs {
    display: flex;
    margin-bottom: 15px;
}

.follow-tab {
    flex: 1;
    text-align: center;
    padding: 10px;
    cursor: pointer;
    border-bottom: 2px solid transparent;
    color: #999;
}

.follow-tab.active {
    border-bottom: 2px solid var(--accent-color);
    color: var(--accent-color);
}

.tab-count {
    background-color: var(--accent-color);
    color: white;
    font-size: 11px;
    padding: 2px 6px;
    border-radius: 10px;
    margin-left: 4px;
}

.follow-content {
    flex: 1;
    overflow-y: auto;
    scrollbar-width: none; /* Firefox */
}

.follow-content::-webkit-scrollbar {
    display: none; /* Chrome, Safari, Edge */
}

.friend-item {
    display: flex;
    align-items: center;
    padding: 10px;
    border-bottom: 1px solid var(--border-color);
    cursor: pointer;
}

.friend-item:hover {
    background-color: var(--primary-color);
}

.friend-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    margin-right: 10px;
    flex-shrink: 0;
}

.friend-info {
    flex: 1;
    min-width: 0;
    margin-right: 10px;
}

.friend-name {
    font-weight: bold;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 14px;
}

.friend-status {
    font-size: 10px;
    color: #999;
    white-space: normal;
    line-height: 1.2;
}

.friend-item button {
    flex-shrink: 0;
    min-width: 60px;
    text-align: center;
    font-size: 10px;
    padding: 3px 10px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

.popular-users {
    background-color: rgba(44, 44, 44, 0.5);
    border-radius: 0 10px 10px 0;
    padding: 15px;
    display: flex;
    flex-direction: column;
    flex: 1;
    min-width: 0;
}

/* 用户名滚动显示 */
.popular-users .friend-name {
    overflow: auto;
    scrollbar-width: none;
}

.popular-users .friend-name::-webkit-scrollbar {
    display: none;
}

.popular-users .friend-status {
    font-size: 12px;
    color: #999;
    white-space: nowrap;
    overflow: auto;
    scrollbar-width: none;
}

.popular-users .friend-status::-webkit-scrollbar {
    display: none;
}

/* 移动端响应式布局 */
@media (max-width: 768px) {
    #friends {
        padding: 0;
    }

    /* 用户信息页面内容卡片一行3列 */
    #userVideos, #userImages, #userProducts, #userDiscussions, #userTasks, #userCrowdfunds,
    #favoriteVideos, #favoriteImages, #favoriteProducts, #favoriteDiscussions, #favoriteTasks, #favoriteCrowdfunds {
        grid-template-columns: repeat(3, 1fr) !important;
    }

    .friends-container {
        flex-direction: row;
        width: 100%;
        gap: 0;
        margin: 0;
        padding: 0;
    }

    .friends-list {
        flex: 2;
        border-radius: 10px 0 0 10px;
        border-right: 1px solid var(--border-color);
        padding: 10px;
        margin: 0;
    }

    .popular-users {
        flex: 1;
        border-radius: 0 10px 10px 0;
        padding: 10px;
        margin: 0;
    }

    /* 热度最高用户列表标题缩小 */
    .popular-users h3 {
        font-size: 14px;
        margin-bottom: 10px;
    }

    /* 热度最高用户列表卡片样式调整 */
    .popular-users .friend-item {
        padding: 8px 5px;
    }

    .popular-users .friend-avatar {
        width: 30px;
        height: 30px;
        margin-right: 8px;
    }

    .popular-users .friend-name {
        font-size: 12px;
        font-weight: normal;
    }

    .popular-users .friend-status {
        font-size: 10px;
    }

    .popular-users .friend-item button {
        min-width: 45px;
        font-size: 10px;
        padding: 2px 6px;
    }

    /* 关注/粉丝列表样式 */
    .friend-item button {
        min-width: 50px;
        font-size: 9px;
        padding: 2px 8px;
    }

    .friend-avatar {
        width: 42px;
        height: 42px;
    }
}

/* 关注页面搜索框样式 */
.friends-search-bar {
    display: flex;
    margin-bottom: 0;
    background-color: rgba(60, 60, 60, 0.7);
    border-radius: 25px;
    padding: 5px 15px;
    flex: 1;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.friends-search-input {
    flex: 1;
    background: none;
    border: none;
    color: var(--text-color);
    font-size: 14px;
    padding: 5px;
}

.friends-search-input::placeholder {
    color: #999;
}

.friends-search-btn {
    background: none;
    border: none;
    color: var(--text-color);
    margin-left: 5px;
}

.friends-close-btn {
    background: none;
    border: none;
    color: var(--text-color);
    margin-left: 15px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 18px;
}

.friends-close-btn:hover {
    background-color: rgba(0, 0, 0, 0.1);
}

.friends-search-btn:hover {
    color: var(--accent-color);
}

/* 搜索结果提示弹窗样式 */
.search-tip-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 2000;
    align-items: center;
    justify-content: center;
}

.search-tip-modal.active {
    display: flex;
}

.search-tip-content {
    background-color: var(--card-background);
    border-radius: 10px;
    padding: 5px 30px;
    color: var(--text-color);
    font-size: 14px;
}

/* 热门用户样式 */
.popular-users h3 {
    margin-bottom: 15px;
}

.popular-users-list {
    flex: 1;
    overflow-y: auto;
    scrollbar-width: none; /* Firefox */
}

.popular-users-list::-webkit-scrollbar {
    display: none; /* Chrome, Safari, Edge */
}

/* 管理员关注页面样式 */
.admin-friends-page {
    width: 100%;
    padding: 0;
}

.admin-full-width {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    padding: 10px 0;
    max-height: 70vh;
    overflow-y: auto;
}

.admin-full-width::-webkit-scrollbar {
    width: 6px;
}

.admin-full-width::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 3px;
}

.admin-full-width::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 3px;
}

.admin-full-width::-webkit-scrollbar-thumb:hover {
    background: #555;
}

.admin-user-card {
    background-color: var(--card-background);
    border-radius: 12px;
    padding: 15px;
    width: calc(25% - 9px);
    box-sizing: border-box;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
}

.admin-user-name {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
}

/* 移动端适配 */
@media (max-width: 768px) {
    .admin-user-card {
        width: calc(33.333% - 8px);
        padding: 10px;
    }

    .admin-user-avatar {
        width: 30px;
        height: 30px;
    }

    .admin-user-name {
        font-size: 12px;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .admin-user-name:hover {
        overflow-x: auto;
        cursor: ew-resize;
    }

    .admin-user-role {
        font-size: 10px;
    }
}

/* 平板适配 */
@media (min-width: 769px) and (max-width: 1024px) {
    .admin-user-card {
        width: calc(33.333% - 8px);
    }

    .admin-user-name {
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .admin-user-name:hover {
        overflow-x: auto;
        cursor: ew-resize;
    }
}

/* PC端适配 */
@media (min-width: 1025px) {
    .admin-user-card {
        width: calc(25% - 9px);
    }

    .admin-user-name {
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .admin-user-name:hover {
        overflow-x: auto;
        cursor: ew-resize;
    }
}

/* 自定义滚动条样式 */
.admin-user-name::-webkit-scrollbar {
    height: 4px;
}

.admin-user-name::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 2px;
}

.admin-user-name::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 2px;
}

.admin-user-name::-webkit-scrollbar-thumb:hover {
    background: #555;
}

.admin-user-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.admin-user-card-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}

.admin-user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
}

.admin-user-name {
    font-size: 14px;
    font-weight: bold;
    color: var(--text-color);
}

.admin-user-role {
    font-size: 12px;
    color: #999;
    margin-top: 2px;
}

/* 搜索条 */
.search-bar {
    background-color: var(--card-background);
    border-radius: 25px;
    padding: 10px 15px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
}

.search-input {
    background: none;
    border: none;
    color: var(--text-color);
    flex: 1;
    margin-left: 10px;
}

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

/* 搜索弹窗 */
.search-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.6);
    display: none;
    align-items: flex-start;
    justify-content: center;
    z-index: 2000;
    padding-top: 50px;
}

.search-modal.active {
    display: flex;
}

.search-modal-content {
    width: 100%;
    max-width: 600px;
    background: linear-gradient(135deg, rgba(30, 30, 30, 0.95), rgba(20, 20, 20, 0.5));
    border-radius: 0 0 16px 16px;
    padding: 12px 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-top: none;
}

.search-modal-header {
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 24px;
    padding: 4px 8px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    transition: all 0.3s ease;
}

.search-modal-header:focus-within {
    border-color: var(--accent-color);
    box-shadow: 0 0 0 2px rgba(var(--accent-color-rgb), 0.2);
}

.search-modal-input {
    flex: 1;
    padding: 12px 16px;
    background-color: transparent;
    border: none;
    color: var(--text-color);
    font-size: 15px;
    outline: none;
}

.search-modal-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.search-modal-btn {
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.6);
    padding: 10px 16px;
    cursor: pointer;
    font-size: 16px;
    transition: all 0.3s ease;
}

.search-modal-btn:hover {
    color: var(--accent-color);
}

.search-results {
    margin-top: 16px;
}

.search-result-item {
    padding: 15px;
    border-bottom: 1px solid var(--border-color);
    cursor: pointer;
}

.search-result-item:hover {
    background-color: var(--primary-color);
}

/* 搜索结果页面分类标签按钮 */
.search-tab-btn {
    padding: 8px 16px;
    border: 1px solid var(--border-color);
    border-radius: 20px;
    background-color: var(--card-background);
    color: var(--text-color);
    cursor: pointer;
    font-size: 14px;
    transition: all 0.3s ease;
}

.search-tab-btn:hover {
    background-color: var(--primary-color);
}

.search-tab-btn.active {
    background-color: var(--accent-color);
    color: white;
    border-color: var(--accent-color);
}

/* 消息页面样式 */
.message-tabs {
    display: flex;
    border-bottom: 1px solid #333;
    margin-bottom: 20px;
    position: sticky !important;
    top: 0 !important;
    z-index: 1000 !important;
}

/* 清空按钮栏粘性定位 */
#clearButtonBar {
    position: sticky !important;
    top: 48px !important;
    z-index: 999 !important;
}

.message-tab {
    flex: 1;
    text-align: center;
    padding: 10px 5px;
    cursor: pointer;
    color: #999;
    transition: all 0.3s ease;
    position: relative;
}
.message-tab.active {
    color: var(--accent-color) !important;
    background-color: rgba(255,255,255,0.05);
}
.message-tab.active > span {
    color: var(--accent-color) !important;
}
.message-tab.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 5px;
    right: 5px;
    height: 2px;
    background-color: var(--accent-color);
}

.message-badge {
    position: absolute;
    top: -8px;
    right: -14px;
    background-color: #FF4444;
    color: white;
    font-size: 10px;
    font-weight: bold;
    min-width: 16px;
    height: 16px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 4px;
    box-shadow: 0 1px 2px rgba(0,0,0,0.2);
    z-index: 5;
}

.menu-badge {
    position: absolute;
    bottom: 5px;
    right: -8px;
    background-color: #FF4444;
    color: white;
    font-size: 10px;
    font-weight: bold;
    min-width: 16px;
    height: 16px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2px 4px;
    box-shadow: 0 1px 2px rgba(0,0,0,0.2);
    z-index: 5;
    line-height: 1;
}

.msg-unread-badge {
    position: absolute;
    top: -8px;
    right: -8px;
    background-color: #FF4444;
    color: #fff;
    font-size: 10px;
    font-weight: bold;
    min-width: 20px;
    height: 20px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 5px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.4);
    z-index: 10;
    border: 1px solid rgba(255,255,255,0.3);
    line-height: 1;
    pointer-events: none;
}

.message-content {
    color: var(--text-color);
    line-height: 1.5;
}

/* 分享消息卡片样式 */
.share-card {
    background-color: #2c2c2c;
    border-radius: 8px;
    padding: 10px;
    margin-top: 10px;
    cursor: pointer;
}

.share-card-content {
    display: flex;
    gap: 15px;
}

.share-card-image {
    flex-shrink: 0;
    width: 80px;
    height: 80px;
    border-radius: 6px;
    overflow: hidden;
}

.share-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

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

.share-card-title {
    font-weight: bold;
    font-size: 14px;
    margin-bottom: 5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.share-card-description {
    font-size: 12px;
    color: #999;
    margin-bottom: 8px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.share-card-meta {
    font-size: 11px;
    color: #666;
}

/* 个人信息页面 */
.profile-section {
    background-color: transparent;
    padding: 0;
    margin: 0;
    position: relative;
    width: 100%;
}

.profile-background {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-size: cover;
    background-position: center;
    z-index: 0;
    pointer-events: none;
    transform-origin: center center;
    transform: translate(0, 0);
}

.profile-background::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to top, rgba(26, 26, 26, 0.95) 0%, rgba(26, 26, 26, 0.6) 40%, rgba(26, 26, 26, 0.2) 70%, transparent 100%);
    pointer-events: none;
}

.profile-header {
    display: flex;
    align-items: center;
    position: relative;
    z-index: 1;
    padding: 5px 20px 0 20px;
}

.profile-avatar {
    width: 90px;
    height: 90px;
    border-radius: 50%;
    margin-right: 15px;
    margin-top: -40px;
}

.profile-details {
    font-size: 12px;
    margin-top: 8px;
}

.profile-info {
    flex: 1;
    max-width: calc(100% - 120px);
}

.profile-name {
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 5px;
    display: block;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
}

.profile-bio {
    font-size: 14px;
    color: #999;
    margin-bottom: 10px;
    line-height: 1.4;
    min-height: 2.8em;
    max-height: 2.8em;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    text-overflow: ellipsis;
    cursor: pointer;
    pointer-events: auto;
}

.profile-detail-item {
    display: flex;
    align-items: center;
    margin-bottom: 3px;
    font-size: 13px;
}

.profile-detail-label {
    width: 80px;
    color: #999;
}

.profile-detail-value {
    color: var(--text-color);
}

.profile-stats {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 15px;
    padding-left: 20px;
    border-left: 1px solid #eee;
    margin-left: auto;
    flex-shrink: 0;
}

.stat-item {
    color: var(--accent-color);
    cursor: pointer;
    white-space: nowrap;
}

.stat-item:hover {
    text-decoration: underline;
}

.stat-divider {
    color: #ccc;
}

.settings-list {
    background-color: transparent;
    border-radius: 0;
    padding: 15px 20px;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    position: relative;
    z-index: 5;
    cursor: grab;
}

.settings-list:active {
    cursor: grabbing;
}

.settings-list::-webkit-scrollbar {
    display: none;
}

.settings-rows-container {
    display: flex;
    flex-direction: column;
    gap: 15px;
    width: max-content;
}

.settings-row {
    display: flex;
    gap: 15px;
}

.settings-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 15px 10px;
    border-radius: 8px;
    background-color: rgba(255, 255, 255, 0.15);
    cursor: pointer;
    transition: all 0.3s ease;
    min-height: 80px;
    min-width: 100px;
    flex-shrink: 0;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    pointer-events: auto;
}

.settings-item i {
    font-size: 24px;
    margin-bottom: 6px;
}

.settings-item span {
    font-size: 14px;
}

.settings-item:hover {
    background-color: var(--primary-color);
}

/* 抽奖页面 */
.lottery-page {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--background-color);
    z-index: 2000;
    display: none;
    flex-direction: column;
}

.lottery-page.active {
    display: flex;
}

.lottery-header {
    height: 60px;
    background-color: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

.lottery-header h2 {
    color: var(--text-color);
}

.lottery-header button {
    background: none;
    border: none;
    color: var(--text-color);
    font-size: 18px;
    cursor: pointer;
}

.lottery-content {
    flex: 1;
    padding: 5px;
    overflow-y: auto;
}

.lottery-products {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 15px;
}

.lottery-product {
    background-color: var(--card-background);
    border-radius: 10px;
    overflow: hidden;
    text-align: center;
    padding: 15px;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.lottery-product:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5);
}

.lottery-product img {
    width: 100px;
    height: 100px;
    object-fit: cover;
    border-radius: 10px;
    margin-bottom: 10px;
}

/* 登录/注册弹窗 */
.auth-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.8);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 3000;
}

.auth-modal.active {
    display: flex;
}

.auth-modal-content {
    width: 90%;
    max-width: 400px;
    background-color: var(--card-background);
    border-radius: 10px;
    padding: 30px;
}

.auth-tabs {
    display: flex;
    margin-bottom: 20px;
}

.auth-tab {
    flex: 1;
    text-align: center;
    padding: 10px;
    cursor: pointer;
    border-bottom: 2px solid var(--border-color);
}

.auth-tab.active {
    border-bottom: 2px solid var(--accent-color);
    color: var(--accent-color);
}

.auth-form {
    display: none;
}

.auth-form.active {
    display: block;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-size: 14px;
}

.form-group input {
    width: 100%;
    padding: 10px;
    background-color: var(--primary-color);
    border: 1px solid var(--border-color);
    border-radius: 5px;
    color: var(--text-color);
}

.form-group input::placeholder {
    color: #999;
}

.auth-button {
    width: 100%;
    padding: 12px;
    background-color: var(--accent-color);
    border: none;
    border-radius: 5px;
    color: white;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    margin-top: 10px;
}

.auth-button:hover {
    background-color: #2980b9;
}

.oauth-button {
    flex: 1;
    padding: 10px;
    border: none;
    border-radius: 5px;
    color: white;
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    transition: opacity 0.3s ease;
}

.oauth-button:hover {
    opacity: 0.9;
}

.wechat-btn {
    background-color: #07C160;
}

.douyin-btn {
    background-color: #000;
}

/* 内容详情页面 */
.detail-page {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--background-color);
    z-index: 100000;
    display: none;
    flex-direction: column;
}

.detail-page.active {
    display: flex;
}

.detail-header {
    height: 60px;
    background-color: rgba(44, 62, 80, 0.5);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 5100;
}

.detail-header h2 {
    color: var(--text-color);
    font-size: 18px;
}

.detail-header button {
    background: none;
    border: none;
    color: var(--text-color);
    font-size: 28px;
    cursor: pointer;
    padding: 5px 10px;
    border-radius: 50%;
    transition: background-color 0.3s ease;
}

.detail-header button:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

/* 详情页通用样式 - 隐藏标题栏，显示返回按钮 */
.detail-page.detail-mode .detail-header {
    display: none;
}

.detail-page.detail-mode .detail-content {
    padding: 0 0 100px 0;
}

.product-back-button {
    position: fixed;
    top: 20px;
    left: 20px;
    z-index: 5200;
    width: 40px;
    height: 30px;
    border-radius: 6px;
    background-color: rgba(44, 62, 80, 0.3);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-color);
    font-size: 16px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    opacity: 0.7;
}

.product-back-button:hover {
    background-color: rgba(44, 62, 80, 0.6);
    opacity: 1;
    transform: scale(1.05);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.detail-content {
    flex: 1;
    padding: 80px 20px 100px 20px;
    overflow-y: auto;
    min-height: 0;
}

.video-player {
    width: 100%;
    min-height: 300px;
    background-color: var(--card-background);
    border-radius: 10px;
    margin-bottom: 20px;
    display: block;
    padding: 10px;
}

.video-player video {
    width: 100%;
    max-height: 400px;
    border-radius: 5px;
}

.video-detail-content {
    margin-top: 0;
    padding: 0;
    background-color: transparent;
    border-radius: 0;
    width: 100%;
    height: 100%;
}

.douyin-detail-container {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #000;
    z-index: 5000;
    touch-action: pan-y;
    will-change: transform, opacity;
}

.douyin-video-container {
    touch-action: pan-y;
    will-change: transform, opacity;
}

.swipe-hint {
    position: absolute;
    bottom: 120px;
    left: 50%;
    transform: translateX(-50%);
    color: rgba(255, 255, 255, 0.6);
    font-size: 12px;
    z-index: 100;
    animation: swipeHintPulse 2s ease-in-out infinite;
    pointer-events: none;
}

@keyframes swipeHintPulse {
    0%, 100% { opacity: 0.4; transform: translateX(-50%) translateY(0); }
    50% { opacity: 0.8; transform: translateX(-50%) translateY(-5px); }
}

.douyin-action-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    cursor: pointer;
    transition: transform 0.2s ease;
}

/* 视频描述容器样式 */
.video-description-container {
    transition: all 0.3s ease;
}

.video-description-container.collapsed {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    max-height: 44.8px;
}

.video-description-container.expanded {
    display: block;
    max-height: 500px;
    overflow-y: auto;
}

/* 图文描述容器样式 */
.image-description-container {
    transition: all 0.3s ease;
}

.image-description-container.collapsed {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.image-description-container.expanded {
    display: block;
    max-height: 500px;
    overflow-y: auto;
}

.douyin-action-btn:hover {
    transform: scale(1.1);
}

.product-detail {
    background-color: var(--card-background);
    border-radius: 10px;
    padding: 5px;
    margin-bottom: 20px;
}

.product-images {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    overflow-x: auto;
}

.product-images img {
    width: 100px;
    height: 100px;
    object-fit: cover;
    border-radius: 5px;
}

.product-info h3 {
    margin-bottom: 10px;
    color: var(--accent-color);
}

.product-price {
    font-size: 20px;
    font-weight: bold;
    color: #e74c3c;
    margin-bottom: 15px;
}

.product-description {
    line-height: 1.6;
    margin-bottom: 20px;
}

.product-actions {
    display: flex;
    gap: 10px;
}

.action-button {
    flex: 1;
    padding: 12px;
    border: none;
    border-radius: 5px;
    font-weight: bold;
    cursor: pointer;
}

.buy-button {
    background-color: var(--accent-color);
    color: white;
}

.add-button {
    background-color: var(--primary-color);
    color: var(--text-color);
}

.forum-post {
    background-color: var(--card-background);
    border-radius: 10px;
    padding: 5px;
}

.post-header {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
}

.post-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    margin-right: 10px;
}

.post-info {
    flex: 1;
}

.post-author {
    font-weight: bold;
    margin-bottom: 2px;
}

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

.post-content {
    line-height: 1.6;
    margin-bottom: 15px;
}

.post-image {
    width: 100%;
    border-radius: 10px;
    margin-bottom: 15px;
}

.post-actions {
    display: flex;
    gap: 20px;
    padding-top: 0;
    border-top: none;
}

.post-action {
    display: flex;
    align-items: center;
    gap: 5px;
    cursor: pointer;
    font-size: 12px;
}

.post-action span:first-child {
    font-size: 14px;
}

.comments-section {
    margin-top: 20px;
}

.comment {
    background-color: var(--primary-color);
    border-radius: 10px;
    padding: 15px;
    margin-bottom: 10px;
}

.comment-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
}

.comment-author {
    font-weight: bold;
    color: var(--accent-color);
}

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

.comment-content {
    line-height: 1.4;
}

        /* 颜色选择器面板自适应样式 */
.comment-color-picker {
    max-height: 100px;
}

.comment-color-picker .comment-color-grid {
    display: flex !important;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
}

.comment-color-picker .comment-color-grid > div {
    flex-shrink: 0;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .comment-icons-container {
        gap: 1px !important;
    }

    .comment-color-picker {
        max-height: 60px !important;
        padding: 8px 15px !important;
    }

    .comment-color-picker .comment-color-grid {
        display: flex !important;
        flex-wrap: nowrap !important;
        overflow-x: auto !important;
        gap: 8px !important;
        justify-content: flex-start !important;
        scrollbar-width: none;
        -ms-overflow-style: none;
    }

    .comment-color-picker .comment-color-grid::-webkit-scrollbar {
        display: none;
    }

    .comment-color-picker .comment-color-grid > div {
        flex-shrink: 0 !important;
        width: 28px !important;
        height: 28px !important;
    }

    .forum-comment-input {
        position: relative;
    }
    .forum-comment-input[data-empty="true"]::before {
        content: attr(data-placeholder);
        color: rgba(255,255,255,0.4);
        pointer-events: none;
    }

    .grid-container {
        padding: 10px 0;
        max-width: 100%;
    }

    .grid-container.grid-normal {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
        gap: 10px;
    }

    .card {
        margin-bottom: 8px;
        border-radius: 10px;
    }

    .grid-normal .card {
        margin-bottom: 0;
    }

    .friends-container {
        grid-template-columns: 1fr;
        grid-template-rows: 1fr 1fr;
    }

    .top-menu button {
        font-size: 14px;
    }

    .bottom-menu {
        height: 48px;
    }

    .bottom-menu button {
        font-size: 11px;
        padding: 8px;
    }

    .main-content {
        margin-bottom: 48px;
    }

    /* 任务区块折叠时底部适配 */
    #tasksSection.collapsed {
        bottom: 48px !important;
    }

    #moreContentPage {
        bottom: 48px;
    }

    .settings-list {
        gap: 10px;
        padding: 10px;
    }

    .settings-row {
        gap: 10px;
    }

    .settings-item {
        padding: 12px 8px;
        min-height: 70px;
        min-width: 90px;
    }

    .settings-item i {
        font-size: 20px;
        margin-bottom: 4px;
    }

    .settings-item span {
        font-size: 12px;
    }

    .profile-detail-item {
        font-size: 11px;
    }

    .profile-detail-label {
        width: 65px;
    }

    .profile-stats {
        gap: 3px;
        padding-left: 5px;
        font-size: 10px;
    }
}

/* 子页面：PC端恢复底部60px（移动端内联样式已改为48px） */
@media (min-width: 769px) {
    #favorites, #mylikes, #mycomments, #history, #helpCenter,
    #myMerchandise, #myOrders, #myPosts, #myTasks, #aboutUs, #friends {
        bottom: 60px !important;
        height: calc(100vh - 60px) !important;
    }
}

@media (min-width: 769px) and (max-width: 1023px) {
    .grid-container {
        padding: 5px 0;
        max-width: 100%;
        width: 100%;
    }

    .grid-container.grid-waterfall {
        max-width: 100%;
        width: 100%;
    }

    .page {
        max-width: 100%;
        width: 100%;
        padding: 0 15px;
    }
}

@media (min-width: 1024px) and (max-width: 1439px) {
    .grid-container {
        padding: 5px 0;
        max-width: 100%;
        width: 100%;
    }

    .grid-container.grid-normal {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 20px;
        max-width: 100%;
        width: 100%;
    }

    .grid-container.grid-waterfall {
        max-width: 100%;
        width: 100%;
    }

    .card {
        border-radius: 12px;
    }

    .grid-normal .card {
        margin-bottom: 0;
    }

    .page {
        max-width: 100%;
        width: 100%;
        padding: 0 20px;
    }
}

@media (min-width: 1440px) {
    .grid-container {
        padding: 5px 0;
        max-width: 100%;
        width: 100%;
    }

    .grid-container.grid-normal {
        grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
        gap: 25px;
        max-width: 100%;
        width: 100%;
    }

    .grid-container.grid-waterfall {
        max-width: 100%;
        width: 100%;
    }

    .card {
        border-radius: 12px;
    }

    .grid-normal .card {
        margin-bottom: 0;
    }

    .page {
        max-width: 100%;
        width: 100%;
        padding: 0 30px;
    }

    /* 地图容器样式 */
    .map-container {
        width: 100%;
        height: 500px;
        margin-bottom: 20px;
        border-radius: 8px;
        overflow: hidden;
        background-color: #f0f0f0;
        position: relative;
        background-image: url('https://trae-api-cn.mchost.guru/api/ide/v1/text_to_image?prompt=map%20background%20gray%20style&image_size=landscape_16_9');
        background-size: cover;
        background-position: center;
    }

    .map-placeholder {
        width: 100%;
        height: 100%;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 16px;
        color: #666;
        position: relative;
        z-index: 1;
    }

    /* 地图标点样式 */
    .map-markers {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        z-index: 2;
    }

    .map-marker {
        position: absolute;
        transform: translate(-50%, -50%);
        cursor: pointer;
        transition: all 0.3s ease;
    }

    .map-marker:hover {
        transform: translate(-50%, -50%) scale(1.2);
    }

    .marker-icon {
        font-size: 24px;
        text-align: center;
        line-height: 30px;
    }

    .marker-label {
        position: absolute;
        bottom: -25px;
        left: 50%;
        transform: translateX(-50%);
        background-color: rgba(0, 0, 0, 0.7);
        color: white;
        padding: 2px 8px;
        border-radius: 10px;
        font-size: 12px;
        white-space: nowrap;
    }

    /* 标点信息弹窗样式 */
    .marker-info {
        position: absolute;
        top: 20px;
        right: 20px;
        background-color: white;
        border-radius: 8px;
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
        padding: 15px;
        width: 200px;
        z-index: 10;
        display: none;
    }

    .marker-info.active {
        display: block;
    }

    .marker-info-content h3 {
        margin: 0 0 10px 0;
        font-size: 16px;
    }

    .marker-info-content p {
        margin: 0 0 15px 0;
        font-size: 14px;
        color: #666;
    }

    .marker-action {
        width: 100%;
        padding: 8px;
        background-color: #4CAF50;
        color: white;
        border: none;
        border-radius: 4px;
        cursor: pointer;
        font-size: 14px;
    }

    .marker-action:hover {
        background-color: #45a049;
    }

    /* 地图控制栏样式 */
    .map-controls {
        background-color: white;
        border-radius: 8px;
        padding: 15px;
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    }

    .map-controls h3 {
        margin: 0 0 15px 0;
        font-size: 16px;
        color: #333;
    }

    .control-buttons {
        display: flex;
        gap: 10px;
        flex-wrap: wrap;
    }

    .control-button {
        padding: 8px 16px;
        border: 1px solid #ddd;
        border-radius: 20px;
        background-color: white;
        cursor: pointer;
        font-size: 14px;
        transition: all 0.3s ease;
    }

    .control-button:hover {
        background-color: #f0f0f0;
    }

    .control-button.active {
        background-color: #4CAF50;
        color: white;
        border-color: #4CAF50;
    }

    /* 个人信息设置弹窗样式 */
    .profile-modal {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background-color: rgba(0, 0, 0, 0.5);
        display: flex;
        align-items: center;
        justify-content: center;
        z-index: 1000;
    }

    .profile-modal-content {
        background-color: white;
        border-radius: 8px;
        width: 90%;
        max-width: 500px;
        max-height: 80%;
        overflow-y: auto;
        box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    }

    .profile-modal-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        margin-bottom: 20px;
        padding-bottom: 10px;
        border-bottom: 1px solid #e0e0e0;
        background-color: white;
    }

    .profile-modal-header h2 {
        margin: 0;
        font-size: 20px;
        color: #333;
    }

    .profile-modal-header button {
        background: none;
        border: none;
        font-size: 30px;
        cursor: pointer;
        color: #333;
    }

    .profile-modal-body {
        padding: 5px;
    }

    .profile-modal-footer {
        display: flex;
        justify-content: flex-end;
        gap: 10px;
        padding: 15px 20px;
        border-top: 1px solid #e0e0e0;
        background-color: #f9f9f9;
        border-radius: 0 0 8px 8px;
    }

    .profile-modal-footer button {
        padding: 8px 16px;
        border: 1px solid #ddd;
        border-radius: 4px;
        background-color: white;
        cursor: pointer;
        font-size: 14px;
    }

    .profile-modal-footer .save-button {
        background-color: #4CAF50;
        color: white;
        border-color: #4CAF50;
    }

    .profile-modal-footer .save-button:hover {
        background-color: #45a049;
    }

    .form-group {
        margin-bottom: 15px;
    }

    .form-group label {
        display: block;
        margin-bottom: 5px;
        font-size: 14px;
        color: #333;
    }

    .form-group input,
    .form-group textarea {
        width: 100%;
        padding: 8px;
        border: 1px solid #ddd;
        border-radius: 4px;
        font-size: 14px;
        box-sizing: border-box;
    }

    .form-group textarea {
        resize: vertical;
    }

    /* 用户信息弹窗样式 */
    .friend-modal {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        width: 100vw;
        height: 100vh;
        background-color: rgba(0, 0, 0, 0.8);
        display: flex;
        align-items: center;
        justify-content: center;
        z-index: 1002;
        overflow: auto;
        box-sizing: border-box;
    }

    .friend-modal-content {
        background-color: white;
        color: #333;
        border-radius: 8px;
        width: 90%;
        max-width: 90vw;
        max-width: min(90vw, 500px);
        max-height: 80vh;
        overflow-y: auto;
        box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
        margin: 20px;
        padding: 5px;
        position: relative;
        box-sizing: border-box;
        flex-shrink: 0;
    }

    .friend-modal-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        margin-bottom: 20px;
        padding-bottom: 10px;
        border-bottom: 1px solid #e0e0e0;
        background-color: white;
    }

    .friend-modal-header h2 {
        margin: 0;
        font-size: 20px;
        color: #333;
    }

    .friend-modal-header button {
        background: none;
        border: none;
        font-size: 40px;
        cursor: pointer;
        color: #333;
        position: absolute;
        top: 10px;
        right: 20px;
        line-height: 1;
    }

    .friend-modal-body {
        color: #333;
        display: flex;
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .friend-avatar-large {
        margin-bottom: 20px;
        display: flex;
        justify-content: center;
        align-items: center;
        max-width: 100%;
        width: 10vw;
        max-width: 80px;
        height: 10vw;
        max-height: 80px;
        margin-left: auto;
        margin-right: auto;
    }

    .friend-avatar-large img {
        width: 50%;
        height: 50%;
        border-radius: 50%;
        object-fit: cover;
    }


    .friend-avatar-large img {
        width: 60%;
        max-width: 100px;
        height: auto;
        border-radius: 50%;
        object-fit: cover;
        max-height: 100%;
    }

    .friend-info-details {
        width: 100%;
    }

    .info-item {
        margin-bottom: 10px;
        display: flex;
        flex-wrap: wrap;
        width: 100%;
    }

    .info-value {
        word-break: break-word;
        flex: 1;
    }

    .info-label {
        font-weight: bold;
        margin-right: 10px;
        width: 80px;
        color: #333;
    }

    .info-value {
        color: #666;
        flex: 1;
    }

    .friend-modal-footer {
        display: flex;
        justify-content: flex-end;
        gap: 10px;
        padding: 15px 20px;
        border-top: 1px solid #e0e0e0;
        background-color: #f9f9f9;
        border-radius: 0 0 8px 8px;
    }

    .friend-modal-footer button {
        padding: 12px 24px;
        border: none;
        border-radius: 8px;
        background-color: #f5f5f5;
        cursor: pointer;
        font-size: 16px;
        font-weight: bold;
        transition: all 0.3s ease;
    }

    .friend-modal-footer button:hover {
        transform: translateY(-2px);
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    }

    .friend-modal-footer .remove-button {
        background-color: #ff4d4f;
        color: white;
        border: none;
    }

    .friend-modal-footer .remove-button:hover {
        background-color: #ff7875;
    }

    .friend-modal-footer .add-button {
        background-color: #1890ff;
        color: white;
        border: none;
    }

    .friend-modal-footer .add-button:hover {
        background-color: #40a9ff;
    }

    /* 用户名称点击样式 */
    .friend-name {
        cursor: pointer;
        color: #ffffff;
        transition: color 0.3s ease;
        font-weight: 500;
    }

    .friend-name:hover {
        color: #4CAF50;
        text-decoration: underline;
    }

    /* 发布按钮样式 */
    .floating-post-button {
        position: fixed !important;
        bottom: 60px !important;
        left: 50% !important;
        transform: translateX(-50%) !important;
        width: 50px !important;
        height: 30px !important;
        background-color: #444 !important;
        color: white !important;
        border: none !important;
        border-radius: 5px !important;
        cursor: pointer !important;
        font-size: 24px !important;
        font-weight: bold !important;
        align-items: center !important;
        justify-content: center !important;
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2) !important;
        transition: all 0.3s ease !important;
        z-index: 1001 !important;
    }

    /* 移动端适配 */
    @media (max-width: 768px) {
        .floating-post-button {
            bottom: 48px !important;
            width: 40px !important;
            height: 25px !important;
            font-size: 20px !important;
            z-index: 1001 !important;
        }
    }

    @media (max-width: 480px) {
        .floating-post-button {
            bottom: 48px !important;
            width: 40px !important;
            height: 40px !important;
            font-size: 18px !important;
            z-index: 1001 !important;
        }

        .forum-list .card {
            max-height: 90px;
        }

        .forum-list .card-image {
            width: 90px;
            height: 90px;
        }

        .forum-list .card-content {
            padding: 6px 8px;
            gap: 3px;
        }

        .forum-list .card-title {
            font-size: 12px;
        }
    }

    .floating-post-button:hover {
        background-color: #555;
        transform: translateX(-50%) scale(1.1);
    }

    .floating-post-button.hidden {
        display: none !important;
    }

    /* 内容类型切换按钮样式 */
    .content-type-toggle {
        display: flex;
        gap: 10px;
        margin-bottom: 15px;
    }

    .type-btn {
        flex: 1;
        padding: 10px 20px;
        border: 1px solid #ddd;
        border-radius: 4px;
        background-color: white;
        cursor: pointer;
        font-size: 14px;
        transition: all 0.3s ease;
    }

    .type-btn:hover {
        background-color: #f0f0f0;
    }

    .type-btn.active {
        background-color: #4CAF50;
        color: white;
        border-color: #4CAF50;
    }
}

/* 评论弹窗样式 */
.comments-modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    z-index: 12000;
    justify-content: center;
    align-items: flex-end;
}

.comments-modal-overlay.active {
    display: flex;
}

.comments-modal-content {
    width: 100%;
    height: 75vh;
    background-color: #222222;
    border-radius: 20px 20px 0 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    animation: slideUp 0.3s ease-out;
}

@keyframes slideUp {
    from {
        transform: translateY(100%);
    }
    to {
        transform: translateY(0);
    }
}

@keyframes toastIn {
    from { opacity: 0; transform: translateX(-50%) translateY(20px); }
    to { opacity: 1; transform: translateX(-50%) translateY(0); }
}

.share-action-btn {
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
}

#shareActionsScroll, #shareUsersScroll {
    -webkit-overflow-scrolling: touch;
}

.comments-modal-header {
    flex-shrink: 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 20px;
    background-color: #333333;
    border-bottom: 2px solid rgba(255,255,255,0.2);
}

.comments-modal-header h3 {
    font-size: 16px;
    font-weight: bold;
    color: #fff;
    margin: 0;
}

.comments-modal-close {
    background: none;
    border: none;
    color: #fff;
    font-size: 24px;
    cursor: pointer;
    padding: 5px 10px;
}

.comments-modal-close:hover {
    color: #ccc;
}

.comments-modal-body {
    flex: 1;
    overflow-y: auto;
    padding: 15px;
    padding-bottom: 80px;
}

/* 数量选择弹窗移动端响应式 */
@media (max-width: 480px) {
    #quantityModal > div {
        padding: 12px !important;
    }
    #quantityModal img {
        width: 60px !important;
        height: 60px !important;
    }
    #quantityModal button[onclick="changeQuantity(-1)"],
    #quantityModal button[onclick="changeQuantity(1)"] {
        width: 24px !important;
        height: 24px !important;
        font-size: 14px !important;
    }
    #quantityModal button[onclick="closeQuantityModal()"],
    #quantityModal button[onclick="confirmQuantity()"] {
        padding: 5px 12px !important;
        font-size: 12px !important;
    }
}

.tab-button.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 5px;
    right: 5px;
    height: 2px;
    background-color: var(--accent-color);
}
.home-tabs {
    background-color: rgba(0, 0, 0, 0.1) !important;
}

/* 全屏视频容器背景修复 */
.video-player video,
.douyin-video-container video {
    background-color: #000 !important;
}

/* CSS全屏模式 - 确保视频容器最上层 */
.douyin-video-container.video-css-fullscreen {
    z-index: 99999 !important;
}

/* 横屏视频全屏旋转 */
.douyin-video-container.video-landscape-fullscreen {
    transform: rotate(90deg) !important;
    -webkit-transform: rotate(90deg) !important;
    transform-origin: center center !important;
    -webkit-transform-origin: center center !important;
    width: 100vh !important;
    height: 100vw !important;
    top: 50% !important;
    left: 50% !important;
    margin-left: -50vh !important;
    margin-top: -50vw !important;
}

/* GPU加速滚动 - 提高GeckoView和系统WebView滑动流畅度 */
.home-tab-content,
.main-content {
    -webkit-transform: translateZ(0);
    transform: translateZ(0);
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    -webkit-overflow-scrolling: touch;
}

/* 全屏恢复布局辅助 */
.video-fullscreen-parent {
    overflow: hidden !important;
}

.swipe-container {
    width: 100%;
    overflow: hidden;
    position: relative;
    -webkit-overflow-scrolling: touch;
    height: calc(100vh - 50px);
}

.swipe-wrapper {
    display: flex;
    transform: translateX(0);
    transition: transform 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    will-change: transform;
    align-items: flex-start;
    height: 100%;
}

.home-tab-page {
    flex-shrink: 0;
    width: 100vw;
    box-sizing: border-box;
    display: block;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    height: 100%;
    padding-top: 50px;
}
.page-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 50px;
    background-color: transparent;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 999;
    padding: 0 20px;
    backdrop-filter: blur(5px);
}
.page-header-title {
    color: var(--text-color);
    font-size: 18px;
    font-weight: bold;
}
.innovation-tab-button.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 5px;
    right: 5px;
    height: 2px;
    background-color: var(--accent-color);
}
.innovation-swipe-container {
    width: 100%;
    overflow: hidden;
    position: relative;
    -webkit-overflow-scrolling: touch;
    height: calc(100vh - 50px);
}
.innovation-swipe-wrapper {
    display: flex;
    transform: translateX(0);
    transition: transform 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    will-change: transform;
    align-items: flex-start;
    height: 100%;
}
.innovation-tab-page {
    flex-shrink: 0;
    width: 100vw;
    box-sizing: border-box;
    display: block;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    height: 100%;
    padding-top: 50px;
}
/* 简约风格树形菜单样式 */
.co-creation-tree-menu-btn {
    transition: background 0.2s;
}
.co-creation-tree-menu-btn:hover {
    background: rgba(255, 255, 255, 0.03) !important;
}
.co-creation-tree-dropdown {
    position: fixed;
    background: rgba(11, 13, 14, 0.5);
    border-radius: 10px;
    min-width: 150px;
    max-width: 180px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.1);
    overflow: hidden;
    z-index: 10000;
    backdrop-filter: blur(10px);
}
.co-creation-tree-item {
    display: flex;
    align-items: center;
    padding: 10px 12px;
    cursor: pointer;
    transition: background 0.2s;
    font-size: 13px;
    color: #fff;
}
.co-creation-tree-item:hover {
    background: rgba(255, 255, 255, 0.1);
}
.co-creation-tree-item.parent {
    font-weight: 600;
}
.co-creation-tree-item.child {
    padding-left: 28px;
    color: rgba(255, 255, 255, 0.8);
}
.co-creation-tree-item.child-child {
    padding-left: 44px;
    color: rgba(255, 255, 255, 0.6);
}
.co-creation-tree-item.selected {
    background: rgba(43, 55, 63, 0.3) !important;
}

/* 隐藏滚动条但保持滚动功能 */
.message-content-scroll::-webkit-scrollbar {
    display: none;
}
.message-content-scroll {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.profile-dropdown-btn {
    cursor: pointer;
    padding: 4px 8px;
    color: #999;
    font-size: 12px;
    background: transparent;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    user-select: none;
    border-radius: 4px;
}
.profile-dropdown-btn:hover {
    background: rgba(0,0,0,0.05);
    color: var(--accent-color);
}
#userProfilePage #categoryDropdown-posts,
#userProfilePage #categoryDropdown-favorites,
#userProfilePage .profile-dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    background: #2c2c2c !important;
    background-color: #2c2c2c !important;
    background-image: none !important;
    border: 1px solid #444 !important;
    border-radius: 8px;
    z-index: 100;
    min-width: 120px;
    box-shadow: 0 4px 16px rgba(0,0,0,0.3);
    overflow: hidden;
    margin-top: 4px;
}
#userProfilePage #sortDropdown {
    display: none;
    position: absolute;
    top: 100%;
    background: #2c2c2c !important;
    background-color: #2c2c2c !important;
    background-image: none !important;
    border: 1px solid #444 !important;
    border-radius: 8px;
    z-index: 100;
    min-width: 80px;
    width: 80px;
    box-shadow: 0 4px 16px rgba(0,0,0,0.3);
    overflow: hidden;
    margin-top: 4px;
}
#userProfilePage #categoryDropdown-posts.show,
#userProfilePage #categoryDropdown-favorites.show,
#userProfilePage #sortDropdown.show,
#userProfilePage .profile-dropdown-menu.show {
    display: block !important;
}
#userProfilePage .profile-dropdown-menu div {
    padding: 9px 14px;
    cursor: pointer;
    color: #ecf0f1;
    font-size: 13px;
    transition: background 0.15s;
    border-bottom: 1px solid #444;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
#userProfilePage .profile-dropdown-menu div .cat-count {
    font-size: 11px;
    color: #999;
    font-weight: normal;
}
#userProfilePage .profile-dropdown-menu div:last-child {
    border-bottom: none;
}
#userProfilePage .profile-dropdown-menu div:hover {
    background: #3a3a3a !important;
    color: var(--accent-color);
}
#userProfilePage .profile-dropdown-menu div:hover .cat-count {
    color: var(--accent-color);
}
#userProfilePage .profile-dropdown-menu div.active {
    background: #4a4a4a !important;
    color: var(--accent-color);
    font-weight: bold;
}
#userProfilePage .profile-dropdown-menu div.active .cat-count {
    color: var(--accent-color);
}

.carousel-scroll::-webkit-scrollbar {
    display: none;
}
#carouselInner:active {
    cursor: grabbing;
}

/* 商品详情页样式 - 全宽显示，溢出裁切 */
#productDetail {
    width: 100% !important;
    margin: 0 auto !important;
    overflow-x: hidden !important;
    box-sizing: border-box !important;
}

#productDetail .product-detail-content {
    width: 100% !important;
    overflow-x: hidden !important;
    box-sizing: border-box !important;
}

/* 确保商品详情页高度自适应 */
.detail-section {
    max-width: 100% !important;
    box-sizing: border-box !important;
}

/* 店铺推荐横向滚动容器 - 隐藏滚动条 */
[id^="storeRecommendContent-"] {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

/* PC端店铺推荐 - 单行横向滚动 */
@media screen and (min-width: 768px) {
    [id^="storeRecommendContent-"] {
        flex-wrap: nowrap !important;
        overflow-x: auto !important;
    }
    .store-card-item {
        flex: 0 0 220px !important;
    }
}

/* 移动端店铺推荐 - 一行三个，保持横向滚动 */
@media screen and (max-width: 767px) {
    [id^="storeRecommendContent-"] {
        overflow-x: auto !important;
        flex-wrap: nowrap !important;
        -webkit-overflow-scrolling: touch;
    }
    .store-card-item {
        flex: 0 0 calc(33.33% - 7px) !important;
        min-width: 0 !important;
    }
    .store-card-item img {
        height: 70px !important;
    }
    .store-card-item > div:first-child {
        height: 70px !important;
    }
    .store-card-item > div > div:first-child {
        font-size: 11px !important;
    }
    .store-card-item > div > div:last-child > span:first-child {
        font-size: 12px !important;
    }
}
[id^="storeRecommendContent-"]::-webkit-scrollbar {
    display: none;
}

/* PC端全屏适配 - 所有内容详情页最大宽度1200px，两侧填充不透明背景 */
@media screen and (min-width: 768px) {
    #detailPage.detail-mode {
        background: var(--background-color);
    }
    
    .detail-content {
        width: 100% !important;
        max-width: 1200px !important;
        margin-left: auto !important;
        margin-right: auto !important;
        background: var(--background-color);
    }
    
    #productDetail,
    #videoDetail,
    #forumDetail {
        max-width: 1200px !important;
        margin-left: auto !important;
        margin-right: auto !important;
        background: var(--background-color);
    }
    
    #productDetail .product-detail-content,
    #videoDetail .video-detail-content,
    #forumDetail .forum-detail-content {
        max-width: 1200px !important;
        margin-left: auto !important;
        margin-right: auto !important;
        background: var(--background-color);
    }
}

/* ========== 系统消息滚动区 ========== */
.sys-msg-section {
    display: none;
    margin: 0 12px 10px 0;
    background: linear-gradient(135deg, #1e1e1e 0%, #222 50%, #1e1e1e 100%);
    border: 1px solid rgba(120, 140, 180, 0.15);
    border-radius: 14px;
    overflow: hidden;
    position: relative;
}
.sys-msg-section::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(120, 140, 180, 0.2), transparent);
    z-index: 1;
    pointer-events: none;
}
.sys-msg-scroll {
    position: relative;
    max-height: 72px;
    height: 72px;
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    transition: height .3s ease;
}
.sys-msg-scroll::-webkit-scrollbar { display: none; }
.sys-msg-list {
    /* no transition needed for native scroll */
}
.sys-msg-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 3px 14px;
    height: 24px;
    line-height: 1;
    cursor: pointer;
    border-bottom: 1px solid rgba(120, 140, 180, 0.06);
    transition: background .2s;
    overflow: hidden;
    flex-shrink: 0;
}
.sys-msg-item:last-child { border-bottom: none; }
.sys-msg-item:hover { background: rgba(120, 140, 180, 0.06); }
.sys-msg-item .msg-text {
    flex: 1;
    font-size: 13px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: flex;
    align-items: center;
    gap: 0;
    min-width: 0;
}
.sys-msg-item .msg-title {
    background: linear-gradient(90deg, #d0d0d8, #a8a8b8);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    flex-shrink: 0;
    max-width: 40%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.sys-msg-item .msg-sep {
    color: #444;
    margin: 0 6px;
    flex-shrink: 0;
    font-size: 11px;
}
.sys-msg-item .msg-preview {
    font-size: 12px;
    color: #777;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    min-width: 0;
}
.sys-msg-item .msg-dot {
    width: 6px; height: 6px;
    border-radius: 50%;
    background: #4a8bc2;
    margin-right: 8px;
    flex-shrink: 0;
    box-shadow: 0 0 6px rgba(74, 139, 194, 0.4);
}
.sys-msg-item .msg-arrow {
    color: rgba(120, 140, 180, 0.35);
    font-size: 12px;
    margin-left: 8px;
    flex-shrink: 0;
}
.sys-msg-item .msg-time {
    font-size: 10px;
    color: #555;
    margin-left: 6px;
    flex-shrink: 0;
    white-space: nowrap;
}
.sys-msg-empty {
    padding: 16px;
    text-align: center;
    color: #555;
    font-size: 13px;
}

/* 系统消息详情弹窗 */
.sys-msg-overlay {
    display: none;
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,.7);
    z-index: 3000;
    justify-content: center;
    align-items: center;
    padding: 20px;
}
.sys-msg-overlay.show { display: flex; }
.sys-msg-detail {
    background: var(--card-background, #2c2c2c);
    border: 1px solid var(--border-color, #444);
    border-radius: 16px;
    max-width: 520px;
    width: 100%;
    max-height: 70vh;
    overflow-y: auto;
    box-shadow: 0 8px 40px rgba(0,0,0,.5);
}
.sys-msg-detail-header {
    padding: 20px 24px 12px;
    border-bottom: 1px solid var(--border-color, #333);
}
.sys-msg-detail-header h3 {
    font-size: 17px;
    color: #fff;
    margin: 0 0 4px;
}
.sys-msg-detail-time {
    font-size: 12px;
    color: #777;
}
.sys-msg-detail-body {
    padding: 20px 24px;
    font-size: 14px;
    color: #ccc;
    line-height: 1.8;
    white-space: pre-wrap;
    word-break: break-word;
}
.sys-msg-detail-close {
    display: block;
    width: 100%;
    padding: 12px;
    background: none;
    border: none;
    border-top: 1px solid var(--border-color, #333);
    color: var(--accent-color, #3498db);
    font-size: 14px;
    cursor: pointer;
    transition: background .2s;
}
.sys-msg-detail-close:hover { background: rgba(255,255,255,.05); }

/* 积分系统样式 */
.points-tab {
    padding: 8px 20px;
    border: 1px solid #444;
    background: #2c2c2c;
    color: #888;
    cursor: pointer;
    border-radius: 4px;
    font-size: 14px;
    transition: all 0.2s;
}
.points-tab.active {
    background: #e74c3c;
    color: #fff;
    border-color: #e74c3c;
}

/* 移动端商城、众筹页面排序标签文字加大 */
@media (max-width: 768px) {
    .mall-sort-tab,
    .crowdfunding-sort-tab {
        font-size: 18px !important;
    }
    .mall-sort-tab .sort-icon,
    .crowdfunding-sort-tab .sort-icon {
        font-size: 16px !important;
    }
}
/* 众筹页面PC端卡片宽度（参考商城页面响应式布局） */
@media (min-width: 1024px) {
    #crowdfunding .grid-container.grid-waterfall {
        grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    }
}
/* AI内容生成屏蔽 - 全局禁用AI生成按钮 */
body.ai-content-assist-disabled .ai-generate-btn {
    display: none !important;
}
