@tailwind base;
@tailwind components;
@tailwind utilities;

:root {
  --primary: #0A1F5C;
  --secondary: #1A3D7A;
  --accent: #007BFF;
  --cyan: #00F7FF;
}

body {
  font-family: 'Inter', 'Microsoft YaHei', sans-serif;
  color: #F8FAFC;
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
}

/* 视频背景 */
.video-bg {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -1;
  opacity: 0.8;
}

/* 科技感背景线条 */
.bg-tech {
  position: relative;
}

.bg-tech::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(10, 31, 92, 0.85);
  pointer-events: none;
  z-index: 0;
}

/* 毛玻璃效果 */
.glass {
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
}

/* 蓝色渐变文字 */
.text-gradient {
  background: linear-gradient(90deg, #007BFF, #00F7FF);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* 发光边框 */
.glow-border {
  border: 1px solid rgba(0, 123, 255, 0.5);
  box-shadow: 0 0 10px rgba(0, 123, 255, 0.5);
  transition: all 0.3s ease;
}

.glow-border:hover {
  box-shadow: 0 0 20px rgba(0, 123, 255, 0.8);
  transform: translateY(-5px);
}

/* 粒子效果 */
.particles {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
}

.particle {
  position: absolute;
  width: 2px;
  height: 2px;
  background: rgba(0, 247, 255, 0.6);
  border-radius: 50%;
  animation: float 6s ease-in-out infinite;
}

/* 按钮样式 */
.btn-primary {
  background: linear-gradient(90deg, var(--primary), var(--secondary));
  border: 1px solid rgba(0, 123, 255, 0.5);
  box-shadow: 0 0 10px rgba(0, 123, 255, 0.5);
  transition: all 0.3s ease;
}

.btn-primary:hover {
  box-shadow: 0 0 20px rgba(0, 123, 255, 0.8);
  transform: translateY(-2px);
}

/* 输入框样式 */
.input-tech {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(0, 123, 255, 0.5);
  transition: all 0.3s ease;
}

.input-tech:focus {
  outline: none;
  box-shadow: 0 0 10px rgba(0, 123, 255, 0.8);
  border-color: #00F7FF;
}

/* 卡片样式 */
.card-tech {
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
  transition: all 0.3s ease;
}

.card-tech:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 40px 0 rgba(0, 0, 0, 0.5);
  border-color: rgba(0, 123, 255, 0.5);
}

/* 时间轴样式 */
.timeline {
  position: relative;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(to bottom, #007BFF, #00F7FF);
  transform: translateX(-50%);
}

.timeline-item {
  position: relative;
  margin-bottom: 2rem;
}

.timeline-item::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 0;
  width: 16px;
  height: 16px;
  background: #0A1F5C;
  border: 2px solid #00F7FF;
  border-radius: 50%;
  transform: translateX(-50%);
  box-shadow: 0 0 10px rgba(0, 247, 255, 0.5);
}

/* 折叠面板样式 */
.collapse-panel {
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  margin-bottom: 1rem;
  border-radius: 8px;
  overflow: hidden;
  transition: all 0.3s ease;
}

.collapse-panel:hover {
  border-color: rgba(0, 123, 255, 0.5);
}

.collapse-header {
  padding: 1rem;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: all 0.3s ease;
}

.collapse-header:hover {
  background: rgba(0, 123, 255, 0.1);
}

.collapse-content {
  padding: 0 1rem;
  max-height: 0;
  overflow: hidden;
  transition: all 0.3s ease;
}

.collapse-content.active {
  padding: 1rem;
  max-height: 500px;
}

/* 导航栏滚动效果 */
.navbar {
  transition: all 0.3s ease;
  white-space: nowrap;
}

.navbar.scrolled {
  background: rgba(10, 31, 92, 0.9);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

/* 导航菜单 */
.navbar .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.navbar .md\:flex {
  flex-shrink: 0;
}

.navbar .md\:flex a {
  white-space: nowrap;
}

/* 导航项高亮状态 */
.navbar .nav-item.active {
  color: #00F7FF;
  font-weight: 600;
  text-shadow: 0 0 10px rgba(0, 247, 255, 0.5);
}

/* 响应式调整 */
@media (max-width: 1280px) {
  .navbar .md\:px-12 {
    padding-left: 1rem;
    padding-right: 1rem;
  }
  
  .navbar .space-x-8 {
    gap: 1rem;
  }
}

@media (max-width: 1024px) {
  .navbar .md\:flex {
    display: none;
  }
  
  .navbar .md\:hidden {
    display: block;
  }
}

/* 响应式调整 */
@media (max-width: 768px) {
  .timeline::before {
    left: 20px;
  }
  
  .timeline-item::before {
    left: 20px;
    transform: none;
  }
  
  .timeline-content {
    margin-left: 50px;
  }
}

/* 加载动画 */
.loading {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  border-top-color: #00F7FF;
  animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* 平滑滚动 */
html {
  scroll-behavior: smooth;
}

/* 轮播图样式 */
.carousel {
  position: relative;
  overflow: hidden;
}

.carousel-inner {
  display: flex;
  transition: transform 0.5s ease;
}

.carousel-item {
  min-width: 100%;
}

/* 图标样式 */
.icon-tech {
  color: #00F7FF;
  filter: drop-shadow(0 0 5px rgba(0, 247, 255, 0.5));
  transition: all 0.3s ease;
}

.icon-tech:hover {
  filter: drop-shadow(0 0 10px rgba(0, 247, 255, 0.8));
  transform: scale(1.1);
}