body {
  background-color: #e3f4fc;
  box-sizing: border-box;
}
#l {
  margin: 30px 0;
}

.container {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  -webkit-transform: translate();
  -moz-transform: translate();
  -ms-transform: translate();
  -o-transform: translate();
  display: flex;
  width: 80%;
  height: 80%;
  border-radius: 80px;
  -webkit-border-radius: 80px;
  -moz-border-radius: 80px;
  -ms-border-radius: 80px;
  -o-border-radius: 80px;
  background-color: #fff;
}
.left {
  width: 50%;
  background-color: #ffffff;
  border-top-left-radius: 20px;
  border-bottom-left-radius: 20px;
  display: flex;
  flex-direction: column;
  padding: 20px;
  gap: 20px;
  color: #283d4b;
}

#error-amount,
#error-term,
#error-rate,
#error-type {
  color: red;
  display: none;
}

#currency-amount {
  background-color: #e3f4fc;
  width: 40px;
  height: 44px;
  font-family: Arial, sans-serif;
  color: #79919d;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  font-weight: bold;
  border-top-left-radius: 2px;
  border-bottom-left-radius: 2px;
}

#currency-term {
  background-color: #e3f4fc;
  width: 80px;
  height: 44px;
  font-size: 20px;
  color: #79919d;
  font-family: Arial, sans-serif;
  display: flex;
  align-items: center;
  justify-content: center;
  border-top-right-radius: 2px;
  border-bottom-right-radius: 2px;
  font-weight: bold;
}

#currency-rate {
  background-color: #e3f4fc;
  width: 40px;
  height: 44px;
  font-weight: bold;
  font-family: Arial, sans-serif;
  display: flex;
  align-items: center;
  justify-content: center;
  border-top-right-radius: 2px;
  border-bottom-right-radius: 2px;
  font-size: 20px;
  color: #79919d;
}

#mortgage-amount {
  border-top: 1px solid #8e9fa8;
  border-bottom: 1px solid #8e9fa8;
  border-right: 1px solid #8e9fa8;
  border-left: none;
}

#mortgage-term,
#interest-rate {
  border-top: 1px solid #8e9fa8;
  border-bottom: 1px solid #8e9fa8;
  border-left: 1px solid #8e9fa8;
  border-right: none;
  width: 100%;
}

input[type="text"] {
  height: 40px;
  width: 100%;
  font-size: 20px;
  font-family: Arial, sans-serif;
  cursor: pointer;
  outline: none;
}

.left .head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  margin-bottom: -20px;
}

.left .center {
  display: flex;
  justify-content: center;
  margin-top: 20px;
  width: 100%;
  gap: 200px;
}

.error {
  display: flex;
  justify-content: space-between;
}

#error-rate {
  margin-right: 115px;
}

.title {
  display: flex;
  justify-content: space-between;
  margin-bottom: -15px;
}

#rate {
  margin-right: 170px;
  margin-bottom: -5px;
}

.left .radio-group {
  display: flex;
  align-items: start;
  flex-direction: column;
  width: 100%;
}
.left .radio-group div {
  display: flex;
  align-items: center;
  width: 100%;
  height: 45px;
  gap: 10px;
  font-weight: bold;
  border: 2px solid #8e9fa8;
  border-radius: 4px;
  margin-top: 10px;
  font-size: 20px;
  transition: background-color 0.3s;
}

.left .radio-group div:hover {
  border: 2px solid #ebee97;
  background-color: #fafae0;
}

.radio-group div.selected {
  border: 2px solid #ebee97;
  background-color: #fafae0;
}

.radio label,
.radio2 label {
  cursor: pointer;
  width: 100%;
}

.head p {
  text-decoration: underline;
  cursor: pointer;
  color: #8e9ea4;
}

button {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-size: 20px;
  font-weight: bold;
  width: 40%;
  height: 50px;
  background-color: #d9db30;
  border: none;
  border-radius: 30px;
  -webkit-border-radius: 30px;
  -moz-border-radius: 30px;
  -ms-border-radius: 30px;
  -o-border-radius: 30px;
  margin-top: 20px;
  cursor: pointer;
}

button:hover {
  background-color: #ebee97;
}

.right {
  width: 50%;
  background-color: #133040;
  border-top-right-radius: 20px;
  border-bottom-right-radius: 20px;
  border-bottom-left-radius: 70px;
  padding: 20px;
  display: none;
}

.header {
  margin-left: 15px;
}

.header h2 {
  color: white;
}
.header p,
.results p {
  color: #8ba8ba;
}

.results {
  border-top: 5px solid #d5dc47;
  width: 90%;
  height: 320px;
  margin: auto;
  background-color: #0e2431;
  padding: 20px;
  border-top-left-radius: 10px;
  border-top-right-radius: 10px;
  border-bottom-right-radius: 16px;
  border-bottom-left-radius: 66px;
}
#monthly-repayments {
  color: #dadb2f;
  font-size: 48px;
}

hr {
  width: 100%;
  border: 1px solid #2e4450;
  margin: 30px auto;
}
input[type="radio"] {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  width: 25px;
  height: 25px;
  border: 2px solid #dadfe6;
  border-radius: 50%;
  outline: none;
  cursor: pointer;
  position: relative;
  margin-right: 10px;
}

input[type="radio"]::before {
  content: "";
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background-color: white;
}

input[type="radio"]:checked::before {
  background-color: #d5d92b;
  box-shadow: inset 0 0 0 5px white;
}

#total-repayment {
  color: white;
  font-size: 30px;
}

.result {
  width: 50%;
  background-color: #133040;
  border-top-right-radius: 20px;
  border-bottom-right-radius: 20px;
  border-bottom-left-radius: 70px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.result h2 {
  color: white;
}

.result p {
  color: #8ba8ba;
}

.input-icon {
  display: flex;
  align-items: center;
  border: 1px solid #8e9fa8;
  border-radius: 4px;
  background-color: #e5f3fe;
  overflow: hidden;
  width: fit-content;
  -webkit-border-radius: 4px;
  -moz-border-radius: 4px;
  -ms-border-radius: 4px;
  -o-border-radius: 4px;
  width: 100%;
  margin-top: 10px;
}

.inputs-icon {
  display: flex;
  align-items: center;
  border: 1px solid #8e9fa8;
  border-radius: 4px;
  background-color: #e5f3fe;
  overflow: hidden;
  width: fit-content;
  -webkit-border-radius: 4px;
  -moz-border-radius: 4px;
  -ms-border-radius: 4px;
  -o-border-radius: 4px;
  margin-bottom: 10px;
}

#t {
  display: none;
}

@media (max-width: 1366px) {
  #rate {
    margin-right: 65px;
    margin-bottom: -5px;
  }
}

@media (max-width: 430px) {
  body {
    height: 100vh;
  }
  #t {
    display: block;
    margin-bottom: 10px;
  }
  .title {
    display: none;
  }
  .container {
    flex-direction: column;
    height: 100%;
    width: 100%;
    border-radius: 0px;
  }
  .left {
    width: 90%;
    height: 100%;
  }
  .left .head {
    display: block;
  }
  .left .center {
    display: flex;
    flex-direction: column;
    margin-top: 20px;
    width: 100%;
    gap: 0px;
  }

  .input-icon,
  .inputs-icon {
    width: 88%;
  }

  #mortgage-amount {
    width: 100%;
  }
  .left .radio-group {
    width: 88%;
  }

  button {
    gap: 15px;
    width: 80%;
    margin-left: 15px;
  }

  .right {
    width: 90%;
    border-top-right-radius: 0px;
    border-bottom-right-radius: 0px;
    border-bottom-left-radius: 0px;
  }

  .result {
    width: 90%;
    border-top-right-radius: 0px;
    border-bottom-right-radius: 0px;
    border-bottom-left-radius: 0px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
  }

  .header p {
    width: 88%;
  }
  .results {
    width: 90%;
    height: 250px;
    margin-right: 70px;
    background-color: #0e2431;
    border-top-left-radius: 10px;
    border-top-right-radius: 10px;
    border-bottom-right-radius: 10px;
    border-bottom-left-radius: 10px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
  }
  .results div p {
    margin-top: 20px;
  }
  hr {
    margin-bottom: 20px;
    margin-top: -20px;
  }
}
