Some hack tips:
In CSS, the way I use to code for different browsers (usually IE and FF) is '!important'.
However, it seems that IE 7 understands this magic command while IE 6 doesn't. It makes more difficult to recognize IE 7 and FF.
Here is the solution: Conditional Comments
simple way to check IE version
<!--[if IE 6]>or check the condition: [if !IE] => for FFUsing Internet Explorer 6.
<![endif]-->