welcome to the board

This fails because OR("X","Y","Z") will be evaluated by itself and return a #value! error. OR is a logical formula that returns TRUE or FALSE, it doesn't allow you to look for X or Y or Z. You'll probably have to look for each value individually, and then return the minimum value

Sadly this would make your formula

=MIN(IFERROR(MATCH("X",OFFSET('Unit Data'!$C$2,0,$A$8-1,COUNTA('Unit Data'!$C:$C),1),0),""),IFERROR(MATCH("Y",OFFSET('Unit Data'!$C$2,0,$A$8-1,COUNTA('Unit Data'!$C:$C),1),0),""),IFERROR(MATCH("Z",OFFSET('Unit Data'!$C$2,0,$A$8-1,COUNTA('Unit Data'!$C:$C),1),0),""))