I receive .docx or .doc documents that I need to convert to a PDF. However, I frequently lose both formatting and text when I open the document in Pages. I don't understand how to fix the problem.
Probably, the description of the problem is incomplete. It is unlikely that plain text is lost, provided plain text is represented as plain text. This implies that what you think is represented as revisable plain text is not in fact represented as revisable plain text.
From your phrasing of the problem, it appears that you work with PDF Portable Document Format. Everyday endusers who work with PDF do not necessarily, as a minor mountain of mail indicates, distinguish non-revisable .PDF from revisable document formats such as .DOC.
PDF leads to all sorts of problems, in particular if the domain of imaging is not intertwined with the domain of information through what is technically termed 'tagged PDF' which requires PDF 1.4 and higher with matching of the rendering order at the level of graphic data by reading order at the level of graphic metadata through Adobe XMP Extensible Markup Platform.
/hh