:root {
    --ink: #111827;
    --muted: #64748b;
    --paper: #ffffff;
    --canvas: #f5f7fb;
    --navy: #101a32;
    --navy-soft: #182642;
    --brand: #ff6b4a;
    --brand-dark: #e74d2e;
    --aqua: #2cc9a5;
    --line: #e5eaf1;
    --shadow: 0 18px 45px rgba(15, 23, 42, 0.08);
    --radius: 22px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    color: var(--ink);
    background: var(--canvas);
    font-family: "Microsoft YaHei", "PingFang SC", system-ui, sans-serif;
    font-size: 16px;
    line-height: 1.7;
}

body::before {
    position: fixed;
    inset: 0;
    z-index: -1;
    content: "";
    pointer-events: none;
    background-image: radial-gradient(circle at 9% 8%, rgba(255, 107, 74, 0.08), transparent 24%), radial-gradient(circle at 91% 20%, rgba(44, 201, 165, 0.08), transparent 22%);
}

a {
    color: inherit;
    text-decoration: none;
}

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

button,
input {
    font: inherit;
}

.site-shell {
    width: min(1200px, calc(100% - 40px));
    margin-inline: auto;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    color: #ffffff;
    background: rgba(16, 26, 50, 0.96);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(16px);
}

.header-inner {
    display: flex;
    align-items: center;
    min-height: 76px;
    gap: 24px;
}

.brand {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    gap: 10px;
    font-size: 1.25rem;
    font-weight: 900;
    letter-spacing: 0.02em;
}

.brand-mark {
    display: grid;
    width: 44px;
    height: 44px;
    place-items: center;
    color: #ffffff;
    background: var(--brand);
    border: 3px solid #ffffff;
    border-radius: 14px 14px 14px 4px;
    box-shadow: 4px 4px 0 var(--aqua);
    font-size: 0.9rem;
    font-weight: 950;
}

.nav-toggle {
    display: none;
    margin-left: auto;
    color: #ffffff;
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 10px;
    padding: 8px 12px;
    cursor: pointer;
}

.main-nav {
    display: flex;
    align-items: center;
    margin-left: auto;
    gap: 3px;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 10px 9px;
    color: #cad3e4;
    border-radius: 10px;
    font-size: 0.88rem;
    transition: 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
    color: #ffffff;
    background: rgba(255, 107, 74, 0.2);
}

.nav-link.active {
    box-shadow: inset 0 -2px 0 var(--brand);
}

.nav-icon {
    color: var(--aqua);
    font-weight: 900;
}

main {
    padding-block: 34px 72px;
}

.hero {
    position: relative;
    overflow: hidden;
    display: grid;
    grid-template-columns: 1.35fr 0.65fr;
    min-height: 440px;
    padding: 64px;
    color: #ffffff;
    background: var(--navy);
    border-radius: 30px;
    box-shadow: var(--shadow);
}

.hero::after {
    position: absolute;
    width: 340px;
    height: 340px;
    right: -40px;
    bottom: -110px;
    content: "";
    background: var(--brand);
    border: 34px solid var(--aqua);
    border-radius: 50%;
    opacity: 0.78;
}

.hero-copy {
    position: relative;
    z-index: 2;
    align-self: center;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 18px;
    color: #b8fff0;
    font-size: 0.88rem;
    font-weight: 800;
    letter-spacing: 0.12em;
}

.hero h1 {
    margin: 0;
    font-size: clamp(3rem, 8vw, 6.4rem);
    line-height: 1;
    letter-spacing: -0.06em;
}

.hero h1 a {
    color: #ffffff;
}

.hero-lead {
    max-width: 680px;
    margin: 24px 0 30px;
    color: #d9e2f1;
    font-size: 1.08rem;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 0 22px;
    color: #ffffff;
    background: var(--brand);
    border: 0;
    border-radius: 12px;
    font-weight: 800;
    cursor: pointer;
    transition: transform 0.2s ease, background 0.2s ease;
}

.button:hover {
    background: var(--brand-dark);
    transform: translateY(-2px);
}

.button.secondary {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.24);
}

.hero-panel {
    position: relative;
    z-index: 2;
    align-self: center;
    padding: 28px;
    color: var(--ink);
    background: #ffffff;
    border-radius: 22px;
    transform: rotate(2deg);
    box-shadow: 14px 14px 0 rgba(44, 201, 165, 0.95);
}

.hero-panel strong {
    display: block;
    margin-bottom: 8px;
    color: var(--brand);
    font-size: 2.5rem;
}

.update-strip {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    margin-top: 28px;
    padding: 18px 22px;
    background: #ffffff;
    border: 1px solid var(--line);
    border-radius: 16px;
    gap: 18px;
}

.update-label {
    color: var(--brand);
    font-weight: 900;
}

.update-strip p {
    margin: 0;
    color: var(--muted);
}

.section {
    margin-top: 72px;
}

.section-heading {
    display: flex;
    align-items: end;
    justify-content: space-between;
    margin-bottom: 24px;
    gap: 24px;
}

.section-heading h2 {
    margin: 0;
    font-size: clamp(1.65rem, 3vw, 2.25rem);
    line-height: 1.2;
}

.section-heading p {
    max-width: 650px;
    margin: 8px 0 0;
    color: var(--muted);
}

.text-link {
    flex: 0 0 auto;
    color: var(--brand-dark);
    font-weight: 800;
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 18px;
}

.category-card {
    padding: 24px;
    background: #ffffff;
    border: 1px solid var(--line);
    border-radius: 18px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.category-card .category-icon {
    display: grid;
    width: 46px;
    height: 46px;
    place-items: center;
    margin-bottom: 18px;
    color: #ffffff;
    background: var(--category-color, var(--brand));
    border-radius: 14px;
    font-size: 1.35rem;
}

.category-card h3 {
    margin: 0 0 8px;
}

.category-card p {
    margin: 0;
    color: var(--muted);
    font-size: 0.93rem;
}

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

.comic-card {
    overflow: hidden;
    background: #ffffff;
    border: 1px solid var(--line);
    border-radius: 18px;
    box-shadow: 0 9px 24px rgba(15, 23, 42, 0.05);
}

.cover-wrap {
    position: relative;
    overflow: hidden;
    aspect-ratio: 3 / 4;
    background: #dce3ee;
}

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

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

.badge {
    position: absolute;
    left: 12px;
    bottom: 12px;
    padding: 4px 9px;
    color: #ffffff;
    background: rgba(16, 26, 50, 0.88);
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 800;
}

.comic-info {
    padding: 16px;
}

.comic-info h3 {
    margin: 0 0 6px;
    font-size: 1rem;
    line-height: 1.45;
}

.comic-meta {
    display: flex;
    justify-content: space-between;
    color: var(--muted);
    font-size: 0.78rem;
}

.popular-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 18px;
}

.popular-card {
    position: relative;
    overflow: hidden;
    min-height: 360px;
    color: #ffffff;
    background: var(--navy);
    border-radius: 20px;
}

.popular-card img {
    width: 100%;
    height: 100%;
    min-height: 360px;
    object-fit: cover;
    opacity: 0.68;
    transition: transform 0.35s ease;
}

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

.popular-copy {
    position: absolute;
    inset: auto 0 0;
    padding: 54px 20px 20px;
    background: linear-gradient(transparent, rgba(8, 15, 31, 0.96));
}

.popular-copy strong {
    display: block;
    margin-bottom: 5px;
    color: #ffffff;
    font-size: 1.06rem;
}

.popular-copy span {
    color: #b8fff0;
    font-size: 0.84rem;
}

.feature-layout {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 24px;
}

.feature-main {
    position: relative;
    overflow: hidden;
    min-height: 430px;
    color: #ffffff;
    background: var(--navy);
    border-radius: var(--radius);
}

.feature-main img {
    width: 100%;
    height: 100%;
    min-height: 430px;
    object-fit: cover;
    opacity: 0.46;
}

.feature-copy {
    position: absolute;
    inset: auto 0 0;
    padding: 36px;
    background: linear-gradient(transparent, rgba(5, 12, 27, 0.94));
}

.feature-copy h3 {
    margin: 8px 0;
    font-size: 2rem;
}

.feature-copy p {
    margin: 0;
    color: #dce7f6;
}

.feature-list {
    display: grid;
    gap: 14px;
}

.feature-item {
    display: grid;
    grid-template-columns: 92px 1fr;
    align-items: center;
    padding: 13px;
    background: #ffffff;
    border: 1px solid var(--line);
    border-radius: 16px;
    gap: 16px;
}

.feature-item img {
    width: 92px;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    border-radius: 12px;
}

.feature-item h3,
.feature-item p {
    margin: 0;
}

.feature-item p {
    color: var(--muted);
    font-size: 0.86rem;
}

.rank-board {
    overflow: hidden;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    background: #ffffff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
}

.rank-item {
    display: grid;
    grid-template-columns: 46px 68px 1fr auto;
    align-items: center;
    padding: 18px 20px;
    border-bottom: 1px solid var(--line);
    gap: 14px;
}

.rank-item:nth-last-child(-n + 2) {
    border-bottom: 0;
}

.rank-number {
    color: var(--brand);
    font-size: 1.5rem;
    font-weight: 950;
}

.rank-item img {
    width: 68px;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    border-radius: 12px;
}

.rank-item h3,
.rank-item p {
    margin: 0;
}

.rank-item p {
    color: var(--muted);
    font-size: 0.82rem;
}

.score {
    color: #f59e0b;
    font-weight: 900;
}

.timeline {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0;
}

.timeline-item {
    position: relative;
    padding: 28px 24px;
    background: #ffffff;
    border-top: 4px solid var(--brand);
}

.timeline-item + .timeline-item {
    border-left: 1px solid var(--line);
}

.timeline-item:first-child {
    border-radius: 18px 0 0 18px;
}

.timeline-item:last-child {
    border-radius: 0 18px 18px 0;
}

.timeline-item time {
    color: var(--brand-dark);
    font-weight: 900;
}

.timeline-item h3 {
    margin: 8px 0;
}

.timeline-item p {
    margin: 0;
    color: var(--muted);
    font-size: 0.9rem;
}

.route-cloud {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}

.route-card {
    position: relative;
    overflow: hidden;
    min-height: 190px;
    padding: 28px;
    color: #ffffff;
    background: var(--navy-soft);
    border-radius: 20px;
}

.route-card::after {
    position: absolute;
    width: 100px;
    height: 100px;
    right: -18px;
    bottom: -24px;
    content: attr(data-icon);
    color: rgba(255, 255, 255, 0.1);
    font-size: 6rem;
    line-height: 1;
}

.route-card h3 {
    margin: 0 0 12px;
}

.route-card p {
    margin: 0;
    color: #cbd5e1;
}

.guide-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.guide-card {
    padding: 28px;
    background: #ffffff;
    border: 1px solid var(--line);
    border-radius: 18px;
}

.guide-step {
    display: grid;
    width: 44px;
    height: 44px;
    place-items: center;
    color: #ffffff;
    background: var(--navy);
    border-radius: 50%;
    font-weight: 900;
}

.guide-card h3 {
    margin: 18px 0 8px;
}

.guide-card p {
    margin: 0;
    color: var(--muted);
}

.about-panel {
    display: grid;
    grid-template-columns: 0.8fr 1.2fr;
    overflow: hidden;
    color: #ffffff;
    background: var(--navy);
    border-radius: 28px;
}

.about-title {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 50px;
    background: var(--brand);
}

.about-title h2 {
    margin: 0;
    font-size: 2.5rem;
}

.about-title p {
    margin: 12px 0 0;
}

.about-copy {
    padding: 50px;
}

.about-copy p {
    margin: 0 0 16px;
    color: #d8e1f0;
}

.about-points {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}

.about-point {
    padding: 12px;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 10px;
}

.app-panel {
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
    padding: 44px 50px;
    color: #ffffff;
    background: linear-gradient(135deg, #176b67, #101a32 70%);
    border-radius: 28px;
    gap: 34px;
}

.app-panel h2 {
    margin: 0 0 12px;
}

.app-panel p {
    max-width: 720px;
    margin: 0 0 22px;
    color: #d7f5ef;
}

.subscribe-row {
    display: flex;
    max-width: 560px;
    gap: 10px;
}

.subscribe-row input {
    min-width: 0;
    flex: 1;
    padding: 0 16px;
    color: var(--ink);
    background: #ffffff;
    border: 0;
    border-radius: 12px;
}

.qr-mark {
    display: grid;
    width: 150px;
    height: 150px;
    place-items: center;
    color: var(--navy);
    background: repeating-conic-gradient(#101a32 0 25%, #ffffff 0 50%) 0 0 / 26px 26px;
    border: 12px solid #ffffff;
    border-radius: 18px;
    box-shadow: 0 14px 35px rgba(0, 0, 0, 0.2);
}

.qr-mark span {
    padding: 7px 10px;
    background: #ffffff;
    border-radius: 8px;
    font-weight: 950;
}

.site-footer {
    padding: 36px 0;
    color: #aab7cc;
    background: #0b1222;
}

.footer-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.footer-inner p {
    margin: 0;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 18px;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    margin-bottom: 24px;
    color: var(--muted);
    gap: 8px;
    font-size: 0.9rem;
}

.page-hero {
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
    padding: 42px 48px;
    color: #ffffff;
    background: var(--navy);
    border-radius: 24px;
    gap: 24px;
}

.page-hero h1 {
    margin: 0;
    font-size: clamp(2rem, 5vw, 3.8rem);
}

.page-hero p {
    max-width: 720px;
    margin: 12px 0 0;
    color: #cad6e8;
}

.page-symbol {
    display: grid;
    width: 100px;
    height: 100px;
    place-items: center;
    color: #ffffff;
    background: var(--brand);
    border-radius: 28px 28px 28px 8px;
    font-size: 3rem;
}

.category-intro {
    padding: 26px 30px;
    background: #ffffff;
    border-left: 5px solid var(--aqua);
    border-radius: 0 16px 16px 0;
}

.category-intro p {
    margin: 0;
    color: var(--muted);
}

.reader-shell {
    max-width: 920px;
    margin-inline: auto;
}

.article-head {
    padding: 38px;
    text-align: center;
    background: #ffffff;
    border: 1px solid var(--line);
    border-radius: 22px;
}

.article-head h1 {
    margin: 0 0 12px;
    font-size: clamp(2rem, 5vw, 3.2rem);
    line-height: 1.25;
}

.article-meta {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    color: var(--muted);
    gap: 16px;
}

.reading-note {
    margin-top: 24px;
    padding: 20px 24px;
    color: #453312;
    background: #fff8df;
    border: 1px solid #f6dfa1;
    border-radius: 14px;
}

.reading-note h2,
.reading-note p {
    margin: 0;
}

.reading-note h2 {
    margin-bottom: 6px;
    font-size: 1rem;
}

.chapter-content {
    margin-top: 36px;
}

.chapter-content h2 {
    margin-bottom: 22px;
    text-align: center;
}

.chapter-content > p {
    margin: 0 0 24px;
    padding: 22px 26px;
    color: #334155;
    background: #ffffff;
    border-left: 4px solid var(--aqua);
    border-radius: 0 14px 14px 0;
}

.comic-page {
    overflow: hidden;
    margin-bottom: 24px;
    background: #ffffff;
    border: 10px solid #ffffff;
    border-radius: 16px;
    box-shadow: var(--shadow);
}

.comic-page img {
    width: 100%;
    aspect-ratio: 4 / 5;
    object-fit: cover;
}

.comic-page figcaption {
    padding: 12px 8px 4px;
    color: var(--muted);
    text-align: center;
    font-size: 0.86rem;
}

.chapter-end {
    margin-top: 34px;
    padding: 34px;
    text-align: center;
    background: #ffffff;
    border: 1px solid var(--line);
    border-radius: 18px;
}

.chapter-end h2,
.chapter-end p {
    margin: 0;
}

.chapter-end p {
    margin-top: 8px;
    color: var(--muted);
}

.chapter-nav {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    margin-top: 20px;
    gap: 12px;
}

.chapter-nav a,
.chapter-nav span {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 50px;
    padding: 10px;
    background: #ffffff;
    border: 1px solid var(--line);
    border-radius: 12px;
    font-weight: 800;
}

.chapter-nav span {
    color: #a8b0bd;
    background: #eef1f5;
}

.empty-state {
    padding: 64px 24px;
    text-align: center;
    background: #ffffff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
}

.empty-state h2 {
    margin: 0 0 10px;
}

.empty-state p {
    max-width: 620px;
    margin: 0 auto 22px;
    color: var(--muted);
}

.toast {
    position: fixed;
    right: 20px;
    bottom: 20px;
    z-index: 80;
    padding: 13px 18px;
    color: #ffffff;
    background: var(--navy);
    border-radius: 12px;
    opacity: 0;
    transform: translateY(12px);
    pointer-events: none;
    transition: 0.25s ease;
}

.toast.show {
    opacity: 1;
    transform: translateY(0);
}

@media (max-width: 1024px) {
    .main-nav {
        gap: 0;
    }

    .nav-link {
        padding-inline: 7px;
        font-size: 0.8rem;
    }

    .hero {
        grid-template-columns: 1fr;
        padding: 48px;
    }

    .hero-panel {
        display: none;
    }

    .category-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .comic-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .popular-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .comic-card:nth-child(n + 4) {
        display: none;
    }

    .feature-layout {
        grid-template-columns: 1fr;
    }

    .timeline {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }

    .timeline-item,
    .timeline-item:first-child,
    .timeline-item:last-child {
        border-left: 0;
        border-radius: 16px;
    }
}

@media (max-width: 780px) {
    .site-shell {
        width: min(100% - 28px, 1200px);
    }

    .header-inner {
        min-height: 68px;
        flex-wrap: wrap;
        padding-block: 10px;
    }

    .nav-toggle {
        display: block;
    }

    .main-nav {
        display: none;
        width: 100%;
        padding: 10px 0 6px;
        border-top: 1px solid rgba(255, 255, 255, 0.1);
        grid-template-columns: repeat(2, 1fr);
        gap: 6px;
    }

    .main-nav.open {
        display: grid;
    }

    .nav-link {
        justify-content: center;
        font-size: 0.9rem;
    }

    main {
        padding-top: 24px;
    }

    .hero {
        min-height: 390px;
        padding: 34px 26px;
        border-radius: 22px;
    }

    .update-strip {
        grid-template-columns: 1fr;
        gap: 6px;
    }

    .section {
        margin-top: 52px;
    }

    .section-heading {
        align-items: start;
        flex-direction: column;
        gap: 8px;
    }

    .comic-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 14px;
    }

    .popular-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 14px;
    }

    .popular-card,
    .popular-card img {
        min-height: 280px;
    }

    .comic-card:nth-child(n) {
        display: block;
    }

    .comic-card:nth-child(5) {
        display: none;
    }

    .rank-board,
    .route-cloud,
    .guide-grid,
    .about-panel {
        grid-template-columns: 1fr;
    }

    .rank-item:nth-last-child(-n + 2) {
        border-bottom: 1px solid var(--line);
    }

    .rank-item:last-child {
        border-bottom: 0;
    }

    .app-panel {
        grid-template-columns: 1fr;
        padding: 34px 26px;
    }

    .qr-mark {
        order: -1;
    }

    .footer-inner {
        align-items: flex-start;
        flex-direction: column;
    }

    .page-hero {
        grid-template-columns: 1fr;
        padding: 32px 26px;
    }

    .page-symbol {
        display: none;
    }

    .article-head {
        padding: 28px 20px;
    }

    .chapter-nav {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 520px) {
    .category-grid,
    .timeline,
    .about-points {
        grid-template-columns: 1fr;
    }

    .comic-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .comic-info {
        padding: 12px;
    }

    .comic-meta span:last-child {
        display: none;
    }

    .feature-main,
    .feature-main img {
        min-height: 360px;
    }

    .feature-copy {
        padding: 24px;
    }

    .feature-item {
        grid-template-columns: 74px 1fr;
    }

    .feature-item img {
        width: 74px;
    }

    .rank-item {
        grid-template-columns: 38px 56px 1fr;
        padding: 14px;
        gap: 10px;
    }

    .rank-item img {
        width: 56px;
    }

    .score {
        display: none;
    }

    .about-title,
    .about-copy {
        padding: 32px 26px;
    }

    .subscribe-row {
        flex-direction: column;
    }

    .subscribe-row input {
        min-height: 48px;
    }
}
