    <!-- Main Sidebar Container -->
    <aside class="main-sidebar sidebar-dark-primary elevation-4" style="background-color: #022141 !important;">
        <!-- Brand Logo -->
        <a href="index.php" class="brand-link text-center pb-3 pt-4 border-bottom-0">
            <?php if(file_exists('../logo/logo1.png')): ?>
                <img src="../logo/logo1.png?v=<?= time() ?>" alt="Logo" style="max-height: 55px; display: block; margin: 0 auto;">
            <?php else: ?>
                <span class="brand-text font-weight-bold">LENTERA</span>
            <?php endif; ?>
        </a>

        <!-- Sidebar -->
        <div class="sidebar">
            <nav class="mt-4">
                <ul class="nav nav-pills nav-sidebar flex-column" data-widget="treeview" role="menu" data-accordion="false">
                    <li class="nav-item">
                        <a href="index.php" class="nav-link <?= (basename($_SERVER['PHP_SELF']) == 'index.php') ? 'active' : '' ?>">
                            <i class="nav-icon fas fa-tachometer-alt"></i>
                            <p>Dashboard</p>
                        </a>
                    </li>
                    <li class="nav-item">
                        <?php 
                            $dp_link = ($_SESSION['level'] == 'administrator') ? 'data_pengajuan.php' : 'data_pengajuan2.php';
                            $is_active = (basename($_SERVER['PHP_SELF']) == 'data_pengajuan.php' || basename($_SERVER['PHP_SELF']) == 'data_pengajuan2.php') ? 'active' : '';
                        ?>
                        <a href="<?= $dp_link ?>" class="nav-link <?= $is_active ?>">
                            <i class="nav-icon fas fa-envelope-open-text text-info"></i>
                            <p>Data Pengajuan</p>
                        </a>
                    </li>
                    <li class="nav-item">
                        <a href="laporan.php" class="nav-link <?= (basename($_SERVER['PHP_SELF']) == 'laporan.php') ? 'active' : '' ?>">
                            <i class="nav-icon fas fa-print text-warning"></i>
                            <p>Cetak Laporan</p>
                        </a>
                    </li>
                    <?php if($_SESSION['level'] == 'administrator'): ?>
                    <li class="nav-header">ADMINISTRATOR</li>
                    <li class="nav-item">
                        <a href="manajemen_user.php" class="nav-link <?= (basename($_SERVER['PHP_SELF']) == 'manajemen_user.php') ? 'active' : '' ?>">
                            <i class="nav-icon fas fa-users-cog"></i>
                            <p>Manajemen Petugas</p>
                        </a>
                    </li>
                    <li class="nav-item">
                        <a href="tatacara.php" class="nav-link <?= (basename($_SERVER['PHP_SELF']) == 'tatacara.php') ? 'active' : '' ?>">
                            <i class="nav-icon fas fa-list-ol"></i>
                            <p>Tata Cara Pengajuan</p>
                        </a>
                    </li>
                    <li class="nav-item">
                        <a href="pengaturan_frontend.php" class="nav-link <?= (basename($_SERVER['PHP_SELF']) == 'pengaturan_frontend.php') ? 'active' : '' ?>">
                            <i class="nav-icon fas fa-desktop"></i>
                            <p>Pengaturan Halaman Depan</p>
                        </a>
                    </li>
                    <li class="nav-item">
                        <a href="pengaturan.php" class="nav-link <?= (basename($_SERVER['PHP_SELF']) == 'pengaturan.php') ? 'active' : '' ?>">
                            <i class="nav-icon fas fa-cogs"></i>
                            <p>Integrasi & Sistem</p>
                        </a>
                    </li>
                    <?php endif; ?>
                </ul>
            </nav>
        </div>
    </aside>
