Instinctively, men and women have a natural inclination to each other. Therefore, contrary to the laxity of the Western culture, Islam regulates the relation between the two sexes in a way that safeguards morals and modesty. As interaction between men and women is sometimes unavoidable, Shari`ah sets conditions and boundaries that must be observed in such situations. However, unfortunately, a lot of Muslims have taken the liberty of mimicking the Western lifestyle, playing around such boundaries and making false excuses to justify their unacceptable behaviors.
Dr. Hatem Al-Haj, dean of the Shari`ah Academy of America, said,
Intermingling is a general term, which includes that which is permissible and that which is prohibited. If it is men and women merely gathering in an open space to perform a shared work, whether religious or non-religious, that in itself is not prohibited, as long as the Islamic code of conduct is followed, in terms of hijab (i.e., Islamic dress code for women), lowering gaze, and the like. Women must keep away from men and vice versa as much as possible.
If mingling is about men and women socializing and mixing together closely and freely, this follows the basic principle of prohibition, as long as there is no exigent need according to the criteria of Shari`ah.
the prohibition of free mixing, particularly between people of young age, is based on many proofs, of them are the following:
Allah says, (And stay in your houses, and do not display your finery like the displaying of the ignorance of yore, and keep up Prayer, and pay the poor-rate, and obey Allah and His Messenger. Allah wishes only to keep away the uncleanness from you, O people of the household [of the Prophet (peace and blessing be upon him)], and to purify you a [thorough] purifying)(Al-Ahzab 33:33).
If staying in houses to prevent fitnah (i.e., temptation) is obligatory on the Mothers of the Believers, because the address is directed to them at the first place, the generality of `illah (i.e., effective cause of the ruling) in [to keep away the uncleanness from you] indicates that others are included, for Allah cannot be pleased with the uncleanness of any believing woman.
Abu Hurairah (may Allah be pleased with him) said, “Allah’s Messenger (peace and blessings be upon him) said, ‘The best of the men’s rows [in congregational Prayer] are the first and the worst are the last, while the best of the women’s rows are the last and the worst are the first.'”
An-Nawawi (may Allah have mercy on him) said, “Indeed, the last rows of the women attending [the congregational Prayer] with the Messenger were preferred due to their distance from intermingling with men, and the censure of the first women rows is for the opposite reason.
The Messenger said, “I have not left after me any fitnah more harmful to men than women.”
In this hadith, there is enough deterrence that would make anyone concerned about his faith avoid places of ruin and seek refuge in the fortress of pious caution.