7. If $\sin ^{2}\left(x+\frac{\pi}{12}\right)-\sin ^{2}\left(x-\frac{\pi}{12}\right)=-\frac{1}{4}$, and $x \in\left(\frac{\pi}{2}, \frac{3 \pi}{4}\right)$, then the value of $\tan x$ is . $\qquad$
II, 7. $-2-\sqrt{3}$.
$$
\begin{array}{l}
\text { Given } \sin ^{2}\left(x+\frac{\pi}{12}\right)-\sin ^{2}\left(x-\frac{\pi}{12}\right)=-\frac{1}{4} \\
\Rightarrow \cos \left(2 x-\frac{\pi}{6}\right)-\cos \left(2 x+\frac{\pi}{6}\right)=-\frac{1}{2} \\
\Rightarrow 2 \sin 2 x \cdot \sin \frac{\pi}{6}=-\frac{1}{2} \\
\Rightarrow \sin 2 x=-\frac{1}{2} .
\end{array}
$$

Given $x \in\left(\frac{\pi}{4}, \frac{3 \pi}{4}\right)$, we have $2 x \in\left(\pi, \frac{3 \pi}{2}\right)$.
Therefore, $\cos 2 x=-\frac{\sqrt{3}}{2}$.
Thus, $\tan x=\frac{\sin x}{\cos x}=\frac{2 \sin ^{2} x}{\sin 2 x}=-4 \sin ^{2} x$
$$
=-2(1-\cos 2 x)=-2-\sqrt{3} .
$$