It looks like you confused secant with sine and cosecant with cosine. Remember that secant is hypotenuse over adjacent and cosecant is hypotenuse over opposite.