<script lang="ts">
	import { resolveRoute } from '$app/paths';
	import ThemeToggle from '$lib/components/ThemeToggle.svelte';

	const chatHref = resolveRoute('/chat');
	const lineageHref = resolveRoute('/lineage');
	const memoryHref = resolveRoute('/memory');
	const auditHref = resolveRoute('/audit');
</script>

<div class="flex min-h-screen flex-col items-center bg-white dark:bg-gray-900 px-4">
	<div class="absolute right-4 top-4">
		<ThemeToggle />
	</div>
	<h1 class="text-2xl md:text-3xl font-bold text-center mt-8 text-gray-900 dark:text-gray-100">LLM Multiverse UI</h1>
	<p class="text-center text-gray-600 dark:text-gray-400 mt-2">Orchestration interface</p>
	<nav class="flex flex-col sm:flex-row justify-center gap-3 sm:gap-4 mt-6 w-full max-w-md sm:max-w-none sm:w-auto">
		<!-- eslint-disable-next-line svelte/no-navigation-without-resolve -- resolveRoute is resolve; plugin does not recognize the alias -->
		<a href={chatHref} class="rounded-lg bg-blue-600 px-4 py-3 sm:py-2 text-center text-sm font-medium text-white hover:bg-blue-700">Chat</a>
		<!-- eslint-disable-next-line svelte/no-navigation-without-resolve -- resolveRoute is resolve; plugin does not recognize the alias -->
		<a href={lineageHref} class="rounded-lg bg-gray-100 dark:bg-gray-700 px-4 py-3 sm:py-2 text-center text-sm font-medium text-gray-700 dark:text-gray-300 hover:bg-gray-200 dark:hover:bg-gray-600">Agent Lineage</a>
		<!-- eslint-disable-next-line svelte/no-navigation-without-resolve -- resolveRoute is resolve; plugin does not recognize the alias -->
		<a href={memoryHref} class="rounded-lg bg-gray-100 dark:bg-gray-700 px-4 py-3 sm:py-2 text-center text-sm font-medium text-gray-700 dark:text-gray-300 hover:bg-gray-200 dark:hover:bg-gray-600">Memory Candidates</a>
		<!-- eslint-disable-next-line svelte/no-navigation-without-resolve -- resolveRoute is resolve; plugin does not recognize the alias -->
		<a href={auditHref} class="rounded-lg bg-gray-100 dark:bg-gray-700 px-4 py-3 sm:py-2 text-center text-sm font-medium text-gray-700 dark:text-gray-300 hover:bg-gray-200 dark:hover:bg-gray-600">Audit Log</a>
	</nav>
</div>
