The Laws of Bein HaMetzarim
The three week period between Shiva Asar B'Tammuz and Tisha B'Av (known as bein hametzarim) is a period in which many customs and restrictions are observed in order to commemorate the destruction of the first and second Beit HaMikdash. There is an incremental increase in these observances as Tisha B'Av approaches. Tisha B'Av is the culmination of these observances when the most intense form of mourning the loss of the Temples is observed.
There are four different time periods that bring about these increases in observances. Shiva Asar B'Tammuz marks the beginning of the bein hametzarim period, known colloquially as "the three weeks." Rosh Chodesh Av is the beginning of the period known as "the nine days." Another significant period is the week in which Tisha B'Av occurs (shavu'a shechal bo). The final time period is Tisha B'Av itself.
The Three Week Period
The concept of a three week mourning period was initiated by Daniel the Prophet (see Daniel ch. 10). Daniel mourned for a three week period over the destruction of the Temple (see the comments of R. Sa'adiah Gaon, Daniel 10:2). For this reason, some practices that were originally instituted for one of the more intense periods of mourning were adopted to be observed during this three week period.
Sefer Chasidim, no. 840, writes that there are people who don't recite a shehechiyanu on a new fruit during the three week period, though there are others who permit recitation of shehchiyanu on a Shabbat of the three week period. Maharil, Teshuvot Maharil no. 31, writes that if the beracha is one that can wait until after Tisha B'Av, such as a beracha on a new fruit, one should wait. However, if it is a beracha that cannot wait, such as the shehechiyanu recited at a Pidyon HaBen, one should recite it during this period. Shulchan Aruch, Orach Chaim 551:17, rules in accordance with the opinion of Maharil. Nevertheless, R. Ovadia Yosef, Yechave Da'at 1:37, rules that on Shabbat, one may recite a shehchiyanu on a new fruit or new clothes if they will enhance one's enjoyment of Shabbat.
R. Yitzchak Tirnau, Sefer Haminhagim, Chodesh Tammuz, writes that one should refrain from getting married or from cutting one's hair during this period. This position is adopted by Rama, Orach Chaim 551:2, 4. R. Yosef D. Soloveitchik, Shiurei HaRav Al Inyanei Aveilut V'Tisha B'Av, pp. 20-21, provides a basis for shaving one's beard during this period. He contends that the observances of the three week mourning period are patterned after the twelve month period of mourning that one observes when losing a parent. A mourner during this period may shave or cut his hair when he has reached a state that his friends note his unkempt appearance. Nowadays, when people shave on a daily basis, this state is attained after a day or two. Once that state is reached, one may shave his beard and continue to shave for the rest of the mourning period. However, this leniency will only apply to the three week period.
R. Moshe Feinstein, Igrot Moshe, Orach Chaim 4:21, prohibits listening to music during the three week period, even if it is recorded music. R. Ovadia Yosef, Yechave Da'at 6:34, permits music at a seudat mitzvah, such as a Pidyon HaBen, or a siyyum (completion of a tractate of Talmud).
The Nine Day Period
The Gemara, Yevamot 43b, quotes a Beraita that from Rosh Chodesh Av until the fast of Tisha B'Av one should minimize business activities and refrain from getting married, building, and planting. The Talmud Yerushalmi, Ta'anit 4:6, implies that the ruling of the beraita is based on the principle listed in the Mishna, Ta'anit 26b, "mishenichnas Av mema'atin b'simcha," when the month of Av commences, one should limit in rejoicing. Therefore, the mandate to refrain from business transactions, building and planting only applies to activities that bring one happiness. Tur, Orach Chaim 551, writes that there is a dispute among the poskim as to whether one may adopt the leniency presented in the Talmud Yerushalmi. Shulchan Aruch, Orach Chaim 551:2, follows the lenient position that activities that don't bring one happiness are permitted.
The Gemara, Baba Batra 60b, quotes the opinion of R. Yishmael Ben Elisha that after the destruction of the Beit HaMikdash, it would have been appropriate for the rabbis to place a ban on eating meat and drinking wine in order to properly mourn its destruction. However, since most of the tzibbur would not be able to abide by such a ban, the rabbis never instituted the ban. The Vilna Gaon, Biur HaGra, Orach Chaim 551:9, writes that this is the source for refraining from eating meat and drinking wine prior to Tisha B'Av. Although it is impossible to ban eating meat and drinking wine throughout the year, it is possible to refrain from meat and wine for a short period of time. Rambam, Hilchot Ta'aniot 5:6, writes that one should refrain from eating meat starting the week of Tisha B'Av. However, he writes that there are communities that refrain from eating meat starting on Rosh Chodesh. Tur, op. cit., writes that there are certain people who refrain from meat and wine starting on Shiva Asar B'Tammuz. Shulchan Aruch, Orach Chaim 551:9, quotes all three practices, and does not rule on the matter. Rama, ad loc., writes shechita should not take place during these nine days, apparently following the opinion that meat is not eaten during the nine days. Mishna Berurah, ad loc., writes that the common practice is to refrain from eating meat or drinking wine during the nine day period. Mishna Berurah notes that this practice does not apply on Shabbat.
Rama, Orach Chaim 551:10, writes that the tradition to refrain from eating meat and drinking wine does not apply to a seudat mitzvah. Rama includes a siyyum in his list of meals that constitute a seudat mitzvah. Rama adds that one should try to minimize the siyyum by only inviting a few guests. Nevertheless, R. Moshe Feinstein and R. Shlomo Z. Auerbach (cited in Nitei Gavriel, Hilchot Bein HaMetzarim 41:4), rule that if the one who completes the tractate eats in a communal dining room (such as a camp or hotel), all those who eat with him may participate in the siyyum.
Rambam, Hilchot Ta'aniot 5:6, writes that a tradition has been accepted by the Jewish people to refrain from bathing during the week of Tisha B'Av. Mordechai, Ta'anit no. 639, writes that it is proper to refrain from bathing starting on Rosh Chodesh Av. Shulchan Aruch, Orach Chaim 551:16, quotes both traditions. The Vilna Gaon, Biur HaGra, ad loc., notes that this tradition is based on the laws of mourning. Just as it is prohibited for a mourner to bathe, so too it is prohibited to bathe during the period of mourning the destruction of the Temple.
The Week of Tisha B'Av
The Mishna, Ta'anit 26b, states that during the week of Tisha B'Av it is prohibited to wash clothing and to cut one's hair. As noted earlier, Rama extends the prohibition of cutting one's hair to encompass the whole three weeks. Likewise, Rama, Orach Chaim 551:2 includes washing clothing in the activities that one should refrain from starting on Rosh Chodesh Av.
Shulchan Aruch, Orach Chaim 551:2 (based on the Gemara, Ta'anit 29b), rules that it is prohibited to wear clothes that are freshly laundered, even if they were washed beforehand. It is also prohibited to wash clothes that are going to be worn after Tisha B'Av. Rama, Orach Chaim 551:14, writes that one may wash children’s' clothing that the children regularly soil.
R. Soloveitchik, Shiurei HaRav pg.36, notes that the observances on Tisha B'Av are based on a combination of two factors. First, Tisha B'Av is a full-fledged fast-day comparable to Yom Kippur. As such, the five prohibited activities on Yom Kippur apply to Tisha B'Av. Second, Tisha B'Av is a day of intense mourning, and the observances reflect the mourning comparable to one who is observing shiva. Four of the observances apply to both the fast-day aspect as well as the mourning aspect (bathing, donning leather shoes, anointing, and marital relations). The prohibition to eat and drink is unique to the fast day aspect. The prohibition of learning Torah and the tradition of sitting on the floor are unique to the mourning aspect of Tisha B'Av.