All three triangles are similar (the two smaller ones and the larger one). 20 is the larger hypotenuse. Not sure why you think 16/12 is useful. For both the red and blue triangles, you need to relate the unknown a or b to the hypotenuse (of the red or blue triangle), so the useful side ratios for the larger triangle would be
relevant leg / hypotenuse
Tbh, you can interpret the relevant side ratios in terms of simple trig if you find that easier. Your 16/12 is tan(), whereas the releavant trig terms for the red and blue trianges are sin() and cos(). Sometimes its worth drawing the three triangles as separate ones, with the same orientation, so the correct side ratios are obvious