Russian court clears way for Putin to stay in power