For the pastry: Combine the flour, baking powder, and salt in a food processor. Pulse until the mixture resembles rough breadcrumbs.
Add the egg and 1 tbsp water and pulse again until a pastry forms around the blades of the processor; add a little more water, if needed, to bring it together.
Turn out the pastry and shape into a disc. Wrap in clingfilm and chill for 30 minutes.
After chilling, preheat the oven to 180°C (160° fan) | 350F | gas 4. Roll out the pastry on a lightly floured surface to 1/2 cm | 1/4" thickness and use it to line the base of a 20 cm | 8" fluted heart-shaped tin; if needed, let the excess pastry overhang the edges.
Prick the base of the pastry all over with a fork before lining with greaseproof paper and filling with baking beans. Blind-bake for 15 minutes.
Remove from the oven, discard the paper and beans, and return the pastry to the oven until dry to the touch on the base, about 5-10 minutes.
Remove to a wire rack and trim away any excess pastry with a serrated knife to leave a clean edge all the way around.
For the filling: Core and quarter the apples. Thinly slice on a mandoline set to a fine setting to yield thin, even slices; you can also do this freehand using a very sharp chef's knife.
In a large mixing bowl, toss the apple slices with the lemon juice, half the melted butter, and the caster sugar. Arrange them in overlapping layers inside the pastry case, working all the way up to the top right corner. Once you reach the corner, tightly overlap the slices to create a rosebud pattern.
Brush the top of the apples with the remaining melted butter and dust with 1 tbsp icing sugar.
Bake until the top of the apples are slightly dried out, about 15-20 minutes. Remove from the oven and immediately dust with the remaining icing sugar before serving.