.calendar,
.calendar:before, 
.calendar:after, 
.calendar *, 
.calendar *:before, 
.calendar *:after {
    -moz-box-sizing: border-box;
    -webkit-box-sizing: border-box;
    box-sizing: border-box;
}

.contador {
    height: 100%;
    padding: 0;
}

.calendar {
    width: 100%;
    height: 100%;
    background: #012f50;
    margin: 0 auto;
    position: relative;
    padding: 0;
    overflow: hidden;
}

.calendar-inner {
    position: relative;
    text-align: center;
    font-size: 19px;
    color: #ffffff;
    display: flex;
    flex-wrap: wrap;
    align-content: stretch;
    height: 100%;
}

.calendar-top {
    background: #ebb900;
    width: 100%;
    height: 134px;
    display: flex;
    align-items: center;
}

.calendar-bottom {
    width: 100%;
}

.calendar-top-content  {
    width: 100%;
}

.calendar-top-content > div  {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    max-width: 198px;
    margin: 0 auto;
}

.calendar-inner p {
    margin: 2px auto;
    line-height: 25px;
    font-family: "Raleway", sans-serif;
    font-weight: 500;
    font-size: 18px;
}

.text-calendar {
    color: #1e3a5e;
    font-weight: 700;
}

.clearfix:after {
    content: ".";
    clear: both;
    display: block;
    visibility: hidden;
    height: 0px;
}

.counter {
    width: 138px;
    margin: 7px auto 0;
}

.counter .sheet {
    width: 42px;
    height: 50px;
    line-height: 50px;
    perspective: 600px;
    font-size: 39px;
    color: #e79900;
    float: left;
    box-sizing: border-box;
    position: relative;
    z-index: 10;
    font-weight: 700;
    margin: 2px;
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.1);
    font-family: "Raleway", sans-serif;
    font-weight: 700;
}

.counter .sheet:after {
    content: "";
    position: absolute;
    width: 100%;
    height: 1px;
    background: rgba(0, 0, 0, 0.05);
    left: 0;
    top: 25px;
    z-index: 100;
}

.counter .sheet>div {
    height: 50%;
    width: 100%;
    overflow: hidden;
    position: relative;
}

.counter .sheet>div span {
    position: absolute;
    left: 0;
    width: 100%;
    text-align: center;
}

.counter .sheet .up {
    top: 0;
    background-color: #ffffff;
    border-radius: 5px 5px 0 0;
}

.counter .sheet .up span {
    top: 0;
}

.counter .sheet .down {
    bottom: 0;
    background-color: #f4f3f3;
    box-sizing: border-box;
    border-radius: 0 0 5px 5px;
}

.counter .sheet .down span {
    bottom: 0;
}

.counter .sheet .helper {
    position: absolute;
    left: 0;
}

.counter .sheet .helper-up {
    background-color: #ebe7e0;
    border-radius: 5px 5px 0 0;
    top: 0;
    -webkit-transform-origin: center bottom;
    -ms-transform-origin: center bottom;
    transform-origin: center bottom;
    border-top: 1px solid #cac0b2;
}

.counter .sheet .helper-up:nth-child(3) {
    background-color: #ffffff;
}

.counter .sheet .helper-up span {
    top: 0;
}

.counter .sheet .helper-down {
    background-color: #ebe7e0;
    border-radius: 0 0 5px 5px;
    top: 50%;
    border-top: 0px solid #826a4d0d;
    box-sizing: border-box;
    -webkit-transform-origin: center top;
    -ms-transform-origin: center top;
    transform-origin: center top;
    -webkit-transform: rotateX(90deg);
    -ms-transform: rotateX(90deg);
    transform: rotateX(90deg);
    border-bottom: 1px solid #cac0b2;
}

.counter .sheet .helper-down:last-child {
    background-color: #f4f3f3;
    border-bottom: none;
}

.counter .sheet .helper-down span {
    bottom: 0;
}

.calendar .logo-censo {
}

.calendar .logo-censo {
    display: none;
}

.calendar .logo-censo {
    position: absolute;
    display: block;
    height: 72%;
    top: 50%;
    -webkit-transform: translateY(-50%) translateX(-150px) translateZ(130px) rotateY(-90deg);
    transform: translateY(-50%) translateX(-150px) translateZ(130px) rotateY(-90deg);
    right: 64%;
    box-shadow: 0 1px 8px rgba(0,0,0,0.6);
}

.calendar .mascote-homem {
    position: absolute;
    bottom: 0px;
    left: 64%;
    height: 94%;
    -webkit-transform: translateX(150px) translateZ(130px) rotateY(90deg);
    transform: translateX(150px) translateZ(130px) rotateY(90deg);
}

.calendar .mascote-mulher {
    display: none;
}

.calendar .logo-censo.animate {
    -webkit-animation: logo 1.5s cubic-bezier(0.680, -0.550, 0.265, 1.550) forwards;
    animation: logo 1.5s cubic-bezier(0.680, -0.550, 0.265, 1.550) forwards;
    animation-iteration-count: 1;
}

.calendar .mascote-homem.animate {
    -webkit-animation: mascote 1.5s cubic-bezier(0.680, -0.550, 0.265, 1.550) forwards;
    animation: mascote 1.5s cubic-bezier(0.680, -0.550, 0.265, 1.550) forwards;
    animation-iteration-count: 1;
}

.calendar .counter-text {
    margin-top: 0;
    line-height: 22px;
    width: 100%;
    flex: 0 0 auto;
}

.calendar.before-start .calendar-top-content > div {
    max-width: 228px;
}

.start-text {
    background: #f4f3f3;
    box-shadow: 0 0 5px rgb(0 0 0 / 10%);
    border-radius: 3px;
    padding: 19px 5px;
    position: relative;
}

.start-text:before {
    content: "";
    width: 100%;
    position: absolute;
    top: 0;
    left: 0;
    background: #ffffff;
    border-radius: 3px;
    height: 35px;
    border-bottom: 1px solid #cccccc69;
}

.start-text p {
    font-size: 29px;
    color: #e79900;
    font-weight: 700;
    position: relative;
}

@keyframes logo {
    0% {
        -webkit-transform: translateY(-50%) translateX(-150px) translateZ(130px) rotateY(-90deg);
        transform: translateY(-50%) translateX(-150px) translateZ(130px) rotateY(-90deg);
        -webkit-transform-origin: bottom center;
        transform-origin: bottom center;
    }
    100% {
        -webkit-transform: translateY(-50%) translateX(0) translateZ(0) rotateY(0deg);
        transform: translateY(-50%) translateX(0) translateZ(0) rotateY(0deg);
        -webkit-transform-origin: bottom center;
        transform-origin: bottom center;
    }
}

@keyframes mascote {
    0% {
        -webkit-transform: translateX(150px) translateZ(130px) rotateY(90deg);
        transform: translateX(150px) translateZ(130px) rotateY(90deg);
        -webkit-transform-origin: bottom center;
        transform-origin: bottom center;
    }
    100% {
        -webkit-transform: translateX(0) translateZ(0) rotateY(0deg);
        transform: translateX(0) translateZ(0) rotateY(0deg);
        -webkit-transform-origin: bottom center;
        transform-origin: bottom center;
    }
}

@-webkit-keyframes upflip {
    from {
        -webkit-transform: rotateX(0deg);
    }
    to {
        -webkit-transform: rotateX(-90deg);
    }
}

@keyframes upflip {
    from {
        transform: rotateX(0deg);
    }
    to {
        transform: rotateX(-90deg);
    }
}

@-webkit-keyframes downflip {
    0% {
        -webkit-transform: rotateX(90deg);
    }
    100% {
        -webkit-transform: rotateX(0deg);
    }
}

@keyframes downflip {
    0% {
        transform: rotateX(90deg);
    }
    100% {
        transform: rotateX(0deg);
    }
}

@media (max-width: 568px) {
    .calendar-top-content > div {
        flex-direction: column;
        padding: 12px 0;
    }
    
    .calendar .mascote-homem {
        left: 70%;
        height: 89%;
    }
    
    .calendar .logo-censo {
        right: 76%;
        height: 54%;
    }
    
    .counter {
        width: 138px;
        margin: 4px auto;
    }

    .calendar-top-content > div.start-text {
        padding: 19px 5px;
    }
}

@media (max-width: 700px) {    
    .calendar .mascote-homem {
        left: 80%;
        height: 92%;
    }
    
    .calendar .logo-censo {
        right: 79%;
        height: 68%;
    }
}

@media (max-width: 568px) {
    .calendar-top-content {
        flex-direction: column;
        padding: 12px 0;
    }
    
    .calendar .mascote-homem {
        left: 74%;
        height: 89%;
    }
    
    .calendar .logo-censo {
        right: 79%;
        height: 47%;
    }
    
    .counter {
        width: 138px;
        margin: 4px auto;
    }

    .calendar-inner p.text-calendar {
        font-size: 22px;
    }

    .calendar .counter-text {
        line-height: 18px;
        font-size: 16px;
    }
}

@media (max-height: 150px) {
    .calendar-top {
        height: 88px;
    }

    .start-text {
        padding: 10px 5px;
    }
    
    .start-text:before {
        height: 28px;
    }
}

@media (max-width: 450px) { 
    .calendar .mascote-homem {
        left: 74% !important;
        height: 52% !important;
        bottom: 105px;
    }
    
    .calendar .logo-censo {
        right: 75% !important;
        height: 38% !important;
        top: 70px;
    }
}

@media (max-width: 450px) and (max-height: 150px) { 
    .calendar .mascote-homem {
        left: 76% !important;
        height: 58% !important;
        bottom: 53px;
    }
    
    .calendar .logo-censo {
        right: 78% !important;
        height: 50% !important;
        top: 44px;
    }
}

.calendar.after-start .before-start-calendar {
    display: none;
}

.calendar.after-start .after-start-calendar {
    display: block;
}

.calendar.before-start .before-start-calendar {
    display: block;
}

.calendar.before-start .after-start-calendar {
    display: none;
}