8. Given $0<x<\frac{\pi}{2}, \sin x-\cos x=\frac{\pi}{4}$. If $\tan x+\frac{1}{\tan x}$ can be expressed in the form $\frac{a}{b-\pi^{c}}$ ($a$, $b$, $c$ are positive integers), then $a+b+c=$ $\qquad$
8. 50 .

Squaring both sides of $\sin x-\cos x=\frac{\pi}{4}$ and rearranging yields $\sin x \cdot \cos x=\frac{16-\pi^{2}}{32}$.
Therefore, $\tan x+\frac{1}{\tan x}=\frac{\sin x}{\cos x}+\frac{\cos x}{\sin x}$
$$
=\frac{1}{\sin x \cdot \cos x}=\frac{32}{16-\pi^{2}} \text {. }
$$

Thus, $a=32, b=16, c=2$.
Hence, $a+b+c=50$.