/* file: assets/css/style.css */
/* 中文：全站样式（保留你原来的赛博风变量、按钮、卡片、粒子、光标、动画与响应式） */

:root {
  --bg-color: #050505;
  --text-color: #e0e0e0;
  --accent-color: #00f3ff; /* Cyber Cyan */
  --accent-glow: rgba(0, 243, 255, 0.4);
  --card-bg: rgba(255, 255, 255, 0.03);
  --glass-border: rgba(255, 255, 255, 0.1);
}

* { margin: 0; padding: 0; box-sizing: border-box; scroll-behavior: smooth; }

body {
  font-family: 'Inter', sans-serif;
  background-color: var(--bg-color);
  color: var(--text-color);
  line-height: 1.6;
  overflow-x: hidden;
  cursor: default; /* 中文：JS 正常后再隐藏默认光标，避免 JS 报错导致无光标 */
}

body.custom-cursor-active { cursor: none; }

a { text-decoration: none; color: inherit; transition: 0.3s; }
ul { list-style: none; }

.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.tech-font { font-family: 'Orbitron', sans-serif; letter-spacing: 2px; text-transform: uppercase; }

.btn {
  display: inline-block;
  padding: 12px 30px;
  border: 1px solid var(--accent-color);
  color: var(--accent-color);
  font-family: 'Orbitron', sans-serif;
  font-size: 0.9rem;
  position: relative;
  overflow: hidden;
  background: transparent;
  transition: all 0.4s ease;
  z-index: 10;
}
.btn:hover { background: var(--accent-color); color: #000; box-shadow: 0 0 20px var(--accent-glow); }
.btn.alt { border-color: #fff; color: #fff; }
.btn.alt:hover { background: #fff; color: #000; box-shadow: 0 0 20px rgba(255,255,255,.2); }

/* --- BACKGROUND CANVAS --- */
#particle-canvas {
  position: fixed; top: 0; left: 0;
  width: 100%; height: 100%;
  z-index: -1;
  pointer-events: none;
}

/* --- CUSTOM CURSOR --- */
.cursor-dot, .cursor-outline {
  position: fixed; top: 0; left: 0;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  z-index: 9999;
  pointer-events: none;
  display: none;
}
body.custom-cursor-active .cursor-dot,
body.custom-cursor-active .cursor-outline { display: block; }

.cursor-dot { width: 8px; height: 8px; background-color: var(--accent-color); }
.cursor-outline {
  width: 40px; height: 40px;
  border: 1px solid rgba(255, 255, 255, 0.5);
  transition: width 0.2s, height 0.2s, background-color 0.2s;
  will-change: transform;
}
body.hovering .cursor-outline {
  width: 60px; height: 60px;
  background-color: rgba(255, 255, 255, 0.1);
  border-color: var(--accent-color);
  backdrop-filter: blur(2px);
}

/* --- Header --- */
header {
  position: fixed;
  top: 0; width: 100%;
  padding: 20px 0;
  z-index: 1000;
  background: rgba(5, 5, 5, 0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255,255,255,0.05);
  transition: all 0.3s;
}
nav { display: flex; justify-content: space-between; align-items: center; }

.logo { font-size: 1.5rem; font-weight: 900; color: #fff; letter-spacing: 3px; }
.logo span { color: var(--accent-color); }

.nav-links { display: flex; gap: 40px; }
.nav-links a { font-size: 0.9rem; opacity: 0.7; position: relative; }
.nav-links a:hover { opacity: 1; color: var(--accent-color); }
.nav-links a[aria-current="page"] { opacity: 1; color: var(--accent-color); }

/* Mobile Menu */
.menu-toggle { display: none; flex-direction: column; gap: 6px; cursor: pointer; z-index: 1001; }
.bar { width: 25px; height: 2px; background-color: #fff; transition: 0.3s; }

/* --- Main spacing (new) --- */
/* 中文：因为 header 是 fixed，这里给所有页面主内容留出顶部空间 */
main { padding-top: 92px; }

/* --- Home Hero (保留你原来的 hero) --- */
.hero {
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}
.hero-bg {
  position: absolute; top: 0; left: 0;
  width: 100%; height: 100%;
  background: url('https://images.unsplash.com/photo-1542282088-fe8426682b8f?q=80&w=2070&auto=format&fit=crop') no-repeat center center/cover;
  opacity: 0.4;
  z-index: 0;
  filter: grayscale(100%) contrast(110%);
}
.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 900px;
  padding: 0 20px;
}
.hero h1 {
  font-size: clamp(2.5rem, 8vw, 5.5rem);
  line-height: 1.1;
  margin-bottom: 20px;
  background: linear-gradient(to bottom, #ffffff, #888888);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
.hero p {
  font-size: clamp(1rem, 4vw, 1.3rem);
  margin-bottom: 22px;
  color: #ddd;
  font-weight: 300;
}

/* --- Generic page hero (new, for inner pages) --- */
.page-hero { padding: 90px 0 40px; position: relative; z-index: 2; }
.page-hero h1 {
  font-size: clamp(2rem, 5vw, 3.2rem);
  line-height: 1.15;
  margin-bottom: 14px;
  background: linear-gradient(to bottom, #ffffff, #888888);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
.page-hero p { color: #bbb; font-weight: 300; max-width: 920px; }

/* --- Sections --- */
.features, .products, .stats, .contact, .section {
  position: relative;
  z-index: 2;
}
.features { padding: 100px 0; }

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
}
.feature-card {
  background: var(--card-bg);
  border: 1px solid var(--glass-border);
  padding: 40px;
  border-radius: 4px;
  transition: 0.3s;
  position: relative;
  backdrop-filter: blur(5px);
}
.feature-card:hover { transform: translateY(-10px); background: rgba(255, 255, 255, 0.08); }
.feature-icon { font-size: 2rem; margin-bottom: 20px; color: var(--accent-color); }
.feature-title { font-size: 1.2rem; margin-bottom: 15px; color: #fff; }
.feature-desc { font-size: 0.9rem; color: #aaa; }

/* Products */
.products { padding: 100px 0; background: #080808; }

.section-header {
  margin-bottom: 60px;
  text-align: left;
  border-left: 3px solid var(--accent-color);
  padding-left: 20px;
}
.section-header p { color: #aaa; }

.product-showcase { display: flex; flex-wrap: wrap; }
.product-item { flex: 1 1 50%; height: 400px; position: relative; overflow: hidden; }
.product-img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s ease; }
.product-overlay {
  position: absolute; bottom: 0; left: 0; width: 100%;
  padding: 40px;
  background: linear-gradient(to top, rgba(0,0,0,0.95), transparent);
  transform: translateY(20px);
  opacity: 0;
  transition: 0.4s;
}
.product-item:hover .product-img { transform: scale(1.1); }
.product-item:hover .product-overlay { transform: translateY(0); opacity: 1; }

/* Stats */
.stats { padding: 80px 0; background: #0a0a0a; border-top: 1px solid #222; }
.stats-grid { display: flex; justify-content: space-around; text-align: center; flex-wrap: wrap; }
.stat-item h3 { font-size: 3rem; color: var(--accent-color); }

/* Contact */
.contact { padding: 100px 0; text-align: center; }

/* Simple footer (new) */
.footer {
  padding: 40px 0;
  border-top: 1px solid rgba(255,255,255,0.08);
  background: #050505;
  color: #777;
  position: relative;
  z-index: 2;
}
.footer .row {
  display: flex;
  gap: 20px;
  justify-content: space-between;
  flex-wrap: wrap;
}
.footer a { color: #aaa; }
.footer a:hover { color: var(--accent-color); }

/* --- Animation --- */
.fade-in-init {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.8s ease-out;
}
.fade-in-visible { opacity: 1; transform: translateY(0); }

/* --- Responsive --- */
@media (max-width: 768px) {
  .nav-links {
    position: fixed;
    top: 0; right: -100%;
    height: 100vh; width: 70%;
    background: #000;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    transition: 0.4s;
    z-index: 999;
    border-left: 1px solid #333;
  }
  .nav-links.active { right: 0; }
  .menu-toggle { display: flex; }

  .menu-toggle.active .bar:nth-child(1) { transform: rotate(45deg) translate(5px, 6px); }
  .menu-toggle.active .bar:nth-child(2) { opacity: 0; }
  .menu-toggle.active .bar:nth-child(3) { transform: rotate(-45deg) translate(5px, -6px); }

  .product-item { flex: 1 1 100%; height: 300px; }
  .stats-grid { flex-direction: column; gap: 40px; }

  body.custom-cursor-active { cursor: auto; }
  .cursor-dot, .cursor-outline { display: none !important; }
}
