<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org"
      xmlns:layout="http://www.ultraq.net.nz/thymeleaf/layout"
      layout:decorator="fragments/base"
      th:with="lang=${#locale.language}" th:lang="${lang}">

<head>
  <meta content="text/html; charset=utf-8" http-equiv="Content-Type">
  <meta name="viewport" content="width=device-width, initial-scale=1">
  <link rel="stylesheet" href="../webcontent/css/css_country.css" th:href="@{/static/css/css_country.css}"/>
  <script type="text/javascript" src="../webcontent/js/js_country.js" th:attr="src=@{/static/js/js_country.js}"></script>
  <title th:text="#{gui.countryselection.title}">eIDAS-Login Länderauswahl</title>
</head>

<body>
    <div id="page">
      <div class="languageselection" th:include="language_selection :: selectlanguage">
          LanguageSelectionBlock
      </div>

        <h2 th:text="#{gui.countryselection.header.selection}"> Select your country </h2>
        <div id="country">

            <form class="block" method="post" action="$contextPath$submitEndpoint" th:attr="action=@{${submitEndpoint}}">
                <a><img class="countryimage" src="../webcontent/img/countries/germany-eu_.png" alt="Germany-eID"
                        th:attr="src=@{/img/countries/germany-eu_.png},alt=#{gui.countryselection.country.de.logo.alt}"/></a>
                <input type="submit" role="button" value="Deutschland / Germany" th:attr="value=#{gui.countryselection.country.de}" />
                <input type="hidden" name="selectedCountry" value="DE">
                <input  type="hidden" name="pendingid"  value="$pendingid" th:attr="value=${pendingid}" />
                <select id="testEnvironment" name="selectedEnvironment">
                       <option value="prod" th:text="#{gui.countryselection.mode.prod}">Production</option>
                       <option value="qs" th:text="#{gui.countryselection.mode.qs}">QS</option>
                       <option value="test" th:text="#{gui.countryselection.mode.test}">Testing</option>
                       <option value="dev" th:text="#{gui.countryselection.mode.dev}">Development</option>
                </select>
            </form>

            <form class="block" method="post" action="$contextPath$submitEndpoint" th:attr="action=@{${submitEndpoint}}">
                <a><img class="countryimage" src="../webcontent/img/countries/Belgium-EU_gray.png" alt="Belgium-eID"
                        th:attr="src=@{img/countries/Belgium-EU_gray.png},alt=#{gui.countryselection.country.be.logo.alt}"/></a>
                <input type="submit" value="Belgium" th:attr="value=#{gui.countryselection.country.be}">
            </form>

        </div>

        <form   class="block" method="post"  action="$contextPath$submitEndpoint" th:attr="action=@{${submitEndpoint}}">
          <input  type="submit" class="btn btn-outline-primary btn-block" value="Abbrechen/Cancel" th:attr="value=#{gui.countryselection.cancel}">
          <input  type="hidden" name="stopAuthProcess" value="true" >
          <input  type="hidden" name="pendingid"  value="$pendingid" th:attr="value=${pendingid}">
        </form>

    </div>
</body>
</html>