<!DOCTYPE html>
<html lang="fr">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title><?php echo $__env->yieldContent('title', 'LabConnect'); ?></title>
    <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.3/dist/css/bootstrap.min.css" rel="stylesheet">
    <link rel="preconnect" href="https://fonts.googleapis.com">
    <style>
        body { background-color: #f4f6f9; }
        .navbar-brand { font-weight: 700; letter-spacing: .5px; }
        .badge-urgent { background-color: #dc3545; }
        .badge-ecart { background-color: #fd7e14; }
        .table-actions form { display: inline-block; }
        .card { border: none; box-shadow: 0 1px 3px rgba(0,0,0,.08); }
    </style>
</head>
<body>
<?php if(auth()->guard()->check()): ?>
<nav class="navbar navbar-expand-lg navbar-dark bg-dark mb-4">
    <div class="container-fluid">
        <a class="navbar-brand" href="<?php echo e(route('dashboard')); ?>">LabConnect</a>
        <button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navMenu">
            <span class="navbar-toggler-icon"></span>
        </button>
        <div class="collapse navbar-collapse" id="navMenu">
            <ul class="navbar-nav me-auto">
                <?php if(auth()->user()->isAdmin()): ?>
                    <li class="nav-item"><a class="nav-link" href="<?php echo e(route('admin.dashboard')); ?>">Tableau de bord</a></li>
                    <li class="nav-item"><a class="nav-link" href="<?php echo e(route('admin.requests.index')); ?>">Demandes</a></li>
                    <li class="nav-item"><a class="nav-link" href="<?php echo e(route('admin.partners.index')); ?>">Partenaires</a></li>
                    <li class="nav-item"><a class="nav-link" href="<?php echo e(route('admin.users.index')); ?>">Comptes</a></li>
                <?php elseif(auth()->user()->isPartner()): ?>
                    <li class="nav-item"><a class="nav-link" href="<?php echo e(route('partner.dashboard')); ?>">Tableau de bord</a></li>
                    <li class="nav-item"><a class="nav-link" href="<?php echo e(route('partner.requests.index', 'prelevement')); ?>">Prelevement</a></li>
                    <li class="nav-item"><a class="nav-link" href="<?php echo e(route('partner.requests.index', 'consommable')); ?>">Consommables</a></li>
                    <li class="nav-item"><a class="nav-link" href="<?php echo e(route('partner.requests.index', 'reclamation')); ?>">Reclamations</a></li>
                    <li class="nav-item"><a class="nav-link" href="<?php echo e(route('partner.requests.index', 'resultat')); ?>">Resultats</a></li>
                <?php elseif(auth()->user()->isCourier()): ?>
                    <li class="nav-item"><a class="nav-link" href="<?php echo e(route('courier.dashboard')); ?>">Tableau de bord</a></li>
                    <li class="nav-item"><a class="nav-link" href="<?php echo e(route('courier.requests.index')); ?>">Mes demandes</a></li>
                <?php endif; ?>
            </ul>
            <span class="navbar-text text-light me-3"><?php echo e(auth()->user()->name); ?> (<?php echo e(auth()->user()->role); ?>)</span>
            <form action="<?php echo e(route('logout')); ?>" method="POST">
                <?php echo csrf_field(); ?>
                <button class="btn btn-outline-light btn-sm">Deconnexion</button>
            </form>
        </div>
    </div>
</nav>
<?php endif; ?>

<div class="container pb-5">
    <?php if(session('success')): ?>
        <div class="alert alert-success alert-dismissible fade show" role="alert">
            <?php echo e(session('success')); ?>

            <button type="button" class="btn-close" data-bs-dismiss="alert"></button>
        </div>
    <?php endif; ?>
    <?php if(session('warning')): ?>
        <div class="alert alert-warning alert-dismissible fade show" role="alert">
            <?php echo e(session('warning')); ?>

            <button type="button" class="btn-close" data-bs-dismiss="alert"></button>
        </div>
    <?php endif; ?>
    <?php if($errors->any()): ?>
        <div class="alert alert-danger">
            <ul class="mb-0">
                <?php $__currentLoopData = $errors->all(); $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $error): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                    <li><?php echo e($error); ?></li>
                <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
            </ul>
        </div>
    <?php endif; ?>

    <?php echo $__env->yieldContent('content'); ?>
</div>

<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.3/dist/js/bootstrap.bundle.min.js"></script>
</body>
</html>
<?php /**PATH /home/smartch/capara/resources/views/layouts/app.blade.php ENDPATH**/ ?>