Good game design has it's roots in building intuitive and fun connections between the various aspects of the game, something religion can provide, especially if it can tie every aspect of fortress life into an overarching activity that is larger than your dwarves or even your entire fortress.
The temple designation is the most intuitive connection. It ties the simple act of dwarves digging(carving out a space for a temple or shrine) into the evolution of civilization itself (religions and philosophies gaining/losing prominence).
To complete the circle, and give those activities meaning, the religions need to feed back and effect the fortress.
One form this could take would be a simple taboo, against a specific material in a specific item type. i.e. a religion with a taboo against eating a particular animal, would slightly complicate the process of feeding your dwarves, and force the player to provide a wider or specific variety of foodstuffs. Fun could ensue when the local cult starts refusing to eat kittens, leading to a shortage of non-cat foodstuffs, especially if you do all your baking with Kitty Crisco.
Notice that if the player does nothing, the cult just destroys itself and, once the tantrum spiral stops, ceases to be an issue; this only adds as much complexity as you're willing to put up with, as the goal of preserving/destroying religions(on the local or global level, your choice) doesn't have to interfere with the goal of keeping the fortress alive.
Likewise, followers of a religion could all demand a specific thing, ranging from just owning an idol of any sort, to wearing an amulet of a particular material(a use besides selling it, and possibly a reason to import a particular thing, that is less urgent than the current noble demands), to pouring out sacrificial wine, on their altar (which uses up booze and might offend dwarves or players who oppose waste). Very lucky players might find themselves with a cult that sacrifices kittens to their war god, a religion that is worth preserving, even if their war god is does not exist, or simply doesn't care about the kitten thing.
Another idea, that has more potential to annoy and us thus presented less forcefully, is for religions to occasionally venerate trades, to the point that their priests always have a particular job active, much like the dungeon master always has weaponsmithing and animal training. As the order manager get's refined this might not even do anything important. A less extreme doctrine might simply provide better work satisfaction to dwarves that follow the favored trade of their religion, and have other adherents be better disposed toward them.
These aren't enormous changes, but subtlety is the key here. Religion should be a pervasive thing, and have the potential to effect any aspect of fortress life. At the same time it's effects should be generally minor or slow, allowing the player to neglect it in the early stages of the fortress founding process. Above all religion should lend color to different fortresses, worlds, and even individual dwarves, making them more unique and filling them with life.
All this can easily be tied back into the goal of making late game play less dull, and more varied and challenging.