/* ========== 全站基础样式 ========== */
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: "Microsoft YaHei", "PingFang SC", "Hiragino Sans GB", sans-serif;
  font-size: 15px;
  line-height: 1.7;
  color: #333;
  background: #fff;
}
a { color: #1a56db; text-decoration: none; transition: color .2s; }
a:hover { color: #ff6b35; }
img { max-width: 100%; height: auto; display: block; }
ul, ol { list-style: none; }

/* ========== 配色变量 ========== */
:root {
  --primary: #1a56db;
  --primary-dark: #0e2a86;
  --accent: #ff6b35;
  --text: #333;
  --text-light: #666;
  --bg-light: #f5f7fa;
  --border: #e5e7eb;
  --max-width: 1200px;
}

/* ========== 顶部 ========== */
.top-bar {
  background: var(--primary-dark);
  color: #fff;
  font-size: 13px;
  padding: 6px 0;
}
.top-bar .container { display: flex; justify-content: space-between; align-items: center; }
.top-bar a { color: #fff; }
.top-bar .top-phone { font-weight: 600; }
.container { max-width: var(--max-width); margin: 0 auto; padding: 0 20px; }

/* ========== 头部导航 ========== */
header {
  background: #fff;
  box-shadow: 0 2px 8px rgba(0,0,0,.06);
  position: sticky;
  top: 0;
  z-index: 100;
}
.nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 70px;
}
.logo { display: flex; align-items: center; gap: 10px; }
.logo-icon {
  width: 42px; height: 42px;
  background: var(--primary);
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-weight: 700; font-size: 18px;
}
.logo-text { font-size: 18px; font-weight: 600; color: var(--primary-dark); }
.logo-text small { display: block; font-size: 11px; color: var(--text-light); font-weight: 400; margin-top: 2px; }
.nav-menu { display: flex; gap: 30px; }
.nav-menu a {
  color: var(--text);
  font-size: 15px;
  font-weight: 500;
  padding: 8px 0;
  position: relative;
}
.nav-menu a:hover, .nav-menu a.active { color: var(--primary); }
.nav-menu a.active::after {
  content: '';
  position: absolute;
  bottom: -2px; left: 0; right: 0;
  height: 3px;
  background: var(--primary);
  border-radius: 2px;
}
.nav-cta {
  background: var(--accent);
  color: #fff;
  padding: 8px 18px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 500;
}
.nav-cta:hover { background: #e85a25; color: #fff; }
.menu-toggle { display: none; background: none; border: none; font-size: 24px; cursor: pointer; }

/* ========== Hero 大图 ========== */
.hero {
  background: linear-gradient(135deg, #1a56db 0%, #0e2a86 100%);
  color: #fff;
  padding: 80px 0;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  top: -100px; right: -100px;
  width: 400px; height: 400px;
  background: rgba(255,255,255,.05);
  border-radius: 50%;
}
.hero h1 { font-size: 44px; font-weight: 700; margin-bottom: 20px; line-height: 1.3; }
.hero .subtitle { font-size: 20px; margin-bottom: 30px; opacity: .95; }
.hero .badges { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 30px; }
.hero .badge {
  background: rgba(255,255,255,.18);
  border: 1px solid rgba(255,255,255,.3);
  padding: 6px 16px;
  border-radius: 20px;
  font-size: 14px;
}
.hero .cta-group { display: flex; gap: 15px; flex-wrap: wrap; }
.btn {
  display: inline-block;
  padding: 12px 28px;
  border-radius: 6px;
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  transition: all .2s;
  text-align: center;
}
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: #e85a25; color: #fff; }
.btn-outline { background: rgba(255,255,255,.1); color: #fff; border: 1px solid #fff; }
.btn-outline:hover { background: #fff; color: var(--primary); }
.btn-large { padding: 14px 36px; font-size: 16px; }

/* ========== 通用模块 ========== */
.section { padding: 60px 0; }
.section-light { background: var(--bg-light); }
.section-title { text-align: center; margin-bottom: 40px; }
.section-title h2 { font-size: 32px; color: var(--primary-dark); margin-bottom: 12px; font-weight: 700; }
.section-title p { color: var(--text-light); font-size: 16px; }
.section-title::after {
  content: '';
  display: block;
  width: 60px; height: 3px;
  background: var(--accent);
  margin: 16px auto 0;
  border-radius: 2px;
}

/* ========== 卡片网格 ========== */
.grid { display: grid; gap: 24px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
  transition: all .25s;
}
.card:hover {
  box-shadow: 0 8px 24px rgba(0,0,0,.08);
  transform: translateY(-3px);
  border-color: var(--primary);
}
.card-img {
  background: linear-gradient(135deg, #e8eef9 0%, #d4e1f5 100%);
  height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
  font-size: 14px;
  position: relative;
}
.card-img::after {
  content: '产品图位置 \A 750x500px';
  white-space: pre;
  text-align: center;
  line-height: 1.6;
}
.card-img:has(img)::after { content: none; }
.card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: inherit;
}
.card-body { padding: 20px; }
.card-body h3 { font-size: 18px; margin-bottom: 10px; color: var(--primary-dark); }
.card-body p { color: var(--text-light); font-size: 14px; line-height: 1.6; }
.card-link { display: inline-block; margin-top: 12px; color: var(--primary); font-size: 14px; font-weight: 500; }

/* ========== 产品详情页 ========== */
.product-hero {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: center;
  padding: 40px 0;
}
.product-img {
  background: linear-gradient(135deg, #e8eef9 0%, #d4e1f5 100%);
  border-radius: 12px;
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
  font-size: 16px;
  overflow: hidden;
}
.product-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.product-info h1 { font-size: 32px; color: var(--primary-dark); margin-bottom: 16px; }
.product-info .price { color: var(--accent); font-size: 24px; font-weight: 600; margin-bottom: 20px; }
.product-info .desc { color: var(--text-light); margin-bottom: 24px; line-height: 1.8; }
.feature-list { margin: 20px 0; }
.feature-list li { padding: 8px 0 8px 28px; position: relative; }
.feature-list li::before {
  content: '✓';
  position: absolute;
  left: 0; top: 8px;
  width: 20px; height: 20px;
  background: var(--primary);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
}

.params-table { width: 100%; border-collapse: collapse; margin: 20px 0; }
.params-table td { padding: 14px 18px; border: 1px solid var(--border); }
.params-table td:first-child { background: var(--bg-light); font-weight: 600; width: 35%; color: var(--primary-dark); }

/* ========== FAQ ========== */
.faq-item { border-bottom: 1px solid var(--border); padding: 20px 0; }
.faq-q { font-size: 17px; font-weight: 600; color: var(--primary-dark); margin-bottom: 10px; cursor: pointer; }
.faq-q::before { content: 'Q '; color: var(--accent); }
.faq-a { color: var(--text-light); padding-left: 24px; }
.faq-a::before { content: 'A: '; color: var(--primary); font-weight: 500; }

/* ========== 内容页 ========== */
.article { max-width: 900px; margin: 0 auto; }
.article h1 { font-size: 32px; color: var(--primary-dark); margin: 30px 0 20px; }
.article h2 { font-size: 24px; color: var(--primary-dark); margin: 30px 0 15px; padding-left: 12px; border-left: 4px solid var(--accent); }
.article h3 { font-size: 18px; color: var(--primary-dark); margin: 20px 0 10px; }
.article p { margin-bottom: 15px; line-height: 1.8; }
.article ul, .article ol { margin: 15px 0 15px 25px; }
.article li { margin-bottom: 8px; line-height: 1.7; }
.breadcrumb { padding: 16px 0; font-size: 14px; color: var(--text-light); }
.breadcrumb a { color: var(--text-light); }
.breadcrumb .sep { margin: 0 8px; }

/* ========== 联系我们 ========== */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; margin: 30px 0; }
.contact-card { background: var(--bg-light); padding: 30px; border-radius: 8px; }
.contact-card h3 { color: var(--primary-dark); margin-bottom: 16px; }
.contact-item { padding: 10px 0; border-bottom: 1px dashed var(--border); }
.contact-item:last-child { border-bottom: none; }
.contact-item .label { color: var(--text-light); font-size: 13px; }
.contact-item .value { font-size: 16px; font-weight: 500; color: var(--primary-dark); }

/* ========== 底部 ========== */
footer { background: #0b1d4a; color: #c5cae0; padding: 50px 0 20px; margin-top: 60px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 30px; margin-bottom: 30px; }
.footer-col h4 { color: #fff; margin-bottom: 16px; font-size: 15px; }
.footer-col ul li { padding: 4px 0; font-size: 14px; }
.footer-col a { color: #c5cae0; }
.footer-col a:hover { color: #fff; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.1); padding-top: 20px; text-align: center; font-size: 13px; }
.footer-bottom a { color: #c5cae0; }

/* ========== 浮动按钮 ========== */
.float-phone {
  position: fixed;
  right: 20px; bottom: 100px;
  width: 60px; height: 60px;
  background: var(--accent);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 600;
  text-align: center;
  box-shadow: 0 4px 12px rgba(255,107,53,.4);
  z-index: 99;
}
.float-phone:hover { color: #fff; transform: scale(1.05); }
.back-top {
  position: fixed;
  right: 20px; bottom: 30px;
  width: 44px; height: 44px;
  background: var(--primary);
  color: #fff;
  border-radius: 50%;
  display: none;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  cursor: pointer;
  z-index: 99;
  border: none;
}
.back-top:hover { background: var(--primary-dark); }

/* ========== 响应式 ========== */
@media (max-width: 768px) {
  .top-bar { font-size: 12px; }
  .top-bar .top-phone { font-size: 13px; }
  .nav { height: 60px; }
  .logo-text { font-size: 16px; }
  .logo-text small { display: none; }
  .nav-menu { display: none; position: absolute; top: 100%; left: 0; right: 0; background: #fff; flex-direction: column; padding: 20px; gap: 16px; box-shadow: 0 4px 12px rgba(0,0,0,.1); }
  .nav-menu.show { display: flex; }
  .nav-cta { display: none; }
  .menu-toggle { display: block; }
  .hero { padding: 50px 0; }
  .hero h1 { font-size: 28px; }
  .hero .subtitle { font-size: 16px; }
  .section { padding: 40px 0; }
  .section-title h2 { font-size: 24px; }
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .product-hero, .contact-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .float-phone { width: 50px; height: 50px; font-size: 12px; }
  .news-card { flex-direction: column; }
  .news-card-date { flex-direction: row; width: 100%; padding: 12px; }
  .post-content table { font-size: 13px; }
}

/* ========== 新闻/博客子系统样式 ========== */
.news-list {
  display: grid;
  gap: 20px;
  margin-bottom: 40px;
}

.news-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
  transition: all .25s;
}
.news-card:hover {
  border-color: var(--primary);
  box-shadow: 0 6px 20px rgba(26,86,219,.1);
  transform: translateY(-2px);
}
.news-card-link {
  display: flex;
  align-items: stretch;
  color: inherit;
}
.news-card-link:hover { color: inherit; }

.news-card-date {
  background: var(--primary);
  color: #fff;
  width: 100px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 16px 8px;
  text-align: center;
}
.news-card-date .day {
  font-size: 32px;
  font-weight: 700;
  line-height: 1;
}
.news-card-date .month {
  font-size: 14px;
  margin-top: 4px;
  opacity: .9;
}
.news-card-date .year {
  font-size: 12px;
  margin-top: 2px;
  opacity: .75;
}

.news-card-body {
  padding: 20px 24px;
  flex: 1;
}
.news-card-body h3 {
  font-size: 18px;
  color: var(--primary-dark);
  margin-bottom: 10px;
  line-height: 1.4;
}
.news-summary {
  color: var(--text-light);
  font-size: 14px;
  margin-bottom: 12px;
  line-height: 1.6;
}
.news-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 10px;
}
.tag {
  background: var(--bg-light);
  color: var(--text-light);
  font-size: 12px;
  padding: 3px 10px;
  border-radius: 12px;
}
.news-meta {
  color: var(--accent);
  font-size: 14px;
  font-weight: 600;
}

/* 最新动态区块（首页用） */
.news-section {
  background: var(--bg-light);
  padding: 50px 0;
}
.news-list-mini {
  display: grid;
  gap: 16px;
}
.news-item-mini {
  background: #fff;
  padding: 18px 22px;
  border-radius: 8px;
  border-left: 4px solid var(--primary);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  transition: all .2s;
}
.news-item-mini:hover {
  box-shadow: 0 4px 12px rgba(0,0,0,.08);
  border-left-color: var(--accent);
}
.news-item-mini-info { flex: 1; min-width: 0; }
.news-item-mini-date {
  color: var(--text-light);
  font-size: 13px;
  margin-bottom: 4px;
}
.news-item-mini-title {
  font-size: 15px;
  color: var(--text-dark, var(--primary-dark));
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.news-item-mini-arrow {
  color: var(--accent);
  font-size: 20px;
}

/* 文章详情页 */
.post-article {
  max-width: 900px;
  margin: 0 auto;
}
.post-content {
  background: #fff;
  padding: 30px 40px;
  border-radius: 8px;
  border: 1px solid var(--border);
  font-size: 16px;
  line-height: 1.8;
}
.post-content h1 {
  font-size: 28px;
  color: var(--primary-dark);
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--primary);
}
.post-content h2 {
  font-size: 22px;
  color: var(--primary-dark);
  margin: 28px 0 14px;
  padding-left: 12px;
  border-left: 4px solid var(--accent);
}
.post-content h3 {
  font-size: 18px;
  color: var(--primary-dark);
  margin: 22px 0 12px;
}
.post-content p { margin-bottom: 14px; }
.post-content ul, .post-content ol {
  padding-left: 28px;
  margin-bottom: 14px;
  list-style: disc;
}
.post-content li { margin-bottom: 6px; }
.post-content strong { color: var(--primary-dark); }
.post-content blockquote {
  border-left: 4px solid var(--accent);
  padding: 12px 18px;
  background: var(--bg-light);
  color: var(--text-light);
  margin: 16px 0;
  border-radius: 0 6px 6px 0;
}
.post-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 16px 0;
}
.post-content th, .post-content td {
  border: 1px solid var(--border);
  padding: 10px 12px;
  text-align: left;
}
.post-content th {
  background: var(--bg-light);
  font-weight: 600;
}
.post-content code {
  background: #f0f0f0;
  padding: 2px 6px;
  border-radius: 3px;
  font-family: "Courier New", monospace;
  font-size: 14px;
  color: #c7254e;
}
.post-content img {
  margin: 16px 0;
  border-radius: 6px;
  border: 1px solid var(--border);
}

.post-nav {
  display: flex;
  gap: 12px;
  justify-content: space-between;
  margin-top: 30px;
}

.btn {
  display: inline-block;
  padding: 10px 22px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all .2s;
}
.btn-primary {
  background: var(--accent);
  color: #fff !important;
}
.btn-primary:hover {
  background: #e55a25;
  color: #fff !important;
}
.btn-secondary {
  background: var(--bg-light);
  color: var(--text) !important;
  border: 1px solid var(--border);
}
.btn-secondary:hover {
  background: #e8eaef;
}

.loading {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-light);
}
.loading.error {
  color: #c7254e;
  background: #fff5f5;
  border-radius: 6px;
}
