templates/header.html.twig line 1
<header class="fixed top-0 left-0 right-0 z-50 bg-white/80 backdrop-blur-lg border-b border-gray-100 transition-all duration-300"x-data="{ scrolled: false, mobileMenu: false }"x-init="() => { }"@scroll.window="scrolled = window.scrollY > 50"><div class="container mx-auto px-4"><div class="flex items-center justify-between h-20"><!-- Logo --><a href="{{ path('app_home') }}" class="flex items-center space-x-2 group"><img src="{{ asset('/image/metfpa.png') }}" class="relative h-10 w-auto" alt="METFPA"><img src="{{ asset('/image/logo.png') }}" class="relative h-10 w-auto" alt="DAIP"></a><!-- Navigation Desktop --><nav class="hidden lg:flex items-center space-x-8"><a href="{{ path('app_home') }}" class="text-gray-700 hover:text-primary-600 font-medium transition {{ app.current_route == 'app_home' ? 'text-primary-600' : '' }}">Accueil</a><a href="{{ path('app_candidature_index') }}" class="text-gray-700 hover:text-primary-600 font-medium transition {{ app.current_route starts with 'app_candidature' ? 'text-primary-600' : '' }}">Candidatures</a><a href="#contact" class="text-gray-700 hover:text-primary-600 font-medium transition">Contact</a></nav><!-- Actions --><div class="flex items-center space-x-4">{% if app.user %}<a href="{{ path('app_dashboard') }}" class="hidden md:flex items-center space-x-2 bg-gradient-to-r from-orange-300 to-orange-500 text-white px-6 py-2.5 rounded-xl hover:from-orange-400 hover:to-orange-600 transition shadow-lg"><i class="fas fa-tachometer-alt"></i><span>Dashboard</span></a>{% else %}<a href="{{ path('app_login') }}" class="hidden md:flex items-center space-x-2 bg-gradient-to-r from-orange-300 to-orange-500 text-white px-6 py-2.5 rounded-xl hover:from-orange-400 hover:to-orange-600 transition shadow-lg"><i class="fas fa-sign-in-alt"></i><span>Connexion</span></a>{% endif %}<!-- Menu mobile button --><button @click="mobileMenu = !mobileMenu;"class="lg:hidden w-10 h-10 rounded-lg bg-gray-100 text-gray-700 hover:bg-primary-600 hover:text-white transition relative z-50 focus:outline-none":aria-expanded="mobileMenu"><i class="fas fa-bars" x-show="!mobileMenu"></i><i class="fas fa-times" x-show="mobileMenu"></i></button></div></div></div><!-- Menu mobile --><div x-show="mobileMenu"x-cloakx-transition:enter="transition ease-out duration-300"x-transition:enter-start="opacity-0 -translate-y-2"x-transition:enter-end="opacity-100 translate-y-0"x-transition:leave="transition ease-in duration-200"x-transition:leave-start="opacity-100 translate-y-0"x-transition:leave-end="opacity-0 -translate-y-2"class="lg:hidden absolute top-20 left-0 right-0 bg-white border-t border-gray-100 shadow-xl z-40 max-h-[calc(100vh-5rem)] overflow-y-auto"><div class="container mx-auto px-4 py-6"><nav class="flex flex-col space-y-3"><a href="{{ path('app_home') }}"@click="mobileMenu = false"class="flex items-center px-4 py-3 rounded-xl bg-gray-50 text-gray-700 hover:bg-primary-50 hover:text-primary-600 font-medium transition"><i class="fas fa-home w-6 mr-3 text-primary-500"></i>Accueil</a><a href="{{ path('app_candidature_index') }}"@click="mobileMenu = false"class="flex items-center px-4 py-3 rounded-xl bg-gray-50 text-gray-700 hover:bg-primary-50 hover:text-primary-600 font-medium transition"><i class="fas fa-file-alt w-6 mr-3 text-primary-500"></i>Candidatures</a><a href="#contact"@click="mobileMenu = false"class="flex items-center px-4 py-3 rounded-xl bg-gray-50 text-gray-700 hover:bg-primary-50 hover:text-primary-600 font-medium transition"><i class="fas fa-envelope w-6 mr-3 text-primary-500"></i>Contact</a><div class="border-t border-gray-200 my-4"></div>{% if app.user %}<a href="{{ path('app_dashboard') }}"@click="mobileMenu = false"class="flex items-center px-4 py-3 rounded-xl bg-gradient-to-r from-orange-300 to-orange-500 text-white font-medium"><i class="fas fa-tachometer-alt w-6 mr-3"></i>Dashboard</a><a href="{{ path('app_logout') }}"@click="mobileMenu = false"class="flex items-center px-4 py-3 rounded-xl bg-red-50 text-red-600 hover:bg-red-100 font-medium transition"><i class="fas fa-sign-out-alt w-6 mr-3"></i>Déconnexion</a>{% else %}<a href="{{ path('app_login') }}"@click="mobileMenu = false"class="flex items-center px-4 py-3 rounded-xl bg-gradient-to-r from-orange-300 to-orange-500 text-white font-medium"><i class="fas fa-sign-in-alt w-6 mr-3"></i>Connexion</a><a href="{{ path('app_register') }}"@click="mobileMenu = false"class="flex items-center px-4 py-3 rounded-xl bg-green-50 text-green-600 hover:bg-green-100 font-medium transition"><i class="fas fa-user-plus w-6 mr-3"></i>Inscription</a>{% endif %}</nav></div></div></header><!-- Espace pour compenser le header fixe --><div class="h-20"></div><style>[x-cloak] { display: none !important; }</style>