<?php
if (!isset($_SESSION)) session_start();
require __DIR__ . '/../auth.php';

// Make the permission flag available as a normal variable for admin pages.
// auth.php stores it in $GLOBALS['CAN_EDIT'].
$CAN_EDIT = $GLOBALS['CAN_EDIT'] ?? false;

if (!isset($pageTitle)) $pageTitle = "Admin — Smurfette's Country Delights";
if (!isset($pageClass)) $pageClass = "page-admin";

include __DIR__ . '/../../includes/header.php';
include __DIR__ . '/../../includes/nav.php';
?>
<main class="content-area">
  <div class="smurf-divider"></div>
  <div class="content-wrapper">
  <div class="admin-topbar">
      <a class="admin-return" href="/admin/index.php">← Return to Admin</a>
    </div>

