<?php
session_start();

if(!isset($_SESSION['login'])){
    header("Location: index.php");
    exit;
}

if($_SESSION['role'] !== 'sekolah'){
    echo "Akses ditolak!";
    exit;
}

// NPSN sekolah dari login
$npsn_login = $_SESSION['username'];
