:root {
  --accent: #126e5b;
  --accent-2: #0e9472;
  --bg: #f4f6f5;
  --surface: rgba(255,255,255,.86);
  --surface-strong: #fff;
  --text: #15211e;
  --muted: #65726e;
  --line: rgba(20,45,38,.11);
  --shadow: 0 18px 55px rgba(21,55,45,.08);
  --radius: 24px;
  color-scheme: light;
}

:root[data-theme="dark"] {
  --bg: #0d1211;
  --surface: rgba(23,30,28,.88);
  --surface-strong: #171e1c;
  --text: #edf4f1;
  --muted: #a1afaa;
  --line: rgba(222,245,237,.11);
  --shadow: 0 22px 70px rgba(0,0,0,.3);
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  background-color: var(--bg);
  background-image:
    radial-gradient(circle at 14% 0%, color-mix(in srgb, var(--accent) 9%, transparent), transparent 28rem),
    linear-gradient(var(--bg), var(--bg));
  color: var(--text);
  font-family: "Microsoft YaHei", "PingFang SC", system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.7;
  transition: background .3s ease, color .3s ease;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
svg { width: 1.15em; height: 1.15em; flex: 0 0 auto; }
button, input, textarea, select { font: inherit; }

.site-shell { width: min(1120px, calc(100% - 40px)); margin: 0 auto; padding: 64px 0 30px; }
.masthead { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin: 0 0 34px; }
.brand { display: inline-flex; align-items: center; gap: 14px; font-size: clamp(2rem, 4vw, 3.2rem); font-weight: 800; letter-spacing: -.05em; line-height: 1; }
.brand-mark { display: grid; place-items: center; width: 52px; height: 52px; border-radius: 17px 17px 17px 6px; background: var(--text); color: var(--bg); font-size: 1.35rem; letter-spacing: 0; }
.masthead p { max-width: 360px; margin: 0; color: var(--muted); text-align: right; font-size: .94rem; }

.theme-toggle { position: fixed; right: 24px; top: 24px; z-index: 20; width: 46px; height: 46px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 50%; background: var(--surface); color: var(--text); box-shadow: var(--shadow); backdrop-filter: blur(15px); cursor: pointer; transition: transform .2s ease; }
.theme-toggle:hover { transform: rotate(8deg) scale(1.04); }
.theme-toggle .theme-moon, :root[data-theme="dark"] .theme-toggle .theme-sun { display: none; }
:root[data-theme="dark"] .theme-toggle .theme-moon { display: inline-flex; }

.bento { display: grid; grid-template-columns: repeat(12, minmax(0,1fr)); gap: 20px; }
.card { position: relative; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); box-shadow: 0 1px 0 rgba(255,255,255,.4) inset; backdrop-filter: blur(14px); transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease; }
a.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: color-mix(in srgb, var(--accent) 28%, var(--line)); }
.feature-card { grid-column: 1 / -1; min-height: 255px; display: flex; align-items: flex-end; justify-content: space-between; gap: 28px; padding: clamp(28px, 5vw, 56px); color: #fff; background: var(--accent); background: linear-gradient(135deg, color-mix(in srgb, var(--accent) 94%, #051b15), color-mix(in srgb, var(--accent) 70%, #25b88b)); border: 0; box-shadow: 0 24px 60px rgba(18,110,91,.22); }
.feature-card:hover { box-shadow: 0 30px 75px color-mix(in srgb, var(--accent) 30%, transparent); }
.feature-glow { position: absolute; width: 500px; height: 500px; right: -190px; top: -330px; border-radius: 50%; border: 80px solid rgba(255,255,255,.07); }
.feature-copy { position: relative; max-width: 720px; }
.feature-copy h1 { margin: 10px 0 9px; font-size: clamp(2.15rem, 5vw, 4.2rem); line-height: 1.1; letter-spacing: -.045em; }
.feature-copy p { margin: 0; font-size: clamp(1rem, 2vw, 1.18rem); opacity: .84; }
.eyebrow { display: inline-flex; align-items: center; gap: 8px; padding: 5px 12px; border: 1px solid rgba(255,255,255,.25); border-radius: 99px; background: rgba(255,255,255,.1); font-size: .82rem; }
.feature-action { position: relative; display: inline-flex; align-items: center; gap: 9px; flex: 0 0 auto; padding: 13px 18px; border-radius: 14px; background: #fff; color: var(--accent); font-weight: 700; }

.about-card { grid-column: span 8; min-height: 190px; display: flex; align-items: flex-start; gap: 22px; padding: 32px; }
.stat-card { grid-column: span 4; padding: 30px; background: var(--text); color: var(--bg); }
.stat-card strong { display: block; margin: 15px 0 0; font: 700 clamp(3.2rem, 6vw, 5rem)/1 Georgia, serif; }
.stat-card p { margin: 1px 0 18px; opacity: .7; }
.stat-card a { display: inline-flex; align-items: center; gap: 7px; font-size: .9rem; font-weight: 600; }
.stat-card a svg { transition: transform .2s ease; }
.stat-card a:hover svg { transform: translateX(4px); }
.card-icon { display: grid; place-items: center; flex: 0 0 auto; width: 46px; height: 46px; border-radius: 14px; background: color-mix(in srgb, var(--accent) 12%, transparent); color: var(--accent); }
.card-icon svg { width: 22px; height: 22px; }
.card-kicker { color: var(--accent); font-size: .72rem; font-weight: 800; letter-spacing: .16em; }
.about-card h2, .link-card h2, .articles-card h2 { margin: 4px 0 5px; font-size: 1.35rem; line-height: 1.3; }
.about-card p, .link-card p { margin: 0; color: var(--muted); }
.meta-row { display: flex; flex-wrap: wrap; gap: 12px 20px; margin-top: 17px; color: var(--muted); font-size: .88rem; }
.meta-row span, .meta-row a { display: inline-flex; align-items: center; gap: 6px; }
.meta-row svg { width: 16px; }

.link-card { grid-column: span 4; min-height: 178px; display: flex; align-items: flex-start; gap: 18px; padding: 28px; }
.link-card.wide-card { grid-column: span 8; }
.link-card p { font-size: .92rem; }
.corner-arrow { position: absolute; right: 22px; bottom: 20px; display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--line); color: var(--muted); }
.link-card:hover .corner-arrow { color: var(--accent); border-color: color-mix(in srgb, var(--accent) 40%, var(--line)); }

.articles-card { grid-column: span 8; padding: 32px; }
.quote-card { grid-column: span 4; padding: 34px; min-height: 350px; display: flex; flex-direction: column; justify-content: flex-end; color: #effff9; background: #102620; background: linear-gradient(150deg, #102620, color-mix(in srgb, var(--accent) 80%, #06100d)); border: 0; }
.quote-mark { position: absolute; top: 3px; right: 23px; font: 700 9rem/1 Georgia, serif; color: rgba(255,255,255,.08); }
.quote-card p { position: relative; margin: 0 0 24px; font: 700 clamp(1.35rem, 3vw, 2.05rem)/1.45 "Microsoft YaHei", "PingFang SC", sans-serif; }
.quote-card > span:last-child { opacity: .62; font-size: .88rem; }
.section-heading { display: flex; align-items: center; gap: 18px; margin-bottom: 15px; }
.section-line { height: 1px; flex: 1; background: var(--line); }
.article-list { display: grid; }
.article-row { display: grid; grid-template-columns: 56px 1fr auto; gap: 17px; align-items: center; padding: 20px 2px; border-top: 1px solid var(--line); }
.article-row time { align-self: start; color: var(--muted); font: 600 .85rem/1.4 Georgia, serif; }
.article-row div > span { color: var(--accent); font-size: .75rem; font-weight: 600; }
.article-row h3 { margin: 2px 0 3px; font-size: 1.02rem; }
.article-row p { margin: 0; color: var(--muted); font-size: .84rem; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.article-row > svg { color: var(--muted); transition: transform .2s ease, color .2s ease; }
.article-row:hover > svg { color: var(--accent); transform: translateX(4px); }
.empty-state { color: var(--muted); }

.footer { display: flex; justify-content: space-between; align-items: center; gap: 20px; padding: 30px 4px 0; color: var(--muted); font-size: .82rem; }
.footer p { margin: 0; }
.footer a { opacity: .4; }
.footer a:hover { opacity: 1; }
.footer .icp-link { opacity: .78; }
.footer .icp-link:hover { color: var(--accent); opacity: 1; }

.article-shell { width: min(860px, calc(100% - 40px)); margin: 0 auto; padding: 48px 0 80px; }
.article-nav { display: flex; justify-content: space-between; align-items: center; margin-bottom: 40px; color: var(--muted); font-size: .92rem; }
.article-nav a { display: inline-flex; align-items: center; gap: 8px; }
.article-page { border: 1px solid var(--line); border-radius: 32px; background: var(--surface); box-shadow: var(--shadow); overflow: hidden; }
.article-header { padding: clamp(34px, 8vw, 72px) clamp(28px, 8vw, 72px) 42px; }
.article-category { display: inline-block; padding: 5px 11px; border-radius: 99px; background: color-mix(in srgb, var(--accent) 11%, transparent); color: var(--accent); font-size: .78rem; font-weight: 700; }
.article-header h1 { max-width: 720px; margin: 18px 0 14px; font-size: clamp(2.15rem, 5.8vw, 4.2rem); line-height: 1.18; letter-spacing: -.045em; }
.article-header p { max-width: 650px; margin: 0 0 24px; color: var(--muted); font-size: 1.08rem; }
.article-header time { color: var(--muted); font-size: .84rem; }
.article-cover { margin: 0; aspect-ratio: 16 / 8; background: color-mix(in srgb, var(--accent) 8%, var(--bg)); overflow: hidden; }
.article-cover img { width: 100%; height: 100%; object-fit: cover; }
.article-content { padding: 46px clamp(28px, 8vw, 72px) 60px; font-size: 1.05rem; line-height: 1.9; }
.article-content > :first-child { margin-top: 0; }
.article-content h2 { margin: 2em 0 .65em; font-size: 1.65rem; line-height: 1.35; }
.article-content h3 { margin: 1.7em 0 .55em; }
.article-content p { margin: 1.1em 0; }
.article-content a { color: var(--accent); border-bottom: 1px solid color-mix(in srgb, var(--accent) 30%, transparent); }
.article-content blockquote { margin: 1.6em 0; padding: 18px 22px; border-left: 4px solid var(--accent); border-radius: 0 14px 14px 0; background: color-mix(in srgb, var(--accent) 7%, transparent); color: var(--muted); }
.article-content img { margin: 30px auto 8px; border-radius: 18px; }
.article-content pre { overflow-x: auto; padding: 20px; border-radius: 16px; background: #111916; color: #e6fff5; font-size: .9rem; }
.article-content code { font-family: ui-monospace, SFMono-Regular, Consolas, monospace; }
.article-content :not(pre) > code { padding: 2px 6px; border-radius: 6px; background: color-mix(in srgb, var(--accent) 9%, transparent); color: var(--accent); }
.article-end { display: flex; align-items: center; gap: 16px; margin: 0 clamp(28px, 8vw, 72px); padding: 30px 0 48px; border-top: 1px solid var(--line); color: var(--muted); font-size: .86rem; }
.article-end > span { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }
.article-end p { margin: 0; flex: 1; }
.article-end a { display: inline-flex; align-items: center; gap: 7px; color: var(--text); font-weight: 600; }

.reveal { opacity: 0; transform: translateY(14px); }
.reveal.is-visible { opacity: 1; transform: none; transition: opacity .65s ease var(--delay), transform .65s ease var(--delay); }

@media (max-width: 820px) {
  .site-shell { width: min(100% - 28px, 680px); padding-top: 76px; }
  .masthead { align-items: flex-start; flex-direction: column; }
  .masthead p { text-align: left; }
  .feature-card { min-height: 330px; align-items: flex-start; flex-direction: column; }
  .feature-action { margin-top: auto; }
  .about-card, .stat-card, .link-card, .link-card.wide-card, .articles-card, .quote-card { grid-column: 1 / -1; }
  .quote-card { min-height: 260px; }
}

@media (max-width: 520px) {
  .site-shell, .article-shell { width: calc(100% - 22px); }
  .theme-toggle { right: 14px; top: 14px; }
  .brand { font-size: 2.15rem; }
  .brand-mark { width: 44px; height: 44px; border-radius: 14px 14px 14px 5px; }
  .feature-card { min-height: 360px; padding: 26px; }
  .feature-copy h1 { font-size: 2.5rem; }
  .about-card, .link-card, .articles-card { padding: 24px; }
  .about-card { flex-direction: column; }
  .article-row { grid-template-columns: 43px 1fr; }
  .article-row > svg { display: none; }
  .article-row p { white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
  .article-shell { padding-top: 75px; }
  .article-nav { padding: 0 4px; }
  .article-page { border-radius: 24px; }
  .article-end { align-items: flex-start; flex-wrap: wrap; }
  .article-end p { min-width: 70%; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; }
  .reveal { opacity: 1; transform: none; }
}
