:root {
  color-scheme: light;
  --paper: #fffef1;
  --ink: #111214;
  --muted: #62666d;
  --line: rgba(17, 18, 20, 0.18);
  --blue: #0071d4;
  --blue-dark: #005cad;
  --cyan: #00b7ff;
  font-family: "Avenir Next", Avenir, ui-sans-serif, system-ui, -apple-system, sans-serif;
  font-synthesis: none;
}

* { box-sizing: border-box; }

html { background: var(--paper); }

body {
  min-height: 100vh;
  margin: 0;
  background: var(--paper);
  color: var(--ink);
}

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

button, a { -webkit-tap-highlight-color: transparent; }

.site-header,
#role-hub,
footer {
  width: min(1240px, calc(100% - 64px));
  margin-inline: auto;
}

.site-header {
  display: flex;
  min-height: 88px;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  font-size: 0.92rem;
  font-weight: 650;
  letter-spacing: 0.01em;
}

.brand img { border-radius: 8px; }

nav a,
footer a,
.back-link {
  color: var(--muted);
  font-size: 0.86rem;
}

nav {
  display: inline-flex;
  align-items: center;
  gap: 18px;
}

nav a:hover,
footer a:hover,
.back-link:hover { color: var(--blue); }

.hero {
  display: grid;
  min-height: 500px;
  align-content: end;
  grid-template-columns: minmax(0, 3fr) minmax(260px, 1fr);
  gap: 40px;
  padding: 72px 0 64px;
  border-bottom: 1px solid var(--line);
}

.home-features {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 34px;
  padding: 58px 0 62px;
  border-bottom: 1px solid var(--line);
}

.feature-card {
  display: grid;
  gap: 12px;
  align-content: start;
  min-width: 0;
}

.feature-card h2 {
  margin: 0;
  color: #242629;
  font-size: clamp(1.35rem, 2.4vw, 1.7rem);
  font-weight: 560;
  line-height: 1.08;
  letter-spacing: 0;
  overflow-wrap: anywhere;
}

.feature-card p:not(.eyebrow) {
  margin: 0;
  color: #7a7d82;
  font-size: clamp(1rem, 1.6vw, 1.15rem);
  line-height: 1.22;
  overflow-wrap: anywhere;
}

.feature-art {
  position: relative;
  min-height: 320px;
  margin-top: 18px;
  overflow: hidden;
  border-radius: 18px;
  background: #101734;
}

.feature-art span {
  position: absolute;
  display: block;
  border-radius: 999px;
}

.feature-art-blue {
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.08), transparent 44%),
    #101734;
}

.feature-art-blue span:nth-child(1) { width: 150px; height: 62px; left: 12%; top: 18%; rotate: -36deg; background: #eaa19b; }
.feature-art-blue span:nth-child(2) { width: 210px; height: 68px; left: 25%; top: 47%; rotate: -23deg; background: #f06653; }
.feature-art-blue span:nth-child(3) { width: 230px; height: 70px; right: 12%; top: 43%; rotate: 21deg; background: #55a9d8; }
.feature-art-blue span:nth-child(4) { width: 76px; height: 170px; left: 48%; top: 26%; rotate: 12deg; background: #83c5ac; }
.feature-art-blue span:nth-child(5) { width: 128px; height: 64px; right: 7%; bottom: 18%; rotate: 42deg; background: #d99aa0; }

.feature-art-media {
  background:
    linear-gradient(90deg, rgba(33, 151, 237, 0.88), rgba(37, 195, 223, 0.82)),
    #1782dc;
}

.feature-art-media::before {
  position: absolute;
  inset: 0;
  content: "";
  background:
    repeating-linear-gradient(90deg, rgba(34, 23, 133, 0.36) 0 8px, transparent 8px 54px),
    repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.34) 0 2px, transparent 2px 16px);
  mix-blend-mode: multiply;
  opacity: 0.62;
}

.feature-art-media span:nth-child(1) { width: 148px; height: 148px; left: 13%; top: 18%; border-radius: 32px; background: #7b2ce1; }
.feature-art-media span:nth-child(2) { width: 210px; height: 260px; left: 28%; bottom: -18px; border-radius: 90px 90px 0 0; background: rgba(245, 246, 248, 0.92); }
.feature-art-media span:nth-child(3) { width: 210px; height: 270px; right: 15%; bottom: -22px; border-radius: 88px 88px 0 0; background: rgba(35, 37, 41, 0.92); }
.feature-art-media span:nth-child(4) { width: 112px; height: 82px; right: 10%; top: 30%; border-radius: 12px; background: #ff8b1f; }

.hero .eyebrow { grid-column: 1 / -1; align-self: start; }

.hero h1 {
  max-width: 760px;
  margin: 0;
  font-size: clamp(2.8rem, 6.5vw, 5rem);
  font-weight: 520;
  line-height: 0.82;
  letter-spacing: -0.075em;
}

.lede {
  max-width: 42ch;
  margin: 0;
  align-self: end;
  color: var(--muted);
  font-size: clamp(1rem, 1.6vw, 1.15rem);
  line-height: 1.52;
}

.eyebrow {
  margin: 0 0 16px;
  color: var(--blue);
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.catalog { padding: 34px 0 96px; }

.section-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 28px;
  margin-bottom: 30px;
}

.section-heading h2,
.narrative h2 {
  margin: 0;
  font-size: clamp(1.3rem, 2vw, 1.7rem);
  font-weight: 650;
  line-height: 1.04;
  letter-spacing: 0;
}

.section-heading a {
  color: var(--blue);
  font-size: 0.92rem;
  font-weight: 560;
}

.section-heading p { margin: 8px 0 0; color: var(--muted); line-height: 1.5; }

.state {
  min-height: 200px;
  padding: 34px 0;
  border-top: 1px solid var(--line);
  color: var(--muted);
}

.state[data-state="error"] { color: #9d271f; }

.role-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: 54px;
  border-top: 0;
}

.role-row {
  display: grid;
  grid-template-columns: minmax(128px, max-content) minmax(0, 1fr);
  gap: 22px;
  align-items: center;
  min-height: 154px;
  border-bottom: 1px solid var(--line);
}

.role-side {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  padding: 18px 0;
}

.role-icon-link {
  display: block;
  width: 112px;
  height: 112px;
  overflow: hidden;
  border-radius: 50%;
  background: white;
  box-shadow: 0 10px 24px rgba(17, 18, 20, 0.12);
}

.role-icon,
.detail-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 420ms cubic-bezier(0.2, 0.75, 0.3, 1);
}

.role-icon-link:hover img { transform: scale(1.018); }

.role-body {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
  padding: 18px 0;
}

.role-body h3 {
  margin: 0;
  overflow-wrap: anywhere;
  color: #242629;
  font-size: clamp(1.05rem, 1.4vw, 1.2rem);
  font-weight: 700;
  line-height: 1.16;
  letter-spacing: 0;
}

.role-summary,
.role-value {
  max-width: 54ch;
  margin: 6px 0 0;
  color: #7a7d82;
  font-size: 0.95rem;
  line-height: 1.32;
}

.role-value { color: var(--ink); }

.compact-facts {
  display: flex;
  gap: 18px;
  margin: 14px 0 0;
  padding-top: 0;
}

dl div { min-width: 0; }

dt {
  margin-bottom: 7px;
  color: var(--muted);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

dd { margin: 0; color: #6b6f76; font-variant-numeric: tabular-nums; }

.compact-facts dd { font-size: 0.85rem; }

.store-button {
  display: inline-flex;
  align-items: center;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 600;
  transition: color 160ms ease;
}

.store-button:hover { color: var(--blue); }

.text-link { border-bottom: 1px solid currentColor; color: var(--blue-dark); font-size: 0.92rem; font-weight: 650; padding-bottom: 3px; }

.back-link { display: inline-block; margin: 32px 0 60px; }

.detail-loading { min-height: 480px; }

.detail-hero {
  display: grid;
  grid-template-columns: 164px minmax(0, 1fr);
  gap: 40px;
  align-items: center;
  padding: 0 0 38px;
  border-bottom: 1px solid var(--line);
}

.detail-copy h1,
.not-found h1 {
  margin: 0;
  font-size: clamp(1.8rem, 3.5vw, 2.6rem);
  font-weight: 700;
  line-height: 1.02;
  letter-spacing: 0;
}

.detail-copy .lede {
  margin-top: 12px;
  font-size: clamp(0.98rem, 1.5vw, 1.1rem);
  line-height: 1.38;
}

.detail-action {
  margin-top: 30px;
}

.download-button {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: var(--blue);
  color: white;
  font-size: 0.98rem;
  font-weight: 700;
  padding: 0 30px;
  transition: background 160ms ease, transform 160ms ease;
}

.download-button:hover { background: var(--blue-dark); transform: translateY(-1px); }

.unavailable { max-width: 24ch; margin: 0; color: var(--muted); text-align: right; }

.role-avatar {
  flex-shrink: 0;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  object-fit: cover;
  border: 1px solid var(--line);
}

.role-avatar-large {
  width: 144px;
  height: 144px;
  border-radius: 50%;
  background: white;
  box-shadow: 0 18px 34px rgba(17, 18, 20, 0.12);
}

.detail-gallery {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 28px;
  margin: 58px 0 68px;
}

.detail-gallery .detail-image:only-child { grid-column: 1 / -1; }

.detail-image {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  border: 1px solid var(--line);
  border-radius: 8px;
  object-fit: cover;
}

.narrative {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 72px;
  padding-bottom: 64px;
}

.narrative-block { border-top: 1px solid var(--ink); padding-top: 22px; }
.narrative-block p { max-width: 49ch; color: var(--muted); line-height: 1.62; }

.detail-facts {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  margin: 0 0 56px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.detail-facts > div { min-height: 98px; border-right: 1px solid var(--line); padding: 18px 18px; text-align: center; }
.detail-facts > div:last-child { border-right: 0; }
.detail-facts dd {
  color: var(--muted);
  font-size: 0.95rem;
  font-weight: 700;
}
.detail-facts .hash { grid-column: 1 / -1; min-height: 0; border-top: 1px solid var(--line); text-align: left; }
.detail-facts .hash dd { overflow-wrap: anywhere; font-family: ui-monospace, monospace; font-size: 0.76rem; line-height: 1.45; }

footer {
  display: flex;
  min-height: 110px;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid var(--line);
  font-size: 0.88rem;
}

.not-found { min-height: calc(100vh - 88px); padding: 18vh 0 80px; }
.not-found h1 { max-width: 980px; font-size: clamp(2.2rem, 5vw, 3.4rem); }
.not-found > p:not(.eyebrow) { margin: 28px 0 48px; color: var(--muted); font-size: 1.1rem; }

.docs-shell { padding: 72px 0 96px; }

.docs-shell h1 {
  max-width: 900px;
  margin: 0;
  font-size: clamp(2.2rem, 5vw, 3.6rem);
  font-weight: 520;
  line-height: 0.88;
  letter-spacing: -0.07em;
}

.docs-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 0.42fr);
  gap: 56px;
  margin-top: 56px;
  padding-top: 34px;
  border-top: 1px solid var(--ink);
}

.doc-link {
  display: block;
  padding: 26px 0;
  border-bottom: 1px solid var(--line);
}

.doc-link h2 { margin: 0; font-size: clamp(1.2rem, 2vw, 1.5rem); font-weight: 540; letter-spacing: -0.04em; }
.doc-link p { max-width: 58ch; margin: 12px 0 0; color: var(--muted); line-height: 1.58; }
.docs-note { margin: 0; color: var(--muted); line-height: 1.62; }

//// docs 渲染页(docs-prose):.md 的 HTML 投影,正文复用 .article-body 排版。
//// h1 收敛为正文级标题(覆盖 .docs-shell h1 的巨型展示字),max-width 限制阅读宽度。
.docs-prose { max-width: 760px; }
.docs-prose h1 { max-width: none; font-size: clamp(1.8rem, 3.4vw, 2.4rem); font-weight: 600; letter-spacing: -0.03em; line-height: 1.15; }
.docs-raw-link { margin: 20px 0 28px; padding-bottom: 24px; border-bottom: 1px solid var(--line); font-size: 0.92rem; }
.docs-raw-link a { color: var(--blue); border-bottom: 1px solid rgba(0, 113, 212, 0.35); }
.docs-raw-link a:hover { border-bottom-color: var(--blue); }
.text-link { color: var(--blue); }

@media (max-width: 800px) {
  body { background: var(--paper); }
  .site-header, #role-hub, footer { width: auto; margin-inline: 18px; }
  .site-header { min-height: 72px; }
  .home-features { display: block; padding: 38px 0 42px; }
  .feature-card { max-width: 100%; }
  .feature-card + .feature-card { margin-top: 38px; }
  .feature-card h2 { max-width: 100%; font-size: clamp(1.25rem, 5vw, 1.5rem); }
  .feature-card p:not(.eyebrow) { font-size: 1rem; }
  .feature-art { width: 100%; min-height: 230px; border-radius: 14px; }
  .hero { min-height: 430px; grid-template-columns: 1fr; gap: 26px; padding: 54px 0 42px; }
  .hero h1 { font-size: clamp(2.3rem, 11vw, 3.4rem); }
  .section-heading, .role-row, .detail-hero, .narrative, .docs-grid { grid-template-columns: 1fr; }
  .section-heading { align-items: flex-start; }
  .catalog { padding: 52px 0 72px; }
  .role-list { grid-template-columns: 1fr; }
  .role-row { grid-template-columns: minmax(84px, max-content) minmax(0, 1fr); gap: 16px; min-height: 112px; }
  .role-side { gap: 10px; padding: 14px 0; }
  .role-icon-link { width: 76px; height: 76px; border-radius: 50%; }
  .role-body { padding: 14px 0; }
  .role-body h3 { font-size: clamp(1.05rem, 5vw, 1.24rem); }
  .role-summary { font-size: 0.98rem; }
  .compact-facts { margin-top: auto; }
  .store-button { font-size: 0.86rem; }
  .compact-facts dd { font-size: 0.8rem; }
  .back-link { margin: 24px 0 48px; }
  .detail-hero { gap: 36px; }
  .role-avatar-large { width: 112px; height: 112px; border-radius: 50%; }
  .detail-copy h1 { font-size: clamp(1.6rem, 7.5vw, 2.2rem); }
  .detail-action { justify-self: start; }
  .unavailable { text-align: left; }
  .detail-gallery { grid-template-columns: 1fr; }
  .detail-gallery { margin: 38px 0; }
  .narrative { gap: 38px; }
  .detail-facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .detail-facts > div:nth-child(even) { border-right: 0; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
}

/* 文章板块 */
.articles-page { padding: 44px 0 96px; }

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

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

.article-row h3 { margin: 0; font-size: clamp(1.05rem, 1.5vw, 1.25rem); font-weight: 700; }
.article-row:hover h3 { color: var(--blue); }
.article-row p { max-width: 64ch; margin: 8px 0 0; color: #7a7d82; font-size: 0.95rem; line-height: 1.45; }
.article-date { flex-shrink: 0; color: var(--muted); font-size: 0.85rem; font-variant-numeric: tabular-nums; }

.article-page .back-link { display: inline-block; margin: 28px 0 4px; }
.article { max-width: 720px; margin: 0 auto; padding: 12px 0 80px; }
.article h1 { margin: 6px 0 10px; font-size: clamp(1.7rem, 3vw, 2.3rem); font-weight: 700; line-height: 1.18; }
.article-meta { margin: 0 0 34px; color: var(--muted); font-size: 0.9rem; }

.article-body { color: #2c2e31; font-size: 1.02rem; line-height: 1.7; }
.article-body h2 { margin: 40px 0 12px; font-size: 1.35rem; font-weight: 700; line-height: 1.25; }
.article-body h3 { margin: 30px 0 10px; font-size: 1.12rem; font-weight: 700; }
.article-body p { margin: 0 0 16px; }
.article-body ul, .article-body ol { margin: 0 0 16px; padding-left: 24px; }
.article-body li { margin: 6px 0; }
.article-body code { background: #f0efe7; border-radius: 5px; padding: 2px 6px; font-family: ui-monospace, monospace; font-size: 0.88em; }
.article-body pre { margin: 0 0 18px; padding: 16px 18px; overflow-x: auto; background: #14161a; color: #e8e8e3; border-radius: 10px; }
.article-body pre code { background: none; padding: 0; color: inherit; font-size: 0.86rem; line-height: 1.55; }
.article-body blockquote { margin: 0 0 16px; padding: 2px 0 2px 18px; border-left: 3px solid rgba(17, 18, 20, 0.3); color: #55585d; }
.article-body blockquote p { margin: 0; }
.article-body img { max-width: 100%; border-radius: 10px; }
.article-body a { color: var(--blue); border-bottom: 1px solid rgba(0, 113, 212, 0.35); }
.article-body a:hover { border-bottom-color: var(--blue); }
.article-body hr { margin: 32px 0; border: 0; border-top: 1px solid var(--line); }

a.feature-card:hover h2 { color: var(--blue); }

/* docs 页 agent 引导复制行 */
.agent-copy { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; margin: 18px 0 0; }
.agent-copy p { max-width: 72ch; margin: 0; color: var(--muted); font-size: 0.98rem; line-height: 1.55; }

.agent-copy button {
  border: 1px solid var(--blue);
  background: none;
  color: var(--blue);
  border-radius: 999px;
  padding: 5px 16px;
  font: inherit;
  font-size: 0.9rem;
  font-weight: 650;
  cursor: pointer;
  transition: background 160ms ease, color 160ms ease;
}

.agent-copy button:hover { background: var(--blue); color: #fff; }
