My proof goes as follows:
Suppose for contradiction that $\mathbb{Z}[x]$ is a PID. Then the ideal generated by any irreducible element is maximal. We know that $x^2+1$ is irreducible in $\mathbb{Z}[x]$ so $(x^2+1)$ should be maximal; $(x^2+1) \ne \mathbb{Z}[x]$ since $1 \notin (x^2+1)$. However, $(x^2+1) \subset (x^2+1, x)$, and the containment is strict since $x \notin (x^2+1)$. Thus $(x^2+1)$ is not maximal, and $\mathbb{Z}[x]$ is not a PID, and therefore also not an Euclidean domain.
I feel like I made a mistake somewhere because $x^2+1$ is also irreducible over $\mathbb{Q}$ so the same argument should work for $\mathbb{Q}[x]$, but I know that $\mathbb{Q}[x]$ is an Euclidean domain (and thus a PID) since $\mathbb{Q}$ is a field. Where is my mistake? Am I wrong to say $(x^2+1) \subset (x^2+1, x)$ when considered as ideals over $\mathbb{Q}[x]$?