Preheat oven and prepare pan
Preheat oven to 350°F (175°C).
Line a 9×9-inch baking pan with parchment paper, leaving overhang on two sides. Lightly grease the parchment.
Cream butter and sugars
In a large bowl, beat softened butter, granulated sugar, and brown sugar together until light and fluffy (2–3 minutes with a hand mixer or stand mixer).
Add eggs and vanilla
Beat in eggs one at a time, mixing well after each addition.
Mix in vanilla extract.
Combine dry ingredients
In a separate bowl, whisk together flour, baking powder, baking soda, and salt.
Make the cookie dough
Gradually add the dry ingredients to the wet ingredients, mixing on low speed just until combined and no dry flour remains.
The dough will be soft and slightly sticky.
Press base layer into pan
Scoop about two-thirds of the dough into the prepared pan.
Press evenly into the bottom using your fingers, a flat measuring cup, or an offset spatula.
Prepare the cinnamon filling
In a small bowl, stir together brown sugar, melted butter, cinnamon, flour, and optional nutmeg/cardamom until crumbly but cohesive.
Add filling and top with remaining dough
Spread or swirl the cinnamon filling evenly over the dough base, leaving a small border around the edges.
Dot or crumble the remaining dough over the filling. Gently press to create a mostly even top layer, letting some filling peek through.
Bake the bars
Bake at 350°F (175°C) for 30–35 minutes, or until the edges are golden and the center looks set but still slightly soft.
Do not overbake; the bars will firm up as they cool.
Cool completely
Place the pan on a wire rack and let the bars cool completely in the pan before glazing (at least 1–2 hours).
This prevents the glaze from melting and soaking in.
Make the cinnamon glaze
In a medium bowl, whisk together powdered sugar, 2 tablespoons milk or cream, vanilla extract, cinnamon, and a pinch of salt.
Add more milk/cream, ½ teaspoon at a time, until the glaze is smooth and pourable but still thick enough to coat the back of a spoon.
Glaze and decorate
Drizzle or spread the glaze evenly over the cooled bars.
Add optional toppings (cinnamon-sugar, crushed cookies, caramel drizzle, nuts) while the glaze is still wet.
Let the glaze set for 15–20 minutes.
Cut and serve
Lift the slab out of the pan using the parchment overhang.
Cut into 16 squares (4×4) or desired size.
Serve at room temperature.