Importing the Crt unit breaks UTF8ToAnsi and it starts outputting wrong characters or pseudographics again.
As the documentation states:
There are some caveats when using the CRT unit:
[...]
* The CRT unit stems from the TP/Dos area. It is designed to work with single-byte character sets, where 1 char = 1 byte. That means that widestrings or UTF-8 encoded (ansi)strings will not work correctly.
I need the Crt unit for stuff like ClrScr, so I can't leave it out.
I don't know whether it still works in Free Pascal or how portable it is, but there was an old trick in TP times to allow you to use (most of) the functions of CRT w/out sacrifycing interoperability with the OS:
Assign(Input, ''); Reset(Input);
Assign(Output, ''); Rewrite(Output);
That allowed you to, for example, use IO redirection from the commad line while still allowing you to use GotoXY, ClrScr, Sound, Delay, etc.