<!DOCTYPE html>
<html>
<head>
    <title>Upload Successful</title>
    <style>
        /* Стили для вашего шаблона */
        body {
            font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
            background-color: #f5f5f5;
            color: #312828;
            margin: 20px;
        }

        h1, h2 {
            color: #000000;
        }

        ul {
            list-style-type: none;
            padding: 0;
        }

        li {
            margin-bottom: 10px;
        }

        .test-case {
            margin-bottom: 20px;
            padding: 10px;
            background-color: #ffffff;
            border: 1px solid #e6e6e6;
            border-radius: 5px;
            box-shadow: 0 2px 4px rgba(0,0,0,0.1);
        }

        .test-case strong {
            display: block;
            margin-bottom: 5px;
            color: #010508;
            font-weight: bold;
        }

        .test-case span {
            display: block;
            margin-bottom: 5px;
            font-size: 14px;
        }

        .test-case span.description {
            margin-bottom: 0;
            color: #666;
        }

        button {
            display: block;
            margin-top: 20px;
            margin-bottom: 20px;
            border: none;
            padding: 10px 20px;
            background-color: #ffffff;
            color: #000000;
            border-radius: 6px;
            text-decoration: none;
            box-shadow: #00000033 0 2px 4px;
        }

        button:hover {
            background-color: #f1f1f1;
            opacity: 0.8;
        }

        .test-suites {
            margin-bottom: 20px;
            padding: 10px;
            background-color: #ffffff;
            border: 1px solid #e6e6e6;
            border-radius: 5px;
            box-shadow: 0 2px 4px rgba(0,0,0,0.1);
        }
        

    </style>
</head>
<body>
    <h1>Upload Successful</h1>

    <h2>Test Suites</h2>
    <div class="test-suites">
        <span>{{ created_test_suites }}</span>
    </div>
    <button type="button" class='back-to-main-btn' onclick="window.location.href='/';">Back to TestY</button>
    <h2>Test Cases</h2>
    <div class="test-cases">
        <span>{{ countTestCases() }}</span>
        {% for case in created_test_cases %}
            <div class="test-case">
                <strong>{{ case.name }}</strong>
                <span>Suite: {{ case.suite.name }}</span>
                <span class="description">Description: {{ case.description }}</span>
            </div>
        {% endfor %}
        <button type="button" class='back-to-main-btn' onclick="window.location.href='/';">Back to TestY</button>
    </div>
</body>
</html>

<script>
    function countTestCases() {
        const testCases = created_test_cases;
        return testCases.length;
    }