RELATIONS DURING THE DAY OR IN FRONT OF A NER
Gemara
R. Yochanan: "In the evening she comes, and in the morning she returns" - amidst the detriment of Achashverosh we hear his praise, that he would not have relations during the day.
Nidah 17a - Rav Chisda: It is forbidden to have relations during the day - "V'Ohavta l'Re'acha Kamocha".
Question: How do we learn this from the verse?
Answer (Abaye): Perhaps he will see something repulsive in her, and he will despise her.
Rav Huna: Yisraelim are Kedoshim. They have relations only at night.
Rava: In a dark house it is permitted during the day;
A Chacham is always permitted; he covers with his garment to make it dark.
Question (Mishnah - Beis Shamai): Or they have relations in front of a lamp...(this should be forbidden for the same reason).
Correction: It means, or she checks the Edim (cloths used to check for Dam Nidah) by a lamp.
Question (Beraisa - Beis Shamai): Even though Chachamim disparage relations in front of a lamp... (they may have relations in front of a lamp).
Correction: It means, even though Chachamim disparage checking an Ed in front of a lamp (sunlight is much better)...
Question (Beraisa): Chachamim praised the household of Munvaz ha'Melech for three things: they would have relations during the day, they did Bedikos using cotton (some say - soft wool), and they considered snow to be Mekabel Tum'ah.
Correction: They praised them for checking Edim during the day.
Support: Presumably, this is correct. Even if relations during the day are permitted, it is not praiseworthy!
Rejection: It is praiseworthy (if done for the right reason). At night, perhaps he will be sleepy and she will not be appealing to him. (One of the nine Midos of despicable relations is when he despises her.)
Beitzah 22a - Question (Aba bar Marsa): May one extinguish a Ner (on Yom Tov) to permit relations?
Answer (Abaye): No; they should have relations in another room, or make a Mechitzah (between the Ner and the bed, or put a Keli over the Ner. If none of these are possible, relations are forbidden.
Question (Beraisa): One may not extinguish a burning piece of wood in order to save it; it is permitted to prevent the house or food from getting smoky.
Answer: The Beraisa is R. Yehudah (who permits Machshirim); I answered according to Chachamim, who forbid.
Kesuvos 56a - Question (Ravin): If there was Chupah but not Bi'ah, does she receive Tosefes Kesuvah?
Does Chibas Chupah acquire, or Chibas Bi'ah?
Answer: Rav Yosef taught that he wrote the Tosefes only for Chibah of the first night.
This is reasonable if Chibas Chupah acquires, for this is the first night. But if Chibas Bi'ah acquires, this is not only the first night!
Question: If it is Chibas Chupah, why did Rav Yosef specify the first night? Chupah can also be during the day!
Counter-question: You assume that Bi'ah is only at night. But Rava permits in a dark house during the day!
Answer: Rav Yosef teaches that it is normal to have Bi'ah at night.
Answer: Since Chupah is for Bi'ah, it is normal to do it at night.
Nedarim 20a (Beraisa): Eima Shalom (R. Eliezer's wife) was asked why her children were so beautiful.
Eima Shalom: My husband does not have relations with me at the beginning or end of the night, only at midnight.
He said that this is lest he (hear and) think about other women, resulting in children who are like Mamzerim.
Rishonim
The Rif (Shevuos 1b) brings the Beraisa of Eima Shalom and Rav Huna's teaching (Yisraelim are Kedoshim...)
Rambam (Hilchos Isurei Bi'ah 21:10): It is forbidden to have relations in front of a Ner. If on Shabbos there is a Ner burning and he has no other place, he should not have relations. Similarly, it is audacity for a Yisrael to have relations during the day. It is permitted for a Chacham, for he will not become habituated to this; he darkens with his cloak and has relations. This should be done only in case of great need. It is most Kodesh to have relations in the middle of the night.
Poskim
Shulchan Aruch (OC 240:11): One may not have relations in front of a Ner even if he darkens with his cloak.
Rema: However, it is permitted if he makes a Mechitzah 10 Tefachim tall in between, even though light goes through, e.g. a sheet. Alternatively, one may put a Keli over the Ner.
Magen Avraham (24): If light comes through he must darken with his cloak. It is not sufficient to point the Ner in another direction, or if the Ner is in a Keli. Bi'ah where it is light can cause the child to be epileptic, even if she is already pregnant. It is permitted to sleep in a canopy with a thick covering, even if it does not block all the light (for it is a Mechitzah). We are concerned for moonlight only if it shines directly on them.
Kaf ha'Chayim (69): Child mortality is mostly from epilepsy; if the child is not epileptic in his youth, he will be epileptic in his old age, if he reaches it.
Mishnah Berurah (40,42): The Mechitzah must be fastened so it does not move in a normal wind. If the Ner is in another room, this is better than a Mechitzah.
Shulchan Aruch (ibid.): it is forbidden to have relations during the day, unless it is in a dark house.
Kaf ha'Chayim (80): Some say that it is l'Chatchilah in a dark house. However, the Ari Zal says that a child conceived through relations during the day will be a Gilgul Neshamah.
Rema: A Chacham is permitted; he darkens with his cloak.
Magen Avraham (25,26): The Heter is for a Tzenu'a Chacham. It is only when there is great need, i.e. his Yetzer is very strong. However, Kesuvos 56a permits l'Chatchilah in a dark house.
Shulchan Aruch (EH 25:5): One may not have relations in front of a Ner even if he darkens with his cloak. If it was Shabbos and he has no other house, he should not have relations.
Source (Gra DH Afilu): We learn from Beitzah 22a.
Kaf ha'Chayim (OC 240:71): Olas Tamid and the Zohar permit darkening with a cloak even regarding a Ner. On Shabbos, when one may not extinguish or make a Mechitzah, one may rely on this, in particular if she will not become (and is not already) pregnant. They must be covered from head to toe, and the covering must be totally opaque.