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

body {
    font-family: 'Microsoft YaHei', Arial, sans-serif;
    color: #333;
    line-height: 1.6;
    background-color: #f8f8f8;
}

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

ul, ol {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

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

/* 主题颜色 */
:root {
    --primary-color: #ff6b81;
    --secondary-color: #7971ea;
    --accent-color: #5c6bc0;
    --light-color: #f8f9fa;
    --dark-color: #343a40;
    --gray-color: #6c757d;
    --border-color: #e9ecef;
    --hover-color: #ff4757;
}

/* 按钮样式 */
.btn {
    display: inline-block;
    padding: 8px 20px;
    background-color: var(--primary-color);
    color: white;
    border-radius: 4px;
    font-weight: 500;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn:hover {
    background-color: var(--hover-color);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 107, 129, 0.3);
}

/* 头部导航 */
.header {
    background-color: white;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px;
}

.logo a {
    display: flex;
    align-items: center;
    font-size: 24px;
    font-weight: bold;
    color: var(--primary-color);
}

.logo img {
    height: 40px;
    margin-right: 10px;
}

.main-nav ul {
    display: flex;
}

.main-nav li {
    margin: 0 15px;
}

.main-nav a {
    font-weight: 500;
    position: relative;
}

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

.main-nav a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--primary-color);
    transition: width 0.3s ease;
}

.main-nav a:hover::after {
    width: 100%;
}

.search-box {
    display: flex;
    margin: 0 20px;
}

.search-box input {
    padding: 8px 15px;
    border: 1px solid var(--border-color);
    border-radius: 4px 0 0 4px;
    width: 200px;
}

.search-btn {
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 8px 15px;
    border-radius: 0 4px 4px 0;
    cursor: pointer;
}

.user-actions {
    display: flex;
}

.user-actions .btn {
    margin-left: 10px;
}

.login-btn {
    background-color: transparent;
    color: var(--primary-color);
    border: 1px solid var(--primary-color);
}

.login-btn:hover {
    background-color: var(--primary-color);
    color: white;
}

/* 轮播图 */
.banner {
    padding: 30px 0;
    background-color: white;
}

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

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.5s ease;
    display: flex;
    align-items: center;
}

.slide.active {
    opacity: 1;
    z-index: 1;
}

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

.slide-content {
    position: absolute;
    left: 50px;
    bottom: 50px;
    max-width: 500px;
    color: white;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.5);
    z-index: 2;
}

.slide-content h2 {
    font-size: 32px;
    margin-bottom: 10px;
}

.slide-content p {
    font-size: 18px;
    margin-bottom: 20px;
}

.slider-controls {
    position: absolute;
    bottom: 20px;
    right: 20px;
    z-index: 10;
    display: flex;
}

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

.control.active {
    background-color: white;
    transform: scale(1.2);
}

/* 主要内容区 */
main {
    padding: 30px 0;
}

.section-title {
    font-size: 28px;
    margin-bottom: 30px;
    color: var(--dark-color);
    position: relative;
    padding-left: 15px;
    border-left: 5px solid var(--primary-color);
}

.section-title small {
    font-size: 16px;
    color: var(--gray-color);
    margin-left: 10px;
    font-weight: normal;
}

/* 漫画卡片样式 */
.comic-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 25px;
    margin-bottom: 30px;
}

.comic-card {
    background-color: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.comic-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.15);
}

.comic-cover {
    position: relative;
    height: 250px;
    overflow: hidden;
}

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

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

.tag {
    position: absolute;
    top: 10px;
    right: 10px;
    padding: 5px 10px;
    border-radius: 3px;
    font-size: 12px;
    font-weight: bold;
    color: white;
}

.tag.hot {
    background-color: #ff4757;
}

.tag.new {
    background-color: #2ed573;
}

.tag.update {
    background-color: #1e90ff;
}

.comic-info {
    padding: 15px;
}

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

.comic-info .author {
    color: var(--gray-color);
    font-size: 14px;
    margin-bottom: 8px;
}

.comic-info .desc {
    font-size: 14px;
    color: #666;
    margin-bottom: 10px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    height: 42px;
}

.tags {
    display: flex;
    flex-wrap: wrap;
}

.tags span {
    background-color: #f1f2f6;
    color: var(--gray-color);
    padding: 3px 8px;
    border-radius: 3px;
    font-size: 12px;
    margin-right: 5px;
    margin-bottom: 5px;
}

.view-more {
    text-align: center;
    margin-top: 20px;
}

/* 分类区域样式 */
.hot-section, .japan-section, .china-section, .korea-section, .news-section, .article-section, .app-download, .ranking-section {
    margin-bottom: 50px;
    padding: 30px 0;
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.hot-section {
    background-color: #fff8f8;
}

.japan-section {
    background-color: #f8f8ff;
}

.china-section {
    background-color: #fff8f8;
}

.korea-section {
    background-color: #f8fff8;
}

/* 新闻区域样式 */
.news-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}

.news-card {
    display: flex;
    background-color: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
}

.news-img {
    flex: 0 0 200px;
    overflow: hidden;
}

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

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

.news-content {
    flex: 1;
    padding: 20px;
}

.news-content h3 {
    font-size: 20px;
    margin-bottom: 10px;
}

.news-content .date {
    color: var(--gray-color);
    font-size: 14px;
    margin-bottom: 10px;
}

.news-content .summary {
    font-size: 14px;
    color: #666;
    margin-bottom: 15px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.read-more {
    color: var(--primary-color);
    font-weight: 500;
    font-size: 14px;
}

.read-more:hover {
    color: var(--hover-color);
    text-decoration: underline;
}

/* 文章专区样式 */
.article-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}

.article-card {
    background-color: white;
    padding: 25px;
    border-radius: 8px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
}

.article-card h3 {
    font-size: 22px;
    margin-bottom: 10px;
}

.article-meta {
    display: flex;
    justify-content: space-between;
    color: var(--gray-color);
    font-size: 14px;
    margin-bottom: 15px;
}

.article-card p {
    font-size: 15px;
    color: #555;
    margin-bottom: 15px;
    text-align: justify;
}

/* APP下载区域 */
.app-download {
    background: linear-gradient(135deg, #7f7fd5, #91eae4);
    color: white;
    padding: 50px 0;
}

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

.app-info {
    flex: 1;
    padding-right: 30px;
}

.app-info h2 {
    font-size: 32px;
    margin-bottom: 10px;
}

.app-info p {
    font-size: 18px;
    margin-bottom: 20px;
}

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

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

.icon-check {
    display: inline-block;
    width: 20px;
    height: 20px;
    background-color: white;
    color: var(--primary-color);
    border-radius: 50%;
    text-align: center;
    line-height: 20px;
    margin-right: 10px;
}

.download-buttons {
    display: flex;
    margin-bottom: 20px;
}

.download-buttons .btn {
    margin-right: 15px;
    display: flex;
    align-items: center;
    background-color: white;
    color: var(--dark-color);
}

.download-buttons .btn i {
    margin-right: 8px;
}

.download-buttons .btn:hover {
    background-color: var(--light-color);
    color: var(--primary-color);
}

.qr-code {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.qr-code img {
    width: 100px;
    height: 100px;
    margin-bottom: 10px;
    background-color: white;
    padding: 5px;
}

.app-preview {
    flex: 1;
    display: flex;
    justify-content: center;
}

.phone-mockup {
    max-height: 500px;
    filter: drop-shadow(0 10px 20px rgba(0, 0, 0, 0.2));
}

/* 排行榜样式 */
.ranking-tabs {
    background-color: white;
    border-radius: 8px;
    overflow: hidden;
}

.tab-header {
    display: flex;
    background-color: #f8f9fa;
}

.tab {
    padding: 15px 30px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.tab.active {
    background-color: white;
    color: var(--primary-color);
    border-bottom: 2px solid var(--primary-color);
}

.tab-content {
    padding: 20px;
}

.tab-pane {
    display: none;
}

.tab-pane.active {
    display: block;
}

.ranking-list li {
    display: flex;
    align-items: center;
    padding: 15px 0;
    border-bottom: 1px solid var(--border-color);
}

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

.rank {
    flex: 0 0 40px;
    height: 40px;
    border-radius: 50%;
    background-color: #f1f2f6;
    color: var(--gray-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 18px;
    margin-right: 15px;
}

.rank-1 {
    background-color: #ffd700;
    color: white;
}

.rank-2 {
    background-color: #c0c0c0;
    color: white;
}

.rank-3 {
    background-color: #cd7f32;
    color: white;
}

.rank-cover {
    flex: 0 0 60px;
    height: 80px;
    margin-right: 15px;
    border-radius: 4px;
    overflow: hidden;
}

.rank-info {
    flex: 1;
}

.rank-info h4 {
    font-size: 16px;
    margin-bottom: 5px;
}

.rank-score {
    flex: 0 0 60px;
    text-align: center;
}

.rank-score span {
    font-size: 20px;
    font-weight: bold;
    color: #ff9800;
}

/* 页脚 */
.footer {
    background-color: #343a40;
    color: #adb5bd;
    padding: 50px 0 20px;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 3fr 1fr;
    gap: 30px;
    margin-bottom: 30px;
}

.footer-about {
    padding-right: 30px;
}

.footer-about h3, .footer-links h3, .footer-contact h3 {
    color: white;
    margin-bottom: 20px;
    font-size: 18px;
}

.footer-about p {
    margin-bottom: 15px;
    font-size: 14px;
    line-height: 1.7;
}

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

.link-group {
    flex: 1;
}

.link-group ul li {
    margin-bottom: 10px;
}

.link-group ul li a {
    color: #adb5bd;
    font-size: 14px;
}

.link-group ul li a:hover {
    color: white;
}

.footer-contact p {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
    font-size: 14px;
}

.footer-contact i {
    margin-right: 10px;
    font-size: 18px;
}

.social-media {
    display: flex;
    margin-top: 20px;
}

.social-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 10px;
    color: white;
    font-size: 18px;
}

.social-icon:hover {
    background-color: var(--primary-color);
    transform: translateY(-3px);
}

.footer-links-section {
    margin-bottom: 30px;
}

.friend-links {
    display: flex;
    flex-wrap: wrap;
}

.friend-links ul {
    display: flex;
    flex-wrap: wrap;
    width: 100%;
}

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

.friend-links ul li a {
    color: #adb5bd;
    font-size: 14px;
}

.friend-links ul li a:hover {
    color: white;
}

.copyright {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 14px;
}

.copyright p {
    margin-bottom: 10px;
}

/* 响应式设计 */
@media (max-width: 1200px) {
    .comic-grid {
        grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    }
}

@media (max-width: 992px) {
    .header .container {
        flex-wrap: wrap;
    }
    
    .main-nav {
        order: 3;
        width: 100%;
        margin-top: 15px;
    }
    
    .main-nav ul {
        justify-content: center;
        flex-wrap: wrap;
    }
    
    .main-nav li {
        margin: 5px 10px;
    }
    
    .article-grid {
        grid-template-columns: 1fr;
    }
    
    .app-content {
        flex-direction: column;
    }
    
    .app-info {
        padding-right: 0;
        margin-bottom: 30px;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .comic-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    }
    
    .news-card {
        flex-direction: column;
    }
    
    .news-img {
        height: 200px;
    }
    
    .slide-content {
        left: 20px;
        bottom: 20px;
    }
    
    .slide-content h2 {
        font-size: 24px;
    }
    
    .slide-content p {
        font-size: 16px;
    }
    
    .footer-links {
        flex-direction: column;
    }
    
    .link-group {
        margin-bottom: 20px;
    }
}

@media (max-width: 576px) {
    .comic-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .search-box {
        display: none;
    }
    
    .slider {
        height: 300px;
    }
}
