<!DOCTYPE html>
<html lang="ru">
<head>
    <meta charset="UTF-8">
    <title>Редактирование судьи</title>
    <link rel="icon" href="/static/smith.ico" type="image/x-icon">
    <style>
        :root {
            --bg: #0f1115; --panel: #171a21; --panel-2: #1d222b; --border: #2b3240;
            --text: #e8ecf3; --muted: #9aa4b2; --accent: #4f8cff; --shadow: 0 10px 30px rgba(0,0,0,.35); --radius: 16px;
        }
        * { box-sizing: border-box; }
        body { margin: 0; background: var(--bg); color: var(--text); font-family: Arial, sans-serif; }
        .page { max-width: 900px; margin: 0 auto; padding: 24px; }
        .panel { background: var(--panel); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); padding: 20px; }
        .title { font-size: 24px; font-weight: 700; margin-bottom: 18px; }
        .small-meta { margin-bottom: 16px; color: var(--muted); font-size: 13px; }
        .form-grid { display: grid; grid-template-columns: 1fr; gap: 16px; }
        .form-group { display: flex; flex-direction: column; gap: 6px; }
        label { color: var(--muted); font-size: 13px; font-weight: 600; }
        input[type="text"] { min-height: 42px; padding: 0 12px; border-radius: 10px; border: 1px solid var(--border); background: var(--panel-2); color: var(--text); }
        .actions { margin-top: 20px; display: flex; gap: 10px; }
        .btn { min-height: 42px; padding: 0 14px; border: none; border-radius: 10px; cursor: pointer; font-weight: 600; text-decoration: none; display: inline-flex; align-items: center; }
        .btn-primary { background: var(--accent); color: white; }
        .btn-secondary { background: transparent; color: var(--text); border: 1px solid var(--border); }
    </style>
</head>
<body>
    <div class="page">
        <div class="panel">
            <div class="title">Редактирование судьи</div>
            <div class="small-meta">ID: {{ referee.id }}</div>

            <form method="post" action="/admin/db/referees/{{ referee.id }}/edit">
                <div class="form-grid">
                    <div class="form-group">
                        <label>ФИО</label>
                        <input type="text" name="full_name" value="{{ referee.full_name }}">
                    </div>

                    <div class="form-group">
                        <label>External ID</label>
                        <input type="text" name="external_id" value="{{ referee.external_id }}">
                    </div>
                </div>

                <div class="actions">
                    <button type="submit" class="btn btn-primary">Сохранить</button>
                    <a href="/admin/db/referees" class="btn btn-secondary">К списку</a>
                    <a href="/admin/db" class="btn btn-secondary">Разделы</a>
                </div>
            </form>
        </div>
    </div>
</body>
</html>