<?php $err = $error ?? ''; ?>
<!DOCTYPE html>
<html lang="tr">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Giriş — Yönetim</title>
<link rel="stylesheet" href="<?= e(asset('assets/css/admin.css')) ?>">
</head>
<body class="login-body">
<div class="login-card">
    <div class="login-brand"><?= e(setting('business_name','QR Menü')) ?></div>
    <p class="login-sub">Yönetim Paneli Girişi</p>
    <?php if ($err): ?><div class="flash error"><?= e($err) ?></div><?php endif; ?>
    <form method="post" action="<?= e(url('admin/login')) ?>">
        <?= csrf_field() ?>
        <label>Kullanıcı Adı</label>
        <input name="username" autofocus required autocomplete="username">
        <label>Şifre</label>
        <input name="password" type="password" required autocomplete="current-password">
        <button class="btn-primary" type="submit">Giriş Yap</button>
    </form>
    <a class="login-back" href="<?= e(url('/')) ?>">← Siteye dön</a>
</div>
</body>
</html>
