These Chocolate-Stout Cupcakes can be frosted and stored in an airtight container in the refrigerator up to a day ahead. Perfect for St. Patrick's Day, decorate them with the hearts just before serving.
Cream Cheese Frosting: Beat cream cheese with butter until fluffy, about 5 minutes. Add confectioners' sugar, 1 cup at a time, and beat until smooth, scraping down sides of bowl as necessary. Beat in vanilla and salt. Frosting can be stored in an airtight container in refrigerator for up to 5 days.
Cupcakes: Preheat oven to 375 degrees. Line two standard 12-cup muffin tins with baking cups. In a large heatproof bowl, whisk together flour, 2 cups sugar, baking soda, and salt.
Melt butter in a saucepan over medium heat. Whisk in cocoa powder, then stout. Increase heat to medium-high and bring mixture to a boil, whisking occasionally. Remove from heat; stir into flour mixture just until combined. Stir in eggs and sour cream.
Divide batter evenly among cups, filling each two-thirds of the way. Bake, rotating once, until cupcakes spring back and a tester inserted in centers comes out clean, 16 to 18 minutes. Transfer tins to wire racks; let cool completely.
Meanwhile, peel wide strips of lime zest with a vegetable peeler. Thinly slice zest into 1/8-inch-wide strips. Coat strips in remaining 2 tablespoons sugar; cut into 1/2-inch-long pieces.
Spread cupcakes with 2 cups frosting (reserve remaining for another use). Top each with 4 gold hearts (to form a shamrock) and 1 piece of sugared lime zest (to make a stem). Serve.