/* ==========================================================================
   base.css — 变量、重置、排版、通用工具类
   ========================================================================== */

:root {
  /* 主色 */
  --c-navy-900: #050B16;
  --c-navy-800: #0A1526;
  --c-navy-700: #0B1B33;
  --c-navy-600: #12253F;
  --c-navy-500: #12345C;
  --c-navy-400: #1B3E68;

  --c-orange: #FF6B1A;
  --c-orange-light: #FFA34D;
  --c-orange-dark: #E45400;

  /* 背景 */
  --bg-body: #F5F7FA;
  --bg-card: #FFFFFF;
  --bg-soft: #E8EDF3;
  --bg-dark: #0A1526;

  /* 文本 */
  --t-on-dark: #FFFFFF;
  --t-strong: #1A2433;
  --t-body: #5B6B7F;
  --t-muted: #9AA8BA;

  /* 功能色 */
  --f-warning: #F5C518;
  --f-info: #1E6FD9;
  --f-danger: #E03B3B;
  --f-success: #1FA463;

  /* 负荷色标 */
  --load-yellow: #EAB308;
  --load-light: #2563EB;
  --load-medium: #DC2626;
  --load-heavy: #16A34A;
  --load-extra-heavy: #8B4513;
  --load-black: #1F2937;

  /* 尺寸 */
  --container: 1280px;
  --nav-h: 76px;
  --radius-sm: 6px;
  --radius: 12px;
  --radius-lg: 18px;
  --radius-pill: 999px;

  /* 阴影 */
  --sh-sm: 0 2px 8px rgba(11, 27, 51, 0.06);
  --sh: 0 8px 24px rgba(11, 27, 51, 0.08);
  --sh-lg: 0 18px 48px rgba(11, 27, 51, 0.14);
  --sh-orange: 0 10px 30px rgba(255, 107, 26, 0.28);

  /* 动效 */
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
  --dur: 240ms;

  /* 渐变 */
  --grad-orange: linear-gradient(135deg, #FF8A3D 0%, #FF5A00 100%);
  --grad-dark: linear-gradient(140deg, #12253F 0%, #0A1526 55%, #050B16 100%);
  --grad-metal: linear-gradient(120deg, #3C4B60 0%, #8697AC 45%, #4A5A70 100%);

  --font: "Noto Sans SC", "Noto Sans", "PingFang SC", "Microsoft YaHei", "Segoe UI", system-ui, sans-serif;
}

/* ---------- reset ---------- */
*,
*::before,
*::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.75;
  color: var(--t-body);
  background: var(--bg-body);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 { margin: 0; color: var(--t-strong); line-height: 1.3; font-weight: 700; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; transition: color var(--dur) var(--ease); }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; border: none; background: none; }
table { border-collapse: collapse; width: 100%; }

:focus-visible { outline: 2px solid var(--c-orange); outline-offset: 3px; }

::selection { background: rgba(255, 107, 26, 0.24); color: var(--t-strong); }

/* 滚动条 */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: var(--bg-soft); }
::-webkit-scrollbar-thumb { background: #B7C4D4; border-radius: 5px; }
::-webkit-scrollbar-thumb:hover { background: #94A5B9; }

/* ---------- 排版 ---------- */
.h-display { font-size: 48px; font-weight: 700; letter-spacing: -0.5px; }
.h-1 { font-size: 40px; font-weight: 700; }
.h-2 { font-size: 32px; font-weight: 700; }
.h-3 { font-size: 24px; font-weight: 600; }
.lead { font-size: 17px; line-height: 1.85; }
.small { font-size: 13px; }
.mono { font-family: "JetBrains Mono", "Consolas", "SFMono-Regular", monospace; }

/* ---------- 布局工具 ---------- */
.container { width: min(100% - 48px, var(--container)); margin-inline: auto; }
.section { padding: 96px 0; }
.section--tight { padding: 64px 0; }
.section--dark { background: var(--grad-dark); color: #C8D5E4; }
.section--dark h1, .section--dark h2, .section--dark h3 { color: #fff; }
.section--soft { background: var(--bg-soft); }

.grid { display: grid; gap: 28px; }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

.flex { display: flex; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.gap-8 { gap: 8px; }
.gap-12 { gap: 12px; }
.gap-16 { gap: 16px; }
.gap-24 { gap: 24px; }
.wrap { flex-wrap: wrap; }

.text-center { text-align: center; }
.text-right { text-align: right; }
.mt-8 { margin-top: 8px; }
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.mt-40 { margin-top: 40px; }
.mb-8 { margin-bottom: 8px; }
.mb-16 { margin-bottom: 16px; }
.mb-24 { margin-bottom: 24px; }
.mb-40 { margin-bottom: 40px; }

.hidden { display: none !important; }
.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;
}

/* ---------- 区块标题 ---------- */
.section-head { margin-bottom: 52px; }
.section-head--center { text-align: center; }
.section-head__eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 13px; font-weight: 600; letter-spacing: 2px; text-transform: uppercase;
  color: var(--c-orange);
}
.section-head__eyebrow::before {
  content: ''; width: 26px; height: 2px; background: var(--grad-orange); border-radius: 2px;
}
.section-head--center .section-head__eyebrow::after {
  content: ''; width: 26px; height: 2px; background: var(--grad-orange); border-radius: 2px;
}
.section-head__title { margin-top: 14px; font-size: 36px; }
.section-head__desc { margin-top: 14px; max-width: 660px; font-size: 16px; color: var(--t-body); }
.section-head--center .section-head__desc { margin-inline: auto; }
.section--dark .section-head__desc { color: #9DB0C7; }

/* ---------- 滚动入场 ---------- */
.reveal {
  opacity: 1;
  transform: none;
  transition: opacity 700ms var(--ease), transform 700ms var(--ease);
  will-change: opacity, transform;
}
.reveal.is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
  .reveal { opacity: 1; transform: none; }
}

/* ---------- 响应式 ---------- */
@media (max-width: 1024px) {
  .section { padding: 76px 0; }
  .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .h-display { font-size: 38px; }
  .section-head__title { font-size: 30px; }
}

@media (max-width: 768px) {
  body { font-size: 14.5px; }
  .container { width: min(100% - 32px, var(--container)); }
  .section { padding: 60px 0; }
  .grid { gap: 20px; }
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .h-display { font-size: 30px; }
  .section-head { margin-bottom: 36px; }
  .section-head__title { font-size: 25px; }
}

@media (max-width: 480px) {
  .grid-4 { grid-template-columns: 1fr; }
}
