/* 全局样式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* 根变量定义 */
:root {
    --primary-color: #d32f2f;
    --primary-dark: #b71c1c;
    --secondary-color: #f57c00;
    --accent-color: #ff5722;
    --light-color: #f5f5f5;
    --dark-color: #333333;
    --white-color: #ffffff;
    --gray-color: #757575;
    --gray-light: #f5f5f5;
    --gray-dark: #424242;
    --transition: all 0.3s ease;
    --shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    --shadow-hover: 0 5px 15px rgba(0, 0, 0, 0.15);
}

/* 基础样式 */
body {
    font-family: 'PingFang SC', 'Microsoft YaHei', sans-serif;
    line-height: 1.6;
    color: var(--dark-color);
    background-color: var(--white-color);
    overflow-x: hidden;
}

/* 容器样式 */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 标题样式 */
h1, h2, h3, h4, h5, h6 {
    margin-bottom: 15px;
    font-weight: 600;
    line-height: 1.2;
    color: var(--dark-color);
}

h1 {
    font-size: 2.8rem;
}

h2 {
    font-size: 2.2rem;
}

h3 {
    font-size: 1.6rem;
}

h4 {
    font-size: 1.3rem;
}

/* 段落样式 */
p {
    margin-bottom: 15px;
    color: var(--gray-color);
}

/* 链接样式 */
a {
    color: var(--primary-color);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--primary-dark);
}

/* 按钮样式 */
.btn {
    display: inline-block;
    padding: 12px 30px;
    margin-right: 10px;
    margin-bottom: 10px;
    font-weight: 500;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 1px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: var(--transition);
}

.btn-primary {
    background-color: var(--primary-color);
    color: var(--white-color);
}

.btn-primary:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-hover);
}

/* 顶部通知栏 */
.top-notice {
    background-color: var(--accent-color);
    color: var(--white-color);
    padding: 10px 0;
    text-align: center;
}

.top-notice p {
    margin: 0;
    color: var(--white-color);
    font-weight: 500;
}

/* 导航栏样式 */
.header {
    position: sticky;
    top: 0;
    left: 0;
    width: 100%;
    background-color: var(--white-color);
    box-shadow: var(--shadow);
    z-index: 1000;
    transition: var(--transition);
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
}

.logo-container {
    display: flex;
    align-items: center;
}

.logo-img {
    width: 40px;
    height: 40px;
    margin-right: 10px;
}

.logo-text {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--primary-color);
}

.nav-list {
    display: flex;
    list-style: none;
}

.nav-item {
    margin-left: 30px;
}

.nav-link {
    position: relative;
    padding: 10px 0;
    font-weight: 500;
    color: var(--dark-color);
}

.nav-link:hover {
    color: var(--primary-color);
}

.nav-link.active {
    color: var(--primary-color);
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: var(--primary-color);
}

.menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 20px;
    cursor: pointer;
}

.menu-toggle span {
    display: block;
    width: 100%;
    height: 2px;
    background-color: var(--dark-color);
    transition: var(--transition);
}

/* 英雄区域样式 */
.hero {
    position: relative;
    height: 500px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background-color: var(--gray-light);
}

.hero-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.hero-bg {
    width: 100%;
    height: 100%;
    object-fit: cover;
    /* 控制图片大小 */
    max-height: 500px;
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    color: var(--white-color);
    background-color: rgba(0, 0, 0, 0.5);
    padding: 40px;
    border-radius: 8px;
}

.hero-title {
    margin-bottom: 20px;
    font-size: 2.8rem;
    color: var(--white-color);
}

.hero-description {
    margin-bottom: 30px;
    font-size: 1.2rem;
    color: var(--white-color);
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* 区域头部样式 */
.section-header {
    text-align: center;
    margin-bottom: 50px;
    padding-top: 20px;
}

.section-title {
    position: relative;
    display: inline-block;
    margin-bottom: 15px;
    padding-bottom: 10px;
    color: var(--dark-color);
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 3px;
    background-color: var(--primary-color);
}

.section-subtitle {
    color: var(--gray-color);
    font-size: 1.1rem;
}

/* 产品介绍区域样式 */
.products {
    padding: 80px 0;
    background-color: var(--white-color);
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 30px;
}

.product-card {
    background-color: var(--white-color);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.product-image {
    width: 100%;
    height: 200px;
    overflow: hidden;
}

.product-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.product-card:hover .product-img {
    transform: scale(1.05);
}

.product-info {
    padding: 20px;
}

.product-title {
    margin-bottom: 10px;
    font-size: 1.4rem;
    color: var(--dark-color);
}

.product-desc {
    margin-bottom: 15px;
    color: var(--gray-color);
    font-size: 0.95rem;
}

.product-price {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--primary-color);
}

.product-price .unit {
    font-size: 0.9rem;
    font-weight: normal;
    color: var(--gray-color);
}

/* 产品特色区域样式 */
.features {
    padding: 80px 0;
    background-color: var(--gray-light);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 30px;
}

.feature-item {
    text-align: center;
    padding: 30px;
    background-color: var(--white-color);
    border-radius: 8px;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.feature-item:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.feature-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
    margin-bottom: 20px;
    color: var(--primary-color);
    background-color: rgba(211, 47, 47, 0.1);
    border-radius: 50%;
}

.feature-icon svg {
    width: 24px;
    height: 24px;
}

.feature-title {
    margin-bottom: 15px;
    font-size: 1.3rem;
    color: var(--dark-color);
}

.feature-desc {
    color: var(--gray-color);
    font-size: 0.95rem;
}

/* 新闻资讯区域样式 */
.news {
    padding: 80px 0;
    background-color: var(--white-color);
}

.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 30px;
}

.news-item {
    display: flex;
    flex-direction: column;
    background-color: var(--white-color);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.news-item:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.news-image {
    width: 100%;
    height: 200px;
    overflow: hidden;
}

.news-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.news-item:hover .news-img {
    transform: scale(1.05);
}

.news-info {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.news-date {
    display: inline-block;
    margin-bottom: 10px;
    padding: 3px 10px;
    background-color: var(--gray-light);
    color: var(--gray-color);
    font-size: 0.85rem;
    border-radius: 4px;
}

.news-title {
    margin-bottom: 10px;
    font-size: 1.2rem;
    line-height: 1.4;
}

.news-title a {
    color: var(--dark-color);
}

.news-title a:hover {
    color: var(--primary-color);
}

.news-excerpt {
    color: var(--gray-color);
    font-size: 0.95rem;
    margin-top: auto;
}

/* 用户评价区域样式 */
.reviews {
    padding: 80px 0;
    background-color: var(--gray-light);
}

.reviews-slider {
    position: relative;
    overflow: hidden;
}

.reviews-track {
    display: flex;
    transition: transform 0.5s ease;
    gap: 20px;
}

.review-item {
    flex: 0 0 calc(100% / 3 - 20px);
    min-width: 0;
}

.review-content {
    padding: 25px;
    background-color: var(--white-color);
    border-radius: 8px;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.review-content:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.review-rating {
    margin-bottom: 15px;
    color: var(--secondary-color);
    font-size: 1.2rem;
}

.review-text {
    margin-bottom: 20px;
    color: var(--gray-color);
    line-height: 1.6;
}

.review-author {
    display: flex;
    align-items: center;
}

.review-avatar {
    width: 40px;
    height: 40px;
    margin-right: 15px;
    border-radius: 50%;
    object-fit: cover;
}

.author-info {
    flex: 1;
}

.author-name {
    display: block;
    margin-bottom: 3px;
    font-weight: 500;
    color: var(--dark-color);
}

.author-date {
    font-size: 0.85rem;
    color: var(--gray-color);
}

.slider-prev,
.slider-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--white-color);
    color: var(--primary-color);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: var(--shadow);
    transition: var(--transition);
    z-index: 10;
}

.slider-prev:hover,
.slider-next:hover {
    background-color: var(--primary-color);
    color: var(--white-color);
}

.slider-prev {
    left: -20px;
}

.slider-next {
    right: -20px;
}

/* 友情链接区域样式 */
.friendlinks {
    padding: 40px 0;
    background-color: var(--white-color);
    border-top: 1px solid #eee;
    border-bottom: 1px solid #eee;
}

.friendlinks-title {
    margin-bottom: 20px;
    font-size: 1.3rem;
    color: var(--dark-color);
    text-align: center;
}

.friendlinks-list {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px 30px;
}

.friendlink {
    color: var(--gray-color);
    transition: var(--transition);
}

.friendlink:hover {
    color: var(--primary-color);
}

/* 页脚样式 */
.footer {
    padding: 60px 0 30px;
    background-color: var(--dark-color);
    color: var(--white-color);
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-info .footer-logo {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
}

.footer-logo-img {
    width: 50px;
    height: 50px;
    margin-right: 15px;
}

.footer-logo-text {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--white-color);
}

.footer-desc {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.95rem;
}

.footer-links-title,
.footer-contact-title {
    margin-bottom: 20px;
    font-size: 1.2rem;
    color: var(--white-color);
}

.footer-links-list {
    list-style: none;
}

.footer-links-list li {
    margin-bottom: 10px;
}

.footer-link {
    color: rgba(255, 255, 255, 0.7);
}

.footer-link:hover {
    color: var(--white-color);
}

.footer-contact-info p {
    margin-bottom: 10px;
    color: rgba(255, 255, 255, 0.7);
}

.footer-bottom {
    padding-top: 30px;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-copyright,
.footer-disclaimer {
    margin-bottom: 10px;
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.9rem;
}

.footer-disclaimer {
    font-style: italic;
}

/* 响应式设计 */
@media (max-width: 992px) {
    .review-item {
        flex: 0 0 calc(100% / 2 - 15px);
    }
}

@media (max-width: 768px) {
    /* 导航栏响应式 */
    .nav {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        height: 100vh;
        padding: 80px 20px;
        background-color: var(--white-color);
        box-shadow: -5px 0 15px rgba(0, 0, 0, 0.1);
        transition: var(--transition);
        z-index: 999;
    }
    
    .nav.active {
        right: 0;
    }
    
    .nav-list {
        flex-direction: column;
    }
    
    .nav-item {
        margin: 15px 0;
    }
    
    .nav-link {
        font-size: 1.2rem;
    }
    
    .menu-toggle {
        display: flex;
        z-index: 1000;
    }
    
    .menu-toggle.active span:first-child {
        transform: rotate(45deg) translate(5px, 5px);
    }
    
    .menu-toggle.active span:nth-child(2) {
        opacity: 0;
    }
    
    .menu-toggle.active span:last-child {
        transform: rotate(-45deg) translate(5px, -5px);
    }
    
    /* 英雄区域响应式 */
    .hero {
        height: 400px;
    }
    
    .hero-title {
        font-size: 2.2rem;
    }
    
    /* 产品响应式 */
    .products-grid,
    .features-grid,
    .news-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    }
    
    /* 评价响应式 */
    .review-item {
        flex: 0 0 100%;
    }
    
    .slider-prev {
        left: 10px;
    }
    
    .slider-next {
        right: 10px;
    }
    
    /* 友情链接响应式 */
    .friendlinks-list {
        flex-direction: column;
        align-items: center;
        gap: 10px;
    }
}

@media (max-width: 576px) {
    /* 基础样式响应式 */
    h1 {
        font-size: 2rem;
    }
    
    h2 {
        font-size: 1.8rem;
    }
    
    h3 {
        font-size: 1.4rem;
    }
    
    /* 英雄区域响应式 */
    .hero {
        height: 300px;
    }
    
    .hero-content {
        padding: 20px;
    }
    
    .hero-title {
        font-size: 1.8rem;
    }
    
    .hero-description {
        font-size: 1rem;
    }
    
    /* 区域头部响应式 */
    .section-header {
        margin-bottom: 30px;
    }
    
    /* 间距响应式 */
    .products,
    .features,
    .news,
    .reviews {
        padding: 50px 0;
    }
    
    .footer {
        padding: 40px 0 20px;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: 30px;
    }
}

/* 动画效果 */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 图片懒加载 */
img[data-src] {
    opacity: 0;
    transition: opacity 0.3s ease;
}

img[data-src].loaded {
    opacity: 1;
}

/* 打印样式 */
@media print {
    .header,
    .footer,
    .top-notice,
    .menu-toggle,
    .slider-prev,
    .slider-next {
        display: none;
    }
    
    body {
        color: #000;
        background-color: #fff;
    }
}