The bad effect of the inappropriate images, videos and language needs
to be cleaned from the heart and mind, so that the person can be
gradually purified from that dirt. It starts from a sincere feeling of
sorrow and repentance and from the decision to leave it and never come
back to it. Along with continuous and repeated Istegfaar specially
during the night in the state of Sujood.
It is very useful to weep or try to weep when you remember such sins. Even a drop of tear of sorrow and repentance extinguishes the fire.
When the heart becomes clear as it was created by Allah SWT, the person will be shocked to see or listen to any of the evil material again. So the main point is how to purify the
heart from the dirt of the sinful acts. The Hadeeths guide to keep on
repeating Istegfaar to achieve more purity in the heart and mind.