* {
  box-sizing: border-box;
}
:root {
  --primary-color: #f44336;
}
body {
  margin: 0;
  background-color: #eee;
  font-family: Arial, Helvetica, sans-serif;
}
h1 {
  text-align: center;
  padding: 20px;
  margin: 0 0 20px;
  background-color: white;
}
.guess-game {
  text-align: center;
  margin: 0 20px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  max-width: 1000px;
  .game-area {
    .inputs {
      > div {
        margin-bottom: 20px;
        display: flex;
        justify-content: center;
        align-items: center;
        span {
          font-size: 30px;
          margin-right: 15px;
          font-weight: bold;
        }
      }
      .disabled-inputs {
        opacity: 0.5;
        pointer-events: none;
      }
      input {
        margin: 0 5px;
        width: 60px;
        height: 60px;
        text-align: center;
        font-size: 50px;
        caret-color: var(--primary-color);
        background-color: white;
        border: none;
        border-bottom: 3px solid #333;
        &:focus {
          outline-color: #ccc;
        }
        &.yes-in-place {
          background-color: #18ba89;
          border: #18ba89;
          color: white;
        }
        &.not-in-place {
          background-color: #f89e13;
          border: #f89e13;
          color: white;
        }
        &.no {
          background-color: #27303f;
          border: #27303f;
          color: white;
        }
      }
    }
    .control {
      display: flex;
      justify-content: center;
      align-items: center;
      margin: 30px auto;
      gap: 10px;
      .check {
        background-color: var(--primary-color);
        flex: 1;
      }
      .hint {
        background-color: #009688;
        width: fit-content;
      }
      button {
        border: none;
        font-size: 25px;
        padding: 15px 20px;
        border-radius: 6px;
        color: white;
        cursor: pointer;
        font-weight: bold;
      }
      button:disabled {
        background-color: black;
        opacity: 0.4;
        cursor: no-drop;
      }
    }
  }
  .key-colors {
    .key-color {
      display: flex;
      align-items: center;
      padding: 15px;
      background-color: white;
      margin-bottom: 10px;
      .key {
        width: 30px;
        height: 30px;
        border-radius: 50%;
        margin-right: 10px;
        &.in-place {
          background-color: #18ba89;
        }
        &.not-in-place {
          background-color: #f89e13;
        }
        &.no {
          background-color: #27303f;
        }
      }
      .key-text {
        font-size: 20px;
        font-weight: bold;
      }
    }
  }
}
@media (max-width: 950px) {
  .guess-game {
    flex-direction: column;
    align-items: center;
  }
  .guess-game .game-area {
    margin-top: 10px;
  }
  .guess-game h2 {
    margin: 0 0 15px;
  }
  .guess-game input {
    width: 40px !important;
    height: 40px !important;
    font-size: 25px !important;
  }
  .guess-game .check {
    flex: none !important;
  }
  .guess-game .key-color {
    padding: 10px !important;
  }
}
@media (max-width: 500px) {
  h1 {
    padding: 10px;
    margin: 0 0 10px;
  }
  .inputs > div {
    margin-bottom: 10px !important;
  }
  .inputs > div span {
    font-size: 15px !important;
  }
  .guess-game input {
    width: 35px !important;
    height: 35px !important;
    font-size: 20px !important;
  }
  .guess-game .key-text {
    font-size: 16px !important;
  }
  .guess-game .control button {
    font-size: 20px !important;
  }
}
.message {
  text-align: center;
  font-weight: bold;
  font-size: 30px;
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  border: 3px solid;
  padding: 10px;
  display: none;
  color: white;
  span {
    font-weight: bold;
    display: block;
    font-size: 50px;
    text-transform: capitalize;
    margin-top: 10px;
  }
  p {
    margin-top: 15px;
  }
}
.message.s {
  display: block;
  background-color: #009688;
  border-color: #95fff5;
  span {
    color: #95fff5;
  }
}
.message.f {
  display: block;
  background-color: #a82a2a;
  border-color: #ffaba5;
  span {
    color: #ffaba5;
  }
}
@media (max-width: 500px) {
  .message {
    width: 280px;
  }
  
}