/* 全局样式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: "Microsoft YaHei", "Hiragino Sans GB", "WenQuanYi Micro Hei", sans-serif;
    color: #333;
    background-color: #f5f5f5;
    line-height: 1.6;
    min-width: 1200px;
}

a {
    text-decoration: none;
    color: #333;
    transition: color 0.3s ease;
}

a:hover {
    color: #ff6b81;
}

ul, ol {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
    vertical-align: middle;
}

.section {
    padding: 30px 0;
    margin-bottom: 20px;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px 15px;
    border-bottom: 1px solid #eee;
    margin-bottom: 20px;
}

.section-header h1, .section-header h2 {
    font-size: 22px;
    color: #333;
    position: relative;
    padding-left: 15px;
}

.section-header h1::before, .section-header h2::before {
    content: "";
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 20px;
    background: linear-gradient(to bottom, #ff6b81, #ff8e9e);
    border-radius: 2px;
}

.more-link {
    color: #999;
    font-size: 14px;
}

.more-link:hover {
    color: #ff6b81;
}

/* 头部样式 */
header {
    background-color: #fff;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px 50px;
    max-width: 1400px;
    margin: 0 auto;
}

.logo a {
    display: flex;
    align-items: center;
    font-size: 24px;
    font-weight: bold;
    color: #ff6b81;
}

.star-icon {
    display: inline-block;
    width: 30px;
    height: 30px;
    margin-right: 10px;
    background: linear-gradient(135deg, #ff6b81, #ff8e9e);
    border-radius: 50%;
    position: relative;
}

.star-icon::before {
    content: "★";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #fff;
    font-size: 18px;
}

.search-box {
    flex: 1;
    max-width: 500px;
    margin: 0 30px;
}

.search-box form {
    display: flex;
    height: 40px;
}

.search-box input {
    flex: 1;
    height: 100%;
    padding: 0 15px;
    border: 2px solid #ff6b81;
    border-radius: 20px 0 0 20px;
    outline: none;
    font-size: 14px;
}

.search-box button {
    width: 60px;
    height: 100%;
    background: #ff6b81;
    border: none;
    border-radius: 0 20px 20px 0;
    cursor: pointer;
    color: #fff;
    font-size: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.search-icon::before {
    content: "🔍";
}

.user-actions {
    display: flex;
    align-items: center;
}

.btn {
    display: inline-block;
    padding: 8px 15px;
    border-radius: 4px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.login-btn {
    background-color: #f5f5f5;
    color: #666;
    margin-right: 10px;
}

.register-btn {
    background-color: #ff6b81;
    color: #fff;
}

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

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

.main-nav {
    background-color: #333;
}

.main-nav ul {
    display: flex;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 50px;
}

.main-nav li {
    position: relative;
}

.main-nav li a {
    display: block;
    padding: 12px 25px;
    color: #fff;
    font-size: 16px;
    transition: all 0.3s ease;
}

.main-nav li a:hover {
    background-color: #ff6b81;
    color: #fff;
}

/* 轮播图样式 */
.banner {
    margin: 20px auto;
    max-width: 1200px;
}

.banner-wrapper {
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    height: 400px;
}

.banner-slide {
    position: absolute;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.5s ease;
    display: none;
}

.banner-slide.active {
    opacity: 1;
    display: block;
}

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

.banner-info {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 20px;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    color: #fff;
}

.banner-info h2 {
    font-size: 24px;
    margin-bottom: 10px;
}

.banner-info p {
    font-size: 16px;
    margin-bottom: 15px;
    opacity: 0.8;
}

.watch-btn {
    display: inline-block;
    padding: 8px 20px;
    background-color: #ff6b81;
    color: #fff;
    border-radius: 4px;
    font-size: 14px;
}

.watch-btn:hover {
    background-color: #ff8e9e;
    color: #fff;
}

.banner-controls {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
}

.prev-btn, .next-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 40px;
    background-color: rgba(0,0,0,0.5);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    cursor: pointer;
    opacity: 0.7;
    transition: opacity 0.3s ease;
}

.prev-btn {
    left: 20px;
}

.next-btn {
    right: 20px;
}

.prev-btn:hover, .next-btn:hover {
    opacity: 1;
}

.banner-dots {
    position: absolute;
    bottom: 20px;
    right: 20px;
    display: flex;
}

.dot {
    width: 10px;
    height: 10px;
    background-color: rgba(255,255,255,0.5);
    border-radius: 50%;
    margin: 0 5px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.dot.active {
    background-color: #fff;
    transform: scale(1.2);
}

/* 主要内容区域样式 */
main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

/* 卡片样式 */
.card-container {
    display: flex;
    flex-wrap: wrap;
    margin: 0 -10px;
    padding: 0 20px;
}

.card {
    width: calc(16.666% - 20px);
    margin: 10px;
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    background-color: #fff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.card-img {
    position: relative;
    padding-top: 140%;
    overflow: hidden;
}

.card-img img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.card:hover .card-img img {
    transform: scale(1.05);
}

.score, .update {
    position: absolute;
    top: 10px;
    right: 10px;
    padding: 2px 8px;
    background-color: rgba(255, 107, 129, 0.8);
    color: #fff;
    font-size: 12px;
    border-radius: 3px;
}

.card-info {
    padding: 10px;
}

.card-info h3 {
    font-size: 16px;
    margin-bottom: 5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.card-info p {
    font-size: 12px;
    color: #999;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* 分类标签样式 */
.category-tabs {
    display: flex;
    padding: 0 20px;
    margin-bottom: 20px;
    border-bottom: 1px solid #eee;
}

.tab {
    padding: 8px 20px;
    margin-right: 10px;
    cursor: pointer;
    font-size: 16px;
    border-bottom: 2px solid transparent;
    transition: all 0.3s ease;
}

.tab.active {
    color: #ff6b81;
    border-bottom-color: #ff6b81;
}

.category-content {
    display: none;
}

.category-content.active {
    display: block;
}

/* 排行榜样式 */
.ranking-container {
    padding: 0 20px;
}

.ranking-item {
    display: flex;
    align-items: center;
    padding: 15px 0;
    border-bottom: 1px solid #eee;
}

.ranking-item:last-child {
    border-bottom: none;
}

.rank-num {
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #f5f5f5;
    color: #999;
    font-weight: bold;
    border-radius: 50%;
    margin-right: 15px;
}

.ranking-item:nth-child(1) .rank-num {
    background-color: #ff6b81;
    color: #fff;
}

.ranking-item:nth-child(2) .rank-num {
    background-color: #ffb347;
    color: #fff;
}

.ranking-item:nth-child(3) .rank-num {
    background-color: #6bd4ff;
    color: #fff;
}

.ranking-item img {
    width: 100px;
    height: 140px;
    object-fit: cover;
    border-radius: 4px;
    margin-right: 15px;
}

.rank-info {
    flex: 1;
}

.rank-info h3 {
    font-size: 18px;
    margin-bottom: 8px;
}

.rank-info p {
    font-size: 14px;
    color: #999;
    margin-bottom: 8px;
}

.hot {
    font-size: 14px;
    color: #ff6b81;
}

/* APP下载模块样式 */
.app-download {
    background: linear-gradient(135deg, #3a1c71, #d76d77, #ffaf7b);
    padding: 30px;
    border-radius: 8px;
    color: #fff;
}

.app-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.app-info {
    flex: 1;
}

.app-info h2 {
    font-size: 28px;
    margin-bottom: 15px;
}

.app-desc {
    font-size: 16px;
    margin-bottom: 20px;
    opacity: 0.9;
}

.app-features {
    margin-bottom: 25px;
}

.app-features li {
    margin-bottom: 10px;
    display: flex;
    align-items: center;
}

.feature-icon {
    display: inline-block;
    width: 20px;
    height: 20px;
    margin-right: 10px;
    background-color: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    position: relative;
}

.feature-icon::before {
    content: "✓";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #fff;
    font-size: 12px;
}

.download-btns {
    display: flex;
}

.download-btn {
    display: flex;
    align-items: center;
    padding: 10px 20px;
    background-color: rgba(255, 255, 255, 0.2);
    border-radius: 4px;
    margin-right: 15px;
    transition: background-color 0.3s ease;
}

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

.android-icon, .ios-icon {
    display: inline-block;
    width: 20px;
    height: 20px;
    margin-right: 8px;
    position: relative;
}

.android-icon::before {
    content: "🤖";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.ios-icon::before {
    content: "🍎";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.app-qrcode {
    text-align: center;
}

.app-qrcode img {
    width: 150px;
    height: 150px;
    background-color: #fff;
    padding: 10px;
    border-radius: 8px;
    margin-bottom: 10px;
}

.app-qrcode p {
    font-size: 14px;
}

/* 文章样式 */
.article-container {
    padding: 0 20px;
}

.article-item {
    display: flex;
    padding: 20px 0;
    border-bottom: 1px solid #eee;
}

.article-item:last-child {
    border-bottom: none;
}

.article-img {
    width: 200px;
    height: 120px;
    margin-right: 20px;
    overflow: hidden;
    border-radius: 4px;
}

.article-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.article-item:hover .article-img img {
    transform: scale(1.05);
}

.article-content {
    flex: 1;
}

.article-content h3 {
    font-size: 18px;
    margin-bottom: 10px;
}

.article-content p {
    font-size: 14px;
    color: #666;
    margin-bottom: 15px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

.article-meta {
    display: flex;
    align-items: center;
    font-size: 12px;
    color: #999;
}

.date {
    margin-right: 15px;
}

/* 页脚样式 */
footer {
    background-color: #333;
    color: #ccc;
    padding: 50px 0 20px;
    margin-top: 50px;
}

.footer-top {
    display: flex;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
    margin-bottom: 30px;
}

.footer-logo {
    width: 250px;
    padding-right: 30px;
}

.footer-logo span {
    font-size: 22px;
    font-weight: bold;
    color: #ff6b81;
}

.footer-logo p {
    font-size: 14px;
    margin-top: 10px;
}

.footer-nav {
    flex: 1;
    display: flex;
    justify-content: space-between;
}

.footer-nav-col h4 {
    font-size: 16px;
    color: #fff;
    margin-bottom: 15px;
    position: relative;
    padding-bottom: 10px;
}

.footer-nav-col h4::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    width: 30px;
    height: 2px;
    background-color: #ff6b81;
}

.footer-nav-col ul li {
    margin-bottom: 8px;
}

.footer-nav-col ul li a {
    color: #ccc;
    font-size: 14px;
    transition: color 0.3s ease;
}

.footer-nav-col ul li a:hover {
    color: #ff6b81;
}

.footer-middle {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
    display: flex;
    justify-content: space-between;
    border-top: 1px solid #444;
    border-bottom: 1px solid #444;
    padding: 30px 0;
    margin-bottom: 30px;
}

.footer-contact p {
    margin-bottom: 10px;
    font-size: 14px;
}

.footer-qrcode {
    display: flex;
}

.qrcode-item {
    text-align: center;
    margin-left: 30px;
}

.qrcode-item img {
    width: 100px;
    height: 100px;
    background-color: #fff;
    padding: 5px;
    border-radius: 4px;
    margin-bottom: 8px;
}

.qrcode-item p {
    font-size: 12px;
}

.footer-bottom {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

.footer-links {
    margin-bottom: 20px;
}

.footer-links h4 {
    font-size: 16px;
    color: #fff;
    margin-bottom: 15px;
}

.footer-links ul {
    display: flex;
    flex-wrap: wrap;
}

.footer-links ul li {
    margin-right: 15px;
    margin-bottom: 10px;
}

.footer-links ul li a {
    color: #ccc;
    font-size: 14px;
    transition: color 0.3s ease;
}

.footer-links ul li a:hover {
    color: #ff6b81;
}

.copyright {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid #444;
}

.copyright p {
    font-size: 12px;
    margin-bottom: 8px;
    color: #999;
}

.copyright a {
    color: #999;
}

.copyright a:hover {
    color: #ff6b81;
}

/* 响应式设计 */
@media screen and (max-width: 1200px) {
    .card {
        width: calc(20% - 20px);
    }
}

@media screen and (max-width: 992px) {
    .card {
        width: calc(25% - 20px);
    }
    
    .footer-top {
        flex-direction: column;
    }
    
    .footer-logo {
        width: 100%;
        margin-bottom: 30px;
        padding-right: 0;
    }
    
    .footer-middle {
        flex-direction: column;
    }
    
    .footer-qrcode {
        margin-top: 20px;
    }
    
    .qrcode-item {
        margin-left: 0;
        margin-right: 30px;
    }
}

@media screen and (max-width: 768px) {
    .header-container {
        flex-direction: column;
        padding: 15px;
    }
    
    .logo {
        margin-bottom: 15px;
    }
    
    .search-box {
        width: 100%;
        max-width: none;
        margin: 0 0 15px;
    }
    
    .main-nav ul {
        flex-wrap: wrap;
        padding: 0 15px;
    }
    
    .main-nav li a {
        padding: 10px 15px;
    }
    
    .card {
        width: calc(33.333% - 20px);
    }
    
    .banner-wrapper {
        height: 300px;
    }
    
    .article-item {
        flex-direction: column;
    }
    
    .article-img {
        width: 100%;
        height: 180px;
        margin-right: 0;
        margin-bottom: 15px;
    }
    
    .footer-nav {
        flex-wrap: wrap;
    }
    
    .footer-nav-col {
        width: 50%;
        margin-bottom: 30px;
    }
}

@media screen and (max-width: 576px) {
    .card {
        width: calc(50% - 20px);
    }
    
    .app-content {
        flex-direction: column;
    }
    
    .app-qrcode {
        margin-top: 30px;
    }
    
    .footer-nav-col {
        width: 100%;
    }
}
