<!DOCTYPE html>
<html lang="de">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Event Feedback</title>
    <link rel="stylesheet" href="/static/style.css">
    <link rel="icon" href="/static/logo.png" type="image/png">
    <style>
        body {
            background-image: url('/static/background.png');
            background-size: cover;
            background-position: center;
            background-repeat: no-repeat;
            height: 100vh;
            margin: 0;
            display: flex;
            justify-content: center;
            align-items: center;
            overflow: hidden;
        }
        .content {
            background: rgba(255, 255, 255, 0.8);
            padding: 20px;
            border-radius: 8px;
            box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
            width: 80%;
            max-width: 600px;
            max-height: 90vh;
            overflow-y: auto;
            text-align: center;
        }
        .content form {
            display: flex;
            flex-direction: column;
            align-items: center;
        }
        .content form label {
            margin-top: 10px;
            width: 100%;
            text-align: left;
        }
        .content form input,
        .content form textarea,
        .content form select {
            width: 100%;
            padding: 10px;
            margin-top: 5px;
            border: 1px solid #ccc;
            border-radius: 4px;
        }
        .content form button {
            background-color: #007BFF;
            color: white;
            border: none;
            padding: 10px 15px;
            cursor: pointer;
            border-radius: 4px;
            margin-top: 20px;
        }
        .content form button:hover {
            background-color: #0056b3;
        }
    </style>
    <script>
        function toggleOtherInput(selectId, inputId) {
            var selectElement = document.getElementById(selectId);
            var inputElement = document.getElementById(inputId);
            if (selectElement.value === "Anderes") {
                inputElement.style.display = "block";
            } else {
                inputElement.style.display = "none";
            }
        }
    </script>
</head>
<body>
    {% include "top_bar.html" %}
    <div class="content">
        <h1>Event Feedback</h1>
        <form method="POST">
            <input type="hidden" name="csrf_token" value="{{ csrf_token() }}">
            <label for="event_name">Event:</label>
            <select id="event_name" name="event_name" onchange="toggleOtherInput('event_name', 'other_event_name')" required>
                <option value="Simon Says">Simon Says</option>
                <option value="Speedevent">Speedevent</option>
                <option value="SCP999">SCP999</option>
                <option value="Hide and Seek mit SCP939">Hide and Seek mit SCP939</option>
                <option value="Hide and Seek mit Scaling">Hide and Seek mit Scaling</option>
                <option value="Team Deathmatch auf der Surface">Team Deathmatch auf der Surface</option>
                <option value="Team Deathmatch in der Heavy Zone">Team Deathmatch in der Heavy Zone</option>
                <option value="Team Deathmatch in der Light">Team Deathmatch in der Light</option>
                <option value="Anderes">Anderes</option>
            </select>
            <input type="text" id="other_event_name" name="other_event_name" placeholder="Event Name eingeben" style="display:none;">
            
            <label for="event_progress">Verlauf des Events:</label>
            <textarea id="event_progress" name="event_progress" required></textarea>
            <input type="text" id="other_event_progress" name="other_event_progress" placeholder="Verlauf des Events eingeben" style="display:none;">
            
            <label for="event_end">Ende des Events:</label>
            <textarea id="event_end" name="event_end" required></textarea>
            <input type="text" id="other_event_end" name="other_event_end" placeholder="Ende des Events eingeben" style="display:none;">
            
            <label for="community_feedback">Feedback der Community:</label>
            <textarea id="community_feedback" name="community_feedback" required></textarea>
            <input type="text" id="other_community_feedback" name="other_community_feedback" placeholder="Feedback der Community eingeben" style="display:none;">
            
            <label for="improvement_suggestions">Verbesserungsvorschläge:</label>
            <textarea id="improvement_suggestions" name="improvement_suggestions" required></textarea>
            
            <button type="submit">Abschicken</button>
        </form>
        <form action="{{ url_for('dashboard') }}" method="get">
            <input type="hidden" name="csrf_token" value="{{ csrf_token() }}">
            <button type="submit">Zurück</button>
        </form>
    </div>
</body>
</html>
