Pls help ill give points

I hope you don't find the solution too messy. If there is anything you don't get. Let me know and I will explain it: