@import url('https://fonts.googleapis.com/css2?family=DM+Serif+Text:ital@0;1&display=swap');
:root{
  --accent-color: #8672FF;
  --base-color: white;
  --text-color: #2E2B41;
  --input-color: #F3F0FF;
}
*{
  margin: 0;
  padding: 0;
}
html{
  font-family: "DM Serif Text", serif;
  font-size: 12pt;
  font-weight: 400;
  font-style: normal;
  color: var(--text-color);
}
body{
  min-height: 100vh;
  background-image: url('Oldie-Helper.png');
  background-position: center;
  background-size: cover;
}
.wrapper{
  box-sizing: border-box;
  background-color: var(--base-color);
  height: 100vh;
  width: max(40%, 600px);
  padding: 10px;
  border-radius: 0 20px 20px 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}
h1{
  font-size: 3rem;
  font-weight: 900;
  text-transform: uppercase;
}
form{
  width: min(400px, 100%);
  margin-top: 20px;
  margin-bottom: 50px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}
form > div{
  width: 100%;
  display: flex;
  justify-content: center;
}
form label{
  flex-shrink: 0;
  height: 50px;
  width: 50px;
  background-color: var(--accent-color);
  fill: var(--base-color);
  color: var(--base-color);
  border-radius: 10px 0 0 10px;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 1.5rem;
  font-weight: 500;
}
form input{
  box-sizing: border-box;
  flex-grow: 1;
  min-width: 0;
  height: 50px;
  padding: 1em;
  font: inherit;
  border-radius: 0 10px 10px 0;
  border: 2px solid var(--input-color);
  border-left: none;
  background-color: var(--input-color);
  transition: 150ms ease;
}
form input:hover{
  border-color: var(--accent-color);
}
form input:focus{
  outline: none;
  border-color: var(--text-color);
}
div:has(input:focus) > label{
  background-color: var(--text-color);
}
form input::placeholder{
  color: var(--text-color);
}
form button{
  margin-top: 10px;
  border: none;
  border-radius: 1000px;
  padding: .85em 4em;
  background-color: var(--accent-color);
  color: var(--base-color);
  font: inherit;
  font-weight: 600;
  text-transform: uppercase;
  cursor: pointer;
  transition: 150ms ease;
}
form button:hover{
  background-color: var(--text-color);
}
form button:focus{
  outline: none;
  background-color: var(--text-color);
}
a{
  text-decoration: none;
  color: var(--accent-color);
}
a:hover{
  text-decoration: underline;
}
@media(max-width: 1100px){
  .wrapper{
    width: min(600px, 100%);
    border-radius: 0;
  }
}
form div.incorrect label{
  background-color: #f06272;
}
form div.incorrect input{
  border-color: #f06272;
}
#error-message{
  color:#f06272;
}
