MIMM-X: Disentangling Spurious Correlations for Medical Image Analysis