:root {
  color-scheme: light;
  --ink: #17211b;
  --muted: #66726b;
  --paper: #f6f2e9;
  --surface: #fffdf8;
  --line: #ded8cc;
  --orange: #e96b2c;
  --orange-dark: #a93d12;
  --green: #244e3b;
  font-family: "Noto Sans SC", "Microsoft YaHei", system-ui, sans-serif;
}

* { box-sizing: border-box; }
html { background: var(--paper); color: var(--ink); }
body { margin: 0; min-width: 0; line-height: 1.7; }
a { color: inherit; text-decoration-thickness: .08em; text-underline-offset: .18em; }

.site-header {
  align-items: center;
  border-bottom: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  margin: 0 auto;
  max-width: 1180px;
  padding: 18px clamp(18px, 4vw, 48px);
}
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--green); font-size: 1.1rem; font-weight: 800; text-decoration: none; }
.brand img { width: 46px; height: 46px; object-fit: contain; }
.app-link, .primary-action {
  background: var(--ink); border-radius: 999px; color: white; display: inline-flex;
  font-weight: 700; padding: 8px 18px; text-decoration: none;
}
.page-shell { margin: 0 auto; max-width: 1080px; padding: clamp(34px, 7vw, 90px) clamp(18px, 4vw, 48px); }
.hero { max-width: 820px; padding: clamp(20px, 5vw, 60px) 0 clamp(50px, 9vw, 110px); }
.hero h1, .page-intro h1 { font-family: Georgia, "Noto Serif SC", serif; font-size: clamp(2.25rem, 7vw, 5rem); letter-spacing: -.04em; line-height: 1.08; margin: 12px 0 22px; }
.hero p:last-child, .page-intro > p:last-child { color: var(--muted); font-size: clamp(1rem, 2vw, 1.22rem); max-width: 700px; }
.eyebrow, .card-kicker { color: var(--orange-dark); font-size: .78rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.section-heading { align-items: baseline; display: flex; justify-content: space-between; margin: 54px 0 18px; }
.section-heading h2 { font-size: clamp(1.45rem, 3vw, 2rem); margin: 0; }
.section-heading span { color: var(--muted); }
.card-grid { display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr)); }
.catalog-card { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; display: grid; gap: 10px; padding: 28px; text-decoration: none; transition: transform .15s ease, border-color .15s ease; }
.catalog-card:hover { border-color: var(--orange); transform: translateY(-2px); }
.catalog-card strong { font-size: 1.45rem; }
.catalog-card span:not(.card-kicker), .catalog-card small { color: var(--muted); }
.set-list, .question-list { list-style: none; margin: 0; padding: 0; }
.set-list li, .question-list li { border-top: 1px solid var(--line); }
.set-list li:last-child, .question-list li:last-child { border-bottom: 1px solid var(--line); }
.set-list a, .question-list a { align-items: center; display: grid; gap: 12px; grid-template-columns: 1fr auto; padding: 20px 4px; text-decoration: none; }
.question-list a { grid-template-columns: 42px minmax(0, 1fr) auto; }
.question-index { color: var(--orange-dark); font-variant-numeric: tabular-nums; }
.set-list span, .question-list small { color: var(--muted); }
.breadcrumbs { color: var(--muted); display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 44px; }
.page-intro { border-bottom: 1px solid var(--line); padding-bottom: 36px; }
.question-shell { max-width: 900px; }
.question-article { background: var(--surface); border: 1px solid var(--line); border-radius: 22px; padding: clamp(22px, 5vw, 54px); }
.question-title > :first-child { font-family: Georgia, "Noto Serif SC", serif; font-size: clamp(1.8rem, 5vw, 3.2rem); line-height: 1.25; margin-top: 0; }
.answer-panel, .extension-panel { border-top: 1px solid var(--line); margin-top: 40px; padding-top: 28px; }
.prose { overflow-wrap: anywhere; }
.prose pre { background: #17211b; border-radius: 12px; color: #f9f5ea; max-width: 100%; overflow-x: auto; padding: 18px; }
.prose code { font-family: "Cascadia Code", Consolas, monospace; }
.prose :not(pre) > code { background: #ece5d7; border-radius: 5px; padding: .1em .35em; }
.prose blockquote { border-left: 4px solid var(--orange); color: var(--muted); margin-left: 0; padding-left: 18px; }
.adjacent-navigation { display: grid; gap: 14px; grid-template-columns: repeat(2, minmax(0, 1fr)); margin-top: 24px; }
.adjacent-navigation a, .navigation-placeholder { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; display: grid; padding: 18px; text-decoration: none; }
.adjacent-navigation span { color: var(--muted); font-size: .85rem; }
.site-footer { border-top: 1px solid var(--line); color: var(--muted); margin: 0 auto; max-width: 1080px; padding: 28px clamp(18px, 4vw, 48px) 50px; }
.error-page { padding-top: 15vh; text-align: center; }
.error-code { color: var(--orange); font-size: clamp(4rem, 15vw, 9rem); font-weight: 900; line-height: 1; margin: 0; }
.error-page h1 { font-size: clamp(2rem, 6vw, 4rem); margin: 20px 0 8px; }
.error-page .primary-action { margin-top: 22px; }

@media (max-width: 620px) {
  .site-header { padding: 14px 18px; }
  .page-shell { padding-top: 30px; }
  .hero { padding-top: 18px; }
  .question-list a { align-items: start; grid-template-columns: 30px minmax(0, 1fr); }
  .question-list small { grid-column: 2; }
  .adjacent-navigation { grid-template-columns: 1fr; }
}
.legal-nav, .site-footer { display: flex; align-items: center; gap: 18px; }
.legal-nav > a:not(.app-link), .site-footer a { color: #52645a; font-weight: 700; text-decoration: none; }
.legal-shell { width: min(900px, calc(100% - 32px)); }
.legal-hero { padding: 50px 0 30px; border-bottom: 1px solid #dce4df; }
.legal-hero h1 { margin: 8px 0 18px; font-size: clamp(38px, 7vw, 64px); letter-spacing: -.045em; }
.legal-hero > p:last-child { max-width: 720px; color: #52645a; font-size: 17px; line-height: 1.8; }
.legal-hero dl { display: flex; gap: 30px; margin: 0 0 20px; }
.legal-hero dl div { display: grid; gap: 4px; }
.legal-hero dt { color: #78857d; font-size: 12px; font-weight: 800; letter-spacing: .08em; }
.legal-hero dd { margin: 0; font-variant-numeric: tabular-nums; font-weight: 800; }
.legal-document { padding: 20px 0 60px; }
.legal-document section { padding: 25px 0; border-bottom: 1px solid #e4e9e6; }
.legal-document h2 { margin: 0 0 13px; font-size: 22px; }
.legal-document p, .legal-document li { color: #46554d; line-height: 1.85; }
.legal-document ul { padding-left: 22px; }
.site-footer { justify-content: center; flex-wrap: wrap; }
@media (max-width: 600px) { .site-header { align-items: flex-start; }.legal-nav { align-items: flex-end; flex-direction: column; gap: 10px; }.legal-hero { padding-top: 34px; }.legal-hero dl { gap: 18px; } }
