Society in Shogunate Japan was organized around a strict feudal system. At the top was the Emperor, who was the nominal ruler but held little real power. Below the Emperor was the Shogun, who was the military commander and held the true power during periods of Shogunate rule. Local domains were ruled by Daimyo lords, who owed loyalty to the Shogun. Peasant farmers and artisans made up the bulk of society, with samurai warriors and merchants filling out the middle layers. All classes had obligations to those above them in the hierarchy, with Confucian ideals reinforcing the social order.