<!DOCTYPE html>
<html lang="de">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>LiveComponent Autocomplete Demo</title>
    <style>
        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
        }

        body {
            font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
            padding: 2rem;
            background: #f5f5f5;
        }

        .container {
            max-width: 900px;
            margin: 0 auto;
        }

        h1 {
            margin-bottom: 1rem;
            color: #333;
        }

        .intro {
            background: white;
            padding: 1.5rem;
            border-radius: 8px;
            margin-bottom: 2rem;
            box-shadow: 0 2px 4px rgba(0,0,0,0.1);
        }

        .intro h2 {
            font-size: 1.25rem;
            margin-bottom: 1rem;
            color: #444;
        }

        .feature-list {
            line-height: 1.8;
            color: #666;
        }

        .feature-list li {
            margin-bottom: 0.5rem;
        }

        .demo-section {
            margin-bottom: 2rem;
        }
    </style>
</head>
<body data-module="livecomponent">
    <div class="container">
        <h1>🎯 LiveComponent Autocomplete Demo</h1>

        <div class="intro">
            <h2>Intelligent Autocomplete with Context Switching</h2>
            <ul class="feature-list">
                <li>✅ <strong>Context-Aware:</strong> Different suggestions for different contexts</li>
                <li>✅ <strong>Smart Sorting:</strong> Exact matches first, then starts-with, then contains</li>
                <li>✅ <strong>Debouncing:</strong> 200ms delay for optimal performance</li>
                <li>✅ <strong>Recent Searches:</strong> Track and reuse recent selections</li>
                <li>✅ <strong>Visual Feedback:</strong> Icons and categories for each suggestion</li>
                <li>✅ <strong>Minimum Characters:</strong> Shows hint when less than 2 characters</li>
            </ul>
        </div>

        <div class="demo-section">
            {{autocomplete}}
        </div>
    </div>
</body>
</html>
