/* ============================================================
   全局基础样式 · Reset / 排版 / 通用结构
   ============================================================ */

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

html {
  scroll-behavior: smooth;
  /* 锚点跳转让出固定头部高度 */
  scroll-padding-top: calc(var(--header-h) + 14px);
  -webkit-text-size-adjust: 100%;
}

body {
  min-height: 100vh;
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.7;
  color: var(--text-1);
  overflow-x: hidden;
  background:
    radial-gradient(1200px 800px at 85% -10%, rgba(61, 123, 255, 0.15), transparent 60%),
    radial-gradient(1000px 700px at -10% 30%, rgba(62, 230, 255, 0.06), transparent 55%),
    radial-gradient(900px 900px at 110% 88%, rgba(143, 107, 255, 0.08), transparent 60%),
    var(--bg-0);
}

/* 网格坐标底纹 */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(148, 180, 255, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(148, 180, 255, 0.045) 1px, transparent 1px);
  background-size: 56px 56px;
  -webkit-mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.95), rgba(0, 0, 0, 0.4) 45%, rgba(0, 0, 0, 0.75));
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.95), rgba(0, 0, 0, 0.4) 45%, rgba(0, 0, 0, 0.75));
}

/* 噪点颗粒，营造胶片质感 */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 999;
  pointer-events: none;
  opacity: 0.05;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)'/%3E%3C/svg%3E");
}

#app {
  position: relative;
  z-index: 1;
}

[v-cloak] {
  display: none;
}

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

a {
  color: inherit;
}

button {
  font-family: inherit;
}

ul,
ol {
  list-style: none;
}

h1,
h2,
h3,
h4 {
  font-weight: 700;
  line-height: 1.35;
}

::selection {
  background: rgba(61, 123, 255, 0.45);
  color: #fff;
}

::-webkit-scrollbar {
  width: 10px;
}
::-webkit-scrollbar-track {
  background: var(--bg-0);
}
::-webkit-scrollbar-thumb {
  background: rgba(90, 120, 200, 0.35);
  border-radius: 8px;
  border: 2px solid var(--bg-0);
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(62, 230, 255, 0.5);
}

:focus-visible {
  outline: 2px solid rgba(62, 230, 255, 0.75);
  outline-offset: 3px;
  border-radius: 4px;
}

.skip-link {
  position: fixed;
  top: -60px;
  left: 16px;
  z-index: 2000;
  padding: 10px 18px;
  font-size: 13px;
  color: #051226;
  background: var(--cyan);
  border-radius: 6px;
  text-decoration: none;
  transition: top 0.3s;
}
.skip-link:focus {
  top: 12px;
}

/* —— 通用布局 —— */
.container {
  width: min(var(--container), 100% - var(--gutter) * 2);
  margin-inline: auto;
}

.section {
  position: relative;
  padding-block: clamp(84px, 11vw, 136px);
}

/* —— 区块标题体系 —— */
.sec-tag {
  display: flex;
  align-items: center;
  gap: 14px;
  font-family: var(--font-disp);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  color: var(--cyan);
}
.sec-tag .idx {
  color: var(--text-3);
}
.sec-tag .rule {
  width: 64px;
  height: 1px;
  background: linear-gradient(90deg, var(--cyan), transparent);
}

.sec-title {
  margin-top: 18px;
  font-size: clamp(28px, 4.4vw, 44px);
  font-weight: 800;
  letter-spacing: 0.02em;
  line-height: 1.3;
}

.sec-lead {
  margin-top: 16px;
  max-width: 640px;
  color: var(--text-2);
  font-size: 15.5px;
  line-height: 2;
}

/* 渐变文字 */
.grad-text {
  background: var(--grad-main);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.grad-text-v {
  background: var(--grad-creative);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* —— 滚动显现系统（配合 v-reveal 指令） —— */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  will-change: opacity, transform;
}
.reveal.is-in {
  opacity: 1;
  transform: none;
  transition:
    opacity 0.9s var(--ease-out),
    transform 0.9s var(--ease-out);
  transition-delay: var(--d, 0s);
}

/* —— 减少动态偏好 —— */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .reveal {
    opacity: 1 !important;
    transform: none !important;
  }
}
