/* ============================
   Theme · Cyberpunk Tech
   ============================ */

:root {
  /* 基础色板 */
  --bg: #05060A;
  --bg-elev: #0E1118;
  --bg-elev-2: #131726;
  --border: #1A2233;
  --border-strong: #2A3650;
  --text: #E6F1FF;
  --text-dim: #7A8AA6;
  --text-faint: #4A5A78;

  /* 霓虹强调色 */
  --neon-cyan: #00E5FF;
  --neon-purple: #7C5CFF;
  --neon-green: #39FF88;
  --neon-pink: #FF4FCB;
  --neon-yellow: #FFD166;

  /* 语义色 */
  --primary: var(--neon-cyan);
  --accent: var(--neon-purple);
  --success: var(--neon-green);
  --warning: var(--neon-yellow);
  --danger: #FF5577;

  /* 字体 */
  --font-display: "Orbitron", "Rajdhani", "HarmonyOS Sans SC", "PingFang SC", sans-serif;
  --font-body: "Inter", "HarmonyOS Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
  --font-mono: "JetBrains Mono", "Fira Code", "Cascadia Code", Consolas, monospace;

  /* 圆角 */
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-xl: 24px;

  /* 阴影 */
  --shadow-card: 0 8px 24px rgba(0, 0, 0, 0.45);
  --shadow-glow-cyan: 0 0 24px rgba(0, 229, 255, 0.35);
  --shadow-glow-purple: 0 0 24px rgba(124, 92, 255, 0.35);
  --shadow-glow-green: 0 0 24px rgba(57, 255, 136, 0.35);

  /* 布局 */
  --container-max: 1200px;
  --container-px: 24px;
  --nav-h: 64px;

  /* 动画 */
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
  --t-fast: 0.18s;
  --t-base: 0.3s;
  --t-slow: 0.6s;
}

/* ============================
   全局背景
   ============================ */

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(ellipse 60% 40% at 20% 0%, rgba(0, 229, 255, 0.10), transparent 60%),
    radial-gradient(ellipse 50% 40% at 100% 30%, rgba(124, 92, 255, 0.10), transparent 60%),
    linear-gradient(180deg, #05060A 0%, #06080F 50%, #05060A 100%);
  pointer-events: none;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background-image:
    linear-gradient(rgba(0, 229, 255, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 229, 255, 0.06) 1px, transparent 1px);
  background-size: 32px 32px;
  background-position: -1px -1px;
  pointer-events: none;
  mask-image: radial-gradient(ellipse 80% 60% at 50% 30%, #000 40%, transparent 100%);
  -webkit-mask-image: radial-gradient(ellipse 80% 60% at 50% 30%, #000 40%, transparent 100%);
}

/* ============================
   工具类
   ============================ */

.container {
  width: 100%;
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: var(--container-px);
}

.mono {
  font-family: var(--font-mono);
}

.text-dim { color: var(--text-dim); }
.text-cyan { color: var(--neon-cyan); }
.text-purple { color: var(--neon-purple); }
.text-green { color: var(--neon-green); }

.gradient-text {
  background: linear-gradient(120deg, var(--neon-cyan) 0%, var(--neon-purple) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.section {
  padding-block: 96px;
  position: relative;
}

.section--sm {
  padding-block: 56px;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 2.4vw, 2.2rem);
  margin-bottom: 36px;
  display: flex;
  align-items: center;
  gap: 12px;
  letter-spacing: 0.04em;
}

.section-title::before {
  content: "//";
  color: var(--neon-cyan);
  font-family: var(--font-mono);
  font-weight: 500;
  font-size: 0.85em;
  letter-spacing: 0.08em;
}

.section-title::after {
  content: "";
  flex: 0 0 80px;
  height: 1px;
  background: linear-gradient(90deg, var(--neon-cyan), transparent);
}

.section-subtitle {
  color: var(--text-dim);
  font-family: var(--font-mono);
  font-size: 0.9rem;
  margin: -24px 0 36px;
  letter-spacing: 0.04em;
}

.cursor-blink::after {
  content: "_";
  color: var(--neon-cyan);
  animation: blink 1s steps(1) infinite;
  margin-left: 4px;
  font-family: var(--font-mono);
}

@keyframes blink {
  50% { opacity: 0; }
}

/* 扫描线 */
.scanlines {
  position: relative;
  overflow: hidden;
}

.scanlines::after {
  content: "";
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    0deg,
    transparent 0,
    transparent 3px,
    rgba(0, 229, 255, 0.025) 3px,
    rgba(0, 229, 255, 0.025) 4px
  );
  pointer-events: none;
  z-index: 1;
}

.scanline-move {
  position: absolute;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--neon-cyan), transparent);
  box-shadow: 0 0 16px var(--neon-cyan);
  animation: scanline 6s linear infinite;
  z-index: 1;
  pointer-events: none;
  opacity: 0.6;
}

@keyframes scanline {
  0% { top: -5%; }
  100% { top: 105%; }
}

/* 通用动画 */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.8s var(--ease-out), transform 0.8s var(--ease-out);
}

.reveal.is-visible {
  opacity: 1;
  transform: none;
}

.reveal-stagger > * {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s var(--ease-out), transform 0.6s var(--ease-out);
}

.reveal-stagger.is-visible > * {
  opacity: 1;
  transform: none;
}

.reveal-stagger.is-visible > *:nth-child(1) { transition-delay: 0.05s; }
.reveal-stagger.is-visible > *:nth-child(2) { transition-delay: 0.12s; }
.reveal-stagger.is-visible > *:nth-child(3) { transition-delay: 0.20s; }
.reveal-stagger.is-visible > *:nth-child(4) { transition-delay: 0.28s; }
.reveal-stagger.is-visible > *:nth-child(5) { transition-delay: 0.36s; }
.reveal-stagger.is-visible > *:nth-child(6) { transition-delay: 0.44s; }

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-12px); }
}

@keyframes glow-pulse {
  0%, 100% { box-shadow: 0 0 12px rgba(0, 229, 255, 0.4); }
  50% { box-shadow: 0 0 28px rgba(0, 229, 255, 0.7); }
}

@keyframes gradient-shift {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}
