/* ════════════════════════════════════════════════════════════
   Zlink Technology — Shared Base Stylesheet
   参数化主色：--accent / --accent-rgb / --accent2，各页面可覆盖
   ════════════════════════════════════════════════════════════ */

:root {
  --accent: #00bfff;
  --accent-rgb: 0, 191, 255;
  --accent2: #00ff41;
  --accent2-rgb: 0, 255, 65;
  --bg: #000;
  --panel: rgba(10, 10, 12, 0.82);
  --text: #e2e2e2;
  --muted: #888;
  --dim: #555;
  --mono: 'Courier New', 'Consolas', monospace;
}

/* ── Reset & Base ── */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', sans-serif;
  background: var(--bg);
  color: var(--text);
  overflow-x: hidden;
  line-height: 1.6;
}

/* ── Matrix Canvas ── */
#matrix-canvas {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  z-index: 0;
  pointer-events: none;
}

/* ── Cursor Glow ── */
.cursor-glow {
  position: fixed;
  width: 420px; height: 420px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(var(--accent2-rgb), 0.07) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
  transform: translate(-50%, -50%);
  transition: left 0.1s, top 0.1s;
}

/* ── Navigation ── */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 48px;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(var(--accent-rgb), 0.15);
  transition: background 0.3s, border-color 0.3s;
}
nav.scrolled { background: rgba(0, 0, 0, 0.88); }
.logo {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--accent);
  text-shadow: 0 0 12px rgba(var(--accent-rgb), 0.6);
  letter-spacing: 3px;
  text-transform: uppercase;
  text-decoration: none;
}
.nav-links { display: flex; gap: 32px; list-style: none; align-items: center; }
.nav-links a {
  color: #aaa;
  text-decoration: none;
  font-size: 0.95rem;
  letter-spacing: 1px;
  transition: color 0.3s, text-shadow 0.3s;
  position: relative;
}
.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px; left: 0;
  width: 0; height: 2px;
  background: var(--accent);
  transition: width 0.3s;
}
.nav-links a:hover { color: var(--accent); text-shadow: 0 0 8px rgba(var(--accent-rgb), 0.5); }
.nav-links a:hover::after { width: 100%; }

/* 返回首页按钮 */
.back-home {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 18px;
  border: 1px solid rgba(var(--accent-rgb), 0.35);
  color: var(--accent);
  font-size: 0.85rem;
  letter-spacing: 1px;
  text-decoration: none;
  font-family: var(--mono);
  transition: all 0.3s;
}
.back-home:hover {
  background: rgba(var(--accent-rgb), 0.12);
  box-shadow: 0 0 18px rgba(var(--accent-rgb), 0.25);
}
.back-home svg { width: 14px; height: 14px; fill: currentColor; }

/* ── Sections ── */
section {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 120px 48px 80px;
}

/* ── Section Headers ── */
.section-header {
  text-align: center;
  margin-bottom: 64px;
}
.section-header h2 {
  font-size: clamp(1.8rem, 3.5vw, 2.6rem);
  color: #fff;
  letter-spacing: 3px;
  margin-bottom: 12px;
}
.section-header h2 span { color: var(--accent); }
.section-header p { color: var(--muted); font-size: 1.05rem; }
.section-line {
  width: 60px; height: 2px;
  background: var(--accent);
  margin: 16px auto 0;
  box-shadow: 0 0 10px rgba(var(--accent-rgb), 0.5);
}

/* ── Buttons ── */
.btn {
  padding: 14px 36px;
  border: 1px solid var(--accent);
  background: transparent;
  color: var(--accent);
  font-size: 1rem;
  letter-spacing: 1px;
  cursor: pointer;
  transition: all 0.3s;
  text-decoration: none;
  font-family: inherit;
  display: inline-block;
}
.btn:hover {
  background: var(--accent);
  color: #000;
  box-shadow: 0 0 30px rgba(var(--accent-rgb), 0.4);
}
.btn-filled {
  background: var(--accent);
  color: #000;
  font-weight: 600;
}
.btn-filled:hover {
  filter: brightness(1.1);
  box-shadow: 0 0 40px rgba(var(--accent-rgb), 0.5);
}

/* ── Fade-in on scroll ── */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ── Footer ── */
footer {
  position: relative;
  z-index: 1;
  text-align: center;
  padding: 32px;
  color: #444;
  font-size: 0.85rem;
  border-top: 1px solid rgba(var(--accent-rgb), 0.08);
  font-family: var(--mono);
  letter-spacing: 1px;
}

/* ── Animations ── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(30px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes pulseGlow {
  0%, 100% { opacity: 0.6; }
  50% { opacity: 1; }
}
@keyframes spinSlow {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-12px); }
}

/* ── Generic panel ── */
.panel {
  background: var(--panel);
  border: 1px solid rgba(var(--accent-rgb), 0.14);
  position: relative;
  overflow: hidden;
  transition: border-color 0.4s, box-shadow 0.4s, transform 0.4s;
}
.panel::before {
  content: '';
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 2px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  opacity: 0;
  transition: opacity 0.4s;
}
.panel:hover {
  border-color: rgba(var(--accent-rgb), 0.4);
  box-shadow: 0 18px 50px rgba(0,0,0,0.5), 0 0 30px rgba(var(--accent-rgb), 0.08);
}
.panel:hover::before { opacity: 1; }

/* corner ticks decoration */
.corners::after, .corners::before { /* placeholder for potential decoration */ }

.tick-corner {
  position: absolute;
  width: 14px; height: 14px;
  border-color: rgba(var(--accent-rgb), 0.5);
  border-style: solid;
  border-width: 0;
}
.tick-corner.tl { top: 8px; left: 8px; border-top-width: 2px; border-left-width: 2px; }
.tick-corner.tr { top: 8px; right: 8px; border-top-width: 2px; border-right-width: 2px; }
.tick-corner.bl { bottom: 8px; left: 8px; border-bottom-width: 2px; border-left-width: 2px; }
.tick-corner.br { bottom: 8px; right: 8px; border-bottom-width: 2px; border-right-width: 2px; }

/* monospace chip */
.mono { font-family: var(--mono); letter-spacing: 0.5px; }

/* ── Responsive ── */
@media (max-width: 768px) {
  nav { padding: 14px 20px; }
  .nav-links { gap: 14px; }
  .nav-links a { font-size: 0.82rem; }
  section { padding: 100px 20px 60px; }
  .back-home { padding: 6px 12px; font-size: 0.78rem; }
}
