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



body {
  margin: 16px;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen,
    Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  background-color: #fafafa;
  color: #212121;
  line-height: 1.5;
}

img {
  max-width: 100%;
  display: block;
} 

input,
button,
textarea,
select {
  font: inherit;
}

ul {
  list-style: none;

}

input,
textarea,
select {
  outline: none;
  box-shadow: none;
}

input {
  border: 1px solid #808080;
  border-radius: 4px;
  width: 360px;
  height: 40px;
  font-family: "Montserrat", sans-serif;
  font-weight: 400;
  font-size: 16px;
  line-height: 1.5;
  letter-spacing: 0.04em;
  color: #2e2f42;
}

input:hover {
  border: 1px solid #000;
}

input:active {
  border: 1px solid #808080;
}

.main-li {
  border: none;
}

/*Task1*/
.item {
  border-radius: 8px;
  padding: 16px;
  width: 392px;
  height: 100%;
  background-color: #f6f6fe;
  margin-bottom: 24px;
  border: none;
}

h2 {
  font-family: "Montserrat", sans-serif;
  font-weight: 600;
  font-size: 24px;
  line-height: 1.33;
  letter-spacing: 0.04em;
  color: #2e2f42;
  margin: 0;
  margin-bottom: 16px;
}

li {
  border: 1px solid #808080;
  border-radius: 4px;
  width: 360px;
  height: 40px;
  margin-bottom: 8px;
  padding: 8px 16px;
}

/*Task2*/
.gallery {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  row-gap: 48px;
  margin: auto;
  column-gap: 24px;

  margin-top: 100px;
  width: 1128px;
}

.gallery li {
  width: 360px;
  height: 300px;
  overflow: hidden;
  margin: 0;
  padding: 0;
  border: none;
  border-radius: 0;
}

.gallery img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/*Task3*/

#name-input {
  margin-top: 100px;
  margin-bottom: 16px;

  border: 1px solid #808080;
  border-radius: 4px;
  width: 360px;
  height: 40px;
}

#name-input::placeholder {
  font-family: "Montserrat", sans-serif;
  font-weight: 400;
  font-size: 16px;
  line-height: 1.5;
  letter-spacing: 0.04em;
  color: #2e2f42;

  padding-bottom: 8px;
  padding-top: 8px;
  padding-left: 16px;
}

#name-output, h1 {
  font-family: "Montserrat", sans-serif;
  font-weight: 600;
  font-size: 24px;
  line-height: 1.33;
  letter-spacing: 0.04em;
  color: #2e2f42;
}

/*Task4*/

.login-form { 
  display: flex;
  flex-direction: column;
}

.login-form label {
  display: flex;
  flex-direction: column;
  margin-top: 8px;

  font-family: "Montserrat", sans-serif;
  font-weight: 400;
  font-size: 16px;
  line-height: 1.5;
  letter-spacing: 0.04em;
  color: #2e2f42;
}

.login-form label input {
  margin-top: 8px;
}

.login-form button {
  font-family: "Montserrat", sans-serif;
  font-weight: 500;
  font-size: 16px;
  line-height: 1.5;
  letter-spacing: 0.04em;
  color: #fff;

  border-radius: 8px;
  border: none;
  padding: 8px 16px;
  width: 86px;
  height: 40px;
  background-color: #4e75ff;

  margin-top: 16px;
}

.login-form button:hover {
  background-color: #6c8cff;
}

/*Task5*/

.widget {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.widget p,
.color {
  font-family: "Montserrat", sans-serif;
  font-weight: 400;
  font-size: 16px;
  line-height: 1.5;
  letter-spacing: 0.04em;
  color: #2e2f42;
}

.change-color {
  font-family: "Montserrat", sans-serif;
  font-weight: 500;
  font-size: 16px;
  line-height: 1.5;
  letter-spacing: 0.04em;
  color: #fff;

  border-radius: 8px;
  border: none;
  padding: 8px 16px;
  width: 148px;
  height: 40px;
  background-color: #4e75ff;

  margin-top: 16px;
}

.change-color:hover {
  background-color: #6c8cff;
}