/* =========================================
   1. 字体与全局设置 (Global)
   ========================================= */
@font-face {
    font-family: 'FZSJ-SXH';
    src: url('../fonts/fzsx.TTF') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

body, html {
    margin: 0;
    padding: 0;
    
    font-family: "PingFang SC", "Helvetica Neue", "Microsoft YaHei", sans-serif;
    background-color: #ffffff;
    color: #333;
    font-size: 16px;
    scroll-behavior: smooth;
    width: 100%;
    overflow-x: hidden;
}

svg {
    max-width: 100%;
    vertical-align: middle;
}

a { text-decoration: none; transition: all 0.3s; }

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0;
    box-sizing: border-box;
}

/* 间距与背景 */
.section-wrapper { padding: 80px 0; }
.section-wrapper.bg-light, .products-wrapper { background-color: #f7f8fa; padding: 110px 0 80px; }

/* 标题 */
.section-title, .section-title-alt { 
    text-align: center; font-size: 38px; font-weight: 600; color: #1a1a1a; margin-top: 0 !important; padding-top: 0 !important; margin-bottom: 60px; 
}
.section-subtitle { 
    text-align: center; font-size: 18px; color: #777; margin-top: -40px; margin-bottom: 60px; 
    max-width: 850px; margin: 0 auto; 
}
.font-fzsj { font-family: 'FZSJ-SXH', sans-serif; }

/* =========================================
   2. Header & PC 导航栏 (必须保留修复逻辑，否则菜单会错乱)
   ========================================= */
.header {
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid #f0f0f0;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    height: 93px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

#header-placeholder {
    height: 93px; /* 必须等于菜单的高度 */
    width: 100%;
    display: block; /* 确保它占据空间 */
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative; /* 关键 */
    height: 100%;
}

.logo {
    display: flex; 
    align-items: center; 
    gap: 10px;
    height: 100%;
    z-index: 1002;
}
.logo img { height: 35px; width: auto; }

/* 默认隐藏移动端组件 (防止出现巨大X) */
.hamburger-menu { display: none; }
.mobile-nav { display: none; }
.overlay { display: none; }

.nav {
    display: flex;
    align-items: center;
    height: 100%;
    position: static; /* 关键 */
}

.nav-item {
    height: 100%;
    display: flex;
    align-items: center;
    position: static; /* 关键 */
}

.nav-item > a {
    margin: 0 20px;
    color: #333;
    font-size: 16px;
    font-weight: 500;
    position: relative;
    padding: 20px 0;
}

.nav-item > a:hover, .nav-item > a.active { color: #FF4040; }
.nav-item > a:hover::after, .nav-item > a.active::after {
    content: ''; position: absolute; bottom: 15px; left: 0; right: 0; height: 2px; background-color: #FF4040;
}

/* =========================================
   3. 下拉菜单 (PC端)
   ========================================= */
.dropdown-menu { display: none; }

@media (min-width: 993px) {
    .dropdown-menu {
        display: block;
        position: absolute;
        top: 70px;
        left: 0;
        width: 100%;
        opacity: 0;
        visibility: hidden;
        transform: translateY(10px);
        transition: all 0.3s ease;
        pointer-events: none;
        z-index: 999;
        margin-top: -10px;
        border-top: 10px solid transparent;
    }

    .nav-item:hover .dropdown-menu {
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
        pointer-events: auto;
    }

    .dropdown-content {
        background-color: #fff;
        border-radius: 12px;
        box-shadow: 0 10px 30px rgba(0,0,0,0.1);
        padding: 30px;
        display: flex;
        justify-content: space-between;
        width: 100%;
        box-sizing: border-box;
    }

    .dropdown-column {
        flex: 1;
        padding: 0 15px;
        border-right: 1px solid #f0f0f0;
    }
    .dropdown-column:last-child { border-right: none; }

    .dropdown-column h4 {
        font-size: 18px; font-weight: 600; color: #333;
        margin: 0 0 25px 0;
    }

    .dropdown-item {
        display: flex; align-items: flex-start; gap: 15px;
        padding: 15px; border-radius: 6px;
        margin-bottom: 10px;
    }
    .dropdown-item:hover { background-color: #f7f8fa; }
    
    .dropdown-item .icon { width: 24px; height: 24px; margin-top: 2px; flex-shrink: 0; color: #FF4040; }
    .dropdown-item .text-content .title { font-size: 16px; font-weight: 500; color: #333; margin-bottom: 5px; display: block;}
    .dropdown-item .text-content .description { font-size: 14px; color: #888; margin: 0; display: block; line-height: 1.5; }
}

/* =========================================
   4. Banner (Hero) 区域
   ========================================= */
.hero, .product-hero, .about-hero {
    background-size: cover; background-position: center; color: #fff; text-align: center;
    position: relative; width: 100%;
}
.hero { padding: 140px 0; background-image: linear-gradient(rgba(0,0,0,0.4), rgba(0,0,0,0.4)), url('../img/misc/top.jpg'); }
.about-hero { padding: 100px 0; background-image: linear-gradient(rgba(0,0,0,0.4), rgba(0,0,0,0.4)), url('../img/misc/top.jpg'); }
.product-hero { padding: 120px 0; min-height: 420px; display: flex; align-items: center; justify-content: center; }

/* 产品背景 */
.hero-bcic { background-image: linear-gradient(rgba(0,0,0,0.4), rgba(0,0,0,0.4)), url('../img/products/bcic-top.jpg'); }
.hero-sjzt { background-image: linear-gradient(rgba(0,0,0,0.4), rgba(0,0,0,0.4)), url('../img/products/sjzt-top.jpg'); }
.hero-xmgl { background-image: linear-gradient(rgba(0,0,0,0.5), rgba(0,0,0,0.5)), url('../img/products/xmgl-top.jpg'); }
.hero-yygj { background-image: linear-gradient(rgba(0,0,0,0.4), rgba(0,0,0,0.4)), url('../img/products/yygj-top.jpg'); }
.hero-ycrh { background-image: linear-gradient(rgba(0,0,0,0.4), rgba(0,0,0,0.4)), url('../img/products/ycrh-top.jpg'); }
.hero-hjjc { background-image: linear-gradient(rgba(0,0,0,0.4), rgba(0,0,0,0.4)), url('../img/products/hjjc-top.png'); }
.hero-swhj { background-image: linear-gradient(rgba(0,0,0,0.4), rgba(0,0,0,0.4)), url('../img/products/swhj-top.png'); }

.hero h1, .product-hero h1, .about-hero h1 { font-size: 64px; margin: 0 0 20px; font-weight: 600; text-shadow: 0 2px 4px rgba(0,0,0,0.5); }
.hero p, .product-hero p, .about-hero p { font-size: 28px; color: #f0f0f0; max-width: 850px; margin: 0 auto; text-shadow: 0 1px 3px rgba(0,0,0,0.5); }
.product-hero .subtitle { font-size: 24px; font-weight: 500; margin: 0 0 15px 0; display: block; }

/* =========================================
   5. 首页产品介绍 (完全还原原代码逻辑)
   ========================================= */
/* 此部分代码逻辑严格对应您提供的原始 index.html */

.product-showcase {
    display: flex;
    align-items: stretch;
    justify-content: space-between;
    background-color: #fff;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.05);
    margin-bottom: 50px;
    overflow: hidden;
    transition: all 0.3s ease;
    /* 原代码未设置 height，此处也不设置，由内容撑开 */
}

.product-showcase:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 32px rgba(0,0,0,0.08);
}

.product-showcase:nth-child(even) {
    flex-direction: row-reverse;
}

.product-info {
    flex: 1; /* 对应原代码：占据剩余空间 */
    padding: 50px 60px; /* 对应原代码：padding */
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.product-info h3 {
    font-size: 26px; /* 对应原代码 */
    font-weight: 600;
    margin: 0;
    color: #1a1a1a;
}

.product-info .details {
    font-size: 15px; /* 对应原代码 */
    color: #666;
    line-height: 1.8;
    margin-top: 15px;
    margin-bottom: 35px;
    /* 原代码未设置 text-align: justify，故此处不设置 */
}

.product-image {
    flex: 0 0 550px; /* 对应原代码：固定宽度 550px */
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.cta-button {
    display: inline-block;
    background: linear-gradient(to right, #F96A53, #D81E06);
    color: #fff;
    padding: 12px 24px;
    text-decoration: none;
    border-radius: 6px;
    font-weight: 500;
    align-self: flex-start;
    border: none;
}
.cta-button:hover { background: linear-gradient(to right, #C01202, #C01202); }

/* =========================================
   6. 通用组件 (Feature, Grid, Workflow)
   ========================================= */
/* BCIC Workflow */
.workflow-steps { display: flex; justify-content: space-between; align-items: flex-start; text-align: center; margin-top: 40px; }
.workflow-step { flex: 1; max-width: 200px; position: relative; padding: 0 10px; }
.workflow-step:not(:last-child)::after {
    content: ''; position: absolute; top: 45px; left: 67%; width: 67%; height: 12px; transform: translate(45px, -50%);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M4 0 L12 6 L4 12' fill='none' stroke='%233498db' stroke-width='2'/%3E%3C/svg%3E"), linear-gradient(to right, #ccc 60%, transparent 40%);
    background-repeat: no-repeat, repeat-x; background-position: center, center; background-size: 12px 12px, 15px 2px;
}
.workflow-icon { width: 90px; height: 90px; border-radius: 50%; background: #fff; border: 2px solid #3498db; display: flex; align-items: center; justify-content: center; margin: 0 auto 25px; color: #3498db; }
.workflow-icon svg { width: 40px !important; height: 40px !important; }

/* Grid 补丁 */
.core-modules-grid, .advantages-grid, .scenarios-grid, .swhj-grid-4, .swhj-grid-3, .swhj-grid-2 {
    display: grid !important; gap: 30px !important; width: 100% !important;
}
.core-modules-grid { grid-template-columns: repeat(3, 1fr) !important; }
.advantages-grid, .scenarios-grid, .swhj-grid-4 { grid-template-columns: repeat(4, 1fr) !important; }
.swhj-grid-3 { grid-template-columns: repeat(3, 1fr) !important; }
.swhj-grid-2 { grid-template-columns: repeat(2, 1fr) !important; }

/* 左右图文 */
.feature-row, .advantage-item-row { display: flex; align-items: center; gap: 50px; margin-bottom: 70px; }
.feature-row:nth-child(even), .advantage-item-row:nth-child(even) { flex-direction: row-reverse; }
.feature-text, .advantage-text { flex: 1; }
.feature-image, .advantage-image { flex: 1; }
.feature-image img, .advantage-image img { width: 100%; border-radius: 12px; box-shadow: 0 8px 24px rgba(0,0,0,0.08); display: block; }

/* 场景图片圆形 */
.scenario-item .image-wrapper, .scenario-item img.circle-img {
    width: 150px !important; height: 150px !important; margin: 0 auto 20px !important; border-radius: 50% !important; object-fit: cover !important; display: block !important;
}
.scenario-item, .advantage-item { text-align: center !important; }

/* 模块卡片 */
.module-card, .advantage-item { background: #fff; border: 1px solid #e9e9e9; border-radius: 8px; padding: 30px; transition: transform 0.3s; }
.module-card:hover, .advantage-item:hover { transform: translateY(-5px); }
.module-icon { width: 80px; height: 80px; border-radius: 50%; background: #eaf4fb; margin: 0 auto 20px; display: flex; align-items: center; justify-content: center; color: #3498db; }
.module-icon svg { width: 36px; height: 36px; }

/* 通用图片容器 */
.diagram-container { text-align: center; }
.diagram-container img { max-width: 100%; height: auto; display: block; margin: 0 auto 30px; border-radius: 8px; }
.featured-image { text-align: center; }
.featured-image img { max-width: 100%; border-radius: 12px; }

/* =========================================
   7. 特定页面组件 (HJJC, SWHJ, SJZT)
   ========================================= */
/* SJZT 轮播 */
.carousel-container { position: relative; max-width: 1000px; margin: 0 auto; overflow: hidden; border-radius: 8px; }
.carousel-slider { display: flex; transition: transform 0.5s ease-in-out; }
.carousel-slide { min-width: 100%; }
.carousel-slide img { width: 100%; display: block; }
.carousel-btn { position: absolute; top: 50%; transform: translateY(-50%); background: rgba(0,0,0,0.4); color: #fff; border: none; padding: 10px; cursor: pointer; border-radius: 50%; z-index: 10; font-size: 20px; }
.carousel-btn.prev { left: 15px; } .carousel-btn.next { right: 15px; }
.carousel-dots { text-align: center; padding-top: 20px; }
.dot { cursor: pointer; height: 12px; width: 12px; margin: 0 5px; background: #ddd; border-radius: 50%; display: inline-block; }
.dot.active { background: #717171; }

/* HJJC/SWHJ 样式 */
.func-card { background: #f9f9f9; border-radius: 16px; padding: 40px; margin-bottom: 40px; border: 1px solid #eee; }
.func-header { display: flex; gap: 15px; margin-bottom: 20px; }
.func-icon { width: 48px; height: 48px; border-radius: 12px; display: flex; align-items: center; justify-content: center; color: white; flex-shrink: 0; }
.func-icon svg { width: 28px; height: 28px; }
.bg-blue { background: #3b82f6; } .bg-green { background: #22c55e; } .bg-red { background: #ef4444; } .bg-purple { background: #a855f7; } .bg-orange { background: #f97316; }
.func-image { width: 100%; border-radius: 8px; overflow: hidden; background: #fff; box-shadow: 0 4px 15px rgba(0,0,0,0.05); }

.scene-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 30px; }
.scene-item { position: relative; border-radius: 50%; overflow: hidden; aspect-ratio: 1/1; box-shadow: 0 8px 20px rgba(0,0,0,0.1); }
.scene-label { position: absolute; bottom: 20px; left: 50%; transform: translateX(-50%); background: rgba(255,255,255,0.95); padding: 8px 20px; border-radius: 50px; width: 70%; text-align: center; backdrop-filter: blur(5px); }

/* SWHJ */
.swhj-card { background: #fff; border-radius: 12px; padding: 24px; box-shadow: 0 4px 12px rgba(0,0,0,0.05); border: 1px solid #eee; transition: 0.3s; }
.swhj-card:hover { transform: translateY(-5px); box-shadow: 0 10px 25px rgba(0,0,0,0.1); }
.param-header { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.param-icon { width: 48px; height: 48px; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 24px; }
.bg-orange-light { background: #fff7ed; color: #f97316; } .bg-green-light { background: #f0fdf4; color: #22c55e; } .bg-blue-light { background: #eff6ff; color: #3b82f6; } .bg-purple-light { background: #faf5ff; color: #a855f7; }
.param-list { list-style: none; padding: 0; margin: 0; }
.param-list li { display: flex; align-items: center; gap: 8px; font-size: 18px; color: #555; margin-bottom: 8px; }
.dot { width: 6px; height: 6px; border-radius: 50%; }
.dot-orange { background: #f97316; } .dot-green { background: #22c55e; } .dot-blue { background: #3b82f6; } .dot-purple { background: #a855f7; }

/* =========================================
   8. 关于我们页面 - 联系卡片细节修复
   ========================================= */
.contact-card {
    display: flex; /* 让文字信息和地图并排 */
    gap: 50px;
    background: #fff;
    padding: 50px;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.05);
}

.contact-info {
    flex: 1; /* 占据左侧空间 */
}

.info-item {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 20px;
}

/* 核心修复：限制图标大小 */
.info-item svg {
    width: 24px !important;
    height: 24px !important;
    color: #FF4040;
    flex-shrink: 0;
}

.info-item span {
    font-size: 16px;
    color: #666;
    line-height: 1.6;
}

.qr-code-section {
    margin-top: 30px;
    text-align: left;
}

.qr-code-section img {
    width: 120px;
    border: 1px solid #eee;
    padding: 5px;
    border-radius: 4px;
}

.map-container {
    flex: 1; /* 占据右侧空间 */
    min-height: 300px;
    border-radius: 8px;
    overflow: hidden;
}

.map-container iframe {
    width: 100%;
    height: 100%;
    border: none;
}

/* 移动端适配 */
@media (max-width: 992px) {
    .contact-card { flex-direction: column; padding: 30px; }
    .map-container { height: 300px; }
}

/* =========================================
   9. 页脚 & 联系
   ========================================= */
.contact-card { display: flex; background: #fff; border-radius: 12px; box-shadow: 0 8px 24px rgba(0,0,0,0.05); overflow: hidden; gap: 40px; padding: 50px; }
.site-footer { background-color: #2f343a; color: #c9c9c9; padding: 60px 0 20px; }
.footer-main { display: flex; justify-content: space-between; border-bottom: 1px solid #444; padding-bottom: 40px; }
.footer-brand { flex-basis: 260px; margin-right: 40px; }
.footer-brand .logo-text img { height: 120px; filter: brightness(0) invert(1); }
.footer-nav { display: flex; flex-grow: 1; justify-content: space-around; }
.footer-column h4 { font-size: 16px; color: #fff; margin-bottom: 20px; font-weight: 500; }
.footer-column ul { padding: 0; margin: 0; list-style: none; }
.footer-column li a { color: #c9c9c9; line-height: 2.2; }
.footer-qr { text-align: center; }
.footer-qr img { width: 120px; background: #fff; padding: 5px; border-radius: 4px; }
.footer-bottom { padding-top: 20px; text-align: center; font-size: 14px; }

/* =========================================
   10. 移动端适配
   ========================================= */
.mobile-nav, .overlay { display: none; }

@media (max-width: 992px) {
    .nav { display: none; }
    .hamburger-menu { display: block; width: 30px; height: 24px; cursor: pointer; z-index: 1010; }
    .overlay { display: block; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.5); opacity: 0; visibility: hidden; transition: 0.3s; z-index: 1001; }
    .overlay.is-active { opacity: 1; visibility: visible; }
    
    .mobile-nav { 
        display: block; position: fixed; top: 0; right: 0; width: 80%; max-width: 320px; height: 100%;
        background: #fff; z-index: 1005; padding-top: 80px; box-shadow: -5px 0 25px rgba(0,0,0,0.1);
        transform: translateX(100%); transition: transform 0.3s ease-in-out;
    }
    .mobile-nav.is-active { transform: translateX(0); }
    .mobile-nav .close-btn { position: absolute; top: 20px; right: 20px; width: 24px; height: 24px; }
    .mobile-nav ul { list-style: none; padding: 0; margin: 0; }
    .mobile-nav ul li a { display: flex; justify-content: space-between; padding: 15px 30px; border-bottom: 1px solid #f0f0f0; color: #333; }
    .mobile-nav .arrow { width: 10px; height: 10px; border-right: 2px solid #333; border-bottom: 2px solid #333; transform: rotate(45deg); transition: 0.3s; }
    .mobile-nav .arrow.open { transform: rotate(-135deg); }
    .mobile-submenu { display: none; background: #f7f8fa; padding: 0; }
    .mobile-submenu li a { padding-left: 50px; font-size: 14px; color: #666; }

    /* 移动端内容适配 */
    .product-showcase, .product-showcase:nth-child(even) { flex-direction: column !important; }
    .product-image { flex-basis: 300px; } /* 原代码逻辑：移动端 300px */
    .product-info { padding: 40px; text-align: center; }
    .product-info .cta-button { align-self: center; }

    .core-modules-grid, .advantages-grid, .scenarios-grid, .swhj-grid-4, .swhj-grid-3, .contact-card, .footer-main {
        grid-template-columns: 1fr !important; flex-direction: column !important; text-align: center !important;
    }
    .feature-row, .feature-row:nth-child(even), .advantage-item-row, .advantage-item-row:nth-child(even) { flex-direction: column !important; }
    .footer-nav { flex-direction: column; gap: 30px; }
    .footer-brand { margin-right: 0; margin-bottom: 40px; }
}