Collisions and symmetries in the periodic $N$-body problem