:root {
  --bg: #f4f6fa;
  --surface: #ffffff;
  --surface-2: #eaeef5;
  --text: #111827;
  --muted: #5b6577;
  --line: #dbe1ea;
  --accent: #2453e6;
  --accent-ink: #ffffff;
  --accent-soft: #e2e9fd;
  --warn: #c98a07;
  --warn-soft: #fbf0d6;
  --bad: #d4483b;
  --bad-soft: #fbe3df;
  --shadow: 0 1px 2px rgba(17, 24, 39, .05), 0 8px 24px rgba(17, 24, 39, .07);
  --radius: 14px;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
  color-scheme: light;
}
:root[data-theme="dark"] {
  --bg: #0a0e17; --surface: #111827; --surface-2: #182033; --text: #e6eaf2; --muted: #8b95a9;
  --line: #243049; --accent: #5b8cff; --accent-ink: #050b1f; --accent-soft: #172a57;
  --warn: #f0b429; --warn-soft: #3a2e10; --bad: #ff6b5e; --bad-soft: #3d1915;
  --shadow: 0 1px 2px rgba(0,0,0,.3), 0 8px 24px rgba(0,0,0,.3); color-scheme: dark;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 76px; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font: 15px/1.65 -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
h1, h2, h3 { line-height: 1.2; margin: 0; }
h2 { font-size: 26px; font-weight: 900; letter-spacing: -.01em; }
.wrap { max-width: 1160px; margin: 0 auto; padding: 0 20px; }
.muted { color: var(--muted); }
.num { text-align: right; font-family: var(--mono); font-variant-numeric: tabular-nums; }

/* Topbar */
.topbar { position: sticky; top: 0; z-index: 20; background: color-mix(in srgb, var(--bg) 85%, transparent); backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.topbar-inner { display: flex; align-items: center; gap: 24px; height: 62px; }
.brand { display: flex; align-items: center; gap: 8px; font-weight: 900; font-size: 18px; }
.brand small { font-family: var(--mono); font-size: 11px; color: var(--muted); font-weight: 500; margin-top: 3px; }
.brand-mark { width: 28px; height: 28px; color: var(--accent); }
.nav { display: flex; gap: 4px; margin-left: 12px; }
.nav a { padding: 6px 12px; border-radius: 8px; color: var(--muted); font-weight: 500; font-size: 14px; }
.nav a:hover { color: var(--text); background: var(--surface-2); }
.nav a.active { color: var(--accent); background: var(--accent-soft); font-weight: 700; }
.topbar-actions { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.icon-btn { display: inline-grid; place-items: center; width: 36px; height: 36px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); color: var(--text); cursor: pointer; }
.menu-btn { display: none; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; border: 0; border-radius: 10px; padding: 11px 18px; font: inherit; font-weight: 700; cursor: pointer; transition: transform .1s, filter .15s; }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--accent); color: var(--accent-ink); }
.btn-primary:hover { filter: brightness(1.06); }
.btn-sm { padding: 7px 14px; font-size: 14px; }

/* Hero */
.hero { padding: 56px 0 32px; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 40px; align-items: start; }
.pill { display: inline-flex; align-items: center; gap: 8px; padding: 5px 12px; border-radius: 99px; background: var(--accent-soft); color: var(--accent); font-size: 13px; font-weight: 700; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: currentColor; display: inline-block; }
.dot.live { animation: pulse 1.6s infinite; }
@keyframes pulse { 0%,100% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 60%, transparent); } 50% { box-shadow: 0 0 0 6px transparent; } }
h1 { font-size: clamp(36px, 5.4vw, 60px); font-weight: 900; letter-spacing: -.02em; margin: 18px 0 16px; }
.hl { color: var(--accent); position: relative; }
.hl::after { content: ""; position: absolute; left: 0; right: 0; bottom: .06em; height: .18em; background: var(--accent); opacity: .2; border-radius: 4px; }
.lead { color: var(--muted); font-size: 17px; max-width: 34em; margin: 0 0 28px; }

.search { position: relative; display: flex; align-items: center; gap: 10px; max-width: 480px; padding: 0 16px; height: 52px; border-radius: 14px; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); color: var(--muted); }
.search:focus-within { border-color: var(--accent); }
.search input { flex: 1; border: 0; outline: 0; background: transparent; font: inherit; color: var(--text); font-size: 16px; }
.suggest { position: absolute; top: calc(100% + 6px); left: 0; right: 0; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow); overflow: hidden; display: none; z-index: 5; }
.suggest.show { display: block; }
.suggest button { display: flex; justify-content: space-between; width: 100%; padding: 10px 16px; border: 0; background: none; font: inherit; color: var(--text); cursor: pointer; text-align: left; }
.suggest button:hover, .suggest button.active { background: var(--surface-2); }

.overview { background: var(--surface); border: 1px solid var(--line); border-radius: 20px; padding: 22px; box-shadow: var(--shadow); }
.overview-head { display: flex; justify-content: space-between; align-items: baseline; font-weight: 700; margin-bottom: 12px; }
.overview-head small { font-weight: 400; font-size: 12px; }
.pergb { display: grid; gap: 4px; margin-bottom: 14px; }
.pg-row { display: grid; grid-template-columns: 8.5em 1fr 4.2em; align-items: center; gap: 10px; border: 0; background: none; padding: 5px 6px; margin: 0 -6px; border-radius: 8px; font: inherit; color: var(--text); cursor: pointer; text-align: left; }
.pg-row:hover { background: var(--surface-2); }
.pg-name { font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pg-track { height: 8px; border-radius: 99px; background: var(--surface-2); overflow: hidden; }
.pg-track i { display: block; height: 100%; border-radius: 99px; background: var(--accent); animation: grow .6s both cubic-bezier(.2,.8,.2,1); transform-origin: left; }
@keyframes grow { from { transform: scaleX(0); } }
.pg-val { font-family: var(--mono); font-size: 12px; color: var(--muted); text-align: right; }
@media (prefers-reduced-motion: reduce) { .pg-track i, .card { animation: none; } }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--line); padding-top: 16px; margin-top: 4px; text-align: center; }
.stats b { display: block; font-family: var(--mono); font-size: 22px; }
.stats span { color: var(--muted); font-size: 12px; }

/* Sections */
.section { padding: 48px 20px; }
.section-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; flex-wrap: wrap; margin-bottom: 20px; }
.section-head p { margin: 6px 0 0; }

.tabs { display: flex; gap: 4px; background: var(--surface-2); padding: 4px; border-radius: 12px; overflow-x: auto; }
.tabs button { border: 0; background: none; font: inherit; font-size: 14px; font-weight: 700; color: var(--muted); padding: 7px 14px; border-radius: 9px; cursor: pointer; white-space: nowrap; }
.tabs button[aria-selected="true"] { background: var(--surface); color: var(--text); box-shadow: var(--shadow); }

.board { display: grid; grid-template-columns: repeat(auto-fill, minmax(330px, 1fr)); gap: 14px; }
.card { position: relative; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; cursor: pointer; transition: border-color .15s, transform .15s; animation: rise .35s both; }
.card:hover { border-color: var(--accent); transform: translateY(-2px); }
@keyframes rise { from { opacity: 0; transform: translateY(6px); } }
.card-top { display: flex; gap: 14px; align-items: center; }
.rank { font-family: var(--mono); font-weight: 700; font-size: 13px; width: 30px; height: 30px; display: grid; place-items: center; border-radius: 8px; background: var(--surface-2); color: var(--muted); flex: none; }
.card:nth-child(1) .rank { background: var(--accent); color: var(--accent-ink); }
.card h3 { font-size: 17px; font-weight: 700; }
.meta { color: var(--muted); font-size: 13px; }
.score { margin-left: auto; text-align: right; }
.score b { font-family: var(--mono); font-size: 26px; line-height: 1; }
.score span { display: block; font-size: 11px; color: var(--muted); }
.kpis { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 14px 0 12px; }
.kpis div { background: var(--surface-2); border-radius: 10px; padding: 8px 10px; }
.kpis span { display: block; font-size: 11px; color: var(--muted); }
.kpis b { font-family: var(--mono); font-size: 15px; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tag { font-size: 12px; padding: 2px 8px; border-radius: 6px; background: var(--accent-soft); color: var(--accent); font-weight: 500; }
.pin { display: inline-block; vertical-align: 2px; margin-left: 4px; font-size: 11px; font-weight: 700; padding: 1px 7px; border-radius: 6px; background: var(--accent); color: var(--accent-ink); }
.card.pinned { border-color: var(--accent); }
.card .rank.rank-pin { background: var(--accent); color: var(--accent-ink); font-family: inherit; }
.card:nth-child(1):not(.pinned) .rank { background: var(--surface-2); color: var(--muted); }
.board-empty { display: grid; place-items: center; border: 1px dashed var(--line); border-radius: var(--radius); }
.tag.grey { background: var(--surface-2); color: var(--muted); }

.summary { color: var(--muted); font-size: 13.5px; line-height: 1.7; margin: 12px 0 0; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.summary.lg { font-size: 15px; -webkit-line-clamp: unset; display: block; margin-top: 10px; }
.status { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 700; }
.status.ok { color: var(--accent); }
.status.warn { color: var(--warn); }
.status.down { color: var(--bad); }
.status.pending { color: var(--muted); }
.score b.pending { font-size: 22px; }

/* Table */
.filters { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.filters select { font: inherit; font-size: 14px; padding: 7px 10px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); color: var(--text); }
.check { display: inline-flex; gap: 6px; align-items: center; font-size: 14px; color: var(--muted); cursor: pointer; }
.check input { accent-color: var(--accent); }
.table-wrap { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; min-width: 720px; }
.table th, .table td { padding: 12px 16px; text-align: left; border-bottom: 1px solid var(--line); white-space: nowrap; }
.table th.num, .table td.num { text-align: right; }
.table th { font-size: 12px; color: var(--muted); font-weight: 700; background: var(--surface-2); cursor: pointer; user-select: none; }
.table th[data-k]:hover { color: var(--text); }
.table th.sorted::after { content: " ↓"; color: var(--accent); }
.table th.sorted.asc::after { content: " ↑"; }
.table tbody tr { cursor: pointer; }
.table tbody tr:hover { background: var(--surface-2); }
.table tbody tr:last-child td { border-bottom: 0; }
.name-cell b { display: block; }
.name-cell > span { font-size: 12px; color: var(--muted); }
.bars { display: flex; gap: 2px; align-items: flex-end; height: 22px; }
.bars i { width: 5px; border-radius: 2px; background: var(--accent); }
.bars i.warn { background: var(--warn); }
.bars i.down { background: var(--bad); }
.empty { padding: 32px; text-align: center; color: var(--muted); }

/* Risk */
.risk-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 14px; }
.risk { border-radius: var(--radius); padding: 18px; border: 1px solid; cursor: pointer; }
.risk.down { background: var(--bad-soft); border-color: color-mix(in srgb, var(--bad) 30%, transparent); }
.risk.warn { background: var(--warn-soft); border-color: color-mix(in srgb, var(--warn) 30%, transparent); }
.risk h3 { font-size: 16px; display: flex; justify-content: space-between; align-items: center; }
.risk p { margin: 8px 0 0; font-size: 14px; }

/* Method */
.method-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-top: 20px; }
.method { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.m-num { font-family: var(--mono); font-weight: 700; font-size: 20px; color: var(--accent); }
.method h3 { font-size: 16px; margin: 6px 0 6px; }
.method p { margin: 0; color: var(--muted); font-size: 14px; }
.note { color: var(--muted); font-size: 13px; margin-top: 16px; }

/* FAQ */
.faq { margin-top: 20px; display: grid; gap: 10px; max-width: 820px; }
.faq details { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 14px 18px; }
.faq summary { font-weight: 700; cursor: pointer; list-style: none; display: flex; justify-content: space-between; }
.faq summary::after { content: "+"; color: var(--accent); font-family: var(--mono); }
.faq details[open] summary::after { content: "−"; }
.faq p { margin: 10px 0 0; color: var(--muted); }

/* Join */
.join { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; align-items: center; padding: 36px; border-radius: 22px; background: linear-gradient(135deg, var(--accent-soft), var(--surface)); border: 1px solid var(--line); }
.join p { color: var(--muted); margin: 10px 0 0; }
.join-form { display: grid; gap: 10px; }
.join-form input { font: inherit; padding: 12px 14px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); color: var(--text); }
.join-form input:focus { outline: 2px solid var(--accent); border-color: transparent; }

.footer { margin-top: 24px; border-top: 1px solid var(--line); background: var(--surface); font-size: 14px; }
.footer-top { display: grid; grid-template-columns: 1.6fr repeat(3, 1fr); gap: 32px; padding: 44px 0 28px; }
.footer-brand p { margin: 12px 0 0; color: var(--muted); max-width: 26em; line-height: 1.7; }
.footer-col { display: flex; flex-direction: column; gap: 10px; }
.footer-col h4 { margin: 0 0 4px; font-size: 13px; color: var(--text); }
.footer-col a { color: var(--muted); width: fit-content; }
.footer-col a:hover { color: var(--accent); }
.footer-legal { margin: 0; padding: 18px 0; border-top: 1px solid var(--line); color: var(--muted); font-size: 12px; line-height: 1.8; }
.footer-bottom { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 0 0 24px; color: var(--muted); font-size: 12px; }
.footer-bottom a:hover { color: var(--accent); }

/* Dialog */
dialog { border: 0; padding: 0; background: transparent; max-width: 640px; width: calc(100% - 32px); color: var(--text); }
dialog::backdrop { background: rgba(0, 0, 0, .45); backdrop-filter: blur(3px); }
.dlg { position: relative; background: var(--surface); border-radius: 20px; padding: 26px; border: 1px solid var(--line); }
.dlg-close { position: absolute; top: 16px; right: 16px; }
.dlg h3 { font-size: 22px; }
.chart { width: 100%; height: 160px; margin: 18px 0 8px; }
.chart .area { fill: var(--accent); opacity: .12; }
.chart .line { fill: none; stroke: var(--accent); stroke-width: 2; }
.chart .grid { stroke: var(--line); }
.chart text { fill: var(--muted); font: 10px var(--mono); }
.plans { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 10px; margin: 18px 0 14px; }
.plan { background: var(--surface-2); border-radius: 12px; padding: 12px 14px; }
.plan span { display: block; font-size: 12px; color: var(--muted); }
.plan b { font-family: var(--mono); font-size: 22px; }
.plan small { font-size: 12px; color: var(--muted); font-weight: 500; }
.plan em { display: block; font-style: normal; font-size: 12px; color: var(--muted); }
.dl { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px 24px; margin-top: 16px; font-size: 14px; }
.dl div { display: flex; justify-content: space-between; border-bottom: 1px dashed var(--line); padding-bottom: 6px; }
.dl span { color: var(--muted); }

.toast { position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 20px); background: var(--text); color: var(--bg); padding: 10px 18px; border-radius: 10px; font-weight: 500; opacity: 0; pointer-events: none; transition: .25s; z-index: 50; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* Posts */
.more-link { color: var(--accent); font-weight: 700; font-size: 14px; }
.post-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.post-card { display: flex; flex-direction: column; gap: 8px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; transition: border-color .15s, transform .15s; }
.post-card:hover { border-color: var(--accent); transform: translateY(-2px); }
.post-card h3 { font-size: 17px; line-height: 1.45; }
.post-card p { margin: 0; color: var(--muted); font-size: 14px; flex: 1; }
.post-cat { align-self: flex-start; font-size: 12px; font-weight: 700; color: var(--accent); background: var(--accent-soft); padding: 2px 8px; border-radius: 6px; }
.post-meta { font-size: 12px; color: var(--muted); font-family: var(--mono); }

.page-head { margin-bottom: 20px; }
.page-head p { margin: 8px 0 0; }
.page-title { font-size: clamp(30px, 4vw, 40px); font-weight: 900; letter-spacing: -.01em; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 20px; }
.chip { border: 1px solid var(--line); background: var(--surface); color: var(--muted); font: inherit; font-size: 14px; font-weight: 500; padding: 6px 14px; border-radius: 99px; cursor: pointer; }
.chip:hover { color: var(--text); }
.chip[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); font-weight: 700; }

/* Article */
.article-page { padding-top: 24px; padding-bottom: 56px; }
.crumbs { display: flex; flex-wrap: wrap; gap: 8px; font-size: 13px; color: var(--muted); margin-bottom: 20px; }
.crumbs a:hover { color: var(--accent); }
.article-layout { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 40px; align-items: start; }
.article-main { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 36px 40px 40px; min-width: 0; }
.article-head { padding-bottom: 22px; margin-bottom: 6px; border-bottom: 1px solid var(--line); }
.article-head h1 { font-size: clamp(24px, 3vw, 32px); font-weight: 900; line-height: 1.35; margin: 0; letter-spacing: -.01em; }
.article-lead { margin: 14px 0 0; color: var(--muted); font-size: 15.5px; line-height: 1.75; }
.article-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 16px; font-size: 13px; color: var(--muted); font-family: var(--mono); }
.article-meta .post-cat { font-family: inherit; }

.prose { font-size: 15.5px; line-height: 1.8; color: var(--text); }
.prose > :first-child { margin-top: 22px; }
.prose h2 { position: relative; font-size: 21px; font-weight: 800; margin: 38px 0 14px; padding: 0 0 10px 14px; border-bottom: 1px solid var(--line); scroll-margin-top: 84px; }
.prose h2::before { content: ""; position: absolute; left: 0; top: 4px; bottom: 14px; width: 4px; border-radius: 2px; background: var(--accent); }
.prose h3 { font-size: 17px; font-weight: 700; margin: 26px 0 10px; scroll-margin-top: 84px; }
.prose p, .prose ul, .prose ol { margin: 0 0 14px; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li { margin: 6px 0; }
.prose li::marker { color: var(--accent); }
.prose a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.prose strong { font-weight: 700; }
.prose blockquote { margin: 18px 0; padding: 12px 16px; border: 1px solid color-mix(in srgb, var(--accent) 25%, transparent); background: var(--accent-soft); border-radius: 12px; font-size: 14.5px; }
.prose blockquote p { margin: 0; }
.prose code { font-family: var(--mono); font-size: .86em; background: var(--surface-2); padding: 2px 6px; border-radius: 5px; }
.prose pre { background: var(--surface-2); padding: 14px 16px; border-radius: 10px; overflow-x: auto; }
.prose pre code { background: none; padding: 0; }
.table-scroll { overflow-x: auto; margin: 4px 0 18px; border: 1px solid var(--line); border-radius: 12px; }
.prose table { width: 100%; border-collapse: collapse; font-size: 14px; }
.prose th, .prose td { padding: 10px 14px; border-bottom: 1px solid var(--line); text-align: left; white-space: nowrap; }
.prose tr:last-child td { border-bottom: 0; }
.prose th { background: var(--surface-2); font-size: 13px; font-weight: 700; color: var(--muted); }
.prose tbody tr:hover { background: var(--surface-2); }

.article-side { position: sticky; top: 84px; display: grid; gap: 16px; }
.side-card { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 18px 18px 16px; }
.side-card h4 { margin: 0 0 12px; font-size: 15px; }
.side-dl { margin: 0; display: grid; gap: 8px; font-size: 13.5px; }
.side-dl div { display: flex; justify-content: space-between; gap: 12px; border-bottom: 1px dashed var(--line); padding-bottom: 7px; }
.side-dl dt { color: var(--muted); flex: none; }
.side-dl dd { margin: 0; font-weight: 700; text-align: right; }
.side-dl code { font-family: var(--mono); color: var(--accent); }
.side-btn { width: 100%; margin-top: 14px; }
.toc { display: flex; flex-direction: column; gap: 2px; max-height: calc(100vh - 260px); overflow-y: auto; }
.toc a { font-size: 13.5px; color: var(--muted); padding: 6px 10px; border-left: 2px solid var(--line); line-height: 1.5; }
.toc a.sub { padding-left: 22px; font-size: 13px; }
.toc a:hover { color: var(--text); }
.toc a.active { color: var(--accent); border-left-color: var(--accent); font-weight: 700; background: var(--accent-soft); border-radius: 0 6px 6px 0; }
.related { margin-top: 40px; }
.related h2 { font-size: 20px; margin-bottom: 14px; }
.post-nav { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 24px; }
.post-nav a { display: flex; flex-direction: column; gap: 4px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 18px; font-weight: 700; }
.post-nav a:hover { border-color: var(--accent); }
.post-nav a span { font-size: 12px; color: var(--muted); font-weight: 500; }
.post-nav a.next { text-align: right; grid-column: 2; }

/* Clients */
.client-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.client { display: flex; flex-direction: column; gap: 10px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.client-top { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.client h3 { font-size: 17px; }
.client p { margin: 0; color: var(--muted); font-size: 14px; flex: 1; }
.btn-ghost { background: var(--accent-soft); color: var(--accent); margin-top: 4px; }
.btn-ghost:hover { filter: brightness(.97); }
.dlg-actions { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 10px; margin-top: 18px; }
.dlg-actions:empty { display: none; }
.aff-note { font-size: 12px; color: var(--muted); margin: 8px 0 0; }
.coupon { margin: 14px 0 0; font-size: 14px; }
.coupon code { font-family: var(--mono); font-weight: 700; color: var(--accent); background: var(--accent-soft); padding: 2px 8px; border-radius: 6px; }
.plan.once { background: transparent; border: 1px dashed var(--line); }

/* Files */
.file-ext { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 12px; background: var(--accent-soft); color: var(--accent); font-family: var(--mono); font-size: 11px; font-weight: 700; }

/* Home: hero */
.eyebrow { display: inline-flex; align-items: center; gap: 8px; font-size: 12px; font-weight: 700; letter-spacing: .08em; color: var(--accent); }
.eyebrow::before { content: ""; width: 22px; height: 2px; background: var(--accent); border-radius: 2px; }
.hero-main h1 { margin-top: 14px; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 28px; }
.featured { display: block; background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 22px 24px; transition: border-color .15s, transform .15s; }
.featured:hover { border-color: var(--accent); transform: translateY(-2px); }
.featured h3 { font-size: 20px; line-height: 1.4; margin: 10px 0 8px; }
.featured p { margin: 0 0 10px; color: var(--muted); font-size: 14px; }
.feed-card { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 20px 22px; }
.feed-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
.feed { list-style: none; margin: 0; padding: 0; }
.feed li + li { border-top: 1px dashed var(--line); }
.feed a { display: block; padding: 12px 0; }
.feed a:hover .feed-title { color: var(--accent); }
.feed-meta { display: flex; align-items: center; gap: 8px; margin-bottom: 4px; }
.feed-meta time { font-family: var(--mono); font-size: 12px; color: var(--muted); }
.feed-tag { font-size: 11px; font-weight: 700; color: var(--accent); background: var(--accent-soft); padding: 1px 7px; border-radius: 5px; }
.feed-title { display: block; font-size: 14.5px; font-weight: 500; line-height: 1.5; }

/* Home: search band */
.search-band { background: var(--surface); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 26px 0; }
.search-band-inner { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 28px; align-items: center; }
.search-band h2 { font-size: 20px; white-space: nowrap; }
.search-box .search { max-width: none; box-shadow: none; background: var(--bg); }
.hot { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; margin-top: 12px; font-size: 13px; }
.hot-chip { border: 1px solid var(--line); background: transparent; color: var(--muted); font: inherit; font-size: 13px; padding: 3px 10px; border-radius: 99px; cursor: pointer; }
.hot-chip:hover { color: var(--accent); border-color: var(--accent); }

/* Home: start here */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.step { display: flex; flex-direction: column; gap: 6px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; transition: border-color .15s, transform .15s; }
.step:hover { border-color: var(--accent); transform: translateY(-2px); }
.step-num { font-family: var(--mono); font-size: 28px; font-weight: 700; color: var(--accent); line-height: 1; }
.step h3 { font-size: 17px; margin-top: 8px; }
.step p { margin: 0; color: var(--muted); font-size: 14px; flex: 1; }
.step-go { font-size: 13px; font-weight: 700; color: var(--accent); margin-top: 6px; }

/* Home: data band */
.data-band { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); gap: 20px; align-items: stretch; padding-top: 8px; }
.stats-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.stats-grid div { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; display: flex; flex-direction: column; justify-content: center; }
.stats-grid b { font-family: var(--mono); font-size: 28px; color: var(--accent); line-height: 1.1; }
.stats-grid span { color: var(--muted); font-size: 13px; margin-top: 6px; }

/* Home: ranking list */
.rank-list { display: grid; gap: 12px; }
.rank-row { display: grid; grid-template-columns: 72px minmax(0, 1fr) auto; gap: 20px; align-items: start; background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 22px 24px; cursor: pointer; transition: border-color .15s; animation: rise .35s both; }
.rank-row:hover { border-color: var(--accent); }
.rank-row.pinned { border-color: color-mix(in srgb, var(--accent) 45%, var(--line)); }
.rank-num { font-family: var(--mono); font-size: 40px; font-weight: 700; line-height: 1; color: var(--accent); letter-spacing: -.02em; }
.rank-num.is-pin { font-family: inherit; font-size: 30px; display: grid; place-items: center; width: 56px; height: 56px; border-radius: 14px; background: var(--accent); color: var(--accent-ink); }
.rank-title { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px; }
.rank-title h3 { font-size: 20px; }
.rank-title .muted { font-size: 13px; }
.rank-sum { margin: 8px 0 14px; color: var(--muted); font-size: 14px; line-height: 1.7; }
.rank-facts { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px 18px; margin: 0 0 14px; padding: 14px 16px; background: var(--surface-2); border-radius: 12px; }
.rank-facts div { min-width: 0; }
.rank-facts dt { font-size: 12px; color: var(--muted); }
.rank-facts dd { margin: 2px 0 0; font-size: 14px; font-weight: 700; }
.rank-actions { display: flex; flex-direction: column; align-items: flex-end; gap: 10px; white-space: nowrap; }
.rank-review { font-size: 13px; color: var(--muted); text-decoration: underline; text-underline-offset: 3px; }
.rank-review:hover { color: var(--accent); }

/* Home: tools */
.tool-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.tool { display: flex; flex-direction: column; gap: 6px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; transition: border-color .15s, transform .15s; }
.tool:hover { border-color: var(--accent); transform: translateY(-2px); }
.tool-tag { align-self: flex-start; font-size: 11px; font-weight: 700; color: var(--accent); background: var(--accent-soft); padding: 2px 8px; border-radius: 6px; }
.tool h3 { font-size: 16px; margin-top: 4px; }
.tool p { margin: 0; color: var(--muted); font-size: 13.5px; }

/* Clients page */
.page-intro { max-width: 46em; line-height: 1.75; }
.cl-section { margin-top: 36px; }
.cl-section .section-head { margin-bottom: 14px; align-items: center; }
.cl-section .section-head .chips { margin: 0; }
.cl-h2 { position: relative; font-size: 21px; padding-left: 14px; margin-bottom: 14px; }
.cl-h2::before { content: ""; position: absolute; left: 0; top: 3px; bottom: 3px; width: 4px; border-radius: 2px; background: var(--accent); }
.cl-section .section-head .cl-h2 { margin-bottom: 0; }
.pick-table { min-width: 640px; }
.pick-table td { vertical-align: top; }
.pick-table td.pick-why { white-space: normal; min-width: 240px; line-height: 1.6; }
.pick-table a { color: var(--accent); font-weight: 700; }
.pick-table a:hover { text-decoration: underline; text-underline-offset: 3px; }
.pick-table tbody tr { cursor: default; }
.howto { background: var(--accent-soft); border: 1px solid color-mix(in srgb, var(--accent) 25%, transparent); border-radius: 16px; padding: 22px 26px; }
.howto h3 { font-size: 17px; margin-bottom: 10px; }
.howto ol { margin: 0; padding-left: 1.4em; display: grid; gap: 6px; line-height: 1.7; }
.howto li::marker { color: var(--accent); font-weight: 700; }
.howto-tip { margin: 12px 0 0; font-size: 13.5px; color: var(--muted); }
.client-dl { margin: 0; display: grid; gap: 6px; font-size: 13px; }
.client-dl div { display: flex; justify-content: space-between; gap: 10px; border-bottom: 1px dashed var(--line); padding-bottom: 6px; }
.client-dl dt { color: var(--muted); }
.client-dl dd { margin: 0; font-weight: 700; text-align: right; }
.client { scroll-margin-top: 90px; }
.client.flash { animation: flash 1.4s ease-out; }
@keyframes flash { 0%, 30% { border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); } 100% { box-shadow: 0 0 0 0 transparent; } }
.next-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.next-card { display: flex; flex-direction: column; gap: 6px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; transition: border-color .15s, transform .15s; }
.next-card:hover { border-color: var(--accent); transform: translateY(-2px); }
.next-card span { color: var(--accent); font-size: 13.5px; }

/* Downloads page */
.seg { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; padding: 6px; background: var(--surface-2); border-radius: 14px; margin-bottom: 16px; }
.seg button { border: 0; background: none; font: inherit; font-size: 15px; font-weight: 700; color: var(--muted); padding: 11px 8px; border-radius: 10px; cursor: pointer; white-space: nowrap; }
.seg button:hover { color: var(--text); }
.seg button[aria-selected="true"] { background: var(--surface); color: var(--accent); box-shadow: var(--shadow); }
.dl-list { display: grid; gap: 12px; }
.dl-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 16px 24px; align-items: center; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 20px 24px; }
.dl-row:has(.file-ext) { grid-template-columns: auto minmax(0, 1fr) auto; }
.dl-title { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.dl-title h3 { font-size: 18px; overflow-wrap: anywhere; }
.dl-title .pin { margin-left: 0; }
.dl-badge { font-size: 12px; color: var(--muted); border: 1px solid var(--line); padding: 1px 8px; border-radius: 6px; }
.dl-desc { margin: 6px 0 0; color: var(--muted); font-size: 14px; }
.dl-meta { margin: 8px 0 0; font-family: var(--mono); font-size: 12px; color: var(--muted); overflow-wrap: anywhere; }
.dl-actions { display: flex; flex-direction: column; align-items: flex-end; gap: 10px; }
.dl-actions .btn { white-space: nowrap; }
.dl-guide { font-size: 13px; color: var(--accent); font-weight: 700; white-space: nowrap; }
.dl-guide:hover { text-decoration: underline; text-underline-offset: 3px; }
.warn-box { background: var(--warn-soft); border: 1px solid color-mix(in srgb, var(--warn) 35%, transparent); border-radius: 16px; padding: 18px 22px; }
.warn-box h3 { font-size: 16px; color: var(--warn); margin-bottom: 6px; }
.warn-box p { margin: 0; font-size: 14px; line-height: 1.75; }
.text-link { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }

/* FAQ page */
.first-step { background: var(--accent-soft); border: 1px solid color-mix(in srgb, var(--accent) 25%, transparent); border-radius: 16px; padding: 18px 22px; font-size: 14.5px; line-height: 1.75; }
.first-step ol { margin: 6px 0 8px; padding-left: 1.4em; }
.first-step li::marker { color: var(--accent); font-weight: 700; }
.first-step > span { color: var(--muted); font-size: 13.5px; }
.faq-tools { display: grid; gap: 12px; margin: 22px 0 8px; position: sticky; top: 62px; z-index: 5; background: var(--bg); padding: 10px 0; }
.faq-search { max-width: none; box-shadow: none; height: 48px; }
.jump { display: flex; flex-wrap: wrap; gap: 8px; }
.jump .chip { display: inline-flex; align-items: center; gap: 6px; }
.jump .chip:hover { border-color: var(--accent); color: var(--accent); }
.jump-n { font-family: var(--mono); font-size: 11px; background: var(--surface-2); color: var(--muted); padding: 0 6px; border-radius: 99px; }
.faq-cat { margin-top: 32px; scroll-margin-top: 200px; }
.faq-cat-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; border-bottom: 1px solid var(--line); padding-bottom: 12px; }
.faq-cat-head .cl-h2 { margin-bottom: 4px; }
.faq-cat-head p { margin: 0; font-size: 14px; }
.faq-count { font-family: var(--mono); font-size: 12px; color: var(--muted); white-space: nowrap; padding-top: 6px; }
.faq-start { margin: 12px 0 0; font-size: 14px; }
.faq-cat .faq { max-width: none; margin-top: 14px; }
.faq details p { line-height: 1.8; }
.faq-more { display: inline-block; margin-top: 10px; font-size: 13.5px; font-weight: 700; color: var(--accent); }
.faq-more:hover { text-decoration: underline; text-underline-offset: 3px; }

/* 404 */
.notfound { padding-top: 56px; padding-bottom: 72px; }
.notfound-code { font-family: var(--mono); font-size: 64px; font-weight: 700; color: var(--accent); line-height: 1; }
.notfound .page-title { margin-top: 12px; }
.notfound .next-grid { margin-top: 24px; }

/* Submit page */
.join-cta { display: flex; flex-wrap: wrap; gap: 10px; justify-content: flex-end; }
.submit-layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 32px; align-items: start; }
.seg.seg-2 { grid-template-columns: repeat(2, 1fr); max-width: 420px; }
.submit-form { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 8px 28px 28px; }
.submit-form fieldset { border: 0; margin: 0; padding: 20px 0 4px; border-bottom: 1px solid var(--line); display: grid; gap: 14px; }
.submit-form fieldset:last-of-type { border-bottom: 0; }
.submit-form legend { font-weight: 800; font-size: 16px; padding: 0; margin-bottom: 4px; }
.submit-form label { display: grid; gap: 6px; font-size: 14px; font-weight: 700; }
.submit-form label em { color: var(--bad); font-style: normal; }
.submit-form input, .submit-form textarea, .submit-form select { font: inherit; font-weight: 400; font-size: 15px; padding: 11px 13px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); color: var(--text); width: 100%; }
.submit-form textarea { resize: vertical; line-height: 1.6; }
.submit-form input:focus, .submit-form textarea:focus, .submit-form select:focus { outline: 2px solid var(--accent); border-color: transparent; }
.submit-form small { font-weight: 400; color: var(--muted); font-size: 12px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.submit-btn { width: 100%; margin-top: 18px; padding: 13px; font-size: 16px; }
.submit-btn:disabled { opacity: .6; cursor: wait; }
.form-msg { margin: 10px 0 0; font-size: 14px; min-height: 1.4em; text-align: center; }
.form-msg.err { color: var(--bad); }
.submit-done { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 40px 28px; text-align: center; }
.submit-done .hero-cta { justify-content: center; margin: 18px 0 0; }
.done-icon { display: inline-grid; place-items: center; width: 56px; height: 56px; border-radius: 50%; background: var(--accent); color: var(--accent-ink); font-size: 28px; font-weight: 700; }
.submit-done h2 { margin: 14px 0 8px; }
.submit-side { position: sticky; top: 84px; display: grid; gap: 16px; }
.flow { margin: 0; padding-left: 1.3em; display: grid; gap: 12px; }
.flow li::marker { color: var(--accent); font-weight: 700; }
.flow b { display: block; font-size: 14px; }
.flow span { font-size: 13px; color: var(--muted); }
.side-list { margin: 0; padding-left: 1.2em; display: grid; gap: 8px; font-size: 13.5px; color: var(--muted); line-height: 1.6; }

/* Responsive */
@media (max-width: 960px) {
  .hero-grid { grid-template-columns: 1fr; gap: 32px; }
  .method-grid, .post-grid, .client-grid, .tool-grid { grid-template-columns: repeat(2, 1fr); }
  .data-band { grid-template-columns: 1fr; }
  .next-grid { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: 1fr; }
  .join { grid-template-columns: 1fr; padding: 24px; }
}
@media (max-width: 1024px) {
  .submit-layout { grid-template-columns: 1fr; }
  .submit-side { position: static; }
  .article-layout { grid-template-columns: 1fr; gap: 16px; }
  .article-side { position: static; order: -1; }
  .toc-card { display: none; }
  .nav { display: none; position: absolute; top: 62px; left: 0; right: 0; flex-direction: column; background: var(--surface); border-bottom: 1px solid var(--line); padding: 8px 16px 16px; margin: 0; box-shadow: var(--shadow); }
  .nav.open { display: flex; }
  .nav a { padding: 10px 12px; font-size: 15px; }
  .menu-btn { display: inline-grid; }
}
@media (max-width: 760px) {
  .wrap { padding: 0 16px; }
  .section { padding: 36px 16px; }
  .brand small { display: none; }
  .board, .risk-grid { grid-template-columns: 1fr; }
  .method-grid, .post-grid, .client-grid { grid-template-columns: 1fr; }
  .search-band-inner { grid-template-columns: 1fr; gap: 12px; }
  .next-grid { grid-template-columns: 1fr; }
  .submit-form { padding: 4px 18px 22px; }
  .form-row { grid-template-columns: 1fr; }
  .join-cta { justify-content: flex-start; }
  .faq-tools { position: static; padding: 0; }
  .faq-cat { scroll-margin-top: 80px; }
  .seg { grid-template-columns: repeat(3, 1fr); }
  .seg button { font-size: 14px; padding: 9px 4px; }
  .dl-row, .dl-row:has(.file-ext) { grid-template-columns: 1fr; padding: 18px; }
  .dl-row .file-ext { display: none; }
  .dl-actions { flex-direction: row; justify-content: space-between; align-items: center; }
  .howto { padding: 18px; }
  .pick-wrap { border: 0; background: none; overflow: visible; }
  .pick-table { min-width: 0; display: block; }
  .pick-table thead { display: none; }
  .pick-table tbody { display: grid; gap: 10px; }
  .pick-table tr { display: grid; gap: 8px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 14px 16px; }
  .pick-table td { display: grid; grid-template-columns: 4.5em minmax(0, 1fr); gap: 12px; border: 0; padding: 0; white-space: normal; }
  .pick-table td::before { content: attr(data-label); color: var(--muted); font-size: 12px; padding-top: 2px; }
  .pick-table td.pick-why { min-width: 0; }
  .rank-row { grid-template-columns: 1fr; gap: 12px; padding: 18px; }
  .rank-num { font-size: 30px; }
  .rank-num.is-pin { width: 44px; height: 44px; font-size: 22px; }
  .rank-actions { flex-direction: row; justify-content: space-between; align-items: center; }
  .rank-facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .post-nav { grid-template-columns: 1fr; }
  .article-main { padding: 22px 18px 26px; border-radius: 14px; }
  .prose { font-size: 15px; }
  .prose h2 { font-size: 19px; }
  .footer-top { grid-template-columns: repeat(3, 1fr); gap: 24px 16px; padding-top: 32px; }
  .footer-brand { grid-column: 1 / -1; }
  .post-nav a.next { grid-column: auto; }
      .dl { grid-template-columns: 1fr; }
  .hero { padding-top: 36px; }
}
[hidden] { display: none !important; }
