:root {
    --bg-dark: #29252c;
    --bg-mid: #33425b;
    --bg-light: #d8e9f0;
    --accent: #f33535;
    --text-light: #f0f0f0;
    --text-muted: #b0b8c1;
    --text-dark: #1a1a1a;
    --card-bg: #1e1b21;
    --card-border: #3a3540;
    --sidebar-bg: #1f1c23;
    --white: #ffffff;
    --shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
    --radius: 10px;
    --radius-sm: 6px;
    --transition: 0.3s ease;
    --nav-height: 64px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: var(--nav-height); }
body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', 'Helvetica Neue', sans-serif;
    background-color: #1a171d; color: #e0e0e0; line-height: 1.6; min-height: 100vh; overflow-x: hidden;
}

.top-nav {
    width: 100%; height: var(--nav-height); background-color: var(--bg-dark);
    border-bottom: 2px solid #3a3540; position: sticky; top: 0; z-index: 1000;
    display: flex; align-items: center; justify-content: space-between; padding: 0 24px;
    box-shadow: 0 2px 16px rgba(0,0,0,0.4); transition: var(--transition);
}
.top-nav .nav-left { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.top-nav .nav-left .logo-icon { width: 38px; height: 38px; border-radius: 8px; background: var(--accent); flex-shrink: 0; }
.top-nav .nav-left h1 { font-size: 1.5rem; font-weight: 700; color: #ffffff; letter-spacing: 1px; white-space: nowrap; margin: 0; }
.nav-links { display: flex; align-items: center; gap: 6px; list-style: none; flex-wrap: wrap; justify-content: center; padding: 0 12px; }
.nav-links li a { display: block; padding: 8px 14px; color: #c8cdd4; text-decoration: none; font-size: 0.9rem; font-weight: 500; border-radius: 20px; transition: var(--transition); white-space: nowrap; letter-spacing: 0.5px; }
.nav-links li a:hover { background-color: rgba(243,53,53,0.15); color: #ffffff; }
.nav-right { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.btn-login { padding: 8px 16px; background: transparent; border: 1.5px solid #5a5560; color: #d0d0d0; border-radius: 20px; cursor: pointer; font-size: 0.85rem; font-weight: 500; transition: var(--transition); white-space: nowrap; text-decoration: none; }
.btn-login:hover { border-color: #ffffff; color: #ffffff; background: rgba(255,255,255,0.05); }
.btn-read-now { padding: 8px 20px; background-color: var(--accent); color: #fff; border: none; border-radius: 22px; cursor: pointer; font-size: 0.85rem; font-weight: 600; letter-spacing: 0.5px; transition: var(--transition); white-space: nowrap; text-decoration: none; }
.btn-read-now:hover { background-color: #d42a2a; transform: translateY(-1px); box-shadow: 0 4px 14px rgba(243,53,53,0.4); }
.hamburger { display: none; background: none; border: none; cursor: pointer; padding: 6px; flex-direction: column; gap: 5px; z-index: 1001; }
.hamburger span { display: block; width: 26px; height: 2.5px; background: #e0e0e0; border-radius: 2px; transition: var(--transition); }

.main-wrapper { max-width: 1400px; margin: 0 auto; padding: 20px 16px 30px; display: flex; gap: 24px; position: relative; }
.content-area { flex: 1; min-width: 0; }
.sidebar { width: 340px; flex-shrink: 0; display: flex; flex-direction: column; gap: 20px; position: sticky; top: calc(var(--nav-height) + 20px); align-self: flex-start; max-height: calc(100vh - var(--nav-height) - 40px); overflow-y: auto; scrollbar-width: thin; scrollbar-color: #4a4550 transparent; }
.sidebar::-webkit-scrollbar { width: 5px; } .sidebar::-webkit-scrollbar-thumb { background: #4a4550; border-radius: 10px; }

.section-block { background-color: #1e1b21; border-radius: var(--radius); padding: 22px 20px; border: 1px solid var(--card-border); box-shadow: var(--shadow); transition: var(--transition); }
.section-title { font-size: 1.25rem; font-weight: 700; color: #ffffff; margin-bottom: 16px; padding-bottom: 10px; border-bottom: 2px solid #3a3540; display: flex; align-items: center; gap: 8px; letter-spacing: 0.5px; }
.section-title::before { content: ''; display: inline-block; width: 4px; height: 22px; background-color: var(--accent); border-radius: 2px; flex-shrink: 0; }

.comic-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 14px; }
.comic-card { background: #1e1b21; border-radius: var(--radius); overflow: hidden; border: 1px solid #2e2a33; transition: var(--transition); cursor: pointer; display: flex; flex-direction: column; position: relative; }
.comic-card:hover { transform: translateY(-4px); border-color: var(--accent); box-shadow: 0 10px 28px rgba(243,53,53,0.2); }
.comic-card .card-img-wrap { position: relative; width: 100%; aspect-ratio: 200 / 280; overflow: hidden; background: #2a252f; flex-shrink: 0; }
.comic-card .card-img-wrap img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s ease; }
.comic-card:hover .card-img-wrap img { transform: scale(1.06); }
.comic-card .card-badge { position: absolute; top: 8px; left: 8px; background: var(--accent); color: #fff; font-size: 0.7rem; font-weight: 700; padding: 3px 8px; border-radius: 4px; letter-spacing: 0.5px; z-index: 2; }
.comic-card .card-info { padding: 10px 10px 12px; display: flex; flex-direction: column; gap: 4px; flex: 1; }
.comic-card .card-info .comic-title { font-size: 0.9rem; font-weight: 700; color: #ffffff; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.comic-card .card-info .comic-meta { font-size: 0.7rem; color: #a0a5ad; display: flex; flex-wrap: wrap; gap: 4px 8px; line-height: 1.5; }
.comic-card .card-info .comic-meta span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 90px; }
.comic-card .card-info .comic-type { display: inline-block; background: rgba(51,66,91,0.6); color: #d8e9f0; font-size: 0.65rem; padding: 2px 7px; border-radius: 10px; white-space: nowrap; }

.featured-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.featured-card { background: linear-gradient(180deg, #25212a 0%, #1e1b21 100%); border-radius: var(--radius); overflow: hidden; border: 1px solid #3a3540; transition: var(--transition); cursor: pointer; display: flex; flex-direction: column; }
.featured-card:hover { border-color: #d8e9f0; box-shadow: 0 8px 24px rgba(216,233,240,0.12); transform: translateY(-3px); }
.featured-card .fc-img-wrap { width: 100%; aspect-ratio: 16 / 10; overflow: hidden; background: #2a252f; flex-shrink: 0; }
.featured-card .fc-img-wrap img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s ease; }
.featured-card:hover .fc-img-wrap img { transform: scale(1.05); }
.featured-card .fc-info { padding: 10px 12px 12px; }
.featured-card .fc-info .fc-title { font-weight: 700; color: #fff; font-size: 0.9rem; margin-bottom: 4px; }
.featured-card .fc-info .fc-desc { font-size: 0.72rem; color: #a0a5ad; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

.comic-detail-card { display: flex; gap: 20px; flex-wrap: wrap; background: #1e1b21; border-radius: var(--radius); padding: 20px; border: 1px solid var(--card-border); }
.comic-detail-card .detail-cover { width: 180px; flex-shrink: 0; border-radius: 8px; overflow: hidden; aspect-ratio: 200 / 280; background: #2a252f; }
.comic-detail-card .detail-cover img { width: 100%; height: 100%; object-fit: cover; }
.comic-detail-card .detail-content { flex: 1; min-width: 240px; }
.comic-detail-card .detail-content h3 { font-size: 1.3rem; font-weight: 700; color: #fff; margin-bottom: 8px; }
.comic-detail-card .detail-content .detail-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.comic-detail-card .detail-content .detail-tags span { background: rgba(51,66,91,0.7); color: #d8e9f0; font-size: 0.72rem; padding: 4px 10px; border-radius: 12px; }
.comic-detail-card .detail-content p { font-size: 0.88rem; color: #c0c5cc; line-height: 1.7; }

.characters-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 14px; }
.character-card { background: #1e1b21; border-radius: var(--radius); padding: 14px 10px; text-align: center; border: 1px solid #2e2a33; transition: var(--transition); cursor: pointer; }
.character-card:hover { border-color: #d8e9f0; transform: translateY(-2px); box-shadow: 0 6px 18px rgba(0,0,0,0.3); }
.character-card .char-avatar { width: 80px; height: 80px; border-radius: 50%; overflow: hidden; margin: 0 auto 8px; background: #2a252f; border: 2px solid #4a4550; }
.character-card .char-avatar img { width: 100%; height: 100%; object-fit: cover; }
.character-card .char-name { font-weight: 700; color: #fff; font-size: 0.85rem; margin-bottom: 2px; }
.character-card .char-role { font-size: 0.7rem; color: #a0a5ad; }

.comment-list { display: flex; flex-direction: column; gap: 12px; }
.comment-item { background: #1e1b21; border-radius: var(--radius); padding: 14px 16px; border: 1px solid #2e2a33; transition: var(--transition); }
.comment-item:hover { border-color: #4a4550; }
.comment-item .comment-header { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.comment-item .comment-user { font-weight: 600; color: #e0e0e0; font-size: 0.85rem; }
.comment-item .comment-time { font-size: 0.7rem; color: #888; margin-left: auto; }
.comment-item .comment-body { font-size: 0.84rem; color: #b8bec5; line-height: 1.65; }

.platform-intro { background: #1e1b21; border-radius: var(--radius); padding: 22px 20px; border: 1px solid var(--card-border); }
.platform-intro p { font-size: 0.9rem; color: #c0c5cc; line-height: 1.8; margin-bottom: 10px; }
.platform-intro .intro-highlights { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 10px; }
.platform-intro .intro-highlights .hl-item { flex: 1; min-width: 120px; background: rgba(51,66,91,0.5); border-radius: 8px; padding: 14px 12px; text-align: center; border: 1px solid #3a4555; }
.hl-item .hl-num { font-size: 1.5rem; font-weight: 700; color: #d8e9f0; }
.hl-item .hl-label { font-size: 0.72rem; color: #a0a5ad; margin-top: 2px; }

.download-section { background: linear-gradient(135deg, #1e1b21 0%, #25212c 100%); border-radius: var(--radius); padding: 24px 20px; border: 1px solid var(--card-border); text-align: center; }
.download-section .download-title { font-size: 1.2rem; font-weight: 700; color: #fff; margin-bottom: 6px; }
.download-section .download-subtitle { font-size: 0.82rem; color: #a0a5ad; margin-bottom: 18px; }
.download-buttons { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.download-btn { display: inline-flex; align-items: center; gap: 8px; padding: 10px 18px; border-radius: 24px; font-weight: 600; font-size: 0.82rem; cursor: pointer; transition: var(--transition); text-decoration: none; border: 1.5px solid transparent; white-space: nowrap; }
.download-btn.android { background: #3ddc84; color: #1a1a1a; border-color: #3ddc84; }
.download-btn.android:hover { background: #2cc573; box-shadow: 0 4px 16px rgba(61,220,132,0.35); }
.download-btn.ios { background: #1a1a1a; color: #fff; border-color: #555; }
.download-btn.ios:hover { background: #2a2a2a; border-color: #888; }
.download-btn.pc { background: #52616b; color: #fff; border-color: #52616b; }
.download-btn.pc:hover { background: #3d4a53; }
.download-btn.mac { background: #1a1a1a; color: #fff; border-color: #555; }
.download-btn.mac:hover { background: #2a2a2a; border-color: #888; }
.app-icon { flex-shrink: 0; }

.sidebar-card { background: #1f1c23; border-radius: var(--radius); padding: 16px 14px; border: 1px solid #2e2a33; }
.sidebar-card h4 { font-size: 0.95rem; font-weight: 700; color: #fff; margin-bottom: 12px; padding-bottom: 8px; border-bottom: 1.5px solid #3a3540; letter-spacing: 0.4px; }
.rank-list { list-style: none; display: flex; flex-direction: column; gap: 8px; }
.rank-list li { display: flex; align-items: center; gap: 10px; padding: 6px 0; border-bottom: 1px solid #2a252f; transition: var(--transition); cursor: pointer; }
.rank-list li:last-child { border-bottom: none; }
.rank-list li:hover { color: #fff; }
.rank-list .rank-num { width: 24px; height: 24px; border-radius: 6px; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 0.75rem; flex-shrink: 0; background: #33425b; color: #d8e9f0; }
.rank-list li:nth-child(1) .rank-num { background: #f33535; color: #fff; }
.rank-list li:nth-child(2) .rank-num { background: #e8890c; color: #fff; }
.rank-list li:nth-child(3) .rank-num { background: #c7922f; color: #fff; }
.rank-list .rank-info { flex: 1; min-width: 0; }
.rank-list .rank-name { font-weight: 600; font-size: 0.82rem; color: #d0d0d0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rank-list .rank-sub { font-size: 0.68rem; color: #888; }
.rank-list .rank-change { font-size: 0.72rem; font-weight: 600; flex-shrink: 0; }
.rank-change.up { color: #3ddc84; } .rank-change.down { color: #f33535; }

.total-read-card { background: linear-gradient(135deg, #1f1c23 0%, #25212c 100%); border-radius: var(--radius); padding: 18px 14px; border: 1px solid #2e2a33; text-align: center; }
.total-read-card .big-number { font-size: 2rem; font-weight: 800; color: #d8e9f0; letter-spacing: 2px; }
.total-read-card .big-label { font-size: 0.75rem; color: #a0a5ad; margin-top: 4px; }
.total-read-card .update-time { font-size: 0.68rem; color: #777; margin-top: 6px; }

.stats-grid { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 8px; }
.stat-item { background: #25212c; border-radius: 8px; padding: 12px 8px; text-align: center; border: 1px solid #2e2a33; }
.stat-item .stat-val { font-size: 1.1rem; font-weight: 700; color: #d8e9f0; }
.stat-item .stat-lbl { font-size: 0.65rem; color: #888; margin-top: 2px; }

.bottom-nav { width: 100%; background-color: var(--bg-dark); border-top: 2px solid #3a3540; padding: 28px 20px 20px; margin-top: 30px; }
.bottom-nav .bottom-inner { max-width: 1400px; margin: 0 auto; display: flex; flex-wrap: wrap; gap: 20px; justify-content: space-between; align-items: flex-start; }
.bottom-nav .bottom-col h5 { font-size: 0.9rem; font-weight: 700; color: #fff; margin-bottom: 8px; }
.bottom-nav .bottom-col a { display: block; color: #a0a5ad; text-decoration: none; font-size: 0.78rem; padding: 3px 0; transition: var(--transition); }
.bottom-nav .bottom-col a:hover { color: #d8e9f0; }
.bottom-nav .bottom-copyright { width: 100%; text-align: center; color: #666; font-size: 0.7rem; margin-top: 16px; padding-top: 12px; border-top: 1px solid #2a252f; }
.brand-links-row { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; margin-top: 6px; }
.brand-links-row a { color: #d8e9f0; text-decoration: none; font-size: 0.78rem; padding: 4px 10px; border-radius: 14px; background: rgba(216,233,240,0.08); transition: var(--transition); }
.brand-links-row a:hover { background: rgba(216,233,240,0.18); color: #fff; }

@media (max-width: 1200px) { .comic-grid { grid-template-columns: repeat(4, 1fr); } .featured-grid { grid-template-columns: repeat(3, 1fr); } .sidebar { width: 280px; } }
@media (max-width: 992px) { .comic-grid { grid-template-columns: repeat(3, 1fr); gap: 10px; } .featured-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; } .main-wrapper { flex-direction: column; gap: 20px; } .sidebar { width: 100%; position: static; max-height: none; overflow-y: visible; display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; } .nav-links { display: none; } .hamburger { display: flex; } .nav-links.mobile-open { display: flex; position: absolute; top: var(--nav-height); left: 0; width: 100%; background: var(--bg-dark); flex-direction: column; padding: 12px 20px; gap: 2px; border-bottom: 2px solid #3a3540; box-shadow: 0 8px 20px rgba(0,0,0,0.5); z-index: 999; } .nav-links.mobile-open li a { padding: 10px 14px; border-radius: 6px; } }
@media (max-width: 768px) { .comic-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; } .featured-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; } .sidebar { grid-template-columns: 1fr; gap: 10px; } .comic-detail-card { flex-direction: column; align-items: center; text-align: center; } .comic-detail-card .detail-cover { width: 140px; } .characters-grid { grid-template-columns: repeat(3, 1fr); gap: 8px; } .top-nav { padding: 0 12px; } .top-nav .nav-left h1 { font-size: 1.2rem; } .btn-read-now { padding: 6px 14px; font-size: 0.75rem; } .btn-login { padding: 6px 12px; font-size: 0.75rem; } }
@media (max-width: 480px) { .comic-grid { grid-template-columns: repeat(2, 1fr); gap: 6px; } .comic-card .card-info { padding: 6px 6px 8px; } .comic-card .card-info .comic-title { font-size: 0.75rem; } .characters-grid { grid-template-columns: repeat(2, 1fr); } .btn-read-now { padding: 5px 10px; font-size: 0.7rem; border-radius: 16px; } .btn-login { padding: 5px 10px; font-size: 0.7rem; } }
