/* 重置样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --header-h: 70px;
}

/* 基础样式 */
html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: 'PingFang SC', 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #fff;
}

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

/* 头部样式 */
.header {
    background: #fff;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px 0;
}

.logo {
    flex-shrink: 0;
}

.logo a {
    display: flex;
    align-items: center;
    line-height: 0;
}

.logo-img {
    height: 40px;
    width: auto;
}

.main-nav {
    flex: 1;
    display: flex;
    justify-content: center;
}

.nav-list {
    display: flex;
    list-style: none;
    gap: 40px;
}

.nav-item {
    position: relative;
}

.nav-link {
    text-decoration: none;
    color: #333;
    font-weight: 500;
    font-size: 16px;
    transition: color 0.3s ease;
    padding: 10px 0;
}

.nav-link:hover {
    color: #007bff;
}

/* 下拉菜单 */
.dropdown {
    position: relative;
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background: #fff;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    padding: 10px 0;
    min-width: 180px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    list-style: none;
}

.dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-menu li {
    margin: 0;
}

.dropdown-subitem {
    position: relative;
}

.dropdown-menu a {
    display: block;
    padding: 12px 20px;
    color: #333;
    text-decoration: none;
    transition: background-color 0.3s ease;
}

.dropdown-menu a:hover {
    background-color: #f8f9fa;
    color: #007bff;
}

.dropdown-submenu {
    position: absolute;
    top: 0;
    left: 100%;
    background: #fff;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    padding: 10px 0;
    min-width: 180px;
    opacity: 0;
    visibility: hidden;
    transform: translateX(-10px);
    transition: all 0.3s ease;
    list-style: none;
}

.dropdown-subitem:hover .dropdown-submenu {
    opacity: 1;
    visibility: visible;
    transform: translateX(0);
}

/* 产品中心三级菜单：左侧二级，右侧三级 */
.products-dropdown-menu {
    --products-l2-width: 160px;
    padding: 0;
    overflow: visible;
    min-width: var(--products-l2-width);
}

.products-dropdown-menu > .dropdown-subitem > a {
    display: block;
    width: var(--products-l2-width);
    padding: 16px 20px;
    border-right: 1px solid #f0f0f0;
    background: #fff;
}

.products-dropdown-menu > .dropdown-subitem:first-child > a {
    border-top-left-radius: 8px;
}

.products-dropdown-menu > .dropdown-subitem:last-child > a {
    border-bottom-left-radius: 8px;
}

.products-dropdown-menu .dropdown-submenu {
    display: none;
    top: 0;
    left: calc(100% + 1px);
    height: auto;
    max-height: 520px;
    overflow-y: auto;
    box-shadow: none;
    border-radius: 0 8px 8px 0;
    transform: none;
    transition: none;
    opacity: 1;
    visibility: visible;
    background: #fff;
}

.products-category-submenu {
    width: calc(var(--products-l2-width) * 4.5);
    display: flex;
    align-items: stretch;
    gap: 0;
    padding: 12px 8px;
}

.products-category-submenu > .category-type-col {
    flex: 1;
    min-width: 0;
    padding: 0 8px;
}

.products-category-submenu > .category-type-col + .category-type-col {
    border-left: 1px solid #e0e0e0;
}

.category-type-title {
    display: block;
    font-size: 15px;
    font-weight: 700;
    color: #222;
    letter-spacing: 0.5px;
    padding: 6px 12px 10px;
    margin-bottom: 4px;
    text-decoration: none;
}

.category-type-title:hover {
    color: #007bff;
}

.category-type-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.products-category-submenu a {
    padding: 9px 12px;
    font-size: 16px;
}

.products-dropdown-menu .dropdown-subitem:hover .dropdown-submenu {
    display: block;
}

.products-dropdown-menu .dropdown-subitem:hover .products-category-submenu {
    display: flex;
}

.products-dropdown-menu > .dropdown-subitem:hover > .dropdown-submenu {
    z-index: 2;
}

/* 搜索框 */
.search-box {
    flex-shrink: 0;
}

.search-form {
    display: flex;
    align-items: center;
    background: #f8f9fa;
    border-radius: 25px;
    padding: 8px 15px;
    transition: all 0.3s ease;
}

.search-form:focus-within {
    background: #fff;
    box-shadow: 0 0 0 2px #007bff;
}

.search-input {
    border: none;
    background: transparent;
    outline: none;
    padding: 5px 10px;
    font-size: 14px;
    width: 200px;
}

.search-btn {
    background: none;
    border: none;
    cursor: pointer;
    color: #666;
    transition: color 0.3s ease;
}

.search-btn:hover {
    color: #007bff;
}

/* 移动端菜单按钮 */
.mobile-menu-btn {
    display: none;
    flex-direction: column;
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
}

.mobile-menu-btn span {
    width: 25px;
    height: 3px;
    background: #333;
    margin: 3px 0;
    transition: 0.3s;
}

/* 移动端菜单 */
.mobile-menu {
    display: none;
    position: fixed;
    top: var(--header-h);
    left: 0;
    right: 0;
    background: #fff;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    z-index: 999;
    max-height: calc(100vh - var(--header-h));
    overflow: hidden;
}

.mobile-menu-content {
    max-height: calc(100vh - var(--header-h));
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

.mobile-menu-open {
    overflow: hidden;
    height: 100vh;
}

.mobile-nav-list {
    list-style: none;
    padding: 20px;
}

.mobile-nav-list li {
    margin-bottom: 15px;
}

.mobile-nav-list a {
    color: #333;
    text-decoration: none;
    font-size: 16px;
    display: block;
    padding: 10px 0;
}

/* 移动端手风琴菜单（多级） */
.mobile-accordion-toggle {
    width: 100%;
    text-align: left;
    background: none;
    border: none;
    color: #333;
    font-size: 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 0;
    cursor: pointer;
}

.mobile-accordion-toggle::after {
    content: '';
    width: 10px;
    height: 10px;
    margin-left: 12px;
    border-right: 2px solid #999;
    border-bottom: 2px solid #999;
    transform: rotate(45deg);
    transition: transform 0.2s ease, border-color 0.2s ease;
    flex: 0 0 auto;
}

.mobile-accordion-item.is-open > .mobile-accordion-toggle::after {
    transform: rotate(-135deg);
    border-color: #007bff;
}

.mobile-subnav {
    list-style: none;
    display: none;
    padding-left: 18px;
    margin: 6px 0 12px;
}

.mobile-accordion-item.is-open > .mobile-subnav {
    display: block;
}

.mobile-accordion-item .mobile-accordion-item .mobile-subnav {
    padding-left: 26px;
}

.mobile-accordion-item .mobile-accordion-item .mobile-accordion-item .mobile-subnav {
    padding-left: 38px;
}

.mobile-accordion-item .mobile-accordion-item .mobile-accordion-toggle {
    font-size: 16px;
}

.mobile-accordion-item .mobile-accordion-item .mobile-accordion-item .mobile-accordion-toggle {
    font-size: 16px;
}

/* 主要内容区域 */
.main-content {
    margin-top: var(--header-h);
}

/* 轮播图样式 */
.hero-section {
    position: relative;
    height: 500px;
    overflow: hidden;
}

.hero-swiper {
    height: 100%;
}

.hero-slide {
    position: relative;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
}

.hero-slide-content {
    text-align: center;
    padding: 0 20px;
}

.hero-slide h1 {
    font-size: 3rem;
    margin-bottom: 20px;
    font-weight: 700;
}

.hero-slide p {
    font-size: 1.2rem;
    margin-bottom: 30px;
    opacity: 0.9;
}

.hero-slide .btn {
    display: inline-block;
    background: #fff;
    color: #333;
    padding: 15px 30px;
    border-radius: 30px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.hero-slide .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

/* 产品展示区域 */
.products-section {
    padding: 80px 0;
    background: #f8f9fa;
}

.section-title {
    text-align: center;
    margin-bottom: 60px;
}

.section-title h2 {
    font-size: 2.5rem;
    color: #333;
    margin-bottom: 15px;
}

.section-title p {
    font-size: 1.1rem;
    color: #666;
    max-width: 600px;
    margin: 0 auto;
}

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

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

.product-card:hover {
    transform: translateY(-5px);
}

.product-image {
    height: 200px;
    background: linear-gradient(45deg, #667eea, #764ba2);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.2rem;
}

.product-info {
    padding: 25px;
}

.product-info h3 {
    font-size: 1.3rem;
    margin-bottom: 10px;
    color: #333;
}

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

.product-link {
    display: inline-block;
    color: #007bff;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

.product-link:hover {
    color: #0056b3;
}

/* 行业案例区域 */
.cases-section {
    padding: 80px 0;
}

.cases-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 40px;
    margin-top: 60px;
}

.case-card {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.case-card:hover {
    transform: translateY(-5px);
}

.case-image {
    height: 200px;
    background: linear-gradient(45deg, #ff6b6b, #ffa500);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.1rem;
}

.case-content {
    padding: 25px;
}

.case-content h3 {
    font-size: 1.3rem;
    margin-bottom: 15px;
    color: #333;
}

.case-content p {
    color: #666;
    line-height: 1.6;
    margin-bottom: 20px;
}

.case-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.case-tag {
    background: #e9ecef;
    color: #495057;
    padding: 5px 12px;
    border-radius: 15px;
    font-size: 0.9rem;
}

/* 合作伙伴区域 */
.partners-section {
    padding: 80px 0;
    background: #f8f9fa;
}

.partners-tabs {
    display: flex;
    justify-content: center;
}

.tab-btn {
    background: none;
    border: none;
    padding: 15px 30px;
    font-size: 1.1rem;
    color: #666;
    cursor: pointer;
    border-bottom: 3px solid transparent;
    transition: all 0.3s ease;
}

.tab-btn.active {
    color: #007bff;
    border-bottom-color: #007bff;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

.partners-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.partner-item {
    background: #fff;
    border-radius: 8px;
    padding: 30px;
    text-align: center;
    box-shadow: 0 3px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.partner-item:hover {
    transform: translateY(-3px);
}

.partner-image {
    height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 15px;
    overflow: hidden;
    position: relative;
}

.partner-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* 为每个合作伙伴设置不同的背景色 */
.partner-item:nth-child(1) .partner-image {
    background: linear-gradient(135deg, #4A90E2, #357ABD);
}

.partner-item:nth-child(2) .partner-image {
    background: linear-gradient(135deg, #E74C3C, #C0392B);
}

/* 企业tab的合作伙伴背景色 */
#enterprises .partner-item:nth-child(1) .partner-image {
    background: linear-gradient(135deg, #FF6B6B, #E74C3C);
}

#enterprises .partner-item:nth-child(2) .partner-image {
    background: linear-gradient(135deg, #4ECDC4, #27AE60);
}

.partner-name {
    font-weight: 600;
    color: #333;
}

/* 页脚样式 */
.footer {
    background: #2c3e50;
    color: #ecf0f1;
    padding: 60px 0 20px;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 40px;
}

.footer-section h4 {
    color: #fff;
    margin-bottom: 20px;
    font-size: 1.2rem;
}

.footer-logo {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
}

.footer-logo-img {
    height: 40px;
    width: auto;
    margin-right: 15px;
}

.footer-logo h3 {
    color: #fff;
    font-size: 1.5rem;
}

.footer-desc {
    color: #bdc3c7;
    margin-bottom: 25px;
    line-height: 1.6;
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.contact-item {
    display: flex;
    align-items: center;
    color: #bdc3c7;
}

.contact-item svg {
    margin-right: 10px;
    color: #3498db;
}

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

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

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

.footer-links a:hover {
    color: #3498db;
}

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

.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: #34495e;
    color: #ecf0f1;
    border-radius: 50%;
    text-decoration: none;
    transition: all 0.3s ease;
}

.social-link:hover {
    background: #3498db;
    transform: translateY(-2px);
}

.qr-code {
    margin-top: 10px;
}

.qr-code img {
    width: 128px;
    height: 128px;
}

.footer-bottom {
    border-top: 1px solid #34495e;
    padding-top: 20px;
}

.footer-bottom-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #bdc3c7;
}

.footer-bottom-links {
    display: flex;
    gap: 20px;
}

.footer-bottom-links a {
    color: #bdc3c7;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-bottom-links a:hover {
    color: #3498db;
}

/* 响应式设计 */
@media (max-width: 768px) {
    :root {
        --header-h: 60px;
    }

    .container {
        padding: 0 15px;
    }
    
    .header-content {
        padding: 10px 0;
    }
    
    .main-nav {
        display: none;
    }
    
    .search-box {
        display: none;
    }
    
    .mobile-menu-btn {
        display: flex;
    }
    
    .mobile-menu.active {
        display: block;
    }
    
    .hero-slide h1 {
        font-size: 2rem;
    }
    
    .hero-slide p {
        font-size: 1rem;
    }
    
    .section-title h2 {
        font-size: 2rem;
    }
    
    .products-grid {
        grid-template-columns: 1fr;
    }
    
    .cases-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .footer-bottom-content {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .partners-tabs {
        flex-direction: column;
        gap: 10px;
    }
    
    .tab-btn {
        border-bottom: none;
        border-left: 3px solid transparent;
    }
    
    .tab-btn.active {
        border-left-color: #007bff;
        border-bottom-color: transparent;
    }
}

@media (max-width: 480px) {
    .hero-section {
        height: 400px;
    }
    
    .hero-slide h1 {
        font-size: 1.5rem;
    }
    
    .section-title h2 {
        font-size: 1.8rem;
    }
    
    .products-section,
    .cases-section,
    .partners-section {
        padding: 60px 0;
    }
}
