/* 全局样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    margin: 0;
    padding: 0;
    min-height: 100vh;
    position: relative;
    overflow-x: hidden;
}

/* 添加一个微妙的背景动画 */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 20% 80%, rgba(52, 152, 219, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(231, 76, 60, 0.1) 0%, transparent 50%);
    z-index: -1;
    animation: bgPulse 10s ease-in-out infinite alternate;
}

@keyframes bgPulse {
    0% { opacity: 0.5; }
    100% { opacity: 0.8; }
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 3D导航效果 */
.navbar {
    position: fixed;
    top: 10px;
    left: 10px;
    right: 10px;
    width: auto;
    z-index: 1000;
    transition: all 0.3s ease;
    background: transparent;
    border-radius: 15px;
}

.navbar:hover {
    background: rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(15px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px;
}

.logo {
    display: flex;
    align-items: center;
}

.logo-link {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: white;
}

.logo-image {
    width: 100px;
    height: 100px;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.logo-image:hover {
    transform: scale(1.1);
}

/* 3D导航容器 */
.nav-3d {
    perspective: 1000px;
    display: flex;
    gap: 25px;
    list-style: none;
    margin: 0;
    padding: 0;
}

/* 导航项 */
.nav-item {
    list-style: none;
}

/* 基础链接样式 */
.nav-item a {
    display: inline-block;
    padding: 11px 20px;
    background: linear-gradient(145deg, var(--color-primary), var(--color-secondary));
    color: #fff;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 16px;
    letter-spacing: 0.5px;
    transform: translateZ(25px);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    
    /* 多重阴影增强3D感 */
    box-shadow: 
        0 5px 15px rgba(0, 0, 0, 0.3), 
        0 10px 25px rgba(0, 0, 0, 0.1), 
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    
    border: 1px solid rgba(255, 255, 255, 0.05);
    position: relative;
    overflow: hidden;
    white-space: nowrap;
    min-width: auto;
    width: 120px;
    text-align: center;
    
    /* 随机颜色变量 */
    --color-primary: #2d4059;
    --color-secondary: #1e2a3a;
    --hover-primary: #3498db;
    --hover-secondary: #2980b9;
    --glow-color: rgba(52, 152, 219, 0.4);
}

/* 鼠标悬停时的3D效果 */
.nav-item:hover a {
    transform: translateZ(45px) scale(1.05);
    background: linear-gradient(145deg, var(--hover-primary), var(--hover-secondary));
    
    /* 更强烈的阴影增强弹出效果 */
    box-shadow: 
        0 15px 35px rgba(0, 0, 0, 0.5), 
        0 0 0 1px rgba(255, 255, 255, 0.1), 
        0 0 40px var(--glow-color);
    
    color: #ffffff;
}

/* 添加流光动画效果 */
.nav-item a::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(
        45deg,
        transparent 30%,
        rgba(255, 255, 255, 0.1) 50%,
        transparent 70%
    );
    transform: rotate(45deg);
    transition: transform 0.6s ease;
    pointer-events: none;
}

.nav-item:hover a::before {
    transform: rotate(45deg) translate(50%, 50%);
}

/* 添加聚焦状态（键盘导航） */
.nav-item a:focus {
    outline: none;
    transform: translateZ(40px);
    background: linear-gradient(145deg, #2ecc71, #27ae60);
    box-shadow: 
        0 10px 25px rgba(0, 0, 0, 0.4), 
        0 0 0 2px rgba(46, 204, 113, 0.5);
}

/* 添加激活状态 */
.nav-item a.active {
    transform: translateZ(35px);
    background: linear-gradient(145deg, #e74c3c, #c0392b);
    box-shadow: 
        0 10px 25px rgba(0, 0, 0, 0.4), 
        0 0 0 2px rgba(231, 76, 60, 0.5);
}

/* 添加发光文本效果 */
.nav-item a span {
    position: relative;
    z-index: 1;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

/* 响应式调整 */
@media (max-width: 768px) {
    .nav-3d {
        flex-direction: column;
        gap: 15px;
    }
}

/* 导航栏按钮随机颜色 - 使用JavaScript实现 */
/* 移除固定颜色分配，由JavaScript动态生成 */

/* 添加入场动画 */
.nav-item {
    animation: floatIn 0.6s ease-out forwards;
    opacity: 0;
}

@keyframes floatIn {
    0% {
        opacity: 0;
        transform: translateY(20px) rotateX(15deg);
    }
    100% {
        opacity: 1;
        transform: translateY(0) rotateX(0);
    }
}

/* 每个按钮不同的延迟 */
.nav-item:nth-child(1) { animation-delay: 0.1s; }
.nav-item:nth-child(2) { animation-delay: 0.2s; }
.nav-item:nth-child(3) { animation-delay: 0.3s; }
.nav-item:nth-child(4) { animation-delay: 0.4s; }
.nav-item:nth-child(5) { animation-delay: 0.5s; }
.nav-item:nth-child(6) { animation-delay: 0.6s; }
.nav-item:nth-child(7) { animation-delay: 0.7s; }

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background-color: #34495e;
    margin: 3px 0;
    transition: 0.3s;
}

/* 英雄区域 */
.hero {
    background: linear-gradient(135deg, #27ae60 0%, #27ae60 100%);
    color: #fff;
    padding: 120px 0 80px;
    text-align: center;
}

.hero-content h2 {
    font-size: 48px;
    margin-bottom: 20px;
    font-weight: 700;
}

.hero-content p {
    font-size: 20px;
    margin-bottom: 40px;
    opacity: 0.9;
}

.hero-buttons {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

/* 按钮样式 */
.btn {
    display: inline-block;
    padding: 12px 30px;
    text-decoration: none;
    border-radius: 50px;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    font-size: 16px;
}

.btn-primary {
    background-color: #fff;
    color: #2ecc71;
}

.btn-primary:hover {
    background-color: #f0f0f0;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.btn-secondary {
    background-color: transparent;
    color: #fff;
    border: 2px solid #fff;
}

.btn-secondary:hover {
    background-color: #fff;
    color: #2ecc71;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.btn-link {
    color: #2ecc71;
    padding: 8px 0;
    font-size: 14px;
}

.btn-link:hover {
    color: #27ae60;
    padding-left: 10px;
}

/* 标题样式 */
.section-title {
    text-align: center;
    font-size: 36px;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 50px;
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: linear-gradient(135deg, #2ecc71 0%, #f39c12 100%);
    border-radius: 2px;
}

/* 核心优势 */
.advantages {
    padding: 80px 0;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

.advantages-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.advantage-item {
    text-align: center;
    padding: 30px;
    background-color: #fff;
    border-radius: 10px;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.advantage-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
}

.advantage-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 20px;
    background: linear-gradient(135deg, #2ecc71 0%, #f39c12 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 28px;
}

.advantage-item h4 {
    font-size: 20px;
    margin-bottom: 15px;
    color: #2c3e50;
}

.advantage-item p {
    color: #7f8c8d;
    line-height: 1.6;
}

/* 产品预览 */
.products-preview {
    padding: 80px 0;
    background: linear-gradient(135deg, #fff 0%, #f8f9fa 100%);
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 15px;
}

.product-item {
    background-color: #fff;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.product-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
}

.product-image {
    background: linear-gradient(135deg, #2ecc71 0%, #27ae60 100%);
    padding: 25px;
    text-align: center;
    color: #fff;
}

.product-item h4 {
    font-size: 18px;
    margin: 12px 0 8px;
    text-align: center;
    color: #2c3e50;
}

.product-item p {
    color: #7f8c8d;
    padding: 0 15px 10px;
    text-align: center;
    line-height: 1.5;
    font-size: 13px;
}

.product-item .btn-link {
    display: block;
    text-align: center;
    margin: 0 15px 15px;
    font-size: 13px;
}

/* 产品服务预览 */
.services-preview {
    padding: 80px 0;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.service-item {
    background-color: #fff;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.service-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
}

.service-image {
    background: linear-gradient(135deg, #2ecc71 0%, #27ae60 100%);
    padding: 40px;
    text-align: center;
    color: #fff;
}

.service-item h4 {
    font-size: 22px;
    margin: 20px 0 15px;
    text-align: center;
    color: #2c3e50;
}

.service-item p {
    color: #7f8c8d;
    padding: 0 30px 20px;
    text-align: center;
    line-height: 1.6;
}

.service-item .btn-link {
    display: block;
    text-align: center;
    margin: 0 30px 30px;
}

/* 企业简介 */
.about-preview {
    padding: 80px 0;
    background: linear-gradient(135deg, #fff 0%, #f8f9fa 100%);
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}

/* 不影响about.php页面的float布局 */
.about-intro .about-content {
    display: block;
}

.about-text h3 {
    text-align: left;
    margin-bottom: 20px;
}

.about-text h3::after {
    left: 0;
    transform: none;
}

.about-text p {
    color: #7f8c8d;
    margin-bottom: 20px;
    line-height: 1.8;
}

.about-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.stat-item {
    text-align: center;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

/* 随机背景样式 */
.stat-item.random-bg-1 {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.stat-item.random-bg-2 {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    color: white;
}

.stat-item.random-bg-3 {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    color: white;
}

.stat-item.random-bg-4 {
    background: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%);
    color: white;
}

.stat-item.random-bg-5 {
    background: linear-gradient(135deg, #fa709a 0%, #fee140 100%);
    color: white;
}

.stat-item.random-bg-6 {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    color: #333;
}

/* 随机背景样式下的文字颜色 */
.stat-item.random-bg-1 .stat-label,
.stat-item.random-bg-2 .stat-label,
.stat-item.random-bg-3 .stat-label,
.stat-item.random-bg-4 .stat-label,
.stat-item.random-bg-5 .stat-label {
    color: white;
}

.stat-number {
    font-size: 48px;
    font-weight: 700;
    color: #2ecc71;
    margin-bottom: 10px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.stat-label {
    font-size: 16px;
    color: #7f8c8d;
    font-weight: 500;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

/* 随机背景下的统计数字和标签颜色 */
.stat-item.random-bg-1 .stat-number,
.stat-item.random-bg-2 .stat-number,
.stat-item.random-bg-3 .stat-number,
.stat-item.random-bg-4 .stat-number,
.stat-item.random-bg-5 .stat-number {
    color: white;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

/* 添加悬停效果 */
.stat-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.2);
}

/* 新闻动态 */
.news-preview {
    padding: 80px 0;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.news-item {
    background-color: #fff;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.news-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
}

.news-date {
    color: #2ecc71;
    font-weight: 600;
    margin-bottom: 15px;
    font-size: 14px;
}

.news-item h4 {
    font-size: 20px;
    margin-bottom: 15px;
    color: #2c3e50;
}

.news-item p {
    color: #7f8c8d;
    margin-bottom: 20px;
    line-height: 1.6;
}

/* 联系我们 */
.contact-preview {
    padding: 80px 0;
    background: linear-gradient(135deg, #fff 0%, #f8f9fa 100%);
}

.contact-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    text-align: center;
}

.contact-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    padding: 30px;
    background-color: #fff;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.contact-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
}

.contact-item i {
    font-size: 32px;
    color: #2ecc71;
}

.contact-item p {
    color: #7f8c8d;
    font-size: 16px;
    margin: 0;
}

/* 页脚 */
.footer {
    background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
    color: #fff;
    padding: 60px 0 30px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-section h4 {
    font-size: 18px;
    margin-bottom: 20px;
    color: #2ecc71;
}

.footer-section p {
    color: #bdc3c7;
    line-height: 1.6;
    margin-bottom: 20px;
}

.social-links {
    display: flex;
    gap: 15px;
}

.social-links a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%);
    color: #fff;
    border-radius: 50%;
    transition: all 0.3s ease;
    text-decoration: none;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.social-links a:hover {
    background: linear-gradient(135deg, #2ecc71 0%, #27ae60 100%);
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.footer-section ul {
    list-style: none;
}

/* 快速链接分两排显示 */
.footer-section:nth-child(2) ul {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
}

/* 微信公众号部分居中对齐 */
.footer-section:nth-child(4) {
    text-align: center;
}

.footer-section:nth-child(4) h4,
.footer-section:nth-child(4) p {
    text-align: center;
}

.footer-section ul li {
    margin-bottom: 0;
}

.footer-section ul li a {
    color: #bdc3c7;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-section ul li a:hover {
    color: #2ecc71;
    padding-left: 5px;
}

.footer-section ul li i {
    margin-right: 10px;
    color: #2ecc71;
}

.footer-bottom {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid #34495e;
    color: #95a5a6;
    font-size: 14px;
}

/* 后台入口链接 */
.admin-link {
    display: block;
    text-align: center;
    margin-top: 20px;
    color: #2ecc71;
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s ease;
}

.admin-link:hover {
    color: #27ae60;
    text-decoration: underline;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .navbar {
        top: 5px;
        left: 5px;
        right: 5px;
    }
    
    .hamburger {
        display: flex;
    }
    
    .nav-3d {
        position: fixed;
        top: 80px;
        left: 5px;
        right: 5px;
        background: rgba(26, 26, 46, 0.95);
        backdrop-filter: blur(10px);
        border-radius: 20px;
        padding: 30px;
        box-shadow: 
            0 20px 40px rgba(0, 0, 0, 0.5),
            inset 0 1px 0 rgba(255, 255, 255, 0.1);
        border: 1px solid rgba(255, 255, 255, 0.05);
        transform-style: preserve-3d;
        z-index: 999;
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s ease;
        flex-direction: column;
        gap: 15px;
    }
    
    .nav-3d.active {
        opacity: 1;
        visibility: visible;
    }
    
    .nav-item {
        margin: 0;
    }
    
    .hero-content h2 {
        font-size: 36px;
    }
    
    .hero-content p {
        font-size: 18px;
    }
    
    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .section-title {
        font-size: 28px;
    }
    
    .about-content {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .about-text h3 {
        text-align: center;
    }
    
    .about-text h3::after {
        left: 50%;
        transform: translateX(-50%);
    }
    
    .about-stats {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .stat-number {
        font-size: 36px;
    }
}

@media (max-width: 480px) {
    .hero-content h2 {
        font-size: 28px;
    }
    
    .hero-content p {
        font-size: 16px;
    }
    
    .section-title {
        font-size: 24px;
    }
    
    .about-stats {
        grid-template-columns: 1fr;
    }
    
    .stat-item {
        padding: 20px;
    }
    
    .stat-number {
        font-size: 32px;
    }
    
    .services-grid,
    .products-grid,
    .news-grid,
    .advantages-grid,
    .contact-info {
        grid-template-columns: 1fr;
    }
}

/* 动画效果 */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.advantage-item,
.service-item,
.product-item,
.news-item,
.stat-item,
.contact-item {
    animation: fadeInUp 0.6s ease-out;
}

/* 滚动条样式 */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #2ecc71 0%, #f39c12 100%);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, #27ae60 0%, #e67e22 100%);
}