/* ========================================
   产品中心页面样式 - Products Page Styles
======================================== */

/* 产品分类筛选 */
.products-filter {
    padding: 60px 0 40px;
    background: var(--light-color);
}

.filter-tabs {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
}

.filter-btn {
    padding: 0.75rem 2rem;
    background: var(--white-color);
    color: var(--text-color);
    border: 2px solid var(--border-color);
    border-radius: 50px;
    font-weight: 600;
    transition: all 0.3s ease;
    cursor: pointer;
}

.filter-btn:hover,
.filter-btn.active {
    background: var(--primary-color);
    color: var(--white-color);
    border-color: var(--primary-color);
    transform: translateY(-3px);
    box-shadow: var(--shadow);
}

/* 产品列表 */
.products-list {
    padding: 60px 0;
}

.products-product-card {
    background: var(--white-color);
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.products-product-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}

.products-product-img {
    position: relative;
    height: 280px;
    overflow: hidden;
}

.products-product-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: all 0.5s ease;
}

.products-product-card:hover .products-product-img img {
    transform: scale(1.15);
}

.products-product-badge {
    position: absolute;
    top: 15px;
    left: 15px;
    padding: 0.4rem 1rem;
    background: var(--accent-color);
    color: var(--white-color);
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
    z-index: 2;
}

.products-product-tag {
    position: absolute;
    top: 15px;
    right: 15px;
    padding: 0.4rem 1rem;
    background: var(--success-color);
    color: var(--white-color);
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
    z-index: 2;
}

.products-product-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(37, 99, 235, 0.95);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    opacity: 0;
    transition: all 0.3s ease;
}

.products-product-card:hover .products-product-overlay {
    opacity: 1;
}

.products-overlay-btn {
    width: 45px;
    height: 45px;
    background: var(--white-color);
    color: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    transform: translateY(20px);
}

.products-product-card:hover .products-overlay-btn {
    transform: translateY(0);
}

.products-overlay-btn:hover {
    background: var(--accent-color);
    color: var(--white-color);
    transform: scale(1.2) translateY(0);
}

.products-product-info {
    padding: 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.products-product-category {
    color: var(--primary-color);
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
}

.products-product-info h5 {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--dark-color);
    margin-bottom: 0.8rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.products-product-desc {
    color: var(--secondary-color);
    font-size: 0.95rem;
    margin-bottom: 1rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    flex-grow: 1;
}

.products-product-features {
    list-style: none;
    padding: 0;
    margin-bottom: 1rem;
}

.products-product-features li {
    font-size: 0.9rem;
    color: var(--secondary-color);
    margin-bottom: 0.3rem;
    padding-left: 1.5rem;
    position: relative;
}

.products-product-features li::before {
    content: '\f00c';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    position: absolute;
    left: 0;
    color: var(--success-color);
}

.products-product-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 1rem;
    border-top: 1px solid var(--border-color);
}

.products-product-price {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
}

.products-product-price small {
    font-size: 0.9rem;
    color: var(--secondary-color);
    text-decoration: line-through;
    margin-left: 0.5rem;
}

.products-product-price .unit {
    font-size: 0.8rem;
    color: var(--secondary-color);
    font-weight: 400;
}

.products-contact-btn {
    padding: 0.5rem 1.5rem;
    background: var(--primary-color);
    color: var(--white-color);
    border: none;
    border-radius: 50px;
    font-weight: 600;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
}

.products-contact-btn:hover {
    background: #1d4ed8;
    color: var(--white-color);
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

/* 分页 */
.products-pagination {
    padding: 40px 0;
    display: flex;
    justify-content: center;
}

/* 侧边栏（如果需要） */
.products-sidebar {
    background: var(--white-color);
    border-radius: 12px;
    padding: 2rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.sidebar-widget {
    margin-bottom: 2rem;
}

.sidebar-widget:last-child {
    margin-bottom: 0;
}

.sidebar-widget h5 {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--dark-color);
    margin-bottom: 1rem;
    padding-bottom: 0.8rem;
    border-bottom: 2px solid var(--primary-color);
}

.sidebar-categories {
    list-style: none;
    padding: 0;
}

.sidebar-categories li {
    margin-bottom: 0.8rem;
}

.sidebar-categories a {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--text-color);
    text-decoration: none;
    padding: 0.5rem;
    border-radius: 6px;
    transition: all 0.3s ease;
}

.sidebar-categories a:hover,
.sidebar-categories a.active {
    background: var(--primary-color);
    color: var(--white-color);
    padding-left: 1rem;
}

.sidebar-categories .count {
    font-size: 0.9rem;
    opacity: 0.8;
}

/* 热门产品 */
.sidebar-hot-product {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.sidebar-hot-product:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.sidebar-hot-img {
    width: 80px;
    height: 80px;
    border-radius: 8px;
    overflow: hidden;
    flex-shrink: 0;
}

.sidebar-hot-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.sidebar-hot-info h6 {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--dark-color);
    margin-bottom: 0.5rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.sidebar-hot-price {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--primary-color);
}

/* 响应式设计 */
@media (max-width: 991.98px) {
    .products-sidebar {
        margin-top: 3rem;
    }
}

@media (max-width: 767.98px) {
    .products-filter,
    .products-list {
        padding: 40px 0;
    }
    
    .filter-tabs {
        gap: 0.5rem;
    }
    
    .filter-btn {
        padding: 0.6rem 1.2rem;
        font-size: 0.9rem;
    }
    
    .products-product-img {
        height: 220px;
    }
}
