Zant cursed her when she was a baby. When the twilight came and Link awoke as the hero, the curse would force her to kill him and follow Zant. But the gods, specifically the male counterpart of Farore, changed the curse so that she had the twilight power, but she wouldn't use it for evil