/* ==========================================================================
   个人作品集
   全站共享样式：单个文件、零第三方依赖（不加载 Tailwind / FontAwesome / 外部字体）。
   页面：/            → main/index.html
         /tools/      → others/index.html
         /regulations/ → others/Regulations/index.html
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. 设计变量
   -------------------------------------------------------------------------- */
:root {
    --bg: #0a0b0c;
    --bg-soft: #0d0f11;
    --surface: #111316;
    --surface-2: #16191c;
    --line: rgba(255, 255, 255, 0.09);
    --line-strong: rgba(255, 255, 255, 0.16);
    --text: #ecebe6;
    --text-soft: #c7c7c1;
    --muted: #969aa0;
    --muted-2: #7b7f85;
    --accent: #d8ff3e;
    --accent-soft: rgba(216, 255, 62, 0.1);
    --accent-line: rgba(216, 255, 62, 0.38);
    --ink: #0a0b0c;
    --wrap: 1240px;
    --gutter: clamp(20px, 5vw, 48px);
    --header-h: 76px;
    --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
    --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
        "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", sans-serif;
    --font-mono: "SFMono-Regular", "Cascadia Code", "JetBrains Mono", Consolas,
        "Liberation Mono", monospace;
}

/* --------------------------------------------------------------------------
   2. 基础重置
   -------------------------------------------------------------------------- */
*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: var(--font-sans);
    font-size: 16px;
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
    overflow-x: hidden;
}

body.nav-open {
    overflow: hidden;
}

h1,
h2,
h3,
h4,
p,
figure,
dl,
dd {
    margin: 0;
}

ul,
ol {
    margin: 0;
    padding: 0;
    list-style: none;
}

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

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

button {
    font: inherit;
    color: inherit;
    background: none;
    border: 0;
    padding: 0;
    cursor: pointer;
}

::selection {
    background: var(--accent);
    color: var(--ink);
}

:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 3px;
}

::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-track {
    background: var(--bg);
}

::-webkit-scrollbar-thumb {
    background: #2a2d31;
    border: 2px solid var(--bg);
    border-radius: 8px;
}

::-webkit-scrollbar-thumb:hover {
    background: #3a3e43;
}

/* --------------------------------------------------------------------------
   3. 通用布局与工具类
   -------------------------------------------------------------------------- */
/* 通用布局与工具类 */
.wrap {
    width: min(var(--wrap), calc(100% - var(--gutter) * 2));
    margin-inline: auto;
}

.hero-main,
.work-main {
    min-width: 0;
}

.mono {
    font-family: var(--font-mono);
    font-size: 12px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-family: var(--font-mono);
    font-size: 11px;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--muted);
}

.eyebrow .dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--accent);
    box-shadow: 0 0 0 4px var(--accent-soft);
    flex: none;
}

.accent {
    color: var(--accent);
}

.skip-link {
    position: fixed;
    top: 12px;
    left: 12px;
    z-index: 200;
    padding: 10px 16px;
    background: var(--accent);
    color: var(--ink);
    font-size: 13px;
    border-radius: 2px;
    transform: translateY(-200%);
    transition: transform 0.2s var(--ease);
}

.skip-link:focus-visible {
    transform: none;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
    border: 0;
}

.is-hidden {
    display: none !important;
}

/* 顶部阅读进度条 */
.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 120;
    width: 0;
    height: 2px;
    background: var(--accent);
    pointer-events: none;
}

/* --------------------------------------------------------------------------
   4. 页头
   -------------------------------------------------------------------------- */
.site-header {
    position: fixed;
    inset: 0 0 auto 0;
    z-index: 100;
    padding: 18px 0;
    border-bottom: 1px solid transparent;
    transition: padding 0.35s var(--ease), background 0.35s var(--ease),
        border-color 0.35s var(--ease), backdrop-filter 0.35s var(--ease);
}

.site-header.is-scrolled {
    padding: 11px 0;
    background: rgba(10, 11, 12, 0.82);
    border-bottom-color: var(--line);
    backdrop-filter: blur(16px) saturate(140%);
    -webkit-backdrop-filter: blur(16px) saturate(140%);
}

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

.brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    flex: none;
}

.brand-mark {
    display: grid;
    place-items: center;
    width: 36px;
    height: 36px;
    background: var(--accent);
    color: var(--ink);
    font-weight: 700;
    font-size: 17px;
    line-height: 1;
    border-radius: 2px;
    transition: transform 0.35s var(--ease), background 0.3s var(--ease);
}

.brand:hover .brand-mark {
    transform: rotate(-6deg);
}

.brand-text {
    display: flex;
    flex-direction: column;
    gap: 1px;
    line-height: 1.2;
}

.brand-text strong {
    font-size: 16px;
    font-weight: 600;
    letter-spacing: 0.02em;
}

.brand-text small {
    font-family: var(--font-mono);
    font-size: 9px;
    letter-spacing: 0.18em;
    color: var(--muted-2);
    text-transform: uppercase;
}

.nav-desktop {
    display: flex;
    align-items: center;
    gap: 6px;
}

.nav-link {
    position: relative;
    padding: 8px 14px;
    font-size: 14px;
    color: var(--text-soft);
    border-radius: 2px;
    transition: color 0.25s var(--ease), background 0.25s var(--ease);
}

.nav-link::after {
    content: "";
    position: absolute;
    left: 14px;
    right: 14px;
    bottom: 4px;
    height: 1px;
    background: var(--accent);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.3s var(--ease);
}

.nav-link:hover {
    color: var(--text);
}

.nav-link:hover::after,
.nav-link.is-active::after {
    transform: scaleX(1);
}

.nav-link.is-active {
    color: var(--text);
}

.nav-link--cta {
    margin-left: 8px;
    padding: 9px 18px;
    color: var(--ink);
    background: var(--accent);
    font-weight: 600;
}

.nav-link--cta::after {
    display: none;
}

.nav-link--cta:hover {
    color: var(--ink);
    background: #e6ff7a;
}

.nav-toggle {
    display: none;
    width: 40px;
    height: 40px;
    border: 1px solid var(--line-strong);
    border-radius: 2px;
    position: relative;
    flex: none;
}

.nav-toggle span {
    position: absolute;
    left: 11px;
    width: 16px;
    height: 1.5px;
    background: var(--text);
    transition: transform 0.3s var(--ease), opacity 0.3s var(--ease);
}

.nav-toggle span:nth-child(1) {
    top: 15px;
}

.nav-toggle span:nth-child(2) {
    top: 22px;
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) {
    transform: translateY(3.5px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] span:nth-child(2) {
    transform: translateY(-3.5px) rotate(-45deg);
}

/* 移动端全屏菜单 */
.mobile-nav {
    position: fixed;
    inset: 0;
    z-index: 90;
    background: var(--bg);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.35s var(--ease), visibility 0.35s var(--ease);
}

.mobile-nav.is-open {
    opacity: 1;
    visibility: visible;
}

.mobile-nav-inner {
    display: flex;
    flex-direction: column;
    justify-content: center;
    height: 100%;
    padding-top: var(--header-h);
    padding-bottom: 48px;
}

.mobile-link {
    display: grid;
    grid-template-columns: 48px 1fr auto;
    align-items: baseline;
    gap: 8px;
    padding: 18px 0;
    border-bottom: 1px solid var(--line);
    font-size: clamp(1.6rem, 6vw, 2.2rem);
    font-weight: 500;
    letter-spacing: -0.02em;
    transition: color 0.25s var(--ease), padding-left 0.25s var(--ease);
}

.mobile-link span {
    font-family: var(--font-mono);
    font-size: 11px;
    color: var(--accent);
    letter-spacing: 0.1em;
}

.mobile-link i {
    font-style: normal;
    color: var(--muted-2);
    font-size: 18px;
}

.mobile-link:hover {
    color: var(--accent);
    padding-left: 8px;
}

.mobile-nav-foot {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 12px;
    margin-top: 40px;
    font-family: var(--font-mono);
    font-size: 11px;
    letter-spacing: 0.08em;
    color: var(--muted);
}

.mobile-nav-foot a:hover {
    color: var(--accent);
}

/* --------------------------------------------------------------------------
   5. 首页 Hero
   -------------------------------------------------------------------------- */
.hero {
    position: relative;
    min-height: 100svh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: calc(var(--header-h) + 24px) 0 104px;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
    z-index: 0;
    pointer-events: none;
}

.hero-bg::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(900px 600px at 78% 8%, rgba(216, 255, 62, 0.11), transparent 62%),
        radial-gradient(700px 500px at 6% 92%, rgba(120, 140, 255, 0.05), transparent 65%);
}

.hero-bg::after {
    content: "";
    position: absolute;
    inset: 0;
    background-image: linear-gradient(rgba(255, 255, 255, 0.028) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.028) 1px, transparent 1px);
    background-size: 72px 72px;
    -webkit-mask-image: radial-gradient(ellipse 80% 70% at 50% 30%, #000 20%, transparent 78%);
    mask-image: radial-gradient(ellipse 80% 70% at 50% 30%, #000 20%, transparent 78%);
}

.hero-inner {
    position: relative;
    z-index: 2;
}

.hero-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 300px;
    align-items: end;
    gap: 48px;
}

.hero-kicker {
    margin-bottom: clamp(20px, 3vh, 32px);
}

.hero-title {
    font-size: clamp(2.8rem, 7.2vw, 6rem);
    line-height: 1.04;
    letter-spacing: -0.045em;
    font-weight: 600;
    margin: 0 0 clamp(18px, 2.8vh, 30px) -0.03em;
    animation: rise 0.9s var(--ease) both;
}

.hero-title .accent {
    display: inline-block;
    transform: translateY(-0.06em);
}

.hero-role {
    font-size: clamp(1rem, 1.6vw, 1.2rem);
    color: var(--text-soft);
    letter-spacing: 0.04em;
    margin-bottom: 18px;
    animation: rise 0.9s 0.08s var(--ease) both;
}

.hero-role em {
    font-style: normal;
    color: var(--muted-2);
    padding: 0 8px;
}

.hero-lede {
    max-width: 520px;
    font-size: clamp(0.98rem, 1.5vw, 1.08rem);
    line-height: 1.85;
    color: var(--muted);
    animation: rise 0.9s 0.14s var(--ease) both;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: clamp(28px, 4vh, 40px);
    animation: rise 0.9s 0.2s var(--ease) both;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 24px;
    border: 1px solid var(--line-strong);
    border-radius: 2px;
    font-size: 14px;
    letter-spacing: 0.02em;
    color: var(--text);
    transition: background 0.25s var(--ease), color 0.25s var(--ease),
        border-color 0.25s var(--ease), transform 0.25s var(--ease);
}

.btn span {
    transition: transform 0.25s var(--ease);
}

.btn:hover {
    border-color: var(--text);
    transform: translateY(-2px);
}

.btn:hover span {
    transform: translate(2px, -2px);
}

.btn--primary {
    background: var(--accent);
    border-color: var(--accent);
    color: var(--ink);
    font-weight: 600;
}

.btn--primary:hover {
    background: #e6ff7a;
    border-color: #e6ff7a;
}

.hero-meta {
    padding-bottom: 6px;
    animation: rise 0.9s 0.16s var(--ease) both;
}

.meta-list {
    border-top: 1px solid var(--line);
}

.meta-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 16px;
    padding: 13px 0;
    border-bottom: 1px solid var(--line);
}

.meta-row dt {
    font-family: var(--font-mono);
    font-size: 10px;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--muted-2);
}

.meta-row dd {
    font-size: 13px;
    color: var(--text-soft);
    text-align: right;
}

.meta-row dd a:hover {
    color: var(--accent);
}

.meta-row .dot {
    display: inline-block;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--accent);
    margin-right: 6px;
    vertical-align: 1px;
    animation: pulse 2.4s ease-in-out infinite;
}

/* 关键词跑马灯 */
.marquee {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 2;
    overflow: hidden;
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
    padding: 15px 0;
    background: rgba(10, 11, 12, 0.6);
}

.marquee-track {
    display: flex;
    width: max-content;
    animation: marquee 42s linear infinite;
}

.marquee:hover .marquee-track {
    animation-play-state: paused;
}

.marquee-item {
    display: inline-flex;
    align-items: center;
    gap: 28px;
    padding-right: 28px;
    font-family: var(--font-mono);
    font-size: 11px;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--muted);
    white-space: nowrap;
}

.marquee-item::after {
    content: "✳";
    color: var(--accent);
    font-size: 10px;
}

/* --------------------------------------------------------------------------
   6. 通用区块
   -------------------------------------------------------------------------- */
.section {
    padding: clamp(72px, 11vw, 148px) 0;
}

.section--soft {
    background: var(--bg-soft);
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
}

.section-head {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 10px 24px;
    padding-top: 20px;
    margin-bottom: clamp(40px, 6vw, 76px);
    border-top: 1px solid var(--line-strong);
}

.section-index {
    font-family: var(--font-mono);
    font-size: 11px;
    letter-spacing: 0.18em;
    color: var(--accent);
    flex: none;
}

.section-title {
    font-size: clamp(1.7rem, 3.4vw, 2.7rem);
    line-height: 1.15;
    letter-spacing: -0.035em;
    font-weight: 600;
}

.section-note {
    margin-left: auto;
    max-width: 340px;
    font-size: 13.5px;
    line-height: 1.8;
    color: var(--muted);
}

/* 关于 */
.about-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
    gap: clamp(32px, 6vw, 96px);
    align-items: start;
}

.statement {
    font-size: clamp(1.7rem, 3.2vw, 2.75rem);
    line-height: 1.32;
    letter-spacing: -0.03em;
    font-weight: 500;
    max-width: 20ch;
}

.statement em {
    font-style: normal;
    color: var(--accent);
}

.prose p {
    color: var(--muted);
    font-size: 15px;
    line-height: 1.95;
    margin-bottom: 18px;
}

.prose p:last-child {
    margin-bottom: 0;
}

.prose strong {
    color: var(--text-soft);
    font-weight: 500;
}

.stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1px;
    margin-top: clamp(48px, 7vw, 88px);
    border: 1px solid var(--line);
    background: var(--line);
}

.stat {
    background: var(--bg);
    padding: clamp(20px, 3vw, 32px);
}

.stat b {
    display: block;
    font-size: clamp(2rem, 4.4vw, 3.2rem);
    line-height: 1;
    font-weight: 600;
    letter-spacing: -0.04em;
    margin-bottom: 10px;
}

.stat b i {
    font-style: normal;
    color: var(--accent);
    font-size: 0.5em;
    vertical-align: 0.5em;
    padding-left: 2px;
}

.stat span {
    font-family: var(--font-mono);
    font-size: 10px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--muted);
}

/* 精选作品（行式列表） */
.work-list {
    border-top: 1px solid var(--line);
}

.work-row {
    display: grid;
    grid-template-columns: 64px minmax(0, 1fr) 150px 44px;
    align-items: center;
    gap: 24px;
    padding: clamp(24px, 3.4vw, 36px) 4px;
    border-bottom: 1px solid var(--line);
    position: relative;
    transition: background 0.35s var(--ease), padding-left 0.35s var(--ease);
}

.work-row::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--accent);
    transform: scaleY(0);
    transform-origin: top;
    transition: transform 0.35s var(--ease);
}

.work-row:hover {
    background: rgba(255, 255, 255, 0.022);
    padding-left: 18px;
}

.work-row:hover::before {
    transform: scaleY(1);
}

.work-no {
    font-family: var(--font-mono);
    font-size: 11px;
    letter-spacing: 0.12em;
    color: var(--muted-2);
    padding-top: 6px;
    align-self: start;
}

.work-title {
    display: block;
    font-size: clamp(1.45rem, 2.8vw, 2.1rem);
    line-height: 1.2;
    letter-spacing: -0.03em;
    font-weight: 600;
    margin-bottom: 6px;
}

.work-title em {
    font-style: normal;
    font-size: 0.56em;
    font-weight: 400;
    letter-spacing: 0.01em;
    color: var(--muted);
    margin-left: 10px;
    white-space: nowrap;
}

.work-desc {
    display: block;
    max-width: 520px;
    color: var(--muted);
    font-size: 14px;
    line-height: 1.7;
    margin-bottom: 12px;
}

.work-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.work-tags span {
    padding: 4px 9px;
    border: 1px solid var(--line);
    border-radius: 999px;
    font-family: var(--font-mono);
    font-size: 10px;
    letter-spacing: 0.06em;
    color: var(--muted);
    text-transform: uppercase;
}

.work-meta {
    font-family: var(--font-mono);
    font-size: 11px;
    letter-spacing: 0.06em;
    color: var(--muted-2);
    text-align: right;
    white-space: nowrap;
}

.work-arrow {
    width: 40px;
    height: 40px;
    display: grid;
    place-items: center;
    border: 1px solid var(--line-strong);
    border-radius: 50%;
    font-size: 15px;
    color: var(--muted);
    transition: background 0.3s var(--ease), color 0.3s var(--ease),
        border-color 0.3s var(--ease), transform 0.3s var(--ease);
}

.work-row:hover .work-arrow {
    background: var(--accent);
    border-color: var(--accent);
    color: var(--ink);
    transform: rotate(45deg);
}

.more-link {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-top: 36px;
    font-family: var(--font-mono);
    font-size: 12px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--text-soft);
    border-bottom: 1px solid var(--line-strong);
    padding-bottom: 6px;
    transition: color 0.25s var(--ease), border-color 0.25s var(--ease);
}

.more-link:hover {
    color: var(--accent);
    border-color: var(--accent);
}

/* 能力 */
.cap-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    border-top: 1px solid var(--line);
    border-left: 1px solid var(--line);
}

.cap-card {
    padding: 30px 26px 36px;
    border-right: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
    transition: background 0.3s var(--ease);
}

.cap-card:hover {
    background: var(--surface);
}

.cap-no {
    display: block;
    font-family: var(--font-mono);
    font-size: 10px;
    letter-spacing: 0.16em;
    color: var(--accent);
    margin-bottom: 22px;
}

.cap-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 14px;
}

.cap-list li {
    position: relative;
    padding-left: 14px;
    font-size: 13px;
    line-height: 2;
    color: var(--muted);
}

.cap-list li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.95em;
    width: 4px;
    height: 1px;
    background: var(--muted-2);
}

/* 现在 */
.now-list {
    border-top: 1px solid var(--line);
}

.now-item {
    display: grid;
    grid-template-columns: 90px minmax(0, 1fr) auto 30px;
    align-items: center;
    gap: 20px;
    padding: 26px 4px;
    border-bottom: 1px solid var(--line);
    transition: background 0.3s var(--ease), padding-left 0.3s var(--ease);
}

.now-item:hover {
    background: rgba(255, 255, 255, 0.022);
    padding-left: 16px;
}

.now-status {
    font-family: var(--font-mono);
    font-size: 10px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--accent);
    border: 1px solid var(--accent-line);
    border-radius: 999px;
    padding: 4px 10px;
    text-align: center;
    white-space: nowrap;
}

.now-title {
    font-size: 1.1rem;
    font-weight: 500;
}

.now-title small {
    display: block;
    font-size: 13px;
    font-weight: 400;
    color: var(--muted);
    margin-top: 4px;
}

.now-year {
    font-family: var(--font-mono);
    font-size: 11px;
    color: var(--muted-2);
}

.now-item i {
    font-style: normal;
    color: var(--muted-2);
    transition: color 0.25s var(--ease), transform 0.25s var(--ease);
}

.now-item:hover i {
    color: var(--accent);
    transform: translate(2px, -2px);
}

/* 联系 */
.contact {
    position: relative;
    overflow: hidden;
    border-top: 1px solid var(--line);
}

.contact::before {
    content: "";
    position: absolute;
    right: -10%;
    bottom: -40%;
    width: 700px;
    height: 700px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(216, 255, 62, 0.09), transparent 65%);
    pointer-events: none;
}

.contact-inner {
    position: relative;
    z-index: 1;
}

.contact-head {
    font-size: clamp(2rem, 5vw, 4.2rem);
    line-height: 1.15;
    letter-spacing: -0.04em;
    font-weight: 600;
    max-width: 16ch;
    margin: 22px 0 clamp(32px, 5vw, 56px);
}

.contact-head span {
    color: var(--muted);
}

.mail-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 16px 24px;
    padding-top: 28px;
    border-top: 1px solid var(--line);
}

.mail-link {
    position: relative;
    font-size: clamp(1.25rem, 3.4vw, 2.4rem);
    letter-spacing: -0.02em;
    font-weight: 500;
    border-bottom: 1px solid var(--line-strong);
    padding-bottom: 4px;
    transition: color 0.25s var(--ease), border-color 0.25s var(--ease);
}

.mail-link:hover {
    color: var(--accent);
    border-color: var(--accent);
}

.copy-btn {
    padding: 9px 16px;
    border: 1px solid var(--line-strong);
    border-radius: 2px;
    font-family: var(--font-mono);
    font-size: 10px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--muted);
    transition: color 0.2s var(--ease), border-color 0.2s var(--ease),
        background 0.2s var(--ease);
}

.copy-btn:hover {
    color: var(--accent);
    border-color: var(--accent-line);
    background: var(--accent-soft);
}

.contact-note {
    margin-top: 22px;
    max-width: 760px;
    font-size: 13px;
    line-height: 1.9;
    color: var(--muted-2);
}

.contact-links {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 28px;
    margin-top: 44px;
    font-family: var(--font-mono);
    font-size: 11px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--muted);
}

.contact-links a {
    border-bottom: 1px solid transparent;
    padding-bottom: 2px;
    transition: color 0.2s var(--ease), border-color 0.2s var(--ease);
}

.contact-links a:hover {
    color: var(--accent);
    border-color: var(--accent);
}

/* --------------------------------------------------------------------------
   7. 子页面 Hero
   -------------------------------------------------------------------------- */
.page-hero {
    position: relative;
    overflow: hidden;
    padding: calc(var(--header-h) + clamp(48px, 9vh, 90px)) 0 clamp(48px, 8vh, 84px);
    border-bottom: 1px solid var(--line);
    background:
        radial-gradient(800px 380px at 12% 0%, rgba(216, 255, 62, 0.07), transparent 70%),
        var(--bg);
}

.page-hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background-image: linear-gradient(rgba(255, 255, 255, 0.024) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.024) 1px, transparent 1px);
    background-size: 72px 72px;
    -webkit-mask-image: linear-gradient(180deg, #000, transparent 85%);
    mask-image: linear-gradient(180deg, #000, transparent 85%);
    pointer-events: none;
}

.page-hero .wrap {
    position: relative;
    z-index: 1;
}

.page-title {
    font-size: clamp(3rem, 9vw, 7rem);
    line-height: 0.94;
    letter-spacing: -0.055em;
    font-weight: 600;
    margin: 18px 0 24px;
}

.page-title .accent {
    display: inline-block;
}

.page-title--long {
    font-size: clamp(2.6rem, 7vw, 5.4rem);
}

.page-lede {
    max-width: 660px;
    font-size: clamp(0.98rem, 1.6vw, 1.12rem);
    line-height: 1.85;
    color: var(--muted);
}

.page-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 14px 44px;
    margin-top: clamp(32px, 5vw, 52px);
    padding-top: 22px;
    border-top: 1px solid var(--line);
}

.page-stat {
    display: flex;
    align-items: baseline;
    gap: 8px;
}

.page-stat b {
    font-size: 1.35rem;
    font-weight: 600;
    letter-spacing: -0.02em;
}

.page-stat span {
    font-family: var(--font-mono);
    font-size: 10px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--muted);
}

/* --------------------------------------------------------------------------
   8. 作品索引页
   -------------------------------------------------------------------------- */
.products {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
}

.product-card {
    display: flex;
    flex-direction: column;
    border: 1px solid var(--line);
    background: var(--surface);
    border-radius: 3px;
    overflow: hidden;
    transition: border-color 0.35s var(--ease), transform 0.35s var(--ease),
        box-shadow 0.35s var(--ease);
}

.product-card:hover {
    border-color: var(--accent-line);
    transform: translateY(-3px);
    box-shadow: 0 24px 50px -30px rgba(0, 0, 0, 0.9);
}

.product-media {
    position: relative;
    aspect-ratio: 16 / 8.4;
    max-height: 380px;
    display: flex;
    align-items: flex-end;
    padding: 26px;
    overflow: hidden;
    border-bottom: 1px solid var(--line);
    background: #0e1218;
}

.product-media::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: linear-gradient(rgba(255, 255, 255, 0.055) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.055) 1px, transparent 1px);
    background-size: 56px 56px;
    -webkit-mask-image: radial-gradient(ellipse 90% 90% at 30% 20%, #000 10%, transparent 85%);
    mask-image: radial-gradient(ellipse 90% 90% at 30% 20%, #000 10%, transparent 85%);
    pointer-events: none;
}

.product-media img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.9;
    transition: transform 0.8s var(--ease), opacity 0.5s var(--ease);
}

.product-card:hover .product-media img {
    transform: scale(1.04);
    opacity: 1;
}

.product-media--csct {
    background:
        radial-gradient(120% 130% at 18% 12%, rgba(72, 132, 255, 0.4), transparent 58%),
        linear-gradient(140deg, #0c1424, #090b10);
}

.product-media--hoperia::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(8, 9, 10, 0.1) 30%, rgba(8, 9, 10, 0.92) 100%);
}

.product-media--twelve {
    background:
        radial-gradient(120% 130% at 82% 12%, rgba(255, 120, 64, 0.32), transparent 58%),
        linear-gradient(140deg, #1d100a, #090b10);
}

.product-media--qingyou {
    background:
        radial-gradient(120% 130% at 30% 90%, rgba(88, 214, 160, 0.28), transparent 60%),
        linear-gradient(140deg, #0a1815, #090b10);
}

.media-tag {
    position: absolute;
    top: 16px;
    left: 16px;
    z-index: 2;
    padding: 5px 11px;
    border: 1px solid rgba(255, 255, 255, 0.28);
    border-radius: 999px;
    background: rgba(8, 9, 10, 0.45);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    font-family: var(--font-mono);
    font-size: 9px;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--text);
}

.product-mark {
    position: relative;
    z-index: 1;
    font-family: var(--font-mono);
    font-size: clamp(2.2rem, 6vw, 4.2rem);
    line-height: 1;
    letter-spacing: -0.05em;
    color: rgba(236, 235, 230, 0.9);
}

.product-mark small {
    display: block;
    margin-top: 12px;
    font-size: 10px;
    letter-spacing: 0.18em;
    color: var(--muted);
}

.product-body {
    display: flex;
    flex-direction: column;
    flex: 1;
    padding: 24px 26px 26px;
}

.product-head {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 16px;
    margin-bottom: 12px;
}

.product-name {
    font-size: 1.4rem;
    font-weight: 600;
    letter-spacing: -0.02em;
}

.product-kind {
    font-family: var(--font-mono);
    font-size: 10px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--muted-2);
    white-space: nowrap;
}

.product-desc {
    font-size: 13.5px;
    line-height: 1.8;
    color: var(--muted);
    margin-bottom: 22px;
}

.product-foot {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    margin-top: auto;
    padding-top: 16px;
    border-top: 1px solid var(--line);
    font-family: var(--font-mono);
    font-size: 10px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--muted);
}

.product-foot i {
    font-style: normal;
    font-size: 14px;
    transition: transform 0.3s var(--ease), color 0.3s var(--ease);
}

.product-card:hover .product-foot i {
    color: var(--accent);
    transform: translate(2px, -2px);
}

/* 筛选器 */
.filters {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-bottom: 28px;
}

.chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 16px;
    border: 1px solid var(--line);
    border-radius: 999px;
    font-size: 13px;
    color: var(--muted);
    transition: color 0.2s var(--ease), border-color 0.2s var(--ease),
        background 0.2s var(--ease);
}

.chip span {
    font-family: var(--font-mono);
    font-size: 10px;
    color: var(--muted-2);
}

.chip:hover {
    color: var(--text);
    border-color: var(--line-strong);
}

.chip.is-active {
    background: var(--accent);
    border-color: var(--accent);
    color: var(--ink);
    font-weight: 600;
}

.chip.is-active span {
    color: rgba(10, 11, 12, 0.6);
}

.filter-count {
    margin-left: auto;
    font-family: var(--font-mono);
    font-size: 10px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--muted-2);
}

/* 工具卡片 */
.tool-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.tool-card {
    display: flex;
    flex-direction: column;
    min-height: 236px;
    padding: 22px 22px 20px;
    border: 1px solid var(--line);
    border-radius: 3px;
    background: var(--surface);
    transition: border-color 0.3s var(--ease), transform 0.3s var(--ease),
        background 0.3s var(--ease);
}

.tool-card:hover {
    border-color: var(--accent-line);
    background: var(--surface-2);
    transform: translateY(-3px);
}

.tool-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-bottom: 22px;
    font-family: var(--font-mono);
    font-size: 10px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--muted-2);
}

.tool-cat {
    color: var(--muted);
}

.tool-title {
    font-size: 1.16rem;
    font-weight: 600;
    letter-spacing: -0.01em;
    margin-bottom: 8px;
}

.tool-desc {
    font-size: 13px;
    line-height: 1.75;
    color: var(--muted);
    margin-bottom: 22px;
}

.tool-foot {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-top: auto;
    padding-top: 14px;
    border-top: 1px solid var(--line);
    font-family: var(--font-mono);
    font-size: 10px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--muted-2);
}

.tool-foot b {
    font-weight: 400;
    color: var(--text-soft);
    transition: color 0.25s var(--ease);
}

.tool-card:hover .tool-foot b {
    color: var(--accent);
}

/* --------------------------------------------------------------------------
   8.5 桌面应用详情页（中国象棋）
   -------------------------------------------------------------------------- */
.page-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: clamp(28px, 4vw, 40px);
}

.btn--lg {
    padding: 16px 28px;
    font-size: 15px;
}

.chess-layout {
    display: grid;
    grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
    gap: clamp(32px, 6vw, 80px);
    align-items: center;
}

.chess-figure {
    margin: 0;
}

.chess-board {
    display: block;
    width: 100%;
    max-width: 520px;
    height: auto;
    margin-inline: auto;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: #0b0c0a;
    box-shadow: 0 50px 90px -60px #000;
}

.chess-board .board-line {
    stroke: rgba(255, 255, 255, 0.15);
    stroke-width: 1.1;
}

.chess-board .river-text {
    fill: var(--muted-2);
    font-family: var(--font-mono);
    font-size: 12px;
    letter-spacing: 0.5em;
    text-anchor: middle;
}

.chess-board .piece circle {
    fill: #0d0e0c;
    stroke-width: 1.5;
}

.chess-board .piece text {
    font-family: "Songti SC", "STSong", "Noto Serif SC", "SimSun", serif;
    font-size: 25px;
    font-weight: 600;
    text-anchor: middle;
    dominant-baseline: central;
}

.chess-board .piece--red circle {
    stroke: #ff7a5c;
}

.chess-board .piece--red text {
    fill: #ff8a70;
}

.chess-board .piece--black circle {
    stroke: #d9d6cc;
}

.chess-board .piece--black text {
    fill: #dedbd2;
}

.chess-figure figcaption {
    margin-top: 16px;
    text-align: center;
    font-family: var(--font-mono);
    font-size: 10px;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--muted-2);
}

.chess-copy {
    display: flex;
    flex-direction: column;
}

.chess-feature {
    display: grid;
    grid-template-columns: 40px minmax(0, 1fr);
    gap: 14px;
    padding: 20px 0;
    border-top: 1px solid var(--line);
}

.chess-feature:last-child {
    border-bottom: 1px solid var(--line);
}

.chess-feature .cap-no {
    margin: 0;
    padding-top: 3px;
}

.chess-feature h3 {
    font-size: 1.08rem;
    font-weight: 600;
    margin-bottom: 6px;
}

.chess-feature p {
    font-size: 13.5px;
    line-height: 1.85;
    color: var(--muted);
}

.download-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 16px 24px;
    padding: 28px 0;
    border-top: 1px solid var(--line);
}

.download-meta {
    font-family: var(--font-mono);
    font-size: 11px;
    letter-spacing: 0.08em;
    color: var(--muted);
}

.download-specs {
    display: grid;
    gap: 1px;
    margin-top: 32px;
    border: 1px solid var(--line);
    background: var(--line);
}

.download-specs > div {
    display: grid;
    grid-template-columns: 120px minmax(0, 1fr) auto;
    align-items: center;
    gap: 16px;
    padding: 14px 18px;
    background: var(--bg);
}

.download-specs span {
    font-family: var(--font-mono);
    font-size: 10px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--muted-2);
}

.download-specs b {
    font-weight: 400;
    font-size: 13px;
    color: var(--text-soft);
}

.download-specs code {
    font-family: var(--font-mono);
    font-size: 11px;
    line-height: 1.7;
    color: var(--text-soft);
    word-break: break-all;
}

/* --------------------------------------------------------------------------
   9. 文档页
   -------------------------------------------------------------------------- */
.doc-hero {
    padding-bottom: clamp(40px, 6vh, 60px);
}

.doc-meta {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1px;
    margin-top: clamp(32px, 5vw, 48px);
    border: 1px solid var(--line);
    background: var(--line);
}

.doc-meta > div {
    background: var(--bg);
    padding: 16px 18px;
}

.doc-meta dt {
    font-family: var(--font-mono);
    font-size: 9px;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--muted-2);
    margin-bottom: 7px;
}

.doc-meta dd {
    font-size: 13px;
    color: var(--text-soft);
}

.doc-grid {
    display: grid;
    grid-template-columns: 236px minmax(0, 1fr);
    gap: clamp(32px, 6vw, 80px);
    padding: clamp(40px, 7vw, 80px) 0 clamp(72px, 10vw, 120px);
    align-items: start;
}

.toc {
    position: sticky;
    top: calc(var(--header-h) + 24px);
}

.toc-title {
    font-family: var(--font-mono);
    font-size: 10px;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--muted-2);
    padding-bottom: 12px;
    border-bottom: 1px solid var(--line-strong);
}

.toc-list a {
    display: flex;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid var(--line);
    font-size: 13px;
    color: var(--muted);
    transition: color 0.2s var(--ease), padding-left 0.2s var(--ease);
}

.toc-list a span {
    font-family: var(--font-mono);
    font-size: 10px;
    color: var(--muted-2);
    padding-top: 2px;
}

.toc-list a:hover {
    color: var(--accent);
    padding-left: 6px;
}

.toc-note {
    margin-top: 22px;
    font-size: 12px;
    line-height: 1.8;
    color: var(--muted-2);
}

.doc-article {
    max-width: 760px;
}

.doc-lead {
    font-size: clamp(1.05rem, 1.8vw, 1.25rem);
    line-height: 1.9;
    color: var(--text-soft);
    padding-bottom: 36px;
    margin-bottom: 8px;
    border-bottom: 1px solid var(--line-strong);
}

.chapter {
    padding-top: clamp(40px, 6vw, 64px);
    scroll-margin-top: calc(var(--header-h) + 24px);
}

.chapter-head {
    display: flex;
    align-items: baseline;
    gap: 14px;
    margin-bottom: 22px;
}

.chapter-no {
    font-family: var(--font-mono);
    font-size: 10px;
    letter-spacing: 0.14em;
    color: var(--accent);
    white-space: nowrap;
}

.chapter-title {
    font-size: clamp(1.3rem, 2.4vw, 1.7rem);
    letter-spacing: -0.02em;
    font-weight: 600;
}

.article {
    display: grid;
    grid-template-columns: 96px minmax(0, 1fr);
    gap: 20px;
    padding: 20px 0;
    border-top: 1px solid var(--line);
}

.article-no {
    font-family: var(--font-mono);
    font-size: 11px;
    letter-spacing: 0.06em;
    color: var(--muted-2);
    padding-top: 3px;
    white-space: nowrap;
}

.article p {
    font-size: 14.5px;
    line-height: 2;
    color: var(--text-soft);
}

.article p strong {
    color: var(--text);
    font-weight: 500;
}

.doc-footer {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 16px;
    margin-top: 48px;
    padding-top: 24px;
    border-top: 1px solid var(--line-strong);
    font-family: var(--font-mono);
    font-size: 10px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--muted-2);
}

.doc-footer a:hover {
    color: var(--accent);
}

/* --------------------------------------------------------------------------
   10. 页脚
   -------------------------------------------------------------------------- */
.site-footer {
    border-top: 1px solid var(--line);
    padding: clamp(56px, 8vw, 96px) 0 28px;
    background: var(--bg-soft);
}

.footer-top {
    padding-bottom: clamp(40px, 6vw, 64px);
    border-bottom: 1px solid var(--line);
}

.footer-name {
    font-size: clamp(3rem, 10vw, 7rem);
    line-height: 0.9;
    letter-spacing: -0.06em;
    font-weight: 600;
}

.footer-name span {
    color: var(--accent);
}

.footer-line {
    margin-top: 18px;
    font-family: var(--font-mono);
    font-size: 10px;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--muted-2);
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 32px;
    padding: clamp(40px, 6vw, 56px) 0;
}

.footer-col h4 {
    font-family: var(--font-mono);
    font-size: 10px;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--muted-2);
    margin-bottom: 18px;
}

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

.footer-col a,
.footer-col span {
    font-size: 13.5px;
    color: var(--muted);
    transition: color 0.2s var(--ease);
}

.footer-col a:hover {
    color: var(--accent);
}

.footer-bottom {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 12px;
    padding-top: 24px;
    border-top: 1px solid var(--line);
    font-family: var(--font-mono);
    font-size: 10px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--muted-2);
}

/* --------------------------------------------------------------------------
   11. 动效
   -------------------------------------------------------------------------- */
@keyframes rise {
    from {
        opacity: 0;
        transform: translateY(22px);
    }
    to {
        opacity: 1;
        transform: none;
    }
}

@keyframes pulse {
    0%,
    100% {
        opacity: 1;
        box-shadow: 0 0 0 0 rgba(216, 255, 62, 0.4);
    }
    50% {
        opacity: 0.55;
        box-shadow: 0 0 0 5px rgba(216, 255, 62, 0);
    }
}

@keyframes marquee {
    from {
        transform: translateX(0);
    }
    to {
        transform: translateX(-50%);
    }
}

/* 滚动入场：仅当脚本加上 .is-in 时播放，脚本失效时内容依然可见 */
.reveal.is-in {
    animation: rise 0.75s var(--ease) both;
    animation-delay: var(--d, 0ms);
}

/* --------------------------------------------------------------------------
   12. 响应式
   -------------------------------------------------------------------------- */
@media (max-width: 1080px) {
    .cap-grid {
        grid-template-columns: repeat(2, 1fr);
    }

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

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

@media (max-width: 900px) {
    .nav-desktop {
        display: none;
    }

    .nav-toggle {
        display: block;
    }

    .hero-grid {
        grid-template-columns: minmax(0, 1fr);
        gap: 36px;
    }

    .hero-meta {
        max-width: 420px;
    }

    .hero {
        min-height: auto;
        padding: calc(var(--header-h) + 64px) 0 0;
    }

    .hero-inner {
        padding-bottom: 40px;
    }

    .marquee {
        position: relative;
    }

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

    .statement {
        max-width: 22ch;
    }

    .work-row {
        grid-template-columns: 44px minmax(0, 1fr) 36px;
        gap: 16px;
        align-items: start;
    }

    .work-meta {
        display: none;
    }

    .work-arrow {
        margin-top: 2px;
    }

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

    .doc-grid {
        grid-template-columns: minmax(0, 1fr);
        gap: 40px;
    }

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

    .chess-layout {
        grid-template-columns: minmax(0, 1fr);
        gap: 40px;
    }

    .toc {
        position: static;
    }

    .toc-list {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 0 20px;
    }
}

@media (max-width: 640px) {
    :root {
        --header-h: 64px;
    }

    .site-header {
        padding: 12px 0;
    }

    .brand-text small {
        display: none;
    }

    .hero-title {
        font-size: clamp(2.5rem, 10vw, 3.4rem);
    }

    .chess-board {
        max-width: 400px;
    }

    .download-specs > div {
        grid-template-columns: minmax(0, 1fr);
        gap: 6px;
        padding: 14px 16px;
    }

    .download-specs code {
        font-size: 10px;
    }

    .hero-lede {
        font-size: 14.5px;
    }

    .btn {
        padding: 12px 18px;
        font-size: 13px;
    }

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

    .stat {
        display: flex;
        align-items: baseline;
        justify-content: space-between;
        gap: 16px;
    }

    .stat b {
        font-size: 2rem;
        margin-bottom: 0;
    }

    .section-note {
        margin-left: 0;
        max-width: none;
    }

    .work-row {
        grid-template-columns: 34px minmax(0, 1fr);
        padding: 22px 2px;
    }

    .work-arrow {
        display: none;
    }

    .work-title em {
        display: block;
        margin: 6px 0 0;
        font-size: 0.6em;
    }

    .work-desc {
        font-size: 13px;
    }

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

    .now-item {
        grid-template-columns: minmax(0, 1fr) auto;
        gap: 8px 12px;
        align-items: start;
    }

    .now-status {
        order: -1;
        justify-self: start;
        grid-column: 1 / -1;
    }

    .now-year {
        display: none;
    }

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

    .filter-count {
        display: none;
    }

    .article {
        grid-template-columns: minmax(0, 1fr);
        gap: 8px;
    }

    .article p {
        font-size: 14px;
    }

    .toc-list {
        grid-template-columns: 1fr;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 28px;
    }

    .footer-bottom {
        flex-direction: column;
        gap: 8px;
    }
}

/* --------------------------------------------------------------------------
   13. 降低动态效果 & 打印
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        animation-duration: 0.001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.001ms !important;
    }

    .marquee-track {
        animation: none;
    }
}

@media print {
    body {
        background: #fff;
        color: #111;
    }

    .site-header,
    .mobile-nav,
    .site-footer,
    .scroll-progress,
    .toc,
    .doc-footer {
        display: none !important;
    }

    .doc-grid {
        display: block;
        padding: 0;
    }

    .article p,
    .doc-lead {
        color: #222;
    }

    .chapter-no,
    .article-no {
        color: #555;
    }
}
