:root {
  color-scheme: light dark;
  --paper: #f6f8f6;
  --ink: #162521;
  --muted: #435b55;
  --line: #cad6d0;
  --surface: #e9f1ed;
  --accent: #076753;
  --signal: #a35020;
  font-family: "Segoe UI", "Microsoft YaHei", "PingFang SC", sans-serif;
  letter-spacing: 0;
}
@media (prefers-color-scheme: dark) {
  :root { --paper: #111a18; --ink: #e6efeb; --muted: #afc1b9; --line: #3a4e47; --surface: #1d2c27; --accent: #85e9ca; --signal: #f0ae78; }
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--paper); color: var(--ink); line-height: 1.65; }
h1, h2, h3, p, ul { margin: 0; }
a { color: var(--accent); text-underline-offset: 4px; }
a:hover { color: var(--signal); }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
[hidden] { display: none !important; }
.frame { width: min(1080px, calc(100% - 64px)); margin-inline: auto; }
.top { border-bottom: 1px solid var(--line); }
.top-inner, .brand, nav, .access, .footer, .footer div, .detail-actions { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.top-inner, .footer { justify-content: space-between; padding-block: 15px; }
.brand { color: var(--ink); gap: 10px; font-weight: 700; text-decoration: none; }
.mark { display: block; }
nav a, .footer a, .access a { font-size: 14px; }
.intro { display: flex; justify-content: space-between; gap: 20px; align-items: end; padding-block: 42px 28px; }
.kicker { color: var(--accent); font-size: 13px; font-weight: 700; margin-bottom: 5px; }
h1 { font-size: 46px; line-height: 1.17; }
h2 { font-size: 22px; line-height: 1.35; }
h3 { font-size: 16px; }
.lead { color: var(--muted); font-size: 17px; margin-top: 12px; }
.access { color: var(--muted); gap: 8px; font-size: 14px; padding-bottom: 2px; }
.access a { margin-left: 8px; }
.status-dot { background: var(--accent); border-radius: 50%; width: 8px; height: 8px; }
.rules { border-block: 1px solid var(--line); display: grid; grid-template-columns: 180px 1fr; padding: 22px 0; gap: 16px; }
.rules p { max-width: 740px; font-size: 15px; }
.rules p + p { margin-top: 8px; color: var(--muted); }
.handoff { margin-top: 13px; padding: 10px 12px; display: flex; align-items: center; gap: 12px; background: var(--surface); border-radius: 5px; }
code { font-family: "Cascadia Mono", Consolas, monospace; overflow-wrap: anywhere; color: var(--muted); }
.handoff code { font-size: 13px; flex: 1; }
button { cursor: pointer; background: transparent; border: 1px solid var(--line); border-radius: 5px; color: var(--accent); }
#copy { display: grid; place-items: center; flex: 0 0 36px; height: 36px; }
#copy:hover { background: var(--paper); }
.catalog { padding-block: 25px 36px; }
.catalog-top { display: flex; align-items: end; justify-content: space-between; gap: 16px; }
#result-count, .entry-note { font-size: 13px; color: var(--muted); }
.filters { display: flex; gap: 8px; }
input, select { height: 42px; background: var(--surface); color: var(--ink); border: 1px solid var(--line); border-radius: 5px; padding-inline: 10px; font: inherit; font-size: 14px; }
input { width: 240px; min-width: 0; }
input::placeholder { color: var(--muted); }
.group { margin-top: 21px; }
.group h3 { padding-bottom: 8px; border-bottom: 1px solid var(--line); }
.group ul { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 24px; padding: 0; list-style: none; }
.entry { padding: 12px 0 11px; border-bottom: 1px solid var(--line); }
.entry a { display: grid; grid-template-columns: minmax(0, 1fr) auto 16px; gap: 8px; align-items: start; text-decoration: none; }
.entry a:hover strong { text-decoration: underline; }
.entry strong, .entry code { display: block; }
.entry code, .entry p { font-size: 13px; }
.entry p { margin-top: 5px; color: var(--muted); }
.arrow { text-align: right; }
#empty { color: var(--muted); padding: 26px 0; }
.footer { border-top: 1px solid var(--line); color: var(--muted); font-size: 14px; }
.detail { max-width: 820px; padding-block: 25px 40px; }
.detail .back { display: inline-block; margin-bottom: 25px; }
.detail h1 { margin-bottom: 8px; }
.detail-actions { margin-top: 18px; }
.detail section { margin-top: 25px; border-top: 1px solid var(--line); padding-top: 16px; }
.detail section p { margin-top: 8px; }
pre { white-space: pre-wrap; overflow-wrap: anywhere; background: var(--surface); border-radius: 5px; padding: 16px; }
.sr-only { position: absolute; clip-path: inset(50%); width: 1px; height: 1px; white-space: nowrap; overflow: hidden; }
@media (max-width: 680px) {
  .frame { width: calc(100% - 36px); }
  .top-inner { gap: 7px; }
  nav { gap: 13px; }
  .intro, .catalog-top { flex-direction: column; align-items: stretch; }
  .intro { padding-block: 27px 20px; }
  h1 { font-size: 34px; overflow-wrap: anywhere; }
  .rules { grid-template-columns: 1fr; gap: 8px; }
  .group ul { grid-template-columns: 1fr; }
  input { flex: 1; width: 100%; }
  select { max-width: 44%; }
}
