For the first problem, I think your vacuum is low. The low vacuum cannot power the brake booster for too long. If you step on the brake pedal too many times (using up the vacuum power) before the final stop, it will happen and you possibly may not be able to shut off the engine at this time. To make the matter worse, braking reduces the engine rpm causing weaker vacuum to the brake booster. You have to find out if your vacuum pump is bad or you have a vacuum leak.
For the second problem, a sinking brake pedal is a sign of bad master cylinder.