* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: "Microsoft YaHei", "Helvetica Neue", Helvetica, Arial, sans-serif;
    font-size: 14px;
    line-height: 1.6;
    color: #333;
    background-color: #f5f5f5;
}

a {
    color: #1e87f0;
    text-decoration: none;
    transition: color 0.3s;
}

a:hover {
    color: #0f6ecd;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

.section {
    padding: 40px 0;
}

.section-light {
    background-color: #fff;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.section-title {
    font-size: 24px;
    font-weight: 600;
    color: #333;
    position: relative;
    padding-left: 15px;
}

.section-title::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 20px;
    background-color: #1e87f0;
}

.more-link {
    color: #1e87f0;
    font-size: 14px;
}

.more-link:hover {
    color: #0f6ecd;
}

.btn {
    display: inline-block;
    padding: 12px 30px;
    font-size: 16px;
    border-radius: 4px;
    transition: all 0.3s;
    cursor: pointer;
    border: none;
}

.btn-primary {
    background-color: #1e87f0;
    color: #fff;
}

.btn-primary:hover {
    background-color: #0f6ecd;
    color: #fff;
}

.btn-secondary {
    background-color: #fff;
    color: #1e87f0;
    border: 1px solid #1e87f0;
}

.btn-secondary:hover {
    background-color: #1e87f0;
    color: #fff;
}

.header {
    background-color: #fff;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px;
}

.logo h1 {
    font-size: 24px;
    color: #1e87f0;
    margin: 0;
}

.nav ul {
    display: flex;
    list-style: none;
}

.nav ul li {
    margin-left: 30px;
}

.nav ul li a {
    color: #333;
    font-size: 15px;
    padding: 8px 0;
    position: relative;
}

.nav ul li a.active {
    color: #1e87f0;
}

.nav ul li a.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2px;
    background-color: #1e87f0;
}

.header-actions {
    display: flex;
    align-items: center;
}

.search-form {
    display: flex;
    margin-right: 20px;
}

.search-input {
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px 0 0 4px;
    width: 200px;
    font-size: 14px;
}

.search-btn {
    padding: 8px 15px;
    background-color: #1e87f0;
    color: #fff;
    border: none;
    border-radius: 0 4px 4px 0;
    cursor: pointer;
    font-size: 14px;
}

.search-btn:hover {
    background-color: #0f6ecd;
}

.user-menu {
    display: flex;
    align-items: center;
}

.user-menu a {
    margin-left: 15px;
    font-size: 14px;
}

.auth-links {
    display: flex;
    align-items: center;
}

.auth-links a {
    margin-left: 15px;
    padding: 8px 20px;
    border-radius: 4px;
    font-size: 14px;
}

.login-btn {
    color: #1e87f0;
    border: 1px solid #1e87f0;
}

.login-btn:hover {
    background-color: #1e87f0;
    color: #fff;
}

.register-btn {
    background-color: #1e87f0;
    color: #fff;
}

.register-btn:hover {
    background-color: #0f6ecd;
    color: #fff;
}

.banner {
    background: linear-gradient(135deg, #1e87f0 0%, #0f6ecd 100%);
    padding: 80px 0;
    color: #fff;
    text-align: center;
}

.banner-title {
    font-size: 36px;
    margin-bottom: 20px;
    font-weight: 600;
}

.banner-desc {
    font-size: 18px;
    margin-bottom: 30px;
    opacity: 0.9;
}

.banner-actions {
    display: flex;
    justify-content: center;
    gap: 20px;
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 20px;
}

.category-card {
    background-color: #fff;
    padding: 30px 20px;
    text-align: center;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s, box-shadow 0.3s;
}

.category-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15);
}

.category-card h4 {
    font-size: 16px;
    color: #333;
}

.category-card:hover h4 {
    color: #1e87f0;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 25px;
}

.product-card {
    background-color: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s, box-shadow 0.3s;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
}

.product-image {
    position: relative;
    height: 200px;
    background-color: #f8f8f8;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #f8f8f8;
}

.product-image .no-image {
    color: #999;
    font-size: 14px;
}

.product-info {
    padding: 20px;
}

.product-title {
    font-size: 16px;
    margin-bottom: 10px;
    height: 44px;
    overflow: hidden;
    line-height: 1.5;
}

.product-title a {
    color: #333;
}

.product-title a:hover {
    color: #1e87f0;
}

.product-desc {
    font-size: 13px;
    color: #666;
    margin-bottom: 15px;
    height: 40px;
    overflow: hidden;
    line-height: 1.5;
}

.product-meta {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: #999;
    margin-bottom: 10px;
}

.product-price {
    font-size: 18px;
    color: #ff4400;
    font-weight: 600;
}

.product-price .original-price {
    font-size: 14px;
    color: #999;
    text-decoration: line-through;
    margin-right: 8px;
    font-weight: normal;
}

.price-free {
    color: #52c41a;
}

.product-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 10px;
}

.theme-btn {
    display: inline-block;
    padding: 6px 15px;
    background: #1e87f0;
    color: #fff;
    border-radius: 4px;
    font-size: 13px;
    transition: background 0.3s;
}

.theme-btn:hover {
    background: #0f6ecd;
    color: #fff;
}

.product-image {
    position: relative;
    height: 200px;
    background-color: #f8f8f8;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.product-tags {
    position: absolute;
    top: 10px;
    left: 10px;
    display: flex;
    gap: 5px;
    flex-wrap: wrap;
}

.product-tag {
    padding: 3px 8px;
    border-radius: 3px;
    font-size: 11px;
    color: #fff;
    font-weight: 500;
    text-shadow: 0 1px 2px rgba(0,0,0,0.2);
}

.product-tag.hot {
    background: linear-gradient(135deg, #ff4d4f 0%, #ff7875 100%);
}

.product-tag.new {
    background: linear-gradient(135deg, #52c41a 0%, #73d13d 100%);
}

.product-tag.recommend {
    background: linear-gradient(135deg, #ff8f00 0%, #ffa940 100%);
}

.product-meta .divider {
    color: #ddd;
    margin: 0 8px;
}

.article-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 25px;
}

.article-card {
    background-color: #fff;
    padding: 25px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s;
}

.article-card:hover {
    transform: translateY(-3px);
}

.article-title {
    font-size: 18px;
    margin-bottom: 12px;
    height: 48px;
    overflow: hidden;
    line-height: 1.5;
}

.article-title a {
    color: #333;
}

.article-title a:hover {
    color: #1e87f0;
}

.article-desc {
    font-size: 14px;
    color: #666;
    margin-bottom: 15px;
    height: 42px;
    overflow: hidden;
    line-height: 1.5;
}

.article-meta {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: #999;
}

.article-list {
    background-color: #fff;
    padding: 25px;
    border-radius: 8px;
}

.article-ul {
    list-style: none;
}

.article-ul li {
    padding: 12px 0;
    border-bottom: 1px solid #f0f0f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.article-ul li:last-child {
    border-bottom: none;
}

.article-ul li a {
    color: #333;
    font-size: 15px;
}

.article-ul li a:hover {
    color: #1e87f0;
}

.article-ul li .views {
    color: #999;
    font-size: 12px;
}

.footer {
    background-color: #2d3436;
    color: #fff;
    padding: 50px 0 20px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-section h4 {
    font-size: 16px;
    margin-bottom: 20px;
    color: #fff;
}

.footer-section p {
    font-size: 14px;
    color: #b2bec3;
    line-height: 1.8;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 10px;
}

.footer-section ul li a {
    color: #b2bec3;
}

.footer-section ul li a:hover {
    color: #fff;
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid #3d4547;
}

.footer-bottom p {
    font-size: 13px;
    color: #b2bec3;
    margin-bottom: 5px;
}

.no-data {
    text-align: center;
    padding: 40px;
    color: #999;
    font-size: 14px;
}

.pagination {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 30px;
}

.pagination a,
.pagination span {
    padding: 8px 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.pagination a:hover {
    background-color: #1e87f0;
    color: #fff;
    border-color: #1e87f0;
}

.pagination .current {
    background-color: #1e87f0;
    color: #fff;
    border-color: #1e87f0;
}

.clearfix::after {
    content: '';
    display: table;
    clear: both;
}

.text-center {
    text-align: center;
}

.mt-20 {
    margin-top: 20px;
}

.mb-20 {
    margin-bottom: 20px;
}

@media (max-width: 768px) {
    .header .container {
        flex-direction: column;
    }
    
    .nav ul {
        margin: 15px 0;
    }
    
    .nav ul li {
        margin-left: 15px;
    }
    
    .header-actions {
        width: 100%;
        justify-content: center;
    }
    
    .banner-title {
        font-size: 24px;
    }
    
    .banner-desc {
        font-size: 16px;
    }
    
    .product-grid,
    .article-grid {
        grid-template-columns: 1fr;
    }
}
