/* 全局样式和变量 */
:root {
  --primary-color: #007bff;
  --secondary-color: #6c757d;
  --background-light: #f8f9fa;
  --text-color: #333;
  --text-light: #fff;
  --header-height: 70px;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--header-height); /* 保证锚点定位不会被导航栏遮挡 */
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  margin: 0;
  line-height: 1.6;
  color: var(--text-color);
}

.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 20px;
}

h1,
h2,
h3 {
  margin-bottom: 1rem;
}

h2 {
  text-align: center;
  font-size: 2.5rem;
  margin-bottom: 40px;
}

.page-section {
  padding: 80px 0;
}

.bg-light {
  background-color: var(--background-light);
}

/* 导航栏 */
.header {
  background: #fff;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  position: sticky;
  top: 0;
  z-index: 1000;
  height: var(--header-height);
}

.header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 100%;
}

.logo {
  font-size: 1.5rem;
  font-weight: bold;
  color: var(--primary-color);
  text-decoration: none;
}

.nav-links {
  list-style: none;
  display: flex;
  margin: 0;
  padding: 0;
}

.nav-links li {
  margin-left: 20px;
}

.nav-links a {
  text-decoration: none;
  color: var(--text-color);
  font-weight: 500;
  transition: color 0.3s ease;
}

.nav-links a:hover {
  color: var(--primary-color);
}

.hamburger {
  display: none;
  cursor: pointer;
  background: none;
  border: none;
}

/* 首屏 - 修改后的样式 */
.hero-section {
  position: relative; /* 关键：为子元素的绝对定位提供参考 */
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  min-height: calc(100vh - var(--header-height));
  color: var(--text-light);
  /* 替换背景图为深色渐变背景 */
  background: linear-gradient(135deg, #0d122b, #1a237e);
  overflow: hidden; /* 隐藏超出范围的气泡 */
}

.hero-content {
  position: relative; /* 关键：确保内容在动画层之上 */
  z-index: 2;
  padding: 10px;
}

/* 原来的 .hero-section 背景图样式可以删除了 */
.hero-content h1 {
  font-size: 3.5rem;
  margin-bottom: 0.5rem;
}

.hero-content p {
  font-size: 1.25rem;
  margin-bottom: 2rem;
}

.cta-button {
  display: inline-block;
  background: var(--primary-color);
  color: var(--text-light);
  padding: 12px 24px;
  border-radius: 5px;
  text-decoration: none;
  font-weight: bold;
  transition: background 0.3s ease;
}

.cta-button:hover {
  background: #0056b3;
}

/* 关于我们 */
.about-content {
  display: flex;
  align-items: center;
  gap: 40px;
}

.about-content img {
  max-width: 400px;
  border-radius: 8px;
}

/* 我们的服务 */
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
}

.service-card {
  background: #fff;
  padding: 30px;
  text-align: center;
  border-radius: 8px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
  transition: transform 0.3s ease;
}

.service-card:hover {
  transform: translateY(-10px);
}

.service-card .icon {
  font-size: 3rem;
  margin-bottom: 1rem;
}

/* 团队介绍 */
.team-grid {
  display: flex;
  justify-content: center;
  gap: 30px;
  flex-wrap: wrap;
}

.team-member {
  text-align: center;
}

.team-member img {
  width: 150px;
  height: 150px;
  border-radius: 50%;
  object-fit: cover;
  margin-bottom: 15px;
}

/* 联系我们 */
.contact-info {
  text-align: left;
  font-size: 1.1rem;
}

.address-info {
  display: flex;
}
.address-info .address {
  flex: 1;
}
.address-info .address p {
  margin: 0;
}

.contact-info p {
  margin-bottom: 10px;
}

/* 页脚 */
.footer {
  background: #333;
  color: var(--text-light);
  text-align: center;
  padding: 20px 0;
}

/* ------------------- */
/* 响应式设计 (手机端) */
/* ------------------- */
@media (max-width: 768px) {
  h2 {
    font-size: 2rem;
  }

  /* 手机导航栏 */
  .nav-links {
    display: none;
    flex-direction: column;
    position: absolute;
    top: var(--header-height);
    left: 0;
    width: 100%;
    background: #fff;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  }

  .nav-links.active {
    display: flex;
  }

  .nav-links li {
    margin: 0;
    text-align: center;
  }

  .nav-links a {
    display: block;
    padding: 15px;
    border-bottom: 1px solid #eee;
  }

  .hamburger {
    display: block;
  }

  .hamburger span {
    display: block;
    width: 25px;
    height: 3px;
    background-color: var(--text-color);
    margin: 5px 0;
    transition: 0.4s;
  }

  /* 汉堡菜单动画 */
  .hamburger.active span:nth-child(1) {
    transform: rotate(-45deg) translate(-5px, 6px);
  }
  .hamburger.active span:nth-child(2) {
    opacity: 0;
  }
  .hamburger.active span:nth-child(3) {
    transform: rotate(45deg) translate(-5px, -6px);
  }

  /* 首屏 */
  .hero-content h1 {
    font-size: 2.5rem;
  }

  /* 关于我们 */
  .about-content {
    flex-direction: column;
  }
  .about-content img {
    max-width: 100%;
  }
}

/* --- 酷炫动画背景 - 方案一：漂浮气泡 --- */
.hero-animation-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
}

.circle {
  position: absolute;
  display: block;
  list-style: none;
  background: rgba(255, 255, 255, 0.15); /* 气泡颜色和透明度 */
  animation: bubble-rise 25s linear infinite;
  bottom: -150px; /* 从屏幕下方开始 */
}

/* 为每个气泡设置不同的大小、位置和动画延迟，制造随机感 */
.circle:nth-child(1) {
  left: 25%;
  width: 80px;
  height: 80px;
  animation-delay: 0s;
}
.circle:nth-child(2) {
  left: 10%;
  width: 20px;
  height: 20px;
  animation-delay: 2s;
  animation-duration: 12s;
}
.circle:nth-child(3) {
  left: 70%;
  width: 20px;
  height: 20px;
  animation-delay: 4s;
}
.circle:nth-child(4) {
  left: 40%;
  width: 60px;
  height: 60px;
  animation-delay: 0s;
  animation-duration: 18s;
}
.circle:nth-child(5) {
  left: 65%;
  width: 20px;
  height: 20px;
  animation-delay: 0s;
}
.circle:nth-child(6) {
  left: 75%;
  width: 110px;
  height: 110px;
  animation-delay: 3s;
}
.circle:nth-child(7) {
  left: 35%;
  width: 150px;
  height: 150px;
  animation-delay: 7s;
}
.circle:nth-child(8) {
  left: 50%;
  width: 25px;
  height: 25px;
  animation-delay: 15s;
  animation-duration: 45s;
}
.circle:nth-child(9) {
  left: 20%;
  width: 15px;
  height: 15px;
  animation-delay: 2s;
  animation-duration: 35s;
}
.circle:nth-child(10) {
  left: 85%;
  width: 150px;
  height: 150px;
  animation-delay: 0s;
  animation-duration: 11s;
}

/* 定义气泡上升的动画 */
@keyframes bubble-rise {
  0% {
    transform: translateY(0) rotate(0deg);
    opacity: 1;
    border-radius: 0;
  }
  100% {
    transform: translateY(-1000px) rotate(720deg);
    opacity: 0;
    border-radius: 50%;
  }
}

/* --- 联系我们板块优化样式 --- */
.contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  margin-top: 40px;
}

.contact-card {
  background: #fff;
  padding: 30px;
  text-align: center;
  border-radius: 8px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
}

.contact-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
}

.contact-card .icon {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  color: var(--primary-color); /* 使用主题色 */
}

.contact-card h3 {
  margin-bottom: 15px;
  font-size: 1.25rem;
  color: var(--text-color);
}

.contact-card p {
  margin: 5px 0;
  line-height: 1.7;
  color: var(--secondary-color);
  flex-grow: 1; /* 让内容撑满卡片，解决卡片不等高问题 */
}

.contact-card p strong {
  color: var(--text-color);
}

.contact-card .en-address {
  font-size: 0.9em;
  font-style: italic;
  color: #888;
}
