/* 基础样式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Helvetica Neue', Arial, sans-serif;
}

:root {
    --primary-color: #1a365d;
    --secondary-color: #2b6cb0;
    --accent-color: #ed8936;
    --light-color: #f7fafc;
    --dark-color: #2d3748;
    --gray-color: #718096;
    --light-gray: #e2e8f0;
    --border-color: #cbd5e0;
}

body {
    color: var(--dark-color);
    background-color: var(--light-color);
    line-height: 1.6;
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

/* 按钮样式 */
.btn {
    display: inline-block;
    padding: 10px 20px;
    font-weight: 500;
    text-align: center;
    text-decoration: none;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.primary-btn {
    background-color: var(--primary-color);
    color: white;
}

.primary-btn:hover {
    background-color: #1a202c;
}

.secondary-btn {
    background-color: transparent;
    color: var(--primary-color);
    border: 1px solid var(--primary-color);
}

.secondary-btn:hover {
    background-color: var(--primary-color);
    color: white;
}

.product-btn {
    width: 100%;
    background-color: var(--secondary-color);
    color: white;
    margin-top: 15px;
}

.product-btn:hover {
    background-color: #1a4a8f;
}

/* 标题样式 */
.section-title {
    text-align: center;
    margin-bottom: 40px;
}

.section-title h2 {
    font-size: 28px;
    color: var(--primary-color);
    margin-bottom: 10px;
    position: relative;
    display: inline-block;
}

.section-title h2::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background-color: var(--accent-color);
}

.section-title p {
    color: var(--gray-color);
    font-size: 16px;
}

.left-align {
    text-align: left;
}

.left-align h2::after {
    left: 0;
    transform: none;
}

/* 头部样式 */
.header {
    background-color: white;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid var(--light-gray);
}

.contact-info span {
    margin-right: 20px;
    color: var(--gray-color);
    font-size: 14px;
}

.contact-info i {
    margin-right: 5px;
    color: var(--secondary-color);
}

.social-links a {
    color: var(--gray-color);
    margin-left: 15px;
    font-size: 16px;
    transition: color 0.3s ease;
}

.social-links a:hover {
    color: var(--primary-color);
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
}

.logo img {
    max-height: 50px;
}

.nav-links {
    display: flex;
    list-style: none;
}

.nav-links li {
    margin-left: 30px;
}

.nav-links a {
    text-decoration: none;
    color: var(--dark-color);
    font-weight: 500;
    transition: color 0.3s ease;
    position: relative;
}

.nav-links a:hover, .nav-links a.active {
    color: var(--primary-color);
}

.nav-links a.active::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: var(--accent-color);
}

.menu-toggle {
    display: none;
    font-size: 24px;
    color: var(--primary-color);
    cursor: pointer;
}

/* 英雄区域样式 */
.hero {
    background-color: var(--primary-color);
    color: white;
    padding: 80px 0;
    text-align: center;
    background-image: linear-gradient(rgba(26, 54, 93, 0.9), rgba(26, 54, 93, 0.9)), url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="100" height="100" viewBox="0 0 100 100"><rect width="100" height="100" fill="none" stroke="rgba(255,255,255,0.1)" stroke-width="1"/></svg>');
    background-size: 100px 100px;
}

.hero-content h1 {
    font-size: 42px;
    margin-bottom: 20px;
    font-weight: 700;
}

.hero-content p {
    font-size: 18px;
    margin-bottom: 30px;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
    color: rgba(255, 255, 255, 0.9);
}

.cta-buttons .btn {
    margin: 0 10px;
}

/* 商品分类样式 */
.categories {
    padding: 60px 0;
    background-color: white;
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
}

.category-item {
    position: relative;
    overflow: hidden;
    border-radius: 4px;
    height: 200px;
}

.category-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.category-item:hover img {
    transform: scale(1.05);
}

.category-item h3 {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 15px;
    background-color: rgba(26, 54, 93, 0.8);
    color: white;
    margin: 0;
    font-size: 18px;
}

/* 商品展示样式 */
.products {
    padding: 60px 0;
    background-color: var(--light-color);
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 30px;
    margin-bottom: 40px;
}

.product-item {
    background-color: white;
    border-radius: 4px;
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.product-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.product-image {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.product-item:hover .product-image img {
    transform: scale(1.05);
}

.product-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background-color: var(--accent-color);
    color: white;
    padding: 5px 10px;
    font-size: 12px;
    border-radius: 4px;
}

.product-details {
    padding: 20px;
}

.product-details h3 {
    font-size: 18px;
    margin-bottom: 10px;
    color: var(--primary-color);
}

.product-details p {
    color: var(--gray-color);
    font-size: 14px;
    margin-bottom: 15px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-price {
    font-size: 20px;
    font-weight: 700;
    color: var(--secondary-color);
}

.view-more {
    text-align: center;
}

/* 关于我们样式 */
.about {
    padding: 60px 0;
    background-color: white;
}

.about-content {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 40px;
}

.about-image {
    flex: 1;
    min-width: 300px;
}

.about-image img {
    width: 100%;
    border-radius: 4px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.about-text {
    flex: 1;
    min-width: 300px;
}

.about-text p {
    margin-bottom: 20px;
    color: var(--gray-color);
}

.about-features {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-top: 20px;
}

.feature-item {
    display: flex;
    align-items: center;
    color: var(--primary-color);
}

.feature-item i {
    margin-right: 5px;
    color: var(--accent-color);
}

/* 新闻资讯样式 */
.news {
    padding: 60px 0;
    background-color: var(--light-color);
}

.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
}

.news-item {
    background-color: white;
    border-radius: 4px;
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.news-item:hover {
    transform: translateY(-5px);
}

.news-image {
    height: 180px;
    overflow: hidden;
}

.news-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.news-item:hover .news-image img {
    transform: scale(1.05);
}

.news-content {
    padding: 20px;
}

.news-date {
    font-size: 12px;
    color: var(--gray-color);
    margin-bottom: 10px;
    display: block;
}

.news-content h3 {
    font-size: 18px;
    margin-bottom: 10px;
    color: var(--primary-color);
}

.news-content p {
    color: var(--gray-color);
    font-size: 14px;
    margin-bottom: 15px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.read-more {
    color: var(--secondary-color);
    text-decoration: none;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    transition: color 0.3s ease;
}

.read-more:hover {
    color: var(--primary-color);
}

.read-more i {
    margin-left: 5px;
    font-size: 14px;
}

/* 联系我们样式 */
.contact {
    padding: 60px 0;
    background-color: white;
}

.contact-content {
    display: flex;
    flex-wrap: wrap;
    gap: 40px;
}

.contact-form {
    flex: 1;
    min-width: 300px;
    background-color: var(--light-color);
    padding: 30px;
    border-radius: 4px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.contact-form h3 {
    font-size: 20px;
    margin-bottom: 20px;
    color: var(--primary-color);
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: var(--dark-color);
    font-weight: 500;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 14px;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--secondary-color);
}

.contact-info {
    flex: 1;
    min-width: 300px;
}

.contact-info h3 {
    font-size: 20px;
    margin-bottom: 20px;
    color: var(--primary-color);
}

.info-item {
    display: flex;
    margin-bottom: 20px;
}

.info-item i {
    font-size: 20px;
    color: var(--secondary-color);
    margin-right: 15px;
    flex-shrink: 0;
    margin-top: 5px;
}

.info-text h4 {
    font-size: 16px;
    margin-bottom: 5px;
    color: var(--dark-color);
}

.info-text p {
    color: var(--gray-color);
    font-size: 14px;
}

/* 页脚样式 */
.footer {
    background-color: var(--primary-color);
    color: white;
    padding: 60px 0 20px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    margin-bottom: 40px;
}

.footer-logo img {
    max-height: 50px;
    margin-bottom: 15px;
}

.footer-logo p {
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
}

.footer-links h3 {
    font-size: 18px;
    margin-bottom: 20px;
    position: relative;
    padding-bottom: 10px;
}

.footer-links h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 2px;
    background-color: var(--accent-color);
}

.footer-links ul {
    list-style: none;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: white;
}

.footer-contact ul {
    list-style: none;
}

.footer-contact li {
    margin-bottom: 10px;
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
    display: flex;
    align-items: flex-start;
}

.footer-contact i {
    margin-right: 10px;
    margin-top: 5px;
    color: var(--accent-color);
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.copyright p {
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
}

.payment-methods img {
    max-height: 30px;
}

/* 响应式设计 */
@media (max-width: 992px) {
    .hero-content h1 {
        font-size: 36px;
    }
}

@media (max-width: 768px) {
    .header-top {
        flex-direction: column;
        text-align: center;
        padding: 10px 0;
    }

    .contact-info {
        margin-bottom: 10px;
    }

    .contact-info span {
        margin: 0 10px;
    }

    .nav-links {
        position: fixed;
        top: 120px;
        left: -100%;
        width: 100%;
        height: calc(100vh - 120px);
        background-color: white;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        transition: left 0.3s ease;
        box-shadow: 0 5px 10px rgba(0, 0, 0, 0.1);
    }

    .nav-links.active {
        left: 0;
    }

    .nav-links li {
        margin: 15px 0;
    }

    .menu-toggle {
        display: block;
    }

    .hero-content h1 {
        font-size: 30px;
    }

    .hero-content p {
        font-size: 16px;
    }

    .cta-buttons .btn {
        margin: 10px 0;
        display: block;
        width: 80%;
        margin-left: auto;
        margin-right: auto;
    }

    .footer-bottom {
        flex-direction: column;
        text-align: center;
    }

    .payment-methods {
        margin-top: 15px;
    }
}

@media (max-width: 576px) {
    .hero {
        padding: 60px 0;
    }

    .hero-content h1 {
        font-size: 26px;
    }

    .section-title h2 {
        font-size: 24px;
    }

    .categories, .products, .about, .news, .contact {
        padding: 40px 0;
    }
}