/* Shared reading and directory styles for the Chinese and English editions. */
:root {
    color-scheme: light;
    --ink: #142e39;
    --navy: #142e39;
    --body: #405963;
    --muted: #526a72;
    --line: #d9e4e5;
    --soft: #f3f8f7;
    --accent: #006963;
    --purple: #006963;
    --paper: #fff;
    --radius: .8rem;
}
* { box-sizing: border-box; }
html { scroll-padding-top: 1rem; }
body { margin: 0; color: var(--ink); background: #fff; font: 1rem/1.7 system-ui, -apple-system, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif; }
a { color: var(--accent); text-underline-offset: .18em; text-decoration-thickness: 1px; }
a:hover { text-decoration: underline; text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid #b95b05; outline-offset: 3px; border-radius: 3px; }
main:focus { outline: none; }
img { max-width: 100%; }
h1, h2, h3, h4, p, ul, ol, figure { margin-top: 0; }
h1, h2, h3, h4 { line-height: 1.4; overflow-wrap: anywhere; }
h2, .section-title { font-size: clamp(1.35rem, 2.5vw, 1.8rem); letter-spacing: -.025em; margin: 0 0 1rem; }
h3 { font-size: 1.14rem; }
small, time { font-size: .875rem; }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
.wrap { max-width: 74rem; margin-inline: auto; padding-inline: clamp(1rem, 4vw, 3rem); }
.main { padding-block: clamp(1.6rem, 4vw, 3rem) clamp(3rem, 6vw, 5rem); }
.site-header { border-bottom: 1px solid var(--line); }
.site-nav, .site-nav nav, .footer-inner, .footer-inner nav { display: flex; align-items: center; flex-wrap: wrap; }
.site-nav { justify-content: space-between; gap: .25rem 2rem; padding-block: .7rem; }
.brand { display: inline-flex; gap: .65rem; align-items: center; text-decoration: none; font-size: 1.2rem; font-weight: 800; letter-spacing: -.04em; color: var(--ink); min-height: 44px; }
.brand-mark { position: relative; width: 2rem; height: 2rem; flex-shrink: 0; border-radius: .56rem; background: var(--accent); }
.brand-mark::before { content: ''; position: absolute; left: .55rem; top: .48rem; width: .8rem; height: 1.04rem; border: 2px solid #fff; border-radius: 2px; box-shadow: .22rem .15rem 0 -.07rem #94d9bd; }
.site-nav nav, .footer-inner nav { gap: .12rem 1.15rem; }
.site-nav nav a, .footer-inner nav a { display: inline-flex; align-items: center; min-height: 44px; color: var(--body); text-decoration: none; font-size: .94rem; }
.site-nav nav a:is(:hover,[aria-current]), .footer-inner nav a:hover { color: var(--accent); text-decoration: underline; }
.page-heading, .home-hero { background: #edf6f3; border-bottom: 1px solid var(--line); }
.page-heading .wrap { padding-block: clamp(2rem, 4.6vw, 3.75rem); }
.page-heading h1 { font-size: clamp(1.85rem, 4vw, 3.05rem); letter-spacing: -.045em; line-height: 1.26; max-width: 32em; margin: 0; }
.page-heading p, .home-intro p { max-width: 49rem; color: var(--body); font-size: 1.08rem; margin: .95rem 0 0; }
.home-hero-inner { display: grid; grid-template-columns: minmax(0, 1.65fr) minmax(16rem, 1fr); gap: clamp(2rem, 6vw, 5rem); align-items: center; padding-block: clamp(2.5rem, 6vw, 5.5rem); }
.home-intro h1 { font-size: clamp(2.4rem, 5.8vw, 4.25rem); line-height: 1.17; letter-spacing: -.065em; margin-bottom: .8rem; }
.search-form { display: flex; gap: .35rem; align-items: center; margin-top: 1.6rem; padding: .35rem; border: 1px solid #99b3ae; border-radius: .7rem; background: #fff; max-width: 35rem; }
.search-form input { min-width: 0; flex: 1; border: 0; border-radius: .35rem; padding: .58rem .8rem; background: transparent; color: var(--ink); }
.search-form button, .btn { display: inline-flex; justify-content: center; align-items: center; padding: .55rem 1.25rem; min-height: 44px; border: 1px solid transparent; border-radius: .5rem; background: var(--accent); color: white; font-size: 1rem; font-weight: 650; text-decoration: none; }
.btn.alt, .btn.ios { background: #1a3c47; }
.btn.ghost { background: white; border-color: #9abcb5; color: var(--accent); }
.quick-apps { border-inline-start: 1px solid #c6ddd5; padding-inline-start: clamp(1.4rem, 4vw, 3rem); }
.quick-apps h2 { margin: 0 0 .9rem; font-size: .9rem; color: var(--body); font-weight: 600; }
.quick-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .85rem .6rem; }
.quick-grid a { display: flex; align-items: center; gap: .6rem; color: var(--ink); text-decoration: none; font-weight: 650; font-size: .94rem; line-height: 1.3; overflow-wrap: anywhere; }
.quick-grid .app-card-icon { width: 2.65rem; height: 2.65rem; }
.app-card-icon, .game-icon, .mini-icon { width: 3.2rem; height: 3.2rem; display: inline-grid; place-items: center; flex-shrink: 0; border-radius: .8rem; border: 1px solid #d4e4df; background: #edf5f2; color: var(--accent); overflow: hidden; font-weight: 750; }
.app-icon-img { display: block; width: 100%; height: 100%; object-fit: cover; }
.home-section + .home-section, .category-rail + .home-section { margin-top: 2.6rem; }
.section-head, .category-rail { display: flex; justify-content: space-between; gap: .5rem 1.4rem; align-items: baseline; flex-wrap: wrap; }
.section-head { margin-bottom: 1rem; }
.section-head h2, .category-rail h2 { margin: 0; }
.section-head a { font-weight: 650; }
.category-rail { align-items: center; justify-content: flex-start; padding-bottom: 1.25rem; border-bottom: 1px solid var(--line); }
.category-rail h2 { font-size: 1rem; }
.platforms, .meta, .hero-actions, .store-actions { display: flex; flex-wrap: wrap; align-items: center; gap: .45rem; }
.platforms { margin-block: .7rem; }
.category-rail .platforms { margin: 0; }
.platform-pill, .badge, .trust-badge { display: inline-flex; align-items: center; border-radius: 2rem; font-size: .875rem; padding: .27rem .75rem; background: var(--soft); color: var(--body); }
a.platform-pill { min-height: 42px; border: 1px solid var(--line); color: var(--accent); text-decoration: none; }
a.platform-pill[aria-current] { background: var(--accent); color: white; border-color: var(--accent); }
.directory-grid, .guide-grid, .grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
.directory-card, .guide-card, .card, .panel, .side-box { min-width: 0; border: 1px solid var(--line); border-radius: var(--radius); background: white; padding: clamp(1.05rem, 2.2vw, 1.65rem); overflow-wrap: anywhere; }
.directory-card, .app-card-head, .game-head, .mini-card { display: flex; align-items: center; gap: .9rem; }
.directory-card, .guide-card { position: relative; }
.directory-card a::after, .guide-card h3 a::after { content: ''; position: absolute; inset: 0; }
.directory-card:focus-within, .guide-card:focus-within, .directory-card:hover, .guide-card:hover { border-color: #729f93; }
.directory-card h3, .card h3, .guide-card h3, .card h2 { font-size: 1.14rem; margin: .2rem 0 .35rem; }
.directory-card small, .guide-card small { color: var(--accent); font-weight: 650; }
.directory-card p, .guide-card p { margin: 0; color: var(--muted); }
.directory-card p { font-size: .9rem; }
.directory-card a, .guide-card h3 a, .card h3 a, .card h2 a { color: var(--ink); text-decoration: none; }
.guide-card { display: flex; flex-direction: column; align-items: flex-start; }
.guide-card h3 { margin-bottom: .65rem; }
.guide-card time { color: var(--muted); margin-top: auto; padding-top: 1rem; }
.link-grid { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 0 1.5rem; }
.link-row { padding: .72rem 0; border-bottom: 1px solid var(--line); color: var(--ink); text-decoration: none; }
.link-row small { display: block; color: var(--muted); }
.resource-line { margin: 2.2rem 0 0; color: var(--muted); }
.muted, .byline, .crumb, .meta, .reader-foot, .footer-inner small { color: var(--muted); }
.crumb { display: flex; gap: .5rem; flex-wrap: wrap; align-items: center; margin-bottom: 1.3rem; font-size: .92rem; }
.reader-layout, .sidebar { display: grid; grid-template-columns: minmax(0, 2.8fr) minmax(13rem, 1fr); gap: clamp(1.4rem, 4vw, 3.5rem); align-items: start; }
.reader, .article, .article-body, .sidebar > *, .reader-layout > * { min-width: 0; overflow-wrap: anywhere; }
.reader { width: 100%; max-width: 50rem; }
.byline { display: flex; flex-wrap: wrap; gap: .25rem 1rem; align-items: center; padding-bottom: 1.1rem; margin-bottom: 1.5rem; border-bottom: 1px solid var(--line); font-size: .875rem; }
.reading-toc { padding: .8rem 1.1rem; background: var(--soft); border-radius: .55rem; border: 1px solid var(--line); margin-block: 1.3rem 2rem; }
.reading-toc summary { min-height: 32px; padding-block: .2rem; cursor: pointer; font-weight: 650; color: var(--accent); }
.reading-toc ol { margin: .6rem 0 .25rem; }
.reading-toc li { margin-block: .32rem; }
.article-copy, .article-body { font-size: 1.055rem; line-height: 1.9; }
.article-copy h2 { margin: 2.15rem 0 .8rem; font-size: 1.55rem; }
.article-copy h3 { margin: 1.65rem 0 .6rem; }
.article-copy p, .article-body p { margin-bottom: .95rem; }
.article-copy ul, .article-copy ol { padding-inline-start: 1.6rem; }
.article-copy li + li { margin-top: .4rem; }
.article-copy img { height: auto; border-radius: .4rem; }
.article-copy table { width: max-content; min-width: 100%; max-width: 100%; display: block; overflow-x: auto; border-collapse: collapse; }
.article-copy td, .article-copy th { min-width: 6rem; border: 1px solid var(--line); padding: .48rem .75rem; text-align: left; }
.article-copy pre { overflow: auto; padding: .7rem; background: var(--soft); }
.reader-foot, .sources { margin-top: 2.5rem; padding-top: 1.1rem; border-top: 1px solid var(--line); font-size: .94rem; }
.side-box { background: #f5f9f7; margin-bottom: 1rem; }
.side-box h2, .toc h2, .toc h3 { font-size: 1.09rem; margin: 0 0 .75rem; }
.side-box ul, .toc ul { list-style: none; padding: 0; margin: 0; }
.side-box li + li, .toc li + li { margin-top: .65rem; }
.article-body > :last-child, .panel > :last-child, .card > :last-child { margin-bottom: 0; }
.sidebar article > section + section, .sidebar .panel + .panel, .reader-aside > section + section { margin-top: 1.2rem; }
.toc a { display: block; padding: .3rem 0; }
.dark-band, .notice { padding: 1.2rem 1.5rem; background: #edf6f3; border: 1px solid #c5ddd4; border-radius: var(--radius); overflow-wrap: anywhere; }
.dark-band { margin-bottom: 1.2rem; }
.code { overflow-wrap: anywhere; font: .87rem/1.7 ui-monospace, monospace; }
.game-head h2 { margin: 0; }
.store-details summary { cursor: pointer; font-size: .94rem; color: var(--accent); margin-top: .8rem; }
.store-details p { margin: .45rem 0 0; }
.search-form + .home-section, .search-form + section, .reader + .home-section { margin-top: 1.8rem; }
.store-missing { color: var(--muted); font-size: .94rem; }
.faq-item { border-top: 1px solid var(--line); padding-block: .8rem; }
.faq-item strong, .faq-item span { display: block; }
.faq-item summary { cursor: pointer; font-weight: 650; }
.feature-list, .summary-box { display: grid; grid-template-columns: repeat(auto-fit,minmax(min(14rem, 100%),1fr)); gap: 1rem; }
.feature, .summary-box > div { padding: .9rem; border-radius: .5rem; background: var(--soft); }
.fact-table { display: grid; grid-template-columns: minmax(5rem, 8rem) minmax(0, 1fr); margin-block: 1rem; }
.fact-table > * { padding: .55rem .75rem; border-bottom: 1px solid var(--line); margin: 0; }
.fact-table > :nth-child(odd) { color: var(--muted); background: var(--soft); }
.news-item { display: block; border-bottom: 1px solid var(--line); padding: .8rem 0; text-decoration: none; }
.news-item span, .news-item small { display: block; color: var(--muted); }
.feedback-form { max-width: 35rem; }
.feedback-form fieldset { padding: .6rem 1rem; border: 1px solid var(--line); margin: 0; }
.feedback-form fieldset label { display: inline-block; padding: .3rem; }
.feedback-form > label { display: block; margin-top: .8rem; font-weight: 600; }
.feedback-form > label :is(input, select, textarea) { display: block; width: 100%; margin-top: .3rem; padding: .55rem; border-radius: .4rem; border: 1px solid #96aaa7; }
.feedback-form .muted { font-size: .9rem; }
.pagination-nav { display: flex; align-items: center; flex-wrap: wrap; justify-content: space-between; gap: .7rem; margin-top: 1.5rem; }
.pagination-nav p { margin: 0; color: var(--muted); font-size: .9rem; }
.pagination-links { display: flex; align-items: center; flex-wrap: wrap; gap: .28rem; }
.pagination-links > * { display: inline-flex; justify-content: center; align-items: center; min-width: 2.6rem; min-height: 2.6rem; padding: .3rem .55rem; border: 1px solid var(--line); border-radius: .4rem; text-decoration: none; }
.pagination-links .current { color: #fff; background: var(--accent); }
.site-footer { border-top: 1px solid var(--line); background: var(--soft); }
.footer-inner { justify-content: space-between; gap: .9rem 2rem; padding-block: 1.5rem; }
.footer-inner small { display: block; }
.footer-inner .dmca-badge img { vertical-align: middle; }
.visually-hidden, .skip-link:not(:focus) { position: absolute; height: 1px; width: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
.skip-link:focus { position: absolute; z-index: 5; left: .6rem; top: .6rem; background: #fff; padding: .55rem; }
@media (max-width: 56rem) {
    .home-hero-inner { grid-template-columns: minmax(0, 1.4fr) minmax(13rem, 1fr); gap: 1.4rem; }
    .directory-grid, .guide-grid, .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .reader-layout, .sidebar { grid-template-columns: minmax(0, 1fr); }
    .reader { max-width: 100%; }
    .quick-apps { padding-inline-start: 1.3rem; }
}
@media (max-width: 40rem) {
    .site-nav { display: block; padding-block: .4rem 0; }
    .site-nav nav { gap: 0 .9rem; }
    .site-nav nav a { font-size: .9rem; }
    .home-hero-inner { display: block; padding-block: 2rem 1.5rem; }
    .home-intro p, .page-heading p { font-size: 1rem; }
    .quick-apps { border-inline-start: 0; border-top: 1px solid #c6ddd5; padding: .85rem 0 0; margin-top: 1.25rem; }
    .quick-apps h2 { margin-bottom: .65rem; }
    .quick-grid { grid-template-columns: repeat(2, minmax(0,1fr)); gap: .5rem; }
    .quick-grid .app-card-icon { width: 2rem; height: 2rem; border-radius: .5rem; }
    .directory-grid, .guide-grid, .grid, .link-grid { grid-template-columns: minmax(0, 1fr); }
    .home-section + .home-section, .category-rail + .home-section { margin-top: 1.8rem; }
    .directory-card, .guide-card { padding: 1rem; }
    .footer-inner { align-items: flex-start; flex-direction: column; }
    .footer-inner nav { gap: .2rem 1rem; }
    .byline { font-size: .82rem; }
}
