The camera interpolation during movement is not working correctly.

Godot Version

4.2.1

Question

My problem is that when interpolating the camera movement as shown in the code below, the camera smoothly follows the direction of the player’s movement vector and (upon stopping) smoothly centers on the player. I want to make it so that it smoothly FOLLOWS the player and smoothly centers on him when he stops. How can I fix the code? Moreover, changing player.Velocity to player.Position changes nothing except that the camera stops centering on the player.

Here’s my code that is attached to the Pivot node.

public partial class Camera : Node3D
{
    [Export]
    private float cameraFollowSpeed = 2.0f;

    private CharacterBody3D player;

    // Called when the node enters the scene tree for the first time.
    public override void _Ready()
    {
        player = GetParent<CharacterBody3D>();
    }

    // Called every frame. 'delta' is the elapsed time since the previous frame.
    public override void _PhysicsProcess(double delta)
    {
        if (player == null)
            return;

        Position = Position.Lerp(player.Position, (float)delta * cameraFollowSpeed);
    }
}

The script attached to the Player node is responsible for regular movement using WASD and the camera works like in isometric games.

Here is a screenshot of the scene with the player.
image