How to Load Main Menu on Player's Death

So I’ve gone through all the other questions which were helpful, but I am still getting an error. Right now I am using javascript and I want to make it so when the player dies they return to the main menu or go to a death screen. This is the error:
Assets/scripts/player health.js(2,1): BCE0044: expecting EOF, found ‘import’.

And this is the script:

var health = 300;

import UnityEngine.SceneManagment;

function Update() {

}

function OnCollisionEnter(playerHit : Collision){
    if (playerHit.gameObject.name == "zombie(Clone)"){
        health -= 30;
    }

    if (playerHit.gameObject.name == "fireball(Clone)"){
        health -= 15;
    }

    if (health <= 0)
    {
        SceneManager.LoadScene("MainMenu");
    }

}

    function OnGUI(){
        GUI.Button(Rect(20,20,health,20), "");
    }

Move the import statement before your variable definitions:

 import UnityEngine.SceneManagment;
 var health = 300;
  
 function Update() {
 
 }
 
 function OnCollisionEnter(playerHit : Collision){
     if (playerHit.gameObject.name == "zombie(Clone)"){
         health -= 30;
     }
 
     if (playerHit.gameObject.name == "fireball(Clone)"){
         health -= 15;
     }
 
     if (health <= 0)
     {
         SceneManager.LoadScene("MainMenu");
     }
 
 }
 
 function OnGUI(){
     GUI.Button(Rect(20,20,health,20), "");
 }

Imports should always be on the top of the file. Move line 3 all the way up.