Soften the margarine to room temperature, preheat the oven to 200 degrees.
Pour the flour into a separate bowl, add baking powder and margarine, mix, then add salt, vanilla sugar and granulated sugar, mix again with a mixer until the dough is smooth. Wrap the dough in cling film and leave in the refrigerator for half an hour.
After the time has passed, roll out the dough into a thin cake, then place it back in the refrigerator.
Pour water over the sugar and place on the stove, bring to a boil and boil for about five minutes, then add citric acid and place the pan on cold water and stir. Beat the resulting mass until it reaches a white consistency. Place the resulting cream in the refrigerator.
Remove the dough from the refrigerator and place it in the preheated oven for 15-20 minutes. Remove the dough from the oven, divide into 2 parts and brush one of them with apple jam. Cover the first with the second part of the dough.
Remove the cream from the refrigerator and set aside a few spoons. Microwave the rest for 5 seconds and add cocoa to the rest and microwave again.
Cover the top layer of the cake with white cream, and make a pattern with dark cream. Cut off excess edges from the cake and serve.
Use a cookie cutter to cut out shapes such as stars or hearts from the cakes.