<?php
session_start(); 
if(isset($_GET['path']))
{
    if($_GET['path'] == 'logout.php')
    {
        $config = json_decode(file_get_contents(__DIR__ . "/../../../../config/access.json"), true);
        unset($_SESSION['login_exp']);
        unset($_SESSION['access_token']);
        session_destroy();
        header("Location: ../?".$config['parameter_access']);
        ob_flush();
    }
}
?>
            <header class="app-header sticky"> 

                <!-- Start::main-header-container -->
                <div class="main-header-container container-fluid"> 

                    <!-- Start::header-content-left -->
                    <div class="header-content-left">

                        <!-- Start::header-element -->
                        <div class="header-element">
                            <div class="horizontal-logo">
                                <a href="" class="header-logo">
                                    <img src="<?php echo $baseUrl; ?>/assets/money.png" alt="logo" class="desktop-logo">
                                    <img src="<?php echo $baseUrl; ?>/assets/money.png" alt="logo" class="toggle-logo">
                                    <img src="<?php echo $baseUrl; ?>/assets/money.png" alt="logo" class="desktop-dark">
                                    <img src="<?php echo $baseUrl; ?>/assets/money.png" alt="logo" class="toggle-dark">
                            </div>
                        </div>
                        <!-- End::header-element -->

                        <!-- Start::header-element -->
                        <div class="header-element mx-lg-0 mx-2">
                            <a aria-label="Hide Sidebar" class="sidemenu-toggle header-link animated-arrow hor-toggle horizontal-navtoggle" data-bs-toggle="sidebar" href="javascript:void(0);"><span></span></a>
                        </div>
                        
                        <style>
                        .rgb-animated-text {
                          display: inline-block;
                          background: linear-gradient(90deg, red, orange, yellow, lime, cyan, blue, violet, red);
                          background-size: 300% 300%;
                          -webkit-background-clip: text;
                          -webkit-text-fill-color: transparent;
                          animation: rainbowText 5s linear infinite;
                        }
                        
                        @keyframes rainbowText {
                          0% {
                            background-position: 0% 50%;
                          }
                          100% {
                            background-position: 100% 50%;
                          }
                        }
                        </style>
                        
                        <div class="header-element">
                            <div class="header-link">
                                <h6 class="rgb-animated-text">405 MONEY HEIST TEAM TROBOS</h6>
                            </div>
                        </div>
                        <!-- End::header-element -->

                    </div>
                    <!-- End::header-content-left -->

                    <!-- Start::header-content-right -->
                    <ul class="header-content-right">

                        <!-- Start::header-element -->
                        <li class="header-element dropdown">
                            <!-- Start::header-link|dropdown-toggle -->
                            <a href="javascript:void(0);" class="header-link dropdown-toggle" id="mainHeaderProfile" data-bs-toggle="dropdown" data-bs-auto-close="outside" aria-expanded="false">
                                <div class="d-flex align-items-center">
                                    <div>
                                        <img src="<?php echo $baseUrl; ?>/assets/money.png" alt="img" class="avatar avatar-sm rounded-0">
                                    </div>
                                </div>
                            </a>
                            <!-- End::header-link|dropdown-toggle -->
                            <ul class="main-header-dropdown dropdown-menu pt-0 overflow-hidden header-profile-dropdown dropdown-menu-end" aria-labelledby="mainHeaderProfile">
                                <li><a href="?path=logout.php" class="dropdown-item d-flex align-items-center" href="signin-cover.php"><i class="bi bi-box-arrow-right fs-18 me-2 op-7"></i>Log Out</a></li>
                            </ul>
                        </li>  
                        <!-- End::header-element -->

                        <!-- Start::header-element -->
                        <li class="header-element">
                            <!-- Start::header-link|switcher-icon -->
                            <a href="javascript:void(0);" class="header-link switcher-icon" data-bs-toggle="offcanvas" data-bs-target="#switcher-canvas">
                                <i class="bi bi-gear header-link-icon border-0"></i>
                            </a>
                            <!-- End::header-link|switcher-icon -->
                        </li>
                        <!-- End::header-element -->

                    </ul>
                    <!-- End::header-content-right -->

                </div>
                <!-- End::main-header-container -->

            </header>