/* ============================================================
   base.css — 设计变量 / 重置 / 排版 / 按钮

   设计语言（编辑式 / 新粗野主义）:
   - 色彩：米白底 · 近黑墨水 · 深绿唯一强调
   - 字体：衬线标题（拉丁用 Georgia，斜体做点睛）× 细体无衬线正文
   - 半径：0px 全直角
   - 留白：区块间距 120px，大量空气感
   - 按钮：hover 时强调色从左向右滑入填充

   约束: 不引用任何境外资源，字体一律系统字体栈。
   Windows 上不落到 SimSun（大字号发虚），宁可退回黑体。
   ============================================================ */

:root {
  /* 墨水 */
  --ink: #161d1a;
  --ink-2: #4e5a55;
  --ink-3: #8b958f;

  /* 唯一强调色：深绿 */
  --brand: #0e7a5f;
  --brand-deep: #0a5946;
  --brand-dark: #0c201a;
  --brand-tint: #eaf3ef;

  /* 纸面与线 */
  --paper: #faf9f5;
  --surface: #ffffff;
  --line: #e3e0d9;
  --line-2: #cfcbc1;

  /* 间距 */
  --s1: 4px;
  --s2: 8px;
  --s3: 12px;
  --s4: 16px;
  --s5: 24px;
  --s6: 32px;
  --s7: 48px;
  --s8: 72px;
  /* 区块留白：桌面 120px */
  --s-sec: clamp(72px, 9vw, 120px);

  --w-page: 1240px;
  --w-doc: 700px;

  /* 衬线：拉丁走 Georgia，中文优先思源宋，缺失时退黑体而非 SimSun */
  --font-serif: Georgia, "Noto Serif SC", "Source Han Serif SC",
    "Source Han Serif CN", "Songti SC", STSong, "PingFang SC",
    "Microsoft YaHei", serif;
  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
    "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 15px;
  font-weight: 400;
  line-height: 1.9;
  color: var(--ink-2);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
}

/* ---------- 标题：衬线，字重轻，字距不收 ---------- */

h1,
h2,
h3 {
  margin: 0 0 var(--s5);
  font-family: var(--font-serif);
  font-weight: 400;
  line-height: 1.2;
  letter-spacing: 0;
  color: var(--ink);
}

h1 {
  font-size: clamp(2.5rem, 1.7rem + 3.6vw, 4.5rem);
  line-height: 1.12;
}

h2 {
  font-size: clamp(1.75rem, 1.35rem + 1.7vw, 2.75rem);
}

h3 {
  margin-bottom: var(--s3);
  font-size: 1.125rem;
  line-height: 1.45;
}

/* 斜体点睛：拉丁走 Georgia italic，中文用强调色区分 */
em,
.it {
  font-style: italic;
  color: var(--brand);
}

p {
  margin: 0 0 var(--s4);
}

a {
  color: var(--ink);
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: var(--brand);
}

ul,
ol {
  margin: 0 0 var(--s4);
  padding-left: 1.3em;
}

li {
  margin-bottom: var(--s2);
}

strong {
  color: var(--ink);
  font-weight: 600;
}

img,
svg {
  max-width: 100%;
  vertical-align: middle;
}

/* ---------- 编辑式小标签 ---------- */

/* 全大写、宽字距的小标签，编辑版式的骨架 */
.label {
  display: block;
  margin-bottom: var(--s5);
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink-3);
}

.label--brand {
  color: var(--brand);
}

/* 拉丁小标题用衬线斜体，和中文标签配对 */
.label__en {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 0.8125rem;
  letter-spacing: 0.04em;
  text-transform: none;
}

.lead {
  max-width: 34em;
  font-size: 1.0625rem;
  line-height: 1.85;
  color: var(--ink-2);
}

/* ---------- 按钮：直角，hover 从左填充 ---------- */

.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: var(--s3);
  padding: 15px 30px;
  border: 1px solid var(--ink);
  border-radius: 0;
  background: transparent;
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  line-height: 1;
  overflow: hidden;
  cursor: pointer;
  transition: color 0.3s ease, border-color 0.3s ease;
}

.btn::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--brand);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 0.38s cubic-bezier(0.22, 0.61, 0.36, 1);
}

.btn > * {
  position: relative;
  z-index: 1;
}

.btn:hover {
  color: #fff;
  border-color: var(--brand);
}

.btn:hover::before {
  transform: scaleX(1);
}

/* 实心版：默认就是强调色，hover 转深 */
.btn--solid {
  border-color: var(--brand);
  color: #fff;
}

.btn--solid::before {
  transform: scaleX(1);
}

.btn--solid:hover {
  border-color: var(--brand-deep);
}

.btn--solid:hover::before {
  background: var(--brand-deep);
}

/* 深底上的反白版 */
.btn--onDark {
  border-color: rgba(255, 255, 255, 0.35);
  color: #fff;
}

.btn--onDark:hover {
  border-color: #fff;
  color: var(--brand-dark);
}

.btn--onDark::before {
  background: #fff;
}

/* ---------- 图标 ---------- */

.icon {
  width: 22px;
  height: 22px;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.25;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.icon--sm {
  width: 16px;
  height: 16px;
  stroke-width: 1.4;
}

.icon--xs {
  width: 13px;
  height: 13px;
  stroke-width: 1.6;
}

.sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 3px;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 100;
  padding: var(--s2) var(--s4);
  background: var(--brand);
  color: #fff;
}

.skip-link:focus {
  left: 0;
}

@media (max-width: 720px) {
  body {
    font-size: 14.5px;
    line-height: 1.85;
  }
  .lead {
    font-size: 1rem;
  }
  .btn {
    padding: 13px 24px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}
