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.
Does passing wind from the anus affect ritual purity?
Ablution is nullified by the passing of wind from the anus, but washing the anus is not required as wind leaves no impurity.
Is there a solution to put an end to thinking of worries during prayer?
Firstly, make ablution after the time for prayer begins and busy yourself with remembering Allah, The Exalted, before the iqaamah (start of prayer).In order to become humbly submissive during prayer, you must perform prayer in congregation. After the prayer ends, stay in your place and read the post-prayer remembrances (Adhkaar) and make supplication to Allah, The Exalted.
Should a prayer performer who forgets to offer the middle Tashahod (saying ash-hadu anala ilaha ila-alah) offer Sujood As-Sahw (prostration of forgetfulness)?
He/she should offer two prostrations of forgetfulness at the end of the prayer. And Allah Knows Best.