* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { font-family: 'Microsoft YaHei', 'PingFang SC', sans-serif; line-height: 1.6; color: #333; background: #fff; }

/* 骨架屏动画 */
@keyframes skeleton-loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s infinite;
    min-height: 1.5rem;
    display: inline-block;
}

/* 渐入动画 */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.dynamic-content {
    opacity: 0;
    animation: fadeInUp 0.4s ease-out forwards;
}

/* 导航栏 */
header {
    background: #fff;
    height: 100px;
    padding: 0 20px;
    border-bottom: 2px solid #1e73be;
    position: sticky;
    top: 0;
    z-index: 100;
}
.logo {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 2rem;
    font-weight: bold;
    color: #1e73be;
    text-decoration: none;
    animation: slideInLeft 0.3s ease-out;
}
.logo img { height: 45px; }
nav { max-width: 1200px; margin: 0 auto; display: flex; justify-content: space-between; align-items: center; height: 100%; }
.nav-links { display: flex; list-style: none; }
.nav-links li { padding: 0; }
.nav-links a {
    display: inline-block;
    padding: 10px 10px;
    text-decoration: none;
    color: #1e73be;
    font-size: 0.95rem;
    font-weight: 500;
    transition: all 0.2s;
    line-height: 1;
}
.nav-links a:hover {
    background: #1e73be;
    color: #fff;
}
.nav-links a.active {
    background: #1e73be;
    color: #fff;
}

.menu-btn { display: none; }

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideInLeft {
    from { 
        opacity: 0; 
        transform: translateX(-300px);
    }
    to { 
        opacity: 1; 
        transform: translateX(0);
    }
}

@keyframes slideInUp {
    from { 
        opacity: 0; 
        transform: translateY(60px);
    }
    to { 
        opacity: 1; 
        transform: translateY(0);
    }
}

#home {
    background: url('../img/banner.webp') no-repeat center;
    background-size: cover;
    color: white;
    height: 700px;
    position: relative;
    animation: fadeIn 0.3s ease-out;
}
#home::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(30, 115, 190, 0.65) 0%, rgba(52, 152, 219, 0.55) 50%, rgba(30, 115, 190, 0.65) 100%);
}
#home .home-content {
    position: absolute;
    z-index: 1;
    top: 500px;
    left: calc((100% - 1200px) / 2 + 60px);
}
#home h2 { 
    font-size: 3.5rem; 
    margin-bottom: -15px;
    font-weight: bold;
    animation: slideInUp 0.3s ease-out 0.1s both;
}
#home p { 
    font-size: 1.3rem; 
    opacity: 0.95;
    animation: slideInUp 0.3s ease-out 0.15s both;
}

section { 
    padding: 80px 20px; 
    min-height: 400px; 
    border-top: 1px solid #e9ecef;
    border-bottom: 1px solid #e9ecef;
}
.container { max-width: 1200px; margin: 0 auto; }
.section-title { 
    text-align: center; 
    margin-bottom: 40px; 
    padding-bottom: 20px;
    border-bottom: 2px solid #1e73be;
    position: relative;
}
.section-title::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 2px;
    background: #3498db;
}
.section-title h2 { 
    font-size: 1.6rem; 
    color: #1e73be; 
    margin-bottom: 10px;
    font-weight: 600;
    letter-spacing: 4px;
}
.section-title p { 
    color: #666; 
    font-size: 0.95rem;
    letter-spacing: 3px;
}

#about { 
    background: #f0f2f5; 
}
#about .about-content { 
    background: #fff; 
    padding: 30px; 
    border-radius: 8px; 
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    gap: 30px;
}
#about .about-image { 
    width: 35%; 
    min-width: 280px;
}
#about .about-image img { 
    width: 100%; 
    height: auto; 
    border-radius: 6px;
}
#about .about-text { 
    flex: 1; 
}
#about .about-text p { 
    color: #444; 
    line-height: 1.9; 
    font-size: 0.95rem;
    text-indent: 2em;
}

/* 企业资质 */
#qualification { 
    background: #fff; 
}
.products-list { 
    display: grid; 
    grid-template-columns: repeat(3, 1fr); 
    gap: 30px; 
    max-width: 1200px;
    margin: 0 auto;
}
.product-item { 
    text-align: center; 
}
.product-item .img-box { 
    margin-bottom: 12px; 
}
.product-item .img-box img { 
    max-width: 100%; 
    max-height: 300px; 
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    cursor: pointer;
}
.product-item h3 { color: #333; font-size: 0.95rem; font-weight: 500; }

/* 产品展示 */
#products { 
    background: #f0f2f5; 
}

/* 联系我们 */
#contact { 
    background: #fff; 
}
.contact-grid { 
    display: grid; 
    grid-template-columns: repeat(3, 1fr); 
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
}
.contact-item { 
    background: #fff; 
    padding: 25px; 
    border-radius: 8px;
    border: 1px solid #eee;
}
.contact-item h3 { 
    color: #1e73be; 
    margin-bottom: 15px; 
    font-size: 1rem;
    padding-bottom: 10px;
    border-bottom: 1px dashed #ddd;
}
.contact-item ul { list-style: none; }
.contact-item li { 
    margin-bottom: 10px; 
    color: #555; 
    font-size: 0.9rem;
    line-height: 1.6;
}
.contact-item a { color: #1e73be; text-decoration: none; }
.contact-item a:hover { text-decoration: underline; }
.contact-item p { color: #555; font-size: 0.9rem; line-height: 1.7; }
.contact-item .welcome-link {
    display: inline-block;
    margin-top: 12px;
    padding: 8px 16px;
    background: #1e73be;
    color: #fff;
    text-decoration: none;
    border-radius: 4px;
    font-size: 0.9rem;
    transition: background 0.3s;
}
.contact-item .welcome-link:hover { background: #3498db; }

/* 联系我们表单 */
.contact-form-container { 
    display: flex; 
    justify-content: center; 
}
.contact-form { 
    width: 100%; 
    max-width: 800px; 
    background: #fff; 
    padding: 40px; 
    border-radius: 8px; 
    box-shadow: 0 2px 15px rgba(0,0,0,0.1); 
}
.form-group { 
    margin-bottom: 25px; 
}
.form-group label { 
    display: block; 
    margin-bottom: 8px; 
    font-weight: bold; 
    color: #333; 
}
.form-group input,
.form-group textarea { 
    width: 100%; 
    padding: 12px; 
    border: 1px solid #ddd; 
    border-radius: 4px; 
    font-size: 1rem; 
}
.form-group textarea { 
    resize: vertical; 
}
.submit-btn { 
    background: #1e73be; 
    color: #fff; 
    padding: 12px 30px; 
    border: none; 
    border-radius: 4px; 
    font-size: 1rem; 
    cursor: pointer; 
}
.submit-btn:hover { 
    background: #155a8a; 
}
.form-submit-container {
    text-align: center;
}
.error-msg {
    color: #dc3545;
    font-size: 0.85rem;
    margin-top: 5px;
    display: none;
}

/* 图片预览模态框 */
.image-modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    justify-content: center;
    align-items: center;
    overflow: hidden;
}
.image-modal.active {
    display: flex;
}
.modal-content {
    position: relative;
    width: 90vw;
    height: 90vh;
    max-width: 1400px;
    background: #fff;
    padding: 10px;
    border-radius: 8px;
    overflow: hidden;
}
.modal-image-wrapper {
    position: relative;
    width: 100%;
    height: calc(100% - 60px);
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
}
.modal-image-wrapper img {
    display: block;
    cursor: grab;
    transform-origin: center center;
    max-width: 100%;
    max-height: 100%;
}
.modal-image-wrapper img:active {
    cursor: grabbing;
}
.modal-close {
    position: absolute;
    top: -40px;
    right: 0;
    color: #fff;
    font-size: 2rem;
    cursor: pointer;
    user-select: none;
}
.modal-close:hover {
    color: #ccc;
}
.modal-zoom-controls {
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
    background: rgba(0, 0, 0, 0.6);
    padding: 8px 15px;
    border-radius: 20px;
}
.zoom-btn {
    background: rgba(255, 255, 255, 0.9);
    border: none;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
}
.zoom-btn:hover {
    background: #fff;
}
.zoom-level {
    color: #fff;
    font-size: 0.8rem;
    line-height: 30px;
    min-width: 40px;
    text-align: center;
}

/* 成功提示模态框 */
.success-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 9999;
}
.success-modal-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: white;
    padding: 30px 50px;
    border-radius: 8px;
    text-align: center;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}
.success-modal-content h3 {
    color: #28a745;
    margin: 0 0 10px 0;
    font-size: 1.5rem;
}
.success-modal-content p {
    margin: 0 0 20px 0;
    color: #666;
}
.success-modal-content button {
    background-color: #1e73be;
    color: white;
    border: none;
    padding: 10px 30px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1rem;
}

/* 页脚 */
footer { 
    background: #1e73be; 
    padding: 15px 20px; 
    text-align: center; 
}
.footer-container { 
    max-width: 1200px; 
    margin: 0 auto; 
    display: flex; 
    flex-direction: column; 
    align-items: center; 
    justify-content: center; 
    gap: 0; 
    text-align: center; 
}
.footer-top { 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    gap: 20px; 
    flex-wrap: wrap; 
}
.footer-top span { 
    color: #fff; 
    font-size: 0.7rem; 
}
.footer-bottom { 
    display: flex; 
    align-items: center; 
    gap: 30px; 
    flex-wrap: wrap; 
    justify-content: center; 
}
.footer-bottom span { 
    color: #fff; 
    font-size: 0.7rem; 
}
.footer-divider { 
    color: rgba(255,255,255,0.6); 
}

/* 响应式 */
@media (max-width: 768px) {
    .nav-links { 
        display: none;
        position: absolute;
        top: 58px;
        left: 0;
        right: 0;
        background: #fff;
        flex-direction: column;
        border-bottom: 2px solid #1e73be;
        padding: 10px;
    }
    .nav-links.active { display: flex; }
    .nav-links a { padding: 12px 20px; border-bottom: 1px solid #eee; }
    .menu-btn { 
        display: block; 
        background: none; 
        border: none; 
        font-size: 1.5rem; 
        color: #1e73be;
    }
    .products-list { grid-template-columns: 1fr; }
    .contact-form { padding: 25px; }
    .footer-contact { 
        flex-direction: column; 
        gap: 10px; 
        text-align: center; 
    }
    #home h2 { font-size: 1.5rem; }
    #home p { font-size: 1.1rem; }
    #home { padding: 120px 20px; }
}
