* {
  box-sizing: border-box;
}

body {
  display: flex;
  flex-direction: column;
  justify-content: center;
  margin: 0;
  padding: 0;
  min-width: 100vw;
  min-height: 100vh;
  background: url(../images/cloud.png) calc(50% + 500px) -450px no-repeat,
    url(../images/cloud.png) calc(50% - 350px) 520px no-repeat, #fff;
  background-size: 900px;
  color: #31353d;
  font-family: "DM Sans", sans-serif;
  font-size: 16px;
  font-weight: 300;
  line-height: 22px;
}

[data-show="loader"] #loader,
[data-show="google"] #google,
[data-show="facebook"] #facebook,
[data-show="other"] #other,
[data-show="private"] #private,
[data-show="thanks"] #thanks,
[data-show="missing"] #missing,
[data-show="error"] #error,
[data-show="terms"] #terms {
  display: block;
}

header {
  display: flex;
  background: #5a6972;
  box-shadow: 0 4px 4px 0 rgb(48, 52, 60, 0.19);
  padding: 16px 32px;
}

article {
  display: flex;
  align-items: start;
  justify-content: center;
  flex-grow: 1;
}

section {
  display: none;
  max-width: 600px;
  border-radius: 8px;
  background-color: #fff;
  box-shadow: 0 4px 10px 0 rgb(42, 38, 56, 14%);
  padding: 24px;
  margin: 24px;
}

h1 {
  color: #000;
  font-size: 24px;
  line-height: 32px;
  margin: 0 0 8px 0;
}

p {
  margin: 16px 0;
}

p:last-child {
  margin-bottom: 0;
}

.subtitle {
  margin: 0;
}

.content {
  max-width: 320px;
  margin: 0 auto;
  padding: 0;
  text-align: center;
}

.graphic {
  margin: 48px 0;
}

.button {
  font-family: "DM Sans", sans-serif;
  display: block;
  background: #ff31a2;
  color: #fff;
  font-weight: bold;
  font-size: 16px;
  border-radius: 48px;
  cursor: pointer;
  padding: 16px;
  text-decoration: none;
  margin: 0 auto 24px auto;
  text-align: center;
  border: 0;
  width: 100%;
  max-width: 320px;
  line-height: 1em;
}

.link {
  display: flex;
  align-items: center;
  font-family: "DM Sans", sans-serif;
  font-size: 1em;
  color: inherit;
  font-weight: 200;
  background: transparent;
  border: 0;
  cursor: pointer;
  text-decoration: none;
  margin: 0 40px 24px;
  width: calc(100% - 80px);
  text-align: left;
}

.link.traditional {
  justify-content: center;
  margin: 40px 0 0 0;
  text-decoration: underline;
  width: 100%;
}

.link.visible {
  display: flex;
}

.icon {
  width: 40px;
  margin-right: 16px;
}

.text.visible {
  display: inline;
}

.back {
  display: inline-flex;
  font-family: "DM Sans", sans-serif;
  font-size: 20px;
  padding: 8px;
  margin: 0 0 8px 0;
  border: 0;
  background: transparent;
  cursor: pointer;
  color: #31353d;
}

.back.hidden {
  display: none;
}

.backIcon {
  margin-right: 16px;
}

.googleContent,
.facebookContent,
.otherContent {
  display: none;
}

#review {
  font-family: "DM Sans", sans-serif;
  font-size: 16px;
  display: block;
  width: 100%;
  border: solid 1px #c3c8d2;
  border-radius: 4px;
  padding: 16px;
  margin-bottom: 32px;
  line-height: 1.8em;
  color: #31353d;
  resize: none;
}

#review:focus {
  outline-color: #009fe8;
}

#loader {
  display: none;
  width: 64px;
  height: 64px;
  margin-top: 80px;
  background: #fff;
  border-radius: 50%;
}

#loader div {
  box-sizing: border-box;
  display: block;
  position: absolute;
  width: 56px;
  height: 56px;
  margin: 4px;
  border: 6px solid #009fe8;
  border-radius: 50%;
  animation: rotation 1.2s cubic-bezier(0.5, 0, 0.5, 1) infinite;
  border-color: #009fe8 transparent transparent transparent;
}

#loader div:nth-child(1) {
  animation-delay: -0.45s;
}

#loader div:nth-child(2) {
  animation-delay: -0.3s;
}

#loader div:nth-child(3) {
  animation-delay: -0.15s;
}

@keyframes rotation {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

@media only screen and (max-width: 425px) {
  header {
    padding: 8px 16px;
  }

  header img {
    height: 16px;
  }

  section {
    margin: 16px;
    padding: 16px;
  }

  .link {
    margin: 0 0 16px 0;
    width: 100%;
    justify-content: center;
  }

  .icon {
    margin-right: 8px;
  }
}

@media only screen and (max-width: 350px) {
  html,
  body {
    background: none;
  }

  section {
    margin: 0;
    box-shadow: none;
  }
}
