Let $(1+\sin t)(1+\cos t)=\frac{5}{4},(1-\sin t)(1-\cos t)=\frac{m}{n}-\sqrt{k}$, where $k, m, n$ are positive integers, $m$ and $n$ are coprime, then $k+m+n=$ $\qquad$
8. 27 .

Let $(1-\sin t)(1-\cos t)=x$, then $\frac{5}{4}+x=2+2 \sin t \cos t$, which means $x-\frac{3}{4}=2 \sin t \cos t$. Also, $\frac{5}{4} x=\left(1-\sin ^{2} t\right)\left(1-\cos ^{2} t\right)=\sin ^{3} t \cos ^{2} t$, so $\bar{x} x=\left(x-\frac{3}{4}\right)^{2}, 16 x^{2}-104 x+9=$ 0, solving for $x$ gives $x=\frac{13}{4} \pm \sqrt{10}$.
Since $x \leqslant 4$, $x=\frac{13}{4}+\sqrt{10}$ is discarded, so $x=\frac{13}{4}-\sqrt{10}, k+m+n=27$.