Understand Rudyard Kipling's poem If
Solution 1:
How to understand "losing theirs and blaming it on you" in the first stanza? In particular, what do the pronouns "theirs" and "it" respectively stand for?
To "keep your head" means to remain calm, which is sometimes hard to do when the people around you ("about you") are in "panic mode." To remain calm in spite of their panic is therefore a virtue.
The word theirs, then, means their heads, and the pronoun it is a substitute for the phrase "having lost their heads." Kipling is saying it is good to remain calm even when people are blaming their panic (i.e., it) on you. His psychological insight into human behavior is quite perceptive.
Imagine a scenario in which only one person among many is calm while everyone else is in panic mode. Not comprehending why this lone person could possibly be calm, they attempt to get him to join them in their panic by saying, "Don't just stand there; do something!" When he fails to comply, they become suspicious of him and start blaming him for their panic.
Why do the first and the second stanzas end with colons?
One purpose of colons is to get the reader to stop, to pause for a moment and to anticipate what comes next. This is what Kipling is doing in part, I think. Additionally, the two colons serve to unite the first three stanzas in a continuous flow, as it were. When you read the last line of the first two stanzas, each line leads naturally into the first lines of the second and third stanzas.
Instead of the feeling of finality that comes after an average, typical declarative sentence, there is a feeling of continuity that connects stanza one to two, and two to three. Stanza three, on the other hand, has a feeling of finality and therefore does not need a colon.
Not having access to Kipling's original manuscript, which I assume would have been written by hand (Kipling described himself as "irretrievably committed to the ink-pot"), I do not know for certain if Kipling used colons in stanzas one and two or not. To me, their inclusion makes sense.
How to understand "Yours is the Earth" in the last stanza? What does "yours" stands for?
"Yours" means simply "belonging to you." Another saying which means essentially the same thing is, "The world is your oyster!" In other words, the world opens up for you, or to you, much as an oyster would, IF you exemplify the virtues the poem praises.
How many virtues do you find in the poem? There are quite a few, to be sure. Kipling is saying simply, if you embody these virtues, the world will be more accepting of you and what you have to offer. Put differently, the world ("the Earth") is yours! Generally, this is true, too, since the world generally prefers virtuous people.
Solution 2:
Awesome. What language are you translating it to, and have you checked if it hasn't already been translated to that language? It's a well-known and famous poem, after all.
That being said...
"losing theirs" harks back to the first line, where you are keeping your head (i.e. "staying calm") and others are losing their heads (i.e. "panicking"). "Theirs" is a pronoun for "their heads", or in other words, they are losing their heads while you are keeping yours. "It" is the act of their losing their heads that they are blaming on you, or at least, the situation that they are losing their heads over.
I have no idea. Ask Kipling. Oh, wait, he's dead. Sorry!
"Yours is the earth" is the same thing as saying "The earth is yours", but the latter doesn't fit the scansion, or Kipling wanted to use an uncommon (but still correct) word order for emphasis. Means that if you can do all that the poem says that you will be very successful in whatever you endeavor, be that in obtaining riches, power, or whatever it is might be your cherished goal. And, as Kipling said, you'd be a Man. Or Woman. A fully-actualized human being, in any event.
Edited to Add:
"If you can keep your head when all about you
Are losing theirs and blaming it on you,"
could be rendered non-poetically as
If you can remain calm when everyone else around you
are panicking and blaming the situation on you,"