as you can see the top of my circle is protruding out the bottom of the screen. My code is pretty normal and I've tried numerous ways to fix this such as by making the child view in storyboard and setting the centre to the parent view but nothing is working.
class ModalViewController: UIViewController {
override func viewDidLoad() {
super.viewDidLoad()
let Panel = UIView()
Panel.frame = CGRect(x: 0, y: 400, width: 400, height: 200)
Panel.backgroundColor = UIColor.white
view.backgroundColor = UIColor.clear
modalPresentationStyle = .overCurrentContext
view.addSubview(Panel)
let shapeLayer = CAShapeLayer()
let CircularPath = UIBezierPath(ovalIn: Panel.frame)
shapeLayer.path = CircularPath.cgPath
Panel.layer.addSublayer(shapeLayer)
}```