the reason shirk is said to be unforgivable is because if you die with any major shirk, you're going straight to Hell forever
so basically, you have to repent sincerely before the time of death comes
other sins, Allah can choose to forgive you and if you still have tawheed, you won't be in Hell forever (and the Prophet SAWS can intercede for you)