* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "PingFang SC", "Helvetica Neue", Arial, sans-serif;
}

:root {
    --primary-color: #ff3b30;
    --secondary-color: #ff9500;
    --dark-color: #333;
    --light-color: #f5f5f5;
    --gray-color: #666;
    --white: #fff;
    --shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

body {
    background-color: var(--light-color);
    color: var(--dark-color);
    line-height: 1.6;
    padding-bottom: 60px;
}

/* 顶部导航栏 */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 50px;
    background-color: var(--primary-color);
    color: var(--white);
    display: flex;
    align-items: center;
    padding: 0 15px;
    z-index: 1000;
    box-shadow: var(--shadow);
}

.logo {
    display: flex;
    align-items: center;
}

.logo-img {
    width: 30px;
    height: 30px;
    background: white;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 10px;
    color: #ff3b30;
    font-weight: bold;
    font-size: 14px;
}

.logo h1 {
    font-size: 18px;
    font-weight: 600;
}

.nav-right {
    margin-left: auto;
    display: flex;
    align-items: center;
}

.nav-right a {
    color: var(--white);
    text-decoration: none;
    padding: 5px 10px;
    font-size: 14px;
    border-radius: 4px;
    margin-left: 10px;
    transition: all 0.3s;
}

.login-btn {
    background-color: rgba(255, 255, 255, 0.2);
}

.login-btn:hover {
    background-color: rgba(255, 255, 255, 0.3);
}

.register-btn {
    background-color: #4CAF50;
}

.register-btn:hover {
    background-color: #45a049;
}

.user-btn {
    background-color: rgba(255, 255, 255, 0.1);
}

.live-btn {
    background-color: var(--secondary-color);
}

.live-btn:hover {
    background-color: #ff8800;
}

/* 主要内容区 */
.main-content {
    margin-top: 50px;
    padding: 15px;
}

/* 直播分类 */
.categories {
    display: flex;
    overflow-x: auto;
    margin-bottom: 15px;
    padding-bottom: 5px;
    scrollbar-width: none;
}

.categories::-webkit-scrollbar {
    display: none;
}

.category {
    flex: 0 0 auto;
    padding: 8px 15px;
    margin-right: 10px;
    background-color: var(--white);
    border-radius: 20px;
    font-size: 14px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    cursor: pointer;
    transition: all 0.3s;
}

.category.active {
    background-color: var(--primary-color);
    color: var(--white);
}

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

/* 主直播间 */
.main-live {
    margin-bottom: 20px;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transition: all 0.3s;
    cursor: pointer;
}

.main-live:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.15);
}

.live-player {
    width: 100%;
    height: 200px;
    background: linear-gradient(135deg, #1a1a1a, #333);
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--white);
    position: relative;
}

.video-placeholder {
    text-align: center;
}

.video-placeholder i {
    font-size: 40px;
    opacity: 0.8;
    margin-bottom: 10px;
}

.video-placeholder p {
    font-size: 12px;
    opacity: 0.7;
}

.live-info {
    padding: 12px;
    background-color: var(--white);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.live-text h3 {
    font-weight: 600;
    margin-bottom: 5px;
}

.live-text p {
    font-size: 14px;
    color: var(--gray-color);
}

.live-stats {
    display: flex;
    align-items: center;
    color: var(--gray-color);
    font-size: 14px;
}

.live-stats i {
    margin-right: 5px;
    color: var(--primary-color);
}

.live-status {
    position: absolute;
    top: 10px;
    right: 10px;
    background-color: var(--primary-color);
    color: var(--white);
    padding: 3px 8px;
    border-radius: 3px;
    font-size: 12px;
    font-weight: 500;
}

/* 直播间列表 */
.section-title {
    margin: 20px 0 15px;
    font-size: 16px;
}

.live-list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
}

.live-item {
    border-radius: 8px;
    overflow: hidden;
    background-color: var(--white);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: all 0.3s;
    cursor: pointer;
}

.live-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.live-thumb {
    width: 100%;
    height: 120px;
    background: linear-gradient(135deg, #1a1a1a, #333);
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--white);
    position: relative;
}

.live-item-info {
    padding: 10px;
}

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

.live-item-host {
    font-size: 12px;
    color: var(--gray-color);
    display: flex;
    align-items: center;
    margin-bottom: 5px;
}

.avatar-small {
    width: 20px;
    height: 20px;
    background: #ddd;
    border-radius: 50%;
    margin-right: 5px;
}

.live-item-stats {
    font-size: 12px;
    color: var(--gray-color);
    display: flex;
    align-items: center;
}

.live-item-stats i {
    margin-right: 5px;
    color: var(--primary-color);
}

/* 无直播内容样式 */
.no-live-message {
    grid-column: 1 / -1;
    text-align: center;
    padding: 40px 20px;
    background: white;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.no-live-message p {
    margin-bottom: 20px;
    color: #666;
    font-size: 16px;
}

.no-live-message .btn {
    display: inline-block;
    padding: 10px 20px;
    background: var(--primary-color);
    color: white;
    text-decoration: none;
    border-radius: 5px;
    transition: background 0.3s;
}

.no-live-message .btn:hover {
    background: #ff1a1a;
}

/* 在线客服 */
.customer-service {
    position: fixed;
    bottom: 80px;
    right: 15px;
    width: 50px;
    height: 50px;
    background-color: var(--primary-color);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--white);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    z-index: 999;
    cursor: pointer;
    transition: all 0.3s;
}

.customer-service:hover {
    transform: scale(1.1);
    background-color: #ff1a1a;
}

/* 页脚 */
.footer {
    padding: 20px 15px;
    text-align: center;
    background-color: #f0f0f0;
    color: var(--gray-color);
    font-size: 12px;
    margin-top: 30px;
}

.footer a {
    color: var(--gray-color);
    text-decoration: none;
}

.footer a:hover {
    color: var(--primary-color);
}

/* 底部导航 */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 60px;
    background-color: var(--white);
    display: flex;
    justify-content: space-around;
    align-items: center;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
    z-index: 999;
}

.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    color: var(--gray-color);
    font-size: 12px;
    cursor: pointer;
    transition: all 0.3s;
}

.nav-item i {
    font-size: 20px;
    margin-bottom: 3px;
}

.nav-item.active {
    color: var(--primary-color);
}

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

/* 表单样式 */
.form-container {
    max-width: 400px;
    margin: 70px auto 20px;
    padding: 20px;
    background: var(--white);
    border-radius: 10px;
    box-shadow: var(--shadow);
}

.form-title {
    text-align: center;
    margin-bottom: 20px;
    color: var(--primary-color);
}

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

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

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 14px;
}

.form-group textarea {
    height: 100px;
    resize: vertical;
}

.btn {
    display: block;
    width: 100%;
    padding: 12px;
    background: var(--primary-color);
    color: var(--white);
    border: none;
    border-radius: 5px;
    font-size: 16px;
    cursor: pointer;
    transition: background 0.3s;
}

.btn:hover {
    background: #ff1a1a;
}

.form-footer {
    text-align: center;
    margin-top: 15px;
}

.form-footer a {
    color: var(--primary-color);
    text-decoration: none;
}

.form-footer a:hover {
    text-decoration: underline;
}

/* 错误和成功消息样式 */
.error-message {
    background: #ffebee;
    color: #c62828;
    padding: 10px;
    border-radius: 5px;
    margin-bottom: 15px;
    text-align: center;
    border: 1px solid #ffcdd2;
}

.success-message {
    background: #e8f5e8;
    color: #2e7d32;
    padding: 10px;
    border-radius: 5px;
    margin-bottom: 15px;
    text-align: center;
    border: 1px solid #c8e6c9;
}

/* 表单小提示 */
.form-group small {
    display: block;
    margin-top: 5px;
    color: #666;
    font-size: 12px;
}

/* 响应式调整 */
@media (max-width: 360px) {
    .live-list {
        grid-template-columns: 1fr;
    }
    
    .nav-right a {
        font-size: 12px;
        padding: 4px 8px;
        margin-left: 5px;
    }
}

/* 仪表板样式 */
.dashboard {
    margin-top: 70px;
    padding: 15px;
}

.dashboard-section {
    background: var(--white);
    border-radius: 10px;
    padding: 15px;
    margin-bottom: 20px;
    box-shadow: var(--shadow);
}

.dashboard-section h2 {
    margin-bottom: 15px;
    color: var(--primary-color);
}

.room-list {
    display: grid;
    gap: 15px;
}

.room-item {
    padding: 15px;
    border: 1px solid #eee;
    border-radius: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.room-info h3 {
    margin-bottom: 5px;
}

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

.action-btn {
    padding: 5px 10px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
}

.edit-btn {
    background: var(--secondary-color);
    color: white;
}

.delete-btn {
    background: #ff3b30;
    color: white;
}
/* 发现页面样式 */
.discover-page {
    margin-top: 50px;
    padding: 15px;
    background: var(--light-color);
    min-height: calc(100vh - 110px);
}

.discover-header {
    background: white;
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 15px;
    box-shadow: var(--shadow);
}

.discover-header h2 {
    margin-bottom: 15px;
    color: var(--dark-color);
    text-align: center;
}

.search-box {
    display: flex;
    gap: 10px;
}

.search-box input {
    flex: 1;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 25px;
    font-size: 14px;
    outline: none;
}

.search-box input:focus {
    border-color: var(--primary-color);
}

.search-btn {
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 50%;
    width: 45px;
    height: 45px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s;
}

.search-btn:hover {
    background: #ff1a1a;
}

.discover-categories {
    display: flex;
    overflow-x: auto;
    margin-bottom: 20px;
    padding-bottom: 10px;
    scrollbar-width: none;
}

.discover-categories::-webkit-scrollbar {
    display: none;
}

.discover-category {
    flex: 0 0 auto;
    padding: 10px 20px;
    margin-right: 10px;
    background: white;
    border-radius: 20px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.discover-category.active {
    background: var(--primary-color);
    color: white;
}

.discover-category:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

.discover-content {
    background: white;
    border-radius: 10px;
    padding: 20px;
    box-shadow: var(--shadow);
}

.recommend-list h3, .hot-topics h3 {
    margin-bottom: 15px;
    color: var(--dark-color);
    font-size: 18px;
}

.recommend-items {
    display: grid;
    gap: 15px;
    margin-bottom: 25px;
}

.recommend-item {
    display: flex;
    gap: 15px;
    padding: 15px;
    border: 1px solid #eee;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
}

.recommend-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    border-color: var(--primary-color);
}

.recommend-thumb {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #1a1a1a, #333);
    border-radius: 8px;
    flex-shrink: 0;
}

.recommend-info {
    flex: 1;
}

.recommend-info h4 {
    margin-bottom: 8px;
    color: var(--dark-color);
    font-size: 16px;
}

.recommend-info p {
    color: var(--gray-color);
    margin-bottom: 5px;
    font-size: 14px;
}

.viewer-count {
    color: var(--primary-color);
    font-size: 12px;
    font-weight: 500;
}

.topic-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.topic-item {
    background: #f0f0f0;
    padding: 8px 15px;
    border-radius: 15px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s;
}

.topic-item:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-2px);
}
/* 底部导航激活状态 */
.bottom-nav .nav-item.active {
    color: var(--primary-color);
    transform: translateY(-2px);
}

.bottom-nav .nav-item.active i {
    color: var(--primary-color);
}

/* 底部导航悬停效果 */
.bottom-nav .nav-item:hover {
    color: var(--primary-color);
    transform: translateY(-2px);
}

.bottom-nav .nav-item:hover i {
    color: var(--primary-color);
}