<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Sign up to Friendo!</title>
    <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.1.3/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-1BmE4kWBq78iYhFldvKuhfTAU6auU8tT94WrHftjDbrCEXSU1oBoqyl2QvZ6jIW3" crossorigin="anonymous">
    <link rel="stylesheet" href="css/register.css" />
</head>
<body>
    <header>
        <nav class="navbar navbar-expand-sm navbar-dark bg-dark">
            <div class="container">
                <a class="navbar-brand" href="/">Friendo</a>
                <button class="navbar-toggler" type="button" data-bs-toggle="collapse"
                    data-bs-target="#navbarSupportedContent" aria-controls="navbarSupportedContent"
                    aria-expanded="false" aria-label="Toggle navigation">
                    <span class="navbar-toggler-icon"></span>
                </button>
                <div class="collapse navbar-collapse" id="navbarSupportedContent">
                    <ul class="navbar-nav mb-2 mb-lg-0">
                        <li class="nav-item">
                            <a class="nav-link" aria-current="page" href="/">Home</a>
                        </li>
                        <li class="nav-item">
                            <a class="nav-link disabled" href="/search">Search</a>
                        </li>
                        <li class="nav-item">
                            <a class="nav-link disabled" href="#">Contact</a>
                        </li>
                    </ul>
                    <ul class="navbar-nav ms-auto mb-2 mb-lg-0">
                        <li class="nav-item">
                            <a href="/login" class="nav-link d-sm-none">Login</a>
                        </li>
                        <li class="nav-item dropdown d-none d-sm-block">
                            <a class="nav-link dropdown-toggle" href="#" id="navbarDropdown" role="button"
                                data-bs-toggle="dropdown" aria-expanded="false">Login</a>
                            <ul class="dropdown-menu">
                                <li>
                                    <form class="px-3 py-3" action="/login" method="POST">
                                        <div class="mb-3 text-center">
                                            <label for="dropdownEmail" class="form-label">Email address</label>
                                            <input type="email" class="form-control rounded-pill" id="dropdownEmail"
                                                name="email" required placeholder="email@example.com" />
                                        </div>
                                        <div class="mb-3 text-center">
                                            <label for="dropdownPassword" class="form-label">Password</label>
                                            <input type="password" class="form-control rounded-pill"
                                                id="dropdownPassword" name="password" required placeholder="password" />
                                        </div>
                                        <div class="d-flex justify-content-center mb-3">
                                            <button type="submit" class="btn btn-primary loginPopupButton">
                                                Log in
                                            </button>
                                        </div>
                                        <div class="text-center">
                                            <span class="mb-1 d-block text-break">Don't have an account?</span>
                                            <a href="/register">You can sign up instead</a>
                                        </div>
                                    </form>
                                </li>
                            </ul>
                        </li>
                    </ul>
                </div>
            </div>
        </nav>
    </header>
    <main>
        <div class="container">
            <div class="row justify-content-center">
                <div class="col-12 col-sm-9 col-md-8 col-lg-6 col-xxl-5">
                    <form id="form-style" class="mt-3 mb-3" action="/register" method="POST">
                        <div class="mb-2">
                            <label for="name">Name:</label>
                            <input class="form-control" id="name" name="firstName" type="text"
                                placeholder="first name" required />
                        </div>
                        <div class="mb-3">
                            <label for="email" class="form-label">Email:</label>
                            <input type="email" class="form-control" id="email" name="email"
                                placeholder="email" required />
                            <div class="form-text text-break">
                                We will
                                <span class="fw-bold">never</span> share your email with anyone.
                                Don't worry.
                            </div>
                        </div>
                        <div class="mb-1">
                            <label for="password">Password:</label>
                            <input type="password" class="form-control" name="password"
                                id="password" placeholder="password" minlength="8" required />
                        </div>
                        <div class="mb-3">
                            <input type="password" class="form-control" name="rpassword"
                                id="rpassword" placeholder="confirm password" minlength="8"
                                required />
                        </div>
                        <div class="mb-3">
                            <label class="d-block mb-1" for="gender">Gender:</label>
                            <div class="form-check-inline">
                                <input class="form-check-input" type="radio" name="gender" id="male"
                                    value="1" checked required />
                                <label class="form-check-label" for="male">Male</label>
                            </div>
                            <div class="form-check-inline">
                                <input class="form-check-input" type="radio" name="gender"
                                    id="female" value="2" required />
                                <label class="form-check-label" for="female">Female</label>
                            </div>
                            <div class="form-check-inline">
                                <input class="form-check-input" type="radio" name="gender"
                                    id="other" value="3" required />
                                <label class="form-check-label" for="other">Other</label>
                            </div>
                        </div>
                        <button id="regbutton" type="submit" class="btn btn-primary w-100 registerButton disabled">
                            Sign up
                        </button>
                    </form>
                </div>
            </div>
        </div>
    </main>
    <script src="https://cdn.jsdelivr.net/npm/bootstrap@5.1.3/dist/js/bootstrap.bundle.min.js" integrity="sha384-ka7Sk0Gln4gmtz2MlQnikT1wXgYsOg+OMhuP+IlRH9sENBO0LRn5q+8nbTov4+1p" crossorigin="anonymous"></script>
    <script src="javascript/register.js"></script>
</body>
</html>