:root {
  --primary-color: #4a6cf7;
  --primary-dark: #3a57d5;
  --dark-bg: #0f172a;
  --dark-card: #1e293b;
  --light-bg: #f8fafc;
  --light-card: #ffffff;
  --text-dark: #1e293b;
  --text-light: #f1f5f9;
  --border-radius: 10px;
  --shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
  --transition: all 0.3s ease;
  --mobile-menu-width: 280px;

  /* 新增柔和配色 */
  --contact-bg: #f0f5ff;
  --contact-border: #d1e0ff;
  --contact-primary: #5b7cfa;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
  background-color: var(--light-bg);
  color: var(--text-dark);
  line-height: 1.6;
  transition: var(--transition);
  overflow-x: hidden;
  position: relative;
}

body.dark-mode {
  background-color: var(--dark-bg);
  color: var(--text-light);
}

body.mobile-menu-open {
  overflow: hidden;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* 导航栏样式 */
header {
  background-color: var(--light-card);
  box-shadow: var(--shadow);
  position: sticky;
  top: 0;
  z-index: 1000;
  transition: var(--transition);
}

body.dark-mode header {
  background-color: var(--dark-card);
}

.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 0;
  position: relative;
}

.logo-container {
  display: flex;
  justify-content: center;
  position: relative;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--primary-color);
  text-decoration: none;
  transition: var(--transition);
  justify-content: center;
}

.logo i {
  font-size: 1.8rem;
}

.nav-links {
  display: flex;
  gap: 30px;
  margin-left: auto;
}

.nav-links a {
  text-decoration: none;
  color: var(--text-dark);
  font-weight: 500;
  transition: var(--transition);
  position: relative;
  padding: 5px 0;
}

.nav-links a:after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--primary-color);
  transition: var(--transition);
}

.nav-links a:hover:after {
  width: 100%;
}

body.dark-mode .nav-links a {
  color: var(--text-light);
}

.nav-links a.active {
  color: var(--primary-color);
}

.nav-links a.active:after {
  width: 100%;
}

.theme-toggle {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 1.5rem;
  color: var(--text-dark);
  transition: var(--transition);
  margin-left: 20px;
}

body.dark-mode .theme-toggle {
  color: var(--text-light);
}

/* 汉堡菜单样式 */
.hamburger {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 1.5rem;
  color: var(--text-dark);
  display: none;
  transition: var(--transition);
  position: absolute;
  left: 0;
}

body.dark-mode .hamburger {
  color: var(--text-light);
}

/* 移动端菜单样式 */
.mobile-menu {
  position: fixed;
  top: 0;
  left: -100%;
  width: var(--mobile-menu-width);
  height: 100vh;
  background-color: var(--light-card);
  z-index: 2000;
  transition: var(--transition);
  box-shadow: 5px 0 15px rgba(0, 0, 0, 0.1);
  overflow-y: auto;
}

body.dark-mode .mobile-menu {
  background-color: var(--dark-card);
}

.mobile-menu.active {
  left: 0;
}

.mobile-menu-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px;
  border-bottom: 1px solid #e2e8f0;
}

body.dark-mode .mobile-menu-header {
  border-bottom: 1px solid #334155;
}

.mobile-menu-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--primary-color);
}

.close-menu {
  background: none;
  border: none;
  color: var(--text-dark);
  font-size: 1.5rem;
  cursor: pointer;
}

body.dark-mode .close-menu {
  color: var(--text-light);
}

.mobile-nav-links {
  display: flex;
  flex-direction: column;
  padding: 20px;
}

.mobile-nav-links a {
  padding: 15px 10px;
  text-decoration: none;
  color: var(--text-dark);
  font-weight: 500;
  border-bottom: 1px solid #e2e8f0;
  display: flex;
  align-items: center;
  gap: 10px;
}

body.dark-mode .mobile-nav-links a {
  color: var(--text-light);
  border-bottom: 1px solid #334155;
}

.mobile-nav-links a i {
  width: 20px;
  text-align: center;
}

.mobile-nav-links a.active {
  color: var(--primary-color);
}

.overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  z-index: 1500;
  display: none;
}

.overlay.active {
  display: block;
}

.section {
  padding: 60px 0;
}

.section-title {
  text-align: center;
  margin-bottom: 40px;
}

.section-title h2 {
  font-size: 2.5rem;
  margin-bottom: 15px;
  color: var(--primary-color);
}

.section-title p {
  max-width: 700px;
  margin: 0 auto;
  color: #64748b;
  font-size: 1.1rem;
}

body.dark-mode .section-title p {
  color: #94a3b8;
}

.content-card {
  background-color: var(--light-card);
  border-radius: var(--border-radius);
  padding: 30px;
  box-shadow: var(--shadow);
  transition: var(--transition);
  margin-bottom: 30px;
}

body.dark-mode .content-card {
  background-color: var(--dark-card);
}

.content-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}

.content-card h3 {
  font-size: 1.4rem;
  margin-bottom: 20px;
  color: var(--primary-color);
  display: flex;
  align-items: center;
  gap: 10px;
}

.content-card h3 i {
  font-size: 1.3rem;
}

/* 页脚样式 */
footer {
  background-color: var(--light-card);
  padding: 60px 0 30px;
  margin-top: auto;
}

body.dark-mode footer {
  background-color: var(--dark-card);
}

.footer-content {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 40px;
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--primary-color);
  margin-bottom: 20px;
}

.footer-about p {
  color: #64748b;
  margin-bottom: 25px;
}

body.dark-mode .footer-about p {
  color: #94a3b8;
}

.social-links {
  display: flex;
  gap: 15px;
}

.social-links a {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: #e2e8f0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #475569;
  transition: var(--transition);
  text-decoration: none;
}

body.dark-mode .social-links a {
  background-color: #334155;
  color: #cbd5e1;
}

.social-links a:hover {
  background-color: var(--primary-color);
  color: white;
}

.footer-links h4 {
  font-size: 1.2rem;
  margin-bottom: 25px;
  color: var(--text-dark);
}

body.dark-mode .footer-links h4 {
  color: var(--text-light);
}

.footer-links ul {
  list-style: none;
}

.footer-links li {
  margin-bottom: 15px;
}

.footer-links a {
  text-decoration: none;
  color: #64748b;
  transition: var(--transition);
}

body.dark-mode .footer-links a {
  color: #94a3b8;
}

.footer-links a:hover {
  color: var(--primary-color);
}

.copyright {
  text-align: center;
  padding-top: 30px;
  border-top: 1px solid #e2e8f0;
  color: #64748b;
  font-size: 0.9rem;
}

body.dark-mode .copyright {
  border-top: 1px solid #334155;
  color: #94a3b8;
}

/* 返回顶部按钮 */
.back-to-top {
  position: fixed;
  bottom: 40px;
  right: 40px;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background-color: var(--primary-color);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.4s ease;
  z-index: 99;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.back-to-top.visible {
  opacity: 1;
  transform: translateY(0);
}

.back-to-top:hover {
  background-color: var(--primary-dark);
  transform: translateY(-5px);
}

/* 响应式设计 */
@media (max-width: 992px) {
  .footer-content {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 768px) {
  .section-title h2 {
    font-size: 2rem;
  }
  
  .footer-content {
    grid-template-columns: 1fr;
  }
  
  .nav-links {
    display: none;
  }
  
  .back-to-top {
    bottom: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
  }

  /* 汉堡菜单显示 */
  .hamburger {
    display: block;
  }

  /* 标题居中布局 */
  .logo-container {
    position: static;
    flex: 1;
    display: flex;
    justify-content: center;
  }z

  .logo {
    font-size: 1.4rem;
  }

  .theme-toggle {
    position: absolute;
    right: 0;
    margin: 0;
  }

  .beian-links {
    display: flex;
    flex-direction: column;
    gap: 8px;
  }
    
  .split {
    display: none;
  }
}

@media (max-width: 480px) {
  .section-title h2 {
    font-size: 1.8rem;
  }
  
  .section-title p {
    font-size: 1rem;
  }
}

/* 备案信息区域样式 */
.beian-links {
    text-align: center;
    padding: 15px 0;
    border-top: 1px solid #eaeaea;
    margin-top: 20px;
    font-size: 13px;
}

.beian-links a {
    color: #666;
    text-decoration: none;
    transition: color 0.3s ease;
}

.beian-links a:hover {
    color: #1a73e8;
}

.split {
    margin: 0 10px;
    color: #ccc;
}