Preheat oven to 350°F (175°C). Grease an 8x8 or 9x9-inch baking dish with butter.
Combine chopped pistachios, almonds (if using), and cinnamon in a bowl.
Place a sheet of gluten-free phyllo dough in the baking dish and brush with melted butter. Repeat with 6 more layers, buttering each one.
Spread half the nut mixture evenly over the phyllo.
Add 4-5 more layers of phyllo on top, buttering each one.
Sprinkle the remaining pistachio mixture evenly over this layer.
Add a final 4-5 sheets of phyllo dough, again brushing each with butter.
Using a sharp knife, cut into diamonds or squares.
Bake for 35-40 minutes until golden brown and crisp.
While baking, simmer honey (or sugarcane syrup), water, orange zest, lemon zest, vanilla, and cardamom for 5 minutes. Let it cool slightly.
Pour the warm syrup over the hot baklava as soon as it comes out of the oven. Let it soak for 2-3 hours before serving.