I've messed around with trying to detect how complex the query is (like if it's just an ID selector, it goes through getElementById instead and such) but this is clearly no way to do complex CSS queries and will probably fail on a certain few selectors.
So my question is to anyone who's done something similar, how did you end up replicating it for older browsers.