@charset "utf-8";
/* ============================================================
   base.css — 设计令牌 / 重置 / 排版 / 栅格容器 / 工具类
   GANGHUAI 官网重构版
   ============================================================ */

/* ---------- 1. 设计令牌 ---------- */
:root {
  /* 品牌色 */
  --brand: #FF5A1F;
  --brand-ink: #c2410c;
  --brand-soft: #ffede4;
  --brand-glow: #ff8a4c;

  /* 中性色 */
  --ink: #1a1a1c;
  --ink-2: #333333;
  --ink-3: #5c5c63;
  --ink-4: #6f6f78;
  --paper: #ffffff;
  --paper-dim: #f5f6fa;
  --line: #dedede;
  --line-soft: #e9e9ee;

  /* 半透明白（深色底上用，对比度按 WCAG AA 校准） */
  --on-brand-line: rgba(255, 255, 255, 0.22);
  /* 深色区块上的次要白字：按 #c2410c 底色校到 AA（对比度 ≈4.6） */
  --on-brand-text: rgba(255, 255, 255, 0.92);

  /* 版式 */
  --font-sans: "PingFang SC", "HarmonyOS Sans SC", "Noto Sans SC", "Source Han Sans SC",
    "Microsoft YaHei", system-ui, -apple-system, "Segoe UI", sans-serif;

  --fs-body: 16px;
  --fs-small: 14px;
  --fs-h1: 5vw;
  --fs-h2: 36px;

  /* 尺寸与节奏：不设最大宽度，与首屏 5vw 字级的全幅排版保持一致 */
  --shell-max: 100%;
  --shell-pad: 120px;
  --header-h: 90px;
  --radius-pill: 999px;
  --radius-s: 4px;

  /* 动效 */
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --dur: 0.45s;
  --dur-slow: 0.7s;

  /* 图层 */
  --z-header: 90;
  --z-rail: 100;
  --z-float: 80;
}

/* ---------- 2. 重置 ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

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

html,
body {
  margin: 0;
  padding: 0;
}

body {
  background: var(--paper);
  color: var(--ink-2);
  font-family: var(--font-sans);
  font-size: var(--fs-body);
  line-height: 1.4;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

body.is-locked {
  overflow: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  margin: 0;
  font-size: inherit;
  font-weight: 400;
  line-height: 1.3;
}

p {
  margin: 0;
}

ul,
ol,
li {
  margin: 0;
  padding: 0;
  list-style: none;
}

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

img,
svg,
video,
canvas {
  display: block;
  max-width: 100%;
}

img {
  height: auto;
  border: 0;
}

button {
  margin: 0;
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
  font: inherit;
  line-height: inherit;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

address {
  font-style: normal;
}

figure {
  margin: 0;
}

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

:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 4px;
  border-radius: 2px;
}

/* 滚动条 */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: #f2f3f7;
}
::-webkit-scrollbar-thumb {
  background: rgba(23, 45, 231, 0.55);
  border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--brand);
}

/* ---------- 3. 栅格容器 ---------- */
.shell {
  width: 100%;
  max-width: var(--shell-max);
  margin-inline: auto;
  padding-inline: var(--shell-pad);
}

@media (max-width: 1440px) {
  :root {
    --shell-pad: 60px;
  }
}

@media (max-width: 960px) {
  :root {
    --shell-pad: 30px;
  }
}

@media (max-width: 768px) {
  :root {
    --shell-pad: 15px;
    --fs-h2: 24px;
  }
}

/* ---------- 4. 工具类 ---------- */
.sr-only {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 200;
  padding: 10px 18px;
  border-radius: var(--radius-pill);
  background: var(--brand);
  color: #fff;
  font-size: var(--fs-small);
  transform: translateY(-160%);
  transition: transform 0.25s var(--ease);
}

.skip-link:focus-visible {
  transform: translateY(0);
  outline-color: #fff;
}

/* ---------- 5. 滚动揭示 ---------- */
.has-js .u-reveal {
  opacity: 0;
  transform: translateY(26px);
  transition:
    opacity var(--dur-slow) var(--ease),
    transform var(--dur-slow) var(--ease);
  transition-delay: var(--reveal-delay, 0ms);
}

.has-js .u-reveal.is-in {
  opacity: 1;
  transform: none;
}

/* ---------- 6. 减弱动效偏好 ---------- */
@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;
    transition-delay: 0ms !important;
  }

  .has-js .u-reveal {
    opacity: 1;
    transform: none;
  }
}
