Adjust oven rack to middle position and preheat oven to 350ºF (175ºC). Line a 9- by 13-inch rimmed baking sheet with an 11- by 17-inch piece of parchment crosswise so the parchment overhangs the rim of the baking sheet by at least 2 inches. Grease parchment and baking sheet with nonstick cooking spray; set aside.
In a large bowl, whisk together all-purpose flour, rice flour or cornstarch, sugar, and salt. Pour melted butter into flour mixture and incorporate butter into dry ingredients until a cohesive dough just forms, about 1 minute.
Scrape dough into the prepared baking sheet and press dough into an even layer. Bake until fragrant and light golden, about 30 minutes. Remove shortbread from oven and set on wire rack to cool to room temperature, about 30 minutes.
In a 6-quart pot, melt butter over medium heat. Whisk in brown sugar and salt, cooking until sugar has melted and begins to bubble, about 5 minutes. Add heavy cream and whisk until a loose sauce forms. Bring to a boil and cook until sauce is thick, shiny, and registers 235ºF (113ºC) on an instant-read thermometer. Remove from heat and allow butterscotch to slightly cool, about 5 minutes.
Carefully pour butterscotch over cooled shortbread. Allow butterscotch to sit until warm room temperature, another 30 minutes, then refrigerate uncovered until just set, about 1 hour.
In a medium heat-proof mixing bowl, combine dark chocolate and butter. Set it over a saucepan of simmering water and heat, stirring occasionally, until chocolate and butter have melted and mixture is homogenous, about 3 minutes.
Remove shortbread from freezer and pour chocolate over shortbread, using an offset spatula to evenly coat butterscotch. Refrigerate until set, about 30 minutes.
Lift parchment overhang to gently remove millionaire’s shortbread from rimmed baking sheet and transfer to a cutting board. Cut bars into squares, rectangles, or desired shape. Serve cold or at room temperature.
