What is the ruling of Islamic Law on following the actions of the imam in prayer and how this following is achieved?
Praise be to Allah, and peace and blessings be upon our master, the Messenger of Allah.
The follower (ma'mum) is required to follow his imam in the actions of the prayer. This "following" (mutaba'ah) means that the follower performs each action of the prayer after the imam has begun it but before he has finished it. For example, the follower bows (in ruku') after the imam has reached the position of bowing, then rises after the imam has risen. The Prophet, peace and blessings be upon him, said: "The imam is only appointed to be followed, so when he says the takbir, say the takbir; and when he bows, then bow; and when he prostrates, then prostrate" (agreed upon, i.e., reported by both al-Bukhari and Muslim).
It is stated in Mughni al-Muhtaj (1/505): "Among the conditions of valid congregational prayer (iqtida') is following the imam in the actions of the prayer... meaning that following the imam is obligatory in the physical actions of the prayer, not in its verbal utterances... Complete following (kamal al-mutaba'ah) is achieved when the follower's beginning of an action comes after the imam's beginning of that same action, while the follower's beginning of the action precedes the imam's completion of it" — end of quote, with slight paraphrasing.
And Allah, the Exalted, knows best.
Is the one who gives up on marriage because he can`t afford it considered sinful?
Marriage is desirable, but one who can`t afford it isn`t considered sinful. However, he should supplicate to Allah, and seek His forgiveness.
What is the ruling on public street water if it gets on a person's clothes or body?
The default ruling is that public street water is pure (tahir). If one is certain of its impurity (najasa), then a small amount that gets on the lower part of a person's clothes or body is overlooked (excused). And Allah the Almighty knows best.
What is required of one who doubts the number of rakʿāt during prayer?
All praise is due to Allah, and peace and blessings be upon our master the Messenger of Allah ﷺ.
If a person doubts the number of rakʿāt he has prayed, he should build upon the lesser number, as that is what he is certain of. He should then perform the prostration of forgetfulness (sujūd al-sahw) before the final salām at the end of the prayer. ʿAṭāʾ ibn Yasār narrated that the Messenger of Allah ﷺ said: "When any one of you is in doubt during his prayer and does not know whether he has prayed three rakʿāt or four, let him pray one more rakʿah and then perform two prostrations while seated before the salām. If the rakʿah he prayed was a fifth, these two prostrations will make it even; and if it was the fourth, then the two prostrations serve as a humiliation for the devil." (Reported by Abū Dāwūd.)
It is stated in al-Muqaddimah al-Ḥaḍramiyyah — one of the foundational texts of the Shāfiʿī school: "If one doubts whether he has prayed three rakʿāt or four, he is obliged to build upon the lesser number."
However, if such doubt recurs repeatedly and reaches the level of obsessive whispering (waswasah), he should not build upon the lesser number in that case — rather, he should build upon the greater number. And Allah the Almighty knows best.