Why do Sepharadi keep a minimum of four days and Ashkenazi keep a minimum of 5 days before hefsek tahara? What is the underlying reason behind this difference?
The difference of minhagim is already mentioned in the Remah himself, see here. Rabbi Wosner in Shiurei Shevet Levi mentions that Yemenites wait 7 days.
The reason for waiting before doing a hefsek taharah is because there is a halacha that a woman who discharges live semen is considered tameh (just like any man who emits semen) and that such a tumah disrupts her counting of seven clean days. Therefore, since any semen that is older than three days is not considered viable, a woman must wait at least three days before beginning to count her seven clean days. This is true even if she did not have relations with her husband before becoming a Niddah (and even if he was out of town and couldn't have relations with her, but if he was forbidden to her, then some hold that those days of abstinence can count for these three days). In order to ensure that there were three full days (i.e. three periods of twenty-four hours, not calendar days), we make her wait four days according to the Shulchan Aruch. The Remah adds that since if they had relations during bein hashmashos one might make a mistake in counting the three days, one should be stringent and wait five days before counting the seven clean days (unless she became a niddah through virginal defloration, in which case even the Remah agrees she could wait a mere four days).
I hope I made this clear enough.
Reb Chaim HaQoton's answer is a very good explanation, but I would like to add a couple of details. As he says:
What this means is that a woman who has marital relations, and then has her period start, must wait 72 hours (three 24-hour days) from the time she had relations so that any semen that drips out from her is no longer viable, and then if she makes hefsek tahorah, she can start counting her seven clean days from the following night. These three 24-hour periods are called "four days," because they always comprise parts of 4 different calendar days: the day she had relations plus 3 calendar days following that. Only after those 4 days can she start counting seven clean days.
Reb Chaim HaQoton then goes on to write:
That's not strictly true. The Mechaber allows one to count 4 days including the day of her last martial relations, exactly as I have written above. (R' Ovadia Yosef is one contemporary posek who poskins l'halacaha that Sepharadim can count this way.)
The Rema brings a stringency: in order that women should have a uniform way of counting, the 4 (actually 5, as I'll explain below) days should start from the day that she first saw her period. I believe that all Ashkenazic poskim rule this way, as well as many contemporary Sephardic poskim (e.g. Rav Mordechai Eliyahu, Rav Ben Tzion Abba Shaul, and the poskim of the American Syrian community). It's this opinion that Reb Chaim HaQoton's answer reflects.
Reb Chaim HaQoton then writes a separate stringent custom that the Rema holds:
It's this stringency which is why (some) Sepharadim keep 4 days, and Askhenazim keep 5 days. It should be noted that many Sephardic poskim poskin by this opinion as well, and hold that one should keep 5 days. (e.g. Rav Mordechai Eliyahu, Rav Ben Tzion Abba Shaul, and the poskim of the American Syrian community.)
Of the Sephardic poskim I've seen and listed so far in this question, they either hold by both stringencies of the Rema, or they don't old by either. There is one other contemporary Sephardi posek who I've seen who holds by only one of these stringencies: The author of HaBayit HaYehudi holds that one can count 4 days, but they start from the day the woman sees her period.
All of this only matters if the woman stops bleeding before those 4 or 5 days up. If she bleeds for longer than that, then she can't start counting 7 clean days before she stops bleeding anyway anyway (though it's worth asking she'ilot about questionable bedikot after those 4 or 5 days, even if you're inclined to look at them and be stringent about the color). I was told by my rav (a talmid of R' Ovadia Yosef) that practically speaking I probably wasn't going to run into a situation where my wife could make hefsek tahorah on the 4th day.
Both the halacha that the seven days have to start after the woman stops bleeding, and the halacha of semen (requiring a minimum of 4 or 5 days before hefsek tahorah) have been adopted into hilchot niddah from the biblical requirements for a zavah. (A question that I see you've asked elsewhere on this site in a couple of different forms.) The reason for this is that it's difficult to distinguish between zavah and niddah bleeding.
If you're interested in great detail about the biblical sources of everything, Gemaras, and the opinions of the Rishonim and Acharonim, I recommend The Laws and Concepts of Niddah by Rabbi Zvi Sobolofsky, a Rosh Yeshiva at Yeshiva University. I've only skimmed that sefer myself, but here is a review.