{{define "home"}}
<!doctype html>
<html lang="en">
<head>
  <title>{{.Title}}</title>
  {{template "head" .}}
</head>
<body>
  {{template "nav" .}}
  {{if .Msg}}<div class="flash flash-ok">{{.Msg}}</div>{{end}}
  {{if .Err}}<div class="flash flash-err">{{.Err}}</div>{{end}}
  <h1>QC Text Builder</h1>
  <p>Minimal admin UI for AI template workflow.</p>
  <table>
    <tr><th>Available templates</th><td>{{.TemplateCount}}</td></tr>
  </table>
  <p>
    <a href="/templates">Open Templates</a>
  </p>
</body>
</html>
{{end}}
