<?php
require_once __DIR__ . '/header.php';
require_once __DIR__ . '/sidebar.php';

/* ===== AUTO BREADCRUMB DETECTION ===== */
$currentPage = basename($_SERVER['PHP_SELF']);
$pageName = ucwords(str_replace(['.php','_'], ['',' '], $currentPage));

$breadcrumb = $breadcrumb ?? $pageName;
?>

<div class="main-content">

    <!-- TOP MESSAGE BAR -->
    <div class="top-message">
    <div>
        <strong><?php echo SYSTEM_NAME; ?></strong> • <?php echo SYSTEM_TAGLINE; ?>
    </div>
        <div>
            <div style="display:flex; align-items:center; gap:15px;">

   <!-- Notification Bell -->
<div id="notification-bell" style="position:relative; cursor:pointer; font-size:18px;">

    <i class="fa fa-bell" style="color:#f2531e;"></i>

        <span id="notif-count" style="
            position:absolute;
            top:-5px;
            right:-8px;
            background:red;
            color:#fff;
            font-size:10px;
            padding:2px 6px;
            border-radius:50%;
            display:none;
        ">0</span>

    </div>

    <div>
        Logged in as <?= htmlspecialchars($_SESSION['full_name'] ?? 'User') ?>
    </div>

</div>
        </div>
    </div>

    <!-- BREADCRUMB -->
    <div class="breadcrumb">
        <a href="index.php">Dashboard</a>
        <span>›</span>
        <span class="active"><?= $breadcrumb ?></span>
    </div>

