Bring both your ganache and salted caramel to room temperature, and set aside.
To make the dough for the pastry cups, use an electric mixer to cream the butter and sugar for about a minute. Add the egg yolk and vanilla and continue to mix until it's smooth. Sift in the flour and cocoa powder and mix only until it's well combined. Place the dough on a large sheet of plastic wrap and form it into a disk. Wrap it tightly and chill until it's firm, at least an hour.
Preheat the oven to 325 degrees, and remove the dough from the fridge. Lightly flour a clean work surface and use a rolling pin to roll the dough into an 18 X 12-inch rectangle, about ¼-inch thick. Add flour to the surface of the dough, and under it, as needed. Then use a 2-½-inch round cutter or a paring knife (the circles you cut don't have to be exactly perfect) to cut out 2 dozen rounds. Gently press the rounds of dough into mini-muffin pans or 2-inch tart pans. You may have to pleat the dough along the sides so that it becomes somewhat flat against the side surface. Gently poke each one all over with a fork. Chill the cups for about 20 minutes.
Remove the cups from the fridge and line each one loosely with foil and fill with dried beans, rice or pie weights. Bake in the preheated oven for 15 minutes. Remove the foil and beans and bake for another 5 minutes, until the dough looks dry. Place them on a cooling rack and do not fill them until they are at least room temperature.
Now let's assemble! If your salted caramel isn't a pourable consistency, heat it in a saucepan or in the microwave just until it's soft enough to pour. Then divide it evenly among the pastry cups. Let the cups sit at room temperature until the caramel sets, at least 45 minutes.
Like the caramel, if the ganache isn't pourable, warm it slightly in a saucepan or in the microwave -- only until it can be easily poured. Now pour the ganache to cover the surface of each caramel layer. Let this set at room temperature for about 2 hours. Sprinkle each one with the sea salt just before serving.