Acheologists have found megalithic stones in Bali oreiented towards one of the 3 main mountains (Gunung Agung, Gunung Batukaru, Gunung Batur), which suggests the ancient Balinese were looking at more than the view when they designed their structures.
However one aspect of Balinese layout that persists today, is the Hindu concept of Tri Loka. Tri Loka insists on a sacred orientation, based on the kaja-kelod axis. According to Tri Loka, kaja is towards the mountains, the home of the Gods, kelod is towards the ocean, home of the demons and evil forces. The land between the mountains and the ocean is where the people live, trying their best to balance good and evil.
This whole concept fits nicely with the Hindu idea of dharma, everything in the world has its place and harmony will only be achieved if things stay balanced. This concept is a skeleton key to Balinese mentality (you run over my cow, I attack you, now everything is cool again).
The Hindu idea that the universe is divided into 3 parts (Tri Loka) which are the realm of the Gods, the realm of the humans and the realm of demons, transfers over to temple layout. In many cases, certianly with the larger temples, there are 3 courtyards, outer, middle and inner. The sacredness and function of each is designed to show that as one gets further in, one passes from the realm of humans to the realm of the Gods.
Temple shrines, tall cement structures in honor of a particular diety, display Tri Loka vertically. The roof is the realm of the Gods, the mid section is aligned with where people will be looking, and the base is designated for demons.
The Balinese incorporated wave after wave of ideas into their version of Hinduism, including the sacred mountain or Meru. The Hindu-Budhhist concept is that the sacred mountain (Semeru or Meru) is the center of the universe and the home of the Gods. The Baliense took to this idea and made Gunung Agung their own Meru. Tri Loka came to Bali in the 11th Century and to the exisiting kaja-kelod axis was added another, the east – west (if you are in Kuta) kangin – kuah axis.