I have simulated a class A RF amplifier. When I simulated the output impedance, it is around 50ohms50 Ω for the frequency range that is of interest (50kHz50 kHz to 100MHz100 MHz), now at the input impedance is around 56 ohmsΩ and then it dips, how can I stabilize it to 50 ohmsΩ for the entire range?
Regarding the question asked by Tim Williams, I do not know how to ensure the flatness to the output...
Another good point that was raised is that the output impedance was simulated with the 50 ohmsΩ attached to it... Without the 50 ohmsΩ, the output is different.

I am assuming that I will need a matching circuit at the output as well...
I believe maybe a Pi-network can work for this but I am unsure. Also, the characteristic impedance is around 65ohms65 Ω, but if I want to split it to a Resistance and Reactance, would that help?
Here is the circuit in question. I modified it according to GodJihyo.



