<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>AuraAccountify | Enterprise Accounting</title>
    <script src="https://cdn.tailwindcss.com"></script>
    <script defer src="https://cdn.jsdelivr.net/npm/alpinejs@3.x.x/dist/cdn.min.js"></script>
    <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800;900&display=swap" rel="stylesheet">
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.1/css/all.min.css">
    <style>
        body { font-family: 'Inter', sans-serif; font-size: 13px; }
        [x-cloak] { display: none !important; }
        .sidebar-item-active { background-color: #f8fafc; color: #4f46e5; font-weight: 700; border-left: 3px solid #4f46e5; }
        .sub-nav-active { color: #4f46e5 !important; font-weight: 800 !important; }
    </style>
</head>
<body class="bg-[#fcfcfc] text-slate-600">
    
    <div x-data="{ 
        show: false, 
        message: '', 
        type: 'success',
        init() {
            <?php if(session('success')): ?>
                this.showToast('<?php echo e(session('success')); ?>', 'success');
            <?php endif; ?>
            <?php if(session('error')): ?>
                this.showToast('<?php echo e(session('error')); ?>', 'error');
            <?php endif; ?>
        },
        showToast(msg, type) {
            this.message = msg;
            this.type = type;
            this.show = true;
            setTimeout(() => { this.show = false }, 4000);
        }
    }" 
    x-show="show" 
    x-transition:enter="transition ease-out duration-300"
    x-transition:enter-start="opacity-0 transform translate-y-2"
    x-transition:enter-end="opacity-100 transform translate-y-0"
    class="fixed top-5 right-5 z-[100] min-w-[300px]"
    x-cloak>
    
        <div :class="type === 'success' ? 'bg-emerald-600' : 'bg-rose-600'" 
             class="text-white px-4 py-3 rounded shadow-2xl flex items-center gap-3 border border-white/20">
            <template x-if="type === 'success'">
                <svg class="w-5 h-5" fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M9 12l2 2 4-4m6 2a9 9 0 11-18 0 9 9 0 0118 0z"></path></svg>
            </template>
            <template x-if="type === 'error'">
                <svg class="w-5 h-5" fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M12 8v4m0 4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z"></path></svg>
            </template>
            <span class="text-[12px] font-bold" x-text="message"></span>
            <button @click="show = false" class="ml-auto opacity-70 hover:opacity-100">
                <svg class="w-3 h-3" fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M6 18L18 6M6 6l12 12"></path></svg>
            </button>
        </div>
    </div>

    <div class="flex h-screen overflow-hidden">
        
        <aside class="w-56 bg-white border-r border-slate-200 flex flex-col shrink-0">
            <div class="h-12 flex items-center px-5 border-b border-slate-100">
                <div class="flex items-center gap-2">
                    <div class="w-6 h-6 bg-indigo-600 rounded flex items-center justify-center text-white font-black text-[10px]">A</div>
                    <span class="font-black text-slate-900 tracking-tighter text-sm">AuraAccountify</span>
                </div>
            </div>

            <nav class="flex-1 overflow-y-auto py-4">
                <div class="px-5 mb-2 text-[11px] font-bold text-slate-400">Main Menu</div>
                
                <a href="<?php echo e(route('dashboard')); ?>" class="flex items-center px-5 py-2.5 hover:bg-slate-50 transition <?php echo e(request()->routeIs('dashboard') ? 'sidebar-item-active' : ''); ?>">
                    <svg class="w-4 h-4 mr-3 opacity-70" fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M3 12l2-2m0 0l7-7 7 7M5 10v10a1 1 0 001 1h3m10-11l2 2m-2-2v10a1 1 0 01-1 1h-3m-6 0a1 1 0 001-1v-4a1 1 0 011-1h2a1 1 0 011 1v4a1 1 0 001 1m-6 0h6"></path></svg>
                    Dashboard
                </a>

                <div x-data="{ open: <?php echo e(request()->is('accounting*') ? 'true' : 'false'); ?> }">
                    <button @click="open = !open" class="w-full flex items-center px-5 py-2.5 hover:bg-slate-50 transition outline-none <?php echo e(request()->is('accounting*') ? 'text-indigo-600 font-bold' : ''); ?>">
                        <svg class="w-4 h-4 mr-3 opacity-70" fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"></path></svg>
                        <span class="flex-1 text-left text-[13px] font-semibold">Accounting</span>
                        <svg :class="open ? 'rotate-180' : ''" class="w-3 h-3 transition-transform text-slate-300" fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M19 9l-7 7-7-7"></path></svg>
                    </button>
                    <div x-show="open" x-cloak x-transition class="bg-slate-50/50 border-l-2 border-indigo-100 ml-5 py-1">
                        <a href="<?php echo e(route('financial-years.index')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->routeIs('financial-years.*') ? 'sub-nav-active' : ''); ?>">Financial Years</a>
                        <a href="<?php echo e(route('currencies.index')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->routeIs('currencies.*') ? 'sub-nav-active' : ''); ?>">Currencies</a>
                        <a href="<?php echo e(route('currency-rates.index')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->routeIs('currency-rates.*') ? 'sub-nav-active' : ''); ?>">Exchange Rates</a>
                        <a href="<?php echo e(route('accounting.categories')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->routeIs('accounting.categories') ? 'sub-nav-active' : ''); ?>">Primary Categories</a>
                        <a href="<?php echo e(route('accounting.groups')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->routeIs('accounting.groups') ? 'sub-nav-active' : ''); ?>">Account Groups</a>
                        <a href="<?php echo e(route('accounting.types')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->routeIs('accounting.types') ? 'sub-nav-active' : ''); ?>">Account Types</a>
                        <a href="<?php echo e(route('accounting.coa')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->routeIs('accounting.coa') ? 'sub-nav-active' : ''); ?>">Chart of Accounts</a>
                        <a href="<?php echo e(route('accounting.transactions')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->routeIs('accounting.transactions') ? 'sub-nav-active' : ''); ?>">Journal Entries</a>
                        <a href="<?php echo e(route('accounting.mappings')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->routeIs('accounting.mappings') ? 'sub-nav-active' : ''); ?>">Account Mappings</a>
                    </div>
                </div>

                <div x-data="{ open: <?php echo e(request()->is('sales*') ? 'true' : 'false'); ?> }">
                    <button @click="open = !open" class="w-full flex items-center px-5 py-2.5 hover:bg-slate-50 transition outline-none <?php echo e(request()->is('sales*') ? 'text-indigo-600 font-bold' : ''); ?>">
                        <svg class="w-4 h-4 mr-3 opacity-70" fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M12 8c-1.657 0-3 1.343-3 3s1.343 3 3 3 3-1.343 3-3-1.343-3-3-3zM17 16v2a2 2 0 01-2 2H5a2 2 0 01-2-2H5a2 2 0 01-2-2v-7a2 2 0 012-2h2m3-3l3-3m0 0l3 3m-3-3v12"></path></svg>
                        <span class="flex-1 text-left text-[13px] font-semibold">Sales</span>
                        <svg :class="open ? 'rotate-180' : ''" class="w-3 h-3 transition-transform text-slate-300" fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M19 9l-7 7-7-7"></path></svg>
                    </button>
                    <div x-show="open" x-cloak x-transition class="bg-slate-50/50 border-l-2 border-indigo-100 ml-5 py-1">
                        <a href="<?php echo e(route('customers.index')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->routeIs('customers.*') ? 'sub-nav-active' : ''); ?>">Customers</a>
                        <a href="<?php echo e(route('products.index')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->routeIs('products.*') ? 'sub-nav-active' : ''); ?>">Products and services</a>
                        <a href="<?php echo e(route('invoices.index')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->routeIs('invoices.*') ? 'sub-nav-active' : ''); ?>">Invoices</a>
                        <a href="<?php echo e(route('invoice.payments.history')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->routeIs('invoice.payments.*') ? 'sub-nav-active' : ''); ?>">Invoice payments</a>
                        <a href="<?php echo e(route('sales-receipts.index')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->routeIs('sales-receipts.*') ? 'sub-nav-active' : ''); ?>">Sales Receipts</a>
                        <a href="<?php echo e(route('credit-memos.index')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->routeIs('credit-memos.*') ? 'sub-nav-active' : ''); ?>">Invoice Credit Memos</a>
                        <a href="<?php echo e(route('invoices.aging')); ?>"    class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->routeIs('invoices.aging') ? 'sub-nav-active' : ''); ?>">
                           Invoice Aging Analysis
                        </a>
                        
                    </div>
                </div>

               <div x-data="{ open: <?php echo e(request()->is('suppliers*') || request()->is('expenses*') ? 'true' : 'false'); ?> }">
                     <button @click="open = !open" class="w-full flex items-center px-5 py-2.5 hover:bg-slate-50 transition outline-none <?php echo e(request()->is('suppliers*') || request()->is('expenses*') ? 'text-indigo-600 font-bold' : ''); ?>">
                        <svg class="w-4 h-4 mr-3 opacity-70" fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M16 11V7a4 4 0 00-8 0v4M5 9h14l1 12H4L5 9z"></path></svg>
                           <span class="flex-1 text-left text-[13px] font-semibold">Purchases</span>
                        <svg :class="open ? 'rotate-180' : ''" class="w-3 h-3 transition-transform text-slate-300" fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M19 9l-7 7-7-7"></path></svg>
                    </button>
                    <div x-show="open" x-cloak x-transition class="bg-slate-50/50 border-l-2 border-indigo-100 ml-5 py-1">
                     <a href="<?php echo e(route('suppliers.index')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->routeIs('suppliers.index') ? 'sub-nav-active' : ''); ?>">Suppliers</a>
                     <a href="<?php echo e(route('suppliers.expenses.index')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->routeIs('expenses.*') ? 'sub-nav-active' : ''); ?>">Expenses</a>
                     <a href="<?php echo e(route('suppliers.bills.index')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->is('suppliers/bills*') ? 'sub-nav-active' : ''); ?>">Bills</a>
                     <a href="<?php echo e(route('suppliers.billpayments.index')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition">Payments</a>
                     <a href="<?php echo e(route('suppliers.bills.aging')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition">Aging Analysis</a>
                     </div>
               </div>
               
               
                
               <div x-data="{ open: <?php echo e(request()->is('assets*') ? 'true' : 'false'); ?> }">
                   <button @click="open = !open" class="w-full flex items-center px-5 py-2.5 hover:bg-slate-50 transition outline-none <?php echo e(request()->is('assets*') ? 'text-indigo-600 font-bold' : ''); ?>">
                    <svg class="w-4 h-4 mr-3 opacity-70" fill="none" stroke="currentColor" viewBox="0 0 24 24">
                      <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M19 21V5a2 2 0 00-2-2H7a2 2 0 00-2 2v16m14 0h2m-2 0h-5m-9 0H3m2 0h5M9 7h1m-1 4h1m4-4h1m-1 4h1m-5 10v-5a1 1 0 011-1h2a1 1 0 011 1v5m-4 0h4"></path>
                    </svg>
                   <span class="flex-1 text-left text-[13px] font-semibold">Fixed Assets</span>
                   <svg :class="open ? 'rotate-180' : ''" class="w-3 h-3 transition-transform text-slate-300" fill="none" stroke="currentColor" viewBox="0 0 24 24">
                     <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M19 9l-7 7-7-7"></path>
                   </svg>
                   </button>
                    <div x-show="open" x-cloak x-transition class="bg-slate-50/50 border-l-2 border-indigo-100 ml-5 py-1">
                        <a href="<?php echo e(route('assets.index')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->routeIs('assets.index') ? 'sub-nav-active' : ''); ?>">
                           Asset Register
                       </a>
                       <a href="<?php echo e(route('assets.create')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->routeIs('assets.create') ? 'sub-nav-active' : ''); ?>">
                          Add New Asset
                      </a>
                      <a href="<?php echo e(route('assets.reports.schedule')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->routeIs('assets.reports.schedule') ? 'sub-nav-active' : ''); ?>">
                          Depreciation Schedule</a>
                       <a href="#" class="block pl-6 py-1.5 text-[11px] hover:text-indigo-600 transition">Asset Disposals</a>
                      <a href="#" class="block pl-6 py-1.5 text-[11px] hover:text-indigo-600 transition">Revaluations</a>
                   </div>
                </div>
               
               
               
               <div x-data="{ open: <?php echo e(request()->is('inventory*') ? 'true' : 'false'); ?> }">
                  <button @click="open = !open" class="w-full flex items-center px-5 py-2.5 hover:bg-slate-50 transition outline-none <?php echo e(request()->is('inventory*') ? 'text-indigo-600 font-bold' : ''); ?>">
                    <svg class="w-4 h-4 mr-3 opacity-70" fill="none" stroke="currentColor" viewBox="0 0 24 24">
                       <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M20 7l-8-4-8 4m16 0l-8 4m8-4v10l-8 4m0-10L4 7m8 4v10M4 7v10l8 4"></path>
                    </svg>
                    <span class="flex-1 text-left text-[13px] font-semibold">Inventory</span>
                    <svg :class="open ? 'rotate-180' : ''" class="w-3 h-3 transition-transform text-slate-300" fill="none" stroke="currentColor" viewBox="0 0 24 24">
                      <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M19 9l-7 7-7-7"></path>
                    </svg>
                    </button>
                   <div x-show="open" x-cloak x-transition class="bg-slate-50/50 border-l-2 border-indigo-100 ml-5 py-1">
                       <a href="<?php echo e(route('products.index', ['type' => 'inventory'])); ?>"    class="block pl-6 py-1.5 hover:text-indigo-600 transition">Inventory Items</a>
                      <a href="<?php echo e(route('inventory.adjustments.index')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->is('inventory/adjustments*') ? 'sub-nav-active' : ''); ?>">Adjustments</a>
                      <a href="<?php echo e(route('inventory.transfers.index')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->is('inventory/transfers*') ? 'sub-nav-active' : ''); ?>">Transfer Orders</a>
                      <a href="<?php echo e(route('inventory.counts.index')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->is('inventory/stocktakes*') ? 'sub-nav-active' : ''); ?>">Physical Count</a>
                      <a href="<?php echo e(route('inventory.warehouses.index')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->is('inventory/warehouses*') ? 'sub-nav-active' : ''); ?>">Warehouses</a>
                      <div class="px-6 py-2 mt-1 text-[9px] font-black text-slate-400 uppercase tracking-widest border-t border-slate-100">Stock Reports</div>
                        <a href="<?php echo e(route('inventory.reports.valuation')); ?>" class="block pl-6 py-1.5 text-[11px] hover:text-indigo-600 transition">Valuation (FIFO)</a>
                        <a href="<?php echo e(route('inventory.reports.aging')); ?>" class="block pl-6 py-1.5 text-[11px] hover:text-indigo-600 transition <?php echo e(request()->routeIs('inventory.reports.aging') ? 'sub-nav-active' : ''); ?>">Stock Aging</a>
                       </div>
                    </div>
                    
                    
                    

<div x-data="{ open: <?php echo e(request()->is('payroll*') ? 'true' : 'false'); ?> }">
    <button @click="open = !open" class="w-full flex items-center px-5 py-2.5 hover:bg-slate-50 transition outline-none <?php echo e(request()->is('payroll*') ? 'text-indigo-600 font-bold' : ''); ?>">
        <svg class="w-4 h-4 mr-3 opacity-70" fill="none" stroke="currentColor" viewBox="0 0 24 24">
            <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M17 9V7a2 2 0 00-2-2H5a2 2 0 00-2 2v6a2 2 0 002 2h2m2 4h10a2 2 0 002-2v-6a2 2 0 00-2-2H9a2 2 0 00-2 2v6a2 2 0 002 2zm7-5a2 2 0 11-4 0 2 2 0 014 0z"></path>
        </svg>
        <span class="flex-1 text-left text-[13px] font-semibold">Payroll</span>
        <svg :class="open ? 'rotate-180' : ''" class="w-3 h-3 transition-transform text-slate-300" fill="none" stroke="currentColor" viewBox="0 0 24 24">
            <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M19 9l-7 7-7-7"></path>
        </svg>
    </button>
    
    <div x-show="open" x-cloak x-transition class="bg-slate-50/50 border-l-2 border-indigo-100 ml-5 py-1">
        <a href="<?php echo e(route('payroll.settings.index')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->routeIs('payroll.paye.*') ? 'sub-nav-active' : ''); ?>">Payroll Settings</a>
        <a href="<?php echo e(route('payroll.paye.index')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->routeIs('payroll.paye.*') ? 'sub-nav-active' : ''); ?>">PAYE Tax Bands</a>
        <a href="<?php echo e(route('payroll.napsa.index')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->routeIs('payroll.napsa.*') ? 'sub-nav-active' : ''); ?>">NAPSA Configuration</a>
        <a href="<?php echo e(route('payroll.nhima.index')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->routeIs('payroll.nhima.*') ? 'sub-nav-active' : ''); ?>">NHIMA Settings</a>
        <a href="<?php echo e(route('payroll.sdl.index')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->routeIs('payroll.sdl.*') ? 'sub-nav-active' : ''); ?>">SDL Settings</a>
        <a href="<?php echo e(route('payroll.periods.index')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->routeIs('payroll.periods.*') ? 'sub-nav-active' : ''); ?>">Payroll Periods</a>
        <a href="<?php echo e(route('payroll.employees.index')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->routeIs('payroll.employees.*') ? 'sub-nav-active' : ''); ?>">Employees</a>
        <a href="<?php echo e(route('payroll.preparation.index')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->routeIs('payroll.preparation.*') ? 'sub-nav-active' : ''); ?>">Payroll Preparation</a>
        
        <a href="<?php echo e(route('payroll.processing.index', ['status' => 'calculated'])); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request('status') == 'calculated' ? 'sub-nav-active' : ''); ?>">Pending Review</a>
        <a href="<?php echo e(route('payroll.processing.index', ['status' => 'approved'])); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request('status') == 'approved' ? 'sub-nav-active' : ''); ?>">Approved Payroll</a>
    </div>
</div>


                    <div x-data="{ open: false }">
                    <button @click="open = !open" class="w-full flex items-center px-5 py-2.5 hover:bg-slate-50 transition outline-none">
                        <svg class="w-4 h-4 mr-3 opacity-70" fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M9 17v-2m3 2v-4m3 4v-6m2 10H7a2 2 0 01-2-2V5a2 2 0 012-2h5.586a1 1 0 01.707.293l5.414 5.414a1 1 0 01.293.707V19a2 2 0 01-2 2z"></path></svg>
                        <span class="flex-1 text-left text-[13px] font-semibold">Reports</span>
                        <svg :class="open ? 'rotate-180' : ''" class="w-3 h-3 transition-transform text-slate-300" fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M19 9l-7 7-7-7"></path></svg>
                    </button>
                    <div x-show="open" x-cloak x-transition class="bg-slate-50/50 border-l-2 border-indigo-100 ml-5 py-1">
                        <a href="<?php echo e(route('reports.trial-balance')); ?>" 
                               class="block pl-6 py-1.5 hover:text-indigo-600 transition <?php echo e(request()->routeIs('reports.trial-balance') ? 'sub-nav-active' : ''); ?>">
                                 Trial Balance
                         </a>
                        <a href="<?php echo e(route('reports.balance-sheet')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition">Balance Sheet</a>
                        <a href="<?php echo e(route('reports.profit-loss')); ?>" class="block pl-6 py-1.5 hover:text-indigo-600 transition">Profit & Loss</a>
                        <a href="<?php echo e(route('reports.statements.create')); ?>" class="flex items-center gap-3 px-6 py-3 text-slate-600 hover:bg-indigo-50 hover:text-indigo-600 transition group">
                           <span class="text-xs font-bold uppercase tracking-wider">Financial Statements</span>
                        </a>
                    </div>
                </div>
            </nav>

            <div class="p-4 border-t border-slate-100">
                <div class="flex items-center gap-3 px-1 py-1">
                    <div class="w-8 h-8 rounded bg-indigo-600 text-white flex items-center justify-center font-black text-[10px]">
                        <?php echo e(substr(Auth::user()->first_name, 0, 1)); ?><?php echo e(substr(Auth::user()->last_name, 0, 1)); ?>

                    </div>
                    <div class="flex-1 min-w-0">
                        <p class="text-[12px] font-bold truncate text-slate-900 leading-none"><?php echo e(Auth::user()->full_name); ?></p>
                        <p class="text-[10px] text-slate-400 truncate mt-1.5 font-semibold"><?php echo e(Auth::user()->currentCompany->name ?? 'Default'); ?></p>
                    </div>
                </div>
            </div>
        </aside>

        <div class="flex-1 flex flex-col min-w-0 overflow-hidden">
        
           <header class="h-12 bg-white border-b border-slate-200 flex items-center justify-between px-8 shrink-0">
    <div class="flex-1 max-w-2xl flex items-center gap-4">
        
        <a href="<?php echo e(route('company.profile')); ?>" class="flex items-center gap-2.5 px-2 py-1 rounded hover:bg-slate-50 transition group shrink-0">
            <div class="w-7 h-7 rounded bg-indigo-50 flex items-center justify-center text-indigo-600 group-hover:bg-indigo-600 group-hover:text-white transition shadow-sm">
                <i class="fas fa-home text-[12px]"></i>
            </div>
            <span class="text-[12px] font-bold text-slate-900 group-hover:text-indigo-600 transition">
                <?php echo e(Auth::user()->currentCompany->name ?? 'Select Company'); ?>

            </span>
        </a>

        <div class="relative flex-1 max-w-xs">
            <span class="absolute inset-y-0 left-0 flex items-center pl-3">
                <svg class="w-3.5 h-3.5 text-slate-400" fill="none" stroke="currentColor" viewBox="0 0 24 24">
                    <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M21 21l-6-6m2-5a7 7 0 11-14 0 7 7 0 0114 0z"></path>
                </svg>
            </span>
            <input type="text" placeholder="Search..." class="w-full bg-slate-50 border border-transparent rounded py-1.5 pl-10 pr-4 text-[11px] focus:bg-white focus:border-slate-200 outline-none transition font-medium">
        </div>
    </div>

    <div class="flex items-center gap-5">
        <button class="text-slate-400 hover:text-indigo-600 transition relative">
            <svg class="w-5 h-5" fill="none" stroke="currentColor" viewBox="0 0 24 24">
                <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M15 17h5l-1.405-1.405A2.032 2.032 0 0118 14.158V11a6.002 6.002 0 00-4-5.659V5a2 2 0 10-4 0v.341C7.67 6.165 6 8.388 6 11v3.159c0 .538-.214 1.055-.595 1.436L4 17h5m6 0v1a3 3 0 11-6 0v-1m6 0H9"></path>
            </svg>
            <span class="absolute -top-1 -right-1 w-2 h-2 bg-rose-500 rounded-full border-2 border-white"></span>
        </button>

        <div class="h-4 w-[1px] bg-slate-200"></div>

        <form method="POST" action="<?php echo e(route('logout')); ?>">
            <?php echo csrf_field(); ?>
            <button type="submit" class="text-[12px] font-bold text-slate-500 hover:text-rose-600 transition flex items-center gap-2">
                Logout
                <svg class="w-3.5 h-3.5" fill="none" stroke="currentColor" viewBox="0 0 24 24">
                    <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M17 16l4-4m0 0l-4-4m4 4H7m6 4v1a3 3 0 01-3 3H6a3 3 0 01-3-3V7a3 3 0 013-3h4a3 3 0 013 3v1"></path>
                </svg>
            </button>
        </form>
    </div>
</header>


            <main class="flex-1 overflow-y-auto p-8 bg-[#fcfcfc]">
                <?php echo $__env->yieldContent('main-content'); ?>
            </main>
        </div>
    </div>

</body>
</html><?php /**PATH /home/edugfqvw/auraaccountify.online/portal/resources/views/layouts/aura-main.blade.php ENDPATH**/ ?>