/* optimized.css - 非关键CSS，异步加载 */

/* 响应式设计 */
@media (max-width: 1024px) {
    /* 平板端 */
    footer .container {
        padding: 0 1.5rem !important;
    }
    
    footer .container > div:first-child > div:nth-child(2) {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 1.5rem !important;
    }
    
    footer .container > div:nth-child(3) {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 3rem !important;
    }
    
    footer .container > div:first-child > div:last-child > div {
        flex-direction: column !important;
        gap: 1rem !important;
    }
    
    footer .container > div:first-child > div:last-child > div a {
        width: 100% !important;
        justify-content: center !important;
    }
}

@media (max-width: 768px) {
    /* 手机端 */
    footer {
        padding: 6rem 0 2rem !important;
    }
    
    footer .container > div:first-child > div:nth-child(2) {
        grid-template-columns: 1fr !important;
        gap: 1.5rem !important;
    }
    
    footer .container > div:nth-child(3) {
        grid-template-columns: 1fr !important;
        gap: 3rem !important;
    }
    
    footer .container > div:first-child > div:first-child h2 {
        font-size: 2.5rem !important;
    }
    
    footer .container > div:first-child > div:first-child p {
        font-size: 1.125rem !important;
        padding: 0 1rem !important;
    }
    
    /* 移动端导航 */
    .nav-links {
        display: none !important;
        position: fixed;
        top: 64px;
        left: 0;
        width: 100%;
        background: white;
        flex-direction: column;
        padding: 1rem 0;
        box-shadow: 0 4px 12px rgba(0,0,0,0.1);
        z-index: 999;
        max-height: calc(100vh - 64px);
        overflow-y: auto;
        transition: all 0.3s ease;
    }
    
    .nav-links.active {
        display: flex !important;
        animation: slideDown 0.3s ease;
    }
    
    @keyframes slideDown {
        from {
            opacity: 0;
            transform: translateY(-10px);
        }
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }
    
    .nav-links li {
        width: 100%;
        text-align: center;
    }
    
    .nav-links a {
        display: block;
        padding: 1rem !important;
        border-bottom: 1px solid #f1f5f9;
        color: #475569 !important;
        font-weight: 500 !important;
        font-size: 1.125rem !important;
        transition: all 0.2s ease;
    }
    
    .nav-links a:hover,
    .nav-links a:focus {
        background-color: #f8fafc;
        color: #2563eb !important;
    }
    
    .menu-toggle {
        display: block !important;
        background: none;
        border: none;
        cursor: pointer;
        padding: 8px;
        margin-left: 1rem;
        transition: transform 0.2s ease;
    }
    
    .menu-toggle:hover {
        transform: scale(1.1);
    }
    
    .menu-toggle:focus {
        outline: 2px solid #2563eb;
        outline-offset: 2px;
        border-radius: 4px;
    }
    
    .menu-toggle svg {
        display: block;
        transition: transform 0.3s ease;
    }
    
    .cta-button {
        display: none !important;
    }
    
    /* 移动端内容调整 */
    .hero-title span:first-child {
        font-size: 2.25rem !important;
        margin-bottom: 0.5rem !important;
    }
    
    .hero-title span:last-child {
        font-size: 2.75rem !important;
        margin-top: 0.5rem !important;
    }
    
    .hero-subtitle {
        font-size: 1.125rem !important;
        padding: 0 1rem;
    }
    
    .hero-cta {
        flex-direction: column !important;
        gap: 1rem !important;
    }
    
    .hero-cta a {
        width: 100% !important;
        justify-content: center !important;
    }
    
    /* 卡片网格 */
    .card-grid {
        grid-template-columns: 1fr !important;
        gap: 2rem !important;
    }
    
    /* 服务网格 */
    .service-grid {
        grid-template-columns: 1fr !important;
        gap: 2rem !important;
    }
    
    /* 案例网格 */
    .case-grid {
        grid-template-columns: 1fr !important;
        gap: 2rem !important;
    }
    
    /* 页脚调整 */
    .footer-content {
        grid-template-columns: 1fr !important;
        gap: 3rem !important;
    }
    
    .footer-links {
        grid-template-columns: 1fr !important;
        gap: 2rem !important;
    }
    
    .footer-actions {
        flex-direction: column !important;
        gap: 1rem !important;
    }
    
    .footer-actions a {
        width: 100% !important;
        justify-content: center !important;
    }
}

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

@keyframes slideInLeft {
    from { opacity: 0; transform: translateX(-30px); }
    to { opacity: 1; transform: translateX(0); }
}

@keyframes slideInRight {
    from { opacity: 0; transform: translateX(30px); }
    to { opacity: 1; transform: translateX(0); }
}

@keyframes scaleIn {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

/* 组件样式 */
.card {
    background: white;
    border-radius: 12px;
    padding: 2rem;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 30px rgba(0,0,0,0.12);
}

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.875rem 2rem;
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    color: white;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
}

.button:hover {
    background: linear-gradient(135deg, #1d4ed8, #1e40af);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(37, 99, 235, 0.3);
}

.button-secondary {
    background: white;
    color: #2563eb;
    border: 2px solid #2563eb;
}

.button-secondary:hover {
    background: #f8fafc;
    color: #1d4ed8;
    border-color: #1d4ed8;
}

/* 工具类 */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.mt-1 { margin-top: 0.25rem; }
.mt-2 { margin-top: 0.5rem; }
.mt-4 { margin-top: 1rem; }
.mt-8 { margin-top: 2rem; }
.mt-12 { margin-top: 3rem; }
.mt-16 { margin-top: 4rem; }

.mb-1 { margin-bottom: 0.25rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-4 { margin-bottom: 1rem; }
.mb-8 { margin-bottom: 2rem; }
.mb-12 { margin-bottom: 3rem; }
.mb-16 { margin-bottom: 4rem; }

.p-4 { padding: 1rem; }
.p-8 { padding: 2rem; }
.p-12 { padding: 3rem; }

/* 打印样式 */
@media print {
    .no-print { display: none !important; }
    body { color: black !important; background: white !important; }
    a { color: black !important; text-decoration: underline !important; }
}
