@php
    $adminNavItems = [
        ['route' => 'admin.dashboard', 'icon' => 'fas fa-tachometer-alt', 'label' => 'Dashboard', 'pattern' => 'admin.dashboard'],
        ['route' => 'admin.members.index', 'icon' => 'fas fa-users', 'label' => 'Members', 'pattern' => 'admin.members.*'],
        ['route' => 'admin.coaches.index', 'icon' => 'fas fa-dumbbell', 'label' => 'Coaches', 'pattern' => 'admin.coaches.*'],
        ['route' => 'admin.referees.index', 'icon' => 'fas fa-gavel', 'label' => 'Referees', 'pattern' => 'admin.referees.*'],
        ['route' => 'admin.events.index', 'icon' => 'fas fa-calendar-alt', 'label' => 'Events', 'pattern' => 'admin.events.*'],
        ['route' => 'admin.news.index', 'icon' => 'fas fa-newspaper', 'label' => 'News', 'pattern' => 'admin.news.*'],
        ['route' => 'admin.albums.index', 'icon' => 'fas fa-images', 'label' => 'Gallery', 'pattern' => 'admin.albums.*'],
        ['route' => 'admin.achievements.index', 'icon' => 'fas fa-trophy', 'label' => 'Achievements', 'pattern' => 'admin.achievements.*'],
        ['route' => 'admin.settings', 'icon' => 'fas fa-cog', 'label' => 'Settings', 'pattern' => 'admin.settings*'],
        ['route' => 'admin.logs', 'icon' => 'fas fa-history', 'label' => 'Logs', 'pattern' => 'admin.logs*'],
    ];
@endphp

<!-- Admin Operations Navigation Sub-Bar -->
<section style="background: var(--off-white); border-bottom: 1px solid var(--gray-200); padding: 12px 0;">
    <div class="container" style="display: flex; gap: 8px; flex-wrap: wrap;">
        @foreach($adminNavItems as $item)
            @php
                $isActive = request()->routeIs($item['pattern']);
            @endphp
            <a href="{{ route($item['route']) }}" class="btn {{ $isActive ? 'btn-blue' : '' }}" style="{{ $isActive ? 'padding: 8px 16px; font-size: 0.8rem;' : 'background: var(--gray-200); color: var(--gray-700); padding: 8px 16px; font-size: 0.8rem;' }}">
                <i class="{{ $item['icon'] }}"></i> {{ $item['label'] }}
            </a>
        @endforeach
    </div>
</section>
