/* ============================================================
   祥云环保设备 - 主样式表
   设计：工业蓝白风格 | 响应式 | SEO优化
   ============================================================ */

/* === Reset & Base === */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { font-size: 16px; scroll-behavior: smooth; }
body {
  font-family: "Microsoft YaHei", "PingFang SC", "Helvetica Neue", Arial, sans-serif;
  color: #333; background: #f5f6f8; line-height: 1.7;
}
a { text-decoration: none; color: inherit; }
ul, ol { list-style: none; }
img { max-width: 100%; height: auto; display: block; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.section { padding: 60px 0; }
.section-title {
  text-align: center; margin-bottom: 40px;
}
.section-title h2 {
  font-size: 32px; color: #1a3a4a; margin-bottom: 10px;
}
.section-title p {
  font-size: 16px; color: #888;
}

/* === Header === */
.header {
  background: #fff; box-shadow: 0 2px 8px rgba(0,0,0,0.06);
  position: sticky; top: 0; z-index: 100;
}
.header .container {
  display: flex; align-items: center; justify-content: space-between;
  height: 100px;
}
.logo img { height: 90px; }
.nav { display: flex; gap: 0; }
.nav > li { position: relative; }
.nav > li > a {
  display: block; padding: 28px 18px; font-size: 15px; color: #444;
  transition: .2s; white-space: nowrap;
}
.nav > li > a:hover, .nav > li.active > a {
  color: #1a6fa0; border-bottom: 3px solid #1a6fa0;
}
.nav .dropdown-box {
  position: absolute; top: 100%; left: 0; background: #fff;
  min-width: 160px; box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  border-radius: 0 0 4px 4px; opacity: 0; visibility: hidden;
  transform: translateY(-5px); transition: .2s; z-index: 200;
}
.nav li:hover .dropdown-box { opacity: 1; visibility: visible; transform: translateY(0); }
.nav .dropdown-box a {
  display: block; padding: 10px 18px; font-size: 14px; color: #555;
  border-bottom: 1px solid #f0f0f0;
}
.nav .dropdown-box a:hover { background: #f8f9fa; color: #1a6fa0; }

/* === Mobile Menu === */
.menu-btn {
  display: none;
  cursor: pointer;
  padding: 12px;
  background: #1a6fa0; /* 添加背景色让它更明显 */
  border-radius: 6px;
  margin-right: 10px;
}
.menu-btn span {
  display: block;
  width: 26px;
  height: 3px;
  background: #fff; /* 改成白色和背景对比 */
  margin: 5px 0;
  border-radius: 2px;
  transition: .3s;
}
.menu-btn::before {
  content: "菜单"; /* 添加文字提示 */
  display: block;
  font-size: 12px;
  color: #fff;
  text-align: center;
  margin-bottom: 2px;
}

/* === Banner === */
.banner {
  position: relative; overflow: hidden;
  background: #1a3a4a;
}
.banner .swiper { width: 100%; }
.banner .swiper-slide { text-align: center; background: #1a3a4a; }
.banner .swiper-slide img {
  width: 100%; max-width: 1200px; height: auto; display: block; margin: 0 auto;
}
.banner .swiper-pagination-bullet { background: #fff; opacity: .6; }
.banner .swiper-pagination-bullet-active { opacity: 1; background: #1a6fa0; }

/* === Search Bar === */
.search-bar {
  background: #fff; padding: 15px 0; border-bottom: 1px solid #eee;
}
.search-bar .container { display: flex; gap: 10px; align-items: center; }
.search-bar .hot { font-size: 14px; color: #888; white-space: nowrap; }
.search-bar .hot a {
  display: inline-block; margin: 0 8px; padding: 4px 12px;
  background: #e8f4fd; color: #1a6fa0; border-radius: 3px; font-size: 13px;
}
.search-bar .hot a:hover { background: #1a6fa0; color: #fff; }
.search-bar form { display: flex; gap: 0; margin-left: auto; }
.search-bar input {
  padding: 8px 15px; border: 2px solid #ddd; border-right: none;
  border-radius: 4px 0 0 4px; width: 220px; font-size: 14px; outline: none;
}
.search-bar input:focus { border-color: #1a6fa0; }
.search-bar button {
  padding: 8px 20px; background: #1a6fa0; color: #fff; border: none;
  border-radius: 0 4px 4px 0; cursor: pointer; font-size: 14px;
}

/* === Footer === */
.footer {
  background: #1a3a4a; color: #ccc; padding: 50px 0 20px;
}
.footer-grid {
  display: grid; grid-template-columns: 2fr 1fr 1fr 1.5fr;
  gap: 40px; margin-bottom: 30px;
}
.footer h3 { color: #fff; font-size: 18px; margin-bottom: 15px; }
.footer p, .footer a { font-size: 14px; line-height: 2; }
.footer a:hover { color: #fff; }
.footer .contact-info p { display: flex; align-items: center; gap: 8px; }
.footer .footer-products {
  display: flex;
  gap: 20px;
}
.footer .footer-products > div {
  flex: 1;
}
.footer .footer-products a {
  display: inline-block;
  width: 100%;
}
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1); padding-top: 20px;
  text-align: center; font-size: 13px; color: #888;
}

/* === Breadcrumb === */
.breadcrumb {
  background: #f0f2f5; padding: 12px 0; font-size: 14px; color: #888;
}
.breadcrumb a { color: #1a6fa0; }
.breadcrumb span { margin: 0 6px; }

/* === Home: Product Grid === */
.product-grid {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px;
}
.product-card {
  background: #fff; border-radius: 8px; overflow: hidden;
  box-shadow: 0 2px 8px rgba(0,0,0,0.04); transition: .3s;
}
.product-card:hover { transform: translateY(-4px); box-shadow: 0 8px 24px rgba(0,0,0,0.1); }
.product-card img { width: 100%; height: 200px; object-fit: cover; }
.product-card .info { padding: 16px; }
.product-card .info h3 { font-size: 17px; color: #1a3a4a; margin-bottom: 6px; }
.product-card .info p { font-size: 13px; color: #999; }

/* === Home: About Intro === */
.about-intro {
  display: grid; grid-template-columns: 1fr 1fr; gap: 50px; align-items: center;
}
.about-intro img { border-radius: 8px; box-shadow: 0 4px 16px rgba(0,0,0,0.1); }
.about-intro h2 { font-size: 28px; color: #1a3a4a; margin-bottom: 15px; }
.about-intro p { font-size: 15px; color: #666; margin-bottom: 12px; }
.about-intro .stats {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 15px; margin-top: 20px;
}
.stats .stat { text-align: center; padding: 15px; background: #f0f6fa; border-radius: 6px; }
.stat strong { display: block; font-size: 28px; color: #1a6fa0; }
.stat span { font-size: 13px; color: #888; }

/* === Home: Case Cards === */
.case-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px;
}
.case-card {
  background: #fff; border-radius: 8px; overflow: hidden;
  box-shadow: 0 2px 8px rgba(0,0,0,0.04); transition: .3s;
}
.case-card:hover { transform: translateY(-4px); box-shadow: 0 8px 24px rgba(0,0,0,0.1); }
.case-card img { width: 100%; height: 220px; object-fit: cover; }
.case-card .info { padding: 16px; }
.case-card .info h3 { font-size: 16px; color: #1a3a4a; margin-bottom: 6px; }
.case-card .info p { font-size: 13px; color: #999; }
.case-card .tag {
  display: inline-block; padding: 2px 10px; background: #e8f4fd;
  color: #1a6fa0; font-size: 12px; border-radius: 10px; margin-bottom: 8px;
}

/* === Product Page Layout === */
.product-list { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }

/* === Product Detail === */
.product-detail {
  display: grid; grid-template-columns: 1fr 1fr; gap: 50px; margin-bottom: 40px;
}
.product-detail .gallery-main {
  width: 100%; border-radius: 8px; overflow: hidden;
  box-shadow: 0 2px 12px rgba(0,0,0,0.08);
}
.product-detail .gallery-main img { width: 100%; }
.gallery-thumbs { display: flex; gap: 10px; margin-top: 10px; }
.gallery-thumbs img {
  width: 80px; height: 60px; object-fit: cover; border-radius: 4px;
  cursor: pointer; border: 2px solid transparent; transition: .2s;
}
.gallery-thumbs img:hover, .gallery-thumbs img.active { border-color: #1a6fa0; }
.product-info h1 { font-size: 28px; color: #1a3a4a; margin-bottom: 10px; }
.product-info .subtitle { font-size: 15px; color: #888; margin-bottom: 20px; }
.product-info .features { margin-bottom: 20px; }
.product-info .features li {
  padding: 6px 0; font-size: 15px; color: #555;
}
.product-info .features li::before { content: '✓ '; color: #27ae60; font-weight: bold; }
.product-info .cta { margin-top: 24px; }
.btn {
  display: inline-block; padding: 12px 32px; border-radius: 4px;
  font-size: 16px; font-weight: bold; cursor: pointer; transition: .2s; border: none;
}
.btn-primary { background: #c0392b; color: #fff; }
.btn-primary:hover { background: #a93226; }
.btn-outline {
  border: 2px solid #1a6fa0; color: #1a6fa0; background: transparent; margin-left: 10px;
}
.btn-outline:hover { background: #1a6fa0; color: #fff; }

/* === Specs Table === */
.specs-table { width: 100%; border-collapse: collapse; margin: 20px 0; font-size: 14px; }
.specs-table thead { background: #1a3a4a; color: #fff; }
.specs-table th, .specs-table td {
  padding: 10px 14px; border: 1px solid #ddd; text-align: center;
}
.specs-table tbody tr:nth-child(even) { background: #f8f9fa; }
.specs-table tbody tr:hover { background: #e8f4fd; }

/* === Content Text === */
.content { max-width: 800px; margin: 0 auto; }
.content h2 {
  font-size: 24px; color: #1a3a4a; margin: 30px 0 15px;
  padding-bottom: 10px; border-bottom: 2px solid #e8f4fd;
}
.content h3 { font-size: 18px; color: #333; margin: 20px 0 10px; }
.content p { font-size: 15px; color: #555; margin-bottom: 12px; }
.content ul, .content ol { margin: 10px 0 20px 20px; }
.content li { font-size: 15px; color: #555; padding: 4px 0; }
.content table { width: 100%; border-collapse: collapse; margin: 15px 0; }
.content table th, .content table td {
  padding: 8px 12px; border: 1px solid #ddd; font-size: 14px;
}

/* === Case / Article Detail === */
.case-hero { width: 100%; max-height: 400px; object-fit: cover; border-radius: 8px; margin-bottom: 30px; }
.article-list { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }

/* === About Page === */
.about-hero img { width: 100%; border-radius: 8px; margin-bottom: 30px; }
.about-grid { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 30px; margin: 40px 0; }

/* === Contact Page === */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; }
.contact-form input, .contact-form textarea {
  width: 100%; padding: 12px; margin-bottom: 15px; border: 2px solid #ddd;
  border-radius: 4px; font-size: 14px; font-family: inherit; outline: none;
}
.contact-form input:focus, .contact-form textarea:focus { border-color: #1a6fa0; }
.contact-form textarea { height: 150px; resize: vertical; }
.contact-info-card {
  background: #f8f9fa; padding: 30px; border-radius: 8px;
}
.contact-info-card h3 { margin-bottom: 15px; color: #1a3a4a; }
.contact-info-card p { margin-bottom: 10px; font-size: 15px; }

/* === 404 === */
.page-404 { text-align: center; padding: 100px 0; }
.page-404 h1 { font-size: 120px; color: #ddd; margin-bottom: 20px; }
.page-404 p { font-size: 18px; color: #888; margin-bottom: 30px; }
.page-404 a { color: #1a6fa0; text-decoration: underline; }

/* === Breadcrumb Schema === */
.breadcrumb ol { display: flex; gap: 0; list-style: none; }
.breadcrumb ol li + li::before { content: '/'; margin: 0 8px; color: #ccc; }

/* === Top Button === */
#topBtn {
  position: fixed; bottom: 30px; right: 30px; width: 44px; height: 44px;
  background: #1a6fa0; color: #fff; border: none; border-radius: 50%;
  font-size: 20px; cursor: pointer; display: none; z-index: 99;
  box-shadow: 0 2px 8px rgba(0,0,0,0.2); transition: .3s;
}
#topBtn:hover { background: #155a80; transform: translateY(-2px); }

/* === Responsive === */
@media (max-width: 1024px) {
  .product-grid, .case-grid, .article-list { grid-template-columns: repeat(3, 1fr); }
  .product-list { grid-template-columns: repeat(3, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 768px) {
  .product-grid, .case-grid, .article-list, .product-list { grid-template-columns: repeat(2, 1fr); }
  .about-intro { grid-template-columns: 1fr; }
  .product-detail { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .section-title h2 { font-size: 24px; }
  .header .container { height: auto; padding: 10px 15px; flex-wrap: wrap; }

  /* 手机端导航：两行显示 */
  .menu-btn { display: none; }
  .nav {
    display: flex !important;
    flex-direction: row;
    flex-wrap: wrap;
    position: static;
    background: #fff;
    box-shadow: none;
    width: 100%;
    border-bottom: 1px solid #eee;
  }
  .nav > li {
    width: 33.33%;
    text-align: center;
    border-bottom: none;
    position: relative;
  }
  .nav > li > a {
    padding: 12px 5px;
    font-size: 13px;
    color: #444;
    border-bottom: none;
    white-space: nowrap;
  }
  .nav > li > a:hover, .nav > li.active > a {
    color: #1a6fa0;
    border-bottom: none;
  }
  /* 产品中心下拉箭头 */
  .nav > li.has-dropdown > a::after {
    content: "▼";
    font-size: 8px;
    margin-left: 4px;
    color: #888;
  }
  .nav > li.has-dropdown.open > a::after {
    content: "▲";
  }
  /* 子菜单下拉 - 手机端 */
  .nav .dropdown-box {
    display: none;
    position: fixed;
    top: auto;
    left: 10px;
    right: 10px;
    bottom: auto;
    min-width: auto;
    z-index: 300;
    background: #fff;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    text-align: left;
  }
  .nav > li.has-dropdown.open .dropdown-box {
    display: block;
  }
  .nav .dropdown-box a {
    color: #333;
    padding: 10px 15px;
    border-bottom: 1px solid #eee;
  }
}

/* 更小屏幕一行4个放不下，改成3个 */
@media (max-width: 480px) {
  .product-grid, .case-grid, .article-list, .product-list { grid-template-columns: 1fr; }
  .stats { grid-template-columns: repeat(3, 1fr); }
  .nav > li { width: 33.33%; }
}
@media (max-width: 480px) {
  .product-grid, .case-grid, .article-list, .product-list { grid-template-columns: 1fr; }
  .stats { grid-template-columns: repeat(3, 1fr); }
}
