:root {
  --navy: #0b3a6b;
  --navy-2: #123f70;
  --red: #c8102e;
  --blue: #1f6fd0;
  --ink: #14263a;
  --muted: #64748b;
  --line: #e5eaf1;
  --bg: #f5f7fa;
  --surface: #fff;
  --font: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB",
    "Microsoft YaHei", "Segoe UI", sans-serif;
  --serif: "Songti SC", "SimSun", "Noto Serif SC", Georgia, serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: var(--font); font-size: 15px; line-height: 1.75;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
button, input, textarea, select { font-family: inherit; }
.wrap { width: min(1180px, calc(100% - 48px)); margin: 0 auto; }

/* ---------- top / header ---------- */
.topbar { background: #08294d; color: #a9c3dd; font-size: 12.5px; }
.topbar .wrap { display: flex; justify-content: space-between; align-items: center; height: 34px; }
.top-right { display: flex; gap: 16px; align-items: center; }
.top-right a:hover { color: #fff; }
.lang-dots { color: #7fa3c9; letter-spacing: .02em; }

.header { background: #fff; border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 30; }
.head-inner { display: flex; align-items: center; gap: 34px; height: 74px; }
.brand { display: flex; align-items: center; gap: 11px; color: var(--navy); }
.logo {
  width: 40px; height: 40px; border-radius: 11px; background: linear-gradient(150deg, #16528f, #0b3a6b);
  color: #fff; display: grid; place-items: center;
}
.logo svg { width: 26px; height: 26px; }
.brand-txt { display: flex; flex-direction: column; line-height: 1.15; }
.brand-txt b { font-size: 19px; font-family: var(--serif); letter-spacing: .06em; }
.brand-txt small { font-size: 10.5px; color: #8098b3; letter-spacing: .08em; }
.nav { display: flex; gap: 6px; margin-left: auto; }
.nav a { padding: 8px 14px; border-radius: 7px; font-size: 14.5px; color: #31465e; }
.nav a:hover { background: #f0f5fa; color: var(--navy); }
.nav a.on { color: var(--navy); font-weight: 600; background: #eaf2fb; }
.btn {
  display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line);
  background: #fff; color: var(--ink); padding: 9px 16px; border-radius: 8px;
  cursor: pointer; font-size: 14px;
}
.btn:hover { border-color: #c7d6e6; }
.btn.primary { background: var(--navy); border-color: var(--navy); color: #fff; font-weight: 600; }
.btn.primary:hover { background: #0f4a83; }
.btn.red { background: var(--red); border-color: var(--red); color: #fff; }
.btn.small { padding: 6px 12px; font-size: 13px; }
.btn:disabled { opacity: .6; cursor: default; }

/* ---------- hero ---------- */
.hero { background: linear-gradient(140deg, #0b3a6b 0%, #124a80 55%, #0a2f57 100%); color: #fff; position: relative; overflow: hidden; }
.hero::after {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(700px 300px at 80% 0%, rgba(90,170,255,.28), transparent 70%);
}
.hero-inner { position: relative; z-index: 2; padding: 58px 0 50px; display: grid; grid-template-columns: 1.15fr .85fr; gap: 40px; align-items: center; }
.hero h1 { font-family: var(--serif); font-size: clamp(28px, 3.4vw, 42px); line-height: 1.3; margin: 0 0 14px; letter-spacing: .01em; }
.hero h1 em { font-style: normal; color: #ffd7a8; }
.hero p { color: #c6d9ec; margin: 0 0 24px; max-width: 54ch; font-size: 15.5px; }
.hero-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.hero-actions .btn { background: rgba(255,255,255,.1); border-color: rgba(255,255,255,.26); color: #fff; }
.hero-actions .btn.primary { background: #fff; color: var(--navy); border-color: #fff; }
.hero-panel { background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.16); border-radius: 14px; padding: 18px 20px; backdrop-filter: blur(4px); }
.hero-panel h4 { margin: 0 0 12px; font-size: 13px; color: #9dc0e2; font-weight: 600; letter-spacing: .06em; }
.hero-panel .row { display: flex; justify-content: space-between; padding: 7px 0; border-bottom: 1px dashed rgba(255,255,255,.12); font-size: 13.5px; }
.hero-panel .row:last-child { border-bottom: 0; }
.hero-panel .row b { color: #fff; font-size: 15px; }

/* ---------- sections ---------- */
.section { padding: 46px 0; }
.section.white { background: #fff; }
.sec-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 22px; }
.sec-head h2 { font-family: var(--serif); font-size: 24px; margin: 0; letter-spacing: .02em; }
.sec-head h2::before { content: ""; display: inline-block; width: 4px; height: 18px; background: var(--red); margin-right: 10px; vertical-align: -2px; border-radius: 2px; }
.sec-head p { margin: 4px 0 0; color: var(--muted); font-size: 13.5px; }
.more { font-size: 13.5px; color: var(--blue); }

.grid { display: grid; gap: 18px; }
.g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }

.card { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 20px; transition: .18s; }
.card:hover { box-shadow: 0 10px 26px rgba(11,58,107,.08); transform: translateY(-2px); }
.card .tag { display: inline-block; font-size: 11.5px; color: var(--red); background: #fdeff1; border-radius: 4px; padding: 2px 8px; }
.card h3 { font-size: 17px; margin: 10px 0 8px; line-height: 1.5; font-family: var(--serif); }
.card p { margin: 0 0 12px; color: #526174; font-size: 13.5px; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.card .meta { font-size: 12.5px; color: #8a99ab; display: flex; gap: 10px; align-items: center; }
.card .langs { margin-left: auto; display: flex; gap: 4px; }
.card .langs i { font-style: normal; font-size: 10.5px; background: #eef4fb; color: #37628f; border-radius: 4px; padding: 1px 5px; }

/* fact list */
.fact { display: flex; gap: 16px; padding: 16px 0; border-bottom: 1px solid var(--line); }
.fact:last-child { border-bottom: 0; }
.fact .k { flex: none; width: 52px; height: 52px; border-radius: 10px; background: #fdeff1; color: var(--red); display: grid; place-items: center; font-family: var(--serif); font-size: 20px; }
.fact h4 { margin: 0 0 4px; font-size: 15px; }
.fact p { margin: 0; color: #5b6b7e; font-size: 13.5px; }

/* ---------- article ---------- */
.article-wrap { display: grid; grid-template-columns: minmax(0,1fr) 330px; gap: 30px; padding: 36px 0 60px; align-items: start; }
.crumbs { font-size: 12.5px; color: #8a99ab; margin-bottom: 12px; }
.crumbs a:hover { color: var(--blue); }
.article h1 { font-family: var(--serif); font-size: clamp(24px, 2.6vw, 32px); line-height: 1.4; margin: 0 0 12px; }
.article .meta { font-size: 13px; color: #7c8b9d; display: flex; gap: 14px; padding-bottom: 16px; border-bottom: 1px solid var(--line); margin-bottom: 22px; }
.article .body p { margin: 0 0 1em; font-size: 16px; line-height: 1.95; color: #1e2f42; text-align: justify; }
.article .body h2 { font-family: var(--serif); font-size: 19px; margin: 1.7em 0 .6em; }
.summary-box { background: #f2f7fd; border-left: 3px solid var(--blue); padding: 14px 16px; border-radius: 0 8px 8px 0; color: #2b4665; font-size: 14px; margin-bottom: 22px; }

.side-card { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 18px; position: sticky; top: 92px; }
.side-card h3 { margin: 0 0 12px; font-size: 14px; color: #37506c; letter-spacing: .04em; }
.lang-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.lang-tabs button { border: 1px solid var(--line); background: #fff; border-radius: 999px; padding: 5px 12px; font-size: 13px; cursor: pointer; color: #3d5470; }
.lang-tabs button.on { background: var(--navy); border-color: var(--navy); color: #fff; }
.version-body { font-size: 13.5px; line-height: 1.85; color: #33465c; max-height: 380px; overflow-y: auto; white-space: pre-wrap; }
.hint { font-size: 12.5px; color: #8a99ab; }
.progress { height: 4px; background: #eef3f9; border-radius: 99px; overflow: hidden; margin: 10px 0; display: none; }
.progress.on { display: block; }
.progress i { display: block; height: 100%; width: 35%; background: var(--blue); animation: move 1.1s infinite linear; }
@keyframes move { from { transform: translateX(-100%); } to { transform: translateX(300%); } }

/* ---------- forms / table ---------- */
.panel { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 22px; }
.field { display: block; margin-bottom: 14px; }
.field > span { display: block; font-size: 12.5px; color: var(--muted); margin-bottom: 5px; font-weight: 600; }
.field input, .field textarea, .field select {
  width: 100%; padding: 9px 12px; border: 1px solid var(--line); border-radius: 8px;
  font-size: 14px; background: #fff; color: var(--ink);
}
.field textarea { resize: vertical; }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 10px; background: #fff; }
table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
th, td { padding: 10px 14px; border-bottom: 1px solid #eef2f7; text-align: left; vertical-align: top; }
th { background: #f7f9fc; font-size: 12.5px; color: #4a6076; font-weight: 600; white-space: nowrap; }
tr:last-child td { border-bottom: 0; }
.searchbar { display: flex; gap: 10px; margin-bottom: 16px; }
.searchbar input { flex: 1; padding: 10px 14px; border: 1px solid var(--line); border-radius: 8px; font-size: 14px; }

/* translate workbench */
.tr-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.tr-card { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 16px; display: flex; flex-direction: column; min-height: 300px; }
.tr-card h4 { margin: 0 0 10px; font-size: 13px; color: #4a6076; display: flex; justify-content: space-between; }
.tr-card textarea { flex: 1; border: 0; resize: none; font-size: 15px; line-height: 1.8; outline: none; }
.tr-out { flex: 1; font-size: 15px; line-height: 1.85; white-space: pre-wrap; color: #16324f; }
.tr-bar { display: flex; gap: 10px; align-items: center; margin-bottom: 16px; flex-wrap: wrap; }
.evidence { margin-top: 16px; font-size: 13px; color: #5b6b7e; }
.evidence b { color: #2b4665; }

.footer { background: #08294d; color: #9db4cd; margin-top: 40px; font-size: 13px; }
.foot-inner { display: flex; justify-content: space-between; gap: 30px; padding: 34px 0; flex-wrap: wrap; }
.foot-inner b { color: #fff; font-family: var(--serif); font-size: 16px; }
.foot-inner p { max-width: 58ch; margin: 8px 0 0; line-height: 1.8; }
.foot-meta { display: flex; flex-direction: column; gap: 6px; color: #7fa3c9; font-size: 12.5px; }

.tagline { font-size: 12.5px; color: #8a99ab; }
.pill { display: inline-block; font-size: 11.5px; background: #eef4fb; color: #37628f; border-radius: 99px; padding: 2px 9px; }

@media (max-width: 980px) {
  .hero-inner, .article-wrap, .g3, .g2, .tr-grid { grid-template-columns: 1fr; }
  .nav { display: none; }
  .side-card { position: static; }
}

/* 术语高亮 */
mark.term { background: #fff2c9; color: inherit; border-bottom: 2px solid #f0b429; padding: 0 1px; border-radius: 2px; }
mark.term.tgt { background: #ddf3ff; border-bottom-color: #3aa0e0; }
.src-note { font-size: 12.5px; color: #7d8ea3; margin: 8px 0 0; }
.src-marked { margin-top: 10px; padding: 12px 14px; background: #fbfcfe; border: 1px dashed #dbe6f2; border-radius: 8px; font-size: 14px; line-height: 1.9; color: #2b4665; max-height: 160px; overflow-y: auto; }
.legend { display: flex; gap: 14px; font-size: 12px; color: #7d8ea3; margin-top: 8px; }
.legend i { display: inline-block; width: 12px; height: 12px; border-radius: 3px; vertical-align: -2px; margin-right: 4px; }
