@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;500&display=swap");

*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: Inter, sans-serif;
  height: 100vh;
  background-color: #1a1a1a;
  color: #dedede;
  display: flex;
  justify-content: center;
  align-items: center;
}

.input-wrapper {
  position: relative;
  font-size: 20px;
}

.input-wrapper input {
  all: unset;
  width: 100%;
  padding: 10px 0;
  border-bottom: 2px solid #dedede;
}

.input-wrapper label {
  position: absolute;
  bottom: 10px;
  left: 0;
  color: #999999;
  pointer-events: none;
  transition: all 0.3s ease;
}

.input-wrapper input:is(:focus, :valid) ~ label {
  bottom: 100%;
  font-size: 16px;
  color: #666;
}

.input-wrapper > .underline {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background-color: #2196f3;
  scale: 0 1;
  transition: 0.3s;
}

.input-wrapper input:focus ~ .underline {
  scale: 1 1;
}
