/* ==========================================================================
   HASH GAME · wire/base.css
   Section 0 —— 设计令牌、重置、排版基线
   设计语言：SPEC SHEET（技术规格书）—— 浅灰纸面 + 发丝线 + 条形码哈希纹
   ========================================================================== */

/* ===== SECTION: tokens ===== */

:root {
  /* 墨色 */
  --hx-ink: #101519;
  --hx-ink-2: #2c353c;
  --hx-mute: #657079;
  --hx-faint: #8b949b;

  /* 纸面 */
  --hx-paper: #eceeef;
  --hx-sheet: #fafaf8;
  --hx-deep: #0c1116;
  --hx-deep-2: #151c22;

  /* 线 */
  --hx-line: #c6ccd0;
  --hx-line-soft: #dfe3e5;
  --hx-line-deep: #2a343c;

  /* 信号色 */
  --hx-signal: #d63b1e;
  --hx-signal-soft: #f8e6e1;
  --hx-teal: #0c6b64;
  --hx-teal-soft: #dceceb;
  --hx-amber: #b8810f;

  /* 字体 */
  --hx-sans: "PingFang SC", "Segoe UI", "Microsoft YaHei", "Hiragino Sans GB", Arial, sans-serif;
  --hx-mono: "Cascadia Mono", "JetBrains Mono", "SFMono-Regular", Consolas, "Courier New", monospace;

  /* 尺度 */
  --hx-wrap: 1240px;
  --hx-gut: 32px;
  --hx-fs-display: clamp(2.55rem, 5.2vw, 4.35rem);
  --hx-fs-h2: clamp(1.65rem, 2.8vw, 2.4rem);
  --hx-fs-h3: clamp(1.12rem, 1.5vw, 1.34rem);
  --hx-fs-body: 1rem;
  --hx-fs-sm: 0.875rem;
  --hx-fs-xs: 0.75rem;

  /* 节奏 */
  --hx-pad-sec: clamp(56px, 7vw, 104px);
  --hx-shadow: 6px 6px 0 rgba(16, 21, 25, 0.06);
  --hx-shadow-hi: 8px 8px 0 rgba(214, 59, 30, 0.14);
}


/* ===== SECTION: reset ===== */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
}

h1,
h2,
h3,
h4,
h5,
h6,
p,
figure,
blockquote,
dl,
dd,
ul,
ol {
  margin: 0;
  padding: 0;
}

ul,
ol {
  list-style: none;
}

img,
svg,
video {
  display: block;
  max-width: 100%;
}

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

button {
  cursor: pointer;
  background: none;
  border: 0;
}

a {
  color: inherit;
  text-decoration: none;
}

table {
  border-collapse: collapse;
  width: 100%;
}


/* ===== SECTION: base ===== */

body {
  font-family: var(--hx-sans);
  font-size: var(--hx-fs-body);
  line-height: 1.76;
  color: var(--hx-ink-2);
  background-color: var(--hx-paper);
  background-image:
    linear-gradient(90deg, rgba(16, 21, 25, 0.045) 1px, transparent 1px),
    linear-gradient(rgba(16, 21, 25, 0.045) 1px, transparent 1px);
  background-size: 56px 56px;
  background-position: -1px -1px;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3,
h4 {
  color: var(--hx-ink);
  font-weight: 700;
  line-height: 1.18;
  letter-spacing: -0.015em;
}

h1 {
  font-size: var(--hx-fs-display);
  letter-spacing: -0.03em;
}

h2 {
  font-size: var(--hx-fs-h2);
}

h3 {
  font-size: var(--hx-fs-h3);
  line-height: 1.4;
}

p {
  text-wrap: pretty;
}

strong {
  color: var(--hx-ink);
  font-weight: 700;
}

::selection {
  background: var(--hx-signal);
  color: #fff;
}

:focus-visible {
  outline: 2px solid var(--hx-signal);
  outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
  }
}
