Hmm.. I may be in error here, but, I believe the browser string for NS 4 returns a very similar string for a portion of it (i.e. Mozilla/4.xxx).
I think the solution in this case would be to filter for this particular string using a regular expression.
Also, a lot of browsers return Mozilla 4.0 compatible in the string. You'll need to make sure that you don't classify the 4.0 compatibles as NS4.x, as this includes most of the up to date browsers that do support CSS.
Just a thought, good luck with it. :)