@import url('https://fonts.googleapis.com/css?family=Lato|ZCOOL+KuaiLe&display=swap');

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

body {
  font-family: 'Lato', sans-serif;
  font-size: 18px;
  line-height: 1.2;
  background-image: linear-gradient(135deg, #c3cfe2 0%, #3f3f3f 100%);
  display: flex;
  flex-direction: column;
}

a {
  text-decoration: none;
  color: #000;
}

a:hover {
  color: #ff0000;
  background: rgba(255, 217, 0, 0.3);
}

.main-window {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  min-height: 100vh;
}

.other-loaders {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  grid-gap: 1rem;
}

.other-loaders h2 {
  grid-column: 1/3;
}

#loader1 {
  grid-column: 1/2;
  grid-row: 2/4;
  height: 100%;
}

.loader {
  margin-top: 5rem;
}

#loader2 {
  grid-row: 4/5;
  grid-column: 1/3;
  display: flex;
  justify-content: space-between;
}

#loader2,
#loader3 {
  height: 20vh;
}

.other-loaders {
  border: blue solid 5px;
  width: 100%;
  padding: 20px;
}

.main {
  text-align: center;
  width: 70%;
  opacity: 0;
  display: none;
  transition: opacity 1s ease-in;
}

.main h1 {
  font-size: 1.75rem;
  margin-bottom: 10px;
}

.main p {
  font-size: 1.2rem;
  color: #333;
}

.btn {
  display: inline-block;
  background: purple;
  color: #fff;
  text-decoration: none;
  border: none;
  border-radius: 5px;
  padding: 10px 20px;
  margin-top: 15px;
}

.btn:hover {
  opacity: 0.9;
}

h2 {
  color: #ff0000;
  text-align: center;
  text-decoration: underline;
  letter-spacing: 0.5rem;
}

h3 {
  margin: 1rem 0;
}

.container {
  height: 25vh;
  overflow: hidden;
}

/* LOADER 1 */
.loader {
  z-index: -1;
  transform-origin: bottom center;
  animation: rotate 3s linear infinite;
}

.circle {
  display: inline-block;
  background-color: purple;
  height: 30px;
  width: 30px;
  border-radius: 50%;
  transform: scale(0);
  animation: grow 1.5s linear infinite;
  margin: -5px;
}

.circle:nth-child(even) {
  background-color: palevioletred;
  animation-delay: 0.75s;
}

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

@keyframes grow {
  50% {
    transform: scale(1);
  }
}

/* LOADER 2 */
.loader2 {
  font-family: 'ZCOOL KuaiLe', cursive;
  font-size: 40px;
  color: rgb(133, 4, 47);
  margin: 1.5rem 0;
}

.loader2::after {
  content: '\2026';
  display: inline-block;
  overflow: hidden;
  vertical-align: bottom;
  animation: dots steps(4, end) 2s infinite;
  width: 0px;
}

@keyframes dots {
  to {
    width: 1.25em;
  }
}

/* LOADER 3 */
.loader3 {
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 2.5rem 0;
}

.loader3 > span {
  display: inline-block;
  background-color: purple;
  width: 0px;
  height: 0px;
  border-radius: 50%;
  margin: 0 8px;
  transform: translate3d(0);
  animation: bounce 0.6s infinite alternate;
}

.loader3 > span:nth-child(2) {
  background-color: palevioletred;
  animation-delay: 0.2s;
}

.loader3 > span:nth-child(3) {
  animation-delay: 0.4s;
}

@keyframes bounce {
  to {
    width: 16px;
    height: 16px;
    transform: translate3d(0, -16px, 0);
  }
}

/* LOADER 4 */
.spinner {
  color: #ccc;
  display: inline-block;
  position: relative;
  width: 80px;
  height: 80px;
}
.spinner div {
  transform-origin: 40px 40px;
  animation: spinner 1.2s linear infinite;
}
.spinner div:after {
  content: '';
  display: block;
  position: absolute;
  top: 3px;
  left: 37px;
  width: 7px;
  height: 21px;
  border-radius: 20%;
  background: #fff;
}
.spinner div:nth-child(1) {
  transform: rotate(0deg);
  animation-delay: -1.1s;
}
.spinner div:nth-child(2) {
  transform: rotate(30deg);
  animation-delay: -1s;
}
.spinner div:nth-child(3) {
  transform: rotate(60deg);
  animation-delay: -0.9s;
}
.spinner div:nth-child(4) {
  transform: rotate(90deg);
  animation-delay: -0.8s;
}
.spinner div:nth-child(5) {
  transform: rotate(120deg);
  animation-delay: -0.7s;
}
.spinner div:nth-child(6) {
  transform: rotate(150deg);
  animation-delay: -0.6s;
}
.spinner div:nth-child(7) {
  transform: rotate(180deg);
  animation-delay: -0.5s;
}
.spinner div:nth-child(8) {
  transform: rotate(210deg);
  animation-delay: -0.4s;
}
.spinner div:nth-child(9) {
  transform: rotate(240deg);
  animation-delay: -0.3s;
}
.spinner div:nth-child(10) {
  transform: rotate(270deg);
  animation-delay: -0.2s;
}
.spinner div:nth-child(11) {
  transform: rotate(300deg);
  animation-delay: -0.1s;
}
.spinner div:nth-child(12) {
  transform: rotate(330deg);
  animation-delay: 0s;
}
@keyframes spinner {
  0% {
    opacity: 1;
  }
  100% {
    opacity: 0;
  }
}

@media (min-width: 700px) {
  body {
    display: grid;
    grid-template-columns: 2fr 1fr;
    grid-gap: 20px;
  }

  .main-window {
    grid-column: 1;
  }

  .other-loaders {
    display: flex;
    flex-direction: column;
    grid-column: 2;
  }

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

  .main p {
    font-size: 2rem;
    color: #333;
  }

  #loader1 {
    height: 40vh;
  }

  #loader1 > .loader {
    margin-top: none;
  }

  #loader2 {
    display: block;
  }

  #loader2.container,
  #loader3.container {
    height: 20vh;
  }
}
