/* ================================================================
   海联智达 AI数字员工 — 基础样式
   Reset / Typography / Global Elements
   ================================================================ */

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

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

body {
  background: var(--bg);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: var(--leading-normal);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

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

a {
  color: var(--primary);
  text-decoration: none;
  transition: color var(--fast) var(--ease-out);
}

a:hover {
  color: var(--primary-dark);
}

ul, ol {
  list-style: none;
}

button, input, select, textarea {
  font: inherit;
  color: inherit;
}

button {
  cursor: pointer;
  border: none;
  background: none;
}

table {
  border-collapse: collapse;
  width: 100%;
}

/* ── 排版 ── */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: var(--font-bold);
  line-height: var(--leading-tight);
  letter-spacing: -0.02em;
  color: var(--text-primary);
}

h1 { font-size: var(--text-hero); }
h2 { font-size: var(--text-3xl); margin-bottom: var(--space-4); }
h3 { font-size: var(--text-2xl); margin-bottom: var(--space-3); }
h4 { font-size: var(--text-xl);  margin-bottom: var(--space-2); }

p {
  margin-bottom: var(--space-4);
  text-wrap: pretty;
}

p:last-child { margin-bottom: 0; }

.eyebrow {
  font-size: var(--text-xs);
  font-weight: var(--font-bold);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--primary);
  margin-bottom: var(--space-3);
}

.section-desc {
  font-size: var(--text-lg);
  color: var(--text-secondary);
  max-width: 640px;
  text-wrap: pretty;
}

.text-secondary { color: var(--text-secondary); }
.text-tertiary  { color: var(--text-tertiary); }
.text-primary-c { color: var(--primary); }
.text-cta-c     { color: var(--cta); }
.mono           { font-family: var(--font-mono); }
.text-center    { text-align: center; }
.font-semibold  { font-weight: var(--font-semibold); }
.font-bold      { font-weight: var(--font-bold); }

/* ── 布局容器 ── */
.container {
  width: 100%;
  max-width: var(--container-xl);
  margin: 0 auto;
  padding: 0 var(--space-6);
}

.container-narrow {
  max-width: var(--container-md);
}

.container-wide {
  max-width: var(--container-2xl);
}

/* ── Section间距 ── */
.section {
  padding: var(--space-20) 0;
}

@media (min-width: 768px) {
  .section { padding: var(--space-24) 0; }
}

@media (min-width: 1024px) {
  .section { padding: var(--space-30) 0; }
}

/* ── 章节标题组 ── */
.section-header {
  margin-bottom: var(--space-12);
}

.section-header--center {
  text-align: center;
}

.section-header--center .section-desc {
  margin-left: auto;
  margin-right: auto;
}

/* ── 分隔线 ── */
.divider {
  border: none;
  border-top: 1px solid var(--border);
  margin: 0;
}

/* ── 选择高亮 ── */
::selection {
  background: oklch(0.48 0.15 250 / 0.15);
  color: var(--text-primary);
}

/* ── 焦点环 ── */
:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}

/* ── 滚动条（Webkit） ── */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: var(--radius-full);
}
::-webkit-scrollbar-thumb:hover { background: var(--text-tertiary); }
