﻿*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: "Microsoft YaHei", "PingFang SC", Arial, sans-serif; background: #fff; color: #333; line-height: 1.6; }
a { color: #333; text-decoration: none; transition: color 0.2s; }
a:hover { color: #C41E3A; }
img { max-width: 100%; height: auto; display: block; }
.container { width: 1200px; margin: 0 auto; padding: 0 20px; }

:root {
    --primary: #C41E3A;
    --secondary: #1A3A5C;
    --bg-light: #F5F7FA;
    --text-primary: #333333;
    --text-secondary: #666666;
    --border: #E0E0E0;
}

.top-bar { background: var(--secondary); color: #fff; padding: 8px 0; font-size: 13px; }
.top-bar .container { display: flex; justify-content: space-between; align-items: center; }
.top-bar-right { color: rgba(255,255,255,0.9); }

.main-header { background: #fff; box-shadow: 0 2px 8px rgba(0,0,0,0.08); position: sticky; top: 0; z-index: 100; }
.main-header .container { display: flex; align-items: center; height: 70px; }
.logo { display: flex; align-items: center; gap: 8px; }
.logo-img { height: 48px; width: auto; display: block; }
.logo-text { font-size: 24px; font-weight: bold; color: var(--primary); }
.logo-sub { font-size: 13px; color: var(--text-secondary); white-space: nowrap; }
.nav-toggle { display: none; background: none; border: none; font-size: 28px; cursor: pointer; color: var(--secondary); margin-left: auto; padding: 8px; }
.main-header nav { margin-left: auto; display: flex; align-items: center; }
.nav-list { display: flex; list-style: none; gap: 4px; }
.nav-list li a { display: block; padding: 10px 20px; font-size: 15px; color: var(--text-primary); border-bottom: 3px solid transparent; transition: all 0.2s; font-weight: 500; }
.nav-list li a:hover,
.nav-list li.active a { color: var(--primary); border-bottom-color: var(--primary); }

.btn { display: inline-block; padding: 10px 28px; border-radius: 4px; font-size: 14px; font-weight: 500; cursor: pointer; transition: all 0.2s; border: none; }
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: #A01830; color: #fff; }
.btn-secondary { background: var(--secondary); color: #fff; }
.btn-secondary:hover { background: #0F2840; color: #fff; }
.btn-outline { background: transparent; color: var(--primary); border: 1px solid var(--primary); }
.btn-outline:hover { background: var(--primary); color: #fff; }

.section { padding: 60px 0; }
.section-alt { background: var(--bg-light); }
.section-title { font-size: 28px; font-weight: bold; color: var(--secondary); text-align: center; margin-bottom: 8px; }
.section-desc { font-size: 16px; color: var(--text-secondary); text-align: center; margin-bottom: 40px; }

.banner { position: relative; overflow: hidden; height: 500px; background: var(--secondary); }
.banner-slide { position: absolute; inset: 0; background-size: cover; background-position: center; opacity: 0; transition: opacity 0.8s; display: flex; align-items: center; justify-content: center; }
.banner-slide.active { opacity: 1; }
.banner-overlay { position: absolute; inset: 0; background: rgba(26,58,92,0.6); }
.banner-content { position: relative; z-index: 1; text-align: center; color: #fff; }
.banner-content h2 { font-size: 42px; margin-bottom: 16px; font-weight: bold; text-shadow: 0 2px 8px rgba(0,0,0,0.3); }
.banner-content p { font-size: 18px; margin-bottom: 24px; opacity: 0.9; }
.banner-dots { position: absolute; bottom: 24px; left: 50%; transform: translateX(-50%); display: flex; gap: 8px; z-index: 2; }
.banner-dots .dot { width: 12px; height: 12px; border-radius: 50%; background: rgba(255,255,255,0.4); cursor: pointer; transition: background 0.2s; }
.banner-dots .dot.active { background: #fff; }

.category-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.category-card { background: #fff; border: 1px solid var(--border); border-radius: 8px; overflow: hidden; transition: box-shadow 0.3s, transform 0.3s; text-align: center; display: flex; flex-direction: column; }
.category-card:hover { box-shadow: 0 8px 24px rgba(0,0,0,0.1); transform: translateY(-4px); }
.category-card-icon { height: 360px; background: var(--bg-light); display: flex; align-items: center; justify-content: center; overflow: hidden; }
.category-card-icon img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s; }
.category-card:hover .category-card-icon img { transform: scale(1.05); }
.category-card-body { padding: 16px; flex: 1; display: flex; align-items: center; justify-content: center; }
.category-card-body h3 { font-size: 17px; color: var(--secondary); margin-bottom: 8px; }
.category-card-body p { font-size: 13px; color: var(--text-secondary); }

/* 列表式布局：一行一条卡片，纵向排列 */
.product-grid { display: flex; flex-direction: column; gap: 16px; }
.product-card { background: #fff; border: 1px solid var(--border); border-radius: 8px; overflow: hidden; transition: box-shadow 0.3s; }
.product-card:hover { box-shadow: 0 8px 24px rgba(0,0,0,0.1); }
/* 固定宽度、高度随原图比例自适应：不变形、不裁切，整图完整可见 */
.product-card-img { width: 100%; overflow: hidden; background: var(--bg-light); cursor: zoom-in; }
.product-card-img img { display: block; width: 100%; height: auto; }
.product-card-body { padding: 12px 14px; display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.product-card-body h3 { font-size: 15px; color: var(--text-primary); font-weight: 500; }
.product-card-body .model { font-size: 12px; color: var(--text-secondary); }
.product-card-body .cat-tag { display: inline-block; background: var(--primary); color: #fff; padding: 2px 8px; border-radius: 3px; font-size: 11px; margin-top: 8px; }

/* ===== 产品原图灯箱 ===== */
.lightbox { position: fixed; inset: 0; z-index: 1000; display: flex; align-items: center; justify-content: center; padding: 40px; background: rgba(0, 0, 0, 0.85); opacity: 0; visibility: hidden; transition: opacity 0.25s ease, visibility 0.25s ease; }
.lightbox.open { opacity: 1; visibility: visible; }
.lightbox img { max-width: 100%; max-height: 100%; object-fit: contain; background: #fff; border-radius: 4px; box-shadow: 0 16px 48px rgba(0, 0, 0, 0.5); transform: scale(0.96); transition: transform 0.25s ease; }
.lightbox.open img { transform: scale(1); }
.lightbox-close { position: absolute; top: 18px; right: 22px; width: 42px; height: 42px; border: 0; border-radius: 50%; background: rgba(255, 255, 255, 0.15); color: #fff; font-size: 26px; line-height: 42px; text-align: center; cursor: pointer; transition: background 0.2s ease; }
.lightbox-close:hover { background: rgba(255, 255, 255, 0.3); }
.lightbox-caption { position: absolute; left: 0; right: 0; bottom: 18px; text-align: center; color: #fff; font-size: 14px; text-shadow: 0 1px 3px rgba(0, 0, 0, 0.6); pointer-events: none; }
body.lightbox-open { overflow: hidden; }

.products-layout { display: flex; gap: 24px; min-height: 600px; }
.products-sidebar { width: 240px; flex-shrink: 0; }
.products-main { flex: 1; }
.sidebar-nav { background: #fff; border: 1px solid var(--border); border-radius: 8px; overflow: hidden; }
.sidebar-nav-title { background: var(--secondary); color: #fff; padding: 14px 16px; font-size: 16px; font-weight: bold; }
.sidebar-nav-list { list-style: none; }
.sidebar-nav-list li a { display: block; padding: 10px 16px; font-size: 14px; color: var(--text-primary); border-bottom: 1px solid var(--border); transition: all 0.2s; }
.sidebar-nav-list li a:hover,
.sidebar-nav-list li a.active { background: var(--bg-light); color: var(--primary); }
.sidebar-nav-list li a.top-cat { font-weight: bold; }
.sidebar-nav-list li a.top-cat[data-collapsed] { font-weight: normal; color: var(--text-primary); }
.sidebar-sub-list { list-style: none; background: var(--bg-light); }
.sidebar-sub-list li a { display: block; padding: 8px 16px 8px 34px; font-size: 13px; color: var(--text-secondary); border-bottom: 1px solid var(--border); }
.sidebar-sub-list li a:hover,
.sidebar-sub-list li a.active { background: #fff; color: var(--primary); }

.advantages-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.advantage-item { text-align: center; padding: 30px 20px; background: #fff; border-radius: 8px; border: 1px solid var(--border); }
.advantage-item h4 { font-size: 16px; color: var(--secondary); margin-bottom: 8px; }
.advantage-item p { font-size: 13px; color: var(--text-secondary); }
.advantage-num { display: inline-flex; width: 48px; height: 48px; border-radius: 50%; background: var(--primary); color: #fff; font-size: 20px; font-weight: bold; align-items: center; justify-content: center; margin-bottom: 12px; }

.news-card { display: flex; gap: 20px; background: #fff; padding: 20px; border: 1px solid var(--border); border-radius: 8px; margin-bottom: 12px; transition: box-shadow 0.3s; }
.news-card:hover { box-shadow: 0 4px 16px rgba(0,0,0,0.08); }
.news-date { min-width: 100px; color: var(--primary); font-weight: bold; font-size: 14px; padding-right: 16px; border-right: 2px solid var(--primary); display: flex; align-items:center; }
.news-body { flex: 1; }
.news-body h3 { font-size: 17px; margin-bottom: 6px; }
.news-body h3 a { color: var(--text-primary); }
.news-body h3 a:hover { color: var(--primary); }
.news-body p { color: var(--text-secondary); font-size: 14px; line-height: 1.6; margin-bottom: 8px; }
.news-meta { display: flex; align-items: center; gap: 12px; }
.news-category { display: inline-block; background: var(--primary); color: #fff; padding: 2px 10px; border-radius: 4px; font-size: 12px; }
.news-more { color: var(--primary); font-size: 13px; }

.page-banner { background: linear-gradient(rgba(26,58,92,0.7), rgba(26,58,92,0.7)), url('/images/banner-bg.jpg') center/cover; height: 250px; display: flex; align-items: center; justify-content: center; color: #fff; text-align: center; }
.page-banner h1 { font-size: 32px; font-weight: bold; }
.page-banner p { font-size: 16px; margin-top: 8px; opacity: 0.8; }

.about-content { max-width: 880px; margin: 0 auto; padding: 40px 20px; line-height: 2; font-size: 16px; }
.about-content h2 { font-size: 22px; color: var(--secondary); margin: 30px 0 16px; padding-bottom: 8px; border-bottom: 2px solid var(--primary); }
.about-content p { margin-bottom: 16px; color: var(--text-primary); }
.contact-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; margin-top: 20px; }
.contact-item { background: var(--bg-light); padding: 20px; border-radius: 8px; }
.contact-item h4 { font-size: 15px; color: var(--secondary); margin-bottom: 8px; }
.contact-item p { font-size: 14px; color: var(--text-secondary); margin: 0; }

.pagination { text-align: center; margin: 40px 0; display: flex; justify-content: center; gap: 4px; }
.pagination a, .pagination span { display: inline-block; padding: 8px 16px; border: 1px solid var(--border); border-radius: 4px; color: var(--text-primary); font-size: 14px; }
.pagination a:hover { background: var(--primary); color: #fff; border-color: var(--primary); }
.pagination .current { background: var(--primary); color: #fff; border-color: var(--primary); }

.news-detail-page { width: 880px; margin: 0 auto; padding: 40px 20px 60px; min-height: 500px; }
.news-detail-page h1 { font-size: 26px; color: var(--text-primary); margin-bottom: 12px; }
.news-detail-meta { color: var(--text-secondary); font-size: 14px; margin-bottom: 24px; padding-bottom: 16px; border-bottom: 1px solid var(--border); display: flex; gap: 16px; }
.news-detail-meta .category { display: inline-block; background: var(--primary); color: #fff; padding: 2px 12px; border-radius: 4px; font-size: 12px; }
.news-detail-content { line-height: 2; font-size: 16px; color: var(--text-primary); }
.news-detail-content p { margin-bottom: 16px; }
.news-detail-content img { max-width: 100%; height: auto; border-radius: 4px; margin: 8px 0; }
.news-detail-content table { width: 100%; border-collapse: collapse; margin: 16px 0; }
.news-detail-content td, .news-detail-content th { border: 1px solid var(--border); padding: 8px; }
.news-detail-content th { background: var(--bg-light); }
.news-detail-content ul, .news-detail-content ol { padding-left: 24px; margin: 8px 0; }
.news-detail-content blockquote { border-left: 4px solid var(--primary); padding: 8px 16px; margin: 16px 0; background: var(--bg-light); }
.news-nav { margin-top: 40px; padding-top: 20px; border-top: 1px solid var(--border); display: flex; justify-content: space-between; }
.news-nav a { color: var(--primary); font-size: 15px; max-width: 45%; }
.news-nav a:hover { text-decoration: underline; }
.news-nav .disabled { color: #ccc; }

.main-footer { background: var(--secondary); color: rgba(255,255,255,0.8); padding: 40px 0 0; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 40px; }
.footer-col h4 { color: #fff; font-size: 16px; margin-bottom: 16px; }
.footer-col p { font-size: 14px; margin-bottom: 8px; }
.footer-col a { color: rgba(255,255,255,0.8); }
.footer-col a:hover { color: #fff; }
.footer-bottom { background: rgba(0,0,0,0.2); padding: 16px 0; margin-top: 30px; text-align: center; }
.footer-bottom p { font-size: 13px; color: rgba(255,255,255,0.6); }

/* ===== 页脚分站模块 ===== */
.footer-stations { margin-bottom: 30px; padding-bottom: 22px; border-bottom: 1px solid rgba(255,255,255,0.12); }
.footer-stations-list { display: flex; flex-wrap: wrap; row-gap: 8px; }
.footer-stations-list a,
.footer-stations-list span { font-size: 13px; line-height: 1.6; padding: 0 10px; color: rgba(255,255,255,0.65); white-space: nowrap; }
.footer-stations-list a { text-decoration: none; transition: color 0.2s; }
.footer-stations-list a:hover { color: #fff; }
.footer-stations-list span { color: rgba(255,255,255,0.45); }
/* 除第一项外，每项前面加一条竖线分隔符 */
.footer-stations-list > * + * { position: relative; }
.footer-stations-list > * + *::before { content: "|"; position: absolute; left: 0; top: 0; color: rgba(255,255,255,0.2); }

@media (max-width: 1024px) {
    .container { width: 96%; }
    .category-card-icon { height: 300px; }
    .advantages-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
    .top-bar .container { flex-direction: column; text-align: center; gap: 4px; }
    .main-header .container { flex-wrap: wrap; height: auto; padding: 10px 0; }
    .logo { flex: 1; }
    .logo-sub { display: none; }
    .nav-toggle { display: block; }
    .nav-list { display: none; width: 100%; flex-direction: column; position: absolute; top: 100%; left: 0; background: #fff; box-shadow: 0 4px 12px rgba(0,0,0,0.1); z-index: 200; }
    .nav-list.open { display: flex; }
    .nav-list li a { border-bottom: 1px solid var(--border); }
    .banner { height: 300px; }
    .banner-content h2 { font-size: 26px; }
    .banner-content p { font-size: 14px; }
    .section { padding: 40px 0; }
    .section-title { font-size: 22px; }
    .category-grid { grid-template-columns: 1fr; }
    .category-card-icon { height: 240px; }
    .advantages-grid { grid-template-columns: 1fr; }
    .products-layout { flex-direction: column; }
    .products-sidebar { width: 100%; }
    .news-card { flex-direction: column; }
    .news-date { border-right: none; border-bottom: 2px solid var(--primary); padding-bottom: 8px; min-width: auto; }
    .footer-grid { grid-template-columns: 1fr; gap: 24px; }
    .page-banner { height: 180px; }
    .page-banner h1 { font-size: 24px; }
    .news-detail-page { width: 100%; }
    .contact-grid { grid-template-columns: 1fr; }
}


