7. Let $a_{1}, a_{2}, \cdots, a_{21}$ be a permutation of $1,2, \cdots, 21$, satisfying
$$
\left|a_{20}-a_{21}\right| \geqslant\left|a_{19}-a_{21}\right| \geqslant\left|a_{18}-a_{21}\right| \geqslant \cdots \geqslant\left|a_{1}-a_{21}\right| \text {. }
$$

The number of such permutations is $\qquad$ .
When $a_{21}=1$, there is only one case: $a_{1}=2, a_{2}=3, \cdots, a_{20}=21$, and similarly for $a_{21}=21$; when $a_{21}=2$, $a_{1}, a_{2}$ can be 1,3, and the rest must be in order, and similarly for $a_{21}=20$; when $a_{21}=3$, $a_{1}, a_{2}$ can be 2,4, and $a_{3}, a_{4}$ can be 1,5, and the rest must be in order, and similarly for $a_{21}=19$; $\cdots$;

When $a_{21}=11$, $a_{1}, a_{2}$ can be 10,12, $a_{3}, a_{4}$ can be 9,13, $\cdots$, $a_{19}, a_{20}$ can be 1,21. Therefore, the number of permutations that satisfy the condition is
$$
2\left(1+2+2^{2}+\cdots+2^{9}\right)+2^{10}=2\left(2^{10}-1\right)+2^{10}=3 \cdot 2^{10}-2=3070
$$