/* 全局样式 */
@import url('https://fonts.googleapis.com/css2?family=Orbitron:wght@400;500;600;700;800;900&family=Rajdhani:wght@300;400;500;600;700&family=Roboto:wght@100;300;400;500;700;900&display=swap');

:root {
  --primary-dark: #050A18;
  --secondary-dark: #0A1128;
  --accent-blue: #0070F3;
  --neon-cyan: #00FFFF;
  --neon-purple: #9D4EDD;
  --neon-pink: #FF00FF;
  --text-primary: #FFFFFF;
  --text-secondary: #B0BEC5;
  --grid-color: rgba(0, 255, 255, 0.1);
  --glow-cyan: 0 0 10px var(--neon-cyan), 0 0 20px rgba(0, 255, 255, 0.5);
  --glow-purple: 0 0 10px var(--neon-purple), 0 0 20px rgba(157, 78, 221, 0.5);
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Rajdhani', sans-serif;
  background-color: var(--primary-dark);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  background-image: 
    radial-gradient(circle at 25% 25%, rgba(0, 255, 255, 0.05) 0%, transparent 50%),
    radial-gradient(circle at 75% 75%, rgba(157, 78, 221, 0.05) 0%, transparent 50%);
}

/* 网格背景 */
body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: 
    linear-gradient(var(--grid-color) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-color) 1px, transparent 1px);
  background-size: 50px 50px;
  z-index: -1;
  animation: gridMove 20s linear infinite;
}

@keyframes gridMove {
  0% {
    background-position: 0 0;
  }
  100% {
    background-position: 50px 50px;
  }
}

/* 标题样式 */
h1, h2, h3, h4, h5, h6 {
  font-family: 'Orbitron', sans-serif;
  font-weight: 700;
  letter-spacing: 1px;
  margin-bottom: 1rem;
}

h1 {
  font-size: 3.5rem;
  background: linear-gradient(90deg, var(--neon-cyan), var(--neon-purple));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: var(--glow-cyan);
}

h2 {
  font-size: 2.5rem;
  background: linear-gradient(90deg, var(--neon-purple), var(--neon-cyan));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

h3 {
  font-size: 1.8rem;
  color: var(--neon-cyan);
}

h4 {
  font-size: 1.4rem;
  color: var(--neon-purple);
}

/* 段落和文本 */
p {
  font-size: 1.1rem;
  margin-bottom: 1.5rem;
  color: var(--text-secondary);
}

a {
  color: var(--neon-cyan);
  text-decoration: none;
  transition: all 0.3s ease;
}

a:hover {
  color: var(--neon-purple);
  text-shadow: var(--glow-purple);
}

/* 容器 */
.container {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
}

/* 导航栏 */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  background-color: rgba(5, 10, 24, 0.8);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(0, 255, 255, 0.2);
  padding: 1rem 0;
  transition: all 0.3s ease;
}

.navbar.scrolled {
  background-color: rgba(5, 10, 24, 0.95);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5);
}

.navbar-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  display: flex;
  align-items: center;
}

.logo img {
  height: 50px;
  margin-right: 1rem;
  filter: drop-shadow(var(--glow-cyan));
}

.logo-text {
  font-family: 'Orbitron', sans-serif;
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--text-primary);
}

.nav-links {
  display: flex;
  list-style: none;
}

.nav-links li {
  margin-left: 2rem;
}

.nav-links a {
  font-family: 'Orbitron', sans-serif;
  font-size: 1rem;
  font-weight: 500;
  position: relative;
  padding: 0.5rem 0;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--neon-cyan), var(--neon-purple));
  transition: width 0.3s ease;
}

.nav-links a:hover::after {
  width: 100%;
}

.burger {
  display: none;
  cursor: pointer;
}

.burger div {
  width: 25px;
  height: 3px;
  background-color: var(--neon-cyan);
  margin: 5px;
  transition: all 0.3s ease;
}

/* 按钮样式 */
.btn {
  display: inline-block;
  padding: 0.8rem 2rem;
  font-family: 'Orbitron', sans-serif;
  font-size: 1rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
  z-index: 1;
}

.btn-primary {
  background: linear-gradient(90deg, var(--neon-cyan), var(--neon-purple));
  color: var(--primary-dark);
  box-shadow: var(--glow-cyan);
}

.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 20px rgba(0, 255, 255, 0.3);
}

.btn-primary::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 0;
  height: 100%;
  background: linear-gradient(90deg, var(--neon-purple), var(--neon-cyan));
  transition: width 0.5s ease;
  z-index: -1;
}

.btn-primary:hover::after {
  width: 100%;
}

.btn-outline {
  background-color: transparent;
  border: 2px solid var(--neon-cyan);
  color: var(--neon-cyan);
}

.btn-outline:hover {
  background-color: rgba(0, 255, 255, 0.1);
  box-shadow: var(--glow-cyan);
}

/* 卡片样式 */
.card {
  background-color: rgba(10, 17, 40, 0.7);
  border-radius: 8px;
  padding: 2rem;
  margin-bottom: 2rem;
  border: 1px solid rgba(0, 255, 255, 0.2);
  transition: all 0.3s ease;
  backdrop-filter: blur(5px);
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
  border-color: var(--neon-cyan);
}

.card-title {
  font-size: 1.5rem;
  margin-bottom: 1rem;
  color: var(--neon-cyan);
}

/* 部分样式 */
.section {
  padding: 8rem 0;
  position: relative;
}

.section-title {
  text-align: center;
  margin-bottom: 4rem;
  position: relative;
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: -1rem;
  left: 50%;
  transform: translateX(-50%);
  width: 100px;
  height: 3px;
  background: linear-gradient(90deg, var(--neon-cyan), var(--neon-purple));
}

/* 页脚 */
.footer {
  background-color: var(--secondary-dark);
  border-top: 1px solid rgba(0, 255, 255, 0.2);
  padding: 3rem 0 1rem;
  position: relative;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin-bottom: 2rem;
}

.footer-section h3 {
  font-size: 1.3rem;
  margin-bottom: 1.5rem;
  position: relative;
  padding-bottom: 0.5rem;
}

.footer-section h3::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 50px;
  height: 2px;
  background: var(--neon-cyan);
}

.footer-section p,
.footer-section li {
  margin-bottom: 0.8rem;
  color: var(--text-secondary);
}

.footer-section ul {
  list-style: none;
}

.footer-section a {
  color: var(--text-secondary);
}

.footer-section a:hover {
  color: var(--neon-cyan);
}

.social-links {
  display: flex;
  gap: 1rem;
}

.social-links a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: rgba(0, 255, 255, 0.1);
  border: 1px solid rgba(0, 255, 255, 0.2);
  transition: all 0.3s ease;
}

.social-links a:hover {
  background-color: rgba(0, 255, 255, 0.2);
  box-shadow: var(--glow-cyan);
  transform: translateY(-3px);
}

.footer-bottom {
  text-align: center;
  padding-top: 2rem;
  border-top: 1px solid rgba(0, 255, 255, 0.1);
  color: var(--text-secondary);
}

/* 动画类 */
.fade-in {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.active {
  opacity: 1;
  transform: translateY(0);
}

/* 量子粒子效果 */
#particles-js {
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  z-index: -1;
}

/* 响应式设计 */
@media screen and (max-width: 768px) {
  h1 {
    font-size: 2.5rem;
  }
  
  h2 {
    font-size: 2rem;
  }
  
  .nav-links {
    position: absolute;
    right: 0;
    top: 70px;
    background-color: rgba(10, 17, 40, 0.95);
    width: 100%;
    flex-direction: column;
    align-items: center;
    padding: 2rem 0;
    clip-path: circle(0px at 90% -10%);
    -webkit-clip-path: circle(0px at 90% -10%);
    transition: all 0.5s ease-out;
    pointer-events: none;
    border-bottom: 1px solid rgba(0, 255, 255, 0.2);
  }
  
  .nav-links.active {
    clip-path: circle(1500px at 90% -10%);
    -webkit-clip-path: circle(1500px at 90% -10%);
    pointer-events: all;
  }
  
  .nav-links li {
    margin: 1rem 0;
    opacity: 0;
  }
  
  .nav-links li:nth-child(1) {
    transition: opacity 0.2s ease 0.2s;
  }
  
  .nav-links li:nth-child(2) {
    transition: opacity 0.2s ease 0.3s;
  }
  
  .nav-links li:nth-child(3) {
    transition: opacity 0.2s ease 0.4s;
  }
  
  .nav-links li:nth-child(4) {
    transition: opacity 0.2s ease 0.5s;
  }
  
  .nav-links li:nth-child(5) {
    transition: opacity 0.2s ease 0.6s;
  }
  
  .nav-links li:nth-child(6) {
    transition: opacity 0.2s ease 0.7s;
  }
  
  .nav-links li:nth-child(7) {
    transition: opacity 0.2s ease 0.8s;
  }
  
  .nav-links.active li {
    opacity: 1;
  }
  
  .burger {
    display: block;
  }
  
  .toggle .line1 {
    transform: rotate(-45deg) translate(-5px, 6px);
  }
  
  .toggle .line2 {
    opacity: 0;
  }
  
  .toggle .line3 {
    transform: rotate(45deg) translate(-5px, -6px);
  }
  
  .section {
    padding: 6rem 0;
  }
}

@media screen and (max-width: 480px) {
  h1 {
    font-size: 2rem;
  }
  
  h2 {
    font-size: 1.8rem;
  }
  
  .btn {
    padding: 0.7rem 1.5rem;
    font-size: 0.9rem;
  }
  
  .card {
    padding: 1.5rem;
  }
  
  .section {
    padding: 4rem 0;
  }
}

/* 加载动画 */
.loading-screen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: var(--primary-dark);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9999;
  transition: opacity 0.5s ease, visibility 0.5s ease;
}

.loading-screen.hidden {
  opacity: 0;
  visibility: hidden;
}

.loading-spinner {
  width: 80px;
  height: 80px;
  border: 4px solid rgba(0, 255, 255, 0.1);
  border-radius: 50%;
  border-top: 4px solid var(--neon-cyan);
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* 滚动指示器 */
.scroll-indicator {
  position: fixed;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  z-index: 100;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.scroll-indicator.visible {
  opacity: 1;
}

.scroll-text {
  font-family: 'Orbitron', sans-serif;
  font-size: 0.8rem;
  margin-bottom: 0.5rem;
  color: var(--neon-cyan);
  letter-spacing: 2px;
}

.scroll-line {
  width: 1px;
  height: 30px;
  background: linear-gradient(to bottom, var(--neon-cyan), transparent);
  animation: scrollPulse 2s infinite;
}

@keyframes scrollPulse {
  0% { opacity: 0.3; }
  50% { opacity: 1; }
  100% { opacity: 0.3; }
}

/* 页面过渡效果 */
.page-transition {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, var(--primary-dark), var(--secondary-dark));
  z-index: 9998;
  transform: translateX(100%);
  transition: transform 0.5s ease;
}

.page-transition.active {
  transform: translateX(0);
}

/* 自定义滚动条 */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: var(--primary-dark);
}

::-webkit-scrollbar-thumb {
  background: linear-gradient(var(--neon-cyan), var(--neon-purple));
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(var(--neon-purple), var(--neon-cyan));
}