Preheat your oven to 180°C (350°F) and spread the shredded coconut evenly on a baking sheet. Toast for 5-7 minutes, stirring halfway, until golden and fragrant. Set aside to cool.
Chop the dark chocolate into small pieces and melt it gently over a double boiler or in short bursts in the microwave, stirring until smooth and glossy.
In a mixing bowl, combine the sweetened condensed milk, melted butter, and vanilla extract. Stir until smooth and well integrated.
Fold in the cooled toasted coconut into the wet mixture, ensuring an even distribution. If the mixture feels too thick, add a teaspoon of coconut oil to help it come together.
Press the coconut mixture firmly into the prepared baking pan, spreading it out evenly with a spatula. Chill in the fridge for 15 minutes to set slightly.
Pour the melted chocolate over the chilled coconut base, spreading it into an even layer. Gently tap the pan to smooth out the surface and remove air bubbles.
Sprinkle a pinch of sea salt flakes on top for added flavor contrast, if desired. Cover loosely and refrigerate for at least 2 hours, or until the chocolate is firm and the bars are set.
Once chilled, lift the bars out of the pan using the edges of parchment paper and cut into 16 equal squares with a sharp knife. Wipe the knife clean between cuts for tidy edges.
Serve the bars immediately or store them in an airtight container in the fridge for up to 5 days. For longer storage, wrap tightly and freeze, thawing before serving.