body {
  background-color: #fafafa;
  background-image: linear-gradient(#121212 168px, transparent 168px);
  background-repeat: no-repeat;
  font-family: Arial, sans-serif;
  font-size: 14px;
  margin: 0;
}

input,
button {
  font-family: inherit;
}

.header {
  max-width: 640px;
  margin: 0 auto;
  padding-top: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.header span {
  color: #ffffff;
  font-size: 24px;
}

.header a {
  color: #b4b4b4;
  text-decoration: none;
  margin-right: 16px;
}

.header a:last-child {
  margin-right: 0;
}

.ad-slot {
  max-width: 640px;
  margin: 16px auto 0 auto;
  min-height: 0;
  text-align: center;
  box-sizing: border-box;
}

form {
  background-color: #ffffff;
  max-width: 640px;
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.10);
  margin: 32px auto 0 auto;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  box-sizing: border-box;
}

form button,
form input {
  height: 48px;
  border-radius: 6px;
}

.form__title {
  color: #363636;
  font-size: 14px;
  font-weight: bold;
  line-height: 16px;
  text-overflow: ellipsis;
  white-space: nowrap;
  overflow: hidden;
}

.form__input input {
  color: #595959;
  background-color: #fafafa;
  font-size: 16px;
  width: 100%;
  border: 1px solid #e2e2e2;
  padding: 0 12px;
  outline: none;
  box-sizing: border-box;
}

.form__actions {
  display: flex;
  justify-content: space-between;
}

.form__formats {
  background-color: #fafafa;
  border: 1px solid #e2e2e2;
  height: 48px;
  border-radius: 6px;
  padding: 6px;
  display: flex;
  align-items: center;
  gap: 6px;
  box-sizing: border-box;
}

.form__formats button[type="button"] {
  color: #494949;
  background-color: transparent;
  font-size: 14px;
  border: none;
  border-radius: 4px;
  height: 34px;
  padding: 0 24px;
  cursor: pointer;
}

.form__formats button[type="button"].active {
  color: #ffffff;
  background-color: #121212;
}

.form__actions button[type="submit"] {
  color: #ffffff;
  background-color: #d62828;
  font-size: 16px;
  border: none;
  cursor: pointer;
  padding: 0 24px;
}

.form__input--progress {
  color: #595959;
  background-color: #fafafa;
  width: 100%;
  height: 48px;
  border: 1px solid #e2e2e2;
  border-radius: 6px;
  padding: 0 12px;
  display: flex;
  align-items: center;
  gap: 8px;
  justify-content: left;
  box-sizing: border-box;
}

.form__loader {
  width: 16px;
  height: 16px;
  border: 2px solid #e2e2e2;
  border-top-color: #d62828;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  flex-shrink: 0;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.form__actions--download {
  display: flex;
  justify-content: space-between;
}

.form__actions--download button.more {
  color: #363636;
  background-color: #ffffff;
  font-size: 16px;
  border: 1px solid #e2e2e2;
  padding: 0 12px;
  cursor: pointer;
}

.form__actions--download button.more:disabled {
  color: #b4b4b4;
  background-color: #fafafa;
  cursor: not-allowed;
}

.form__actions--download button.download {
  color: #ffffff;
  background-color: #d62828;
  font-size: 16px;
  border: none;
  padding: 0 24px;
  cursor: pointer;
}

.form__actions--download button.download:disabled {
  cursor: not-allowed;
  opacity: 0.4;
}

.form__error--title {
  color: #363636;
  font-size: 14px;
  font-weight: bold;
  line-height: 16px;
}

.form__error--message {
  color: #595959;
  background-color: #fafafa;
  font-size: 16px;
  line-height: 48px;
  height: 48px;
  border: 1px solid #e2e2e2;
  border-radius: 6px;
  padding: 0 12px;
  box-sizing: border-box;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.form__error--button {
  display: flex;
  justify-content: right;
}

.form__error--button button {
  color: #ffffff;
  background-color: #d62828;
  font-size: 16px;
  border: none;
  padding: 0 24px;
  cursor: pointer;
}

.text {
  color: #494949;
  max-width: 640px;
  margin: 48px auto 0 auto;
}

.text h1 {
  color: #363636;
  font-size: 24px;
  line-height: 24px;
  margin: 0;
}

.text h2 {
  color: #363636;
  font-size: 20px;
  line-height: 20px;
  margin: 24px 0 16px 0;
}

.text p {
  font-size: 14px;
  line-height: 24px;
  margin: 16px 0 0 0;
}

.text p.b {
  font-weight: bold;
}

.text a {
  color: #494949;
}

.text ol {
  list-style-position: inside;
  margin: 8px 0 0 0;
  padding: 0;
}

.text li {
  line-height: 24px;
  margin-bottom: 4px;
}

.text li::marker {
  font-weight: bold;
}

.text li:last-child {
  margin-bottom: 0;
}

.footer {
  border-top: 1px solid #e2e2e2;
  margin-top: 48px;
}

.footer div {
  text-align: center;
  max-width: 640px;
  margin: 0 auto;
  padding: 24px 0;
}

.footer a {
  color: #363636;
  text-decoration: none;
  margin: 0 8px;
}

@media (max-width: 640px) {
  .header {
    padding: 16px 4% 0 4%;
  }

  .header a:nth-of-type(3),
  .header a:nth-of-type(4) {
    display: none;
  }

  form {
    margin: 32px 4% 0 4%;
  }

  .text {
    margin: 48px 4% 0 4%;
  }

  .ad-slot {
    margin-left: 4%;
    margin-right: 4%;
  }
}
