/* 响应式增强样式 */
@media (max-width: 1200px) {
    .container {
        width: 95%;
        max-width: 1140px;
    }
    
    .product-grid, 
    .news-grid,
    .advantages-grid,
    .team-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 992px) {
    .header {
        padding: 15px 0;
    }
    
    .main-nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background-color: white;
        box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
        z-index: 100;
        padding: 20px 0;
    }
    
    .main-nav.active {
        display: block;
    }
    
    .main-nav ul {
        flex-direction: column;
        align-items: center;
    }
    
    .main-nav li {
        margin: 10px 0;
    }
    
    .mobile-menu-toggle {
        display: flex;
        flex-direction: column;
        justify-content: space-between;
        width: 30px;
        height: 20px;
        cursor: pointer;
    }
    
    .mobile-menu-toggle span {
        display: block;
        width: 100%;
        height: 2px;
        background-color: var(--dark-color);
        transition: all 0.3s ease;
    }
    
    .mobile-menu-toggle.active span:nth-child(1) {
        transform: translateY(9px) rotate(45deg);
    }
    
    .mobile-menu-toggle.active span:nth-child(2) {
        opacity: 0;
    }
    
    .mobile-menu-toggle.active span:nth-child(3) {
        transform: translateY(-9px) rotate(-45deg);
    }
    
    .hero-content {
        width: 100%;
        text-align: center;
    }
    
    .hero-content h1 {
        font-size: 32px;
    }
    
    .hero-content p {
        font-size: 16px;
    }
    
    .hero-image {
        display: none;
    }
    
    .section-title {
        font-size: 28px;
    }
    
    .intro-container,
    .contact-container {
        flex-direction: column;
    }
    
    .intro-content, 
    .intro-image,
    .contact-form,
    .contact-info {
        width: 100%;
    }
    
    .intro-image {
        margin-top: 30px;
    }
    
    .contact-info {
        margin-top: 40px;
    }
    
    .product-detail-header .container {
        flex-direction: column;
    }
    
    .product-detail-content,
    .product-detail-image {
        width: 100%;
    }
    
    .product-detail-image {
        margin-top: 30px;
    }
    
    .news-detail-title {
        font-size: 28px;
    }
}

@media (max-width: 768px) {
    .product-grid, 
    .news-grid,
    .advantages-grid,
    .team-grid,
    .culture-grid,
    .contact-info-grid {
        grid-template-columns: 1fr;
    }
    
    .cta-buttons {
        flex-direction: column;
    }
    
    .cta-buttons .btn {
        width: 100%;
        margin: 10px 0;
    }
    
    .footer-top {
        flex-direction: column;
    }
    
    .footer-logo {
        margin-bottom: 30px;
    }
    
    .footer-nav {
        flex-direction: column;
    }
    
    .footer-nav-group {
        width: 100%;
        margin-bottom: 20px;
    }
    
    .footer-bottom {
        flex-direction: column;
    }
    
    .copyright {
        margin-bottom: 20px;
    }
    
    .hero-section {
        padding: 80px 0 50px;
    }
    
    .section-padding {
        padding: 50px 0;
    }
    
    .subscribe-form {
        flex-direction: column;
    }
    
    .subscribe-form input {
        width: 100%;
        margin-bottom: 10px;
        border-radius: 4px;
    }
    
    .subscribe-form button {
        width: 100%;
        border-radius: 4px;
    }
    
    .timeline-content {
        width: calc(100% - 50px);
        margin-left: 50px !important;
    }
    
    .timeline:before {
        left: 20px;
    }
    
    .timeline-item:nth-child(odd) .timeline-content:before,
    .timeline-item:nth-child(even) .timeline-content:before {
        left: -30px;
    }
}

@media (max-width: 576px) {
    .hero-content h1 {
        font-size: 28px;
    }
    
    .section-title {
        font-size: 24px;
    }
    
    .product-card,
    .news-card,
    .team-card {
        margin-bottom: 20px;
    }
    
    .news-detail-header {
        padding: 80px 0 40px;
    }
    
    .news-detail-title {
        font-size: 24px;
    }
    
    .news-detail-content {
        padding: 40px 0;
    }
    
    .related-news {
        padding: 40px 0;
    }
    
    .about-header {
        padding: 60px 0;
    }
    
    .about-header h1 {
        font-size: 28px;
    }
}

/* 返回顶部按钮 */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-color: var(--primary-color);
    color: white;
    border: none;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 999;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background-color: var(--primary-dark);
    transform: translateY(-5px);
}

/* 表单错误状态 */
.error {
    border-color: #ff3860 !important;
}

/* 图片懒加载占位 */
img[data-src] {
    opacity: 0;
    transition: opacity 0.3s ease;
}

img {
    opacity: 1;
    transition: opacity 0.3s ease;
}

/* 导航栏滚动效果 */
.header.scrolled {
    background-color: white;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.header.hidden {
    transform: translateY(-100%);
}

/* 移动端菜单优化 */
@media (max-width: 992px) {
    .main-nav ul {
        padding: 0;
    }
    
    .main-nav li {
        width: 100%;
        text-align: center;
    }
    
    .main-nav a {
        display: block;
        padding: 15px 0;
    }
    
    .main-nav a:hover,
    .main-nav a.active {
        background-color: var(--light-color);
    }
}

/* 触摸设备交互优化 */
@media (hover: none) {
    .product-card:hover,
    .news-card:hover,
    .team-card:hover,
    .advantage-card:hover {
        transform: none;
    }
    
    .read-more:hover:after {
        width: 0;
    }
    
    .news-tabs a:hover:after {
        width: 0;
    }
}

/* 打印样式优化 */
@media print {
    .header,
    .footer,
    .subscribe-section,
    .back-to-top,
    .share-buttons {
        display: none !important;
    }
    
    body {
        font-size: 12pt;
        line-height: 1.5;
        color: #000;
        background: #fff;
    }
    
    a {
        text-decoration: none;
        color: #000;
    }
    
    .container {
        width: 100%;
        max-width: none;
    }
    
    .news-detail-content,
    .product-detail-content {
        padding: 0;
    }
    
    h1, h2, h3, h4, h5, h6 {
        page-break-after: avoid;
        page-break-inside: avoid;
    }
    
    img {
        max-width: 100% !important;
        page-break-inside: avoid;
    }
    
    p, blockquote, ul, ol, dl, table {
        page-break-inside: avoid;
    }
}
