Hello JJK,
You can use XLOOKUP with BYROW to search for an Item ID across multiple columns (E to M) and return the corresponding cost from column N.
Assuming your lookup value is in cell P2, try this formula:
=XLOOKUP(TRUE,BYROW(E2:M1000,LAMBDA(r,OR(r=P2))),N2:N1000,"Not found")
BYROW checks...