What is the ruling on the cessation of blood after (40) days from delivery, but later continued sporadically during two days of Ramadan?
Once postpartum bleeding (Nifas) ceases, and the woman is certain that it won`t reoccur, then she becomes ritually pure and so she is free to make Ghusl (purificatory bath), pray, and fast. If the bleeding reoccurs before fifteen days from its cessation, and before the end of (60) days after delivery, then the ruling on postpartum bleeding is effective, and her fasting and prayer are null and void, thus she must make up the fasting that she missed and not the prayer during those particular days.
Is the marriage contract considered valid if concluded at home by the marriage official (Ma`zon)?
Yes, it is valid as long as it is registered at the court.
Is it permissible for a wife to leave her house without obtaining the permission of her husband, and not to come back unless he divorces her co-wife?
It is forbidden for the wife to leave without obtaining her husband`s permission, and it is impermissible for her to ask him to divorce her co-wife as this inflicts harm on the latter and such an act is forbidden in Islamic law.
I used artificial nails on my wedding night, but I was surprised to find out that they require at least a week to remove. However, I performed all my prayers during that period. What is the ruling on those prayers?
If these nails prevent water from reaching one's skin then your prayer are invalid and obliged to redo all of them. And Allah Knows Best.