<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Domainer | Edit subdomain</title>
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/tailwindcss/2.2.7/tailwind.min.css" />
    <link rel="stylesheet" href="/css/style.css" />
    <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.2/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-T3c6CoIi6uLrA9TneNEoa7RxnatzjcDSCmG1MXxSR1GAsXEV/Dwwykc2MPK8M2HN" crossorigin="anonymous">
</head>
<body class="bg-gray-800">
    <div class="flex w-screen h-screen flex-col items-center justify-between">
        <div class="flex flex-col justify-center items-center w-screen h-5/6">
        <% if (message.length > 0) { %>
            <div class="alert alert-danger">
                <%= message[0] %>
            </div>
        <% } %>
        <div class="welcome-card w-auto p-3 h-1/3 rounded-2xl flex flex-col justify-center items-center bg-gray-700">
            <div class="flex flex-col text-center">
                <h2 class="text-gray-100 font-bold text-2xl">Edit a subdomain</h2>
                <form action="/edit" method="post" class="flex flex-col text-center justify-center items-center">
                    <input type="hidden" name="subdomain" value="<%= subdomain %>">
                    <label for="recordType" class="text-gray-100 font-bold text-lg">Record type</label>
                    <select class="rounded-2xl text-lg text-center" id="recordType" name="recordType">
                        <option value="A">A</option>
                        <option value="AAAA">AAAA</option>
                        <option value="CNAME">CNAME</option>
                        <option value="MX">MX</option>
                    </select>
                    <label for="pointedto" class="text-gray-100 font-bold text-lg">Pointed to</label>
                    <input type="pointedto" id="pointedto" name="pointedto" class="rounded-2xl text-lg text-center">
                    <button type="submit" class="rounded-2xl bg-gray-100 w-auto pl-1 pr-1 h-8 mt-2 duration-200 hover:bg-gray-200">Edit subdomain</button>
                </form>
            </div>
        </div>
    </div>
    </div>
</body>
</html>