
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>CEZENnac</title>
    <link rel="stylesheet" href="../css/style.css" type="text/css">
    <link rel="stylesheet" href="../css/popup.css">
    <script>
        function toggleSubmenu(event, submenuId) {
            event.preventDefault();
            var submenu = document.getElementById(submenuId);
            if (submenu.style.display === 'block') {
                submenu.style.display = 'none';
            } else {
                submenu.style.display = 'block';
            }
            adjustSidebarHeight();
        }

        function adjustSidebarHeight() {
            var sidebar = document.getElementById('sidebar');
            var totalHeight = 0;
            var children = sidebar.children;
            for (var i = 0; i < children.length; i++) {
                totalHeight += children[i].offsetHeight;
            }
            sidebar.style.height = totalHeight + 'px';
        }

        document.addEventListener("DOMContentLoaded", function() {
            adjustSidebarHeight();
        });
    </script>
</head>
<body>
<div class="navigation">
    <nav>
       
        <a href="../admin/elements/dashboard.php" class="active">
            <h3>Access Control</h3>
        </a>
        <a href="#" class="disable">
            <span class="icon"></span>
            <h3>Monitoring</h3>
        </a>
        <a href="#" class="disable">
            <span class="icon"></span>
            <h3>Log Management</h3>
        </a>

        <!-- Notification Section -->
        <div class="notification">
            <img class="bell" id="bell" src="../images/bell.png" alt="Notifications">
            <div class="dropdown-content" id="notificationDropdown">
                <!-- Notifications will be dynamically inserted here -->
            </div>
        </div>


        <!-- DARK AND LIGHT MODE STARTS -->
        <div class="theme_toggler">
                        
                <span class="active"><img src="../images/light_mode.png" class="icon"></span>
                <span><img src="../images/dark_mode.png" class="icon"></span>
        </div>

        <!-- DARK AND LIGHT MODE ENDS -->

 
        <!-- Settings Dropdown -->
        <div class="dropdown">
            <img src="../images/setting.png" alt="Settings" class="setting" id="settingsButton">
            <div class="dropdown-content" id="dropdownContent">
                <a href="../user/change_password.php">Change Password</a>
                <a href="other_settings.php">Other Settings</a>
            </div>
        </div>

        <!-- Log Out -->
        <a href="../admin/elements/index.php" class="active">
            <span class="icon"></span>
            <h3>Log Out</h3>
        </a>
    </nav>
</div>

    <div class="container">
        <!--side bar start..-->
        <aside>
            <div class="sidebar">
                <a href="../elements/dashboard.php" class="<?php echo $activePage == 'Dashboard' ? 'active1' : 'active'; ?>">
                    <span><img src="../images/analytics.png" class="icon"></span>
                    <h3>Dashboard</h3>  
                </a>

                <a href="#" onclick="toggleSubmenu(event, 'user-submenu')" class="<?php echo $activePage == 'User' ? 'active1' : 'active'; ?>">
                    <span><img src="../images/manage_accounts.png" class="icon"></span>
                    <h3>User</h3>
                </a>
                <div class="submenu" id="user-submenu" style="display: <?php echo $activePage == 'User' ? 'block' : 'none'; ?>">
                    <a href="../user/userlist.php" class="<?php echo $activeSubPage == 'Userlist' ? 'disabled' : 'active'; ?>">
                        <span class="submenu_span"></span>
                        <h3>User List</h3>
                    </a>
                    <a href="../user/createuser.php" class="<?php echo $activeSubPage == 'Createuser' ? 'disabled' : 'active'; ?>">
                        <span class="submenu_span"></span>
                        <h3>Create User</h3>
                    </a>
                    <a href="otheruser.php" class="<?php echo $activeSubPage == 'OtherUser' ? 'disabled' : 'active'; ?>">
                        <span class="submenu_span"></span>
                        <h3>Other User</h3>
                    </a>
                </div>

                <!-- Other sections -->

               
                

             <!--....................ADMINISTRATION...............................-->

        <a href="#" onclick="toggleSubmenu(event, 'administration-submenu')" class="<?php echo $activePage == 'Administration' ? 'active1' : 'active'; ?>">
        <span ><img src="../images/menu_open.png" class="icon"></img></span>
        <h3>Administration</h3>  
        </a>
        <div class="submenu" id="administration-submenu" style="display: <?php echo $activePage == 'Administration' ? 'block' : 'none'; ?>;">
                <a href="../administration/roles.php" class="<?php echo $activeSubPage == 'roles' ?  'disable' : 'active'; ?>">
                    <span class="submenu_span"></span>
                    <h3>Roles</h3>                
                </a>
        
        
                <a href="../administration/domains.php" class="<?php echo $activeSubPage == 'domains' ? 'disable' : 'active'; ?>">
                    <span class="submenu_span"></span>
                    <h3>Domains</h3>

                </a>
                <a href="../administration/admin_access.php" class="<?php echo $activeSubPage == 'admin_access' ? 'disable' : 'active'; ?>">
                    <span class="submenu_span"></span>
                    <h3>Admin Access</h3>
                </a>
                <a href="../administration/admin_login.php" class="<?php echo $activeSubPage == 'admin_login' ? 'disable' : 'active'; ?>">
                    <span class="submenu_span"></span>
                    <h3>Admin Login</h3>
                </a>
                <a href="../administration/ssl_certificates.php" class="<?php echo $activeSubPage == 'ssl' ? 'disable' : 'active'; ?>">
                    <span class="submenu_span"></span>
                    <h3>SSL Certificates</h3>
                </a>
               

                <!---------------------------------------------- Devices --------------------------------------------------------------------->
                <a href="#" onclick="toggleSubmenu(event, 'devices-submenu')" class="<?php echo $activePage == 'devices' ? 'active1' : 'active'; ?>">
                    <span><img src="../images/manage_accounts.png" class="icon"></span>
                    <h3>Devices</h3>
                </a>
                <div class="submenu" id="devices-submenu" style="display: <?php echo $activePage == 'devices' ? 'block' : 'none'; ?>">
                    <a href="../Devices/windows_devices.php" class="<?php echo $activeSubPage == 'windows_devices' ? 'disable' : 'active'; ?>">
                        <span class="submenu_span"></span>
                        <h3>Windows Devices</h3>
                    </a>
                    <a href="../Devices/linux_devices.php" class="<?php echo $activeSubPage == 'linux_devices' ? 'disable' : 'active'; ?>">
                        <span class="submenu_span"></span>
                        <h3>Linux Devices</h3>
                    </a>
                    <a href="../Devices/network_devices.php" class="<?php echo $activeSubPage == 'network_devices' ? 'disable' : 'active'; ?>">
                        <span class="submenu_span"></span>
                        <h3>Network Devices</h3>
                    </a>
                    <a href="../Devices/device_groups.php" class="<?php echo $activeSubPage == 'device_groups' ? 'disable' : 'active'; ?>">
                        <span class="submenu_span"></span>
                        <h3>Device Groups</h3>
                    </a>
                </div>

                 <!--....................................CONFIGURATION.............................-->

                 <a href="#" onclick="toggleSubmenu(event, 'configuration-submenu')" class="<?php echo $activePage == 'configuration' ? 'active1' : 'active'; ?>">
            <span ><img src="../images/menu_open.png" class="icon"></img></span>
            <h3>Configuration</h3>  
            </a>

            <div class="submenu" id="configuration-submenu" style="display: <?php echo $activePage == 'configuration' ? 'block' : 'none'; ?>">
                <a href="../configuration/generalsettings.php" class="<?php echo $activeSubPage == 'generalsetting' ?  'disable' : 'active'; ?>">
                    <span class="submenu_span"></span>
                    <h3>General Settings</h3>                
                </a>
        
        
                <a href="../configuration/integration.php" class="<?php echo $activeSubPage == 'integration' ? 'disable' : 'active'; ?>">
                    <span class="submenu_span"></span>
                    <h3>Integration</h3>

                </a>
                <a href="../configuration/maintenance.php" class="<?php echo $activeSubPage == 'Maintenance' ? 'disable' : 'active'; ?>">
                    <span class="submenu_span"></span>
                    <h3>Maintenance</h3>
                </a>
                <a href="../configuration/alerting.php" class="<?php echo $activeSubPage == 'Alerting' ? 'disable' : 'active'; ?>">
                    <span class="submenu_span"></span>
                    <h3>Alerting</h3>
                </a>
                <a href="../configuration/advance_config.php" class="<?php echo $activeSubPage == 'advance_configuration' ? 'disable' : 'active'; ?>">
                    <span class="submenu_span"></span>
                    <h3>Advance Configuration</h3>
                </a>
            </div>


          <!--....................NETWORK...............................-->
          
        <a href="#" onclick="toggleSubmenu(event, 'network-submenu')" class="<?php echo $activePage == 'network' ? 'active1' : 'active'; ?>">
        <span ><img src="../images/menu_open.png" class="icon"></img></span>
        <h3>Network</h3>  
        </a>
        <div class="submenu" id="network-submenu" style="display: <?php echo $activePage == 'network' ? 'block' : 'none'; ?>">
                <a href="../network/network_settings.php" class="<?php echo $activeSubPage == 'networksettings' ?  'disable' : 'active'; ?>">
                    <span class="submenu_span"></span>
                    <h3>Network Settings</h3>                
                </a>
        
        
                <a href="../network/interfaces.php" class="<?php echo $activeSubPage == 'interfaces' ? 'disable' : 'active'; ?>">
                    <span class="submenu_span"></span>
                    <h3>Interfaces</h3>

                </a>
                <a href="../network/snmp.php" class="<?php echo $activeSubPage == 'snmp' ? 'disable' : 'active'; ?>">
                    <span class="submenu_span"></span>
                    <h3>SNMP</h3>
                </a>
                <a href="../network/inline_config.php" class="<?php echo $activeSubPage == 'inline_config' ? 'disable' : 'active'; ?>">
                    <span class="submenu_span"></span>
                    <h3>Inline Configuration</h3>
                </a>    
        </div>

             
        </div>
       
        
    </aside>
<script src="/admin/js/script.js"></script>
<script src="/admin/js/bell.js"></script>
</body>
</html>