/* ==== 产品列表页面样式 ==== */

/* 页面整体样式 */
.product-list-page {
    min-height: 100vh !important;
    background: white !important;
    padding: 20px 0 !important;
}

/* 页面头部 */
.page-header {
    margin-bottom: 20px !important;
}

.results-count {
    display: flex !important;
    align-items: center !important;
}

.count-text {
    font-size: 14px !important;
    color: #1e3a8a !important;
    font-weight: 400 !important;
}

/* 主要内容布局 */
.product-list-content {
    display: flex !important;
    gap: 20px !important;
    align-items: flex-start !important;
}

/* ==== 左侧筛选条件侧边栏 ==== */
.filter-sidebar {
    width: 268px !important;
    flex-shrink: 0 !important;
    background: #f8f9fa !important;
    border: 1px solid #e9ecef !important;
    border-radius: 4px !important;
}

.filter-section {
    border-bottom: 1px solid #e9ecef !important;
}

.filter-section:last-child {
    border-bottom: none !important;
}

.filter-title {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    font-size: 14px !important;
    color: #333 !important;
    font-weight: 600 !important;
    margin: 0 !important;
    padding: 12px 16px !important;
    background: #e9ecef !important;
    border-bottom: 1px solid #dee2e6 !important;
}

.clear-all-btn {
    background: none !important;
    border: none !important;
    color: #1e3a8a !important;
    font-size: 12px !important;
    cursor: pointer !important;
    padding: 0 !important;
    text-decoration: underline !important;
}

.clear-all-btn:hover {
    color: #1e3a8a !important;
}

/* 筛选组 */
.filter-group {
    border-bottom: 1px solid #f0f0f0 !important;
}

.filter-group:last-child {
    border-bottom: none !important;
}

.filter-group-header {
    display: flex !important;
    align-items: center !important;
    padding: 10px 16px !important;
    cursor: pointer !important;
    transition: background-color 0.3s ease !important;
}

.filter-group-header:hover {
    background: #f0f0f0 !important;
}

.filter-group-header i {
    font-size: 10px !important;
    color: #999 !important;
    margin-right: 8px !important;
    transition: transform 0.3s ease !important;
}

.filter-group-header span {
    font-size: 13px !important;
    color: #333 !important;
    font-weight: 400 !important;
}

/* 筛选选项区域 */
.filter-options {
    display: none !important;
    background: white !important;
    border-top: 1px solid #e9ecef !important;
}

.filter-group.expanded .filter-options {
    display: block !important;
}

.search-box {
    position: relative !important;
    padding: 8px 12px !important;
    border-bottom: 1px solid #f0f0f0 !important;
}

.search-box input {
    width: 100% !important;
    padding: 6px 30px 6px 10px !important;
    border: 1px solid #ddd !important;
    border-radius: 3px !important;
    font-size: 12px !important;
    outline: none !important;
}

.search-box i {
    position: absolute !important;
    right: 18px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    color: #999 !important;
    font-size: 12px !important;
}

.filter-scroll-area {
    max-height: 180px !important;
    overflow-y: auto !important;
    padding: 4px 0 !important;
}

/* 自定义滚动条样式 */
.filter-scroll-area::-webkit-scrollbar {
    width: 8px !important;
}

.filter-scroll-area::-webkit-scrollbar-track {
    background: #f1f1f1 !important;
    border-radius: 4px !important;
}

.filter-scroll-area::-webkit-scrollbar-thumb {
    background: #c1c1c1 !important;
    border-radius: 4px !important;
}

.filter-scroll-area::-webkit-scrollbar-thumb:hover {
    background: #a1a1a1 !important;
}

.filter-option {
    display: flex !important;
    align-items: center !important;
    padding: 6px 12px !important;
    cursor: pointer !important;
    transition: background-color 0.3s ease !important;
}

.filter-option:hover {
    background: #f8f9fa !important;
}

.filter-option input[type="checkbox"] {
    margin: 0 8px 0 0 !important;
    width: 14px !important;
    height: 14px !important;
    accent-color: #3b82f6 !important;
}

.option-text {
    flex: 1 !important;
    font-size: 12px !important;
    color: #333 !important;
}

.option-count {
    font-size: 11px !important;
    color: #999 !important;
    margin-left: 8px !important;
}

/* 产品类型树形结构 */
.filter-tree {
    padding: 0 !important;
}

.tree-node {
    border-bottom: 1px solid #f0f0f0 !important;
}

.tree-node:last-child {
    border-bottom: none !important;
}

.tree-node-header {
    display: flex !important;
    align-items: center !important;
    padding: 10px 16px !important;
    cursor: pointer !important;
    transition: background-color 0.3s ease !important;
}

.tree-node-header:hover {
    background: #f0f0f0 !important;
}

.tree-node-header i {
    font-size: 10px !important;
    color: #999 !important;
    margin-right: 8px !important;
    transition: transform 0.3s ease !important;
}

.tree-node-header span {
    font-size: 13px !important;
    color: #333 !important;
    font-weight: 400 !important;
}

/* 树形子节点 */
.tree-children {
    display: none !important;
    background: white !important;
}

.tree-children.expanded,
.tree-node.expanded > .tree-children {
    display: block !important;
}

.tree-children .tree-node {
    margin-left: 16px !important;
    border-left: 1px solid #e9ecef !important;
}

.tree-children .tree-node-header {
    padding-left: 12px !important;
}

/* 树形叶子节点 */
.tree-leaf {
    padding: 8px 16px 8px 36px !important;
    font-size: 13px !important;
    color: #1e3a8a !important;
    cursor: pointer !important;
    transition: all 0.3s ease !important;
}

.tree-leaf:hover {
    background: #f0f0f0 !important;
    color: #333 !important;
}

.tree-leaf.active {
    background: #e3f2fd !important;
    color: #1976d2 !important;
    font-weight: 500 !important;
}

/* 展开状态的图标 */
.tree-node-header i.fa-chevron-down {
    transform: rotate(0deg) !important;
}

.tree-node-header i.fa-chevron-right {
    transform: rotate(0deg) !important;
}

/* ==== 右侧产品列表主区域 ==== */
.product-list-main {
    flex: 1 !important;
}

.product-list-header {
    margin-bottom: 20px !important;
}

.category-title {
    font-size: 18px !important;
    color: #333 !important;
    font-weight: 600 !important;
    margin: 0 !important;
}

/* 产品网格 */
.product-grid {
    display: flex !important;
    flex-direction: column !important;
    gap: 16px !important;
}

/* ==== 产品卡片样式 ==== */
.product-card {
    border: 2px solid #e9ecef !important;
    border-radius: 4px !important;
    background: white !important;
    overflow: hidden !important;
    transition: all 0.3s ease !important;
    cursor: pointer !important;
}

.product-card:hover {
    border-color: #3b82f6 !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1) !important;
    transform: translateY(-2px) !important;
}

/* 产品卡片内容布局 */
.product-card-content {
    display: flex !important;
    padding: 16px !important;
    gap: 16px !important;
}

.product-left-content {
    flex: 1 !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 12px !important;
}

.product-right-content {
    flex-shrink: 0 !important;
    width: 140px !important;
    display: flex !important;
    justify-content: center !important;
    align-items: flex-start !important;
}

/* 产品头部区域 */
.product-header-section {
    display: flex !important;
    flex-direction: column !important;
    gap: 8px !important;
}

.product-badges {
    display: flex !important;
    gap: 6px !important;
}

.badge-ko {
    background: #ff9500 !important;
    color: white !important;
    padding: 2px 6px !important;
    border-radius: 2px !important;
    font-size: 10px !important;
    font-weight: 600 !important;
    white-space: nowrap !important;
    display: inline-block !important;
}

.product-title {
    font-size: 16px !important;
    color: #333 !important;
    font-weight: 600 !important;
    margin: 0 !important;
    line-height: 1.3 !important;
}

/* 产品操作按钮 */
.product-actions {
    display: flex !important;
    gap: 8px !important;
}

.btn-quote,
.btn-manual {
    padding: 3px 8px !important;
    border: 1px solid #ddd !important;
    border-radius: 2px !important;
    font-size: 11px !important;
    cursor: pointer !important;
    transition: all 0.3s ease !important;
    white-space: nowrap !important;
}

.btn-quote {
    background: #e3f2fd !important;
    border-color: #90caf9 !important;
    color: #1976d2 !important;
}

.btn-manual {
    background: #fff3e0 !important;
    border-color: #3b82f6 !important;
    color: #f57c00 !important;
}

.btn-quote:hover,
.btn-manual:hover {
    opacity: 0.8 !important;
}

/* 产品元信息图标 */
.product-meta-icons {
    display: flex !important;
    gap: 16px !important;
}

.meta-icon {
    display: flex !important;
    align-items: center !important;
    gap: 4px !important;
    font-size: 11px !important;
    color: #1e3a8a !important;
}

.meta-icon i {
    font-size: 12px !important;
    color: #ffa500 !important;
}

.meta-icon span {
    color: #1e3a8a !important;
}

/* 产品图片 */
.product-image {
    position: relative !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
}

.product-image img {
    max-width: 120px !important;
    max-height: 100px !important;
    object-fit: contain !important;
}

.image-count {
    position: absolute !important;
    bottom: 2px !important;
    right: 2px !important;
    background: rgba(0, 0, 0, 0.7) !important;
    color: white !important;
    padding: 2px 4px !important;
    border-radius: 2px !important;
    font-size: 10px !important;
}

/* 产品详细信息 */
.product-details {
    margin-bottom: 12px !important;
}

.detail-row {
    display: flex !important;
    align-items: flex-start !important;
    margin-bottom: 6px !important;
    font-size: 12px !important;
    line-height: 1.4 !important;
}

.detail-row:last-child {
    margin-bottom: 0 !important;
}

.detail-label {
    min-width: 80px !important;
    color: #1e3a8a !important;
    font-weight: 500 !important;
    flex-shrink: 0 !important;
}

.detail-value {
    color: #333 !important;
    flex: 1 !important;
}

.detail-value.link {
    color: #1976d2 !important;
    cursor: pointer !important;
    text-decoration: underline !important;
}

.detail-value.link:hover {
    color: #1565c0 !important;
}

/* 应用标签 */
.app-tags {
    display: flex !important;
    gap: 4px !important;
    flex-wrap: wrap !important;
}

.app-tag {
    padding: 2px 6px !important;
    border-radius: 2px !important;
    font-size: 10px !important;
    font-weight: 500 !important;
    border: 1px solid !important;
}

/* 不同应用的颜色 */
.app-tag.wb {
    background: #e8f5e8 !important;
    color: #2e7d32 !important;
    border-color: #c8e6c9 !important;
}

.app-tag.ihc {
    background: #fff3e0 !important;
    color: #f57c00 !important;
    border-color: #3b82f6 !important;
}

.app-tag.if {
    background: #f3e5f5 !important;
    color: #7b1fa2 !important;
    border-color: #ce93d8 !important;
}

.app-tag.ip {
    background: #e1f5fe !important;
    color: #0277bd !important;
    border-color: #81d4fa !important;
}

.app-tag.elisa {
    background: #fce4ec !important;
    color: #c2185b !important;
    border-color: #f8bbd9 !important;
}

/* 产品卡片底部 */
.product-card-footer {
    padding: 8px 16px !important;
    border-top: 1px solid #e9ecef !important;
    background: #6c757d !important;
    display: flex !important;
    justify-content: flex-end !important;
}

.add-to-compare {
    display: flex !important;
    align-items: center !important;
    gap: 6px !important;
    font-size: 11px !important;
    color: white !important;
    cursor: pointer !important;
}

.add-to-compare input[type="checkbox"] {
    margin: 0 !important;
    width: 14px !important;
    height: 14px !important;
    accent-color: #fff !important;
}

.add-to-compare span {
    color: white !important;
}

/* ==== 响应式设计 ==== */

/* 平板设备 */
@media (max-width: 992px) {
    .product-list-content {
        flex-direction: column !important;
        gap: 16px !important;
    }

    .filter-sidebar {
        width: 100% !important;
    }

    .product-card-header {
        flex-direction: column !important;
        align-items: flex-start !important;
    }

    .product-image {
        align-self: center !important;
    }
}

/* 手机设备 */
@media (max-width: 768px) {
    .product-list-page {
        padding: 12px 0 !important;
    }

    .filter-sidebar {
        border-radius: 0 !important;
        border-left: none !important;
        border-right: none !important;
    }

    .product-card {
        border-radius: 0 !important;
        border-left: none !important;
        border-right: none !important;
    }

    .product-actions {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 8px !important;
    }

    .detail-row {
        flex-direction: column !important;
        gap: 2px !important;
    }

    .detail-label {
        min-width: auto !important;
    }

    .app-tags {
        margin-top: 4px !important;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 12px !important;
    }

    .product-card-header {
        padding: 8px !important;
    }

    .product-card-body {
        padding: 8px !important;
    }

    .product-title {
        font-size: 14px !important;
    }

    .action-buttons {
        flex-direction: column !important;
        gap: 4px !important;
    }

    .btn-quote,
    .btn-manual {
        width: 100% !important;
        text-align: center !important;
    }
}
