*,
*::before,
*::after {
  padding: 0px;
  margin: 0px;
  box-sizing: border-box;
  font-family: Verdana, Geneva, Tahoma, sans-serif;
}

html,
body {
  height: 100%;
}

html {
  font-size: 62.5%;
  min-width: 40rem;
}

body {
  font-size: 1.4rem;
}

a {
  text-decoration: none;
  color: var(--linkTextColor);

  &:hover {
    text-decoration: underline;
  }
}

h2 {
  font-size: 1.6rem;
  padding: 1rem;
}

ul {
  list-style: none;

  li {
      margin: 0.3rem;
      padding: 0.2rem;
    }

    img {
      width: 1.6rem;
    }
}

img[disabled=true] {
  filter: grayscale(100%);
}

section {
  padding: 1rem;
  min-width: 35rem;
}

main {
  section {
    border: 1px solid var(--sectionBorderColor);
    background-color: var(--sectionBgColor);

    header {
      border-bottom: 1px solid var(--sectionBorderColor);

      h2 {
        color: var(--mainH2Color);
      }
    }
  }

  input,
  textarea,
  button {
    padding: 0.5rem;
    font-size: 1.4rem;
  }

  button,
  input[type="Submit"] {
    background-color: var(--buttonBgColor);
    padding: 0.5rem;
    font-weight: bold;
    color: #0E1A2B;
    border: 1px solid var(--buttonBorderColor);
    cursor: pointer;
    width: 15rem;
  }

  button:disabled,
  input[type="Submit"]:disabled {
  background-color: var(--buttonDisabledBgColor);
  border-color: var(--buttonDisabledBorderColor);
  }
}

.grid {
  display: grid;
  padding: 0.5rem;
  gap: 1rem;
  
    &.center {
      justify-content: center;
    }

    &.fit {
        grid-template-columns: repeat(auto-fit, minmax(35rem, max-content));
    }

    &.fill {
        grid-template-columns: repeat(auto-fill, minmax(35rem, max-content));
    }
}

form {
  padding: 1rem;

  fieldset {
    display: grid;
    border: none;
    gap: 1rem;

    > div.input {
      padding-top: 2rem;
      position: relative;

      input,
      textarea {
        outline: none;
        border: 1px solid var(--inputBorderColor);
        resize: none;
        width: 100%;
      }

      input ~ label,
      textarea ~ label {
        position: absolute;
        top: 2.7rem;
        left: 0.7rem;
        transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
        cursor: text;
        user-select: none;
        color: var(--inputPlaceholderColor);
      }

      input:focus ~ label,
      textarea ~ label,
      input:not(:placeholder-shown) ~ label,
      textarea:not(:placeholder-shown) ~ label {
        top: 0.5rem;
        left: 0.2rem;
        font-size: 1.1rem;
        color: var(--inputPlaceholderHighlightColor);
      }
    }
  }
}

p {
  padding: 1rem;
}

#Summary {
  padding: 1rem;
  display: none;
}

.right {
  text-align: right;
}

.invalid {
  border: 1px solid red !important;
}

.errors, .red {
  color: red;
}

.green {
  color: green;
  font-weight: bold;
}

.red {
  font-weight: bold;
}