CHAFIFAH MUST BE CLOSE TO TEVILAH [Nidah: Tevilah: Chafifah]
Gemara
(Rav Huna): A woman may do Chafifah (comb or wash her hair or her entire body) on Sunday and immerse on Tuesday, just like one may immerse on Motza'ei Shabbos, two (Halachic) days after Chafifah on Erev Shabbos;
She may (do Chafifah on Sunday and) immerse on Wednesday, just like when Yom Tov follows Shabbos, Tevilah is three days after Chafifah (on Erev Shabbos);
She may immerse on Thursday, just like when Rosh Hashanah follows Shabbos, Tevilah is four days after Chafifah.
(Rav Chisda): When it is possible (to do Chafifah on Leil (the night of) Tevilah), she does so. When it is impossible, she cannot. We do not say 'just like'.
(Rav Yemar): We say "just like," except for immersion four days after Chafifah on Motza'ei Yom Sheni of Rosh Hashanah when Rosh Hashanah follows Shabbos, for the Chafifah may be done that night before immersing.
(Mereimar): The Halachah follows Rav Chisda and Rav Yemar.
Question: May a woman do Chafifah at night and then immerse?
Answer #1 (Mar Zutra): It is forbidden.
Answer #2 (Rav Chinena of Sura): It is permitted.
Question (Rav Ada): A case occurred in which the Reish Galusa quarreled with his wife (during the day. She was due to immerse that night). Rav Nachman bar Yitzchak went to appease her that night.
The wife: What is your rush? I will immerse tomorrow!
Rav Nachman understood that she thought that she cannot immerse tonight because she had not done Chafifah.
Rav Nachman: (You can do Chafifah now and immerse tonight, for) surely you have slaves (to heat the water), basins and a seat (to sit on at the time)!
(Rava): A woman who will immerse on Motza'ei Shabbos does Chafifah on Erev Shabbos.
Question (Rav Papa): A letter (in the name of R. Yochanan) forbids this;
It is difficult enough to allow Chafifah during the day before immersion at night. It should be right before Tevilah!
Rava retracted, and ruled like R. Yochanan.
The Halachah is, she may do Chafifah during the day and immerse at night.
The Halachah is, she must do Chafifah at night.
Question: These Halachos contradict each other!
Answer: One discusses when it is possible. The other discusses when it is impossible.
Rishonim
Rambam (Hilchos Mikva'os 2:16): Ezra enacted that a woman be Chofef her hair and afterwards immerse. If she can do Chafifah at night and immerse immediately, this is praiseworthy. In pressed circumstances or due to illness, she may do Chafifah even on Erev Shabbos and immerse on Motza'ei Shabbos.
Rosh (Hilchos Mikva'os 37): The Gemara answered that one Beraisa discusses when it is possible, and the other discusses when it is impossible. Rashi explains that it (Chafifah during the day) is possible on a weekday. It is impossible when she immerses on Motza'ei Shabbos. Chafifah during the day would have to be from Erev Shabbos. Therefore, she does Chafifah on Leil Tevilah. If so, if Yom Tov is on Motza'ei Shabbos, she may not do Chafifah on Erev Shabbos and immerse Motza'ei Shabbos. Rashi explains that with difficulty, Chachamim permitted distancing the Chafifah from the Tevilah. It is better during the day only due to concern lest if she does Chafifah at night, she will not do it properly, for she rushes to return home. To distance so much, from Erev Shabbos to Motza'ei Shabbos, is forbidden. It is better to delay her Tevilah.
Tosfos (68a DH Kach): Above we ruled like Rav Chisda, like Rav Yemar explained. This did not stand, for here do not allow Chafifah on Erev Shabbos and Tevilah on Motza'ei Shabbos! We can say that Rav Chisda discussed Tevilah on Motza'ei Shabbos that is Yom Tov, therefore she does Chafifah on Erev Shabbos, and does not lose her Tevilah. It seems that Rashi permits Chafifah at night, just it is better during the day, lest she rush. The Gemara supports this. It says 'she immerses during the day', and not 'only during the day.' Also the episode with the Reish Galusa's wife connotes that Chafifah is permitted at night. It is unreasonable to distinguish because there they quarreled. That episode was brought to teach about Chafifah at night. This connotes the same applies without Ones.
Rosh: The She'altos (Acharei Mos 96) explains that when it (Chafifah) is possible at night, i.e. on a weekday, she should do so. When it is impossible at night, i.e. on Shabbos or Yom Tov, she does Chafifah during the day. Even if Yom Tov is on Thursday and Friday and her Tevilah is on Shabbos, she does Chafifah on Wednesday, and does not miss her Tevilah. The Sugya connotes unlike this. The Gemara asked whether she may do Chafifah at night and immerse at night. This connotes that it is better during the day, lest she rush at night for she wants to hurry home. However, also according to the She'altos it is a good custom that women begin Chafifah during the day and engage in it until dark, and then immerse. Also, even though they did Chafifah (at home), they are stringent and take a comb to the Mikveh and comb there.
Tosfos: The She'altos forbids only to do Chafifah during the day and leave the bathhouse before night. If she stays until night, it is a long Chafifah, for the entire time she engages in cleaning her body and hair. She should be blessed!
Rosh: We ruled that she does Chafifah during the day, i.e. Erev Shabbos, and immerses at night, i.e. Motza'ei Shabbos. We also ruled that Chafifah is only at night, i.e. Motza'ei Shabbos. We answer that when this is possible, i.e. Motza'ei Shabbos is not Yom Tov, she does not distance the Chafifah to Erev Shabbos. When it is impossible, i.e. it is Yom Tov, she does Chafifah on Erev Shabbos. Women do so nowadays. They are careful on Shabbos not to feed their children or engage in matters that can lead to a Chatzitzah.
Poskim
Shulchan Aruch (YD 199:3): L'Chatchilah, Chafifah must be close to Tevilah. The proper custom is that she begins Chafifah during the day, engages in it until dark, and then immerses. Similarly, it is a proper custom that even though she did Chafifah, she takes a comb with her to the Mikveh and combs there.
Beis Yosef (DH Ha): The Rosh says that the Sugya is unlike the She'altos. We asked whether she may do Chafifah and Tevilah at night. This connotes it is better during the day. Also the Mordechai brings from Sefer ha'Terumah that it is good to enter the bathhouse long before night, so she can do Chafifah without rushing, and she does not leave until dark.
Beis Yosef (DH v'Da): The Rashba rules like the She'altos. L'Chatchilah, she must do Chafifah and immerse at night, lest something get tied to her hair between Chafifah and Tevilah. The Rambam agrees. The Ran (Shevu'os 7a DH Lo) says that the Rif agrees.
Taz (5) and Gra (12): The proper custom of the Shulchan Aruch is due to the argument of Rashi and the She'altos.
Shach (6): The Sugya and Sifri are like Rashi, that Chafifah during the day is better. Therefore, if her Tevilah is on Motza'ei Shabbos, or even on Motza'ei Yom Tov when Yom Tov is after Shabbos, she does Chafifah on Erev Shabbos, since it is possible during the day. However, if two days of Rosh Hashanah or Yom Tov of Chutz la'Aretz are after Shabbos, we do not allow three days between Chafifah and Tevilah. Then, Chafifah is on Leil Tevilah. To answer the contradiction of Halachos, the Gemara merely said 'here it is possible, here it is impossible.' It relied on the rulings of Rav Chisda and Rav Yemar above. I say that Rashi agrees. He said that it is impossible on Motza'ei Yom Tov, i.e. like we said above that it is impossible (when two days of Yom Tov follow Shabbos). If not, it is possible from Erev Yom Tov. We need not reject the Sugya above, like Tosfos and the Poskim must. Also, Rav Huna, Rav Chisda, Mereimar and Rav Yemar connotes that women used to do Chafifah on Erev Shabbos or Erev Yom Tov and immerse on Motza'ei Shabbos. They brought proofs from this custom, just Rav Chisda does not learn what is possible from what is impossible. Rav Yemar ruled like this. How can we say that our Sugya argues with the Halachah and practice of the above Sugya?! Why didn't the Poskim explain Rashi this way?! In any case, in practice she bathes in hot water on Erev Shabbos or Erev Yom Tov and does Chafifah, and do so again on Leil Tevilah if it is a weekday.
Shach (6): During the week, it is proper to begin Chafifah during the day and engage in it until night. The Gemara concludes that when Tevilah is three days after Chafifah, she does Chafifah on Leil Tevilah. We can say that this means that Chafifah on Erev Shabbos is not enough. Rather, she must do Chafifah on Leil Tevilah and also on Erev Shabbos, since Chafifah during the day is better. Our women do Chafifah on Erev Shabbos and also on Leil Tevilah, so we should not distinguish between when two days separate Chafifah and Tevilah and when three days separate, lest they come to err. Sha'arei Dura says so. Mereimar ruled like the stringencies of Rav Chisda, to do Chafifah on Erev Shabbos, and of Rav Yemar, to do Chafifah on Leil Tevilah. The Poskim did not distinguish between one or two days of Yom Tov after Shabbos, for in both cases she does Chafifah before Shabbos and also on Leil Tevilah. The Maharshal rules like those who argue with Rashi, but he did not give a proper reason.
Gra (11): Most Poskim hold like the She'altos.
Gra (13): Rashi (Bava Kama 82b DH Chafifah) says that Chafifah is with a comb.
Rema: In pressed circumstances that she must to Chafifah during the day, or she cannot do Chafifah during the day and she must do it at night, she may do so, as long as she does not rush and does it properly.
Taz (6): A case when she must do Chafifah during the day is when she is going away, and she will not have hot water at night, or other Onesim. Even the She'altos permits Chafifah during the day when there is Ones. Similarly, even Rashi permits Chafifah at night when there is Ones. Chachamim were not insistent (about the time of Chafifah) to postpone Tevilah, just they gave the optimal time. In pressed circumstances, we permit Chafifah during the day. Surely at night she must check her entire body before Tevilah, just like we say (Sa'if 6) about the days between Chafifah and Tevilah.
Shach (9): If it is possible during the day and at night, clearly she should do so.