
:root {
  --primary: #18191A;
  --secondary: #000000;
  --accent1: #3F51B5;
  --accent2: #673AB7;
  --accent3: #4CAF50;
  --text: rgba(255,255,255,0.85);
  --text-secondary: rgba(255,255,255,0.6);
}

body {
  font-family: 'Montserrat', 'Roboto', sans-serif;
  background: radial-gradient(circle at 20% 30%, var(--primary), var(--secondary));
  color: var(--text);
  line-height: 1.7;
  margin: 0;
  padding: 0;
  min-height: 100%;
}

.header {
  background: linear-gradient(90deg, var(--primary), rgba(0,0,0,0.8));
  padding: 1.5rem;
  position: relative;
  box-shadow: 0 0 25px rgba(63, 81, 181, 0.3);
}

.header::after {
  content: "这是一个网页样式设计参考";
  position: absolute;
  right: 2rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--accent3);
  font-size: 0.9rem;
  opacity: 0.8;
}

.nav {
  display: flex;
  gap: 2rem;
}

.nav a {
  color: var(--text);
  text-decoration: none;
  font-weight: 500;
  position: relative;
  padding: 0.5rem 0;
  transition: all 0.3s ease;
}

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

.nav a:hover {
  color: var(--accent3);
}

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

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

.hero {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  margin-bottom: 4rem;
  align-items: center;
}

.hero-text h1 {
  font-size: 2.5rem;
  margin-bottom: 1.5rem;
  background: linear-gradient(90deg, var(--accent1), var(--accent3));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: 0 0 15px rgba(63, 81, 181, 0.3);
}

.hero-text p {
  font-size: 1.1rem;
  color: var(--text-secondary);
  margin-bottom: 2rem;
}

.hero-image {
  position: relative;
  border-radius: 15px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0,0,0,0.5);
  transition: transform 0.5s ease;
}

.hero-image:hover {
  transform: translateY(-10px);
}

.hero-image img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 15px;
}

.hero-image::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(45deg, rgba(63,81,181,0.3), rgba(76,175,80,0.3));
  z-index: 1;
}

article {
  background: rgba(24, 25, 26, 0.7);
  border-radius: 15px;
  padding: 3rem;
  margin-bottom: 4rem;
  box-shadow: 0 5px 25px rgba(0,0,0,0.3);
  border: 1px solid rgba(255,255,255,0.05);
}

article h2 {
  font-size: 1.8rem;
  color: var(--accent1);
  margin-bottom: 2rem;
  position: relative;
  padding-bottom: 1rem;
}

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

article h3 {
  font-size: 1.5rem;
  color: var(--accent3);
  margin: 2rem 0 1.5rem;
}

article p {
  margin-bottom: 1.5rem;
  font-size: 1.05rem;
}

article pre {
  background: rgba(0,0,0,0.3);
  border-radius: 8px;
  padding: 1.5rem;
  margin: 2rem 0;
  overflow-x: auto;
  border-left: 3px solid var(--accent1);
  box-shadow: inset 0 0 10px rgba(0,0,0,0.5);
}

article code {
  font-family: 'Courier New', monospace;
  color: var(--accent3);
  background: transparent;
  padding: 0;
}

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

.gallery-item {
  border-radius: 10px;
  overflow: hidden;
  position: relative;
  box-shadow: 0 5px 15px rgba(0,0,0,0.3);
  transition: all 0.3s ease;
}

.gallery-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(63, 81, 181, 0.4);
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.5s ease;
}

.gallery-item:hover img {
  transform: scale(1.05);
}

.gallery-item::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(to top, rgba(0,0,0,0.7), transparent);
}

.footer {
  text-align: center;
  padding: 2rem;
  background: rgba(0,0,0,0.3);
  margin-top: 4rem;
  border-top: 1px solid rgba(255,255,255,0.1);
}

.footer p {
  color: var(--text-secondary);
  font-size: 0.9rem;
}

@media (max-width: 768px) {
  .hero {
    grid-template-columns: 1fr;
  }
  
  .nav {
    flex-direction: column;
    gap: 1rem;
  }
  
  article {
    padding: 2rem;
  }
  
  .gallery {
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  }
}

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

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

