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

:root {
    --primary: #ff6b9d;
    --secondary: #c44569;
    --accent: #f8b500;
    --bg-light: #fafafa;
    --bg-white: #ffffff;
    --text-dark: #2c3e50;
    --text-gray: #7f8c8d;
    --border: #e8e8e8;
    --shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    --shadow-hover: 0 8px 24px rgba(0, 0, 0, 0.12);
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
    background: var(--bg-light);
    color: var(--text-dark);
    line-height: 1.6;
}

/* 顶部导航 */
.site-header {
    background: var(--bg-white);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: var(--shadow);
}

.header-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 70px;
}

.logo-area {
    display: flex;
    flex-direction: column;
}

.site-logo {
    font-size: 28px;
    font-weight: 700;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1.2;
}

.logo-tag {
    font-size: 12px;
    color: var(--text-gray);
    margin-top: 2px;
}

.main-navigation {
    display: flex;
    gap: 30px;
}

.nav-link {
    color: var(--text-dark);
    text-decoration: none;
    font-size: 16px;
    font-weight: 500;
    padding: 8px 0;
    position: relative;
    transition: color 0.3s;
}

.nav-link:hover,
.nav-link.active {
    color: var(--primary);
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
}

.mobile-menu-btn {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
}

.mobile-menu-btn span {
    width: 25px;
    height: 3px;
    background: var(--text-dark);
    border-radius: 3px;
    transition: all 0.3s;
}

/* 主横幅 */
.hero-section {
    background: linear-gradient(135deg, #fff5f7 0%, #ffeef2 100%);
    padding: 60px 0;
}

.hero-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.hero-content {
    animation: fadeInLeft 0.6s ease-out;
}

.hero-title {
    font-size: 48px;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 15px;
    line-height: 1.2;
}

.hero-subtitle {
    font-size: 18px;
    color: var(--text-gray);
    margin-bottom: 20px;
    font-weight: 500;
}

.hero-description {
    font-size: 16px;
    color: var(--text-gray);
    line-height: 1.8;
}

.hero-image {
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-hover);
    animation: fadeInRight 0.6s ease-out;
}

.hero-image img {
    width: 100%;
    height: auto;
    display: block;
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* 内容容器 */
.content-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 区块标题 */
.section-title-wrapper {
    text-align: center;
    margin-bottom: 50px;
}

.section-title {
    font-size: 36px;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 15px;
}

.title-line {
    width: 60px;
    height: 4px;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    margin: 0 auto;
    border-radius: 2px;
}

/* 关于区块 */
.about-section {
    padding: 80px 0;
    background: var(--bg-white);
}

.about-text-content {
    max-width: 900px;
    margin: 0 auto;
}

.about-text-content p {
    font-size: 16px;
    line-height: 1.8;
    color: var(--text-dark);
    margin-bottom: 20px;
}

.about-text-content p:last-child {
    margin-bottom: 0;
}

/* 推荐区块 */
.recommend-section {
    padding: 80px 0;
    background: var(--bg-light);
}

.comics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 30px;
}

.comic-item {
    background: var(--bg-white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: all 0.3s;
    cursor: pointer;
}

.comic-item:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.comic-cover-wrapper {
    position: relative;
    width: 100%;
    aspect-ratio: 3/4;
    overflow: hidden;
}

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

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

.comic-hover {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s;
}

.comic-item:hover .comic-hover {
    opacity: 1;
}

.read-button {
    padding: 12px 30px;
    background: var(--primary);
    color: var(--bg-white);
    border: none;
    border-radius: 25px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.read-button:hover {
    background: var(--secondary);
    transform: scale(1.05);
}

.comic-details {
    padding: 20px;
}

.comic-name {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 8px;
}

.comic-category {
    font-size: 13px;
    color: var(--text-gray);
    margin-bottom: 10px;
}

.comic-summary {
    font-size: 14px;
    color: var(--text-gray);
    line-height: 1.6;
}

/* 特色区块 */
.features-section {
    padding: 80px 0;
    background: var(--bg-white);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.feature-card {
    text-align: center;
    padding: 40px 30px;
    background: var(--bg-light);
    border-radius: 12px;
    transition: all 0.3s;
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow);
    background: var(--bg-white);
}

.feature-icon {
    font-size: 48px;
    margin-bottom: 20px;
}

.feature-heading {
    font-size: 20px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 12px;
}

.feature-text {
    font-size: 15px;
    color: var(--text-gray);
    line-height: 1.6;
}

/* 页脚 */
.site-footer {
    background: var(--text-dark);
    color: var(--bg-white);
    padding: 60px 0 20px;
    margin-top: 80px;
}

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

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 20px;
    color: var(--primary);
}

.footer-text {
    font-size: 14px;
    line-height: 1.8;
    color: rgba(255, 255, 255, 0.7);
}

.footer-links {
    list-style: none;
}

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

.footer-links a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s;
}

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

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-bottom p {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.5);
}

/* 页面标题横幅 */
.page-hero {
    background: linear-gradient(135deg, #fff5f7 0%, #ffeef2 100%);
    padding: 60px 0;
    text-align: center;
}

.page-title {
    font-size: 42px;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 15px;
}

.page-subtitle {
    font-size: 18px;
    color: var(--text-gray);
    max-width: 700px;
    margin: 0 auto;
}

/* 分类区块 */
.category-section {
    background: var(--bg-white);
    padding: 30px 0;
    border-bottom: 1px solid var(--border);
}

.category-tabs {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    justify-content: center;
}

.category-btn {
    padding: 10px 25px;
    background: var(--bg-light);
    border: 1px solid var(--border);
    border-radius: 25px;
    font-size: 15px;
    font-weight: 500;
    color: var(--text-dark);
    cursor: pointer;
    transition: all 0.3s;
}

.category-btn:hover,
.category-btn.active {
    background: var(--primary);
    color: var(--bg-white);
    border-color: var(--primary);
}

/* 漫画列表区块 */
.comics-list-section {
    padding: 60px 0;
    background: var(--bg-light);
}

/* 排行区块 */
.ranking-section {
    padding: 60px 0;
    background: var(--bg-white);
}

.section-desc {
    font-size: 16px;
    color: var(--text-gray);
    margin-top: 15px;
}

.ranking-list {
    max-width: 800px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.ranking-item {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 20px;
    background: var(--bg-light);
    border-radius: 12px;
    transition: all 0.3s;
}

.ranking-item:hover {
    transform: translateX(5px);
    box-shadow: var(--shadow);
}

.rank-number {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: var(--bg-white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    font-weight: 700;
    flex-shrink: 0;
}

.rank-cover {
    width: 80px;
    height: 100px;
    border-radius: 8px;
    overflow: hidden;
    flex-shrink: 0;
}

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

.rank-info {
    flex: 1;
}

.rank-info h3 {
    font-size: 20px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 8px;
}

.rank-info p {
    font-size: 14px;
    color: var(--text-gray);
    margin-bottom: 10px;
}

.rank-badge {
    display: inline-block;
    padding: 4px 12px;
    background: var(--accent);
    color: var(--bg-white);
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
}

/* 信息区块 */
.info-section {
    padding: 60px 0;
    background: var(--bg-white);
}

.info-content {
    max-width: 900px;
    margin: 0 auto;
    text-align: center;
}

.info-content h2 {
    font-size: 32px;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 20px;
}

.info-content p {
    font-size: 16px;
    color: var(--text-gray);
    line-height: 1.8;
}

/* 响应式设计 */
@media (max-width: 968px) {
    .hero-container {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-image {
        order: -1;
    }
}

@media (max-width: 768px) {
    .main-navigation {
        position: fixed;
        top: 70px;
        left: -100%;
        width: 100%;
        background: var(--bg-white);
        flex-direction: column;
        padding: 20px;
        gap: 0;
        box-shadow: var(--shadow);
        transition: left 0.3s;
    }

    .main-navigation.active {
        left: 0;
    }

    .main-navigation .nav-link {
        display: block;
        padding: 15px 0;
        border-bottom: 1px solid var(--border);
    }

    .mobile-menu-btn {
        display: flex;
    }

    .mobile-menu-btn.active span:nth-child(1) {
        transform: rotate(45deg) translate(8px, 8px);
    }

    .mobile-menu-btn.active span:nth-child(2) {
        opacity: 0;
    }

    .mobile-menu-btn.active span:nth-child(3) {
        transform: rotate(-45deg) translate(7px, -7px);
    }

    .hero-title {
        font-size: 36px;
    }

    .section-title {
        font-size: 28px;
    }

    .comics-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 20px;
    }

    .features-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 28px;
    }

    .comics-grid {
        grid-template-columns: 1fr;
    }
}
