<?php
// Get current page name
$currentPage = basename($_SERVER['PHP_SELF']);
?>
<!-- Modern Admin Navigation -->
<div class="bg-white rounded-2xl shadow-2xl p-6 mb-8 border border-gray-100">
    <div class="flex items-center justify-between mb-6">
        <div class="flex items-center">
            <div class="bg-gradient-to-r from-red-500 to-pink-500 w-12 h-12 rounded-xl flex items-center justify-center mr-4">
                <i class="fas fa-tachometer-alt text-white text-xl"></i>
            </div>
            <div>
                <h1 class="text-2xl font-bold text-gray-800">Admin Dashboard</h1>
                <p class="text-sm text-gray-500">Manage your website content and settings</p>
            </div>
        </div>
        <a href="../index.php" class="bg-gray-100 hover:bg-gray-200 text-gray-700 px-4 py-2 rounded-xl transition-all duration-200 flex items-center">
            <i class="fas fa-home mr-2"></i>Back to Website
        </a>
    </div>
    
    <!-- Modern Navigation Menu -->
    <nav class="bg-gray-50 rounded-xl p-2">
        <div class="flex flex-wrap gap-2">
            <a href="modern-dashboard.php" 
               class="<?= in_array($currentPage, ['modern-dashboard.php', 'admin-dashboard.php']) ? 'bg-gradient-to-r from-red-500 to-pink-500 text-white shadow-lg' : 'text-gray-600 hover:bg-white hover:shadow-md' ?> px-4 py-3 rounded-lg font-medium text-sm transition-all duration-200 flex items-center">
                <i class="fas fa-tachometer-alt mr-2"></i>Dashboard
            </a>
            <a href="modern-content-management.php" 
               class="<?= in_array($currentPage, ['modern-content-management.php', 'city-service-admin.php']) ? 'bg-gradient-to-r from-red-500 to-pink-500 text-white shadow-lg' : 'text-gray-600 hover:bg-white hover:shadow-md' ?> px-4 py-3 rounded-lg font-medium text-sm transition-all duration-200 flex items-center">
                <i class="fas fa-edit mr-2"></i>Content Management
            </a>
            <a href="modern-manage-cities-services.php" 
               class="<?= in_array($currentPage, ['modern-manage-cities-services.php', 'manage-cities-services.php']) ? 'bg-gradient-to-r from-red-500 to-pink-500 text-white shadow-lg' : 'text-gray-600 hover:bg-white hover:shadow-md' ?> px-4 py-3 rounded-lg font-medium text-sm transition-all duration-200 flex items-center">
                <i class="fas fa-city mr-2"></i>Manage Cities & Services
            </a>
            <a href="modern-seo-optimizer.php" 
               class="<?= in_array($currentPage, ['modern-seo-optimizer.php', 'seo-optimizer.php', 'simple-seo-optimizer.php']) ? 'bg-gradient-to-r from-red-500 to-pink-500 text-white shadow-lg' : 'text-gray-600 hover:bg-white hover:shadow-md' ?> px-4 py-3 rounded-lg font-medium text-sm transition-all duration-200 flex items-center">
                <i class="fas fa-search mr-2"></i>SEO Optimizer
            </a>
            <a href="../generate-sitemap.php" target="_blank"
               class="<?= $currentPage === 'generate-sitemap.php' ? 'bg-gradient-to-r from-blue-500 to-indigo-500 text-white shadow-lg' : 'text-gray-600 hover:bg-white hover:shadow-md' ?> px-4 py-3 rounded-lg font-medium text-sm transition-all duration-200 flex items-center">
                <i class="fas fa-sitemap mr-2"></i>Generate Sitemap
            </a>
            <a href="modern-sync-data.php" 
               class="<?= $currentPage === 'modern-sync-data.php' ? 'bg-gradient-to-r from-red-500 to-pink-500 text-white shadow-lg' : 'text-gray-600 hover:bg-white hover:shadow-md' ?> px-4 py-3 rounded-lg font-medium text-sm transition-all duration-200 flex items-center">
                <i class="fas fa-sync-alt mr-2"></i>Sync Data
            </a>
            <a href="fix-database.php" 
               class="<?= $currentPage === 'fix-database.php' ? 'bg-gradient-to-r from-red-500 to-pink-500 text-white shadow-lg' : 'text-gray-600 hover:bg-white hover:shadow-md' ?> px-4 py-3 rounded-lg font-medium text-sm transition-all duration-200 flex items-center">
                <i class="fas fa-wrench mr-2"></i>Database Tools
            </a>
        </div>
    </nav>
</div>