/* Fonts */
@import url('https://fonts.googleapis.com/css?family=Josefin+Sans');

/* Color Variables */
:root {
  --black: #000000;
  --white: #ffffff;
  --steel: #4682B4;
  --gray: #808080;
  --light-gray: #D3D3D3;
}

/* General */
* {
  box-sizing: border-box;
}

ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

main {
  position: relative;
  height: 100vh;
  z-index: -10;
  background: linear-gradient(to top, var(--black), var(--steel));
}

body {
  font-size: 12px;
  font-family: 'Josefin Sans', 'Roboto', sans-serif;
  color: var(--white);
  overflow: hidden;
  background-color: var(--black);
}
 .main-content{

  height: 100vh;
 }
/* Specific */
.crane__list,
.skyscrappers__list,
.tree__container {
  position: absolute;
  width: 100%;
  bottom: 0;
}

.advice {
  display: flex;
  height: 50vh;
  width: 100vw;
  flex-flow: column nowrap;
  justify-content: top;
  align-items: center;
}
.advice__title {
  font-size: 2rem;  /* Mobile default */
  text-align: center;
}
.advice__description {
  margin-top: 40%;  /* Mobile default */
  z-index: 999;
  width: 50%;  /* Mobile default */
  position: absolute;
  font-size: 1rem; /* Adding base font size for mobile */
  max-width: 300px;
  height: auto;
  display: block;
}
.advice__description span:first-child {
  margin-right: -0.7rem;
}
.advice__description span:last-child {
  margin-left: -0.7rem;
}

.city-stuff {
  display: flex;
  position: absolute;
  justify-content: center;
  width: 100%;
  height: 100%;
  bottom: 0;
  overflow: hidden;
  box-shadow: inset 0 -60px 0 -30px var(--steel);
}

.skyscrappers__list {
  width: 100%;
  height: 86.66667px;
  left: 0;
}
.skyscrappers__list .skyscrapper__item {
  position: absolute;
  height: inherit;
  bottom: 15%;
  width: 43.33333px;
  background: linear-gradient(115deg, var(--steel) 73%, var(--gray) 73%, var(--gray) 100%);
}
.skyscrappers__list .skyscrapper__item::after {
  content: '';
  position: absolute;
  width: 80%;
  height: 80%;
  left: 10%;
  bottom: 10%;
  background: url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAAGCAYAAAAG5SQMAAAAFElEQVQImWP4////fwYYIJKDEwAAfPsP8eFXG40AAAAASUVORK5CYII=') space;
}
.skyscrappers__list .skyscrapper__item:last-child:not(:only-child) {
  background: var(--steel);
}

.skyscrappers__list .skyscrapper-1 {
  width: 121.33333px;
  height: 138.66667px;
  right: 25%;
  bottom: 0;
  z-index: 10;
  transform: rotate(180deg);
}
.skyscrappers__list .skyscrapper-2 {
  width: 69.33333px;
  height: 108.33333px;
  right: 35%;
  bottom: 10%;
  z-index: 10;
  transform: rotate(180deg);
}
@media screen and (max-width: 900px) {
  .skyscrappers__list .skyscrapper-2 {
    display: none;
  }
}
.skyscrappers__list .skyscrapper-3 {
  width: 46.22222px;
  height: 86.66667px;
  right: 45%;
  bottom: 0;
  z-index: 10;
  transform: rotate(180deg);
}
@media screen and (max-width: 900px) {
  .skyscrappers__list .skyscrapper-3 {
    display: none;
  }
}
.skyscrappers__list .skyscrapper-4 {
  width: 34.66667px;
  height: 86.66667px;
  right: 55%;
  bottom: 0;
  z-index: 10;
  transform: rotate(180deg);
}
.skyscrappers__list .skyscrapper-4::after {
  width: 20%;
  height: 60%;
  left: 25%;
}
.skyscrappers__list .skyscrapper-5 {
  width: 7%;
  right: 67%;
  height: 50%;
  z-index: 11;
}
.skyscrappers__list .skyscrapper-5::after {
  height: 0;
}
@media screen and (max-width: 450px) {
  .skyscrappers__list .skyscrapper-1 {
    display: none;
  }
}

.crane-cabin,
.crane-arm,
.crane-picker {
  transform-origin: 80% center;
  animation: crane__movement 12s infinite alternate;
}

.crane__list {
  width: 260px;
  height: 173.33333px;
  z-index: 0;
  perspective: 600px;
}
.crane__list .crane__item {
  position: absolute;
  border: solid 1px var(--steel);
  border-radius: 2px;
}
.crane__list .crane-cable {
  width: 1px;
  height: 1px;
  border: none;
  outline: 1px solid transparent;
  background: var(--gray);
  z-index: 0;
}
.crane__list .crane-cable-1 {
  width: 60%;
  top: 0;
  left: 11%;
  transform-origin: right 0;
  animation: cable-1__movement 12s infinite alternate;
}
.crane__list .crane-cable-2 {
  width: 19%;
  top: 0;
  right: 8%;
  transform-origin: top left;
  animation: cable-2__movement 12s infinite alternate;
}
.crane__list .crane-cable-3 {
  height: 30%;
  top: 22%;
  left: 9%;
  transform-origin: right center;
  animation: cable-3__movement 12s ease-in-out infinite alternate;
}
.crane__list .crane-cable-3::after {
  content: '';
  display: block;
  position: absolute;
  height: 0.2em;
  width: 9000%;
  bottom: 0;
  left: -4500%;
  background: var(--steel);
  border: 1px solid var(--gray);
}
.crane__list .crane-stand {
  width: 5%;
  height: 100%;
  right: 25%;
  z-index: 1;
  background: linear-gradient(to top, var(--steel), var(--gray));
}
.crane__list .crane-weight {
  width: 8%;
  height: 20%;
  right: 4%;
  top: 12%;
  z-index: 2;
  background: var(--gray);
  transform-origin: 0 center;
  animation: crane-weight__movement 12s infinite alternate;
}
.crane__list .crane-cabin {
  width: 12%;
  height: 9%;
  right: 24%;
  top: 20%;
  z-index: 2;
  background: var(--gray);
}
.crane__list .crane-cabin::after {
  content: '';
  display: block;
  position: absolute;
  width: 100%;
  height: 10%;
  top: 60%;
  left: 0;
  background: var(--light-gray);
}
.crane__list .crane-arm {
  width: 100%;
  height: 7%;
  top: 15%;
  border-top-left-radius: 10px;
  z-index: 3;
  background: var(--gray);
}

.crane-1 {
  left: 20%;
  z-index: 10;
}

.crane-2 {
  left: 30%;
  bottom: -1rem;
  z-index: -1;
  transform: scale(0.75) scaleX(-1);
}
.crane-2 .crane-cable-3 {
  animation-delay: 3s;
}
@media screen and (max-width: 900px) {
  .crane-2 {
    display: none;
  }
}

.crane-3 {
  left: 40%;
  bottom: -0.5rem;
  transform: scale(0.8);
}
.crane-3 .crane-cable-3 {
  animation-delay: 4.5s;
}
@media screen and (max-width: 900px) {
  .crane-3 {
    z-index: -1;
    transform: scale(0.75) scaleX(-1);
  }
}
@media screen and (max-width: 900px) {
  .crane-3 {
    display: none;
  }
}



/* Animations */
@keyframes cable-1__movement {
  0%, 20% {
    transform: rotateY(0) rotateZ(-10deg);
  }
  70%, 100% {
    transform: rotateY(45deg) rotateZ(-10deg);
  }
}
@keyframes cable-2__movement {
  0%, 20% {
    transform: rotateY(0) rotateZ(29deg);
  }
  70%, 100% {
    transform: rotateY(15deg) rotateZ(29deg);
  }
}
@keyframes cable-3__movement {
  0% {
    transform: translate(0, 0);
  }
  20% {
    transform: translate(2500%, -18%);
  }
  60% {
    transform: translate(11000%, -25%);
  }
  70% {
    height: 30%;
    transform: translate(9100%, -25%);
  }
  90%, 100% {
    height: 80%;
    transform: translate(9100%, -15%);
  }
}
@keyframes crane__movement {
  0%, 20% {
    transform: rotateY(0);
  }
  70%, 100% {
    transform: rotateY(45deg);
  }
}
@keyframes crane-weight__movement {
  0%, 20% {
    transform: rotateY(0) translateX(0);
  }
  70%, 100% {
    transform: rotateY(45deg) translateX(-50%);
  }
}

/* Desktop overrides */
@media screen and (min-width: 992px) {
  .advice__title {
    font-size: 3rem;
  }
  
  .advice__description {
    margin-top: 10%;
    width: 30%;
    font-size: 1.2rem;
  }
}

/* Tablet and up */
@media screen and (min-width: 481px) {
    .advice__description {
        margin-top: 20%;
        width: 70%;
    }
}

/* Small desktop and up */
@media screen and (min-width: 769px) {
    .advice__description {
        margin-top: 15%;
        width: 50%;
    }
}