In a large dutch oven or heavy bottomed pot, combine brown sugar, molasses, spices and butter.
Cook over medium heat, stirring constantly until butter has melted.
Turn off the heat and stir in the baking soda. The mixture will foam up.
Once the foaming subsides some, stir in the cocoa.
Add the egg, mixing vigorously so that it does not cook before you get it mixed in.
Once the egg is incorporated, add in the flour a little bit at a time
When you reach the point your arms are too tired to keep stirring in flour, transfer to a lightly oiled work surface ( I did this on my marble countertop) or to a very large bowl. Knead in remaining flour until the dough is smooth.
Cover the dough and let it rest until it's cooled down. At first the dough will be very shiny from the melted butter, but as it cools and the butter rehardens, the dough will start to look more matte.
Form the dough into 3-4 disks and wrap all but one so they don't dry out.
Roll out the first disk between two sheets of parchment paper to about 3/16th-1/8th inch thickness. You'll want your sheets to be the same size as the cookie sheet you'll be using.
Cut out cookies then remove the excess dough but don't move the cookies. Transfer your parchment (with cookies) onto a cookie sheet and place in the freezer for 60 minutes. (Feel free to crowd the pan for freezing)
Preheat oven to 350F
Continue rolling out cookies with remaining dough, repeating steps above.
When ready to bake, take your cookies out of the freezer and reposition them so they don't spread into each other while baking.
Bake cookies 8-10 minutes. This is a guide! If you're cookies are rolled thick they will puff up and spread more and take longer. Thinner, smaller cookies may only take 6-7 minutes. My suggestion is to bake a few first to test the timing in your oven so you don't ruin a whole batch!
How to Make Royal Icing
With a mixer, whip the egg whites with the cream of tartar until stiff peaks form.
Slowly add in powdered sugar, whipping between additions.
Once all the sugar has been added, thin with water one teaspoon at a time to the desired consistency. (see notes)
Fill a pastry bag loaded with a number 2 or 3 piping tip with royal icing and place them in a large glass with a moistened paper towel in the bottom.
Once cookies have cooled completely, have fun decorating! Make sure to leave the cookies overnight to dry.
Keep unused icing in the refrigerator.
Some stores carry pasteurized eggs, but many do not. You can make them at home on the stovetop or the sous vide method. I'll be honest, I don't use pasteurized eggs, but for children, elderly, sick or pregnant cookie eaters safety is a must.
Make sure to not boil the molasses mixture when melting the butter. You don't want to cook the water out of the sugar. That results in hard, rather than soft and chewy cookies.
The thicker these cookies are rolled, the softer they turn out. However the thicker the cookies are, the less they hold their shape during baking. If you'd like soft cookies, I suggest cutting out rounds and then decorating them with vanilla buttercream frosting rather than royal icing.