@import url("https://fonts.googleapis.com/css2?family=Balsamiq+Sans:ital,wght@0,400;0,700;1,400;1,700&family=Exo+2:ital,wght@0,100..900;1,100..900&display=swap");

body {
  margin: 0 auto;
  background-color: aliceblue;
  font-family: "Balsamiq Sans";
  -webkit-tap-highlight-color: transparent;
}

.toggle-button-container {
  border-radius: 12px;
  border: 1px solid #39a183;
  background-color: #ffffff;
  color: #111827;
  max-width: fit-content;
  padding: 4px;
  position: relative;
  display: grid;
  justify-content: center;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  margin-bottom: 16px;

  label {
    color: #6b7280;
    cursor: pointer;
    display: inline-block;
    font-size: 16px;
    font-weight: 400;
    padding: 8px 12px;
    text-align: center;
    transition: color 0.2s;
    position: relative;
    z-index: 1;
  }

  .selected {
    background-color: rgba(57, 161, 131, 0.3);
    border-radius: 8px;
    border: 1px solid #39a183;
    color: var(--text-black);
    height: calc(100% - 8px);
    transform: translateY(-50%);
    transition: transform 0.3s;
    width: calc(50% - 8px);
    position: absolute;
    top: 50%;
    left: 4px;
  }

  .toggleActive {
    transform: translateX(calc(100% + 5px)) translateY(-50%);
  }

  input[type="radio"]:checked + label {
    color: #111827;
  }

  input[type="radio"] {
    position: absolute !important;
    width: 0 !important;
    height: 0 !important;
    visibility: hidden;
  }
}

.header {
  background-color: #1d2037;
  padding: 30px 40px 20px;
  margin-bottom: 25px;
  color: #ffffff;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

h1 {
  margin: 5px 0 25px;
}

textarea {
  border-radius: 5px;
  min-width: 50%;
  height: 27px;
  padding: 8px 10px 0px;
  font-size: 16px;
  margin-bottom: 10px;
  overflow: hidden;
  resize: none;
}

#encrypt {
  min-width: 15%;
  background-color: #ffffff;
  color: #111827;
  text-align: center;
  transition: 0.2s;
  font-size: 20px;
  font-family: "Exo 2";
  font-weight: 500;
  border-radius: 10px;
  padding: 10px;
  margin-top: 10px;
  border: 4px solid #ffffff;
  cursor: pointer;

  &:active {
    font-weight: bold;
    background-color: #cfe2da;
  }

  @media (hover: hover) {
    &:hover {
      font-weight: bold;
      background-color: #cfe2da;
    }
  }
}

table {
  border-spacing: 0px;
  border: 1px solid #f0f0f0;
  margin-bottom: 25px;
  background-color: #e3e3e3;
}

th {
  background-color: #1d2037;
  color: #ffffff;
  width: 100vw;
  font-size: 20px;
  font-family: "Exo 2";
  font-weight: bold;
  padding: 8px;
  border-right: 1px solid #f0f0f0;
}

td {
  padding: 8px;
  text-align: left;
  line-break: anywhere;
  border-right: 1px solid #f0f0f0;
}

tr:nth-child(even) {
  background-color: #ffffff;
}

@media only screen and (max-width: 1024px) {
  textarea {
    min-width: 75%;
  }
}

@media only screen and (max-width: 768px) {
  #encrypt {
    font-size: 16px;
  }

  textarea {
    min-width: 100%;
  }

  th {
    font-size: 14px;
  }
}
