distance away from the capital of Kyoto, which had long been a target of violence, Azuchi's carefully chosen location allowed it a great degree of control over the transportation and communication routes of Oda's enemies. Before the Sengoku period (roughly the 16th century), most castles were called . Though most later castles were built atop mountains or hills, these were built from the mountains. Trees and other foliage were cleared, and the stone and dirt of the mountain itself was carved into rough fortifications. Ditches were dug, to present obstacles to attackers, as well as to allow boulders to be rolled down at attackers. Moats were created by diverting mountain streams. Buildings were made primarily of wattle and daub, using thatched roofs, or, occasionally, wooden shingles. Small ports in the walls or planks could be used to deploy bows or fire guns from. The main weakness of this style was its general instability. Thatch caught fire even more easily than wood, and weather and soil erosion prevented structures from being particularly large or heavy. Eventually, stone bases began to be used, encasing the hilltop in a layer of fine pebbles, and then a layer of larger rocks over that, with no mortar. This support allowed larger, heavier, and more permanent buildings. Early fortifications The first fortifications in Japan were hardly what one generally associates with the term "castles". Made primarily of earthworks, or rammed earth, and wood, the earliest fortifications made far greater use of natural defences and topography than anything man-made. These kōgoishi and chashi (チャシ, for Ainu castles) were never intended to be long-term defensive positions, let alone residences; the native peoples of the archipelago built fortifications when they were needed and abandoned the sites afterwards. The Yamato people began to build cities in earnest in the 7th century, complete with expansive palace complexes, surrounded on four sides with walls and impressive gates. Earthworks and wooden fortresses were also built throughout the countryside to defend the territory from the native Emishi, Ainu and other groups; unlike their primitive predecessors, these were relatively permanent structures, built in peacetime. These were largely built as extensions of natural features, and often consisted of little more than earthworks and wooden barricades. The Nara period (c. 710–794) fortress at Dazaifu, from which all of Kyūshū would be governed and defended for centuries afterwards, was originally constructed in this manner, and remnants can still