There are at least two well known proofs of the infinitude of primes (Euclid's original one and Euler's proof using L-series) and both of them can be extended to prove more general statements of the form: "There exist infinitely many primes of the form an+b" for specific $a,b$.
Here is another proof that there are infinitely many primes using algebro-geometric ideas:
Suppose there were only finitely many primes. Then $\operatorname{Spec} \mathbb Z$ would be an artin ring and in particular, any regular ring finite over it would be locally a PID and Artin, hence globally a PID.
In particular, this would imply that all (integrally closed) number rings have class number one which is clearly false, hence there would have to be infinitely many primes.
I don't believe this is a circular argument! (This idea is definitely not original to me but I sadly don't remember where I saw this argument. I very vaguely remember reading it from a post of David Speyer on this very site...)
Question: Does anyone see how to extend this to proving that there are infinitely many primes of the form $4n+1$ or $4n+3$? Or more general statements of this form.