/**
 * 企业官网自定义样式
 * 避免与现有项目样式冲突
 */

/* 基础重置 */
.website-wrapper * {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

.website-wrapper {
    font-family: 'Microsoft YaHei', 'PingFang SC', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    overflow-x: hidden;
    color: #333;
}

/* ==================== 导航栏样式 ==================== */
.navbar-website {
    position: fixed;
    top: 0;
    width: 100%;
    background: transparent;
    box-shadow: none;
    z-index: 1000;
    transition: all 0.3s ease;
    backdrop-filter: none;
    will-change: background, box-shadow;
}

.navbar-website.scrolled {
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.12);
    backdrop-filter: blur(10px);
}

.navbar-website .nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 30px;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 80px;
    position: relative;
    overflow: visible;
}

/* Logo样式 */
.navbar-website .website-logo {
    position: absolute;
    left: 30px;
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    transition: transform 0.3s;
    z-index: 1005;
    /* 限制Logo宽度，为右侧按钮留出空间 */
    max-width: 60%;
}

.navbar-website .website-logo:hover {
    transform: scale(1.05);
}

.navbar-website .logo-image {
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
    position: relative;
    /* 限制图片最大宽度 */
    max-width: 200px;
}

.navbar-website.scrolled .logo-image {
    /* 滚动后保持透明 */
}

.navbar-website .logo-image img {
    height: 100%;
    width: auto;
    max-width: 100%;
    object-fit: contain;
    transition: opacity 0.3s ease;
}

/* 白色logo默认显示（未滚动时） */
.navbar-website .logo-light {
    display: block;
}

/* 黑色logo默认隐藏 */
.navbar-website .logo-dark {
    display: none;
}

/* 滚动后显示黑色logo，隐藏白色logo */
.navbar-website.scrolled .logo-dark {
    display: block;
}

.navbar-website.scrolled .logo-light {
    display: none;
}

.navbar-website .logo-text {
    display: flex;
    flex-direction: column;
}

.navbar-website .brand-name {
    font-size: 24px;
    font-weight: bold;
    color: #fff;
    line-height: 1.2;
    transition: color 0.3s;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.navbar-website.scrolled .brand-name {
    color: #4caf50;
}

.navbar-website .brand-slogan {
    font-size: 9px;
    color: rgba(255, 255, 255, 0.8);
    letter-spacing: 1px;
    transition: color 0.3s;
}

.navbar-website.scrolled .brand-slogan {
    color: #999;
}

/* 导航菜单 */
.navbar-website .website-nav-menu {
    display: flex;
    list-style: none;
    gap: 5px;
    align-items: center;
    margin: 0;
    padding: 0;
}

.navbar-website .website-nav-menu>li {
    position: relative;
    flex-shrink: 0;
}

/* 导航链接样式 */
.navbar-website .website-nav-menu>li>a {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 10px 20px;
    text-decoration: none;
    color: #fff;
    font-size: 16px;
    font-weight: 500;
    transition: color 0.3s, background 0.3s;
    border-radius: 8px;
    position: relative;
    white-space: nowrap;
}

/* 强制覆盖 mobile.css 中的样式，PC端确保所有导航项 padding 一致 */
.navbar-website .website-nav-menu .has-dropdown > a {
    padding: 10px 20px !important;
}

/* PC端滚动后的导航链接颜色 */
.navbar-website.scrolled .website-nav-menu>li>a {
    color: #333;
}

/* PC端导航链接悬停和激活状态 */
.navbar-website .website-nav-menu>li>a:hover {
    color: #4caf50;
}

/* PC端滚动后导航链接悬停效果 */
.navbar-website.scrolled .website-nav-menu>li>a:hover {
    background: rgba(76, 175, 80, 0.05);
}

/* PC端和移动端激活状态链接颜色 */
.navbar-website .website-nav-menu>li.active>a {
    color: #4caf50;
}

/* 下拉菜单箭头 - 已移除 */

/* 二级下拉菜单 */
.navbar-website .website-dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 200px;
    background: white;
    border-radius: 10px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s ease;
    padding: 10px 0;
    margin-top: 10px;
    list-style: none;
}

.navbar-website .website-nav-menu>li:hover .website-dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.navbar-website .website-dropdown-menu li {
    list-style: none;
}

.navbar-website .website-dropdown-menu a {
    display: block;
    padding: 12px 25px;
    color: #555;
    text-decoration: none;
    font-size: 14px;
    transition: all 0.3s;
    position: relative;
}

.navbar-website .website-dropdown-menu a::before {
    content: '';
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    width: 0;
    height: 2px;
    background: #4caf50;
    transition: width 0.3s;
}

.navbar-website .website-dropdown-menu a:hover {
    color: #4caf50;
    background: rgba(76, 175, 80, 0.05);
    padding-left: 35px;
}

.navbar-website .website-dropdown-menu a:hover::before {
    width: 10px;
}

/* 右侧功能按钮 */
.navbar-website .nav-actions {
    display: flex;
    align-items: center;
    gap: 15px;
}

.navbar-website .search-btn,
.navbar-website .contact-btn {
    padding: 10px 20px;
    border: none;
    border-radius: 25px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.navbar-website .search-btn {
    background: transparent;
    color: #fff;
    border: 2px solid rgba(255, 255, 255, 0.5);
}

.navbar-website.scrolled .search-btn {
    color: #666;
    border-color: #e0e0e0;
}

.navbar-website .search-btn:hover {
    border-color: #4caf50;
    color: #4caf50;
    background: rgba(76, 175, 80, 0.1);
}

.navbar-website .contact-btn {
    background: linear-gradient(135deg, #4caf50, #2e7d32);
    color: white;
    font-weight: 600;
    box-shadow: 0 4px 15px rgba(76, 175, 80, 0.3);
}

.navbar-website .contact-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(76, 175, 80, 0.4);
    color: white;
    text-decoration: none;
}

/* 移动端菜单按钮 */
.navbar-website .mobile-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    padding: 10px;
    position: absolute;
    right: 20px;
    z-index: 1010;
    background: rgba(0, 0, 0, 0.3);
    border: none;
    outline: none;
    border-radius: 6px;
    transition: background 0.3s ease;
}

.navbar-website .mobile-toggle span {
    width: 25px;
    height: 3px;
    background: #fff;
    transition: all 0.3s ease;
    border-radius: 2px;
    display: block;
    pointer-events: none;
}

.navbar-website.scrolled .mobile-toggle {
    background: rgba(0, 0, 0, 0.05);
}

.navbar-website.scrolled .mobile-toggle span {
    background: #333;
}

/* 确保移动端按钮始终可见 */
.navbar-website .mobile-toggle.active span {
    background: #fff;
}

.navbar-website.scrolled .mobile-toggle.active span {
    background: #333;
}

.navbar-website .mobile-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
}

.navbar-website .mobile-toggle.active span:nth-child(2) {
    opacity: 0;
}

.navbar-website .mobile-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}

/* 移动端菜单遮罩层 */
.mobile-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: rgba(0, 0, 0, 0.5);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    z-index: 999;
    pointer-events: none;
    -webkit-tap-highlight-color: transparent;
}

.mobile-menu-overlay.active {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

/* ==================== 底部样式 ==================== */
.website-footer {
    background: #2c3e50;
    color: white;
    padding: 60px 20px 30px;
}

.website-footer .footer-content {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto 40px;
}

.website-footer .footer-section h3 {
    font-size: 20px;
    margin-bottom: 20px;
    color: #4caf50;
}

.website-footer .footer-section p {
    font-size: 14px;
    line-height: 1.8;
    color: #bdc3c7;
}

.website-footer .footer-section ul {
    list-style: none;
    padding: 0;
}

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

.website-footer .footer-section ul li a {
    color: #bdc3c7;
    text-decoration: none;
    transition: color 0.3s;
    font-size: 14px;
}

.website-footer .footer-section ul li a:hover {
    color: white;
}

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

.website-footer .footer-bottom a {
    color: #bdc3c7;
    text-decoration: none;
}

.website-footer .footer-bottom a:hover {
    color: white;
}

/* ==================== 响应式设计 ==================== */
@media (max-width: 992px) {
    .navbar-website .nav-container {
        height: 70px;
        padding: 0 20px;
    }

    .navbar-website .website-logo {
        left: 20px;
        max-width: 65%;
        z-index: 1005;
    }

    .navbar-website .logo-image {
        height: 40px;
        max-width: 180px;
    }

    .navbar-website .logo-image img {
        height: 100%;
        width: auto;
    }

    .navbar-website .brand-name {
        font-size: 20px;
    }

    .navbar-website .brand-slogan {
        display: none;
    }

    .navbar-website .mobile-toggle {
        display: flex;
        right: 20px;
        z-index: 1010;
    }

    .navbar-website .website-nav-menu {
        position: fixed;
        top: 70px;
        left: -100%;
        width: 300px;
        max-width: 80%;
        height: calc(100vh - 70px);
        background: white;
        flex-direction: column;
        padding: 30px 0;
        gap: 0;
        transition: left 0.3s ease;
        overflow-y: auto;
        overflow-x: hidden;
        box-shadow: 2px 0 20px rgba(0, 0, 0, 0.1);
        align-items: stretch;
        z-index: 1001;
        -webkit-overflow-scrolling: touch;
        transform: translateZ(0);
        backface-visibility: hidden;
        will-change: left;
    }

    .navbar-website .website-nav-menu.active {
        left: 0;
    }

    .navbar-website .website-nav-menu>li {
        width: 100%;
    }

    .navbar-website .website-nav-menu>li>a {
        padding: 15px 25px;
        border-radius: 0;
        justify-content: space-between;
        color: #333 !important;
        background: white;
        -webkit-tap-highlight-color: transparent;
        user-select: none;
    }

    .navbar-website .website-nav-menu>li>a:hover,
    .navbar-website .website-nav-menu>li.active>a {
        color: #4caf50 !important;
        background: rgba(76, 175, 80, 0.05);
    }

    .navbar-website .website-nav-menu>li>a i {
        transition: transform 0.3s;
    }

    .navbar-website .website-nav-menu>li.dropdown-open>a i {
        transform: rotate(180deg);
    }

    .navbar-website .website-dropdown-menu {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        box-shadow: none;
        margin-top: 0;
        padding: 0;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease;
        background: #f8f9fa;
    }

    .navbar-website .website-nav-menu>li.dropdown-open .website-dropdown-menu {
        max-height: 500px;
    }

    .navbar-website .website-dropdown-menu a {
        padding: 12px 25px 12px 45px;
        color: #555 !important;
        background: #f8f9fa;
    }

    .navbar-website .website-dropdown-menu a:hover {
        color: #4caf50 !important;
        background: rgba(76, 175, 80, 0.08);
        padding-left: 50px;
    }

    .navbar-website .nav-actions {
        display: none;
    }

    .navbar-website .mobile-toggle {
        display: flex;
        z-index: 1010;
    }

    .website-footer .footer-content {
        grid-template-columns: repeat(2, 1fr);
    }

    .website-footer {
        padding: 40px 20px 20px;
    }
}

@media (max-width: 768px) {
    .navbar-website .nav-container {
        height: 60px;
        padding: 0 15px;
    }

    .navbar-website .website-logo {
        left: 15px;
        max-width: 60%;
        z-index: 1005;
    }

    .navbar-website .logo-image {
        height: 35px;
        max-width: 150px;
    }

    .navbar-website .logo-image img {
        height: 100%;
        width: auto;
        max-height: 35px;
        max-width: 100%;
    }

    .navbar-website .brand-name {
        font-size: 16px;
    }

    .navbar-website .mobile-toggle {
        display: flex;
        right: 15px;
        padding: 8px;
        z-index: 1010;
    }

    .navbar-website .mobile-toggle span {
        width: 22px;
        height: 2.5px;
        display: block;
    }

    .navbar-website .website-nav-menu {
        top: 60px;
        height: calc(100vh - 60px);
        padding: 20px 0;
    }

    .navbar-website .website-nav-menu>li>a {
        padding: 12px 20px;
        font-size: 15px;
        color: #333 !important;
    }

    .navbar-website .website-dropdown-menu a {
        padding: 10px 20px 10px 40px;
        font-size: 14px;
        color: #555 !important;
        background: #f8f9fa;
    }

    .navbar-website .website-dropdown-menu a:hover {
        padding-left: 45px;
    }

    .website-footer .footer-section h3 {
        font-size: 18px;
        margin-bottom: 15px;
    }

    .website-footer .footer-section p,
    .website-footer .footer-section ul li a {
        font-size: 13px;
    }
}

@media (max-width: 576px) {
    .website-footer .footer-content {
        grid-template-columns: 1fr;
    }

    .website-footer .footer-section {
        margin-bottom: 30px;
    }

    .website-footer .footer-section:last-child {
        margin-bottom: 0;
    }

    .website-footer .footer-bottom {
        font-size: 12px;
    }
}

@media (max-width: 414px) {
    .navbar-website .nav-container {
        padding: 0 10px;
        height: 55px;
    }

    .navbar-website .website-logo {
        left: 10px;
        max-width: 55%;
        z-index: 1005;
    }

    .navbar-website .logo-image {
        height: 30px;
        max-width: 120px;
    }

    .navbar-website .logo-image img {
        max-height: 30px;
        max-width: 100%;
    }

    .navbar-website .brand-name {
        font-size: 14px;
    }

    .navbar-website .mobile-toggle {
        display: flex;
        right: 10px;
        padding: 6px;
        z-index: 1010;
    }

    .navbar-website .mobile-toggle span {
        width: 20px;
        height: 2px;
        display: block;
    }

    .navbar-website .website-nav-menu {
        width: 280px;
        max-width: 90%;
        top: 55px;
        height: calc(100vh - 55px);
        padding: 20px 0;
    }

    .navbar-website .website-nav-menu>li>a {
        padding: 12px 18px;
        color: #333 !important;
    }

    .navbar-website .website-dropdown-menu a {
        padding: 10px 18px 10px 35px;
        color: #555 !important;
        background: #f8f9fa;
    }

    .navbar-website .website-dropdown-menu a:hover {
        padding-left: 40px;
    }

    .website-footer {
        padding: 30px 15px 15px;
    }
}

/* ==================== 页面内容区域 ==================== */
.website-content {
    margin-top: 80px;
    min-height: calc(100vh - 80px);
}

@media (max-width: 992px) {
    .website-content {
        margin-top: 70px;
    }
}

/* ==================== 回到顶部按钮 ==================== */
.scroll-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: #4caf50;
    color: white;
    border-radius: 50%;
    display: none;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s;
    z-index: 999;
    font-size: 20px;
}

.scroll-top:hover {
    background: #2e7d32;
    transform: translateY(-5px);
}

.scroll-top.show {
    display: flex;
}