/* ── Barra de filtros ── */
#ct37-filter-bar {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 14px 20px;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    flex-wrap: wrap;
    font-family: inherit;
}

#ct37-filter-bar .ct37-filter-group {
    display: flex;
    align-items: center;
    gap: 8px;
}

#ct37-filter-bar label {
    color: #888;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.09em;
    white-space: nowrap;
    margin: 0;
}

/* ── Dropdown personalizado ── */
.ct37-brand-dropdown {
    position: relative;
    min-width: 180px;
    font-size: 14px;
    user-select: none;
}

.ct37-brand-trigger {
    appearance: none;
    background: #f5f5f5 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23666' d='M6 8L1 3h10z'/%3E%3C/svg%3E") no-repeat right 12px center;
    background-size: 10px;
    border: 1px solid #ddd;
    border-radius: 6px;
    color: #222;
    font-size: 14px;
    padding: 8px 36px 8px 14px;
    cursor: pointer;
    width: 100%;
    transition: border-color 0.2s;
    text-align: left;
    font-family: inherit;
}

.ct37-brand-trigger:focus,
.ct37-brand-dropdown.open .ct37-brand-trigger {
    outline: none;
    border-color: #c00;
}

.ct37-brand-list {
    display: none;
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    right: 0;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 6px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.12);
    z-index: 999;
    padding: 4px 0;
}

.ct37-brand-dropdown.open .ct37-brand-list {
    display: block;
}

.ct37-brand-option {
    padding: 8px 14px;
    cursor: pointer;
    color: #222;
    font-size: 14px;
    transition: background 0.15s, color 0.15s;
}

.ct37-brand-option:hover,
#ct37-filter-bar .ct37-brand-option:hover {
    background: #c00 !important;
    color: #fff !important;
}

.ct37-brand-option.selected,
#ct37-filter-bar .ct37-brand-option.selected {
    background: #c00 !important;
    color: #fff !important;
    font-weight: 600;
}

.ct37-sort-btn {
    background: #f5f5f5;
    border: 1px solid #ddd;
    border-radius: 6px;
    color: #444;
    cursor: pointer;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.03em;
    padding: 8px 16px;
    text-transform: uppercase;
    transition: background 0.2s, color 0.2s, border-color 0.2s;
    white-space: nowrap;
}

.ct37-sort-btn:hover {
    background: #eee;
    border-color: #bbb;
    color: #111;
}

.ct37-sort-btn.active {
    background: #c00;
    border-color: #c00;
    color: #fff;
}

.ct37-filter-divider {
    width: 1px;
    height: 24px;
    background: #e0e0e0;
    flex-shrink: 0;
}

/* Contador debajo de la barra */
.ct37-filter-count {
    text-align: center;
    color: #bbb;
    font-size: 11px;
    margin-bottom: 24px;
    letter-spacing: 0.03em;
}

.ct37-filter-count strong {
    color: #555;
}

#ct37-no-results {
    display: none;
    text-align: center;
    padding: 48px 20px;
    color: #aaa;
    font-size: 15px;
    width: 100%;
}

/* ── Móvil ── */
@media (max-width: 768px) {
    #ct37-filter-bar {
        padding: 12px 14px;
        gap: 8px;
        flex-direction: column;
        align-items: stretch;
        justify-content: flex-start;
    }

    #ct37-filter-bar label {
        display: none;
    }

    .ct37-brand-dropdown {
        width: 100%;
        min-width: unset;
    }

    #ct37-filter-bar .ct37-filter-group:last-child {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 6px;
    }

    .ct37-sort-btn {
        padding: 10px 8px;
        text-align: center;
        font-size: 12px;
    }

    .ct37-filter-divider {
        display: none;
    }

    .ct37-filter-count {
        font-size: 11px;
        margin-bottom: 16px;
    }
}
