  We construct a general theory of $Z_2$ topological phase transitions in
two-dimensional systems with time-reversal symmetry. We investigate the
possibilities of $Z_2$ topological phase transitions at band inversions at all
high-symmetry points in $k$-space in all the 80 layer groups. We exclude the
layer groups with inversion symmetry because the $Z_2$ topological phase
transition is known to be associated with band inversions with an exchange of
parities. Among the other layer groups, we find 21 layer groups with
insulator-to-insulator transitions with band inversion, and this problem is
finally reduced to five point groups $C_3, C_4, C_6, S_4$, and $C_{3h}$. We
show how the change of the $Z_2$ topological invariant at a band inversion is
entirely determined by the irreps of occupied and unoccupied bands at the
high-symmetry point. For example, in the case of $C_3$, we show that the $Z_2$
topological invariants change whenever the band inversion occurs between two
Kramers pairs whose $C_3$ eigenvalues are $\{e^{\pi i / 3}, e^{-\pi i / 3}\}$
and $\{-1, -1\}$. These results are not included in the theory of
symmetry-based indicators or topological quantum chemistry.
