* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

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

.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #fff;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.5s ease;
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #ff6b6b;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

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

.main-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
}

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

.logo a {
    font-size: 2.5rem;
    font-weight: bold;
    color: white;
    text-decoration: none;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.search-container {
    flex: 1;
    max-width: 600px;
    margin: 0 40px;
}

.search-box {
    display: flex;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 25px;
    overflow: hidden;
    margin-bottom: 10px;
}

.search-type {
    padding: 12px 15px;
    border: none;
    background: transparent;
    font-size: 14px;
    cursor: pointer;
}

.search-input {
    flex: 1;
    padding: 12px 15px;
    border: none;
    outline: none;
    font-size: 16px;
}

.search-btn {
    padding: 12px 20px;
    background: #ff6b6b;
    color: white;
    border: none;
    cursor: pointer;
    font-weight: bold;
    transition: background 0.3s ease;
}

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

.hot-searches {
    display: flex;
    align-items: center;
    gap: 15px;
    font-size: 14px;
}

.hot-tag {
    color: #ff6b6b;
    font-weight: bold;
}

.hot-searches a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: color 0.3s ease;
}

.hot-searches a:hover {
    color: white;
}

.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.mobile-menu-toggle span {
    width: 25px;
    height: 3px;
    background: white;
    margin: 3px 0;
    transition:
    transition: 0.3s;
}

.main-nav {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
}

.nav-list {
    display: flex;
    list-style: none;
    justify-content: center;
}

.nav-list li {
    margin: 0 20px;
}

.nav-list a {
    display: block;
    padding: 15px 0;
    color: white;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
    position: relative;
}

.nav-list a:hover,
.nav-list a.active {
    color: #ffeb3b;
}

.nav-list a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 50%;
    background: #ffeb3b;
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.nav-list a:hover::after,
.nav-list a.active::after {
    width: 100%;
}

.hero-banner {
    position: relative;
    height: 400px;
    overflow: hidden;
    margin-bottom: 30px;
}

.banner-slider {
    position: relative;
    height: 100%;
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.5s ease;
}

.slide.active {
    opacity: 1;
}

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

.slide-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
    color: white;
    padding: 40px 30px 30px;
}

.slide-content h2 {
    font-size: 2.5rem;
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.slide-content p {
    font-size: 1.2rem;
    opacity: 0.9;
}

.banner-controls {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 100%;
    display: flex;
    justify-content: space-between;
    padding: 0 20px;
}

.banner-controls button {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: none;
    background: rgba(255, 255, 255, 0.3);
    color: white;
    font-size: 24px;
    cursor: pointer;
    transition: background 0.3s ease;
    backdrop-filter: blur(10px);
}

.banner-controls button:hover {
    background: rgba(255, 255, 255, 0.5);
}

.banner-dots {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: background 0.3s ease;
}

.dot.active {
    background: white;
}

.category-nav {
    background: white;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    margin-bottom: 30px;
}

.category-tabs {
    display: flex;
    justify-content: center;
    padding: 20px 0;
}

.tab-item {
    margin: 0 30px;
    position: relative;
}

.tab-item > a {
    font-size: 18px;
    font-weight: bold;
    color: #333;
    text-decoration: none;
    transition: color 0.3s ease;
}

.tab-item > a:hover {
    color: #667eea;
}

.sub-tabs {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: white;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    padding: 10px;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.tab-item:hover .sub-tabs {
    opacity: 1;
    visibility: visible;
}

.sub-tabs a {
    display: block;
    padding: 8px 15px;
    color: #666;
    text-decoration: none;
    border-radius: 4px;
    transition: background 0.3s ease;
}

.sub-tabs a:hover {
    background: #f0f0f0;
    color: #667eea;
}

.main-content {
    padding: 30px 0;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 3px solid #667eea;
}

.section-header h2 {
    font-size: 24px;
    color: #333;
    position: relative;
}

.section-header h2::before {
    content: '';
    position: absolute;
    left: -25px;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 30px;
    background: linear-gradient(45deg, #667eea, #764ba2);
    border-radius: 2px;
}

.section-stats {
    color: #666;
    font-size: 14px;
}

.section-stats em {
    color: #ff6b6b;
    font-weight: bold;
    font-style: normal;
}

.section-tabs {
    display: flex;
    gap: 20px;
}

.section-tabs a {
    color: #666;
    text-decoration: none;
    padding: 8px 16px;
    border-radius: 20px;
    transition: all 0.3s ease;
    font-size: 14px;
}

.section-tabs a.active,
.section-tabs a:hover {
    background: #667eea;
    color: white;
}

.hot-recommend {
    margin-bottom: 40px;
}

.comic-slider {
    overflow: hidden;
}

.comic-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 20px;
}

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

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

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

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

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

.comic-status {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(255, 107, 107, 0.9);
    color: white;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: bold;
}

.comic-card h3 {
    padding: 15px;
    text-align: center;
}

.comic-card h3 a {
    color: #333;
    text-decoration: none;
    font-size: 16px;
    transition: color 0.3s ease;
}

.comic-card h3 a:hover {
    color: #667eea;
}

.content-layout {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 40px;
    margin-bottom: 40px;
}

.main-sections {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.comic-section {
    background: white;
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.comic-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 20px;
}

.comic-item {
    text-align: center;
}

.comic-item.featured {
    grid-column: span 2;
}

.comic-item .comic-cover {
    height: 200px;
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 10px;
}

.comic-item.featured .comic-cover {
    height: 280px;
}

.comic-item h3 a {
    color: #333;
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s ease;
}

.comic-item h3 a:hover {
    color: #667eea;
}

.sidebar {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.ranking-widget {
    background: white;
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.ranking-widget h3 {
    margin-bottom: 20px;
    color: #333;
    font-size: 18px;
    text-align: center;
}

.ranking-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.ranking-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 10px;
    border-radius: 8px;
    transition: background 0.3s ease;
}

.ranking-item:hover {
    background: #f8f9fa;
}

.ranking-item .rank {
    width: 30px;
    height: 30px;
    background: #667eea;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 14px;
}

.ranking-item:nth-child(1) .rank {
    background: #ff6b6b;
}

.ranking-item:nth-child(2) .rank {
    background: #ffa726;
}

.ranking-item:nth-child(3) .rank {
    background: #66bb6a;
}

.item-info {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
}

.item-info img {
    width: 40px;
    height: 40px;
    border-radius: 4px;
    object-fit: cover;
}

.item-details h4 a {
    color: #333;
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s ease;
}

.item-details h4 a:hover {
    color: #667eea;
}

.item-details p {
    color: #666;
    font-size: 12px;
    margin-top: 2px;
}

.views {
    color: #ff6b6b;
    font-size: 12px;
    font-weight: bold;
}

.friend-links {
    background: white;
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.friend-links h3 {
    margin-bottom: 20px;
    color: #333;
    font-size: 18px;
}

.links-list {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
}

.links-list a {
    color: #666;
    text-decoration: none;
    padding: 8px 16px;
    background: #f8f9fa;
    border-radius: 20px;
    transition: all 0.3s ease;
    font-size: 14px;
}

.links-list a:hover {
    background: #667eea;
    color: white;
}

.main-footer {
    background: #2c3e50;
    color: white;
    padding: 30px 0;
    margin-top: 50px;
}

.footer-links {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 20px;
}

.footer-links a {
    color: #bdc3c7;
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: white;
}

.footer-text {
    text-align: center;
    color: #95a5a6;
    font-size: 14px;
    line-height: 1.8;
}

.fixed-tools {
    position: fixed;
    right: 20px;
    bottom: 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    z-index: 1000;
}

.tool-item {
    width: 50px;
    height: 50px;
    background: #667eea;
    color: white;
    border-radius: 50%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.tool-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}

.tool-item span {
    font-size: 18px;
    font-weight: bold;
}

.tool-item p {
    font-size: 10px;
    margin-top: 2px;
}

.theme-switch .dark-mode {
    display: none;
}

.quick-nav {
    position: absolute;
    right: 60px;
    bottom: 0;
    background: white;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    padding: 10px;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.fixed-tools:hover .quick-nav {
    opacity: 1;
    visibility: visible;
}

.quick-nav a {
    display: block;
    padding: 8px 15px;
    color: #333;
    text-decoration: none;
    border-radius: 4px;
    transition: background 0.3s ease;
    font-size: 14px;
}

.quick-nav a:hover {
    background: #f0f0f0;
    color: #667eea;
}

@media (max-width: 768px) {
    .container {
        padding: 0 15px;
    }
    
    .header-top {
        flex-wrap: wrap;
    }
    
    .logo a {
        font-size: 2rem;
    }
    
    .search-container {
        order: 3;
        width: 100%;
        margin: 15px 0 0 0;
    }
    
    .mobile-menu-toggle {
        display: flex;
    }
    
    .main-nav {
        position: fixed;
        top: 100%;
        left: 0;
        width: 100%;
        background: white;
        box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
        transform: translateY(-100%);
        transition: transform 0.3s ease;
        z-index: 999;
    }
    
    .main-nav.active {
        transform: translateY(0);
    }
    
    .nav-list {
        flex-direction: column;
        padding: 20px;
    }
    
    .nav-list li {
        margin: 10px 0;
    }
    
    .nav-list a {
        color: #333;
        padding: 10px 0;
    }
    
    .hero-banner {
        height: 250px;
    }
    
    .slide-content h2 {
        font-size: 1.8rem;
    }
    
    .slide-content p {
        font-size: 1rem;
    }
    
    .category-tabs {
        flex-wrap: wrap;
        justify-content: flex-start;
        gap: 15px;
    }
    
    .tab-item {
        margin: 0;
    }
    
    .content-layout {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .comic-grid {
        grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
        gap: 15px;
    }
    
    .comic-list {
        grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
        gap: 15px;
    }
    
    .comic-item.featured {
        grid-column: span 1;
    }
    
    .section-tabs {
        flex-wrap: wrap;
        gap: 10px;
    }
    
    .footer-links {
        gap: 15px;
    }
    
    .fixed-tools {
        right: 15px;
        bottom: 15px;
    }
    
    .tool-item {
        width: 45px;
        height: 45px;
    }
    
    .tool-item span {
        font-size: 16px;
    }
    
    .tool-item p {
        font-size: 9px;
    }
}

@media (max-width: 480px) {
    .logo a {
        font-size: 1.5rem;
    }
    
    .hero-banner {
        height: 200px;
    }
    
    .slide-content {
        padding: 20px 15px 15px;
    }
    
    .slide-content h2 {
        font-size: 1.5rem;
    }
    
    .comic-grid {
        grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    }
    
    .comic-list {
        grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
    }
    
    .comic-cover {
        height: 160px;
    }
    
    .comic-item .comic-cover {
        height: 140px;
    }
    
    .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
    
    .section-tabs {
        width: 100%;
        justify-content: flex-start;
    }
}

[data-theme="dark"] {
    background: #1a1a1a;
    color: #e0e0e0;
}

[data-theme="dark"] .main-header {
    background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
}

[data-theme="dark"] .category-nav,
[data-theme="dark"] .comic-section,
[data-theme="dark"] .ranking-widget,
[data-theme="dark"] .friend-links {
    background: #2d2d2d;
    color: #e0e0e0;
}

[data-theme="dark"] .comic-card {
    background: #2d2d2d;
}

[data-theme="dark"] .comic-card h3 a,
[data-theme="dark"] .comic-item h3 a,
[data-theme="dark"] .ranking-item .item-details h4 a {
    color: #e0e0e0;
}

[data-theme="dark"] .section-header h2,
[data-theme="dark"] .ranking
