/* ═══════════════════════════════════════════════════════════
   RackForge — Design Tokens (Style: Monolith 镜面不锈钢)
   冷白 #F7F8F8 · 石墨黑 #101214 · 钢渐变 #DFE3E6→#8B949C
   Fonts: Fraunces (display serif) / Inter (body) / IBM Plex Mono (utility)
   从零产出 · 禁止跨站复制
   ═══════════════════════════════════════════════════════════ */

:root {
  /* color */
  --paper: #F7F8F8;
  --paper-2: #EFF1F1;
  --ink: #101214;
  --ink-2: #1B1E21;
  --steel-a: #DFE3E6;
  --steel-b: #8B949C;
  --steel-c: #4A5257;
  --line: #E2E5E7;
  --line-2: #C9CDD0;
  --mut: #6A7377;
  --mut-2: #8B9398;
  --on-dark: #EDEFEF;
  --on-dark-mut: #9AA2A6;
  --on-dark-line: rgba(255,255,255,.09);
  --white: #FFFFFF;

  /* steel gradient signature */
  --steel-grad: linear-gradient(90deg, #DFE3E6, #8B949C 50%, #DFE3E6);
  --steel-grad-v: linear-gradient(180deg, #DFE3E6, #8B949C);
  --steel-grad-text: linear-gradient(90deg, #8B949C, #4A5257);

  /* type */
  --font-display: 'Fraunces', Georgia, serif;
  --font-body: 'Inter', -apple-system, 'Segoe UI', sans-serif;
  --font-mono: 'IBM Plex Mono', 'Courier New', monospace;

  --fs-h1: clamp(38px, 5.2vw, 58px);
  --fs-h2: clamp(26px, 3.2vw, 34px);
  --fs-h3: 20px;
  --fs-body: 15.5px;
  --fs-small: 14px;
  --fs-mono: 12px;

  --lh-tight: 1.12;
  --lh-body: 1.7;

  /* space */
  --sp-1: 8px; --sp-2: 16px; --sp-3: 24px; --sp-4: 40px;
  --sp-5: 64px; --sp-6: 96px; --sp-7: 128px;
  --sec-pad: clamp(56px, 8vw, 104px);
  --title-mb: 20px;          /* 标题-内容节奏 ≥16px（硬约束 43） */

  /* shape */
  --r-sm: 8px; --r-md: 12px; --r-lg: 16px; --r-pill: 99px;
  --shadow-card: 0 2px 14px rgba(16,18,20,.05);
  --shadow-float: 0 14px 40px rgba(16,18,20,.10);
  --shadow-win: 0 18px 44px rgba(16,18,20,.16);

  /* layout */
  --container: 1160px;
  --nav-h: 72px;

  /* motion */
  --t-fast: .18s ease;
  --t-med: .28s cubic-bezier(.4,0,.2,1);
}

/* ── base ─────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
html, body { overflow-x: clip; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: var(--fs-body);
  line-height: var(--lh-body);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4 { font-family: var(--font-display); font-weight: 600; line-height: var(--lh-tight); letter-spacing: -.02em; margin-bottom: var(--title-mb); }
h1 { font-size: var(--fs-h1); }
h2 { font-size: var(--fs-h2); }
h3 { font-size: var(--fs-h3); }
p { margin: 0 0 var(--sp-2); }
.container { max-width: var(--container); margin: 0 auto; padding: 0 var(--sp-3); }
main { min-height: 60vh; }
::selection { background: var(--steel-a); color: var(--ink); }

/* ── signature: steel rule（签名元素，全站限量 ≤8 处） ── */
.steel-rule { height: 1.5px; background: var(--steel-grad); border: 0; margin: 0; }
.steel-rule--soft { background: linear-gradient(90deg, transparent, var(--steel-b) 30%, var(--steel-b) 70%, transparent); }

/* ── utility type ── */
.eyebrow {
  font-family: var(--font-mono); font-size: 14px; letter-spacing: .22em;
  text-transform: uppercase; color: var(--mut); margin-bottom: 22px; display: block;
}
.eyebrow--ink { color: var(--steel-c); }
.mono { font-family: var(--font-mono); }
.figline { font-family: var(--font-display); font-style: italic; font-size: 14px; color: var(--mut); }
.lead { font-size: 17px; color: var(--mut); line-height: 1.75; }

/* ── buttons（全站唯一 accent = 曜石黑） ── */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 28px; border-radius: var(--r-pill);
  font-size: 14px; font-weight: 500; font-family: var(--font-body);
  border: 1px solid transparent; cursor: pointer;
  transition: transform var(--t-fast), background var(--t-fast), border-color var(--t-fast);
  min-height: 48px;
}
.btn--p { background: var(--ink); color: var(--white); }
.btn--p:hover { background: var(--ink-2); transform: translateY(-1px); }
.btn--s { border-color: var(--line-2); color: var(--ink); background: transparent; }
.btn--s:hover { border-color: var(--steel-b); }
.btn--w { background: var(--white); color: var(--ink); }
.btn--w:hover { transform: translateY(-1px); }
.btn--ow { border-color: rgba(255,255,255,.45); color: var(--on-dark); background: transparent; }
.btn--ow:hover { border-color: var(--on-dark); }

/* ── sections ── */
.section { padding: var(--sec-pad) 0; }
.section--tint { background: var(--paper-2); }
.section--white { background: var(--white); }
.section--dark { background: var(--ink); color: var(--on-dark); }
.section--dark h2, .section--dark h3 { color: var(--white); }
.section-head { max-width: 720px; margin-bottom: var(--sp-4); }
.section-head--center { margin-left: auto; margin-right: auto; text-align: center; }

/* ── grids（卡片数必须=列数整倍数，硬约束 21） ── */
.grid { display: grid; gap: var(--sp-3); }
.grid > * { min-width: 0; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 980px) { .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; } }

/* ── split 图文分屏（图文同高，排除清单项） ── */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: var(--sp-5); align-items: stretch; }
.split.rev .split-media { order: 2; }
.split-media { border-radius: var(--r-md); overflow: hidden; min-width: 0; aspect-ratio: auto; }
.split-media img { width: 100%; height: 100%; object-fit: cover; }
.split-body { display: flex; flex-direction: column; justify-content: center; }
@media (max-width: 880px) {
  .split { grid-template-columns: 1fr; gap: var(--sp-3); }
  .split.rev .split-media { order: 0; }
}

/* ── 图片位 aspect 容器（比例白名单 3/2 · 2/3 · 1/1） ── */
.ar-3-2 { aspect-ratio: 3 / 2; }
.ar-2-3 { aspect-ratio: 2 / 3; }
.ar-1-1 { aspect-ratio: 1 / 1; }
.frame-img { position: relative; overflow: hidden; border-radius: var(--r-md); background: var(--paper-2); }
.frame-img img { width: 100%; height: 100%; object-fit: cover; }
.frame-img img.img-1-1 { aspect-ratio: 1 / 1; }

/* ── 数据表 ── */
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
table.spec { width: 100%; border-collapse: collapse; font-size: 14px; }
table.spec th {
  font-family: var(--font-mono); font-size: 14px; letter-spacing: .08em; text-transform: uppercase;
  text-align: left; color: var(--mut); font-weight: 500;
  padding: 12px 16px; border-bottom: 1.5px solid var(--steel-b); white-space: nowrap;
}
table.spec td { padding: 13px 16px; border-bottom: 1px solid var(--line); vertical-align: top; }
table.spec td:first-child { color: var(--ink); font-weight: 500; }
table.spec tr td:not(:first-child) { font-family: var(--font-mono); font-size: 14px; color: var(--ink-2); }

/* ── FAQ ── */
.faq-item { border-bottom: 1px solid var(--line); }
.faq-q {
  width: 100%; display: flex; justify-content: space-between; align-items: center; gap: 16px;
  padding: 20px 4px; background: none; border: 0; cursor: pointer;
  font-family: var(--font-body); font-size: 15.5px; font-weight: 500; color: var(--ink); text-align: left;
  min-height: 48px;
}
.faq-q::after { content: '+'; font-family: var(--font-mono); font-size: 18px; color: var(--steel-b); transition: transform var(--t-med); flex-shrink: 0; }
.faq-item.open .faq-q::after { transform: rotate(45deg); }
.faq-a { max-height: 0; overflow: hidden; visibility: hidden; transition: max-height var(--t-med), visibility var(--t-med); }
.faq-item.open .faq-a { visibility: visible; }
.faq-a p { padding: 0 4px 20px; color: var(--mut); margin: 0; }

/* ── cards ── */
.card {
  background: var(--white); border: 1px solid var(--line); border-radius: var(--r-md);
  padding: var(--sp-4) var(--sp-3); position: relative;
  transition: transform var(--t-fast), box-shadow var(--t-fast);
}
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow-float); }
.card--tint { background: var(--paper-2); border-color: transparent; }
.card h3, .card h4 { position: relative; }
.card .mono-tag { font-family: var(--font-mono); font-size: 14px; letter-spacing: .06em; color: var(--steel-c); }

/* card 顶部钢线（X1 变体签名用法，限量） */
.card--steel::before { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px; background: var(--steel-grad-v); }

/* ── reveal 动效 ── */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity .7s ease, transform .7s cubic-bezier(.4,0,.2,1); }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; transition: none; } html { scroll-behavior: auto; } }

/* ── a11y ── */
:focus-visible { outline: 2px solid var(--steel-c); outline-offset: 3px; border-radius: 4px; }
.skip-link { position: absolute; left: -9999px; top: 0; background: var(--ink); color: var(--white); padding: 10px 18px; z-index: 99; border-radius: 0 0 8px 0; }
.skip-link:focus { left: 0; }

/* 硬编码浅色值禁令（硬约束 29）：深色区块内一律用上面 token */
