Is the marriage, which lacks a valid legal contract, a guardian, and a court registration, valid?
It is incumbent that a valid marriage contract be concluded in the presence of a guardian and two trustful witnesses, and it should be registered in the court to protect the rights of the wife. Actually, a valid marriage contract is what differentiates between sound marriage and fornication.
What is the ruling on having brotherly ties between a strange man and a strange woman, and is the former considered a Mahram (unmarriageable) to the latter?
Such a relation between a strange man and a strange woman is forbidden in Islam because it involves forbidding what Allah has allowed by marriage, and allowing what Allah has forbidden such as looking and the like. Such a relation doesn`t render any act lawful between them, thus they are forbidden to look at each other, have a Khulwah (seclusion), and travel together.
Is prayer nullified by having thoughts while performing it?
Prayer isn`t nullified by having thoughts while performing it, provided that the praying person offers all of its pillars and meets all of its conditions. However, the reward decreases significantly in the absence of reverence since a praying person is rewarded according to the attentiveness of his/her heart during prayer.
A woman used contraceptive pills, and her menses exceeded (15) days, is it permissible for her to fast?
The maximum of menstrual blood is (15) days, but if it exceeded that due to a medication, or the like, then it is Istihadah (bleeding outside the monthly period), and in this case she should perform Ghusl (ritual bath), pray, and fast. Moreover, she is obliged to make up for the missed fasting days which exceeded her regular menses. And Allah Knows Best.