8. In a $5 \times 5$ matrix, each element is either 0 or 1, and it satisfies: the sum of the elements in each of the five rows is equal, but the sum of the elements in the five columns are all different. The number of such matrices is $\qquad$
Given the matrix where the sum of all elements is $S$, then $0+1+2+3+4 \leqslant S \leqslant 1+2+3+4+5$ $\Rightarrow 10 \leqslant S \leqslant 15$, and $S$ is a multiple of 5, thus $S=10$ or $S=15$. When $S=10$, each row has 2 ones. Considering the columns with sums of 3 and 4, if all 3 ones are in the rows with 4 ones, there are $C_{4}^{3}$ arrangements; if only 2 of the 3 ones are in the rows with 4 ones, there are $C_{4}^{2} \cdot C_{3}^{2}$ arrangements. In this case, the number of corresponding matrices is $A_{5}^{5} \cdot C_{5}^{4} \cdot\left(C_{4}^{3}+C_{4}^{2} \cdot C_{3}^{2}\right)=13200$. When $S=15$, each row has 3 ones, and similarly, the number of corresponding matrices is also 13200. In summary, the number of matrices that satisfy the conditions is 26400.