
/* 全局样式 */
:root {
  --primary: #0d47a1;
  --secondary: #1976d2;
  --accent: #ff9800;
  --success: #4caf50;
  --text: #ffffff;
  --card-bg: rgba(255, 255, 255, 0.1);
}

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

body {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: var(--text);
  font-family: 'Roboto', sans-serif;
  line-height: 1.6;
  padding: 0;
  overflow-x: hidden;
}

/* 导航系统 */
.nav-container {
  position: fixed;
  top: 0;
  width: 100%;
  background: rgba(13, 71, 161, 0.9);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
  z-index: 1000;
  padding: 1rem 2rem;
}

.nav-links {
  display: flex;
  justify-content: center;
  gap: 2rem;
}

.nav-link {
  color: white;
  text-decoration: none;
  font-weight: 500;
  padding: 0.5rem 1rem;
  border-radius: 4px;
  transition: all 0.3s ease;
  position: relative;
}

.nav-link:hover {
  background: rgba(255, 255, 255, 0.2);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 0;
  height: 2px;
  background: var(--accent);
  transition: all 0.3s ease;
}

.nav-link:hover::after {
  width: 100%;
  left: 0;
}

/* 主内容区 */
.main-container {
  max-width: 1200px;
  margin: 6rem auto 3rem;
  padding: 0 2rem;
}

/* 卡片样式 */
.card {
  background: var(--card-bg);
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
  padding: 2rem;
  margin-bottom: 3rem;
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  transition: transform 0.3s, box-shadow 0.3s;
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.3);
}

/* 标题样式 */
h1, h2, h3, h4 {
  font-family: 'Bodoni', serif;
  margin-bottom: 1.5rem;
  color: var(--accent);
}

h1 {
  font-size: 2.5rem;
  text-align: center;
  margin: 2rem 0;
  background: linear-gradient(90deg, var(--accent), #fb8c00);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

h2 {
  font-size: 2rem;
  position: relative;
  padding-bottom: 0.5rem;
}

h2::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 60px;
  height: 3px;
  background: linear-gradient(90deg, var(--accent), transparent);
}

h3 {
  font-size: 1.5rem;
  margin-top: 2rem;
}

/* 段落样式 */
p {
  margin-bottom: 1.5rem;
  font-size: 1.1rem;
}

/* 代码块样式 */
pre {
  background: rgba(0, 0, 0, 0.3);
  border-radius: 8px;
  padding: 1.5rem;
  margin: 1.5rem 0;
  overflow: auto;
  border-left: 4px solid var(--accent);
}

code {
  font-family: 'Courier New', monospace;
  color: #f8f8f2;
}

/* 图片样式 */
.img-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
  margin: 2rem 0;
}

.img-card {
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
  transition: all 0.3s ease;
  position: relative;
}

.img-card:hover {
  transform: scale(1.03);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.3);
}

.img-card img {
  width: 100%;
  height: auto;
  display: block;
  transition: transform 0.5s ease;
}

.img-card:hover img {
  transform: scale(1.1);
}

/* 按钮样式 */
.btn {
  display: inline-block;
  padding: 0.8rem 1.5rem;
  border-radius: 6px;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.3s ease;
  margin: 0.5rem 0;
  border: none;
  cursor: pointer;
}

.btn-primary {
  background: linear-gradient(45deg, var(--accent), #fb8c00);
  color: white;
  box-shadow: 0 4px 8px rgba(251, 140, 0, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 12px rgba(251, 140, 0, 0.4);
}

.btn-success {
  background: linear-gradient(45deg, var(--success), #43a047);
  color: white;
  box-shadow: 0 4px 8px rgba(67, 160, 71, 0.3);
}

.btn-success:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 12px rgba(67, 160, 71, 0.4);
}

/* 浮动标签 */
.floating-label {
  position: absolute;
  top: 2rem;
  right: 2rem;
  background: rgba(255, 255, 255, 0.2);
  padding: 0.5rem 1rem;
  border-radius: 20px;
  font-size: 0.9rem;
  backdrop-filter: blur(5px);
  animation: float 3s ease-in-out infinite;
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

/* 响应式设计 */
@media (max-width: 768px) {
  .nav-links {
    flex-direction: column;
    gap: 0.5rem;
  }
  
  .main-container {
    margin-top: 8rem;
  }
  
  h1 {
    font-size: 2rem;
  }
  
  h2 {
    font-size: 1.5rem;
  }
  
  .img-container {
    grid-template-columns: 1fr;
  }
}

