/* ══════════════════════════════════════════════════════════
   润皓科技 RAISEINFO · 基础层 base.css
   Reset / 排版 / 布局容器 / 通用工具类
══════════════════════════════════════════════════════════ */

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-h) + 16px);
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-sans);
  font-size: var(--fs-base);
  line-height: 1.75;
  background: var(--bg-base);
  color: var(--text-md);
  overflow-x: hidden;
  transition: background-color .3s ease, color .3s ease;
}

h1, h2, h3, h4 {
  color: var(--text-hi);
  font-weight: 500;
  line-height: 1.3;
  letter-spacing: -0.2px;
}

a { color: var(--brand); text-decoration: none; transition: color .2s ease; }
a:hover { color: var(--accent); }

img, svg { max-width: 100%; display: block; }
button { font: inherit; cursor: pointer; border: none; background: none; color: inherit; }
ul, ol { list-style: none; }

::selection { background: var(--brand); color: var(--on-brand); }

::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: var(--bg-base); }
::-webkit-scrollbar-thumb { background: var(--border-hi); border-radius: var(--radius-full); }
::-webkit-scrollbar-thumb:hover { background: var(--brand); }

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

/* ── 布局容器 ── */
.wrap {
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 var(--sp-5);
}

.section { padding: var(--sp-8) 0; position: relative; }
.section--tint { background: var(--bg-surface); }
.section--tight { padding: var(--sp-7) 0; }

/* ── 内页页头 ── */
.page-hero {
  position: relative;
  padding: calc(var(--nav-h) + 68px) 0 var(--sp-7);
  background: var(--bg-surface);
  border-bottom: 1px solid var(--line);
  overflow: hidden;
}
.page-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(var(--line) 1px, transparent 1px),
    linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 58px 58px;
  -webkit-mask-image: radial-gradient(ellipse 70% 90% at 22% 30%, #000 5%, transparent 72%);
  mask-image: radial-gradient(ellipse 70% 90% at 22% 30%, #000 5%, transparent 72%);
  pointer-events: none;
}
.page-hero__inner { position: relative; z-index: 1; max-width: 68ch; }
.page-hero .lead { margin-top: var(--sp-4); }
.page-hero__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: var(--sp-5);
}

/* ── 面包屑 ── */
.crumb {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: var(--fs-xs);
  color: var(--text-lo);
  margin-bottom: var(--sp-4);
}
.crumb a { color: var(--text-lo); }
.crumb a:hover { color: var(--brand); }
.crumb span { opacity: .45; }

/* ── 标题体系 ── */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: var(--fs-xs);
  font-weight: 500;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--brand);
  margin-bottom: var(--sp-3);
}
.eyebrow::before {
  content: "";
  width: 28px;
  height: 2px;
  background: var(--brand);
  border-radius: var(--radius-full);
  flex-shrink: 0;
}

.h1 { font-size: var(--fs-h1); line-height: 1.18; font-weight: 500; }
.h2 { font-size: var(--fs-h2); line-height: 1.25; font-weight: 500; }
.h3 { font-size: var(--fs-h3); line-height: 1.35; font-weight: 500; }

.h1 em, .h2 em, .h3 em {
  font-style: normal;
  color: var(--brand);
}

.lead {
  font-size: var(--fs-lg);
  line-height: 1.8;
  color: var(--text-md);
  max-width: 62ch;
}

.muted { color: var(--text-lo); font-size: var(--fs-sm); }

/* 防止标题里的专有名词被断行拆开 */
.nowrap { white-space: nowrap; }

/* ── 区块头部 ── */
.sec-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--sp-5);
  margin-bottom: var(--sp-6);
}
.sec-head__text { max-width: 66ch; }
.sec-head .lead { margin-top: var(--sp-3); font-size: var(--fs-base); }

/* ── 数字/英文强调 ── */
.num {
  font-family: var(--font-num);
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.5px;
}

/* ── 网格 ── */
.grid { display: grid; gap: var(--sp-4); }
.grid--2 { grid-template-columns: repeat(2, 1fr); }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--4 { grid-template-columns: repeat(4, 1fr); }

/* ── 滚动淡入 ──
   默认可见：只有 JS 正常执行（html 上挂到 .js-anim）时才隐藏等待动画，
   这样 JS 未加载 / 被禁用 / 爬虫不执行脚本时，内容依然完整可见。 */
.js-anim .reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity .6s ease, transform .6s ease;
}
.js-anim .reveal.is-in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js-anim .reveal,
  .js-anim .reveal.is-in {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

/* ── 无障碍 ── */
.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  top: -60px; left: var(--sp-4);
  z-index: 2000;
  padding: 10px 18px;
  background: var(--brand);
  color: var(--on-brand);
  border-radius: var(--radius-sm);
  font-size: var(--fs-sm);
  font-weight: 500;
}
.skip-link:focus { top: var(--sp-3); color: var(--on-brand); }

/* ── 分隔装饰线 ── */
.rule {
  height: 1px;
  background: var(--line);
  border: none;
  margin: 0;
}

/* ── 响应式 ── */
@media (max-width: 1024px) {
  .grid--4 { grid-template-columns: repeat(2, 1fr); }
  .grid--3 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 760px) {
  :root { --sp-8: 64px; --sp-7: 48px; }
  .wrap { padding: 0 var(--sp-4); }
  .sec-head { flex-direction: column; align-items: flex-start; margin-bottom: var(--sp-5); }
  .grid--2, .grid--3, .grid--4 { grid-template-columns: 1fr; }
  .lead { font-size: var(--fs-base); }
}
