Start by preheating your oven to 350°F (175°C). Line two 8-inch round cake pans with parchment paper circles and lightly grease the sides. If you prefer taller layers, you can skip greasing the sides to help the batter grip and rise — though if you're concerned about sticking, greasing is recommended.
To make the cake batter, whisk together the flour, baking powder, baking soda, salt, and spices in a medium bowl until well combined and evenly distributed.
In a large mixing bowl, combine the grated carrots, light brown sugar, granulated sugar, and eggs. Using a handheld electric mixer on medium speed, beat the mixture until fully blended. Add in the sunflower oil, plain yogurt, and maple syrup, then beat again until everything is smooth and well incorporated.
Next, add half of the dry ingredients to the wet mixture and mix on low speed just until combined. Add the remaining flour mixture and continue mixing on low only until just blended — be careful not to overmix. If you're including walnuts and raisins, fold them in at this stage until evenly dispersed throughout the batter.
Evenly divide the batter between the two prepared pans and bake for 28 to 32 minutes, or until the cakes are golden brown and a skewer inserted in the center comes out clean. Once baked, place the pans on a wire rack and let them cool for 15 minutes. Run a knife around the edges of each pan to loosen the cakes, then carefully invert them onto the rack and allow them to cool completely.
To prepare the frosting, beat the softened unsalted butter with 1 cup (120g) of sifted icing sugar for about 2 minutes until the mixture is smooth, light, and fluffy. Cut the softened cream cheese into cubes and beat it in gradually, one tablespoon at a time, until fully incorporated and the mixture becomes thick, pale, and airy. Add the lemon juice and vanilla extract, beating until blended. Finally, beat in the remaining ⅔ cup (80g) of icing sugar and continue whipping the frosting until it’s smooth, creamy, and very fluffy.
Assemble the cake by placing one cake layer on a serving plate or cake stand. Spread about 1 cup of the cream cheese frosting evenly over the top, leaving a ½-inch border around the edges. Set the second cake layer on top and press down gently to secure it. Apply a thin layer of frosting over the entire cake to create a crumb coat, then chill it for 15 minutes to set. After chilling, spoon the remaining frosting on top and spread it evenly from the center outward to the edges and down the sides, or leave the sides semi-naked for a rustic look, using an offset spatula to create decorative swoops on top.
For decoration, reserve about 3 tablespoons of frosting. Place 2 tablespoons in a small bowl and tint it with orange food coloring. Place the remaining tablespoon in another bowl and tint it green. Transfer each colored frosting to a small zip-top plastic bag, snip a corner off, and pipe little decorative carrots on top of the cake (refer to the video tutorial if needed). Finish by sprinkling chopped walnuts or pecans over the top and serve with pride.