I am here talking in general & not related to a specific temple or place. Why are women not allowed to touch an idol of God or come near it? Is it related to their menstrual cycle? If so, why is it considered impure because of it?
During menses women are said to have an "irreversible religious impurity".
So it means, no matter what they do (like bathing, or achamana etc) they can't purify themselves in those days.
That's why their visit to temples or worshiping are considered futile and hence the restriction.
A same kind "irreversible religious impurity" also applies during the period of "Osaucham" to the members of a family where a death (or birth) has taken place.
Members of that family during that period are also prohibited from participating in any kind of religious activities irrespective of whether they are male or female members.
And, of course the question "why such impurity occurs?" can't have rational answers.