/**
 * 安居客风格的筛选界面样式
 * Anjuke-style filter interface
 */

/* 筛选容器 */
.anjuke-filter-container {
    background: #fff;
    border: 1px solid #e5e5e5;
    border-radius: 4px;
    margin-bottom: 20px;
    padding: 15px 20px;
}

/* 每一行筛选 */
.anjuke-filter-row {
    display: flex;
    align-items: flex-start;
    padding: 12px 0;
    border-bottom: 1px solid #f0f0f0;
}

.anjuke-filter-row:last-child {
    border-bottom: none;
}

/* 筛选标签 */
.anjuke-filter-label {
    flex-shrink: 0;
    width: 80px;
    padding-right: 15px;
    font-weight: 600;
    color: #333;
    font-size: 14px;
    line-height: 32px;
}

/* 筛选选项容器 */
.anjuke-filter-options {
    flex: 1;
    display: flex;
    flex-wrap: wrap;
    gap: 8px 12px;
    align-items: center;
}

/* 可折叠的筛选选项（品牌较多时） */
.anjuke-filter-collapsible:not(.is-expanded) {
    max-height: 80px;
    overflow: hidden;
    position: relative;
}

.anjuke-filter-collapsible.is-expanded {
    max-height: none;
}

/* 单个筛选选项 */
.anjuke-filter-option {
    display: inline-block;
    padding: 6px 16px;
    font-size: 14px;
    color: #333;
    text-decoration: none;
    border-radius: 2px;
    transition: all 0.2s;
    background: #fff;
    border: 1px solid transparent;
    white-space: nowrap;
}

.anjuke-filter-option:hover {
    color: #38b875;
    background: #f0fff7;
    border-color: #38b875;
}

.anjuke-filter-option.active {
    color: #fff;
    background: #38b875;
    border-color: #38b875;
    font-weight: 600;
}

/* 展开/收起按钮 */
.anjuke-filter-toggle {
    background: none;
    border: none;
    color: #38b875;
    cursor: pointer;
    font-size: 14px;
    padding: 6px 12px;
    margin-left: 10px;
    transition: color 0.2s;
}

.anjuke-filter-toggle:hover {
    color: #2d9a5f;
}

.anjuke-filter-toggle i {
    margin-left: 4px;
    font-size: 12px;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .anjuke-filter-label {
        width: 60px;
        font-size: 13px;
    }
    
    .anjuke-filter-option {
        font-size: 13px;
        padding: 5px 12px;
    }
    
    .anjuke-filter-row {
        padding: 10px 0;
    }
}

/* 筛选计数样式 */
.anjuke-filter-option .filter-count {
    color: #999;
    font-size: 12px;
    margin-left: 4px;
}

.anjuke-filter-option.active .filter-count {
    color: rgba(255, 255, 255, 0.9);
}

/* 重置所有筛选按钮 */
.anjuke-filter-reset {
    display: inline-block;
    padding: 6px 16px;
    background: #f5f5f5;
    color: #666;
    border-radius: 2px;
    text-decoration: none;
    font-size: 14px;
    transition: all 0.2s;
    margin-left: auto;
}

.anjuke-filter-reset:hover {
    background: #e5e5e5;
    color: #333;
}

.anjuke-filter-reset i {
    margin-right: 4px;
}

/* 筛选标签样式（选中的筛选条件） */
.anjuke-selected-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 15px;
    padding: 10px 20px;
    background: #f9f9f9;
    border-radius: 4px;
}

.selected-filter-tag {
    display: inline-flex;
    align-items: center;
    padding: 4px 12px;
    background: #38b875;
    color: #fff;
    border-radius: 2px;
    font-size: 13px;
}

.selected-filter-tag .remove-filter {
    margin-left: 8px;
    cursor: pointer;
    opacity: 0.8;
    transition: opacity 0.2s;
}

.selected-filter-tag .remove-filter:hover {
    opacity: 1;
}

/* 筛选结果统计 */
.anjuke-filter-result {
    padding: 15px 20px;
    background: #f9f9f9;
    border-radius: 4px;
    margin-bottom: 20px;
    font-size: 14px;
    color: #666;
}

.anjuke-filter-result strong {
    color: #38b875;
    font-size: 16px;
}

/* 动画效果 */
.anjuke-filter-options {
    transition: max-height 0.3s ease;
}

/* 加载状态 */
.anjuke-filter-container.loading {
    opacity: 0.6;
    pointer-events: none;
}

/* 空状态 */
.anjuke-filter-empty {
    text-align: center;
    padding: 40px 20px;
    color: #999;
    font-size: 14px;
}

.anjuke-filter-empty i {
    font-size: 48px;
    margin-bottom: 16px;
    opacity: 0.3;
}

