Make sure your CharacterBody2D motion mode is on grounded and the up direction is correct:
Also i recommend you change the _process callback to _physics_process callback, everything physics related should be called inside _physics_process
_process
_physics_process