<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.5/dist/css/bootstrap.min.css" rel="stylesheet"
        integrity="sha384-SgOJa3DmI69IUzQ2PVdRZhwQ+dy64/BUtbMJw1MZ8t5HZApcHrRKUc4W0kG879m7" crossorigin="anonymous">
    <title>Login</title>
    <style>
        .rounded-input {
            border-radius: 20px;
        }

        .split-background {
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 50vh;
            background-color: #424D66;
            z-index: -1;
        }

        @keyframes moveLeftRight {
            0% {
                transform: translateX(0);
            }

            100% {
                transform: translateX(1366px);
            }
        }

        .logo {
            margin-top: 70px;
            width: 770px;
            height: auto;
        }

        .car-image-container {
            position: fixed;
            bottom: 33px;
        }

        .animate {
            animation: moveLeftRight 15s infinite alternate;
        }
    </style>
</head>

<body>
    <div class="split-background">
        <div class="container-fluid text-center">
            <img src="{{ url_for('static', filename='images/logo-light.png') }}" alt="Logo" class="logo img-fluid mt-5">
        </div>
    </div>
    <div class="container d-flex justify-content-center align-items-center" style="min-height: 100vh;">
        <div class="col-md-6 col-lg-4">
            <form method="POST" class="p-5 border rounded-input shadow-sm bg-white bg-opacity-75">
                {{form.hidden_tag()}}
                <div class=" p-4 border rounded-input shadow-sm bg-white">
                    <label for="username" class="form-label text-center w-100">Username</label>
                    {{form.username(class="form-control rounded-input")}}
                    <label for="password" class="form-label text-center w-100">Password</label>
                    {{form.password(class="form-control rounded-input")}}
                    <br>
                    <div class="d-grid">
                        {{form.submit(class="btn btn-dark rounded-input px-4 mx-auto w-50")}}
                    </div>
                </div>
            </form>
        </div>
    </div>
    <div class="car-image-container">
        <img src="{{ url_for('static', filename='images/car.png') }}" alt="Moving Image" class="animate">
    </div>
    <footer class="py-3 bg-dark text-white fixed-bottom"">
                <div class=" container text-center">
        <span class="text-muted"> </span>
        </div>
    </footer>
</body>

</html>