Right now it just sorts randomly, which I admit is pretty bad. The search itself is very basic--it just takes your query and regex matches it on property names in the db.
If you want to keep it simple, you could just sort by length, with shorter property names first. I think that would work pretty well for most cases (border would come before border-color, etc).