(Adding a second answer for the clarified question)
When you you used
sudo open http://google.com, the the system ran
as root, but
open is really just a client for MacOS LaunchServices,
which is still running as the logged-in user.
In fact Activity Monitor is showing you that the Safari instance opened
sudo open http:/google.com is not running as root, as the "User"
column is showing your username, not
You can, however, just invoke Safari directly on the command line with
sudo, by-passing Launch Services:
$ sudo /Applications/Safari.app/Contents/MacOS/Safari http://google.com
Now in Activity Monitor, you can confirm that it's running as