<!doctype html>
<html>
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <script src="https://cdn.tailwindcss.com"></script>
    <title>Admin Login</title>
</head>
<body>
<div class="grid place-items-center h-screen">
    <form method="POST" action="{{ route('admin.post.login')  }}" class="rounded-md shadow-md p-4 w-1/3">
        @csrf
        @if(session()->has('error'))
            <div class="p-4 bg-red-500 text-white w-full rounded-md">
                {{ session()->get('error') }}
            </div>
            <div class="pb-2"></div>
        @endif
        <span class="text-lg">Login as Admin</span>
        <div class="pt-4"></div>
        <div class="grid gap-4">
            <div class="grid gap-2">
                <label for="code">Pin Code</label>
                <input type="number" name="code" id="code" class="rounded-md border p-3" />
            </div>
            <div>
                <button type="submit" class="bg-blue-500 rounded-md px-4 py-2 text-white">Login</button>
            </div>
        </div>
    </form>
</div>
</body>
</html>
