/* WebTools 视觉系统：纸感画布、清晰层级与统一工作台。 */
:root {
    --primary-color: #176d62;
    --body-bg: #f7f8f4;
    --body-color: #172823;
    --card-bg: #fffefa;
    --card-border: #dde5dc;
    --input-bg: #fffefa;
    --input-border: #cbd8cd;
    --input-color: #172823;
    --secondary-color: #66736e;
    --sidebar-bg: #f0f3ed;
    --canvas: #f7f8f4;
    --surface: #fffefa;
    --surface-soft: #f0f4ed;
    --ink: #172823;
    --muted: #66736e;
    --line: #dde5dc;
    --accent: #176d62;
    --accent-strong: #0f574e;
    --accent-soft: #dfebe3;
    --warm: #d17854;
    --deep: #102c2a;
    --shadow: 0 16px 45px rgba(22, 47, 39, .07);
    --font-main: "PingFang SC", "Microsoft YaHei", "Noto Sans CJK SC", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    --font-mono: "Cascadia Code", "SFMono-Regular", Consolas, "Liberation Mono", monospace;
}

[data-theme="dark"] {
    --primary-color: #8cd5bc;
    --body-bg: #101b19;
    --body-color: #e7efe9;
    --card-bg: #1a2925;
    --card-border: #32463e;
    --input-bg: #13211e;
    --input-border: #3b564b;
    --input-color: #e7efe9;
    --secondary-color: #a7b9af;
    --sidebar-bg: #172723;
    --canvas: #101b19;
    --surface: #1a2925;
    --surface-soft: #1e312b;
    --ink: #e7efe9;
    --muted: #a7b9af;
    --line: #32463e;
    --accent: #8cd5bc;
    --accent-strong: #b7efd6;
    --accent-soft: #24483b;
    --warm: #eca47f;
    --deep: #0b1614;
    --shadow: 0 16px 45px rgba(0, 0, 0, .17);
}

html { scroll-behavior: smooth; }
body {
    min-width: 320px;
    background: var(--canvas);
    color: var(--ink);
    font-family: var(--font-main);
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
}
body, .site-main, .site-header, .tool-tile, .card, .form-control { transition: background-color .25s ease, border-color .25s ease, color .25s ease; }
::selection { background: var(--accent-soft); color: var(--ink); }
a { color: var(--accent); }
a:hover { color: var(--accent-strong); }
button, input, textarea, select { font: inherit; }
:focus-visible { outline: 3px solid var(--warm) !important; outline-offset: 3px; }
.skip-link { position: fixed; z-index: 2000; left: 16px; top: -60px; background: var(--ink); color: var(--surface); padding: 10px 16px; border-radius: 10px; }
.skip-link:focus { top: 12px; color: var(--surface); }
.site-container { width: min(100% - 56px, 1320px); margin-inline: auto; }
.eyebrow { display: inline-flex; align-items: center; gap: 9px; color: var(--accent); font: 700 11px/1.4 var(--font-mono); letter-spacing: .16em; text-transform: uppercase; }
.eyebrow-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--warm); box-shadow: 0 0 0 5px color-mix(in srgb, var(--warm) 18%, transparent); }

/* 顶栏只保留主要入口，搜索结果按工具名即时呈现。 */
.site-header { background: color-mix(in srgb, var(--surface) 90%, transparent); border-bottom: 1px solid var(--line); backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px); z-index: 1030; }
.site-nav { padding: 0; min-height: 82px; }
.nav-inner { display: flex; flex-wrap: wrap; align-items: center; gap: clamp(22px, 4vw, 64px); }
.site-brand { display: inline-flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); flex: none; }
.site-brand:hover { text-decoration: none; color: var(--ink); }
.brand-mark { width: 43px; height: 43px; border-radius: 13px; display: grid; place-items: center; background: var(--deep); color: #c8f4d7; font-size: 17px; transform: rotate(-7deg); box-shadow: 4px 4px 0 var(--accent-soft); }
.brand-mark i { transform: rotate(7deg); }
.brand-copy { display: flex; flex-direction: column; line-height: 1.2; }
.brand-copy strong { font-size: 19px; letter-spacing: -.035em; font-weight: 800; }
.brand-copy small { margin-top: 3px; color: var(--muted); font-size: 10px; letter-spacing: .1em; }
.site-nav .navbar-collapse { order: 2; gap: 26px; }
.site-nav-links { gap: 10px; margin-left: clamp(10px, 2vw, 24px); }
.site-nav-links .nav-link { color: var(--muted); font-size: 14px; font-weight: 700; padding: 10px 14px !important; border-radius: 10px; white-space: nowrap; }
.site-nav-links .nav-link:hover, .site-nav-links .nav-link.active { color: var(--accent); background: var(--accent-soft); text-decoration: none; }
.nav-actions { order: 3; display: flex; align-items: center; gap: 10px; margin-left: auto; }
.theme-toggle, .nav-menu-toggle { width: 42px; height: 42px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); color: var(--ink); display: grid; place-items: center; padding: 0; }
.theme-toggle:hover, .nav-menu-toggle:hover { border-color: var(--accent); color: var(--accent); }
.nav-menu-toggle { display: none; font-size: 17px; }
.header-search { position: relative; width: min(30vw, 314px); min-width: 214px; margin-left: auto; }
.header-search input { width: 100%; height: 43px; background: var(--surface-soft); border: 1px solid var(--line); border-radius: 12px; color: var(--ink); padding: 0 44px 0 40px; outline: 0; font-size: 13px; }
.header-search input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.header-search input::placeholder { color: var(--muted); }
.header-search .search-leading { position: absolute; top: 14px; left: 14px; z-index: 1; color: var(--muted); font-size: 13px; }
.header-search button { position: absolute; top: 5px; right: 5px; width: 33px; height: 33px; border: 0; border-radius: 9px; background: var(--surface); color: var(--accent); }
.header-search button:hover { background: var(--accent); color: var(--surface); }
.search-results { position: absolute; top: calc(100% + 8px); left: 0; right: 0; z-index: 1100; display: grid; gap: 3px; max-height: 330px; overflow-y: auto; padding: 7px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow); }
.search-results[hidden] { display: none; }
.search-results a, .search-results .search-empty { display: flex; align-items: center; gap: 10px; padding: 10px 11px; border-radius: 8px; color: var(--ink); font-size: 13px; text-decoration: none; }
.search-results a:hover, .search-results a:focus { background: var(--accent-soft); color: var(--accent); }
.search-results a i { width: 18px; text-align: center; color: var(--accent); }
.search-results .search-empty { color: var(--muted); }
.site-main { min-height: 54vh; }

/* 首页：版式由展示区、工具目录和流程构成，减少重复卡片。 */
.page-home .site-main { overflow: clip; background-image: radial-gradient(circle at 83% 5%, color-mix(in srgb, var(--accent) 10%, transparent), transparent 27%), linear-gradient(to right, color-mix(in srgb, var(--line) 26%, transparent) 1px, transparent 1px); background-size: auto, 48px 48px; background-position: 0 0, center top; }
.home-hero { min-height: 624px; display: grid; grid-template-columns: minmax(0, .92fr) minmax(0, 1.08fr); align-items: center; gap: clamp(30px, 6vw, 92px); padding-block: clamp(65px, 8vw, 112px) 93px; }
.hero-copy { position: relative; z-index: 2; max-width: 590px; }
.hero-copy h1 { margin: 29px 0 22px; max-width: 590px; color: var(--ink); font-size: clamp(43px, 5.3vw, 76px); font-weight: 850; line-height: 1.17; letter-spacing: -.065em; }
.hero-copy h1 em { font-style: normal; display: block; color: var(--accent); }
.hero-description { max-width: 520px; color: var(--muted); font-size: clamp(16px, 1.4vw, 19px); line-height: 1.85; }
.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 15px 28px; margin-top: 31px; }
.button-primary { min-height: 53px; display: inline-flex; align-items: center; justify-content: center; gap: 20px; padding: 0 23px; border-radius: 13px; background: var(--accent); color: #fff; font-size: 14px; font-weight: 750; text-decoration: none; box-shadow: 0 9px 21px color-mix(in srgb, var(--accent) 24%, transparent); }
.button-primary:hover { color: #fff; background: var(--accent-strong); text-decoration: none; transform: translateY(-2px); }
[data-theme="dark"] .button-primary { color: #10251f; }
[data-theme="dark"] .button-primary:hover { color: #10251f; }
.button-text { display: inline-flex; align-items: center; gap: 9px; color: var(--ink); font-weight: 750; font-size: 14px; text-decoration: none; border-bottom: 1px solid var(--accent); padding-bottom: 4px; }
.button-text:hover { color: var(--accent); text-decoration: none; gap: 13px; }
.hero-highlights { display: flex; flex-wrap: wrap; gap: 10px 20px; padding-top: 27px; margin-top: 36px; border-top: 1px solid var(--line); color: var(--muted); font-size: 12px; }
.hero-highlights i { margin-right: 7px; color: var(--accent); }
.hero-visual { position: relative; width: 100%; min-height: 458px; display: grid; place-items: center; }
.visual-orbit { position: absolute; border: 1px dashed color-mix(in srgb, var(--accent) 25%, transparent); border-radius: 50%; pointer-events: none; }
.visual-orbit-one { width: 550px; height: 550px; right: 0; top: -44px; }
.visual-orbit-two { width: 390px; height: 390px; right: 74px; top: 37px; }
.preview-window { position: relative; z-index: 1; width: min(100%, 576px); transform: rotate(-2deg); border: 1px solid var(--line); border-radius: 20px; background: var(--surface); box-shadow: 0 35px 70px rgba(19, 55, 45, .17), 11px 11px 0 var(--accent-soft); overflow: hidden; }
.preview-topbar { height: 48px; display: flex; align-items: center; justify-content: space-between; padding: 0 18px; border-bottom: 1px solid var(--line); background: color-mix(in srgb, var(--surface-soft) 55%, var(--surface)); color: var(--muted); font: 600 11px var(--font-mono); }
.window-dots { display: flex; gap: 5px; }
.window-dots span { width: 8px; height: 8px; background: #d7b0a0; border-radius: 50%; }
.window-dots span:nth-child(2) { background: #e9d494; }
.window-dots span:nth-child(3) { background: #9ac9ab; }
.preview-tabs { display: flex; gap: 24px; padding: 0 26px; border-bottom: 1px solid var(--line); color: var(--muted); font-size: 12px; font-weight: 700; }
.preview-tabs span { padding: 15px 0 11px; }
.preview-tabs .active { color: var(--accent); border-bottom: 2px solid var(--accent); }
.preview-code { min-height: 257px; display: flex; gap: 19px; padding: 22px 25px; }
.preview-code .line-number { color: #aab7ad; font: 12px/1.9 var(--font-mono); text-align: right; }
.preview-code pre, .preview-code code { margin: 0; padding: 0; background: none; border: 0; color: var(--ink); font: 13px/1.9 var(--font-mono); white-space: pre-wrap; }
.code-key { color: #9d5d6c; }.code-string { color: #23816b; }.code-bool { color: #af7540; }
[data-theme="dark"] .code-key { color: #e0a2b0; }[data-theme="dark"] .code-string { color: #9cdbb4; }[data-theme="dark"] .code-bool { color: #e7ba7e; }
.preview-status { display: flex; justify-content: space-between; gap: 10px; padding: 13px 25px; border-top: 1px solid var(--line); background: var(--surface-soft); color: var(--muted); font: 600 11px var(--font-mono); }
.preview-status span:first-child { color: var(--accent); }
.floating-note { position: absolute; z-index: 2; right: -5px; bottom: 5px; display: flex; align-items: center; gap: 11px; padding: 12px 18px 12px 12px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); box-shadow: var(--shadow); transform: rotate(4deg); }
.floating-note .note-symbol { display: grid; place-items: center; width: 37px; height: 37px; border-radius: 11px; color: var(--warm); background: color-mix(in srgb, var(--warm) 14%, var(--surface)); }
.floating-note strong, .floating-note small { display: block; }
.floating-note strong { color: var(--ink); font-size: 12px; }
.floating-note small { color: var(--muted); font-size: 10px; }

.tools-section { padding-block: 51px 105px; scroll-margin-top: 100px; }
.section-intro { display: flex; align-items: end; justify-content: space-between; gap: 30px; margin-bottom: 29px; }
.section-intro h2, .workflow-intro h2, .callout-copy h2 { color: var(--ink); font-size: clamp(32px, 3.3vw, 47px); font-weight: 800; line-height: 1.25; letter-spacing: -.055em; }
.section-intro h2 { margin: 14px 0 8px; }
.section-intro p, .workflow-intro p, .callout-copy p { color: var(--muted); margin: 0; }
.section-count { white-space: nowrap; color: var(--muted); font: 700 12px var(--font-mono); }
.section-count i { margin-left: 14px; color: var(--accent); }
.tool-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 15px; }
.tool-tile { position: relative; min-height: 248px; display: flex; flex-direction: column; justify-content: space-between; padding: 24px; border: 1px solid var(--line); border-radius: 18px; background: var(--surface); color: var(--ink); text-decoration: none; overflow: hidden; box-shadow: 0 5px 20px rgba(18, 43, 35, .025); }
.tool-tile::after { content: ""; position: absolute; width: 140px; height: 140px; border: 1px solid color-mix(in srgb, var(--accent) 13%, transparent); border-radius: 50%; top: -82px; right: -49px; transition: transform .25s ease; }
.tool-tile:hover { color: var(--ink); text-decoration: none; border-color: var(--accent); box-shadow: var(--shadow); transform: translateY(-5px); }
.tool-tile:hover::after { transform: scale(1.4); }
.tool-tile-featured { grid-column: span 2; background: radial-gradient(circle at 89% 18%, color-mix(in srgb, var(--accent) 16%, transparent), transparent 45%), var(--surface); }
.tool-tile-featured::before { content: "{ }"; position: absolute; bottom: 32px; right: 32px; color: color-mix(in srgb, var(--accent) 15%, transparent); font: 700 128px/.8 var(--font-mono); letter-spacing: -.2em; pointer-events: none; }
.tile-top, .tile-bottom { position: relative; z-index: 1; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.tile-number { color: var(--muted); font: 700 11px var(--font-mono); letter-spacing: .08em; }
.tile-icon { width: 46px; height: 46px; display: grid; place-items: center; border-radius: 13px; background: var(--accent-soft); color: var(--accent); font-size: 18px; }
.tile-body { position: relative; z-index: 1; display: block; margin: 22px 0 17px; }
.tile-body strong { display: block; margin-bottom: 5px; font-size: 20px; font-weight: 800; letter-spacing: -.03em; }
.tile-body small { display: block; color: var(--muted); font-size: 12px; line-height: 1.65; }
.tile-bottom { padding-top: 16px; border-top: 1px solid var(--line); color: var(--muted); font-size: 11px; }
.tile-bottom i { color: var(--accent); font-size: 13px; }

.workflow-section { border-block: 1px solid var(--line); background: radial-gradient(circle at 15% 18%, color-mix(in srgb, var(--warm) 8%, transparent), transparent 27%), var(--surface-soft); }
.workflow-inner { display: grid; grid-template-columns: 270px 1fr; gap: clamp(35px, 6vw, 88px); align-items: center; padding-block: 82px; }
.workflow-intro h2 { margin: 18px 0 13px; }
.workflow-steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px; }
.workflow-step { position: relative; padding-top: 18px; border-top: 1px solid var(--line); }
.workflow-step::before { content: ""; position: absolute; width: 7px; height: 7px; top: -4px; left: 0; border-radius: 50%; background: var(--accent); }
.step-index { color: var(--accent); font: 700 11px var(--font-mono); }
.step-icon { width: 43px; height: 43px; margin: 21px 0 17px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); color: var(--accent); }
.workflow-step h3 { margin: 0 0 8px; color: var(--ink); font-size: 17px; font-weight: 750; }
.workflow-step p { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.8; }

.privacy-callout { display: grid; grid-template-columns: .85fr 1.15fr; gap: clamp(45px, 9vw, 135px); align-items: center; padding-block: 109px 121px; }
.callout-art { position: relative; min-height: 265px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 20px; background: var(--surface); overflow: hidden; }
.art-grid { position: absolute; inset: 0; opacity: .65; background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px); background-size: 28px 28px; mask-image: radial-gradient(circle, black 30%, transparent 80%); }
.art-ring { position: relative; z-index: 1; width: 128px; height: 128px; display: grid; place-items: center; border: 1px dashed var(--accent); border-radius: 50%; box-shadow: 0 0 0 24px var(--accent-soft), 0 0 0 25px var(--line); color: var(--accent); font-size: 39px; }
.art-label { position: absolute; left: 21px; bottom: 17px; color: var(--muted); font: 700 10px var(--font-mono); letter-spacing: .09em; }
.callout-copy h2 { margin: 18px 0 17px; }
.callout-copy p { max-width: 450px; margin-bottom: 23px; line-height: 1.9; }

/* 工具页：保留原功能元素与 ID，统一工作区和说明区的阅读层级。 */
.tool-shell { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: clamp(24px, 3.4vw, 48px); padding-block: 38px 95px; }
.tool-rail { min-width: 0; align-self: start; position: sticky; top: 108px; }
.rail-heading { margin: 4px 0 19px; padding: 0 10px; }
.rail-heading h2 { margin: 9px 0 1px; font-size: 19px; font-weight: 800; letter-spacing: -.03em; }
.rail-heading p { margin: 0; color: var(--muted); font-size: 11px; }
.rail-links { display: grid; gap: 4px; }
.rail-link { min-height: 47px; display: flex; align-items: center; gap: 10px; padding: 0 10px; border: 1px solid transparent; border-radius: 10px; color: var(--muted); font-size: 13px; font-weight: 700; text-decoration: none; white-space: nowrap; }
.rail-link:hover, .rail-link.active { color: var(--accent); background: var(--accent-soft); border-color: color-mix(in srgb, var(--accent) 16%, transparent); text-decoration: none; }
.rail-link > i:not(.rail-arrow) { width: 20px; text-align: center; }
.rail-number { width: 19px; font: 700 10px var(--font-mono); opacity: .65; }
.rail-arrow { margin-left: auto; font-size: 10px; opacity: 0; }
.rail-link:hover .rail-arrow, .rail-link.active .rail-arrow { opacity: 1; }
.rail-utilities { margin-top: 30px; padding: 20px 10px 0; border-top: 1px solid var(--line); }
.rail-utility-buttons { display: grid; gap: 5px; margin-top: 11px; }
.rail-utility-buttons button { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 34px; padding: 4px 7px; border: 0; background: transparent; color: var(--muted); text-align: left; font-size: 11px; }
.rail-utility-buttons button:hover { color: var(--accent); }
.rail-utility-buttons i { width: 16px; text-align: center; }
.tool-workspace { min-width: 0; }
.tool-workspace > :is(.container-fluid, .container) { max-width: none; padding: 0 !important; }
.tool-workspace > :is(.container-fluid, .container) > .row:first-child { margin-bottom: 22px !important; padding: 12px 0 25px; border-bottom: 1px solid var(--line); }
.tool-workspace .breadcrumb { margin-bottom: 20px; font-size: 11px; }
.tool-workspace .breadcrumb-item + .breadcrumb-item::before { color: var(--muted); }
.tool-workspace .breadcrumb-item.active { color: var(--muted); }
.tool-workspace > :is(.container-fluid, .container) > .row:first-child .bg-primary.rounded-circle { display: grid; place-items: center; width: 57px; height: 57px; padding: 0 !important; border-radius: 16px !important; background: var(--accent-soft) !important; }
.tool-workspace > :is(.container-fluid, .container) > .row:first-child .bg-primary.rounded-circle i { color: var(--accent) !important; font-size: 24px !important; }
.tool-workspace h1 { color: var(--ink); font-weight: 800 !important; letter-spacing: -.04em; }
.tool-workspace .card { border: 1px solid var(--line); border-radius: 17px; background: var(--surface); box-shadow: 0 3px 16px rgba(17, 46, 35, .025); }
.tool-workspace .card:hover { box-shadow: var(--shadow); }
.tool-workspace .card-header { padding: 17px 21px; border-bottom: 1px solid var(--line); color: var(--ink); }
.tool-workspace .card-header.bg-light { background: transparent !important; }
.tool-workspace .card-header.bg-primary { background: #176d62 !important; color: #fff !important; }
.tool-workspace .card-header.bg-success { background: #237a5d !important; color: #fff !important; }
.tool-workspace .card-header.bg-primary *, .tool-workspace .card-header.bg-success * { color: #fff !important; }
.tool-workspace .card-header h5, .tool-workspace .card-header h4 { font-weight: 750; font-size: 15px; }
.tool-workspace .card-header i { color: var(--accent); }
.tool-workspace .card-body { padding: 21px; }
.tool-workspace .card-footer { border-top: 1px solid var(--line); background: var(--surface-soft); }
.tool-workspace .form-control, .tool-workspace .form-select, .tool-workspace textarea { border: 1px solid var(--input-border); border-radius: 10px; background: var(--input-bg); color: var(--input-color); }
.tool-workspace textarea, .tool-workspace pre, .tool-workspace code { font-family: var(--font-mono); }
.tool-workspace .form-control:focus, .tool-workspace .form-select:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); background: var(--input-bg); color: var(--input-color); }
.tool-workspace .form-label, .tool-workspace .form-check-label { color: var(--ink); }
.tool-workspace .form-text { color: var(--muted); }
.tool-workspace .btn { border-radius: 9px; font-weight: 650; }
.tool-workspace .btn-outline-secondary { color: var(--ink); border-color: var(--line); }
.tool-workspace .btn-outline-secondary:hover { color: var(--ink); background: var(--surface-soft); border-color: var(--accent); }
.tool-workspace .btn-primary, .btn-primary { background-color: var(--accent); border-color: var(--accent); color: #fff; }
.tool-workspace .btn-primary:hover, .btn-primary:hover { background-color: var(--accent-strong); border-color: var(--accent-strong); color: #fff; }
[data-theme="dark"] .tool-workspace .btn-primary, [data-theme="dark"] .btn-primary, [data-theme="dark"] .tool-workspace .btn-primary:hover, [data-theme="dark"] .btn-primary:hover { color: #10251f; }
.btn-outline-primary { color: var(--accent); border-color: var(--accent); }
.btn-outline-primary:hover { color: #fff; background: var(--accent); border-color: var(--accent); }
[data-theme="dark"] .btn-outline-primary:hover { color: #10251f; }
.bg-primary { background-color: var(--accent) !important; }
.text-primary { color: var(--accent) !important; }
.text-muted { color: var(--muted) !important; }
.bg-light { background-color: var(--surface-soft) !important; }
.list-group-item { background: var(--surface); color: var(--ink); border-color: var(--line); }
.dropdown-menu { background: var(--surface); color: var(--ink); border-color: var(--line); box-shadow: var(--shadow); }
.dropdown-item { color: var(--ink); }
.dropdown-item:hover { background: var(--accent-soft); color: var(--accent); }
.alert { border-radius: 10px; }
[data-theme="dark"] .tool-workspace .alert:not(.alert-danger):not(.alert-success):not(.alert-warning) { background: var(--surface-soft); color: var(--ink); border-color: var(--line); }
[data-theme="dark"] .tool-workspace .text-dark { color: var(--ink) !important; }
[data-theme="dark"] .tool-workspace .btn-secondary { background: #33493f; border-color: #33493f; color: var(--ink); }
[data-theme="dark"] .tool-workspace .bg-primary.text-white,
[data-theme="dark"] .tool-workspace .badge.bg-primary { background: #176d62 !important; color: #fff !important; }
[data-theme="dark"] .tool-workspace .badge.bg-success { background: #237a5d !important; color: #fff !important; }

/* 内容页提供较窄的阅读栏和统一的章节节奏。 */
.content-shell { width: min(100% - 56px, 1110px); margin-inline: auto; padding-block: 60px 110px; }
.content-page { color: var(--ink); }
.editorial-hero { position: relative; padding: clamp(38px, 6vw, 74px); border: 1px solid var(--line); border-radius: 22px; background: radial-gradient(circle at 88% 14%, color-mix(in srgb, var(--accent) 13%, transparent), transparent 34%), var(--surface); overflow: hidden; }
.editorial-hero::after { content: ""; position: absolute; width: 210px; height: 210px; top: -125px; right: -50px; border: 1px dashed var(--accent); border-radius: 50%; opacity: .5; }
.editorial-hero h1 { max-width: 700px; margin: 15px 0; color: var(--ink); font-size: clamp(34px, 4vw, 57px); font-weight: 800; letter-spacing: -.055em; }
.editorial-hero p { max-width: 690px; margin: 0; color: var(--muted); font-size: 16px; line-height: 1.85; }
.section-heading { margin: 0 0 22px; color: var(--ink); font-size: clamp(24px, 2.5vw, 32px); font-weight: 800; letter-spacing: -.04em; }
.surface-panel { background: var(--surface); border: 1px solid var(--line); border-radius: 17px; padding: clamp(22px, 3vw, 35px); }
.content-page .text-muted { color: var(--muted) !important; }
.content-page h2, .content-page h3, .content-page h4 { color: var(--ink); }
.content-page a:not(.btn):not(.button-primary) { color: var(--accent); }
.content-page .btn-primary { color: #fff; }
.content-page .button-primary { color: #fff; }
[data-theme="dark"] .content-page .btn-primary { color: #10251f; }
[data-theme="dark"] .content-page .button-primary { color: #10251f; }
.error-hero { min-height: 380px; display: flex; align-items: flex-start; flex-direction: column; justify-content: center; }
.error-hero h1 { position: relative; z-index: 1; }
.error-hero p { position: relative; z-index: 1; }
.error-code { position: absolute; right: 45px; top: 5px; color: color-mix(in srgb, var(--accent) 9%, transparent); font: 800 clamp(120px, 18vw, 230px)/1 var(--font-mono); letter-spacing: -.12em; pointer-events: none; }
.error-actions { position: relative; z-index: 1; display: flex; flex-wrap: wrap; align-items: center; gap: 24px; margin-top: 30px; }
.error-suggestions { display: flex; flex-wrap: wrap; align-items: center; gap: 22px; padding: 28px 7px; }
.error-suggestions > div { display: flex; flex-wrap: wrap; gap: 10px; }
.error-suggestions a { display: inline-flex; align-items: center; gap: 9px; padding: 8px 13px; border: 1px solid var(--line); border-radius: 9px; background: var(--surface); text-decoration: none; font-size: 12px; }

/* 页脚保留真实站点入口与备案信息。 */
.site-footer { position: relative; overflow: hidden; padding-top: 65px; border-top: 1px solid color-mix(in srgb, var(--accent) 24%, transparent); background: #102b29; color: #dbe9e1; }
.site-footer::before { content: ""; position: absolute; width: 400px; height: 400px; right: -170px; top: -280px; border: 1px solid rgba(255,255,255,.13); border-radius: 50%; box-shadow: 0 0 0 70px rgba(255,255,255,.018), 0 0 0 140px rgba(255,255,255,.012); }
.footer-grid { position: relative; display: grid; grid-template-columns: 1.6fr 1fr 1fr; gap: 50px; padding-bottom: 56px; }
.footer-brand { color: #fff; }
.footer-brand:hover { color: #fff; }
.footer-brand .brand-mark { background: #c7eed7; color: #10332a; box-shadow: 4px 4px 0 rgba(255,255,255,.12); }
.footer-brand .brand-copy small { color: #b4c8bf; }
.footer-intro p { max-width: 340px; margin: 23px 0 0; color: #aabeb4; font-size: 13px; line-height: 1.85; }
.footer-column { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; }
.footer-column h2 { margin: 0 0 9px; color: #fff; font-size: 13px; font-weight: 750; }
.footer-column a, .footer-bottom a { color: #afc7bb; font-size: 12px; text-decoration: none; }
.footer-column a:hover, .footer-bottom a:hover { color: #fff; text-decoration: none; }
.footer-bottom { display: flex; justify-content: space-between; gap: 20px; padding-block: 20px; border-top: 1px solid rgba(255,255,255,.11); color: #8da99b; font: 11px var(--font-mono); }

@media (max-width: 1199px) {
    .site-container { width: min(100% - 42px, 1320px); }
    .home-hero { gap: 28px; }
    .visual-orbit-one { right: -70px; }
    .tool-shell { grid-template-columns: 190px minmax(0, 1fr); gap: 22px; }
    .rail-link { gap: 7px; font-size: 12px; }
}
@media (max-width: 991px) {
    .site-nav { min-height: 72px; }
    .nav-menu-toggle { display: grid; }
    .site-nav .navbar-collapse { order: 4; width: 100%; flex-basis: 100%; padding: 12px 0 21px; border-top: 1px solid var(--line); margin-top: 12px; }
    .site-nav-links { margin: 0 0 15px; gap: 4px; }
    .header-search { width: 100%; }
    .home-hero { grid-template-columns: 1fr; padding-top: 70px; }
    .hero-copy { max-width: 700px; }
    .hero-visual { width: min(100%, 650px); margin-inline: auto; }
    .tool-grid { grid-template-columns: repeat(3, 1fr); }
    .tool-tile-featured { grid-column: span 2; }
    .workflow-inner { grid-template-columns: 1fr; gap: 35px; }
    .tool-shell { display: block; }
    .tool-rail { position: static; margin-bottom: 24px; }
    .rail-heading, .rail-utilities { display: none; }
    .rail-links { display: flex; gap: 8px; overflow-x: auto; padding: 0 0 7px; scrollbar-width: none; }
    .rail-links::-webkit-scrollbar { display: none; }
    .rail-link { flex: none; padding-inline: 13px; background: var(--surface); border-color: var(--line); }
    .rail-number, .rail-arrow { display: none; }
}
@media (max-width: 700px) {
    .site-container, .content-shell { width: min(100% - 32px, 1320px); }
    .brand-copy small { display: none; }
    .site-nav { min-height: 67px; }
    .home-hero { padding-block: 52px 50px; gap: 25px; min-height: 0; }
    .hero-copy h1 { margin-top: 21px; font-size: clamp(40px, 9vw, 60px); }
    .hero-description { font-size: 15px; }
    .hero-highlights { margin-top: 28px; }
    .hero-visual { min-height: 370px; }
    .visual-orbit-one { width: 410px; height: 410px; right: -30px; top: -20px; }
    .visual-orbit-two { width: 280px; height: 280px; right: 40px; top: 43px; }
    .floating-note { right: 0; bottom: -4px; }
    .tools-section { padding-block: 57px 76px; }
    .section-intro { align-items: flex-start; flex-direction: column; gap: 9px; }
    .tool-grid { grid-template-columns: repeat(2, 1fr); gap: 11px; }
    .tool-tile { min-height: 214px; padding: 18px; }
    .tool-tile-featured { grid-column: span 2; }
    .tile-body strong { font-size: 18px; }
    .workflow-inner { padding-block: 68px; }
    .workflow-steps { grid-template-columns: 1fr; gap: 16px; }
    .workflow-step { display: grid; grid-template-columns: 58px 1fr; column-gap: 10px; padding: 16px 0 0; }
    .workflow-step .step-index { grid-column: 1 / -1; }
    .workflow-step .step-icon { grid-row: span 2; margin: 14px 0 0; }
    .workflow-step h3 { margin: 15px 0 1px; }
    .workflow-step p { grid-column: 2; }
    .privacy-callout { grid-template-columns: 1fr; gap: 35px; padding-block: 72px 85px; }
    .callout-art { min-height: 225px; }
    .content-shell { padding-block: 35px 80px; }
    .tool-shell { padding-block: 20px 75px; }
    .tool-workspace .card-body, .tool-workspace .card-header { padding-inline: 16px; }
    .tool-workspace .nav-tabs { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
    .tool-workspace .nav-tabs::-webkit-scrollbar { display: none; }
    .tool-workspace .nav-tabs .nav-item { flex: none; }
    .footer-grid { grid-template-columns: 1fr 1fr; gap: 35px 20px; }
    .footer-intro { grid-column: 1 / -1; }
}
@media (max-width: 440px) {
    .site-container, .content-shell { width: min(100% - 26px, 1320px); }
    .brand-mark { width: 39px; height: 39px; }
    .brand-copy strong { font-size: 18px; }
    .theme-toggle, .nav-menu-toggle { width: 39px; height: 39px; }
    .hero-actions { align-items: stretch; flex-direction: column; }
    .button-primary { justify-content: space-between; }
    .preview-code { padding-inline: 13px; gap: 10px; }
    .preview-code pre, .preview-code code { font-size: 10px; }
    .floating-note { display: none; }
    .tool-grid { grid-template-columns: 1fr; }
    .tool-tile-featured { grid-column: auto; }
    .tool-tile { min-height: 195px; }
    .footer-grid { grid-template-columns: 1fr 1fr; }
    .footer-bottom { flex-direction: column; gap: 5px; }
}
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
