I have the following system of congruences:
$$\cases{3x\equiv6\pmod{18}\\2^x \equiv1\pmod5}$$
After solving the two equations, I obtain: $$\cases{x\equiv2\pmod6\\x\equiv0\pmod4}$$ As per the Chinese remainder theorem, I expect the solution to be in the form $x\equiv x_0\pmod{12}$, however the following procedure, which is the one we've been taught at my course, leads to a result modulo $24$.
$$x\equiv2\pmod6 \land x\equiv0\pmod4 \iff x = 2 + 6k = 4h$$$$ k, h \in \mathbb{Z}$$
So we have the equation $$6k-4h = -2$$ which $k_0 = -1, h_0 = -1$ are a particular solution of. Therefore, $k = -1 +4y, h = -1 + 6y$, with $y \in \mathbb{Z}$.
Plugging, say, the equation for $k$ back into our equation for $x$, I get $x = 2 + 6(-1+4y) = 2 - 6 + 24y$, which means $x\equiv-4\pmod{24}$.
However, I was expecting an answer modulo $12$. What am I missing?