/* ============================================================
   唐丰机电外贸官网 前台样式（全宽布局，参考51steelhome）
   ============================================================ */
* { margin: 0; padding: 0; box-sizing: border-box; }
:root {
  --primary: #1e3a5f;
  --primary-light: #2c5282;
  --accent: #c8a45c;
  --accent-dark: #a8863f;
  --dark: #12233c;
  --text: #333;
  --text-light: #666;
  --bg-light: #f5f7fa;
  --white: #fff;
  --border: #e5e7eb;
}
html { scroll-behavior: smooth; }
body {
  font-family: "Microsoft YaHei", "PingFang SC", Arial, "Helvetica Neue", sans-serif;
  color: var(--text);
  background: #fff;
  font-size: 14px;
  line-height: 1.6;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
ul { list-style: none; }
.container { width: 100%; max-width: 1400px; margin: 0 auto; padding: 0 20px; }

/* ===== 顶部信息条 ===== */
.topbar { background: var(--dark); color: #cfd8e3; font-size: 13px; }
.topbar-inner { display: flex; justify-content: space-between; align-items: center; height: 36px; flex-wrap: wrap; }
.topbar-item { margin-right: 18px; display: inline-flex; align-items: center; }
.lang-switch a { padding: 2px 7px; margin-left: 4px; border: 1px solid #3d5575; border-radius: 3px; font-size: 12px; }
.lang-switch a.active { background: var(--accent); color: #fff; border-color: var(--accent); }
.icon-whatsapp { display: inline-block; width: 14px; height: 14px; margin-right: 5px; background: #25d366; border-radius: 3px; vertical-align: middle; }

/* ===== 主头部 ===== */
.site-header { background: var(--white); box-shadow: 0 2px 10px rgba(0,0,0,.08); position: sticky; top: 0; z-index: 100; }
.header-inner { display: flex; align-items: center; justify-content: space-between; padding: 12px 20px; }
.logo { display: flex; align-items: center; }
.logo a { display: flex; align-items: center; }
.logo-brand { display: flex; align-items: center; gap: 14px; }
.logo img { height: 52px; width: auto; }
.logo-texts { display: flex; align-items: center; text-align: left; line-height: 1.25; max-width: 300px; }
.logo-title { display: block; font-size: 18px; font-weight: bold; color: var(--primary); white-space: normal; overflow: hidden; text-align: left; text-align-last: left; }
.logo-size-zh { font-size: 18px; line-height: 1.3; }
.logo-size-lat { font-size: 14px; letter-spacing: .2px; line-height: 1.3; }
.logo-size-ru { font-size: 12px; letter-spacing: .1px; line-height: 1.35; }
.logo-text { font-size: 22px; font-weight: bold; color: var(--primary); }
.main-nav { display: flex; align-items: center; flex-wrap: nowrap; white-space: nowrap; }
.main-nav a {
  padding: 10px 16px; font-size: 15px; font-weight: 500; color: var(--dark);
  border-bottom: 3px solid transparent; transition: all .2s; white-space: nowrap; flex-shrink: 1;
}
.main-nav a:hover, .main-nav a.active { color: var(--accent-dark); border-bottom-color: var(--accent); }
.nav-toggle { display: none; font-size: 24px; background: none; border: none; cursor: pointer; }

/* ===== 语言切换下拉菜单（放导航最后） ===== */
.lang-dropdown { position: relative; margin-left: 6px; }
.lang-dropdown-btn {
  display: inline-flex; align-items: center; gap: 6px; padding: 8px 14px;
  border: 1px solid var(--border); border-radius: 4px; background: #fff;
  font-size: 14px; font-weight: 500; color: var(--dark); cursor: pointer;
  transition: all .2s;
}
.lang-dropdown-btn:hover { border-color: var(--accent); color: var(--accent-dark); }
.lang-dropdown-caret { font-size: 11px; color: #8a94a6; }
.lang-dropdown-menu {
  display: none; position: absolute; right: 0; top: 100%; margin-top: 4px;
  min-width: 108px; background: #fff; border: 1px solid var(--border);
  border-radius: 6px; box-shadow: 0 6px 20px rgba(0,0,0,.12); overflow: hidden; z-index: 200;
}
.lang-dropdown.open .lang-dropdown-menu { display: block; }
.lang-dropdown-menu a {
  display: block; padding: 10px 16px; font-size: 14px; color: var(--dark);
  border-bottom: none !important; text-align: left; transition: background .15s;
}
.lang-dropdown-menu a:hover { background: #f2f5f9; color: var(--accent-dark); }
.lang-dropdown-menu a.active { background: var(--accent); color: #fff; font-weight: 600; }

/* ===== 移动端适配：下拉菜单 ===== */
@media (max-width: 992px) {
  .main-nav.open .lang-dropdown { margin-left: 0; }
  .lang-dropdown-menu { left: 0; right: auto; }
}

/* ===== Banner 轮播（全宽） ===== */
.banner { position: relative; width: 100%; max-width: 1400px; margin: 0 auto; height: 340px; overflow: hidden; background: var(--dark); }
.banner-slide { position: absolute; inset: 0; opacity: 0; transition: opacity .8s ease; }
.banner-slide.active { opacity: 1; }
.banner-slide img { width: 100%; height: 100%; object-fit: cover; }
.banner-caption {
  position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: center;
  align-items: center; text-align: center; color: #fff;
  background: linear-gradient(90deg, rgba(18,35,60,.55), rgba(18,35,60,.15), rgba(18,35,60,.55));
  padding: 20px;
}
.banner-caption h2 { font-size: 46px; font-weight: bold; margin-bottom: 14px; text-shadow: 0 2px 8px rgba(0,0,0,.4); }
.banner-caption p { font-size: 20px; opacity: .95; text-shadow: 0 1px 4px rgba(0,0,0,.4); }
.banner-caption .banner-tag { margin-top: 16px; display: inline-block; background: rgba(0,0,0,.5); border: 1px solid rgba(255,255,255,.45); border-radius: 30px; padding: 9px 22px; font-size: 15px; letter-spacing: 1px; opacity: 1; }
.banner-dots { position: absolute; bottom: 22px; left: 0; right: 0; display: flex; justify-content: center; gap: 8px; }
.banner-dots span { width: 34px; height: 4px; background: rgba(255,255,255,.5); cursor: pointer; border-radius: 2px; }
.banner-dots span.active { background: var(--accent); }

/* ===== 通用区块 ===== */
.section { padding: 36px 0; }
.section-title { text-align: center; margin-bottom: 40px; }
.section-title h2 { font-size: 30px; color: var(--dark); margin-bottom: 8px; }
.section-title p { color: var(--text-light); font-size: 15px; }
.section-title .title-line { width: 60px; height: 3px; background: var(--accent); margin: 12px auto 0; }

/* 全宽内容区（与banner同宽，参考51steelhome） */
.content-full { width: 100%; max-width: 1400px; margin: 0 auto; padding: 0 20px; }

/* ===== 公司简介 ===== */
.intro-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 50px; align-items: center; }
.intro-img img { border-radius: 6px; box-shadow: 0 8px 30px rgba(0,0,0,.12); width: 100%; height: 300px; object-fit: cover; }
.intro-text h3 { font-size: 26px; color: var(--dark); margin-bottom: 16px; }
.intro-text p { color: var(--text-light); margin-bottom: 12px; line-height: 1.9; }

/* ===== 资质荣誉条 ===== */
.honor-band { background: linear-gradient(90deg, var(--primary) 0%, #14487f 100%); padding: 16px 0; max-width: 1400px; margin: 0 auto; border-radius: 0 0 8px 8px; }
.honor-grid { display: flex; justify-content: space-between; align-items: center; gap: 20px; flex-wrap: wrap; }
.honor-item { display: flex; align-items: center; gap: 10px; color: #fff; font-size: 15px; font-weight: 600; letter-spacing: .3px; }
.honor-ico { width: 22px; height: 22px; border-radius: 50%; background: rgba(255,255,255,.22); display: inline-flex; align-items: center; justify-content: center; font-size: 12px; color: #ffd75e; flex-shrink: 0; }

/* ===== 统计数据 ===== */
.stats-band { background: var(--primary); color: #fff; max-width: 1400px; margin: 0 auto; border-radius: 8px 8px 0 0; }
.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 24px; padding: 50px 0; text-align: center; }
.stat-item { min-width: 0; }
.stat-num { font-size: 44px; font-weight: bold; color: var(--accent); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.stat-label { font-size: 16px; margin-top: 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ===== 核心业务 ===== */
.business-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.business-card {
  background: var(--white); border: 1px solid var(--border); border-radius: 8px; overflow: hidden;
  transition: all .25s; text-align: center;
}
.business-card:hover { transform: translateY(-6px); box-shadow: 0 10px 30px rgba(0,0,0,.12); }
.business-card img { width: 100%; height: 180px; object-fit: cover; }
.business-card .bc-body { padding: 20px 16px; }
.business-card h3 { font-size: 18px; color: var(--dark); margin-bottom: 8px; }
.business-card p { font-size: 13px; color: var(--text-light); }

/* ===== 产品 ===== */
.product-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.product-card { background: var(--white); border: 1px solid var(--border); border-radius: 8px; overflow: hidden; transition: all .25s; }
.product-card:hover { transform: translateY(-6px); box-shadow: 0 10px 30px rgba(0,0,0,.12); }
.product-card img { width: 100%; height: 220px; object-fit: cover; }
.product-card .pc-body { padding: 18px 16px; }
.product-card h3 { font-size: 16px; color: var(--dark); margin-bottom: 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.product-card p { font-size: 13px; color: var(--text-light); height: 40px; overflow: hidden; }

/* ===== 客户案例 ===== */
.client-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.client-card {
  background: var(--white); border: 1px solid var(--border); border-radius: 8px; padding: 28px 18px;
  text-align: center; transition: all .25s; display: flex; flex-direction: column; align-items: center; justify-content: center; min-height: 110px;
}
.client-card:hover { transform: translateY(-5px); box-shadow: 0 8px 24px rgba(0,0,0,.1); border-color: var(--accent); }
.client-card img { max-width: 88%; max-height: 56px; object-fit: contain; margin: 0 auto; }
.client-card .client-name { font-size: 14px; color: var(--dark); font-weight: 500; line-height: 1.4; }

/* ===== 资质荣誉 ===== */
.cert-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.cert-card { background: var(--white); border: 1px solid var(--border); border-radius: 8px; overflow: hidden; text-align: center; transition: all .25s; }
.cert-card:hover { box-shadow: 0 8px 24px rgba(0,0,0,.12); }
.cert-card img { width: 100%; height: 340px; object-fit: contain; background: var(--bg-light); padding: 14px; }
.cert-card.landscape img { height: 250px; }
.cert-card h3 { padding: 16px; font-size: 15px; color: var(--dark); }
.cert-card .cert-type { font-size: 12px; color: var(--accent-dark); }

/* ===== 新闻 ===== */
.news-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.news-card { background: var(--white); border: 1px solid var(--border); border-radius: 8px; overflow: hidden; transition: all .25s; }
.news-card:hover { transform: translateY(-5px); box-shadow: 0 8px 24px rgba(0,0,0,.1); }
.news-card img { width: 100%; height: 190px; object-fit: cover; }
.news-card .nc-body { padding: 18px; }
.news-card .nc-date { font-size: 12px; color: var(--accent-dark); }
.news-card h3 { font-size: 16px; margin: 8px 0; color: var(--dark); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.news-card p { font-size: 13px; color: var(--text-light); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* ===== 工厂画廊 ===== */
.gallery-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.gallery-item { position: relative; overflow: hidden; border-radius: 8px; }
.gallery-item img { width: 100%; height: 200px; object-fit: cover; transition: transform .3s; }
.gallery-item:hover img { transform: scale(1.05); }
.gallery-item .g-title { position: absolute; bottom: 0; left: 0; right: 0; background: linear-gradient(transparent, rgba(0,0,0,.7)); color: #fff; padding: 24px 12px 10px; font-size: 14px; }

/* ===== 设备清单 ===== */
.equip-cats { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-bottom: 30px; }
.equip-cats button {
  padding: 8px 18px; border: 1px solid var(--border); background: var(--white); border-radius: 20px;
  cursor: pointer; font-size: 14px; transition: all .2s;
}
.equip-cats button.active, .equip-cats button:hover { background: var(--primary); color: #fff; border-color: var(--primary); }
.equip-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.equip-card { background: var(--white); border: 1px solid var(--border); border-radius: 8px; overflow: hidden; transition: all .25s; }
.equip-card:hover { box-shadow: 0 8px 24px rgba(0,0,0,.1); }
.equip-card img { width: 100%; height: 160px; object-fit: cover; background: var(--bg-light); }
.equip-card .ec-body { padding: 14px; }
.equip-card h3 { font-size: 15px; color: var(--dark); margin-bottom: 6px; }
.equip-card .ec-model { font-size: 13px; color: var(--accent-dark); margin-bottom: 6px; }
.equip-card p { font-size: 12px; color: var(--text-light); }
.capacity-band { background: var(--primary); color: #fff; padding: 26px; border-radius: 8px; margin-top: 36px; display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px; text-align: center; }
.capacity-band .cap-item strong { display: block; font-size: 24px; color: var(--accent); }
.capacity-band .cap-item span { font-size: 13px; opacity: .9; }

/* ===== 关于/服务 ===== */
.page-hero { background: var(--dark); color: #fff; padding: 60px 0; text-align: center; max-width: 1400px; margin: 0 auto; border-radius: 8px; }
.page-hero h1 { font-size: 34px; margin-bottom: 8px; }
.page-hero p { opacity: .85; }
.about-section h3 { font-size: 22px; color: var(--dark); margin-bottom: 16px; padding-left: 14px; border-left: 4px solid var(--accent); }
.about-section .about-text { color: var(--text-light); line-height: 1.9; }
.service-list { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.service-item { background: var(--white); border: 1px solid var(--border); border-radius: 8px; padding: 26px; transition: all .25s; }
.service-item:hover { box-shadow: 0 8px 24px rgba(0,0,0,.1); transform: translateY(-4px); }
.service-item h3 { color: var(--dark); margin-bottom: 10px; font-size: 18px; }
.service-item p { color: var(--text-light); }

/* ===== 联系我们 ===== */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; }
.contact-info-item { display: flex; margin-bottom: 22px; }
.contact-info-item .ci-icon { width: 46px; height: 46px; background: var(--primary); color: #fff; border-radius: 50%; display: flex; align-items: center; justify-content: center; margin-right: 14px; font-size: 18px; flex-shrink: 0; }
.contact-info-item h4 { color: var(--dark); margin-bottom: 4px; }
.contact-info-item p { color: var(--text-light); }
.inquiry-form { background: var(--bg-light); border: 1px solid var(--border); border-radius: 8px; padding: 30px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-group { margin-bottom: 16px; }
.form-group label { display: block; margin-bottom: 6px; color: var(--dark); font-size: 14px; }
.form-group input, .form-group textarea, .form-group select {
  width: 100%; padding: 10px 12px; border: 1px solid var(--border); border-radius: 5px; font-size: 14px; font-family: inherit;
}
.form-group textarea { height: 110px; resize: vertical; }
.btn {
  display: inline-block; padding: 11px 30px; background: var(--accent); color: #fff; border: none;
  border-radius: 5px; font-size: 15px; cursor: pointer; transition: all .2s;
}
.btn:hover { background: var(--accent-dark); }
.btn-primary { background: var(--primary); }
.btn-primary:hover { background: var(--primary-light); }
.alert { padding: 12px 16px; border-radius: 5px; margin-bottom: 16px; }
.alert-success { background: #d4edda; color: #155724; border: 1px solid #c3e6cb; }
.alert-error { background: #f8d7da; color: #721c24; border: 1px solid #f5c6cb; }

/* ===== 页脚 ===== */
.site-footer { background: var(--dark); color: #b8c4d4; margin-top: 60px; }
.footer-inner { display: grid; grid-template-columns: 2fr 1fr 1.5fr; gap: 40px; padding: 48px 0; }
.footer-col h4 { color: #fff; font-size: 17px; margin-bottom: 16px; }
.footer-col p { font-size: 13px; line-height: 1.8; }
.footer-links li { margin-bottom: 8px; }
.footer-links a:hover { color: var(--accent); }
.footer-bottom { border-top: 1px solid #2c3e58; padding: 16px 0; font-size: 13px; text-align: center; }
.footer-bottom .footer-icp { margin-left: 14px; }
.footer-bottom .footer-icp a { color: #b8c4d4; text-decoration: none; }
.footer-bottom .footer-icp a:hover { color: var(--accent); }
.wa-float {
  position: fixed; right: 24px; bottom: 30px; width: 54px; height: 54px; background: #25d366;
  border-radius: 50%; display: flex; align-items: center; justify-content: center; box-shadow: 0 4px 16px rgba(0,0,0,.3); z-index: 200;
}
.wa-float .icon-whatsapp { width: 30px; height: 30px; margin: 0; }

/* ===== 分页 ===== */
.pagination { display: flex; justify-content: center; gap: 8px; margin-top: 36px; }
.pagination a, .pagination span { padding: 8px 14px; border: 1px solid var(--border); border-radius: 5px; color: var(--dark); }
.pagination a:hover { border-color: var(--accent); color: var(--accent-dark); }
.pagination .current { background: var(--primary); color: #fff; border-color: var(--primary); }

/* ===== 响应式 ===== */
/* 导航不换行：宽度不足时仅缩小字号与间距 */
@media (max-width: 1280px) {
  .logo img { height: 44px; }
  .logo-size-zh { font-size: 16px; }
  .logo-size-lat { font-size: 13px; }
  .logo-size-ru { font-size: 11px; }
  .main-nav a { padding: 10px 12px; font-size: 14px; }
  .lang-dropdown-btn { padding: 7px 10px; font-size: 13px; }
}
@media (max-width: 1100px) {
  .header-inner { padding: 10px 14px; }
  .logo img { height: 38px; }
  .logo-brand { gap: 10px; }
  .logo-texts { max-width: 220px; }
  .logo-size-zh { font-size: 14px; }
  .logo-size-lat { font-size: 12px; }
  .logo-size-ru { font-size: 10px; }
  .main-nav a { padding: 9px 8px; font-size: 13px; }
  .lang-dropdown-btn { padding: 6px 8px; font-size: 12px; }
}

@media (max-width: 1024px) {
  .business-grid { grid-template-columns: repeat(3, 1fr); }
  .product-grid { grid-template-columns: repeat(3, 1fr); }
  .client-grid { grid-template-columns: repeat(3, 1fr); }
  .equip-grid { grid-template-columns: repeat(3, 1fr); }
  .gallery-grid { grid-template-columns: repeat(3, 1fr); }
  .service-list { grid-template-columns: repeat(2, 1fr); }
  .capacity-band { grid-template-columns: repeat(3, 1fr); }
  .news-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 768px) {
  .banner { height: 260px; }
  .banner-caption h2 { font-size: 28px; }
  .intro-img img { height: 220px; }
  .main-nav { display: none; position: absolute; top: 100%; left: 0; right: 0; background: #fff; flex-direction: column; box-shadow: 0 8px 20px rgba(0,0,0,.1); }
  .main-nav.open { display: flex; }
  .main-nav a { width: 100%; text-align: center; }
  .nav-toggle { display: block; }
  .intro-grid, .contact-grid { grid-template-columns: 1fr; }
  .business-grid { grid-template-columns: repeat(2, 1fr); }
  .product-grid, .client-grid, .equip-grid, .gallery-grid, .news-grid { grid-template-columns: repeat(2, 1fr); }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-inner { grid-template-columns: 1fr; gap: 24px; }
  .service-list { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .cert-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 480px) {
  .product-grid, .client-grid, .equip-grid, .gallery-grid { grid-template-columns: 1fr; }
  .topbar-inner { height: auto; padding: 6px 0; }
}

/* ===== FAQ 常见问题（GEO） ===== */
.faq-list { max-width: 900px; margin: 0 auto; }
.faq-item { border: 1px solid #e5e9f0; border-radius: 8px; margin-bottom: 12px; background: #fff; overflow: hidden; }
.faq-item summary { cursor: pointer; padding: 16px 20px; font-size: 16px; font-weight: 600; color: #1a2b4a; list-style: none; position: relative; padding-right: 42px; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: '+'; position: absolute; right: 18px; top: 50%; transform: translateY(-50%); font-size: 22px; font-weight: 400; color: #c8102e; transition: transform .2s; }
.faq-item[open] summary::after { content: '−'; }
.faq-item[open] summary { border-bottom: 1px solid #eef1f6; background: #fafbfd; }
.faq-answer { padding: 16px 20px; color: #555; line-height: 1.85; }
.faq-answer p { margin: 0; }
