
:root {
  --primary: #1E3C72;
  --secondary: #2A5298;
  --accent: #FF7E5F;
  --light: #F8F9FA;
  --dark: #212529;
  --gray: #6C757D;
}

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

body {
  font-family: 'Roboto', sans-serif;
  line-height: 1.6;
  letter-spacing: 0.5px;
  color: var(--dark);
  background: linear-gradient(135deg, #f5f7fa 0%, #e4e8eb 100%);
  overflow-x: hidden;
}

.header {
  position: relative;
  height: 80vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 2rem;
  background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 50%, var(--accent) 100%);
  color: white;
  clip-path: polygon(0 0, 100% 0, 100% 85%, 0 100%);
  margin-bottom: 4rem;
}

.header::after {
  content: "这是一个网页样式设计参考";
  position: absolute;
  bottom: 1rem;
  right: 1rem;
  font-size: 0.8rem;
  opacity: 0.7;
}

.nav {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background: rgba(255,255,255,0.9);
  backdrop-filter: blur(10px);
  box-shadow: 0 2px 10px rgba(0,0,0,0.1);
  z-index: 1000;
  padding: 1rem 2rem;
}

.nav-list {
  display: flex;
  justify-content: center;
  list-style: none;
  gap: 2rem;
}

.nav-link {
  color: var(--primary);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.3s;
  position: relative;
}

.nav-link:hover {
  color: var(--accent);
}

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

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

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}

.article {
  background: white;
  border-radius: 15px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.05);
  padding: 3rem;
  margin-bottom: 4rem;
}

h2, h3 {
  color: var(--primary);
  margin: 2rem 0 1rem;
  position: relative;
}

h2 {
  font-size: 2.2rem;
  padding-bottom: 0.5rem;
}

h2::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100px;
  height: 4px;
  background: var(--accent);
  border-radius: 2px;
}

h3 {
  font-size: 1.6rem;
}

p {
  margin-bottom: 1.5rem;
  font-size: 1.1rem;
  color: var(--dark);
}

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

.img-card {
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 5px 15px rgba(0,0,0,0.1);
  transition: transform 0.3s, box-shadow 0.3s;
}

.img-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 15px 30px rgba(0,0,0,0.15);
}

.img-card img {
  width: 100%;
  height: 250px;
  object-fit: cover;
  display: block;
}

pre {
  background: #f8f9fa;
  border-radius: 8px;
  padding: 1.5rem;
  margin: 2rem 0;
  overflow: auto;
  border-left: 4px solid var(--accent);
  font-family: 'Courier New', monospace;
  font-size: 0.9rem;
  line-height: 1.5;
}

code {
  background: #f8f9fa;
  padding: 0.2rem 0.4rem;
  border-radius: 4px;
  font-family: 'Courier New', monospace;
  font-size: 0.9rem;
  color: var(--primary);
}

.footer {
  text-align: center;
  padding: 2rem;
  background: var(--primary);
  color: white;
  margin-top: 4rem;
}

.scroll-element {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s, transform 0.6s;
}

.scroll-element.visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 768px) {
  .header {
    height: 60vh;
    padding: 1rem;
  }
  
  .nav-list {
    gap: 1rem;
  }
  
  .article {
    padding: 2rem 1.5rem;
  }
  
  h2 {
    font-size: 1.8rem;
  }
  
  h3 {
    font-size: 1.4rem;
  }
}

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

.floating {
  animation: float 3s ease-in-out infinite;
}

