:root {
  --black: #072227;
  --dark-blue: #35858b;
  --blue: #4fbdba;
  --blue-light: #aefeff;
  --white: #fff8f3;
  --yellow: #ffbd35;
}

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

body {
  /* font-family: "Genos", sans-serif; */
  font-family: "M PLUS 1 Code", sans-serif;
  min-height: 100vh;
  background-color: var(--blue-light);
  display: grid;
  place-items: center;
}

input,
button {
  font-family: "Genos", sans-serif;
  text-transform: uppercase;
}

.container {
  border-radius: 1rem;
  padding: 2rem;
  margin: 0 auto;
  width: 920px;
  background-color: var(--dark-blue);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  box-shadow: 0.3em 0.5em 0.5em hsl(200 50% 30%);
}

.title {
  color: var(--white);
  font-family: "Genos", sans-serif;
  margin-bottom: 2rem;

  text-shadow: 0.1em 0.1em 0 hsl(200 50% 30%);
}

form {
  width: 100%;
  margin-bottom: 1rem;
  display: grid;
  grid-template-columns: 2fr 1fr;
}

form label {
  margin-bottom: 0.5rem;
  grid-column-start: span 2;
  display: block;
  font-size: 1.2rem;
}

form input {
  font-size: 1.2rem;
  border: none;
  border-radius: 0.5rem;
  margin-right: 2rem;
  padding: 0.5rem;
  background-color: var(--white);
}

.error {
  outline: 1px solid #b92b2b;
  border: 1px solid #b92b2b;
}

.error-message {
  margin-bottom: 0.5rem;
  text-align: center;
  width: 100%;
}

.span-error {
  background-color: #ffaeae;
  text-align: center;
  font-size: 1rem;
  font-weight: 900;
  color: #b92b2b;
}

form button {
  border: none;
  font-size: 1.2rem;
  padding: 0.5rem;
  border-radius: 0.5rem;
  background-color: var(--blue-light);
  cursor: pointer;
  transition: all 0.2s;
  box-shadow: 0.1em 0.1em 0 hsl(200 50% 30%);
}

form button:hover {
  background-color: var(--yellow);
  color: var(--white);
}

/* ==== OUTPUT ==== */

.output-binary .decimal-output-text,
.output-decimal .binary-output-text {
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
}

.binary-output-box,
.decimal-output-box {
  width: 100%;
  min-height: 5rem;
  max-height: 10rem;
  overflow-y: auto;
  background: var(--white);
  margin-bottom: 0.5rem;
  border-radius: 0.5rem;
}

.conversion-box {
  border-bottom: 1px solid #000;
  padding: 0.5rem;
}

.conversion-box p {
  font-weight: 700;
  display: inline-block;
  margin: 0 1rem 0 0;
}

.resetBtnBinary,
.resetBtnDecimal {
  font-size: 1.2rem;
  border: none;
  border-radius: 0.5rem;
  width: 100%;
  max-width: 100%;
  padding: 0.5rem;
  background-color: #ffaeae;
  cursor: pointer;
  transition: all 0.2s;
  box-shadow: 0.1em 0.1em 0.2em hsla(0, 62%, 45%, 0.788);
}

.resetBtnBinary:hover,
.resetBtnDecimal:hover {
  color: var(--white);
  background-color: hsl(0, 62%, 45%);
}

/* ==== MEDIA QUERIES ==== */

@media screen and (max-width: 960px) {
  .container {
    width: 700px;
    grid-template-columns: 1fr;
  }
}

@media screen and (max-width: 768px) {
  .container {
    width: 80%;
  }
}

/* OCULTAR FLECHAS INPUT */

input::-webkit-outer-spin-button,
input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

/* Firefox */
input[type="number"] {
  -moz-appearance: textfield;
}
