That is the biggest sin,lusting after the opposite sex,which Satan uses it so much.
Satan used Eve to tempt Adam.
The Bible says that love does not think an evil thought.It is sin if we lust in our mind,and a bum on the street is as guilty as the rich man if he wants to heap money to themselves and be rich.
While it is a sin to lust after a woman,if you glance at her and say that is a pretty woman,but do not lust after her,it would seem like it would not be sin,for if you came by a pretty flower or anything else like that,you would think it is pretty,so thinking a women is pretty does not necessarily mean lusting for your mind will think that,like something that is ugly your mind will think it is ugly,but do not lust.