/* 全局样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Noto Sans SC', sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f5f5f5;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 导航栏 */
.navbar {
    background-color: #fff;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    transition: all 0.3s ease;
}

.navbar.scrolled {
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
}

.navbar-brand .logo {
    display: flex;
    flex-direction: row;
    align-items: center;
    text-decoration: none;
    color: #333;
}

.logo-text {
    font-size: 32px;
    font-weight: 700;
    color: #0066cc;
}

.logo-subtext {
    font-size: 32px;
    font-weight: 700;
    color: #0066cc;
    margin-left: 10px;
}

.navbar-nav ul {
    display: flex;
    list-style: none;
}

.navbar-nav ul li {
    margin-left: 30px;
}

.navbar-nav ul li a {
    text-decoration: none;
    color: #333;
    font-weight: 500;
    transition: color 0.3s ease;
}

.navbar-nav ul li a:hover {
    color: #0066cc;
}

.navbar-toggle {
    display: none;
    cursor: pointer;
    font-size: 24px;
    color: #333;
}

/* 英雄区域 */
.hero {
    background: linear-gradient(135deg, #0066cc 0%, #0099ff 100%);
    color: #fff;
    padding: 120px 0 80px;
    text-align: center;
}

.hero-content h1 {
    font-size: 48px;
    font-weight: 700;
    margin-bottom: 20px;
    line-height: 1.2;
}

.hero-content p {
    font-size: 18px;
    margin-bottom: 40px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.hero-buttons {
    display: flex;
    justify-content: center;
    gap: 20px;
}

.btn {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 4px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
}

.btn-primary {
    background-color: #fff;
    color: #0066cc;
}

.btn-primary:hover {
    background-color: #f0f0f0;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.btn-secondary {
    background-color: transparent;
    color: #fff;
    border: 2px solid #fff;
}

.btn-secondary:hover {
    background-color: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.btn-sm {
    padding: 8px 20px;
    font-size: 14px;
}

/* 通用区块样式 */
.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.section-header h2 {
    font-size: 36px;
    font-weight: 700;
    margin-bottom: 20px;
    color: #333;
}

.section-header p {
    font-size: 16px;
    color: #666;
    max-width: 800px;
    margin: 0 auto;
}

/* 关于我们 */
.about {
    padding: 100px 0;
    background-color: #fff;
}

.about-content {
    display: flex;
    flex-wrap: wrap;
    gap: 60px;
    align-items: center;
}

.about-text {
    flex: 1;
    min-width: 300px;
}

.about-text h3 {
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 20px;
    color: #333;
}

.about-text p {
    margin-bottom: 20px;
    color: #666;
}

.about-text ul {
    list-style: none;
}

.about-text ul li {
    margin-bottom: 10px;
    color: #666;
    display: flex;
    align-items: center;
}

.about-text ul li i {
    color: #0066cc;
    margin-right: 10px;
}

.about-image {
    flex: 1;
    min-width: 300px;
}

.about-image img {
    width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* 产品中心 */
.products {
    padding: 100px 0;
    background-color: #f5f5f5;
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
}

.product-card {
    background-color: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.product-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

.product-image {
    height: 200px;
    overflow: hidden;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.product-card:hover .product-image img {
    transform: scale(1.1);
}

.product-info {
    padding: 20px;
}

.product-info h3 {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 10px;
    color: #333;
}

.product-info p {
    margin-bottom: 20px;
    color: #666;
    font-size: 14px;
}

/* 解决方案 */
.solutions {
    padding: 100px 0;
    background-color: #fff;
}

.solutions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.solution-card {
    background-color: #f9f9f9;
    padding: 40px 30px;
    border-radius: 8px;
    text-align: center;
    transition: all 0.3s ease;
}

.solution-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
    background-color: #0066cc;
    color: #fff;
}

.solution-icon {
    font-size: 48px;
    margin-bottom: 20px;
    color: #0066cc;
    transition: all 0.3s ease;
}

.solution-card:hover .solution-icon {
    color: #fff;
}

.solution-card h3 {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 15px;
    transition: all 0.3s ease;
}

.solution-card p {
    color: #666;
    transition: all 0.3s ease;
}

.solution-card:hover p {
    color: #f0f0f0;
}

/* 技术分享 */
.tech {
    padding: 100px 0;
    background-color: #f5f5f5;
}

.tech-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.tech-card {
    background-color: #fff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.tech-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

.tech-card h3 {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 15px;
    color: #333;
}

.tech-card p {
    margin-bottom: 20px;
    color: #666;
    font-size: 14px;
}

/* 资料下载 */
.downloads {
    padding: 100px 0;
    background-color: #fff;
}

.downloads-categories {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
}

.category h3 {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 20px;
    color: #333;
    padding-bottom: 10px;
    border-bottom: 2px solid #0066cc;
}

.category ul {
    list-style: none;
}

.category ul li {
    margin-bottom: 15px;
}

.category ul li a {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: #666;
    transition: all 0.3s ease;
}

.category ul li a:hover {
    color: #0066cc;
    transform: translateX(5px);
}

.category ul li a i {
    margin-right: 10px;
    color: #0066cc;
}

/* 联系我们 */
.contact {
    padding: 100px 0;
    background-color: #f5f5f5;
}

.contact-content {
    display: flex;
    flex-wrap: wrap;
    gap: 60px;
}

.contact-info {
    flex: 1;
    min-width: 300px;
}

.info-item {
    display: flex;
    align-items: flex-start;
    margin-bottom: 30px;
}

.info-item i {
    font-size: 24px;
    color: #0066cc;
    margin-right: 20px;
    margin-top: 5px;
}

.info-item h4 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 5px;
    color: #333;
}

.info-item p {
    color: #666;
}

.contact-form {
    flex: 1;
    min-width: 300px;
    background-color: #fff;
    padding: 40px;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #333;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #0066cc;
    box-shadow: 0 0 0 2px rgba(0, 102, 204, 0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

/* 页脚 */
.footer {
    background-color: #333;
    color: #fff;
    padding: 60px 0 30px;
}

.footer-content {
    display: flex;
    flex-wrap: wrap;
    gap: 60px;
    margin-bottom: 40px;
}

.footer-info {
    flex: 1;
    min-width: 250px;
}

.footer-logo {
    display: block;
    margin-bottom: 20px;
}

.footer-logo .logo-text {
    display: block;
    font-size: 24px;
    font-weight: 700;
    color: #fff;
    margin-bottom: 5px;
}

.footer-logo .logo-subtext {
    display: block;
    font-size: 14px;
    color: #ccc;
}

.footer-info p {
    margin-bottom: 20px;
    color: #ccc;
}

.social-links {
    display: flex;
    gap: 15px;
}

.social-links a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.1);
    color: #fff;
    transition: all 0.3s ease;
}

.social-links a:hover {
    background-color: #0066cc;
    transform: translateY(-3px);
}

.footer-links {
    flex: 1;
    min-width: 200px;
}

.footer-links h4,
.footer-contact h4 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 20px;
    color: #fff;
}

.footer-links ul {
    list-style: none;
}

.footer-links ul li {
    margin-bottom: 10px;
}

.footer-links ul li a {
    text-decoration: none;
    color: #ccc;
    transition: color 0.3s ease;
}

.footer-links ul li a:hover {
    color: #0066cc;
}

.footer-contact {
    flex: 1;
    min-width: 250px;
}

.footer-contact ul {
    list-style: none;
}

.footer-contact ul li {
    margin-bottom: 10px;
    color: #ccc;
    display: flex;
    align-items: flex-start;
    word-break: break-all;
}

.footer-contact ul li i {
    margin-right: 10px;
    color: #0066cc;
}

.footer-bottom {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: #ccc;
    font-size: 14px;
}

/* ========== 新增修复：确保所有标题自动换行，不截断 ========== */
h1, h2, h3, h4, h5, h6 {
    word-wrap: break-word;
    word-break: break-word;
    white-space: normal;
    overflow-wrap: break-word;
    max-width: 100%;
}

/* 针对文章详情页的标题特别处理，防止被截断或隐藏 */
.about-content h1,
.about h1,
.section-header h1 {
    white-space: normal !important;
    word-break: break-word !important;
    overflow-wrap: break-word !important;
    text-overflow: clip !important;
    overflow: visible !important;
}

/* ===== 修复首页技术分享标题截断 ===== */
.tech-card h3,
.product-info h3,
.solution-card h3,
.about-text h3,
.about-content h1,
.about-content h2,
.about-content h3 {
    white-space: normal !important;
    word-break: break-word !important;
    overflow-wrap: break-word !important;
    overflow: visible !important;
    text-overflow: clip !important;
    max-width: 100% !important;
    max-height: none !important;
    line-height: 1.4 !important;
}

/* 确保卡片自适应高度，不限制溢出 */
.tech-card,
.product-card,
.solution-card {
    height: auto !important;
    overflow: visible !important;
}

/* 响应式设计 */
@media (max-width: 992px) {
    .hero-content h1 {
        font-size: 36px;
    }
    
    .about-content,
    .contact-content {
        flex-direction: column;
    }
    
    .navbar-nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background-color: #fff;
        box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
        padding: 20px;
    }
    
    .navbar-nav.active {
        display: block;
    }
    
    .navbar-nav ul {
        flex-direction: column;
    }
    
    .navbar-nav ul li {
        margin: 10px 0;
    }
    
    .navbar-toggle {
        display: block;
    }
}

@media (max-width: 768px) {
    .hero-content h1 {
        font-size: 28px;
    }
    
    .hero-content p {
        font-size: 16px;
    }
    
    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .section-header h2 {
        font-size: 28px;
    }
    
    .products-grid,
    .solutions-grid,
    .tech-grid,
    .downloads-categories {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        flex-direction: column;
        gap: 40px;
    }
}

@media (max-width: 576px) {
    .hero {
        padding: 100px 0 60px;
    }
    
    .hero-content h1 {
        font-size: 24px;
    }
    
    .section-header h2 {
        font-size: 24px;
    }
    
    .contact-form {
        padding: 30px 20px;
    }
}

/* 动画效果 */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.6s ease forwards;
}

/* 滚动条样式 */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: #0066cc;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #0052a3;
}

/* ===== 富文本内容样式（前台展示） ===== */
/* 表格样式 */
.about-content table,
.article-content table,
.tech-detail-content table {
    border-collapse: collapse;
    width: 100%;
    margin: 15px 0;
    font-size: 15px;
}
.about-content table th,
.about-content table td,
.article-content table th,
.article-content table td,
.tech-detail-content table th,
.tech-detail-content table td {
    border: 1px solid #ddd;
    padding: 8px 12px;
    text-align: left;
    vertical-align: top;
}
.about-content table th,
.article-content table th,
.tech-detail-content table th {
    background-color: #f2f2f2;
    font-weight: 600;
}
.about-content table tr:nth-child(even),
.article-content table tr:nth-child(even),
.tech-detail-content table tr:nth-child(even) {
    background-color: #f9f9f9;
}
.about-content table tr:hover,
.article-content table tr:hover,
.tech-detail-content table tr:hover {
    background-color: #f0f4f8;
}
/* 列表样式 */
.about-content ul,
.about-content ol,
.article-content ul,
.article-content ol,
.tech-detail-content ul,
.tech-detail-content ol {
    padding-left: 25px;
    margin: 10px 0;
}
/* 图片样式 */
.about-content img,
.article-content img,
.tech-detail-content img {
    max-width: 100%;
    height: auto;
    border-radius: 4px;
}
/* 引用块样式 */
.about-content blockquote,
.article-content blockquote,
.tech-detail-content blockquote {
    border-left: 4px solid #0066cc;
    padding: 10px 20px;
    margin: 15px 0;
    background-color: #f8f9fa;
    color: #555;
    font-style: italic;
}