Chinese society during the Song dynasty (960–1279) was marked by political and legal reforms, a philosophical revival of Confucianism, and the development of cities beyond administrative purposes into centers of trade, industry, and maritime commerce. The inhabitants of rural areas were mostly farmers, although some were also hunters, fishers, or government employees working in mines or the salt marshes. Conversely, shopkeepers, artisans, city guards, entertainers, laborers, and wealthy merchants lived in the county and provincial centers along with the Chinese gentry—a small, elite community of educated scholars and scholar-officials.