* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background-color: #000;
    color: #fff;
}

.community-container {
    display: grid;
    grid-template-columns: 200px 1fr 300px;
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* 侧边栏样式 */
.sidebar {
    background-color: #1a1a1a;
    border-radius: 10px;
    padding: 10px;
    position: sticky;
    top: 20px;
    height: fit-content;
}

.menu-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 15px;
    margin: 5px 0;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s;
}

.menu-item:hover {
    background-color: #333;
}

.menu-item.active {
    background-color: #333;
}

.count {
    background-color: #333;
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 12px;
}

/* 主内容区样式 */
.post-card {
    background-color: #1a1a1a;
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 20px;
}

.post-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: #333;
}

.username {
    font-weight: bold;
}

.post-time {
    color: #666;
    font-size: 12px;
}

.post-content {
    margin-bottom: 15px;
    line-height: 1.5;
    white-space: pre-wrap;
}

.post-image {
    width: 100%;
    border-radius: 10px;
    margin-top: 10px;
    cursor: pointer;
}

.post-actions {
    display: flex;
    gap: 20px;
    margin-top: 15px;
}

.action-btn {
    background: none;
    border: none;
    color: #666;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 5px;
    transition: color 0.3s;
}

.action-btn:hover {
    color: #fff;
}

.action-btn.liked {
    color: #1da1f2;
}

.action-btn.disliked {
    color: #e0245e;
}

/* 评论区样式 */
.comments-section {
    margin-top: 15px;
    border-top: 1px solid #333;
    padding-top: 15px;
}

.comment-input {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
}

.comment-input input {
    flex: 1;
    padding: 8px 12px;
    border: 1px solid #333;
    border-radius: 20px;
    background: #222;
    color: #fff;
}

.comment-input button {
    padding: 8px 15px;
    border: none;
    border-radius: 20px;
    background: #1da1f2;
    color: white;
    cursor: pointer;
}

.comment {
    display: flex;
    gap: 10px;
    margin-bottom: 10px;
    padding: 10px;
    background: #222;
    border-radius: 8px;
}

.comment-content {
    flex: 1;
}

.comment-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 4px;
}

.comment-username {
    font-weight: bold;
    color: #1da1f2;
}

.comment-time {
    color: #666;
    font-size: 12px;
}

/* 右侧用户信息样式 */
.guest-card {
    background-color: #1a1a1a;
    border-radius: 10px;
    padding: 20px;
    text-align: center;
}

.guest-avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background-color: #333;
    margin: 0 auto 15px;
}

.login-btn {
    background-color: #1da1f2;
    color: white;
    border: none;
    padding: 8px 20px;
    border-radius: 20px;
    margin: 15px 0;
    cursor: pointer;
    width: 100%;
}

.login-tip {
    color: #666;
    font-size: 12px;
}

/* 响应式设计 */
@media (max-width: 1200px) {
    .community-container {
        grid-template-columns: 200px 1fr;
    }
    .user-sidebar {
        display: none;
    }
}

@media (max-width: 768px) {
    .community-container {
        grid-template-columns: 1fr;
    }
    .sidebar {
        display: none;
    }
}



