<!DOCTYPE html>
<html lang="id">
<head>
    <meta charset="UTF-8">
    <title>Pusat Kendali - Superadmin</title>
    <script src="https://cdn.tailwindcss.com"></script>
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
</head>
<body class="bg-slate-900 text-slate-100 font-sans min-h-screen flex">

    <?php include(APPPATH . 'Views/layout/sidebar.php'); ?>

    <main class="flex-1 p-8 overflow-y-auto">
        <div class="flex justify-between items-center mb-8">
            <div>
                <h1 class="text-3xl font-extrabold text-white tracking-tight">Pusat Kendali Superadmin</h1>
                <p class="text-sm text-slate-400">Selamat datang di sistem manajemen utama portal Apresiasi.</p>
            </div>
            <span class="text-xs bg-indigo-500/10 text-indigo-600 border border-indigo-500/20 px-3 py-1.5 rounded-full font-bold">
                <i class="fa fa-user-check mr-1"></i> Sesi Aktif: <?= session()->get('username') ?>
            </span>
        </div>

        <div class="grid grid-cols-1 md:grid-cols-3 gap-6 mb-8">
            <div class="bg-slate-800 p-6 rounded-xl border border-slate-700 shadow-lg relative overflow-hidden">
                <i class="fa fa-users absolute -bottom-4 -right-4 text-7xl text-slate-700/50"></i>
                <h3 class="text-slate-400 font-semibold text-xs uppercase tracking-wider mb-2">Total Pengguna Aktif</h3>
                <p class="text-4xl font-black text-white relative z-10"><?= $total_user ?? 0 ?></p>
            </div>
            
            <div class="bg-slate-800 p-6 rounded-xl border border-slate-700 shadow-lg relative overflow-hidden">
                <i class="fa fa-sitemap absolute -bottom-4 -right-4 text-7xl text-slate-700/50"></i>
                <h3 class="text-slate-400 font-semibold text-xs uppercase tracking-wider mb-2">Total Modul Menu</h3>
                <p class="text-4xl font-black text-indigo-400 relative z-10"><?= $total_menu ?? 0 ?></p>
            </div>
            
            <div class="bg-slate-800 p-6 rounded-xl border border-slate-700 shadow-lg relative overflow-hidden">
                <i class="fa fa-award absolute -bottom-4 -right-4 text-7xl text-slate-700/50"></i>
                <h3 class="text-slate-400 font-semibold text-xs uppercase tracking-wider mb-2">Prestasi Terekam</h3>
                <p class="text-4xl font-black text-emerald-400 relative z-10"><?= $total_prestasi ?? 0 ?></p>
            </div>
        </div>

        <div class="bg-indigo-600/10 border border-indigo-500/30 rounded-xl p-8 text-center mt-12">
            <i class="fa fa-rocket text-5xl text-indigo-500 mb-4 animate-bounce"></i>
            <h2 class="text-2xl font-bold text-white mb-2">Sistem Berjalan Optimal!</h2>
            <p class="text-slate-400 text-sm max-w-lg mx-auto">
                Anda kini memiliki kontrol penuh. Coba gunakan panel navigasi di sebelah kiri untuk menyuntikkan menu baru atau mengubah konfigurasi global.
            </p>
        </div>
    </main>

</body>
</html>