/* Global */

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

:root {
  /* Primary */

  --red: hsl(4, 100%, 67%);
  --light-red: hsl(2, 69%, 92%);

  /* Neutral */

  --blue-800: hsl(234, 29%, 20%);
  --blue-700: hsl(235, 18%, 26%);
  --blue-600: hsl(236, 17%, 37%);
  --grey: hsl(0, 0%, 58%);
  --white: hsl(0, 0%, 100%);
}

/* ========== DESKTOP UI ========== */

/* Body */

body {
  font-family: "Roboto", sans-serif;
  background-color: var(--blue-700);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  overflow-x: hidden;
}

/* -------- FORM CARD ELEMENT -------- */

.form__card {
  background-color: var(--white);
  width: 55%;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  grid-template-rows: repeat(1, 1fr);
  border-radius: 1.2rem;
  margin: 10rem auto;
}

.banner {
  grid-column: 2/3;
  grid-row: 1/2;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.banner__img {
  width: 100%;
}

#mobile__banner {
  display: none;
}

.form__container {
  grid-column: 1/2;
  grid-row: 1/2;
  padding: 2.5rem 2.5rem 2.5rem 3.3rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 1.4rem;
  font-size: 0.8rem;
  color: var(--blue-600);
  font-weight: 500;
}

.form__container h1 {
  font-size: 2.8rem;
  color: var(--blue-800);
}

.form__list {
  padding: 0.7rem 0rem 0.7rem 0rem;
  list-style: none;
}

.form__list li {
  display: flex;
  justify-content: start;
  gap: 1rem;
  align-items: start;
}

.form__list li:not(:last-child) {
  margin: 0rem 0rem 1rem 0rem;
}

.form__list li img {
  height: 1rem;
}

#form {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

#form span {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.7rem;
  font-weight: 800;
}

#form span p {
  color: var(--red);
  display: none; /* set block by dom manipulation */
}

#email {
  padding: 0.9rem;
  border-radius: 0.4rem;
  border-width: 1.1px;
  border-color: var(--grey); /* set var(--red) by dom manipulation */
  border-style: solid;
  color: var(--blue-800); /* set var(--red) by dom manipulation */
  background-color: transparent; /* set var(--light-red) by dom manipulation */
}

#email:focus {
  outline: none;
  border-color: var(--grey);
  border-width: 1.5px;
}

.button {
  margin-top: 0.9rem;
  padding: 1rem;
  border-radius: 0.4rem;
  border: none;
  color: var(--white);
  background-color: var(--blue-800);
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  width: 100%;
}

/* -------- SUCCESS MESSAGE ELEMENT -------- */

.message__container {
  background-color: var(--white);
  width: 30%;
  display: none; /* set flex by dom manipulation */
  flex-direction: column;
  justify-content: center;
  align-items: start;
  border-radius: 1.2rem;
  margin: 10rem auto;
  padding: 3rem;
  gap: 1.5rem;
  font-size: 0.9rem;
  color: var(--blue-600);
  font-weight: 500;
}

.message__container img {
  height: 3.5rem;
}

.message__container h1 {
  font-size: 3rem;
  color: var(--blue-800);
}
.message__container p span {
  color: var(--blue-800);
  font-weight: 700;
}

/* Footer */

.attribution {
  font-size: 11px;
  text-align: center;
  color: var(--grey);
  padding: 2rem;
}
.attribution a {
  color: var(--red);
}

/* ========== SMALL SCREEN UI ========== */

/* Media Query */

@media screen and (max-width: 375px) {
  /* -------- FORM CARD ELEMENT -------- */

  .form__card {
    width: 100%;
    margin: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    border-radius: 0rem;
    position: relative;
  }

  .banner {
    padding: 0rem;
    width: 100%;
  }

  #mobile__banner {
    display: block;
  }

  #desktop__banner {
    display: none;
  }

  .form__container {
    padding: 2rem;
    font-size: 1rem;
  }

  /* -------- SUCCESS MESSAGE ELEMENT -------- */

  .message__container {
    width: 100%;
    border-radius: 0;
    height: 100vh;
    padding: 3rem;
  }

  .message__container h1 {
    font-size: 2rem;
  }
}

@media screen and (min-width: 376px) and (max-width: 500px) {
  /* -------- FORM CARD ELEMENT -------- */

  .form__card {
    width: 100%;
    margin: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    border-radius: 0rem;
    position: relative;
  }

  .banner {
    padding: 0rem;
    width: 100%;
  }

  #mobile__banner {
    display: block;
  }

  #desktop__banner {
    display: none;
  }

  .form__container {
    padding: 2rem;
    font-size: 1rem;
  }

  /* -------- SUCCESS MESSAGE ELEMENT -------- */

  .message__container {
    width: 100%;
    border-radius: 0;
    height: 100vh;
    padding: 3rem;
  }

  .message__container h1 {
    font-size: 3rem;
  }
}

@media screen and (min-width: 501px) and (max-width: 700px) {
  /* -------- FORM CARD ELEMENT -------- */

  body {
    padding: 5rem;
  }

  .form__card {
    width: 100%;
    margin: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    border-radius: 1.2rem;
    position: relative;
  }

  .banner {
    padding: 0rem;
    width: 100%;
  }

  .banner__img {
    border-top-left-radius: 1.2rem;
    border-top-right-radius: 1.2rem;
  }

  #mobile__banner {
    display: block;
  }

  #desktop__banner {
    display: none;
  }

  .form__container {
    padding: 2rem;
    font-size: 1rem;
  }

  /* -------- SUCCESS MESSAGE ELEMENT -------- */

  .message__container {
    width: 100%;
    border-radius: 0;
    height: 100vh;
    padding: 3rem;
    border-radius: 1.2rem;
  }
}

@media screen and (min-width: 701px) and (max-width: 1000px) {
  /* -------- FORM CARD ELEMENT -------- */

  .form__card {
    width: 80%;
  }

  .form__container {
    padding: 3rem 1rem 3rem 2rem;
  }

  /* -------- SUCCESS MESSAGE ELEMENT -------- */

  .message__container {
    width: 60%;
    border-radius: 0;
    height: 80vh;
    padding: 3rem;
    border-radius: 1.2rem;
  }
}

.custom__hidden {
  display: none;
}
