We learned that the beauty of Adam came from the glow of the supernal knot of the brightness that shines, being the secret of the glow of Aba, since he had a Neshamah of the Neshamah of Aba of Atzilut. The beauty of Eve was such that no creature could look at her, since her Neshamah of Neshamah of Ima of Atzilut. Even Adam did not look at her until the time they sinned and their beauty was removed. Only then could Adam look at her and recognize her for the purpose of mating. This is the essence of the verse, "And Adam knew his wife again" (Genesis 4:25). He knew her in everything; he knew her through mating, that is, "knew," in that he recognized her and saw her.
We learned that is it prohibited for a man to look at the beauty of a woman to prevent him from acquiring bad thoughts and being torn into another thing, meaning that a drop of semen will be torn from him in vain. So did Rabbi Shimon behave when he came to the city. The friends followed him, and when he saw beautiful women, he lowered his eyes and told the friends not to look.
Whoever looks at the beauty of women during the day will have those thoughts coming to him at night. When those evil thoughts come upon him at night, he transgresses, because "nor make to yourselves molten Elohim." For the Klipot [empty shells] that nurture from this are called 'molten Elohim'. Furthermore, if he is mating with his wife when he has these evil thoughts, the children born are called 'molten Elohim' (Leviticus 19:4). Therefore, it is written: "Turn not to idols, nor make to yourselves molten Elohim." Rabbi Aba said: It is prohibited for a person to look at idols and women of the nations, to derive any benefit from them, or to seek a cure from them, as it is forbidden to look at a forbidden place.