In Hartshorne's proof of Bertini's theorem, given a linear system $|H|$, he defines the locus of "bad" hyperplanes $B_x$ for each point $x\in X\subset \Bbb P^n$ a projective variety, shows that this is a proper linear subset of $\{x\}\times |H|$, defines $B$ to be the union of all pairs $(x,H)$ so that $H\in B_x$, and then claims that "clearly $B$ is the set of closed points of a closed subset of $X\times|H|$".
I don't understand this. Clearly the statement "if a subset has proper closed intersection with all fibers of a map over closed points, then it's a proper closed subset" is false - consider the inclusion of a copy of $(\Bbb P^1\setminus\{0\})\times\{p\} \to \Bbb P^1\times\Bbb P^1$ followed by a projection. How can I rigorously see Hartshorne's claim?