Spaces:
Sleeping
Sleeping
| <html lang="pt-BR" class="scroll-smooth"> | |
| <head> | |
| <meta charset="UTF-8" /> | |
| <meta name="viewport" content="width=device-width, initial-scale=1.0" /> | |
| <title>Painel Administrativo - SoftEdge Corporation</title> | |
| <!-- SEO & SOCIAL --> | |
| <meta name="description" content="Painel administrativo SoftEdge Corporation. Gerencie projetos, usuários e estatísticas."> | |
| <meta name="keywords" content="admin, painel, dashboard, softedge"> | |
| <!-- FAVICON --> | |
| <link rel="icon" href="/assets/placeholder.svg" type="image/svg+xml"> | |
| <link rel="apple-touch-icon" href="/assets/placeholder.svg"> | |
| <meta property="og:image" content="/assets/placeholder.svg" /> | |
| <meta property="og:title" content="Painel Administrativo - SoftEdge Corporation" /> | |
| <meta property="og:description" content="Gerencie seu negócio digital" /> | |
| <!-- FONTS --> | |
| <link rel="preconnect" href="https://fonts.googleapis.com"> | |
| <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin> | |
| <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800;900&display=swap" rel="stylesheet"> | |
| <!-- TAILWIND CSS --> | |
| <script src="https://cdn.tailwindcss.com"></script> | |
| <script> | |
| tailwind.config = { | |
| theme: { | |
| extend: { | |
| fontFamily: { | |
| sans: ['Inter', 'system-ui', 'sans-serif'], | |
| }, | |
| colors: { | |
| primary: { | |
| 50: '#ecfeff', | |
| 100: '#cffafe', | |
| 500: '#06b6d4', | |
| 600: '#0891b2', | |
| 700: '#0e7490', | |
| 900: '#164e63', | |
| } | |
| } | |
| } | |
| } | |
| } | |
| </script> | |
| <!-- LUCIDE ICONS --> | |
| <script src="https://unpkg.com/lucide@latest"></script> | |
| <!-- CUSTOM CSS --> | |
| <link href="/assets/css/style.css" rel="stylesheet"> | |
| </head> | |
| <body class="min-h-screen bg-slate-950 text-white antialiased font-sans"> | |
| <!-- SIDEBAR --> | |
| <div class="fixed inset-y-0 left-0 z-50 w-64 bg-slate-900 border-r border-slate-700 transform -translate-x-full lg:translate-x-0 transition-transform duration-300" id="sidebar"> | |
| <div class="flex items-center justify-between p-4 border-b border-slate-700"> | |
| <div class="flex items-center space-x-3"> | |
| <div class="w-8 h-8 rounded-lg overflow-hidden bg-linear-to-br from-cyan-500 to-blue-600 p-0.5"> | |
| <img src="/assets/logo.jpeg" alt="SoftEdge Logo" class="w-full h-full object-cover rounded-lg"> | |
| </div> | |
| <span class="text-lg font-bold gradient-text">SoftEdge</span> | |
| </div> | |
| <button class="lg:hidden text-gray-400 hover:text-white" id="sidebar-close"> | |
| <i data-lucide="x" class="w-6 h-6"></i> | |
| </button> | |
| </div> | |
| <nav class="p-4 space-y-2"> | |
| <a href="#dashboard" class="nav-link active flex items-center space-x-3 px-4 py-3 text-white bg-cyan-500/10 border-r-2 border-cyan-500 rounded-lg"> | |
| <i data-lucide="layout-dashboard" class="w-5 h-5"></i> | |
| <span>Dashboard</span> | |
| </a> | |
| <a href="#projects" class="nav-link flex items-center space-x-3 px-4 py-3 text-gray-300 hover:text-white hover:bg-slate-800 rounded-lg transition-colors"> | |
| <i data-lucide="folder" class="w-5 h-5"></i> | |
| <span>Projetos</span> | |
| </a> | |
| <a href="#users" class="nav-link flex items-center space-x-3 px-4 py-3 text-gray-300 hover:text-white hover:bg-slate-800 rounded-lg transition-colors"> | |
| <i data-lucide="users" class="w-5 h-5"></i> | |
| <span>Usuários</span> | |
| </a> | |
| <a href="#messages" class="nav-link flex items-center space-x-3 px-4 py-3 text-gray-300 hover:text-white hover:bg-slate-800 rounded-lg transition-colors"> | |
| <i data-lucide="mail" class="w-5 h-5"></i> | |
| <span>Mensagens</span> | |
| </a> | |
| <a href="#analytics" class="nav-link flex items-center space-x-3 px-4 py-3 text-gray-300 hover:text-white hover:bg-slate-800 rounded-lg transition-colors"> | |
| <i data-lucide="bar-chart" class="w-5 h-5"></i> | |
| <span>Analytics</span> | |
| </a> | |
| <a href="#settings" class="nav-link flex items-center space-x-3 px-4 py-3 text-gray-300 hover:text-white hover:bg-slate-800 rounded-lg transition-colors"> | |
| <i data-lucide="settings" class="w-5 h-5"></i> | |
| <span>Configurações</span> | |
| </a> | |
| </nav> | |
| <div class="absolute bottom-4 left-4 right-4"> | |
| <form method="POST" action="/api/auth/logout"> | |
| <button type="submit" class="w-full flex items-center space-x-3 px-4 py-3 text-red-400 hover:text-red-300 hover:bg-red-500/10 rounded-lg transition-colors"> | |
| <i data-lucide="log-out" class="w-5 h-5"></i> | |
| <span>Sair</span> | |
| </button> | |
| </form> | |
| </div> | |
| </div> | |
| <!-- MAIN CONTENT --> | |
| <div class="lg:ml-64"> | |
| <!-- HEADER --> | |
| <header class="bg-slate-900 border-b border-slate-700 px-4 py-4 lg:px-8"> | |
| <div class="flex items-center justify-between"> | |
| <div class="flex items-center space-x-4"> | |
| <button class="lg:hidden text-gray-400 hover:text-white" id="sidebar-toggle"> | |
| <i data-lucide="menu" class="w-6 h-6"></i> | |
| </button> | |
| <h1 class="text-2xl font-bold text-white">Painel Administrativo</h1> | |
| </div> | |
| <div class="flex items-center space-x-4"> | |
| <div class="text-right"> | |
| <p class="text-sm text-gray-400">Bem-vindo,</p> | |
| <p class="text-sm font-semibold text-white">Isaac Quarenta</p> | |
| </div> | |
| <div class="w-10 h-10 rounded-full bg-linear-to-br from-cyan-500 to-blue-600 flex items-center justify-center"> | |
| <span class="text-white font-bold text-sm">IQ</span> | |
| </div> | |
| </div> | |
| </div> | |
| </header> | |
| <!-- DASHBOARD CONTENT --> | |
| <main class="p-4 lg:p-8"> | |
| <!-- STATS CARDS --> | |
| <div class="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-4 gap-6 mb-8"> | |
| <div class="glass rounded-xl p-6"> | |
| <div class="flex items-center justify-between"> | |
| <div> | |
| <p class="text-gray-400 text-sm">Total de Projetos</p> | |
| <p class="text-2xl font-bold text-white">{{ stats.total_projects }}</p> | |
| </div> | |
| <div class="w-12 h-12 bg-blue-500/20 rounded-lg flex items-center justify-center"> | |
| <i data-lucide="folder" class="w-6 h-6 text-blue-400"></i> | |
| </div> | |
| </div> | |
| </div> | |
| <div class="glass rounded-xl p-6"> | |
| <div class="flex items-center justify-between"> | |
| <div> | |
| <p class="text-gray-400 text-sm">Usuários Ativos</p> | |
| <p class="text-2xl font-bold text-white">{{ stats.total_users }}</p> | |
| </div> | |
| <div class="w-12 h-12 bg-green-500/20 rounded-lg flex items-center justify-center"> | |
| <i data-lucide="users" class="w-6 h-6 text-green-400"></i> | |
| </div> | |
| </div> | |
| </div> | |
| <div class="glass rounded-xl p-6"> | |
| <div class="flex items-center justify-between"> | |
| <div> | |
| <p class="text-gray-400 text-sm">Mensagens</p> | |
| <p class="text-2xl font-bold text-white">{{ stats.total_contacts }}</p> | |
| </div> | |
| <div class="w-12 h-12 bg-purple-500/20 rounded-lg flex items-center justify-center"> | |
| <i data-lucide="mail" class="w-6 h-6 text-purple-400"></i> | |
| </div> | |
| </div> | |
| </div> | |
| <div class="glass rounded-xl p-6"> | |
| <div class="flex items-center justify-between"> | |
| <div> | |
| <p class="text-gray-400 text-sm">Taxa de Satisfação</p> | |
| <p class="text-2xl font-bold text-white">4.9★</p> | |
| </div> | |
| <div class="w-12 h-12 bg-yellow-500/20 rounded-lg flex items-center justify-center"> | |
| <i data-lucide="star" class="w-6 h-6 text-yellow-400"></i> | |
| </div> | |
| </div> | |
| </div> | |
| </div> | |
| <!-- RECENT ACTIVITY --> | |
| <div class="grid grid-cols-1 lg:grid-cols-2 gap-8 mb-8"> | |
| <!-- Recent Users --> | |
| <div class="glass rounded-xl p-6"> | |
| <h3 class="text-xl font-bold text-white mb-4">Usuários Recentes</h3> | |
| <div class="space-y-4"> | |
| {% for user in stats.recent_users %} | |
| <div class="flex items-center space-x-3"> | |
| <div class="w-10 h-10 rounded-full bg-slate-700 flex items-center justify-center"> | |
| <span class="text-white font-bold text-sm">{{ user.name[0] }}</span> | |
| </div> | |
| <div class="flex-1"> | |
| <p class="text-white font-medium">{{ user.name }}</p> | |
| <p class="text-gray-400 text-sm">{{ user.email }}</p> | |
| </div> | |
| <span class="text-xs text-gray-500">{{ user.created_at.strftime('%d/%m') }}</span> | |
| </div> | |
| {% endfor %} | |
| </div> | |
| </div> | |
| <!-- Recent Messages --> | |
| <div class="glass rounded-xl p-6"> | |
| <h3 class="text-xl font-bold text-white mb-4">Mensagens Recentes</h3> | |
| <div class="space-y-4"> | |
| {% for contact in stats.recent_contacts %} | |
| <div class="border-l-2 border-cyan-500 pl-4"> | |
| <p class="text-white font-medium">{{ contact.name }}</p> | |
| <p class="text-gray-400 text-sm line-clamp-2">{{ contact.message }}</p> | |
| <p class="text-xs text-gray-500 mt-1">{{ contact.created_at.strftime('%d/%m %H:%M') }}</p> | |
| </div> | |
| {% endfor %} | |
| </div> | |
| </div> | |
| </div> | |
| <!-- QUICK ACTIONS --> | |
| <div class="glass rounded-xl p-6"> | |
| <h3 class="text-xl font-bold text-white mb-4">Ações Rápidas</h3> | |
| <div class="grid grid-cols-1 md:grid-cols-3 gap-4"> | |
| <button class="bg-cyan-500 hover:bg-cyan-600 text-white font-semibold py-3 px-4 rounded-lg transition-colors flex items-center justify-center space-x-2"> | |
| <i data-lucide="plus" class="w-5 h-5"></i> | |
| <span>Novo Projeto</span> | |
| </button> | |
| <button class="bg-blue-500 hover:bg-blue-600 text-white font-semibold py-3 px-4 rounded-lg transition-colors flex items-center justify-center space-x-2"> | |
| <i data-lucide="user-plus" class="w-5 h-5"></i> | |
| <span>Adicionar Usuário</span> | |
| </button> | |
| <button class="bg-purple-500 hover:bg-purple-600 text-white font-semibold py-3 px-4 rounded-lg transition-colors flex items-center justify-center space-x-2"> | |
| <i data-lucide="download" class="w-5 h-5"></i> | |
| <span>Exportar Dados</span> | |
| </button> | |
| </div> | |
| </div> | |
| </main> | |
| </div> | |
| <!-- SCRIPTS --> | |
| <script src="https://unpkg.com/lucide@latest"></script> | |
| <script> | |
| document.addEventListener('DOMContentLoaded', function() { | |
| // Initialize Lucide icons | |
| lucide.createIcons(); | |
| // Sidebar toggle | |
| const sidebar = document.getElementById('sidebar'); | |
| const sidebarToggle = document.getElementById('sidebar-toggle'); | |
| const sidebarClose = document.getElementById('sidebar-close'); | |
| sidebarToggle?.addEventListener('click', () => { | |
| sidebar.classList.toggle('-translate-x-full'); | |
| }); | |
| sidebarClose?.addEventListener('click', () => { | |
| sidebar.classList.add('-translate-x-full'); | |
| }); | |
| // Navigation | |
| const navLinks = document.querySelectorAll('.nav-link'); | |
| navLinks.forEach(link => { | |
| link.addEventListener('click', function(e) { | |
| e.preventDefault(); | |
| // Update active state | |
| navLinks.forEach(l => { | |
| l.classList.remove('active', 'text-white', 'bg-cyan-500/10', 'border-r-2', 'border-cyan-500'); | |
| l.classList.add('text-gray-300'); | |
| }); | |
| this.classList.add('active', 'text-white', 'bg-cyan-500/10', 'border-r-2', 'border-cyan-500'); | |
| this.classList.remove('text-gray-300'); | |
| // Close sidebar on mobile | |
| if (window.innerWidth < 1024) { | |
| sidebar.classList.add('-translate-x-full'); | |
| } | |
| }); | |
| }); | |
| // Auto-refresh stats every 30 seconds | |
| setInterval(async () => { | |
| try { | |
| const response = await fetch('/api/stats'); | |
| const data = await response.json(); | |
| // Update stats if available | |
| const projectStat = document.querySelector('.glass p:contains("Total de Projetos")').nextElementSibling; | |
| if (projectStat) projectStat.textContent = data.projects + '+'; | |
| } catch (error) { | |
| console.log('Stats refresh failed'); | |
| } | |
| }, 30000); | |
| }); | |
| </script> | |
| <style> | |
| .glass { | |
| background: rgba(0, 0, 0, 0.8); | |
| backdrop-filter: blur(20px); | |
| -webkit-backdrop-filter: blur(20px); | |
| border: 1px solid rgba(255, 255, 255, 0.1); | |
| } | |
| .gradient-text { | |
| background: linear-gradient(135deg, #06b6d4, #3b82f6); | |
| -webkit-background-clip: text; | |
| -webkit-text-fill-color: transparent; | |
| background-clip: text; | |
| } | |
| .nav-link.active { | |
| background: rgba(6, 182, 212, 0.1) ; | |
| color: white ; | |
| border-right: 2px solid #06b6d4 ; | |
| } | |
| .line-clamp-2 { | |
| display: -webkit-box; | |
| -webkit-line-clamp: 2; | |
| -webkit-box-orient: vertical; | |
| overflow: hidden; | |
| } | |
| </style> | |
| </body> | |
| </html> | |