.canvas
  .sky
  .stars
      .falling-stars
        .star-fall
        .star-fall
        .star-fall
        .star-fall
      .small-stars
        -for(i=0;i<12;i++)
          .star
      .medium-stars
        -for(i=0;i<12;i++)
          .star
  .mountains
  .sun
  .glowflies
    .glowfly
    .glowfly
    .glowfly
    .glowfly
    .glowfly
    .glowfly
    .glowfly
    .glowfly
  .tent
    .upper
    .bottom
    .shadow
    .line
    .door
    .door-part
    .door-part.two
  .trees
    .tree
    .tree
    .tree
    .tree
  .floor
View Compiled
* {
  box-sizing: border-box;
}

html, body {
  width: 100%;
  height: 100%;
  overflow-x: hidden;
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
}

body {
  --sky: #010641;
  --gradient-bg: linear-gradient(180deg, rgba(97,77,102,1) 0%, rgba(1,6,65,1) 83%);
  --tree-a: #0e134f;
  --tree-b: #6c5665;
  --mountain: linear-gradient(180deg, rgba(90,80,121,1) 0%, rgba(34,40,104,1) 83%);
  --shadow: #020836;
  --sun: #fdc3aa;
  --growfly: #a57d7a;
  --light: #f9b12f;
  --tent-a: #4c5c9a;
  --tent-b: #252b65;
  background-color: var(--sky);
}

@mixin el-position($left,$bottom) {
  left: $left;
  bottom: $bottom;
}

.canvas {
  position: relative;
  border-radius: 50%;
  width: 600px;
  height: 600px;
  background-color: var(--sky);
  overflow: hidden;
  flex-shrink: 0;
}

.floor {
  position: absolute;
  bottom: 0;
  width: 100%;
  height: 180px;
  background: var(--gradient-bg);
  z-index: 2;
}

.tree {
  position: absolute;
  width: 0;
  height: 0;
  border-left: 50px solid transparent;
  border-right: 50px solid transparent;
  border-bottom: 280px solid var(--tree-a);
  z-index: 3;
  
  &:before {
    content: '';
    position: absolute;
    width: 0;
    height: 0;
    border-bottom: 280px solid var(--shadow);
    border-left: 50px solid transparent;
    transform: translatex(-100%);
  }
  
  &:after {
      position: absolute;
      border-left: 50px solid transparent;
      border-right: 50px solid transparent;
      border-top: 180px solid var(--shadow);
      bottom: -460px;
      left: -102px;
      z-index: 6;
   }

  &:first-child {
     @include el-position(20px,160px);
     z-index: 4;
    
    &:after {
      content: '';
      bottom: -460px;
      left: -122px;
      z-index: 6;
      transform: skew(-32deg);
    }
  }
  
  &:nth-child(2) {
     @include el-position(80px,140px);
     transform: scale(.8);
    
    &:after {
      content: '';
      bottom: -460px;
      left: -102px;
      z-index: 5;
      transform: skew(-30deg);
    }
  }
  
  &:nth-child(3) {
    @include el-position(420px,40px);
    transform: scale(1.6);
    z-index: 6;
  }
  
  &:nth-child(4) {
    @include el-position(490px,140px);
    transform: scale(1.4);
  }
  
  &:nth-child(5) {
    @include el-position(490px,140px);
    transform: scale(1.4);
  }
  
}

.mountains {
  position: absolute;
  width: 280px;
  height: 120px;
  background: var(--mountain);
  @include el-position(40px,120px);
  border-radius: 120%;
  box-shadow: 260px 0 0 rgba(34,40,104,1);
  z-index: 1;
}

.sun {
  position: absolute;
  border-radius: 50%;
  width: 240px;
  height: 240px;
  background-color: var(--sun);
  transform: translatex(-50%);
  @include el-position(50%, 10px);
  box-shadow: 0 0 200px var(--sun);
}

.stars {
  position: absolute;
  z-index: 1;
  width: 100%;
  height: 400px;
}

.star {
  border-radius: 50%;
  background: #ffffff;
  box-shadow: 0px 0px 6px 0px rgba(255,255,255,0.80); 
}

.small-stars .star {
  position: absolute;
  width: 3px;
  height: 3px;
  
  &:nth-child(2n) {
    opacity: 0;
    animation: star-blink 1.2s linear infinite alternate;
  }
  
  &:nth-child(1) {
    @include el-position(210px,50px);
  }
  &:nth-child(2) {
    @include el-position(400px,40px);
  }
  &:nth-child(3) {
    @include el-position(420px, 120px);
  }
  &:nth-child(4) {
    @include el-position(140px,250px);
  }
  &:nth-child(5) {
    @include el-position(400px,300px);
  }
  &:nth-child(6) {
    @include el-position(170px,80px);
  }
  &:nth-child(7) {
    @include el-position(200px,360px);
    animation-delay: .2s;
  }
  &:nth-child(8) {
    @include el-position(250px,320px);
  }
  &:nth-child(9) {
    @include el-position(300px,340px);
  }
  &:nth-child(10) {
    @include el-position(130px,320px);
    animation-delay: .5s;
  }
  &:nth-child(11) {
    @include el-position(230px,330px);
    animation-delay: 7s;
  }
  &:nth-child(12) {
    @include el-position(300px,360px);
    animation-delay: .3s;
  }
  
  @keyframes star-blink {
    50% {
      width: 3px;
      height: 3px;
      opacity: 1;
    }
  }
}

.medium-stars .star {
   position: absolute;
   width: 3px;
   height: 3px;
   opacity: 0;
   animation: star-blink 1.2s ease-in infinite alternate;
  
  &:nth-child(1) {
    @include el-position(300px,50px);
  }
  &:nth-child(2) {
    @include el-position(400px,40px);
    animation-delay: .4s;
  }
  &:nth-child(3) {
    @include el-position(330px, 300px);
     animation-delay: .2s;
  }
  &:nth-child(4) {
    @include el-position(460px,300px);
     animation-delay: .9s;
  }
  &:nth-child(5) {
    @include el-position(300px,150px);
     animation-delay: 1.2s;
  }
  &:nth-child(6) {
    @include el-position(440px,120px);
    animation-delay: 1s;
  }
  &:nth-child(7) {
    @include el-position(200px,140px);
     animation-delay: .8s;
  }
  &:nth-child(8) {
    @include el-position(30px,480px);
    animation-delay: .3s;
  }
  &:nth-child(9) {
    @include el-position(460px,400px);
     animation-delay: 1.2s;
  }
  &:nth-child(10) {
    @include el-position(150px,10px);
    animation-delay: 1s;
  }
  &:nth-child(11) {
    @include el-position(420px,450px);
     animation-delay: 1.2s;
  }
  &:nth-child(12) {
    @include el-position(340px,180px);
    animation-delay: 1.1s;
  }
  
  @keyframes star-blink {
    50% {
      width: 4px;
      height: 4px;
      opacity: 1;
    }
  }
}

.star-fall {
  position: relative;
  border-radius: 2px;
  width: 80px;
  height: 2px;
  overflow: hidden;
  transform: rotate(-20deg);
  
  &:after {
    content: "";
    position: absolute;
    width: 50px;
    height:2px;
    background: linear-gradient(to left, rgba(0,0,0,0) 0%,rgba(255,255,255,0.4) 100%); 
    left: 100%;
    animation: star-fall 3.6s linear infinite;
  }
}

.star-fall:nth-child(1) {
  @include el-position(80px,-100px);
  &:after {
    animation-delay: 2.4s;
  } 
}

.star-fall:nth-child(2) {
  @include el-position(200px,-200px);
  &:after {
    animation-delay: 2s;
  } 
}

.star-fall:nth-child(3) {
  @include el-position(430px,-50px);
  &:after {
    animation-delay: 3.6s;
  } 
}

.star-fall:nth-child(4) {
  @include el-position(400px,100px);
  &:after {
    animation-delay: .2s;
  } 
}

@keyframes star-fall {
  20% {
    left: -100%;
  }
  
  100% {
    left: -100%;
  }
}

.glowfly {
  position: absolute;
  border-radius: 50%;
  background-color: var(--growfly);
  box-shadow: 0 0 14px var(--light);
  width: 8px;
  height: 8px;
  z-index: 8;
  animation: fly 5s ease infinite alternate; 
  
  &:first-child {
    @include el-position(120px,180px);
  }
  
  &:nth-child(1) {
    @include el-position(240px,180px);
    animation-delay: .6s;
  }
  
  &:nth-child(2) {
    @include el-position(340px,160px);
    animation-delay: .8s;
  }
  
  &:nth-child(3) {
    @include el-position(110px,110px);
    animation-delay: .4s;
  }
  
  &:nth-child(4) {
    @include el-position(40px,60px);
    animation-delay: 1s;
  }
  
  &:nth-child(5) {
    @include el-position(80px,240px);
    animation-delay: 1.2s;
  }
  
   &:nth-child(6) {
    @include el-position(480px,140px);
     animation-delay: .2s;
  }
  
  &:nth-child(7) {
    @include el-position(400px,30px);
    animation-delay: .4s;
  }
  &:nth-child(8) {
    @include el-position(400px,200px);
    animation-delay: .5s;
  }
}

@keyframes fly {
  0% { transform: translate( 0, 0); }
  20% { transform: translate( -8px, -8px); }
  60% { transform: translate( 0, 0); }
  80% { transform: translate( -6px, -6px); }
  100% { transform: translate( -10px, -10px); }
}

.tent {
  position: absolute;
  transform: translatex(-50%) scale(1.1);
  @include el-position(50%,120px);
  z-index: 6;
  width: 200px;
  height: 120px;
  
  &:before, &:after {
    content: '';
    position: absolute;
    height: 50px;
    width: 2px;
    background-color: #e09d7d;
  }
  
  &:before {
    transform: rotate(45deg);
    left: -14px;
    bottom: 12px;
  }
  
  &:after {
    transform: rotate(-45deg);
    right: -16px;
    bottom: 12px;
  }
}

.upper {
  position: absolute;
  clip-path: polygon(0% 80%, 50% 0%, 100% 80%, 51.50% 54.16%);
  height: 120px;
  width: 200px;
  background-color: var(--tent-a);
  transform: translatex(-50%);
  @include el-position(50%,30px);
}

.bottom {
  position: absolute;
  clip-path: polygon(50% 0.74%, 99.83% 19.11%, 80.17% 38.15%, 18% 39.26%, -1px 19.85%);
  height: 180px;
  width: 200px;
  bottom: 0;
  left: 0;
  background-color: var(--tent-b);
  transform: translatex(-50%);
  @include el-position(50%,-91px);
}

.shadow {
  position: absolute;
  clip-path: polygon(50% 0.74%, 99.83% 19.11%, 73.77% 28.68%, 27.76% 29.41%, -1px 19.85%);
  height: 240px;
  width: 270px;
  background-color: var(--shadow);
  transform: translatex(-50%) rotate(-180deg);
  @include el-position(50%,-50px);
}

.line {
  position: absolute;
  height: 22px;
  width: 2px;
  background-color: var(--shadow);
  transform: skew(-10deg);
  left: -32px;
  bottom: -4px;
}

.door {
  position: absolute;
  clip-path: polygon(50% 0%, 20% 100%, 88% 100%);
  width: 70px;
  height: 88px;
  transform: translatex(-50%);
  @include el-position(50%, 0);
  z-index: 7;
  background-color: var(--shadow);
}

.door-part {
  position: absolute;
  width: 12px;
  height: 80px;
  background-color: var(--tent-a);
  border-radius: 120%;
  left: calc(50% - 14px);
  bottom: 19px;
  z-index: 8;
  transform: skew(-15deg);
  
  &:before {
    content:'';
    position: absolute;
    clip-path: polygon(50% 0%, 1px 71.55%, 50.50% 100.14%);
    width: 30px;
    height: 80px;
    background-color: var(--tent-a);
    left: -10px;
  }
  
  &.two {
    transform: skew(15deg);
    left: calc(50% + 2px);
    
    &:before {
      clip-path: polygon(50% 0%, 30px 69.27%, 59.34% 99%);
    }
  }
}

@media screen and (max-width: 840px) {
  .canvas {
    transform: scale(.6);
  }
}

@media screen and (max-width: 520px) {
  .canvas {
    transform: scale(.5);
  }
}

@media screen and (max-height: 520px) {
  .canvas {
    transform: scale(.5);
  }
}
View Compiled

External CSS

This Pen doesn't use any external CSS resources.

External JavaScript

This Pen doesn't use any external JavaScript resources.