* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Noto Sans SC", sans-serif;
  scroll-behavior: smooth;
}

:root {
  --primary: #2c3e50;
  /* --secondary: #f4312d; */
  /* --secondary: #e74c3c; */
  --secondary: #3498db;
  --accent: #e74c3c;
  --light: #f8f9fa;
  --dark: #1a2530;
}

body {
  color: #333;
  line-height: 1.6;
}

/* 导航栏 */
header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background: white;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  z-index: 999;
  padding: 0 30px;
}

.navbar {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 70px;
}

.logo {
  font-size: 24px;
  font-weight: 700;
  color: var(--primary);
  text-decoration: none;
}

.logo span {
  color: var(--secondary);
}

.nav-links {
  display: flex;
  list-style: none;
  gap: 30px;
}

.nav-links a {
  text-decoration: none;
  color: var(--primary);
  font-weight: 500;
  transition: 0.3s;
}

.nav-links a:hover {
  color: var(--secondary);
}

.mobile-menu {
  display: none;
  font-size: 24px;
  cursor: pointer;
}

/* 移动端导航 */
@media (max-width: 768px) {
  .nav-links {
    position: fixed;
    top: 70px;
    left: -100%;
    width: 100%;
    height: calc(100vh - 70px);
    background: white;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    transition: 0.4s;
    gap: 20px;
  }
  .nav-links.active {
    left: 0;
  }
  .mobile-menu {
    display: block;
  }
}

/* 英雄区 */
.hero {
  margin-top: 70px;
  height: 80vh;
  background:
    linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.6)),
    url("images/hero.png");
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: white;
  padding: 0 20px;
}

.hero-content h1 {
  font-size: 48px;
  margin-bottom: 20px;
}

.hero-content p {
  font-size: 18px;
  max-width: 700px;
  margin: 0 auto 30px;
}

.btn {
  display: inline-block;
  padding: 12px 30px;
  background: var(--secondary);
  color: white;
  text-decoration: none;
  border-radius: 5px;
  transition: 0.3s;
  font-weight: 500;
}

.btn:hover {
  background: #2980b9;
  transform: translateY(-3px);
}

/* 通用区块 */
.section {
  padding: 80px 30px;
  max-width: 1200px;
  margin: 0 auto;
}

.section-title {
  text-align: center;
  margin-bottom: 50px;
  font-size: 32px;
  color: var(--primary);
  position: relative;
}

.section-title::after {
  content: "";
  width: 80px;
  height: 3px;
  background: var(--secondary);
  position: absolute;
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
}

/* 产品展示 */
.products {
  background: var(--light);
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 30px;
}

.product-card {
  background: white;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
  transition: 0.3s;
}

.product-card:hover {
  transform: translateY(-10px);
}

.product-img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.product-info {
  padding: 20px;
  text-align: center;
}

.product-info h3 {
  margin-bottom: 10px;
  color: var(--primary);
}

/* 工厂实力 */
.factory-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 40px;
  align-items: center;
}

.factory-img img {
  width: 100%;
  border-radius: 10px;
}

.factory-text h3 {
  font-size: 24px;
  margin-bottom: 20px;
  color: var(--primary);
}

.factory-text p {
  margin-bottom: 15px;
  line-height: 1.8;
}

@media (max-width: 768px) {
  .factory-grid {
    grid-template-columns: 1fr;
  }
}

/* 生产流程 */
.process {
  background: var(--light);
}

.process-steps {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 20px;
  text-align: center;
}

.step {
  flex: 1;
  min-width: 150px;
}

.step i {
  font-size: 80px;
  color: var(--secondary);
  margin-bottom: 15px;
}

/* 联系我们 */
.contact-form {
  max-width: 700px;
  margin: 0 auto;
  background: white;
  padding: 40px;
  border-radius: 10px;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
}

.form-group {
  margin-bottom: 20px;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 12px 15px;
  border: 1px solid #ddd;
  border-radius: 5px;
  font-size: 16px;
}

.form-group textarea {
  min-height: 150px;
  resize: vertical;
}

/* 页脚 */
footer {
  background: var(--dark);
  color: white;
  padding: 60px 30px 20px;
}

.footer-content {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 40px;
}

.footer-col h3 {
  margin-bottom: 20px;
  font-size: 20px;
}

.footer-col p,
.footer-col a {
  color: #ccc;
  text-decoration: none;
  margin-bottom: 10px;
  display: block;
}

.footer-col a:hover {
  color: var(--secondary);
}

.social {
  display: flex;
  gap: 15px;
  margin-top: 20px;
}

.social a {
  width: 40px;
  height: 40px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: 0.3s;
}

.social a:hover {
  background: var(--secondary);
}

.copyright {
  text-align: center;
  margin-top: 40px;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  color: #999;
}

/* 产品轮播样式 无缝无限循环 */
.product-slider-wrap {
  position: relative;
  overflow: hidden;
  padding: 0 10px;
}
.product-slider {
  overflow: hidden;
}
.product-track {
  display: flex;
  gap: 30px;
  /* transition: transform 0.5s ease; */
}
.product-card {
  flex: 0 0 calc(25% - 23px);
  background: white;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
  transition: 0.3s;
}
.product-card:hover {
  transform: translateY(-10px);
}
.product-img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}
.product-info {
  padding: 20px;
  text-align: center;
}
.product-info h3 {
  margin-bottom: 10px;
  color: var(--primary);
}

/* 自适应每行几张卡片 */
@media (max-width: 992px) {
  .product-card {
    flex: 0 0 calc(33.33% - 20px);
  }
}
@media (max-width: 768px) {
  .product-card {
    flex: 0 0 calc(50% - 15px);
  }
}
@media (max-width: 480px) {
  .product-card {
    flex: 0 0 100%;
  }
}
