President Michel Temer of Brazil is in choppy waters, four months after the impeachment of his predecessor, Dilma Rousseff. His majority in Congress has shown signs of crumbling, his bill to cap spending passed the Senate by a much-narrower-than-expected margin, and some leaders in his own coalition are publicly voicing discontent. On and off protests over the past months against corruption and government spending cuts are a reminder of widespread discontent among Brazilians with their political class.